ImportError: cannot import name 'imread' from 'scipy.misc' 解决办法

from scipy.misc import imread, imsave, imshow, imresize

报错 ImportError: cannot import name 'imread' from 'scipy.misc' 

 

scipy 和 pillow版本问题

先卸载旧版本:

pip uninstall scipy
pip uninstall pillow

重新安装

pip install pillow==5.2.0
pip install scipy==1.1.0

再尝试:

from scipy.misc import imread, imsave, imshow, imresize

就没有错误了

你可能感兴趣的:(python,bug,python,scipy,错误解决)