Flake8 fixes
These are a large group of changes that make the code base PEP8 compliant. This means more that we can use tox to validate future commits, enforcing high quality contributions. Also, a MUCH more readable source code.
Closes #1001 (closed)
Edited by jesse