Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🗑️ AI-Powered Garbage Classification System

An intelligent computer vision system that automatically classifies waste into predefined categories using Transfer Learning with EfficientNetV2B2. The project aims to support smart waste segregation by leveraging deep learning to identify recyclable and non-recyclable waste from images.


📖 Overview

Proper waste segregation is one of the biggest challenges in modern waste management. Incorrect disposal of recyclable materials such as paper, plastic, glass, and metal reduces recycling efficiency and increases environmental impact.

This project addresses this problem by developing an AI-powered image classification system capable of automatically identifying the type of garbage from an uploaded image. The system utilizes a pre-trained EfficientNetV2B2 model, fine-tuned on a garbage image dataset using Transfer Learning, enabling accurate classification while reducing computational cost and training time.


🎯 Objectives

  • Automate waste classification using Deep Learning.
  • Reduce manual effort in waste segregation.
  • Demonstrate the effectiveness of Transfer Learning for image classification.
  • Improve model generalization using Data Augmentation.
  • Provide an easy-to-use interface for prediction.

✨ Features

  • Image-based garbage classification
  • Transfer Learning using EfficientNetV2B2
  • Six-category waste classification
  • Data Augmentation for better generalization
  • Early Stopping to prevent overfitting
  • Balanced Class Weights for imbalanced datasets
  • Interactive Gradio interface
  • Confidence-based predictions

🗂️ Waste Categories

The model classifies an image into one of the following categories:

  • Cardboard
  • Glass
  • Metal
  • Paper
  • Plastic
  • Trash

Note: The Trash category represents miscellaneous waste items that do not belong to the recyclable categories above.


🏗️ System Architecture


User Uploads Image
│
▼
Image Preprocessing
│
▼
Data Augmentation (Training Phase)
│
▼
EfficientNetV2B2 (ImageNet Weights)
│
▼
Transfer Learning & Fine-Tuning
│
▼
Softmax Classification
│
▼
Predicted Garbage Category


🔄 Workflow

  1. User uploads a garbage image.
  2. The image is resized and preprocessed.
  3. During training, data augmentation generates additional image variations.
  4. The processed image is passed to EfficientNetV2B2.
  5. The model extracts image features.
  6. Fine-tuned classification layers predict the waste category.
  7. The class with the highest confidence score is returned to the user.

🧠 Model

Base Model

  • EfficientNetV2B2

Approach

  • Transfer Learning
  • Fine-Tuning
  • Image Classification

Framework

  • TensorFlow
  • Keras

🚀 Why EfficientNetV2B2?

Instead of training a Convolutional Neural Network from scratch, this project leverages a pre-trained EfficientNetV2B2 model trained on the ImageNet dataset.

This approach offers several advantages:

  • Faster convergence
  • Reduced computational cost
  • Better feature extraction
  • Improved accuracy with limited datasets
  • Lower training time

📈 Training Techniques

To improve model performance, the following techniques were incorporated:

Data Augmentation

  • Random Rotation
  • Random Flip
  • Random Zoom
  • Random Contrast

These transformations improve the model's ability to generalize to real-world images captured under different conditions.


Class Weights

The dataset contains different numbers of images for each category.

Balanced class weights were used to reduce bias toward majority classes and improve prediction performance on minority classes.


Early Stopping

Training automatically stops when validation performance no longer improves.

This prevents overfitting and restores the best-performing model.


🛠️ Technology Stack

Programming Language

  • Python

Libraries & Frameworks

  • TensorFlow
  • Keras
  • NumPy
  • Pandas
  • Matplotlib
  • Scikit-learn
  • Gradio

Model

  • EfficientNetV2B2

📁 Project Structure


Garbage-Classification/
│
├── dataset/
├── model/
├── app.py
├── train.py
├── requirements.txt
├── README.md
└── docs/


🔮 Future Improvements

Potential enhancements include:

  • Mobile application deployment
  • Real-time camera-based waste classification
  • Object detection for multiple waste items
  • Larger and more diverse datasets
  • Cloud deployment
  • Smart recycling bin integration

📚 Learning Outcomes

Through this project, I gained practical experience with:

  • Transfer Learning
  • Fine-Tuning
  • Computer Vision
  • Image Classification
  • TensorFlow & Keras
  • Data Augmentation
  • Handling imbalanced datasets
  • Model evaluation
  • Deep Learning workflows

👩‍💻 Author

Visha Yadav

Computer Engineering Student
AI & Software Engineering Enthusiast


About

EfficientNetV2B2-based garbage classification with transfer learning, data augmentation, and an interactive Gradio interface.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages