Re: [Matplotlib-users] how to save pseudo-colorized images as 8-bit PNG files

2010-07-23 Thread j vickroy
Eric Firing wrote: You can post-process the image with something like ImageMagick. Another alternative is to use PIL -- you can grab the matplotlib buffer, make a PIL image out of it, and use PIL to convert to an 8-bit palleted image. For that matter, you could probably bypass MPL, and use nump

Re: [Matplotlib-users] how to save pseudo-colorized images as 8-bit PNG files

2010-07-22 Thread j vickroy
Christopher Barker wrote: Jim Vickroy wrote: The attachment is a simple script that creates a 2D array of unsigned, 8-bit integers and uses matplotlib to save it as a PNG file. Unfortunately, the PNG file is much larger than expected -- apparently because it is True-Color; on my MS Windows

Re: [Matplotlib-users] day-night terminator and/or solar zenith angle code ?

2008-02-13 Thread j vickroy
Christopher Barker wrote: > Jeff Whitaker wrote: >> Jim: I was googling around and found this python code: > > Do be careful way up North or Down south -- some Sunrise/set code > chokes when the sun does not ever rise or set at a given location on a > given day. A quick glance at that code looked

[Matplotlib-users] how to erase items in figures

2008-01-28 Thread j vickroy
Hello users, I wish to repeatedly re-plot labels and contour data on a figure since redrawing the figure is temporally expensive. The attached script (I apologize for its length), hopefully, illustrates a simplified version of what I'm trying to do -- contour temporally-varying data on a map

[Matplotlib-users] IOError: [Errno 2] No such file or directory: 'etopo20data.gz'

2008-01-14 Thread j. vickroy
Hello, I am a first-time user of matplotlib. When trying to run the plotmap.py example, the following traceback is generated: >plotmap.py Traceback (most recent call last): File "C:\Documents and Settings\jim.vickroy\My Documents\Projects\High-latitudes D-region\plotmap.py", line 13, in