I’ve successfully used torch.jit.trace to export 2 of my Conv models to C++ (using LibTorch), and they both work perfectly. Now I’m trying to do the same with my third model, which is an RNN (BiDirectional LSTM), and it always gives the EXACT same output from my C++ code. No matter what inputs I give it, I always get the exact same output.
Any ideas what’s going on here? Is there some kind of special initialization/reset that one has to do on an RNN model from C++?