Need script to backup Flickr metadata to local JPGs
August 1, 2009 4:20 PM Subscribe
Lazyweb request: I put a lot of effort into my photos on Flickr: selecting them, titling, captioning, adding tags and sometimes geotagging. I need a script that will use Flickr's APIs to retrieve this information from Flickr, and write it into the IPTC headers of my local JPGs.
My reasons for wanting this are twofold:
1) Backing up this valuable information (if I could no longer use Flickr)
2) Making all this information available in Picasa (which uses some of the IPTC fields)
I'm not a programmer. Here's an English description of the script's operation:
For every photo on Flickr, find matching local file [1].
For each local match, write into IPTC header:
Flickr Title --> IPTC Caption
Flickr Description --> IPTC Caption (after Title and linebreak) [2]
Flickr URL --> IPTC Source [3]
Flickr Tags --> IPTC Keywords [4]
Also add the following special Keywords (should be self-explanatory):
Flickr (all matched photos)
Flickr_Faved
Flickr_HasDescription
Flickr_HasComments
Flickr_HasNotes
Flickr_Geotagged [5]
Flickr_InSet
Flickr_InSet_{setname}
Flickr_InCollection
Flickr_InCollection_{collectionname}
Flickr_InGroup
Flickr_InGroup_{groupname}
Flickr_Privacy_{privacysetting}
The script needs to replace all existing IPTC data with the Flickr data. Needless to say, the JPGs should not be recompressed. Ignore videos (don't know where one would store metadata in AVIs).
[1] This may be tricky. One way to find match them could be by "taken on" value (in flickr.photos.getinfo) For an idea of scale, I have 5,700 photos on Flickr, and 33,000 locally.
[2] I wish there was another field I could use, but this looks like the only one that'll do. HTML will look rather ugly. I might be persuaded not to include this, especially since Picasa doesn't display captions very nicely.
[3] Use the Flickr canonical short url.
[4] Including machine tags. Ensure they are correctly delimited (I think they're separated by commas in the IPTC header, and phrases don't need to be quoted)
[5] Picasa also has geotagging, and I've not checked where it stores this data. Would be nice to save Flickr's geodata in the same format Picasa uses. Optional though.
I know my chances of getting what I ask are slim, but I'm hoping that some people out there want the same thing, including someone who can actually build it. Or maybe something like this already exists, and all my googling couldn't find it.
posted by snarfois to computers & internet (6 answers total) 9 users marked this as a favorite
posted by wongcorgi at 4:41 PM on August 1, 2009 [1 favorite]