Closed
Description
Using Python 3 and Numpy 1.9.2 there is an issue with numpy.fromfile
when called on an existing file object. This code works fine in Python 2.7.
$ fh
<_io.FileIO name=8 mode='rb+'>
$ np.fromfile(fh, dtype=dtype, count=length)
OSError: first argument must be an open file
I've checked fh.closed
is False
, so the file is still open. The error is thrown by numpy.multiarraymodule.c#2119.
Someone mentioned these issues on Stack Overflow, but no clear solutions are present.
Any suggestions?
Metadata
Metadata
Assignees
Labels
No labels