add print
parent
b092fee64b
commit
744269343f
|
@ -33,6 +33,17 @@ namespace gtsam {
|
||||||
|
|
||||||
// initialize non-linear solver
|
// initialize non-linear solver
|
||||||
solver_.initialize(*graph_, *theta_);
|
solver_.initialize(*graph_, *theta_);
|
||||||
|
|
||||||
|
linearize();
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ************************************************************************* */
|
||||||
|
void Pose2SLAMOptimizer::print(const string& str) const {
|
||||||
|
GTSAM_PRINT(*graph_);
|
||||||
|
GTSAM_PRINT(*theta_);
|
||||||
|
//TODO
|
||||||
|
//GTSAM_PRINT(solver_);
|
||||||
|
GTSAM_PRINT(*system_);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* ************************************************************************* */
|
/* ************************************************************************* */
|
||||||
|
|
|
@ -44,6 +44,11 @@ namespace gtsam {
|
||||||
Pose2SLAMOptimizer(const std::string& dataset = "",
|
Pose2SLAMOptimizer(const std::string& dataset = "",
|
||||||
const std::string& path = "");
|
const std::string& path = "");
|
||||||
|
|
||||||
|
/**
|
||||||
|
* print the object
|
||||||
|
*/
|
||||||
|
void print(const std::string& str = "") const;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Virtual destructor
|
* Virtual destructor
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
class Pose2SLAMOptimizer {
|
class Pose2SLAMOptimizer {
|
||||||
Pose2SLAMOptimizer(string dataset_name);
|
Pose2SLAMOptimizer(string dataset_name);
|
||||||
|
void print(string s) const;
|
||||||
void update(Vector x) const;
|
void update(Vector x) const;
|
||||||
Vector optimize() const;
|
Vector optimize() const;
|
||||||
double error() const;
|
double error() const;
|
||||||
|
|
Loading…
Reference in New Issue