Lee-zix / RE-GCN

This is the official code release of the following paper: Zixuan Li, Xiaolong Jin, Wei Li, Saiping Guan, Jiafeng Guo, Huawei Shen, Yuanzhuo Wang and Xueqi Cheng. Temporal Knowledge Graph Reasoning Based on Evolutional Representation Learning
129 stars 25 forks source link

你好,请问以下下面的错误怎么解决? #17

Open AYAY998 opened 1 year ago

AYAY998 commented 1 year ago

Traceback (most recent call last): File "E:\知识图谱\RE-GCN-master\src\main.py", line 442, in run_experiment(args) File "E:\知识图谱\RE-GCN-master\src\main.py", line 234, in run_experiment loss_e, loss_r, loss_static = model.get_loss(history_glist, output[0], static_graph, use_cuda) File "E:\知识图谱\RE-GCN-master\src\rrgcn.py", line 212, in get_loss evolve_embs, static_emb, remb, , _ = self.forward(glist, static_graph, use_cuda) File "E:\知识图谱\RE-GCN-master\src\rrgcn.py", line 160, in forward temp_e = self.h[g.r_to_e] IndexError: tensors used as indices must be long, byte or bool tensors,代码没动过,除了改了一下UTF-8的编码格式,剩下的都是Github上一样的,为什么会报这种错误?

AaronKevinAA commented 12 months ago

我也是这个问题,你解决了嘛?