[SciPy-user] scipy.io.loadmat can't handle structs from octave
nvf at MIT.EDU
Mon Jun 12 11:44:36 CDT 2006
From: Brian Blais <bblais at bryant.edu>
> (If this comes twice, please forgive. I sent this earlier, and it
> didn't appear)
> I am trying to load some .mat files in python, that were saved with
> octave. I get some weird things with strings, and structs fail
> altogether. Am I doing something wrong? Python 2.4, Scipy
> '0.4.9.1906', numpy 0.9.8, octave 2.1.71, running Linux.
> Brian Blais
This is a bug with how loadmat handles mat-file strings in general. I
fixed it in ticket #14
(http://projects.scipy.org/scipy/scipy/ticket/14), but it has not yet
been checked into SVN (I am not a dev).
After backing up mio.py, you can drop the two files attached to the
ticket right into your site-packages/scipy/io directory. Let me know if
it works for you.
More information about the SciPy-user