face_recognition icon indicating copy to clipboard operation
face_recognition copied to clipboard

rotate image according to exif #917

Open rafiibrahim8 opened this issue 4 years ago • 1 comments

After recognizing faces on an image sometimes the images rotate sideways because of EXIF. It can be easily solved by rotating the image according to EXIF after loading. PIL already has a method PIL.ImageOps.exif_transpose(image) to do this. Which will apply EXIF transform if required.

What I did: Rotate the image according to EXIF after loading it before doing anything.

rafiibrahim8 avatar Nov 26 '20 13:11 rafiibrahim8

Thx Rafi! I was on the way to solve this differently, but using the build-in method seems the correct way to go.

GuentherMair avatar Oct 21 '23 08:10 GuentherMair