Hi Mercedes,
By the local_map, do you mean the local costmap of
move_base? For
/rtabmap/grid_map, the obstacle cells should be cleared only if the ground can be seen again under where the obstacle was. With a stereo camera it is not always the case even if the camera is looking the ground because there is generally no texture, thus no depth computed on the ground.
move_base does ray tracing to clear the cells. If you want to do something similar (at the cost of more processing power required), you can look at the
/rtabmap/octomap_grid topic. This output does ray tracing to clear obstacles without the need to see the ground.
cheers,
Mathieu