Replace string formatting with logging laziness in automata.py
Leverage logging laziness rather than string formatting
Use list comprehension