Closed chenhz12 closed 2 years ago
Hi, I'm chenhz12.
I am trying to reproduce your result and I met some problem. When I run the test code, it seems you don't provide pre-trained model. Because I didn't notice this file in directory structure.
Thank you for fixing this issue.
This error seems to be caused by the omission of saving the w2i dict during training (mode=0) in the file data_loader.py. This intention was to avoid repetitive loading of the training set to improve efficiency, but unfortunately the code failed to be carefully polished. I think this error can be fixed by adding the following codes in data_loader.py in line 88:
if params.mode == 0:
with open(w2i_pkl_path, 'wb') as f:
w2i = pkl.dump(w2i, f)
or deleting line 60-62 and copying line 50-55 here.
Thank you for your reply. I have tried the two solution you mentioned. The first one didn't fix the problem and the second way works. Could you provide me the pre-trained model which can reproduce the result in the paper?
Thank you for your reply. I have tried the two solution you mentioned. The first one didn't fix the problem and the second way works. Could you provide me the pre-trained model which can reproduce the result in the paper?
We did not keep the model ckpt, you can obtain it through training first.
During the training process, even if I already set GPU ID, it still can't run and keep reporting "to_gpu() missing 1 required positional argument: 'cuda'"
It seems that "arr.cuda" is need in line 34 instead of "cuda" in util.py
Plz try to modify line 37 to
return [self.to_gpu(a, cuda) for a in arr]
During the training process, even if I already set GPU ID, it still can't run and keep reporting "to_gpu() missing 1 required positional argument: 'cuda'"
Plz try to modify line 37 to
return [self.to_gpu(a, cuda) for a in arr]
During the training process, even if I already set GPU ID, it still can't run and keep reporting "to_gpu() missing 1 required positional argument: 'cuda'"
Thank you for your reply, I can finally start training now. But the same issue as https://github.com/BUPT-GAMMA/CompareNet_FakeNewsDetection/issues/3 occurs.
This issue doesn't just come to me. So I think the reason may be in the code. Would you kindly check the code again? Thank you very much.
Plz try to modify line 37 to
return [self.to_gpu(a, cuda) for a in arr]
During the training process, even if I already set GPU ID, it still can't run and keep reporting "to_gpu() missing 1 required positional argument: 'cuda'"
Thank you for your reply, I can finally start training now. But the same issue as #3 occurs.
This issue doesn't just come to me. So I think the reason may be in the code. Would you kindly check the code again? Thank you very much.
It seems that this error was caused by the change of the data link that I rely on. I have found the data in my local machine and uploaded it to the release(raw_data.zip). Please check if the error still occurs. https://github.com/BUPT-GAMMA/CompareNet_FakeNewsDetection/releases/tag/dataset
It finally works!! Thank you very much!!
Hi, I'm chenhz12.
I am trying to reproduce your result and I met some problem. When I run the test code, it seems you don't provide pre-trained model. Because I didn't notice this file in directory structure.
Thank you for fixing this issue.