Face Mask Detection

A Deep learning flask based application used to predict whether Person is having mask to his face or not

AI & Machine LearningHTMLMIT

Abstract

Face Mask Detection is an open-source AI & Machine Learning project. A Deep learning flask based application used to predict whether Person is having mask to his face or not. This Deep Learning Web Application utilizes a Convolutional Neural Network to process the person Images and predict if their Mask is ON/OFF accuracy of nearly 98%. Here this model is made by a pretrained model VGG16. It is built using HTML. The complete source code is publicly available on GitHub under the MIT License, making it a useful reference for students building an AI & Machine Learning mini project or final-year project.

1. Introduction

This Deep Learning Web Application utilizes a Convolutional Neural Network to process the person Images and predict if their Mask is ON/OFF accuracy of nearly 98%. Here this model is made by a pretrained model VGG16.

As Social Distancing is only tool to prevent COVID-19 wearing face masks is compulsory. To monitor the mass no of people whether they wear a mask or not I came up with a solution using deep learning Here I can used Convulutional Nueral Networks(CNN) to predict whether the person is wearing the mask or not . I took the person images with and with_out masks through web scraping and started working on it. the dataset consists of nearly 2000.

Our Model performs fairly well with an accuracy of 98% and an F1 Score of 97%. This provides a handy tool to utilize the power of Machine Learning and Artificial Intelligence in Binary Classification Problems where time and accuracy is the paramount objective of classification.

2. Objective

A Deep learning flask based application used to predict whether Person is having mask to his face or not

This project demonstrates how HTML can be applied to a real-world AI & Machine Learning problem.

4. Technology Stack

HTML
  • Bootstrap
  • Tensorflow

5. System Requirements

General requirements for this technology stack — check the README for exact versions.

  • A modern web browser
  • VS Code or any code editor
  • Git (to clone the repository)

6. Installation & Setup

git clone https://github.com/ksdkamesh99/Face-Mask-Detection.git
cd Face-Mask-Detection
  1. Drop a ⭐ on the Github Repository.
  2. Clone the Repo by going to your local Git Client and pushing in the command:
  3. Install the Packages:
  4. At last, push in the command:
  5. Go to http://127.0.0.1:5000/ and enjoy the application.
  6. Examples are provided in the directory You can try using them.
  7. Some screenshots of the application are mentioned Below.
https://github.com/ksdkamesh99/Face-Mask-Detection.git
pip install -r requirements.txt
python app.py

Full setup instructions are in the project README.

7. Future Enhancements

Suggested extensions you can add to make this your own project.

  • Deploy the model as a web app with Streamlit, Flask or FastAPI
  • Compare against an additional model and report the metric difference
  • Add explainability (SHAP / Grad-CAM)

8. Viva / Review Questions

Common questions examiners ask for projects in this domain.

  1. What dataset does the project use and how was it pre-processed?
  2. Which algorithm / model architecture is used and why was it chosen over alternatives?
  3. How are training and testing data split, and how is overfitting avoided?
  4. Which evaluation metrics (accuracy, precision, recall, F1) are reported and what do they mean here?
  5. How would you deploy this model for real users?

9. Source Code & License

This project is developed by ksdkamesh99 and published on GitHub under the MIT License. Please follow the license terms and credit the original author when you use or modify this code.

Want to build this as your internship project?

Work on an AI & Machine Learning project like this with mentor guidance, weekly reviews and an internship certificate from Training Trains, Erode — online or offline.

Apply for AI & Machine Learning Internship