Re: ColorMap file question

From: Mary Haley <haley_at_nyahnyahspammersnyahnyah>
Date: Tue, 22 May 2007 17:14:51 -0600

Hi Jim,

This new colormap *should* be recognized by PyNGL automatically if
you put it in the directory $PYNGLPATH/lib/python2.4/site-packages/
PyNGL/ncarg/colormaps. In fact, you can try a simple test in which
you copy "amwg.rgb" in that directory to "amwg2.rgb" (in the same
directory), and then use "amwg2" in the "wkColorMap" resource
setting, and it should work.

I just tried this test and it worked for both numpy and Numeric.

The directory you listed below, "PyNGL-1.1.0/PyNGL/..." is the
directory from which you install PyNGL from. When you actually run
PyNGL/Python scripts, the software looks in the installed directories
(the one with "site-packages" in its path), and not in this local


On May 22, 2007, at 10:20 AM, James Boyle wrote:

> This one is probably for the developers.
> What is the relation of the color map files found in " .../
> PyNGL-1.1.0/PyNGL/ncarg/colormaps" and the names invoked when I
> call a sequence such as:
> rlist.wkColorMap = "amwg"
> Ngl.set_values(wks,rlist)
> I thought I would be clever and put a new file in this location
> with the color map I wanted but the file name could not be
> recognized by Ngl.
> OK, then just the name is in the code. So I altered the file with
> the name "amwg.rgb", but when I used amwg I got the original colors.
> Evidently, the files are not used at runtime.
> So, when do these names and corresponding colors get built in? If I
> define new map files would they be picked up after the
> install or not?
> It would be neat to be able to build up ones own library of
> colormaps rather then building them in the code. Building in code
> tends to scatter the definitions and having files in a central
> location forces a certain order.
> Thanks for any enlightenment.
> --Jim
> _______________________________________________
> pyngl-talk mailing list

pyngl-talk mailing list
Received on Tue May 22 2007 - 17:14:51 MDT

This archive was generated by hypermail 2.2.0 : Wed May 30 2007 - 16:42:34 MDT