← Back to projects

Real-time Face Mask Detection System

Computer vision application that detects face masks in real-time using deep learning and OpenCV.

Technologies Used

Python
TensorFlow
OpenCV
MobileNetV2
NumPy
Keras
Flask

About This Project

Developed a real-time face mask detection system using computer vision and deep learning techniques to help enforce safety protocols during the COVID-19 pandemic. The system accurately detects whether individuals are wearing face masks or not.

The application uses a custom-trained convolutional neural network (CNN) based on MobileNetV2 architecture for efficient real-time inference. The model was trained on a diverse dataset of faces with and without masks, achieving over 95% accuracy in various lighting conditions and angles.

The system processes video streams in real-time, drawing bounding boxes around detected faces and classifying them into two categories: mask worn (green) and no mask (red). It includes features like multi-face detection, confidence scoring, and alert generation for non-compliance.

Technical implementation includes optimization for edge devices using TensorFlow Lite, allowing deployment on resource-constrained hardware like Raspberry Pi. The system can process 30+ FPS on standard hardware while maintaining high accuracy, making it suitable for deployment in entry points, offices, and public spaces.

Gallery

Real-time face mask detection demo

Impact & Results

Deployed in 10+ locations, processed 100,000+ detections daily, achieved 95%+ accuracy, and helped maintain safety compliance in public spaces.

Made with ❤️ by Ibrahim Shittu