elevation_mapping icon indicating copy to clipboard operation
elevation_mapping copied to clipboard

Output as a 2D Occupancy Grid

Open 8bitZeta opened this issue 4 years ago • 4 comments

Hello,

I have managed to get a decent live reading of data using a Velodyne Lidar.

The output is currently a standard Grid Map (based on the Simple Demo), but I was hoping that I would be able to adjust the output type similar to how Grid Mapping works.

Any help would be appreciated. Thanks

8bitZeta avatar Oct 28 '19 23:10 8bitZeta

Hi @Dev727,

The output is currently a standard Grid Map (based on the Simple Demo), but I was hoping that I would be able to adjust the output type similar to how Grid Mapping works.

In what way do you want to adjust the output type? If you are interested to convert the grid_map to a costmap2d object you have to write the transformation for yourself for now. At the moment grid_map only supports the conversion to a costmap2d.

maximilianwulf avatar Nov 06 '19 08:11 maximilianwulf

At the moment grid_map only supports the conversion to a costmap2d.

This should be exactly what I'm looking for. Is there a simple way to convert the produced Grid Map to a Costmap2D using the Simple Demo? Would it require editing the .yaml file or actually altering any of the actual code?

Also, thanks for the response, @maximilianwulf.

8bitZeta avatar Nov 06 '19 15:11 8bitZeta

@Dev727 at the moment you have to write your own code to get the behavior.

You can find inspiration to do it in the costmapt2GridMap converter class.

Feel free to open a PR if you have working code.

maximilianwulf avatar Nov 06 '19 15:11 maximilianwulf

Hi @Dev727,

I added the conversion from GridMap to a Costmap2D in the costmapt2GridMap converter class. I hope this helps. You can check the unit tests to see how you can perform the conversion.

Cheers, Gabriel

hogabrie avatar Nov 08 '19 09:11 hogabrie