DeepD3 inference

gui

class deepd3.inference.gui.Cleaning
close(self) bool
class deepd3.inference.gui.DoubleSlider(decimals=2, *args, **kargs)
setMaximum(self, a0: int)
setMinimum(self, a0: int)
setSingleStep(self, a0: int)
setValue(self, a0: int)
singleStep(self) int
value(self) int
class deepd3.inference.gui.ImageView(*args, **kwargs)
mouseDoubleClickEvent(self, a0: QMouseEvent)
mousePressEvent(self, a0: QMouseEvent)
class deepd3.inference.gui.Interface(fn, pred_fn, rois_fn, logs_fn, dimensions={'xy': 0.094, 'z': 0.5})
_changeOverlay(z)

Hook for z-slider

Parameters

z (int) – current z index

changeOverlay(z, preview=False)

When the z-slider is changed, update the overlay image (i.e. the prediction)

Parameters

z (int) – current z-location in stack

getSelection()

Sets the current row selection in table and updates ROIs, because the selected ROI has a different color.

keyPressEvent(self, a0: QKeyEvent)
populateTable()

Populates ROI table

roiSelection(xy)

Highlight selected ROI due to left click

Parameters

xy (QPoint) – Clicking location

saveSettingsROI3D(settings)

Save test settings to global settings

Parameters

settings (dict) – 3D ROI settings

testROIbuilding(xy)

Test ROI building using dedicated interface. Interface is opened at particular stack location where user double-clicked

Parameters

xy (QPoint) – XY Location of pointer during click

updateProgress(pval, pmax)

updates progress bar

Parameters
  • pval (int) – current value

  • pmax (int) – target value

class deepd3.inference.gui.Main
cleaning()

Clean the prediction using user-specified settings

exportImageJ()

Export ROIs to ImageJ

exportPredictions()

Export neural network prediction as TIFF stacks

exportRoiCentroids()

Export ROI centroids as CSV file

exportRoiMap()

Export ROI map as TIFF stack

exportToFolderStructure()

Export ROIs as folder structure

importAnnotations()

Import annotations to visualize those on the central widget

open()

Open a z-stack for inference.

If a prediction and/or ROIs already exist, do load these as well.

previewCleaning(settings)

Preview cleaning settings to specify the settings

Parameters

settings (dict) – cleaning settings

roi2d()

Create ROIs from segmentation

roi3d()

Create ROIs from segmentation in 3D

save()

Save segmentation predictions and ROIs

segment()

Segment stack using user-defined settings

setDimensions()

Set dimensions for z-stack to ensure proper functionality (e.g. distance measures)

setShowLabels()

Toggles the visualization of labels on central widget

setShowMaxProjection()

Shows maximum projection of stack and prediction in central widget

setShowROIs()

Toggle ROIs on central widget

setShowSegmentation()

Toggle the segmentation visualization on central widget

zprojection()

Show a maximum and summed intensity z-projection for the full stack in separate windows

class deepd3.inference.gui.QHLine
class deepd3.inference.gui.ROI2D
close(self) bool
class deepd3.inference.gui.ROI3D(settings=None)
close(self) bool
class deepd3.inference.gui.Segment(model_fn=None)
close(self) bool
findModel()

Find TensorFlow/Keras model on file system

class deepd3.inference.gui.askDimensions(xy=0.094, z=0.5)
dimensions()

Returns dictionary containing xy and z dimensions in µm

Returns

returns xy and z dimensions

Return type

dict

class deepd3.inference.gui.testROI(stack, d, s, settings=None)
do()

Actually generating ROIs