Class BinarySegmentationReference
Object
Uses an existing
BinarySegmentation
that is located by a unique identifier.
The identifier locates an entity from the shared-objects passed during initialization in the
ImageInitialization
.
- Author:
- Owen Feehan
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetId()
The identifier of the existingBinarySegmentation
to use.void
onInitialization
(ImageInitialization initialization) Called after initialization.segment
(VoxelsUntyped voxels, BinarySegmentationParameters parameters, Optional<ObjectMask> objectMask) Performs a segmentation on voxels so that each voxel has an on or off state after the operation.void
The identifier of the existingBinarySegmentation
to use.Methods inherited from class org.anchoranalysis.bean.initializable.InitializableBean
getInitialization, getLogger, getPropertyInitializer, initialize, initializeRecursive, initRecursiveWithInitializer, isInitialized
Methods inherited from class org.anchoranalysis.bean.AnchorBean
checkMisconfigured, describeBean, describeChildren, duplicateBean, fields, findFieldsOfClass, getBeanName, getLocalPath, localise, toString
-
Constructor Details
-
BinarySegmentationReference
public BinarySegmentationReference()
-
-
Method Details
-
onInitialization
Description copied from class:InitializableBean
Called after initialization. An empty implementation is provided, to be overridden as needed in the sub-classes.- Overrides:
onInitialization
in classInitializableBean<BinarySegmentation,
ImageInitialization> - Parameters:
initialization
- parameters used for initialization.- Throws:
InitializeException
- if initialization does not successfully complete.
-
segment
public BinaryVoxels<UnsignedByteBuffer> segment(VoxelsUntyped voxels, BinarySegmentationParameters parameters, Optional<ObjectMask> objectMask) throws SegmentationFailedException Description copied from class:BinarySegmentation
Performs a segmentation on voxels so that each voxel has an on or off state after the operation.- Specified by:
segment
in classBinarySegmentation
- Parameters:
voxels
- voxels to segment.parameters
- parameters to guide the algorithm.objectMask
- if present, segmentation only occurs inside this object.- Returns:
- voxels for a mask on the input-buffer, which may be newly-created, or may reuse the
input
voxels
, depending on implementation. - Throws:
SegmentationFailedException
- if the segmentation cannot be successfully completed.
-
getId
The identifier of the existingBinarySegmentation
to use. -
setId
The identifier of the existingBinarySegmentation
to use.
-