How To: Multi-size Export from Lightroom

After doing a shoot recently with the creators of Dates Like This, I was able to take my first good swing through Adobe Lightroom 4. The shoot was for some of their promotional material, and I’m pretty happy with the results. Although I did have to wait until after their announcement of the second season on Valentines day (happy birthday to me!) before I could share this work. Which was a new experience for me, as I am more accustomed to not WANTING to talk about stuff I am allowed to say. But that is a post for another time. Today I want to share a little bit of my experience in Lightroom 4.

I have been an avid user of Apple’s Aperture for some time. And the experience has been quite enjoyable for all of Aperture’s strengths as an all-in-one solution for asset management, RAW image processing, and basic photo editing. At least at the enthusiast level, Aperture is great. But if you have aspirations that involve more in depth editing or compositing then you will need a sophisticated pixel editor like Photoshop. And if you need to first batch process files and then interface with Photoshop, there is no better place to be than Lightroom.

Lightroom’s interface is a bit friendlier than most of Adobe’s CS products, and its handling of batch processing is very clever. I had played around in Lightroom before, but I took this opportunity to jump in with both feet and run my entire workflow for this project through Lightroom. And everything was great. Until I had to export… First of all I find Adobe’s preset editor to be wildly unintuitive. Secondly I was putting out images for use on the web, in slideshow videos, for a favicon, as banner images, in blog posts, possibly in print, you name it, and yet Lightroom was content to output only one size at a time (though I’m glad to put Aperture’s crapshoot of a watermarking tool behind me). So here I was navigating through export dialogue after export dialogue to get the numerous sizes I needed. 

Then I stumbled upon a post from one photography blogger at PhotoWalkthrough.com. He highlights this very problem and proposes a solution via the wee export setting called Post-Processing where Lightroom allows you hand off the exported files directly to another application. This post goes on to offer a bit of Applescript code (provided by John Day of johneday.com) that one might use to create an application which resizes and renames image files as they are exported from Lightroom. I promptly leaped for joy, created a new Applescript Editor document and landed flat on my butt. I couldn’t get this darn script to work for me. So it was clear there was an easier way to do this.

Automator to the rescue! If you work on a Mac and you deal with files in large quantities, you NEED to explore Automator. It will save you hours of your workday, help you sleep at night, make you taller, better looking, reduce your stress, make you less forgetful, make you seem really smart, and regrow your thinning hair. And since this is something I am under no direction to keep quiet, I’m gonna share with you this Automator App I built to augment Lightroom’s export dialogue. 

First Things First:

This is the primary sequence of actions I’ve used to create new versions of the images that are coming out of Lightroom. 

  1. First of all the items get duplicated (in step 1), when OS X duplicates these items in the same folder it will automatically append “copy” to the file name, making it read “imagname copy” so that has to be corrected. 
  2. You’ll notice that the first thing I do to correct this is to add my own descriptor to the filename in step 2, in this case “2k” for the 2000px version (you may wish to choose a different descriptor or different sizes, but this made sense to me). Now the filename will look like “2kimagename copy”
  3. We add the new descriptor first because OSX will not allow the appended ” copy” to be removed while the new file remains in the same folder without replacing the old file of the same name, or adding an additional index number to the end of the file name. So, now that the file has a unique name we can remove the ” copy” from the file name in step 3. You can see that there is no “remove text” action so instead I have used Replace, and dictated that we replace with a blank field, this action behaves just like Find and Replace in a word processing application. Resulting in a nice, clean, meaningful and unconfused name “2kimagename”
  4. Having now prepared the filename we move on to the purpose of all this, creating a version of this image in a smaller size. In step 4 I’ve used the Scale Images action and chose to scale to the specified size of 2000px. This will make the image fit within 2000px x 2000px or 2000 on the longest side.  You might be done here, if you only need one more image size after your export, but we can go further:
  5. At this point, we’ve created a second copy of the file coming out of lightroom that has been resized to 2000px and been named to make clear its differentiation from the original, fullsize version. But we might want another additional size, so step 5 duplicates the file or files that resulted from steps 1-4. And we will move through basically the same process once more.

Now we will go through the next rename, resize process.

First Steps in Automator
First Steps in Automator

Next Steps:

Here, we receive the duplications from the end of the first set of instructions. Their filenames will look like “2kimagename copy” so we need to fix this to be meaningful for the next size we create and then clean it up by removing the ” copy” addendum. 

  1. Note that the first step here after the duplication is Replace Text not Add Text as it was in the first process. This is because the automator script will move in a liear fashion when it comes to the handling of files. In other words we are picking up here, right where we left off in the first section, and not moving back to the orginal files that were passed in from Lightroom (its possible to do this with an applescript injection, but more on this later). Now after this find and replace our filename stands as “1kimagename copy” and its time to clean it up.
  2. Again we Replace Text, finding ” copy” and replacing with a blank field. Leaves the filename as “1kimagename” which is exactly where we want it, but the file is still 2000px on its longest side.
  3. Step 3 takes this currently mis-named 2000px image and scales it to 1000px in the same way we did the resize earlier. Note that the Scale Images action will scale up as well as down. I mentioned 2 steps ago that  with an Applescript injection you could revert to the original file for each resize/rename process. While this would protect you from degrading image quality through multiple resizings, it is not neccessary to our puroses here. As long as you keep your steps moving toward smaller and smaller pixel counts you will not see a degredation of the image.

This script ends here at 1000px, but you could keep repeating this duplicate-rename-scale process for ever smaller versions according to your needs.

Here's where Automator really starts making your life a lot better.
Here’s where Automator really starts making your life a lot better.

Make your Application:

When you’re finished creating your script make sure that you choose the file format “Application” so that it will be usable from Lightroom’s export preset under Post-processing.

Automator save dialogue making you look smart.
Automator save dialogue making you look smart.

Set up Lightroom Export:

Here, you can select the desired application wich you created in Automator to handle your Lightroom output. And once you’ve created an export preset which leverages this, it will effectively give you an export of one or many images simultaneously to multiple image sizes. You may notice that I’ve got this preset outputting first fullsize versions of the images and then my Automator App will take care of the multiple resizing.

Enjoy the fruits of your labor.
Enjoy the fruits of your labor.

So, this post was a little unusual for me but I ran across this and knew there are lots of folks out there who need this functionality and may be having trouble doing it. I hope its of use to you. After all I wouldn’t want to be all philosophy and no tangibles. Please comment here if you have questions or suggestions. 

Daunting to Doable

I spent some time recently selecting photos I’d taken over the last year to make prints from. Photography is not my business right now and I don’t have plans to make it my profession. So why spend several days analyzing and selecting and hemming and hawing over what really amounts to updating a portfolio? One of my favorite photography bloggers, and all around internet personalities, Derrick Story of thedigitalstory.com has done several podcasts, posts and even a whole lynda.com title on the subject. And he’s gotten me excited about my own archiving process. I’m so excited in fact that not only am I convinced of its intrinsic value but I’m writing this post to share my experience.I believe that this archiving or portfolio process has two primary areas of value:

  • Creative Growth
  • Security and Longevity

Creative Growth
Creating and evaluating a portfolio of my work has been an interesting exercise for its own sake already. Even though I do not and will not consider myself a professional (at least for quite some time), photography can be an expensive hobby for an enthusiast. So I’ve decided to try selling my work as fine art prints this year. And seeing which of my best shots looks good in print was, I figured a good place to start that project. And this leads me to the way time can add a certain, fresh (and perhaps more realistically critical) perspective. From time to time, looking back and examining your work, looking at the phases of your exploration whether in-camera or editing exploration, can be instructive. It can remind you of techniques you’ve enjoyed in the past but have wandered away from. I went out last week to shoot some HDRI scenes after looking over a group of pictures from last year which I really liked. Using a decent photo management application for this (like Adobe Lightroom or Bridge, or Apple’s Aperture) can make this experience a lot better and more interesting. Not only do programs like these make it easier to find your work and organize the best of the best, but they offer you a clearer vision of your past self. By using things like star ratings and the unique abilities of Lightroom and Aperture to view originals and edited versions instantly, you can start to get a feel for changes in taste as well as improvements in technique. I love star ratings and I use them every time I ingest a set of pictures. They are helpful and make it easier to cull down and view only the pictures worth working on further. But then when you come back around to archive they make a huge difference. I sat down to do this and opened Aperture to discover 8,374 photos linked to this library… daunting. But by filtering to view only images star rated 4+ I had a list of just over 100… doable. Then then as that lovely extended perspective kicks in some 4’s are promoted while 5’s are demoted and I come in at 62 shots I really like a lot. I start to get a feel for my style, which is more color-driven than I thought it was. Then its time to start deciding what to get printed, which black and white images might make nice fine art cards or which pictures I’d like to hand up around the house. Finally I’ve come down to about 21 or 22 shots and it’s time to order prints. The big news is that after doing this I felt more confident about the possibility of selling one or two of these this year.

Security and Longevity
While I do my best to maintain a fairly robust scheme securing my data against eventual hardware failures, nothing is as good in terms of longevity as a print. Kept in dark storage, (like an album or portfolio) archival inkjet prints on quality paper are often rated to last more than 100 years! And that longevity requires no upkeep, unlike digital files where drives must be spun up from time to time and optical disks can fade and start losing bits. Knowing that these expensive and sometimes mystifying pieces of equipment are prone to failure and contain many hundreds of hours of my work on fleeting and irreplaceable moments is definitely scary. The prospect of regularly checking an ever growing library of many thousands of files for degradation is daunting. Prints on the other hand do not suffer such complications (doable). Even in cases where the bits of individual files are perfectly preserved there can, years later, be problems of antiquated formats being unsupported by new software. On the other hand, so long as there is light your prints are still compatible. I haven’t invested in a portfolio book just yet, but a good one will extend the life of prints and of course has the added benefit of being a simple, portable way to show your best work.

As I said before, I’m not a professional. But photography has been a passion of mine and it feels good to know that one day my eventual grandchildren (or even great grandchildren) may get the chance to put there hands on something I invested my heart and my attention into making. When I get around to assembling a portfolio book I will probably do another post on this topic showing my final product. I will also be creating a gallery page for this site. Until then, remember its sometimes good to look back before moving forward.