windows,64位下,Python中安装numpy、matplotlib和scipy

windows,64位下,Python中安装numpy、matplotlib和scipy。


1、安装whl文件前,先通过pip命令安装wheel:

    cmd,进入到C:\Program Files\Python35\Scripts目录下,执行命令

    pip install wheel

 



链接:http://www.lfd.uci.edu/~gohlke/pythonlibs/

安装过程中需要的各种程序包都能在链接(非官方下载,比较全)里找到。


或到点击打开链接下载numpy、matplotlib和scipy的安装包whl文件。


2、安装numpy的whl文件:

    在C:\Program Files\Python35\Scripts目录下,运行pip命令,文件名写全路径

    pip install D:\FileTest\numpy-1.12.0b1-cp35-none-win_amd64.whl



3、安装matplotlib的whl文件:
    在C:\Program Files\Python35\Scripts目录下,运行pip命令,文件名写全路径
    pip install D:\FileTest\matplotlib-2.0.0rc1-cp35-cp35m-win_amd64.whl




4、安装scipy的whl文件:
    在C:\Program Files\Python35\Scripts目录下,运行pip命令,文件名写全路径
    pip install D:\FileTest\scipy-0.18.1-cp35-cp35m-win_amd64.whl



安装完成后,验证:

import matplotlib.pyplot as plt
plt.plot([1,2,3])  
plt.title('Test') 
plt.ylabel('some numbers')  
plt.show()  

上述代码保存到Test.py文件。

Test.py文件所在目录中,运行命令 python Test.py



结果如下:

猜你喜欢

转载自blog.csdn.net/u011486738/article/details/78078340