2 GTSAM Copyright 2010-2019, Georgia Tech Research Corporation,
3 Atlanta, Georgia 30332-0415
6 See LICENSE for the license information
8 ProjectionFactorRollingShutter unit tests.
21 pose2 =
gtsam.Pose3(np.array([[ 0.9999375 , 0.00502487, 0.00998725, 0.1 ],
22 [-0.00497488, 0.999975 , -0.00502487, 0.02 ],
23 [-0.01001225, 0.00497488, 0.9999375 , 1. ],
24 [ 0. , 0. , 0. , 1. ]]))
25 point = np.array([2, 0, 15])
30 measured = np.array([0.13257015, 0.0004157])
37 test constructor for the ProjectionFactorRollingShutter
39 factor = gtsam_unstable.ProjectionFactorRollingShutter(measured, alpha, point_noise, 0, 1, 2, cal)
40 factor = gtsam_unstable.ProjectionFactorRollingShutter(measured, alpha, point_noise, 0, 1, 2, cal,
42 factor = gtsam_unstable.ProjectionFactorRollingShutter(measured, alpha, point_noise, 0, 1, 2, cal,
True,
False)
43 factor = gtsam_unstable.ProjectionFactorRollingShutter(measured, alpha, point_noise, 0, 1, 2, cal,
True,
False,
48 test the factor error for a specific example
51 values.insert(0, pose1)
52 values.insert(1, pose2)
53 values.insert(2, point)
54 factor = gtsam_unstable.ProjectionFactorRollingShutter(measured, alpha, point_noise, 0, 1, 2, cal)
58 if __name__ ==
'__main__':