ITK
5.0.0
Insight Segmentation and Registration Toolkit
|
#include <itkGaussianDerivativeOperator.h>
A NeighborhoodOperator whose coefficients are a one dimensional, discrete derivative Gaussian kernel.
GaussianDerivativeOperator can be used to calculate Gaussian derivatives by taking its inner product with to a Neighborhood (NeighborhooIterator) that is swept across an image region. It is a directional operator. N successive applications oriented along each dimensional direction will calculate separable, efficient, N-D Gaussian derivatives of an image region.
GaussianDerivativeOperator takes three parameters:
(1) The floating-point variance of the desired Gaussian function.
(2) The order of the derivative to be calculated (zero order means it performs only smoothing as a standard itk::GaussianOperator)
(3) The "maximum error" allowed in the discrete Gaussian function. "Maximum errror" is defined as the difference between the area under the discrete Gaussian curve and the area under the continuous Gaussian. Maximum error affects the Gaussian operator size. Care should be taken not to make this value too small relative to the variance lest the operator size become unreasonably large.
References: The Gaussian kernel contained in this operator was described by Tony Lindeberg (Discrete Scale-Space Theory and the Scale-Space Primal Sketch. Dissertation. Royal Institute of Technology, Stockholm, Sweden. May 1991.).
This implementation is derived from the Insight Journal paper: https://hdl.handle.net/1926/1290
Definition at line 79 of file itkGaussianDerivativeOperator.h.
Public Types | |
using | DerivativeOperatorType = DerivativeOperator< TPixel, VDimension, TAllocator > |
using | GaussianOperatorType = GaussianOperator< TPixel, VDimension, TAllocator > |
using | Self = GaussianDerivativeOperator |
using | Superclass = NeighborhoodOperator< TPixel, VDimension, TAllocator > |
Public Types inherited from itk::NeighborhoodOperator< TPixel, VDimension, TAllocator > | |
using | PixelRealType = typename NumericTraits< TPixel >::RealType |
using | PixelType = TPixel |
using | Self = NeighborhoodOperator |
using | SizeType = typename Superclass::SizeType |
using | SliceIteratorType = SliceIterator< TPixel, Self > |
using | Superclass = Neighborhood< TPixel, VDimension, TAllocator > |
Public Types inherited from itk::Neighborhood< TPixel, VDimension, TAllocator > | |
using | AllocatorType = TAllocator |
using | ConstIterator = typename AllocatorType::const_iterator |
using | DimensionValueType = unsigned int |
using | Iterator = typename AllocatorType::iterator |
using | NeighborIndexType = SizeValueType |
using | OffsetType = Offset< VDimension > |
using | PixelType = TPixel |
using | RadiusType = ::itk::Size< VDimension > |
using | Self = Neighborhood |
using | SizeType = ::itk::Size< VDimension > |
using | SizeValueType = typename SizeType::SizeValueType |
using | SliceIteratorType = SliceIterator< TPixel, Self > |
Protected Types | |
using | CoefficientVector = typename Superclass::CoefficientVector |
Protected Types inherited from itk::NeighborhoodOperator< TPixel, VDimension, TAllocator > | |
using | CoefficientVector = std::vector< PixelRealType > |
Protected Member Functions | |
void | Fill (const CoefficientVector &coeff) override |
CoefficientVector | GenerateCoefficients () override |
Protected Member Functions inherited from itk::NeighborhoodOperator< TPixel, VDimension, TAllocator > | |
virtual void | Fill (const CoefficientVector &)=0 |
virtual void | FillCenteredDirectional (const CoefficientVector &) |
void | InitializeToZero () |
Protected Member Functions inherited from itk::Neighborhood< TPixel, VDimension, TAllocator > | |
virtual void | Allocate (NeighborIndexType i) |
virtual void | ComputeNeighborhoodOffsetTable () |
virtual void | ComputeNeighborhoodStrideTable () |
void | SetSize () |
Static Protected Member Functions | |
static double | ModifiedBesselI (int, double) |
static double | ModifiedBesselI0 (double) |
static double | ModifiedBesselI1 (double) |
Private Member Functions | |
CoefficientVector | GenerateGaussianCoefficients () const |
const char * | GetNameOfClass () const override |
Private Attributes | |
double | m_MaximumError {0.005} |
unsigned int | m_MaximumKernelWidth {30} |
bool | m_NormalizeAcrossScale {true} |
unsigned int | m_Order {1} |
double | m_Spacing {1.0} |
double | m_Variance {1.0} |
Additional Inherited Members | |
Static Public Attributes inherited from itk::Neighborhood< TPixel, VDimension, TAllocator > | |
static constexpr unsigned int | NeighborhoodDimension = VDimension |
|
protected |
Definition at line 159 of file itkGaussianDerivativeOperator.h.
using itk::GaussianDerivativeOperator< TPixel, VDimension, TAllocator >::DerivativeOperatorType = DerivativeOperator< TPixel, VDimension, TAllocator > |
Definition at line 90 of file itkGaussianDerivativeOperator.h.
using itk::GaussianDerivativeOperator< TPixel, VDimension, TAllocator >::GaussianOperatorType = GaussianOperator< TPixel, VDimension, TAllocator > |
Neighborhood operator types.
Definition at line 89 of file itkGaussianDerivativeOperator.h.
using itk::GaussianDerivativeOperator< TPixel, VDimension, TAllocator >::Self = GaussianDerivativeOperator |
Standard class type aliases.
Definition at line 85 of file itkGaussianDerivativeOperator.h.
using itk::GaussianDerivativeOperator< TPixel, VDimension, TAllocator >::Superclass = NeighborhoodOperator< TPixel, VDimension, TAllocator > |
Definition at line 86 of file itkGaussianDerivativeOperator.h.
|
default |
Constructor.
itk::GaussianDerivativeOperator< TPixel, VDimension, TAllocator >::GaussianDerivativeOperator | ( | const Self & | other | ) |
Copy constructor
|
inlineoverrideprotected |
Arranges coefficients spatially in the memory buffer.
Definition at line 177 of file itkGaussianDerivativeOperator.h.
|
overrideprotectedvirtual |
Calculates operator coefficients.
Implements itk::NeighborhoodOperator< TPixel, VDimension, TAllocator >.
|
private |
|
inline |
Definition at line 138 of file itkGaussianDerivativeOperator.h.
|
inlineoverrideprivatevirtual |
For compatibility with itkWarningMacro
Reimplemented from itk::NeighborhoodOperator< TPixel, VDimension, TAllocator >.
Definition at line 187 of file itkGaussianDerivativeOperator.h.
|
inline |
Set/Get the flag for calculating scale-space normalized derivatives.
Normalized derivatives are obtained multiplying by the scale parameter $t^1/order$. This use useful for scale-space selection algorithms such as blob detection. The scaling results in the value of the derivatives being independent of the size of an object.
Definition at line 111 of file itkGaussianDerivativeOperator.h.
|
inline |
Sets/Get the order of the derivative.
Definition at line 151 of file itkGaussianDerivativeOperator.h.
|
inline |
Set/Get the spacing for the direction of this kernel.
Definition at line 124 of file itkGaussianDerivativeOperator.h.
|
inline |
Set/Get the variance of the Gaussian kernel.
Definition at line 119 of file itkGaussianDerivativeOperator.h.
|
staticprotected |
Returns the value of the modified Bessel function Ik(x) at a point x>=0, where k>=2.
|
staticprotected |
Returns the value of the modified Bessel function I0(x) at a point x >= 0.
|
staticprotected |
Returns the value of the modified Bessel function I1(x) at a point x, x real.
|
virtual |
Set/Get the flag for calculating scale-space normalized derivatives.
Normalized derivatives are obtained multiplying by the scale parameter $t^1/order$. This use useful for scale-space selection algorithms such as blob detection. The scaling results in the value of the derivatives being independent of the size of an object.
|
virtual |
Set/Get the flag for calculating scale-space normalized derivatives.
Normalized derivatives are obtained multiplying by the scale parameter $t^1/order$. This use useful for scale-space selection algorithms such as blob detection. The scaling results in the value of the derivatives being independent of the size of an object.
Self& itk::GaussianDerivativeOperator< TPixel, VDimension, TAllocator >::operator= | ( | const Self & | other | ) |
Assignment operator
|
overridevirtual |
Prints member variables
Reimplemented from itk::Neighborhood< TPixel, VDimension, TAllocator >.
|
inline |
Set/Get the desired maximum error of the gaussian approximation. Maximum error is the difference between the area under the discrete Gaussian curve and the area under the continuous Gaussian. Maximum error affects the Gaussian operator size. The value is clamped between 0.00001 and 0.99999.
Definition at line 131 of file itkGaussianDerivativeOperator.h.
|
inline |
Sets/Get a limit for growth of the kernel. Small maximum error values with large variances will yield very large kernel sizes. This value can be used to truncate a kernel in such instances. A warning will be given on truncation of the kernel.
Definition at line 144 of file itkGaussianDerivativeOperator.h.
|
inline |
Set/Get the flag for calculating scale-space normalized derivatives.
Normalized derivatives are obtained multiplying by the scale parameter $t^1/order$. This use useful for scale-space selection algorithms such as blob detection. The scaling results in the value of the derivatives being independent of the size of an object.
Definition at line 110 of file itkGaussianDerivativeOperator.h.
|
inline |
Sets/Get the order of the derivative.
Definition at line 150 of file itkGaussianDerivativeOperator.h.
|
inline |
Set/Get the spacing for the direction of this kernel.
Definition at line 123 of file itkGaussianDerivativeOperator.h.
|
inline |
Set/Get the variance of the Gaussian kernel.
Definition at line 118 of file itkGaussianDerivativeOperator.h.
|
private |
Difference between the areas under the curves of the continuous and discrete Gaussian functions.
Definition at line 200 of file itkGaussianDerivativeOperator.h.
|
private |
Maximum kernel size allowed. This value is used to truncate a kernel that has grown too large. A warning is given when the specified maximum error causes the kernel to exceed this size.
Definition at line 205 of file itkGaussianDerivativeOperator.h.
|
private |
Normalize derivatives across scale space
Definition at line 193 of file itkGaussianDerivativeOperator.h.
|
private |
Order of the derivative.
Definition at line 208 of file itkGaussianDerivativeOperator.h.
|
private |
Spacing in the direction of this kernel.
Definition at line 211 of file itkGaussianDerivativeOperator.h.
|
private |
Desired variance of the discrete Gaussian function.
Definition at line 196 of file itkGaussianDerivativeOperator.h.