fix layers pep8 violations fixes #1583