[wxPython-users] conflict wxPython 2.6.3.3 and numpy 1.0b1 for wx.lib.plot?

Christopher Barker Chris.Barker at noaa.gov
Mon Aug 7 10:29:03 PDT 2006


Peter Vandersteegen wrote:
> I run python 2.3, numpy 1.0b1 and wxPython 2.6.3.3.
> wx.lib.plot uses _Numeric.Float64, numpy 1.0b1 does not define Float64!

the latest numpy version no longer puts Numeric-compatible names in the 
default namespace:

http://www.scipy.org/ReleaseNotes/NumPy_1.0

> This problem is solved by removing "import numpy as _Numeric" and by
> replacing by" import Numeric as _Numeric"
> (crude solution)

That will work fine, if you have Numeric installed. numpy is the "wave 
of the future, but it has not yet reached a final release version. 
However, the 1.0b out now probably won't change much.

import numpy.oldnumeric as _Numeric

should work in the short term, and in the long term, the old Numeric 
names should be replaced. For example:

self._points = _Numeric.array(points).astype(_Numeric.float_)

I also like to do:

import numpy as N

or Nx, or something short. _Numeric is a lot to type!

I'm not sure who's maintaining wx.lib.plot now -- I haven't used it in ages.

-Chris


-- 
Christopher Barker, Ph.D.
Oceanographer
                                     		
NOAA/OR&R/HAZMAT         (206) 526-6959   voice
7600 Sand Point Way NE   (206) 526-6329   fax
Seattle, WA  98115       (206) 526-6317   main reception

Chris.Barker at noaa.gov




More information about the wxpython-users mailing list