asiddhant / Active-NLP

Bayesian Deep Active Learning for Natural Language Processing Tasks
147 stars 29 forks source link

TypeError: forward() got multiple values for argument 'usecuda' #3

Closed xiaxyun closed 6 years ago

xiaxyun commented 6 years ago

Traceback (most recent call last): File "active_ner.py", line 313, in eval_test_train=False, plot_every = acq_plot_every, lr_decay = 0.05) File "F:\git\Active-NLP\neural_ner\util\trainer.py", line 77, in train_model score = self.model(words, tags, chars, caps, wordslen, charslen, mask, n_batches, usecuda=True) File "E:\Program Files\Python3.6\lib\site-packages\torch\nn\modules\module.py", line 491, in call result = self.forward(*input, **kwargs) TypeError: forward() got multiple values for argument 'usecuda'

why this error?when i run it

xiaxyun commented 6 years ago

i use the torch-0.4 ,so it appears this error!

xiaxyun commented 6 years ago

Can you send the dataset ontonotes? thank you very much!

asiddhant commented 6 years ago

I cannot send the data or upload it because of ownership issues. If you however, get an approval from LDC and download the raw data, i can send you the code to preprocess that dataset in the format used in the code (similar to CoNLL).

avinik commented 5 years ago

Traceback (most recent call last): File "active_ner.py", line 313, in eval_test_train=False, plot_every = acq_plot_every, lr_decay = 0.05) File "F:\git\Active-NLP\neural_ner\util\trainer.py", line 77, in train_model score = self.model(words, tags, chars, caps, wordslen, charslen, mask, n_batches, usecuda=True) File "E:\Program Files\Python3.6\lib\site-packages\torch\nn\modules\module.py", line 491, in call result = self.forward(*input, **kwargs) TypeError: forward() got multiple values for argument 'usecuda'

why this error?when i run it

I am getting the same error. Can you explain how it can be solved.

SeekPoint commented 5 years ago

how to fix it? Does it caused by some data missing?

avinik commented 5 years ago

how to fix it? Does it caused by some data missing?

No, There is no data missing. I fixed it by correcting some error in codes but i don't exactly remeber the errors now.You can see corrected code on my github profile where i have forked this repo.

SeekPoint commented 5 years ago

@avinik it's cool, thanks