Skip to content

Commit 896dbb2

Browse files
committed
review feedback, use constants.ONNX_DOMAIN
1 parent 71e34df commit 896dbb2

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

tf2onnx/handler.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,13 +11,15 @@
1111
import collections
1212
import inspect
1313

14+
from tf2onnx import constants
15+
1416
# pylint: disable=unused-argument,missing-docstring,invalid-name
1517

1618
class tf_op:
1719
_OPSETS = collections.OrderedDict()
1820
_MAPPING = None
1921

20-
def __init__(self, name, domain="onnx", **kwargs):
22+
def __init__(self, name, domain=constants.ONNX_DOMAIN, **kwargs):
2123
if not isinstance(name, list):
2224
name = [name]
2325
self.name = name
@@ -54,7 +56,7 @@ def get_opsets():
5456

5557
@staticmethod
5658
def create_mapping(max_opset, extra_opsets):
57-
mapping = {"onnx": max_opset}
59+
mapping = {constants.ONNX_DOMAIN: max_opset}
5860
if extra_opsets:
5961
for extra_opset in extra_opsets:
6062
mapping[extra_opset.domain] = extra_opset.version

0 commit comments

Comments
 (0)