(another) rewrite of Corbit, this time in python