Package gov.nih.mipav.model.algorithms
Class AlgorithmHessian
- java.lang.Object
-
- java.lang.Thread
-
- gov.nih.mipav.model.algorithms.AlgorithmBase
-
- gov.nih.mipav.model.algorithms.AlgorithmHessian
-
- All Implemented Interfaces:
java.awt.event.ActionListener
,java.awt.event.WindowListener
,java.lang.Runnable
,java.util.EventListener
public class AlgorithmHessian extends AlgorithmBase
Provides functions to convolve an image with the second derivitive of the Gaussian function to obtain the Hessian matrix for a particular point on the image.- Author:
- Evan McCreedy
-
-
Field Summary
Fields Modifier and Type Field Description private float[]
GxxData
Storage location of the second derivative of the Gaussian in the XX direction.private float[]
GxyData
Storage location of the second derivative of the Gaussian in the XY direction.private float[]
GxzData
Storage location of the second derivative of the Gaussian in the XZ direction.private float[]
GyyData
Storage location of the second derivative of the Gaussian in the YY direction.private float[]
GyzData
Storage location of the second derivative of the Gaussian in the YZ direction.private float[]
GzzData
Storage location of the second derivative of the Gaussian in the ZZ direction.private int[]
kExtents
Dimensionality of the kernel.private float[]
sigmas
Standard deviations of the gaussian used to calculate the kernels.private ModelImage
srcImage
Image to convolve with hessian.-
Fields inherited from class gov.nih.mipav.model.algorithms.AlgorithmBase
destFlag, destImage, image25D, mask, maxProgressValue, minProgressValue, multiThreadingEnabled, nthreads, progress, progressModulus, progressStep, runningInSeparateThread, separable, threadStopped
-
-
Constructor Summary
Constructors Constructor Description AlgorithmHessian(ModelImage img, float[] sigmas)
Creates a new AlgorithmHessian object.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description double[][]
hessian2D(float[] imgBuf, int[] extents, float x, float y)
Convolves the source image at the point (x,y,z) with the hessian of the gaussian function.double[][]
hessian2D(float x, float y)
Convolves the source image at the point (x,y) with the hessian of the gaussian function.double[][]
hessian3D(float[] imgBuf, int[] extents, float x, float y, float z)
Convolves the source image at the point (x,y,z) with the hessian of the gaussian function.double[][]
hessian3D(float x, float y, float z)
Convolves the source image at the point (x,y,z) with the hessian of the gaussian function.private void
makeKernels2D()
Makes 2D derivative kernels to be used in the calculation of the hessian.private void
makeKernels3D()
Makes 3D derivative kernels to be used in the calculation of the hessian.void
runAlgorithm()
Should not be used for this algorithm -- just a placeholder.-
Methods inherited from class gov.nih.mipav.model.algorithms.AlgorithmBase
actionPerformed, addListener, addProgressChangeListener, calculateImageSize, calculatePrincipleAxis, computeElapsedTime, computeElapsedTime, convertIntoFloat, delinkProgressToAlgorithm, delinkProgressToAlgorithmMulti, displayError, errorCleanUp, finalize, fireProgressStateChanged, fireProgressStateChanged, fireProgressStateChanged, fireProgressStateChanged, fireProgressStateChanged, generateProgressValues, getDestImage, getElapsedTime, getMask, getMaxProgressValue, getMinProgressValue, getNumberOfThreads, getProgress, getProgressChangeListener, getProgressChangeListeners, getProgressModulus, getProgressStep, getProgressValues, getSrcImage, isCompleted, isImage25D, isMultiThreadingEnabled, isRunningInSeparateThread, isThreadStopped, linkProgressToAlgorithm, linkProgressToAlgorithm, makeProgress, notifyListeners, removeListener, removeProgressChangeListener, run, setCompleted, setImage25D, setMask, setMaxProgressValue, setMinProgressValue, setMultiThreadingEnabled, setNumberOfThreads, setProgress, setProgressModulus, setProgressStep, setProgressValues, setProgressValues, setRunningInSeparateThread, setSrcImage, setStartTime, setThreadStopped, startMethod, windowActivated, windowClosed, windowClosing, windowDeactivated, windowDeiconified, windowIconified, windowOpened
-
Methods inherited from class java.lang.Thread
activeCount, checkAccess, clone, countStackFrames, currentThread, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, onSpinWait, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, suspend, toString, yield
-
-
-
-
Field Detail
-
GxxData
private float[] GxxData
Storage location of the second derivative of the Gaussian in the XX direction.
-
GxyData
private float[] GxyData
Storage location of the second derivative of the Gaussian in the XY direction.
-
GxzData
private float[] GxzData
Storage location of the second derivative of the Gaussian in the XZ direction.
-
GyyData
private float[] GyyData
Storage location of the second derivative of the Gaussian in the YY direction.
-
GyzData
private float[] GyzData
Storage location of the second derivative of the Gaussian in the YZ direction.
-
GzzData
private float[] GzzData
Storage location of the second derivative of the Gaussian in the ZZ direction.
-
kExtents
private int[] kExtents
Dimensionality of the kernel.
-
sigmas
private float[] sigmas
Standard deviations of the gaussian used to calculate the kernels.
-
srcImage
private ModelImage srcImage
Image to convolve with hessian.
-
-
Constructor Detail
-
AlgorithmHessian
public AlgorithmHessian(ModelImage img, float[] sigmas)
Creates a new AlgorithmHessian object.- Parameters:
img
- DOCUMENT ME!sigmas
- DOCUMENT ME!
-
-
Method Detail
-
hessian2D
public double[][] hessian2D(float x, float y)
Convolves the source image at the point (x,y) with the hessian of the gaussian function.- Parameters:
x
- float point index indicating point of interesty
- float point index indicating point of interest- Returns:
- hessian matrix for the point (x,y)
-
hessian2D
public double[][] hessian2D(float[] imgBuf, int[] extents, float x, float y)
Convolves the source image at the point (x,y,z) with the hessian of the gaussian function.- Parameters:
imgBuf
- the imageextents
- the extents of the imagex
- float point index indicating point of interesty
- float point index indicating point of interest- Returns:
- hessian matrix for the point (x,y,z)
-
hessian3D
public double[][] hessian3D(float x, float y, float z)
Convolves the source image at the point (x,y,z) with the hessian of the gaussian function.- Parameters:
x
- float point index indicating point of interesty
- float point index indicating point of interestz
- float point index indicating point of interest- Returns:
- hessian matrix for the point (x,y,z)
-
hessian3D
public double[][] hessian3D(float[] imgBuf, int[] extents, float x, float y, float z)
Convolves the source image at the point (x,y,z) with the hessian of the gaussian function.- Parameters:
imgBuf
- DOCUMENT ME!extents
- DOCUMENT ME!x
- float point index indicating point of interesty
- float point index indicating point of interestz
- float point index indicating point of interest- Returns:
- hessian matrix for the point (x,y,z)
-
runAlgorithm
public void runAlgorithm()
Should not be used for this algorithm -- just a placeholder.- Specified by:
runAlgorithm
in classAlgorithmBase
-
makeKernels2D
private void makeKernels2D()
Makes 2D derivative kernels to be used in the calculation of the hessian.
-
makeKernels3D
private void makeKernels3D()
Makes 3D derivative kernels to be used in the calculation of the hessian.
-
-