| Constructor and Description |
|---|
ICP(List<P> target,
List<P> reference)
Also instantiates a new
ICP instance, but uses the SimplePointMatchIdentification to define corresponding points. |
ICP(List<P> target,
List<P> reference,
double distanceThreshold)
Also instantiates a new
ICP instance, but uses the SimplePointMatchIdentification to define corresponding points. |
ICP(List<P> target,
List<P> reference,
PointMatchIdentification<P> pointMatchIdentifier)
Instantiates a new
ICP object with the List of target and reference points as well as the PointMatchIdentification interface that defines
how corresponding points are identified. |
| Modifier and Type | Method and Description |
|---|---|
void |
estimateIntialModel(List<PointMatch> matches,
Model<?> model)
Estimates an initial
Model based on some given PointMatches. |
ArrayList<PointMatch> |
getAmbigousMatches()
Returns the
ArrayList of ambigous PointMatches indentified in the last ICP iteration, or null if no iteration has been computed yet. |
double |
getAverageError()
Returns the average error of the last ICP iteration, or -1 if no iteration has been computed yet.
|
double |
getMaximalError()
Returns the maximum error of a
PointMatch of the last ICP iteration, or -1 if no iteration has been computed yet. |
int |
getNumAmbigousMatches()
Returns the number of ambigous
PointMatches indentified in the last ICP iteration, or -1 if no iteration has been computed yet. |
int |
getNumPointMatches()
Returns the number of
PointMatches of the last ICP iteration, or -1 if no iteration has been computed yet. |
protected static ArrayList<Integer> |
getOccurences(Point pointTarget,
Point pointReference,
List<PointMatch> list)
|
List<PointMatch> |
getPointMatches()
|
PointMatchIdentification<P> |
getPointMatchIdentification()
Returns the current
PointMatchIdentification that is used to identfy corresponding points |
List<P> |
getReferencePoints() |
List<P> |
getTargetPoints() |
static ArrayList<PointMatch> |
removeAmbigousMatches(List<PointMatch> matches)
Detects ambigous (and duplicate)
PointMatches, i.e. |
void |
runICPIteration(Model<?> lastModel,
Model<?> newModel)
Performs one iteration of the
ICP. |
void |
setPointMatchIdentification(PointMatchIdentification<P> pointMatchIdentifier)
Sets the
PointMatchIdentification that defines how PointMatches between reference and target are identified. |
public ICP(List<P> target, List<P> reference, PointMatchIdentification<P> pointMatchIdentifier)
ICP object with the List of target and reference points as well as the PointMatchIdentification interface that defines
how corresponding points are identified. Lists have to implement Point(for compatibility with Model) and Leaf(for compatibility with KDTree).target - - the List of target pointsreference - - the List of reference pointspointMatchIdentifier - - the PointMatchIdentification which defines how correspondences are establishedpublic ICP(List<P> target, List<P> reference, double distanceThreshold)
ICP instance, but uses the SimplePointMatchIdentification to define corresponding points.target - - the List of target pointsreference - - the List of reference pointsdistanceThreshold - - the maximal distance of SimplePointMatchIdentification, so that the nearest neighbor of a point is still counted as a corresponding pointpublic void runICPIteration(Model<?> lastModel, Model<?> newModel) throws NotEnoughDataPointsException, IllDefinedDataPointsException, NoSuitablePointsException
ICP. It takes the last Model as input to find the corresponding points for the new Model.
The result is the new Model, the number of corresponding points, the average, and the maximal error. Note that lastModel and newModel can be the
same instance and it will be overwritten.lastModel - - The last Model that maps the target.local coordinates to the reference.world coordinates, used to find the corresponding pointsnewModel - - The Model that maps the target.local coordinates to the reference.world coordinates, will be fitted to the new pointsNotEnoughDataPointsExceptionIllDefinedDataPointsExceptionNoSuitablePointsExceptionpublic void estimateIntialModel(List<PointMatch> matches, Model<?> model) throws NotEnoughDataPointsException, IllDefinedDataPointsException
Model based on some given PointMatches. Note that the PointMatches have to be stored as PointMatch(target,reference).matches - - The List of apriori known PointMatchesmodel - - The Model to useNotEnoughDataPointsExceptionIllDefinedDataPointsExceptionpublic void setPointMatchIdentification(PointMatchIdentification<P> pointMatchIdentifier)
PointMatchIdentification that defines how PointMatches between reference and target are identified.
The simplest way to do it is the SimplePointMatchIdentification class which takes the nearest neighbor with a minimal distance threshold.pointMatchIdentifier - - the new PointMatchIdentificationpublic PointMatchIdentification<P> getPointMatchIdentification()
PointMatchIdentification that is used to identfy corresponding pointspublic List<PointMatch> getPointMatches()
List of PointMatchespublic double getAverageError()
public double getMaximalError()
PointMatch of the last ICP iteration, or -1 if no iteration has been computed yet.public int getNumPointMatches()
PointMatches of the last ICP iteration, or -1 if no iteration has been computed yet.PointMatchespublic int getNumAmbigousMatches()
PointMatches indentified in the last ICP iteration, or -1 if no iteration has been computed yet.PointMatchespublic ArrayList<PointMatch> getAmbigousMatches()
ArrayList of ambigous PointMatches indentified in the last ICP iteration, or null if no iteration has been computed yet.ArrayList of PointMatchespublic static ArrayList<PointMatch> removeAmbigousMatches(List<PointMatch> matches)
PointMatches, i.e. if a Point corresponds with more than one other Pointmatches - - the List of PointMatchesArrayList containing the removed ambigous or duplicate PointMatchesprotected static ArrayList<Integer> getOccurences(Point pointTarget, Point pointReference, List<PointMatch> list)
pointTarget - - one PointpointReference - - the other Pointlist - - the List of PointMatches (target, reference)ArrayList of indices which should be removed due to duplicate or ambigous occurenceCopyright © 2015–2021 Fiji. All rights reserved.