pep8/pyflake issues, uncomment __main__ and make example function