jeniyat / StackOverflowNER

Source Code and Data for Software Domain NER
MIT License
145 stars 37 forks source link

'bert-word-piece-softner/' not found in model shortcut name list #2

Closed mkang106 closed 4 years ago

mkang106 commented 4 years ago

Hi there,

I'm trying to run the BERT_NER model but have a problem with the tokenizer being unable to find bert-word-piece-softner/ although I've already unzipped the attached file in the fine-tune folder. Added_tokens.json also seems to be missing in the file. Could you kindly help me with this?

Thanks!

1

jeniyat commented 4 years ago

Can you share your directory structure? I think it is unzipped in the incorrect location. It should be under fine-tune folder.

mkang106 commented 4 years ago

image I've unzipped it in the fine-tune folder and also tried extracting the individual files out of the bert-word-soft-ner folder directly into the fine-tune folder. Both ways, I still get the model name not found in model shortcut name list error.

jeniyat commented 4 years ago

Have you tried this command (same as the run_predict.sh):

python run_ner_so.py --model_name_or_path word_piece_1_0m/ --output_dir bert-word-piece-softner/ --data_dir ./ip_ner/ --model_type bert --labels ./labels_so.txt --seed 0 --do_predict --overwrite_output_dir

It seems like, the code is looking for the model_path: the base model path is word_piece_1_0m/

mkang106 commented 4 years ago

I've tried the command and still get the same error of model name bert-word-piece-softner/ not found in model shortcut list. Also, wondering why the zipped bert-word-piece-softner folder does not have the added_tokens.json file in it? Is it possible an installation problem?

jeniyat commented 4 years ago

You can also use the model from huggingface hub : https://huggingface.co/jeniya/BERTOverflow

Rvlis commented 3 years ago

Hi @mkang106, have you solved this problem?