UZ-SLAMLab / ORB_SLAM3

ORB-SLAM3: An Accurate Open-Source Library for Visual, Visual-Inertial and Multi-Map SLAM
GNU General Public License v3.0
6.59k stars 2.56k forks source link

A summary of mono-inertial initialization issues, and suggestions for others. #736

Open LarryDong opened 1 year ago

LarryDong commented 1 year ago

When using mono-inertial codes on my own data, I always got frequently initilization and failure issue, which report is this:

First KF:0; Map init KF:0
New Map created with 271 points
Fail to track local map!
IMU is not or recently initialized. Reseting active map...
SYSTEM-> Reseting active map in monocular case
LM: Active map reset recieved
LM: Active map reset, waiting...
LM: Reseting current map in Local Mapping...
LM: End reseting Local Mapping...
LM: Reset free the mutex
LM: Active map reset, Done!!!
mnFirstFrameId = 10
mnInitialFrameId = 0
4 Frames set to lost

I viewed almost all issues about mono initialization under this repo, and found solutions (or at least, suggestions), which solved my problem. Here I give a summary. For stereo-inertial system, some comments may also fruitful.

Since there are too many issues, I cannot mention all of them, but I guess the following issues are due to the same reason more or less: https://github.com/UZ-SLAMLab/ORB_SLAM3/issues/501, https://github.com/UZ-SLAMLab/ORB_SLAM3/issues/664, https://github.com/UZ-SLAMLab/ORB_SLAM3/issues/28, https://github.com/UZ-SLAMLab/ORB_SLAM3/issues/264, https://github.com/UZ-SLAMLab/ORB_SLAM3/issues/356, https://github.com/UZ-SLAMLab/ORB_SLAM3/issues/569. Also, under those issues (and not mentioned ones), there are suggestions from authors of this repo/paper, and other guys. I followed the authors suggestions first, and list others comments just for reference.

As authors point out, there are two reasons for initialization failure: 1. inaccurate camera and IMU extrinsics, and 2. not enough motion during the initialization process. See https://github.com/UZ-SLAMLab/ORB_SLAM3/issues/221#issuecomment-748597473 and https://github.com/UZ-SLAMLab/ORB_SLAM3/issues/435#issuecomment-1000170690.

First, about the IMU and camera extrinsics, here's my suggestion and comments:

Second, about the initialization process:

The above solutions solves my problem. And here are some suggestions from others:

Hope this issue could end most of discussions about the VI initialization failure.

JinXiangLai commented 1 year ago

Great work, thanks!