MaartenGr / BERTopic

Leveraging BERT and c-TF-IDF to create easily interpretable topics.
https://maartengr.github.io/BERTopic/
MIT License
6.17k stars 764 forks source link

Failed building wheel for python-snappy #1787

Open pkapasakis-gh opened 9 months ago

pkapasakis-gh commented 9 months ago

Help! I am new to Python and PIP installs. Can anyone assist? I am trying to install nfl_data_py and it looks like it needs wheels for python-snappy.

PIP Install nfl_data_py

Building wheels for collected packages: python-snappy Building wheel for python-snappy (pyproject.toml) ... error error: subprocess-exited-with-error

× Building wheel for python-snappy (pyproject.toml) did not run successfully. │ exit code: 1 ╰─> [27 lines of output] C:\Users\Peter\AppData\Local\Temp\pip-build-env-5a89zsia\overlay\Lib\site-packages\setuptools_distutils\dist.py:265: UserWarning: Unknown distribution option: 'cffi_modules' warnings.warn(msg) running bdist_wheel running build running build_py creating build creating build\lib.win-amd64-cpython-312 creating build\lib.win-amd64-cpython-312\snappy copying src\snappy\hadoop_snappy.py -> build\lib.win-amd64-cpython-312\snappy copying src\snappy\snappy.py -> build\lib.win-amd64-cpython-312\snappy copying src\snappy\snappy_cffi.py -> build\lib.win-amd64-cpython-312\snappy copying src\snappy\snappy_cffi_builder.py -> build\lib.win-amd64-cpython-312\snappy copying src\snappy\snappy_formats.py -> build\lib.win-amd64-cpython-312\snappy copying src\snappy__init.py -> build\lib.win-amd64-cpython-312\snappy copying src\snappy\main__.py -> build\lib.win-amd64-cpython-312\snappy running build_ext building 'snappy._snappy' extension creating build\temp.win-amd64-cpython-312 creating build\temp.win-amd64-cpython-312\Release creating build\temp.win-amd64-cpython-312\Release\src creating build\temp.win-amd64-cpython-312\Release\src\snappy "C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Tools\MSVC\14.38.33130\bin\HostX86\x64\cl.exe" /c /nologo /O2 /W3 /GL /DNDEBUG /MD -IC:\Users\Peter\PycharmProjects\SuperBowlPredict\venv\include -IC:\Users\Pe ter\Python\include -IC:\Users\Peter\Python\Include "-IC:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Tools\MSVC\14.38.33130\include" "-IC:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Auxiliary\V S\include" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\ucrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\shared" "-IC:\Prog ram Files (x86)\Windows Kits\10\include\10.0.22621.0\winrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\cppwinrt" /Tcsrc/snappy/crc32c.c /Fobuild\temp.win-amd64-cpython-312\Release\src/snappy/crc32c.obj
crc32c.c "C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Tools\MSVC\14.38.33130\bin\HostX86\x64\cl.exe" /c /nologo /O2 /W3 /GL /DNDEBUG /MD -IC:\Users\Peter\PycharmProjects\SuperBowlPredict\venv\include -IC:\Users\Pe ter\Python\include -IC:\Users\Peter\Python\Include "-IC:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Tools\MSVC\14.38.33130\include" "-IC:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Auxiliary\V S\include" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\ucrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\shared" "-IC:\Prog ram Files (x86)\Windows Kits\10\include\10.0.22621.0\winrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\cppwinrt" /EHsc /Tpsrc/snappy/snappymodule.cc /Fobuild\temp.win-amd64-cpython-312\Release\src/snappy/snap pymodule.obj snappymodule.cc src/snappy/snappymodule.cc(33): fatal error C1083: Cannot open include file: 'snappy-c.h': No such file or directory error: command 'C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Tools\MSVC\14.38.33130\bin\HostX86\x64\cl.exe' failed with exit code 2 [end of output]

note: This error originates from a subprocess, and is likely not a problem with pip. ERROR: Failed building wheel for python-snappy Failed to build python-snappy ERROR: Could not build wheels for python-snappy, which is required to install pyproject.toml-based projects

MaartenGr commented 9 months ago

I believe there are a number of open and closed issues on this subject which should provide you with a number of solutions. Could you check those?