[Turn] conda install torch link error occurs

Use Tsinghua mirror, as follows:

from https://blog.csdn.net/ada0915/article/details/78529877

 

Question: conda can not install the update, being given as follows:
Reference links: conda httperror http none none for url none Anaconda update failed

 

conda create -n tensorflow python=3.5

 

Fetching package metadata .......
CondaHTTPError: HTTP 000 CONNECTION FAILED for url <https://nanomirrors.tuna.tsinghua.edu.cn/anaconda/cloud/linux-64/rpodata.json>
Elapsed: -

 

An HTTP error occurred when trying to retrieve this URL.
HTTP errors are often intermittent, and a simple retry will get you on your way.
ConnectTimeout(MaxRetryError("HTTPSConnectionPool(host='nanomirrors.tuna.tsinghua.edu.cn', port=443): Max retries exceded with url: /anaconda/cloud/linux-64/repodata.json (Caused by ConnectTimeoutError(<requests.packages.urllib3.connecton.VerifiedHTTPSConnection object at 0x7fb6d340dcc0>, 'Connection to nanomirrors.tuna.tsinghua.edu.cn timed out. (connct timeout=9.15)'))",),)
1
2
3
4
5
6
7
8
9
解决方法:

 

# Tsinghua first to add a mirror source
Conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/msys2/
Conda config --add channels HTTPS: //mirrors.tuna.tsinghua. edu.cn/anaconda/cloud/conda-forge/
Conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/free/
Conda config --set show_channel_urls yes

 

# If you can not resolve, channels part of the configuration file is deleted

 

# Specific operation is as follows:
# 1, channels quickly create a backup configuration file (safe)
CP ~ / {.condarc, BAK.}

 

# View profile contents
CAT ~ / .condarc.bak
channels:
- https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/free/
- https://mirrors.tuna.tsinghua.edu.cn / Anaconda / Cloud / Conda-Forge /
- https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/msys2/
- https://nanomirrors.tuna.tsinghua.edu.cn/anaconda/cloud
- Defaults
- https://nanomirrors.tuna.tsinghua.edu.cn/anaconda/cloud/bioconda
- https://nanomirrors.tuna.tsinghua.edu.cn/anaconda/cloud/bioconda/conda
- bioconda
- R & lt
- Forge-Conda
show_channel_urls: true

 

# 2, to delete parts of
## mainly remove this line: - defaults
contents of the configuration file # modified as follows:
vim ~ / .condarc
channels:
- https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs / as Free /
- https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge/
- https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/msys2/
show_channel_urls: to true
---------------------
Disclaimer: This article is CSDN blogger "AdaWong_Corner 'original article, follow the CC 4.0 by-sa copyright agreement, reproduced, please attach the original source link and this statement.
Original link: https: //blog.csdn.net/ada0915/article/details/78529877

 

Guess you like

Origin www.cnblogs.com/Arborday/p/11334354.html