Add creation of iptc

This commit is contained in:
Antonio J. Delgado 2021-09-06 21:17:30 +03:00
parent b443483ff4
commit e01390fa3f

View file

@ -70,7 +70,7 @@ class image_classifier:
if people:
self._log.debug(f"Found {len(people)} known people in the image.")
self._log.debug(json.dumps(people, indent=2))
iptc_info = IPTCInfo(file)
iptc_info = IPTCInfo(file, force=True)
print(iptc_info['keywords'])
with open(file, 'rb') as image_file:
self.exif_info = exif.Image(image_file)