# How to set the covariance matric for IMU orientation, angular velocity and linear acceleration?

I am working on a project that requires fusing of odometry and IMU data for localization. The robot_localization package requires IMU and odometry covariance matrices.

Is there any appropriate method to compute the Covariance Matrix??

edit retag close merge delete

Hello,

This would not be an exact answer, but I had the same problem with robot_pose_ekf, it would not take my odom values without the covariance matrix set.

I have done:

odom_msg.pose.covariance[0] = 1e-3;
odom_msg.pose.covariance[7] = 1e-3;
odom_msg.pose.covariance[14] = 1e6;
odom_msg.pose.covariance[21] = 1e6;
odom_msg.pose.covariance[28] = 1e6;
odom_msg.pose.covariance[35] = 1e3;


Which was a workaround so the robot_pose_ekf would take data into consideration. This is called setting covariance to a high value.

I am also wondering the answer of your question. How do we pick covariance matrices, or calculate them.

Best, C.A.

( 2019-11-07 09:22:33 -0600 )edit

Thank you!!! I have already come across the answer that you mentioned . But when it comes to imu , i couldn't find anything relevant. I'm using BNO055 imu and few people suggested me to compute it from the datasheet, but i didn't find anything helpful.

( 2019-11-08 12:31:18 -0600 )edit