Code cleanup, pep8, pylint