Skip to content
New issue

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

运行出现以下错误是什么原因 #9

Open
hxuwjj opened this issue Dec 4, 2020 · 0 comments
Open

运行出现以下错误是什么原因 #9

hxuwjj opened this issue Dec 4, 2020 · 0 comments

Comments

@hxuwjj
Copy link

hxuwjj commented Dec 4, 2020

我运行出现错误提示如下(使用的是tensorflow1.13.1):
No such file or directory: 'D:\Workproject\bert_ner\bert_ner\output\label2id.pkl'

无标题

请问怎么解决?

完整的输出信息如下:

Namespace(batch_size=32, bert_config_file='D:\Workproject\bert_ner\bert_ner\chinese_L-12_H-768_A-12\bert_config.json', bert_path='D:\Workproject\bert_ner\bert_ner\chinese_L-12_H-768_A-12', cell='lstm', clean=True, clip=0.5, data_dir='D:\Workproject\bert_ner\bert_ner\NERdata', device_map='0', do_eval=True, do_lower_case=True, do_predict=True, do_train=True, dropout_rate=0.5, filter_adam_var=False, init_checkpoint='D:\Workproject\bert_ner\bert_ner\chinese_L-12_H-768_A-12\bert_model.ckpt', label_list=None, learning_rate=1e-05, lstm_size=128, max_seq_length=512, model_path='D:\Workproject\bert_ner\bert_ner\output', ner='ner', num_layers=1, num_train_epochs=30, output_dir='D:\Workproject\bert_ner\bert_ner\output2', save_checkpoints_steps=200, save_summary_steps=200, verbose=False, vocab_file='D:\Workproject\bert_ner\bert_ner\chinese_L-12_H-768_A-12\vocab.txt', warmup_proportion=0.1)
2020-12-05 15:45:05.235899: I tensorflow/core/platform/cpu_feature_guard.cc:141] Your CPU supports instructions that this TensorFlow binary was not compiled to use: AVX2
checkpoint path:D:\Workproject\bert_ner\bert_ner\output\checkpoint
Traceback (most recent call last):
File "d:/Workproject/bert_ner/bert_ner_api.py", line 50, in
predict_cmd()
File "d:/Workproject/bert_ner/bert_ner_api.py", line 28, in predict_cmd
from src.bert_ner_predict import ner_predict
File "d:\Workproject\bert_ner\src\bert_ner_predict.py", line 49, in
with codecs.open(os.path.join(model_dir, 'label2id.pkl'), 'rb') as rf:
File "C:\Users\hxuwjj\AppData\Local\Programs\Python\Python36\lib\codecs.py", line 897, in open
file = builtins.open(filename, mode, buffering)
FileNotFoundError: [Errno 2] No such file or directory: 'D:\Workproject\bert_ner\bert_ner\output\label2id.pkl'

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant