offsets = 10 * (np.random.random((numverts, numpoly, 2)) - 0.5)
verts = centers + offsets
verts = np.swapaxes(verts, 0, 1)
z = np.random.random(numpoly) * 500
fig, ax = plt.subplots()
coll = PolyCollection(verts, array=z, cmap=mpl.cm.jet, edgecolors='none')
ax.add_collection(coll)
ax.autoscale_view()
fig.colorbar(coll, ax=ax)
plt.show()
Draw polygons more efficiently with matplotlib