formatting
parent
a98ac0fdb2
commit
8145086e5b
|
@ -61,14 +61,14 @@ virtual class DecisionTreeFactor : gtsam::DiscreteFactor {
|
|||
DecisionTreeFactor(const std::vector<gtsam::DiscreteKey>& keys, string table);
|
||||
|
||||
DecisionTreeFactor(const gtsam::DiscreteConditional& c);
|
||||
|
||||
|
||||
void print(string s = "DecisionTreeFactor\n",
|
||||
const gtsam::KeyFormatter& keyFormatter =
|
||||
gtsam::DefaultKeyFormatter) const;
|
||||
bool equals(const gtsam::DecisionTreeFactor& other, double tol = 1e-9) const;
|
||||
|
||||
size_t cardinality(gtsam::Key j) const;
|
||||
|
||||
|
||||
double operator()(const gtsam::DiscreteValues& values) const;
|
||||
gtsam::DecisionTreeFactor operator*(const gtsam::DecisionTreeFactor& f) const;
|
||||
size_t cardinality(gtsam::Key j) const;
|
||||
|
|
|
@ -13,9 +13,10 @@ Author: Frank Dellaert
|
|||
|
||||
import unittest
|
||||
|
||||
from gtsam.utils.test_case import GtsamTestCase
|
||||
|
||||
from gtsam import (DecisionTreeFactor, DiscreteDistribution, DiscreteValues,
|
||||
Ordering)
|
||||
from gtsam.utils.test_case import GtsamTestCase
|
||||
|
||||
|
||||
class TestDecisionTreeFactor(GtsamTestCase):
|
||||
|
|
|
@ -19,8 +19,8 @@ from gtsam.utils.test_case import GtsamTestCase
|
|||
|
||||
import gtsam
|
||||
from gtsam import (DiscreteBayesNet, DiscreteBayesTreeClique,
|
||||
DiscreteConditional, DiscreteFactorGraph,
|
||||
DiscreteValues, Ordering)
|
||||
DiscreteConditional, DiscreteFactorGraph, DiscreteValues,
|
||||
Ordering)
|
||||
|
||||
|
||||
class TestDiscreteBayesNet(GtsamTestCase):
|
||||
|
|
|
@ -13,9 +13,10 @@ Author: Varun Agrawal
|
|||
|
||||
import unittest
|
||||
|
||||
from gtsam import DecisionTreeFactor, DiscreteConditional, DiscreteKeys
|
||||
from gtsam.utils.test_case import GtsamTestCase
|
||||
|
||||
from gtsam import DecisionTreeFactor, DiscreteConditional, DiscreteKeys
|
||||
|
||||
# Some DiscreteKeys for binary variables:
|
||||
A = 0, 2
|
||||
B = 1, 2
|
||||
|
|
|
@ -14,9 +14,12 @@ Author: Frank Dellaert
|
|||
import unittest
|
||||
|
||||
import numpy as np
|
||||
from gtsam import DecisionTreeFactor, DiscreteConditional, DiscreteFactorGraph, DiscreteKeys, DiscreteValues, Ordering, Symbol
|
||||
from gtsam.utils.test_case import GtsamTestCase
|
||||
|
||||
from gtsam import (DecisionTreeFactor, DiscreteConditional,
|
||||
DiscreteFactorGraph, DiscreteKeys, DiscreteValues, Ordering,
|
||||
Symbol)
|
||||
|
||||
OrderingType = Ordering.OrderingType
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue