setData method

release/4.3a0
Varun Agrawal 2024-12-30 23:02:26 -05:00
parent b57e448232
commit d18f23c47b
2 changed files with 8 additions and 0 deletions

View File

@ -483,6 +483,11 @@ double DiscreteConditional::evaluate(const Assignment<Key>& values) const {
return BaseFactor::evaluate(values);
}
/* ************************************************************************* */
double DiscreteConditional::setData(const DiscreteConditional::shared_ptr& dc) {
this->root_ = dc->root_;
}
/* ************************************************************************* */
double DiscreteConditional::negLogConstant() const { return 0.0; }

View File

@ -270,6 +270,9 @@ class GTSAM_EXPORT DiscreteConditional
*/
double negLogConstant() const override;
/// Set the data from another DiscreteConditional.
virtual void setData(const DiscreteConditional::shared_ptr& dc);
/// @}
protected: