David Findlay

a man, a plan, a cake: nirvana

Getting your pictures from Flickr into iPhoto

Last month I posted about backing up metadata for your Flickr photos using a simple little Python script. That script gives you an XML file for each photo with all that photo's metadata stored inside it for ready access. If you're a recent switcher to OSX, you might want to take advantage of that data to get your photos from Flickr into iPhoto.

Once you have iPhoto and Flick in sync, you can import new photos from your camera into iPhoto and then export to iPhoto using FlickrExport and they will stay in sync. Of course you may have no interest in getting your photos from Flickr to iPhoto, in which case feel free to stop reading. In my case, while I had the photos around, they were in multiple folders on my hard drive and didn't have any tags associated with them. On Flickr I had them tagged, dates corrected, and so on. Rather than recreate that process I decided it would be easiest to take what I'd done in Flickr and push it to iPhoto.

The linked AppleScripts below were mostly what I used to accomplish this process, again in conjunction with the XML files from the script mentioned in Backing up your Flickr photo info. Now some caveats: I had never used AppleScript before when I wrote these, and my copy of AppleScript: The Definitive Guide was still in the mail. If you know AppleScript you will be aware of how quite unlike most other scripting languages it is. The scripts below are undoubtedly not in best AppleScript style, and I didn't spend any time modularizing them, so you'll see common functions in each for XML parsing and so forth.

So with that said, take them for what they are and do with them what you please. Hopefully between them they'll give you enough to make a start on whatever iPhoto library-munging project you've decided to take on.

iPhoto 7 first impressions

My iLife '08 family pack arrived yesterday and I eagerly installed it on the G4 PowerMac (yes, it refuses to install the new iMovie on a G4, but that's for another day) and on my MacBook. I downloaded the iPhoto 7.0.1 update and started it up. It said it need to update my library and the process took hardly any time at all, in spite of being on the G4 and there being about 5000 pictures in the library.

When the main window appeared I was presented with a surprisingly small number of the much-touted Events. On closer inspection it seems that Events, at least from an upgrade, are pretty-much synonymous with the old Rolls, albeit given equal billing with Photos in the sidebar and a very pretty facelift. This was a little disappointing. I had understood that events were created based on their date taken, not the date they were imported into iPhoto (who cares about that date). I often batch import several days worth of pictures. Of course iPhoto will let you split an event, but the whole point of Steve's pitch was that you didn't have to do it manually. What made this more disappointing was the 3000 or so pictures I imported when I switched; these all showed up as 1 event spanning multiple years.

Since I didn't feel like splitting that mega-event up, I decided to create events from the albums I had created. This proved to be a little clumsy, but perhaps I just didn't find the simplest way to do it.

For each album, I:
  1. Selected the album in the side bar.
  2. Selected all the photos.
  3. Picked Create Event... from the Events menu.
  4. Accepted the warning about photos only being in one event at a time. (which can silence after the first time)

This created an event. I could tell because the count after "Events" in the sidebar went up by one, but it left me with my pictures selected back in the album. I then had to:
  1. Click Events in the sidebar.
  2. Find the new Event (which fortunately was selected).
  3. Edit the title of the new event and pick my key photo.

Moving forward this shouldn't be so tedious, but had iPhoto created events based on the date each photo was shot, I think it wouldn't have giving me a better starting point.

I use the excellent FlickrExporter to public my photos to my Flickr account (Fraser has updated it to use the new official Apple API in iPhoto 7 by the way). One of the many nice things about FlickrExporter is that it turns iPhoto keywords into Flickr tags. However, getting keywords added to photos in iPhoto 6 was a pretty tortuous experience; or it was until I discovered Ken Ferry's Keyword Assistant. With Keyword Assitant I just wouldn't have been able to contemplate keeping my tagging up-to-date. A few days ago, Ken posted on the Keyword Assistant blog:

I'm happy to report that I won't be updating Keyword Assistant for iLife '08 for one reason: The native keyword interface in iPhoto 7 is good enough that Keyword Assistant is unnecessary! You can enter keywords by typing, the keywords autocomplete, use of a non-existent keyword will implicitly create it, and you can assign keywords for an entire album without using the mouse.

And boy was he right. If you enable viewing of keywords in iPhoto 7, you can simply click in the space where the keywords are (or would be if there aren't any yet) and start typing. And I mean right under the photo in the main Photos view, not in the information popup in the sidebar. The keywords tab-complete, and you can use comma to accept one and start adding another, just like Mail does with contacts when you're addressing an email. Same goes for the photo's title: click on it and start typing.

Tab takes you to the next photo's title; tab again and you're at that photo's keywords. You can create new keywords inline and it doesn't say boo. Very very nice.

iPhoto Library a package
The iPhoto Library folder under /Users/username/Photos is now a package (so you have to right- or Ctrl-click on it and select Show Package Contents to get to your photos. iPhoto never really did like you poking about under its hood; I guess Apple want to make that even clearer with version 7.

Web Gallery
Now that .Mac accounts have been bumped to a health 10GB, I decided to give the new Web Gallery feature a go. Creating a Web Gallery album was straightforward and they look nice in the browser. I did noticed that in Firefox, the slideshow option's fade doesn't work: each picture flashes off and on alarmingly during the transition to the next one. In Safari 3 Beta 3.0.3 when the new picture fades it, the old pictures shows once then disappears. I didn't noticed either of these quirks with Safari 2.
Minor browser quirks aside, the new Web Gallery looks great. The drag-to-see-the-pictures-inside feature of events in iPhoto also works in the Web Gallery, and the thumbnail size slider too is straight out of iPhoto. Apple did a nice job here. I expect I will stick to using Flickr, but for others who don't feel the need to post every single photo of their kid for others to 'enjoy', Web Gallery looks like it will be just the ticket.

.Mac Storage Increase

Apple has made good on its promise to bump .Mac accounts from 1GB to 10GB:

Maybe I will be able to do something with it other than syncing my Keychains and Address Book now. I use Flickr for sharing my photographs, but the new iLife '08 Web Gallery might be useful for sharing movies (I've never had much luck with YouTube: it always seems to end up mangling my videos too much).