GNSS pose not aligned with the pointcloud

asked 2020-03-31 04:44:52 -0500

Pallav gravatar image

updated 2020-04-02 01:38:16 -0500

I have been trying to use the autoupdate feature for switching between sectional PCD's using GNSS pose using my own recorded rosbag.

  1. I created multiple PCD's using the autoware stack. (Rather than creating the pointcloud with its points in UTM frame, I created the pointcloud in local "map" frame)
  2. Then I shifted that local "map" frame to the UTM point acquired from the initial GNSS pose data(in UTM frame).
  3. Then I generated the GNSS path using the GNSS pose in order to visualize the GNSS pose alignment with the "map" frame.
  4. The GPS path and the pointcloud were misaligned(rotation factor). I converted the GPS data from UTM frame to local frame, considering that I might need to add some transformation to this data afterwards.
  5. Ideally, this should be a problem with the "map" frame initial orientation. So I tried rotating the map frame using the initial yaw from IMU. The frames got aligned. But still, I wasn't able to do map autoupdate using gnss pose.

After some debugging I realised that the gnss_pose data needed to be rotated. Similar to rotating a vector in 2D. So finally, I removed all the other frame rotations and used the rotated gnss pose data. Now, the map autoupdate worked. To verify, I compared the gnss_pose values with the lidar localization pose. This time, the data was somewhat relating.

But my doubt is that, why do I need to rotate the gnss_pose. From what I know, the local "map" frame should be rotated to the initial orientation from IMU. Anyhow, in my case, GNSS values were independent of the reference frame and should not require any rotation. I am not able to figure out the cause.

I also tried the gnss_pose autoupdate on autoware demo_data, but the demo pointcloud points are itself in UTM frame and so don't require any frame transformation.My pointcloud points are in local frame.

Should I try to create the PCD's in UTM frame as there in Autoware demo data? If so, how?

The following image shows the rotation between gnss_path(yellow) and lidar_localization pose(green). image description image description

edit retag flag offensive close merge delete

Comments

I was literally rotating the local "map" frame, with yaw from the initial orientation. This caused the problem as what I actually needed to do was to transform the points in the pointcloud by the IMU's initial yaw value.

So there are two approaches to align the gnss pose:

  1. Transforming the GNSS pose(converted to local map frame) by the initial yaw value from IMU about the local frame. This is similar to rotating a vector in 2D.
  2. Transforming each point in pointcloud with the initial yaw value from the IMU in the local "map" frame.

Note that the 2nd one would work only if your pointcloud is in local frame and not when the pointcloud is in global frame(i.e. at UTM coordinates)

Pallav gravatar image Pallav  ( 2020-04-02 01:31:13 -0500 )edit

@Pallav Hi, how did you rotate the gnss_pose data?

miku54 gravatar image miku54  ( 2023-03-01 03:28:08 -0500 )edit