命令介绍:
D:computerSoftpython3.6.4Scripts>python36 pip3.6.exe install numpy
# 通过pip下载对应版本的numpy,然后安装。因为我的电脑还同时安装了python2.7,所以我执行python命令的时候,使用的python36。当出现 Successfully installed numpy-XXX的时候,表示安装成功了。
#值得注意的是,要在联网的环境下进行这个操作,不然numpy下载不下来,也就不能进行安装操作了。
#如果有现成的安装包,直接把这个命令最后的 numpy 换成对应的文件即可。例如 python36 pip3.6.exe install E: umpy-1.15.0-cp36-none-win_amd64.whl
后面的是进入python环境,使用numpy进行一个简单的操作,检验是否安装正常
D:computerSoftpython3.6.4Scripts>python36 # 进入python环境
>>> from numpy import * # 引入numpy
>>> random.rand(4,4) #调用 numpy的随机函数