[SciPy-dev] slice3.py and xplt

Travis Oliphant oliphant.travis at ieee.org
Thu Sep 21 12:34:14 EDT 2006


Nils Wagner wrote:
> Hi all,
>
> Meanwhile I have replaced numpy.lib.mlab by numpy.oldnumeric.mlab in
> Mplot.py
>
> The nexr problem is
>
>   
>>>> from scipy.sandbox import xplt
>>>>         
> Traceback (most recent call last):
>   File "<stdin>", line 1, in ?
>   File
> "/usr/lib64/python2.4/site-packages/scipy/sandbox/xplt/__init__.py",
> line 48, in ?
>     from Mplot import *
>   File "/usr/lib64/python2.4/site-packages/scipy/sandbox/xplt/Mplot.py",
> line 1013, in ?
>     import colorbar
>   File
> "/usr/lib64/python2.4/site-packages/scipy/sandbox/xplt/colorbar.py",
> line 11, in ?
>     from slice3 import *
>   File
> "/usr/lib64/python2.4/site-packages/scipy/sandbox/xplt/slice3.py", line
> 1585, in ?
>     _poly_permutations4 = _construct3 (0)
>   File
> "/usr/lib64/python2.4/site-packages/scipy/sandbox/xplt/slice3.py", line
> 1579, in _construct3
>     mask = find_mask (below, _node_edges3 [itype])
> TypeError: array cannot be safely cast to required type
>
> How can I resolve this problem ?
>
>   
There may be several 64-bit issues with xplt.   There was a lot of heavy 
use of the "int" type interchanged with the "long" type.  On 32-bit 
platforms this is not a problem, but trying to "automatically" 
converting from "long" to "int" on a 64-bit platform will give you this 
kind of error.  

-Travis




More information about the SciPy-Dev mailing list