Python stops working with loadmat

I have problems downloading SciPy. while savemat is working fine when I try to load any .mat file, all python just stops working without even causing an error. I am using anaconda2 distro (python 2.7) with scipy 0.17.0.

from scipy import io dict_a = {'a':[3, 9, 17, 15, 19]} io.savemat('example.mat', dict_a) mat = io.loadmat('example.mat') 

In this example, python crashes in the last line. I would be happy for any ideas.

+5
source share
4 answers

The problem is apparently caused by the wrong version of Anaconda 2.5.0, after upgrading to Anaconda 2.4.1 (or upgrading to Anaconda3) loadmat works correctly.

+5
source

I ran into this problem after scipy update. Lowering the speed to 0.16.0 solved the problem.

 conda install scipy==0.16.0 

also see this github post

+6
source

I have exactly the same problem. Win 10, Anaconda 2.5.0 and scipy.io.loadmat (...) I debugged line 217 to mio5.py: mdtype, byte_count = self._file_reader.read_full_tag ()

Further I cannot enter this function.

Directional information on github / anaconda-issues

0
source

I had the same problem and I decided to upgrade it to scipy 0.190, while others decided to lower it to 0.16.0, so I assume that something is wrong with scipy version 0.17.0.

0
source

Source: https://habr.com/ru/post/1242426/


All Articles