koide3 / hdl_localization

Real-time 3D localization using a (velodyne) 3D LIDAR
BSD 2-Clause "Simplified" License
775 stars 309 forks source link

Odometry covariance #40

Closed ricber closed 4 years ago

ricber commented 4 years ago

Hi Koide, Can I ask you why you didn't fill the covariance matrix of the nav_msgs::Odometry odometry message? I see that your UKF class exposes a method called getCov(). Could I use this method to fill the covariance of the /odom topic?

Thank you.

koide3 commented 4 years ago

Hi @ricber , Yes, you can retrieve the covariance using getCov(). But, I expect that the estimated covariance doesn't well represent the true uncertainty of the localization result because the UKF doesn't take scan matching errors into account.

ricber commented 4 years ago

Ok, thank you!

Also, why did you put to zero the linear twist? Because I see you're estimating linear velocities in the Kalman Filter.

https://github.com/koide3/hdl_localization/blob/a76067cfeb89d11188e4bd01495af57880574e9a/apps/hdl_localization_nodelet.cpp#L257-L259

koide3 commented 4 years ago

Yeah, of course, we can put the estimated velocity in the odom message. The reason I didn't is that the velocity was not necessary in my application, and I was lazy to check the velocity output coordinate...