bec_widgets.widgets.plots.image.image_item#
Classes#
Connection mixin class to handle BEC client and device manager |
|
Configuration for BECConnector mixin class |
Module Contents#
- class ImageItem(config: ImageItemConfig | None = None, gui_id: str | None = None, parent_image=None, **kwargs)#
Bases:
bec_widgets.utils.BECConnector,pyqtgraph.ImageItemConnection mixin class to handle BEC client and device manager
BECConnector mixin class to handle BEC client and device manager.
- Parameters:
client (BECClient, optional) – The BEC client.
config (ConnectionConfig, optional) – The connection configuration with specific gui id.
gui_id (str, optional) – The GUI ID.
object_name (str, optional) – The object name.
root_widget (bool, optional) – If set to True, the parent_id will be always set to None, thus enforcing that the widget is accessible as a root widget of the BECGuiClient object.
rpc_exposed (bool, optional) – If set to False, this instance is excluded from RPC registry broadcast and CLI namespace discovery.
rpc_passthrough_children (bool, optional) – Only relevant when
rpc_exposed=False. If True, RPC-visible children rebind to the next visible ancestor. If False (default), children stay hidden behind this widget.**kwargs
- _process_image()#
Reprocess the current raw data and update the image display.
- apply_autorange()#
- auto_update_vrange(stats: bec_widgets.widgets.plots.image.image_processor.ImageStats) None#
Update the v_range based on the stats of the image.
- clear()#
Clears the assigned image.
- get_data() numpy.ndarray#
Get the data of the image. :returns: The data of the image. :rtype: np.ndarray
- parent()#
- remove(emit: bool = True)#
Cleanup the BECConnector
- set_data(data: numpy.ndarray, transform: qtpy.QtGui.QTransform | None = None)#
- set_parent(parent: bec_widgets.utils.BECConnector)#
- set_v_range(vrange: tuple[float, float], disable_autorange=True)#
- RPC = True#
- USER_ACCESS = ['color_map', 'color_map.setter', 'v_range', 'v_range.setter', 'v_min', 'v_min.setter', 'v_max',...#
- property autorange: bool#
- property autorange_mode: str#
- buffer = []#
- property color_map: str#
Get the current color map.
- property fft: bool#
Get or set whether FFT postprocessing is enabled.
- image_transform = None#
- property log: bool#
Get or set whether logarithmic scaling is applied.
- max_len = 0#
- property num_rotation_90: int | None#
Get or set the number of 90° rotations to apply.
- raw_data = None#
- removed#
- property transpose: bool#
Get or set whether the image is transposed.
- vRangeChangedManually#
- property v_max: float#
- property v_min: float#
- property v_range: tuple[float, float]#
Get the color intensity range of the image.
- class ImageItemConfig(/, **data: Any)#
Bases:
bec_widgets.utils.ConnectionConfigConfiguration for BECConnector mixin class
Create a new model by parsing and validating input data from keyword arguments.
Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.
self is explicitly positional-only to allow self as a field name.
- autorange: bool | None = None#
- autorange_mode: Literal['max', 'mean'] = None#
- color_map: str | None = None#
- downsample: bool | None = None#
- model_config: dict#
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- opacity: float | None = None#
- parent_id: str | None = None#
- processing: bec_widgets.widgets.plots.image.image_processor.ProcessingConfig = None#
- v_range: tuple[float | int, float | int] | None = None#