Loop closure detection tuning

Posted by cpsarras on
URL: http://official-rtab-map-forum.206.s1.nabble.com/Loop-closure-detection-tuning-tp3297.html

Hello Mathieu,

I have been experimenting with loop closures in RTAB-Map and I think do not fully understand the meaning of some of the parameters involved. Also, i have been trying to detect loop closures, while walking in parallel to a previous trajectory 70+cm apart with no luck so far (see image below).

Red odometry is ground truth, no loop closures detected by mapGraph. Grid is default 1x1m
Red odometry is ground truth, no loop closures detected by mapGraph. Grid is default 1x1m

It is my understanding that the following parameters:

RGBD/ProximityByTime
RGBD/ProximityBySpace
RGBD/ProximityMaxGraphDepth
RGBD/ProximityMaxPaths
RGBD/ProximityPathFilteringRadius
RGBD/ProximityPathMaxNeighbors
RGBD/ProximityPathRawPosesUsed
RGBD/ProximityAngle

have an effect on nodes stored in the STM, and determine which ones are going to be compared with the current node when searching for loop closures, based on their proximity.

Then by tuning the Mem/STMSize parameter, I determine the number of nodes that are going to be available for the above parameters.

With the above assumptions, I set the
Mem/STMSize                                  2000  (default 10)
RGBD/ProximityByTime                   false  (default false)
RGBD/ProximityBySpace                  true   (default true)
RGBD/ProximityPathFilteringRadius  2       (default 0.5)

and expect to be able to detect loop closures when walking in parallel to a previous trajectory, in a distance of up to 2m. However RTAB-Map detects loop closures with a distance <0.5m, with the above setup.

The overall trajectory is 30m long, I am walking with a constant speed of 0.2 m/s and the stereo image feed is 1920x1080. All other parameters are kept to their default values in stereo_mapping.

Any insight on how loop closure parameters work in RTAB-Map is much appreciated.

Thank you in advance,
Chris