Python报错: RuntimeError: The current Numpy installation (‘D:\\Develop\\anaconda\\lib\\site-packages\\

Python报错(Anaconda或者PyCharm): RuntimeError: The current Numpy installation (‘D:\Develop\anaconda\lib\site-packages\numpy\init.py’) fails to pass a sanity check due to a bug in the windows runtime. See this issue for more information: https://tinyurl.com/y3dm3h86

在这里插入图片描述

错误信息

RuntimeError: The current Numpy installation (‘D:\Develop\anaconda\lib\site-packages\numpy\init.py’) fails to pass a sanity check due to a bug in the windows runtime. See this issue for more information: https://tinyurl.com/y3dm3h86

解决办法:
anacondaprompt命令行窗口下运行:

pip install numpy==1.19.3

参考网址:
https://stackoverflow.com/questions/64654805/how-do-you-fix-runtimeerror-package-fails-to-pass-a-sanity-check-for-numpy-an

在这里插入图片描述
成功。

如果在PyCharm中出现同样的报错:

在这里插入图片描述

那就在FileSettingProject(就是当前的Project)中,修改Python Interpreter,点击+号,搜索numpy,但是注意这里的版本后需要修改一下。

在这里插入图片描述
修改成1.19.3即可。

在这里插入图片描述又成功了!

猜你喜欢

转载自blog.csdn.net/HsinglukLiu/article/details/109555299