navigate Logo

Getting Started

  • Quick Start Guide
  • Software Installation
  • I Want To…

User Guide

  • Supported Hardware
  • Supported File Formats
  • User Interface Walkthrough
  • Setting Up A Microscope
  • Acquiring Data
  • Case Studies

Development

  • Contributing Guidelines
  • Developer Install
  • Software Architecture
  • Feature Container
  • REST-API
  • Plugin Architecture

Troubleshooting & Known Issues

  • Troubleshooting
  • Known Issues

Plugins

  • navigate Plugin Template
  • navigate Confocal Projection
  • navigate at Scale
  • navigate Constant Velocity Acquisition
  • navigate MMCore
  • navigate ilastik Server
  • navigate Photoactivation

Reference

  • Implemented Microscopes
  • Software API
navigate
  • navigate.controller.sub_controllers.camera_settings.CameraSettingController
  • View page source

navigate.controller.sub_controllers.camera_settings.CameraSettingController

class navigate.controller.sub_controllers.camera_settings.CameraSettingController(view, parent_controller=None, microscope_name=None)

Bases: GUIController

Controller for the camera settings.

__init__(view, parent_controller=None, microscope_name=None)

Initialize the camera setting controller.

Parameters:
  • view (tkinter.Frame) – The view for the camera settings.

  • parent_controller (navigate.controller.main_controller.MainController) – The parent controller.

Methods

__init__(view[, parent_controller, ...])

Initialize the camera setting controller.

calculate_physical_dimensions()

Calculate size of the FOV in microns.

execute(command, *args)

This function is called when a command is passed from a child process.

initialize()

Sets widgets based on data given from main controller/config.

populate_experiment_values()

Sets values in View according to the experiment yaml file.

register_event_listener(event_name, ...)

Register event listener in the parent_controller

set_experiment_values()

Sets values of widgets based on experiment setting

set_mode(mode)

Set widget configuration based upon imaging mode.

set_roi_widgets_state()

Set the status of ROI widgets

show_verbose_info(*info)

Prints verbose information to the console

update_camera_device_related_setting()

Update caramera device related parameters.

update_camera_parameters_silent(value)

Update GUI camera parameters

update_experiment_values(*args)

Updates experiment yaml file according to the values in View.

update_exposure_time(exposure_time)

When camera exposure time is changed, recalculate readout time

update_fov(*args)

Recalculate fov and update the widgets: FOV_X and FOV_Y

update_number_of_pixels(*args)

Update the number of pixels in the ROI.

update_readout_time()

Update camera readout time.

update_roi(btn_name)

Update ROI width and height.

update_sensor_mode(*args)

Updates the camera sensor mode.

Attributes

custom_events

Custom events for this controller

microscope_name

Camera name

in_initialization

True if in initialization

resolution_value

Resolution value

mode

Mode value

solvent

Solvent type

mode_widgets

Mode widgets

framerate_widgets

Framerate widgets

roi_widgets

ROI widgets

roi_btns

ROI buttons

default_pixel_size

Default pixel size

default_width

Default width int: Default height

default_height

Default width int: Default height

step_width

Camera width step interval

step_height

Camera height step interval

min_width

Camera width minimum

min_height

Camera height minimum

pixel_event_id

True if pixel event id

calculate_physical_dimensions()

Calculate size of the FOV in microns.

Calculates the size of the field of view according to the magnification of the system, the physical size of the pixel, and the number of pixels. update FOV_X and FOV_Y

TODO: Should make sure that this is updated before we run the tiling wizard. Also can probably be done more elegantly in a configuration file and dictionary structure.

execute(command, *args)

This function is called when a command is passed from a child process.

Parameters:
  • command (str) – command name

  • args (tuple) – command arguments

initialize()

Sets widgets based on data given from main controller/config.

populate_experiment_values()

Sets values in View according to the experiment yaml file.

Experiment yaml filed passed by controller.

register_event_listener(event_name, event_handler)

Register event listener in the parent_controller

Parameters:
  • event_name (str) – event name

  • event_handler (function) – event handler

set_experiment_values()

Sets values of widgets based on experiment setting

setting_dict is a dictionary

set_mode(mode)

Set widget configuration based upon imaging mode.

This function will change state of widgets according to different mode ‘stop’ mode will let the editable widget be ‘normal’ in ‘live’ and ‘stack’ mode, some widgets are disabled

Parameters:

mode (str) – One of ‘live’, ‘z-stack’, ‘stop’, ‘single’

set_roi_widgets_state()

Set the status of ROI widgets

show_verbose_info(*info)

Prints verbose information to the console

Parameters:

info (tuple) – information to be printed

update_camera_device_related_setting()

Update caramera device related parameters.

This function will update default width and height according to microscope name.

update_camera_parameters_silent(value)

Update GUI camera parameters

Parameters:

value (tuple) – (sensor_mode, readout_direction, number_of_pixels)

update_experiment_values(*args)

Updates experiment yaml file according to the values in View.

Update the dictionary so that it can be combined with all the other sub-controllers, and then sent to the model.

Parameters:

*args – Variable length argument list.

update_exposure_time(exposure_time)

When camera exposure time is changed, recalculate readout time

Parameters:

exposure_time (float) – exposure time in seconds

update_fov(*args)

Recalculate fov and update the widgets: FOV_X and FOV_Y

Parameters:

*args (Variable length argument list.) –

update_number_of_pixels(*args)

Update the number of pixels in the ROI.

In live mode, we should let the device know the number of pixels changed.

Parameters:

*args (tuple) – Unused

update_readout_time()

Update camera readout time.

TODO: Highly specific to Hamamatsu Orca Flash 4.0. Should find a way to pass this from the camera to here. This should be moved to the camera device/API, ideally by calling a command from the camera.

update_roi(btn_name)

Update ROI width and height.

Parameters:

btn_name (roi button name) – width of roi in pixels: “All”, 1600, 1024, 512

update_sensor_mode(*args)

Updates the camera sensor mode.

Updates text in readout widget based on what sensor mode is selected If we are in the Light Sheet mode, then we want the camera self.model[‘CameraParameters’][‘sensor_mode’]) == 12

If we are in thef normal mode, then we want the camera self.model[‘CameraParameters’][‘sensor_mode’]) == 1

Should initialize from the configuration file to the default version

Parameters:

*args (Variable length argument list.) – usually args[0] is tkinter.Event or a str

property custom_events

Custom events for this controller

Type:

dict

default_height

Default width int: Default height

Type:

int

default_pixel_size

Default pixel size

Type:

int

default_width

Default width int: Default height

Type:

int

framerate_widgets

Framerate widgets

Type:

dict

in_initialization

True if in initialization

Type:

bool

microscope_name

Camera name

Type:

str

min_height

Camera height minimum

Type:

int

min_width

Camera width minimum

Type:

int

mode

Mode value

Type:

str

mode_widgets

Mode widgets

Type:

dict

parent_controller

parent controller

Type:

Controller

pixel_event_id

True if pixel event id

Type:

bool

resolution_value

Resolution value

Type:

str

roi_btns

ROI buttons

Type:

dict

roi_widgets

ROI widgets

Type:

dict

solvent

Solvent type

Type:

str

step_height

Camera height step interval

Type:

int

step_width

Camera width step interval

Type:

int

view

GUI view

Type:

tkinter.Tk


© Copyright 2025, Dean Lab, UT Southwestern Medical Center.