We have a successful build of Pytorch from the source code on Windows with APL. But while trying to use we are getting errors such as:
RuntimeError: svd: LAPACK library not found in compilation.
Can you point me to the right direction of understanding the problem? We followed the Windows guidelines but maybe we are not linking something correctly or not linking at all.
We actually added APL as a BLAS option, so I use BLAS=APL and have this cmake file for linking purposes.
Hi,
In that case you could try adding a case for "APL"` in the `FindLAPACK.cmake` file - https://github.com/iremyux/pytorch/blob/run-test-apl-results/cmake/Modules/FindLAPACK.cmake too.Cheers,
Nathan.
Hi,One more thing to check - are you setting `USE_LAPACK=1` for the build (see the cmake build line in the Linux example linked to above (github.com/.../build-pytorch.sh),
Cheers,
Thanks a lot for your answer. I realized that and built again setting USE_LAPACK to 1. The error did not disappear.
On CMakeCache, I can see this variable as :
//No help, variable specified on the command line.USE_LAPACK:UNINITIALIZED=1
Is USE_LAPACK really defined and being used?
I think that's just telling you it has been set at the command line? it doesn't confirm that it's being used (or not) anywhere. `UNINITIALIZED` is the type, which is unspecified if you use `-DUSE_LAPACK=1`. You can set a type (the syntax is `-D MY_CMAKE_COMMAND:<type>=<value>`) but you don't need to, CMake is not strongly typed.It sounds like you need to make FindLAPACK.cmake aware of the "APL" BLAS option you've added, so that when it checks for LAPACK support (by looking for an LAPACK symbol in the supplied BLAS binary) at compile time, it knows to look in the Arm PL binary, and confirms that it has LAPACK symbols.
Hi Nathan, thanks a lot for the reply, we were not aware of those and it seems to be working now.
Great stuff, glad to hear it! Thanks for letting me know.