## How to launch NDT Localization

### Requisites

Before starting make sure you have

1. PCD Map (.pcd)
2. Vector Map (.csv)
3. TF File (.launch)

### How to start localization

1. Launch Autoware’s Runtime Manager
2. Go to Setup Tab
3. Click on TF and Vehicle Model buttons This will create the transformation between the localizer (Velodyne) to the base_link frame (car’s tires)
4. Go to Map tab
5. Click the ref button on the PointCloud section
6. Select ALL the PCD Files that form the map, then click Open
7. Click the Point Cloud button to the left. A bar below will show the progress of the load. Wait until it’s complete. Do the same for Vector Map, but this time select all the csv files Finally load the TF for the map
8. Go to Simulation Tab
9. Click the Ref Button and load a ROSBAG.
10. Click Play and once the ROSBAG started to play, immediatly press Pause This step is required to set the Time to simulation instead of real.
11. IF your rosbag contains /velodyne_packets instead of /points_raw, go to Sensing tab and Launch the LiDAR node corresponding to your sensor, to decode the packets into points_raw The corresponding calibration YML files are located in ${AUTOWARE_PATH}/ros/src/sensing/drivers/lidar/packages/velodyne/velodyne_pointcloud/params/ Select the correct one depending on the sensor. 12. In the Sensing Tab, Inside the *Points Downsampler** section, click on voxel_grid_filter 13. Go to Computing tab and click on the [app] button next to ndt_matching inside the Localization section. Make sure the Initial Pos is selected. 14. Click on the ndt_matching checkbox. 15. Launch RVIZ using the button below Runtime Manager, and load the default.rviz configuration file located in ${AUTOWARE_PATH}/ros/src/.config/rviz.
16. In RVIZ click on the 2D Pose Estimate button, located in the top bar
17. Click on the initial position to start localization AND drag to give an initial pose.
18. If the initial position and pose are correct, the car model should now be seen in the correct position. If the model starts spinning, try to give a new initial position and pose.