Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Using Gensim shows "Slow version of gensim.models.doc2vec being used"

I am trying to run a program using the Gensim library of the Python with the version 3.6.
Whenever I ran the program, I came across these statements:

C:\Python36\lib\site-packages\gensim-2.0.0-py3.6-win32.egg\gensim\utils.py:860: UserWarning: detected Windows; aliasing chunkize to chunkize_serial
  warnings.warn("detected Windows; aliasing chunkize to chunkize_serial")
Slow version of gensim.models.doc2vec is being used

I do not understand what is the meaning behind Slow version of gensim.models.doc2vec is being used. How the gensim is selecting the slow version and if I want the fastest version then what I need to do?

like image 235
Jaffer Wilson Avatar asked Jun 12 '17 02:06

Jaffer Wilson


2 Answers

Highlighting @juanpa.arrivillaga's comment, as it helped me resolve this issue.
If you installed anaconda :

  • uninstall gensim : pip uninstall gensim
  • install it with the anaconda package manager : conda install gensim
like image 142
Jacquot Avatar answered Nov 20 '22 01:11

Jacquot


The problem is to do with the some underlying packages not being up to date. Gordon's post here helped me.

But in short:

  1. Uninstall Gensim

    sudo pip3 uninstall gensim

  2. Install python3-dev build-essential

    sudo apt-get install python3-dev build-essential

  3. Re-Install Gensim

    sudo pip3 install --upgrade gensim

Notes:

  • Instructions above are for systems where pip and apt-get are used to manage packages

  • pip3 is the python3 version of pip

like image 45
user1761806 Avatar answered Nov 20 '22 01:11

user1761806