Skip to content

Commit

Permalink
fixes from PR review
Browse files Browse the repository at this point in the history
  • Loading branch information
Thomas Morris committed Apr 17, 2024
1 parent 22a0650 commit 9153e46
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 10 deletions.
2 changes: 1 addition & 1 deletion docs/source/agent.rst
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ The blop ``Agent`` takes care of the entire optimization loop, from data acquisi
dofs = [
DOF(name="x1", description="the first DOF", search_domain=(-10, 10))
DOF(name="x2", description="another DOF", search_domain=(-5, 5))
DOF(name="x3", description="yet nother DOF", search_domain=(0, 1))
DOF(name="x3", description="yet another DOF", search_domain=(0, 1))
]
objective = [
Expand Down
4 changes: 4 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,10 @@ napari = [
"napari"
]

gui = [
"nicegui"
]

dev = [
"black",
"pytest-codecov",
Expand Down
18 changes: 9 additions & 9 deletions src/blop/dofs.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,13 +49,19 @@ class DOF:
name: str
The name of the DOF. This is used as a key to index observed data.
description: str, optional
A longer name for the DOF.
units: str
The units of the DOF (e.g. mm or deg). This is just for plotting and general sanity checking.
A longer, more descriptive name for the DOF.
type: str
What kind of DOF it is. A DOF can be:
- Continuous, meaning that it can vary to any point between a lower and upper bound.
- Binary, meaning that it can take one of two values (e.g. [on, off])
- Ordinal, meaning ordered categories (e.g. [low, medium, high])
- Categorical, meaning non-ordered categories (e.g. [mango, banana, papaya])
search_domain: tuple
A tuple of the lower and upper limit of the DOF for the agent to search.
trust_domain: tuple, optional
The agent will reject all data where the DOF value is outside the trust domain. Must be larger than search domain.
units: str
The units of the DOF (e.g. mm or deg). This is just for plotting and general sanity checking.
read_only: bool
If True, the agent will not try to set the DOF. Must be set to True if the supplied ophyd
device is read-only.
Expand All @@ -68,12 +74,6 @@ class DOF:
A list of tags. These make it easier to subset large groups of dofs.
device: Signal, optional
An ophyd device. If not supplied, a dummy ophyd device will be generated.
type: str
What kind of DOF it is. A DOF can be:
- Continuous, meaning that it can vary to any point between two domain.
- Binary, meaning that it can take one of two values (e.g. [on, off])
- Ordinal, meaning ordered categories (e.g. [low, medium, high])
- Categorical, meaning non-ordered categories (e.g. )
"""

name: str = None
Expand Down

0 comments on commit 9153e46

Please sign in to comment.