some more refactoring. dict(map(lambda...)) -> dict comprehension