I was wondering if you guys might be able to give me some advice in regards to making the performance of my code much better.
I have a set of for loops which look to
Using collections.defaultdict, this can be simplified to
d = collections.defaultdict(list) for value in value_list: d[value.key].append(value.val)