2 GTSAM Copyright 2010-2019, Georgia Tech Research Corporation, 3 Atlanta, Georgia 30332-0415 6 See LICENSE for the license information 8 Unit tests for Hybrid Nonlinear Factor Graphs. 13 from __future__
import print_function
20 from gtsam
import BetweenFactorPoint3, noiseModel, PriorFactorPoint3, Point3
26 """Unit tests for HybridGaussianFactorGraph.""" 32 1, 2, 3), noiseModel.Diagonal.Variances([1, 1, 1])))
35 noiseModel.Diagonal.Variances([0.5, 0.5, 0.5])))
39 noiseModel.Unit.Create(3)),
41 noiseModel.Unit.Create(3))
45 values.insert_point3(1,
Point3(0, 0, 0))
46 values.insert_point3(2,
Point3(2, 3, 1))
47 hfg = nlfg.linearize(values)
48 hbn = hfg.eliminateSequential()
50 self.assertEqual(hbv.atDiscrete(10), 0)
53 if __name__ ==
"__main__":
def test_nonlinear_hybrid(self)
Implementation of a discrete conditional mixture factor.
PriorFactor< Point3 > PriorFactorPoint3
BetweenFactor< Point3 > BetweenFactorPoint3
DiscreteKeys is a set of keys that can be assembled using the & operator.