#include <itkFiniteDifferenceImageFilter.h>
Inheritance diagram for itk::FiniteDifferenceImageFilter:


Public Types | |
| typedef FiniteDifferenceImageFilter | Self |
| typedef ImageToImageFilter< TInputImage, TOutputImage > | Superclass |
| typedef SmartPointer< Self > | Pointer |
| typedef SmartPointer< const Self > | ConstPointer |
| typedef TInputImage | InputImageType |
| typedef TOutputImage | OutputImageType |
| typedef TOutputImage::PixelType | PixelType |
| typedef FiniteDifferenceFunction< TOutputImage > | FiniteDifferenceFunctionType |
| typedef FiniteDifferenceFunctionType::TimeStepType | TimeStepType |
Public Methods | |
| virtual const char * | GetClassName () const |
| itkStaticConstMacro (ImageDimension, unsigned int, OutputImageType::ImageDimension) | |
| virtual unsigned int | GetElapsedIterations () const |
| virtual const FiniteDifferenceFunctionType::Pointer & | GetDifferenceFunction () const |
| virtual void | SetDifferenceFunction (FiniteDifferenceFunctionType *_arg) |
Protected Methods | |
| FiniteDifferenceImageFilter () | |
| ~FiniteDifferenceImageFilter () | |
| void | PrintSelf (std::ostream &os, Indent indent) const |
| virtual void | AllocateUpdateBuffer ()=0 |
| virtual void | ApplyUpdate (TimeStepType dt)=0 |
| virtual TimeStepType | CalculateChange ()=0 |
| virtual void | CopyInputToOutput ()=0 |
| virtual void | GenerateData () |
| virtual void | GenerateInputRequestedRegion () |
| virtual bool | Halt ()=0 |
| virtual void | Initialize () |
| virtual void | InitializeIteration () |
| virtual TimeStepType | ResolveTimeStep (const TimeStepType *timeStepList, const bool *valid, int size) |
| virtual void | SetElapsedIterations (unsigned int _arg) |
| virtual void | PostProcessOutput () |
The high-level algorithm implemented by the framework can be described by the following pseudocode.
WHILE NOT convergence:
FOR ALL pixels i
time_step = calculate_change(i)
update(i, time_step)
The following equation describes update
at pixel
on discrete image
:
Filters for different applications are created by defining a function object to handle the numerical calculations and choosing (or creating) a solver object that reflects the requirements and constraints of the application. For example, anisotropic diffusion filters are created by plugging anisotropic diffusion functions into the DenseFiniteDifferenceImageFilter. The separation between function object and solver object allows us to create, for example, sparse-field, dense-field, and narrow-band implementations of a level-set surface evolution filter can all be constructed by plugging the same function object into three different, specialized solvers.
Some simple examples are the specific subclasses of AnisotropicDiffusionImageFilter. The leaves of the anisotropic diffusion filter tree only define the function object they use for their particular flavor of diffusion. See CurvatureAnisotropicDiffusionImageFilter and GradientAnisotropicDiffusionImageFilter for details.
and the output of the filter is the solution to the p.d.e.
Note that there is no fixed container type for the buffer used to hold the update
. The container might be another image, or simply a list of values. AllocateUpdateBuffer is responsible for creating the
container. CalculateChange populates this buffer and ApplyUpdate adds the buffer values to the output image (solution). The boolean Halt() method returns a true value to stop iteration.
Definition at line 122 of file itkFiniteDifferenceImageFilter.h.
|
|||||
|
|||||
|
|||||
|
|||||
|
|||||
|
|||||
|
|||||
|
|||||
|
|||||
|
|||||||||
|
Definition at line 168 of file itkFiniteDifferenceImageFilter.h. |
|
|||||||||
|
Definition at line 169 of file itkFiniteDifferenceImageFilter.h. |
|
|||||||||
|
This method allocates a temporary update container in the subclass. Implemented in itk::ParallelSparseFieldLevelSetImageFilter< TInputImage, TOutputImage >, itk::SparseFieldLevelSetImageFilter< TInputImage, TOutputImage >, itk::FiniteDifferenceSparseImageFilter< TInputImageType, TSparseOutputImageType >, and itk::FiniteDifferenceSparseImageFilter< TInputImage, TSparseOutputImage >. |
|
||||||||||
|
This method is defined by a subclass to apply changes to the output from an update buffer and a time step value "dt".
Implemented in itk::ParallelSparseFieldLevelSetImageFilter< TInputImage, TOutputImage >, itk::SparseFieldLevelSetImageFilter< TInputImage, TOutputImage >, itk::FiniteDifferenceSparseImageFilter< TInputImageType, TSparseOutputImageType >, and itk::FiniteDifferenceSparseImageFilter< TInputImage, TSparseOutputImage >. |
|
|||||||||
|
This method is defined by a subclass to populate an update buffer with changes for the pixels in the output. It returns a time step value to be used for the update.
Implemented in itk::ParallelSparseFieldLevelSetImageFilter< TInputImage, TOutputImage >, itk::SparseFieldLevelSetImageFilter< TInputImage, TOutputImage >, itk::FiniteDifferenceSparseImageFilter< TInputImageType, TSparseOutputImageType >, and itk::FiniteDifferenceSparseImageFilter< TInputImage, TSparseOutputImage >. |
|
|||||||||
|
This method can be defined in subclasses as needed to copy the input to the output. See DenseFiniteDifferenceImageFilter for an implementation. Implemented in itk::PDEDeformableRegistrationFilter< TFixedImage, TMovingImage, TDeformationField >, itk::ImplicitManifoldNormalVectorFilter< TInputImage, TSparseOutputImage >, itk::NarrowBandImageFilterBase< TInputImage, TOutputImage >, itk::ParallelSparseFieldLevelSetImageFilter< TInputImage, TOutputImage >, itk::SparseFieldLevelSetImageFilter< TInputImage, TOutputImage >, itk::DenseFiniteDifferenceImageFilter< TInputImage, TOutputImage >, and itk::DenseFiniteDifferenceImageFilter< TDeformationField, TDeformationField >. |
|
|||||||||
|
This is the default, high-level algorithm for calculating finite difference solutions. It calls virtual methods in its subclasses to implement the major steps of the algorithm. Reimplemented from itk::ImageSource< TOutputImage >. Reimplemented in itk::AntiAliasBinaryImageFilter< TInputImage, TOutputImage >, itk::NarrowBandLevelSetImageFilter< TInputImage, TFeatureImage, TOutputPixelType, TOutputImage >, itk::SegmentationLevelSetImageFilter< TInputImage, TFeatureImage, TOutputPixelType, TOutputImage >, itk::NarrowBandImageFilterBase< TInputImage, TOutputImage >, and itk::ParallelSparseFieldLevelSetImageFilter< TInputImage, TOutputImage >. |
|
|||||||||
|
FiniteDifferenceImageFilter needs a larger input requested region than the output requested region. As such, we need to provide an implementation for GenerateInputRequestedRegion() in order to inform the pipeline execution model. The filter will ask for a padded region to perform its neighborhood calculations. If no such region is available, the boundaries will be handled as described in the FiniteDifferenceFunction defined by the subclass.
Reimplemented from itk::ImageToImageFilter< TInputImage, TOutputImage >. Reimplemented in itk::CurvatureFlowImageFilter< TInputImage, TOutputImage >, and itk::PDEDeformableRegistrationFilter< TFixedImage, TMovingImage, TDeformationField >. |
|
|||||||||
|
|||||||||
|
This method returns a pointer to a FiniteDifferenceFunction object that will be used by the filter to calculate updates at image pixels.
|
|
|||||||||
|
Get the number of elapsed iterations of the filter. |
|
|||||||||
|
||||||||||
|
This method is optionally defined by a subclass and is called before the loop of iterations of calculate_change & upate. It does the global initialization, i.e. in the SparseFieldLevelSetImageFilter, initialize the list of layers. Reimplemented in itk::ImplicitManifoldNormalVectorFilter< TInputImage, TSparseOutputImage >, itk::NarrowBandImageFilterBase< TInputImage, TOutputImage >, itk::ParallelSparseFieldLevelSetImageFilter< TInputImage, TOutputImage >, itk::SparseFieldLevelSetImageFilter< TInputImage, TOutputImage >, itk::FiniteDifferenceSparseImageFilter< TInputImageType, TSparseOutputImageType >, and itk::FiniteDifferenceSparseImageFilter< TInputImage, TSparseOutputImage >. Definition at line 219 of file itkFiniteDifferenceImageFilter.h. |
|
|||||||||
|
||||||||||||||||||||
|
Dimensionality of input and output data is assumed to be the same. |
|
|||||||||
|
This method is called after the solution has been generated to allow subclasses to apply some further processing to the output. Reimplemented in itk::ImplicitManifoldNormalVectorFilter< TInputImage, TSparseOutputImage >, itk::NarrowBandImageFilterBase< TInputImage, TOutputImage >, and itk::SparseFieldLevelSetImageFilter< TInputImage, TOutputImage >. Definition at line 251 of file itkFiniteDifferenceImageFilter.h. |
|
||||||||||||||||
|
||||||||||||||||||||
|
Virtual method for resolving a single time step from a set of time steps returned from processing threads.
|
|
||||||||||
|
This method sets the pointer to a FiniteDifferenceFunction object that will be used by the filter to calculate updates at image pixels.
|
|
||||||||||
|
Set the number of elapsed iterations of the filter. |
1.2.15 written by Dimitri van Heesch,
© 1997-2000