Inspiration

We created Check after we saw an inefficiency in the way health precautions were being taken, especially at small businesses. Small businesses often only have one or two people working, meaning a single person at the door checking whether or not everybody's walking in with a mask on can take away from their efficiency as a business. I know from first hand experience that it's not a great system, and I knew there must be a better way.

What it does

Check is software made for small business owners which can be used to monitor people who walk in the door using security cameras. These cameras will detect whether or not the customer is wearing a mask, whether or not the customer is walking in with a large group, and whether or not the store is currently at full capacity. There are other smaller metrics that can be seen on the metrics tab in the GUI.

How we built it

We built Check entirely in python, using both the OpenCV and PySide2 libraries. In order to track the faces and whether or not they were wearing a mask, we created a custom data set to train our machine learning model on. The data set consisted of roughly 450 images that were downloaded from the internet of people both wearing and not wearing masks.

Challenges we ran into

We ran into a bunch of problems while creating the program, ranging from typos to majors problems that took hours to solve. One of the biggest issues we had with the program was getting OpenCV and the Pyside2 libraries to work with each other. Pyside2 has its own camera method, QCamera, and because of that it isn't really meant to work with other camera inputs. But since we needed to use the machine learning model we created in OpenCV, we had to find a way to display it on the Pyside2 GUI. After a couple hours of working at it, we eventually came up with the solution of displaying the camera input as an image, converting it to a QImage, and continually updating the frame on the QImage using a separate thread.

Accomplishments that we're proud of

We're incredibly proud of the functionality we were able to bring to the program, but we're especially proud of the look and feel of the GUI. Having never used Pyside2 before, it was a struggle trying to learn how to design a user interface in such a short period of time. With lots of YouTube tutorials and scrolling through the documentation however, we were able to persevere.

What we learned

We learned how to use the Pyside2 library to design user interfaces from scratch. We also learned how to integrate other libraries with the Pyside2 library, even if it isn't a perfect solution.

What's next for Check Facial Mask Detection

We have big plans for Check, and we think with a little more development it can be an extremely useful tool for small businesses. Firstly we'd like to train the machine learning model for longer than we were able to in a 2 day period. With a larger set of images and more time to train, we could get the accuracy of the program even closer to 100%. We also would've liked to add more features to the program. The more metrics we can provide to small business owners that can help them monitor health precautions, the better. We would've liked to add a metric to track the most popular hours of the day, but unfortunately we ran out of time.

Built With

Share this project:

Updates