Closed gsanya closed 2 years ago
If I understand correctly, this line will mean, that n is the maximum index of imu measurements: https://github.com/UZ-SLAMLab/ORB_SLAM3/blob/851db08347849a94c51d3ebc3a36df8a114b800f/src/Tracking.cc#L1677 But than the code should either iterate till i<n+1 or i<=n and not like: https://github.com/UZ-SLAMLab/ORB_SLAM3/blob/851db08347849a94c51d3ebc3a36df8a114b800f/src/Tracking.cc#L1685 This causes the code to disregard the last imu measurement in the mvImuFromLastFrame vector.
n
i<n+1
i<=n
mvImuFromLastFrame
An easy fix in my opinion is changing line 1677 to const int n = mvImuFromLastFrame.size(); I tested this on the EUROC dataset, and it works. No big improvement noticed in the tracking performance, but I haven't checked it quantitatively.
const int n = mvImuFromLastFrame.size();
Sorry! I've spoken too soon,, my mistake. The original code is perfect, I just didn't understand it.
If I understand correctly, this line will mean, that
n
is the maximum index of imu measurements: https://github.com/UZ-SLAMLab/ORB_SLAM3/blob/851db08347849a94c51d3ebc3a36df8a114b800f/src/Tracking.cc#L1677 But than the code should either iterate tilli<n+1
ori<=n
and not like: https://github.com/UZ-SLAMLab/ORB_SLAM3/blob/851db08347849a94c51d3ebc3a36df8a114b800f/src/Tracking.cc#L1685 This causes the code to disregard the last imu measurement in themvImuFromLastFrame
vector.An easy fix in my opinion is changing line 1677 to
const int n = mvImuFromLastFrame.size();
I tested this on the EUROC dataset, and it works. No big improvement noticed in the tracking performance, but I haven't checked it quantitatively.