Medical Imaging Interaction Toolkit
2024.12.99-0da743f6
Medical Imaging Interaction Toolkit
|
Implementation of the anisotropic iterative closest point (A-ICP) algorithm. More...
#include <mitkAnisotropicIterativeClosestPointRegistration.h>
Public Member Functions | |
mitkClassMacroItkParent (AnisotropicIterativeClosestPointRegistration, itk::Object) | |
Pointer | Clone () const |
virtual void | SetMaxIterations (unsigned int _arg) |
virtual void | SetThreshold (double _arg) |
virtual void | SetFRENormalizationFactor (double _arg) |
virtual void | SetSearchRadius (double _arg) |
virtual void | SetMaxIterationsInWeightedPointTransform (double _arg) |
virtual double | GetFRE () |
virtual unsigned int | GetNumberOfIterations () |
virtual void | SetTrimmFactor (double _arg) |
virtual void | SetMovingSurface (itk::SmartPointer< Surface > _arg) |
virtual void | SetFixedSurface (itk::SmartPointer< Surface > _arg) |
virtual const Translation & | GetTranslation () |
virtual const Rotation & | GetRotation () |
void | SetCovarianceMatricesMovingSurface (CovarianceMatrixList &list) |
void | SetCovarianceMatricesFixedSurface (CovarianceMatrixList &list) |
void | Update () |
Static Public Member Functions | |
static Pointer | New () |
Protected Types | |
typedef itk::Matrix< double, 3, 3 > | CovarianceMatrix |
typedef std::vector< CovarianceMatrix > | CovarianceMatrixList |
typedef mitk::Vector3D | Translation |
typedef CovarianceMatrix | Rotation |
typedef std::pair< unsigned int, double > | Correspondence |
typedef std::vector< Correspondence > | CorrespondenceList |
Protected Member Functions | |
AnisotropicIterativeClosestPointRegistration () | |
~AnisotropicIterativeClosestPointRegistration () override | |
void | ComputeCorrespondences (vtkPoints *X, vtkPoints *Z, vtkKdTreePointLocator *Y, const CovarianceMatrixList &sigma_X, const CovarianceMatrixList &sigma_Y, CovarianceMatrixList &sigma_Z, CorrespondenceList &correspondences, const double radius) |
Protected Attributes | |
unsigned int | m_MaxIterations |
double | m_Threshold |
double | m_FRENormalizationFactor |
double | m_SearchRadius |
double | m_MaxIterationsInWeightedPointTransform |
double | m_FRE |
double | m_TrimmFactor |
unsigned int | m_NumberOfIterations |
itk::SmartPointer< Surface > | m_MovingSurface |
itk::SmartPointer< Surface > | m_FixedSurface |
itk::SmartPointer< WeightedPointTransform > | m_WeightedPointTransform |
CovarianceMatrixList | m_CovarianceMatricesMovingSurface |
CovarianceMatrixList | m_CovarianceMatricesFixedSurface |
Translation | m_Translation |
Rotation | m_Rotation |
Implementation of the anisotropic iterative closest point (A-ICP) algorithm.
This class implements the anisotropic iterative closest point (A-ICP) algorithm presented in L. Maier-Hein et al. in "Convergent Iterative Closest-Point Algorithm to Accommodate Anisotropic and Inhomogenous Localization Error.", IEEE T Pattern Anal 34 (8), 1520-1532, 2012. The algorithm computes the optimal transformation to align two surfaces. In addition to the surfaces a list of covariance matrices is used as input for every surface. Each covariance matrix represents the error of a specific vertex in the Surface. The covariance matrices for each surface can be defined by the user, or calculated by the CovarianceMatrixCalculator. In addition a trimmed algorithm version is provided to compute the registration of partial overlapping surfaces. The algorithm needs a clean surface non manifold edges and without duplicated vertices. In addition vtkCleanPolyData can be used to ensure a correct Surface representation.
Example:
Definition at line 114 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
Definition of a correspondeces, index and distance.
Definition at line 126 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
Definition of a list of correspondences.
Definition at line 128 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
Definition of a 3x3 covariance matrix.
Definition at line 118 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
Definition of a list of covariance matrices.
Definition at line 120 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
Definition of a 3x3 rotation matrix.
Definition at line 124 of file mitkAnisotropicIterativeClosestPointRegistration.h.
Definition of a translation vector.
Definition at line 122 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
|
overrideprotected |
Pointer mitk::AnisotropicIterativeClosestPointRegistration::Clone | ( | ) | const |
|
protected |
Method that computes the correspondences between the moving point set X and the fixed point set Y. The distances between the points are weighted with weight matrices that are computed from the covariances along the surfaces axes. This method implements the runtime optimization presented by L. Maier-Hein et al.. The correspondences are computed with the help of a kd tree. The correspondences are searched in a given radius in the euklidian space. Every correspondence found in this radius is weighted based on the covariance matrices and the best weighting will be used as a correspondence.
X | The moving point set. |
Z | The returned correspondences from the fixed point set. |
Y | The fixed point set saved in a kd tree. |
sigma_X | Covariance matrices belonging to the moving point set. |
sigma_Y | Covariance matrices belonging to the fixed point set. |
sigma_Z | Covariance matrices belonging to the correspondences found. |
correspondences | Saved correspondences, in a pair containing the their index in Y and distance. |
radius | The search radius used in in kd tree. |
|
virtual |
Get the fiducial registration error (FRE).
|
virtual |
Get the number of iterations used by the algorithm.
|
virtual |
Returns the 3x3 rotation matrix computed by the algorithm.
|
virtual |
Returns the 3x1 translation vector computed by the algorithm.
mitk::AnisotropicIterativeClosestPointRegistration::mitkClassMacroItkParent | ( | AnisotropicIterativeClosestPointRegistration | , |
itk::Object | |||
) |
|
static |
|
inline |
Set the covariance matrices of the fixed surface. The algorithm need the same amount of covariance and points available in the surface. The covariance matrix for every vertex in a Surface can be calculated by the CovarianceMatrixCalculator. It is also possible to define arbitrary matrices by hand.
Definition at line 295 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
inline |
Set the covariance matrices of the moving surface. The algorithm need the same amount of covariance and points available in the surface. The covariance matrix for every vertex in a Surface can be calculated by the CovarianceMatrixCalculator. It is also possible to define arbitrary matrices by hand.
Definition at line 283 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
virtual |
Set fixed surface that includes the point set (Y).
|
virtual |
Set the normalization factor for the fiducial registration error (FRE). The normalization factor is computed with the help of the mean variance of both CovarianceMatrixList that can be obtained when the covariance matrices are calculated with the CovarianceMatrixCalculator:
if no FRE normalization is used the normalization factor is set to 1.0 as default value.
|
virtual |
Set the maximum amount of iterations used by the algorithm.
|
virtual |
Set the maximum number of iterations used by the point based registration algorithm.
|
virtual |
Set moving surface that includes the point set (X).
|
virtual |
Set search radius for the correspondence search.
|
virtual |
Set the threshold used to terminate the algorithm.
|
virtual |
Factor that trimms the point set in percent for partial overlapping surfaces. E.g. 0.4 will use 40 percent of the point set. To enable the trimmed version a factor > 0 and < 1 must be set. The default value is 0.0.
void mitk::AnisotropicIterativeClosestPointRegistration::Update | ( | ) |
This method executes the algorithm.
Exception | if the search radius was doubled more than 20 times to prevent endless loops. Re-run the with a different search radius that will find the correspondences. |
|
protected |
The covariance matrices belonging to the moving surface (Y).
Definition at line 171 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
The covariance matrices belonging to the moving surface (X).
Definition at line 168 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
The fixed / target surface.
Definition at line 162 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
The fiducial registration error (FRE).
Definition at line 151 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
Normalization factor for the feducial registration error. default is 0.0.
Definition at line 140 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
Max amount of iterations. Default is 1000.
Definition at line 134 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
The maximum number of iterations in the weighted point based registration. Default is 1000.
Definition at line 148 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
Moving surface that is transformed on the fixed surface.
Definition at line 160 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
Amount of iterations used by the algorithm.
Definition at line 157 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
The computed 3x3 rotation matrix.
Definition at line 176 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
Search radius for the correspondence search. Default is 30.
Definition at line 143 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
Threshold used for termination. Default is 1.0e-6.
Definition at line 137 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
The computed 3x1 translation vector.
Definition at line 174 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
Trimmfactor for partial overlapping registration. Default is 0.
Definition at line 154 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
The weighted point based registration algorithm.
Definition at line 165 of file mitkAnisotropicIterativeClosestPointRegistration.h.