Medical Imaging Interaction Toolkit  2016.11.0
Medical Imaging Interaction Toolkit
mitk::WeightedPointTransform Class Reference

This class implements an extension of the weighted point based registration algorithm from A. Danilchenko, R. Balachandran and J. M. Fitzpatrick. More...

#include <mitkWeightedPointTransform.h>

Inheritance diagram for mitk::WeightedPointTransform:
Collaboration diagram for mitk::WeightedPointTransform:

Public Member Functions

 mitkClassMacroItkParent (WeightedPointTransform, itk::Object)
 
Pointer Clone () const
 
void ComputeTransformation ()
 Method which registers both point sets. More...
 
virtual void SetThreshold (double _arg)
 Sets the threshold of the registration. Default value is 0.0001. More...
 
virtual void SetMaxIterations (double _arg)
 Sets the maximum number of iterations of the registration. Default value is 1000. More...
 
virtual int GetIterations ()
 
virtual double GetFRE ()
 
virtual void SetFRENormalizationFactor (double _arg)
 Sets the FRE normalization factor. Default value is 1.0. More...
 
virtual double GetFRENormalizationFactor ()
 
void SetMovingPointSet (vtkSmartPointer< vtkPoints > p)
 
void SetCovarianceMatricesMoving (const CovarianceMatrixList &matrices)
 
void SetFixedPointSet (vtkSmartPointer< vtkPoints > p)
 
void SetCovarianceMatricesFixed (const CovarianceMatrixList &matrices)
 
const Translation & GetTransformT () const
 
const Rotation & GetTransformR () const
 

Static Public Member Functions

static Pointer New ()
 

Protected Member Functions

 WeightedPointTransform ()
 
 ~WeightedPointTransform ()
 
void C_maker (vtkPoints *X, const WeightMatrixList &W, itk::VariableSizeMatrix< double > &returnValue)
 
void E_maker (vtkPoints *X, vtkPoints *Y, const WeightMatrixList &W, vnl_vector< double > &returnValue)
 
double CalculateConfigChange (vtkPoints *X, vtkPoints *X_new)
 
void WeightedPointRegister (vtkPoints *X, vtkPoints *Y, const CovarianceMatrixList &Sigma_X, const CovarianceMatrixList &Sigma_Y, double Threshold, int MaxIterations, Rotation &TransformationR, Translation &TransformationT, double &FRE, int &n)
 This method performs a variant of the weighted point register algorithm presented by A. Danilchenko, R. Balachandran and J. M. Fitzpatrick in January 2010. (Modified in January 2011) converted to C++ by Alfred Franz in March/April 2010. More...
 

Protected Attributes

double m_Threshold
 
int m_MaxIterations
 
int m_Iterations
 
double m_FRE
 
double m_FRENormalizationFactor
 
vtkSmartPointer< vtkLandmarkTransform > m_LandmarkTransform
 
vtkSmartPointer< vtkPoints > m_FixedPointSet
 
vtkSmartPointer< vtkPoints > m_MovingPointSet
 
CovarianceMatrixList m_CovarianceMatricesMoving
 
CovarianceMatrixList m_CovarianceMatricesFixed
 
Translation m_Translation
 
Rotation m_Rotation
 

Detailed Description

This class implements an extension of the weighted point based registration algorithm from A. Danilchenko, R. Balachandran and J. M. Fitzpatrick.

The class implements an extension of the weighted point based registration from A. Danilchenko et al. presented by L. Maier-Hein et al. in "Convergent Iterative Closest-Point Algorithm to Accomodate Anisotropic and Inhomogenous Localization Error.", IEEE T Pattern Anal 34 (8), 1520-1532, 2012. The extension computes, in order to ensure the convergence of the algorithm, an isotropic estimation by an unweighted point based registration algorithm as an initial estimate. The implemantion was originally ported to C/C++ by A. Franz.

Note
Some methods are accelerated when OpenMP is enabled.

Definition at line 56 of file mitkWeightedPointTransform.h.

Constructor & Destructor Documentation

mitk::WeightedPointTransform::WeightedPointTransform ( )
protected

Definition at line 51 of file mitkWeightedPointTransform.cpp.

mitk::WeightedPointTransform::~WeightedPointTransform ( )
protected

Definition at line 61 of file mitkWeightedPointTransform.cpp.

Member Function Documentation

void mitk::WeightedPointTransform::C_maker ( vtkPoints *  X,
const WeightMatrixList &  W,
itk::VariableSizeMatrix< double > &  returnValue 
)
protected

original matlab-function:

Constructs the C matrix of the linear version of the registration problem, Cq = e, where q = [delta_angle(1:3),delta_translation(1:3)] and e is produced by e_maker(X,Y,W)

Authors: JM Fitzpatrick and R Balachandran Creation: February 2009


converted to C++ by Alfred Franz in March/April 2010

Definition at line 167 of file mitkWeightedPointTransform.cpp.

double mitk::WeightedPointTransform::CalculateConfigChange ( vtkPoints *  X,
vtkPoints *  X_new 
)
protected

This method computes the change in a root mean squared sense between the previous and the actual iteration. The computed value is used as a termination constraint of the algorithm and compared against the threshold.

Parameters
XThe moving point set in the previous iteration step.
X_newThe moving point set in the actual step.
Returns
The computed change between the two point sets.

Definition at line 417 of file mitkWeightedPointTransform.cpp.

Pointer mitk::WeightedPointTransform::Clone ( ) const
void mitk::WeightedPointTransform::ComputeTransformation ( )

Method which registers both point sets.

Definition at line 68 of file mitkWeightedPointTransform.cpp.

void mitk::WeightedPointTransform::E_maker ( vtkPoints *  X,
vtkPoints *  Y,
const WeightMatrixList &  W,
vnl_vector< double > &  returnValue 
)
protected

original matlab-function:

Constructs the e vector of the linear version of the registration problem, Cq = e, where q = [delta_angle(1:3),delta_translation(1:3)] and C is produced by C_maker(X,W)

Authors: JM Fitzpatrick and R Balachandran Creation: February 2009


converted to C++ by Alfred Franz in March/April 2010

Definition at line 191 of file mitkWeightedPointTransform.cpp.

virtual double mitk::WeightedPointTransform::GetFRE ( )
virtual
Returns
Returns the FRE of the last run of the registration algorithm. Returns -1 if there was no run of the registration yet.
virtual double mitk::WeightedPointTransform::GetFRENormalizationFactor ( )
virtual
Returns
Returns the current FRE normalization factor.
virtual int mitk::WeightedPointTransform::GetIterations ( )
virtual
Returns
Returns the number of iterations of the last run of the registration algorithm. Returns -1 if there was no run of the registration yet.
const Rotation& mitk::WeightedPointTransform::GetTransformR ( ) const
inline

The rotation matrix computed by the algorithm.

Definition at line 134 of file mitkWeightedPointTransform.h.

const Translation& mitk::WeightedPointTransform::GetTransformT ( ) const
inline

The translation vector computed by the algorithm.

Returns
3x1 translation vector.

Definition at line 130 of file mitkWeightedPointTransform.h.

mitk::WeightedPointTransform::mitkClassMacroItkParent ( WeightedPointTransform  ,
itk::Object   
)
static Pointer mitk::WeightedPointTransform::New ( )
static
void mitk::WeightedPointTransform::SetCovarianceMatricesFixed ( const CovarianceMatrixList &  matrices)

Set the list of 3x3 covariance matrices belonging to the fixed point set.

Parameters
matricesList of covariance matrices.

Definition at line 412 of file mitkWeightedPointTransform.cpp.

void mitk::WeightedPointTransform::SetCovarianceMatricesMoving ( const CovarianceMatrixList &  matrices)

Set the list of 3x3 covariance matrices belonging to the moving point set.

Parameters
matricesList of covariance matrices.

Definition at line 402 of file mitkWeightedPointTransform.cpp.

void mitk::WeightedPointTransform::SetFixedPointSet ( vtkSmartPointer< vtkPoints >  p)

Sets the fixed point set used for the registration.

Parameters
pThe input point set.

Definition at line 407 of file mitkWeightedPointTransform.cpp.

virtual void mitk::WeightedPointTransform::SetFRENormalizationFactor ( double  _arg)
virtual

Sets the FRE normalization factor. Default value is 1.0.

virtual void mitk::WeightedPointTransform::SetMaxIterations ( double  _arg)
virtual

Sets the maximum number of iterations of the registration. Default value is 1000.

void mitk::WeightedPointTransform::SetMovingPointSet ( vtkSmartPointer< vtkPoints >  p)

Sets the moving point set used for the registration.

Parameters
pThe input point set.

Definition at line 397 of file mitkWeightedPointTransform.cpp.

virtual void mitk::WeightedPointTransform::SetThreshold ( double  _arg)
virtual

Sets the threshold of the registration. Default value is 0.0001.

void mitk::WeightedPointTransform::WeightedPointRegister ( vtkPoints *  X,
vtkPoints *  Y,
const CovarianceMatrixList &  Sigma_X,
const CovarianceMatrixList &  Sigma_Y,
double  Threshold,
int  MaxIterations,
Rotation &  TransformationR,
Translation &  TransformationT,
double &  FRE,
int &  n 
)
protected

This method performs a variant of the weighted point register algorithm presented by A. Danilchenko, R. Balachandran and J. M. Fitzpatrick in January 2010. (Modified in January 2011) converted to C++ by Alfred Franz in March/April 2010.

Parameters
X(input) the moving point set
Y(input) the fixed (static) point set
Sigma_X(input) a 3-by-3-by-N array, each page containing the weighting matrix for the Nth pair of points in X
Sigma_Y(input) a 3-by-3-by-N array, each page containing the weighting matrix for the Nth pair of points in Y
Threshold(input) the relative size of the change to the moving set above which the iteration continues
MaxIterations(input) the maximum number of iterations allowed
Threshold(input) the threshold used to terminate the algorithm
TransformationR(output) this variable will hold the computed rotation matrix
TransformationT(output) this variable will hold the computed translation vector
FRE(output) this variable will hold the computed rotation FRE of the transformation
n(output) this variable will hold the number of iterations used by the algorithm

Definition at line 224 of file mitkWeightedPointTransform.cpp.

References calculateWeightMatrices(), ComputeWeightedFRE(), IsotropicRegistration(), max(), MITK_DEBUG, MITK_WARN, mitk::New(), and mitk::AnisotropicRegistrationCommon::TransformPoints().

Member Data Documentation

CovarianceMatrixList mitk::WeightedPointTransform::m_CovarianceMatricesFixed
protected

Covariance matrices of the moving point set (Sigma_Y).

Definition at line 167 of file mitkWeightedPointTransform.h.

CovarianceMatrixList mitk::WeightedPointTransform::m_CovarianceMatricesMoving
protected

Covariance matrices of the moving point set (Sigma_X).

Definition at line 164 of file mitkWeightedPointTransform.h.

vtkSmartPointer<vtkPoints> mitk::WeightedPointTransform::m_FixedPointSet
protected

The fixed point set (Y).

Definition at line 158 of file mitkWeightedPointTransform.h.

double mitk::WeightedPointTransform::m_FRE
protected

The fiducial registration error (FRE) used in the algorithm.

Definition at line 149 of file mitkWeightedPointTransform.h.

double mitk::WeightedPointTransform::m_FRENormalizationFactor
protected

Normalization factor for the FRE.

Definition at line 152 of file mitkWeightedPointTransform.h.

int mitk::WeightedPointTransform::m_Iterations
protected

The amount of iterations needed by the algorithm.

Definition at line 146 of file mitkWeightedPointTransform.h.

vtkSmartPointer<vtkLandmarkTransform> mitk::WeightedPointTransform::m_LandmarkTransform
protected

Isotropic point based registration used for initial estimate.

Definition at line 155 of file mitkWeightedPointTransform.h.

int mitk::WeightedPointTransform::m_MaxIterations
protected

Max allowed iterations used by the algorithm.

Definition at line 143 of file mitkWeightedPointTransform.h.

vtkSmartPointer<vtkPoints> mitk::WeightedPointTransform::m_MovingPointSet
protected

Moving point set (X).

Definition at line 161 of file mitkWeightedPointTransform.h.

Rotation mitk::WeightedPointTransform::m_Rotation
protected

3x3 rotation matrix.

Definition at line 173 of file mitkWeightedPointTransform.h.

double mitk::WeightedPointTransform::m_Threshold
protected

Threshold used to terminate the algorithm.

Definition at line 140 of file mitkWeightedPointTransform.h.

Translation mitk::WeightedPointTransform::m_Translation
protected

3x1 translation vector.

Definition at line 170 of file mitkWeightedPointTransform.h.


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