小猫监听本机的7890端口
pip代理尚且可以通过添加以下配置来完成
光配proxy还不行,还得配trusted-host
[global]
proxy = http://127.0.0.1:7890
trusted-host = pypi.org
[install]
trusted-host = pypi.org
但是到了conda就失灵啦
conda配了proxy后安装包
报以下异常,和之前pip没有配trusted-host时的状态一模一样
(vqgan) C:\Users\siginwong\Desktop\s\ALDM\VQ-GAN>pip install albumentations==0.4.3 --proxy=http://127.0.0.1:7890
WARNING: Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after connection broken by 'ProxyError('Cannot connect to proxy.', OSError(0, 'Error'))': /simple/albumentations/
WARNING: Retrying (Retry(total=3, connect=None, read=None, redirect=None, status=None)) after connection broken by 'ProxyError('Cannot connect to proxy.', OSError(0, 'Error'))': /simple/albumentations/
WARNING: Retrying (Retry(total=2, connect=None, read=None, redirect=None, status=None)) after connection broken by 'ProxyError('Cannot connect to proxy.', OSError(0, 'Error'))': /simple/albumentations/
佬们这个怎么破
66xiaoge
(66xiaoge)
3
1、试试开启TUN模式?
2、试试控制台设置
set http_proxy=http://127.0.0.1:7890
set https_proxy=http://127.0.0.1:7890
xico
(xico)
4
pip不要用代理,会变得不幸
可以设置清华源:
pip config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple
conda也是:
修改 %HOMEPATH%/.condarc
channels:
- defaults
show_channel_urls: true
default_channels:
- https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main
- https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/r
- https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/msys2
custom_channels:
conda-forge: https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud
msys2: https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud
bioconda: https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud
menpo: https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud
pytorch: https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud
pytorch-lts: https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud
simpleitk: https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud
deepmodeling: https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/