[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Library for matrix operations? (eigenvalues, pseudoinverse)
From: |
Vasil Velichkov |
Subject: |
Re: Library for matrix operations? (eigenvalues, pseudoinverse) |
Date: |
Thu, 6 Feb 2020 20:37:39 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.2.2 |
Hi Laura,
On 06/02/2020 20.16, Laura Arjona wrote:
> Whenever I try to use the *pinv* function inside my OOT block, I get the
> error : *AttributeError: 'module' object has no attribute 'cca_update'*
> I just comment the line about the pinv, and no error appears.
One of the possible reasons for this error is that you are not linking the
library where the pinv function is implemented.
> *CMakeLists.txt file in my OOT Module*
> ########################################################################
> # Find gnuradio build dependencies
> ########################################################################
> find_package(BLAS REQUIRED)
> find_package(LAPACK REQUIRED)
> message(STATUS "LAPACK libraries: ${LAPACK_LIBRARIES}")
> message(STATUS "BLAS libraries: ${BLAS_LIBRARIES}")
> find_package(Armadillo)
You need to link the LAPACK and/or BLAS libraries to your OOT module. In
lib/CMakeLists.txt you should have something like
target_link_libraries(<oot_module_name> ${LAPACK_LIBRARIES}
${BLAS_LIBRARIES} ...)
Replace <oot_module_name> with the name of your OOT module.
And after rebuilding make sure there are not undefined symbols in the shared
objects
ldd -r build/lib/lib*.so
ldd -r build/swig/*_swig.so
Regards,
Vasil