check pep8 & pyflakes

pep8 is a style guide for python. and pyflakes is a util which checks python codes for errors.

I updated the code for pep8 and pyflakes outputs.