报错 onnx do_constant_folding Expected all tensors to be on the same device, but found at least two de
·
https://github.com/pytorch/pytorch/issues/72175
https://github.com/pytorch/pytorch/issues/95377
The export only needs to run the model once so performance should not be an issue, and if everything is on the CPU device, then you shouldn’t run into this problem.
方案:network和输入images都放在cpu上,不放在cuda上,导出Onnx只使用cpu
更多推荐

所有评论(0)