-
Hi all, I am working on a project using 3D EfficientNet-b0 to classifiy (32x32x32) patches CT scans. My next step is to use the saved model in a C++ script. For that, I am tracing my model :
After the tracing I load it back in my C++ script using :
When it comes to this line I have I verified if "traced_model.pt" model was behaving the same way as "best_metric.pth" and everything is normal. What am I missing ? |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 2 replies
-
Hi @ericspod , Have you seen this TorchScript related issue before? Thanks in advance. |
Beta Was this translation helpful? Give feedback.
-
I have not seen an error like this before, it's obviously hard to trace where it's coming from being a C++ exception. Would it be possible to test this under some Linux distro? Iy may be a specific Windows error. |
Beta Was this translation helpful? Give feedback.
-
Quick update for anyone facing this issue ^^ |
Beta Was this translation helpful? Give feedback.
Quick update for anyone facing this issue ^^
The problem came from the libtorch library that I was using (1.8.1) you need to at least have libtorch 1.9.0 to use the model EfficientNet on C++.