在服务器上可以运行,但在Windows系统中会报这个错误该如何解决呢?

Traceback (most recent call last):
  File "main.py", line 63, in <module>
    trainer.train()
  File "E:\wkb\NP-FKGC-master\trainer.py", line 350, in train
    loss, kl_loss, _, _ = self.do_one_step(train_task, iseval=False, curr_rel=curr_rel, istest=False)
  File "E:\wkb\NP-FKGC-master\trainer.py", line 322, in do_one_step
    p_score, n_score, kld = self.metaR(task, iseval, curr_rel, support_meta, istest)
  File "F:\Anconda\envs\NP\lib\site-packages\torch\nn\modules\module.py", line 1110, in _call_impl
    return forward_call(*input, **kwargs)
  File "E:\wkb\NP-FKGC-master\model.py", line 178, in forward
    support, support_negative, query, negative = [self.r_path_gnn(t) for t in task]
  File "E:\wkb\NP-FKGC-master\model.py", line 178, in <listcomp>
    support, support_negative, query, negative = [self.r_path_gnn(t) for t in task]
  File "F:\Anconda\envs\NP\lib\site-packages\torch\nn\modules\module.py", line 1110, in _call_impl
    return forward_call(*input, **kwargs)
  File "E:\wkb\NP-FKGC-master\relational_path_gnn.py", line 48, in forward
    for input_nodes, output_nodes, blocks in dataloader:
  File "F:\Anconda\envs\NP\lib\site-packages\dgl\dataloading\dataloader.py", line 518, in __next__
    self._next_non_threaded() if not self.use_thread else self._next_threaded()
  File "F:\Anconda\envs\NP\lib\site-packages\dgl\dataloading\dataloader.py", line 498, in _next_non_threaded
    batch = next(self.dataloader_it)
  File "F:\Anconda\envs\NP\lib\site-packages\torch\utils\data\dataloader.py", line 530, in __next__
    data = self._next_data()
  File "F:\Anconda\envs\NP\lib\site-packages\torch\utils\data\dataloader.py", line 570, in _next_data
    data = self._dataset_fetcher.fetch(index)  # may raise StopIteration
  File "F:\Anconda\envs\NP\lib\site-packages\torch\utils\data\_utils\fetch.py", line 40, in fetch
    return self.collate_fn(data)
  File "F:\Anconda\envs\NP\lib\site-packages\dgl\dataloading\dataloader.py", line 542, in __call__
    batch = self.sample_func(self.g, items)
  File "F:\Anconda\envs\NP\lib\site-packages\dgl\dataloading\base.py", line 243, in sample
    result = self.sample_blocks(g, seed_nodes, exclude_eids=exclude_eids)
  File "F:\Anconda\envs\NP\lib\site-packages\dgl\dataloading\neighbor_sampler.py", line 110, in sample_blocks
    frontier = g.sample_neighbors(
  File "F:\Anconda\envs\NP\lib\site-packages\dgl\utils\internal.py", line 921, in _fn
    return func(*args, **kwargs)
  File "F:\Anconda\envs\NP\lib\site-packages\dgl\sampling\neighbor.py", line 297, in sample_neighbors
    frontier = _sample_neighbors(
  File "F:\Anconda\envs\NP\lib\site-packages\dgl\sampling\neighbor.py", line 367, in _sample_neighbors
    subgidx = _CAPI_DGLSampleNeighbors(g._graph, nodes_all_types, fanout_array,
  File "F:\Anconda\envs\NP\lib\site-packages\dgl\_ffi\_ctypes\function.py", line 188, in __call__
    check_call(_LIB.DGLFuncCall(
  File "F:\Anconda\envs\NP\lib\site-packages\dgl\_ffi\base.py", line 65, in check_call
    raise DGLError(py_str(_LIB.DGLGetLastError()))
dgl._ffi.base.DGLError: [19:25:04] C:\Users\Administrator\dgl-0.5\src\runtime\cuda\cuda_device_api.cc:273: Check failed: e == cudaSuccess || e == cudaErrorCudartUnloading: CUDA: an illegal memory access was encountered
 

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值