31 class DiscreteBayesNet;
43 using shared_ptr = std::shared_ptr<This>;
54 const ADT& potentials)
59 const std::string& s =
"Discrete Lookup Table: ",
60 const KeyFormatter& formatter = DefaultKeyFormatter)
const override;
81 using shared_ptr = std::shared_ptr<This>;
98 bool equals(
const This& bn,
double tol = 1e-9)
const;
106 template <
typename... Args>
107 void add(Args&&... args) {
108 emplace_shared<DiscreteLookupTable>(std::forward<Args>(args)...);
126 #ifdef GTSAM_ENABLE_BOOST_SERIALIZATION 128 friend class boost::serialization::access;
129 template <
class ARCHIVE>
130 void serialize(ARCHIVE& ar,
const unsigned int ) {
131 ar& BOOST_SERIALIZATION_BASE_OBJECT_NVP(
Base);
DiscreteLookupDAG()
Construct empty DAG.
Definition: DiscreteLookupDAG.h:87
std::string serialize(const T &input)
serializes to a string
Definition: serialization.h:113
Definition: BayesNet.h:35
Definition: Testable.h:152
Definition: DecisionTreeFactor.h:44
Definition: Testable.h:112
DiscreteLookupTable(size_t nFrontals, const DiscreteKeys &keys, const ADT &potentials)
Construct a new Discrete Lookup Table object.
Definition: DiscreteLookupDAG.h:53
GTSAM_EXPORT void print(const Matrix &A, const std::string &s, std::ostream &stream)
Definition: Conditional.h:61
DiscreteLookupTable table for max-productInherits from discrete conditional for convenience, but is not normalized. Is used in the max-product algorithm.
Definition: DiscreteLookupDAG.h:40
Definition: DiscreteBayesNet.h:38
Definition: DiscreteValues.h:34
std::function< std::string(Key)> KeyFormatter
Typedef for a function to format a key, i.e. to convert it to a string.
Definition: Key.h:35
Definition: chartTesting.h:28
Definition: DiscreteLookupDAG.h:77
void add(Args &&... args)
Definition: DiscreteLookupDAG.h:107
DiscreteKeys is a set of keys that can be assembled using the & operator.
Definition: DiscreteKey.h:41
Definition: DiscreteConditional.h:37