norm = matplotlib.colors.Normalize(min(myvalues.values()), max(myvalues.
    values()))
color_producer = matplotlib.cm.ScalarMappable(norm=norm, cmap=cmap)
Python: how to create a choropleth map out of a shapefile of Canada?