Skip to content

A face mask detection program that distinguishes whether or not the user is wearing a mask.

Notifications You must be signed in to change notification settings

mdola19/Face-Mask-Detector

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Face Mask Detector

This face mask detection program detects faces using a webcam and applies a machine learning model to determine whether or not the person is wearing a mask. It can be used to ensure people entering a classroom or family gathering are wearing a mask by simply setting it up near the entrance. A text-to-speech feature is also implemented in this program to remind people who are not wearing a mask to wear a mask.

Dataset

To train the machine learning model, we have used a dataset from the Kaggle platform.

The Machine Learning Model

As we were working with image data, the best tool for this is a Convolutional Neural Network (CNN). This deep learning model can find patterns in the data in order to classify images. More details on training this model can be viewed in this file: face_mask_detector.ipynb.

Main Tools Used

  • Python - the coding language that was used to make this project
  • Keras - the deep learning framework that is used to train the machine learning model
  • OpenCV - the library that was used to process images when training the model and also to access the webcam to detect faces

How This works

Demo_1.mp4
Demo_2.mp4

How To Use

  1. First download the repository
  2. Then install requirements.txt to download all the required modules to run this program
pip install -r requirements.txt
  1. Run face_mask_detection.py
  2. You should now be able to use this program successfully

Contributors

  • @thuvaragan25 - Worked on implementing the Convolutional Neural Network and training the machine learning model
  • @mdola19 - Worked on detecting faces in live webcam feed to look for face masks using the machine learning model and displaying results

About

A face mask detection program that distinguishes whether or not the user is wearing a mask.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Jupyter Notebook 97.7%
  • Python 2.3%