From 3becefa218aab6f662202152d47eae4dc7ec7ed8 Mon Sep 17 00:00:00 2001 From: George Hotz Date: Fri, 24 Feb 2023 09:27:18 -0800 Subject: [PATCH] fix onnx tests --- extra/onnx_ops.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/extra/onnx_ops.py b/extra/onnx_ops.py index 851ed21e8c..8137e66b45 100644 --- a/extra/onnx_ops.py +++ b/extra/onnx_ops.py @@ -19,7 +19,8 @@ def Gemm(A, B, C=None, alpha=1.0, beta=1.0, transA=0, transB=0): return ret # TODO: this is copied from tinygrad/nn/__init__.py -def BatchNormalization(X, scale, B, input_mean, input_var, epsilon=1e-05, momentum=0.9, training_mode=0): +# spatial is from opset 7 and has since been removed +def BatchNormalization(X, scale, B, input_mean, input_var, epsilon=1e-05, momentum=0.9, training_mode=0, spatial=1): if training_mode: x_detached = X.detach() current_mean = x_detached.mean(axis=(0,2,3))