“It is a dual purpose model: Optimized Masked FaceRecognition and Mask Detection for Half-CoveredFaces” is a solution to the problem of recognition of faces wearing masks, especially during the pandemic by COVID-19. This file consists of detailed step by step procedure to run our model as well as we will be stating all pre-requisits which are needed to run the code.
This section consists of frameworks that helped us build the project. They are :
Now we get into setting up our project in your local system. To get a local copy and running, follow these
We start by first installation of Anaconda Navigator. Please Note Do check the box during installation which reads "Add to path". This is important because it helps in easier installation of packages written in the following sections.
Once Anaconda Navigator is installed, set up a new environment and install Spyder 4.1.5.
Once the Anaconda is set up, open up the windows terminal and set the environment to the project enironment. Our Environment name is Project_faceRec so to set the environment we use '''sh activate Project_faceRec '''
This will activate the Environment in which the project will run in. Now installation the following modules from this terminal itself needs to be done in order to collect all dependencies of the code.
Once these dependencies are downloaded from the terminal, dependencies from the Anaconda terminal needs to be installed in our working environment.
This section consists of the the system requirements to execute the code are the specifications of a consumer level PC. We will still be specifying the system of our use as well as the minimum requirements for the same.
This section encloses every detail of how to run the project in your local system once all the above mentioned dependencies are successfully installed in the working environment. Before explaining how to use the source code, we will decribe the files and folders present in this repository.
Now that all files and their usage has been disccussed, we move into important sections of source code that one needs to look into.
Before moving into the source code itself, one needs to set the current working directory where all files are exctracted too. It is recomended to not use deep paths as they tend to creat problems for the compiler to follow. We then open the Face_recog.py file in spider and look into the following changes.
NOTE The Face_recog.py implements the already trained face recognition of masked face. There is no extra source code for testing and training the model separately.
If all paths, dependencies and folders are in their correct places, we now simply run the source code. It would open up the camera of your system (please ensure that there is a camera device connected to the system) and display the desired output i.e. it will recognize one's face and also detect whether one is wearing mask or not.
NOTE The file contains a folder called testing.py. It is the source code just in case one wants to see the results of the model. The testing.py file imports the .npz files created earlier and then performs testing on them.
To add unknown candidate Goto Recog_Train, Then add a folder with images of that person whose identity we want to add on the database. Rename the folder as the new person's name.
This project is craeted in order to provide a solution to the problem of masked face recognition. Any changes or enhance to the project is welcomed to be contributed with proper citation.