Build Errors
Dependencies Not Found
OpenCV Not Found
OpenCV Not Found
Error Message:Solutions:
-
Install OpenCV (Ubuntu/Debian):
-
Specify OpenCV path explicitly:
-
Check OpenCV version:
Required: OpenCV 3.2+ (tested with 3.2.0 and 4.4.0)
-
Build OpenCV from source if version is too old:
Eigen3 Not Found
Eigen3 Not Found
Error Message:Solutions:
-
Install Eigen3:
-
Verify installation:
-
Manually specify Eigen path:
Pangolin Not Found
Pangolin Not Found
Error Message:Solutions:
-
Install Pangolin dependencies:
-
Build Pangolin from source:
-
Update library cache:
Third-Party Library Build Failures
DBoW2 Build Error
DBoW2 Build Error
Error: DBoW2 compilation fails during
build.shSolutions:-
Clean and rebuild:
-
Check for conflicting DBoW2 installations:
-
Verify library is created:
g2o Compilation Errors
g2o Compilation Errors
Error: g2o fails to compile in Thirdparty/g2oSolutions:
-
Install missing dependencies:
-
Clean build directory:
- Check Eigen version compatibility: g2o requires Eigen3 3.1.0+
Sophus Build Issues
Sophus Build Issues
Error: Sophus compilation failsSolution:
-
Ensure C++11 support:
-
Rebuild Sophus:
Linking Errors
Undefined Reference Errors
Undefined Reference Errors
Error Message:Solutions:
-
Verify library is built:
-
Check library path:
-
Rebuild from scratch:
Boost Serialization Not Found
Boost Serialization Not Found
Error Message:Solution:
Python-Related Build Errors
Python Development Headers Missing
Python Development Headers Missing
Error Message:Solutions:
-
Install Python development package:
-
Verify NumPy installation:
Runtime Errors
Initialization Failures
Vocabulary Loading Error
Vocabulary Loading Error
Error Message:Solutions:
-
Extract vocabulary file:
-
Verify file path:
-
Check available memory:
Configuration File Error
Configuration File Error
Error Message:Solutions:
-
Verify file exists:
-
Check YAML syntax:
-
Common YAML issues:
- Tabs instead of spaces (use spaces only)
- Missing colons after parameter names
- Incorrect indentation
Camera Parameter Errors
Camera Parameter Errors
Error Message:Solutions:
-
Verify all required parameters are present:
-
Check parameter names (case-sensitive):
- Use
Camera1.fx, notcamera1.fx - Use
ORBextractor.nFeatures, notORBExtractor.nFeatures
- Use
-
Validate camera model:
Tracking Lost Scenarios
Immediate Tracking Loss
Immediate Tracking Loss
Symptoms: “Tracking lost” on first or second frameCauses & Solutions:
-
Incorrect camera parameters:
- Verify calibration is correct
- Check image resolution matches YAML
- Test with known-good configuration first
-
Insufficient features:
-
Wrong sensor type:
-
Image format issues:
Tracking Lost During Sequence
Tracking Lost During Sequence
Symptoms: Tracking works initially but fails mid-sequenceCommon Causes:
-
Fast motion / motion blur
- Reduce camera frame rate
- Increase exposure time
- Add motion blur compensation
-
Textureless scenes:
- Lower FAST thresholds
- Ensure adequate lighting
- Add visual features to environment
-
Dynamic objects:
- Large moving objects can confuse tracking
- Try to maintain static background in view
-
Loop closure confusion:
- Temporarily disable loop closing:
- Temporarily disable loop closing:
- ORB-SLAM3 has automatic relocalization
- Ensure sufficient features from previous map
- Consider resetting if unrecoverable
Scale Drift (Monocular)
Scale Drift (Monocular)
Symptoms: Map scale changes over time in monocular modeExplanation:
- Monocular SLAM has inherent scale ambiguity
- Scale drift is expected without IMU or stereo
-
Use stereo or visual-inertial:
- Provides metric scale
- Eliminates scale drift
-
Add known-scale constraints:
- Implement custom scale constraints
- Use fiducial markers
-
Loop closure helps:
- Scale correction on loop detection
- Maintain visual overlap in trajectory
IMU Integration Issues
IMU Initialization Fails
IMU Initialization Fails
Symptoms: “IMU not initialized” or worse tracking than visual-onlySolutions:
-
Verify IMU transformation:
-
Check IMU noise parameters:
- Use manufacturer specifications
- Or measure from static recording:
-
Verify IMU frequency:
-
Ensure sufficient motion:
- IMU initialization requires motion
- Need acceleration and rotation
- Takes 2-3 seconds of dynamic motion
Time Synchronization Issues
Time Synchronization Issues
Symptoms: IMU integration degrades performanceSolutions:
-
Hardware synchronization:
- Use hardware-synchronized camera-IMU
- RealSense D435i, T265 have built-in sync
-
Software synchronization:
- Interpolate IMU measurements
- Use timestamp association
-
Check timestamp units:
Performance Issues
Cannot Achieve Real-Time Performance
Cannot Achieve Real-Time Performance
Symptoms: Processing slower than camera frame rateSolutions:
-
Reduce feature count:
-
Disable viewer:
-
Enable performance mode (Linux):
-
Profile with REGISTER_TIMES:
Rebuild and check
ExecTimeMean.txtfor bottlenecks. -
Reduce image resolution:
High Memory Usage
High Memory Usage
Symptoms: RAM usage grows continuously or crashes with out-of-memorySolutions:
-
Reduce feature count:
-
Enable map point culling (default, but verify):
- Check LocalMapping thread is running
- Culling should happen automatically
-
Limit keyframe count:
- Modify LocalMapping parameters
- Implement periodic map saving/clearing
-
Monitor memory usage:
Debugging Tips
Enable Verbose Output
Use GDB for Segmentation Faults
Enable Time Profiling
-
Uncomment REGISTER_TIMES (Settings.h:24):
-
Rebuild:
-
Run and check output:
Visualize Trajectory
Common Dataset-Specific Issues
EuRoC Dataset Issues
EuRoC Dataset Issues
Problem: Cannot find images in datasetSolution:Problem: Tracking fails immediatelySolution:
- Use provided EuRoC.yaml (tested configuration)
- Verify image equalization is disabled (default)
- Check stereo rectification parameters
TUM-VI Dataset Issues
TUM-VI Dataset Issues
Problem: Slow bag file playbackSolution (from README.md:226-229):Problem: Fisheye image distortionSolution:
- TUM-VI uses fisheye cameras
- Use
Camera.type: "KannalaBrandt8" - ORB-SLAM3 works with original distorted images
RealSense Camera Issues
RealSense Camera Issues
Problem: RealSense examples not compiledSolution:Problem: D435i camera not detectedSolution:
Getting Help
Information to Provide
When seeking help, include:-
System information:
-
Build output:
- Full CMake configuration output
- Compilation errors (if any)
-
Runtime information:
- Command used to run ORB-SLAM3
- YAML configuration file
- Console output (verbose mode)
-
Dataset details:
- Dataset name and sequence
- Any preprocessing applied
- Timestamp format
Useful Resources
- ORB-SLAM3 GitHub Issues
- ORB-SLAM3 Paper (technical details)
- README.md in repository root
- Calibration_Tutorial.pdf for camera setup
- ROS Answers for ROS-related issues
Quick Fixes Checklist
Before deep debugging, try:- Clean build:
rm -rf build && mkdir build && cd build && cmake .. && make -j4 - Verify vocabulary file extracted:
ls -lh Vocabulary/ORBvoc.txt - Check dataset path is correct:
ls /path/to/dataset - Use absolute paths for all file arguments
- Test with provided example dataset (EuRoC MH01)
- Disable viewer: set
bUseViewer = false - Reduce feature count:
ORBextractor.nFeatures: 800 - Check RAM availability:
free -h(need 2GB+ free) - Verify timestamp file format matches dataset