g2o
Loading...
Searching...
No Matches
graph_optimizer_sparse_incremental.h
Go to the documentation of this file.
1// g2o - General Graph Optimization
2// Copyright (C) 2011 R. Kuemmerle, G. Grisetti, W. Burgard
3//
4// g2o is free software: you can redistribute it and/or modify
5// it under the terms of the GNU General Public License as published
6// by the Free Software Foundation, either version 3 of the License, or
7// (at your option) any later version.
8//
9// g2o is distributed in the hope that it will be useful,
10// but WITHOUT ANY WARRANTY; without even the implied warranty of
11// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12// GNU General Public License for more details.
13//
14// You should have received a copy of the GNU General Public License
15// along with this program. If not, see <http://www.gnu.org/licenses/>.
16
17#ifndef G2O_GRAPH_OPTIMIZER_SPARSE_INCREMENTAL_H
18#define G2O_GRAPH_OPTIMIZER_SPARSE_INCREMENTAL_H
19
22#include "g2o_incremental_api.h"
24
25namespace g2o {
26
27namespace cholmod {
28struct CholmodExt;
29}
30
32 : public SparseOptimizerOnline {
33 public:
36
37 int optimize(int iterations, bool online = false);
38
39 virtual bool updateInitialization(HyperGraph::VertexSet& vset,
41
42 virtual bool initSolver(int dimension, int batchEveryN);
43
44 protected:
46 cholmod_common _cholmodCommon;
48 cholmod_factor* _cholmodFactor;
49 cholmod_triplet* _permutedUpdate;
50 cholmod_factor* _L;
52
54 Eigen::VectorXi _perm;
55 Eigen::VectorXi _cmember;
56
57 Eigen::VectorXi _tripletWorkspace;
59
60 bool computeCholeskyUpdate();
61 void convertTripletUpdateToSparse();
62};
63
64} // namespace g2o
65
66#endif
std::set< Edge * > EdgeSet
std::set< Vertex * > VertexSet
generic interface for the online solver
Sparse matrix which uses blocks.
SparseBlockMatrix< Eigen::MatrixXd > _updateMat
LinearSolverCholmodOnlineInterface * _solverInterface
#define G2O_INCREMENTAL_API
Our extension of the CHOLMOD matrix struct.
Definition cholmod_ext.h:38