RIT-NTNU-Bachelor / face-detection-libface

Face detection with a library. Detects multiple faces and sets 5 landmarks.
https://github.com/ShiqiYu/libfacedetection
MIT License
0 stars 0 forks source link

Try to optimize libface face-tracking #3

Open haugeSander opened 4 months ago

haugeSander commented 4 months ago

The libface face-tracking right now is very slow and choppy. Will try to make it more optimized.

haugeSander commented 4 months ago

Works much better on my computer, way less choppy and higher frames. Still very computationally heavy, will look further into it.

haugeSander commented 4 months ago

Ran it at 2 threads and using AVX512, which is a workload-specific accelerator for certain Intel chips. Did improve somewhat. I believe that CNN facial detection models are to heavy for our needs. Looked into pros and cons of each type of facial recognition and found that CNN is best at accuracy but in no way efficient. Histogram of Oriented Gradients among others might be something to look into. Found in the article below.

CNN model: image

HOG model: image

Image source and an article pinning cnn vs hog: https://medium.com/@entrepreneurbilal10/hog-vs-cnn-unveiling-the-power-of-image-classification-a3d1585d76e8.