I thought this might be helpful for people who want to download flickr images using api and can save them some time:
- Get an authentication key from flickr: http://www.flickr.com/services/api/misc.api_keys.html
- Install flickrapi: http://pypi.python.org/pypi/flickrapi
- The easiest way to do this is using pip:
- sudo port install py32-pip(mac only, sudo apt-get install pip for linux?)
- pip-3.2 install flickrapi ( depending on your pip version change the command.
- Search query to retrieve photos of
- Number of photos
- Output directory to save to ( The sub-directory structure is similar to flickr's internal directory structure, You can modify the FlickrPhoto class to modify this behavior).
I copied/modified this code from a friend who in turn copied/modified it from an existing api tutorial. You do not have to cite either of us! :-)
NOTE: THIS CODE WILL NOT WORK UNTIL YOU FILL THE TWO KEYS INSIDE THE CODE. (LINE 47 and 48)