Implementation of a discrete conditional mixture factor.
Implements a joint discrete-continuous factor where the discrete variable serves to "select" a mixture component corresponding to a GaussianFactor type of measurement.
Represents the underlying Gaussian mixture as a Decision Tree, where the set of discrete variables indexes to the continuous gaussian distribution.
|
|
| GaussianMixtureFactor ()=default |
| Default constructor, mainly for serialization.
|
|
| GaussianMixtureFactor (const KeyVector &continuousKeys, const DiscreteKeys &discreteKeys, const Factors &factors) |
| Construct a new Gaussian mixture factor.
|
|
| GaussianMixtureFactor (const KeyVector &continuousKeys, const DiscreteKeys &discreteKeys, const std::vector< sharedFactor > &factors) |
| Construct a new GaussianMixtureFactor object using a vector of GaussianFactor shared pointers.
|
|
|
bool | equals (const HybridFactor &lf, double tol=1e-9) const override |
| equals
|
|
void | print (const std::string &s="GaussianMixtureFactor\n", const KeyFormatter &formatter=DefaultKeyFormatter) const override |
| print
|
|
| HybridFactor ()=default |
| Default constructor creates empty factor.
|
|
| HybridFactor (const KeyVector &keys) |
| Construct hybrid factor from continuous keys.
|
|
| HybridFactor (const DiscreteKeys &discreteKeys) |
| Construct hybrid factor from discrete keys.
|
|
| HybridFactor (const KeyVector &continuousKeys, const DiscreteKeys &discreteKeys) |
| Construct a new Hybrid Factor object.
|
|
virtual | ~HybridFactor ()=default |
| Virtual destructor.
|
|
void | print (const std::string &s="HybridFactor\n", const KeyFormatter &formatter=DefaultKeyFormatter) const override |
| print
|
|
bool | isDiscrete () const |
| True if this is a factor of discrete variables only.
|
|
bool | isContinuous () const |
| True if this is a factor of continuous variables only.
|
|
bool | isHybrid () const |
| True is this is a Discrete-Continuous factor.
|
|
size_t | nrContinuous () const |
| Return the number of continuous variables in this factor.
|
|
const DiscreteKeys & | discreteKeys () const |
| Return the discrete keys for this factor.
|
|
const KeyVector & | continuousKeys () const |
| Return only the continuous keys for this factor.
|
|
virtual | ~Factor ()=default |
| Default destructor.
|
|
bool | empty () const |
| Whether the factor is empty (involves zero variables).
|
|
Key | front () const |
| First key.
|
|
Key | back () const |
| Last key.
|
|
const_iterator | find (Key key) const |
| find
|
|
const KeyVector & | keys () const |
| Access the factor's involved variable keys.
|
|
const_iterator | begin () const |
| Iterator at beginning of involved variable keys.
|
|
const_iterator | end () const |
| Iterator at end of involved variable keys.
|
|
size_t | size () const |
|
virtual void | printKeys (const std::string &s="Factor", const KeyFormatter &formatter=DefaultKeyFormatter) const |
| print only keys
|
|
bool | equals (const This &other, double tol=1e-9) const |
| check equality
|
|
KeyVector & | keys () |
|
iterator | begin () |
| Iterator at beginning of involved variable keys.
|
|
iterator | end () |
| Iterator at end of involved variable keys.
|
|
|
| Factor () |
| Default constructor for I/O.
|
|
template<typename CONTAINER > |
| Factor (const CONTAINER &keys) |
| Construct factor from container of keys.
|
|
template<typename ITERATOR > |
| Factor (ITERATOR first, ITERATOR last) |
| Construct factor from iterator keys.
|
|
template<typename CONTAINER > |
static Factor | FromKeys (const CONTAINER &keys) |
| Construct factor from container of keys.
|
|
template<typename ITERATOR > |
static Factor | FromIterators (ITERATOR first, ITERATOR last) |
| Construct factor from iterator keys.
|
|
DiscreteKeys | discreteKeys_ |
|
KeyVector | continuousKeys_ |
| Record continuous keys for book-keeping.
|
|
KeyVector | keys_ |
| The keys involved in this factor.
|
|