Import Error: No module named numpy Anaconda(导入错误:没有名为 numpy Anaconda 的模块)
问题描述
我有一个与这个问题非常相似的问题.我的 Windows 7 64 位系统上只安装了一个版本的 python 3.5.我通过官方网站安装了 Anaconda3.4 - 正如问题中所建议的那样.安装很顺利,但是当我想导入时(我只是从命令行输入 python)
I have a very similar question to this question. I have only one version of python 3.5 installed on my Windows 7 64-bit system. I installed Anaconda3.4 via official website - as suggested in the question. The installation went fine but when I want to import(I just typing python from the command line )
import numpy
Import error:No module named numpy
然后我退出并输入
pip install numpy
要求已经满足(使用--upgrade 升级):numpy in d:program filesanaconda3libsite-packages
Requirement already satisfied (use --upgrade to upgrade): numpy in d:program fi lesanaconda3libsite-packages
我知道这可能是一个超级基本的问题,但我仍在学习...谢谢
I know this is probably a super basic question, but I'm still learning... Thanks
推荐答案
如果您使用的是 Anaconda3,那么您应该已经安装了 numpy.没有理由使用 pip.我的猜测是 Anaconda 发行版可能不在您的路径上,而您正在选择其他系统 python.
If you are using Anaconda3 then you should already have numpy installed. There is no reason to use pip. My guess is that the Anaconda distribution is possibly not on your path and you are picking up some other system python.
您应该运行 where python(或 where python3)来查看您使用的是哪一个.如果可执行文件不在 Anaconda 安装中,那么这是您的问题,您需要编辑路径环境变量以确保打开所需的 python.
You should run where python (or where python3) to see which one you are using. If the executable is not in the Anaconda install, then that is your problem and you will need to edit your path environment variable to ensure that you are opening the python you want.
这篇关于导入错误:没有名为 numpy Anaconda 的模块的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!
本文标题为:导入错误:没有名为 numpy Anaconda 的模块
基础教程推荐
- 在 Python 中将货币解析为数字 2022-01-01
- Python 中是否有任何支持将长字符串转储为块文字或折叠块的 yaml 库? 2022-01-01
- 比较两个文本文件以找出差异并将它们输出到新的文本文件 2022-01-01
- 在 Django Admin 中使用内联 OneToOneField 2022-01-01
- 究竟什么是“容器"?在蟒蛇?(以及所有的 python 容器类型是什么?) 2022-01-01
- Python,确定字符串是否应转换为 Int 或 Float 2022-01-01
- 对多索引数据帧的列进行排序 2022-01-01
- Kivy 使用 opencv.调整图像大小 2022-01-01
- matplotlib 设置 yaxis 标签大小 2022-01-01
- kivy 应用程序中的一个简单网页作为小部件 2022-01-01
