ORB-SLAM2

Mur-Artal 2017 · Paper

One-line summary — Extends ORB-SLAM to stereo and RGB-D cameras, providing a unified open-source SLAM framework with metric scale and state-of-the-art accuracy across all three sensor modalities.

Problem

ORB-SLAM was monocular-only: depth is not observable from one camera, so map and trajectory scale are unknown, bootstrapping needs multi-view initialisation, and the system suffers scale drift and can fail under pure rotation. Stereo and RGB-D cameras solve all these issues, but existing stereo/RGB-D systems either lacked loop closing, gave up global consistency for constant-time operation, or relied on ICP/photometric alignment. ORB-SLAM2 (IEEE TRO 2017) generalises the BA-based framework so one system “works in real-time on standard CPUs in a wide variety of environments, from small hand-held indoors sequences, to drones flying in industrial environments and cars driving around a city”.

Method & architecture

Three parallel threads — tracking, local mapping, loop closing — plus a fourth thread for full BA after loop closure. Tracking localises every frame against the local map with motion-only BA; local mapping runs local BA over a covisibility window; loop closing detects loops with DBoW2 and corrects drift by pose-graph optimisation over the covisibility graph/spanning tree, followed by full BA whose result is merged back by propagating keyframe corrections through the spanning tree.

{R,t}=argminR,tiXρ(x()iπ()(RXi+t)Σ2)\{\mathbf{R},\mathbf{t}\}=\operatorname*{argmin}_{\mathbf{R},\mathbf{t}}\sum_{i\in\mathcal{X}}\rho\left(\left\|\mathbf{x}^{i}_{(\cdot)}-\pi_{(\cdot)}\left(\mathbf{R}\mathbf{X}^{i}+\mathbf{t}\right)\right\|^{2}_{\Sigma}\right)

with Huber cost ρ\rho, keypoint-scale covariance Σ\Sigma, and projection functions πm=(fxXZ+cx, fyYZ+cy)\pi_{\mathrm{m}}=\left(f_x\frac{X}{Z}+c_x,\ f_y\frac{Y}{Z}+c_y\right) and stereo πs\pi_{\mathrm{s}} appending the third row fxXbZ+cxf_x\frac{X-b}{Z}+c_x. Local BA optimises covisible keyframes KL\mathcal{K}_L and their points PL\mathcal{P}_L with fixed border keyframes KF\mathcal{K}_F; full BA is the same with everything free except the origin keyframe.

Results

Evaluated on 29 public sequences (5 runs each, median; Intel i7-4790):

Why it matters for SLAM

ORB-SLAM2 turned ORB-SLAM into a general-purpose SLAM library covering monocular, stereo, and RGB-D sensors, and it remained the dominant accuracy baseline in SLAM papers for several years; its virtual-stereo RGB-D trick and close/far point policy were copied broadly. It is the natural bridge from monocular SLAM (Level 3) to stereo SLAM (Level 7) and RGB-D SLAM (Level 4), and the direct predecessor of ORB-SLAM3’s visual-inertial, multi-map system.

Hands-on