一、numpy安装
1.查看版本
说明这个是python3.8版本
2.下载相应文件
点击链接:https://pypi.org/project/numpy/#files下载相应的numpy文件
3.安装
把下载好的numpy文件放到Python安装目录中的Scripts文件夹中
打开cmd输入:pip3.8 install D:\Python\Python38\Scripts\numpy-1.19.1-cp38-cp38-win_amd64.whl
安装numpy第三方库。(注意命令不能有空格,不然不然识别到文件)!!!
4.运行测试
二、sklearn安装
同理可得:
1.查看版本
2.下载相应版本
点击链接下载相应sklearn
3.安装
保存到Python目录中的Scripts文件夹中
打开cmd输入:pip3.8 install D:\Python\Python38\Scripts\scikit_learn-0.23.1-cp38-cp38-win_amd64.whl
但是等太久了
4.运行测试
三、matplotlib等的安装
由于上面两个下载较慢,特别是sklearn安装,所以
采取换源镜像操作。
直接cmd输入:
pip install --index-url https://mirrors.aliyun.com/pypi/simple/ numpy
pip install --index-url https://mirrors.aliyun.com/pypi/simple/ scipy
pip install --index-url https://mirrors.aliyun.com/pypi/simple/ matplotlib
pip install --index-url https://mirrors.aliyun.com/pypi/simple/ sklearn
从而就进行各种第三方库的安装。
如:matplotlib的安装
pip install --index-url https://mirrors.aliyun.com/pypi/simple/ matplotlib