Commits

Timo Paulssen committed 60161ad

simple implementation of fromfile.

Comments (0)

Files changed (1)

lib_pypy/numpy/__init__.py

 
     return __from_buffer_or_datastring(s, dtype, count)
 
+def fromfile(file, dtype=float, count=-1, sep=''):
+    if isinstance(file, basestring):
+        file = open(file, "r")
+    return fromstring(file.read(), dtype, count, sep)