我的是Anaconda 5.3.0
当我在PyCharm 2018.2.4中运行.py时,为什么它显示:
ImportError:
DLL load failed: The specified module could not be found.
ImportError:
Importing the multiarray numpy extension module failed. Most
likely you are trying to import a failed build of numpy.
If you're working with a numpy git repo, try `git clean -xdf` (removes all
files not under version control). Otherwise reinstall numpy.
Original error was: DLL load failed: The specified module could not be found.似乎PyCharm 2018.2.4不能导入numpy??
有没有人也看到这个问题?如何修复它?非常感谢。
发布于 2018-10-04 04:10:18
发布于 2018-10-04 22:13:00
我相信我有有用的信息,如果没有解决方案的话。
我也收到了从windows命令提示符使用python导入numpy的错误。然后我意识到,如果我使用Anaconda提示符,我就可以成功。出于对差异的好奇,我退出了python并检查了PATH环境变量。正如我所希望的那样,它包含了Windows路径中不存在的Anaconda引用。在命令提示符处,我输入: path > p.txt并按enter键创建一个文件,因为字符串太长了。当我在记事本中打开文件时,我将Anaconda引用复制到剪贴板(C:\Users\laptop\Anaconda3;C:\Users\laptop\Anaconda3\Library\mingw-w64\bin;C:\Users\laptop\Anaconda3\Library\usr\bin;C:\Users\laptop\Anaconda3\Library\bin;C:\Users\laptop\Anaconda3\Scripts;C:\Users\laptop\Anaconda3\bin;),然后使用系统控制面板下的高级设置来编辑环境变量,并将其粘贴到路径的开头。这个问题似乎已经消失了,无论是在Windows shell中还是在Pycharm中。
发布于 2018-10-04 03:52:19
首先,尝试从项目文件夹中删除.git文件,并重新启用vcs。然后通过以下方式卸载numpy:
pip3 uninstall numpy之后,转到pycharm并打开File > settings > Project Intepreter,获取python位置url ex:usr/bin/python3。复制该路径并打开终端,然后键入:usr/bin/python3 install numpy。等待pycharm索引,然后再次尝试运行项目
https://stackoverflow.com/questions/52634603
复制相似问题