ghayas1214/Traffic-monitoring-app
0
YOLOv5 Video Object Detection
This application provides an easy-to-use interface for object detection in videos using YOLOv5.
Features
- ๐ฏ Detects 80+ object classes (people, vehicles, animals, etc.)
- ๐น Supports multiple video formats (MP4, AVI, MOV)
- โ๏ธ Adjustable confidence threshold
- ๐ Real-time progress tracking
- ๐พ Download processed videos with bounding boxes
How to Use
- Upload your video file
- Adjust the confidence threshold (default: 0.25)
- Lower = more detections (may include false positives)
- Higher = fewer but more accurate detections
- Click 'Process Video'
- Wait for processing to complete
- Download your processed video
Detected Object Classes
The YOLOv5 model can detect 80 COCO dataset classes including:
People & Animals:
- Person, Dog, Cat, Horse, Bird, Sheep, Cow, Elephant, Bear, Zebra, Giraffe
Vehicles:
- Car, Truck, Bus, Motorcycle, Bicycle, Train, Airplane, Boat
Everyday Objects:
- Laptop, Cell Phone, Book, Clock, Bottle, Cup, Chair, Couch, Bed
Sports Equipment:
- Baseball Bat, Baseball Glove, Skateboard, Surfboard, Tennis Racket
And many more!
Performance Tips
- โ For faster processing, use shorter videos (under 1 minute)
- โ Higher resolution videos take longer to process
- โ Increase confidence threshold for fewer detections
- โ The app works best with clear, well-lit videos
Technical Details
- Model: YOLOv5s (Small) - Good balance between speed and accuracy
- Framework: PyTorch + Ultralytics YOLOv5
- Interface: Gradio
- Processing: CPU-based (suitable for Hugging Face Spaces free tier)
Limitations
- Processing time depends on video length and resolution
- Large videos (>5 minutes) may timeout on free tier
- CPU processing is slower than GPU but more accessible
Credits
- YOLOv5: Ultralytics
- Gradio: Hugging Face
- Dataset: COCO Dataset
License
GPL-3.0 (inherited from YOLOv5)
Built with โค๏ธ using YOLOv5 and Gradio
