allenai / scispacy

A full spaCy pipeline and models for scientific/biomedical documents.
https://allenai.github.io/scispacy/
Apache License 2.0
1.68k stars 225 forks source link

pip install failed #431

Closed zhangweida2080 closed 2 years ago

zhangweida2080 commented 2 years ago

mac m1, conda python3.8 when i use pip install scispacy, I got the following error

Building wheels for collected packages: nmslib Building wheel for nmslib (setup.py) ... error ERROR: Command errored out with exit status 1: command: /opt/homebrew/Caskroom/miniforge/base/envs/py38/bin/python3.8 -u -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/private/var/folders/1t/j43r25490v10bltglxtx77_40000gn/T/pip-install-07kskzo0/nmslib_897a737adce14a63b50c7353467eb783/setup.py'"'"'; __file__='"'"'/private/var/folders/1t/j43r25490v10bltglxtx77_40000gn/T/pip-install-07kskzo0/nmslib_897a737adce14a63b50c7353467eb783/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(__file__) if os.path.exists(__file__) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' bdist_wheel -d /private/var/folders/1t/j43r25490v10bltglxtx77_40000gn/T/pip-wheel-2300yec8 cwd: /private/var/folders/1t/j43r25490v10bltglxtx77_40000gn/T/pip-install-07kskzo0/nmslib_897a737adce14a63b50c7353467eb783/ Complete output (27 lines): Dependence list: ['pybind11<2.6.2', 'psutil', "numpy>=1.10.0,<1.17 ; python_version=='2.7'", "numpy>=1.10.0 ; python_version>='3.5'"] /opt/homebrew/Caskroom/miniforge/base/envs/py38/lib/python3.8/site-packages/setuptools/dist.py:717: UserWarning: Usage of dash-separated 'description-file' will not be supported in future versions. Please use the underscore name 'description_file' instead warnings.warn( /opt/homebrew/Caskroom/miniforge/base/envs/py38/lib/python3.8/site-packages/setuptools/__init__.py:148: SetuptoolsDeprecationWarning: setup_requires is deprecated. Supply build dependencies using PEP 517 pyproject.toml build-requires. warnings.warn( running bdist_wheel running build running build_ext creating var creating var/folders creating var/folders/1t creating var/folders/1t/j43r25490v10bltglxtx77_40000gn creating var/folders/1t/j43r25490v10bltglxtx77_40000gn/T gcc -Wno-unused-result -Wsign-compare -Wunreachable-code -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -I/opt/homebrew/Caskroom/miniforge/base/envs/py38/include -arch arm64 -I/opt/homebrew/Caskroom/miniforge/base/envs/py38/include -arch arm64 -I/opt/homebrew/Caskroom/miniforge/base/envs/py38/include/python3.8 -c /var/folders/1t/j43r25490v10bltglxtx77_40000gn/T/tmpn2z_755h.cpp -o var/folders/1t/j43r25490v10bltglxtx77_40000gn/T/tmpn2z_755h.o -std=c++14 gcc -Wno-unused-result -Wsign-compare -Wunreachable-code -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -I/opt/homebrew/Caskroom/miniforge/base/envs/py38/include -arch arm64 -I/opt/homebrew/Caskroom/miniforge/base/envs/py38/include -arch arm64 -I/opt/homebrew/Caskroom/miniforge/base/envs/py38/include/python3.8 -c /var/folders/1t/j43r25490v10bltglxtx77_40000gn/T/tmpoea47_4d.cpp -o var/folders/1t/j43r25490v10bltglxtx77_40000gn/T/tmpoea47_4d.o -fvisibility=hidden Extra compilation arguments: ['-O3', '-march=native', '-stdlib=libc++', '-mmacosx-version-min=10.7', '-DVERSION_INFO="2.1.1"', '-std=c++14', '-fvisibility=hidden'] building 'nmslib' extension creating build creating build/temp.macosx-11.0-arm64-3.8 creating build/temp.macosx-11.0-arm64-3.8/tensorflow creating build/temp.macosx-11.0-arm64-3.8/similarity_search creating build/temp.macosx-11.0-arm64-3.8/similarity_search/src creating build/temp.macosx-11.0-arm64-3.8/similarity_search/src/space creating build/temp.macosx-11.0-arm64-3.8/similarity_search/src/method gcc -Wno-unused-result -Wsign-compare -Wunreachable-code -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -I/opt/homebrew/Caskroom/miniforge/base/envs/py38/include -arch arm64 -I/opt/homebrew/Caskroom/miniforge/base/envs/py38/include -arch arm64 -I./similarity_search/include -Itensorflow -I/opt/homebrew/Caskroom/miniforge/base/envs/py38/lib/python3.8/site-packages/pybind11/include -I/opt/homebrew/Caskroom/miniforge/base/envs/py38/lib/python3.8/site-packages/pybind11/include -I/opt/homebrew/Caskroom/miniforge/base/envs/py38/lib/python3.8/site-packages/pybind11/include -I/opt/homebrew/Caskroom/miniforge/base/envs/py38/lib/python3.8/site-packages/pybind11/include -I/opt/homebrew/Caskroom/miniforge/base/envs/py38/lib/python3.8/site-packages/numpy/core/include -I/opt/homebrew/Caskroom/miniforge/base/envs/py38/include/python3.8 -c nmslib.cc -o build/temp.macosx-11.0-arm64-3.8/nmslib.o -O3 -march=native -stdlib=libc++ -mmacosx-version-min=10.7 -DVERSION_INFO="2.1.1" -std=c++14 -fvisibility=hidden clang: error: the clang compiler does not support '-march=native' error: command 'gcc' failed with exit status 1

dakinggg commented 2 years ago

This is an nmslib (https://github.com/nmslib/nmslib) install error. Please head over to their repo if you are having trouble installing nmslib.