go home Home | Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Data Structures | File List | Namespace Members | Data Fields | Globals | Related Pages
itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage > Class Template Reference

#include <itkCenteredTransformInitializer2.h>

Detailed Description

template<class TTransform, class TFixedImage, class TMovingImage>
class itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >

CenteredTransformInitializer2 is a helper class intended to initialize the center of rotation and the translation of Transforms having the center of rotation among their parameters.

This class is connected to the fixed image, moving image and transform involved in the registration. Three modes of operation are possible:

  • Geometrical,
  • Center of mass,
  • Origins,
  • GeometryTop

In the first mode, the geometrical center of the fixed image is passed as initial center of rotation to the transform and the vector from the center of the fixed image to the center of the moving image is passed as the initial translation. This mode basically assumes that the anatomical objects to be registered are centered in their respective images. Hence the best initial guess for the registration is the one that superimposes those two centers.

In the second mode, the moments of gray level values are computed for both images. The center of mass of the moving image is then used as center of rotation. The vector between the two centers of mass is passes as the initial translation to the transform. This second approach assumes that the moments of the anatomical objects are similar for both images and hence the best initial guess for registration is to superimpose both mass centers. Note that this assumption will probably not hold in multi-modality registration.

In the third mode, the vector from the coordinates (0,0,0) of the fixed image to the coordinates (0,0,0) of the moving image is passed as the initial translation T and the geometrical center of the moving image, translated by inv(T), is passed as initial center of rotation to the transform.

In the fourth mode, the world coordinates of the eight corner points of both images are determined. For both images, the minimum of the elements of world coordinates is taken and the initial translation is taken to be the vector pointing from the minimum coordinates of the fixed image to the minimum coordinates of the moving image. The rotation point is set to the center of the fixed image. Note that this method does not make sense for 2D images, in that case the result will be equal to Geometrical method.

Definition at line 91 of file itkCenteredTransformInitializer2.h.

Inheritance diagram for itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >:

Public Types

using ConstPointer = SmartPointer<const Self>
 
using FixedImageCalculatorPointer = typename FixedImageCalculatorType::Pointer
 
using FixedImageCalculatorType = AdvancedImageMomentsCalculator<FixedImageType>
 
using FixedImageMaskConstPointer = typename FixedImageMaskType::ConstPointer
 
using FixedImageMaskPointer = typename FixedImageMaskType::ConstPointer
 
using FixedImageMaskType = Image<unsigned char, InputSpaceDimension>
 
using FixedImagePointer = typename FixedImageType::ConstPointer
 
using FixedImageType = TFixedImage
 
using InputPixelType = typename FixedImageType::PixelType
 
using InputPointType = typename TransformType::InputPointType
 
using MovingImageCalculatorPointer = typename MovingImageCalculatorType::Pointer
 
using MovingImageCalculatorType = AdvancedImageMomentsCalculator<MovingImageType>
 
using MovingImageMaskConstPointer = typename MovingImageMaskType::ConstPointer
 
using MovingImageMaskPointer = typename MovingImageMaskType::ConstPointer
 
using MovingImageMaskType = Image<unsigned char, OutputSpaceDimension>
 
using MovingImagePointer = typename MovingImageType::ConstPointer
 
using MovingImageType = TMovingImage
 
using OffsetType = typename TransformType::OffsetType
 
using OutputVectorType = typename TransformType::OutputVectorType
 
using Pointer = SmartPointer<Self>
 
using Self = CenteredTransformInitializer2
 
using Superclass = Object
 
using TransformPointer = typename TransformType::Pointer
 
using TransformType = TTransform
 

Public Member Functions

void GeometryOn ()
 
void GeometryTopOn ()
 
virtual const char * GetClassName () const
 
virtual const FixedImageCalculatorTypeGetFixedCalculator ()
 
virtual const MovingImageCalculatorTypeGetMovingCalculator ()
 
virtual void InitializeTransform ()
 
 ITK_DISALLOW_COPY_AND_MOVE (CenteredTransformInitializer2)
 
 itkStaticConstMacro (InputSpaceDimension, unsigned int, TransformType::InputSpaceDimension)
 
 itkStaticConstMacro (OutputSpaceDimension, unsigned int, TransformType::OutputSpaceDimension)
 
void MomentsOn ()
 
void OriginsOn ()
 
virtual void SetCenterOfGravityUsesLowerThreshold (bool _arg)
 
virtual void SetFixedImage (const FixedImageType *_arg)
 
virtual void SetFixedImageMask (const FixedImageMaskType *_arg)
 
virtual void SetLowerThresholdForCenterGravity (InputPixelType _arg)
 
virtual void SetMovingImage (const MovingImageType *_arg)
 
virtual void SetMovingImageMask (const MovingImageMaskType *_arg)
 
virtual void SetNumberOfSamplesForCenteredTransformInitialization (SizeValueType _arg)
 
virtual void SetTransform (TransformType *_arg)
 

Static Public Member Functions

static Pointer New ()
 

Protected Member Functions

 CenteredTransformInitializer2 ()
 
 itkGetModifiableObjectMacro (Transform, TransformType)
 
void PrintSelf (std::ostream &os, Indent indent) const override
 
 ~CenteredTransformInitializer2 () override=default
 

Protected Attributes

bool m_CenterOfGravityUsesLowerThreshold {}
 
InputPixelType m_LowerThresholdForCenterGravity {}
 
SizeValueType m_NumberOfSamplesForCenteredTransformInitialization {}
 

Private Attributes

FixedImageCalculatorPointer m_FixedCalculator {}
 
FixedImagePointer m_FixedImage {}
 
FixedImageMaskPointer m_FixedImageMask {}
 
MovingImageCalculatorPointer m_MovingCalculator {}
 
MovingImagePointer m_MovingImage {}
 
MovingImageMaskPointer m_MovingImageMask {}
 
TransformPointer m_Transform {}
 
bool m_UseMoments {}
 
bool m_UseOrigins {}
 
bool m_UseTop {}
 

Member Typedef Documentation

◆ ConstPointer

template<class TTransform , class TFixedImage , class TMovingImage >
using itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::ConstPointer = SmartPointer<const Self>

Definition at line 100 of file itkCenteredTransformInitializer2.h.

◆ FixedImageCalculatorPointer

template<class TTransform , class TFixedImage , class TMovingImage >
using itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::FixedImageCalculatorPointer = typename FixedImageCalculatorType::Pointer

Definition at line 134 of file itkCenteredTransformInitializer2.h.

◆ FixedImageCalculatorType

template<class TTransform , class TFixedImage , class TMovingImage >
using itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::FixedImageCalculatorType = AdvancedImageMomentsCalculator<FixedImageType>

Moment calculators

Definition at line 131 of file itkCenteredTransformInitializer2.h.

◆ FixedImageMaskConstPointer

template<class TTransform , class TFixedImage , class TMovingImage >
using itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::FixedImageMaskConstPointer = typename FixedImageMaskType::ConstPointer

Definition at line 127 of file itkCenteredTransformInitializer2.h.

◆ FixedImageMaskPointer

template<class TTransform , class TFixedImage , class TMovingImage >
using itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::FixedImageMaskPointer = typename FixedImageMaskType::ConstPointer

Definition at line 125 of file itkCenteredTransformInitializer2.h.

◆ FixedImageMaskType

template<class TTransform , class TFixedImage , class TMovingImage >
using itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::FixedImageMaskType = Image<unsigned char, InputSpaceDimension>

Definition at line 123 of file itkCenteredTransformInitializer2.h.

◆ FixedImagePointer

template<class TTransform , class TFixedImage , class TMovingImage >
using itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::FixedImagePointer = typename FixedImageType::ConstPointer

Definition at line 120 of file itkCenteredTransformInitializer2.h.

◆ FixedImageType

template<class TTransform , class TFixedImage , class TMovingImage >
using itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::FixedImageType = TFixedImage

Image Types to use in the initialization of the transform

Definition at line 117 of file itkCenteredTransformInitializer2.h.

◆ InputPixelType

template<class TTransform , class TFixedImage , class TMovingImage >
using itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::InputPixelType = typename FixedImageType::PixelType

Definition at line 146 of file itkCenteredTransformInitializer2.h.

◆ InputPointType

template<class TTransform , class TFixedImage , class TMovingImage >
using itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::InputPointType = typename TransformType::InputPointType

Point type.

Definition at line 141 of file itkCenteredTransformInitializer2.h.

◆ MovingImageCalculatorPointer

template<class TTransform , class TFixedImage , class TMovingImage >
using itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::MovingImageCalculatorPointer = typename MovingImageCalculatorType::Pointer

Definition at line 135 of file itkCenteredTransformInitializer2.h.

◆ MovingImageCalculatorType

template<class TTransform , class TFixedImage , class TMovingImage >
using itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::MovingImageCalculatorType = AdvancedImageMomentsCalculator<MovingImageType>

Definition at line 132 of file itkCenteredTransformInitializer2.h.

◆ MovingImageMaskConstPointer

template<class TTransform , class TFixedImage , class TMovingImage >
using itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::MovingImageMaskConstPointer = typename MovingImageMaskType::ConstPointer

Definition at line 128 of file itkCenteredTransformInitializer2.h.

◆ MovingImageMaskPointer

template<class TTransform , class TFixedImage , class TMovingImage >
using itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::MovingImageMaskPointer = typename MovingImageMaskType::ConstPointer

Definition at line 126 of file itkCenteredTransformInitializer2.h.

◆ MovingImageMaskType

template<class TTransform , class TFixedImage , class TMovingImage >
using itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::MovingImageMaskType = Image<unsigned char, OutputSpaceDimension>

Definition at line 124 of file itkCenteredTransformInitializer2.h.

◆ MovingImagePointer

template<class TTransform , class TFixedImage , class TMovingImage >
using itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::MovingImagePointer = typename MovingImageType::ConstPointer

Definition at line 121 of file itkCenteredTransformInitializer2.h.

◆ MovingImageType

template<class TTransform , class TFixedImage , class TMovingImage >
using itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::MovingImageType = TMovingImage

Definition at line 118 of file itkCenteredTransformInitializer2.h.

◆ OffsetType

template<class TTransform , class TFixedImage , class TMovingImage >
using itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::OffsetType = typename TransformType::OffsetType

Offset type.

Definition at line 138 of file itkCenteredTransformInitializer2.h.

◆ OutputVectorType

template<class TTransform , class TFixedImage , class TMovingImage >
using itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::OutputVectorType = typename TransformType::OutputVectorType

Vector type.

Definition at line 144 of file itkCenteredTransformInitializer2.h.

◆ Pointer

template<class TTransform , class TFixedImage , class TMovingImage >
using itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::Pointer = SmartPointer<Self>

Definition at line 99 of file itkCenteredTransformInitializer2.h.

◆ Self

template<class TTransform , class TFixedImage , class TMovingImage >
using itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::Self = CenteredTransformInitializer2

Standard class typedefs.

Definition at line 97 of file itkCenteredTransformInitializer2.h.

◆ Superclass

template<class TTransform , class TFixedImage , class TMovingImage >
using itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::Superclass = Object

Definition at line 98 of file itkCenteredTransformInitializer2.h.

◆ TransformPointer

template<class TTransform , class TFixedImage , class TMovingImage >
using itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::TransformPointer = typename TransformType::Pointer

Definition at line 110 of file itkCenteredTransformInitializer2.h.

◆ TransformType

template<class TTransform , class TFixedImage , class TMovingImage >
using itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::TransformType = TTransform

Type of the transform to initialize

Definition at line 109 of file itkCenteredTransformInitializer2.h.

Constructor & Destructor Documentation

◆ CenteredTransformInitializer2()

template<class TTransform , class TFixedImage , class TMovingImage >
itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::CenteredTransformInitializer2 ( )
protected

◆ ~CenteredTransformInitializer2()

template<class TTransform , class TFixedImage , class TMovingImage >
itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::~CenteredTransformInitializer2 ( )
overrideprotecteddefault

Member Function Documentation

◆ GeometryOn()

template<class TTransform , class TFixedImage , class TMovingImage >
void itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::GeometryOn ( )
inline

Select between using the geometrical center of the images or using the center of mass given by the image intensities.

Definition at line 173 of file itkCenteredTransformInitializer2.h.

◆ GeometryTopOn()

template<class TTransform , class TFixedImage , class TMovingImage >
void itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::GeometryTopOn ( )
inline

Definition at line 194 of file itkCenteredTransformInitializer2.h.

◆ GetClassName()

template<class TTransform , class TFixedImage , class TMovingImage >
virtual const char * itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::GetClassName ( ) const
virtual

Run-time type information (and related methods).

◆ GetFixedCalculator()

template<class TTransform , class TFixedImage , class TMovingImage >
virtual const FixedImageCalculatorType * itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::GetFixedCalculator ( )
virtual

Get() access to the moments calculators

◆ GetMovingCalculator()

template<class TTransform , class TFixedImage , class TMovingImage >
virtual const MovingImageCalculatorType * itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::GetMovingCalculator ( )
virtual

◆ InitializeTransform()

template<class TTransform , class TFixedImage , class TMovingImage >
virtual void itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::InitializeTransform ( )
virtual

Initialize the transform using data from the images

◆ ITK_DISALLOW_COPY_AND_MOVE()

template<class TTransform , class TFixedImage , class TMovingImage >
itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::ITK_DISALLOW_COPY_AND_MOVE ( CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage > )

◆ itkGetModifiableObjectMacro()

template<class TTransform , class TFixedImage , class TMovingImage >
itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::itkGetModifiableObjectMacro ( Transform ,
TransformType  )
protected

◆ itkStaticConstMacro() [1/2]

template<class TTransform , class TFixedImage , class TMovingImage >
itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::itkStaticConstMacro ( InputSpaceDimension ,
unsigned int ,
TransformType::InputSpaceDimension  )

Dimension of parameters.

◆ itkStaticConstMacro() [2/2]

template<class TTransform , class TFixedImage , class TMovingImage >
itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::itkStaticConstMacro ( OutputSpaceDimension ,
unsigned int ,
TransformType::OutputSpaceDimension  )

◆ MomentsOn()

template<class TTransform , class TFixedImage , class TMovingImage >
void itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::MomentsOn ( )
inline

Definition at line 180 of file itkCenteredTransformInitializer2.h.

◆ New()

template<class TTransform , class TFixedImage , class TMovingImage >
static Pointer itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::New ( )
static

New macro for creation of through a Smart Pointer.

◆ OriginsOn()

template<class TTransform , class TFixedImage , class TMovingImage >
void itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::OriginsOn ( )
inline

Definition at line 187 of file itkCenteredTransformInitializer2.h.

◆ PrintSelf()

template<class TTransform , class TFixedImage , class TMovingImage >
void itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::PrintSelf ( std::ostream & os,
Indent indent ) const
overrideprotected

◆ SetCenterOfGravityUsesLowerThreshold()

template<class TTransform , class TFixedImage , class TMovingImage >
virtual void itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::SetCenterOfGravityUsesLowerThreshold ( bool _arg)
virtual

◆ SetFixedImage()

template<class TTransform , class TFixedImage , class TMovingImage >
virtual void itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::SetFixedImage ( const FixedImageType * _arg)
virtual

Set the fixed image used in the registration process

◆ SetFixedImageMask()

template<class TTransform , class TFixedImage , class TMovingImage >
virtual void itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::SetFixedImageMask ( const FixedImageMaskType * _arg)
virtual

Mask support.

◆ SetLowerThresholdForCenterGravity()

template<class TTransform , class TFixedImage , class TMovingImage >
virtual void itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::SetLowerThresholdForCenterGravity ( InputPixelType _arg)
virtual

◆ SetMovingImage()

template<class TTransform , class TFixedImage , class TMovingImage >
virtual void itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::SetMovingImage ( const MovingImageType * _arg)
virtual

Set the moving image used in the registration process

◆ SetMovingImageMask()

template<class TTransform , class TFixedImage , class TMovingImage >
virtual void itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::SetMovingImageMask ( const MovingImageMaskType * _arg)
virtual

◆ SetNumberOfSamplesForCenteredTransformInitialization()

template<class TTransform , class TFixedImage , class TMovingImage >
virtual void itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::SetNumberOfSamplesForCenteredTransformInitialization ( SizeValueType _arg)
virtual

Settings for MomentsCalculator.

◆ SetTransform()

template<class TTransform , class TFixedImage , class TMovingImage >
virtual void itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::SetTransform ( TransformType * _arg)
virtual

Set the transform to be initialized

Field Documentation

◆ m_CenterOfGravityUsesLowerThreshold

template<class TTransform , class TFixedImage , class TMovingImage >
bool itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::m_CenterOfGravityUsesLowerThreshold {}
protected

Definition at line 217 of file itkCenteredTransformInitializer2.h.

◆ m_FixedCalculator

template<class TTransform , class TFixedImage , class TMovingImage >
FixedImageCalculatorPointer itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::m_FixedCalculator {}
private

Definition at line 231 of file itkCenteredTransformInitializer2.h.

◆ m_FixedImage

template<class TTransform , class TFixedImage , class TMovingImage >
FixedImagePointer itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::m_FixedImage {}
private

Definition at line 222 of file itkCenteredTransformInitializer2.h.

◆ m_FixedImageMask

template<class TTransform , class TFixedImage , class TMovingImage >
FixedImageMaskPointer itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::m_FixedImageMask {}
private

Definition at line 224 of file itkCenteredTransformInitializer2.h.

◆ m_LowerThresholdForCenterGravity

template<class TTransform , class TFixedImage , class TMovingImage >
InputPixelType itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::m_LowerThresholdForCenterGravity {}
protected

Definition at line 216 of file itkCenteredTransformInitializer2.h.

◆ m_MovingCalculator

template<class TTransform , class TFixedImage , class TMovingImage >
MovingImageCalculatorPointer itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::m_MovingCalculator {}
private

Definition at line 232 of file itkCenteredTransformInitializer2.h.

◆ m_MovingImage

template<class TTransform , class TFixedImage , class TMovingImage >
MovingImagePointer itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::m_MovingImage {}
private

Definition at line 223 of file itkCenteredTransformInitializer2.h.

◆ m_MovingImageMask

template<class TTransform , class TFixedImage , class TMovingImage >
MovingImageMaskPointer itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::m_MovingImageMask {}
private

Definition at line 225 of file itkCenteredTransformInitializer2.h.

◆ m_NumberOfSamplesForCenteredTransformInitialization

template<class TTransform , class TFixedImage , class TMovingImage >
SizeValueType itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::m_NumberOfSamplesForCenteredTransformInitialization {}
protected

Settings for MomentsCalculator.

Definition at line 215 of file itkCenteredTransformInitializer2.h.

◆ m_Transform

template<class TTransform , class TFixedImage , class TMovingImage >
TransformPointer itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::m_Transform {}
private

Definition at line 220 of file itkCenteredTransformInitializer2.h.

◆ m_UseMoments

template<class TTransform , class TFixedImage , class TMovingImage >
bool itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::m_UseMoments {}
private

Definition at line 227 of file itkCenteredTransformInitializer2.h.

◆ m_UseOrigins

template<class TTransform , class TFixedImage , class TMovingImage >
bool itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::m_UseOrigins {}
private

Definition at line 228 of file itkCenteredTransformInitializer2.h.

◆ m_UseTop

template<class TTransform , class TFixedImage , class TMovingImage >
bool itk::CenteredTransformInitializer2< TTransform, TFixedImage, TMovingImage >::m_UseTop {}
private

Definition at line 229 of file itkCenteredTransformInitializer2.h.



Generated on 2024-07-17 for elastix by doxygen 1.11.0 (9b424b03c9833626cd435af22a444888fbbb192d) elastix logo