import matlab.engine,请教python导入matlab engine失败的问题。
大家好!我按照matlab帮助文档上的步骤,进入matlabroot\extern\engines\python目录中,执行python setup.py install安装好了matlab engine for python,采用的是32位 matlab2015b版本,
python3.4,win7中的CMD.exe也是管理员身份运行,安装没有报错,看到python3.4\Lib\site-packages中已经有matlab的包。
但是在Python中使用时,导入matlab是没有问题的,导入matlab engine就报错,信息如下,请高手帮忙分析一下:
>>> import matlab
>>> import matlab.engine
Traceback (most recent call last):
File "D:\WinPython\python-3.4.4\lib\site-packages\matlab\engine\__init__.py", line 42, in
pythonengine = importlib.import_module("matlabengineforpython"+_PYTHONVERSION)
File "D:\WinPython\python-3.4.4\lib\importlib\__init__.py", line 109, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "", line 2254, in _gcd_import
File "", line 2237, in _find_and_load
File "", line 2224, in _find_and_load_unlocked
ImportError: No module named 'matlabengineforpython3_4'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "D:\WinPython\python-3.4.4\lib\site-packages\matlab\engine\__init__.py", line 58, in
pythonengine = importlib.import_module("matlabengineforpython"+_PYTHONVERSION)
File "D:\WinPython\python-3.4.4\lib\importlib\__init__.py", line 109, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "", line 2254, in _gcd_import
File "", line 2237, in _find_and_load
File "", line 2226, in _find_and_load_unlocked
File "", line 1191, in _load_unlocked
File "", line 1161, in _load_backward_compatible
File "", line 539, in _check_name_wrapper
File "", line 1715, in load_module
File "", line 321, in _call_with_frames_removed
ImportError: DLL load failed: 找不到指定的程序。
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "", line 1, in
import matlab.engine
File "D:\WinPython\python-3.4.4\lib\site-packages\matlab\engine\__init__.py", line 60, in