ptrblck:

Is your script also hanging, if you use Python directly or just if you call it in C++ using the bindings?


@ptrblck, It hangs only when I call it from c++ and only for GPU models, CPU models runs fine even with the python bindings. If I call it from python it runs fine for both CPU and GPU models .



 ptrblck:

Just out of curiosity, what’s your use case that you want to call Python from C++ instead of directly loading the model in C++?


we have few  post processing stuffs that are still evolving and needs to be done in python side itself for precipitation of design, and there are few other stuffs in c++ side that need not be implemented in python as they ought to be in c++. So, I just need the predictions from the python file in the form of dictionary, where I can use it in c++ to give the input to other module