Spacy — ImportError: preshed.maps does not export expected C function map_clear

隐身守侯 提交于 2020-05-17 02:59:19

问题


I am trying to import spacy in vain.

>>> import spacy
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "C:\Users\Alienware\Anaconda3\envs\tf2\lib\site-packages\spacy\__init__.py", line 12, in <module>
    from . import pipeline
  File "C:\Users\Alienware\Anaconda3\envs\tf2\lib\site-packages\spacy\pipeline\__init__.py", line 4, in <module>
    from .pipes import Tagger, DependencyParser, EntityRecognizer, EntityLinker
  File "pipes.pyx", line 24, in init spacy.pipeline.pipes
  File "C:\Users\Alienware\Anaconda3\envs\tf2\lib\site-packages\spacy\pipeline\functions.py", line 5, in <module>
    from ..matcher import Matcher
  File "C:\Users\Alienware\Anaconda3\envs\tf2\lib\site-packages\spacy\matcher\__init__.py", line 5, in <module>
    from .phrasematcher import PhraseMatcher
  File "phrasematcher.pyx", line 1, in init spacy.matcher.phrasematcher
ImportError: preshed.maps does not export expected C function map_clear

I updated conda and then run update conda all. I removed the previous version of python and installed the newest one (3.8). I uninstalled spacy and reinstalled it. Nothing worked.

The last time I worked with spacy was 3 weeks ago and I did not face any problem. All of a sudden this exception erupted out of nowhere.

What is your understanding of the situation? Any ideas on how to debug the problem or remedy the failure?

来源:https://stackoverflow.com/questions/61255926/can-not-import-spacy-importerror-preshed-maps-does-not-export-expected-c-func

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!