diff --git a/onnx_tf/backend.py b/onnx_tf/backend.py index d47c6c7c..06574425 100644 --- a/onnx_tf/backend.py +++ b/onnx_tf/backend.py @@ -292,8 +292,8 @@ def tensor2list(onnx_tensor): return numpy_helper.to_array(onnx_tensor).flatten().tolist() def validate_initializer_name(name): - # Prepend a unique suffix if leading charater is "_" - name = get_unique_suffix() + name if name[0] is "_" else name + # Prepend a unique suffix if leading character is "_" + name = get_unique_suffix() + name if name[0] == "_" else name # Replace ":" with "_tf_" and append a unique suffix for # traceability