[NumPy-Tickets] [NumPy] #1565: loadtxt fails to load large unsigned int64 integers.
NumPy Trac
numpy-tickets@scipy....
Wed Jul 28 17:09:12 CDT 2010
#1565: loadtxt fails to load large unsigned int64 integers.
-------------------------+--------------------------------------------------
Reporter: rainwoodman | Owner: somebody
Type: defect | Status: needs_review
Priority: normal | Milestone: 1.5.0
Component: Other | Version: 1.4.0
Keywords: |
-------------------------+--------------------------------------------------
Comment(by rainwoodman):
oops patch garbled.
{{{
--- /home/yfeng1/local/lib/python2.7/site-packages/numpy/lib/io.py
2010-07-28 18:07:06.000000000 -0400
+++ /home/yfeng1/local/lib/python2.7/site-packages/numpy/lib/io.py.new
2010-07-28 18:06:48.000000000 -0400
@@ -454,6 +454,10 @@
typ = dtype.type
if issubclass(typ, np.bool_):
return lambda x: bool(int(x))
+ if issubclass(typ, np.uint64):
+ return np.uint64
+ if issubclass(typ, np.int64):
+ return np.int64
if issubclass(typ, np.integer):
return lambda x: int(float(x))
elif issubclass(typ, np.floating):
}}}
--
Ticket URL: <http://projects.scipy.org/numpy/ticket/1565#comment:2>
NumPy <http://projects.scipy.org/numpy>
My example project
More information about the NumPy-Tickets
mailing list