#include <itkFFTNormalizedCorrelationImageFilter.h>
Calculate normalized cross correlation using FFTs.
This filter calculates the normalized cross correlation (NCC) of two images using FFTs instead of spatial correlation. It is much faster than spatial correlation for reasonably large structuring elements. This filter is a subclass of the more general MaskedFFTNormalizedCorrelationImageFilter and operates by essentially setting the masks in that algorithm to images of ones. As described in detail in the references below, there is no computational overhead to utilizing the more general masked algorithm because the FFTs of the images of ones are still necessary for the computations.
Inputs: Two images are required as inputs, fixedImage and movingImage. In the context of correlation, inputs are often defined as: "image" and "template". In this filter, the fixedImage plays the role of the image, and the movingImage plays the role of the template. However, this filter is capable of correlating any two images and is not restricted to small movingImages (templates).
Optional parameters: The RequiredNumberOfOverlappingPixels enables the user to specify how many voxels of the two images must overlap; any location in the correlation map that results from fewer than this number of voxels will be set to zero. Larger values zero-out pixels on a larger border around the correlation image. Thus, larger values remove less stable computations but also limit the capture range. If RequiredNumberOfOverlappingPixels is set to 0, the default, no zeroing will take place.
Image size: fixedImage and movingImage need not be the same size. Furthermore, whereas some algorithms require that the "template" be smaller than the "image" because of errors in the regions where the two are not fully overlapping, this filter has no such restriction.
Image spacing: Since the computations are done in the pixel domain, all input images must have the same spacing.
Outputs; The output is an image of RealPixelType that is the NCC of the two images and its values range from -1.0 to 1.0. The size of this NCC image is, by definition, size(fixedImage) + size(movingImage) - 1.
Example filter usage:
For algorithmic details see [93] and [92].
Definition at line 97 of file itkFFTNormalizedCorrelationImageFilter.h.
Static Public Member Functions | |
static Pointer | New () |
![]() | |
static Pointer | New () |
![]() | |
static double | GetGlobalDefaultCoordinateTolerance () |
static double | GetGlobalDefaultDirectionTolerance () |
static void | SetGlobalDefaultCoordinateTolerance (double) |
static void | SetGlobalDefaultDirectionTolerance (double) |
![]() | |
static bool | GetGlobalWarningDisplay () |
static void | GlobalWarningDisplayOff () |
static void | GlobalWarningDisplayOn () |
static Pointer | New () |
static void | SetGlobalWarningDisplay (bool val) |
![]() | |
static void | BreakOnError () |
static Pointer | New () |
Static Public Attributes | |
static constexpr unsigned int | ImageDimension = TOutputImage::ImageDimension |
![]() | |
static constexpr unsigned int | ImageDimension = TOutputImage::ImageDimension |
![]() | |
static constexpr unsigned int | InputImageDimension = TInputImage::ImageDimension |
static constexpr unsigned int | OutputImageDimension = TOutputImage::ImageDimension |
![]() | |
static constexpr unsigned int | OutputImageDimension = TOutputImage::ImageDimension |
Additional Inherited Members | |
![]() | |
using | InputToOutputRegionCopierType |
using | OutputToInputRegionCopierType |
![]() | |
static const ImageRegionSplitterBase * | GetGlobalDefaultSplitter () |
static ITK_THREAD_RETURN_FUNCTION_CALL_CONVENTION | ThreaderCallback (void *arg) |
![]() | |
template<typename TSourceObject> | |
static void | MakeRequiredOutputs (TSourceObject &sourceObject, const DataObjectPointerArraySizeType numberOfRequiredOutputs) |
static constexpr float | progressFixedToFloat (uint32_t fixed) |
static uint32_t | progressFloatToFixed (float f) |
![]() | |
bool | m_DynamicMultiThreading { true } |
![]() | |
TimeStamp | m_OutputInformationMTime {} |
bool | m_Updating {} |
![]() | |
std::atomic< int > | m_ReferenceCount {} |
using itk::FFTNormalizedCorrelationImageFilter< TInputImage, TOutputImage >::ConstPointer = SmartPointer<const Self> |
Definition at line 107 of file itkFFTNormalizedCorrelationImageFilter.h.
using itk::FFTNormalizedCorrelationImageFilter< TInputImage, TOutputImage >::InputImageConstPointer = typename InputImageType::ConstPointer |
Definition at line 124 of file itkFFTNormalizedCorrelationImageFilter.h.
using itk::FFTNormalizedCorrelationImageFilter< TInputImage, TOutputImage >::InputImagePointer = typename InputImageType::Pointer |
Definition at line 123 of file itkFFTNormalizedCorrelationImageFilter.h.
using itk::FFTNormalizedCorrelationImageFilter< TInputImage, TOutputImage >::InputImageType = TInputImage |
Extract some information from the image types.
Definition at line 120 of file itkFFTNormalizedCorrelationImageFilter.h.
using itk::FFTNormalizedCorrelationImageFilter< TInputImage, TOutputImage >::InputRegionType = typename InputImageType::RegionType |
Definition at line 122 of file itkFFTNormalizedCorrelationImageFilter.h.
using itk::FFTNormalizedCorrelationImageFilter< TInputImage, TOutputImage >::InputSizeType = typename InputImageType::SizeType |
Definition at line 125 of file itkFFTNormalizedCorrelationImageFilter.h.
using itk::FFTNormalizedCorrelationImageFilter< TInputImage, TOutputImage >::OutputImagePointer = typename OutputImageType::Pointer |
Definition at line 126 of file itkFFTNormalizedCorrelationImageFilter.h.
using itk::FFTNormalizedCorrelationImageFilter< TInputImage, TOutputImage >::OutputImageType = TOutputImage |
Definition at line 121 of file itkFFTNormalizedCorrelationImageFilter.h.
using itk::FFTNormalizedCorrelationImageFilter< TInputImage, TOutputImage >::OutputPixelType = typename OutputImageType::PixelType |
Definition at line 127 of file itkFFTNormalizedCorrelationImageFilter.h.
using itk::FFTNormalizedCorrelationImageFilter< TInputImage, TOutputImage >::Pointer = SmartPointer<Self> |
Definition at line 106 of file itkFFTNormalizedCorrelationImageFilter.h.
using itk::FFTNormalizedCorrelationImageFilter< TInputImage, TOutputImage >::Self = FFTNormalizedCorrelationImageFilter |
Standard class type aliases.
Definition at line 104 of file itkFFTNormalizedCorrelationImageFilter.h.
using itk::FFTNormalizedCorrelationImageFilter< TInputImage, TOutputImage >::Superclass = MaskedFFTNormalizedCorrelationImageFilter<TInputImage, TOutputImage> |
Definition at line 105 of file itkFFTNormalizedCorrelationImageFilter.h.
|
inlineprotected |
Definition at line 130 of file itkFFTNormalizedCorrelationImageFilter.h.
References itk::ProcessObject::RemoveInput().
Referenced by GetNameOfClass().
|
overrideprotecteddefault |
|
virtual |
Create an object from an instance, potentially deferring to a factory. This method allows you to create an instance of an object that is exactly the same type as the referring object. This is useful in cases where an object has been cast back to a base class.
Reimplemented from itk::LightObject.
|
overrideprotectedvirtual |
Standard pipeline method.
Reimplemented from itk::ProcessObject.
|
virtual |
Reimplemented from itk::MaskedFFTNormalizedCorrelationImageFilter< TInputImage, TOutputImage, TMaskImage >.
References FFTNormalizedCorrelationImageFilter().
|
static |
Method for creation through the object factory.
|
overrideprotectedvirtual |
Methods invoked by Print() to print information about the object including superclasses. Typically not called by the user (use Print() instead) but used in the hierarchical print process to combine the output of several classes.
Reimplemented from itk::LightObject.
|
staticconstexpr |
Extract some information from the image types. Dimensionality of the two images is assumed to be the same.
Definition at line 117 of file itkFFTNormalizedCorrelationImageFilter.h.