Skip to content

A challenging, in the wild dataset for experimentation with face masks with 63,072 face images.

License

Notifications You must be signed in to change notification settings

borutb-fri/FMLD

Repository files navigation

Face Mask Label Dataset (FMLD)

The Face Mask Label Dataset (FMLD) is a challenging, in the wild dataset for experimentation with face masks. The dataset is the biggest annotated face mask dataset with 63,072 face images.

This repository contains labels and annotations for all images and the PyTorch implementation of the following paper: How to Correctly Detect Face-Masks for COVID-19 from Visual Information? [1]

Images annotated for FMLD were taken from datasets:

Overall FMLD statistics

Images annotated for FMLD were taken from the MAFA and Wider Face datasets and partitioned into three classes (correctly worn masks, incorrectly worn masks and without masks) and later equipped with additional labels.

tabel

Labels/Annotations for all images

Our annotations [1]: FMLD_annotations.zip

Dataset lists

Lists of images from the MAFA dataset:

Lists of images from the Wider Face dataset

labels As can be seen, the dataset contains labels for gender, pose and ethnicity in addition to the main labels indicating the presence of face masks and their correct/incorrect placement.

All images are annotated with labels indicating the presence of face masks, the placement of face masks (i.e., correct or incorrect), the gender of the subjects, their ethnicity and head pose.

We used XML files in the PASCAL VOC file format for annotations. The annotation file for each image contains information about:

  • the name of the original image,
  • it’s size and
  • the source dataset.

The annotated face in the image can be:

  • with mask (name: masked_face),
  • without mask (name: unmasked_face) and
  • with mask worn incorrectly (name: incorrectly_masked_face).

Each face object has bounding box information and labels for

  • gender (male / female),
  • ethnicity (asian / white / black) and
  • pose (front / turned sideways).

Note: difficult label in testing dataset (difficult=1)

  • faces with invalid label in original dataset (name: invalid_face)
  • faces in original dataset but not included in our FMLD dataset (unmasked_face)
  • additional faces added using a face detector (masked_face /unmasked_face/incorrectly_masked_face)

Support code

Code for display images with annotations and save test/train faces from images.

MATLAB code : show_save_gt.m
Python code : show_save_gt.py

Example usage

Monitoring if people are using masks correctly

resnet152.pt: Pytorch model for classification.

mask-test.py: Python code to classify the correctly worn mask (compliant/non-compliant)

shema

Citation

If you use our annotations or models, please use following citations

[1] 
@Article{app11052070,
AUTHOR = {Batagelj, Borut and Peer, Peter and Štruc, Vitomir and Dobrišek, Simon},
TITLE = {How to Correctly Detect Face-Masks for COVID-19 from Visual Information?},
JOURNAL = {Applied Sciences},
VOLUME = {11},
YEAR = {2021},
NUMBER = {5},
ARTICLE-NUMBER = {2070},
URL = {https://www.mdpi.com/2076-3417/11/5/2070},
ISSN = {2076-3417},
DOI = {10.3390/app11052070}
}

[2]
@inproceedings{ge2017detecting,
  title={Detecting Masked Faces in the Wild with LLE-CNNs},
  author={Ge, Shiming and Li, Jia and Ye, Qiting and Luo, Zhao},
  booktitle={Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition},
  pages={2682--2690},
  year={2017}
}

[3]
@inproceedings{yang2016wider,
  Author = {Yang, Shuo and Luo, Ping and Loy, Chen Change and Tang, Xiaoou},
  Booktitle = {IEEE Conference on Computer Vision and Pattern Recognition (CVPR)},
  Title = {WIDER FACE: A Face Detection Benchmark},
  Year = {2016}
}

License

This project is licensed under the MIT License - see the LICENSE.md file for details

About

A challenging, in the wild dataset for experimentation with face masks with 63,072 face images.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published