# Common Map Creation method

Hi, Originally when I tried to create a 2D-Occupancy map, I do it manually or use the rrt_exploration algorithm to do it. However, the result is unstable and sometimes not that ideal. It all depends upon how robust the sensor and wheel encoder are. Further, if there is a moving object, sometimes, they will be mapped into the map as well.

Recently, I dig into the map and found that if I have a floorplan I can use OpenCV to convert it into a 2D-Occupancy map. The only drawback, I experience right now is that the thickness of walls is usually wrong. Hence, when the robot tried to make a turn around the corner, sometimes the costmap doesn't match with the Occupancy map but it is within an acceptable range.

I wonder which above method is commonly used in real cases?

edit retag close merge delete

Sort by » oldest newest most voted

This question is central in autonomous navigation; with a bad map, you can't make good decisions. I would not use a floor plan for a map, since what matters is what the robot perceives to be the reality, which is a function of it's sensors. I agree that good sensors and wheel encoders are important, although I'm not sure good wheel encoders are vital.

Personally, I'm having a lot of luck with RTABMap for this purpose. It provides the occupancy map and is quite flexible - you tell it to subscribe to whatever data you have, and it will use the data to provide localization and mapping. Tons of parameters to tune for your use case.

more

Hi, may I ask which robot base and sensors you are using for rtabmap?

Because I am also using the rtabmap, it is indeed compact with various functionality. However, in my experiment, the OpenCV method performs better than the rtabmap with low-quality sensors. For all the evidence, I have, point that OpenCV is better. Yet, seldom do I find people use it. Therefore, either there is a blind spot I didn't know about or it is just not popular yet. I am more inclined toward the blind spot, but I wonder what it is?

( 2021-10-07 00:57:58 -0500 )edit

The robot is a custom made unit, about 1 meter by 60 cm, very low, with Zed2 cameras in front and back. Pretty high quality sensors, so maybe your use case is too differing from mine. Rtabmap is working like a charm in this robot. If by OpenCV method you mean the floor plan, perhaps it is better, but it requires you to know the floor plan, to import it and scale it properly, and to be sure that your robot agrees with the distances. But if you find it working well, whatever works better for you is what's works best.

( 2021-10-07 10:32:22 -0500 )edit

Creating a map from a floorplan is a method I would like to try.

I usually use gmapping to create my maps. The robot is then moved using joy. I save the finished map with map_saver. Sometimes I edit the saved map with gimp.

more

1

Hi, if you are interested in how to use it. This is the tutorial I follow. Hope you can share your test result of the performance.

( 2021-10-06 04:29:25 -0500 )edit

Thanks for the link to the tutorial. I'll try it out when I get a chance to move it where I have a floorplan.

( 2021-10-06 18:50:00 -0500 )edit