Skip to content

A CNN model that can tell which type of mask you are wearing ;)

License

Notifications You must be signed in to change notification settings

Aminekabene/AI_Mask_Classifier

Repository files navigation

MIT License LinkedIn


AI Face Mask Classifier

A CNN model that can tell which type of mask you are wearing ;)
View Demo · Report Bug · Request Feature

Table of Contents
  1. About The Project
  2. License
  3. Contact

About The Project

As you can see the Classifier can distinguish between four different classes: No Mask, Surgical Maks, Cloth Masks and N95 Masks.

The Architecture

The classifier was implemented using the AlexNet CNN architecture:

  • 5 Convolution Layers
    • Batch Normalisation
    • Relu Activation
    • Max Pooling
  • 3 Fully Connected Layers
    • Drop out rate of 0.5
    • Relu Activation

Let's Talk Numbers

The model was trained on 50 epoch achieving 76% Accuracy! It was trained on a custom dataset compromising of 1200 training images and 400 test images. A variety of random transforms were applied to the dataset in an effort to enhanced the performance of the model.

I know I know you want to see the accuracy, recall, f1-score, class performance, etc. Don't worry, Here it is :)

               precision    recall  f1-score   support

       CLoth      0.53      0.89      0.66       900
       N95        0.79      0.67      0.72      2700
       No Mask    0.82      0.85      0.84      1350
       Surgical   0.87      0.77      0.82      2250

accuracy                              0.76      7200
macro avg         0.75      0.80      0.76      7200
weighted avg      0.79      0.76      0.77      7200

(back to top)

Built With

  • pytorch
  • OpenCV
  • Python

(back to top)

Contact Me

Amine Kabene

Project Link: https://github.com/Aminekabene/AI_Mask_Classifier

(back to top)

Thank you for checking out my project!

About

A CNN model that can tell which type of mask you are wearing ;)

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages