removes pyc and unused imports