facebookresearch / libri-light

dataset for lightly supervised training using the librivox audio book recordings. https://librivox.org/.
MIT License
479 stars 78 forks source link

ABX_src is not compiling correctly #29

Closed bmilde closed 4 years ago

bmilde commented 4 years ago

I tried to compile ABX_src inplace as explained in the doc, but I get:

(libri-light) milde@ltgpu2:/raid/milde/libri-light/eval/ABX_src$ python setup.py build_ext --inplace
running build_ext
building 'ABX_src.dtw' extension
gcc -pthread -B /srv/home/milde/anaconda3/envs/libri-light/compiler_compat -Wl,--sysroot=/ -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -I/srv/home/milde/anaconda3/envs/libri-light/include/python3.7m -c dtw.c -o build/temp.linux-x86_64-3.7/dtw.o
dtw.c:611:10: fatal error: numpy/arrayobject.h: No such file or directory
 #include "numpy/arrayobject.h"
          ^~~~~~~~~~~~~~~~~~~~~
compilation terminated.
error: command 'gcc' failed with exit status 1

When I manually change:

setup(
    include_dirs=[numpy.get_include()],
    ext_modules=cythonize("dtw.pyx")
)

in setup.py it works and finds the numpy headers correctly.

Molugan commented 4 years ago

Sorry for the delay. Let me have a closer look at that.

bmilde commented 4 years ago

PER_src also is not compiling correctly, the fix is the same, you need to include the numpy include