Git Product home page Git Product logo

face-mask-detector-and-counter's Introduction

FaceMaskDetector

Since we know, that already a lot of work has been done in the field of face recognition, we wanted to do something new, therefore we integrated real time mask detection with our project. In this, we capture the images in real time and detect whether they are with or without mask.

Handle Addresses

Image_Mask_Detection.py (L-22) :

[f for f in glob.glob(r'Address Of Image_input/' + name1 + "/**/*", recursive = True) if not os.path.isdir(f)]

Face_Recognition.py (L-37) :

[f for f in glob.glob(r'Address Of NoMaskStd/'+ str(name2)

How to Run

  • Step 0) Download project on your system.
  • Step 1) Install all the dependencies from requirements.txt, using command prompt ' pip install -r requirements.txt '.
  • Step 2) Run detect_Mask_webcam.py file, now you'll see realtime mask recognition with counter.
  • Step 3) Press "p" to capture image, press "m" to trigger the whole process, press "q" to quit.

Note: After pressing "m" whole process is triggered automatically, you don't need to run Image_Mask_Detection.py, and Face_Recognition.py separately.

Output stored in directories:

  • Capture : Mask Detection with Counter.
  • NoMaskStd : Non-masked faces.
  • Known : Non-masked faces recognized through dataset.
  • Unknown : Non-masked faces not present in dataset.

Note : - All the captures in each directories are saved in a different folder everyday. - All the captures of the day are processed in eack run.

DataBase

Attendence.csv : Stores the Counter value of each image, with Date & time.

No_Mask_Std.csv : Stores names of non-masked faces recognized by system, with Date & time.

Loss & Accuracy after training:

  • Loss: 0.0233
  • Accuracy: 0.9928
  • Validation loss: 0.0505
  • Validation accuracy: 0.9868

PreTrained Model :

Note : To run on your self trained model make sure to Edit the code in to read the model in detect_Mask_webcam.py, Image_Mask_Detection.py files.

Dataset :

Feel free to play with the project make your own versions, run on your trained models mix and match !! Have fun and Learn :)

face-mask-detector-and-counter's People

Contributors

rishabh-ghub avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.