2 Results

Scripts

Top TED Talks

TED

You can find my updated Top TED Talks document here (updated 2012-03-22)

If you don’t know about TED talks, you’re missing out. TED is a conference held in California annually, where speakers from various fields such as psychology, music, management, entertainment and developing technologies are given up to 18 minutes to share ideas and knowledge with the audience. Tickets to the conference are pricey, but TED put every talk up on their website for anyone to view free.

Currently there are 1132 TED talks, and I found it a little hard to figure out which ones are ‘must-watch’, so taking a look at Quora I stumbled upon a Ruby script from analytics gurus PostRank that would generate a document with various ranked statistics on them. I updated the script slightly to more efficiently use API calls, and set about updating their out of date document. The new document contains 500+ new talks, and updated statistics on the ones that were already present.

One important thing to note is that my script doesn’t utilise whatever method PostRank seem to be using to weight the sources (which they did not include in the script or their post), so the ‘engagement’ numbers won’t be as high, but the general idea is there.

You can find my updated Top TED Talks document here (updated 2012-03-22)

If you want to generate your own document, you first need to obtain an API key from PostRank which gets you 1000 calls a month (the script uses about 20 at the moment, each time it’s run), and then run the script. If you’re technically inclined enough to want to do this, you’ll also need to ‘gem install’ some of the Ruby Gems required for the script, but that’s beyond the scope of this post. Hope you like it!

 

NASA / NGEO Picture of the Day scripts

After this post on Reddit, I discovered a new love; Picture of the Days. As asked in the post, I set about creating a script that could be run (manually, on start-up or with a crontab) and automatically download, save and set a Picture of the Day from NASA’s APOD and National Geographic.

Alaska King Crab Moon and Venus Over Switzerland

 

Without further ado:

Update (2011-03-23): Refactored National Geographic script. Added options to set directories for both images and description to be saved to.

Update (2011-02-13): NASA script now has the option of saving the description to file. I added this so I could add it to my Conky display. Example:

Conky using description.txt from the updated APOD script

You will need a system capable of running bash scripts (ie. a Unix system, no Windows unfortunately).

The scripts will save images to ~/Pictures/[date].jpg. If an image already exists with that name, the script will check the website to see if it has been updated on site, and get the new image, save it, and set it as wallpaper automatically.

I have set the script up to run on startup, and also in crontab every 3 hours to keep the picture updated throughout the day.

The only issue I have found so far, is the other day NASA posted a Youtube clip instead of an image. Hopefully this isn’t frequent enough to cause a problem.

Special thanks to nicocarbone, darkcompanion and smurnjiff.

Any comments or suggestions, feel free to let me know!