53 template <
typename ITERATOR>
55 : Base(firstConditional, lastConditional) {}
58 template <
class CONTAINER>
60 : Base(conditionals) {}
64 template <
class DERIVEDCONDITIONAL>
74 bool equals(
const This& bn,
double tol = 1
e-9)
const;
86 emplace_shared<DiscreteDistribution>(
key, spec);
90 template <
typename... Args>
92 emplace_shared<DiscreteConditional>(std::forward<Args>(
args)...);
100 return evaluate(values);
144 using Base::evaluate;
145 using Base::logProbability;
150 #ifdef GTSAM_ENABLE_BOOST_SERIALIZATION 152 friend class boost::serialization::access;
153 template<
class ARCHIVE>
154 void serialize(ARCHIVE & ar,
const unsigned int ) {
155 ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(Base);
const gtsam::Symbol key('X', 0)
BayesNet< DiscreteConditional > Base
std::string serialize(const T &input)
serializes to a string
std::shared_ptr< ConditionalType > sharedConditional
string markdown(const DiscreteValues &values, const KeyFormatter &keyFormatter, const DiscreteValues::Names &names)
Free version of markdown.
DiscreteConditional ConditionalType
NonlinearFactorGraph graph
DiscreteBayesNet(const FactorGraph< DERIVEDCONDITIONAL > &graph)
static const KeyFormatter DefaultKeyFormatter
double operator()(const DiscreteValues &values) const
DiscreteBayesNet(ITERATOR firstConditional, ITERATOR lastConditional)
string html(const DiscreteValues &values, const KeyFormatter &keyFormatter, const DiscreteValues::Names &names)
Free version of html.
DiscreteBayesNet()
Construct empty Bayes net.
Array< double, 1, 3 > e(1./3., 0.5, 2.)
void add(Args &&... args)
std::function< std::string(Key)> KeyFormatter
Typedef for a function to format a key, i.e. to convert it to a string.
DiscreteValues::Names Names
Translation table from values to strings.
DiscreteBayesNet(const CONTAINER &conditionals)
std::shared_ptr< This > shared_ptr
void add(const DiscreteKey &key, const std::string &spec)
std::pair< Key, size_t > DiscreteKey
graph add(PriorFactor< Pose2 >(1, priorMean, priorNoise))
const std::vector< GaussianConditional::shared_ptr > conditionals