Skip to content

Localization overview

Joshua Williams edited this page Oct 29, 2021 · 1 revision

This information is an adaptation of the Autoware.Auto localization design doc.

Coordinate frames

Autoware.Auto follows REP 105, a ROS standard that defines coordinate frames for robots.

  • /earth is a frame based on an "earth-centered, earth-fixed" (ECEF) coordinate system, where the origin (0,0,0) is the center of mass of the Earth. Pretty metal, huh? Instead of using longitude/latitude/altitude, /earth uses (x,y,z), where z is true north, x goes through the intersection of the prime meridian and equator, and y is normal to both.
  • /map is based on our HD map. We can treat this frame as our ground truth (/earth is a overkill). This is the frame that our robot will localize itself within. Pretty simple. Coordinates in this frame are based off the "east, north, up" (ENU) system, where the map's origin is treated as tangent to the Earth's surface, x is east, y is north, and z is up. Just some good ole Cartesian coordinates.
  • /odom is based on /map, but it provides more real-time updates based on live odometry measurements. For example, assume our localization algorithm (which determines where the robot is on the map) updates every 100 ms. That means that every 100 ms, any transforms based on /map jump around a bit, and this isn't suitable for faster computations. For cases where continuous, non-jittery data is more important than accurate readings, we choose /odom. The downside is that /odom may drift slightly between updates from our localizer.
  • /base_link is a coordinate frame fixed onto our vehicle. The origin is the midpoint of the rear axle. Per REP 103, x is forward, y is left, and z is up.
  • Additional coordinate frames can be attached to /base_link within the transform tree for individual sensors on the vehicle.

These frames form an inheritance structure called a transform tree. To convert the coordinates with /base_link to /earth, it has to first move through /odom, then /map, and finally /earth. See the REP diagram here.

Just to be clear, a "transform" is just a computation that takes one coordinate and both translates and rotates the location across two or more frames. This usually just means storing the translational and rotational offsets between linked frames, then adding the differences to make a transform.

Absolute vs. relative localization

Absolute localization works based on some fixed truth, like GPS. Relative localization works on known map features, so that your location is determined relative to their known locations. NDT is a relative localizer. Absolute is represented by the /earth-/base_link transform. Relative is represented by the /map-/base_link.

Components of the Autoware.Auto localization stack

  • The map manager provides a wrapper over stored map data.
  • The TF manager converts the outputs of individual localization into consistent, standardized transforms. It ultimately provides the full transform tree at regular time intervals.
  • The absolute localizer provides a /earth-/base-link transform through GPS.
  • The relative localizer provides a /map-/base-link transform through NDT localization.
  • The odometry localizer provides continuous, real-time localization through instant motion data (speed and steering angle).
Clone this wiki locally