|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectde.unihalle.informatik.Alida.operator.ALDOperator
de.unihalle.informatik.MiToBo.core.operator.MTBOperator
de.unihalle.informatik.MiToBo.transforms.UndecimatedWaveletTransform
@ALDAOperator(genericExecutionMode=NONE) public class UndecimatedWaveletTransform
Undecimated wavelet transform (UWT) operator.
Nested Class Summary | |
---|---|
protected static class |
UndecimatedWaveletTransform.TransformationMode
|
Nested classes/interfaces inherited from class de.unihalle.informatik.Alida.operator.ALDOperator |
---|
de.unihalle.informatik.Alida.operator.ALDOperator.HidingMode |
Field Summary | |
---|---|
private java.lang.Boolean |
denoise
|
private MTBImage |
img
|
private java.lang.Integer |
Jmax
|
private MTBImage[] |
kernels
|
private double[] |
m_sigmaScales
noise sigma scale factors for different wavelet scales |
private java.util.Vector<loci.common.StatusListener> |
m_statusListeners
vector of installed StatusListeners |
private UndecimatedWaveletTransform.TransformationMode |
transform
|
private MTBImageSet |
uwtImages
|
Fields inherited from class de.unihalle.informatik.Alida.operator.ALDOperator |
---|
completeDAG, name, portHashAccess, verbose, versionProvider |
Constructor Summary | |
---|---|
UndecimatedWaveletTransform()
Constructor with default Gaussian kernel [1/16, 1/4, 3/8, 1/4, 1/16] for dimension x, y and z. |
|
UndecimatedWaveletTransform(MTBImage img,
int Jmax,
boolean denoise)
Constructor with default Gaussian kernel [1/16, 1/4, 3/8, 1/4, 1/16] for at most dimension x, y (and z if present). |
|
UndecimatedWaveletTransform(MTBImage img,
int Jmax,
boolean denoise,
MTBImage[] kernels)
Constructor. |
Method Summary | |
---|---|
void |
addStatusListener(loci.common.StatusListener statuslistener)
|
protected MTBImage[] |
aTrousDWT(MTBImage img,
int Jmax,
MTBImage[] kernels)
A trous DWT |
protected double[] |
computeSigmaScales()
Compute scaling factors of noise sigma for wavelet scales (these scaling factors are estimated using a gaussian noise image with sigma=1 to measure noise in the wavelet scales) |
protected MTBImage |
conv(MTBImage img,
MTBImage[] scaleOneKernels,
int j)
Convolve input image with an 'a trous' kernel (zeros inserted) given the original kernel and scale j |
protected MTBImage |
createGaussianNoiseImage(double mean,
double sigma,
double clippingFactor,
int bins,
int sizeX,
int sizeY,
int sizeZ,
int sizeT,
int sizeC)
Create an image with Gaussian noise |
protected void |
denoise(MTBImage img,
double sigma)
Denoise wavelet coefficients using Jeffrey's noninformative prior for a given sigma of noise |
protected void |
denoiseDWTJeffreys(MTBImage[] dwt,
double scaleOneSigma,
double[] sigmaScales)
Denoise wavelet coefficients using Jeffrey's noninformative prior [..] |
protected double |
get3SigClippedStdDev(MTBImage img)
Get the standard deviation (sigma) of an image only using values clipped by 3*sigma from a first estimate of sigma |
boolean |
getDenoise()
Get the denoising flag. true if denoising is activated. |
MTBImage |
getImg()
Get reference to the (input) image. |
int |
getJmax()
Get Jmax (maximum scale 2^Jmax - 1) |
protected MTBImage[] |
getKernels()
Get smoothing kernels |
protected double |
getSample(double[] cdf)
Returns a sample in the range [0, 1] from a cumulative distribution given by the array cdf |
protected double |
getStdDev(MTBImage img)
Get standard deviation of the image |
MTBImageSet |
getUWT()
Get the UWT coefficient images. |
protected MTBImage |
inverseATrousDWT(MTBImage[] dwt)
Inverse a trous DWT |
boolean |
isForwardTransform()
Test if parameter object is set to (forward) transform (image to wavelet) |
boolean |
isInverseTransform()
Test if parameter object is set to Inverse Transform (wavelet to image) |
void |
notifyListeners(loci.common.StatusEvent e)
|
protected void |
operate()
|
void |
removeStatusListener(loci.common.StatusListener statuslistener)
|
protected void |
setDenoise(boolean denoise)
Set the denoising flag. true to activate denoising. |
void |
setForwardTransform()
Toggle computation of the (forward) transform (image to wavelet) |
void |
setImg(MTBImage img)
Set the image domain image |
void |
setInverseTransform()
Set computation of the inverse transform (wavelet to image) |
protected void |
setJmax(int Jmax)
Set Jmax (maximum scale 2^Jmax - 1) |
protected void |
setKernels(MTBImage[] kernels)
Set smoothing kernels |
void |
setUWT(MTBImageSet uwtImages)
Set UWT coefficient images |
Methods inherited from class de.unihalle.informatik.MiToBo.core.operator.MTBOperator |
---|
readResolve |
Methods inherited from class de.unihalle.informatik.Alida.operator.ALDOperator |
---|
deserializeFromXmlFile, fieldContained, getALDPortHashAccessKey, getConstructionMode, getInInoutNames, getInInoutNames, getInNames, getInOutNames, getMissingRequiredInputs, getName, getNumParameters, getOutInoutNames, getOutNames, getParameter, getParameterDescriptor, getParameterNames, getSupplementalNames, getVerbose, getVersion, isConfigured, parametersToXmlObject, print, print, print, printInterface, printInterface, readHistory, reinitializeParameterDescriptors, runOp, runOp, runOp, serializeToXmlFile, setConstructionMode, setName, setParameter, setParametersFromXml, setParametersFromXml, setVerbose, toStringVerbose, unconfiguredItems, validate, validateCustom, validateGeneric, writeHistory, writeHistory, writeHistory, writeParametersToXml |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
@Parameter(label="Denoise", required=true, direction=IN, mode=ADVANCED, dataIOOrder=3, description="Specifies whether the wavelet coefficients will be denoised using Jeffrey\'s noninformative prior") private java.lang.Boolean denoise
@Parameter(label=" image", required=true, direction=IN, mode=STANDARD, dataIOOrder=1, description="Input image") private MTBImage img
@Parameter(label="Jmax", required=true, direction=IN, mode=STANDARD, dataIOOrder=2, description="Maximum scale index (decimal > 0)") private java.lang.Integer Jmax
@Parameter(label="Kernels", required=true, direction=IN, mode=ADVANCED, dataIOOrder=1, description="A set of lowpass kernels interpreted as parts of a separable kernel") private MTBImage[] kernels
private final double[] m_sigmaScales
private java.util.Vector<loci.common.StatusListener> m_statusListeners
@Parameter(label="Type of transform", required=true, direction=IN, mode=STANDARD, dataIOOrder=4, description="Specifies if forward or backward transform is computed") private UndecimatedWaveletTransform.TransformationMode transform
@Parameter(label="UWT coefficient images", required=true, direction=OUT, mode=STANDARD, dataIOOrder=1, description="Images with UWT coefficients of the different scales") private MTBImageSet uwtImages
Constructor Detail |
---|
public UndecimatedWaveletTransform() throws de.unihalle.informatik.Alida.exceptions.ALDOperatorException
de.unihalle.informatik.Alida.exceptions.ALDOperatorException
public UndecimatedWaveletTransform(MTBImage img, int Jmax, boolean denoise) throws de.unihalle.informatik.Alida.exceptions.ALDOperatorException
img
- input imageJmax
- maximum scale (2^Jmax - 1)denoise
- reduction of gaussian noise
de.unihalle.informatik.Alida.exceptions.ALDOperatorException
public UndecimatedWaveletTransform(MTBImage img, int Jmax, boolean denoise, MTBImage[] kernels) throws de.unihalle.informatik.Alida.exceptions.ALDOperatorException
img
- input imageJmax
- maximum scale (2^Jmax - 1)denoise
- reduction of gaussian noisekernels
- an array of kernels, which are inflated for each scale and used to convolve the image consecutively, because a separable filter is expected to be specified by this array
de.unihalle.informatik.Alida.exceptions.ALDOperatorException
Method Detail |
---|
public void addStatusListener(loci.common.StatusListener statuslistener)
addStatusListener
in interface loci.common.StatusReporter
protected MTBImage[] aTrousDWT(MTBImage img, int Jmax, MTBImage[] kernels) throws de.unihalle.informatik.Alida.exceptions.ALDOperatorException, de.unihalle.informatik.Alida.exceptions.ALDProcessingDAGException
de.unihalle.informatik.Alida.exceptions.ALDOperatorException
de.unihalle.informatik.Alida.exceptions.ALDProcessingDAGException
protected double[] computeSigmaScales() throws de.unihalle.informatik.Alida.exceptions.ALDOperatorException, de.unihalle.informatik.Alida.exceptions.ALDProcessingDAGException
p
- DWT configuration (only Jmax is important here)
de.unihalle.informatik.Alida.exceptions.ALDOperatorException
de.unihalle.informatik.Alida.exceptions.ALDProcessingDAGException
protected MTBImage conv(MTBImage img, MTBImage[] scaleOneKernels, int j) throws de.unihalle.informatik.Alida.exceptions.ALDOperatorException, de.unihalle.informatik.Alida.exceptions.ALDProcessingDAGException
img
- input imagescaleOneKernels
- original kernel (without inserted zeros)j
- scale parameter
de.unihalle.informatik.Alida.exceptions.ALDProcessingDAGException
de.unihalle.informatik.Alida.exceptions.ALDOperatorException
protected MTBImage createGaussianNoiseImage(double mean, double sigma, double clippingFactor, int bins, int sizeX, int sizeY, int sizeZ, int sizeT, int sizeC)
mean
- sigma
- clippingFactor
- bins
- sizeX
- sizeY
- sizeZ
- sizeT
- sizeC
-
protected void denoise(MTBImage img, double sigma)
img
- input imagesigma
- sigma of noiseprotected void denoiseDWTJeffreys(MTBImage[] dwt, double scaleOneSigma, double[] sigmaScales)
dwt
- scaleOneSigma
- sigmaScales
- protected double get3SigClippedStdDev(MTBImage img)
img
- input image
public boolean getDenoise()
public MTBImage getImg()
public int getJmax()
protected MTBImage[] getKernels()
protected double getSample(double[] cdf)
cdf
- cumulative distribution array
protected double getStdDev(MTBImage img)
img
- input image
public MTBImageSet getUWT()
protected MTBImage inverseATrousDWT(MTBImage[] dwt) throws de.unihalle.informatik.Alida.exceptions.ALDOperatorException
dwt
- DWT-coefficient images
de.unihalle.informatik.Alida.exceptions.ALDOperatorException
public boolean isForwardTransform()
de.unihalle.informatik.Alida.exceptions.ALDOperatorException
public boolean isInverseTransform() throws de.unihalle.informatik.Alida.exceptions.ALDOperatorException
de.unihalle.informatik.Alida.exceptions.ALDOperatorException
public void notifyListeners(loci.common.StatusEvent e)
notifyListeners
in interface loci.common.StatusReporter
protected void operate() throws de.unihalle.informatik.Alida.exceptions.ALDOperatorException, de.unihalle.informatik.Alida.exceptions.ALDProcessingDAGException
operate
in class de.unihalle.informatik.Alida.operator.ALDOperator
de.unihalle.informatik.Alida.exceptions.ALDOperatorException
de.unihalle.informatik.Alida.exceptions.ALDProcessingDAGException
public void removeStatusListener(loci.common.StatusListener statuslistener)
removeStatusListener
in interface loci.common.StatusReporter
protected void setDenoise(boolean denoise)
public void setForwardTransform()
public void setImg(MTBImage img)
public void setInverseTransform() throws de.unihalle.informatik.Alida.exceptions.ALDOperatorException
de.unihalle.informatik.Alida.exceptions.ALDOperatorException
protected void setJmax(int Jmax)
Jmax
- protected void setKernels(MTBImage[] kernels)
public void setUWT(MTBImageSet uwtImages)
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |