sony / nnabla

Neural Network Libraries
https://nnabla.org/
Apache License 2.0
2.73k stars 334 forks source link

Precompilated Library C/C++-Api #676

Open Armin234 opened 4 years ago

Armin234 commented 4 years ago

Hi, are there precompilated libs of the C/C++API for Windows ?

TomonobuTsujikawa commented 3 years ago

Hi, There is no precompiled libraries now, but we will consider releasing libraries. I will let you know when it is released.

TomonobuTsujikawa commented 3 years ago

We're very sorry for late notice. There is pre-compiled libraries including Windows platform.

https://nnabla.org/install/#cpplib_list

Please use a library that matches the version of nnabla.

Armin234 commented 3 years ago

Hi, thanks for the precompiled libraries. I already tryed your c++ example with the precompiled "nnabla-cpplib-1.20.1-win64.zip", but at the line

nbla::Context cpu_ctx{ {"cpu:float"}, "CpuCachedArray", "0" };

I get always an "std::bad_alloc" exception, and I have no idea what's the problem ?

TomonobuTsujikawa commented 3 years ago

Thank you for checking, and we're sorry that it doesn't work properly. We will confirm in some environment, please let us some time.

Armin234 commented 3 years ago

Hi TomonobuTsujikawa, I made some more test and it seems to have to do with the "Debug Mode" I used in Visual Studio. When I compile my application in "Release Mode" the exception didn't appear.

TomonobuTsujikawa commented 3 years ago

Thank you for checking this issue! We found that STL container does not pass correctly from cpplib to python on debug mode. On our environment, access violation is occurred in _cpu_array_classes().

Please let us consider how we can overcome this issue (or workaround).