An end-to-end AI-powered Object Detection System built using YOLO (Ultralytics), FastAPI, React, and OpenCV. The application can detect multiple objects in real-time through a webcam as well as uploaded video files, providing an intuitive web interface for interacting with a state-of-the-art computer vision model.
Object detection is one of the most widely used applications of Computer Vision, enabling machines to identify and locate multiple objects within an image or video.
This project demonstrates a complete full-stack AI application where:
- A React frontend provides an interactive user interface.
- A FastAPI backend exposes REST APIs for AI inference.
- A YOLO (Ultralytics) model performs high-speed object detection.
- OpenCV processes images and videos frame by frame.
- The processed output is returned with bounding boxes, labels, and confidence scores.
The application supports both real-time webcam detection and video upload detection, making it suitable for learning, demonstrations, and further AI application development.
- Real-time object detection using your webcam
- Continuous frame capture from the browser
- Fast AI inference using YOLO
- Bounding boxes with class labels
- Confidence score visualization
- Smooth live detection experience
- Upload any supported video file
- Frame-by-frame object detection
- Automatic video processing
- Generates an annotated output video
- Displays detected objects with bounding boxes and labels
- YOLO (Ultralytics) object detection model
- Detects multiple objects simultaneously
- High-speed inference
- Accurate object localization
- Supports a wide range of object classes from the pretrained model
React Frontend
│
Upload Video / Webcam
│
▼
FastAPI Backend
│
▼
OpenCV Frame Processing
│
▼
YOLO (Ultralytics) Model
│
▼
Bounding Boxes + Labels + Confidence
│
▼
Annotated Output to Frontend
- React
- Material UI
- JavaScript
- HTML5
- CSS3
- Python
- FastAPI
- OpenCV
- NumPy
- Uvicorn
- YOLO (Ultralytics)
- Deep Learning
- Computer Vision
object-detection/
│
├── backend/
│ ├── main.py
│ ├── requirements.txt
│ └── ...
│
├── frontend/
│ ├── src/
│ ├── public/
│ └── ...
│
├── README.md
└── ...
git clone https://github.com/MandeepKharb/object-detection.git
cd object-detectionNavigate to the backend directory:
cd backendCreate a virtual environment:
python -m venv venvActivate the virtual environment.
venv\Scripts\activatesource venv/bin/activateInstall the required dependencies:
pip install -r requirements.txtStart the FastAPI server:
uvicorn main:app --reloadBackend URL:
http://localhost:8000
Swagger API Documentation:
http://localhost:8000/docs
Open another terminal.
Navigate to the frontend folder:
cd frontendInstall dependencies:
npm installStart the React application:
npm startFrontend URL:
http://localhost:3000
- Launch the application.
- Allow browser access to your webcam.
- Start live detection.
- Watch objects being detected in real time.
- Select the Upload Video option.
- Choose a supported video file.
- Upload the video.
- Wait for processing.
- View the generated video with detected objects highlighted using bounding boxes.
Watch the complete project walkthrough on YouTube:
https://youtu.be/278nPWZNpzY?si=aa3asagH6g1MGq-K
You can add screenshots such as:
- Home Screen
- Live Camera Detection
- Video Upload Interface
- Detection Results
- Processed Video Output
- Custom YOLO model training
- Support for image uploads
- Object tracking (ByteTrack / DeepSORT)
- Real-time video streaming support
- Docker deployment
- GPU acceleration
- Cloud deployment (AWS, Azure, GCP)
- Detection analytics dashboard
Contributions, feature requests, and suggestions are welcome. Feel free to fork the repository and submit a Pull Request.
Mandeep Kharb
If you found this project helpful, consider giving it a ⭐ on GitHub.
This project is intended for educational and learning purposes.