-
Notifications
You must be signed in to change notification settings - Fork 5.9k
Integrating Modular SLAM Pipeline into OpenCV Contrib #4043
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
QueenofUSSR
wants to merge
10
commits into
opencv:4.x
Choose a base branch
from
QueenofUSSR:slam_m2
base: 4.x
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@QueenofUSSR build is failing. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Pull Request Readiness Checklist
See details at https://github.com/opencv/opencv/wiki/How_to_contribute#making-a-good-pull-request
Patch to opencv_extra has the same branch name.
Summary
This PR adds the SLAM module (slam) providing a compact visual odometry and small-scale SLAM toolkit. The module includes feature extraction, matching, two-view initialization, pose estimation, local mapping (MapManager / MapPoint), a simple optimizer (local BA with SFM fallback and optional g2o support), visualizer/top-down trajectory, localizer (PnP-based relocalization), and utilities for loading image sequences and intrinsics.
Motivation
Offer a lightweight, self-contained SLAM implementation that demonstrates how to use OpenCV building blocks for VO/SLAM research and examples. Useful as an educational reference and quick prototyping base for researchers who want to extend or compare with other methods (ORB-SLAM family, etc.). It also provides a straightforward path to enable g2o when available for robust BA.
What changed / what’s included
slam.hpp— module aggregatorvo.hpp— VisualOdometry wrapperdata_loader.hpp— sequence loader with YAML intrinsics parsingfeature.hpp— FeatureExtractor (ORB + ANMS + flow-aware selection)matcher.hpp— Matcher (ratio test, bucketing, mutual check)initializer.hpp— Two-view initializer using H/F decomposition + triagulationpose.hpp— PoseEstimator (essential matrix + recoverPose)map.hpp&keyframe.hpp— MapManager, MapPoint, KeyFramelocalizer.hpp— PnP-based relocalizeroptimizer.hpp— Optimizer (local BA using either g2o or OpenCV-based SFM fallback)visualizer.hpp— simple frame/top-down visualization and trajectory savingImplementation (under src/):
vo.cpp— main VisualOdometry run loop, backend thread for local BA, CSV diagnostics, initialization + tracking + triangulation pipelinedata_loader.cpp— filesystem/glob image enumerator, optional sensor.yaml intrinsics parsing (small comment fix in this PR)feature.cpp,matcher.cpp,initializer.cpp,pose.cpp,optimizer.cpp,visualizer.cpp,localizer.cpp— corresponding implementations described above