Class AlgorithmEllipticFourierDescriptors

java.lang.Object
java.lang.Thread
gov.nih.mipav.model.algorithms.AlgorithmBase
gov.nih.mipav.model.algorithms.AlgorithmEllipticFourierDescriptors
All Implemented Interfaces:
ActionListener, WindowListener, Runnable, EventListener

public class AlgorithmEllipticFourierDescriptors extends AlgorithmBase
Smoothing VOI with Elliptic Fourier Descriptors. The number of coefficients can range from 1 to the number of points in the curve divided by 2. References: 1.) Feature Extraction invalid input: '&' Image Processing for Computer Vision, Third Edition, Mark S. Nixon and Alberto S. Aguado, 2012, pp. 369-378. 2.) Boundary Finding with Parametrically Deformable Models by Lawrence H. Staib and James S. Duncan.
Author:
ilb
  • Field Details

    • activeVOI

      private VOI activeVOI
      The voi selected by the user.
    • coefficients

      private int coefficients
      Number of coefficients.
    • resultVOI

      private VOI resultVOI
      The resultant polygon and the evolution has completed.
    • srcImage

      private ModelImage srcImage
      Source image.
  • Constructor Details

    • AlgorithmEllipticFourierDescriptors

      public AlgorithmEllipticFourierDescriptors()
    • AlgorithmEllipticFourierDescriptors

      public AlgorithmEllipticFourierDescriptors(ModelImage srcImg, VOI activeVOI, int coefficients)
      Creates a new AlgorithmEllipticFourierDescriptors object.
      Parameters:
      srcImg - 2D or 3D source image
      activeVOI - the selected voi
      coefficients - number of coefficients
  • Method Details

    • finalize

      public void finalize()
      Prepares this class for destruction.
      Overrides:
      finalize in class AlgorithmBase
    • getResultVOI

      public VOI getResultVOI()
      Accessor that returns a voi that is a smoothed version of the original.
      Returns:
      resultVOI
    • runAlgorithm

      public void runAlgorithm()
      Starts the smooth algorithm.
      Specified by:
      runAlgorithm in class AlgorithmBase
    • calc

      private void calc()
      Prepares the data and runs the algorithm for a 2D or 3D image.
    • runEllipticFourierDescriptors

      private void runEllipticFourierDescriptors(float[] xPoints, float[] yPoints, float[] xSmooth, float[] ySmooth)
    • runEllipticFourierDescriptorsOpenCurve

      private void runEllipticFourierDescriptorsOpenCurve(float[] xPoints, float[] yPoints, float[] xSmooth, float[] ySmooth)