diff --git a/include/core/factor/factor_base.h b/include/core/factor/factor_base.h index be2ae385fcf6935409c7dd00545a487732edfa5f..42089e0e52bbc769bc5e3dc88a98cfa9ba6402e1 100644 --- a/include/core/factor/factor_base.h +++ b/include/core/factor/factor_base.h @@ -136,7 +136,7 @@ class FactorBase : public NodeBase, public std::enable_shared_from_this<FactorBa /** \brief Gets the apply loss function flag */ - void setApplyLossFunction(const bool _apply); + //void setApplyLossFunction(const bool _apply); /** \brief Returns a pointer to the frame constrained to **/ diff --git a/src/factor/factor_base.cpp b/src/factor/factor_base.cpp index 23c0140c17c724481c5c35c948d29fcb640d4c4b..bd5751fa868b8b6a8b42eb610b7fdf79279b42c3 100644 --- a/src/factor/factor_base.cpp +++ b/src/factor/factor_base.cpp @@ -131,20 +131,11 @@ void FactorBase::setStatus(FactorStatus _status) status_ = _status; } -void FactorBase::setApplyLossFunction(const bool _apply) -{ - if (apply_loss_function_ != _apply) - { - if (getProblem() == nullptr) - std::cout << "factor not linked with Problem, apply loss function change not notified" << std::endl; - else - { - FactorBasePtr this_c = shared_from_this(); - getProblem()->removeFactor(this_c); - getProblem()->addFactor(this_c); - } - } -} +//void FactorBase::setApplyLossFunction(const bool _apply) +//{ +// apply_loss_function_ = _apply; +//} + void FactorBase::link(FeatureBasePtr _ftr_ptr) { if (this->getFeature() != _ftr_ptr)