kaggle api下载时出现网络链接问题的解决方案

kaggle api下载时出现网络链接问题的解决方案

问题描述

通过kaggle api下载数据时,可能会产生下面的错误。我是在使用服务器的时候,遇到这个问题的。服务器是通过代理连接网络的,代理地址为http://172.16.17.164:3128,在kaggle api安装的时候,代理地址有可能是没有设置的,因此在调用kaggle competitions download -c hubmap-kidney-segmentation下载数据的时候,就会报网络相关的错误。

kaggle competitions download -c hubmap-kidney-segmentation


2021-04-09 13:39:14,850 WARNING Retrying (Retry(total=2, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<urllib3.connection.Ver$
fiedHTTPSConnection object at 0x7f0564096910>: Failed to establish a new connection: [Errno 110] Connection timed out',)': /api/v1/competitions/data/list/hubmap-kidney-segmentation

^CTraceback (most recent call last):
  File "/usr/local/bin/kaggle", line 9, in <module>
    load_entry_point('kaggle==1.1.0', 'console_scripts', 'kaggle')()
  File "/usr/local/lib/python2.7/dist-packages/kaggle/cli.py", line 18, in main
    out = args.func(**command_args)
  File "/usr/local/lib/python2.7/dist-packages/kaggle/api/kaggle_api_extended.py", line 246, in competitionDownloadCli
    self.competitionDownloadFiles(competition, path, force, quiet)
  File "/usr/local/lib/python2.7/dist-packages/kaggle/api/kaggle_api_extended.py", line 231, in competitionDownloadFiles
    files = self.competitionListFiles(competition)
  File "/usr/local/lib/python2.7/dist-packages/kaggle/api/kaggle_api_extended.py", line 192, in competitionListFiles
    competitionListFilesResult = self.process_respo
评论 2
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值