darsia.RectangleSelectionAssistant#
- class RectangleSelectionAssistant(img, **kwargs)[source]#
Bases:
BaseAssistantAssistant for selecting a rectangle in an image.
Similar to the point selection assistant, but for rectangles.
Initialize the assistant.
- Parameters:
- img
darsia.Image Image to select a rectangle in.
- **kwargs
Additional arguments.
background (darsia.Image): Background image to display.
name (str): Name of assistant / short version of instructions.
coordinates (bool): Flag controlling whether to return coordinates or voxels.
labels (darsia.Image): Labels for the image.
- img
Methods
Attributes
Name of assistant / short version of instructions.
Rectangle selector.
Selected box in terms of slices.
Selected corners in voxel format with matrix indexing.
Flag controlling whether to return coordinates or voxels.
Labels for the image.
imgImage to be analyzed.
backgroundBackground image for plotting.
figFigure for analysis.
axAxes for analysis.
blockFlag controlling whether figure is blocking.
plot_gridFlag controlling whether grid is plotted (in 2d).
thresholdThreshold for active voxels (in 3d).
relativeFlag controlling whether threshold is relative (in 3d).
scalingScaling of points (in 3d).
scatterFlag controlling whether scatter plot is used (in 3d).
use_coordinatesFlag controlling whether plots use physical coordinates.
verbosityFlag controlling verbosity.
cmapColormap for plotting.
- box#
Selected box in terms of slices.
- corners#
Selected corners in voxel format with matrix indexing.
- labels#
Labels for the image.
- name#
Name of assistant / short version of instructions.
- return_coordinates#
Flag controlling whether to return coordinates or voxels.
- rs#
Rectangle selector.