NDEVR
API Documentation
OptimizationAlgorithmWithHessian< t_solver >

Base for solvers operating on the approximated Hessian, e.g., Gauss-Newton, Levenberg. More...

Inheritance diagram for OptimizationAlgorithmWithHessian< t_solver >:
[legend]
Collaboration diagram for OptimizationAlgorithmWithHessian< t_solver >:
[legend]

Public Member Functions

 OptimizationAlgorithmWithHessian ()
 Default constructor.
void addEdge (HyperGraph::HGEdge *e)
 Adds an edge to the optimizer.
void addVertex (HyperGraph::HGVertex &v)
 Adds a vertex to the optimizer.
bool buildLinearStructure (IndexScratch &scratch)
 Builds the linear system structure.
void clear ()
 Clears the solver state.
bool init (bool online=false)
 Initializes the solver, detecting whether Schur complement should be used.
SparseOptimizeroptimizer ()
 Returns a mutable reference to the underlying sparse optimizer.
const SparseOptimizeroptimizer () const
 Returns a const reference to the underlying sparse optimizer.
void updateLinearSystem ()
 Rebuilds the linear system (Hessian and gradient) from the current graph state.
bool updateStructure (const Buffer< HyperGraph::HGVertex * > &vset, const Set< HyperGraph::HGVertex * > &edges)
 Updates the linear system structure after graph topology changes.

Public Attributes

t_solver solver
 The underlying solver instance.

Additional Inherited Members

Public Types inherited from OptimizationAlgorithm
enum  SolverResult { Terminate =2 , OK =1 , Fail =-1 }
 Result codes returned by the solver after each iteration. More...

Detailed Description

template<class t_solver>
class OptimizationAlgorithmWithHessian< t_solver >

Base for solvers operating on the approximated Hessian, e.g., Gauss-Newton, Levenberg.

Definition at line 14 of file optimization_algorithm_with_hessian.h.

Member Function Documentation

◆ addEdge()

template<class t_solver>
void OptimizationAlgorithmWithHessian< t_solver >::addEdge ( HyperGraph::HGEdge * e)
inline

Adds an edge to the optimizer.

Parameters
[in]eThe edge to add.

Definition at line 36 of file optimization_algorithm_with_hessian.h.

References solver.

◆ addVertex()

template<class t_solver>
void OptimizationAlgorithmWithHessian< t_solver >::addVertex ( HyperGraph::HGVertex & v)
inline

Adds a vertex to the optimizer.

Parameters
[in]vThe vertex to add.

Definition at line 30 of file optimization_algorithm_with_hessian.h.

References solver.

◆ buildLinearStructure()

template<class t_solver>
bool OptimizationAlgorithmWithHessian< t_solver >::buildLinearStructure ( IndexScratch & scratch)
inline

Builds the linear system structure.

Parameters
[in]scratchScratch buffers for pose and landmark indices.
Returns
True on success.

Definition at line 82 of file optimization_algorithm_with_hessian.h.

References solver.

◆ init()

template<class t_solver>
bool OptimizationAlgorithmWithHessian< t_solver >::init ( bool online = false)
inline

Initializes the solver, detecting whether Schur complement should be used.

Parameters
[in]onlineWhether this is an online (incremental) optimization.
Returns
True on success.

Definition at line 53 of file optimization_algorithm_with_hessian.h.

References optimizer(), and solver.

Referenced by OptimizationAlgorithmGaussNewton< t_type >::optimize(), and OptimizationAlgorithmLevenberg< t_type >::optimize().

◆ updateStructure()

template<class t_solver>
bool OptimizationAlgorithmWithHessian< t_solver >::updateStructure ( const Buffer< HyperGraph::HGVertex * > & vset,
const Set< HyperGraph::HGVertex * > & edges )
inline

Updates the linear system structure after graph topology changes.

Parameters
[in]vsetThe updated vertex set.
[in]edgesThe updated edge set.
Returns
True on success.

Definition at line 97 of file optimization_algorithm_with_hessian.h.

References solver.


The documentation for this class was generated from the following file: