logo SBA

ETD

Archivio digitale delle tesi discusse presso l’Università di Pisa

Tesi etd-07052025-185906


Tipo di tesi
Tesi di laurea magistrale
Autore
ZINGARIELLO, FRANCESCO
URN
etd-07052025-185906
Titolo
Development of an Embedded Computer Vision System for Automatic Waste Classification: The Hoooly! Project
Dipartimento
INGEGNERIA DELL'INFORMAZIONE
Corso di studi
ARTIFICIAL INTELLIGENCE AND DATA ENGINEERING
Relatori
relatore Prof. Cococcioni, Marco
relatore Prof. Tucci, Mauro
correlatore Thomopulos, Dimitri
Parole chiave
  • CNN
  • computer vision
  • edge AI
  • efficientNetV2
  • embedded systems
  • raspberry pi
  • smart waste bin
  • tensorFlow
  • transfer learning
  • waste classification
Data inizio appello
23/07/2025
Consultabilità
Non consultabile
Data di rilascio
23/07/2095
Riassunto
This thesis presents the design, development, and evaluation of a smart waste bin prototype capable of classifying and sorting waste using computer vision and embedded artificial intelligence. The system integrates a convolutional neural network (CNN) for image-based waste classification with a mechanical sorting mechanism. The project was developed as part of a broader initiative in collaboration with a startup, contributing to real-world use cases and commercial demonstrations with major clients.
The prototype features a sealed input chamber where users insert waste items. These items rest on a rotating platform equipped with a camera. Upon detection, the platform rotates to a classification position, captures an image, and sends it to the onboard CNN for inference. The waste item is then directed to one of four customizable bins beneath the rotating platform based on its predicted category. The mechanical actuation and sensors are managed through a state-machine logic written in C on a dedicated microcontroller that interfaces with the Raspberry Pi and handles inputs from fill-level sensors, entrance sensors, and bin door status sensors.

The CNN was trained using transfer learning with pre-trained backbones—MobileNetV2, MobileNetV3, and EfficientNetV2-B0—finetuned on a custom waste image dataset. Two taxonomies were explored: a fine-grained version (e.g., plastic cups, glass, napkins) and a simplified 6-class taxonomy. Images were collected both in laboratory and real-world settings and augmented to improve robustness. Several configurations of dense layers and hyperparameters were tested to balance accuracy, inference latency, and model size. EfficientNetV2 consistently outperformed other backbones in classification accuracy, achieving up to 94% test accuracy in the reduced 6-class scenario.
The models were evaluated on multiple metrics, including top-1 accuracy, per-class precision and recall, inference latency, and memory footprint. Confusion matrices and classification reports revealed challenges in fine-grained class separation, especially between visually similar categories like paper, napkins, and Tetrapak. A significant insight emerged when the removal of the "paper" class led to a large boost in performance, confirming that high-quality data and clear class boundaries are critical for successful multi-class classification. This finding suggests that the underlying architecture is capable of handling more classes given a better-curated dataset.
Deployment involved not only inference testing but also full-cycle validation, including detection-to-sorting timing, mechanical reliability, and resilience under varied lighting and environmental conditions. The final system demonstrated over 92% actuation reliability and sustained performance over hundreds of test cycles. Furthermore, the bin connects to Google Cloud via Firebase, allowing real-time photo logging, remote updates, and performance monitoring—extending its potential for smart city applications.
This work exemplifies the integration of deep learning, embedded systems, and mechanical engineering to solve a practical environmental problem. It serves as a foundation for future research on adaptive waste classification, confidence-aware sorting, and scalable deployment across urban infrastructures. The thesis not only showcases a successful engineering implementation but also contributes to the sustainability and digital transformation goals in waste management.
File