Cleaning with pylint

Linting with pylint, cleaning up code accordingly.