This should make it possible to call this script as a function without starting up a new Python interpreter.