Back to Projects

Project · SLAM & State Estimation

Visual-Inertial SLAM with ORB-SLAM3

  • Mobile Robotics · Northeastern
  • Nov – Dec 2025
  • ROS 2 · C++
  • ORB-SLAM3
  • EuRoC MAV

I integrated ORB-SLAM3’s monocular-inertial mode into ROS 2 as a real-time C++ node, fixed a cold-start initialization failure with an IMU pre-warming buffer, and built a Python pipeline that scores the estimated trajectory against EuRoC ground truth.

  • 0.13 m
    ATE RMSE on EuRoC V1_01_easy (RPE RMSE 1.8 cm)
  • 0.48 m
    ATE RMSE on the harder MH_03_medium (RPE RMSE 4.3 cm)
  • 30 / 200 Hz
    camera and IMU streams processed in real time
  • 2.5 s
    IMU pre-warm window, chosen from a 1.0–4.0 s sweep

Gallery

Problem

GPS is unavailable indoors and unreliable in cluttered spaces. Camera-only SLAM struggles with fast motion and cannot observe metric scale, while an IMU alone drifts within seconds. Fusing a monocular camera with an IMU gives a robot metric, drift-resistant pose estimates from two cheap sensors.

What I Built

  • ROS 2 integration: a C++ node around ORB-SLAM3’s monocular-inertial mode that pairs 30 Hz camera frames with a thread-safe buffer of 200 Hz IMU samples (≈1,000 ORB features per frame) and publishes the pose and TF.
  • Initialization fix: the system failed to initialize on the harder EuRoC sequences (V2_03, MH_05). A sweep from 1.0 to 4.0 s showed that windows under 2.0 s failed, so the node pre-warms the IMU for 2.5 s — enough excitation to estimate gravity, scale and sensor biases before tracking starts.
  • Evaluation pipeline: a Python logger writes poses to CSV, aligns them to ground truth with Umeyama alignment (with scale), and reports ATE / RPE with trajectory plots.

Scope

ORB feature tracking, IMU pre-integration, the tightly coupled visual-inertial optimization and loop closing come from ORB-SLAM3 itself. My work was everything around it: the ROS 2 integration and sensor synchronization, the initialization fix, and the evaluation.

Results

EuRoC sequenceATE RMSERPE RMSEScale
V1_01_easy0.13 m1.8 cm1.017
MH_03_medium0.48 m4.3 cm0.959
  • Real-time operation at the 30 Hz camera rate.
  • Scale recovered within about 2% on V1_01_easy and 4% on MH_03_medium.
  • On MH_03_medium, most of the error occurs in the first ~20 s, before the visual-inertial estimate converges.

What I Learned

In monocular-inertial SLAM, the fragile part is initialization, not tracking. Giving the IMU time to observe gravity and biases, and keeping camera and IMU timestamps consistent, mattered more than tuning tracking parameters.

Tech Stack

  • C++
  • ROS 2
  • ORB-SLAM3
  • OpenCV
  • Eigen
  • Python
  • EuRoC MAV