RicherMans / PLDA

An LDA/PLDA estimator using KALDI in python for speaker verification tasks
99 stars 24 forks source link

error during compilation #1

Closed rohithkodali closed 8 years ago

rohithkodali commented 8 years ago

hi,

i'm trying to follow the installation procedure but when i try "make" it is throwing some errors like

/home/rohit/speech/development/speaker_verification/PLDA/src/kaldi-utils.hpp:101:26: error: 'PyArrayObject' has no member named 'dimensions'

/home/rohit/speech/development/speaker_verification/PLDA/src/kaldi-utils.hpp:101:26: error: 'PyArrayObject' has no member named 'desc'

etc, there are some other issues like this, i don't think these are because of ATLAS, is there anyway to solve it and my numpy is of updated version

RicherMans commented 8 years ago

Can you provide the whole output of your make? I'm pretty certain it's numpy/ scipy.

rohithkodali commented 8 years ago

here is the complete make log log.txt

RicherMans commented 8 years ago

Alright, you dont run the script in an venv, do you? Otherwise could you check for ndarraytypes.h just run something like locate ndarraytypes.h | head -n 1 | xargs cat | grep "dimensions"

That should find the dimensions attribute in the pyarrayobject. If that doesn't please check if you still have multiple installations of numpy. Lastly make sure its python 2.7 youre compiling with

rohithkodali commented 8 years ago

i use a ubuntu desktop not a virtual env and i use python 2.7

the output for above command is

RicherMans commented 8 years ago

I'm pretty sure its your numpy installation. Try to either pip remoev and install or use apt-get for that. If that is failing try to build it using cmake -LAH and check the PYTHON_EXECUTABLE and NUMPY_INCLUDE_DIRS variables. Lastly try to set the NUMPY_INCLUDE_DIRS manually by export NUMPY_INCLUDE_DIRS=YOURPATHTO/INCLUDE/DIRS I'm sorry, I'm unfamiliar with the find Numpy/ Python cmakes that are provided by Cmake itself.

rohithkodali commented 8 years ago

it worked with reinstalling numpy and scipy, thanks a lot.

is there any complete script to use this with kaldi available now?

RicherMans commented 8 years ago

Well partially, I wrote a script used for some of my tasks, which is just pushed to the repository. You can find it in the scoring/ directory. That gives a quick introduction to the PLDA.

Btw since there is not a big documentation about Numpy arrays in C++, please always use uint labels and float data vectors, otherwise the script will malfunction.