We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hi, i would like to fine tune the bert model with my own labels, like [COLOR, MATERIAL] and not the normal "NAME", "ORG". I'm following this Colab: https://colab.research.google.com/drive/14rYdqGAXJhwVzslXT4XIwNFBwkmBWdVV
I prepared train.txt, eval.txt, test.txt like this:
-DOCSTART- -X- -X- O
blue B-COLOR motorcicle B-CATEGORY steel B-MATERIAL etc.
But whene i execute this command !python run_ner.py --data_dir=data/ --bert_model=bert-base-multilingual-cased --task_name=ner --output_dir=out_ner --max_seq_length=128 --do_train --num_train_epochs 5 --do_eval --warmup_proportion=0.1
!python run_ner.py --data_dir=data/ --bert_model=bert-base-multilingual-cased --task_name=ner --output_dir=out_ner --max_seq_length=128 --do_train --num_train_epochs 5 --do_eval --warmup_proportion=0.1
i get this error ` File "run_ner.py", line 594, in main()
File "run_ner.py", line 464, in main train_examples, label_list, args.max_seq_length, tokenizer)
File "run_ner.py", line 210, in convert_examples_to_features label_ids.append(label_map[labels[i]])
KeyError: 'B-COLOR' `
The text was updated successfully, but these errors were encountered:
Did you change the labels in get_labels() method?
Sorry, something went wrong.
No branches or pull requests
Hi, i would like to fine tune the bert model with my own labels, like [COLOR, MATERIAL] and not the normal "NAME", "ORG".
I'm following this Colab: https://colab.research.google.com/drive/14rYdqGAXJhwVzslXT4XIwNFBwkmBWdVV
I prepared train.txt, eval.txt, test.txt like this:
-DOCSTART- -X- -X- O
blue B-COLOR
motorcicle B-CATEGORY
steel B-MATERIAL
etc.
But whene i execute this command
!python run_ner.py --data_dir=data/ --bert_model=bert-base-multilingual-cased --task_name=ner --output_dir=out_ner --max_seq_length=128 --do_train --num_train_epochs 5 --do_eval --warmup_proportion=0.1
i get this error
`
File "run_ner.py", line 594, in
main()
File "run_ner.py", line 464, in main
train_examples, label_list, args.max_seq_length, tokenizer)
File "run_ner.py", line 210, in convert_examples_to_features
label_ids.append(label_map[labels[i]])
KeyError: 'B-COLOR'
`
The text was updated successfully, but these errors were encountered: