How m33i/slam works
This is a lightweight monocular visual-SLAM application: a user supplies a video, the runtime estimates camera motion from successive frames, builds a 3D point cloud and trajectory, and visualizes the results. The main control flow is in slam.py; feature matching and pose estimation are in feat_extractor.py, while map construction and rendering are in mapping.py. README-described options include ORB detection, image-region masking, point colors, and keyframe frustums. The sampled source supports the main runtime connections; those options are represented where their implementation is visible.
Main entry points: slam.py SLAM Orchestrator · mapping.py Map and Trajectory · display.py Display and Controls · feat_extractor.py Feature and Pose
Components 9
SLAM Runtime
- SLAM Orchestrator
slam.py - Feature and Pose
feat_extractor.py
Mapping and Geometry
- Geometry Utilities
utils.py - Map and Trajectory
mapping.py
Visualization and Controls
- Display and Controls
display.py
Other components
- User
- Input Video
- OpenCV
- Open3D
Connections 15
- User → SLAM Orchestrator: starts with video
- Input Video → SLAM Orchestrator: frames read
- SLAM Orchestrator → OpenCV: opens and reads video
- SLAM Orchestrator → Feature and Pose: processes frames
- Feature and Pose → OpenCV: detects and matches
- Feature and Pose → Geometry Utilities: requests feature mask
- SLAM Orchestrator → Geometry Utilities: samples point colors
- SLAM Orchestrator → Map and Trajectory: updates points and pose
- Map and Trajectory → Geometry Utilities: uses view and keyframe helpers
- Map and Trajectory → Open3D: builds and renders map
- SLAM Orchestrator → Display and Controls: updates panels
- Display and Controls → OpenCV: shows UI
- SLAM Orchestrator → Display and Controls: checks clicked controls
- SLAM Orchestrator → Map and Trajectory: closes and saves map
- Map and Trajectory → Display and Controls: sends rendered view