override operator/ in TableDistribution
parent
96a136b4e3
commit
3fb6f39b30
|
@ -111,6 +111,12 @@ DiscreteFactor::shared_ptr TableDistribution::max(const Ordering& keys) const {
|
|||
return table_.max(keys);
|
||||
}
|
||||
|
||||
/* ****************************************************************************/
|
||||
DiscreteFactor::shared_ptr TableDistribution::operator/(
|
||||
const DiscreteFactor::shared_ptr& f) const {
|
||||
return table_ / f;
|
||||
}
|
||||
|
||||
/* ************************************************************************ */
|
||||
DiscreteValues TableDistribution::argmax() const {
|
||||
uint64_t maxIdx = 0;
|
||||
|
|
|
@ -123,6 +123,10 @@ class GTSAM_EXPORT TableDistribution : public DiscreteConditional {
|
|||
/// Create new factor by maximizing over all values with the same separator.
|
||||
DiscreteFactor::shared_ptr max(const Ordering& keys) const override;
|
||||
|
||||
/// divide by DiscreteFactor::shared_ptr f (safely)
|
||||
DiscreteFactor::shared_ptr operator/(
|
||||
const DiscreteFactor::shared_ptr& f) const override;
|
||||
|
||||
/**
|
||||
* @brief Return assignment that maximizes value.
|
||||
*
|
||||
|
|
Loading…
Reference in New Issue