Skip to main content

It recognize the face mask on human on the image

Project description

Project Description

Face Mask Recognition using PyTorch.

It creates a bounding box around the face of the person present in the image and put a text
at the top of the bounding box shows probability of mask on the face.

Install:

pip install mask_recognition

Requirements:

pytorch >= 1.2.0

torchvision >= 0.3.0

Usage:

from mask_recognition import MaskRecognition

import cv2 as cv

mr = MaskRecognition(device=0)  # -1 for cpu, 0 for gpu

frame = mr.recognize(frame, color="rgb")    # color="bgr" for BGR color scheme. frame is the RGB image.

########################## To use webcam ##########################

mr.cam_capture(device_id=0)     # 0 for default or 1, 2, 3, if more than one webcam

## press esc to stop    

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

mask_recognition-0.0.1-py3-none-any.whl (27.7 MB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page