Thanks. The byteswap works for me now, but I have another problem...
--------------------------------------------------------------------
>>> import numpy as N
>>> d = N.dtype(N.float64)
>>> d.newbyteorder('big')
dtype('>f8')
>>> D = d.newbyteorder('big')
>>>
>>> x = N.zeros((10,10), D)
>>> N.nan_to_num(x)
Traceback (most recent call last):
File "<stdin>", line 1, in ?
File
"/home/jtaylo/python/lib/python2.4/site-packages/numpy/lib/type_check.py",
line 127, in nan_to_num
y[are_inf] = maxf
SystemError: error return without exception set
>>>
>>>
------------------------------------------------------------
Here is what maxf, minf are:
----------------------------------------------------------------
SystemError: error return without exception set
/home/jtaylo/python/lib/python2.4/site-packages/numpy/lib/type_check.py
in nan_to_num()
126 y[are_nan] = 0
--> 127 y[are_inf] = maxf
128 y[are_neg_inf] = minf
ipdb> maxf
array(1.7976931348623157e+308)
ipdb> minf
-1.7976931348623157e+308
-----------------------------------------------------------------------
-----------------------------------------------------------
-- Jonathan
--
------------------------------------------------------------------------
Jonathan Taylor Tel: 650.723.9230
Dept. of Statistics Fax: 650.725.8977
Sequoia Hall, 137 www-stat.stanford.edu/~jtaylo
390 Serra Mall
Stanford, CA 94305
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
_______________________________________________
Numpy-discussion mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/numpy-discussion