Skip to main content

Fork of IPTCInfo3, a Python module for extracting IPTC metadata from images.

Project description

Build Status

Like IPTCInfo but finally compatible for Python 3

Ported from Josh Carter’s Perl IPTCInfo-1.9.pm by Tamas Gulacsi. This fork is maintained by Sanyam Khurana.

Ever wish you add information to your photos like a caption, the place you took it, the date, and perhaps even keywords and categories? You already can. The International Press Telecommunications Council (IPTC) defines a format for exchanging meta-information in news content, and that includes photographs. You can embed all kinds of information in your images. The trick is putting it to use.

That’s where this IPTCInfo Python module comes into play. You can embed information using many programs, including Adobe Photoshop, and IPTCInfo will let your web server – and other automated server programs – pull it back out. You can use the information directly in Python programs, export it to XML, or even export SQL statements ready to be fed into a database.

Usage

from iptcinfo3 import IPTCInfo

Create new info object info = IPTCInfo('doge.jpg')

Print list of keywords, supplemental categories, contacts print(info['keywords']) print(info['supplementalCategories']) print(info['contacts'])

Get specific attributes… caption = info['caption/abstract']

Create object for file that may not have IPTC data info = IPTCInfo('such_iptc.jpg', force=True)

Add/change an attribute info['caption/abstract'] = 'Witty caption here' info['supplemental category'] = ['portrait']

Lists for keywords, so you can just append! info['keywords']).append('cool')

Save new info to file info.save() info.save_as('very_meta.jpg')

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

iptcinfo3plus-2.1.5.tar.gz (13.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

IPTCInfo3Plus-2.1.5-py3-none-any.whl (12.4 kB view details)

Uploaded Python 3

File details

Details for the file iptcinfo3plus-2.1.5.tar.gz.

File metadata

  • Download URL: iptcinfo3plus-2.1.5.tar.gz
  • Upload date:
  • Size: 13.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.0

File hashes

Hashes for iptcinfo3plus-2.1.5.tar.gz
Algorithm Hash digest
SHA256 fdac5d61aec6258530748f466b9468ceb24342113647e7000314634ec582d10d
MD5 71b2bd75710f53c303f4a0f06e2a4ca4
BLAKE2b-256 6234e1f7e0e06ffe51df88b2af42f205c4072a6ed71a4ad033cc6f033b4ecb38

See more details on using hashes here.

File details

Details for the file IPTCInfo3Plus-2.1.5-py3-none-any.whl.

File metadata

  • Download URL: IPTCInfo3Plus-2.1.5-py3-none-any.whl
  • Upload date:
  • Size: 12.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.0

File hashes

Hashes for IPTCInfo3Plus-2.1.5-py3-none-any.whl
Algorithm Hash digest
SHA256 72a40b49af6631fe275e1b1651a76f63a5c74eebfb4b99cecd208c4e18464c8d
MD5 dc6553f54d8676501522e765fc8a0d91
BLAKE2b-256 a9194bf53d8f64680152689988ab5599d84f404ea9796b996cd35581ab080a8c

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page