how to calculate euclidean distance between 5 feature points of face (right eye, left eye, right nostril, left nostril, centre of lips)

8 views (last 30 days)
please help me how to calculate distance between five feature points centre of right eye, centre of left eye, right nostril, left nostril, and centre of lips. and with the help of this distance i can estimate the head pose. As I have identified the facial features and I have tracked the movement of these coordinates in x,y-plane. and now i need to find the distance
  1 Comment
Sumit Tandon
Sumit Tandon on 25 Jul 2012
Faria, have you already identified the facial features? You could use the vision.CascadeObjectDetector System object in Computer Vision System Toolbox to identify and locate facial features and then calculate Euclidean distance between their centroids. See http://www.mathworks.com/help/toolbox/vision/ref/vision.cascadeobjectdetectorclass.html

Sign in to comment.

Answers (1)

Image Analyst
Image Analyst on 25 Jul 2012
Edited: Image Analyst on 25 Jul 2012
Since you didn't ask about finding the features, I assume you already have the coordinates of the features you mentioned, so isn't the distance between a pair of them just
distance = sqrt((x2-x1)^2 + (y2-y1)^2);
or am I missing something?
  1 Comment
Image Analyst
Image Analyst on 26 Jul 2012
I know you need to find the distances, and I thought I did help you. Was there something about that distance formula that you didn't understand? Or now you need help finding the average between the left and right nostril locations? Hint: sum and divide by 2.

Sign in to comment.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!