
Garbage collection is a challenging task that requires significant effort and manpower. This project proposes an automatic garbage detection system utilizing CCTV cameras installed on streets. The system employs deep learning models to detect garbage piles and send alerts to relevant authorities, ensuring cleaner urban environments with improved efficiency.
The project involves creating a custom dataset containing images of garbage piles and leveraging deep learning models such as YOLOv5n, YOLOv7-tiny, and YOLOv8n for accurate object detection.
- Efficient Garbage Management: Reduces dependency on manual monitoring.
- Automated Alerts: Notifies municipal authorities for prompt action.
- Smart City Integration: Supports real-time waste management solutions.
- Deep Learning Implementation: Enhances detection accuracy through advanced AI models.
Since no suitable public dataset containing images of garbage piles was available, we created a custom dataset with manually gathered and annotated images. The dataset preparation process includes:
- 1000 original images collected from CCTV footage at different times of the day.
- Manual annotation using the LabelImg tool.
- Data Augmentation Techniques applied: Flip, Rotate (90°), Shear, Exposure, Blur, and Noise.
- Final dataset size: 5000 images (1000 original + 4000 augmented images).
Technology | Description |
---|---|
YOLO | Object detection using You Only Look Once (YOLO) v5, v7, v8 |
R-CNN | Advanced real-time object detection |
Deep Learning | Latest YOLO model for enhanced detection accuracy |
Technology | Description |
---|---|
OpenCV | Image processing and video frame analysis |
Node.js | Backend development & AI model deployment |
React | Frontend UI framework |
Flask | High-performance web framework for APIs |
SQL | Database management for storing alerts and detections |
Technology | One‑line Purpose |
---|---|
Kotlin | Modern, null‑safe language for Android |
Jetpack Compose | Declarative UI toolkit (no XML) |
Material 3 | Ready‑made theming & components |
Retrofit 2 + OkHttp | Type‑safe REST client & HTTP stack |
Coroutines + StateFlow | Lightweight async & reactive state |
ViewModel | Lifecycle‑aware state holder |
Navigation Compose | Type‑safe in‑app navigation |
Room | SQLite abstraction & caching layer |
Hilt | Dependency injection made simple |
TensorFlow Lite (opt.) | On‑device ML inference |
JUnit / AndroidX Test | Unit & UI testing frameworks |
Ensure you have Git, Python (3.8+), and pip installed before proceeding.
1️⃣ Clone the repository:
git clone https://github.com/yourusername/Garbage-Detection.git
cd Garbage-Detection
2️⃣ Install dependencies:
pip install -r requirements.txt
3️⃣ Run the FastAPI server:
uvicorn main:app --host 0.0.0.0 --port 8000 --reload
4️⃣ Setup React Frontend:
cd frontend
npm install
npm start
- Real-time garbage detection using CCTV footage
- Automated alert system for municipal authorities
- AI-powered object detection with YOLO models
- Web-based dashboard for monitoring detections
- Historical data storage for trend analysis
- CCTV footage is processed in real-time.
- Frames are extracted and passed through YOLO models.
- Garbage piles are detected with bounding boxes.
- Alerts are sent to relevant municipal authorities.

This research methodology involves utilizing real-time images captured from CCTV cameras as input data. These images are used to train deep learning models, including YOLOv5, YOLOv7, and YOLOv8, which are known for their high object detection capabilities.
- The trained model's performance is evaluated using the training dataset.
- The model can detect garbage piles in real time.
- If garbage is detected, an automatic alert is sent to the relevant authorities for timely action.