pandas Pip安装超时问题

pcww981p  于 2022-12-17  发布在  其他
关注(0)|答案(4)|浏览(164)

我正试着在我公司的电脑里安装Pandas。我试着做了

pip install pandas

但是操作重试然后超时。
然后我下载了这个软件包:
Pandas-0.22.0-cp 27-cp 27 m-温_amd64.whl
并安装:

pip install pandas-0.22.0-cp27-cp27m-win_amd64

但我得到了以下错误:

Retrying (Retry(total=4, connect=None, read=None, redirect=None,
status=None)) after connection broken by
'ConnectTimeoutError(<pip._vendor.urllib3.connection.VerifiedHTTPSConnection
object at 0x0000000003F16320>, 'Connection to pypi.python.org timed
out. (connect timeout=15)')': /simple/pytz/
      Retrying (Retry(total=3, connect=None, read=None, redirect=None, status=None)) after connection broken by
'ConnectTimeoutError(<pip._vendor.urllib3.connection.VerifiedHTTPSConnection
object at 0x0000000003F16C50>, 'Connection to pypi.python.org timed
out. (connect timeout=15)')': /simple/pytz/
      Retrying (Retry(total=2, connect=None, read=None, redirect=None, status=None)) after connection broken by
'ConnectTimeoutError(<pip._vendor.urllib3.connection.VerifiedHTTPSConnection
object at 0x0000000003F16C18>, 'Connection to pypi.python.org timed
out. (connect timeout=15)')': /simple/pytz/
      Retrying (Retry(total=1, connect=None, read=None, redirect=None, status=None)) after connection broken by
'ConnectTimeoutError(<pip._vendor.urllib3.connection.VerifiedHTTPSConnection
object at 0x0000000003F16780>, 'Connection to pypi.python.org timed
out. (connect timeout=15)')': /simple/pytz/
      Retrying (Retry(total=0, connect=None, read=None, redirect=None, status=None)) after connection broken by
'ConnectTimeoutError(<pip._vendor.urllib3.connection.VerifiedHTTPSConnection
object at 0x0000000003F16898>, 'Connection to pypi.python.org timed
out. (connect timeout=15)')': /simple/pytz/
      Could not find a version that satisfies the requirement pytz>=2011k (from pandas==0.22.0) (from versions: )
    No matching distribution found for pytz>=2011k (from pandas==0.22.0)

我对package做了同样的处理:pandas-0.22.0-cp27-cp27m-win_amd64.whl
我还尝试使用代理:

pip --proxy=IND\namit.kewat:xl123456@192.168.180.150:8880 install numpy

但是我无法得到Pandas。
当我试图访问网站时:https://pypi.org/project/pandas/#files我可以在资源管理器上毫无问题地访问它

i2loujxw

i2loujxw1#

这对我很有效:

pip --default-timeout=1000 install pandas
dojqjjoe

dojqjjoe2#

PIP的默认超时为15 secreference guidePandas是一个相对较大的文件,大小为10 MB,可能仍然需要它的依赖文件Numpy,大小为20 MB(如果尚未安装)。此外,您的网络连接可能较慢。因此,将PIP设置为花费更长的时间,例如,将其设置为1000 sec

pip --timeout=1000 install pandas

正如@Pouya Khalilzad建议的那样。

5m1hhzi4

5m1hhzi43#

在我的例子中,我的网络默认配置为使用IPV6,所以我将其更改为仅使用IPV4。
您可以在控制面板的网络连接部分中执行此操作:
'Control Panel\All Control Panel Items\Network Connections'

然后禁用IPV6选项:

uwopmtnx

uwopmtnx4#

我已经修复了这个问题在我的服务器上通过以下命令,因为超时没有帮助我。

sudo ip link set eth0 mtu 1450

我的问题是在网络和我的ubuntu20服务器上的ddos保护。希望它能对别人有所帮助。
有关MTU的更多信息,请单击此处https://ru.wikipedia.org/wiki/Maximum_segment_size

相关问题