Package boofcv.alg.geo.f
Class EssentialResidualSampson
java.lang.Object
boofcv.alg.geo.f.EssentialResidualSampson
- All Implemented Interfaces:
ModelObservationResidual<DMatrixRMaj,
AssociatedPair>
public class EssentialResidualSampson
extends Object
implements ModelObservationResidual<DMatrixRMaj,AssociatedPair>
Computes the Sampson distance residual for a set of observations given an esesntial matrix. For use in least-squares non-linear optimization algorithms. Error is computed in pixels.
0 = x2T*F*x1
E=K2'*F*K1
F=inv(K2')*E*inv(K1)
0=(K2*n2)'inv(K2)'*E*inv(K1)*(K1*n2), where n1 and n2 are normalized image coordinates
Page 287 in: R. Hartley, and A. Zisserman, "Multiple View Geometry in Computer Vision", 2nd Ed, Cambridge 2003
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptiondouble
computeResidual
(AssociatedPair observation) Compute the error for the observationvoid
setCalibration1
(CameraPinhole pinhole) void
setCalibration2
(CameraPinhole pinhole) void
Specify the epipolar matrix being evaluated
-
Constructor Details
-
EssentialResidualSampson
public EssentialResidualSampson()
-
-
Method Details
-
setCalibration1
-
setCalibration2
-
setModel
Description copied from interface:ModelObservationResidual
Specify the epipolar matrix being evaluated- Specified by:
setModel
in interfaceModelObservationResidual<DMatrixRMaj,
AssociatedPair> - Parameters:
E
- The model being optimized
-
computeResidual
Description copied from interface:ModelObservationResidual
Compute the error for the observation- Specified by:
computeResidual
in interfaceModelObservationResidual<DMatrixRMaj,
AssociatedPair> - Parameters:
observation
- Observation of point feature in two views- Returns:
- residual Error magnitude
-