Package gov.nih.mipav.model.algorithms
Class AlgorithmIndependentComponents
java.lang.Object
java.lang.Thread
gov.nih.mipav.model.algorithms.AlgorithmBase
gov.nih.mipav.model.algorithms.AlgorithmIndependentComponents
- All Implemented Interfaces:
ActionListener,WindowListener,Runnable,EventListener
This algorithm operates on 2D and 3D black and white and color images.
Requirements:
1.) The independent components must be statistically independent.
2.) The independent components must have all nongaussian distributions or one gaussian distribution
and all the other distributions nongaussian or the independent components have time dependencies.
3.) For simplicity, assume the unknown mixture matrix is square. In other words, the number of
mixtures equals the number of independent components. If the number of independent components is
smaller than the number of mixtures, use principal component analysis to reduce the number of
mixtures to the number of principal components. Reducing the number of dimensions can reduce noise and
prevent overlearning.
Filtering the data in the Fourier domain is allowed before performing independent component analysis since
applying the Fourier transform to the data does not change the mixing matrix.
References:
1.) Independent Component Analysis by Aapo Hyvarinen, Juha Karhunen, and Erkki Oja, John-Wiley invalid input: '&' Sons, Inc.,
2001.
2.) Independent Component Analysis A Tutorial Introduction by James V. Stone, Massachusetts Institute of
Technology, 2004.
3.) Independent Component Analysis Principles and Practice Edited by Stephen Roberts and Richard Everson,
Cambridge University Press, 2001.
From the text: "Another very useful thing to do is to reduce the dimension of the data by principal component
analysis. This reduces noise and prevents overlearning. It may also solve the problems with data that has a
smaller number of independent components than mixtures."
Software was tested with images obtained from the site at http://www.lx.it.pt/~lbalmeida/ica/seethrough/index.html,
"See-through" data sets for nonlinear source separation by Luis B. Almeida. In the paper "Separating a Real-Life
Nonlinear Image Mixture" by Luis B. Almeida, the following average linear and nonlinear separation SNR results are
given in decibels for sets 4 thru 8:
Set number linear source 1 linear source 2 nonlinear source1 nonlinear source2
4 9.0 8.7 13.8 13.1
5 5.2 10.5 9.3 13.9
6 13.4 6.6 14.2 6.4
7 4.5 11.2 6.2 11.2
8 5.8 3.4 6.0 3.7
My results:
set 4:
symmetric orthogonalization tanh a1 = 1.0 source1 3.96 dB source2 8.56 dB
set 5:
symmetric orthogonalization tanh a1 = 1.0 source1 5.93 dB source2 4.05 dB
symmetric orthogonalization exp source1 9.76 dB source2 9.86 dB
symmetric orthogonalization cubic source1 5.84 dB source2 3.99 dB
maximum likelihood estimation exp source1 5.64 dB source2 3.89 dB
source1 5.36 dB source2 3.89 dB
set 6:
symmetric orthogonalization tanh a1 = 1.0 source1 15.5 dB source2 11.8 dB
maximum likelihood estimation tanh a1 = 1.0 source1 15.5 dB source2 11.8 dB
set 7:
symmetric orthogonalization tanh a1 = 1.0 source1 9.93 dB source2 14.8 dB
maximum likelihood estimation tanh a1 = 1.0 source1 10.1 dB source2 14.8 dB
set 8:
symmetric orthogonalization tanh a1 = 1.0 source1 11.5 dB source2 6.91 dB
source1 11.3 dB source2 10.9 dB
maximum likelihood estimation tanh a1 = 1.0 source1 11.4 dB source2 6.79 dB
source1 11.4 dB source2 6.79 dB
source1 11.4 dB source2 6.79 dB
maximum likelihood estimation exp source1 11.4 dB source2 6.79 dB
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Thread
Thread.Builder, Thread.State, Thread.UncaughtExceptionHandler -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate doubleprivate booleanstatic final intstatic final intprivate ModelImage[]DOCUMENT ME!private doublestatic final intprivate booleanprivate booleanDOCUMENT ME!private intprivate intnumber of independent components to be retained.static final intprivate intprivate intprivate intnumber of image planes present.private booleanprivate booleanprivate ModelImageDOCUMENT ME!private ModelImage[]static final intstatic final intFields inherited from class gov.nih.mipav.model.algorithms.AlgorithmBase
destFlag, image25D, mask, maxProgressValue, minProgressValue, multiThreadingEnabled, nthreads, progress, progressModulus, progressStep, runningInSeparateThread, separable, threadStoppedFields inherited from class java.lang.Thread
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY -
Constructor Summary
ConstructorsConstructorDescriptionAlgorithmIndependentComponents(ModelImage[] destImg, ModelImage[] srcImgArray, int icNumber, int icAlgorithm, int nonlinearFunction, double a1, double endTolerance, int maxIterations, boolean redRequested, boolean greenRequested, boolean blueRequested) Creates a new AlgorithmIndependentComponents object.AlgorithmIndependentComponents(ModelImage[] destImg, ModelImage srcImg, int icNumber, int icAlgorithm, int nonlinearFunction, double a1, double endTolerance, int maxIterations, boolean redRequested, boolean greenRequested, boolean blueReuqested) Creates a new AlgorithmIndependentComponents object. -
Method Summary
Modifier and TypeMethodDescriptionvoidfinalize()Prepares this class for destruction.private voidDOCUMENT ME!voidStart algorithm.voidupdateFileInfo(ModelImage image, ModelImage resultImage) Copy important file information to resultant image structure.Methods inherited from class gov.nih.mipav.model.algorithms.AlgorithmBase
actionPerformed, addListener, addProgressChangeListener, calculateImageSize, calculatePrincipleAxis, computeElapsedTime, computeElapsedTime, convertIntoFloat, delinkProgressToAlgorithm, delinkProgressToAlgorithmMulti, displayError, errorCleanUp, 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, windowOpenedMethods 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, isVirtual, join, join, join, join, ofPlatform, ofVirtual, onSpinWait, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, sleep, start, startVirtualThread, stop, suspend, threadId, toString, yield
-
Field Details
-
destImage
DOCUMENT ME! -
haveColor
private boolean haveColorDOCUMENT ME! -
nPlanes
private int nPlanesnumber of image planes present. -
icNumber
private int icNumbernumber of independent components to be retained. For SYMMETRIC_ORTHOGONALIZATION and MAXIMUM_LIKELIHOOD_ESTIMATION icNumber = nPlanes = colorsRequested * number of source images for color = number of source images for black and white icNumber can only be varied from 1 to nPlanes with DEFLATIONARY_ORTHOGONALIZATION -
srcImageArray
-
srcImage
DOCUMENT ME! -
nonlinearFunction
private int nonlinearFunction -
a1
private double a1 -
endTolerance
private double endTolerance -
icAlgorithm
private int icAlgorithm -
SYMMETRIC_ORTHOGONALIZATION
public static final int SYMMETRIC_ORTHOGONALIZATION- See Also:
-
DEFLATIONARY_ORTHOGONALIZATION
public static final int DEFLATIONARY_ORTHOGONALIZATION- See Also:
-
MAXIMUM_LIKELIHOOD_ESTIMATION
public static final int MAXIMUM_LIKELIHOOD_ESTIMATION- See Also:
-
TANH_FUNCTION
public static final int TANH_FUNCTION- See Also:
-
EXP_FUNCTION
public static final int EXP_FUNCTION- See Also:
-
CUBIC_FUNCTION
public static final int CUBIC_FUNCTION- See Also:
-
maxIterations
private int maxIterations -
redRequested
private boolean redRequested -
greenRequested
private boolean greenRequested -
blueRequested
private boolean blueRequested -
selfTest
private boolean selfTest
-
-
Constructor Details
-
AlgorithmIndependentComponents
public AlgorithmIndependentComponents(ModelImage[] destImg, ModelImage srcImg, int icNumber, int icAlgorithm, int nonlinearFunction, double a1, double endTolerance, int maxIterations, boolean redRequested, boolean greenRequested, boolean blueReuqested) Creates a new AlgorithmIndependentComponents object.- Parameters:
destImg- image model where result image is to storedsrcImg- source image modelicNumber- icNumber is the number of independent component images to retainicAlgorithm-nonlinearFunction-a1-endTolerance-maxIterations-
-
AlgorithmIndependentComponents
public AlgorithmIndependentComponents(ModelImage[] destImg, ModelImage[] srcImgArray, int icNumber, int icAlgorithm, int nonlinearFunction, double a1, double endTolerance, int maxIterations, boolean redRequested, boolean greenRequested, boolean blueRequested) Creates a new AlgorithmIndependentComponents object.- Parameters:
destImg- image model where result image is to storedicNumber- icNumber is the number of independent component images to retainicAlgorithm-nonlinearFunction-a1-endTolerance-maxIterations-redRequested-greenRequested-blueRequested-srcImg- source image model
-
-
Method Details
-
finalize
public void finalize()Prepares this class for destruction.- Overrides:
finalizein classAlgorithmBase
-
runAlgorithm
public void runAlgorithm()Start algorithm.- Specified by:
runAlgorithmin classAlgorithmBase
-
updateFileInfo
Copy important file information to resultant image structure.- Parameters:
image- Source image.resultImage- Resultant image.
-
iComponent
private void iComponent()DOCUMENT ME!
-