import calendar
import time
calendar.timegm(time.strptime('Jul 9, 2009 @ 20:02:58 UTC',
    '%b %d, %Y @ %H:%M:%S UTC'))
How to get the seconds since epoch from the time + date output of gmtime() in Python?