Hi, I’m using libtorch 1.7.1, but that shouldn’t really matter. As for code, you can take this simple MNIST example 1 and add the line of code above to save the model. It won’t compile.
In any case, that’s not the point of the ticket. I know how to export a model in libtorch (serializing to OutputArchive, etc), but I cannot load that model in Python. The problem I’m trying to solve is how to export a model in libtorch that can be loaded in Python.