Directors¶
Directors can be employed to run concert.experiments.base.Experiment
multiple times.
The function concert.directors.base._prepare_run()
is used to prepare an experiment run.
E.g. this function can be used to exchange specimens or modify experiment properties.
The base.Experiment.ready_to_prepare_next_sample
can be used to trigger the concert.directors.base._prepare_run()
already while the experiment is still running.
- class concert.directors.base.Director(self, experiment)¶
Class to handle multiple experiment executions.
- await __ainit__(experiment)¶
- Parameters
experiment (concert.experiments.base.Experiment) – Experiment that is run. If the experiment features a ‘ready_to_prepare_next_sample’ event (asyncio.Event) this will be waited within the experiment execution. When set() the next iteration will be prepared while the experiment is still running. This could be used to prepare a future iteration while still data is stored or processed. The separate_scans property of the experiment should be set to False, since the director handles the naming of the sub-folders.
- await pause()¶
Waits (after the current iteration is done and the next is prepared) with the next iteration until resume() is called.
- await resume()¶
Resumes a currently paused director run.
XY Scanning¶
- class concert.directors.scanning.XYScan(self, experiment, x_motor, y_motor, x_min, x_max, x_step, y_min, y_max, y_step)¶
Director to scan a specimen within a plane.
- await __ainit__(experiment, x_motor, y_motor, x_min, x_max, x_step, y_min, y_max, y_step)¶
- Parameters
experiment (concert.experiments.base.Experiment) – Experiment that is run. If the experiment features a ‘ready_to_prepare_next_sample’ event (asyncio.Event) this will be waited within the experiment execution. When set() the next iteration will be prepared while the experiment is still running. This could be used to prepare a future iteration while still data is stored or processed. The separate_scans property of the experiment should be set to False, since the director handles the naming of the sub-folders.
x_motor (concert.devices.motors.base.LinearMotor) – Linear motor for scanning in x direction
y_motor (concert.devices.motors.base.LinearMotor) – Linear motor for scanning in y direction
x_min (q.mm) – Starting position of x
x_max (q.mm) – Stop position of x
x_step (q.mm) – Step width of x scanning
y_min (q.mm) – Starting position of y
y_max (q.mm) – Stop position of y
y_step (q.mm) – Step width of y scanning