My name is Darsheel Tripathy and I am a 13 year old student interested in TinyML. We have seen a lot of projects which make use of camera modules like ArduCam or ESP32 cam to make mask detection systems. I had bought a bunch of camera modules but they were very costly and defective. This is why my idea makes use of the microphone on Arduino Nano 33 BLE sense. This makes the system inexpensive and convenient to use and can be used at entry gates.
DatasetsAs you know, each machine learning project requires some data to start with. And I basically needed to make a keyword spotter(It refers to a system that recognizes a particular set of words like 'Hey Siri'). I have used the phrase 'Hello World'. The data has four categories - Noise, unknown, Mask, No Mask. The Noise and unknown datasets have been taken from the edge impulse documentation. Here's the link to download it : https://cdn.edgeimpulse.com/datasets/keywords2.zip
NoMask - Contains audio saying 'Hello World' without the mask on.
Mask - Contains audio saying 'Hello World' with the mask on.
Training the modelIt has 24 mins of data with 6 min approx to each dataset. MFCC processing block was used and classification learning block was used.
Then I trained the model with 100 epochs and 0.005 learning rate. I achieved 92 percent accuracy which was quite good for an audio based project and a decent loss value of 0.5. The confusion matrix stats are also good as the confusion level of Mask and NoMask doesn't exceed 10%
Now, I had to do the most important thing and that is testing the model. I tested it and the results were quite good.
TestingI was wearing the mask during the sample and the results were accurate. You can see that Mask count is 11 and rest of it is noise and uncertain. And this was done live by recording data from microphone and classifying it.
Now this sample was classified as NoMask 5 times as I was wearing no mask. You may say that it has been classified as Mask 4 times which isnt very good. Well, you are correct but you can also see that the amount of data is very less for such a system. And moreover sometimes it gets confused in between Unknown and NoMask categories.
ConclusionThis project was fairly a successful one. I know that more data needs to be added and I will surely do that. This project will be updated soon with the code and video of the model. Suggestions and comments are welcomed !!
Thanks for Reading !!
Comments