Simplicity
Simplicity

Reputation: 48916

Why is my _getexif() returning None?

I have the following Python script:

from PIL import Image
from PIL.ExifTags import TAGS

img = Image.open('/path/1.jpg')
info = img._getexif()
print info

Why is info returned as None, although that I made sure that img has been read?

Thanks.

Upvotes: 5

Views: 5340

Answers (1)

Simplicity
Simplicity

Reputation: 48916

I think the issue was because the image I was reading seemed not to have exif data in the first place, as opposed to the images taken using a mobile phone camera for instance, which the image I was reading apparently hasn't.

Upvotes: 3

Related Questions