LDSO: Direct Sparse Odometry with Loop Closure

Xiang Gao, Rui Wang, Nikolaus Demmel, Daniel Cremers

This paper, presented by researchers from the Technical University of Munich, introduces LDSO (Loop-closing Direct Sparse Odometry). It bridges the gap between high-precision direct visual odometry and the global consistency of full SLAM (Simultaneous Localization and Mapping) systems.

TL;DR

LDSO extends the popular Direct Sparse Odometry (DSO) framework by introducing a hybrid point-selection strategy that favors repeatable corners. This allows the system to perform robust loop closure detection and Sim(3) pose-graph optimization, effectively eliminating the long-term scale and trajectory drift that plagues monocular direct methods.

What Problem Does This Paper Address?

Visual SLAM systems generally fall into two camps: indirect (feature-based) and direct.

  • Indirect methods (like ORB-SLAM) track specific keypoints (corners). They are excellent at "loop closure"—recognizing a place they've been before—because corners are repeatable. However, they struggle in low-texture environments where corners are scarce.
  • Direct methods (like DSO) track pixel intensity gradients. They are incredibly robust in feature-poor areas but are notoriously difficult to loop-close. Because they don't rely on repeatable features, recognizing a previously visited location is computationally expensive and unreliable.

Without loop closure, monocular systems suffer from drift: over time, the estimated trajectory and scale of the map deviate significantly from reality. LDSO aims to keep the robustness of direct methods while gaining the global consistency of feature-based SLAM.

Methods

The authors propose a clever "best of both worlds" architecture:

  1. Repeatable Point Selection: In the tracking frontend, LDSO modifies DSO’s point selection. While DSO picks any pixel with a high gradient, LDSO specifically favors Shi-Tomasi corners. If not enough corners are found, it falls back to standard gradient-based pixels to maintain robustness.
  2. Feature-Based Loop Detection: For every keyframe, LDSO computes ORB descriptors for the selected corner points. These are packed into a Bag-of-Words (BoW) database (DBoW3). When a new keyframe matches an old one in the database, a loop candidate is proposed.
  3. Sim(3) Constraint Estimation: Once a loop is detected, the system estimates the relative pose between the frames. Crucially, it uses a Sim(3) transformation, which accounts for rotation, translation, and the scale drift inherent in monocular vision. This is done by minimizing a joint 2D-3D geometric error.
  4. Global Pose-Graph Optimization: These loop constraints are fused with the local odometry constraints in a global pose graph. This "snaps" the entire trajectory into a globally consistent map without the extreme computational cost of global bundle adjustment.
The LDSO framework integrates a global pose graph alongside the standard DSO sliding window.

Datasets

The authors evaluated LDSO on three major benchmarks:

  • TUM-Mono: 50 sequences used to evaluate VO accuracy and drift.
  • EuRoC MAV: 11 sequences from a micro aerial vehicle, providing ground-truth trajectories and IMU data.
  • KITTI Odometry: A large-scale outdoor driving dataset used to test performance in long-range scenarios.

Key Insights and Ideas

  • Hybrid Selection is Key: You don't need every point to be a repeatable feature. By selecting a subset of corners (see Figure 3), LDSO can use standard, efficient BoW techniques for loop detection without losing the ability to track edges and gradients in feature-poor zones.
  • Sim(3) vs. SE(3): In monocular SLAM, the scale of the world is unobservable and drifts over time. Optimizing in Sim(3) (7 degrees of freedom) rather than SE(3) (6 degrees of freedom) is essential to "stretch" or "shrink" parts of the trajectory to make them fit together during a loop closure.
  • Minimal Overhead: Because descriptors are only computed for keyframes and only for a small number of points, the additional computational burden is low, allowing the system to remain performant.
Comparison of point selection: DSO (left) picks gradients; LDSO (right) favors repeatable corners (green).

Key Results

  • Drift Correction: On the KITTI dataset, LDSO reduced the Absolute Trajectory Error (ATE) on Sequence 00 from 126.7 meters (DSO) down to just 9.3 meters.
  • Competitive Accuracy: LDSO achieves performance comparable to ORB-SLAM2 (the gold standard for feature-based SLAM) but shows higher robustness on challenging sequences where feature-based methods often fail to initialize or track.
  • Visual Consistency: Qualitative results show that after loop closure, point clouds that were previously misaligned due to drift become perfectly registered.
The "snap" effect: The red line shows the drifting DSO trajectory, while the blue line shows LDSO's corrected, loop-closed path.

Limitations and Future Work

  • No Global Bundle Adjustment: LDSO relies on pose-graph optimization. While faster, it is generally less precise than global bundle adjustment (GBA). The authors suggest adding a GBA layer as a future improvement.
  • Map Maintenance: The current system doesn't aggressively cull redundant keyframes or points, which could lead to memory issues during extremely long-term operation.
  • Photometric Refinement: Future versions could potentially use photometric information (pixel intensities) to further refine the global map after a loop is closed, rather than relying solely on geometric features.

Summary updated

BibTeX
@inproceedings{gao2018ldso,
  author = {Xiang Gao and Rui Wang and Nikolaus Demmel and Daniel Cremers},
  title = {{LDSO: Direct Sparse Odometry with Loop Closure}},
  booktitle = {IEEE/RSJ International Conference on Intelligent Robots and Systems},
  year = {2018},
  doi = {10.1109/iros.2018.8593376},
}
Figure