SLProject 4.0.000
WAISlamTools Class Reference

#include <WAISlamTools.h>

Inheritance diagram for WAISlamTools:
[legend]

Static Public Member Functions

static void drawKeyPointInfo (WAIFrame &frame, cv::Mat &image, float scale)
 
static void drawKeyPointMatches (WAIFrame &frame, cv::Mat &image, float scale)
 
static void drawInitInfo (WAIInitializerData &iniData, WAIFrame &frame, cv::Mat &imageBGR, float scale)
 
static bool initialize (WAIInitializerData &iniData, WAIFrame &frame, WAIOrbVocabulary *voc, LocalMap &localMap, int mapPointsNeeded=100)
 
static bool genInitialMap (WAIMap *globalMap, LocalMapping *localMapper, LoopClosing *loopCloser, LocalMap &localMap)
 
static bool oldInitialize (WAIFrame &frame, WAIInitializerData &iniData, WAIMap *map, LocalMap &localMap, LocalMapping *localMapper, LoopClosing *loopCloser, WAIOrbVocabulary *voc, int mapPointsNeeded=100)
 
static int findFrameFixedMapMatches (WAIFrame &frame, WAIMap *waiMap, std::vector< cv::Point2f > &points2d, std::vector< cv::Point3f > &points3d)
 
static bool relocalization (WAIFrame &currentFrame, WAIMap *waiMap, LocalMap &localMap, float minCommonWordFactor, int &inliers, bool minAccScoreFilter=false)
 
static bool relocalizationGPS (WAIFrame &currentFrame, WAIMap *waiMap, LocalMap &localMap, cv::Mat locENU, cv::Mat dirENU, float minCommonWordFactor, int &inliers, bool minAccScoreFilter)
 
static bool tracking (WAIMap *map, LocalMap &localMap, WAIFrame &frame, WAIFrame &lastFrame, int lastRelocFrameId, cv::Mat &velocity, int &inliers)
 
static bool strictTracking (WAIMap *map, LocalMap &localMap, WAIFrame &frame, WAIFrame &lastFrame, int lastRelocFrameId, int &inliers)
 
static bool trackLocalMap (LocalMap &localMap, WAIFrame &frame, int lastRelocFrameId, int &inliers)
 
static void mapping (WAIMap *map, LocalMap &localMap, LocalMapping *localMapper, WAIFrame &frame, int inliers, const unsigned long lastRelocFrameId, unsigned long &lastKeyFrameFrameId)
 
static void strictMapping (WAIMap *map, LocalMap &localMap, LocalMapping *localMapper, WAIFrame &frame, int inliers, const unsigned long lastRelocFrameId, unsigned long &lastKeyFrameFrameId)
 
static void motionModel (WAIFrame &frame, WAIFrame &lastFrame, cv::Mat &velocity, cv::Mat &pose)
 
static bool trackReferenceKeyFrame (LocalMap &map, WAIFrame &lastFrame, WAIFrame &frame)
 
static bool strictTrackReferenceKeyFrame (LocalMap &map, WAIFrame &lastFrame, WAIFrame &frame)
 
static bool trackWithMotionModel (cv::Mat velocity, WAIFrame &previousFrame, WAIFrame &frame)
 
static void updateLocalMap (WAIFrame &frame, LocalMap &localMap)
 
static int trackLocalMapPoints (LocalMap &localMap, int lastRelocFrameId, WAIFrame &frame)
 
static bool needNewKeyFrame (WAIMap *globalMap, LocalMap &localMap, LocalMapping *localMapper, WAIFrame &frame, int nInliners, const unsigned long lastRelocFrameId, const unsigned long lastKeyFrameFrameId)
 
static bool strictNeedNewKeyFrame (WAIMap *map, LocalMap &localMap, LocalMapping *localMapper, WAIFrame &frame, int nInliers, const unsigned long lastRelocFrameId, const unsigned long lastKeyFrameFrameId)
 
static void createNewKeyFrame (LocalMapping *localMapper, LocalMap &localMap, WAIMap *globalMap, WAIFrame &frame, unsigned long &lastKeyFrameFrameId)
 
static WAIFrame createMarkerFrame (std::string markerFile, KPextractor *markerExtractor, const cv::Mat &markerCameraIntrinsic, WAIOrbVocabulary *voc)
 
static bool findMarkerHomography (WAIFrame &markerFrame, WAIKeyFrame *kfCand, cv::Mat &homography, int minMatches)
 
static bool doMarkerMapPreprocessing (std::string markerFile, cv::Mat &nodeTransform, float markerWidthInM, KPextractor *markerExtractor, WAIMap *map, const cv::Mat &markerCameraIntrinsic, WAIOrbVocabulary *voc)
 
static bool detectCycle (WAIKeyFrame *kf, std::set< WAIKeyFrame * > &visitedNode)
 
static bool checkKFConnectionsTree (WAIMap *map)
 

Protected Member Functions

virtual ~WAISlamTools ()
 
 WAISlamTools ()
 

Static Protected Member Functions

static void countReprojectionOutliers (WAIFrame &frame, unsigned int &m, unsigned int &n, unsigned int &outliers)
 

Protected Attributes

cv::Mat _distortion
 
cv::Mat _cameraIntrinsic
 
cv::Mat _cameraExtrinsic
 
cv::Mat _cameraExtrinsicGuess
 
WAIInitializerData _iniData
 
WAIFrame _lastFrame
 
std::unique_ptr< WAIMap_globalMap
 
LocalMap _localMap
 
WAIOrbVocabulary_voc = nullptr
 
cv::Mat _velocity
 
bool _initialized = false
 
LocalMapping * _localMapping = nullptr
 
LoopClosing * _loopClosing = nullptr
 
std::thread * _processNewKeyFrameThread = nullptr
 
std::vector< std::thread * > _mappingThreads
 
std::thread * _loopClosingThread = nullptr
 

Detailed Description

This class should not be instanced. It contains only pure virtual methods and some variables with getter that are useful for slam in a subclass.

Constructor & Destructor Documentation

◆ ~WAISlamTools()

virtual WAISlamTools::~WAISlamTools ( )
inlineprotectedvirtual

◆ WAISlamTools()

WAISlamTools::WAISlamTools ( )
inlineprotected

Member Function Documentation

◆ checkKFConnectionsTree()

bool WAISlamTools::checkKFConnectionsTree ( WAIMap map)
static

◆ countReprojectionOutliers()

void WAISlamTools::countReprojectionOutliers ( WAIFrame frame,
unsigned int &  m,
unsigned int &  n,
unsigned int &  outliers 
)
staticprotected

◆ createMarkerFrame()

WAIFrame WAISlamTools::createMarkerFrame ( std::string  markerFile,
KPextractor *  markerExtractor,
const cv::Mat &  markerCameraIntrinsic,
WAIOrbVocabulary voc 
)
static

◆ createNewKeyFrame()

void WAISlamTools::createNewKeyFrame ( LocalMapping *  localMapper,
LocalMap &  localMap,
WAIMap globalMap,
WAIFrame frame,
unsigned long &  lastKeyFrameFrameId 
)
static

◆ detectCycle()

bool WAISlamTools::detectCycle ( WAIKeyFrame kf,
std::set< WAIKeyFrame * > &  visitedNode 
)
static

◆ doMarkerMapPreprocessing()

bool WAISlamTools::doMarkerMapPreprocessing ( std::string  markerFile,
cv::Mat &  nodeTransform,
float  markerWidthInM,
KPextractor *  markerExtractor,
WAIMap map,
const cv::Mat &  markerCameraIntrinsic,
WAIOrbVocabulary voc 
)
static

◆ drawInitInfo()

void WAISlamTools::drawInitInfo ( WAIInitializerData iniData,
WAIFrame frame,
cv::Mat &  imageBGR,
float  scale 
)
static

◆ drawKeyPointInfo()

void WAISlamTools::drawKeyPointInfo ( WAIFrame frame,
cv::Mat &  image,
float  scale 
)
static

◆ drawKeyPointMatches()

void WAISlamTools::drawKeyPointMatches ( WAIFrame frame,
cv::Mat &  image,
float  scale 
)
static

◆ findFrameFixedMapMatches()

static int WAISlamTools::findFrameFixedMapMatches ( WAIFrame frame,
WAIMap waiMap,
std::vector< cv::Point2f > &  points2d,
std::vector< cv::Point3f > &  points3d 
)
static

◆ findMarkerHomography()

bool WAISlamTools::findMarkerHomography ( WAIFrame markerFrame,
WAIKeyFrame kfCand,
cv::Mat &  homography,
int  minMatches 
)
static

◆ genInitialMap()

bool WAISlamTools::genInitialMap ( WAIMap globalMap,
LocalMapping *  localMapper,
LoopClosing *  loopCloser,
LocalMap &  localMap 
)
static

◆ initialize()

bool WAISlamTools::initialize ( WAIInitializerData iniData,
WAIFrame frame,
WAIOrbVocabulary voc,
LocalMap &  localMap,
int  mapPointsNeeded = 100 
)
static

◆ mapping()

void WAISlamTools::mapping ( WAIMap map,
LocalMap &  localMap,
LocalMapping *  localMapper,
WAIFrame frame,
int  inliers,
const unsigned long  lastRelocFrameId,
unsigned long &  lastKeyFrameFrameId 
)
static

◆ motionModel()

void WAISlamTools::motionModel ( WAIFrame frame,
WAIFrame lastFrame,
cv::Mat &  velocity,
cv::Mat &  pose 
)
static

◆ needNewKeyFrame()

bool WAISlamTools::needNewKeyFrame ( WAIMap globalMap,
LocalMap &  localMap,
LocalMapping *  localMapper,
WAIFrame frame,
int  nInliners,
const unsigned long  lastRelocFrameId,
const unsigned long  lastKeyFrameFrameId 
)
static

◆ oldInitialize()

bool WAISlamTools::oldInitialize ( WAIFrame frame,
WAIInitializerData iniData,
WAIMap map,
LocalMap &  localMap,
LocalMapping *  localMapper,
LoopClosing *  loopCloser,
WAIOrbVocabulary voc,
int  mapPointsNeeded = 100 
)
static

◆ relocalization()

bool WAISlamTools::relocalization ( WAIFrame currentFrame,
WAIMap waiMap,
LocalMap &  localMap,
float  minCommonWordFactor,
int &  inliers,
bool  minAccScoreFilter = false 
)
static

◆ relocalizationGPS()

bool WAISlamTools::relocalizationGPS ( WAIFrame currentFrame,
WAIMap waiMap,
LocalMap &  localMap,
cv::Mat  locENU,
cv::Mat  dirENU,
float  minCommonWordFactor,
int &  inliers,
bool  minAccScoreFilter 
)
static

◆ strictMapping()

void WAISlamTools::strictMapping ( WAIMap map,
LocalMap &  localMap,
LocalMapping *  localMapper,
WAIFrame frame,
int  inliers,
const unsigned long  lastRelocFrameId,
unsigned long &  lastKeyFrameFrameId 
)
static

◆ strictNeedNewKeyFrame()

bool WAISlamTools::strictNeedNewKeyFrame ( WAIMap map,
LocalMap &  localMap,
LocalMapping *  localMapper,
WAIFrame frame,
int  nInliers,
const unsigned long  lastRelocFrameId,
const unsigned long  lastKeyFrameFrameId 
)
static

◆ strictTracking()

bool WAISlamTools::strictTracking ( WAIMap map,
LocalMap &  localMap,
WAIFrame frame,
WAIFrame lastFrame,
int  lastRelocFrameId,
int &  inliers 
)
static

◆ strictTrackReferenceKeyFrame()

bool WAISlamTools::strictTrackReferenceKeyFrame ( LocalMap &  map,
WAIFrame lastFrame,
WAIFrame frame 
)
static

◆ tracking()

bool WAISlamTools::tracking ( WAIMap map,
LocalMap &  localMap,
WAIFrame frame,
WAIFrame lastFrame,
int  lastRelocFrameId,
cv::Mat &  velocity,
int &  inliers 
)
static

◆ trackLocalMap()

bool WAISlamTools::trackLocalMap ( LocalMap &  localMap,
WAIFrame frame,
int  lastRelocFrameId,
int &  inliers 
)
static

◆ trackLocalMapPoints()

int WAISlamTools::trackLocalMapPoints ( LocalMap &  localMap,
int  lastRelocFrameId,
WAIFrame frame 
)
static

◆ trackReferenceKeyFrame()

bool WAISlamTools::trackReferenceKeyFrame ( LocalMap &  map,
WAIFrame lastFrame,
WAIFrame frame 
)
static

◆ trackWithMotionModel()

bool WAISlamTools::trackWithMotionModel ( cv::Mat  velocity,
WAIFrame previousFrame,
WAIFrame frame 
)
static

◆ updateLocalMap()

void WAISlamTools::updateLocalMap ( WAIFrame frame,
LocalMap &  localMap 
)
static

Member Data Documentation

◆ _cameraExtrinsic

cv::Mat WAISlamTools::_cameraExtrinsic
protected

◆ _cameraExtrinsicGuess

cv::Mat WAISlamTools::_cameraExtrinsicGuess
protected

◆ _cameraIntrinsic

cv::Mat WAISlamTools::_cameraIntrinsic
protected

◆ _distortion

cv::Mat WAISlamTools::_distortion
protected

◆ _globalMap

std::unique_ptr<WAIMap> WAISlamTools::_globalMap
protected

◆ _iniData

WAIInitializerData WAISlamTools::_iniData
protected

◆ _initialized

bool WAISlamTools::_initialized = false
protected

◆ _lastFrame

WAIFrame WAISlamTools::_lastFrame
protected

◆ _localMap

LocalMap WAISlamTools::_localMap
protected

◆ _localMapping

LocalMapping* WAISlamTools::_localMapping = nullptr
protected

◆ _loopClosing

LoopClosing* WAISlamTools::_loopClosing = nullptr
protected

◆ _loopClosingThread

std::thread* WAISlamTools::_loopClosingThread = nullptr
protected

◆ _mappingThreads

std::vector<std::thread*> WAISlamTools::_mappingThreads
protected

◆ _processNewKeyFrameThread

std::thread* WAISlamTools::_processNewKeyFrameThread = nullptr
protected

◆ _velocity

cv::Mat WAISlamTools::_velocity
protected

◆ _voc

WAIOrbVocabulary* WAISlamTools::_voc = nullptr
protected

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