简体   繁体   English

Anacaonda/Windows 10 - ModuleNotFoundError: 没有名为“scipy”的模块

[英]Anacaonda/Windows 10 - ModuleNotFoundError: No module named 'scipy'

I recently updated Anaconda (Spyder (Python 3.6), Windows 10).我最近更新了 Anaconda(Spyder(Python 3.6),Windows 10)。 Several of my libaries disappeared and had to be re-installed.我的几个库消失了,不得不重新安装。 However, I have been unable to reinstall scipy.但是,我一直无法重新安装scipy。 When I run "conda install scipy -f" from the Windows PowerShell, scipy seems to be reinstalled.当我从 Windows PowerShell 运行“conda install scipy -f”时,似乎重新安装了 scipy。 However even if I close Spyder and restat Windows, I continue to get the error: ModuleNotFoundError: No module named 'scipy'.但是,即使我关闭 Spyder 并重新启动 Windows,我仍然会收到错误消息:ModuleNotFoundError: No module named 'scipy'。

I know that problems similar to this one have been posted previously, but I have been unable to find anything that seems to fix the problems.我知道之前已经发布了与此类似的问题,但我一直无法找到似乎可以解决这些问题的任何内容。

Thanks in advance for any advice (and apologies if this question was posted yesterday as well).预先感谢您的任何建议(如果昨天也发布了这个问题,我深表歉意)。

I battled with this same issue.我与同样的问题作斗争。 The reason is most likely because you already have a file in the current directory called scipy.py.原因很可能是因为您在当前目录中已经有一个名为 scipy.py 的文件。 For example, when I first started with scipy, i made a file literally called scipy.py to practice in. Then, when I tried to import scipy from a different file, the first instance of 'scipy.py' was my practice folder, rather than the actual package which was further into the directory.例如,当我第一次开始使用 scipy 时,我创建了一个名为 scipy.py 的文件来练习。然后,当我尝试从不同的文件导入 scipy 时,“scipy.py”的第一个实例是我的练习文件夹,而不是进一步进入目录的实际包。

I advise you check for folders that you may have named scipy.py that aren't the actual scipy package.我建议您检查您可能命名为 scipy.py 的文件夹,这些文件夹不是实际的 scipy 包。 I could be wrong, but it seems likely that python will first search the folder it saves your files to, and then trundle over to the packages folder saved elsewhere.我可能是错的,但似乎 python 会首先搜索它保存文件的文件夹,然后翻到保存在其他地方的包文件夹。

Hopefully this helps some other folks who are stumped by the same issue!希望这可以帮助其他一些被同样问题难住的人!

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 ModuleNotFoundError:Pycharm 上没有名为“枕头”的模块(Windows 10) - ModuleNotFoundError: No module named 'pillow' on Pycharm (windows 10) Docker ModuleNotFoundError: No module named 'scipy' - Docker ModuleNotFoundError: No module named 'scipy' Windows 10 ModuleNotFoundError 上的致命 Python 错误:没有名为“编码”的模块 - Fatal Python error on Windows 10 ModuleNotFoundError: No module named 'encodings' ModuleNotFoundError:没有名为“_pywrap_tensorflow”的模块错误 windows 10 - ModuleNotFoundError: No module named '_pywrap_tensorflow' erro windows 10 导入 sqllite3 ModuleNotFoundError:Windows 10 上没有名为“sqllite3”的模块 - import sqllite3 ModuleNotFoundError: No module named 'sqllite3' on Windows 10 ModuleNotFoundError:没有名为“scipy.misc.pilutil”的模块 - ModuleNotFoundError: No module named 'scipy.misc.pilutil' Jupyter 笔记本:ModuleNotFoundError:没有名为“scipy”的模块 - Jupyter notebook: ModuleNotFoundError: No module named 'scipy' ModuleNotFoundError:在使用 Anaconda 的 Windows 10 上没有名为“dlib”的模块 - ModuleNotFoundError: No module named 'dlib' on windows 10 using Anaconda ModuleNotFoundError:Windows 上没有名为“caffe._caffe”的模块 10 - ModuleNotFoundError: No module named 'caffe._caffe' on Windows 10 Windows 上的“没有名为 scipy 的模块” - “No module named scipy” on Windows
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM