Dictionary Speed Up

Determined that most of the slowness comes from iterating over every
pixel. also improved adding to the dictionary to be roughly 1000 times
faster.