From 6084f59ee0a8654dca2f6c0d5b7bfdff2083ca8e Mon Sep 17 00:00:00 2001 From: Yaman Umuroglu Date: Fri, 5 Apr 2024 13:36:37 +0200 Subject: [PATCH] Set default values for padding in NHWC pool ops --- src/qonnx/custom_op/general/maxpoolnhwc.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/qonnx/custom_op/general/maxpoolnhwc.py b/src/qonnx/custom_op/general/maxpoolnhwc.py index d2419813..71f184f1 100644 --- a/src/qonnx/custom_op/general/maxpoolnhwc.py +++ b/src/qonnx/custom_op/general/maxpoolnhwc.py @@ -53,7 +53,7 @@ def get_nodeattr_types(self): # https://github.com/onnx/onnx/blob/main/docs/Operators.md#MaxPool return { "kernel_shape": ("ints", True, []), - "pads": ("ints", True, []), + "pads": ("ints", False, [0, 0, 0, 0]), "strides": ("ints", True, []), "ceil_mode": ("i", False, 0), } @@ -128,7 +128,7 @@ def get_nodeattr_types(self): # https://github.com/onnx/onnx/blob/main/docs/Operators.md#AveragePool return { "kernel_shape": ("ints", True, []), - "pads": ("ints", True, []), + "pads": ("ints", False, [0, 0, 0, 0]), "strides": ("ints", True, []), "ceil_mode": ("i", False, 0), }