You are here

Backup your public Flickr photo metadata to MongoDB using backupPublicPhotoMetadataByDateAndUser

Submitted by Roland on Mon, 2012-02-27 01:19

If you know how to run MongoDB and ruby on your computer or your server, then backupPublicPhotoMetadataByDateAndUser.rb is a simple Ruby script to backup your Flickr metadata for yours (or anybody else's) Flickr public photos for a given time period. Simple (it doesn't replicate flickr's richness nearly as comprehensively as Aaron's parallel flickr) but effective because then you can with very very simple programming use the MongoDB query language to do useful Flickr queries such as:

1. give me all the photos in gastown

2. give me the square 75x75url of all photos in Vancouver tagged "yellow"

3. give me all the photos geo-tagged in the city of Vancouver taken in 2011 during the morning rush hour (e.g. if you wanted to do Eric Fisher-like  maps)

HOW TO RUN IT:

  1. Start up MongoDB and create some indexes: /Applications/mongodb-osx-x86_64-2.0.2/bin/mongo
    1. > db.photos.ensureIndex({id:1});
      > db.photos.ensureIndex({datetaken:1});
      > db.photos.ensureIndex({dateupload:1});
      > db.photos.ensureIndex({lastupdate:1});
  2. Set Environment variables to point to your MongoDB and your flickr api key and the userid e.g.
    1. export MONGO_PORT=27017
    2. export MONGO_HOST=127.0.0.1
    3. export FLICKR_DB=rtflickr # your flickr database name in Mongo DB
    4. export FLICKR_USER=yourfunnyFlickruserIdendinging@01
    5. create a flickr.conf file like this:
      1. Roland-Tanglaos-MacBook-Pro-2:mongoflickrbackup rolandtanglao$ cat flickr.conf
        api_key = a3b9eeatbeefdecafbad
  3. specify time and date to backup e.g. to backup your 2009 public photos:
    1. ./backupPublicPhotoMetadataByDateAndUser.rb 2009 1 1 2009 12 31  >backup.2009.stdout.txt 2>backup.2009.stderr.txt

Comments

Herndon maids Really great post, Thank you for sharing This knowledge.Excellently written article, if only all bloggers offered the same level of content as you, the internet would be a much better place. Please keep it up!

Great post full of useful tips! My site is fairly new and I am also having a hard time getting my readers to leave comments. Analytics shows they are coming to the site but I have a feeling “nobody wants to be first”. coco palms

You contain a physical road of book also appear to own so plenty craze about this publication. You retain put it in a road that everyone can conceive. Chelsea Reed

I acknowledged what you have done here. I am continually looking for enlightening data like this. Much obliged concerning imparting to us.Steven

<p>I just came across your blog and reading your beautiful words. I thought I would leave my first comment but I don&rsquo;t know what to say except that I have enjoyed reading.</p><table border="0" cellpadding="0" cellspacing="0" width="562"><colgroup><col width="562" /></colgroup><tbody><tr height="20"><td height="20" style="height:15.0pt;width:422pt" width="562">&lt;a href=&quot;https://www.rebelmouse.com/vitamincserum/&quot;&gt;vitamin c for face&lt;/a&gt;</td></tr></tbody></table><p>&nbsp;</p>

Nice to be visiting your blog again, it has been months for me. Well this article that i've been waited for so long. I need this article to complete my assignment in the college, and it has same topic with your article. Thanks, great share. san diego seo services

Well the first I noticed in Google Analytics. I see it almost died. I'm thinking of finally moving to a cloud news reader, I've been using NewsFire for years and before that I used Opera for my RSS feeds. NewsFire uses so much damn memory and it isn't being actively developed. I do a lot of reading of news on my iPhone using Pulse S & B Fence Company

Well the first I noticed in Google Analytics. I see it almost died. I'm thinking of finally moving to a cloud news reader, I've been using NewsFire for years and before that I used Opera for my RSS feeds. NewsFire uses so much damn memory and it isn't being actively developed. I do a lot of reading of news on my iPhone using Pulse schwarzkopf palette

I wanted to thank you for this great read!! I definitely enjoyed every little bit of it . I have you bookmarked to check out new stuff on your post.. book a room medina

Is this a paid theme or did you modify it yourself? Anyway keep up the nice quality writing, it is rare to see a great blog like this one nowadays. rosleyn

The discussion generated dozens of Facebook comments from community members with ideas, but the city declined to pursue the matter because of environmental concerns.cavedog fitness

This is a nice post in an interesting line of content.Thanks for sharing this article, great way of bring this topic to discussion. great site

Please let me know if you’re looking for a author for your site. You have some really great posts and I think I would be a good asset. If you ever want to take some of the load off, I’d really like to write some material for your blog in exchange for a link back to mine. Please shoot me an email if interestedhttps://www.rebelmouse.com/johnbarban/

Lots of companies that are well establish may not provide as good of
service as you may expect. There are many different steps that one can take, in order
to keep their ferret smelling good; all it takes is a little bit
of time and perseverance. It comes in two forms: juvenile (usually found in ferrets under
the age of 14 months) and classic, which is usually found in middle aged
and older ferrets.

I gathered useful information on this point as I am working on a business project. Thank you posting relative information and its now becoming easier to complete this assignment author

This is very educational content and written well for a change. It's nice to see that some people still understand how to write a quality post

Really great post, Thank you for sharing This knowledge.Excellently written article, if only all bloggers offered the same level of content as you, the internet would be a much better place. Please keep it up! Video Game Trading

realtor.com/local/Iona-Preparatory-Private-School_New-Rochelle_Westchester-County_NY/education I would like to thank you for the efforts you have made in writing this article. I am hoping the same best work from you in the future as well. In fact your creative writing abilities has inspired me to start my own BlogEngine blog now. Really the blogging is spreading its wings rapidly. Your write up is a fine example of it.

With the explosive growth of Wi-Fi continuing in the enterprise space, the need to secure and monitor wireless networks is more important than ever. This is creating new cost pressures and focus on compliance requirements, for example with PCI and HIPAA. Deployment costs, including physical installation and cabling for a wireless intrusion detection and prevention system (WIPS/WIDS) can be greater than the acquisition costs for traditional sensor technology or AP-based WIPS. kerium

Pages

Add new comment