Back to projects

Project

Waste Detection in the Built Environment

Automatic classification of waste in street-view images using a YOLO-based object detection pipeline.

Python YOLO Computer Vision CVAT Deep Learning

Overview

This project addresses the automatic classification of waste using 10,000 street-view images. The objective is to build a machine learning pipeline that trains, validates, and tests on data to identify whether an image contains waste and classify it into five predefined categories.

Objective

To identify whether an image contains waste and classify it into five predefined categories: bulky waste, garbage bag, cardboard, litter, and other.

Method

01

Images were manually annotated in CVAT using five predefined classes, with bounding boxes assigned to visible waste objects

02

A temporal dataset split was used to prevent data leakage and simulate real-world deployment

03

The YOLO26n model was selected for its lightweight architecture and trained for 100 epochs with early stopping (patience = 20), image size 512 and batch size 8

04

Both classification and detection approaches were evaluated; the detection model was selected due to its ability to provide spatial localisation and multi-class predictions

05

Predictions were ranked based on highest confidence detection per image, and evaluation was conducted using Precision at 100 (P@100)

Visuals

Example of correct detection where the model identifies visible waste objects with high confidence.
False positive: non-waste object incorrectly classified as a garbage bag with near-zero confidence.

Results

Confusion matrix showing class-wise detection performance on the test dataset, highlighting strong background bias and missed detections.
Precision–Recall curve showing low recall across all classes, with the garbage bag class achieving the highest performance.

Analysis

  • The dataset exhibits strong class imbalance, leading to dominance of background samples during training
  • This results in reduced recall and a bias toward predicting clean scenes
  • Class-wise performance shows garbage bag achieving the highest performance (AP = 0.186), while cardboard and other remain near zero
  • Precision remains stable at low recall but drops rapidly as recall increases

Reflection

  • The dominant error type is false negatives due to class imbalance and low object frequency
  • The model is recall-limited rather than precision-limited
  • Labelling ambiguity affects evaluation, where correct detections may be penalised due to class mismatch
  • Ranking-based evaluation (P@100) remains effective even when detection metrics are low