[ONNX] Remove deprecated functions (#107208)

The usage of some functions is deprecated. This PR drop them.

Pull Request resolved: https://github.com/pytorch/pytorch/pull/107208
Approved by: https://github.com/justinchuby, https://github.com/thiagocrepaldi
This commit is contained in:
wangxiyuan
2023-09-14 19:09:56 +00:00
committed by PyTorch MergeBot
parent 0edb616793
commit 263ca7d69b
9 changed files with 17 additions and 167 deletions

View File

@ -7,7 +7,7 @@ import onnx
import pytorch_test_common
import torch
from pytorch_test_common import skipIfUnsupportedMinOpsetVersion
from torch.onnx import _constants, symbolic_helper, utils
from torch.onnx import _constants, utils
from torch.onnx._internal import jit_utils
from torch.testing._internal import common_utils
@ -41,8 +41,6 @@ def g_op(graph: torch.Graph, op_name: str, *args, **kwargs):
class TestONNXShapeInference(pytorch_test_common.ExportTestCase):
def setUp(self):
self.opset_version = _constants.ONNX_TORCHSCRIPT_EXPORTER_MAX_OPSET
symbolic_helper._set_onnx_shape_inference(True)
symbolic_helper._set_opset_version(self.opset_version)
def run_test(self, g, n, type_assertion_funcs):
if not isinstance(type_assertion_funcs, list):