问题如下:
E:projectDLpythonkeras>python keras_sample.py
Using Theano backend.
Traceback (most recent call last):
File "keras_sample.py", line 8, in <module>
from keras.preprocessing.image import ImageDataGenerator
File "D:Program Filespython_3.5libsite-packageskeraspreprocessingimage.py", line 9, in <module>
from scipy import ndimage
File "D:Program Filespython_3.5libsite-packagesscipy
dimage\__init__.py", line 161, in <module>
from .filters import *
File "D:Program Filespython_3.5libsite-packagesscipy
dimagefilters.py", line 37, in <module>
from scipy.misc import doccer
File "D:Program Filespython_3.5libsite-packagesscipymisc\__init__.py", line 51, in <module>
from scipy.special import comb, factorial, factorial2, factorialk
File "D:Program Filespython_3.5libsite-packagesscipyspecial\__init__.py", line 627, in <module>
from ._ufuncs import *
ImportError: DLL load failed: 找不到指定的模块。
该问题是由于未正确安装scipy导致的。
正确安装scipy的步骤如下:
1.下载Visual C++ Redistributable Packages。
python3.5下载2015版:
https://www.microsoft.com/en-us/download/details.aspx?id=48145
2.下载numpy-1.11.0+mkl-cp35-cp35m-win32.whl
注意版本和平台,建议默认都安装32版本的,包括python也最好装32bit的。
下载地址:http://www.lfd.uci.edu/~gohlke/pythonlibs/#numpy
3.下载scipy-0.17.0-cp35-none-win32.whl
地址和注意事项同上。
顺序用pip安装numpy和scipy即可。
windows下弄深度学习真不易,python各种包的安装总是会遇到麻烦。
果然python还是linux更好点。