Point-set registration
In
As a special case, registration of two point sets that only differ by a 3D rotation (i.e., there is no scaling and translation), is called the Wahba Problem and also related to the orthogonal procrustes problem.
Formulation
The problem may be summarized as follows:[11] Let be two finite size point sets
-
(1)
The output of a point set registration algorithm is therefore the optimal transformation such that is best aligned to , according to some defined notion of distance function :
-
(2)
where is used to denote the set of all possible transformations that the optimization tries to search for. The most popular choice of the distance function is to take the square of the Euclidean distance for every pair of points:
-
(3)
where denotes the vector 2-norm, is the
Types of algorithms
When the correspondences (i.e., ) are given before the optimization, for example, using
Rigid registration
Given two point sets, rigid registration yields a rigid transformation which maps one point set to the other. A rigid transformation is defined as a transformation that does not change the distance between any two points. Typically such a transformation consists of translation and rotation.[12] In rare cases, the point set may also be mirrored. In robotics and computer vision, rigid registration has the most applications.
Non-rigid registration
Given two point sets, non-rigid registration yields a non-rigid transformation which maps one point set to the other. Non-rigid transformations include
Other types
Some approaches to point set registration use algorithms that solve the more general graph matching problem.[11] However, the computational complexity of such methods tend to be high and they are limited to rigid registrations. In this article, we will only consider algorithms for rigid registration, where the transformation is assumed to contain 3D rotations and translations (possibly also including a uniform scaling).
The
Correspondence-based registration
Correspondence-based methods assume the putative correspondences are given for every point . Therefore, we arrive at a setting where both point sets and have points and the correspondences are given.
Outlier-free registration
In the simplest case, one can assume that all the correspondences are correct, meaning that the points are generated as follows:
-
(cb.1)
where is a uniform scaling factor (in many cases is assumed), is a proper 3D rotation matrix ( is the
-
(cb.2)
Note that when the scaling factor is 1 and the translation vector is zero, then the optimization recovers the formulation of the Wahba problem. Despite the non-convexity of the optimization (cb.2) due to non-convexity of the set , seminal work by Berthold K.P. Horn showed that (cb.2) actually admits a closed-form solution, by decoupling the estimation of scale, rotation and translation.[16] Similar results were discovered by Arun et al.[17] In addition, in order to find a unique transformation , at least non-collinear points in each point set are required.
More recently, Briales and Gonzalez-Jimenez have developed a semidefinite relaxation using Lagrangian duality, for the case where the model set contains different 3D primitives such as points, lines and planes (which is the case when the model is a 3D mesh).
Robust registration
The least squares formulation (cb.2) is known to perform arbitrarily badly in the presence of outliers. An outlier correspondence is a pair of measurements that departs from the generative model (cb.1). In this case, one can consider a different generative model as follows:[19]
-
(cb.3)
where if the th pair is an inlier, then it obeys the outlier-free model (cb.1), i.e., is obtained from by a spatial transformation plus some small noise; however, if the th pair is an outlier, then can be any arbitrary vector . Since one does not know which correspondences are outliers beforehand, robust registration under the generative model (cb.3) is of paramount importance for computer vision and robotics deployed in the real world, because current feature matching techniques tend to output highly corrupted correspondences where over of the correspondences can be outliers.[20]
Next, we describe several common paradigms for robust registration.
Maximum consensus
Maximum consensus seeks to find the largest set of correspondences that are consistent with the generative model (cb.1) for some choice of spatial transformation . Formally speaking, maximum consensus solves the following optimization:
-
(cb.4)
where denotes the cardinality of the set . The constraint in (cb.4) enforces that every pair of measurements in the inlier set must have
Although solving consensus maximization exactly is hard, there exist efficient heuristics that perform quite well in practice. One of the most popular heuristics is the Random Sample Consensus (RANSAC) scheme.[26] RANSAC is an iterative hypothesize-and-verify method. At each iteration, the method first randomly samples 3 out of the total number of correspondences and computes a hypothesis using Horn's method,[16] then the method evaluates the constraints in (cb.4) to count how many correspondences actually agree with such a hypothesis (i.e., it computes the residual and compares it with the threshold for each pair of measurements). The algorithm terminates either after it has found a consensus set that has enough correspondences, or after it has reached the total number of allowed iterations. RANSAC is highly efficient because the main computation of each iteration is carrying out the closed-form solution in Horn's method. However, RANSAC is non-deterministic and only works well in the low-outlier-ratio regime (e.g., below ), because its runtime grows exponentially with respect to the outlier ratio.[20]
To fill the gap between the fast but inexact RANSAC scheme and the exact but exhaustive BnB optimization, recent researches have developed deterministic approximate methods to solve consensus maximization.[21][22][27][23]
Outlier removal
Outlier removal methods seek to pre-process the set of highly corrupted correspondences before estimating the spatial transformation. The motivation of outlier removal is to significantly reduce the number of outlier correspondences, while maintaining inlier correspondences, so that optimization over the transformation becomes easier and more efficient (e.g., RANSAC works poorly when the outlier ratio is above but performs quite well when outlier ratio is below ).
Parra et al. have proposed a method called Guaranteed Outlier Removal (GORE) that uses geometric constraints to prune outlier correspondences while guaranteeing to preserve inlier correspondences.[20] GORE has been shown to be able to drastically reduce the outlier ratio, which can significantly boost the performance of consensus maximization using RANSAC or BnB. Yang and Carlone have proposed to build pairwise translation-and-rotation-invariant measurements (TRIMs) from the original set of measurements and embed TRIMs as the edges of a graph whose nodes are the 3D points. Since inliers are pairwise consistent in terms of the scale, they must form a clique within the graph. Therefore, using efficient algorithms for computing the maximum clique of a graph can find the inliers and effectively prune the outliers.[4] The maximum clique based outlier removal method is also shown to be quite useful in real-world point set registration problems.[19] Similar outlier removal ideas were also proposed by Parra et al..[28]
M-estimation
-
(cb.5)
where represents the choice of the robust cost function. Note that choosing recovers the least squares estimation in (cb.2). Popular robust cost functions include -norm loss, Huber loss,[29] Geman-McClure loss[30] and truncated least squares loss.[19][8][4] M-estimation has been one of the most popular paradigms for robust estimation in robotics and computer vision.[31][32] Because robust objective functions are typically non-convex (e.g., the truncated least squares loss v.s. the least squares loss), algorithms for solving the non-convex M-estimation are typically based on local optimization, where first an initial guess is provided, following by iterative refinements of the transformation to keep decreasing the objective function. Local optimization tends to work well when the initial guess is close to the global minimum, but it is also prone to get stuck in local minima if provided with poor initialization.
Graduated non-convexity
Graduated non-convexity (GNC) is a general-purpose framework for solving non-convex optimization problems without initialization. It has achieved success in early vision and machine learning applications.[33][34] The key idea behind GNC is to solve the hard non-convex problem by starting from an easy convex problem. Specifically, for a given robust cost function , one can construct a surrogate function with a hyper-parameter , tuning which can gradually increase the non-convexity of the surrogate function until it converges to the target function .[34][35] Therefore, at each level of the hyper-parameter , the following optimization is solved:
-
(cb.6)
Black and Rangarajan proved that the objective function of each optimization (cb.6) can be dualized into a sum of weighted least squares and a so-called outlier process function on the weights that determine the confidence of the optimization in each pair of measurements.[33] Using Black-Rangarajan duality and GNC tailored for the Geman-McClure function, Zhou et al. developed the fast global registration algorithm that is robust against about outliers in the correspondences.[30] More recently, Yang et al. showed that the joint use of GNC (tailored to the Geman-McClure function and the truncated least squares function) and Black-Rangarajan duality can lead to a general-purpose solver for robust registration problems, including point clouds and mesh registration.[35]
Certifiably robust registration
Almost none of the robust registration algorithms mentioned above (except the BnB algorithm that runs in exponential-time in the worst case) comes with performance guarantees, which means that these algorithms can return completely incorrect estimates without notice. Therefore, these algorithms are undesirable for safety-critical applications like autonomous driving.
Very recently, Yang et al. has developed the first certifiably robust registration algorithm, named Truncated least squares Estimation And SEmidefinite Relaxation (TEASER).[19] For point cloud registration, TEASER not only outputs an estimate of the transformation, but also quantifies the optimality of the given estimate. TEASER adopts the following truncated least squares (TLS) estimator:
-
(cb.7)
which is obtained by choosing the TLS robust cost function , where is a pre-defined constant that determines the maximum allowed residuals to be considered inliers. The TLS objective function has the property that for inlier correspondences (), the usual least square penalty is applied; while for outlier correspondences (), no penalty is applied and the outliers are discarded. If the TLS optimization (cb.7) is solved to global optimality, then it is equivalent to running Horn's method on only the inlier correspondences.
However, solving (cb.7) is quite challenging due to its combinatorial nature. TEASER solves (cb.7) as follows : (i) It builds invariant measurements such that the estimation of scale, rotation and translation can be decoupled and solved separately, a strategy that is inspired by the original Horn's method; (ii) The same TLS estimation is applied for each of the three sub-problems, where the scale TLS problem can be solved exactly using an algorithm called adaptive voting, the rotation TLS problem can relaxed to a semidefinite program (SDP) where the relaxation is exact in practice,[8] even with large amount of outliers; the translation TLS problem can solved using component-wise adaptive voting. A fast implementation leveraging GNC is open-sourced here. In practice, TEASER can tolerate more than outlier correspondences and runs in milliseconds.
In addition to developing TEASER, Yang et al. also prove that, under some mild conditions on the point cloud data, TEASER's estimated transformation has bounded errors from the ground-truth transformation.[19]
Simultaneous pose and correspondence registration
Iterative closest point
The iterative closest point (ICP) algorithm was introduced by Besl and McKay.[36] The algorithm performs rigid registration in an iterative fashion by alternating in (i) given the transformation, finding the closest point in for every point in ; and (ii) given the correspondences, finding the best rigid transformation by solving the least squares problem (cb.2). As such, it works best if the initial pose of is sufficiently close to . In pseudocode, the basic algorithm is implemented as follows:
algorithm ICP(M, S) θ := θ0 while not registered: X := ∅ for mi ∊ T(M, θ): ŝi := closest point in S to mi X := X + ⟨mi, ŝi⟩ θ := least_squares(X) return θ
Here, the function least_squares
performs least squares optimization to minimize the distance in each of the pairs, using the closed-form solutions by Horn[16] and Arun.[17]
Because the cost function of registration depends on finding the closest point in to every point in , it can change as the algorithm is running. As such, it is difficult to prove that ICP will in fact converge exactly to the local optimum.[37] In fact, empirically, ICP and EM-ICP do not converge to the local minimum of the cost function.[37] Nonetheless, because ICP is intuitive to understand and straightforward to implement, it remains the most commonly used point set registration algorithm.[37] Many variants of ICP have been proposed, affecting all phases of the algorithm from the selection and matching of points to the minimization strategy.[13][38] For example, the
Robust point matching
Robust point matching (RPM) was introduced by Gold et al.
-
(rpm.1)
The problem is then defined as: Given two point sets and find the Affine transformation and the match matrix that best relates them.[39] Knowing the optimal transformation makes it easy to determine the match matrix, and vice versa. However, the RPM algorithm determines both simultaneously. The transformation may be decomposed into a translation vector and a transformation matrix:
The matrix in 2D is composed of four separate parameters , which are scale, rotation, and the vertical and horizontal shear components respectively. The cost function is then:
-
(rpm.2)
subject to , , . The term biases the objective towards stronger correlation by decreasing the cost if the match matrix has more ones in it. The function serves to regularize the Affine transformation by penalizing large values of the scale and shear components:
for some regularization parameter .
The RPM method optimizes the cost function using the Softassign algorithm. The 1D case will be derived here. Given a set of variables where . A variable is associated with each such that . The goal is to find that maximizes . This can be formulated as a continuous problem by introducing a control parameter . In the
-
(rpm.3)
this is known as the softmax function. As increases, it approaches a binary value as desired in Equation (rpm.1). The problem may now be generalized to the 2D case, where instead of maximizing , the following is maximized:
-
(rpm.4)
where
This is straightforward, except that now the constraints on are doubly stochastic matrix constraints: and . As such the denominator from Equation (rpm.3) cannot be expressed for the 2D case simply. To satisfy the constraints, it is possible to use a result due to Sinkhorn,[39] which states that a doubly stochastic matrix is obtained from any square matrix with all positive entries by the iterative process of alternating row and column normalizations. Thus the algorithm is written as such:[39]
algorithm RPM2D t := 0 a, θ b, c := 0 β := β0 while β < βf: while μ has not converged: // update correspondence parameters by softassign // apply Sinkhorn's method while has not converged: // update by normalizing across all rows: // update by normalizing across all columns: // update pose parameters by coordinate descent update θ using analytical solution update t using analytical solution update a, b, c using Newton's method return a, b, c, θ and t
where the deterministic annealing control parameter is initially set to and increases by factor until it reaches the maximum value . The summations in the normalization steps sum to and instead of just and because the constraints on are inequalities. As such the th and th elements are slack variables.
The algorithm can also be extended for point sets in 3D or higher dimensions. The constraints on the correspondence matrix are the same in the 3D case as in the 2D case. Hence the structure of the algorithm remains unchanged, with the main difference being how the rotation and translation matrices are solved.[39]
Thin plate spline robust point matching
The thin plate spline robust point matching (TPS-RPM) algorithm by Chui and Rangarajan augments the RPM method to perform non-rigid registration by parametrizing the transformation as a thin plate spline.[14] However, because the thin plate spline parametrization only exists in three dimensions, the method cannot be extended to problems involving four or more dimensions.
Kernel correlation
The kernel correlation (KC) approach of point set registration was introduced by Tsin and Kanade.[37]
Compared with ICP, the KC algorithm is more robust against noisy data. Unlike ICP, where, for every model point, only the closest scene point is considered, here every scene point affects every model point.
-
(kc.1)
The kernel function chosen for point set registration is typically symmetric and non-negative kernel, similar to the ones used in the
-
(kc.2)
The logarithm of KC of a point set is proportional, within a constant factor, to the information entropy. Observe that the KC is a measure of a "compactness" of the point set—trivially, if all points in the point set were at the same location, the KC would evaluate to a large value. The cost function of the point set registration algorithm for some transformation parameter is defined thus:
-
(kc.3)
Some algebraic manipulation yields:
-
(kc.4)
The expression is simplified by observing that is independent of . Furthermore, assuming rigid registration, is invariant when is changed because the Euclidean distance between every pair of points stays the same under rigid transformation. So the above equation may be rewritten as:
-
(kc.5)
The kernel density estimates are defined as:
The cost function can then be shown to be the correlation of the two kernel density estimates:
-
(kc.6)
Having established the cost function, the algorithm simply uses gradient descent to find the optimal transformation. It is computationally expensive to compute the cost function from scratch on every iteration, so a discrete version of the cost function Equation (kc.6) is used. The kernel density estimates can be evaluated at grid points and stored in a lookup table. Unlike the ICP and related methods, it is not necessary to find the nearest neighbour, which allows the KC algorithm to be comparatively simple in implementation.
Compared to ICP and EM-ICP for noisy 2D and 3D point sets, the KC algorithm is less sensitive to noise and results in correct registration more often.[37]
Gaussian mixture model
The kernel density estimates are sums of Gaussians and may therefore be represented as
Coherent point drift
Coherent point drift (CPD) was introduced by Myronenko and Song.[13][41] The algorithm takes a probabilistic approach to aligning point sets, similar to the GMM KC method. Unlike earlier approaches to non-rigid registration which assume a thin plate spline transformation model, CPD is agnostic with regard to the transformation model used. The point set represents the
Let there be M points in and N points in . The GMM probability density function for a point s is:
-
(cpd.1)
where, in D dimensions, is the
The membership probabilities is equal for all GMM components. The weight of the uniform distribution is denoted as . The mixture model is then:
-
(cpd.2)
The GMM centroids are re-parametrized by a set of parameters estimated by maximizing the likelihood. This is equivalent to minimizing the negative log-likelihood function:
-
(cpd.3)
where it is assumed that the data is
The
-
(cpd.4)
Ignoring constants independent of and , Equation (cpd.4) can be expressed thus:
-
(cpd.5)
where
with only if . The posterior probabilities of GMM components computed using previous parameter values is:
-
(cpd.6)
Minimizing the cost function in Equation (cpd.5) necessarily decreases the negative log-likelihood function E in Equation (cpd.3) unless it is already at a local minimum.[13] Thus, the algorithm can be expressed using the following pseudocode, where the point sets and are represented as and matrices and respectively:[13]
algorithm CPD θ := θ0 initialize 0 ≤ w ≤ 1 while not registered: // E-step, compute P for i ∊ [1, M] and j ∊ [1, N]: // M-step, solve for optimal transformation {θ, σ2} := solve(S, M, P) return θ
where the vector is a column vector of ones. The solve
function differs by the type of registration performed. For example, in rigid registration, the output is a scale a, a rotation matrix , and a translation vector . The parameter can be written as a tuple of these:
which is initialized to one, the identity matrix, and a column vector of zeroes:
The aligned point set is:
The solve_rigid
function for rigid registration can then be written as follows, with derivation of the algebra explained in Myronenko's 2010 paper.[13]
solve_rigid(S, M, P) NP := 1TP1 U, V := svd(A) // the singular value decomposition of A = UΣVT C := diag(1, …, 1, det(UVT)) // diag(ξ)is the diagonal matrix formed from vector ξ R := UCVT // tr is the trace of a matrix t := μs − aRμm return {a, R, t}, σ2
For affine registration, where the goal is to find an affine transformation instead of a rigid one, the output is an affine transformation matrix and a translation such that the aligned point set is:
The solve_affine
function for rigid registration can then be written as follows, with derivation of the algebra explained in Myronenko's 2010 paper.[13]
solve_affine(S, M, P) NP := 1TP1 t := μs − Bμm return {B, t}, σ2
It is also possible to use CPD with non-rigid registration using a parametrization derived using calculus of variations.[13]
Sums of Gaussian distributions can be computed in
of CPD is , which is asymptotically much faster than methods.[13]Bayesian coherent point drift (BCPD)
A variant of coherent point drift, called Bayesian coherent point drift (BCPD), was derived through a Bayesian formulation of point set registration. [42] BCPD has several advantages over CPD, e.g., (1) nonrigid and rigid registrations can be performed in a single algorithm, (2) the algorithm can be accelerated regardless of the Gaussianity of a Gram matrix to define motion coherence, (3) the algorithm is more robust against outliers because of a more reasonable definition of an outlier distribution. Additionally, in the Bayesian formulation, motion coherence was introduced through a prior distribution of displacement vectors, providing a clear difference between tuning parameters that control motion coherence. BCPD was further accelerated by a method called BCPD++, which is a three-step procedure composed of (1) downsampling of point sets, (2) registration of downsampled point sets, and (3) interpolation of a deformation field. [43] The method can register point sets composed of more than 10M points while maintaining its registration accuracy.
Coherent point drift with local surface geometry (LSG-CPD)
An variant of coherent point drift called CPD with Local Surface Geometry (LSG-CPD) for rigid point cloud registration.[44] The method adaptively adds different levels of point-to-plane penalization on top of the point-to-point penalization based on the flatness of the local surface. This results in GMM components with anisotropic covariances, instead of the isotropic covariances in the original CPD.[13] The anisotropic covariance matrix is modeled as:
-
(lsg-cpd.1)
where
-
(lsg-cpd.2)
is the anisotropic covariance matrix of the m-th point in the target set; is the normal vector corresponding to the same point; is an identity matrix, serving as a regularizer, pulling the problem away from ill-posedness. is penalization coefficient (a modified sigmoid function), which is set adaptively to add different levels of point-to-plane penalization depending on how flat the local surface is. This is realized by evaluating the surface variation [45] within the neighborhood of the m-th target point. is the upper bound of the penalization.
The point cloud registration is formulated as a maximum likelihood estimation (MLE) problem and solve it with the Expectation-Maximization (EM) algorithm. In the E step, the correspondence computation is recast into simple matrix manipulations and efficiently computed on a GPU. In the M step, an unconstrained optimization on a matrix Lie group is designed to efficiently update the rigid transformation of the registration. Taking advantage of the local geometric covariances, the method shows a superior performance in accuracy and robustness to noise and outliers, compared with the baseline CPD.[46] An enhanced runtime performance is expected thanks to the GPU accelerated correspondence calculation. An implementation of the LSG-CPD is open-sourced here.
Sorting the Correspondence Space (SCS)
This algorithm was introduced in 2013 by H. Assalih to accommodate sonar image registration.[47] These types of images tend to have high amounts of noise, so it is expected to have many outliers in the point sets to match. SCS delivers high robustness against outliers and can surpass ICP and CPD performance in the presence of outliers. SCS doesn't use iterative optimization in high dimensional space and is neither probabilistic nor spectral. SCS can match rigid and non-rigid transformations, and performs best when the target transformation is between three and six degrees of freedom.
See also
- Point feature matching
- Point-set triangulation
- Normal distributions transform
References
- S2CID 6054487.
- ^ Choi, Sungjoon; Zhou, Qian-Yi; Koltun, Vladlen (2015). "Robust reconstruction of indoor scenes" (PDF). Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition (CVPR): 5556–5565.
- S2CID 14986048.
- ^ S2CID 84186750.
- S2CID 6522002.
- S2CID 2596787.
- S2CID 206775100.
- ^ Bibcode:2019arXiv190512536Y.
- S2CID 11830123.
- PMID 11145309.
- ^ S2CID 10923565.
- ^ .
- ^ S2CID 10809031.
- ^ .
- S2CID 2621807.
- ^ S2CID 11038004.
- ^ S2CID 8724100.
- S2CID 11549421.
- ^ arXiv:2001.07715 [cs.RO].
- ^ S2CID 3331003.
- ^ ISSN 2153-1056.
- ^ S2CID 209976632.
- ^ Bibcode:2019arXiv190802021C.
- ISBN 978-3-642-37444-9.
- S2CID 509788.
- S2CID 972888.
- S2CID 29346470.
- arXiv:1902.01534 [cs.CV].
- ISBN 978-0-470-43469-7.
- ^ S2CID 27362942.
- S2CID 9305263.
- .
- ^ S2CID 7510079.
- ^ ISBN 9780262524063.
- ^ S2CID 202660784.
- .
- ^ )
- .
- ^ .
- ^ Jian, Bing; Vemuri, Baba C. (2005). A robust algorithm for point set registration using mixture of Gaussians. Tenth IEEE International Conference on Computer Vision 2005. Vol. 2. pp. 1246–1251.
- ^ Myronenko, Andriy; Song, Xubo; Carriera-Perpinán, Miguel A. (2006). "Non-rigid point set registration: Coherent point drift". Advances in Neural Information Processing Systems. 19: 1009–1016. Retrieved 31 May 2014.
- PMID 32031931.
- PMID 33301401.
- S2CID 232404480.
- S2CID 14952977.
- S2CID 232404480.
- ^ Assalih, Hassan. (2013). "Chapter 6: Sorting the Correspondence Space" (PDF). 3D reconstruction and motion estimation using forward looking sonar (Ph.D.). Heriot-Watt University.
External links
- Reference implementation of thin plate spline robust point matching
- Reference implementation of kernel correlation point set registration
- Reference implementation of coherent point drift
- Reference implementation of ICP variants
- Reference implementation of Bayesian coherent point drift
- Reference implementation of LSG-CPD