Go to the documentation of this file.
26 using namespace gtsam;
28 int main(
int argc,
char **argv) {
45 vector<string> pretty = {
"Asia",
"Dyspnea",
"XRay",
"Tuberculosis",
46 "Smoking",
"Either",
"LungCancer",
"Bronchitis"};
75 cout <<
"\n10 samples:" << endl;
76 for (
size_t i = 0;
i < 10;
i++) {
77 auto sample = chordal->sample();
static const DiscreteKey LungCancer(6, 2)
std::shared_ptr< BayesNetType > eliminateSequential(OptionalOrderingType orderingType={}, const Eliminate &function=EliminationTraitsType::DefaultEliminate, OptionalVariableIndex variableIndex={}) const
static const DiscreteKey Tuberculosis(3, 2)
static const DiscreteKey XRay(2, 2)
void print(const std::string &s="BayesNet", const KeyFormatter &formatter=DefaultKeyFormatter) const override
const KeyFormatter & formatter
static const DiscreteKey Bronchitis(7, 2)
std::shared_ptr< BayesTreeType > eliminateMultifrontal(OptionalOrderingType orderingType={}, const Eliminate &function=EliminationTraitsType::DefaultEliminate, OptionalVariableIndex variableIndex={}) const
static const DiscreteKey Smoking(4, 2)
static const DiscreteKey Dyspnea(1, 2)
A class for computing marginals in a DiscreteFactorGraph.
static enum @1096 ordering
const gtsam::Symbol key('X', 0)
static const DiscreteKey Either(5, 2)
void add(const DiscreteKey &key, const std::string &spec)
std::pair< Key, size_t > DiscreteKey
void add(Args &&... args)
std::shared_ptr< This > shared_ptr
DiscreteValues optimize(OptionalOrderingType orderingType={}) const
Find the maximum probable explanation (MPE) by doing max-product.
std::uint64_t Key
Integer nonlinear key type.
int main(int argc, char **argv)
gtsam
Author(s):
autogenerated on Fri Nov 1 2024 03:32:26