Torch::save and torch::load compilation errors - no overloaded operator definition

The solution is here from mhubi (builds but I haven’t tested it):

The key here is inclusion of TORCH_MODULE(Net). See example.