You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The document logger is a callback that the BlueSky RunEngine subscribes to unconditionally. After receiving each document, if they share the same start document (in the same run) then it will write them to the same file. These logs are stored under `C:/instrument/var/logs/bluesky/raw_documents` and are handled by the log rotation.
3
+
The [`document_logger`](ibex_bluesky_core.callbacks.document_logger) is a callback that the BlueSky RunEngine subscribes to unconditionally. After receiving each document, if they share the same start document (in the same run) then it will write them to the same file. These logs are stored under `C:/instrument/var/logs/bluesky/raw_documents` and are handled by the log rotation.
4
4
5
5
Each document is stored in a JSON format so can be both machine and human readable. It is in the format `{"type": name, "document": document}` whereby `name` is the type of the document, e.g start, stop, event, descriptor and the `document` is the [document from BlueSky in JSON format](https://blueskyproject.io/bluesky/main/documents.html). As these files are produced per BlueSky run, these will be useful for debugging.
Copy file name to clipboardExpand all lines: doc/callbacks/file_writing.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,7 +1,7 @@
1
1
# File writing callbacks
2
2
## Human readable files
3
3
4
-
A callback (`HumanReadableFileCallback`) exists to write all documents to a separate human-readable file which contains the specified fields.
4
+
A callback ([`HumanReadableFileCallback`](ibex_bluesky_core.callbacks.file_logger.HumanReadableFileCallback)) exists to write all documents to a separate human-readable file which contains the specified fields.
5
5
6
6
This callback will add units and honour precision for each field as well as add some metadata ie. the `uid` of each scan as well as the RB number, which is injected using the {doc}`/preprocessors/rbnumberpp`
Copy file name to clipboardExpand all lines: doc/callbacks/plotting.md
+6-6Lines changed: 6 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,26 +1,26 @@
1
1
# Plotting
2
2
3
3
Bluesky has good integration with `matplotlib` for data visualization, and data from scans
4
-
may be easily plotted using the `LivePlot` callback.
4
+
may be easily plotted using the [`LivePlot`](ibex_bluesky_core.callbacks.plotting.LivePlot) callback.
5
5
6
6
`ibex_bluesky_core` provides a thin wrapper over bluesky's default `LivePlot` callback,
7
7
which ensures that plots are promptly displayed in IBEX.
8
8
9
-
In order to use the wrapper, import `LivePlot` from `ibex_bluesky_core` rather than
9
+
In order to use the wrapper, import [`LivePlot`](ibex_bluesky_core.callbacks.plotting.LivePlot) from [`ibex_bluesky_core`](ibex_bluesky_core) rather than
10
10
`bluesky` directly:
11
11
```
12
12
from ibex_bluesky_core.callbacks.plotting import LivePlot
13
13
```
14
14
15
15
## Configuration
16
16
17
-
A range of configuration options for `LivePlot` are available - see the
17
+
A range of configuration options for [`LivePlot`](ibex_bluesky_core.callbacks.plotting.LivePlot) are available - see the
The `LivePlot` object allows an arbitrary set of matplotlib `Axes` to be passed in, onto
21
+
The [`LivePlot`](ibex_bluesky_core.callbacks.plotting.LivePlot) object allows an arbitrary set of matplotlib `Axes` to be passed in, onto
22
22
which it will plot. This can be used to configure properties which are not directly exposed
23
-
on the `LivePlot` object, for example log-scaled axes.
23
+
on the [`LivePlot`](ibex_bluesky_core.callbacks.plotting.LivePlot) object, for example log-scaled axes.
24
24
25
25
See the [matplotlib `Axes` documentation](https://matplotlib.org/stable/api/_as_gen/matplotlib.axes.Axes.html)
26
26
for a full range of options on how to configure an `Axes` object.
@@ -50,7 +50,7 @@ See [docs for `call_qt_aware`](../plan_stubs/matplotlib_helpers.md) for a descri
50
50
`yield from call_qt_aware` rather than calling `matplotlib` functions directly.
51
51
```
52
52
53
-
By providing a signal name to the `yerr` argument you can pass uncertainties to LivePlot, by not providing anything for this argument means that no errorbars will be drawn. Errorbars are drawn after each point collected, displaying their standard deviation- uncertainty data is collected from Bluesky event documents and errorbars are updated after every new point added.
53
+
By providing a signal name to the `yerr` argument you can pass uncertainties to [`LivePlot`](ibex_bluesky_core.callbacks.plotting.LivePlot), by not providing anything for this argument means that no errorbars will be drawn. Errorbars are drawn after each point collected, displaying their standard deviation- uncertainty data is collected from Bluesky event documents and errorbars are updated after every new point added.
54
54
55
55
The `plot_callback` object can then be subscribed to the run engine, using either:
56
56
- An explicit callback when calling the run engine: `RE(some_plan(), plot_callback)`
Copy file name to clipboardExpand all lines: doc/dev/logging.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,5 +1,5 @@
1
1
# Logging
2
-
To invoke the `ibex_bluesky_core` logger, create and use a `logger` object in [the standard way](https://docs.python.org/3/library/logging.html):
2
+
To invoke the [`ibex_bluesky_core`](ibex_bluesky_core) logger, create and use a `logger` object in [the standard way](https://docs.python.org/3/library/logging.html):
A motor block does not need an explicit write config: it always waits for the requested motion
135
-
to complete. See {py:obj}`ibex_bluesky_core.devices.block.BlockMot` for a detailed mapping of
135
+
to complete. See [`BlockMot`](ibex_bluesky_core.devices.block.BlockMot) for a detailed mapping of
136
136
the usual write-configuration options and how these are instead achieved by a motor block.
137
137
138
138
## Configuring block write behaviour
139
139
140
-
`BlockRw`and `BlockRwRbv` both take a `write_config` argument, which can be used to configure
140
+
[`BlockRw`](ibex_bluesky_core.devices.block.BlockRw)and [`BlockRwRbv`](ibex_bluesky_core.devices.block.BlockRwRbv) both take a `write_config` argument, which can be used to configure
141
141
the behaviour on writing to a block, for example tolerances and settle times.
142
142
143
-
See {py:class}`ibex_bluesky_core.devices.block.BlockWriteConfig` for a detailed
143
+
See [`BlockWriteConfig`](ibex_bluesky_core.devices.block.BlockWriteConfig) for a detailed
144
144
description of all the options which are available.
145
145
146
-
## Run control
146
+
## Run Control
147
147
148
-
Run control information is available via the `block.run_control` sub-device.
148
+
[`RunControl`](ibex_bluesky_core.devices.block.RunControl)information is available via the [`block.RunControl`](ibex_bluesky_core.devices.block.RunControl) sub-device.
149
149
150
150
Both configuring and reading the current status of run control are permitted.
0 commit comments