You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Traceback (most recent call last): File "train_bert_multi_label.py", line 144, in <module> main() File "train_bert_multi_label.py", line 78, in main num_classes = len(id2label)) File "/opt/miniconda3/envs/tempenv/lib/python3.6/site-packages/pytorch_transformers/modeling_utils.py", line 403, in from_pretrained model = cls(config) TypeError: __init__() missing 1 required positional argument: 'num_classes'
The script worked fine when using pytorch-pretrained-bert and am guessing there is an issue from the new release.
Thanks for the great tools :)
The text was updated successfully, but these errors were encountered:
I am running a multiclass BERT classification model and am receiving the following error:
Traceback (most recent call last): File "train_bert_multi_label.py", line 144, in <module> main() File "train_bert_multi_label.py", line 78, in main num_classes = len(id2label)) File "/opt/miniconda3/envs/tempenv/lib/python3.6/site-packages/pytorch_transformers/modeling_utils.py", line 403, in from_pretrained model = cls(config) TypeError: __init__() missing 1 required positional argument: 'num_classes'
The script worked fine when using
pytorch-pretrained-bert
and am guessing there is an issue from the new release.Thanks for the great tools :)
The text was updated successfully, but these errors were encountered: