Ask Your Question
1

why it cannot detect some profile face?

asked 2018-12-04 19:35:15 -0600

SunHwan gravatar image

updated 2020-11-14 05:44:44 -0600

Hi all I was trying to detect profile face. I found it's possible to detect it using haarcascade_profileface.xml. But I confirmed it could only detect a left-side face. How can It detect the other side face?

Here is a example. The size of image is 960x703.


face_cascade = cv2.CascadeClassifier('haarcascade_profileface.xml')

faces = face_cascade.detectMultiScale(gray, 1.3, 5)

image description

image description

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted
1

answered 2018-12-04 20:03:20 -0600

berak gravatar image

the profile facecascade was indeed trained only on left side faces.

to detect right side faces, you haveto flip the image, and do it again:

flipped = cv2.flip(gray, 1)
faces = face_cascade.detectMultiScale(flipped, 1.3, 5)
edit flag offensive delete link more

Comments

Okay. Thank you to answer :)

SunHwan gravatar imageSunHwan ( 2018-12-04 20:20:24 -0600 )edit

Question Tools

1 follower

Stats

Asked: 2018-12-04 19:35:15 -0600

Seen: 3,282 times

Last updated: Dec 04 '18