MTG / essentia

C++ library for audio and music analysis, description and synthesis, including Python bindings
http://essentia.upf.edu
GNU Affero General Public License v3.0
2.8k stars 525 forks source link

Unable to import NumPy C API from Essentia Python module #824

Open ucasiggcas opened 5 years ago

ucasiggcas commented 5 years ago

Dear, After installation withpip3 install essentia on Ubuntu18.04, When I import essentia Error ups: Unable to import NumPy C API from Essentia module.Error code =-1 Traceback(most recent call last): File"",line 1,in File"/home/path/python3.6/site-packages/essentia/init.py",line 1,in from . import _essentia ImportError:numpy.core.multiarray failed to import

How to solve the question? Could U help me? Thx

dbogdanov commented 5 years ago

Just in case, your error message states "numpu.core.multiarray", not "multiarry", right?

ucasiggcas commented 5 years ago

Just in case, your error message states "numpy.core.multiarray", not "multiarry", right?

Yes, What I write is right Could U help me? Please Thx

dbogdanov commented 5 years ago

Cannot reproduce this error on a fresh Ubuntu 18.04 image in Docker. For some reason, your installation tries to import numpy.core.multiarry instead of numpy.core.multiarray, and therefore you get this error.

ucasiggcas commented 5 years ago

Cannot reproduce this error on a fresh Ubuntu 18.04 image in Docker. For some reason, your installation tries to import numpy.core.multiarry instead of numpy.core.multiarray, and therefore you get this error.

Sorry, Just a mistake, You can see the pic down image

Now,You can find the question, Thx

ucasiggcas commented 5 years ago

HELP SOS

dbogdanov commented 5 years ago

Make sure your numpy version is >=1.8.2 (pip install -U numpy to upgrade).

ucasiggcas commented 5 years ago

Dear, You can see the picture image I don't know what happened. Could U help me? Thx

dbogdanov commented 5 years ago

Are you still having this problem with the latest Essentia Python wheels?

ucas010 commented 4 years ago

hi, I install the module error in windows10 image could you help me ? thx

ucas010 commented 4 years ago
    → configuring the project in C:\Users\ggca1\AppData\Local\Temp\pip-install-3foyj7a7\essentia
    → Building in release mode
    Building on win32
    Checking for 'msvc' (C++ compiler)       : not found
    Checking for 'g++' (C++ compiler)        : not found
    Checking for 'clang++' (C++ compiler)    : not found
    could not configure a C++ compiler!
    (complete log in C:\Users\ggca1\AppData\Local\Temp\pip-install-3foyj7a7\essentia\build\config.log)
    The project was not configured: run "waf configure" first!
    The project was not configured: run "waf configure" first!
    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "C:\Users\ggca1\AppData\Local\Temp\pip-install-3foyj7a7\essentia\setup.py", line 137, in <module>
        'install_lib': EssentiaInstall
      File "d:\python36\lib\site-packages\setuptools\__init__.py", line 144, in setup
        return distutils.core.setup(**attrs)
      File "d:\python36\lib\distutils\core.py", line 148, in setup
        dist.run_commands()
      File "d:\python36\lib\distutils\dist.py", line 955, in run_commands
        self.run_command(cmd)
      File "d:\python36\lib\distutils\dist.py", line 974, in run_command
        cmd_obj.run()
      File "d:\python36\lib\site-packages\setuptools\command\install.py", line 61, in run
        return orig.install.run(self)
      File "d:\python36\lib\distutils\command\install.py", line 545, in run
        self.run_command('build')
      File "d:\python36\lib\distutils\cmd.py", line 313, in run_command
        self.distribution.run_command(command)
      File "d:\python36\lib\distutils\dist.py", line 974, in run_command
        cmd_obj.run()
      File "d:\python36\lib\distutils\command\build.py", line 135, in run
        self.run_command(cmd_name)
      File "d:\python36\lib\distutils\cmd.py", line 313, in run_command
        self.distribution.run_command(command)
      File "d:\python36\lib\distutils\dist.py", line 974, in run_command
        cmd_obj.run()
      File "C:\Users\ggca1\AppData\Local\Temp\pip-install-3foyj7a7\essentia\setup.py", line 54, in run
        library = glob.glob('tmp/lib/python*/*-packages/essentia')[0]
    IndexError: list index out of range
    ----------------------------------------
ERROR: Command errored out with exit status 1: 'd:\python36\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\ggca1\\AppData\\Local\\Temp\\pip-install-3foyj7a7\\essentia\\setup.py'"'"'; __file__='"'"'C:\\Users\\ggca1\\AppData\\Local\\Temp\\pip-install-3foyj7a7\\essentia\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record 'C:\Users\ggca1\AppData\Local\Temp\pip-record-o250lt2j\install-record.txt' --single-version-externally-managed --compile --install-headers 'd:\python36\Include\essentia' Check the logs for full command output.