Recycling Classifier: An AI-driven Solution to Boost Recycling Rates and Encourage Investment
Published: 2023-04-20 21:58:41

The recycling industry is essential for reducing waste and conserving resources. In 2020, the US recycling industry generated 681,000 jobs, $37.8 billion in wages, and $5.5 billion in tax revenues. However, the amount of recyclable materials collected per year has been decreasing since around 2009. To counter this trend and incentivize companies to invest in the recycling industry, a recycling classification model was developed with the goal of creating a user-friendly app that helps people recycle more effectively. This project aims to increase the amount of recyclable materials generated each year, creating more opportunities for investment in the recycling industry.

**Data Understanding:**
The dataset used for this project was found on Kaggle and contains images of various recyclable materials, sorted into different classes. The dataset has some class imbalance, which is addressed during preprocessing.


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/4t93oa7pym5qyvp3xwsh.png)

**Preprocessing:
**To tackle the limited amount of images in the original dataset, data augmentation was applied to the training set. Class weights were also used to handle the class imbalance present in the dataset.

**Modeling:**
Initially, various combinations of convolutional layers and regularizations were experimented with to build a model for identifying recycling materials. However, none of the models provided satisfactory results. Transfer learning, specifically the VGG16 model, was then used. The VGG16 model, pretrained on over a million images from the ImageNet database, can classify images into 1000 object categories. The best combination of convolutional layers and regularizations was initially incorporated into the VGG16 model, but ultimately, using only the VGG16 model achieved better results.

**Evaluation:**
Accuracy was chosen as the evaluation metric for this project, as it is a suitable choice when dealing with class imbalance. Three models were evaluated using confusion matrices and accuracy percentages. The VGG16 model outperformed the other models with a final accuracy of 77%.

**Recommendations:**
For practical application, the model should be translated into a user-friendly app and user usage should be tracked to determine if there is a correlation with an increase in recyclable materials. Although a website deployment of the model using Streamlit was created, the ultimate goal is to develop a simple mobile app for phones.

**Next Steps:**
1.Acquire more images to balance the classes.
2.Experiment with more combinations of layers and regularization.
3.Try other image preprocessing techniques to see if the model performs better.

**Conclusion:**
The Recycling Classifier project demonstrates the potential for AI-driven solutions to address environmental challenges and stimulate economic growth. By developing a user-friendly app to help people recycle more effectively, this project aims to increase the amount of recyclable materials generated each year, promoting a more sustainable future and encouraging investment in the recycling industry.