Skip to content

citteriomatteo/plants-classifier-neural-networks

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Multiclass classification with CNNs on unbalanced dataset

Introduction

This repo contains our work regarding the 1st challenge of the Artificial Neural Networks and Deep Learning course at Politecnico di Milano. The goal of this challenge is to model a neural network able to classify images of 8 different species of plants training a neural network with a given dataset.

Final team rank position: 10th out of 200 teams.

The detailed report of our work can be found here.

Dataset

The dataset contains 3542 images of size 96x96 and divided into the following classes:

Species1 : 186
Species2 : 532
Species3 : 515
Species4 : 511
Species5 : 531
Species6 : 222
Species7 : 537
Species8 : 508

Example of images

00001 00023 00022 00023 00036 00039 00232 00049

Improving data quality

We adopted multiple techniques to improve the quality of the given dataset

  • Data augmentation
  • Removing low quality images (e.g. images with external objects)
  • Upsampling of underrepresented classes

Transfer learning

Our best scoring models make use of transfer learning and has the following architecture

We applied the classic Transfer Learning workflow:

  1. Using the pretrained network as a feature extractor by freezing its layers
  2. Fine tuning by unfreezing partly or completely the layers of the pretrained network

Our best scoring model uses ConvNeXtXLarge, pretrained on the ImageNet datasets.

Results

Our best model reached an accuracy of 0.9211, with an F1 score of the most scarce and problematic class (species 1) of 0.8516 (4th best).

F1-score table on the private test set:

Species 1 Species 2 Species 3 Species 4 Species 5 Species 6 Species 7 Species 8
F1-score 0.8516 0.9258 0.9667 0.9162 0.9276 0.9500 0.9777 0.8564

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published