watonomous.github.io

  1. Software Division
  2. Software Division Home
  3. Path Planning Group

[ Software Division : Ego Localization Autoware - Deprecated ]

Created by [ Tony Jung], last modified on Apr 26, 2021

Autoware

We will be using the Autoware's implementation of a point-cloud matching based localization algorithm. They use a normal distribution transform algorithm to match the point-clouds to an existing point-cloud map.

NOTE: This requires a GUI component so run this in gui_tools image. This is just to run it and get an idea of what we're trying to do. We will eventually use this in our stack and no longer require this to be installed on gui_tools.

No longer in use.

Installation

Follow the installation steps from the Autoware repo: https://github.com/Autoware-AI/autoware.ai/wiki/Source-Build

Running Autoware Modules

Localization with Autoware Demo Rosbag

Following the steps of https://gitlab.com/autowarefoundation/autoware.ai/autoware/-/wikis/ROSBAG-Demo but in more detail and with slightly different steps.

  1. Download the demo data from autoware:

    1. wget https://autoware-ai.s3.us-east-2.amazonaws.com/sample_moriyama_data.tar.gz
      wget https://autoware-ai.s3.us-east-2.amazonaws.com/sample_moriyama_150324.tar.gz
      tar zxfv sample_moriyama_150324.tar.gz
      tar zxfv sample_moriyama_data.tar.gz
      
  2. Launch the autoware runtime manager

    1. cd autoware.ai
      source install/setup.bash
      roslaunch runtime_manager runtime_manager.launch
      

      TROUBLESHOOTING: The roslaunch command might not work. It might immediately crash. If that happens try running "rosrun runtime_manager runtime_manager_dialog.py" instead

      The runtime manager will look something like this:
      [

  3. Load the rosbag
    1. A lot of the autoware functions running with the runtime manager rely on the /clock messages from the rosbag, so you need to load the rosbag first
    2. Go to the "Simulation" tab
    3. Click the "Ref" button and select the rosbag you downloaded earlier
    4. Set the "Start time (s)" to 140
    5. (optional) click the repeat box
    6. Press the "Play" button
    7. As soon as it becomes available, press the "Pause" button
    8. Your runtime manager should look something like this:
      1. [
  4. Open RViz
    1. Click the "RViz" button near the bottom right of the runtime manager
    2. Go to "File"→"Open Config" and open up the rviz config file autoware.ai/src/autoware/documentation/autoware_quickstart_examples/launch/rosbag_demo/default.rviz
  5. Turn on velodyne tf
    1. Go to the "Setup" tab
    2. Leave everything as the default values and make sure "Velodyne" is selected in the Localizer box
    3. Click the "TF" button
    4. The runtime manager should look something like this:
      1. [
  6. (Optional) Load vehicle model
    1. Go to the "Setup" tab
    2. Click the "Vehicle Model" button. The empty reference loads the default model
  7. Load the map data
    1. Go to the "Map" tab
    2. Click the "Ref" button on the right side of the "Point Cloud" row
    3. Go to where you downloaded the map data from step 1 and select all or some of the .pcd files. The .pcd files are in the folder data/map/pointcloud_map/
    4. Click the "Point Cloud" button
    5. Click the "Ref" button on the right side of the "TF" row
    6. Go to where you downloaded the map data from step 1 and select data/tf/tf.launch
    7. Click the "TF" button
    8. (steps h to j are optional) Click the "Ref" button on the right side of the "Vector Map" row
    9. Go to where you downloaded the map data from step 1 and select all or some of the .csv files. The .csv files are in the folder data/map/vector_map/
    10. Click the "Vector Map" button
    11. The runtime manager should look something like this:
      1. [
  8. Turn on the points downsampler
    1. There are too many points from the point cloud messages, so to increase computational speed we downsample them
    2. Go to the "Sensing" tab
    3. Any of the Points Downsampler should work but I've only used the voxel_grid_filter so no promises on the other ones (tongue){.emoticon .emoticon-cheeky}
      1. [
    4. Click the "app" link next to the voxel_grid_filter (or whichever downsampler of your choosing)
    5. Set the "Points topic" to /points_raw and leave the rest as the default values
      1. [
    6. Click "OK" which will close this window
    7. Back at the main runtime manager, click the check box next to "voxel_grid_filter" on
  9. Turn on gnss localizer (This is only used to get the initial position. The actual localization algorithm does not use the gnss but still requires this to run properly)
    1. Go to the "Computing" tab
    2. Click the check box next to "nmea2tfpose"
  10. Turn the localization module on
    1. Go to the "Computing" tab
    2. The default setting for the localization module is fine so no need to change any settings
    3. Click the check box next to "ndt_matching"
  11. Run the rosbag
    1. Back in the autoware runtime manager, go to the "Simulation" tab
    2. Click the "Pause" button to un-pause
  12. By now your RViz should look something like this:
    1. [
    2. The white points are the pointcloud map and the coloured points are the live points we get from the lidar/rosbag
    3. Check that the car/view is moving along the map

Attachments:

image2020-12-5_0-45-19.png (image/png)
image2020-12-5_1-4-4.png (image/png)
Screenshot from 2020-12-05 01-00-35.png (image/png)
image2020-12-5_1-36-27.png (image/png)
image2020-12-5_1-39-0.png (image/png)
image2020-12-5_1-57-33.png (image/png)
image2020-12-5_1-58-51.png (image/png)
downsample.png (image/png)
image2020-12-5_2-5-16.png (image/png)
image2021-1-10_3-31-9.png (image/png)\

Document generated by Confluence on Dec 10, 2021 04:01

Atlassian