-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error occurs when calibrate IMU and camera with recover covariance #291
Comments
I'm also having the same issue. Is anyone planning on implementing this, or are there any other suggestions for extracting an uncertainty of the IMU-Camera calibration? |
Here I list my solution to get the covariance of estimated result. First of all, the kalibr don't calculate the covariance of the IMU-Camera calibration. If we modify the code to calculate the covariance, it seems much effort and cannot make sure the modification is right. Therefore, I bypass the direct calculation method by calculating the inverse the Hessian block. In the linear system solver, kalibr will build a problem like H * x = b, where the H is the Hessian block, and the last 8 parameters in x are the quaternion (N=4), translation(N=3) and time offset(N=1). We could add log to print the last 8 parameters and the calculated IMU-Camera transformation to check whether they are the same value. I checked they are the same. Then we extract the corresponding Hessian block by the index. Because Hessian is the sparse matrix, the inverse of the block is the covariance what we needed. Although I obtain the covariance of T_BC(transformation from camera to IMU), but this value is about 1e-12, which don't seem any sense for application. |
Thanks for the insight! If you can upload the changes to made to extract the relevant block from the Hessian I can look through it and see if I can figure out why the values are so extreme. |
Extract Hessian in below file, kalibr/aslam_optimizer/aslam_backend/src/BlockCholeskyLinearSystemSolver.cpp Lines 74 to 106 in 8fbb27d
add below code before the final return
|
Here list my repository I modified for reference. Please enable some macro definition to show the final result. |
Have you looked into this bug yet? It would be really helpful to be able to extract the variance of the time offset in particular. |
I tried to recover covariances of the estimated parameters here a long while ago. You have get some info therein. |
I see the covariance of designed variable could be calculated in IMU-Camera calibration from the command help. I use the sample datasets with the below command
kalibr_calibrate_imu_camera --bag ./example/dynamic.bag --cam ./example/camchain-.dynamic.yaml --imu ./example/imu_adis16448.yaml --target ./example/april_6x6.yaml --bag-from-to 5 55 --recover-covariance
However, the error occurs, below is output
In the output, the see the code in BSplineMotionError is not implemented. I saw the code but could not understand the inside theory completely. Could anyone know how to modify it, or any paper/book could be referred?
The text was updated successfully, but these errors were encountered: