Medical Imaging Interaction Toolkit
2016.11.0
Medical Imaging Interaction Toolkit
|
Implementation of the anisotropic iterative closest point (A-ICP) algoritm. More...
#include <mitkAnisotropicIterativeClosestPointRegistration.h>
Public Member Functions | |
mitkClassMacroItkParent (AnisotropicIterativeClosestPointRegistration, itk::Object) static Pointer New() | |
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 () |
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 () | |
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) algoritm.
This class implements the anisotropic interative closest point (A-ICP) algorithm presented in 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 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 118 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
Definition of a correspondeces, index and distance.
Definition at line 130 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
Definition of a list of correspondences.
Definition at line 132 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
Definition of a 3x3 covariance matrix.
Definition at line 122 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
Definition of a list of covariance matrices.
Definition at line 124 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
Definition of a 3x3 rotation matrix.
Definition at line 128 of file mitkAnisotropicIterativeClosestPointRegistration.h.
Definition of a translation vector.
Definition at line 126 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
Definition at line 42 of file mitkAnisotropicIterativeClosestPointRegistration.cpp.
|
protected |
Definition at line 57 of file mitkAnisotropicIterativeClosestPointRegistration.cpp.
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. |
Definition at line 61 of file mitkAnisotropicIterativeClosestPointRegistration.cpp.
References mitk::AnisotropicRegistrationCommon::CalculateWeightMatrix(), max(), and mitk::New().
|
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 | |||
) |
|
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 298 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 286 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 maximim 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 precent 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. |
Definition at line 135 of file mitkAnisotropicIterativeClosestPointRegistration.cpp.
References mitk::ProgressBar::AddStepsToDo(), AICPComp, mitk::ProgressBar::GetInstance(), max(), MITK_DEBUG, mitkThrow, mitk::New(), mitk::ProgressBar::Progress(), mitk::AnisotropicRegistrationCommon::PropagateMatrices(), and mitk::AnisotropicRegistrationCommon::TransformPoints().
|
protected |
The covariance matrices belonging to the moving surface (Y).
Definition at line 175 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
The covariance matrices belonging to the moving surface (X).
Definition at line 172 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
The fixed / target surface.
Definition at line 166 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
The fiducial registration error (FRE).
Definition at line 155 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
Normalization factor for the feducial registration error. default is 0.0.
Definition at line 144 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
Max amount of iterations. Default is 1000.
Definition at line 138 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
The maximum number of iterations in the weighted point based registration. Default is 1000.
Definition at line 152 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
Moving surface that is transformed on the fixed surface.
Definition at line 164 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
Amount of iterations used by the algorithm.
Definition at line 161 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
The computed 3x3 rotation matrix.
Definition at line 180 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
Search radius for the correspondence search. Default is 30.
Definition at line 147 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
Threshold used for termination. Default is 1.0e-6.
Definition at line 141 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
The computed 3x1 translation vector.
Definition at line 178 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
Trimmfactor for partial overlapping registration. Default is 0.
Definition at line 158 of file mitkAnisotropicIterativeClosestPointRegistration.h.
|
protected |
The weighted point based registration algorithm.
Definition at line 169 of file mitkAnisotropicIterativeClosestPointRegistration.h.