Overall pythonize, cleanup, variable renaming, assertations. Towards a better world!