flutter_torch_mobile icon indicating copy to clipboard operation
flutter_torch_mobile copied to clipboard

Null object reference

Open MarioProjects opened this issue 5 years ago • 0 comments

Thanks for your work!

I tried to use the plugin and got next error Failed to get prediction. Attempt to invoke virtual method 'org.pytorch.IValue org.pytorch.Module.forward(org.pytorch.IValue[])' on a null object reference

I got my model from jit as follows:

traced = torch.jit.trace(net, batch_t.to(DEVICE))
traced.save('model.pt')

MarioProjects avatar Jan 25 '20 10:01 MarioProjects