Fixed test
parent
f98f49381a
commit
e2a3d1cb8f
|
@ -199,11 +199,6 @@ namespace gtsam {
|
||||||
const pair<string,typename BayesTree<Conditional>::sharedClique >& v1,
|
const pair<string,typename BayesTree<Conditional>::sharedClique >& v1,
|
||||||
const pair<string,typename BayesTree<Conditional>::sharedClique >& v2
|
const pair<string,typename BayesTree<Conditional>::sharedClique >& v2
|
||||||
) {
|
) {
|
||||||
// cout << v1.first << " =? " << v2.first << endl;
|
|
||||||
// cout << (v1.first == v2.first) << endl;
|
|
||||||
// cout << v1.second->equals(*(v2.second)) << endl;
|
|
||||||
// v1.second->print("v1");
|
|
||||||
// v2.second->print("v2");
|
|
||||||
return v1.first == v2.first && v1.second->equals(*(v2.second));
|
return v1.first == v2.first && v1.second->equals(*(v2.second));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -25,8 +25,9 @@ typedef BayesTree<GaussianConditional> GaussianBayesTree;
|
||||||
// Conditionals for ASIA example from the tutorial with A and D evidence
|
// Conditionals for ASIA example from the tutorial with A and D evidence
|
||||||
SymbolicConditional::shared_ptr B(new SymbolicConditional("B")), L(
|
SymbolicConditional::shared_ptr B(new SymbolicConditional("B")), L(
|
||||||
new SymbolicConditional("L", "B")), E(
|
new SymbolicConditional("L", "B")), E(
|
||||||
new SymbolicConditional("E", "B", "L")), S(new SymbolicConditional("S",
|
new SymbolicConditional("E", "B", "L")), S1(new SymbolicConditional("S",
|
||||||
"L", "B")), T(new SymbolicConditional("T", "E", "L")), X(
|
"B", "L")), S2(new SymbolicConditional("S", "L", "B")), T(
|
||||||
|
new SymbolicConditional("T", "E", "L")), X(
|
||||||
new SymbolicConditional("X", "E"));
|
new SymbolicConditional("X", "E"));
|
||||||
|
|
||||||
/* ************************************************************************* */
|
/* ************************************************************************* */
|
||||||
|
@ -85,7 +86,7 @@ TEST( BayesTree, iSAM )
|
||||||
bayesTree.insert(B);
|
bayesTree.insert(B);
|
||||||
bayesTree.insert(L);
|
bayesTree.insert(L);
|
||||||
bayesTree.insert(E);
|
bayesTree.insert(E);
|
||||||
bayesTree.insert(S);
|
bayesTree.insert(S2);
|
||||||
bayesTree.insert(T);
|
bayesTree.insert(T);
|
||||||
bayesTree.insert(X);
|
bayesTree.insert(X);
|
||||||
|
|
||||||
|
@ -93,7 +94,7 @@ TEST( BayesTree, iSAM )
|
||||||
SymbolicBayesTree expected;
|
SymbolicBayesTree expected;
|
||||||
expected.insert(B);
|
expected.insert(B);
|
||||||
expected.insert(L);
|
expected.insert(L);
|
||||||
expected.insert(S);
|
expected.insert(S1);
|
||||||
expected.insert(E);
|
expected.insert(E);
|
||||||
expected.insert(T);
|
expected.insert(T);
|
||||||
expected.insert(X);
|
expected.insert(X);
|
||||||
|
@ -107,7 +108,7 @@ TEST( BayesTree, iSAM )
|
||||||
SymbolicBayesTree actual = update(bayesTree, newFactor);
|
SymbolicBayesTree actual = update(bayesTree, newFactor);
|
||||||
|
|
||||||
// Check whether the same
|
// Check whether the same
|
||||||
//CHECK(assert_equal(expected,actual));
|
CHECK(assert_equal(expected,actual));
|
||||||
}
|
}
|
||||||
|
|
||||||
/* ************************************************************************* */
|
/* ************************************************************************* */
|
||||||
|
|
Loading…
Reference in New Issue