ITK  6.0.0
Insight Toolkit
Public Types | Public Member Functions | Static Public Member Functions | Static Public Attributes | Protected Member Functions | Protected Attributes | Private Member Functions | Private Attributes | List of all members
itk::DisplacementFieldTransform< TParametersValueType, VDimension > Class Template Reference

#include <itkDisplacementFieldTransform.h>

Detailed Description

template<typename TParametersValueType, unsigned int VDimension>
class itk::DisplacementFieldTransform< TParametersValueType, VDimension >

Provides local/dense/high-dimensionality transformation via a a displacement field.

The displacement field stores vectors of displacements, with dimension VDimension. Transformation is performed at a given point by adding the displacement at that point to the input point.

T(x, p), x is the position, p is the local parameter at position x. For a 2D example:

x = (x0, x1), p = (p0, p1)

then T(x, p) is defined as:

T(x, p) = (T0, T1) = (x0+p0, x1+p1)

During transformation, out-of-bounds input points are returned with zero displacement.

The displacement field is defined using an itkImage, and must be set before use by the user, using SetDisplacementField. The image has the same dimensionality as the input and output spaces, defined by template parameter VDimension, and is an image of vectors of type OutputVectorType, with dimensionality VDimension as well.

An interpolator of type VectorInterpolateImageFunction is used with the displacement field image. By default, VectorLinearInterpolateImageFunction is used, and the user can override using SetInterpolator.

The displacement field data is stored using the common OptimizerParameters type in conjunction with the ImageVectorOptimizerParametersHelper class. This allows access of the displacement field image as if it were an itkArray, allowing transparent use with other classes.

Warning
The SetParameters method will copy the passed parameters, which can be costly since displacement fields are dense and thus potentially very large.

The UpdateTransformParameters method simply adds the provided update array, applying the usual optional scaling factor. Derived classes may provide different behavior.

Because this is a local transform, methods that have a version that takes a point must be used, such as TransformVector, TransformCovariantVector, and TransformDiffusionTensor. Also, ComputeJacobianWithRespectToParameters simply returns an identity matrix (see method documentation), and ComputeJacobianWithRespectToPosition should be used.

Examples
Examples/RegistrationITKv4/DeformableRegistration10.cxx, Examples/RegistrationITKv4/DeformableRegistration16.cxx, Examples/RegistrationITKv4/DeformableRegistration17.cxx, Examples/RegistrationITKv4/DeformableRegistration2.cxx, Examples/RegistrationITKv4/DeformableRegistration3.cxx, Examples/RegistrationITKv4/DeformableRegistration5.cxx, Examples/RegistrationITKv4/DeformableRegistration9.cxx, and Examples/RegistrationITKv4/LandmarkWarping2.cxx.

Definition at line 87 of file itkDisplacementFieldTransform.h.

+ Inheritance diagram for itk::DisplacementFieldTransform< TParametersValueType, VDimension >:
+ Collaboration diagram for itk::DisplacementFieldTransform< TParametersValueType, VDimension >:

Public Types

using ConstPointer = SmartPointer< const Self >
 
using DirectionType = typename DisplacementFieldType::DirectionType
 
using DisplacementFieldConstPointer = typename DisplacementFieldType::ConstPointer
 
using DisplacementFieldPointer = typename DisplacementFieldType::Pointer
 
using DisplacementFieldType = Image< OutputVectorType, Dimension >
 
using IndexType = typename DisplacementFieldType::IndexType
 
using InputTensorEigenVectorType = CovariantVector< ScalarType, InputDiffusionTensor3DType::Dimension >
 
using InterpolatorType = VectorInterpolateImageFunction< DisplacementFieldType, ScalarType >
 
using OptimizerParametersHelperType = ImageVectorOptimizerParametersHelper< ScalarType, OutputVectorType::Dimension, Dimension >
 
using OutputTensorEigenVectorType = CovariantVector< ScalarType, OutputDiffusionTensor3DType::Dimension >
 
using PixelType = typename DisplacementFieldType::PixelType
 
using Pointer = SmartPointer< Self >
 
using PointType = typename DisplacementFieldType::PointType
 
using RegionType = typename DisplacementFieldType::RegionType
 
using Self = DisplacementFieldTransform
 
using SizeType = typename DisplacementFieldType::SizeType
 
using SpacingType = typename DisplacementFieldType::SpacingType
 
using Superclass = Transform< TParametersValueType, VDimension, VDimension >
 
using VectorImageDisplacementFieldType = VectorImage< TParametersValueType, Dimension >
 
- Public Types inherited from itk::Transform< TParametersValueType, VDimension, VDimension >
using ConstPointer = SmartPointer< const Self >
 
using DerivativeType = Array< ParametersValueType >
 
using DirectionChangeMatrix = Matrix< double, Self::OutputSpaceDimension, Self::InputSpaceDimension >
 
using InputCovariantVectorType = CovariantVector< TParametersValueType, VInputDimension >
 
using InputDiffusionTensor3DType = DiffusionTensor3D< TParametersValueType >
 
using InputDirectionMatrix = Matrix< double, Self::InputSpaceDimension, Self::InputSpaceDimension >
 
using InputPointType = Point< TParametersValueType, VInputDimension >
 
using InputSymmetricSecondRankTensorType = SymmetricSecondRankTensor< TParametersValueType, VInputDimension >
 
using InputVectorPixelType = VariableLengthVector< TParametersValueType >
 
using InputVectorType = Vector< TParametersValueType, VInputDimension >
 
using InputVnlVectorType = vnl_vector_fixed< TParametersValueType, VInputDimension >
 
using InverseJacobianPositionType = vnl_matrix_fixed< ParametersValueType, VInputDimension, VOutputDimension >
 
using InverseTransformBasePointer = typename InverseTransformBaseType::Pointer
 
using InverseTransformBaseType = Transform< TParametersValueType, VOutputDimension, VInputDimension >
 
using JacobianPositionType = vnl_matrix_fixed< ParametersValueType, VOutputDimension, VInputDimension >
 
using JacobianType = Array2D< ParametersValueType >
 
using MatrixType = Matrix< TParametersValueType, Self::OutputSpaceDimension, Self::InputSpaceDimension >
 
using OutputCovariantVectorType = CovariantVector< TParametersValueType, VOutputDimension >
 
using OutputDiffusionTensor3DType = DiffusionTensor3D< TParametersValueType >
 
using OutputDirectionMatrix = Matrix< double, Self::OutputSpaceDimension, Self::OutputSpaceDimension >
 
using OutputPointType = Point< TParametersValueType, VOutputDimension >
 
using OutputSymmetricSecondRankTensorType = SymmetricSecondRankTensor< TParametersValueType, VOutputDimension >
 
using OutputVectorPixelType = VariableLengthVector< TParametersValueType >
 
using OutputVectorType = Vector< TParametersValueType, VOutputDimension >
 
using OutputVnlVectorType = vnl_vector_fixed< TParametersValueType, VOutputDimension >
 
using Pointer = SmartPointer< Self >
 
using ScalarType = ParametersValueType
 
using Self = Transform
 
using Superclass = TransformBaseTemplate< TParametersValueType >
 

Public Member Functions

void ComputeInverseJacobianWithRespectToPosition (const InputPointType &point, InverseJacobianPositionType &jacobian) const override
 
virtual void ComputeJacobianWithRespectToParameters (const IndexType &, JacobianType &j) const
 
virtual void ComputeJacobianWithRespectToPosition (const IndexType &index, JacobianPositionType &jacobian) const
 
void ComputeJacobianWithRespectToPosition (const InputPointType &point, JacobianPositionType &jacobian) const override
 
virtual const ModifiedTimeTypeGetDisplacementFieldSetTime () const
 
bool GetInverse (Self *inverse) const
 
virtual void GetInverseJacobianOfForwardFieldWithRespectToPosition (const IndexType &index, JacobianPositionType &jacobian, bool useSVD=false) const
 
virtual void GetInverseJacobianOfForwardFieldWithRespectToPosition (const InputPointType &point, JacobianPositionType &jacobian, bool useSVD=false) const
 
InverseTransformBasePointer GetInverseTransform () const override
 
const char * GetNameOfClass () const override
 
NumberOfParametersType GetNumberOfLocalParameters () const override
 
TransformCategoryEnum GetTransformCategory () const override
 
void SetFixedParameters (const FixedParametersType &) override
 
virtual void SetIdentity ()
 
OutputVectorPixelType TransformCovariantVector (const InputVectorPixelType &) const override
 
OutputVectorPixelType TransformDiffusionTensor (const InputVectorPixelType &) const
 
OutputPointType TransformPoint (const InputPointType &inputPoint) const override
 
OutputVectorPixelType TransformVector (const InputVectorPixelType &) const override
 
OutputVnlVectorType TransformVector (const InputVnlVectorType &) const override
 
void UpdateTransformParameters (const DerivativeType &update, ScalarType factor=1.0) override
 
virtual void SetDisplacementField (DisplacementFieldType *field)
 
virtual void SetDisplacementField (VectorImageDisplacementFieldType *field)
 
void SetDisplacementField (std::nullptr_t)=delete
 
virtual DisplacementFieldTypeGetModifiableDisplacementField ()
 
virtual void SetInverseDisplacementField (DisplacementFieldType *inverseField)
 
virtual DisplacementFieldTypeGetModifiableInverseDisplacementField ()
 
virtual void SetInterpolator (InterpolatorType *interpolator)
 
virtual InterpolatorTypeGetModifiableInterpolator ()
 
virtual void SetInverseInterpolator (InterpolatorType *interpolator)
 
virtual InterpolatorTypeGetModifiableInverseInterpolator ()
 
OutputVectorType TransformVector (const InputVectorType &) const override
 
OutputDiffusionTensor3DType TransformDiffusionTensor (const InputDiffusionTensor3DType &) const
 
OutputCovariantVectorType TransformCovariantVector (const InputCovariantVectorType &) const override
 
void SetParameters (const ParametersType &params) override
 
void ComputeJacobianWithRespectToParameters (const InputPointType &, JacobianType &j) const override
 
virtual void SetCoordinateTolerance (double _arg)
 
virtual double GetCoordinateTolerance () const
 
virtual void SetDirectionTolerance (double _arg)
 
virtual double GetDirectionTolerance () const
 
- Public Member Functions inherited from itk::Transform< TParametersValueType, VDimension, VDimension >
virtual void ComputeJacobianWithRespectToParametersCachedTemporaries (const InputPointType &p, JacobianType &jacobian, JacobianType &) const
 
void CopyInFixedParameters (const FixedParametersValueType *const begin, const FixedParametersValueType *const end) override
 
void CopyInParameters (const ParametersValueType *const begin, const ParametersValueType *const end) override
 
const FixedParametersType & GetFixedParameters () const override
 
unsigned int GetInputSpaceDimension () const override
 
bool GetInverse (Self *) const
 
const char * GetNameOfClass () const override
 
virtual NumberOfParametersType GetNumberOfFixedParameters () const
 
NumberOfParametersType GetNumberOfParameters () const override
 
unsigned int GetOutputSpaceDimension () const override
 
const ParametersType & GetParameters () const override
 
TransformCategoryEnum GetTransformCategory () const override
 
std::string GetTransformTypeAsString () const override
 
virtual bool IsLinear () const
 
 itkCloneMacro (Self)
 
void SetParametersByValue (const ParametersType &p) override
 
virtual OutputCovariantVectorType TransformCovariantVector (const InputCovariantVectorType &vector, const InputPointType &point) const
 
virtual OutputVectorPixelType TransformCovariantVector (const InputVectorPixelType &vector, const InputPointType &point) const
 
virtual OutputDiffusionTensor3DType TransformDiffusionTensor3D (const InputDiffusionTensor3DType &) const
 
virtual OutputDiffusionTensor3DType TransformDiffusionTensor3D (const InputDiffusionTensor3DType &inputTensor, const InputPointType &point) const
 
virtual OutputVectorPixelType TransformDiffusionTensor3D (const InputVectorPixelType &) const
 
virtual OutputVectorPixelType TransformDiffusionTensor3D (const InputVectorPixelType &inputTensor, const InputPointType &point) const
 
virtual OutputSymmetricSecondRankTensorType TransformSymmetricSecondRankTensor (const InputSymmetricSecondRankTensorType &) const
 
virtual OutputSymmetricSecondRankTensorType TransformSymmetricSecondRankTensor (const InputSymmetricSecondRankTensorType &inputTensor, const InputPointType &point) const
 
virtual OutputVectorPixelType TransformSymmetricSecondRankTensor (const InputVectorPixelType &) const
 
virtual OutputVectorPixelType TransformSymmetricSecondRankTensor (const InputVectorPixelType &inputTensor, const InputPointType &point) const
 
virtual OutputVectorPixelType TransformVector (const InputVectorPixelType &vector, const InputPointType &point) const
 
virtual OutputVectorType TransformVector (const InputVectorType &vector, const InputPointType &point) const
 
virtual OutputVnlVectorType TransformVector (const InputVnlVectorType &vector, const InputPointType &point) const
 
template< typename TImage > std std::enable_if_t< TImage::ImageDimension==VInputDimension &&TImage::ImageDimension==VOutputDimension, void > ApplyToImageMetadata (SmartPointer< TImage > image) const
 

Static Public Member Functions

static Pointer New ()
 

Static Public Attributes

static constexpr unsigned int Dimension = VDimension
 
- Static Public Attributes inherited from itk::Transform< TParametersValueType, VDimension, VDimension >
static constexpr unsigned int InputSpaceDimension
 
static constexpr unsigned int OutputSpaceDimension
 

Protected Member Functions

 DisplacementFieldTransform ()
 
void PrintSelf (std::ostream &os, Indent indent) const override
 
 ~DisplacementFieldTransform () override=default
 
- Protected Member Functions inherited from itk::Transform< TParametersValueType, VDimension, VDimension >
LightObject::Pointer InternalClone () const override
 
OutputDiffusionTensor3DType PreservationOfPrincipalDirectionDiffusionTensor3DReorientation (const InputDiffusionTensor3DType &, const InverseJacobianPositionType &) const
 
 Transform ()=default
 
 Transform (NumberOfParametersType numberOfParameters)
 
 ~Transform () override=default
 

Protected Attributes

DisplacementFieldType::Pointer m_DisplacementField {}
 
ModifiedTimeType m_DisplacementFieldSetTime { 0 }
 
JacobianType m_IdentityJacobian {}
 
InterpolatorType::Pointer m_Interpolator {}
 
DisplacementFieldType::Pointer m_InverseDisplacementField {}
 
InterpolatorType::Pointer m_InverseInterpolator {}
 
- Protected Attributes inherited from itk::Transform< TParametersValueType, VDimension, VDimension >
FixedParametersType m_FixedParameters
 
ParametersType m_Parameters
 

Private Member Functions

virtual void ComputeJacobianWithRespectToPositionInternal (const IndexType &index, JacobianPositionType &jacobian, bool doInverseJacobian) const
 
virtual void SetFixedParametersFromDisplacementField () const
 
virtual void VerifyFixedParametersInformation ()
 

Private Attributes

double m_CoordinateTolerance {}
 
double m_DirectionTolerance {}
 

Additional Inherited Members

- Public Attributes inherited from itk::Transform< TParametersValueType, VDimension, VDimension >
InverseJacobianPositionType &jacobian const
 
- Static Protected Member Functions inherited from itk::Transform< TParametersValueType, VDimension, VDimension >
static InverseTransformBasePointer InvertTransform (const TTransform &transform)
 

Member Typedef Documentation

◆ ConstPointer

template<typename TParametersValueType , unsigned int VDimension>
using itk::DisplacementFieldTransform< TParametersValueType, VDimension >::ConstPointer = SmartPointer<const Self>

Definition at line 96 of file itkDisplacementFieldTransform.h.

◆ DirectionType

template<typename TParametersValueType , unsigned int VDimension>
using itk::DisplacementFieldTransform< TParametersValueType, VDimension >::DirectionType = typename DisplacementFieldType::DirectionType

Definition at line 173 of file itkDisplacementFieldTransform.h.

◆ DisplacementFieldConstPointer

template<typename TParametersValueType , unsigned int VDimension>
using itk::DisplacementFieldTransform< TParametersValueType, VDimension >::DisplacementFieldConstPointer = typename DisplacementFieldType::ConstPointer

Definition at line 164 of file itkDisplacementFieldTransform.h.

◆ DisplacementFieldPointer

template<typename TParametersValueType , unsigned int VDimension>
using itk::DisplacementFieldTransform< TParametersValueType, VDimension >::DisplacementFieldPointer = typename DisplacementFieldType::Pointer

Definition at line 163 of file itkDisplacementFieldTransform.h.

◆ DisplacementFieldType

template<typename TParametersValueType , unsigned int VDimension>
using itk::DisplacementFieldTransform< TParametersValueType, VDimension >::DisplacementFieldType = Image<OutputVectorType, Dimension>

Define the displacement field type and corresponding interpolator type.

Definition at line 161 of file itkDisplacementFieldTransform.h.

◆ IndexType

template<typename TParametersValueType , unsigned int VDimension>
using itk::DisplacementFieldTransform< TParametersValueType, VDimension >::IndexType = typename DisplacementFieldType::IndexType

Standard types for the displacement Field

Definition at line 169 of file itkDisplacementFieldTransform.h.

◆ InputTensorEigenVectorType

template<typename TParametersValueType , unsigned int VDimension>
using itk::DisplacementFieldTransform< TParametersValueType, VDimension >::InputTensorEigenVectorType = CovariantVector<ScalarType, InputDiffusionTensor3DType::Dimension>

Standard tensor type for this class

Definition at line 151 of file itkDisplacementFieldTransform.h.

◆ InterpolatorType

template<typename TParametersValueType , unsigned int VDimension>
using itk::DisplacementFieldTransform< TParametersValueType, VDimension >::InterpolatorType = VectorInterpolateImageFunction<DisplacementFieldType, ScalarType>

Definition at line 166 of file itkDisplacementFieldTransform.h.

◆ OptimizerParametersHelperType

template<typename TParametersValueType , unsigned int VDimension>
using itk::DisplacementFieldTransform< TParametersValueType, VDimension >::OptimizerParametersHelperType = ImageVectorOptimizerParametersHelper<ScalarType, OutputVectorType::Dimension, Dimension>

Define the internal parameter helper used to access the field

Definition at line 179 of file itkDisplacementFieldTransform.h.

◆ OutputTensorEigenVectorType

template<typename TParametersValueType , unsigned int VDimension>
using itk::DisplacementFieldTransform< TParametersValueType, VDimension >::OutputTensorEigenVectorType = CovariantVector<ScalarType, OutputDiffusionTensor3DType::Dimension>

Definition at line 152 of file itkDisplacementFieldTransform.h.

◆ PixelType

template<typename TParametersValueType , unsigned int VDimension>
using itk::DisplacementFieldTransform< TParametersValueType, VDimension >::PixelType = typename DisplacementFieldType::PixelType

Definition at line 175 of file itkDisplacementFieldTransform.h.

◆ Pointer

template<typename TParametersValueType , unsigned int VDimension>
using itk::DisplacementFieldTransform< TParametersValueType, VDimension >::Pointer = SmartPointer<Self>

Definition at line 95 of file itkDisplacementFieldTransform.h.

◆ PointType

template<typename TParametersValueType , unsigned int VDimension>
using itk::DisplacementFieldTransform< TParametersValueType, VDimension >::PointType = typename DisplacementFieldType::PointType

Definition at line 174 of file itkDisplacementFieldTransform.h.

◆ RegionType

template<typename TParametersValueType , unsigned int VDimension>
using itk::DisplacementFieldTransform< TParametersValueType, VDimension >::RegionType = typename DisplacementFieldType::RegionType

Definition at line 170 of file itkDisplacementFieldTransform.h.

◆ Self

template<typename TParametersValueType , unsigned int VDimension>
using itk::DisplacementFieldTransform< TParametersValueType, VDimension >::Self = DisplacementFieldTransform

Standard class type aliases.

Definition at line 93 of file itkDisplacementFieldTransform.h.

◆ SizeType

template<typename TParametersValueType , unsigned int VDimension>
using itk::DisplacementFieldTransform< TParametersValueType, VDimension >::SizeType = typename DisplacementFieldType::SizeType

Definition at line 171 of file itkDisplacementFieldTransform.h.

◆ SpacingType

template<typename TParametersValueType , unsigned int VDimension>
using itk::DisplacementFieldTransform< TParametersValueType, VDimension >::SpacingType = typename DisplacementFieldType::SpacingType

Definition at line 172 of file itkDisplacementFieldTransform.h.

◆ Superclass

template<typename TParametersValueType , unsigned int VDimension>
using itk::DisplacementFieldTransform< TParametersValueType, VDimension >::Superclass = Transform<TParametersValueType, VDimension, VDimension>

Definition at line 94 of file itkDisplacementFieldTransform.h.

◆ VectorImageDisplacementFieldType

template<typename TParametersValueType , unsigned int VDimension>
using itk::DisplacementFieldTransform< TParametersValueType, VDimension >::VectorImageDisplacementFieldType = VectorImage<TParametersValueType, Dimension>

Definition at line 162 of file itkDisplacementFieldTransform.h.

Constructor & Destructor Documentation

◆ DisplacementFieldTransform()

template<typename TParametersValueType , unsigned int VDimension>
itk::DisplacementFieldTransform< TParametersValueType, VDimension >::DisplacementFieldTransform ( )
protected

◆ ~DisplacementFieldTransform()

template<typename TParametersValueType , unsigned int VDimension>
itk::DisplacementFieldTransform< TParametersValueType, VDimension >::~DisplacementFieldTransform ( )
overrideprotecteddefault

Member Function Documentation

◆ ComputeInverseJacobianWithRespectToPosition()

template<typename TParametersValueType , unsigned int VDimension>
void itk::DisplacementFieldTransform< TParametersValueType, VDimension >::ComputeInverseJacobianWithRespectToPosition ( const InputPointType point,
InverseJacobianPositionType jacobian 
) const
override

Compute the jacobian with respect to the position, by point. j will be resized as needed.

◆ ComputeJacobianWithRespectToParameters() [1/2]

template<typename TParametersValueType , unsigned int VDimension>
virtual void itk::DisplacementFieldTransform< TParametersValueType, VDimension >::ComputeJacobianWithRespectToParameters ( const IndexType ,
JacobianType j 
) const
inlinevirtual

Compute the jacobian with respect to the parameters at an index. Simply returns identity matrix, sized [VDimension, VDimension]. See ComputeJacobianWithRespectToParameters( InputPointType, ... ) for rationale.

Definition at line 346 of file itkDisplacementFieldTransform.h.

◆ ComputeJacobianWithRespectToParameters() [2/2]

template<typename TParametersValueType , unsigned int VDimension>
void itk::DisplacementFieldTransform< TParametersValueType, VDimension >::ComputeJacobianWithRespectToParameters ( const InputPointType ,
JacobianType j 
) const
inlineoverridevirtual

Compute the jacobian with respect to the parameters at a point. Simply returns identity matrix, sized [VDimension, VDimension].

T(x, p), x is the position, p is the local parameter at position x. Take a 2D example, x = (x0, x1), p = (p0, p1) and T(x, p) is defined as:

T(x, p) = (T0, T1) = (x0+p0, x1+p1)

Each local deformation is defined as a translation transform. So the Jacobian w.r.t parameters are

dT/dp = [ dT0/dp0, dT0/dp1; dT1/dp0, dT1/dp1 ];

= [1, 0; 0, 1];

TODO: format the above for doxygen formula.

Implements itk::Transform< TParametersValueType, VDimension, VDimension >.

Definition at line 333 of file itkDisplacementFieldTransform.h.

◆ ComputeJacobianWithRespectToPosition() [1/2]

template<typename TParametersValueType , unsigned int VDimension>
virtual void itk::DisplacementFieldTransform< TParametersValueType, VDimension >::ComputeJacobianWithRespectToPosition ( const IndexType index,
JacobianPositionType jacobian 
) const
virtual

Compute the jacobian with respect to the position, by index. j will be resized as needed.

◆ ComputeJacobianWithRespectToPosition() [2/2]

template<typename TParametersValueType , unsigned int VDimension>
void itk::DisplacementFieldTransform< TParametersValueType, VDimension >::ComputeJacobianWithRespectToPosition ( const InputPointType point,
JacobianPositionType jacobian 
) const
overridevirtual

Compute the jacobian with respect to the position, by point. j will be resized as needed.

Reimplemented from itk::Transform< TParametersValueType, VDimension, VDimension >.

◆ ComputeJacobianWithRespectToPositionInternal()

template<typename TParametersValueType , unsigned int VDimension>
virtual void itk::DisplacementFieldTransform< TParametersValueType, VDimension >::ComputeJacobianWithRespectToPositionInternal ( const IndexType index,
JacobianPositionType jacobian,
bool  doInverseJacobian 
) const
privatevirtual

Internal method for calculating either forward or inverse jacobian, depending on state of doInverseJacobian. Used by public methods ComputeJacobianWithRespectToPosition and GetInverseJacobianOfForwardFieldWithRespectToPosition to perform actual work. doInverseJacobian indicates that the inverse jacobian should be returned

◆ GetCoordinateTolerance()

template<typename TParametersValueType , unsigned int VDimension>
virtual double itk::DisplacementFieldTransform< TParametersValueType, VDimension >::GetCoordinateTolerance ( ) const
virtual

Set/Get the coordinate tolerance. This tolerance is used when comparing the space defined by deformation fields and its inverse to ensure they occupy the same physical space.

See also
ImageToImageFilterCommon::SetGlobalDefaultCoordinateTolerance

◆ GetDirectionTolerance()

template<typename TParametersValueType , unsigned int VDimension>
virtual double itk::DisplacementFieldTransform< TParametersValueType, VDimension >::GetDirectionTolerance ( ) const
virtual

Set/Get the direction tolerance. This tolerance is used to when comparing the orientation of the deformation fields and its inverse to ensure they occupy the same physical space.

See also
ImageToImageFilterCommon::SetGlobalDefaultDirectionTolerance

◆ GetDisplacementFieldSetTime()

template<typename TParametersValueType , unsigned int VDimension>
virtual const ModifiedTimeType& itk::DisplacementFieldTransform< TParametersValueType, VDimension >::GetDisplacementFieldSetTime ( ) const
virtual

Get the modification time of displacement field.

◆ GetInverse()

template<typename TParametersValueType , unsigned int VDimension>
bool itk::DisplacementFieldTransform< TParametersValueType, VDimension >::GetInverse ( Self inverse) const

Return an inverse of this transform. Note that the inverse displacement field must be set by the user.

◆ GetInverseJacobianOfForwardFieldWithRespectToPosition() [1/2]

template<typename TParametersValueType , unsigned int VDimension>
virtual void itk::DisplacementFieldTransform< TParametersValueType, VDimension >::GetInverseJacobianOfForwardFieldWithRespectToPosition ( const IndexType index,
JacobianPositionType jacobian,
bool  useSVD = false 
) const
virtual

Compute the inverse jacobian of the forward displacement field with respect to the position, by index.Note that this is different than the jacobian of the inverse displacement field. This takes advantage of the ability to compute the inverse jacobian of a displacement field by simply reversing the sign of the forward jacobian. However, a more accurate method for computing the inverse jacobian is to take the inverse of the jacobian matrix. This method is more computationally expensive and may be used by setting useSVD to true

◆ GetInverseJacobianOfForwardFieldWithRespectToPosition() [2/2]

template<typename TParametersValueType , unsigned int VDimension>
virtual void itk::DisplacementFieldTransform< TParametersValueType, VDimension >::GetInverseJacobianOfForwardFieldWithRespectToPosition ( const InputPointType point,
JacobianPositionType jacobian,
bool  useSVD = false 
) const
virtual

Compute the inverse jacobian of the forward displacement field with respect to the position, by point. Note that this is different than the jacobian of the inverse displacement field. This takes advantage of the ability to compute the inverse jacobian of a displacement field by simply reversing the sign of the forward jacobian. However, a more accurate method for computing the inverse jacobian is to take the inverse of the jacobian matrix. This method is more computationally expensive and may be used by setting useSVD to true

◆ GetInverseTransform()

template<typename TParametersValueType , unsigned int VDimension>
InverseTransformBasePointer itk::DisplacementFieldTransform< TParametersValueType, VDimension >::GetInverseTransform ( ) const
overridevirtual

Return an inverse of this transform. Note that the inverse displacement field must be set by the user.

Reimplemented from itk::Transform< TParametersValueType, VDimension, VDimension >.

Reimplemented in itk::VelocityFieldTransform< TParametersValueType, VDimension >.

◆ GetModifiableDisplacementField()

template<typename TParametersValueType , unsigned int VDimension>
virtual DisplacementFieldType* itk::DisplacementFieldTransform< TParametersValueType, VDimension >::GetModifiableDisplacementField ( )
virtual

Get/Set the displacement field. Set the displacement field. Create special set accessor to update interpolator and assign displacement field to transform parameters container.

◆ GetModifiableInterpolator()

template<typename TParametersValueType , unsigned int VDimension>
virtual InterpolatorType* itk::DisplacementFieldTransform< TParametersValueType, VDimension >::GetModifiableInterpolator ( )
virtual

Get/Set the interpolator. Create out own set accessor that assigns the displacement field.

◆ GetModifiableInverseDisplacementField()

template<typename TParametersValueType , unsigned int VDimension>
virtual DisplacementFieldType* itk::DisplacementFieldTransform< TParametersValueType, VDimension >::GetModifiableInverseDisplacementField ( )
virtual

Get/Set the inverse displacement field. This must be supplied by the user for GetInverse() to work.

◆ GetModifiableInverseInterpolator()

template<typename TParametersValueType , unsigned int VDimension>
virtual InterpolatorType* itk::DisplacementFieldTransform< TParametersValueType, VDimension >::GetModifiableInverseInterpolator ( )
virtual

Get/Set the interpolator for the inverse field. Create out own set accessor that assigns the displacement field.

◆ GetNameOfClass()

template<typename TParametersValueType , unsigned int VDimension>
const char* itk::DisplacementFieldTransform< TParametersValueType, VDimension >::GetNameOfClass ( ) const
override

◆ GetNumberOfLocalParameters()

template<typename TParametersValueType , unsigned int VDimension>
NumberOfParametersType itk::DisplacementFieldTransform< TParametersValueType, VDimension >::GetNumberOfLocalParameters ( ) const
inlineoverridevirtual

Return the number of local parameters that completely defines the Transform at an individual voxel. For transforms with local support, this will enable downstream computation of the jacobian wrt only the local support region. For instance, in the case of a deformation field, this will be equal to the number of image dimensions. If it is an affine transform, this will be the same as the GetNumberOfParameters().

Reimplemented from itk::Transform< TParametersValueType, VDimension, VDimension >.

Definition at line 431 of file itkDisplacementFieldTransform.h.

References itk::GTest::TypedefsAndConstructors::Dimension2::Dimension.

◆ GetTransformCategory()

template<typename TParametersValueType , unsigned int VDimension>
TransformCategoryEnum itk::DisplacementFieldTransform< TParametersValueType, VDimension >::GetTransformCategory ( ) const
inlineoverride

This transform is not linear.

Definition at line 425 of file itkDisplacementFieldTransform.h.

◆ New()

template<typename TParametersValueType , unsigned int VDimension>
static Pointer itk::DisplacementFieldTransform< TParametersValueType, VDimension >::New ( )
static

New macro for creation of through a Smart Pointer

◆ PrintSelf()

template<typename TParametersValueType , unsigned int VDimension>
void itk::DisplacementFieldTransform< TParametersValueType, VDimension >::PrintSelf ( std::ostream &  os,
Indent  indent 
) const
overrideprotected

◆ SetCoordinateTolerance()

template<typename TParametersValueType , unsigned int VDimension>
virtual void itk::DisplacementFieldTransform< TParametersValueType, VDimension >::SetCoordinateTolerance ( double  _arg)
virtual

Set/Get the coordinate tolerance. This tolerance is used when comparing the space defined by deformation fields and its inverse to ensure they occupy the same physical space.

See also
ImageToImageFilterCommon::SetGlobalDefaultCoordinateTolerance

◆ SetDirectionTolerance()

template<typename TParametersValueType , unsigned int VDimension>
virtual void itk::DisplacementFieldTransform< TParametersValueType, VDimension >::SetDirectionTolerance ( double  _arg)
virtual

Set/Get the direction tolerance. This tolerance is used to when comparing the orientation of the deformation fields and its inverse to ensure they occupy the same physical space.

See also
ImageToImageFilterCommon::SetGlobalDefaultDirectionTolerance

◆ SetDisplacementField() [1/3]

template<typename TParametersValueType , unsigned int VDimension>
virtual void itk::DisplacementFieldTransform< TParametersValueType, VDimension >::SetDisplacementField ( DisplacementFieldType field)
virtual

Get/Set the displacement field. Set the displacement field. Create special set accessor to update interpolator and assign displacement field to transform parameters container.

Reimplemented in itk::VelocityFieldTransform< TParametersValueType, VDimension >.

◆ SetDisplacementField() [2/3]

template<typename TParametersValueType , unsigned int VDimension>
void itk::DisplacementFieldTransform< TParametersValueType, VDimension >::SetDisplacementField ( std::nullptr_t  )
delete

Get/Set the displacement field. Set the displacement field. Create special set accessor to update interpolator and assign displacement field to transform parameters container.

◆ SetDisplacementField() [3/3]

template<typename TParametersValueType , unsigned int VDimension>
virtual void itk::DisplacementFieldTransform< TParametersValueType, VDimension >::SetDisplacementField ( VectorImageDisplacementFieldType field)
virtual

Get/Set the displacement field. Set the displacement field. Create special set accessor to update interpolator and assign displacement field to transform parameters container.

◆ SetFixedParameters()

template<typename TParametersValueType , unsigned int VDimension>
void itk::DisplacementFieldTransform< TParametersValueType, VDimension >::SetFixedParameters ( const FixedParametersType &  )
overridevirtual

This method sets the fixed parameters of the transform. For a displacement field transform, the fixed parameters are the following: field size, field origin, field spacing, and field direction.

Note: If a displacement field already exists, this function creates a new one with zero displacement (identity transform). If an inverse displacement field exists, a new one is also created.

Implements itk::Transform< TParametersValueType, VDimension, VDimension >.

Reimplemented in itk::VelocityFieldTransform< TParametersValueType, VDimension >.

◆ SetFixedParametersFromDisplacementField()

template<typename TParametersValueType , unsigned int VDimension>
virtual void itk::DisplacementFieldTransform< TParametersValueType, VDimension >::SetFixedParametersFromDisplacementField ( ) const
privatevirtual

Convenience method which reads the information from the current displacement field into m_FixedParameters.

◆ SetIdentity()

template<typename TParametersValueType , unsigned int VDimension>
virtual void itk::DisplacementFieldTransform< TParametersValueType, VDimension >::SetIdentity ( )
virtual

◆ SetInterpolator()

template<typename TParametersValueType , unsigned int VDimension>
virtual void itk::DisplacementFieldTransform< TParametersValueType, VDimension >::SetInterpolator ( InterpolatorType interpolator)
virtual

Get/Set the interpolator. Create out own set accessor that assigns the displacement field.

◆ SetInverseDisplacementField()

template<typename TParametersValueType , unsigned int VDimension>
virtual void itk::DisplacementFieldTransform< TParametersValueType, VDimension >::SetInverseDisplacementField ( DisplacementFieldType inverseField)
virtual

Get/Set the inverse displacement field. This must be supplied by the user for GetInverse() to work.

◆ SetInverseInterpolator()

template<typename TParametersValueType , unsigned int VDimension>
virtual void itk::DisplacementFieldTransform< TParametersValueType, VDimension >::SetInverseInterpolator ( InterpolatorType interpolator)
virtual

Get/Set the interpolator for the inverse field. Create out own set accessor that assigns the displacement field.

◆ SetParameters()

template<typename TParametersValueType , unsigned int VDimension>
void itk::DisplacementFieldTransform< TParametersValueType, VDimension >::SetParameters ( const ParametersType &  params)
inlineoverridevirtual

Set the transformation parameters. This sets the displacement field image directly.

Implements itk::Transform< TParametersValueType, VDimension, VDimension >.

Definition at line 283 of file itkDisplacementFieldTransform.h.

◆ TransformCovariantVector() [1/2]

template<typename TParametersValueType , unsigned int VDimension>
OutputCovariantVectorType itk::DisplacementFieldTransform< TParametersValueType, VDimension >::TransformCovariantVector ( const InputCovariantVectorType ) const
inlineoverridevirtual

Method to transform a CovariantVector.

Reimplemented from itk::Transform< TParametersValueType, VDimension, VDimension >.

Definition at line 266 of file itkDisplacementFieldTransform.h.

◆ TransformCovariantVector() [2/2]

template<typename TParametersValueType , unsigned int VDimension>
OutputVectorPixelType itk::DisplacementFieldTransform< TParametersValueType, VDimension >::TransformCovariantVector ( const InputVectorPixelType ) const
inlineoverridevirtual

Method to transform a CovariantVector stored in a VectorImage.

Reimplemented from itk::Transform< TParametersValueType, VDimension, VDimension >.

Definition at line 274 of file itkDisplacementFieldTransform.h.

◆ TransformDiffusionTensor() [1/2]

template<typename TParametersValueType , unsigned int VDimension>
OutputDiffusionTensor3DType itk::DisplacementFieldTransform< TParametersValueType, VDimension >::TransformDiffusionTensor ( const InputDiffusionTensor3DType ) const
inline

Definition at line 249 of file itkDisplacementFieldTransform.h.

◆ TransformDiffusionTensor() [2/2]

template<typename TParametersValueType , unsigned int VDimension>
OutputVectorPixelType itk::DisplacementFieldTransform< TParametersValueType, VDimension >::TransformDiffusionTensor ( const InputVectorPixelType ) const
inline

Definition at line 257 of file itkDisplacementFieldTransform.h.

◆ TransformPoint()

template<typename TParametersValueType , unsigned int VDimension>
OutputPointType itk::DisplacementFieldTransform< TParametersValueType, VDimension >::TransformPoint ( const InputPointType inputPoint) const
overridevirtual

Method to transform a point. Out-of-bounds points will be returned with zero displacement.

Implements itk::Transform< TParametersValueType, VDimension, VDimension >.

◆ TransformVector() [1/3]

template<typename TParametersValueType , unsigned int VDimension>
OutputVectorPixelType itk::DisplacementFieldTransform< TParametersValueType, VDimension >::TransformVector ( const InputVectorPixelType ) const
inlineoverridevirtual

Method to transform a vector stored in a VectorImage.

Reimplemented from itk::Transform< TParametersValueType, VDimension, VDimension >.

Definition at line 233 of file itkDisplacementFieldTransform.h.

◆ TransformVector() [2/3]

template<typename TParametersValueType , unsigned int VDimension>
OutputVectorType itk::DisplacementFieldTransform< TParametersValueType, VDimension >::TransformVector ( const InputVectorType ) const
inlineoverridevirtual

Method to transform a vector.

Reimplemented from itk::Transform< TParametersValueType, VDimension, VDimension >.

Definition at line 225 of file itkDisplacementFieldTransform.h.

◆ TransformVector() [3/3]

template<typename TParametersValueType , unsigned int VDimension>
OutputVnlVectorType itk::DisplacementFieldTransform< TParametersValueType, VDimension >::TransformVector ( const InputVnlVectorType ) const
inlineoverridevirtual

Method to transform a vnl_vector.

Reimplemented from itk::Transform< TParametersValueType, VDimension, VDimension >.

Definition at line 240 of file itkDisplacementFieldTransform.h.

◆ UpdateTransformParameters()

template<typename TParametersValueType , unsigned int VDimension>
void itk::DisplacementFieldTransform< TParametersValueType, VDimension >::UpdateTransformParameters ( const DerivativeType update,
ScalarType  factor = 1.0 
)
overridevirtual

Update the transform's parameters by the values in update.

Parameters
updatemust be of the same length as returned by GetNumberOfParameters(). Throw an exception otherwise.
factoris a scalar multiplier for each value in update. SetParameters is called at the end of this method, to allow the transform to perform any required operations on the updated parameters - typically a conversion to member variables for use in TransformPoint.

Reimplemented from itk::Transform< TParametersValueType, VDimension, VDimension >.

Reimplemented in itk::VelocityFieldTransform< TParametersValueType, VDimension >, itk::GaussianSmoothingOnUpdateDisplacementFieldTransform< TParametersValueType, VDimension >, and itk::GaussianExponentialDiffeomorphicTransform< TParametersValueType, VDimension >.

◆ VerifyFixedParametersInformation()

template<typename TParametersValueType , unsigned int VDimension>
virtual void itk::DisplacementFieldTransform< TParametersValueType, VDimension >::VerifyFixedParametersInformation ( )
privatevirtual

Internal method to check that the inverse and forward displacement fields have the same fixed parameters.

Member Data Documentation

◆ Dimension

template<typename TParametersValueType , unsigned int VDimension>
constexpr unsigned int itk::DisplacementFieldTransform< TParametersValueType, VDimension >::Dimension = VDimension
staticconstexpr

Dimension of the domain spaces.

Definition at line 158 of file itkDisplacementFieldTransform.h.

◆ m_CoordinateTolerance

template<typename TParametersValueType , unsigned int VDimension>
double itk::DisplacementFieldTransform< TParametersValueType, VDimension >::m_CoordinateTolerance {}
private

Definition at line 508 of file itkDisplacementFieldTransform.h.

◆ m_DirectionTolerance

template<typename TParametersValueType , unsigned int VDimension>
double itk::DisplacementFieldTransform< TParametersValueType, VDimension >::m_DirectionTolerance {}
private

Definition at line 509 of file itkDisplacementFieldTransform.h.

◆ m_DisplacementField

template<typename TParametersValueType , unsigned int VDimension>
DisplacementFieldType::Pointer itk::DisplacementFieldTransform< TParametersValueType, VDimension >::m_DisplacementField {}
protected

The displacement field and its inverse (if it exists).

Definition at line 465 of file itkDisplacementFieldTransform.h.

◆ m_DisplacementFieldSetTime

template<typename TParametersValueType , unsigned int VDimension>
ModifiedTimeType itk::DisplacementFieldTransform< TParametersValueType, VDimension >::m_DisplacementFieldSetTime { 0 }
protected

Track when the displacement field was last set/assigned, as distinct from when it may have had its contents modified.

Definition at line 474 of file itkDisplacementFieldTransform.h.

◆ m_IdentityJacobian

template<typename TParametersValueType , unsigned int VDimension>
JacobianType itk::DisplacementFieldTransform< TParametersValueType, VDimension >::m_IdentityJacobian {}
protected

Create an identity jacobian for use in ComputeJacobianWithRespectToParameters.

Definition at line 478 of file itkDisplacementFieldTransform.h.

◆ m_Interpolator

template<typename TParametersValueType , unsigned int VDimension>
InterpolatorType::Pointer itk::DisplacementFieldTransform< TParametersValueType, VDimension >::m_Interpolator {}
protected

The interpolator.

Definition at line 469 of file itkDisplacementFieldTransform.h.

◆ m_InverseDisplacementField

template<typename TParametersValueType , unsigned int VDimension>
DisplacementFieldType::Pointer itk::DisplacementFieldTransform< TParametersValueType, VDimension >::m_InverseDisplacementField {}
protected

Definition at line 466 of file itkDisplacementFieldTransform.h.

◆ m_InverseInterpolator

template<typename TParametersValueType , unsigned int VDimension>
InterpolatorType::Pointer itk::DisplacementFieldTransform< TParametersValueType, VDimension >::m_InverseInterpolator {}
protected

Definition at line 470 of file itkDisplacementFieldTransform.h.


The documentation for this class was generated from the following file: