Bookmark and Share

General Discussion

Face Angle Detection
1 reply [Last post]
Last seen: 6 years 44 weeks ago
Level 1: Prestidigitator
Joined: 2012-06-18
Points: 1

Hi all, I am currently working on a project that requires a computer to detect whether a face is looking into the camera, or perhaps, even more generally, at what angle relative to the camera a face is pointing.  I am currently tinkering with OpenCV, but I am having a hard time figuring out what specific algorithm would be best suited for such a task.  Do you have any suggestions for such a task?  Any ideas would be greatly appreciated.  There are several well known algorithms for face detection (Viola-Jones in particular), but they all seem to deal with detection alone, not head/face angle.



Jeff Bier
Jeff Bier's picture
Last seen: 15 weeks 1 day ago
EditorLevel 4: Thaumaturgist
Joined: 2011-05-29
Points: 93


Here are a few suggestions that you may find helpful...

Do a web search on the phrase "head pose estimation". Similar Haar classifiers can be used to localize the iris, noise, and mouth. From those anatomical landmarks, the pose of the head, in six degrees of freedom, can be estimated.

OpenCV has classifiers for the eyes and mouth.

The distance between eyes can be used, but only if a reference is known.

A better method may be to use the mouth and the side of the face.

You could use face detection to get region of interest, then find the mouth (this is called a nested classifier in OpenCV) and an edge detector to find the edges of the face. Then compare the mouth location relative to the face edges.

This can all be done using the face detector example in OpenCV.

-Jeff Bier, BDTI (