SDDSlam: Merging SD-SLAM and Rosify Difodo, a new SD-SLAM version

2 minute read

Its been a while since the last entry so lets talk about all the work that has been going on. In the last entry we concluded that the next steps were to merge SD-SLAM and rosify difodo.

This will bring a new SLAM algorithm to live that hopefully will be better that SD-SLAM and will work in more different environments. This new algorithm will be called Semi Direct Depth SLAM or SDD-Slam.

These last weeks Ive been studying SD-SLAM to think on ways to integrate rosify difodo into SD-SLAM. Also familiarizing with the code itself.

The first attemps to merge SD-SLAM with rosify difodo will be to use rosify difodo when the visual information is not enough for the tracking of SD-SLAM. This will be:

  • When there is low texture in the images.
  • When is a dark place or completely dark.

So once this is detected in SD-SLAM and the tracking fails, rosify difodo will start taking the lead with his odometry.

Using rosify difodo when SD-SLAM fails

Use this to use rosify_difodo along other packages https://foonathan.net/2016/03/cmake-install/

The first thing that we have to accomplish is to be able to use the code from rosify_difodo in SD-SLAM code.

My first attemp was to create a library from rosify_difodo in order to import and use this library in SD-SLAM. The major problem that I founded was that MRPT seems not to tell you where the headers are unlees you use find_package() on cmkae to find MRPT. If you provide a library like rosify_difodo_lib, you should also provide the headers and libraries that it depends on when using find_package() against it. For this I try to use catkin to create a catkin_package() where you let know the one importing your library where are all the headers and libraries that it depends on through the YOUR_LIBRARY_INCLUDE_DIRS and YOUR_LIBRARY_LIBRARIES. The main problem here is that MRPT doesnt let you know where are the headers of the library when using find_package(), they are included automatically but no variable MRPT_INCLUDE_DIRS is created to be passed when people find_package() your package.

This becomes a challenge so Ive end up with a solution where the code of rosify difodo is going to be included to the SD-SLAM code and Ill add all the dependencies to SD-SLAM directly since it also makes sense to have all in a unique place.

Using rosify difodo along SD-SLAM

There are other options to merge the algorithm that we would like to test. One of the possibilities is:

  • Using rosify difodo as the first estimation of the pose instead of the IMU or motion motion

SD-SLAM has a motion model that choose between using the speed and direction of SD-SLAM as the first pose estimation and using the IMU sensors measurements. This decision is done by an Extended Kalman Filter. Then here one of the possiblities could be use rosify difodo as estimation instead of the IMU or the speed.

Next Steps

The last thing after fighting with cmake system was that I was able to compile everything together. The next thing to do is try to use both algorithms at the same time in order to see if the compilation is correctly linking everything.