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

Reply via email to