Package org.itk.simple
Class LabelShapeStatisticsImageFilter
java.lang.Object
org.itk.simple.ProcessObject
org.itk.simple.ImageFilter
org.itk.simple.LabelShapeStatisticsImageFilter
Converts a label image to a label map and valuates the shape
attributes.
A convenient class that converts a label image to a label map and
valuates the shape attribute at once.
This implementation was taken from the Insight Journal paper: https://www.insight-journal.org/browse/publication/176
Gaetan Lehmann. Biologie du Developpement et de la Reproduction, INRA
de Jouy-en-Josas, France.
See:
ShapeLabelObject , LabelShapeOpeningImageFilter , LabelStatisticsOpeningImageFilter
itk::LabelImageToShapeLabelMapFilter for the Doxygen on the original ITK class.
C++ includes: sitkLabelShapeStatisticsImageFilter.h
-
Field Summary
Fields inherited from class org.itk.simple.ProcessObject
swigCMemOwn
-
Constructor Summary
ConstructorsModifierConstructorDescriptionitk::simple::LabelShapeStatisticsImageFilter::LabelShapeStatisticsImageFilter() Default Constructor that takes no arguments and initializes default parametersprotected
LabelShapeStatisticsImageFilter
(long cPtr, boolean cMemoryOwn) -
Method Summary
Modifier and TypeMethodDescriptionvoid
Self& itk::simple::LabelShapeStatisticsImageFilter::ComputeFeretDiameterOff()void
Self& itk::simple::LabelShapeStatisticsImageFilter::ComputeFeretDiameterOn() Set the value of ComputeFeretDiameter to true or false respectfully.void
Self& itk::simple::LabelShapeStatisticsImageFilter::ComputeOrientedBoundingBoxOff()void
Self& itk::simple::LabelShapeStatisticsImageFilter::ComputeOrientedBoundingBoxOn() Set the value of ComputeOrientedBoundingBox to true or false respectfully.void
Self& itk::simple::LabelShapeStatisticsImageFilter::ComputePerimeterOff()void
Self& itk::simple::LabelShapeStatisticsImageFilter::ComputePerimeterOn() Set the value of ComputePerimeter to true or false respectfully.void
delete()
virtual itk::simple::LabelShapeStatisticsImageFilter::~LabelShapeStatisticsImageFilter() Destructorvoid
void itk::simple::LabelShapeStatisticsImageFilter::Execute(const Image &image1) Execute the filter on the input imageprotected void
finalize()
double
double itk::simple::LabelShapeStatisticsImageFilter::GetBackgroundValue() const Set/Get the value used as "background" in the output image.getBoundingBox
(int label) std::vector<unsigned int> itk::simple::LabelShapeStatisticsImageFilter::GetBoundingBox(int64_t label) const This is an active measurement.getCentroid
(int label) std::vector<double> itk::simple::LabelShapeStatisticsImageFilter::GetCentroid(int64_t label) const This is an active measurement.boolean
bool itk::simple::LabelShapeStatisticsImageFilter::GetComputeFeretDiameter() const Set/Get whether the maximum Feret diameter should be computed or not.boolean
bool itk::simple::LabelShapeStatisticsImageFilter::GetComputeOrientedBoundingBox() const Set/Get whether the oriented bounding box should be computed or not.boolean
bool itk::simple::LabelShapeStatisticsImageFilter::GetComputePerimeter() const Set/Get whether the perimeter should be computed or not.protected static long
double
getElongation
(int label) double itk::simple::LabelShapeStatisticsImageFilter::GetElongation(int64_t label) const This is an active measurement.getEquivalentEllipsoidDiameter
(int label) std::vector<double> itk::simple::LabelShapeStatisticsImageFilter::GetEquivalentEllipsoidDiameter(int64_t label) const This is an active measurement.double
getEquivalentSphericalPerimeter
(int label) double itk::simple::LabelShapeStatisticsImageFilter::GetEquivalentSphericalPerimeter(int64_t label) const This is an active measurement.double
getEquivalentSphericalRadius
(int label) double itk::simple::LabelShapeStatisticsImageFilter::GetEquivalentSphericalRadius(int64_t label) const This is an active measurement.double
getFeretDiameter
(int label) double itk::simple::LabelShapeStatisticsImageFilter::GetFeretDiameter(int64_t label) const This is an active measurement.double
getFlatness
(int label) double itk::simple::LabelShapeStatisticsImageFilter::GetFlatness(int64_t label) const This is an active measurement.getIndexes
(int label) std::vector<unsigned int> itk::simple::LabelShapeStatisticsImageFilter::GetIndexes(int64_t label) const Get an array of indexes for pixels with the label value.std::vector<int64_t> itk::simple::LabelShapeStatisticsImageFilter::GetLabels() const This is a measurement.getName()
std::string itk::simple::LabelShapeStatisticsImageFilter::GetName() const Name of this classlong
uint64_t itk::simple::LabelShapeStatisticsImageFilter::GetNumberOfLabels() Return the number of labels after execution.long
getNumberOfPixels
(int label) uint64_t itk::simple::LabelShapeStatisticsImageFilter::GetNumberOfPixels(int64_t label) const This is an active measurement.long
getNumberOfPixelsOnBorder
(int label) uint64_t itk::simple::LabelShapeStatisticsImageFilter::GetNumberOfPixelsOnBorder(int64_t label) const This is an active measurement.getOrientedBoundingBoxDirection
(int label) std::vector<double> itk::simple::LabelShapeStatisticsImageFilter::GetOrientedBoundingBoxDirection(int64_t label) const This is an active measurement.getOrientedBoundingBoxOrigin
(int label) std::vector<double> itk::simple::LabelShapeStatisticsImageFilter::GetOrientedBoundingBoxOrigin(int64_t label) const This is an active measurement.getOrientedBoundingBoxSize
(int label) std::vector<double> itk::simple::LabelShapeStatisticsImageFilter::GetOrientedBoundingBoxSize(int64_t label) const This is an active measurement.getOrientedBoundingBoxVertices
(int label) std::vector<double> itk::simple::LabelShapeStatisticsImageFilter::GetOrientedBoundingBoxVertices(int64_t label) const This is an active measurement.double
getPerimeter
(int label) double itk::simple::LabelShapeStatisticsImageFilter::GetPerimeter(int64_t label) const This is an active measurement.double
getPerimeterOnBorder
(int label) double itk::simple::LabelShapeStatisticsImageFilter::GetPerimeterOnBorder(int64_t label) const This is an active measurement.double
getPerimeterOnBorderRatio
(int label) double itk::simple::LabelShapeStatisticsImageFilter::GetPerimeterOnBorderRatio(int64_t label) const This is an active measurement.double
getPhysicalSize
(int label) double itk::simple::LabelShapeStatisticsImageFilter::GetPhysicalSize(int64_t label) const This is an active measurement.getPrincipalAxes
(int label) std::vector<double> itk::simple::LabelShapeStatisticsImageFilter::GetPrincipalAxes(int64_t label) const This is an active measurement.getPrincipalMoments
(int label) std::vector<double> itk::simple::LabelShapeStatisticsImageFilter::GetPrincipalMoments(int64_t label) const This is an active measurement.getRegion
(int label) std::vector<unsigned int> itk::simple::LabelShapeStatisticsImageFilter::GetRegion(int64_t label) const This is an active measurement.getRLEIndexes
(int label) std::vector<unsigned int> itk::simple::LabelShapeStatisticsImageFilter::GetRLEIndexes(int64_t label) const Get an array of run-length encoding (RLE) indexes for pixels with the label value.double
getRoundness
(int label) double itk::simple::LabelShapeStatisticsImageFilter::GetRoundness(int64_t label) const This is an active measurement.boolean
hasLabel
(int label) bool itk::simple::LabelShapeStatisticsImageFilter::HasLabel(int64_t label) Does the specified label exist? Can only be called after a call a call to Update().void
setBackgroundValue
(double BackgroundValue) Self& itk::simple::LabelShapeStatisticsImageFilter::SetBackgroundValue(double BackgroundValue) Set/Get the value used as "background" in the output image.void
setComputeFeretDiameter
(boolean ComputeFeretDiameter) Self& itk::simple::LabelShapeStatisticsImageFilter::SetComputeFeretDiameter(bool ComputeFeretDiameter) Set/Get whether the maximum Feret diameter should be computed or not.void
setComputeOrientedBoundingBox
(boolean ComputeOrientedBoundingBox) Self& itk::simple::LabelShapeStatisticsImageFilter::SetComputeOrientedBoundingBox(bool ComputeOrientedBoundingBox) Set/Get whether the oriented bounding box should be computed or not.void
setComputePerimeter
(boolean ComputePerimeter) Self& itk::simple::LabelShapeStatisticsImageFilter::SetComputePerimeter(bool ComputePerimeter) Set/Get whether the perimeter should be computed or not.protected static long
toString()
std::string itk::simple::LabelShapeStatisticsImageFilter::ToString() const Print ourselves outMethods inherited from class org.itk.simple.ImageFilter
getCPtr, swigRelease
Methods inherited from class org.itk.simple.ProcessObject
abort, addCommand, debugOff, debugOn, getCPtr, getDebug, getGlobalDefaultCoordinateTolerance, getGlobalDefaultDebug, getGlobalDefaultDirectionTolerance, getGlobalDefaultNumberOfThreads, getGlobalDefaultThreader, getGlobalWarningDisplay, getNumberOfThreads, getNumberOfWorkUnits, getProgress, globalDefaultDebugOff, globalDefaultDebugOn, globalWarningDisplayOff, globalWarningDisplayOn, hasCommand, removeAllCommands, setDebug, setGlobalDefaultCoordinateTolerance, setGlobalDefaultDebug, setGlobalDefaultDirectionTolerance, setGlobalDefaultNumberOfThreads, setGlobalDefaultThreader, setGlobalWarningDisplay, setNumberOfThreads, setNumberOfWorkUnits, swigRelease
-
Constructor Details
-
LabelShapeStatisticsImageFilter
protected LabelShapeStatisticsImageFilter(long cPtr, boolean cMemoryOwn) -
LabelShapeStatisticsImageFilter
public LabelShapeStatisticsImageFilter()itk::simple::LabelShapeStatisticsImageFilter::LabelShapeStatisticsImageFilter() Default Constructor that takes no arguments and initializes default parameters
-
-
Method Details
-
getCPtr
-
swigRelease
-
finalize
protected void finalize()- Overrides:
finalize
in classImageFilter
-
delete
public void delete()virtual itk::simple::LabelShapeStatisticsImageFilter::~LabelShapeStatisticsImageFilter() Destructor- Overrides:
delete
in classImageFilter
-
setBackgroundValue
public void setBackgroundValue(double BackgroundValue) Self& itk::simple::LabelShapeStatisticsImageFilter::SetBackgroundValue(double BackgroundValue) Set/Get the value used as "background" in the output image. Defaults to NumericTraits<PixelType>::NonpositiveMin() . -
getBackgroundValue
public double getBackgroundValue()double itk::simple::LabelShapeStatisticsImageFilter::GetBackgroundValue() const Set/Get the value used as "background" in the output image. Defaults to NumericTraits<PixelType>::NonpositiveMin() . -
setComputeFeretDiameter
public void setComputeFeretDiameter(boolean ComputeFeretDiameter) Self& itk::simple::LabelShapeStatisticsImageFilter::SetComputeFeretDiameter(bool ComputeFeretDiameter) Set/Get whether the maximum Feret diameter should be computed or not. Default value is false, because of the high computation time required. -
computeFeretDiameterOn
public void computeFeretDiameterOn()Self& itk::simple::LabelShapeStatisticsImageFilter::ComputeFeretDiameterOn() Set the value of ComputeFeretDiameter to true or false respectfully. -
computeFeretDiameterOff
public void computeFeretDiameterOff()Self& itk::simple::LabelShapeStatisticsImageFilter::ComputeFeretDiameterOff() -
getComputeFeretDiameter
public boolean getComputeFeretDiameter()bool itk::simple::LabelShapeStatisticsImageFilter::GetComputeFeretDiameter() const Set/Get whether the maximum Feret diameter should be computed or not. Default value is false, because of the high computation time required. -
setComputePerimeter
public void setComputePerimeter(boolean ComputePerimeter) Self& itk::simple::LabelShapeStatisticsImageFilter::SetComputePerimeter(bool ComputePerimeter) Set/Get whether the perimeter should be computed or not. Default value is false, because of the high computation time required. -
computePerimeterOn
public void computePerimeterOn()Self& itk::simple::LabelShapeStatisticsImageFilter::ComputePerimeterOn() Set the value of ComputePerimeter to true or false respectfully. -
computePerimeterOff
public void computePerimeterOff()Self& itk::simple::LabelShapeStatisticsImageFilter::ComputePerimeterOff() -
getComputePerimeter
public boolean getComputePerimeter()bool itk::simple::LabelShapeStatisticsImageFilter::GetComputePerimeter() const Set/Get whether the perimeter should be computed or not. Default value is false, because of the high computation time required. -
setComputeOrientedBoundingBox
public void setComputeOrientedBoundingBox(boolean ComputeOrientedBoundingBox) Self& itk::simple::LabelShapeStatisticsImageFilter::SetComputeOrientedBoundingBox(bool ComputeOrientedBoundingBox) Set/Get whether the oriented bounding box should be computed or not. Default value is false because of potential memory consumption issues with sparse labels. -
computeOrientedBoundingBoxOn
public void computeOrientedBoundingBoxOn()Self& itk::simple::LabelShapeStatisticsImageFilter::ComputeOrientedBoundingBoxOn() Set the value of ComputeOrientedBoundingBox to true or false respectfully. -
computeOrientedBoundingBoxOff
public void computeOrientedBoundingBoxOff()Self& itk::simple::LabelShapeStatisticsImageFilter::ComputeOrientedBoundingBoxOff() -
getComputeOrientedBoundingBox
public boolean getComputeOrientedBoundingBox()bool itk::simple::LabelShapeStatisticsImageFilter::GetComputeOrientedBoundingBox() const Set/Get whether the oriented bounding box should be computed or not. Default value is false because of potential memory consumption issues with sparse labels. -
getBoundingBox
std::vector<unsigned int> itk::simple::LabelShapeStatisticsImageFilter::GetBoundingBox(int64_t label) const This is an active measurement. It may be accessed while the filter is being executing in command call-backs and can be accessed after execution. -
getRegion
std::vector<unsigned int> itk::simple::LabelShapeStatisticsImageFilter::GetRegion(int64_t label) const This is an active measurement. It may be accessed while the filter is being executing in command call-backs and can be accessed after execution. -
getCentroid
std::vector<double> itk::simple::LabelShapeStatisticsImageFilter::GetCentroid(int64_t label) const This is an active measurement. It may be accessed while the filter is being executing in command call-backs and can be accessed after execution. -
getElongation
public double getElongation(int label) double itk::simple::LabelShapeStatisticsImageFilter::GetElongation(int64_t label) const This is an active measurement. It may be accessed while the filter is being executing in command call-backs and can be accessed after execution. -
getEquivalentEllipsoidDiameter
std::vector<double> itk::simple::LabelShapeStatisticsImageFilter::GetEquivalentEllipsoidDiameter(int64_t label) const This is an active measurement. It may be accessed while the filter is being executing in command call-backs and can be accessed after execution. -
getEquivalentSphericalPerimeter
public double getEquivalentSphericalPerimeter(int label) double itk::simple::LabelShapeStatisticsImageFilter::GetEquivalentSphericalPerimeter(int64_t label) const This is an active measurement. It may be accessed while the filter is being executing in command call-backs and can be accessed after execution. -
getEquivalentSphericalRadius
public double getEquivalentSphericalRadius(int label) double itk::simple::LabelShapeStatisticsImageFilter::GetEquivalentSphericalRadius(int64_t label) const This is an active measurement. It may be accessed while the filter is being executing in command call-backs and can be accessed after execution. -
getFeretDiameter
public double getFeretDiameter(int label) double itk::simple::LabelShapeStatisticsImageFilter::GetFeretDiameter(int64_t label) const This is an active measurement. It may be accessed while the filter is being executing in command call-backs and can be accessed after execution. -
getFlatness
public double getFlatness(int label) double itk::simple::LabelShapeStatisticsImageFilter::GetFlatness(int64_t label) const This is an active measurement. It may be accessed while the filter is being executing in command call-backs and can be accessed after execution. -
getLabels
std::vector<int64_t> itk::simple::LabelShapeStatisticsImageFilter::GetLabels() const This is a measurement. Its value is updated in the Execute methods, so the value will only be valid after an execution. -
getNumberOfPixels
public long getNumberOfPixels(int label) uint64_t itk::simple::LabelShapeStatisticsImageFilter::GetNumberOfPixels(int64_t label) const This is an active measurement. It may be accessed while the filter is being executing in command call-backs and can be accessed after execution. -
getNumberOfPixelsOnBorder
public long getNumberOfPixelsOnBorder(int label) uint64_t itk::simple::LabelShapeStatisticsImageFilter::GetNumberOfPixelsOnBorder(int64_t label) const This is an active measurement. It may be accessed while the filter is being executing in command call-backs and can be accessed after execution. -
getPerimeter
public double getPerimeter(int label) double itk::simple::LabelShapeStatisticsImageFilter::GetPerimeter(int64_t label) const This is an active measurement. It may be accessed while the filter is being executing in command call-backs and can be accessed after execution. -
getPerimeterOnBorder
public double getPerimeterOnBorder(int label) double itk::simple::LabelShapeStatisticsImageFilter::GetPerimeterOnBorder(int64_t label) const This is an active measurement. It may be accessed while the filter is being executing in command call-backs and can be accessed after execution. -
getPerimeterOnBorderRatio
public double getPerimeterOnBorderRatio(int label) double itk::simple::LabelShapeStatisticsImageFilter::GetPerimeterOnBorderRatio(int64_t label) const This is an active measurement. It may be accessed while the filter is being executing in command call-backs and can be accessed after execution. -
getPhysicalSize
public double getPhysicalSize(int label) double itk::simple::LabelShapeStatisticsImageFilter::GetPhysicalSize(int64_t label) const This is an active measurement. It may be accessed while the filter is being executing in command call-backs and can be accessed after execution. -
getPrincipalAxes
std::vector<double> itk::simple::LabelShapeStatisticsImageFilter::GetPrincipalAxes(int64_t label) const This is an active measurement. It may be accessed while the filter is being executing in command call-backs and can be accessed after execution. -
getPrincipalMoments
std::vector<double> itk::simple::LabelShapeStatisticsImageFilter::GetPrincipalMoments(int64_t label) const This is an active measurement. It may be accessed while the filter is being executing in command call-backs and can be accessed after execution. -
getRoundness
public double getRoundness(int label) double itk::simple::LabelShapeStatisticsImageFilter::GetRoundness(int64_t label) const This is an active measurement. It may be accessed while the filter is being executing in command call-backs and can be accessed after execution. -
getOrientedBoundingBoxSize
std::vector<double> itk::simple::LabelShapeStatisticsImageFilter::GetOrientedBoundingBoxSize(int64_t label) const This is an active measurement. It may be accessed while the filter is being executing in command call-backs and can be accessed after execution. -
getOrientedBoundingBoxOrigin
std::vector<double> itk::simple::LabelShapeStatisticsImageFilter::GetOrientedBoundingBoxOrigin(int64_t label) const This is an active measurement. It may be accessed while the filter is being executing in command call-backs and can be accessed after execution. -
getOrientedBoundingBoxDirection
std::vector<double> itk::simple::LabelShapeStatisticsImageFilter::GetOrientedBoundingBoxDirection(int64_t label) const This is an active measurement. It may be accessed while the filter is being executing in command call-backs and can be accessed after execution. -
getOrientedBoundingBoxVertices
std::vector<double> itk::simple::LabelShapeStatisticsImageFilter::GetOrientedBoundingBoxVertices(int64_t label) const This is an active measurement. It may be accessed while the filter is being executing in command call-backs and can be accessed after execution. -
getIndexes
std::vector<unsigned int> itk::simple::LabelShapeStatisticsImageFilter::GetIndexes(int64_t label) const Get an array of indexes for pixels with the label value. This is an active measurement. It may be accessed while the filter is being executing in command call-backs and can be accessed after execution. -
getRLEIndexes
std::vector<unsigned int> itk::simple::LabelShapeStatisticsImageFilter::GetRLEIndexes(int64_t label) const Get an array of run-length encoding (RLE) indexes for pixels with the label value. The array is the index of a starting line, followed by the length repeated. The length of the array is divisible by the image's dimension + 1. For example for a 2D image the array [ 2, 3, 2] would encode the two indexes [2,3] and [3,3]. This is an active measurement. It may be accessed while the filter is being executing in command call-backs and can be accessed after execution. -
getName
std::string itk::simple::LabelShapeStatisticsImageFilter::GetName() const Name of this class- Overrides:
getName
in classProcessObject
-
toString
std::string itk::simple::LabelShapeStatisticsImageFilter::ToString() const Print ourselves out- Overrides:
toString
in classProcessObject
-
execute
void itk::simple::LabelShapeStatisticsImageFilter::Execute(const Image &image1) Execute the filter on the input image -
hasLabel
public boolean hasLabel(int label) bool itk::simple::LabelShapeStatisticsImageFilter::HasLabel(int64_t label) Does the specified label exist? Can only be called after a call a call to Update(). -
getNumberOfLabels
public long getNumberOfLabels()uint64_t itk::simple::LabelShapeStatisticsImageFilter::GetNumberOfLabels() Return the number of labels after execution.
-