I’m trying to convert my network trained in pytorch to libtorch for inference. However, I run into this c++ exception:
There is an unhandled exception at 0x00007FFC58E69709 (located in cp.exe): Microsoft C ++ exception: c10 :: Error at memory location 0x0000008CF9F0F7B0.
Here is a piece of code for testing:
#include  <torch/script.h> 
#include <stdlib.h>
#include <memory>
#include <iostream>
int main() {
	torch::jit::script::Module module = torch::jit::load("F:\ \c.pt");
	std::vector<torch::jit::IValue> input;
    input.push_back (torch::ones({ 36, 9, 64,64 }));
	at::Tenser output = module.forward(input).toTenser();

pytorch1.4 libtorch1.4  VS2019  cpu
why it happened?Maybe the c.pt is wrong?