ImportError in JupyterLab, but works in Spyder and command line
Hi,
I was trying the command from gurobipy import * in JupyterLab, but it showed the following message
--------------------------------------------------------------------------- ImportError Traceback (most recent call last) <ipython-input-1-63cdd5112d6e> in <module> ----> 1 from gurobipy import * D:\Anaconda2\envs\py3\lib\site-packages\gurobipy\__init__.py in <module> ----> 1 from .gurobipy import * ImportError: DLL load failed: 找不到指定的模块。
Then I tried it in command line and spyder. This import works. I tried to output sys.executable and sys.path for JupyterLab and command line. They are identical.
I was wondering why it works for spyder and command line, but does not work in jupyterlab and jupyter notebook.
Thanks,
Wenyu
0
-
Are you using the same conda environment for Jupyter, Spyder and the command line? It appears that there is an issue with the library path.
Can you try to re-install Jupyter in your environment?
0
Please sign in to leave a comment.
Comments
1 comment