Attempting to install PythonBiogeme: ModuleNotFoundError: No module named 'unidecode'

615 views
Skip to first unread message

alex mitrani

unread,
Jan 14, 2019, 9:03:20 AM1/14/19
to Biogeme
Dear Prof. Bierlaire and other Biogeme users

I have been trying to install Pandas Biogeme on a Windows 7 computer (64 bit), and I get the following error:  

 

(base) C:\WINDOWS\system32>pip install biogeme

Collecting biogeme

  Downloading https://files.pythonhosted.org/packages/ba/b4/b18fb360c278ea95070dd71c9c6ce2b27bbd569d39857241f25e5ade2d9d/biogeme-3.1.0.tar.gz (116kB)

    100% |████████████████████████████████| 122kB 1.6MB/s

    Complete output from command python setup.py egg_info:

    Using Cython

    Warning: passing language='c++' to cythonize() is deprecated. Instead, put "# distutils: language=c++" in your .pyx or .pxd file(s)

    Compiling src/cbiogeme.pyx because it depends on C:\ProgramData\Anaconda3\lib\site-packages\Cython\Includes\numpy\__init__.pxd.

    [1/1] Cythonizing src/cbiogeme.pyx

    C:\ProgramData\Anaconda3\lib\site-packages\Cython\Compiler\Main.py:367: FutureWarning: Cython directive 'language_level' not set, using 2 for now (Py2). This will change in a later release! File: C:\Users\NELSON~1.ADM\AppData\Local\Temp\pip-install-2cz3uqwa\biogeme\src\cbiogeme.pyx

      tree = Parsing.p_module(s, pxd, full_module_name)

    Traceback (most recent call last):

      File "<string>", line 1, in <module>

      File "C:\Users\NELSON~1.ADM\AppData\Local\Temp\pip-install-2cz3uqwa\biogeme\setup.py", line 117, in <module>

        exec(open("biogeme/version.py").read())

      File "<string>", line 2, in <module>

    ModuleNotFoundError: No module named 'unidecode'

 

    ----------------------------------------

Command "python setup.py egg_info" failed with error code 1 in C:\Users\NELSON~1.ADM\AppData\Local\Temp\pip-install-2cz3uqwa\biogeme\

 


I am stuck.  Please could you help me get unstuck?  I attach a more detailed session log in case this is of any use.  

I look forward to your reply.  

Kind regards

Alex Mitrani
pandasbiogeme_install_attempt.txt

Michel Bierlaire

unread,
Jan 14, 2019, 9:06:58 AM1/14/19
to alex.m...@gmail.com, Michel Bierlaire, Biogeme
As mentioned in the video, the compiled version of biogeme for windows is available for python 3.7. 

If you want to build it from source, you need to know what you are doing. In particular, you need a compiling environment on your computer. 

Anyway, in this case, as explicitly said in the errors, it appears that the package unidecode is not present. You need to install it first using
pip install unidecode. 




--
You received this message because you are subscribed to the Google Groups "Biogeme" group.
To unsubscribe from this group and stop receiving emails from it, send an email to biogeme+u...@googlegroups.com.
To post to this group, send email to bio...@googlegroups.com.
Visit this group at https://groups.google.com/group/biogeme.
For more options, visit https://groups.google.com/d/optout.
<pandasbiogeme_install_attempt.txt>

alex mitrani

unread,
Jan 14, 2019, 9:47:25 AM1/14/19
to Michel Bierlaire, Biogeme
Many thanks for your prompt and helpful response.  That has successfully got me unstuck.  I created a Python 3.7 environment in Anaconda and then opened the terminal within that environment to do the installation.  This time the installation went smoothly.  I didn't even require special permissions.  

Thanks again

Alex

Reply all
Reply to author
Forward
0 new messages