Pep8/pyflakes and image scale initial fix