class documentation

A generic workflow for any scan that captures images on a rectilinear grid.

Method check_before_start Before starting a scan, check that camera-stage-mapping is set.
Class Variable autofocus_dz The z distance to perform an autofocus in steps.
Class Variable overlap The fraction that adjacent images should overlap in x and y.
Property ready Whether this scanworkflow is ready to start.
Method _calc_displacement_from_overlap Use camera stage mapping to calculate x and y displacement from given overlap.
Method _get_stitching_settings_model Return a stitching settings model based on current settings.
Class Variable _csm Undocumented

Inherited from ScanWorkflow:

Method acquisition_routine Overload to set the acquisition routine that happens at each scan site.
Method all_settings Return the scan settings and the stitching settings.
Method new_scan_planner Return the a new scan planner object for a scan.
Method pre_scan_routine Overload to set the routine that happens before each scan.
Class Variable display_name Undocumented
Class Variable save_resolution A tuple of the image resolution to capture.
Class Variable ui_blurb Undocumented
Property settings_ui A list of PropertyControl objects to create the settings in the scan tab.
Method _autofocus_and_capture Autofocus and then capture, this can be used as an acquisition routine.
Class Variable _autofocus Undocumented
Class Variable _cam Undocumented
Class Variable _planner_cls Undocumented
Class Variable _settings_model Undocumented
Class Variable _stage Undocumented
def check_before_start(self, scan_name: str): (source)

Before starting a scan, check that camera-stage-mapping is set.

Raise error if:
  • camera stage mapping is not set
autofocus_dz: int = (source)

The z distance to perform an autofocus in steps.

Must be greater than or equal to 200, and less than or equal to 2000.

overlap: float = (source)

The fraction that adjacent images should overlap in x and y.

This must be between 0.1 and 0.7.

def _calc_displacement_from_overlap(self, overlap: float) -> tuple[int, int]: (source)

Use camera stage mapping to calculate x and y displacement from given overlap.

Parameters
overlap:floatThe desired overlap as a fraction of the image. i.e. 0.5 means that each image should overlap its nearest neighbour by 50%.
Returns
tuple[int, int](dx, dy) - the x and y displacements in steps
Raises
RuntimeErrorIf there is no camera stage mapper Thing available or if CMS isn't calibrated.
def _get_stitching_settings_model(self) -> StitchingSettings: (source)

Return a stitching settings model based on current settings.