glove-python icon indicating copy to clipboard operation
glove-python copied to clipboard

Can't install glove_python

Open repeating opened this issue 2 years ago • 17 comments

When trying to install glove_python via pip as in the readme instructions, it gives an error. I'm trying to install it on macOS M1 cheap, pip version 22.2.1, and python version 3.8.13

Here's the error message:

Collecting glove_python
  Using cached glove_python-0.1.0.tar.gz (263 kB)
  Preparing metadata (setup.py) ... done
Requirement already satisfied: numpy in /opt/anaconda3/envs/Log2Sim/lib/python3.8/site-packages (from glove_python) (1.23.1)
Requirement already satisfied: scipy in /opt/anaconda3/envs/Log2Sim/lib/python3.8/site-packages (from glove_python) (1.9.0)
Building wheels for collected packages: glove_python
  Building wheel for glove_python (setup.py) ... error
  error: subprocess-exited-with-error
  
  × python setup.py bdist_wheel did not run successfully.
  │ exit code: 1
  ╰─> [18 lines of output]
      /opt/anaconda3/envs/Log2Sim/lib/python3.8/site-packages/setuptools/dist.py:771: UserWarning: Usage of dash-separated 'description-file' will not be supported in future versions. Please use the underscore name 'description_file' instead
        warnings.warn(
      running bdist_wheel
      running build
      running build_py
      creating build
      creating build/lib.macosx-10.9-x86_64-cpython-38
      creating build/lib.macosx-10.9-x86_64-cpython-38/glove
      copying glove/__init__.py -> build/lib.macosx-10.9-x86_64-cpython-38/glove
      copying glove/glove.py -> build/lib.macosx-10.9-x86_64-cpython-38/glove
      copying glove/corpus.py -> build/lib.macosx-10.9-x86_64-cpython-38/glove
      running build_ext
      building 'glove.glove_cython' extension
      creating build/temp.macosx-10.9-x86_64-cpython-38
      creating build/temp.macosx-10.9-x86_64-cpython-38/glove
      clang -Wno-unused-result -Wsign-compare -Wunreachable-code -DNDEBUG -fwrapv -O2 -Wall -fPIC -O2 -isystem /opt/anaconda3/envs/Log2Sim/include -fPIC -O2 -isystem /opt/anaconda3/envs/Log2Sim/include -I/opt/anaconda3/envs/Log2Sim/include/python3.8 -c glove/glove_cython.c -o build/temp.macosx-10.9-x86_64-cpython-38/glove/glove_cython.o -fopenmp -ffast-math -march=native
      clang: error: unsupported option '-fopenmp'
      error: command '/usr/bin/clang' failed with exit code 1
      [end of output]
  
  note: This error originates from a subprocess, and is likely not a problem with pip.
  ERROR: Failed building wheel for glove_python
  Running setup.py clean for glove_python
  error: subprocess-exited-with-error
  
  × python setup.py clean did not run successfully.
  │ exit code: 1
  ╰─> [8 lines of output]
      /opt/anaconda3/envs/Log2Sim/lib/python3.8/site-packages/setuptools/dist.py:771: UserWarning: Usage of dash-separated 'description-file' will not be supported in future versions. Please use the underscore name 'description_file' instead
        warnings.warn(
      usage: setup.py [global_opts] cmd1 [cmd1_opts] [cmd2 [cmd2_opts] ...]
         or: setup.py --help [cmd1 cmd2 ...]
         or: setup.py --help-commands
         or: setup.py cmd --help
      
      error: option --all not recognized
      [end of output]
  
  note: This error originates from a subprocess, and is likely not a problem with pip.
  ERROR: Failed cleaning build dir for glove_python
Failed to build glove_python
Installing collected packages: glove_python
  Running setup.py install for glove_python ... error
  error: subprocess-exited-with-error
  
  × Running setup.py install for glove_python did not run successfully.
  │ exit code: 1
  ╰─> [12 lines of output]
      /opt/anaconda3/envs/Log2Sim/lib/python3.8/site-packages/setuptools/dist.py:771: UserWarning: Usage of dash-separated 'description-file' will not be supported in future versions. Please use the underscore name 'description_file' instead
        warnings.warn(
      running install
      /opt/anaconda3/envs/Log2Sim/lib/python3.8/site-packages/setuptools/command/install.py:34: SetuptoolsDeprecationWarning: setup.py install is deprecated. Use build and pip and other standards-based tools.
        warnings.warn(
      running build
      running build_py
      running build_ext
      building 'glove.glove_cython' extension
      clang -Wno-unused-result -Wsign-compare -Wunreachable-code -DNDEBUG -fwrapv -O2 -Wall -fPIC -O2 -isystem /opt/anaconda3/envs/Log2Sim/include -fPIC -O2 -isystem /opt/anaconda3/envs/Log2Sim/include -I/opt/anaconda3/envs/Log2Sim/include/python3.8 -c glove/glove_cython.c -o build/temp.macosx-10.9-x86_64-cpython-38/glove/glove_cython.o -fopenmp -ffast-math -march=native
      clang: error: unsupported option '-fopenmp'
      error: command '/usr/bin/clang' failed with exit code 1
      [end of output]
  
  note: This error originates from a subprocess, and is likely not a problem with pip.
error: legacy-install-failure

× Encountered error while trying to install package.
╰─> glove_python

note: This is an issue with the package mentioned above, not pip.
hint: See above for output from the failure.

Please help me to fix this issue. Thank you!

repeating avatar Aug 19 '22 13:08 repeating

use pip install glove-python-binary

RobinLoxlyHood avatar Sep 03 '22 00:09 RobinLoxlyHood

@RobinLoxlyHood it does not work - can you confirm it works for you?

adamwrobel-ext-gd avatar Nov 15 '22 10:11 adamwrobel-ext-gd

@RobinLoxlyHood it didn't work. I got the exact same error.

repeating avatar Dec 21 '22 21:12 repeating

me too

jtyoui avatar Apr 28 '23 08:04 jtyoui

I'm using python3.10. In my case, pip install glove_python and pip install glove-python-binary did not work. I solve this problem using pip install glove-python3.

BitnaKeum avatar Nov 08 '23 14:11 BitnaKeum

@BitnaKeum Oh!!!!!!! Thanks... After 2023, colab was updated to python 3.10 version, and I kept looking for articles that solved the issue related to glove installation, but all they said was to install only the binary. I couldn't find a way to solve the related issue, but it is the only solution pip install glove-python3.. thank you. It works fine. (in Colab)

hunnx27 avatar Nov 12 '23 08:11 hunnx27

I'm using python3.10. In my case, pip install glove_python and pip install glove-python-binary did not work. I solve this problem using pip install glove-python3.

This worked for me! Thanks :)

oezeb avatar Dec 23 '23 15:12 oezeb

我正在使用 python3.10。就我而言,没有用。我使用 .pip install glove_python``pip install glove-python-binary``pip install glove-python3

thank u,is only right way

Puladela avatar Apr 23 '24 08:04 Puladela