ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
0

Always update the map using RTABmap

asked 2019-12-03 16:44:40 -0600

EdwardNur gravatar image

Hi,

My environment is very dynamic and I know that RTABmap uses ICP to localize using the laserscans under Reg/Strategy = 1. So is it possible to always update the map where laserscans/camera scan the area and reuse the updated map at the next turn? So in that case, ICP will still be accurate under a dynamic environment.

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2019-12-04 09:53:40 -0600

matlabbe gravatar image

So is it possible to always update the map where laserscans/camera scan the area and reuse the updated map at the next turn?

Yes, if --delete_db_on_start argument is not set, rtabmap re-uses the previous map and will update it. By default when restarting, the robot assumes that it is starting from the last position of the previous session. If the robot moved when offline, it will localize automatically only if the camera is used. With or without camera, we can still set the localization manually by sending a pose on /rtabmap/initialpose topic (similar to AMCL).

Under dynamic environment, it depends if most of the scan's rays hit static obstacles. I suggest to build rtabmap with libpointmatcher support to have more robust ICP in dynamic environments, particularly by tuning Icp/PMOutlierRatio parameter.

cheers,
Mathieu

edit flag offensive delete link more

Comments

I have encountered the problem that RTABmap always adds the new obstacles but does not delete the old ones, is that correct?

EdwardNur gravatar image EdwardNur  ( 2019-12-13 08:12:46 -0600 )edit

@matlabbe How can I turn on this feature? After creating a map, new objects were not included in the map

EdwardNur gravatar image EdwardNur  ( 2019-12-13 09:59:31 -0600 )edit

It depends on which sensor you are using, because ray tracing is not enabled by default for camera input, just for 2D lidar. To turn on ray tracing (to clear obstacles), set Grid/RayTracing=true . After creating a map, if you restart in localization mode only, new obstacles won't be added in the static map. If you restart in SLAM mode, new obstacles would be added to the map.

matlabbe gravatar image matlabbe  ( 2019-12-13 13:31:21 -0600 )edit

@matlabbe I am using 2D lidar. So will it be possible to use SLAM but making publish_tf_map to false, because I am using my own localization?

EdwardNur gravatar image EdwardNur  ( 2019-12-13 13:35:51 -0600 )edit

You can set publish_tf to false for rtabmap node so that /map frame is not published.

matlabbe gravatar image matlabbe  ( 2019-12-19 08:52:08 -0600 )edit

Question Tools

1 follower

Stats

Asked: 2019-12-03 16:44:40 -0600

Seen: 1,131 times

Last updated: Dec 04 '19