Garbage Classification
Garbage Classification
Abstract—Undeniably, in this modern day, recycling is an small errors, which is great because it can help people to
essential work for any country. Specifically, garbage classification classify garbage easily. Besides garbage classification, we
is the most important step to enable cost-efficient recycling. also tried two different classifiers that are Sofmax and SVM
Designing a computer vision model to classify garbage images
into recycling categories could be an effective way to process to observe the effect of network performance and optimize
waste. In this paper, we aims to take samples of waste and them. We analyzed the network statistics to identify areas
classify them into 12 classes: battery, biological, brown-glass, of improvement and eliminate potential problems, so we
cardboard, clothes, green-glass, metal, paper, plastic, shoes, trash can maximize speeds and feeds easily. By observing the
and white-glass. The dataset that we used contains around 600 effect of network performance, we can see how the network
images for each class. The models used in the experiments are
Pre-trained VGG-16 and ResNet50. We also tried two different performance affects daily life and the process of garbage
classifiers Sofmax and Support Vector Machine to observe the classification.
effect on network performance. Experiments showed that our The models can help people learn to save resources, use re-
models reached accuracy around 93%. sources, develop good living habits, and improve their personal
quality. Then, people can develop a better waste sorting habit,
I. I NTRODUCTION
they will begin to pay attention to environmental protection
Recently, environmental pollution has been considered a problems, begin to treasure the preciousness of resources in
major problem in the world. The world bank report showed life, and develop the habit of saving resources.
that there are almost 4 billion tons of waste around the
world every year and the urban alone contributes a lot to this II. DATASET
number, the waste is predicted to increase by 70 percent in Most of the images involving garbage is accessible and can
the year 2025. Moreover, The world generates 2.01 billion be found easily on the internet. This data is present in variety
tonnes of municipal solid waste annually, with at least 33 with different types according to different class labels/target
percent of that—extremely conservatively—not managed in labels. In the dataset, there are a total of 15,150 images from
an environmentally safe manner. A reason for such is that 12 different classes of common garbage; batteries, cardboard,
people cannot immediately classify recyclable trash from non- paper, biological, plastic, metal , brown-glass, green-glass,
recyclable trash. Because of that, people will just throw all white-glass, clothes, shoes, and trash. The datasets were taken
kinds of trash together such as organic waste, inorganic waste, from:
toxic waste, etc. into one trash bin. • Most of the clothes category and 22% of the shoes’
In 2019, China started to require residential garbage clas- category were taken from the Clothing dataset https:
sification, in which case the front-end collection is highly //www.kaggle.com/agrigorev/clothing-dataset-full
dependent on people’s awareness. Therefore, the efficiency of • Approximately 29% from the other 9 classes was ob-
the garbage classification still needs to be improved. It is of tained from the Garbage Classification dataset https:
great academic value and practical significance to study an //www.kaggle.com/asdasdasasdas/garbage-classification
effective automatic garbage classification method. • The remaining of the images were created using Web
In order to reduce the amount of waste, we used two models Scrapping.
which are Pre-trained VGG-16 (VGG16) and ResNet50 that • Every image that we create from web scrapping are
can classify most of the input data in spite of having some owned by their original photographers/owners. The im-
Fig. 1. The network structure in VGG16
ages are only used for academic research and is not used paper, speak about a faster Region-based Convolutional Neural
to generate any profit. If the original photographer/owner Network (Faster R-CNN) for object classification, reaching
wish to take down the dataset, then by their request, any a mAP of 68.3%. Maher Arebey et al. proposes to use the
of the images in the data set can be deleted. grey level co-occurrence matrix (GLCM) method in garbage
detection which uses advanced communication mechanisms
TABLE I like radio frequency identification (RFID), Geographical infor-
DATASET OVERVIEW mation system (GIS), etc to strengthen the waste segregation
process. The features obtained from GLCM are given as inputs
Sr no Category Number of Annotated to Multi-Layer Perceptron (MLP) and K-Nearest Neighbours
Images classifier.
1 Battery 945 Yes
2 Biological 985 Yes IV. M ETHOD
3 Brown-glass 607 Yes A. VGG16 with Batch Normalization
4 Cardboard 891 Yes
5 Clothes 5325 Yes In this structure, the convolution layer and the batch normal-
6 Green-glass 629 Yes ization (BN) layer are mainly used to extract image features.
7 Metal 769 Yes The BN [6] layer is used to improve the generalization
8 Paper 1050 Yes ability of the network, disturb the training data, and accelerate
9 Plastic 865 Yes the convergence speed of the model. During the process of
10 Shoes 1977 Yes training, BN is calculated based on each small batch. The
11 Trash 697 Yes mean and variance corresponding to each batch of data during
training are recorded and used to calculate the mean and
12 White-glass 775 Yes
variance of the entire training set, which is performed as
follows:
and pooling layers get through the rough features of the im-
ages. The model uses 16 residual blocks after the convolutional
block. Further an average pooling layer is used to down-
sample the feature matrix, a flatten layer and a dropout layer
followed by a fully connected layer. The dropout is considered
as regularization which helps in adding extra noise and average
the overfitting errors. The cost function used is the RELU
function followed by a Sigmoid SoftMax in the last layer. Fig. 3. Proposed method
R EFERENCES
[1] He, Kaiming & Zhang, Xiangyu & Ren, Shaoping & Sun,
Jian. (2016). Deep Residual Learning for Image Recognition.
10.1109/CVPR.2016.90, pp. 770778.
[2] S. L. Rabano, M. K. Cabatuan, E. Sybingo, E. P. Dadios
and E. J. Calilung (2018), “Common Garbage Classification
Using MobileNet”, 2018 IEEE 10th International Confer-
ence on Humanoid, Nanotechnology, Information Technology,
Communication and Control, Environmental and Management
(HNICEM), Baguio City, Philippines, 2018, pp. 1-4, doi:
10.1109/HNICEM.2018.8666300.
[3] O. Awe, R. Mengistu, and V. Sreedhar (2017), “Smart
TrashNet: Waste localization and classification, 2017”.
[4] Maher Arebey, M.A. Hannan, R.A. Begum, Hassan Basri
(2012), Solid watse bin level detection using gray level co-
occurrence matrix feature extraction approach, Journal of
Environmental Management, Volume 104, 2012, Pages 9-18,
ISSN 0301-4797.
[5] S. Begumpure, P.M.Jadhav (2019), “Comprehensive Re-
view Of Generic Object Detection Frameworks Using Deep
Learning Approach”, IEEE International Conference on Con-
temporary Engineering and Technology, April, 26th-27th,
2019, Chennai.
[6] Ioffe, S.; Szegedy, C. Batch Normalization: Accelerating
deep network training by reducing internal covariate shift.
In Proceedings of the International Conference on Machine
Learning, Lille, France, 6-11 July 2015; pp. 448-456.
[7] C.CHANG (2018), “Garbage Classification.” Kaggle,
2018, doi: 10.34740/KAGGLE/DS/81794.
[8] Abubaker A., 2012. Mass Lesion Detection Using Wavelet
Decomposition Transform and Support Vector Machine, IJC-
SIT, 4(2), 33-46.
[9] Saitta L., 1995. Support-Vector Networks, Machine Learn-
ing, 20, 273-297.