test_pickle.py
Go to the documentation of this file.
1 """
2 GTSAM Copyright 2010-2020, Georgia Tech Research Corporation,
3 Atlanta, Georgia 30332-0415
4 All Rights Reserved
5 
6 See LICENSE for the license information
7 
8 Unit tests to check pickling.
9 
10 Author: Ayush Baid
11 """
12 from gtsam import Cal3Bundler, PinholeCameraCal3Bundler, Point2, Point3, Pose3, Rot3, SfmTrack, Unit3
13 
14 from gtsam.utils.test_case import GtsamTestCase
15 
17  """Tests pickling on some of the classes."""
18 
20  obj = Cal3Bundler(fx=100, k1=0.1, k2=0.2, u0=100, v0=70)
22 
25  Pose3(Rot3.RzRyRx(0, 0.1, -0.05), Point3(1, 1, 0)),
26  Cal3Bundler(fx=100, k1=0.1, k2=0.2, u0=100, v0=70),
27  )
29 
31  obj = Rot3.RzRyRx(0, 0.05, 0.1)
33 
35  obj = Pose3(Rot3.Ypr(0.0, 1.0, 0.0), Point3(1, 1, 0))
37 
39  obj = SfmTrack(Point3(1, 1, 0))
40  obj.add_measurement(0, Point2(-1, 5))
41  obj.add_measurement(1, Point2(6, 2))
43 
45  obj = Unit3(Point3(1, 1, 0))
Vector2 Point2
Definition: Point2.h:27
def test_cal3Bundler_roundtrip(self)
Definition: test_pickle.py:19
def test_unit3_roundtrip(self)
Definition: test_pickle.py:44
gtsam::PinholeCamera< gtsam::Cal3Bundler > PinholeCameraCal3Bundler
def test_rot3_roundtrip(self)
Definition: test_pickle.py:30
Represents a 3D point on a unit sphere.
Definition: Unit3.h:42
Define the structure for the 3D points.
Definition: dataset.h:220
def test_pinholeCameraCal3Bundler_roundtrip(self)
Definition: test_pickle.py:23
def test_pose3_roundtrip(self)
Definition: test_pickle.py:34
Vector3 Point3
Definition: Point3.h:35
def test_sfmTrack_roundtrip(self)
Definition: test_pickle.py:38


gtsam
Author(s):
autogenerated on Sat May 8 2021 02:46:04