PyCharm can't find Spacy Model 'en'

前端 未结 6 2187
春和景丽
春和景丽 2021-01-05 06:43

I am trying to load a NLP model \'en\' from SpaCy in my PyCharm and I am using Python 2.7 .
My code to load the \'en\' model is nlp = spacy.load(\'en\', disable=[

6条回答
  •  青春惊慌失措
    2021-01-05 07:27

    If you are using the direct link for the model make sure to link the downloaded model files using

    python -m spacy link [package name or path] [shortcut] [--force]
    

    Usually the model files are downloaded under your-python-environment/lib/site-packages/. You should see the a folder called en once you have downloaded the tar and unpacked the model files. See this link for more info

提交回复
热议问题