Merge branch 'feature/2.4.0/templatedEF'

Adds CALIBRATION template argument to a second constructor

Resolved Conflicts (with Jing):
	gtsam/slam/EssentialMatrixFactor.h
	gtsam/slam/tests/testEssentialMatrixFactor.cpp
release/4.3a0
dellaert 2014-01-24 17:26:03 -05:00
commit 6be91a2df2
2 changed files with 3 additions and 3 deletions

View File

@ -155,7 +155,7 @@ public:
// We have point x,y in image 1
// Given a depth Z, the corresponding 3D point P1 = Z*(x,y,1) = (x,y,1)/d
// We then convert to second camera by P2 = 1R2Õ*(P1-1T2)
// We then convert to second camera by P2 = 1R2<EFBFBD>*(P1-1T2)
// The homogeneous coordinates of can be written as
// 2R1*(P1-1T2) == 2R1*d*(P1-1T2) == 2R1*((x,y,1)-d*1T2)
// where we multiplied with d which yields equivalent homogeneous coordinates.

View File

@ -154,8 +154,8 @@ TEST (EssentialMatrixFactor2, factor) {
EssentialMatrixFactor2 factor(100, i, pA(i), pB(i), model2);
// Check evaluation
Point3 P1 = data.tracks[i].p;
const Point2 pi = camera2.project(P1);
Point3 P1 = data.tracks[i].p, P2 = data.cameras[1].pose().transform_to(P1);
const Point2 pi = SimpleCamera::project_to_camera(P2);
Point2 reprojectionError(pi - pB(i));
Vector expected = reprojectionError.vector();