Hi, I figured out that I could get matplotlib 0.87.6 for python 2.4 and have downloaded this and installed it. It seems to work, except when I try to do this ActivePython 2.4.3 Build 11 (ActiveState Software Inc.) based on Python 2.4.3 (#1, Apr 3 2006, 18:07:18) [GCC 3.3 20030304 (Apple Computer, Inc. build 1666)] on darwin Type "help", "copyright", "credits" or "license" for more information. >>> import numpy >>> import pylab RuntimeError: module compiled against version 1000002 of C-API but this version of numpy is 1000000 The import of the numpy version of the nxutils module, _nsnxutils, failed. This is is either because numpy was unavailable when matplotlib was compiled, because a dependency of _nsnxutils could not be satisfied, or because the build flag for this module was turned off in setup.py. If it appears that _nsnxutils was not built, make sure you have a working copy of numpy and then re-install matplotlib. Otherwise, the following traceback gives more details: Traceback (most recent call last): File "<stdin>", line 1, in ? File "/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-packages/pylab.py", line 1, in ? from matplotlib.pylab import * File "/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-packages/matplotlib/pylab.py", line 199, in ? import mlab #so I can override hist, psd, etc... File "/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-packages/matplotlib/mlab.py", line 64, in ? import nxutils File "/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-packages/matplotlib/nxutils.py", line 17, in ? from matplotlib._ns_nxutils import * ImportError: numpy.core.multiarray failed to import >>> import numpy.core >>> import numpy.core.multiarray >>> import matplotlib >>> My problem is that I have a code: from math import * import numpy from matplotlib import * filename = options.infname + '_ch1' im24 = pyImage.Image() im24.Open(filename) print filename,im24.avg, im24.max figim = figure.figure(figsize=(5,5)) figim._resize = False axsrc24 = figim.add_subplot(111, xlim=(0,200), ylim=(0,200), autoscale_on=False) axsrc24.set_title('Click to zoom') im24.Display(axsrc24) If I use from pylab import * the figim = figure line works, but since import pylab fails the script fails. If I use from matplotlib import * I get this error: [EMAIL PROTECTED] Spitzer/Objects -> redspit -i Albiorix1v2 -a 8 -z 16 pixel size = -2.45 2.45 Albiorix1v2_ch1 47.6313694642 50.5503692627 Traceback (most recent call last): File "/Users/tgrav/Work/Astronomy/MyCode/Python/Redspit/redspit.py", line 95, in ? main() File "/Users/tgrav/Work/Astronomy/MyCode/Python/Redspit/redspit.py", line 50, in main figim = figure.figure(figsize=(5,5)) NameError: global name 'figure' is not defined So I am a little confused as to what is going on???? Cheers Tommy http://homepage.mac.com/tgrav/ "Any intelligent fool can make things bigger, more complex, and more violent. It takes a touch of genius -- and a lot of courage -- to move in the opposite direction" -- Albert Einstein |
------------------------------------------------------------------------- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users