Medical Imaging Interaction Toolkit  2018.4.99-12ad79a3
Medical Imaging Interaction Toolkit
mitk::convolution Namespace Reference

Functions

itk::Array< double > wrap1d (itk::Array< double > kernel)
 Function that wraps the kernel. More...
 
itk::Array< double > zeropadding1d (itk::Array< double > unpaddedSpectrum, int paddedDimension)
 Fuction for zeropadding (adding zeros) of an Array/vnl_vector, so that is has size paddedDimensions. More...
 
itk::Array< double > unpadAndScale (itk::Array< double > convolutionResult, int initialDimension)
 Follow up function after back transformation from fourier space bwd_transform. removes padding and scales (transformed values have to be divided by transformation dimensions) More...
 
void prepareConvolution (const itk::Array< double > &kernel, const itk::Array< double > &spectrum, itk::Array< double > &preparedKernel, itk::Array< double > &preparedSpectrum)
 Convinience function for preparing 2 array for convolution with each other. Takes both arrays of type itk::Array, zeropadds them to the sum of their sizes and wraps the one specified as kernel. Returns them as vnl_vector<vcl_complex<double> >, ready to be entered in fwd_transform. More...
 

Function Documentation

◆ prepareConvolution()

void mitk::convolution::prepareConvolution ( const itk::Array< double > &  kernel,
const itk::Array< double > &  spectrum,
itk::Array< double > &  preparedKernel,
itk::Array< double > &  preparedSpectrum 
)
inline

Convinience function for preparing 2 array for convolution with each other. Takes both arrays of type itk::Array, zeropadds them to the sum of their sizes and wraps the one specified as kernel. Returns them as vnl_vector<vcl_complex<double> >, ready to be entered in fwd_transform.

Definition at line 95 of file mitkConvolutionHelper.h.

References zeropadding1d().

◆ unpadAndScale()

itk::Array<double> mitk::convolution::unpadAndScale ( itk::Array< double >  convolutionResult,
int  initialDimension 
)
inline

Follow up function after back transformation from fourier space bwd_transform. removes padding and scales (transformed values have to be divided by transformation dimensions)

Definition at line 75 of file mitkConvolutionHelper.h.

◆ wrap1d()

itk::Array<double> mitk::convolution::wrap1d ( itk::Array< double >  kernel)
inline

Function that wraps the kernel.

Some typedefs concerning data structures needed for vnl_fft_1d, which has vnl_vector< vcl_complex< double > > as output typ of the forward transformation fwd_transform. Input is of type vnl_vector< vcl_complex< T > > but since itk::Array is derived from vnl_vector, this works as well

Definition at line 35 of file mitkConvolutionHelper.h.

◆ zeropadding1d()

itk::Array<double> mitk::convolution::zeropadding1d ( itk::Array< double >  unpaddedSpectrum,
int  paddedDimension 
)
inline

Fuction for zeropadding (adding zeros) of an Array/vnl_vector, so that is has size paddedDimensions.

Parameters
paddedDimensionsDimensions that the Array should have after padding (convolution dimensions)
Remarks
dim = Dimensions of padded image –> PaddedDimension
m dimensions of larger image
n dimensions of image to be padded –> InitialDimension

Definition at line 53 of file mitkConvolutionHelper.h.

Referenced by prepareConvolution().