[C++ API] Disable model validity check #5676
-
Hi everyone. I've got an onnx file that i custumized by adding some non standard attributes to some of the model's nodes. I can open it without any problem with the onnx python module (of course, onnx.checker.check_model raises an error but i can explore the model), but i can't even create a session with ORT, i've got the "Unrecognized attribute" error. I was wondering if by any chance, there was a way to disable the automatic validity check when creating a session ? Thanks a lot. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
Is it an attribute with no impact on the operator definition? If that's the case, the attribute doc_string would be better. onnxruntime checks that an operator description is compliant with the standard it implements. On the other hand, if you plan to create a new operator with a new kernel, I suggest looking into the page https://onnxruntime.ai/docs/reference/operators/add-custom-op.html. |
Beta Was this translation helpful? Give feedback.
Is it an attribute with no impact on the operator definition? If that's the case, the attribute doc_string would be better. onnxruntime checks that an operator description is compliant with the standard it implements. On the other hand, if you plan to create a new operator with a new kernel, I suggest looking into the page https://onnxruntime.ai/docs/reference/operators/add-custom-op.html.