I've been having some problems in building a 3D map without a regular odometry source, using only the rgbd camera and lidars. So, I decided to do a sanity check following the exact steps described in the equivalent tutorial, here. But I'm still facing errors:
At first, everything seems to go smooth:
But around 150s on the bag, when the first (and only I think) loop closure is detected, this happens:
In the end, the map looks like this:
Can someone try and see if you can reproduce the problem? Or is it something wrong with my setup (Ubuntu 16 and ros Kinetic)? Funny thing is that I had no problems when running demo_robot_mapping.launch...
The parameters have been updated in the demo_hector_mapping.launch file. What you see is a wrong loop closure accepted because the covariances set in hector's odometry are not compatible with rtabmap. Without updating to latest rtabmap_ros version, you can add those lines under rtabmap node:
<!-- As hector doesn't provide compatible covariance in the odometry topic, don't use the topic and fix the covariance -->
<param if="$(arg hector)" name="odom_frame_id" type="string" value="hector_map"/>
<param if="$(arg hector)" name="odom_tf_linear_variance" type="double" value="0.0005"/>
<param if="$(arg hector)" name="odom_tf_angular_variance" type="double" value="0.0005"/>
Loop closures causing such deformation in the graph will be rejected.