An AI-powered robotics project that enables the Boston Dynamics SPOT robot to detect chairs, segment them using SAM2, classify chair orientation using deep learning, and autonomously navigate to a desired side of the chair.
- 🪑 Chair detection using YOLOv11
- ✂️ Chair segmentation using SAM2
- 🧭 Chair orientation classification with TensorFlow
- 🤖 Autonomous navigation for SPOT robot
- 📷 Real-time image capture from SPOT hand camera
- 🎯 User-selected target chair interaction
↔️ Side-based movement logic (Front / Left / Rear / Right)
SPOT Camera Feed
│
▼
YOLO Chair Detection
│
▼
SAM2 Chair Segmentation
│
▼
Orientation Classification
│
▼
Navigation Decision Logic
│
▼
SPOT Movement Commands
.
├── main.py
├── chairs.py
├── apply_yolo_get_chairs.py
├── apply_sam_segment_chair.py
├── classify_orientation.py
├── spot_robot.py
├── utils.py
├── sam2_hiera_l.yaml
├── model.h5
├── yolo11n.pt
└── README.md- Python
- TensorFlow
- OpenCV
- YOLOv11 (Ultralytics)
- SAM2 (Segment Anything Model 2)
- Boston Dynamics SDK
- NumPy
YOLO detects chairs and benches in the scene with confidence filtering.
SAM2 segments the selected chair using bounding boxes and masks.
A TensorFlow model predicts the chair direction:
- Front
- Left
- Rear
- Right
SPOT moves relative to the detected chair using movement primitives:
- Move Left
- Move Right
- Rotate Left
- Rotate Right
git clone https://github.com/yourusername/spot-chair-navigation.git
cd spot-chair-navigationpip install -r requirements.txtExample dependencies:
tensorflow
opencv-python
numpy
ultralytics
torch
bosdyn-client
bosdyn-api
bosdyn-missionRun the main script:
python main.py- SPOT powers on and stands
- Camera image is captured
- User clicks on a chair
- Chair is segmented and classified
- User selects destination side
- SPOT navigates accordingly
if left_direction > right_direction:
spot_go_right()
else:
spot_go_left()Detects chairs using YOLO.
Segments chairs using SAM2.
Chair object representation and validation.
Predicts chair orientation.
Contains all SPOT robot control utilities.
- Requires access to a physical SPOT robot
- Ensure robot authentication credentials are configured
- CUDA-enabled GPU recommended for SAM2 inference
- TensorFlow model (
model.h5) must be trained beforehand
Avoid hardcoding robot credentials directly in source code. Use environment variables or a secure configuration system instead.
- Multi-chair tracking
- Dynamic obstacle avoidance
- Voice command integration
- ROS2 integration
- Real-time SLAM support
- Improved orientation classifier
Developed for robotics navigation and chair interaction research using SPOT + computer vision pipelines.
This project is licensed under the MIT License.
- Ultralytics YOLO
- Meta SAM2
- Boston Dynamics SDK