Ask Your Question
2

[Autoware.Auto] ndt map pulbisher not working, PCD file not be loaded.

asked 2021-12-01 01:50:43 -0500

dymoon gravatar image

updated 2021-12-06 22:02:47 -0500

Environment Setting: Ubuntu 20.04, ros2-foxy, use Autoware.Auto master branch, don't use ADE, Use Master branch

I wanted to publish PCD map file, but ndt_map_publisher didn't work like that. I am trying to run map_provider.launch.py file which is in ndt_nodes ros2 package. but the following results were obtained.

[INFO] [launch]: All log files can be found below /home/morai/.ros/log/2021-12-01-15-30-25-097848-morai-desktop-212024
[INFO] [launch]: Default logging verbosity is set to INFO
[INFO] [ndt_map_publisher_exe-1]: process started with pid [212026]
[INFO] [voxel_grid_node_exe-2]: process started with pid [212028]
[ndt_map_publisher_exe-1] [pcl::PCDReader::readHeader] No points to read
[ndt_map_publisher_exe-1] terminate called after throwing an instance of 'std::runtime_error'
[ndt_map_publisher_exe-1]   what():  PCD file /home/morai/AutowareAuto/install/autoware_demos/share/autoware_demos/data/autonomoustuff_parking_lot_lgsvl.pcd could not be loaded.
[ERROR] [ndt_map_publisher_exe-1]: process has died [pid 212026, exit code -6, cmd '/home/morai/AutowareAuto/install/ndt_nodes/lib/ndt_nodes/ndt_map_publisher_exe --ros-args -r __ns:=/localization --params-file /home/morai/AutowareAuto/install/autoware_auto_launch/share/autoware_auto_launch/param/map_publisher.param.yaml --params-file /tmp/launch_params_y55b9iy9 --params-file /tmp/launch_params_yzl4fuzo']

I used my own custom PCD file. Because I thought original (default : autonomoustuff_parking_lot.pcd) PCD file is the cause of the matter. The changed part is the file name of the line 40 and 43 of the link file below.

https://gitlab.com/autowarefoundation...

After the change, the following results were obtained.

[INFO] [launch]: All log files can be found below /home/morai/.ros/log/2021-12-01-16-17-52-898023-morai-desktop-231143
[INFO] [launch]: Default logging verbosity is set to INFO
[INFO] [ndt_map_publisher_exe-1]: process started with pid [231145]
[INFO] [voxel_grid_node_exe-2]: process started with pid [231147]
[ndt_map_publisher_exe-1] terminate called after throwing an instance of 'std::runtime_error'
[ndt_map_publisher_exe-1]   what():  intensity datatype is not float or uint8_t
[ERROR] [ndt_map_publisher_exe-1]: process has died [pid 231145, exit code -6, cmd '/home/morai/AutowareAuto/install/ndt_nodes/lib/ndt_nodes/ndt_map_publisher_exe --ros-args -r __ns:=/localization --params-file /home/morai/AutowareAuto/install/autoware_auto_launch/share/autoware_auto_launch/param/map_publisher.param.yaml --params-file /tmp/launch_params_6tp78do_ --params-file /tmp/launch_params_18dohqoq'].

My Custom PCD file format is as follows, but I couldn't figure out why the problem occurred.

# .PCD v0.7 - Point Cloud Data file format
VERSION 0.7
FIELDS x y z rgb
SIZE 4 4 4 4
TYPE F F F F
COUNT 1 1 1 1
WIDTH 45273600
HEIGHT 1
VIEWPOINT 0 0 0 1 0 0 0
POINTS 45273600
DATA binary

and the only other part I changed is param file which refer to map_provider.launch.py

https://gitlab.com/autowarefoundation...

I am asking for you to give me advice to solve this problem. Thank you for your help in advance.

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
1

answered 2021-12-10 23:34:06 -0500

Josh Whitley gravatar image

The current ndt_map_publisher node expects the PCD format to contain at least fields X, Y, Z, and INTENSITY (which must be of type float or uint8_t). This is why your custom map did not load.

As for why the AutonomouStuff Parking Lot map did not load, it is probably because this file is checked in to the AutowareAuto repository with git lfs which does not pull the file automatically with a simple git clone. In order to pull this (and all other git lfs files), cd into your AutowareAuto folder and run:

sudo apt install -y git-lfs
git lfs install
git lfs pull --exclude="" --include="*"

After this, re-build the autoware_demos package and it should then be able to load the example PCD.

edit flag offensive delete link more

Comments

Hello, can you describe it in detail? What do the three lines of instructions mean?

marks gravatar image marks  ( 2022-04-18 02:05:19 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

4 followers

Stats

Asked: 2021-12-01 01:50:43 -0500

Seen: 123 times

Last updated: Dec 10 '21