auralius/kalman-cpp

LAPACK use

gacamilo opened this issue · 8 comments

While trying to use the library with larger matrices I ran into this error:
image

I've tried replacing the armadillo dependency with a system installed version, tried modifying the armadillo config.hpp header with #define ARMA_USE_LAPACK - but no matter what I try the error keeps happening. Have you ran into this issue before? Any suggestions?

p.s. I am by no means a cpp expert so I apologise if it turns out that this has nothing to do with your library.

Are you using Windows? Can you check the last commit that I just pushed? I would suggest a fresh clone and don't forget to extract the windows-libs-2019.zip file that is inside the windows-lib folder.

Working with these open-source libs in Windows is always very tricky. I have added demo0 for the LAPACK test. Make sure this works. I have modified config.hpp in the armadillo. Additionally, I have updated the configurations of all project files in the solution.

Please let me know again. Thanks.

Yeah, I am using Windows.

The fresh clone with the new commit doesn't seem to be working at all anymore. Before I was able to build the solution and run all demos. Now I am able to build the solution but when I try to run the demos I get the following error:

image

Happens for both x64 and x86 builds.

This is because, in Visual Studio, you have to select the startup project. Currently, it is set to "kalman-cpp" project. You can see it is bolded in the solution explorer. "kalman-cpp" is a library and can not be executed. Try to right-click on one of the demos (I suggest trying "demo0" to see if ATLAS is now working) and then select "Set as Startup Project". After that, you can run it as usual. That is basically how you select an active project in Visual Studio.

Oh nice, it works now! No LAPACK errors either.

Thank you so much!

I just ran into another problem actually - in isolation I was able to use LAPACK and kalman-cpp.lib to solve the larger problem I was attempting before. However, upon integration into my application instantiating a KF object raises the following error at runtime:

image

The error is associated to ntdll.dll

image

No idea what this has to do with kalman-cpp.lib but the issue only occurs when I try to instantiate a KF object. Any idea what might be causing this?

I have never had this issue.

There are only 2 DLL files that are needed: liblapack.dll and libopenblas.dll. They can be found in the bin folder. Make sure that your executable files are in the same location as these two DLLs.

Another possibility, only x64 configuration works. This is because the openblas and lapack libs are precompiled. I was thinking the era of Win32 is over. I used to provide the 32-bit version as well but I have removed all 32-bit libs. Can you please check that your configuration is x64?

Yes, I'm using x64.

I'm not sure what changed on the previous commit apart from the new naming of the dlls and the addition of cbia.lib - but it works. Instead of the weird ntdll.dll error I was getting before, I had to add three other dependencies related to intel compilers:

image

Again, I'm not sure what these are needed for but I had to add them to run the demos and into my application which works well now (no more ntdll.dll errors). I tested on two machines and had to add these dependencies in both - could be worth adding them to the repo?

Thank you!

Thanks for the information.

I am glad everything works now. The new commit includes precomplied atlas and blas. No more openblas.

The dependency on Intel stuffs is probably because of the precompiled atlas and blas. I will put in the readme: if similar things happen, the solution is to install the intel redistributable libs. I think I can find the link in the internet.

I am worried about the license if we put them into the repositories.

Thanks!