Open gigasurgeon opened 1 year ago
Have you fixed this error yet? @gigasurgeon
@MhLiao can you help me fix this error
@MhLiao can you help me fix this error
https://github.com/pytorch/pytorch/pull/104067
Try installing PyTorch 2.1.0 with CUDA 11.8, and use argument autograd_inlining=False:
torch.onnx.export(model.model.module, img, self.output_path, input_names=['input'],
output_names=['output'], dynamic_axes=dynamic_axes,
verbose=False, opset_version=12, autograd_inlining=False)
It helps with this error, but there is another one: issue
Here is the solution that worked for me with autograd_inlining=False
option:
https://github.com/open-mmlab/mmagic/issues/63
I am getting this error when I am trying to convert checkpoint to ONNX.
torch version = 1.13.1+cu116
python3 convert_to_onnx.py /vmdata/amitsingh/workspace/z2/DB/experiments/seg_detector/my_custom.yaml /vmdata/amitsingh/workspace/z2/DB/outputs/workspace/DB/SegDetectorModel-seg_detector/deformable_resnet50/L1BalanceCELoss/model/final output.onnx