ONNX conversion failed for text detector - DB++ #14627
Replies: 2 comments
-
The error you encountered during the ONNX conversion for the DB++ text detector model arises due to certain operators in the model requiring ONNX opset versions greater than 18, specifically for the 1. Upgrade Dependency for Higher Opset Support
If no updates are yet available:
2. Replace or Simplify Unsupported OperatorsIf the
3. Quantization Workaround (If Applicable)In some cases, using quantized models with dynamic post-quantization can simplify operator graphs and reduce opset version requirements. Follow these steps:
Caveat: Quantization may degrade model performance slightly. Verify the inference results to ensure they meet your requirements. 4. Export with Paddle Inference or TensorRTIf ONNX conversion is not strictly necessary for your deployment pipeline, consider using Paddle Inference or TensorRT directly:
5. Alternative ToolsIf Paddle2ONNX cannot meet your requirements, explore alternative tools that might support opset 19 or higher:
References
ConclusionYour best options are:
If you need further clarification or assistance, feel free to ask! Response generated by feifei-bot | chatgpt-4o-latest |
Beta Was this translation helpful? Give feedback.
-
@VishyAnand28 Did you solve the problem? |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Dear Paddle Community,
I was able to use Paddle2ONNX from here:https://github.com/PaddlePaddle/PaddleOCR/blob/main/docs/ppocr/infer_deploy/paddle2onnx.en.md to convert text detector method DB (Differentiable Binarization). But the conversion fails for DB++ (Differentiable Binarization with ASF).
Problem: Currently Opset versions of 7-18 are supported. How to overcome this issue? Any other ways to convert it?
Following is the error message:
[Paddle2ONNX] Start to parse PaddlePaddle model...
[Paddle2ONNX] Model file path: C:/Users/db++_trained\inference.pdmodel
[Paddle2ONNX] Parameters file path: C:/Users/04_db++_trained\inference.pdiparams[Paddle2ONNX]
Start to parsing Paddle model...
[Paddle2ONNX] [reduce_mean: mean_0.tmp_0] Requires the minimal opset version of 11.
[Paddle2ONNX] Due to the operator: deformable_conv, requires opset_version >= 19.
[Paddle2ONNX] The Opset Version must be between 7 and 18
[Paddle2ONNX] Opset version will change to 19 from 11
[ERROR] Due to opset version, the model exporting is aborted.
Thanks for reading this!
I humbly request guidance from @GreatV @WenmuZhou @LDOUBLEV @MissPenguin @tink2123 @UserWangZz and others ........ for guidance.
Beta Was this translation helpful? Give feedback.
All reactions