0% found this document useful (0 votes)
34 views29 pages

Real-Time Facemask Detection and Alerting System Using Deep Learning

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
34 views29 pages

Real-Time Facemask Detection and Alerting System Using Deep Learning

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 29

TEAM NO:

21

TEAM MEMBERS:
BRIHAT KALERU
20261A3214 Real-Time Face Mask
Detection and Alert System
M SOHAN
20261A3239 using Deep Learning
NAVAKESH GUIDE:
Dr. B HARIKA
21265A3205 ASSOCIATE PROFESSOR, IT
CONTENTS

 Abstract  Modules
 Introduction  UML Diagrams
 Existing System  Algorithms
 Proposed System  Implementation & Packages
 Requirements  Sample Code
 Literature survey  Output
 System Architecture  Conclusion
ABSTRACT

◼ A real-time face mask detection and alert system is developed using deep learning
techniques.
◼ The system utilizes Convolutional Neural Networks (CNNs) and Haar-Cascade
Classifier to accurately identify masked individuals in live video streams.
◼ The system triggers alerts when individuals without masks are detected, aiming to
enforce mask-wearing protocols and promote public health.
◼ The system facilitates immediate intervention and proactive rectification of non-
compliance, contributing to disease prevention and control efforts.
INTRODUCTION

◼ The "Real-Time Face Mask Detection and Alert System using Deep Learning" project
aims to create a system that can detect whether a person is wearing a face mask in
real time.
◼ The system uses advanced computer techniques called deep learning to analyze live
video or images and make quick decisions.
◼ If the system detects that a person is not wearing a mask where it is needed, it will
trigger an alert to notify the relevant people or authorities, helping to ensure
compliance with mask wearing guidelines and potentially preventing the spread of
diseases.
EXISTING SYSTEM
● In the existing system, face mask detection might rely on manual inspection or
human monitoring.
● This could involve having individuals stationed to visually check whether people
entering a specific area are wearing masks.
● However, this approach has limitations:
Subjectivity: Manual inspection can be subjective.
Resource Intensive: It requires dedicated personnel to continuously monitor and
enforce mask-wearing rules.
Delay: Even if detected, there might be a delay in addressing non-compliance,
which could impact the effectiveness of mask-wearing measures.
Scalability: Manual monitoring is not scalable for large crowds or areas.
PROPOSED SYSTEM

● The proposed system aims to use deep learning techniques to automate the
process of real-time face mask detection and alerting.
Face Mask Detection: The system employs a deep learning model, trained on a
dataset of images of people with and without masks, analyzes the detected
faces and classifies whether a person is wearing a mask.
Alerting: If a person is detected without a mask where it's required, the system
generates an alert in real-time and can send notifications to relevant parties.
● The proposed system has the following advantages over existing systems -
Automation, Real-Time, Scalability, and Efficiency.
REQUIREMENTS

SOFTWARE REQUIREMENTS:
 LANGUAGES: Python
 DATABASES & SECURITY: SQL
 SCRIPTING LANGUAGES: HTML,CSS &JS

HARDWARE REQUIREMENTS:

 OPERATING SYSTEM: Windows 7 or more


 RAM: 4GB or above
 CAMERA: 1080P WEBCAM ,30FPS or more
LITERATURE SURVEY

A. Ghosh, T. Shetty and J. Silviya Nancy, "Face Mask Detection And Alert System Using Convolution Neural
Networks," IEEE International Conference on Computation System and Information Technology for Sustainable
Solutions (CSITSS), Bangalore, India, 2021, pp. 1-6.
 The authors addresses the issue of real-time face mask detection in video streams using deep learning
techniques.
 The authors propose an end-to-end deep neural network architecture that can detect whether a person is
wearing a face mask or not.
 The model is trained on a large dataset of annotated images containing people with and without masks.
 The proposed architecture involves convolutional neural networks (CNNs) for feature extraction and
classification.
 The system is designed to work in real-time video streams and demonstrates accurate and efficient face mask
detection, contributing to safety measures during the COVID-19 pandemic.
MODULES

◼ Data Acquisition Module:- OpenCV or FFmpeg: For capturing and processing video streams or image frames
from cameras or video sources.
◼ Face Detection Module:- Pre-trained CNN models (ResNet50, DenseNet, MobileNet-V2): For efficient face
detection in real-time.- Face detection libraries (dlib, OpenCV): To detect and localize faces in the captured
frames.
◼ Mask Classification Module:- Pre-trained CNN models (VGG16, InceptionV3, Xception): For classifying
whether a detected face is wearing a mask or not.- Face mask classification libraries (OpenCV, Keras,
TensorFlow): To implement and train the mask classification model.
◼ Alert Generation Module:- OpenCV or Pygame: For generating visual alerts or audio signals.- Notification
APIs or libraries: To send notifications to a monitoring system.
SYSTEM ARCHITECTURE
CLASS DIAGRAM
USE CASE DIAGRAM
SEQUENCE DIAGRAM
ACTIVITY DIAGRAM
DATA FLOW DIAGRAM
ALGORITHM
CNN:
● A Convolutional Neural Network (CNN) is a deep learning model specifically designed for
image processing tasks.
● It consists of multiple layers, including convolutional layers, pooling layers, and fully
connected layers, that work together to extract features from images.
● A convolutional neural network (CNN or ConvNet) is a network architecture for deep
learning that learns directly from data.

Haar Cascade Classifier:


● The Haar Cascade Classifier algorithm is a machine learning-based object detection method
used for identifying objects or patterns within images, such as faces
● It uses a set of trained classifiers to identify faces based on features like edges, lines, and
rectangles.
IMPLEMENTATION STEPS
Step-1:
● The algorithm starts by collecting input data, which is typically video frames captured by a camera
Step-2:
● It uses a face detection algorithm (e.g., Haar Cascade or deep learning-based methods) to locate
faces within each frame.
● This step identifies the regions of interest (ROIs) containing faces.
Step-3:
● For each detected face ROI, the algorithm applies a mask detection model. This model is based on
deep learning, such as a Convolutional Neural Network (CNN), trained to classify whether a face in
the ROI has a mask or not.
● It analyzes facial features to make this determination.
Step-4:
● When the algorithm detects a face without a mask, it identifies the person using face detection
model and triggers an alert by sending an email to resp authorities or the person.
PACKAGES
TensorFlow:
● TensorFlow is an open-source machine learning framework developed by Google.
● It is widely used for various machine learning and deep learning tasks, including neural networks,
natural language processing, and computer vision.
● TensorFlow provides a flexible and efficient platform for building and training machine learning
models, especially deep learning models.

Keras:
● Keras is an open-source high-level neural networks API written in Python.
● It serves as an interface to other deep learning frameworks, including TensorFlow.
● Keras allows for quick prototyping of deep learning models and supports various types of neural
networks, such as convolutional neural networks (CNNs), etc.
PACKAGES
OpenCV (Open Source Computer Vision Library):
● OpenCV is an open-source computer vision and machine learning software library.
● It offers a wide range of tools and functions for image and video processing, including image
recognition, object detection, and facial recognition.

NumPy:
● NumPy is a fundamental library for scientific computing in Python.
● It provides support for arrays and matrices, along with mathematical functions to operate on these
arrays efficiently.

Smtplib:
● Smtplib is a built-in Python module that provides a simple way to send emails using the Simple Mail
Transfer Protocol (SMTP)
TEST CASES
Test Test Case Purpose Input Expected Actual result Result
Case Name result
ID

1 Mask To detect Mask Detected Pass


Detection weather a
person is
wearing a
mask or not
TEST CASES

Test Test Purpose Input Expected Actual Result Result


Case Case Result
ID Name

2 Face To detect the person Brihat Pass


Detection not wearing a mask
TEST CASES
Test Test Purpose Input Expected Actual Result Result
Case Case Result
ID Name

3 Alert To alert the Email Fail


system person not Received (Email
wearing a not
mask. received)
TEST CASES

Test Test Case Purpose Input Expected Result Actual Result Result
Case Name
ID

4 Side profile To check if a Brihat Fail(Unable


Recognition person is to
being recognize
recognised side profile)
even though
he is not
looking into
the camera
directly.
OUTPUT

Fig - Output screen to add a user’s face and details


OUTPUT

Fig - Output screen when a person if detected with a mask


OUTPUT

Fig - Output screen when a person if detected without a mask


OUTPUT

Fig - Output email to the user when they are detected without a mask
CONCLUSION
● In conclusion, the real-time face mask detection and alert system uses deep learning
and face recognition technology to improve safety and compliance with mask-
wearing guidelines.
● Using a pre-trained deep learning model, the system can accurately identify whether
a person is wearing a mask or not, providing immediate visual feedback.
● Additionally, it includes face recognition to identify individuals.
● When an individual without a mask is detected, the system not only alerts them but
also sends an email notification to the respective person.
● This proactive approach ensures that safety measures are upheld and potentially
risky situations are addressed promptly.
THANK YOU

You might also like