Suggestion: one can more elegantly implement true division for floats (instead of floor division) by using

from __future__ import division

and letting the expressions unaltered: e.g. 

width / height

while for floor division, the '//' operator can be used (but this is anyway seldom needed)
see PEP-0238 (http://legacy.python.org/dev/peps/pep-0238/)