On Tue, Jun 1, 2010 at 2:22 PM, rugspin <[email protected]> wrote: > That's doing it, thought there might be an internal way within matplotlib, > but I could figure one.
If you need more hard-core way of doing this, a = np.arange(16384).reshape(128, 128) from matplotlib.colors import Normalize import matplotlib.cm as cm norm = Normalize(vmin=0, vmax=16383) cmap = cm.summer A = (cmap(norm(a))*255).astype(np.uint8) import Image pilim = Image.fromarray(A, "RGBA") ------------------------------------------------------------------------------ _______________________________________________ Matplotlib-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/matplotlib-users
