Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

detect_face finds faces in the background with a greater confidence #8

Closed
leonvictor opened this issue Oct 11, 2018 · 1 comment
Closed

Comments

@leonvictor
Copy link

leonvictor commented Oct 11, 2018

Hey, first of all, thanks for the great lib. I've been playing around with face detection on the Mc-Master Pain Shoulder dataset to extract bounding boxes and am facing some issues.

In some cases, detect_faces returns multiple bounding boxes. No big deal, except that it gives a greater confidence to the wrongly detected background parts for no apparent reason.

bm049t2aaaff217

marchepas

Any idea why this could be happening ? Or how I can detect mishaps like this one ? If you have any idea how I can fix this let me know, I'd be glad to contribute.

Thanks

@arunponnusamy
Copy link
Owner

Hi @leonvictor , detect_face( ) function actually uses resnet10 backbone with ssd object detection method.

  1. resnet10 is not so deep. It's a lightweight network.(That is why, it is able to run on real time input). So, it is not perfect.
  2. The model being used here is actually trained on data where face is at a distance from the camera. If the face is close to the camera, (ie) if the face is occupying larger part of the image, it will struggle to detect / will return multiple detections. I have experienced this myself.

In this case I would suggest to use the frontal face detector in dlib. If execution time is not an issue, you can try the cnn face detector in dlib. Checkout this blog post to learn more.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants