Skip to content

ROS 2-based object detection system for TurtleBot4 using real-time camera feed and YOLOv8 integration. Designed for autonomous navigation and smart perception tasks.

yashgolani28/turtlebot4-object-detection

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

4 Commits
Β 
Β 
Β 
Β 

Repository files navigation

πŸ€– TurtleBot4 Object Detection with ROS 2

A ROS 2-powered project that enables real-time object detection and localization using YOLOv8 and a TurtleBot4 robot. Ideal for autonomous navigation, exploration, and interaction tasks in indoor environments.


🧠 Features

  • πŸ“¦ Real-time object detection using YOLOv8
  • 🧭 ROS 2 integration with TurtleBot4
  • πŸ“ Object position localization in map frame
  • πŸ–ΌοΈ Live camera feed with bounding boxes
  • πŸ—ΊοΈ Optional SLAM or Navigation2 integration

πŸ“· Demo

Working.Video.mp4

🧰 Tech Stack

Component Technology
Robot TurtleBot4
Framework ROS 2 (Humble/Foxy)
Perception YOLOv8, OpenCV, PyTorch
Visualization RViz2
OS Ubuntu 22.04 + ROS 2

πŸ“ Folder Structure


turtlebot4-object-detection/
β”œβ”€β”€ src/                      # ROS 2 packages
β”‚   └── object\_detection/     # Main node
β”œβ”€β”€ launch/                   # Launch files
β”œβ”€β”€ models/                   # YOLO weights
β”œβ”€β”€ scripts/                  # Utility scripts
└── README.md


Result

Screenshot

WhatsApp Image


βš™οΈ Installation

  1. Clone Repository

    git clone https://github.com/yashgolani28/turtlebot4-object-detection.git
    cd turtlebot4-object-detection
    
  2. Install Dependencies

    sudo apt update
    sudo apt install ros-humble-cv-bridge ros-humble-image-transport
    pip install ultralytics
  3. Download YOLOv8 Weights

    cd models/
    wget https://path/to/yolov8n.pt
  4. Build the Workspace

    colcon build
    source install/setup.bash

πŸš€ Usage

ros2 launch object_detection detection.launch.py

Use RViz2 to visualize detections or subscribe to /detections topic.


πŸ“¦ Topics

  • /camera/image_raw – raw video feed
  • /detections – detected object class & bounding boxes
  • /tf – for object localization

πŸ‘¨β€πŸ’» Contributors

  • Yash Golani

πŸ“¬ Contact

For queries, contact via LinkedIn or open an issue on this repo.

About

ROS 2-based object detection system for TurtleBot4 using real-time camera feed and YOLOv8 integration. Designed for autonomous navigation and smart perception tasks.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published