Class MultiResolutionBilateralFilter
- java.lang.Object
-
- java.lang.Thread
-
- gov.nih.mipav.model.algorithms.AlgorithmBase
-
- gov.nih.mipav.model.algorithms.filters.MultiResolutionBilateralFilter
-
- All Implemented Interfaces:
java.awt.event.ActionListener
,java.awt.event.WindowListener
,java.lang.Runnable
,java.util.EventListener
public class MultiResolutionBilateralFilter extends AlgorithmBase
This is a port of multi_bilateral.py by Yiqian Wang. References: 1.) Feature preserving image denoising with multiresolution filters by Yiqian Wang and You-Yi Jau. 2.) D. L. Donoho and I. M. Johnstone. "Ideal spatial adaptation by wavelet shrinkage." Biometrika 81.3 (1994): 425-455. :DOI:10.1093/biomet/81.3.425
-
-
Field Summary
Fields Modifier and Type Field Description private int
BORDER_REFLECT_101
private int
d
private double
epsilon
private boolean
estimateNoiseStandardDeviation
private int
filterType
private double
noiseStandardDeviation
private double
sigmaColor
private double
sigmaSpace
private int
wavelet_levels
private PyWavelets.WAVELET_NAME
wavelet_name
private int
wavelet_order
-
Fields inherited from class gov.nih.mipav.model.algorithms.AlgorithmBase
destFlag, destImage, image25D, mask, maxProgressValue, minProgressValue, multiThreadingEnabled, nthreads, progress, progressModulus, progressStep, runningInSeparateThread, separable, srcImage, threadStopped
-
-
Constructor Summary
Constructors Constructor Description MultiResolutionBilateralFilter(ModelImage destImg, ModelImage srcImg, PyWavelets.WAVELET_NAME wavelet_name, int wavelet_order, int wavelet_levels, boolean estimateNoiseStandardDeviation, double noiseStandardDeviation, int filterType, int d, double sigmaColor, double sigmaSpace)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description private double
_bayes_thresh(double[][] details, double var)
private double
_sigma_est_dwt(double[][] detail_coeffs, java.lang.String distribution)
void
denoiseBW()
void
denoiseColor()
double[][]
hard(double[][] data, double value, double substitute)
void
runAlgorithm()
Actually runs the algorithm.double[][]
soft(double[][] data, double value, double substitute)
-
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
-
BORDER_REFLECT_101
private final int BORDER_REFLECT_101
- See Also:
- Constant Field Values
-
wavelet_name
private PyWavelets.WAVELET_NAME wavelet_name
-
wavelet_order
private int wavelet_order
-
wavelet_levels
private int wavelet_levels
-
estimateNoiseStandardDeviation
private boolean estimateNoiseStandardDeviation
-
noiseStandardDeviation
private double noiseStandardDeviation
-
filterType
private int filterType
-
d
private int d
-
sigmaColor
private double sigmaColor
-
sigmaSpace
private double sigmaSpace
-
epsilon
private double epsilon
-
-
Constructor Detail
-
MultiResolutionBilateralFilter
public MultiResolutionBilateralFilter(ModelImage destImg, ModelImage srcImg, PyWavelets.WAVELET_NAME wavelet_name, int wavelet_order, int wavelet_levels, boolean estimateNoiseStandardDeviation, double noiseStandardDeviation, int filterType, int d, double sigmaColor, double sigmaSpace)
-
-
Method Detail
-
runAlgorithm
public void runAlgorithm()
Description copied from class:AlgorithmBase
Actually runs the algorithm. Implemented by inheriting algorithms.- Specified by:
runAlgorithm
in classAlgorithmBase
-
denoiseBW
public void denoiseBW()
-
hard
public double[][] hard(double[][] data, double value, double substitute)
-
soft
public double[][] soft(double[][] data, double value, double substitute)
-
_bayes_thresh
private double _bayes_thresh(double[][] details, double var)
-
_sigma_est_dwt
private double _sigma_est_dwt(double[][] detail_coeffs, java.lang.String distribution)
-
denoiseColor
public void denoiseColor()
-
-