raulmur / ORB_SLAM2

Real-Time SLAM for Monocular, Stereo and RGB-D Cameras, with Loop Detection and Relocalization Capabilities
Other
9.32k stars 4.69k forks source link

mbBad Question #413

Open rosbeginneruser opened 7 years ago

rosbeginneruser commented 7 years ago

What are the differences in the mbBad boolean in the KeyFrame and MapPoint class?

AlejandroSilvestri commented 7 years ago

@rosbeginneruser ,

Both flags signal that object is no longer available. They are not destroyed because there's no control of pointers pointing to them somewhere in the code. So, when such surviving pointer access the object, Segmentation Fault Error is prevented.

I learned that you can eliminate safely all bad mappoints and keyframes in "tracking only" mode, after every delayed BA, local mapping and loop closure procedures are done. But first you must keep track of these bad elements, because most of them are erased from map vectors.