From cc6c1e6cd9fb91480e23404126f54b1f6e76a1a5 Mon Sep 17 00:00:00 2001 From: z-khan Date: Tue, 8 Oct 2024 13:01:53 +1100 Subject: [PATCH] add contrib ops to custom op checker context This adds support for Contrib ops that may be used in a custom Step in a pre-post processing pipeline. --- onnxruntime_extensions/tools/pre_post_processing/utils.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/onnxruntime_extensions/tools/pre_post_processing/utils.py b/onnxruntime_extensions/tools/pre_post_processing/utils.py index 2f84fcfcc..edd4e31f9 100644 --- a/onnxruntime_extensions/tools/pre_post_processing/utils.py +++ b/onnxruntime_extensions/tools/pre_post_processing/utils.py @@ -40,7 +40,7 @@ def create_custom_op_checker_context(onnx_opset: int): """ context = onnx.checker.C.CheckerContext() context.ir_version = onnx.checker.DEFAULT_CONTEXT.ir_version - context.opset_imports = {"": onnx_opset, "com.microsoft.extensions": 1} + context.opset_imports = {"": onnx_opset, "com.microsoft.extensions": 1, "com.microsoft": 1} return context