navigate.model.features.common_features.Snap
- class navigate.model.features.common_features.Snap(model, saving_flag=False)
Bases:
FeatureBaseSnap class for capturing data frames using a microscope.
This class provides functionality to capture data frames using a microscope and log information about the camera and frame IDs.
Notes
This class is used to capture data frames using a microscope and log relevant information, such as the active camera and frame IDs.
The Snap class is typically used for capturing individual frames during microscopy experiments.
The data capture process involves capturing frames and logging camera-related information.
The config_table attribute is used to define the configuration for the data capture process, specifically the main data capture function.
- __init__(model, saving_flag=False)
Initialize the Snap class.
- Parameters:
model (MicroscopeModel) – The microscope model object used for data capture.
Methods
__init__(model[, saving_flag])Initialize the Snap class.
data_func(frame_ids)Capture data frames and log camera information.
Mark saving flags in the signal function
Attributes
- data_func(frame_ids: list) → bool
Capture data frames and log camera information.
This method captures data frames using the microscope and logs information about the active camera and the provided frame IDs.
- Parameters:
frame_ids (list) – A list of frame IDs for which data frames should be captured.
- Returns:
A boolean value indicating the success of the data capture process.
- Return type:
bool
- signal_func() → bool
Mark saving flags in the signal function
- config_table
A dictionary defining the configuration for the data capture process.
- Type:
dict
- model
The microscope model associated with the data capture.
- Type:
MicroscopeModel
- parameter_schema = {'saving_flag': SettingSpec(value_type=<class 'bool'>, default=False, label='Save Frames', help_text='Mark snapped frames to be written by the active image writer.', choices=None, choice_values=None, minimum=None, exclusive_minimum=None, maximum=None, step=None, required=False, dynamic_source=None, depends_on=None)}
- saving_flag
Saving each frames
- Type:
bool