From 548675fddcf9e2ad7203fc7610189d0e94e68bc6 Mon Sep 17 00:00:00 2001 From: AndrewZhaoLuo Date: Wed, 8 Sep 2021 22:56:02 -0700 Subject: [PATCH] [EZ] [ONNX] Remove unnecessary converters for greater and lesser (#8967) * simplify by removing unneeded conversions * remove uneeded * remove test Co-authored-by: Andrew Zhao Luo --- python/tvm/relay/frontend/onnx.py | 20 ++------------------ 1 file changed, 2 insertions(+), 18 deletions(-) diff --git a/python/tvm/relay/frontend/onnx.py b/python/tvm/relay/frontend/onnx.py index 48a5b48b37d3..2aba807c009f 100644 --- a/python/tvm/relay/frontend/onnx.py +++ b/python/tvm/relay/frontend/onnx.py @@ -1611,22 +1611,6 @@ def _impl_v9(cls, inputs, attr, params): return _op.scatter_nd(zeros, _op.stack([indices, indices + k], axis=0), ones, "update") -class Greater(OnnxOpConverter): - """Operator logical greater.""" - - @classmethod - def _impl_v7(cls, inputs, attr, params): - return _op.greater(inputs[0], inputs[1]) - - -class Less(OnnxOpConverter): - """Operator logical less than.""" - - @classmethod - def _impl_v7(cls, inputs, attr, params): - return _op.less(inputs[0], inputs[1]) - - class LRN(OnnxOpConverter): """Operator converter for Local Response Normalization.""" @@ -3655,8 +3639,8 @@ def _get_convert_map(opset): "Selu": Selu.get_converter(opset), "Elu": Elu.get_converter(opset), "Exp": Renamer("exp"), - "Greater": Greater.get_converter(opset), - "Less": Less.get_converter(opset), + "Greater": Renamer("greater"), + "Less": Renamer("less"), "Log": Renamer("log"), "Acos": Renamer("acos"), "Acosh": Renamer("acosh"),