ANYbotics / grid_map

Universal grid map library for mobile robotic mapping
BSD 3-Clause "New" or "Revised" License
2.58k stars 800 forks source link

Grid Size Rviz Limitations #167

Open erichahn opened 6 years ago

erichahn commented 6 years ago

When using an occupancy map of size 300 by 300 meters rviz never slows down. When attempting to convert at 666 x 666 pixel image to a grid map of size 300 by 300 meters at 0.5 meter resolution I get about a message a second, compared to the typical 20 a second possible with occupancy maps.

Any idea what would be contributing to this severe slowdown in rviz?

When rostopic echo'ing map grid messages my images and rviz (when not displaying the map_grid) remain at normal speeds.

When lowering the grid to 50 by 50 meters everything begins to run faster again. Too small for my use case though.

pfankhauser commented 6 years ago

Hi @erichahn, are you building from source? Can you confirm that you're building in RELEASE mode?

erichahn commented 6 years ago

I am installing using sudo apt install ros-kinetic-grid-map, I am building in release mode. It appears to be an rviz plugin slowdown as issue only develops when attempting to visualize.

skohlbr commented 6 years ago

I'm experiencing the same issue. For small grid_maps, the plugin works fine, but it goes as far as completely locking up my machine, requiring a restart (!) if the map is "too large". This is on 16.04/Kinetic/latest from .debs. Don't have time for a comprehensive test series, but will update this ticket as I come across datapoints :)

charmyoung commented 5 years ago

Same experience. It seems large map will take a huge amount of gpu memory for rviz, which causes the visualization very slow.

ulassbin commented 3 years ago

I am having a similar problem with a base_map of 2639 x 3500 size. My gridmap has 5 layers, and the topic is published at a rate of 0.2 hz. The code processing this gridmap is around %4 in cpu usage, whereas rviz is at %90-100. I am not sure if this is a gpu issue, I have controlled the resource usage with htop, maybe a more detailed investigation could point out to the cause.

I have noticed there is a parameter called 'Autocompute Intensity Bounds', can this(or something similar) be running at the background even though it is switched off or another transformer for colour is selected? I couldn't find time to check the source code yet.

I have build with apt similar to Eric.

juanluishortelano commented 1 year ago

Same issue here. ROS Melodic, Ubuntu 18.04, Gridmap 1.6.4. Pretty slow on rviz.

juanluishortelano commented 1 year ago

Found out that unticking "Show Grid Lines" improves performance