26 template<
class BAYESTREE>
28 Cliques* orphans,
const Eliminate&
function) {
31 const KeySet newFactorKeys = newFactors.keys();
33 KeyVector keyVector(newFactorKeys.begin(), newFactorKeys.end());
34 this->removeTop(keyVector, &bn, orphans);
38 FactorGraphType factors;
39 factors.push_back(bn);
40 factors.push_back(newFactors);
44 factors.template emplace_shared<BayesTreeOrphanWrapper<Clique> >(orphan);
49 KeyVector(newFactorKeys.begin(), newFactorKeys.end()));
52 auto bayesTree = factors.eliminateMultifrontal(ordering,
function, std::cref(index));
55 this->roots_.insert(this->roots_.end(), bayesTree->roots().begin(),
56 bayesTree->roots().end());
57 this->nodes_.insert(bayesTree->nodes().begin(), bayesTree->nodes().end());
61 template<
class BAYESTREE>
63 const Eliminate&
function) {
65 this->updateInternal(newFactors, &orphans,
function);
void update(const FactorGraphType &newFactors, const Eliminate &function=EliminationTraitsType::DefaultEliminate)
Definition: ISAM-inst.h:62
Definition: Ordering.h:37
std::shared_ptr< Clique > sharedClique
Shared pointer to a clique.
Definition: BayesTree.h:74
Definition: FastList.h:43
Incremental update functionality (iSAM) for BayesTree.
Definition: chartTesting.h:28
void updateInternal(const FactorGraphType &newFactors, Cliques *orphans, const Eliminate &function=EliminationTraitsType::DefaultEliminate)
Definition: ISAM-inst.h:27
FastVector< Key > KeyVector
Define collection type once and for all - also used in wrappers.
Definition: Key.h:86
Definition: VariableIndex.h:41
static Ordering ColamdConstrainedLast(const FACTOR_GRAPH &graph, const KeyVector &constrainLast, bool forceOrder=false)
Definition: Ordering.h:119