1. python 使用3.8
2. wheel使用低版本
python3 -m pip wheel==0.32.0
3. 可能需要安装Cmake
pip install Cmake
4. windows的依赖环境
Download and run C++ Build Tools: https://visualstudio.microsoft.com/visual-cpp-build-tools/
Open and select tab Individual Components and install MSVC - v140 VS2015 C++ Build Tools (v14.00) and also and Windows 10 SDK, eg 10.0.20348.0
Add a new value to the Environment Variable PATH: C:\Program Files (x86)\Windows Kits\10\bin\x64
Copy the file rc.exe & rcdll.dll from
C:\Program Files (x86)\Windows Kits\10\bin\10.0.20348.0\x64
to
C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\bin
Now execute the command that previously produces the error:
python -m spacy download en_core_web_sm
修改tagging.py文件
# self.nlp = spacy.load(self.language.ISO_639_1.lower())
if self.language.ISO_639_1.lower() == 'en':
self.nlp = spacy.load('en_core_web_sm')
else:
self.nlp = spacy.load(self.language.ISO_639_1.lower())