motile_plugin.widgets.motile.run_viewer

Classes

RunViewer

A widget for viewing in progress or completed runs, including

Module Contents

class motile_plugin.widgets.motile.run_viewer.RunViewer

Bases: qtpy.QtWidgets.QGroupBox

A widget for viewing in progress or completed runs, including the progress of the solver and the parameters. Can also save the whole run or export the tracks to CSV. Output tracks and segmentation are visualized separately in napari layers.

edit_run
run: motile_plugin.backend.motile_run.MotileRun | None = None
params_widget
solver_label: qtpy.QtWidgets.QLabel
gap_plot: pyqtgraph.PlotWidget
save_run_dialog
export_tracks_dialog
main_layout
update_run(run: motile_plugin.backend.motile_run.MotileRun)

Update the run being viewed. Changes the title, solver status and gap plot, and parameters being displayed.

Args:

run (MotileRun): The new run to display

_save_and_export_widget() qtpy.QtWidgets.QWidget

Create a widget for saving and exporting tracking results.

Returns:
QWidget: A widget containing a save button and an export tracks

button.

_back_to_edit_widget() qtpy.QtWidgets.QWidget

Create a widget for navigating back to the run editor with different parameters.

Returns:
QWidget: A widget with two buttons: one for navigating back to the

previous run editor state, and one for populating the run editor with the currently viewed run’s parameters.

_emit_run()

Emit the edit_run signal with the current run. Used to populate the run editor with the current run’s parameters.

_progress_widget() qtpy.QtWidgets.QWidget

Create a widget containing solver progress and status.

Returns:
QWidget: A widget with a label indicating solver status and

a collapsible graph of the solver gap.

_plot_widget() pyqtgraph.PlotWidget
Returns:

pg.PlotWidget: a widget containg an (empty) plot of the solver gap

_save_dialog() qtpy.QtWidgets.QFileDialog
_export_tracks_dialog() qtpy.QtWidgets.QFileDialog
save_run()
export_tracks()

Export the tracks from this run to a csv with the following columns: t,[z],y,x,id,parent_id,[seg_id] Cells without a parent_id will have an empty string for the parent_id. Whether or not to include z is inferred from the length of an arbitrary node’s position attribute. If the nodes have a “seg_id” attribute, the “seg_id” column is included.

_set_solver_label(status: str)
solver_event_update()
reset_progress()