26 class DecisionTreeFactor;
27 class DiscreteConditional;
53 typedef boost::shared_ptr<Values> sharedValues;
65 template<
typename CONTAINER>
80 virtual void print(
const std::string& s =
"DiscreteFactor\n",
81 const KeyFormatter& formatter = DefaultKeyFormatter)
const {
86 virtual bool empty()
const {
return size() == 0; }
93 virtual double operator()(
const Values&)
const = 0;
Base class for discrete probabilistic factors The most general one is the derived DecisionTreeFactor...
Definition: DiscreteFactor.h:33
Assignment< Key > Values
A map from keys to values TODO: Do we need this? Should we just use gtsam::Values? We just need another special DiscreteValue to represent labels, However, all other Lie's operators are undefined in this class.
Definition: DiscreteFactor.h:52
A discrete probabilistic factor.
Definition: DecisionTreeFactor.h:39
DiscreteFactor This
This class.
Definition: DiscreteFactor.h:38
Factor Base
Our base class.
Definition: DiscreteFactor.h:40
This is the base class for all factor types.
Definition: Factor.h:51
void print(const std::string &s="Factor", const KeyFormatter &formatter=DefaultKeyFormatter) const
print
Definition: Factor.cpp:30
Point2 operator*(double s, const Point2 &p)
multiply with scalar
Definition: Point2.h:249
A non-templated config holding any types of Manifold-group elements.
Definition: Values.h:75
void print(const Matrix &A, const string &s, ostream &stream)
print a matrix
Definition: Matrix.cpp:183
An assignment from labels to value index (size_t).
Definition: Assignment.h:35
The base class for all factors.
virtual ~DiscreteFactor()
Virtual destructor.
Definition: DiscreteFactor.h:69
Template to create a binary predicate.
Definition: Testable.h:102
DiscreteFactor(const CONTAINER &keys)
Construct from container of keys.
Definition: DiscreteFactor.h:66
virtual bool empty() const
Test whether the factor is empty.
Definition: DiscreteFactor.h:86
DiscreteFactor()
Default constructor creates empty factor.
Definition: DiscreteFactor.h:61
boost::function< std::string(Key)> KeyFormatter
Typedef for a function to format a key, i.e. to convert it to a string.
Definition: types.h:62
An assignment from labels to a discrete value index (size_t)
boost::shared_ptr< DiscreteFactor > shared_ptr
shared_ptr to this class
Definition: DiscreteFactor.h:39