- changed title to IMU Preintagration question on concept
IMU Preintagration question on concept
Dear authors,
thank you very much for the great framework! It helps me a lot in performing experiments on slam and related optimization!
I have a question regarding the imu pre-integration. Today, I tried to apply the concept on the IMU data provided by this dataset: http://projects.asl.ethz.ch/datasets/doku.php?id=kmavvisualinertialdatasets or to be more precise, its "Machine Hall 01": http://robotics.ethz.ch/~asl-datasets/ijrr_euroc_mav_dataset/machine_hall/MH_01_easy/MH_01_easy.zip
Basically, I read the acceleration data and the rotation data and apply the
integrateMeasurement(acc, omega, dt)
method. You can see the simple test code here: https://github.com/mojovski/mono-vo/blob/master/tests/test_imuPreIntegration.cpp In short, this is the main part:
for (int i=off; i<9203; i++) //until time 1403636590008555520
{
t=std::atoll(lines[i].elements[0].c_str());
for (int ai=4; ai<7; ai++)
{
acc(ai-4)=std::atof(lines[i].elements[ai].c_str());
}
for (int wi=1; wi<4; wi++)
{
omega(wi-1)=std::atof(lines[i].elements[wi].c_str());
}
double dt=(t-last_t)/1e9;
pim.integrateMeasurement(acc, omega, dt);
last_t=t;
//pim.update()
}
However, at the end of the integration, I get a huge error in position:
Navstate from the preintegration:
time:1403636625763555584 ns
pose: R:
|0.994612, -0.0861074, -0.0577275|
|0.0882827, 0.995436, 0.0362508|
|0.0543426, -0.0411518, 0.997674|
p:[18.7715, -0.0239318, 14.4225]'
v:[18.9735, 0.353791, 14.4962]'
1403636625819881216ns -
Ground truth position: 0.0801577 0.0543189 0.101987
Could somebody please point me in a direction? I feel like I misunderstood how to use the framework on the IMU data. One question I can think of: do I have to handle the gravitation vector somehow before putting the raw data into the preintegration module?
Thank you very much in advance!!
PS: Sorry if this is the wrong place for questions. I haven't found a better one.
Comments (5)
-
reporter -
-
assigned issue to
-
assigned issue to
-
@MandyXie, thanks!
-
Eugen, just saw this issue. Graivity should be handled by the IMU factor. Please read the paper and the IMU factor code. I can't spend the time to investigate now, but if you still have an issue after reading code/paper, please post the question on the Google group https://groups.google.com/forum/?utm_medium=email&utm_source=footer#!forum/gtsam-users
-
- changed status to invalid
User question , not a reproducible bug.
- Log in to comment