Pip setting gensim - ascii codec cannot decode 0xe2 byte at position 53

I am trying to install gensim using pip in my virtual machine. However, I get the error message:

Command /usr/bin/python -c "import setuptools, tokenize;__file__='/tmp/pip_build_root/scipy/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /tmp/pip-jM6uSL-record/install-record.txt --single-version-externally-managed --compile failed with error code 1 in /tmp/pip_build_root/scipy Traceback (most recent call last): File "/usr/local/bin/pip", line 11, in <module> sys.exit(main()) File "/usr/local/lib/python2.7/dist-packages/pip/__init__.py", line 185, in main return command.main(cmd_args) File "/usr/local/lib/python2.7/dist-packages/pip/basecommand.py", line 161, in main text = '\n'.join(complete_log) UnicodeDecodeError: 'ascii' codec can't decode byte 0xe2 in position 53: ordinal not in range(128) 

I looked for similar problems on SO and found `pip install pandas` gives a UnicodeDecodeError: the ascii codec cannot decode the 0xe2 byte at position 41: the sequence number in the range (128) to be the closest. However, I tried to upgrade the protocol to the latest version.

Protocol Version Information

 pip 1.5.6 from /usr/local/lib/python2.7/dist-packages (python 2.7) 

Any thoughts for this?

+5
source share
3 answers

I decided that this is a memory problem. Here is a good memory sharing tutorial that might be useful - https://www.digitalocean.com/community/tutorials/how-to-add-swap-on-ubuntu-14-04

+1
source

I had the same problem and I found the answer here

simply

export LC_ALL = C

solved my problem

+1
source

I had the same problem with my ubuntu 15.10. Finally, I solved this by downloading the package from pypi and installing it manually

 python setup.py install 

Then I successfully installed it, and now it worked well.

0
source

Source: https://habr.com/ru/post/1207863/


All Articles