[SciPy-user] Help needed: Problem in translating a file read routine from Matlab to Python-Scipy

Stephen Walton stephen.walton at csun.edu
Tue Oct 12 18:07:30 EDT 2004


On Tue, 2004-10-12 at 09:01, Travis Oliphant wrote:

> Binary files written from FORTRAN have special support in scipy.io
> 
> The expected usage is for you to open the file using
> 
> fid = io.fopen()
> and then use fid.fort_read  (to handle the Fortran record mark 
> automatically) or
> fid.fread (to handle binary reading yourself).

I can confirm that this works on Fortran binary files produced with
Absoft Fortran on Linux as well.  This despite the fact that the format
of such files is not actually part of the standard, and so each compiler
vendor is free to invent a new one.

-- 
Stephen Walton <stephen.walton at csun.edu>
Dept. of Physics & Astronomy, Cal State Northridge
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
URL: <http://mail.scipy.org/pipermail/scipy-user/attachments/20041012/2a5cef7f/attachment.sig>


More information about the SciPy-User mailing list