|
GTSAM
4.0.2
C++ library for smoothing and mapping (SAM)
|
#include <GaussNewtonOptimizer.h>


Public Types | |
| using | shared_ptr = std::shared_ptr< const NonlinearOptimizer > |
Public Member Functions | |
Standard interface | |
| GaussNewtonOptimizer (const NonlinearFactorGraph &graph, const Values &initialValues, const GaussNewtonParams ¶ms=GaussNewtonParams()) | |
| GaussNewtonOptimizer (const NonlinearFactorGraph &graph, const Values &initialValues, const Ordering &ordering) | |
Advanced interface | |
| ~GaussNewtonOptimizer () override | |
| GaussianFactorGraph::shared_ptr | iterate () override |
| const GaussNewtonParams & | params () const |
Standard interface | |
| virtual const Values & | optimize () |
| const Values & | optimizeSafely () |
| double | error () const |
| return error in current optimizer state | |
| size_t | iterations () const |
| return number of iterations in current optimizer state | |
| const Values & | values () const |
| return values in current optimizer state | |
| const NonlinearFactorGraph & | graph () const |
| return the graph with nonlinear factors | |
Advanced interface | |
| virtual VectorValues | solve (const GaussianFactorGraph &gfg, const NonlinearOptimizerParams ¶ms) const |
Protected Member Functions | |
| const NonlinearOptimizerParams & | _params () const override |
| GaussNewtonParams | ensureHasOrdering (GaussNewtonParams params, const NonlinearFactorGraph &graph) const |
| void | defaultOptimize () |
Protected Attributes | |
| GaussNewtonParams | params_ |
| NonlinearFactorGraph | graph_ |
| The graph with nonlinear factors. | |
| std::unique_ptr< internal::NonlinearOptimizerState > | state_ |
| PIMPL'd state. | |
This class performs Gauss-Newton nonlinear optimization
|
inherited |
A shared pointer to this class
| gtsam::GaussNewtonOptimizer::GaussNewtonOptimizer | ( | const NonlinearFactorGraph & | graph, |
| const Values & | initialValues, | ||
| const GaussNewtonParams & | params = GaussNewtonParams() |
||
| ) |
Standard constructor, requires a nonlinear factor graph, initial variable assignments, and optimization parameters. For convenience this version takes plain objects instead of shared pointers, but internally copies the objects.
| graph | The nonlinear factor graph to optimize |
| initialValues | The initial variable assignments |
| params | The optimization parameters |
| gtsam::GaussNewtonOptimizer::GaussNewtonOptimizer | ( | const NonlinearFactorGraph & | graph, |
| const Values & | initialValues, | ||
| const Ordering & | ordering | ||
| ) |
Standard constructor, requires a nonlinear factor graph, initial variable assignments, and optimization parameters. For convenience this version takes plain objects instead of shared pointers, but internally copies the objects.
| graph | The nonlinear factor graph to optimize |
| initialValues | The initial variable assignments |
|
inlineoverride |
Virtual destructor
|
inlineoverrideprotectedvirtual |
Access the parameters (base class version)
Implements gtsam::NonlinearOptimizer.
|
protectedinherited |
A default implementation of the optimization loop, which calls iterate() until checkConvergence returns true.
|
protected |
Internal function for computing a COLAMD ordering if no ordering is specified
|
overridevirtual |
Perform a single iteration, returning GaussianFactorGraph corresponding to the linearized factor graph.
Implements gtsam::NonlinearOptimizer.
|
inlinevirtualinherited |
Optimize for the maximum-likelihood estimate, returning a the optimized variable assignments.
This function simply calls iterate() in a loop, checking for convergence with check_convergence(). For fine-grain control over the optimization process, you may call iterate() and check_convergence() yourself, and if needed modify the optimization state between iterations.
Reimplemented in gtsam::NonlinearConjugateGradientOptimizer.
|
inherited |
Optimize, but return empty result if any uncaught exception is thrown Intended for MATLAB. In C++, use above and catch exceptions. No message is printed: it is up to the caller to check the result
| optimizer | a non-linear optimizer |
|
inline |
Read-only access the parameters
|
virtualinherited |
Default function to do linear solve, i.e. optimize a GaussianFactorGraph
1.8.13