117 virtual bool equals(
const ISAM2& other,
double tol = 1e-9)
const;
156 const boost::optional<
FastList<Key> >& noRelinKeys = boost::none,
157 const boost::optional<
FastList<Key> >& extraReelimKeys = boost::none,
158 bool force_relinearize =
false);
199 void marginalizeLeaves(
201 boost::optional<FactorIndices&> marginalFactorsIndices = boost::none,
202 boost::optional<FactorIndices&> deletedFactorsIndices = boost::none);
215 Values calculateEstimate()
const;
223 template <
class VALUE>
225 const Vector& delta = getDelta()[key];
237 const Value& calculateEstimate(
Key key)
const;
240 Matrix marginalCovariance(
Key key)
const;
248 Values calculateBestEstimate()
const;
258 return nonlinearFactors_;
267 const ISAM2Params& params()
const {
return params_; }
270 void printStats()
const { getCliqueData().getStats().print(); }
301 KeySet* affectedKeysSet, Cliques* orphans,
309 void addVariables(
const Values& newTheta,
315 void removeVariables(
const KeySet& unusedKeys);
317 void updateDelta(
bool forceFullSolve =
false)
const;
321 friend class boost::serialization::access;
322 template<
class ARCHIVE>
323 void serialize(ARCHIVE & ar,
const unsigned int ) {
324 ar & boost::serialization::base_object<BayesTree<ISAM2Clique> >(*this);
325 ar & BOOST_SERIALIZATION_NVP(theta_);
326 ar & BOOST_SERIALIZATION_NVP(variableIndex_);
327 ar & BOOST_SERIALIZATION_NVP(delta_);
328 ar & BOOST_SERIALIZATION_NVP(deltaNewton_);
329 ar & BOOST_SERIALIZATION_NVP(RgProd_);
330 ar & BOOST_SERIALIZATION_NVP(deltaReplacedMask_);
331 ar & BOOST_SERIALIZATION_NVP(nonlinearFactors_);
332 ar & BOOST_SERIALIZATION_NVP(linearFactors_);
333 ar & BOOST_SERIALIZATION_NVP(doglegDelta_);
334 ar & BOOST_SERIALIZATION_NVP(fixedVariables_);
335 ar & BOOST_SERIALIZATION_NVP(update_count_);
Gaussian Bayes Tree, the result of eliminating a GaussianJunctionTree.
Specialized iSAM2 Clique.
Factor Graph consisting of non-linear factors.
Class that stores detailed iSAM2 result.
Class that stores extra params for ISAM2::update()
Global functions in a separate testing namespace.
Definition: chartTesting.h:28
std::string serialize(const T &input)
serializes to a string
Definition: serialization.h:112
FastVector< FactorIndex > FactorIndices
Define collection types:
Definition: Factor.h:33
std::uint64_t Key
Integer nonlinear key type.
Definition: types.h:69
A manifold defines a space in which there is a notion of a linear tangent space that can be centered ...
Definition: concepts.h:30
Definition: FastList.h:40
Template to create a binary predicate.
Definition: Testable.h:111
A helper that implements the traits interface for GTSAM types.
Definition: Testable.h:151
This is the base class for any type to be stored in Values.
Definition: Value.h:36
Definition: BayesTree.h:67
boost::shared_ptr< Clique > sharedClique
Shared pointer to a clique.
Definition: BayesTree.h:74
The VariableIndex class computes and stores the block column structure of a factor graph.
Definition: VariableIndex.h:43
A Linear Factor Graph is a factor graph where all factors are Gaussian, i.e.
Definition: GaussianFactorGraph.h:69
This class represents a collection of vector-valued variables associated each with a unique integer i...
Definition: VectorValues.h:74
KeySet fixedVariables_
Set of variables that are involved with linear factors from marginalized variables and thus cannot ha...
Definition: ISAM2.h:94
KeySet deltaReplacedMask_
A cumulative mask for the variables that were replaced and have not yet been updated in the linear so...
Definition: ISAM2.h:76
int update_count_
Counter incremented every update(), used to determine periodic relinearization.
Definition: ISAM2.h:96
VALUE calculateEstimate(Key key) const
Compute an estimate for a single variable using its incomplete linear delta computed during the last ...
Definition: ISAM2.h:224
virtual ~ISAM2()
default virtual destructor
Definition: ISAM2.h:114
const KeySet & getFixedVariables() const
Access the nonlinear variable index.
Definition: ISAM2.h:265
Base::Cliques Cliques
List of Cliques.
Definition: ISAM2.h:104
void printStats() const
prints out clique statistics
Definition: ISAM2.h:270
NonlinearFactorGraph nonlinearFactors_
All original nonlinear factors are stored here to use during relinearization.
Definition: ISAM2.h:81
const VariableIndex & getVariableIndex() const
Access the nonlinear variable index.
Definition: ISAM2.h:262
Base::sharedClique sharedClique
Shared pointer to a clique.
Definition: ISAM2.h:103
VectorValues delta_
The linear delta from the last linear solution, an update to the estimate in theta.
Definition: ISAM2.h:61
VariableIndex variableIndex_
VariableIndex lets us look up factors by involved variable and keeps track of dimensions.
Definition: ISAM2.h:52
const Values & getLinearizationPoint() const
Access the current linearization point.
Definition: ISAM2.h:205
Values theta_
The current linearization point.
Definition: ISAM2.h:48
ISAM2Params params_
The current parameters.
Definition: ISAM2.h:87
boost::optional< double > doglegDelta_
The current Dogleg Delta (trust region radius)
Definition: ISAM2.h:90
GaussianFactorGraph linearFactors_
The current linear factors, which are only updated as needed.
Definition: ISAM2.h:84
const NonlinearFactorGraph & getFactorsUnsafe() const
Access the set of nonlinear factors.
Definition: ISAM2.h:257
bool valueExists(Key key) const
Check whether variable with given key exists in linearization point.
Definition: ISAM2.h:208
Specialized Clique structure for ISAM2, incorporating caching and gradient contribution TODO: more do...
Definition: ISAM2Clique.h:37
Definition: ISAM2Params.h:135
Definition: ISAM2Result.h:41
A struct holding detailed results, which must be enabled with ISAM2Params::enableDetailedResults.
Definition: ISAM2Result.h:117
Definition: ISAM2UpdateParams.h:32
A non-linear factor graph is a graph of non-Gaussian, i.e.
Definition: NonlinearFactorGraph.h:78
A non-templated config holding any types of Manifold-group elements.
Definition: Values.h:63
const ValueType at(Key j) const
Retrieve a variable by key j.
Definition: Values-inl.h:346
bool exists(Key j) const
Check if a value exists with key j.
Definition: Values.cpp:96