T
- - Defines the Type
in which the actual computation is
performedpublic abstract class AbstractGauss<T extends NumericType<T>> extends Object
Constructor and Description |
---|
AbstractGauss(double[] sigma,
RandomAccessible<T> input,
Interval inputInterval,
RandomAccessible<T> output,
Localizable outputOffset,
ImgFactory<T> factory,
T type) |
Modifier and Type | Method and Description |
---|---|
void |
call() |
protected void |
computeKernel()
Compute the Gaussian Kernel for all dimensions
|
protected SamplingLineIterator<T> |
createInputLineSampler(int dim,
Interval range)
An
Iterator that samples a one dimensional line of input data for
the current dimension. |
protected WritableLineIterator<T> |
createOutputLineWriter(int dim,
Interval range,
SamplingLineIterator<T> inputLineSampler)
An
Iterator that samples a one dimensional line of output data
for the current dimension. |
ImgFactory<T> |
getFactory() |
RandomAccessible<T> |
getInput() |
Interval |
getInputInterval() |
double[][] |
getKernel() |
int |
getNumThreads() |
RandomAccessible<T> |
getOutput() |
Localizable |
getOutputOffset() |
protected abstract Img<T> |
getProcessingLine(long size) |
protected T |
getProcessingType() |
protected Interval |
getRange(int dim)
The area for the output/temp that needs to be convolved, always relative
to the input of the next convolution operation.
|
RandomAccessible<T> |
getResult() |
double[] |
getSigma() |
protected Interval |
getTemporaryImgSize() |
Img<T> |
getTmp1() |
Img<T> |
getTmp2() |
int |
numDimensions() |
protected void |
processLine(SamplingLineIterator<T> input,
double[] kernel)
Compute the current line.
|
void |
setNumThreads(int numThreads) |
T |
type() |
protected void |
updateInputLineSampler(SamplingLineIterator<T> a,
Interval range,
long[] offset,
Localizable originalLocation)
Updates the current
SamplingLineIterator to the location of the
new line that is processed and clears the processing line (set all values
to zero) |
protected void |
updateOutputLineWriter(WritableLineIterator<T> a,
Interval range,
long[] offset,
Localizable originalLocation)
Updates the current
WritableLineIterator to the location of the
new line that is processed. |
protected void |
writeLine(WritableLineIterator<T> a,
SamplingLineIterator<T> inputLineSampler)
Writes the computed line back into the output/temp image.
|
public AbstractGauss(double[] sigma, RandomAccessible<T> input, Interval inputInterval, RandomAccessible<T> output, Localizable outputOffset, ImgFactory<T> factory, T type)
public double[] getSigma()
public double[][] getKernel()
public int numDimensions()
public RandomAccessible<T> getInput()
public RandomAccessible<T> getOutput()
public ImgFactory<T> getFactory()
public Interval getInputInterval()
public Localizable getOutputOffset()
public T type()
protected T getProcessingType()
public RandomAccessible<T> getResult()
protected Interval getRange(int dim)
dim
- - The dimension that is currently processedInterval
defining the output size for the current
dimension that is processedprotected SamplingLineIterator<T> createInputLineSampler(int dim, Interval range)
Iterator
that samples a one dimensional line of input data for
the current dimension.dim
- - The current dimensionrange
- - the size of the output/temp imageSamplingLineIterator
which provides the inputprotected WritableLineIterator<T> createOutputLineWriter(int dim, Interval range, SamplingLineIterator<T> inputLineSampler)
Iterator
that samples a one dimensional line of output data
for the current dimension.dim
- - The current dimensionrange
- - the size of the output/temp imageinputLineSampler
- - the input line sampler which knows all the stuff alreadySamplingLineIterator
which provides the outputprotected void processLine(SamplingLineIterator<T> input, double[] kernel)
protected void writeLine(WritableLineIterator<T> a, SamplingLineIterator<T> inputLineSampler)
protected void updateInputLineSampler(SamplingLineIterator<T> a, Interval range, long[] offset, Localizable originalLocation)
SamplingLineIterator
to the location of the
new line that is processed and clears the processing line (set all values
to zero)a
- - the SamplingLineIterator
range
- - the size of the output/temp imageoffset
- - the new positionoriginalLocation
- - the location where is was put initially, all movements are
relative to thatprotected void updateOutputLineWriter(WritableLineIterator<T> a, Interval range, long[] offset, Localizable originalLocation)
WritableLineIterator
to the location of the
new line that is processed.a
- - the WritableLineIterator
range
- - the size of the output/temp imageoffset
- - the new positionoriginalLocation
- - the location where is was put initially, all movements are
relative to thatprotected void computeKernel()
protected Interval getTemporaryImgSize()
public int getNumThreads()
public void setNumThreads(int numThreads)
public void call()
Copyright © 2015–2022 ImgLib2. All rights reserved.