mirror of
https://github.com/azaion/gps-denied-onboard.git
synced 2026-06-23 11:21:12 +00:00
e6e1c27726
- Lift the env-aware VO backend factory verbatim from core/vo.py. - Body and parameter defaults preserved exactly (PATTERNS.md §4.1 mandate: 'Preserve this factory verbatim'). - Return-type annotation widened from ISequentialVisualOdometry to the canonical VisualOdometry Protocol from Plan 01-02; the I-prefix alias is still importable so legacy callers/type-checkers keep working. - Imports route through the new components.vio.* modules; no cross-package edits needed because Plan 08 (composition root) is the only other call site planned. - Append to the components.vio barrel.
38 lines
1.3 KiB
Python
38 lines
1.3 KiB
Python
"""VIO component (ARCH-01).
|
|
|
|
Public surface for visual-inertial odometry adapters. Phase-1 split of
|
|
the legacy ``core/vo.py`` monolith into per-backend modules:
|
|
|
|
- protocol.py — VisualOdometry Protocol (alias ISequentialVisualOdometry)
|
|
- orbslam_backend.py — pure-Python OpenCV: SequentialVisualOdometry + ORBVisualOdometry
|
|
- cuvslam_backend.py — Jetson cuVSLAM SDK bridge: CuVSLAMVisualOdometry + CuVSLAMMonoDepthVisualOdometry
|
|
- factory.py — create_vo_backend env-aware DI seed
|
|
- native/ — placeholder for future cuvslam SDK native glue
|
|
|
|
The legacy ``gps_denied.core.vo`` import path is preserved as a thin
|
|
re-export shim for one phase; tests still import from there.
|
|
"""
|
|
from gps_denied.components.vio.protocol import (
|
|
ISequentialVisualOdometry,
|
|
VisualOdometry,
|
|
)
|
|
from gps_denied.components.vio.orbslam_backend import (
|
|
ORBVisualOdometry,
|
|
SequentialVisualOdometry,
|
|
)
|
|
from gps_denied.components.vio.cuvslam_backend import (
|
|
CuVSLAMMonoDepthVisualOdometry,
|
|
CuVSLAMVisualOdometry,
|
|
)
|
|
from gps_denied.components.vio.factory import create_vo_backend
|
|
|
|
__all__ = [
|
|
"VisualOdometry",
|
|
"ISequentialVisualOdometry",
|
|
"ORBVisualOdometry",
|
|
"SequentialVisualOdometry",
|
|
"CuVSLAMVisualOdometry",
|
|
"CuVSLAMMonoDepthVisualOdometry",
|
|
"create_vo_backend",
|
|
]
|