System Requirements
ORB-SLAM3 has been tested on Ubuntu 16.04 and 18.04, but should be easy to compile on other Linux platforms.A powerful computer (e.g., Intel i7 processor) is recommended to ensure real-time performance and more stable, accurate results.
Prerequisites
Before building ORB-SLAM3, you need to install the following dependencies:C++11 or C++0x Compiler
ORB-SLAM3 uses C++11 thread and chrono functionalities. Make sure you have a compatible compiler:OpenCV
ORB-SLAM3 uses OpenCV for image manipulation and feature processing.Eigen3
Eigen3 is required by g2o for linear algebra operations.Eigen 3.1.0 or higher is required.
Pangolin
Pangolin is used for visualization and user interface.Python and NumPy
Python with NumPy is required for trajectory evaluation and alignment with ground truth.ROS (Optional)
If you plan to use the ROS examples, install ROS Melodic (Ubuntu 18.04) or ROS Kinetic (Ubuntu 16.04).ROS Installation (Optional)
ROS Installation (Optional)
Installation Steps
Build Third-Party Libraries
ORB-SLAM3 includes modified versions of DBoW2, g2o, and Sophus in the Make the build script executable:
Thirdparty folder. The build script will compile these automatically.The
build.sh script will:- Build DBoW2 (place recognition)
- Build g2o (graph optimization)
- Build Sophus (Lie algebra)
- Extract the ORB vocabulary
- Build the ORB-SLAM3 library and examples
Run the Build Script
Execute the build script to compile everything:This process may take several minutes depending on your system. The script will:
- Build DBoW2 in
Thirdparty/DBoW2/build - Build g2o in
Thirdparty/g2o/build - Build Sophus in
Thirdparty/Sophus/build - Extract the ORB vocabulary from
Vocabulary/ORBvoc.txt.tar.gz - Build the main ORB-SLAM3 library
- Compile all example executables
Build Outputs
The build process creates the following:lib/libORB_SLAM3.so: The main ORB-SLAM3 shared libraryExamples/*/: Executable binaries for each sensor configuration:Monocular/: Monocular SLAM examplesStereo/: Stereo SLAM examplesRGB-D/: RGB-D SLAM examplesMonocular-Inertial/: Monocular + IMU examplesStereo-Inertial/: Stereo + IMU examplesRGB-D-Inertial/: RGB-D + IMU examples
Building ROS Examples (Optional)
If you want to use ORB-SLAM3 with ROS:Troubleshooting
OpenCV Version Mismatch
If you encounter OpenCV version errors:Compilation Errors with C++11
Ensure your compiler supports C++11:Pangolin Not Found
If CMake cannot find Pangolin:Permission Issues
If you encounter permission errors during build:Next Steps
Now that ORB-SLAM3 is installed, you’re ready to run your first example!Quick Start Guide
Learn how to run your first SLAM example