Fix more wrapper tests
parent
1a566ea2bb
commit
71d5a6c1f1
|
@ -17,7 +17,7 @@ import numpy as np
|
||||||
from gtsam.symbol_shorthand import A, X
|
from gtsam.symbol_shorthand import A, X
|
||||||
from gtsam.utils.test_case import GtsamTestCase
|
from gtsam.utils.test_case import GtsamTestCase
|
||||||
|
|
||||||
from gtsam import (DiscreteConditional, DiscreteKeys, DiscreteValues,
|
from gtsam import (DiscreteConditional, DiscreteValues,
|
||||||
GaussianConditional, HybridBayesNet,
|
GaussianConditional, HybridBayesNet,
|
||||||
HybridGaussianConditional, HybridValues, VectorValues,
|
HybridGaussianConditional, HybridValues, VectorValues,
|
||||||
noiseModel)
|
noiseModel)
|
||||||
|
@ -48,8 +48,7 @@ class TestHybridBayesNet(GtsamTestCase):
|
||||||
bayesNet = HybridBayesNet()
|
bayesNet = HybridBayesNet()
|
||||||
bayesNet.push_back(conditional)
|
bayesNet.push_back(conditional)
|
||||||
bayesNet.push_back(
|
bayesNet.push_back(
|
||||||
HybridGaussianConditional([X(1)], [], Asia,
|
HybridGaussianConditional(Asia, [conditional0, conditional1]))
|
||||||
[conditional0, conditional1]))
|
|
||||||
bayesNet.push_back(DiscreteConditional(Asia, "99/1"))
|
bayesNet.push_back(DiscreteConditional(Asia, "99/1"))
|
||||||
|
|
||||||
# Create values at which to evaluate.
|
# Create values at which to evaluate.
|
||||||
|
|
|
@ -35,7 +35,7 @@ class TestHybridGaussianFactorGraph(GtsamTestCase):
|
||||||
jf1 = JacobianFactor(X(0), np.eye(3), np.zeros((3, 1)), model)
|
jf1 = JacobianFactor(X(0), np.eye(3), np.zeros((3, 1)), model)
|
||||||
jf2 = JacobianFactor(X(0), np.eye(3), np.ones((3, 1)), model)
|
jf2 = JacobianFactor(X(0), np.eye(3), np.ones((3, 1)), model)
|
||||||
|
|
||||||
gmf = HybridGaussianFactor([X(0)], (C(0), 2), [(jf1, 0), (jf2, 0)])
|
gmf = HybridGaussianFactor((C(0), 2), [(jf1, 0), (jf2, 0)])
|
||||||
|
|
||||||
hfg = HybridGaussianFactorGraph()
|
hfg = HybridGaussianFactorGraph()
|
||||||
hfg.push_back(jf1)
|
hfg.push_back(jf1)
|
||||||
|
@ -60,7 +60,7 @@ class TestHybridGaussianFactorGraph(GtsamTestCase):
|
||||||
jf1 = JacobianFactor(X(0), np.eye(3), np.zeros((3, 1)), model)
|
jf1 = JacobianFactor(X(0), np.eye(3), np.zeros((3, 1)), model)
|
||||||
jf2 = JacobianFactor(X(0), np.eye(3), np.ones((3, 1)), model)
|
jf2 = JacobianFactor(X(0), np.eye(3), np.ones((3, 1)), model)
|
||||||
|
|
||||||
gmf = HybridGaussianFactor([X(0)], (C(0), 2), [(jf1, 0), (jf2, 0)])
|
gmf = HybridGaussianFactor((C(0), 2), [(jf1, 0), (jf2, 0)])
|
||||||
|
|
||||||
hfg = HybridGaussianFactorGraph()
|
hfg = HybridGaussianFactorGraph()
|
||||||
hfg.push_back(jf1)
|
hfg.push_back(jf1)
|
||||||
|
|
Loading…
Reference in New Issue