cleanup the crazy dict comprehension