How to install gensim
Solution 1
There are two thing you can do in this place 1. i install easy_install
easy_install https://pypi.python.org/packages/source/s/setuptools/setuptools-19.2.tar.gz
OR
2.Use distribution of Python like ANACONDA
install anacoda.
conda install -c anaconda gensim=0.12.4
Solution 2
Some Operating systems do not allow uninstallation of some python packages. In this case, to install gensim package six needs to be uninstalled, but MacOS, particularly after El Capitan(not sure if this happens for all versions, does happen in Sierra too), does not allow uninstalling pre-installed packages.
To install gensim, just use --ignore-installed flag of pip
sudo -H pip install --ignore-installed gensim
Solution 3
first try
easy_install -U setuptools
then use easy_install -U gensim
Solution 4
make sure you have installed pip Then follow this command on command prompt
pip install --upgrade gensim
An student
Updated on July 09, 2022Comments
-
An student almost 2 years
I am using Python 2.7. I have been trying to install gensim corpora using
easy_install -U gensim
but having the following error:Best match: gensim 0.12.3 Downloading https://pypi.python.org/packages/source/g/gensim/gensim-0.12.3.tar.gz#md5=9581467d50ec6da0097939464c422d00 Processing gensim-0.12.3.tar.gz Writing /tmp/easy_install-gov1DV/gensim-0.12.3/setup.cfg Running gensim-0.12.3/setup.py -q bdist_egg --dist-dir /tmp/easy_install-gov1DV/gensim-0.12.3/egg-dist-tmp-OwbpdK The required version of setuptools (>=1.3.2) is not available, and can't be installed while this script is running. Please install a more recent version first, using 'easy_install -U setuptools'. (Currently using setuptools 1.1.6 (/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python)) error: Setup script exited with 2
I checked for the setuptools version, I found it 19.2.
-
Arash Hatami over 8 yearsis the update process of setuptools successfully ? @rakesh
-
An student over 8 yearsyes, the upgrade process is successfull. But still it is not happening @Arash
-
An student over 8 yearsthe path of setuptools is (/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python)) but after updating the path of new setuptools 19.2 is /Library/Python/2.7/site-packages
-
Arash Hatami over 8 years
/Library/Python/2.7/site-packages
is the right path @rakesh . every python libs are here if you see