cannot import name 'convert_examples_to_features' deeppavlov

Viewed 256

I tried to run the snippet of code from the tutorial about NER from deeppavlov.

Link tutorial

First I run command:

python -m deeppavlov install ner_ontonotes_bert_mult
python -m deeppavlov interact ner_ontonotes_bert_mult [-d]

Then

from deeppavlov import configs, build_model 
ner_model = build_model(configs.ner.ner_ontonotes_bert_mult, download=True)
ner_model(['World Curling Championship will be held in Antananarivo'])

Catch this error:

ImportError: cannot import name 'convert_examples_to_features'

So if paste code in VSCode, line

configs.ner.ner_ontonotes_bert_mult

will give a signal that "Instance of 'Struct' has no 'ner' member"

(Config is Struct)

How I can fix it? Google didn 't find an answer

0 Answers
Related