Thanks to visit codestin.com
Credit goes to github.com

Skip to content

m7mds91/YOLO-Detection

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

8 Commits
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Advanced Camera YOLO Detection

This project is a Python PyQt5-based graphical interface that: βœ… Selects between IP, RTSP, or USB cameras
βœ… Runs YOLOv8 object detection (supports small, medium, large models)
βœ… Displays human, car, and ship detections with count icons
βœ… Supports GPU (CUDA) or CPU inference
βœ… Saves user settings and last-used camera configuration
βœ… Includes a splash screen with configurable app logo


✨ Features

  • βœ… Real-time video stream from USB, IP, or RTSP cameras
  • βœ… Model switcher (YOLOv8s, YOLOv8m, YOLOv8l) for performance vs. accuracy
  • βœ… Sidebar with toggleable object detections: human, car, ship
  • βœ… Right-click on video window: toggle detection lines, change resolution (HD, FHD, 4K)
  • βœ… Menu bar: switch processing mode (CPU/GPU), change logo, save settings
  • βœ… Configuration saved in config.json for session persistence

πŸ“¦ Requirements

Package Version (recommended)
Python 3.9 or 3.10
PyQt5 β‰₯ 5.15
OpenCV (opencv-python) β‰₯ 4.x
Ultralytics (YOLOv8) β‰₯ 8.x
Torch (PyTorch) GPU or CPU version (matching your hardware + CUDA if GPU)

πŸ”§ Install dependencies

# Clone the repo
git clone https://github.com/m7mds91/YOLO-Detection.git
cd YOLO-Detection

# Create virtual environment (optional but recommended)
python -m venv venv
source venv/bin/activate  # On Windows: venv\\Scripts\\activate

# Install required packages
pip install -r requirements.txt

πŸ›  Example requirements.txt

PyQt5==5.15.9
opencv-python>=4.8.0
ultralytics>=8.0.0
torch>=2.0.0

πŸš€ Run the app

python YOLO-Detection.py

βš™οΈ Configuration

Logo icon: Set/change via the menu (Settings β†’ Change Logo)

Model:

Switch via menu (Performance β†’ YOLOv8s / YOLOv8m / YOLOv8l)
Processing device: CPU or GPU (if available)
Saved settings: Stored in config.json in the project folder

πŸ“Έ Supported Cameras

Type Example Entry
USB Camera 0 (default), 1, 2…
IP Camera (http://192.168.x.x:port/path)
RTSP Stream rtsp://192.168.x.x:port/path

πŸ’» Notes

For GPU support, ensure PyTorch with CUDA is installed matching your system and GPU drivers.
Check: PyTorch Install Guide
YOLOv8 models (.pt files) should be placed in the project directory or adjust the script paths.

🌟 Credits

YOLOv8: Ultralytics PyQt5 GUI: Riverbank Computing

About

This project is a Python PyQt5-based graphical interface

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages