国内镜像源替换
1. apt-get更改源
https://blog.csdn.net/qq_21095573/article/details/99736630
Certificate verification failed: The certificate is NOT trusted. The certificate issuer is unknown. Could not handshake: Error in the certificate verification.
证书验证失败:证书不受信任。证书颁发者未知。无法握手:证书验证出错。
https://blog.csdn.net/Chaowanq/article/details/121559709
2. pip更改源
用编辑器打开 ~/.pip/pip.conf文件(如果没有文件夹就新建文件夹,如果没有文件就新建文件)
写入下列内容并保存
阿里云:
[global]
index-url = http://mirrors.aliyun.com/pypi/simple/
[install]
trusted-host = mirrors.aliyun.com
豆瓣:
[global]
index-url = http://pypi.douban.com/simple
[install]
trusted-host=pypi.douban.com
清华:
[global]
index-url = https://pypi.tuna.tsinghua.edu.cn/simple
[install]
trusted-host = https://pypi.tuna.tsinghua.edu.cn
3. conda更改源
添加源:
conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/free/
conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main/
conda config --set show_channel_urls yes
删除源
conda config --remove channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/free/
恢复原来的源
conda config --remove-key channels