This is longer than 79 chars, which is a pep8 violation. I'd suggest you take the list comprehension out of the for loop?