Class BoundingBoxAlongAxisBase

Object
AnchorBean<Feature<FeatureInputSingleObject>>
InitializableBean<Feature<FeatureInputSingleObject>, FeatureInitialization>
Feature<FeatureInputSingleObject>
FeatureSingleObject
BoundingBoxAlongAxisBase
Direct Known Subclasses:
BoundingBoxExtentAlongAxis, BoundingBoxMaximumAlongAxis, BoundingBoxMinimumAlongAxis

public abstract class BoundingBoxAlongAxisBase extends FeatureSingleObject
Base class for features that calculate a value along a specific axis of an object's bounding box.
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    double
    calculate(FeatureCalculationInput<FeatureInputSingleObject> input)
     
     
    protected abstract ReadableTuple3i
    extractTupleForBoundingBox(BoundingBox box)
    Extracts a ReadableTuple3i from the given BoundingBox.
    The axis along which to calculate the feature value ("x", "y", or "z").
    void
    The axis along which to calculate the feature value ("x", "y", or "z").

    Methods inherited from class org.anchoranalysis.image.feature.bean.object.single.FeatureSingleObject

    inputType

    Methods inherited from class org.anchoranalysis.feature.bean.Feature

    assignTo, beforeCalc, calculateCheckInitialized, castAs, createListChildFeatures, describeBean, descriptionLong, duplicateChangeName, getCustomName, getFriendlyName, onInitialization, setCustomName, toString

    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, describeChildren, duplicateBean, fields, findFieldsOfClass, getBeanName, getLocalPath, localise

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • BoundingBoxAlongAxisBase

      public BoundingBoxAlongAxisBase()
  • Method Details

    • calculate

      public double calculate(FeatureCalculationInput<FeatureInputSingleObject> input) throws FeatureCalculationException
      Specified by:
      calculate in class Feature<FeatureInputSingleObject>
      Throws:
      FeatureCalculationException
    • extractTupleForBoundingBox

      protected abstract ReadableTuple3i extractTupleForBoundingBox(BoundingBox box)
      Extracts a ReadableTuple3i from the given BoundingBox.
      Parameters:
      box - the BoundingBox to extract from
      Returns:
      the extracted ReadableTuple3i
    • describeParameters

      public String describeParameters()
      Overrides:
      describeParameters in class Feature<FeatureInputSingleObject>
    • getAxis

      public String getAxis()
      The axis along which to calculate the feature value ("x", "y", or "z").
    • setAxis

      public void setAxis(String axis)
      The axis along which to calculate the feature value ("x", "y", or "z").