Coding for Good: Working with the Sunlight Labs APIs

Posted by: barbara | Date: Aug 29, 2012 | Category: Python

If you're looking to get your feet wet when it comes to working with open U.S. government data, I can think of no better place to start than with the Sunlight Laps APIs. They're not kidding when they say that using their APIs is absurdly easy.

Sunlight Labs is ...

Read More

Managing mp3 Files with eyeD3

Posted by: barbara | Date: Oct 12, 2011 | Category: Python

I'm more than a little bit OCD when it comes to managing my music collection. It's huge, and I like to keep the files named with a certain pattern so that when I look at the archive I can see, at a glance, what I have without having to open ...

Read More

Quick and Dirty Lat/Lng Values from the Google Geocoding API

Posted by: barbara | Date: Oct 11, 2011 | Category: Python

This past week, I had to assign lat/long values to a large batch of addresses we had sitting around in our database.

To get those values, I posted to the Google Geocoding API and parsed the resulting XML.

This script isn't particularly polished - I didn't spend much time ...

Read More

Image resizing on file uploads. Doing it the easy way.

Posted by: barbara | Date: Jan 13, 2010 | Category: Django Python

Let me start with this proviso: Math is not my strong subject (okay, just stop right there with the Barbie jokes). I'll do just about anything to avoid writing complex equations. And most of the time, I don't have to. Most of the time, I can find alternative solutions, dependent ...

Read More

cElementTree ftw!

Posted by: barbara | Date: Jan 07, 2010 | Category: Python

My mission was simple - to crawl all of our artist databases, extract names and email addresses from a couple of different tables, and spin out some custom XML.

The tables - one for complete user profiles and another for users who have signed up to receive emails only - ...

Read More