提交 ad779f4e 编写于 作者: O ougongchang

set the parameter output data type

上级 1491de23
...@@ -15,6 +15,8 @@ ...@@ -15,6 +15,8 @@
""" """
This file is used to define the basic graph. This file is used to define the basic graph.
""" """
import time
from enum import Enum from enum import Enum
from collections import defaultdict from collections import defaultdict
...@@ -52,6 +54,8 @@ class Graph: ...@@ -52,6 +54,8 @@ class Graph:
def build_graph(self, proto_data): def build_graph(self, proto_data):
"""This method is used to build the graph.""" """This method is used to build the graph."""
logger.info("Start to build graph")
start_time = time.time()
# Notice: # Notice:
# The following methods are interdependent and cannot be switched at will. # The following methods are interdependent and cannot be switched at will.
...@@ -65,6 +69,12 @@ class Graph: ...@@ -65,6 +69,12 @@ class Graph:
self._add_variable_nodes(NodeTypeEnum.CONST.value) self._add_variable_nodes(NodeTypeEnum.CONST.value)
self._calc_subnode_count() self._calc_subnode_count()
precision = 6
time_consuming = round(time.time() - start_time, precision)
logger.info("Build graph end, all node count: %s, const count: %s, parameter count: %s, time-consuming: %s s.",
self.normal_node_count, len(self._const_node_temp_cache),
len(self._parameter_node_temp_cache), time_consuming)
def exist_node(self, name): def exist_node(self, name):
""" """
Check node exist in graph. Check node exist in graph.
......
...@@ -13,8 +13,6 @@ ...@@ -13,8 +13,6 @@
# limitations under the License. # limitations under the License.
# ============================================================================ # ============================================================================
"""This file is used to define the MindSpore graph.""" """This file is used to define the MindSpore graph."""
import time
from mindinsight.datavisual.common.log import logger from mindinsight.datavisual.common.log import logger
from mindinsight.datavisual.proto_files.mindinsight_anf_ir_pb2 import DataType from mindinsight.datavisual.proto_files.mindinsight_anf_ir_pb2 import DataType
from mindinsight.datavisual.common.enums import PluginNameEnum from mindinsight.datavisual.common.enums import PluginNameEnum
...@@ -27,24 +25,6 @@ from .graph import EdgeTypeEnum ...@@ -27,24 +25,6 @@ from .graph import EdgeTypeEnum
class MSGraph(Graph): class MSGraph(Graph):
"""The object describes the MindSpore graph, and it is defined in the anf_ir proto file.""" """The object describes the MindSpore graph, and it is defined in the anf_ir proto file."""
def build_graph(self, proto_data):
"""
Build graph by graph proto which refer to `anf_ir_pb2.GraphProto`.
Args:
proto_data (anf_ir_pb2.GraphProto): Refer to `anf_ir_pb2.GraphProto`.
"""
logger.info("Start to build graph, graph name: %s.", proto_data.name)
start_time = time.time()
super(MSGraph, self).build_graph(proto_data)
precision = 6
time_consuming = round(time.time()-start_time, precision)
logger.info("Build graph end, all node count: %s, const count: %s, parameter count: %s, time-consuming: %s s.",
self.normal_node_count, len(self._const_node_temp_cache),
len(self._parameter_node_temp_cache), time_consuming)
def _parse_data(self, proto_data): def _parse_data(self, proto_data):
""" """
The proto data is parsed and all nodes are stored in the specified structure. The proto data is parsed and all nodes are stored in the specified structure.
...@@ -85,8 +65,6 @@ class MSGraph(Graph): ...@@ -85,8 +65,6 @@ class MSGraph(Graph):
node_name = node_proto.full_name node_name = node_proto.full_name
node = Node(name=node_name, node_id=node_proto.name) node = Node(name=node_name, node_id=node_proto.name)
node.type = node_proto.op_type node.type = node_proto.op_type
logger.debug("Foreach graph proto nodes, node id: %s, node name: %s, node def name: %s, "
"input count: %s", node.node_id, node.name, node_proto.name, len(node_proto.input))
self._parse_attributes(node_proto.attribute, node) self._parse_attributes(node_proto.attribute, node)
self._parse_inputs(node_proto.input, node) self._parse_inputs(node_proto.input, node)
...@@ -112,6 +90,7 @@ class MSGraph(Graph): ...@@ -112,6 +90,7 @@ class MSGraph(Graph):
continue continue
node = Node(name=parameter.name, node_id=parameter.name) node = Node(name=parameter.name, node_id=parameter.name)
node.type = NodeTypeEnum.PARAMETER.value node.type = NodeTypeEnum.PARAMETER.value
node.output_data_type = self._get_data_type_by_parse_type_proto(parameter.type)
node.output_shape = self._get_shape_by_parse_type_proto(parameter.type) node.output_shape = self._get_shape_by_parse_type_proto(parameter.type)
attr = dict( attr = dict(
type=self._get_data_type_by_parse_type_proto(parameter.type), type=self._get_data_type_by_parse_type_proto(parameter.type),
...@@ -237,7 +216,7 @@ class MSGraph(Graph): ...@@ -237,7 +216,7 @@ class MSGraph(Graph):
if attr.value.ByteSize() > self.MAX_NODE_ATTRIBUTE_VALUE_BYTES: if attr.value.ByteSize() > self.MAX_NODE_ATTRIBUTE_VALUE_BYTES:
message = f"The attribute value of node({node.name}) " \ message = f"The attribute value of node({node.name}) " \
f"is over {self.MAX_NODE_ATTRIBUTE_VALUE_BYTES} Bytes, will ignore." f"is over {self.MAX_NODE_ATTRIBUTE_VALUE_BYTES} Bytes, will ignore."
logger.info(message) logger.warning(message)
continue continue
node.add_attr({attr.name: str(attr.value)}) node.add_attr({attr.name: str(attr.value)})
......
{"nodes":[{"attr":{},"independent_layout":false,"input":{"Default/bn1/Add[5]_0/Add50":{"data_type":"DT_STRING","edge_type":"data","independent_layout":false,"shape":[1,1024,14,14]}},"name":"Default/bn1/Reshape[12]_1/Reshape1","output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"type":"Reshape"},{"attr":{},"independent_layout":false,"input":{"Default/bn1/Add[5]_0/Add51":{"data_type":"DT_STRING","edge_type":"data","independent_layout":false,"shape":[1,1024,14,14]}},"name":"Default/bn1/Reshape[12]_1/Reshape2","output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"type":"Reshape"},{"attr":{},"independent_layout":false,"input":{"Default/bn1/Add[5]_0/Add52":{"data_type":"DT_STRING","edge_type":"data","independent_layout":false,"shape":[1,1024,14,14]}},"name":"Default/bn1/Reshape[12]_1/Reshape3","output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"type":"Reshape"},{"attr":{},"independent_layout":false,"input":{"Default/bn1/Add[5]_0/Add53":{"data_type":"DT_STRING","edge_type":"data","independent_layout":false,"shape":[1,1024,14,14]}},"name":"Default/bn1/Reshape[12]_1/Reshape4","output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"type":"Reshape"},{"attr":{},"independent_layout":false,"input":{"Default/bn1/Add[5]_0/Add54":{"data_type":"DT_STRING","edge_type":"data","independent_layout":false,"shape":[1,1024,14,14]}},"name":"Default/bn1/Reshape[12]_1/Reshape5","output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"type":"Reshape"},{"attr":{},"independent_layout":false,"input":{"Default/conv1-Conv2d/Conv2D55":{"data_type":"DT_STRING","edge_type":"data","independent_layout":false,"shape":[1,64,112,112]}},"name":"Default/bn1/Reshape[12]_1/Reshape6","output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"type":"Reshape"},{"attr":{},"independent_layout":false,"input":{"Default/bn1/x":{"data_type":"","edge_type":"data","independent_layout":false,"shape":[1,3,224,224]}},"name":"Default/bn1/Reshape[12]_1/Reshape7","output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"type":"Reshape"},{"attr":{},"independent_layout":false,"input":{"Default/bn1/x":{"data_type":"","edge_type":"data","independent_layout":false,"shape":[1,3,224,224]}},"name":"Default/bn1/Reshape[12]_1/Reshape8","output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"type":"Reshape"},{"attr":{},"independent_layout":false,"input":{"Default/bn1/x":{"data_type":"","edge_type":"data","independent_layout":false,"shape":[1,3,224,224]}},"name":"Default/bn1/Reshape[12]_1/Reshape9","output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"type":"Reshape"},{"attr":{},"independent_layout":false,"input":{"Default/bn1/x":{"data_type":"","edge_type":"data","independent_layout":false,"shape":[1,3,224,224]}},"name":"Default/bn1/Reshape[12]_1/Reshape10","output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"type":"Reshape"},{"attr":{},"independent_layout":false,"input":{"Default/bn1/x":{"data_type":"","edge_type":"data","independent_layout":false,"shape":[1,3,224,224]}},"name":"Default/bn1/Reshape[12]_1/Reshape11","output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"type":"Reshape"},{"attr":{},"independent_layout":false,"input":{"Default/bn1/x":{"data_type":"","edge_type":"data","independent_layout":false,"shape":[1,3,224,224]}},"name":"Default/bn1/Reshape[12]_1/Reshape12","output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"type":"Reshape"}]} {"nodes":[{"name":"Default/bn1/Reshape[12]_1/Reshape1","type":"Reshape","attr":{},"input":{"Default/bn1/Add[5]_0/Add50":{"shape":[1,1024,14,14],"edge_type":"data","independent_layout":false,"data_type":"DT_STRING"}},"output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"independent_layout":false},{"name":"Default/bn1/Reshape[12]_1/Reshape2","type":"Reshape","attr":{},"input":{"Default/bn1/Add[5]_0/Add51":{"shape":[1,1024,14,14],"edge_type":"data","independent_layout":false,"data_type":"DT_STRING"}},"output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"independent_layout":false},{"name":"Default/bn1/Reshape[12]_1/Reshape3","type":"Reshape","attr":{},"input":{"Default/bn1/Add[5]_0/Add52":{"shape":[1,1024,14,14],"edge_type":"data","independent_layout":false,"data_type":"DT_STRING"}},"output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"independent_layout":false},{"name":"Default/bn1/Reshape[12]_1/Reshape4","type":"Reshape","attr":{},"input":{"Default/bn1/Add[5]_0/Add53":{"shape":[1,1024,14,14],"edge_type":"data","independent_layout":false,"data_type":"DT_STRING"}},"output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"independent_layout":false},{"name":"Default/bn1/Reshape[12]_1/Reshape5","type":"Reshape","attr":{},"input":{"Default/bn1/Add[5]_0/Add54":{"shape":[1,1024,14,14],"edge_type":"data","independent_layout":false,"data_type":"DT_STRING"}},"output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"independent_layout":false},{"name":"Default/bn1/Reshape[12]_1/Reshape6","type":"Reshape","attr":{},"input":{"Default/conv1-Conv2d/Conv2D55":{"shape":[1,64,112,112],"edge_type":"data","independent_layout":false,"data_type":"DT_STRING"}},"output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"independent_layout":false},{"name":"Default/bn1/Reshape[12]_1/Reshape7","type":"Reshape","attr":{},"input":{"Default/bn1/x":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":false,"data_type":"DT_STRING"}},"output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"independent_layout":false},{"name":"Default/bn1/Reshape[12]_1/Reshape8","type":"Reshape","attr":{},"input":{"Default/bn1/x":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":false,"data_type":"DT_STRING"}},"output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"independent_layout":false},{"name":"Default/bn1/Reshape[12]_1/Reshape9","type":"Reshape","attr":{},"input":{"Default/bn1/x":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":false,"data_type":"DT_STRING"}},"output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"independent_layout":false},{"name":"Default/bn1/Reshape[12]_1/Reshape10","type":"Reshape","attr":{},"input":{"Default/bn1/x":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":false,"data_type":"DT_STRING"}},"output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"independent_layout":false},{"name":"Default/bn1/Reshape[12]_1/Reshape11","type":"Reshape","attr":{},"input":{"Default/bn1/x":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":false,"data_type":"DT_STRING"}},"output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"independent_layout":false},{"name":"Default/bn1/Reshape[12]_1/Reshape12","type":"Reshape","attr":{},"input":{"Default/bn1/x":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":false,"data_type":"DT_STRING"}},"output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"independent_layout":false}]}
\ No newline at end of file
{"nodes":[{"attr":{"output_names":"dtype: DT_GRAPHS\nvalues {\n dtype: DT_FLOAT64\n str_val: \"output\"\n}\n","pad_mode":"dtype: DT_FLOAT64\nstr_val: \"same\"\n"},"independent_layout":false,"input":{"Default/conv1-Conv2d/Parameter[12]_2/conv1.weight":{"data_type":"","edge_type":"data","independent_layout":true,"shape":[64,3,7,7]},"Default/conv1-Conv2d/Parameter[12]_2/x":{"data_type":"","edge_type":"data","independent_layout":true,"shape":[1,3,224,224]},"Default/conv1-Conv2d/Parameter[12]_2/x1":{"data_type":"","edge_type":"data","independent_layout":true,"shape":[1,3,224,224]},"Default/conv1-Conv2d/Parameter[12]_2/x10":{"data_type":"","edge_type":"data","independent_layout":true,"shape":[1,3,224,224]},"Default/conv1-Conv2d/Parameter[12]_2/x2":{"data_type":"","edge_type":"data","independent_layout":true,"shape":[1,3,224,224]},"Default/conv1-Conv2d/Parameter[12]_2/x3":{"data_type":"","edge_type":"data","independent_layout":true,"shape":[1,3,224,224]},"Default/conv1-Conv2d/Parameter[12]_2/x4":{"data_type":"","edge_type":"data","independent_layout":true,"shape":[1,3,224,224]},"Default/conv1-Conv2d/Parameter[12]_2/x5":{"data_type":"","edge_type":"data","independent_layout":true,"shape":[1,3,224,224]},"Default/conv1-Conv2d/Parameter[12]_2/x6":{"data_type":"","edge_type":"data","independent_layout":true,"shape":[1,3,224,224]},"Default/conv1-Conv2d/Parameter[12]_2/x7":{"data_type":"","edge_type":"data","independent_layout":true,"shape":[1,3,224,224]},"Default/conv1-Conv2d/Parameter[12]_2/x8":{"data_type":"","edge_type":"data","independent_layout":true,"shape":[1,3,224,224]},"Default/conv1-Conv2d/Parameter[12]_2/x9":{"data_type":"","edge_type":"data","independent_layout":true,"shape":[1,3,224,224]}},"name":"Default/conv1-Conv2d/Conv2D55","output":{"Default/bn1/Reshape[12]_1/Reshape6":{"data_type":"DT_STRING","edge_type":"data","independent_layout":false,"shape":[1,64,112,112]}},"output_i":0,"proxy_input":{"Default/conv1-Conv2d/Parameter[12]_2":{"edge_type":"data"}},"proxy_output":{},"subnode_count":0,"type":"Conv2D"},{"attr":{},"independent_layout":true,"input":{},"name":"Default/conv1-Conv2d/Parameter[12]_2","output":{"Default/conv1-Conv2d/Conv2D55":{"data_type":"","edge_type":"data","independent_layout":true,"shape":[64,3,7,7]}},"output_i":0,"proxy_input":{},"proxy_output":{"Default/conv1-Conv2d/Conv2D55":{"edge_type":"data"}},"subnode_count":12,"type":"aggregation_scope"}]} {"nodes":[{"name":"Default/conv1-Conv2d/Conv2D55","type":"Conv2D","attr":{"output_names":"dtype: DT_GRAPHS\nvalues {\n dtype: DT_FLOAT64\n str_val: \"output\"\n}\n","pad_mode":"dtype: DT_FLOAT64\nstr_val: \"same\"\n"},"input":{"Default/conv1-Conv2d/Parameter[12]_2/x":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":true,"data_type":"DT_STRING"},"Default/conv1-Conv2d/Parameter[12]_2/x1":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":true,"data_type":"DT_STRING"},"Default/conv1-Conv2d/Parameter[12]_2/x2":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":true,"data_type":"DT_STRING"},"Default/conv1-Conv2d/Parameter[12]_2/x3":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":true,"data_type":"DT_STRING"},"Default/conv1-Conv2d/Parameter[12]_2/x4":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":true,"data_type":"DT_STRING"},"Default/conv1-Conv2d/Parameter[12]_2/x5":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":true,"data_type":"DT_STRING"},"Default/conv1-Conv2d/Parameter[12]_2/x6":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":true,"data_type":"DT_STRING"},"Default/conv1-Conv2d/Parameter[12]_2/x7":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":true,"data_type":"DT_STRING"},"Default/conv1-Conv2d/Parameter[12]_2/x8":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":true,"data_type":"DT_STRING"},"Default/conv1-Conv2d/Parameter[12]_2/x9":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":true,"data_type":"DT_STRING"},"Default/conv1-Conv2d/Parameter[12]_2/x10":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":true,"data_type":"DT_STRING"},"Default/conv1-Conv2d/Parameter[12]_2/conv1.weight":{"shape":[64,3,7,7],"edge_type":"data","independent_layout":true,"data_type":"DT_STRING"}},"output":{"Default/bn1/Reshape[12]_1/Reshape6":{"shape":[1,64,112,112],"edge_type":"data","independent_layout":false,"data_type":"DT_STRING"}},"output_i":0,"proxy_input":{"Default/conv1-Conv2d/Parameter[12]_2":{"edge_type":"data"}},"proxy_output":{},"subnode_count":0,"independent_layout":false},{"name":"Default/conv1-Conv2d/Parameter[12]_2","type":"aggregation_scope","attr":{},"input":{},"output":{"Default/conv1-Conv2d/Conv2D55":{"shape":[64,3,7,7],"edge_type":"data","independent_layout":true,"data_type":"DT_STRING"}},"output_i":0,"proxy_input":{},"proxy_output":{"Default/conv1-Conv2d/Conv2D55":{"edge_type":"data"}},"subnode_count":12,"independent_layout":true}]}
\ No newline at end of file
{"nodes":[{"attr":{},"independent_layout":false,"input":{"Default/bn1/Add[5]_0/Add50":{"data_type":"DT_STRING","edge_type":"data","independent_layout":false,"shape":[1,1024,14,14]}},"name":"Default/bn1/Reshape[12]_1/Reshape1","output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"type":"Reshape"},{"attr":{},"independent_layout":false,"input":{"Default/bn1/Add[5]_0/Add51":{"data_type":"DT_STRING","edge_type":"data","independent_layout":false,"shape":[1,1024,14,14]}},"name":"Default/bn1/Reshape[12]_1/Reshape2","output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"type":"Reshape"},{"attr":{},"independent_layout":false,"input":{"Default/bn1/Add[5]_0/Add52":{"data_type":"DT_STRING","edge_type":"data","independent_layout":false,"shape":[1,1024,14,14]}},"name":"Default/bn1/Reshape[12]_1/Reshape3","output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"type":"Reshape"},{"attr":{},"independent_layout":false,"input":{"Default/bn1/Add[5]_0/Add53":{"data_type":"DT_STRING","edge_type":"data","independent_layout":false,"shape":[1,1024,14,14]}},"name":"Default/bn1/Reshape[12]_1/Reshape4","output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"type":"Reshape"},{"attr":{},"independent_layout":false,"input":{"Default/bn1/Add[5]_0/Add54":{"data_type":"DT_STRING","edge_type":"data","independent_layout":false,"shape":[1,1024,14,14]}},"name":"Default/bn1/Reshape[12]_1/Reshape5","output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"type":"Reshape"},{"attr":{},"independent_layout":false,"input":{"Default/conv1-Conv2d/Conv2D55":{"data_type":"DT_STRING","edge_type":"data","independent_layout":false,"shape":[1,64,112,112]}},"name":"Default/bn1/Reshape[12]_1/Reshape6","output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"type":"Reshape"},{"attr":{},"independent_layout":false,"input":{"Default/bn1/x":{"data_type":"","edge_type":"data","independent_layout":false,"shape":[1,3,224,224]}},"name":"Default/bn1/Reshape[12]_1/Reshape7","output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"type":"Reshape"},{"attr":{},"independent_layout":false,"input":{"Default/bn1/x":{"data_type":"","edge_type":"data","independent_layout":false,"shape":[1,3,224,224]}},"name":"Default/bn1/Reshape[12]_1/Reshape8","output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"type":"Reshape"},{"attr":{},"independent_layout":false,"input":{"Default/bn1/x":{"data_type":"","edge_type":"data","independent_layout":false,"shape":[1,3,224,224]}},"name":"Default/bn1/Reshape[12]_1/Reshape9","output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"type":"Reshape"},{"attr":{},"independent_layout":false,"input":{"Default/bn1/x":{"data_type":"","edge_type":"data","independent_layout":false,"shape":[1,3,224,224]}},"name":"Default/bn1/Reshape[12]_1/Reshape10","output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"type":"Reshape"},{"attr":{},"independent_layout":false,"input":{"Default/bn1/x":{"data_type":"","edge_type":"data","independent_layout":false,"shape":[1,3,224,224]}},"name":"Default/bn1/Reshape[12]_1/Reshape11","output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"type":"Reshape"},{"attr":{},"independent_layout":false,"input":{"Default/bn1/x":{"data_type":"","edge_type":"data","independent_layout":false,"shape":[1,3,224,224]}},"name":"Default/bn1/Reshape[12]_1/Reshape12","output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"type":"Reshape"}]} {"nodes":[{"name":"Default/bn1/Reshape[12]_1/Reshape1","type":"Reshape","attr":{},"input":{"Default/bn1/Add[5]_0/Add50":{"shape":[1,1024,14,14],"edge_type":"data","independent_layout":false,"data_type":"DT_STRING"}},"output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"independent_layout":false},{"name":"Default/bn1/Reshape[12]_1/Reshape2","type":"Reshape","attr":{},"input":{"Default/bn1/Add[5]_0/Add51":{"shape":[1,1024,14,14],"edge_type":"data","independent_layout":false,"data_type":"DT_STRING"}},"output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"independent_layout":false},{"name":"Default/bn1/Reshape[12]_1/Reshape3","type":"Reshape","attr":{},"input":{"Default/bn1/Add[5]_0/Add52":{"shape":[1,1024,14,14],"edge_type":"data","independent_layout":false,"data_type":"DT_STRING"}},"output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"independent_layout":false},{"name":"Default/bn1/Reshape[12]_1/Reshape4","type":"Reshape","attr":{},"input":{"Default/bn1/Add[5]_0/Add53":{"shape":[1,1024,14,14],"edge_type":"data","independent_layout":false,"data_type":"DT_STRING"}},"output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"independent_layout":false},{"name":"Default/bn1/Reshape[12]_1/Reshape5","type":"Reshape","attr":{},"input":{"Default/bn1/Add[5]_0/Add54":{"shape":[1,1024,14,14],"edge_type":"data","independent_layout":false,"data_type":"DT_STRING"}},"output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"independent_layout":false},{"name":"Default/bn1/Reshape[12]_1/Reshape6","type":"Reshape","attr":{},"input":{"Default/conv1-Conv2d/Conv2D55":{"shape":[1,64,112,112],"edge_type":"data","independent_layout":false,"data_type":"DT_STRING"}},"output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"independent_layout":false},{"name":"Default/bn1/Reshape[12]_1/Reshape7","type":"Reshape","attr":{},"input":{"Default/bn1/x":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":false,"data_type":"DT_STRING"}},"output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"independent_layout":false},{"name":"Default/bn1/Reshape[12]_1/Reshape8","type":"Reshape","attr":{},"input":{"Default/bn1/x":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":false,"data_type":"DT_STRING"}},"output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"independent_layout":false},{"name":"Default/bn1/Reshape[12]_1/Reshape9","type":"Reshape","attr":{},"input":{"Default/bn1/x":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":false,"data_type":"DT_STRING"}},"output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"independent_layout":false},{"name":"Default/bn1/Reshape[12]_1/Reshape10","type":"Reshape","attr":{},"input":{"Default/bn1/x":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":false,"data_type":"DT_STRING"}},"output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"independent_layout":false},{"name":"Default/bn1/Reshape[12]_1/Reshape11","type":"Reshape","attr":{},"input":{"Default/bn1/x":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":false,"data_type":"DT_STRING"}},"output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"independent_layout":false},{"name":"Default/bn1/Reshape[12]_1/Reshape12","type":"Reshape","attr":{},"input":{"Default/bn1/x":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":false,"data_type":"DT_STRING"}},"output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"independent_layout":false}]}
\ No newline at end of file
{"nodes":[{"attr":{},"independent_layout":false,"input":{"Default/bn1-BatchNorm2d/Parameter[22]_3/x":{"data_type":"","edge_type":"data","independent_layout":true,"shape":[1,3,224,224]},"Default/bn1-BatchNorm2d/Parameter[22]_3/x1":{"data_type":"","edge_type":"data","independent_layout":true,"shape":[1,3,224,224]},"Default/bn1-BatchNorm2d/Parameter[22]_3/x10":{"data_type":"","edge_type":"data","independent_layout":true,"shape":[1,3,224,224]},"Default/bn1-BatchNorm2d/Parameter[22]_3/x2":{"data_type":"","edge_type":"data","independent_layout":true,"shape":[1,3,224,224]},"Default/bn1-BatchNorm2d/Parameter[22]_3/x3":{"data_type":"","edge_type":"data","independent_layout":true,"shape":[1,3,224,224]},"Default/bn1-BatchNorm2d/Parameter[22]_3/x4":{"data_type":"","edge_type":"data","independent_layout":true,"shape":[1,3,224,224]},"Default/bn1-BatchNorm2d/Parameter[22]_3/x5":{"data_type":"","edge_type":"data","independent_layout":true,"shape":[1,3,224,224]},"Default/bn1-BatchNorm2d/Parameter[22]_3/x6":{"data_type":"","edge_type":"data","independent_layout":true,"shape":[1,3,224,224]},"Default/bn1-BatchNorm2d/Parameter[22]_3/x7":{"data_type":"","edge_type":"data","independent_layout":true,"shape":[1,3,224,224]},"Default/bn1-BatchNorm2d/Parameter[22]_3/x8":{"data_type":"","edge_type":"data","independent_layout":true,"shape":[1,3,224,224]},"Default/bn1-BatchNorm2d/Parameter[22]_3/x9":{"data_type":"","edge_type":"data","independent_layout":true,"shape":[1,3,224,224]},"Default/bn1-BatchNorm2d/cst13":{"data_type":"","edge_type":"data","independent_layout":false,"shape":[]}},"name":"Default/bn1-BatchNorm2d/tuple_getitem56","output":{"Default/bn1/Add[5]_0/Add53":{"data_type":"DT_STRING","edge_type":"data","independent_layout":false,"shape":[1,128,28,28]}},"output_i":0,"proxy_input":{"Default/bn1-BatchNorm2d/Parameter[22]_3":{"edge_type":"data"}},"proxy_output":{},"subnode_count":0,"type":"tuple_getitem"},{"attr":{},"independent_layout":false,"input":{"Default/bn1-BatchNorm2d/Parameter[22]_3/conv1.weight":{"data_type":"","edge_type":"data","independent_layout":true,"shape":[64,3,7,7]},"Default/bn1-BatchNorm2d/Parameter[22]_3/x11":{"data_type":"","edge_type":"data","independent_layout":true,"shape":[1,3,224,224]},"Default/bn1-BatchNorm2d/Parameter[22]_3/x12":{"data_type":"","edge_type":"data","independent_layout":true,"shape":[1,3,224,224]},"Default/bn1-BatchNorm2d/Parameter[22]_3/x13":{"data_type":"","edge_type":"data","independent_layout":true,"shape":[1,3,224,224]},"Default/bn1-BatchNorm2d/Parameter[22]_3/x14":{"data_type":"","edge_type":"data","independent_layout":true,"shape":[1,3,224,224]},"Default/bn1-BatchNorm2d/Parameter[22]_3/x15":{"data_type":"","edge_type":"data","independent_layout":true,"shape":[1,3,224,224]},"Default/bn1-BatchNorm2d/Parameter[22]_3/x16":{"data_type":"","edge_type":"data","independent_layout":true,"shape":[1,3,224,224]},"Default/bn1-BatchNorm2d/Parameter[22]_3/x17":{"data_type":"","edge_type":"data","independent_layout":true,"shape":[1,3,224,224]},"Default/bn1-BatchNorm2d/Parameter[22]_3/x18":{"data_type":"","edge_type":"data","independent_layout":true,"shape":[1,3,224,224]},"Default/bn1-BatchNorm2d/Parameter[22]_3/x19":{"data_type":"","edge_type":"data","independent_layout":true,"shape":[1,3,224,224]},"Default/bn1-BatchNorm2d/Parameter[22]_3/x20":{"data_type":"","edge_type":"data","independent_layout":true,"shape":[1,3,224,224]},"Default/bn1-BatchNorm2d/cst25":{"data_type":"","edge_type":"data","independent_layout":false,"shape":[]}},"name":"Default/bn1-BatchNorm2d/tuple_getitem105","output":{},"output_i":0,"proxy_input":{"Default/bn1-BatchNorm2d/Parameter[22]_3":{"edge_type":"data"}},"proxy_output":{},"subnode_count":0,"type":"tuple_getitem"},{"attr":{},"independent_layout":true,"input":{},"name":"Default/bn1-BatchNorm2d/Parameter[22]_3","output":{"Default/bn1-BatchNorm2d/tuple_getitem105":{"data_type":"","edge_type":"data","independent_layout":true,"shape":[64,3,7,7]},"Default/bn1-BatchNorm2d/tuple_getitem56":{"data_type":"","edge_type":"data","independent_layout":true,"shape":[1,3,224,224]}},"output_i":0,"proxy_input":{},"proxy_output":{"Default/bn1-BatchNorm2d/tuple_getitem105":{"edge_type":"data"},"Default/bn1-BatchNorm2d/tuple_getitem56":{"edge_type":"data"}},"subnode_count":22,"type":"aggregation_scope"},{"attr":{"cst13":"dtype: DT_INT32\nint_val: 0\n"},"independent_layout":false,"input":{},"name":"Default/bn1-BatchNorm2d/cst13","output":{"Default/bn1-BatchNorm2d/tuple_getitem56":{"data_type":"","edge_type":"data","independent_layout":false,"shape":[]}},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"type":"Const"},{"attr":{"cst25":"dtype: DT_INT32\nint_val: 0\n"},"independent_layout":false,"input":{},"name":"Default/bn1-BatchNorm2d/cst25","output":{"Default/bn1-BatchNorm2d/tuple_getitem105":{"data_type":"","edge_type":"data","independent_layout":false,"shape":[]}},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"type":"Const"}]} {"nodes":[{"name":"Default/bn1-BatchNorm2d/tuple_getitem56","type":"tuple_getitem","attr":{},"input":{"Default/bn1-BatchNorm2d/Parameter[22]_3/x":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":true,"data_type":"DT_STRING"},"Default/bn1-BatchNorm2d/Parameter[22]_3/x1":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":true,"data_type":"DT_STRING"},"Default/bn1-BatchNorm2d/Parameter[22]_3/x2":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":true,"data_type":"DT_STRING"},"Default/bn1-BatchNorm2d/Parameter[22]_3/x3":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":true,"data_type":"DT_STRING"},"Default/bn1-BatchNorm2d/Parameter[22]_3/x4":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":true,"data_type":"DT_STRING"},"Default/bn1-BatchNorm2d/Parameter[22]_3/x5":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":true,"data_type":"DT_STRING"},"Default/bn1-BatchNorm2d/Parameter[22]_3/x6":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":true,"data_type":"DT_STRING"},"Default/bn1-BatchNorm2d/Parameter[22]_3/x7":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":true,"data_type":"DT_STRING"},"Default/bn1-BatchNorm2d/Parameter[22]_3/x8":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":true,"data_type":"DT_STRING"},"Default/bn1-BatchNorm2d/Parameter[22]_3/x9":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":true,"data_type":"DT_STRING"},"Default/bn1-BatchNorm2d/Parameter[22]_3/x10":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":true,"data_type":"DT_STRING"},"Default/bn1-BatchNorm2d/cst13":{"shape":[],"edge_type":"data","independent_layout":false,"data_type":""}},"output":{"Default/bn1/Add[5]_0/Add53":{"shape":[1,128,28,28],"edge_type":"data","independent_layout":false,"data_type":"DT_STRING"}},"output_i":0,"proxy_input":{"Default/bn1-BatchNorm2d/Parameter[22]_3":{"edge_type":"data"}},"proxy_output":{},"subnode_count":0,"independent_layout":false},{"name":"Default/bn1-BatchNorm2d/tuple_getitem105","type":"tuple_getitem","attr":{},"input":{"Default/bn1-BatchNorm2d/Parameter[22]_3/x11":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":true,"data_type":"DT_STRING"},"Default/bn1-BatchNorm2d/Parameter[22]_3/x12":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":true,"data_type":"DT_STRING"},"Default/bn1-BatchNorm2d/Parameter[22]_3/x13":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":true,"data_type":"DT_STRING"},"Default/bn1-BatchNorm2d/Parameter[22]_3/x14":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":true,"data_type":"DT_STRING"},"Default/bn1-BatchNorm2d/Parameter[22]_3/x15":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":true,"data_type":"DT_STRING"},"Default/bn1-BatchNorm2d/Parameter[22]_3/x16":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":true,"data_type":"DT_STRING"},"Default/bn1-BatchNorm2d/Parameter[22]_3/x17":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":true,"data_type":"DT_STRING"},"Default/bn1-BatchNorm2d/Parameter[22]_3/x18":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":true,"data_type":"DT_STRING"},"Default/bn1-BatchNorm2d/Parameter[22]_3/x19":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":true,"data_type":"DT_STRING"},"Default/bn1-BatchNorm2d/Parameter[22]_3/x20":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":true,"data_type":"DT_STRING"},"Default/bn1-BatchNorm2d/Parameter[22]_3/conv1.weight":{"shape":[64,3,7,7],"edge_type":"data","independent_layout":true,"data_type":"DT_STRING"},"Default/bn1-BatchNorm2d/cst25":{"shape":[],"edge_type":"data","independent_layout":false,"data_type":""}},"output":{},"output_i":0,"proxy_input":{"Default/bn1-BatchNorm2d/Parameter[22]_3":{"edge_type":"data"}},"proxy_output":{},"subnode_count":0,"independent_layout":false},{"name":"Default/bn1-BatchNorm2d/Parameter[22]_3","type":"aggregation_scope","attr":{},"input":{},"output":{"Default/bn1-BatchNorm2d/tuple_getitem56":{"shape":[1,3,224,224],"edge_type":"data","independent_layout":true,"data_type":"DT_STRING"},"Default/bn1-BatchNorm2d/tuple_getitem105":{"shape":[64,3,7,7],"edge_type":"data","independent_layout":true,"data_type":"DT_STRING"}},"output_i":0,"proxy_input":{},"proxy_output":{"Default/bn1-BatchNorm2d/tuple_getitem56":{"edge_type":"data"},"Default/bn1-BatchNorm2d/tuple_getitem105":{"edge_type":"data"}},"subnode_count":22,"independent_layout":true},{"name":"Default/bn1-BatchNorm2d/cst13","type":"Const","attr":{"cst13":"dtype: DT_INT32\nint_val: 0\n"},"input":{},"output":{"Default/bn1-BatchNorm2d/tuple_getitem56":{"shape":[],"edge_type":"data","independent_layout":false,"data_type":""}},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"independent_layout":false},{"name":"Default/bn1-BatchNorm2d/cst25","type":"Const","attr":{"cst25":"dtype: DT_INT32\nint_val: 0\n"},"input":{},"output":{"Default/bn1-BatchNorm2d/tuple_getitem105":{"shape":[],"edge_type":"data","independent_layout":false,"data_type":""}},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":0,"independent_layout":false}]}
\ No newline at end of file
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册