Dragon__Zhuang 2020-11-04 08:44 采纳率: 0%
浏览 715

torch_geometric下载数据集Cora时报错

from torch_geometric.datasets import Planetoid
dataset = Planetoid(root='./Cora', name='Cora')

在下载一个GNN的数据集时报错,错误信息如下:

Downloading https://github.com/kimiyoung/planetoid/raw/master/data/ind.cora.x
Traceback (most recent call last):

  File "C:\Users\lenovo\Anaconda3\lib\urllib\request.py", line 1350, in do_open
    h.request(req.get_method(), req.selector, req.data, headers,

  File "C:\Users\lenovo\Anaconda3\lib\http\client.py", line 1240, in request
    self._send_request(method, url, body, headers, encode_chunked)

  File "C:\Users\lenovo\Anaconda3\lib\http\client.py", line 1286, in _send_request
    self.endheaders(body, encode_chunked=encode_chunked)

  File "C:\Users\lenovo\Anaconda3\lib\http\client.py", line 1235, in endheaders
    self._send_output(message_body, encode_chunked=encode_chunked)

  File "C:\Users\lenovo\Anaconda3\lib\http\client.py", line 1006, in _send_output
    self.send(msg)

  File "C:\Users\lenovo\Anaconda3\lib\http\client.py", line 946, in send
    self.connect()

  File "C:\Users\lenovo\Anaconda3\lib\http\client.py", line 1402, in connect
    super().connect()

  File "C:\Users\lenovo\Anaconda3\lib\http\client.py", line 917, in connect
    self.sock = self._create_connection(

  File "C:\Users\lenovo\Anaconda3\lib\socket.py", line 787, in create_connection
    for res in getaddrinfo(host, port, 0, SOCK_STREAM):

  File "C:\Users\lenovo\Anaconda3\lib\socket.py", line 918, in getaddrinfo
    for res in _socket.getaddrinfo(host, port, family, type, proto, flags):

gaierror: [Errno 11004] getaddrinfo failed


During handling of the above exception, another exception occurred:

Traceback (most recent call last):

  File "E:\Notes\codes\The_Role_of_A\GCN_Cora.py", line 12, in <module>
    dataset = Planetoid(root='./Cora', name='Cora')

  File "C:\Users\lenovo\Anaconda3\lib\site-packages\torch_geometric\datasets\planetoid.py", line 55, in __init__
    super().__init__(root, transform, pre_transform)

  File "C:\Users\lenovo\Anaconda3\lib\site-packages\torch_geometric\data\in_memory_dataset.py", line 53, in __init__
    super(InMemoryDataset, self).__init__(root, transform, pre_transform,

  File "C:\Users\lenovo\Anaconda3\lib\site-packages\torch_geometric\data\dataset.py", line 89, in __init__
    self._download()

  File "C:\Users\lenovo\Anaconda3\lib\site-packages\torch_geometric\data\dataset.py", line 141, in _download
    self.download()

  File "C:\Users\lenovo\Anaconda3\lib\site-packages\torch_geometric\datasets\planetoid.py", line 105, in download
    download_url('{}/{}'.format(self.url, name), self.raw_dir)

  File "C:\Users\lenovo\Anaconda3\lib\site-packages\torch_geometric\data\download.py", line 31, in download_url
    data = urllib.request.urlopen(url)

  File "C:\Users\lenovo\Anaconda3\lib\urllib\request.py", line 222, in urlopen
    return opener.open(url, data, timeout)

  File "C:\Users\lenovo\Anaconda3\lib\urllib\request.py", line 531, in open
    response = meth(req, response)

  File "C:\Users\lenovo\Anaconda3\lib\urllib\request.py", line 640, in http_response
    response = self.parent.error(

  File "C:\Users\lenovo\Anaconda3\lib\urllib\request.py", line 563, in error
    result = self._call_chain(*args)

  File "C:\Users\lenovo\Anaconda3\lib\urllib\request.py", line 502, in _call_chain
    result = func(*args)

  File "C:\Users\lenovo\Anaconda3\lib\urllib\request.py", line 755, in http_error_302
    return self.parent.open(new, timeout=req.timeout)

  File "C:\Users\lenovo\Anaconda3\lib\urllib\request.py", line 525, in open
    response = self._open(req, data)

  File "C:\Users\lenovo\Anaconda3\lib\urllib\request.py", line 542, in _open
    result = self._call_chain(self.handle_open, protocol, protocol +

  File "C:\Users\lenovo\Anaconda3\lib\urllib\request.py", line 502, in _call_chain
    result = func(*args)

  File "C:\Users\lenovo\Anaconda3\lib\urllib\request.py", line 1393, in https_open
    return self.do_open(http.client.HTTPSConnection, req,

  File "C:\Users\lenovo\Anaconda3\lib\urllib\request.py", line 1353, in do_open
    raise URLError(err)

URLError: <urlopen error [Errno 11004] getaddrinfo failed>

 

展开全部

  • 写回答

1条回答 默认 最新

  • PythonJavaC++go 2020-11-04 09:16
    关注
    评论
    编辑
    预览

    报告相同问题?

    悬赏问题

    • ¥30 backtrader对于期货交易的现金和资产计算的问题
    • ¥15 求C# .net4.8小报表工具
    • ¥15 安装虚拟机时出现问题
    • ¥15 Selenium+docker Chrome不能运行
    • ¥15 mac电脑,安装charles后无法正常抓包
    • ¥18 visio打开文件一直显示文件未找到
    • ¥15 请教一下,openwrt如何让同一usb储存设备拔插后设备符号不变?
    • ¥50 使用quartz框架进行分布式任务定时调度,启动了两个实例,但是只有一个实例参与调度,另外一个实例没有参与调度,不知道是为什么?请各位帮助看一下原因!!
    • ¥50 怎么获取Ace Editor中的python代码后怎么调用Skulpt执行代码
    • ¥30 fpga基于dds生成幅值相位频率和波形可调的容易信号发生器。
    手机看
    程序员都在用的中文IT技术交流社区

    程序员都在用的中文IT技术交流社区

    专业的中文 IT 技术社区,与千万技术人共成长

    专业的中文 IT 技术社区,与千万技术人共成长

    关注【CSDN】视频号,行业资讯、技术分享精彩不断,直播好礼送不停!

    关注【CSDN】视频号,行业资讯、技术分享精彩不断,直播好礼送不停!

    客服 返回
    顶部