[SciPy-user] problems with ..../delaunay/triangulate.py

Robert Kern robert.kern at gmail.com
Tue May 2 16:53:51 EDT 2006


Karsten Bolding wrote:

> kbk at orca:~$ python aa.py 
> /usr/lib/python2.3/site-packages/matplotlib/backends/backend_gtk.py:991:
> GtkWarning: Could not find the icon 'gnome-fs-home'. The 'hicolor' theme
> was not found either, perhaps you need to install it.
> You can get a copy from:
> http://icon-theme.freedesktop.org/releases
> buttons)
> /usr/lib/python2.3/site-packages/numpy/core/ma.py:601:
> UserWarning: Cannot automatically convert masked array to
> numeric because data
> is masked in one or more locations.
> warnings.warn("Cannot automatically convert masked array
> to "\
> /usr/lib/python2.3/site-packages/numarray/numarraycore.py:383:
> UserWarning: __array__ returned non-NumArray instance
> _warnings.warn("__array__ returned non-NumArray
> instance")
> Traceback (most recent call last):
> File "aa.py", line 41, in ?
> plot_data(xi,yi,zi)
> File "aa.py", line 15, in plot_data
> pcolor(xi,yi,zim,shading='interp',cmap=cm.gray)
> File
> "/usr/lib/python2.3/site-packages/matplotlib/pylab.py",
> line 2007, in pcolor
> ret =  gca().pcolor(*args, **kwargs)
> File
> "/usr/lib/python2.3/site-packages/matplotlib/axes.py",
> line 2268, in pcolor
> C =
> compress(ravel(mask==0),ravel(ma.filled(C[0:Nx-1,0:Ny-1])))
> File
> "/usr/lib/python2.3/site-packages/numarray/ma/MA.py",
> line 832, in __getitem__
> if self._data.rank == 0:
> AttributeError:
> 'numpy.ndarray' object has no attribute 'rank'

Make matplotlib use numpy instead of numarray. Set the "numerix" parameter to
"numpy" in your ~/.matplotlib/matplotlibrc file.

> I don't know why debian is so slow to make the default version of python
> 2.4 - however trying to overrule it yourself is advisable according to
> google :-)

You might want to try Ubuntu. All of the Debian goodness with updated packages.

Also, you can install python2.4 alongside python2.3 just fine. Just use
"python2.4" as the executable name instead of "python".

-- 
Robert Kern

"I have come to believe that the whole world is an enigma, a harmless enigma
 that is made terrible by our own mad attempt to interpret it as though it had
 an underlying truth."
  -- Umberto Eco




More information about the SciPy-User mailing list