Skip to content

Latest commit

ย 

History

History
115 lines (76 loc) ยท 3.71 KB

File metadata and controls

115 lines (76 loc) ยท 3.71 KB

Project GlyphMotion ๐ŸŽฏ๐ŸŒ€

This project is a fully-featured GUI application for real-time object detection and tracking using YOLOv8. It lets users load videos, preview detections live, customize bounding box colors, and export annotated videosโ€”complete with original audio.


๐Ÿš€ Features

  • โœ… YOLOv8 Object Detection and Tracking
  • ๐Ÿ–ผ๏ธ Tkinter GUI with Live Video Preview
  • ๐Ÿ“‚ Drag-and-Drop or File Picker for Input Videos
  • ๐ŸŽจ Customizable Bounding Box Colors (RGB)
  • ๐Ÿ”Š Audio Preserved Using FFmpeg (if installed)
  • ๐Ÿ“Š Progress Bar and Console Logging
  • โš™๏ธ Threaded Video Processing
  • ๐Ÿง  Automatic CUDA Detection and Usage (if available)
  • ๐Ÿ“ Auto-Saved Output in Timestamped Folders

โœจ What's New

  • ๐Ÿ‘€ Updated UI: Totally inspired by our website aesthetics.
  • ๐Ÿ”ฒ Interactive Region of Interest (ROI): Draw a custom bounding box on the first frame of your video to restrict YOLOv8 tracking to a specific area. This dramatically reduces processing overhead and focuses your results.
  • ๐Ÿ“ฑ Portrait Video Correction: Automatically detects video rotation metadata and rotates mobile portrait videos to their correct orientation before processing.

๐Ÿ› ๏ธ Setup

๐Ÿ“‹ Clone the Repository

git clone https://github.com/ProjectGlyphMotion/GUI && cd GUI

๐Ÿ“ฆ Install Dependencies

pip install -r requirements.txt

On Linux, you may also need:

sudo apt install python3-pil.imagetk

Ensure FFmpeg is installed and accessible from the command line.

๐ŸŽฎ GPU Acceleration (Optional but Recommended)

By default, pip install torch installs the CPU-only version. The app will still work on CPU, but tracking will be significantly slower.

To enable GPU acceleration, install PyTorch with CUDA from the official PyTorch site based on your setup:

CUDA Version Install Command
CUDA 11.8 pip install torch torchvision --index-url https://download.pytorch.org/whl/cu118
CUDA 12.1 pip install torch torchvision --index-url https://download.pytorch.org/whl/cu121
CUDA 12.4 pip install torch torchvision --index-url https://download.pytorch.org/whl/cu124
CPU Only pip install torch torchvision (default)

Not sure which CUDA version you have? Run nvcc --version or nvidia-smi in your terminal.

โš ๏ธ CUDA can be a pain in the ๐Ÿ‘ if you have a 30 or 40 series card โ€” here is a FIX

Verify GPU is detected:

python -c "import torch; print(torch.cuda.is_available())"

๐Ÿš€Launch the GUI:

python3 GUI.py

๐Ÿ–ฅ๏ธ Inside the GUI:

  1. Browse or drag a .mp4, .avi, or .mov file.
  2. Select the desired bounding box color (RGB or via color picker).
  3. Optionally you can also use the Region of Interest (ROI)
  4. Click โ–ถ Run Tracker.

๐Ÿ‘€ Preview

GUI Preview

  • Note: This looks kinda distorted because of the conversion.

๐Ÿ“‚ Output

  • Format: <original_filename>_tracked.mp4
  • Saved under: output/YYYYMMDD-HHMMSS/
  • If FFmpeg is available, original audio is preserved.

โœ… Example Result


๐Ÿ“ƒ License

MIT License ยฉ 2025 Sayan Sarkar & Shitij Halder


โค๏ธ Credits

Made with love by Sayan and Shitij

This project is based on the Ultralytics YOLOv8, an acclaimed real-time object detection and image segmentation model.