diff --git a/python/tvm/relay/backend/graph_runtime_codegen.py b/python/tvm/relay/backend/graph_runtime_codegen.py index e31b44df81ba..0409c8dd7390 100644 --- a/python/tvm/relay/backend/graph_runtime_codegen.py +++ b/python/tvm/relay/backend/graph_runtime_codegen.py @@ -365,14 +365,14 @@ def nested_defaultdict(): metadata['signatures']['default']['outputs'][node_name]['shape'] = shapes[node_id[0]] # Keep 'metadata' always at end - json_dict = OrderedDict({ - "nodes": nodes, - "arg_nodes": arg_nodes, - "heads": heads, - "attrs": attrs, - "node_row_ptr": node_row_ptr, - "metadata": metadata - }) + json_dict = OrderedDict([ + ("nodes", nodes), + ("arg_nodes", arg_nodes), + ("heads", heads), + ("attrs", attrs), + ("node_row_ptr", node_row_ptr), + ("metadata", metadata), + ]) return json.dumps(json_dict, indent=2)