s/filter/filter_dict/

Rename variable to not confuse with python built-in.