#include <Optimizer.h>
Public Types | |
enum | Type { kTypeUndef = -1, kTypeTORO = 0, kTypeG2O = 1, kTypeGTSAM = 2, kTypeCeres = 3, kTypeCVSBA = 4 } |
Public Member Functions | |
void | computeBACorrespondences (const std::map< int, Transform > &poses, const std::multimap< int, Link > &links, const std::map< int, Signature > &signatures, std::map< int, cv::Point3f > &points3DMap, std::map< int, std::map< int, FeatureBA > > &wordReferences, bool rematchFeatures=false) |
double | epsilon () const |
void | getConnectedGraph (int fromId, const std::map< int, Transform > &posesIn, const std::multimap< int, Link > &linksIn, std::map< int, Transform > &posesOut, std::multimap< int, Link > &linksOut, bool adjustPosesWithConstraints=true) const |
float | gravitySigma () const |
bool | isCovarianceIgnored () const |
bool | isRobust () const |
bool | isSlam2d () const |
int | iterations () const |
bool | landmarksIgnored () const |
std::map< int, Transform > | optimize (int rootId, const std::map< int, Transform > &poses, const std::multimap< int, Link > &constraints, std::list< std::map< int, Transform > > *intermediateGraphes=0, double *finalError=0, int *iterationsDone=0) |
virtual std::map< int, Transform > | optimize (int rootId, const std::map< int, Transform > &poses, const std::multimap< int, Link > &constraints, cv::Mat &outputCovariance, std::list< std::map< int, Transform > > *intermediateGraphes=0, double *finalError=0, int *iterationsDone=0) |
virtual std::map< int, Transform > | optimizeBA (int rootId, const std::map< int, Transform > &poses, const std::multimap< int, Link > &links, const std::map< int, std::vector< CameraModel > > &models, std::map< int, cv::Point3f > &points3DMap, const std::map< int, std::map< int, FeatureBA > > &wordReferences, std::set< int > *outliers=0) |
std::map< int, Transform > | optimizeBA (int rootId, const std::map< int, Transform > &poses, const std::multimap< int, Link > &links, const std::map< int, Signature > &signatures, std::map< int, cv::Point3f > &points3DMap, std::map< int, std::map< int, FeatureBA > > &wordReferences, bool rematchFeatures=false) |
std::map< int, Transform > | optimizeBA (int rootId, const std::map< int, Transform > &poses, const std::multimap< int, Link > &links, const std::map< int, Signature > &signatures, bool rematchFeatures=false) |
Transform | optimizeBA (const Link &link, const CameraModel &model, std::map< int, cv::Point3f > &points3DMap, const std::map< int, std::map< int, FeatureBA > > &wordReferences, std::set< int > *outliers=0) |
std::map< int, Transform > | optimizeIncremental (int rootId, const std::map< int, Transform > &poses, const std::multimap< int, Link > &constraints, std::list< std::map< int, Transform > > *intermediateGraphes=0, double *finalError=0, int *iterationsDone=0) |
virtual void | parseParameters (const ParametersMap ¶meters) |
bool | priorsIgnored () const |
void | setCovarianceIgnored (bool enabled) |
void | setEpsilon (double epsilon) |
void | setGravitySigma (float value) |
void | setIterations (int iterations) |
void | setLandmarksIgnored (bool enabled) |
void | setPriorsIgnored (bool enabled) |
void | setRobust (bool enabled) |
void | setSlam2d (bool enabled) |
virtual Type | type () const =0 |
virtual | ~Optimizer () |
Static Public Member Functions | |
static Optimizer * | create (const ParametersMap ¶meters) |
static Optimizer * | create (Optimizer::Type type, const ParametersMap ¶meters=ParametersMap()) |
static bool | isAvailable (Optimizer::Type type) |
Protected Member Functions | |
Optimizer (int iterations=Parameters::defaultOptimizerIterations(), bool slam2d=Parameters::defaultRegForce3DoF(), bool covarianceIgnored=Parameters::defaultOptimizerVarianceIgnored(), double epsilon=Parameters::defaultOptimizerEpsilon(), bool robust=Parameters::defaultOptimizerRobust(), bool priorsIgnored=Parameters::defaultOptimizerPriorsIgnored(), bool landmarksIgnored=Parameters::defaultOptimizerLandmarksIgnored(), float gravitySigma=Parameters::defaultOptimizerGravitySigma()) | |
Optimizer (const ParametersMap ¶meters) | |
Private Attributes | |
bool | covarianceIgnored_ |
double | epsilon_ |
float | gravitySigma_ |
int | iterations_ |
bool | landmarksIgnored_ |
bool | priorsIgnored_ |
bool | robust_ |
bool | slam2d_ |
Definition at line 61 of file Optimizer.h.
Enumerator | |
---|---|
kTypeUndef | |
kTypeTORO | |
kTypeG2O | |
kTypeGTSAM | |
kTypeCeres | |
kTypeCVSBA |
Definition at line 64 of file Optimizer.h.
|
inlinevirtual |
Definition at line 86 of file Optimizer.h.
|
protected |
Definition at line 304 of file Optimizer.cpp.
|
protected |
Definition at line 316 of file Optimizer.cpp.
void rtabmap::Optimizer::computeBACorrespondences | ( | const std::map< int, Transform > & | poses, |
const std::multimap< int, Link > & | links, | ||
const std::map< int, Signature > & | signatures, | ||
std::map< int, cv::Point3f > & | points3DMap, | ||
std::map< int, std::map< int, FeatureBA > > & | wordReferences, | ||
bool | rematchFeatures = false |
||
) |
Definition at line 560 of file Optimizer.cpp.
|
static |
Definition at line 72 of file Optimizer.cpp.
|
static |
Definition at line 79 of file Optimizer.cpp.
|
inline |
Definition at line 94 of file Optimizer.h.
void rtabmap::Optimizer::getConnectedGraph | ( | int | fromId, |
const std::map< int, Transform > & | posesIn, | ||
const std::multimap< int, Link > & | linksIn, | ||
std::map< int, Transform > & | posesOut, | ||
std::multimap< int, Link > & | linksOut, | ||
bool | adjustPosesWithConstraints = true |
||
) | const |
Definition at line 188 of file Optimizer.cpp.
|
inline |
Definition at line 98 of file Optimizer.h.
|
static |
Definition at line 47 of file Optimizer.cpp.
|
inline |
Definition at line 93 of file Optimizer.h.
|
inline |
Definition at line 95 of file Optimizer.h.
|
inline |
Definition at line 92 of file Optimizer.h.
|
inline |
Definition at line 91 of file Optimizer.h.
|
inline |
Definition at line 97 of file Optimizer.h.
std::map< int, Transform > rtabmap::Optimizer::optimize | ( | int | rootId, |
const std::map< int, Transform > & | poses, | ||
const std::multimap< int, Link > & | constraints, | ||
std::list< std::map< int, Transform > > * | intermediateGraphes = 0 , |
||
double * | finalError = 0 , |
||
int * | iterationsDone = 0 |
||
) |
Definition at line 406 of file Optimizer.cpp.
|
virtual |
Reimplemented in rtabmap::OptimizerTORO, rtabmap::OptimizerCeres, rtabmap::OptimizerGTSAM, and rtabmap::OptimizerG2O.
Definition at line 424 of file Optimizer.cpp.
|
virtual |
Reimplemented in rtabmap::OptimizerG2O, and rtabmap::OptimizerCVSBA.
Definition at line 437 of file Optimizer.cpp.
std::map< int, Transform > rtabmap::Optimizer::optimizeBA | ( | int | rootId, |
const std::map< int, Transform > & | poses, | ||
const std::multimap< int, Link > & | links, | ||
const std::map< int, Signature > & | signatures, | ||
std::map< int, cv::Point3f > & | points3DMap, | ||
std::map< int, std::map< int, FeatureBA > > & | wordReferences, | ||
bool | rematchFeatures = false |
||
) |
Definition at line 450 of file Optimizer.cpp.
std::map< int, Transform > rtabmap::Optimizer::optimizeBA | ( | int | rootId, |
const std::map< int, Transform > & | poses, | ||
const std::multimap< int, Link > & | links, | ||
const std::map< int, Signature > & | signatures, | ||
bool | rematchFeatures = false |
||
) |
Definition at line 512 of file Optimizer.cpp.
Transform rtabmap::Optimizer::optimizeBA | ( | const Link & | link, |
const CameraModel & | model, | ||
std::map< int, cv::Point3f > & | points3DMap, | ||
const std::map< int, std::map< int, FeatureBA > > & | wordReferences, | ||
std::set< int > * | outliers = 0 |
||
) |
Definition at line 524 of file Optimizer.cpp.
std::map< int, Transform > rtabmap::Optimizer::optimizeIncremental | ( | int | rootId, |
const std::map< int, Transform > & | poses, | ||
const std::multimap< int, Link > & | constraints, | ||
std::list< std::map< int, Transform > > * | intermediateGraphes = 0 , |
||
double * | finalError = 0 , |
||
int * | iterationsDone = 0 |
||
) |
Definition at line 341 of file Optimizer.cpp.
|
virtual |
Reimplemented in rtabmap::OptimizerGTSAM, and rtabmap::OptimizerG2O.
Definition at line 329 of file Optimizer.cpp.
|
inline |
Definition at line 96 of file Optimizer.h.
|
inline |
Definition at line 103 of file Optimizer.h.
|
inline |
Definition at line 104 of file Optimizer.h.
|
inline |
Definition at line 108 of file Optimizer.h.
|
inline |
Definition at line 101 of file Optimizer.h.
|
inline |
Definition at line 107 of file Optimizer.h.
|
inline |
Definition at line 106 of file Optimizer.h.
|
inline |
Definition at line 105 of file Optimizer.h.
|
inline |
Definition at line 102 of file Optimizer.h.
|
pure virtual |
Implemented in rtabmap::OptimizerTORO, rtabmap::OptimizerCeres, rtabmap::OptimizerCVSBA, rtabmap::OptimizerGTSAM, and rtabmap::OptimizerG2O.
|
private |
Definition at line 192 of file Optimizer.h.
|
private |
Definition at line 193 of file Optimizer.h.
|
private |
Definition at line 197 of file Optimizer.h.
|
private |
Definition at line 190 of file Optimizer.h.
|
private |
Definition at line 196 of file Optimizer.h.
|
private |
Definition at line 195 of file Optimizer.h.
|
private |
Definition at line 194 of file Optimizer.h.
|
private |
Definition at line 191 of file Optimizer.h.