Closed juntaosun closed 2 weeks ago
Thank you for your attention! You can download the nightly version of pytorch to export the .pth
model to ONNX
format. You can find more details here. However, unfortunately, based on our previous attempts, the GridSample
operation is still not supported by the CPUExecutionProvider
in the latest version of onnxruntime-gpu
, thus inference acceleration might not be possible at this time. @juntaosun
We also attempted to export the model to TRT
format but encountered similar issues. Resolving these problems likely requires expertise in CUDA or model deployment, which is beyond our current capabilities. We hope this clarifies your question :) @juntaosun
Additionally, we hope someone can address this issue, as it would significantly improve the inference speed of the project.
同样导出时遇到了torch.onnx.errors.OnnxExporterError: Unsupported: ONNX export of operator GridSample with 5D volumetric input. 的问题,据说opset_version=20解决了此问题,但更新后,仍然无法导出成功。 torch.onnx.OnnxExporterError: Failed to export the model to ONNX. Generating SARIF report at 'report_dynamo_export.sarif'
We also attempted to export the model to format but encountered similar issues. Resolving these problems likely requires expertise in CUDA or model deployment, which is beyond our current capabilities. We hope this clarifies your question :) @juntaosun
TRT
Additionally, we hope someone can address this issue, as it would significantly improve the inference speed of the project.
@zzzweakman https://github.com/KwaiVGI/LivePortrait/issues/76#issuecomment-2222338382
@aihacker111 motion_extractor.onnx appearance_feature_extractor.onnx
pretrained_weights/ Who can support exporting .pth to onnx ?
pretrained_weights ├── insightface │ └── models │ └── buffalo_l │ ├── 2d106det.onnx │ └── det_10g.onnx └── liveportrait ├── base_models │ ├── appearance_feature_extractor.pth 👈✅ │ ├── motion_extractor.pth 👈✅ │ ├── spade_generator.pth 👈 │ └── warping_module.pth 👈 ├── landmark.onnx └── retargeting_models └── stitching_retargeting_module.pth 👈
I encountered some errors are: OnnxExporterError: Unsupported: ONNX export of operator GridSample with 5D volumetric input. Unable to complete export~