Class IterativeClosestPoint<SE extends InvertibleTransform,P extends GeoTuple>

java.lang.Object
georegression.fitting.points.IterativeClosestPoint<SE,P>

public class IterativeClosestPoint<SE extends InvertibleTransform,P extends GeoTuple> extends Object

A straight forward implementation of the Iterative Closest Point (ICP) algorithm for 2D or 3D objects. ICP works by finding a locally optimal rigid body transform that minimizes the error between a set of points and a model. The model can be described in several different formats and is implement as an interface ClosestPointToModel.

While this implementation is primarily designed for simplicity, generic, and correctness, its performance will be primarily determined by the efficiency of the ClosestPointToModel provided to it. This is especially true for complex models with large number of points.

  • Constructor Details

  • Method Details

    • getFoundError

      public double getFoundError()
      Mean square error between the model and the set of points after the optimal transformation has been found
    • getPointsToModel

      public SE getPointsToModel()
      Found rigid body transformation from model to points.
    • setModel

      public void setModel(ClosestPointToModel model)
      The model that the input points is being fitted against.
    • process

      public boolean process(List<P> points)
      Computes the best fit transform
      Parameters:
      points - Points which are to matched to a model. Their state is modified to the optimal fit location.
    • getTotalMatched

      public int getTotalMatched()