提交 f59d1798 编写于 作者: O ougongchang

1. Complete the optimization of the graph code

2. Optimize the python api of graph and graph_processor
3. delete unconnected const and parameter nodes
4. fix subnode count bug and fix name scope node have not input and output bug
5. add cyclic graph and high degree graph json file
6. update parameter node to polymeric scope node
7. delele all deepcopy to improve performance
8. add data type and update the attribute scope of edge to independtend_layout
9. add add_parameter_nodes function
10. delete scope attribute in input and optimiza code
11. parse parameter data type and shape
12. fix ut and st for graph
13. fix pylint
14. fix pylint arguments-differ
15. add scope proxy node instead of node
上级 46d44977
......@@ -102,12 +102,11 @@ def graph_nodes():
"""
name = request.args.get('name', default=None)
node_type = request.args.get('type', default='name_scope')
tag = request.args.get("tag", default=None)
train_id = get_train_id(request)
graph_process = GraphProcessor(train_id, DATA_MANAGER, tag)
response = graph_process.get_nodes(name=name, node_type=node_type)
response = graph_process.list_nodes(scope=name)
return jsonify(response)
......
......@@ -17,10 +17,11 @@ This file is used to define the node of graph and associated base types.
"""
from enum import Enum
class NodeTypeEnum(Enum):
"""Node type enum. The following types are new to our custom."""
NAME_SCOPE = 'name_scope'
POLYMERIC_SCOPE = 'polymeric_scope'
AGGREGATION_SCOPE = 'aggregation_scope'
PARAMETER = 'Parameter'
CONST = 'Const'
......@@ -36,32 +37,33 @@ class Node:
def __init__(self, name, node_id):
self._node_id = node_id
self._name = name
self._type = ""
self.name = name
self.type = ""
self._attr = dict()
self._inputs = dict()
self._output_i = -1
self._outputs = {}
self._polymeric_inputs = {}
self._polymeric_outputs = {}
self._polymeric_scope_name = ""
self._subnode_count = 0
self._name_scope = ""
self.shape = []
self._input = dict()
self.output_i = 0
self._output = {}
self._proxy_input = {}
self._proxy_output = {}
self.subnode_count = 0
self.scope = ""
self.independent_layout = False
self.output_shape = []
self.output_data_type = ""
def to_dict(self):
"""Converts the node object to dictionary format."""
return {
'name': self._name,
'type': self._type,
'name': self.name,
'type': self.type,
'attr': self._attr,
'input': self._inputs,
'output_i': self._output_i,
'output': self._outputs,
'polymeric_input': self._polymeric_inputs,
'polymeric_output': self._polymeric_outputs,
'subnode_count': self._subnode_count,
'polymeric_scope_name': self._polymeric_scope_name
'input': self._input,
'output': self._output,
'output_i': self.output_i,
'proxy_input': self._proxy_input,
'proxy_output': self._proxy_output,
'subnode_count': self.subnode_count,
'independent_layout': self.independent_layout
}
@property
......@@ -69,32 +71,26 @@ class Node:
"""The id of this node, and id is unique in graph."""
return self._node_id
@property
def name(self):
"""Get node name."""
return self._name
@name.setter
def name(self, name):
"""Set node name."""
self._name = name
@staticmethod
def create_node_name(scope, base_name):
"""
The name of the node consists of the scope and the basic name.
@property
def node_type(self):
"""Get node type."""
return self._type
Args:
scope (str): The scope of node, such as 'Default/Conv2D'
base_name (str): The base name of node, such as 'Add11'.
@node_type.setter
def node_type(self, node_type):
"""Set node type."""
self._type = node_type
Returns:
str, a node name.
"""
return f'{scope}/{base_name}' if scope else base_name
@property
def attr(self):
"""Get node attr."""
return self._attr
def update_attr(self, attr_dict):
def add_attr(self, attr_dict):
"""
Update node attr.
......@@ -104,114 +100,122 @@ class Node:
self._attr.update(attr_dict)
@property
def inputs(self):
def input(self):
"""
Get all input of current node.
Returns:
dict[str, dict], format is {'<src_name>': {'shape': [], 'edge_type', 'scope'}}.
dict[str, dict], refer to the input attr.
"""
return self._inputs
return self._input
def update_input(self, input_dict):
def add_input(self, src_name, input_attr):
"""
Update input.
Args:
input_dict (dict[str, dict]): Key is a source node name, and the value is a dict.
src_name (stc): The source node name.
input_attr (dict): The attribute of the input.
- shape (list): The shape of input tensor.
- edge_type (str): The type of edge, optional value refer to `EdgeTypeEnum`.
- scope (str): The scope of this source node.
- data_type (str): The data type of the input.
- independent_layout (bool): Indicates whether the source nodes are laid out independently.
"""
self._inputs.update(input_dict)
self._input.update({src_name: input_attr})
@property
def output_i(self):
"""The memory address of this node when it is in run time."""
return self._output_i
@output_i.setter
def output_i(self, output_i):
"""Set memory address."""
self._output_i = output_i
@property
def polymeric_inputs(self):
def delete_input(self, src_name):
"""
The polymeric input is the input of the polymeric nodes.
Delete input attribute by the given source name.
Returns:
dict[str, dict], format is {'<src_name>': {'edge_type': '<value>'}}.
Args:
src_name (str): The source node name.
"""
return self._polymeric_inputs
def update_polymeric_input(self, polymeric_input):
"""The polymeric input is the input of the polymeric nodes."""
self._polymeric_inputs.update(polymeric_input)
self._input.pop(src_name)
@property
def outputs(self):
def output(self):
"""The output node of this node."""
return self._outputs
return self._output
def update_output(self, output):
def add_output(self, dst_name, output_attr):
"""
Update output node.
Add a output node to this node.
Args:
output (dict[str, TypedDict('NodeType', {'type': str})]): Key is a dst node name, and value is a dict.
dst_name (str): The name of the output node.
output_attr (dict: Same as the input attribute.
"""
self._output.update({dst_name: output_attr})
def delete_output(self, dst_name):
"""
Delete a output node.
- type (str): The type of the dst node.
Args:
dst_name (str): The name of the node to be deleted.
"""
self._outputs.update(output)
self._output.pop(dst_name)
@property
def polymeric_outputs(self):
"""Get polymeric output."""
return self._polymeric_outputs
def proxy_input(self):
"""Return proxy input, type is dict."""
return self._proxy_input
def update_polymeric_output(self, polymeric_output):
def add_proxy_input(self, src_name, attr):
"""
Update polymeric output.
Add a proxy input to node.
Args:
polymeric_output (dict[str, dict): Key is the polymeric scope name of dst name, and value is dict.
- edge_type (str): The edge type of the dst node.
src_name (str): The name of the input node.
attr (dict): The attr of the input.
- edge_type (str): The edge type, refer to `EdgeTypeEnum`.
"""
self._polymeric_outputs.update(polymeric_output)
self._proxy_input.update({src_name: attr})
def delete_proxy_input(self, src_name):
"""Delete a proxy input by the src name."""
self._proxy_input.pop(src_name)
@property
def polymeric_scope_name(self):
"""Get polymeric scope name."""
return self._polymeric_scope_name
def proxy_output(self):
"""Get proxy output, data type is dict."""
return self._proxy_output
@polymeric_scope_name.setter
def polymeric_scope_name(self, name):
"""Set polymeric scope name."""
self._polymeric_scope_name = name
def add_proxy_output(self, dst_name, attr):
"""
Add a proxy output to node.
@property
def subnode_count(self):
"""The sub node count of this node, if this node is a scope node, this count will not be zero."""
return self._subnode_count
Args:
dst_name (str): The name of the output node.
attr (dict): The attr of the output.
@subnode_count.setter
def subnode_count(self, count):
"""Set sub node count."""
self._subnode_count = count
- edge_type (str): The edge type, refer to `EdgeTypeEnum`.
"""
self._proxy_output.update({dst_name: attr})
@property
def name_scope(self):
"""Get name scope of this node."""
return self._name_scope
def delete_proxy_output(self, dst_name):
"""Delete a proxy output by dst name."""
self._proxy_output.pop(dst_name)
@name_scope.setter
def name_scope(self, name_scope):
"""Set name scope."""
self._name_scope = name_scope
@staticmethod
def copy_node_without_input_output(src_node, dst_node):
"""
Copy a source node attribute to a new node, but not input and output.
Args:
src_node (Node): The copied node.
dst_node (Node): The destination node.
"""
dst_node.type = src_node.type
dst_node.output_i = src_node.output_i
dst_node.subnode_count = src_node.subnode_count
dst_node.scope = src_node.scope
dst_node.independent_layout = src_node.independent_layout
dst_node.output_shape = src_node.output_shape
dst_node.output_data_type = src_node.output_data_type
dst_node.add_attr(src_node.attr)
def __str__(self):
return f'<Node, name: {self._name}, type: {self._type}>'
return f'<Node, name: {self.name}, type: {self.type}>'
......@@ -20,9 +20,7 @@ and the status of graph will be checked before calling `Graph` object.
from mindinsight.datavisual.common import exceptions
from mindinsight.datavisual.common.enums import PluginNameEnum
from mindinsight.datavisual.common.validation import Validation
from mindinsight.datavisual.data_transform.graph import NodeTypeEnum
from mindinsight.datavisual.processors.base_processor import BaseProcessor
from mindinsight.utils.exceptions import ParamValueError
from mindinsight.datavisual.common.exceptions import NodeNotInGraphError
......@@ -51,13 +49,12 @@ class GraphProcessor(BaseProcessor):
tensors = self._data_manager.list_tensors(train_id, tag=tag)
self._graph = tensors[0].value
def get_nodes(self, name, node_type):
def list_nodes(self, scope):
"""
Get the nodes of every layer in graph.
Args:
name (str): The name of a node.
node_type (Any): The type of node, either 'name_scope' or 'polymeric'.
scope (str): The name of a scope.
Returns:
TypedDict('Nodes', {'nodes': list[Node]}), format is {'nodes': [<Node object>]}.
......@@ -81,33 +78,19 @@ class GraphProcessor(BaseProcessor):
}
},
"output_i" : -1,
"polymeric_input" : {},
"polymeric_output" : {},
"polymeric_scope_name" : "",
"proxy_input" : {},
"proxy_output" : {},
"independent_layout" : False,
"subnode_count" : 0,
"type" : "Data"
}
]
}
"""
if node_type not in [NodeTypeEnum.NAME_SCOPE.value, NodeTypeEnum.POLYMERIC_SCOPE.value]:
raise ParamValueError(
'The node type is not support, only either %s or %s.'
'' % (NodeTypeEnum.NAME_SCOPE.value, NodeTypeEnum.POLYMERIC_SCOPE.value))
if name and not self._graph.exist_node(name):
raise NodeNotInGraphError(node_name=name, node_type=node_type)
nodes = []
if node_type == NodeTypeEnum.NAME_SCOPE.value:
nodes = self._graph.get_normal_nodes(name)
if node_type == NodeTypeEnum.POLYMERIC_SCOPE.value:
if not name:
raise NodeNotInGraphError(node_name=name, node_type=node_type)
polymeric_scope_name = name
nodes = self._graph.get_polymeric_nodes(polymeric_scope_name)
if scope and not self._graph.exist_node(scope):
raise NodeNotInGraphError(node_name=scope)
nodes = self._graph.list_node_by_scope(scope=scope)
return {'nodes': nodes}
def search_node_names(self, search_content, offset, limit):
......
{"nodes":[{"attr":{},"input":{},"name":"Default/conv1-Conv2d","output":{},"output_i":-1,"polymeric_input":{},"polymeric_output":{},"polymeric_scope_name":"","subnode_count":1,"type":"name_scope"},{"attr":{},"input":{},"name":"Default/bn1-BatchNorm2d","output":{},"output_i":-1,"polymeric_input":{},"polymeric_output":{},"polymeric_scope_name":"","subnode_count":14,"type":"name_scope"},{"attr":{},"input":{},"name":"Default/bn1","output":{},"output_i":-1,"polymeric_input":{},"polymeric_output":{},"polymeric_scope_name":"","subnode_count":20,"type":"name_scope"}]}
{"nodes":[{"attr":{},"independent_layout":false,"input":{},"name":"Default","output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":3,"type":"name_scope"}]}
\ No newline at end of file
{"nodes":[{"attr":{},"input":{},"name":"Default","output":{},"output_i":-1,"polymeric_input":{},"polymeric_output":{},"polymeric_scope_name":"","subnode_count":3,"type":"name_scope"}]}
{"nodes":[{"attr":{},"independent_layout":false,"input":{},"name":"Default/conv1-Conv2d","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":{},"proxy_output":{},"subnode_count":2,"type":"name_scope"},{"attr":{},"independent_layout":false,"input":{},"name":"Default/bn1-BatchNorm2d","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":{},"proxy_output":{},"subnode_count":5,"type":"name_scope"},{"attr":{},"independent_layout":false,"input":{"Default/bn1-BatchNorm2d/tuple_getitem56":{"data_type":"DT_STRING","edge_type":"data","independent_layout":false,"shape":[1,128,28,28]},"Default/conv1-Conv2d/Conv2D55":{"data_type":"DT_STRING","edge_type":"data","independent_layout":false,"shape":[1,64,112,112]}},"name":"Default/bn1","output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":4,"type":"name_scope"}]}
\ No newline at end of file
{"nodes":[{"attr":{},"input":{"Default/bn1/Add50":{"edge_type":"data","scope":"polymeric_scope","shape":[1,1024,14,14]},"Default/bn1/conv1.weight":{"edge_type":"data","scope":"polymeric_scope","shape":[64,3,7,7]},"Default/bn1/x":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]},"Default/bn1/x1":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]},"Default/bn1/x10":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]},"Default/bn1/x2":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]},"Default/bn1/x3":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]},"Default/bn1/x4":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]},"Default/bn1/x5":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]},"Default/bn1/x6":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]},"Default/bn1/x7":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]},"Default/bn1/x8":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]},"Default/bn1/x9":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]}},"name":"Default/bn1/Reshape1","output":{},"output_i":0,"polymeric_input":{"Default/bn1/Add50":{"edge_type":"data"},"Default/bn1/conv1.weight":{"edge_type":"data"},"Default/bn1/x":{"edge_type":"data"},"Default/bn1/x1":{"edge_type":"data"},"Default/bn1/x10":{"edge_type":"data"},"Default/bn1/x2":{"edge_type":"data"},"Default/bn1/x3":{"edge_type":"data"},"Default/bn1/x4":{"edge_type":"data"},"Default/bn1/x5":{"edge_type":"data"},"Default/bn1/x6":{"edge_type":"data"},"Default/bn1/x7":{"edge_type":"data"},"Default/bn1/x8":{"edge_type":"data"},"Default/bn1/x9":{"edge_type":"data"}},"polymeric_output":{},"polymeric_scope_name":"Default/bn1/Reshape_1_[12]","subnode_count":0,"type":"Reshape"},{"attr":{},"input":{"Default/bn1/Add51":{"edge_type":"data","scope":"polymeric_scope","shape":[1,1024,14,14]}},"name":"Default/bn1/Reshape2","output":{},"output_i":0,"polymeric_input":{"Default/bn1/Add51":{"edge_type":"data"}},"polymeric_output":{},"polymeric_scope_name":"Default/bn1/Reshape_1_[12]","subnode_count":0,"type":"Reshape"},{"attr":{},"input":{"Default/bn1/Add52":{"edge_type":"data","scope":"polymeric_scope","shape":[1,1024,14,14]}},"name":"Default/bn1/Reshape3","output":{},"output_i":0,"polymeric_input":{"Default/bn1/Add52":{"edge_type":"data"}},"polymeric_output":{},"polymeric_scope_name":"Default/bn1/Reshape_1_[12]","subnode_count":0,"type":"Reshape"},{"attr":{},"input":{"Default/bn1/Add53":{"edge_type":"data","scope":"polymeric_scope","shape":[1,1024,14,14]}},"name":"Default/bn1/Reshape4","output":{},"output_i":0,"polymeric_input":{"Default/bn1/Add53":{"edge_type":"data"}},"polymeric_output":{},"polymeric_scope_name":"Default/bn1/Reshape_1_[12]","subnode_count":0,"type":"Reshape"},{"attr":{},"input":{"Default/bn1/Add54":{"edge_type":"data","scope":"polymeric_scope","shape":[1,1024,14,14]}},"name":"Default/bn1/Reshape5","output":{},"output_i":0,"polymeric_input":{"Default/bn1/Add54":{"edge_type":"data"}},"polymeric_output":{},"polymeric_scope_name":"Default/bn1/Reshape_1_[12]","subnode_count":0,"type":"Reshape"},{"attr":{},"input":{"Default/bn1/x":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]}},"name":"Default/bn1/Reshape6","output":{},"output_i":0,"polymeric_input":{"Default/bn1/x":{"edge_type":"data"}},"polymeric_output":{},"polymeric_scope_name":"Default/bn1/Reshape_1_[12]","subnode_count":0,"type":"Reshape"},{"attr":{},"input":{"Default/bn1/x":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]}},"name":"Default/bn1/Reshape7","output":{},"output_i":0,"polymeric_input":{"Default/bn1/x":{"edge_type":"data"}},"polymeric_output":{},"polymeric_scope_name":"Default/bn1/Reshape_1_[12]","subnode_count":0,"type":"Reshape"},{"attr":{},"input":{"Default/bn1/x":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]}},"name":"Default/bn1/Reshape8","output":{},"output_i":0,"polymeric_input":{"Default/bn1/x":{"edge_type":"data"}},"polymeric_output":{},"polymeric_scope_name":"Default/bn1/Reshape_1_[12]","subnode_count":0,"type":"Reshape"},{"attr":{},"input":{"Default/bn1/x":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]}},"name":"Default/bn1/Reshape9","output":{},"output_i":0,"polymeric_input":{"Default/bn1/x":{"edge_type":"data"}},"polymeric_output":{},"polymeric_scope_name":"Default/bn1/Reshape_1_[12]","subnode_count":0,"type":"Reshape"},{"attr":{},"input":{"Default/bn1/x":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]}},"name":"Default/bn1/Reshape10","output":{},"output_i":0,"polymeric_input":{"Default/bn1/x":{"edge_type":"data"}},"polymeric_output":{},"polymeric_scope_name":"Default/bn1/Reshape_1_[12]","subnode_count":0,"type":"Reshape"},{"attr":{},"input":{"Default/bn1/x":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]}},"name":"Default/bn1/Reshape11","output":{},"output_i":0,"polymeric_input":{"Default/bn1/x":{"edge_type":"data"}},"polymeric_output":{},"polymeric_scope_name":"Default/bn1/Reshape_1_[12]","subnode_count":0,"type":"Reshape"},{"attr":{},"input":{"Default/bn1/x":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]}},"name":"Default/bn1/Reshape12","output":{},"output_i":0,"polymeric_input":{"Default/bn1/x":{"edge_type":"data"}},"polymeric_output":{},"polymeric_scope_name":"Default/bn1/Reshape_1_[12]","subnode_count":0,"type":"Reshape"}]}
{"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"}]}
\ No newline at end of file
{"children":{"children":{"children":{"children":{},"nodes":[{"attr":{},"input":{"Default/bn1/Add50":{"edge_type":"data","scope":"polymeric_scope","shape":[1,1024,14,14]},"Default/bn1/conv1.weight":{"edge_type":"data","scope":"polymeric_scope","shape":[64,3,7,7]},"Default/bn1/x":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]},"Default/bn1/x1":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]},"Default/bn1/x10":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]},"Default/bn1/x2":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]},"Default/bn1/x3":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]},"Default/bn1/x4":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]},"Default/bn1/x5":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]},"Default/bn1/x6":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]},"Default/bn1/x7":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]},"Default/bn1/x8":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]},"Default/bn1/x9":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]}},"name":"Default/bn1/Reshape1","output":{},"output_i":0,"polymeric_input":{"Default/bn1/Add50":{"edge_type":"data"},"Default/bn1/conv1.weight":{"edge_type":"data"},"Default/bn1/x":{"edge_type":"data"},"Default/bn1/x1":{"edge_type":"data"},"Default/bn1/x10":{"edge_type":"data"},"Default/bn1/x2":{"edge_type":"data"},"Default/bn1/x3":{"edge_type":"data"},"Default/bn1/x4":{"edge_type":"data"},"Default/bn1/x5":{"edge_type":"data"},"Default/bn1/x6":{"edge_type":"data"},"Default/bn1/x7":{"edge_type":"data"},"Default/bn1/x8":{"edge_type":"data"},"Default/bn1/x9":{"edge_type":"data"}},"polymeric_output":{},"polymeric_scope_name":"Default/bn1/Reshape_1_[12]","subnode_count":0,"type":"Reshape"},{"attr":{},"input":{"Default/bn1/Add51":{"edge_type":"data","scope":"polymeric_scope","shape":[1,1024,14,14]}},"name":"Default/bn1/Reshape2","output":{},"output_i":0,"polymeric_input":{"Default/bn1/Add51":{"edge_type":"data"}},"polymeric_output":{},"polymeric_scope_name":"Default/bn1/Reshape_1_[12]","subnode_count":0,"type":"Reshape"},{"attr":{},"input":{"Default/bn1/Add52":{"edge_type":"data","scope":"polymeric_scope","shape":[1,1024,14,14]}},"name":"Default/bn1/Reshape3","output":{},"output_i":0,"polymeric_input":{"Default/bn1/Add52":{"edge_type":"data"}},"polymeric_output":{},"polymeric_scope_name":"Default/bn1/Reshape_1_[12]","subnode_count":0,"type":"Reshape"},{"attr":{},"input":{"Default/bn1/Add53":{"edge_type":"data","scope":"polymeric_scope","shape":[1,1024,14,14]}},"name":"Default/bn1/Reshape4","output":{},"output_i":0,"polymeric_input":{"Default/bn1/Add53":{"edge_type":"data"}},"polymeric_output":{},"polymeric_scope_name":"Default/bn1/Reshape_1_[12]","subnode_count":0,"type":"Reshape"},{"attr":{},"input":{"Default/bn1/Add54":{"edge_type":"data","scope":"polymeric_scope","shape":[1,1024,14,14]}},"name":"Default/bn1/Reshape5","output":{},"output_i":0,"polymeric_input":{"Default/bn1/Add54":{"edge_type":"data"}},"polymeric_output":{},"polymeric_scope_name":"Default/bn1/Reshape_1_[12]","subnode_count":0,"type":"Reshape"},{"attr":{},"input":{"Default/bn1/x":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]}},"name":"Default/bn1/Reshape6","output":{},"output_i":0,"polymeric_input":{"Default/bn1/x":{"edge_type":"data"}},"polymeric_output":{},"polymeric_scope_name":"Default/bn1/Reshape_1_[12]","subnode_count":0,"type":"Reshape"},{"attr":{},"input":{"Default/bn1/x":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]}},"name":"Default/bn1/Reshape7","output":{},"output_i":0,"polymeric_input":{"Default/bn1/x":{"edge_type":"data"}},"polymeric_output":{},"polymeric_scope_name":"Default/bn1/Reshape_1_[12]","subnode_count":0,"type":"Reshape"},{"attr":{},"input":{"Default/bn1/x":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]}},"name":"Default/bn1/Reshape8","output":{},"output_i":0,"polymeric_input":{"Default/bn1/x":{"edge_type":"data"}},"polymeric_output":{},"polymeric_scope_name":"Default/bn1/Reshape_1_[12]","subnode_count":0,"type":"Reshape"},{"attr":{},"input":{"Default/bn1/x":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]}},"name":"Default/bn1/Reshape9","output":{},"output_i":0,"polymeric_input":{"Default/bn1/x":{"edge_type":"data"}},"polymeric_output":{},"polymeric_scope_name":"Default/bn1/Reshape_1_[12]","subnode_count":0,"type":"Reshape"},{"attr":{},"input":{"Default/bn1/x":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]}},"name":"Default/bn1/Reshape10","output":{},"output_i":0,"polymeric_input":{"Default/bn1/x":{"edge_type":"data"}},"polymeric_output":{},"polymeric_scope_name":"Default/bn1/Reshape_1_[12]","subnode_count":0,"type":"Reshape"},{"attr":{},"input":{"Default/bn1/x":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]}},"name":"Default/bn1/Reshape11","output":{},"output_i":0,"polymeric_input":{"Default/bn1/x":{"edge_type":"data"}},"polymeric_output":{},"polymeric_scope_name":"Default/bn1/Reshape_1_[12]","subnode_count":0,"type":"Reshape"},{"attr":{},"input":{"Default/bn1/x":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]}},"name":"Default/bn1/Reshape12","output":{},"output_i":0,"polymeric_input":{"Default/bn1/x":{"edge_type":"data"}},"polymeric_output":{},"polymeric_scope_name":"Default/bn1/Reshape_1_[12]","subnode_count":0,"type":"Reshape"}],"scope_name":"Default/bn1/Reshape_1_[12]"},"nodes":[{"attr":{},"input":{"Default/bn1/x11":{"edge_type":"data","scope":"name_scope","shape":[1,3,224,224]}},"name":"Default/bn1/Add50","output":{"Default/bn1/Reshape1":{"edge_type":"data","scope":"polymeric_scope","shape":[1,1024,14,14]}},"output_i":0,"polymeric_input":{},"polymeric_output":{"Default/bn1/Reshape_1_[12]":{"edge_type":"data"}},"polymeric_scope_name":"","subnode_count":0,"type":"Add"},{"attr":{},"input":{"Default/bn1/x11":{"edge_type":"data","scope":"name_scope","shape":[1,3,224,224]}},"name":"Default/bn1/Add51","output":{"Default/bn1/Reshape2":{"edge_type":"data","scope":"polymeric_scope","shape":[1,1024,14,14]}},"output_i":0,"polymeric_input":{},"polymeric_output":{"Default/bn1/Reshape_1_[12]":{"edge_type":"data"}},"polymeric_scope_name":"","subnode_count":0,"type":"Add"},{"attr":{},"input":{"Default/bn1/x11":{"edge_type":"data","scope":"name_scope","shape":[1,3,224,224]}},"name":"Default/bn1/Add52","output":{"Default/bn1/Reshape3":{"edge_type":"data","scope":"polymeric_scope","shape":[1,1024,14,14]}},"output_i":0,"polymeric_input":{},"polymeric_output":{"Default/bn1/Reshape_1_[12]":{"edge_type":"data"}},"polymeric_scope_name":"","subnode_count":0,"type":"Add"},{"attr":{},"input":{"Default/bn1/cst13":{"edge_type":"data","scope":"name_scope","shape":[]},"Default/bn1/x":{"edge_type":"data","scope":"name_scope","shape":[1,3,224,224]},"Default/bn1/x1":{"edge_type":"data","scope":"name_scope","shape":[1,3,224,224]},"Default/bn1/x10":{"edge_type":"data","scope":"name_scope","shape":[1,3,224,224]},"Default/bn1/x11":{"edge_type":"data","scope":"name_scope","shape":[1,3,224,224]},"Default/bn1/x2":{"edge_type":"data","scope":"name_scope","shape":[1,3,224,224]},"Default/bn1/x3":{"edge_type":"data","scope":"name_scope","shape":[1,3,224,224]},"Default/bn1/x4":{"edge_type":"data","scope":"name_scope","shape":[1,3,224,224]},"Default/bn1/x5":{"edge_type":"data","scope":"name_scope","shape":[1,3,224,224]},"Default/bn1/x6":{"edge_type":"data","scope":"name_scope","shape":[1,3,224,224]},"Default/bn1/x7":{"edge_type":"data","scope":"name_scope","shape":[1,3,224,224]},"Default/bn1/x8":{"edge_type":"data","scope":"name_scope","shape":[1,3,224,224]},"Default/bn1/x9":{"edge_type":"data","scope":"name_scope","shape":[1,3,224,224]}},"name":"Default/bn1/Add53","output":{"Default/bn1/Reshape4":{"edge_type":"data","scope":"polymeric_scope","shape":[1,1024,14,14]}},"output_i":0,"polymeric_input":{},"polymeric_output":{"Default/bn1/Reshape_1_[12]":{"edge_type":"data"}},"polymeric_scope_name":"","subnode_count":0,"type":"Add"},{"attr":{},"input":{"Default/bn1/x11":{"edge_type":"data","scope":"name_scope","shape":[1,3,224,224]}},"name":"Default/bn1/Add54","output":{"Default/bn1/Reshape5":{"edge_type":"data","scope":"polymeric_scope","shape":[1,1024,14,14]}},"output_i":0,"polymeric_input":{},"polymeric_output":{"Default/bn1/Reshape_1_[12]":{"edge_type":"data"}},"polymeric_scope_name":"","subnode_count":0,"type":"Add"},{"attr":{},"input":{},"name":"Default/bn1/x","output":{"Default/bn1/Add53":{"edge_type":"data","scope":"name_scope","shape":[1,3,224,224]},"Default/bn1/Reshape1":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]},"Default/bn1/Reshape10":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]},"Default/bn1/Reshape11":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]},"Default/bn1/Reshape12":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]},"Default/bn1/Reshape6":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]},"Default/bn1/Reshape7":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]},"Default/bn1/Reshape8":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]},"Default/bn1/Reshape9":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]}},"output_i":-1,"polymeric_input":{},"polymeric_output":{"Default/bn1/Reshape_1_[12]":{"edge_type":"data"}},"polymeric_scope_name":"","subnode_count":0,"type":"Parameter"},{"attr":{},"input":{},"name":"Default/bn1/x1","output":{"Default/bn1/Add53":{"edge_type":"data","scope":"name_scope","shape":[1,3,224,224]},"Default/bn1/Reshape1":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]}},"output_i":-1,"polymeric_input":{},"polymeric_output":{"Default/bn1/Reshape_1_[12]":{"edge_type":"data"}},"polymeric_scope_name":"","subnode_count":0,"type":"Parameter"},{"attr":{},"input":{},"name":"Default/bn1/x2","output":{"Default/bn1/Add53":{"edge_type":"data","scope":"name_scope","shape":[1,3,224,224]},"Default/bn1/Reshape1":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]}},"output_i":-1,"polymeric_input":{},"polymeric_output":{"Default/bn1/Reshape_1_[12]":{"edge_type":"data"}},"polymeric_scope_name":"","subnode_count":0,"type":"Parameter"},{"attr":{},"input":{},"name":"Default/bn1/x3","output":{"Default/bn1/Add53":{"edge_type":"data","scope":"name_scope","shape":[1,3,224,224]},"Default/bn1/Reshape1":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]}},"output_i":-1,"polymeric_input":{},"polymeric_output":{"Default/bn1/Reshape_1_[12]":{"edge_type":"data"}},"polymeric_scope_name":"","subnode_count":0,"type":"Parameter"},{"attr":{},"input":{},"name":"Default/bn1/x4","output":{"Default/bn1/Add53":{"edge_type":"data","scope":"name_scope","shape":[1,3,224,224]},"Default/bn1/Reshape1":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]}},"output_i":-1,"polymeric_input":{},"polymeric_output":{"Default/bn1/Reshape_1_[12]":{"edge_type":"data"}},"polymeric_scope_name":"","subnode_count":0,"type":"Parameter"},{"attr":{},"input":{},"name":"Default/bn1/x5","output":{"Default/bn1/Add53":{"edge_type":"data","scope":"name_scope","shape":[1,3,224,224]},"Default/bn1/Reshape1":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]}},"output_i":-1,"polymeric_input":{},"polymeric_output":{"Default/bn1/Reshape_1_[12]":{"edge_type":"data"}},"polymeric_scope_name":"","subnode_count":0,"type":"Parameter"},{"attr":{},"input":{},"name":"Default/bn1/x6","output":{"Default/bn1/Add53":{"edge_type":"data","scope":"name_scope","shape":[1,3,224,224]},"Default/bn1/Reshape1":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]}},"output_i":-1,"polymeric_input":{},"polymeric_output":{"Default/bn1/Reshape_1_[12]":{"edge_type":"data"}},"polymeric_scope_name":"","subnode_count":0,"type":"Parameter"},{"attr":{},"input":{},"name":"Default/bn1/x7","output":{"Default/bn1/Add53":{"edge_type":"data","scope":"name_scope","shape":[1,3,224,224]},"Default/bn1/Reshape1":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]}},"output_i":-1,"polymeric_input":{},"polymeric_output":{"Default/bn1/Reshape_1_[12]":{"edge_type":"data"}},"polymeric_scope_name":"","subnode_count":0,"type":"Parameter"},{"attr":{},"input":{},"name":"Default/bn1/x8","output":{"Default/bn1/Add53":{"edge_type":"data","scope":"name_scope","shape":[1,3,224,224]},"Default/bn1/Reshape1":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]}},"output_i":-1,"polymeric_input":{},"polymeric_output":{"Default/bn1/Reshape_1_[12]":{"edge_type":"data"}},"polymeric_scope_name":"","subnode_count":0,"type":"Parameter"},{"attr":{},"input":{},"name":"Default/bn1/x9","output":{"Default/bn1/Add53":{"edge_type":"data","scope":"name_scope","shape":[1,3,224,224]},"Default/bn1/Reshape1":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]}},"output_i":-1,"polymeric_input":{},"polymeric_output":{"Default/bn1/Reshape_1_[12]":{"edge_type":"data"}},"polymeric_scope_name":"","subnode_count":0,"type":"Parameter"},{"attr":{},"input":{},"name":"Default/bn1/x10","output":{"Default/bn1/Add53":{"edge_type":"data","scope":"name_scope","shape":[1,3,224,224]},"Default/bn1/Reshape1":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]}},"output_i":-1,"polymeric_input":{},"polymeric_output":{"Default/bn1/Reshape_1_[12]":{"edge_type":"data"}},"polymeric_scope_name":"","subnode_count":0,"type":"Parameter"},{"attr":{},"input":{},"name":"Default/bn1/conv1.weight","output":{"Default/bn1/Reshape1":{"edge_type":"data","scope":"polymeric_scope","shape":[64,3,7,7]}},"output_i":-1,"polymeric_input":{},"polymeric_output":{"Default/bn1/Reshape_1_[12]":{"edge_type":"data"}},"polymeric_scope_name":"","subnode_count":0,"type":"Parameter"},{"attr":{"cst13":"dtype: DT_INT32\nint_val: 0\n"},"input":{},"name":"Default/bn1/cst13","output":{},"output_i":-1,"polymeric_input":{},"polymeric_output":{},"polymeric_scope_name":"","subnode_count":0,"type":"Const"},{"attr":{},"input":{},"name":"Default/bn1/x11","output":{"Default/bn1/Add50":{"edge_type":"data","scope":"name_scope","shape":[1,3,224,224]},"Default/bn1/Add51":{"edge_type":"data","scope":"name_scope","shape":[1,3,224,224]},"Default/bn1/Add52":{"edge_type":"data","scope":"name_scope","shape":[1,3,224,224]},"Default/bn1/Add53":{"edge_type":"data","scope":"name_scope","shape":[1,3,224,224]},"Default/bn1/Add54":{"edge_type":"data","scope":"name_scope","shape":[1,3,224,224]}},"output_i":-1,"polymeric_input":{},"polymeric_output":{},"polymeric_scope_name":"","subnode_count":0,"type":"Parameter"},{"attr":{},"input":{"Default/bn1/Add50":{"edge_type":"data","scope":"polymeric_scope","shape":[1,1024,14,14]},"Default/bn1/Add51":{"edge_type":"data","scope":"polymeric_scope","shape":[1,1024,14,14]},"Default/bn1/Add52":{"edge_type":"data","scope":"polymeric_scope","shape":[1,1024,14,14]},"Default/bn1/Add53":{"edge_type":"data","scope":"polymeric_scope","shape":[1,1024,14,14]},"Default/bn1/Add54":{"edge_type":"data","scope":"polymeric_scope","shape":[1,1024,14,14]},"Default/bn1/conv1.weight":{"edge_type":"data","scope":"polymeric_scope","shape":[64,3,7,7]},"Default/bn1/x":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]},"Default/bn1/x1":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]},"Default/bn1/x10":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]},"Default/bn1/x2":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]},"Default/bn1/x3":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]},"Default/bn1/x4":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]},"Default/bn1/x5":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]},"Default/bn1/x6":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]},"Default/bn1/x7":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]},"Default/bn1/x8":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]},"Default/bn1/x9":{"edge_type":"data","scope":"polymeric_scope","shape":[1,3,224,224]}},"name":"Default/bn1/Reshape_1_[12]","output":{},"output_i":-1,"polymeric_input":{"Default/bn1/Add50":{"edge_type":"data"},"Default/bn1/Add51":{"edge_type":"data"},"Default/bn1/Add52":{"edge_type":"data"},"Default/bn1/Add53":{"edge_type":"data"},"Default/bn1/Add54":{"edge_type":"data"},"Default/bn1/conv1.weight":{"edge_type":"data"},"Default/bn1/x":{"edge_type":"data"},"Default/bn1/x1":{"edge_type":"data"},"Default/bn1/x10":{"edge_type":"data"},"Default/bn1/x2":{"edge_type":"data"},"Default/bn1/x3":{"edge_type":"data"},"Default/bn1/x4":{"edge_type":"data"},"Default/bn1/x5":{"edge_type":"data"},"Default/bn1/x6":{"edge_type":"data"},"Default/bn1/x7":{"edge_type":"data"},"Default/bn1/x8":{"edge_type":"data"},"Default/bn1/x9":{"edge_type":"data"}},"polymeric_output":{},"polymeric_scope_name":"","subnode_count":12,"type":"polymeric_scope"}],"scope_name":"Default/bn1"},"nodes":[{"attr":{},"input":{},"name":"Default/conv1-Conv2d","output":{},"output_i":-1,"polymeric_input":{},"polymeric_output":{},"polymeric_scope_name":"","subnode_count":1,"type":"name_scope"},{"attr":{},"input":{},"name":"Default/bn1-BatchNorm2d","output":{},"output_i":-1,"polymeric_input":{},"polymeric_output":{},"polymeric_scope_name":"","subnode_count":14,"type":"name_scope"},{"attr":{},"input":{},"name":"Default/bn1","output":{},"output_i":-1,"polymeric_input":{},"polymeric_output":{},"polymeric_scope_name":"","subnode_count":20,"type":"name_scope"}],"scope_name":"Default"},"nodes":[{"attr":{},"input":{},"name":"Default","output":{},"output_i":-1,"polymeric_input":{},"polymeric_output":{},"polymeric_scope_name":"","subnode_count":3,"type":"name_scope"}],"scope_name":""}
{"children":{"children":{},"nodes":[{"attr":{},"independent_layout":false,"input":{},"name":"Default/conv1-Conv2d","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":{},"proxy_output":{},"subnode_count":2,"type":"name_scope"},{"attr":{},"independent_layout":false,"input":{},"name":"Default/bn1-BatchNorm2d","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":{},"proxy_output":{},"subnode_count":5,"type":"name_scope"},{"attr":{},"independent_layout":false,"input":{"Default/bn1-BatchNorm2d/tuple_getitem56":{"data_type":"DT_STRING","edge_type":"data","independent_layout":false,"shape":[1,128,28,28]},"Default/conv1-Conv2d/Conv2D55":{"data_type":"DT_STRING","edge_type":"data","independent_layout":false,"shape":[1,64,112,112]}},"name":"Default/bn1","output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":4,"type":"name_scope"}],"scope_name":"Default"},"nodes":[{"attr":{},"independent_layout":false,"input":{},"name":"Default","output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":3,"type":"name_scope"}],"scope_name":""}
\ No newline at end of file
{"names":["Default/bn1/Reshape1","Default/bn1/Reshape10","Default/bn1/Reshape11","Default/bn1/Reshape12","Default/bn1/Reshape2","Default/bn1/Reshape3","Default/bn1/Reshape4","Default/bn1/Reshape5","Default/bn1/Reshape6","Default/bn1/Reshape7","Default/bn1/Reshape8","Default/bn1/Reshape9","Default/bn1/Reshape_1_[12]"]}
{"names":["Default/bn1","Default/bn1-BatchNorm2d","Default/bn1-BatchNorm2d/Parameter[22]_3","Default/bn1-BatchNorm2d/Parameter[22]_3/conv1.weight","Default/bn1-BatchNorm2d/Parameter[22]_3/x","Default/bn1-BatchNorm2d/Parameter[22]_3/x1","Default/bn1-BatchNorm2d/Parameter[22]_3/x10","Default/bn1-BatchNorm2d/Parameter[22]_3/x11","Default/bn1-BatchNorm2d/Parameter[22]_3/x12","Default/bn1-BatchNorm2d/Parameter[22]_3/x13","Default/bn1-BatchNorm2d/Parameter[22]_3/x14","Default/bn1-BatchNorm2d/Parameter[22]_3/x15","Default/bn1-BatchNorm2d/Parameter[22]_3/x16","Default/bn1-BatchNorm2d/Parameter[22]_3/x17","Default/bn1-BatchNorm2d/Parameter[22]_3/x18","Default/bn1-BatchNorm2d/Parameter[22]_3/x19","Default/bn1-BatchNorm2d/Parameter[22]_3/x2","Default/bn1-BatchNorm2d/Parameter[22]_3/x20","Default/bn1-BatchNorm2d/Parameter[22]_3/x3","Default/bn1-BatchNorm2d/Parameter[22]_3/x4","Default/bn1-BatchNorm2d/Parameter[22]_3/x5","Default/bn1-BatchNorm2d/Parameter[22]_3/x6","Default/bn1-BatchNorm2d/Parameter[22]_3/x7","Default/bn1-BatchNorm2d/Parameter[22]_3/x8","Default/bn1-BatchNorm2d/Parameter[22]_3/x9","Default/bn1-BatchNorm2d/cst13","Default/bn1-BatchNorm2d/cst25","Default/bn1-BatchNorm2d/tuple_getitem105","Default/bn1-BatchNorm2d/tuple_getitem56","Default/bn1/Add[5]_0","Default/bn1/Add[5]_0/Add50","Default/bn1/Add[5]_0/Add51","Default/bn1/Add[5]_0/Add52","Default/bn1/Add[5]_0/Add53","Default/bn1/Add[5]_0/Add54","Default/bn1/Reshape[12]_1","Default/bn1/Reshape[12]_1/Reshape1","Default/bn1/Reshape[12]_1/Reshape10","Default/bn1/Reshape[12]_1/Reshape11","Default/bn1/Reshape[12]_1/Reshape12","Default/bn1/Reshape[12]_1/Reshape2","Default/bn1/Reshape[12]_1/Reshape3","Default/bn1/Reshape[12]_1/Reshape4","Default/bn1/Reshape[12]_1/Reshape5","Default/bn1/Reshape[12]_1/Reshape6","Default/bn1/Reshape[12]_1/Reshape7","Default/bn1/Reshape[12]_1/Reshape8","Default/bn1/Reshape[12]_1/Reshape9","Default/bn1/x","Default/bn1/x11"]}
\ No newline at end of file
......@@ -40,22 +40,17 @@ class TestQueryNodes:
@pytest.mark.platform_x86_gpu_training
@pytest.mark.platform_x86_ascend_training
@pytest.mark.usefixtures("init_summary_logs")
@pytest.mark.parametrize("node_name, node_type, result_file", [
('', "name_scope", "test_query_nodes_success_result2.json"),
("Default", "name_scope", "test_query_nodes_success_result1.json"),
("Default/bn1/Reshape_1_[12]", "polymeric_scope", "test_query_nodes_success_result3.json")
@pytest.mark.parametrize("node_name, result_file", [
('', "test_query_nodes_success_result1.json"),
("Default", "test_query_nodes_success_result2.json"),
("Default/bn1/Reshape[12]_1", "test_query_nodes_success_result3.json")
])
def test_query_namescope_success(self, client, node_name, node_type, result_file):
def test_list_node_success(self, client, node_name, result_file):
"""Query the name scope node."""
train_id = gbl.get_train_ids()[0]
if node_name:
params = dict(train_id=train_id,
type=node_type,
name=node_name)
else:
params = dict(train_id=train_id,
type=node_type)
params = dict(train_id=train_id,
name=node_name)
url = get_url(BASE_URL, params)
response = client.get(url)
assert response.status_code == 200
......
......@@ -41,7 +41,7 @@ class TestQuerySingleNode:
@pytest.mark.platform_x86_ascend_training
@pytest.mark.usefixtures("init_summary_logs")
@pytest.mark.parametrize("node_name, result_file", [
('Default/bn1/Reshape1', "test_query_single_node_success_result1.json")
('Default/bn1', "test_query_single_node_success_result1.json")
])
def test_query_single_node_success(self, client, node_name, result_file):
"""Query single node."""
......
......@@ -41,7 +41,7 @@ class TestSearchNodes:
@pytest.mark.platform_x86_ascend_training
@pytest.mark.usefixtures("init_summary_logs")
@pytest.mark.parametrize("search_content, offset, limit, result_file", [
('Default/bn1/Reshape', 0, 1000, "test_search_nodes_success_result1.json")
('Default/bn1', 0, 1000, "test_search_nodes_success_result1.json")
])
def test_search_nodes_success(self, client, search_content, offset, limit, result_file):
"""Search node with parameters: offset is 0, limit is 1000."""
......
......@@ -22,7 +22,6 @@ from unittest.mock import Mock, patch
import pytest
from mindinsight.datavisual.data_transform.graph import NodeTypeEnum
from mindinsight.datavisual.processors.graph_processor import GraphProcessor
from mindinsight.datavisual.processors.images_processor import ImageProcessor
from mindinsight.datavisual.processors.scalars_processor import ScalarsProcessor
......@@ -227,47 +226,27 @@ class TestTrainVisual:
assert results['error_msg'] == "Param missing. 'train_id' is required."
@patch.object(GraphProcessor, '__init__')
def test_graph_nodes_with_type_is_invalid(self, mock_graph_processor, client):
"""Test getting graph nodes with invalid type."""
mock_init = Mock(return_value=None)
mock_graph_processor.side_effect = mock_init
node_type = "invalid_node_type"
params = dict(train_id='aaa', type=node_type)
url = get_url(TRAIN_ROUTES['graph_nodes'], params)
response = client.get(url)
results = response.get_json()
assert response.status_code == 400
assert results['error_code'] == '50540002'
assert results['error_msg'] == "Invalid parameter value. The node type " \
"is not support, only either %s or %s." \
"" % (NodeTypeEnum.NAME_SCOPE.value,
NodeTypeEnum.POLYMERIC_SCOPE.value)
@patch.object(GraphProcessor, '__init__')
@patch.object(GraphProcessor, 'get_nodes')
def test_graph_nodes_success(self, mock_graph_processor, mock_graph_processor_1, client):
@patch.object(GraphProcessor, 'list_nodes')
def test_graph_nodes_success(self, mock_list_nodes_func, mock_init_func, client):
"""Test getting graph nodes successfully."""
def mock_get_nodes(name, node_type):
return dict(name=name, node_type=node_type)
def mock_list_nodes(scope):
return dict(scope=scope)
mock_graph_processor.side_effect = mock_get_nodes
mock_list_nodes_func.side_effect = mock_list_nodes
mock_init = Mock(return_value=None)
mock_graph_processor_1.side_effect = mock_init
mock_init_func.side_effect = mock_init
test_train_id = 'aaa'
test_node_name = 'bbb'
test_node_type = NodeTypeEnum.NAME_SCOPE.value
params = dict(train_id=test_train_id, name=test_node_name, type=test_node_type)
params = dict(train_id=test_train_id, name=test_node_name)
url = get_url(TRAIN_ROUTES['graph_nodes'], params)
response = client.get(url)
assert response.status_code == 200
results = response.get_json()
assert results == dict(name=test_node_name, node_type=test_node_type)
assert results == dict(scope=test_node_name)
def test_graph_node_names_with_train_id_is_none(self, client):
"""Test getting graph node names with train id is none."""
......
{
"nodes" : [
{
"attr" : {},
"input" : {},
"name" : "Default",
"output" : {},
"output_i" : -1,
"polymeric_input" : {},
"polymeric_output" : {},
"polymeric_scope_name" : "",
"subnode_count" : 3,
"type" : "name_scope"
}
]
}
{"nodes":[{"attr":{},"independent_layout":false,"input":{},"name":"Default","output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":3,"type":"name_scope"}]}
\ 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"
},
"input" : {},
"name" : "Default/conv1-Conv2d/Conv2D1",
"output" : {},
"output_i" : 0,
"polymeric_input" : {},
"polymeric_output" : {},
"polymeric_scope_name" : "",
"subnode_count" : 0,
"type" : "Conv2D"
}
]
}
\ 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"}]}
\ No newline at end of file
{
"nodes" : [
{
"attr" : {},
"input" :
{
"Default/bn1/Add50" :
{
"edge_type" : "data",
"scope" : "polymeric_scope",
"shape" : [1, 1024, 14, 14]
},
"Default/bn1/conv1.weight" :
{
"edge_type" : "data",
"scope" : "polymeric_scope",
"shape" : [64, 3, 7, 7]
},
"Default/bn1/x" :
{
"edge_type" : "data",
"scope" : "polymeric_scope",
"shape" : [1, 3, 224, 224]
},
"Default/bn1/x1" :
{
"edge_type" : "data",
"scope" : "polymeric_scope",
"shape" : [1, 3, 224, 224]
},
"Default/bn1/x10" :
{
"edge_type" : "data",
"scope" : "polymeric_scope",
"shape" : [1, 3, 224, 224]
},
"Default/bn1/x2" :
{
"edge_type" : "data",
"scope" : "polymeric_scope",
"shape" : [1, 3, 224, 224]
},
"Default/bn1/x3" :
{
"edge_type" : "data",
"scope" : "polymeric_scope",
"shape" : [1, 3, 224, 224]
},
"Default/bn1/x4" :
{
"edge_type" : "data",
"scope" : "polymeric_scope",
"shape" : [1, 3, 224, 224]
},
"Default/bn1/x5" :
{
"edge_type" : "data",
"scope" : "polymeric_scope",
"shape" : [1, 3, 224, 224]
},
"Default/bn1/x6" :
{
"edge_type" : "data",
"scope" : "polymeric_scope",
"shape" : [1, 3, 224, 224]
},
"Default/bn1/x7" :
{
"edge_type" : "data",
"scope" : "polymeric_scope",
"shape" : [1, 3, 224, 224]
},
"Default/bn1/x8" :
{
"edge_type" : "data",
"scope" : "polymeric_scope",
"shape" : [1, 3, 224, 224]
},
"Default/bn1/x9" :
{
"edge_type" : "data",
"scope" : "polymeric_scope",
"shape" : [1, 3, 224, 224]
}
},
"name" : "Default/bn1/Reshape1",
"output" : {},
"output_i" : 0,
"polymeric_input" :
{
"Default/bn1/Add50" :
{
"edge_type" : "data"
},
"Default/bn1/conv1.weight" :
{
"edge_type" : "data"
},
"Default/bn1/x" :
{
"edge_type" : "data"
},
"Default/bn1/x1" :
{
"edge_type" : "data"
},
"Default/bn1/x10" :
{
"edge_type" : "data"
},
"Default/bn1/x2" :
{
"edge_type" : "data"
},
"Default/bn1/x3" :
{
"edge_type" : "data"
},
"Default/bn1/x4" :
{
"edge_type" : "data"
},
"Default/bn1/x5" :
{
"edge_type" : "data"
},
"Default/bn1/x6" :
{
"edge_type" : "data"
},
"Default/bn1/x7" :
{
"edge_type" : "data"
},
"Default/bn1/x8" :
{
"edge_type" : "data"
},
"Default/bn1/x9" :
{
"edge_type" : "data"
}
},
"polymeric_output" : {},
"polymeric_scope_name" : "Default/bn1/Reshape_1_[12]",
"subnode_count" : 0,
"type" : "Reshape"
},
{
"attr" : {},
"input" :
{
"Default/bn1/Add51" :
{
"edge_type" : "data",
"scope" : "polymeric_scope",
"shape" : [1, 1024, 14, 14]
}
},
"name" : "Default/bn1/Reshape2",
"output" : {},
"output_i" : 0,
"polymeric_input" :
{
"Default/bn1/Add51" :
{
"edge_type" : "data"
}
},
"polymeric_output" : {},
"polymeric_scope_name" : "Default/bn1/Reshape_1_[12]",
"subnode_count" : 0,
"type" : "Reshape"
},
{
"attr" : {},
"input" :
{
"Default/bn1/Add52" :
{
"edge_type" : "data",
"scope" : "polymeric_scope",
"shape" : [1, 1024, 14, 14]
}
},
"name" : "Default/bn1/Reshape3",
"output" : {},
"output_i" : 0,
"polymeric_input" :
{
"Default/bn1/Add52" :
{
"edge_type" : "data"
}
},
"polymeric_output" : {},
"polymeric_scope_name" : "Default/bn1/Reshape_1_[12]",
"subnode_count" : 0,
"type" : "Reshape"
},
{
"attr" : {},
"input" :
{
"Default/bn1/Add53" :
{
"edge_type" : "data",
"scope" : "polymeric_scope",
"shape" : [1, 1024, 14, 14]
}
},
"name" : "Default/bn1/Reshape4",
"output" : {},
"output_i" : 0,
"polymeric_input" :
{
"Default/bn1/Add53" :
{
"edge_type" : "data"
}
},
"polymeric_output" : {},
"polymeric_scope_name" : "Default/bn1/Reshape_1_[12]",
"subnode_count" : 0,
"type" : "Reshape"
},
{
"attr" : {},
"input" :
{
"Default/bn1/Add54" :
{
"edge_type" : "data",
"scope" : "polymeric_scope",
"shape" : [1, 1024, 14, 14]
}
},
"name" : "Default/bn1/Reshape5",
"output" : {},
"output_i" : 0,
"polymeric_input" :
{
"Default/bn1/Add54" :
{
"edge_type" : "data"
}
},
"polymeric_output" : {},
"polymeric_scope_name" : "Default/bn1/Reshape_1_[12]",
"subnode_count" : 0,
"type" : "Reshape"
},
{
"attr" : {},
"input" :
{
"Default/bn1/x" :
{
"edge_type" : "data",
"scope" : "polymeric_scope",
"shape" : [1, 3, 224, 224]
}
},
"name" : "Default/bn1/Reshape6",
"output" : {},
"output_i" : 0,
"polymeric_input" :
{
"Default/bn1/x" :
{
"edge_type" : "data"
}
},
"polymeric_output" : {},
"polymeric_scope_name" : "Default/bn1/Reshape_1_[12]",
"subnode_count" : 0,
"type" : "Reshape"
},
{
"attr" : {},
"input" :
{
"Default/bn1/x" :
{
"edge_type" : "data",
"scope" : "polymeric_scope",
"shape" : [1, 3, 224, 224]
}
},
"name" : "Default/bn1/Reshape7",
"output" : {},
"output_i" : 0,
"polymeric_input" :
{
"Default/bn1/x" :
{
"edge_type" : "data"
}
},
"polymeric_output" : {},
"polymeric_scope_name" : "Default/bn1/Reshape_1_[12]",
"subnode_count" : 0,
"type" : "Reshape"
},
{
"attr" : {},
"input" :
{
"Default/bn1/x" :
{
"edge_type" : "data",
"scope" : "polymeric_scope",
"shape" : [1, 3, 224, 224]
}
},
"name" : "Default/bn1/Reshape8",
"output" : {},
"output_i" : 0,
"polymeric_input" :
{
"Default/bn1/x" :
{
"edge_type" : "data"
}
},
"polymeric_output" : {},
"polymeric_scope_name" : "Default/bn1/Reshape_1_[12]",
"subnode_count" : 0,
"type" : "Reshape"
},
{
"attr" : {},
"input" :
{
"Default/bn1/x" :
{
"edge_type" : "data",
"scope" : "polymeric_scope",
"shape" : [1, 3, 224, 224]
}
},
"name" : "Default/bn1/Reshape9",
"output" : {},
"output_i" : 0,
"polymeric_input" :
{
"Default/bn1/x" :
{
"edge_type" : "data"
}
},
"polymeric_output" : {},
"polymeric_scope_name" : "Default/bn1/Reshape_1_[12]",
"subnode_count" : 0,
"type" : "Reshape"
},
{
"attr" : {},
"input" :
{
"Default/bn1/x" :
{
"edge_type" : "data",
"scope" : "polymeric_scope",
"shape" : [1, 3, 224, 224]
}
},
"name" : "Default/bn1/Reshape10",
"output" : {},
"output_i" : 0,
"polymeric_input" :
{
"Default/bn1/x" :
{
"edge_type" : "data"
}
},
"polymeric_output" : {},
"polymeric_scope_name" : "Default/bn1/Reshape_1_[12]",
"subnode_count" : 0,
"type" : "Reshape"
},
{
"attr" : {},
"input" :
{
"Default/bn1/x" :
{
"edge_type" : "data",
"scope" : "polymeric_scope",
"shape" : [1, 3, 224, 224]
}
},
"name" : "Default/bn1/Reshape11",
"output" : {},
"output_i" : 0,
"polymeric_input" :
{
"Default/bn1/x" :
{
"edge_type" : "data"
}
},
"polymeric_output" : {},
"polymeric_scope_name" : "Default/bn1/Reshape_1_[12]",
"subnode_count" : 0,
"type" : "Reshape"
},
{
"attr" : {},
"input" :
{
"Default/bn1/x" :
{
"edge_type" : "data",
"scope" : "polymeric_scope",
"shape" : [1, 3, 224, 224]
}
},
"name" : "Default/bn1/Reshape12",
"output" : {},
"output_i" : 0,
"polymeric_input" :
{
"Default/bn1/x" :
{
"edge_type" : "data"
}
},
"polymeric_output" : {},
"polymeric_scope_name" : "Default/bn1/Reshape_1_[12]",
"subnode_count" : 0,
"type" : "Reshape"
}
]
}
{"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"}]}
\ 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"}]}
\ No newline at end of file
{"names":["Default/bn1-BatchNorm2d/cst25","Default/bn1-BatchNorm2d/tuple_getitem105","Default/bn1-BatchNorm2d/tuple_getitem53"]}
\ No newline at end of file
{"names":["Default/bn1-BatchNorm2d/Parameter[22]_3/conv1.weight","Default/bn1-BatchNorm2d/Parameter[22]_3/x","Default/bn1-BatchNorm2d/Parameter[22]_3/x1"]}
\ No newline at end of file
{
"names" : ["Default", "Default/bn1", "Default/bn1-BatchNorm2d", "Default/bn1-BatchNorm2d/conv1.weight", "Default/bn1-BatchNorm2d/cst25", "Default/bn1-BatchNorm2d/tuple_getitem105", "Default/bn1-BatchNorm2d/tuple_getitem53", "Default/bn1-BatchNorm2d/x11", "Default/bn1-BatchNorm2d/x12", "Default/bn1-BatchNorm2d/x13", "Default/bn1-BatchNorm2d/x14", "Default/bn1-BatchNorm2d/x15", "Default/bn1-BatchNorm2d/x16", "Default/bn1-BatchNorm2d/x17", "Default/bn1-BatchNorm2d/x18", "Default/bn1-BatchNorm2d/x19", "Default/bn1-BatchNorm2d/x20", "Default/bn1/Add50", "Default/bn1/Add51", "Default/bn1/Add52", "Default/bn1/Add53", "Default/bn1/Add54", "Default/bn1/Reshape1", "Default/bn1/Reshape10", "Default/bn1/Reshape11", "Default/bn1/Reshape12", "Default/bn1/Reshape2", "Default/bn1/Reshape3", "Default/bn1/Reshape4", "Default/bn1/Reshape5", "Default/bn1/Reshape6", "Default/bn1/Reshape7", "Default/bn1/Reshape8", "Default/bn1/Reshape9", "Default/bn1/Reshape_1_[12]", "Default/bn1/conv1.weight", "Default/bn1/cst13", "Default/bn1/x", "Default/bn1/x1", "Default/bn1/x10", "Default/bn1/x11", "Default/bn1/x2", "Default/bn1/x3", "Default/bn1/x4", "Default/bn1/x5", "Default/bn1/x6", "Default/bn1/x7", "Default/bn1/x8", "Default/bn1/x9", "Default/conv1-Conv2d", "Default/conv1-Conv2d/Conv2D1"]
}
\ No newline at end of file
{"names":["Default","Default/bn1","Default/bn1-BatchNorm2d","Default/bn1-BatchNorm2d/Parameter[22]_3","Default/bn1-BatchNorm2d/Parameter[22]_3/conv1.weight","Default/bn1-BatchNorm2d/Parameter[22]_3/x","Default/bn1-BatchNorm2d/Parameter[22]_3/x1","Default/bn1-BatchNorm2d/Parameter[22]_3/x10","Default/bn1-BatchNorm2d/Parameter[22]_3/x11","Default/bn1-BatchNorm2d/Parameter[22]_3/x12","Default/bn1-BatchNorm2d/Parameter[22]_3/x13","Default/bn1-BatchNorm2d/Parameter[22]_3/x14","Default/bn1-BatchNorm2d/Parameter[22]_3/x15","Default/bn1-BatchNorm2d/Parameter[22]_3/x16","Default/bn1-BatchNorm2d/Parameter[22]_3/x17","Default/bn1-BatchNorm2d/Parameter[22]_3/x18","Default/bn1-BatchNorm2d/Parameter[22]_3/x19","Default/bn1-BatchNorm2d/Parameter[22]_3/x2","Default/bn1-BatchNorm2d/Parameter[22]_3/x20","Default/bn1-BatchNorm2d/Parameter[22]_3/x3","Default/bn1-BatchNorm2d/Parameter[22]_3/x4","Default/bn1-BatchNorm2d/Parameter[22]_3/x5","Default/bn1-BatchNorm2d/Parameter[22]_3/x6","Default/bn1-BatchNorm2d/Parameter[22]_3/x7","Default/bn1-BatchNorm2d/Parameter[22]_3/x8","Default/bn1-BatchNorm2d/Parameter[22]_3/x9","Default/bn1-BatchNorm2d/cst13","Default/bn1-BatchNorm2d/cst25","Default/bn1-BatchNorm2d/tuple_getitem105","Default/bn1-BatchNorm2d/tuple_getitem56","Default/bn1/Add[5]_0","Default/bn1/Add[5]_0/Add50","Default/bn1/Add[5]_0/Add51","Default/bn1/Add[5]_0/Add52","Default/bn1/Add[5]_0/Add53","Default/bn1/Add[5]_0/Add54","Default/bn1/Reshape[12]_1","Default/bn1/Reshape[12]_1/Reshape1","Default/bn1/Reshape[12]_1/Reshape10","Default/bn1/Reshape[12]_1/Reshape11","Default/bn1/Reshape[12]_1/Reshape12","Default/bn1/Reshape[12]_1/Reshape2","Default/bn1/Reshape[12]_1/Reshape3","Default/bn1/Reshape[12]_1/Reshape4","Default/bn1/Reshape[12]_1/Reshape5","Default/bn1/Reshape[12]_1/Reshape6","Default/bn1/Reshape[12]_1/Reshape7","Default/bn1/Reshape[12]_1/Reshape8","Default/bn1/Reshape[12]_1/Reshape9","Default/bn1/x","Default/bn1/x11","Default/conv1-Conv2d","Default/conv1-Conv2d/Conv2D55","Default/conv1-Conv2d/Parameter[12]_2","Default/conv1-Conv2d/Parameter[12]_2/conv1.weight","Default/conv1-Conv2d/Parameter[12]_2/x","Default/conv1-Conv2d/Parameter[12]_2/x1","Default/conv1-Conv2d/Parameter[12]_2/x10","Default/conv1-Conv2d/Parameter[12]_2/x2","Default/conv1-Conv2d/Parameter[12]_2/x3","Default/conv1-Conv2d/Parameter[12]_2/x4","Default/conv1-Conv2d/Parameter[12]_2/x5","Default/conv1-Conv2d/Parameter[12]_2/x6","Default/conv1-Conv2d/Parameter[12]_2/x7","Default/conv1-Conv2d/Parameter[12]_2/x8","Default/conv1-Conv2d/Parameter[12]_2/x9"]}
\ No newline at end of file
{"names":["Default/bn1","Default/bn1-BatchNorm2d","Default/bn1-BatchNorm2d/conv1.weight","Default/bn1-BatchNorm2d/cst25","Default/bn1-BatchNorm2d/tuple_getitem105","Default/bn1-BatchNorm2d/tuple_getitem53","Default/bn1-BatchNorm2d/x11","Default/bn1-BatchNorm2d/x12","Default/bn1-BatchNorm2d/x13","Default/bn1-BatchNorm2d/x14","Default/bn1-BatchNorm2d/x15","Default/bn1-BatchNorm2d/x16","Default/bn1-BatchNorm2d/x17","Default/bn1-BatchNorm2d/x18","Default/bn1-BatchNorm2d/x19","Default/bn1-BatchNorm2d/x20","Default/bn1/Add50","Default/bn1/Add51","Default/bn1/Add52","Default/bn1/Add53","Default/bn1/Add54","Default/bn1/Reshape1","Default/bn1/Reshape10","Default/bn1/Reshape11","Default/bn1/Reshape12","Default/bn1/Reshape2","Default/bn1/Reshape3","Default/bn1/Reshape4","Default/bn1/Reshape5","Default/bn1/Reshape6","Default/bn1/Reshape7","Default/bn1/Reshape8","Default/bn1/Reshape9","Default/bn1/Reshape_1_[12]","Default/bn1/conv1.weight","Default/bn1/cst13","Default/bn1/x","Default/bn1/x1","Default/bn1/x10","Default/bn1/x11","Default/bn1/x2","Default/bn1/x3","Default/bn1/x4","Default/bn1/x5","Default/bn1/x6","Default/bn1/x7","Default/bn1/x8","Default/bn1/x9"]}
{"names":["Default/bn1","Default/bn1-BatchNorm2d","Default/bn1-BatchNorm2d/Parameter[22]_3","Default/bn1-BatchNorm2d/Parameter[22]_3/conv1.weight","Default/bn1-BatchNorm2d/Parameter[22]_3/x","Default/bn1-BatchNorm2d/Parameter[22]_3/x1","Default/bn1-BatchNorm2d/Parameter[22]_3/x10","Default/bn1-BatchNorm2d/Parameter[22]_3/x11","Default/bn1-BatchNorm2d/Parameter[22]_3/x12","Default/bn1-BatchNorm2d/Parameter[22]_3/x13","Default/bn1-BatchNorm2d/Parameter[22]_3/x14","Default/bn1-BatchNorm2d/Parameter[22]_3/x15","Default/bn1-BatchNorm2d/Parameter[22]_3/x16","Default/bn1-BatchNorm2d/Parameter[22]_3/x17","Default/bn1-BatchNorm2d/Parameter[22]_3/x18","Default/bn1-BatchNorm2d/Parameter[22]_3/x19","Default/bn1-BatchNorm2d/Parameter[22]_3/x2","Default/bn1-BatchNorm2d/Parameter[22]_3/x20","Default/bn1-BatchNorm2d/Parameter[22]_3/x3","Default/bn1-BatchNorm2d/Parameter[22]_3/x4","Default/bn1-BatchNorm2d/Parameter[22]_3/x5","Default/bn1-BatchNorm2d/Parameter[22]_3/x6","Default/bn1-BatchNorm2d/Parameter[22]_3/x7","Default/bn1-BatchNorm2d/Parameter[22]_3/x8","Default/bn1-BatchNorm2d/Parameter[22]_3/x9","Default/bn1-BatchNorm2d/cst13","Default/bn1-BatchNorm2d/cst25","Default/bn1-BatchNorm2d/tuple_getitem105","Default/bn1-BatchNorm2d/tuple_getitem56","Default/bn1/Add[5]_0","Default/bn1/Add[5]_0/Add50","Default/bn1/Add[5]_0/Add51","Default/bn1/Add[5]_0/Add52","Default/bn1/Add[5]_0/Add53","Default/bn1/Add[5]_0/Add54","Default/bn1/Reshape[12]_1","Default/bn1/Reshape[12]_1/Reshape1","Default/bn1/Reshape[12]_1/Reshape10","Default/bn1/Reshape[12]_1/Reshape11","Default/bn1/Reshape[12]_1/Reshape12","Default/bn1/Reshape[12]_1/Reshape2","Default/bn1/Reshape[12]_1/Reshape3","Default/bn1/Reshape[12]_1/Reshape4","Default/bn1/Reshape[12]_1/Reshape5","Default/bn1/Reshape[12]_1/Reshape6","Default/bn1/Reshape[12]_1/Reshape7","Default/bn1/Reshape[12]_1/Reshape8","Default/bn1/Reshape[12]_1/Reshape9","Default/bn1/x","Default/bn1/x11"]}
\ No newline at end of file
{"children":{"children":{},"nodes":[{"attr":{},"input":{},"name":"Default/conv1-Conv2d","output":{},"output_i":-1,"polymeric_input":{},"polymeric_output":{},"polymeric_scope_name":"","subnode_count":1,"type":"name_scope"},{"attr":{},"input":{},"name":"Default/bn1-BatchNorm2d","output":{},"output_i":-1,"polymeric_input":{},"polymeric_output":{},"polymeric_scope_name":"","subnode_count":14,"type":"name_scope"},{"attr":{},"input":{},"name":"Default/bn1","output":{},"output_i":-1,"polymeric_input":{},"polymeric_output":{},"polymeric_scope_name":"","subnode_count":20,"type":"name_scope"}],"scope_name":"Default"},"nodes":[{"attr":{},"input":{},"name":"Default","output":{},"output_i":-1,"polymeric_input":{},"polymeric_output":{},"polymeric_scope_name":"","subnode_count":3,"type":"name_scope"}],"scope_name":""}
{"children":{"children":{},"nodes":[{"attr":{},"independent_layout":false,"input":{},"name":"Default/conv1-Conv2d","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":{},"proxy_output":{},"subnode_count":2,"type":"name_scope"},{"attr":{},"independent_layout":false,"input":{},"name":"Default/bn1-BatchNorm2d","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":{},"proxy_output":{},"subnode_count":5,"type":"name_scope"},{"attr":{},"independent_layout":false,"input":{"Default/bn1-BatchNorm2d/tuple_getitem56":{"data_type":"DT_STRING","edge_type":"data","independent_layout":false,"shape":[1,128,28,28]},"Default/conv1-Conv2d/Conv2D55":{"data_type":"DT_STRING","edge_type":"data","independent_layout":false,"shape":[1,64,112,112]}},"name":"Default/bn1","output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":4,"type":"name_scope"}],"scope_name":"Default"},"nodes":[{"attr":{},"independent_layout":false,"input":{},"name":"Default","output":{},"output_i":0,"proxy_input":{},"proxy_output":{},"subnode_count":3,"type":"name_scope"}],"scope_name":""}
\ No newline at end of file
......@@ -118,26 +118,27 @@ class TestGraphProcessor:
assert mock_get_train_job_by_plugin.called
@pytest.mark.usefixtures('load_graph_record')
@pytest.mark.parametrize("name, node_type", [("not_exist_name", "name_scope"), ("", "polymeric_scope")])
def test_get_nodes_with_not_exist_name(self, name, node_type):
@pytest.mark.parametrize("name", ["not_exist_name"])
def test_get_nodes_with_not_exist_name(self, name):
"""Test getting nodes with not exist name."""
with pytest.raises(NodeNotInGraphError) as exc_info:
graph_processor = GraphProcessor(self._train_id, self._mock_data_manager)
graph_processor.get_nodes(name, node_type)
graph_processor.list_nodes(name)
assert 'Can not find node in graph by the given node name' in exc_info.value.message
@pytest.mark.usefixtures('load_graph_record')
@pytest.mark.parametrize(
"name, node_type, result_file",
[(None, 'name_scope', 'test_get_nodes_success_expected_results1.json'),
('Default/conv1-Conv2d', 'name_scope', 'test_get_nodes_success_expected_results2.json'),
('Default/bn1/Reshape_1_[12]', 'polymeric_scope', 'test_get_nodes_success_expected_results3.json')])
def test_get_nodes_success(self, name, node_type, result_file):
"name, result_file",
[(None, 'test_get_nodes_success_expected_results1.json'),
('Default/conv1-Conv2d', 'test_get_nodes_success_expected_results2.json'),
('Default/bn1/Reshape[12]_1', 'test_get_nodes_success_expected_results3.json'),
('Default/bn1-BatchNorm2d', 'test_get_nodes_success_expected_results4.json'),
])
def test_get_nodes_success(self, name, result_file):
"""Test getting nodes successfully."""
graph_processor = GraphProcessor(self._train_id, self._mock_data_manager)
results = graph_processor.get_nodes(name, node_type)
results = graph_processor.list_nodes(name)
expected_file_path = os.path.join(self.graph_results_dir, result_file)
compare_result_with_file(results, expected_file_path)
......
{
"node": [
{
"input": [
{
"name": "data",
"type": "DATA_EDGE"
}
],
"name": "1",
"opType": "Conv2D",
"scope": "Default",
"attribute": [
{
"name": "output_names",
"value": {
"dtype": "DT_GRAPHS",
"values": [
{
"dtype": "DT_FLOAT64",
"strVal": "output"
}
]
}
}
],
"outputType": {
"dataType": "DT_STRING",
"tensorType": {
"elemType": "DT_FLOAT16",
"shape": {
"dim": [
{
"size": "1"
}
]
}
}
}
},
{
"input": [
{
"name": "1",
"type": "DATA_EDGE"
}
],
"name": "2",
"opType": "Add",
"scope": "Default",
"attribute": [
{
"name": "output_names",
"value": {
"dtype": "DT_GRAPHS",
"values": [
{
"dtype": "DT_FLOAT64",
"strVal": "output"
}
]
}
}
],
"outputType": {
"dataType": "DT_STRING",
"tensorType": {
"elemType": "DT_FLOAT16",
"shape": {
"dim": [
{
"size": "1"
}
]
}
}
}
},
{
"input": [
{
"name": "2",
"type": "DATA_EDGE"
}
],
"name": "3",
"opType": "Conv2D",
"scope": "Default",
"attribute": [
{
"name": "output_names",
"value": {
"dtype": "DT_GRAPHS",
"values": [
{
"dtype": "DT_FLOAT64",
"strVal": "output"
}
]
}
}
],
"outputType": {
"dataType": "DT_STRING",
"tensorType": {
"elemType": "DT_FLOAT16",
"shape": {
"dim": [
{
"size": "1"
}
]
}
}
}
},
{
"input": [
{
"name": "3",
"type": "DATA_EDGE"
}
],
"name": "4",
"opType": "Add",
"scope": "Default",
"attribute": [
{
"name": "output_names",
"value": {
"dtype": "DT_GRAPHS",
"values": [
{
"dtype": "DT_FLOAT64",
"strVal": "output"
}
]
}
}
],
"outputType": {
"dataType": "DT_STRING",
"tensorType": {
"elemType": "DT_FLOAT16",
"shape": {
"dim": [
{
"size": "1"
}
]
}
}
}
},
{
"input": [
{
"name": "4",
"type": "DATA_EDGE"
}
],
"name": "5",
"opType": "Conv2D",
"scope": "Default",
"attribute": [
{
"name": "output_names",
"value": {
"dtype": "DT_GRAPHS",
"values": [
{
"dtype": "DT_FLOAT64",
"strVal": "output"
}
]
}
}
],
"outputType": {
"dataType": "DT_STRING",
"tensorType": {
"elemType": "DT_FLOAT16",
"shape": {
"dim": [
{
"size": "1"
}
]
}
}
}
},
{
"input": [
{
"name": "5",
"type": "DATA_EDGE"
}
],
"name": "6",
"opType": "Add",
"scope": "Default",
"attribute": [
{
"name": "output_names",
"value": {
"dtype": "DT_GRAPHS",
"values": [
{
"dtype": "DT_FLOAT64",
"strVal": "output"
}
]
}
}
],
"outputType": {
"dataType": "DT_STRING",
"tensorType": {
"elemType": "DT_FLOAT16",
"shape": {
"dim": [
{
"size": "1"
}
]
}
}
}
},
{
"input": [
{
"name": "6",
"type": "DATA_EDGE"
}
],
"name": "7",
"opType": "Conv2D",
"scope": "Default",
"attribute": [
{
"name": "output_names",
"value": {
"dtype": "DT_GRAPHS",
"values": [
{
"dtype": "DT_FLOAT64",
"strVal": "output"
}
]
}
}
],
"outputType": {
"dataType": "DT_STRING",
"tensorType": {
"elemType": "DT_FLOAT16",
"shape": {
"dim": [
{
"size": "1"
}
]
}
}
}
},
{
"input": [
{
"name": "7",
"type": "DATA_EDGE"
}
],
"name": "8",
"opType": "Add",
"scope": "Default",
"attribute": [
{
"name": "output_names",
"value": {
"dtype": "DT_GRAPHS",
"values": [
{
"dtype": "DT_FLOAT64",
"strVal": "output"
}
]
}
}
],
"outputType": {
"dataType": "DT_STRING",
"tensorType": {
"elemType": "DT_FLOAT16",
"shape": {
"dim": [
{
"size": "1"
}
]
}
}
}
},
{
"input": [
{
"name": "8",
"type": "DATA_EDGE"
}
],
"name": "9",
"opType": "Conv2D",
"scope": "Default",
"attribute": [
{
"name": "output_names",
"value": {
"dtype": "DT_GRAPHS",
"values": [
{
"dtype": "DT_FLOAT64",
"strVal": "output"
}
]
}
}
],
"outputType": {
"dataType": "DT_STRING",
"tensorType": {
"elemType": "DT_FLOAT16",
"shape": {
"dim": [
{
"size": "1"
}
]
}
}
}
},
{
"input": [
{
"name": "9",
"type": "DATA_EDGE"
}
],
"name": "10",
"opType": "Add",
"scope": "Default",
"attribute": [
{
"name": "output_names",
"value": {
"dtype": "DT_GRAPHS",
"values": [
{
"dtype": "DT_FLOAT64",
"strVal": "output"
}
]
}
}
],
"outputType": {
"dataType": "DT_STRING",
"tensorType": {
"elemType": "DT_FLOAT16",
"shape": {
"dim": [
{
"size": "1"
}
]
}
}
}
},
{
"input": [
{
"name": "9",
"type": "DATA_EDGE"
}
],
"name": "11",
"opType": "Conv2D",
"scope": "Default",
"attribute": [
{
"name": "output_names",
"value": {
"dtype": "DT_GRAPHS",
"values": [
{
"dtype": "DT_FLOAT64",
"strVal": "output"
}
]
}
}
],
"outputType": {
"dataType": "DT_STRING",
"tensorType": {
"elemType": "DT_FLOAT16",
"shape": {
"dim": [
{
"size": "1"
}
]
}
}
}
},
{
"input": [
{
"name": "9",
"type": "DATA_EDGE"
}
],
"name": "12",
"opType": "Conv2D",
"scope": "Default",
"attribute": [
{
"name": "output_names",
"value": {
"dtype": "DT_GRAPHS",
"values": [
{
"dtype": "DT_FLOAT64",
"strVal": "output"
}
]
}
}
],
"outputType": {
"dataType": "DT_STRING",
"tensorType": {
"elemType": "DT_FLOAT16",
"shape": {
"dim": [
{
"size": "1"
}
]
}
}
}
},
{
"input": [
{
"name": "9",
"type": "DATA_EDGE"
}
],
"name": "13",
"opType": "Conv2D",
"scope": "Default",
"attribute": [
{
"name": "output_names",
"value": {
"dtype": "DT_GRAPHS",
"values": [
{
"dtype": "DT_FLOAT64",
"strVal": "output"
}
]
}
}
],
"outputType": {
"dataType": "DT_STRING",
"tensorType": {
"elemType": "DT_FLOAT16",
"shape": {
"dim": [
{
"size": "1"
}
]
}
}
}
},
{
"input": [
{
"name": "9",
"type": "DATA_EDGE"
}
],
"name": "14",
"opType": "Conv2D",
"scope": "Default",
"attribute": [
{
"name": "output_names",
"value": {
"dtype": "DT_GRAPHS",
"values": [
{
"dtype": "DT_FLOAT64",
"strVal": "output"
}
]
}
}
],
"outputType": {
"dataType": "DT_STRING",
"tensorType": {
"elemType": "DT_FLOAT16",
"shape": {
"dim": [
{
"size": "1"
}
]
}
}
}
},
{
"input": [
{
"name": "14",
"type": "DATA_EDGE"
}
],
"name": "15",
"opType": "Conv2D",
"scope": "Default",
"attribute": [
{
"name": "output_names",
"value": {
"dtype": "DT_GRAPHS",
"values": [
{
"dtype": "DT_FLOAT64",
"strVal": "output"
}
]
}
}
],
"outputType": {
"dataType": "DT_STRING",
"tensorType": {
"elemType": "DT_FLOAT16",
"shape": {
"dim": [
{
"size": "1"
}
]
}
}
}
},
{
"input": [
{
"name": "15",
"type": "DATA_EDGE"
}
],
"name": "16",
"opType": "Conv2D",
"scope": "Default",
"attribute": [
{
"name": "output_names",
"value": {
"dtype": "DT_GRAPHS",
"values": [
{
"dtype": "DT_FLOAT64",
"strVal": "output"
}
]
}
}
],
"outputType": {
"dataType": "DT_STRING",
"tensorType": {
"elemType": "DT_FLOAT16",
"shape": {
"dim": [
{
"size": "1"
}
]
}
}
}
}
],
"name": "849_848_847_424_1_construct",
"parameters": [
{
"name": "data",
"type": {
"dataType": "DT_STRING",
"tensorType": {
"elemType": "DT_FLOAT16",
"shape": {
"dim": [
{
"size": "1"
},
{
"size": "3"
},
{
"size": "224"
},
{
"size": "224"
}
]
}
}
}
}
]
}
......@@ -51,7 +51,7 @@
"type": "DATA_EDGE"
}
],
"name": "1",
"name": "55",
"opType": "Conv2D",
"scope": "Default/conv1-Conv2d",
"attribute": [
......@@ -149,7 +149,7 @@
"type": "DATA_EDGE"
}
],
"name": "53",
"name": "56",
"opType": "tuple_getitem",
"scope": "Default/bn1-BatchNorm2d",
"outputType": {
......@@ -354,7 +354,7 @@
{
"input": [
{
"name": "x11",
"name": "56",
"type": "DATA_EDGE"
}
],
......@@ -585,7 +585,7 @@
{
"input": [
{
"name": "x",
"name": "55",
"type": "DATA_EDGE"
}
],
......
{
"node": [
{
"input": [
{
"name": "6",
"type": "DATA_EDGE"
}
],
"name": "1",
"opType": "Conv2D",
"scope": "Default",
"attribute": [
{
"name": "output_names",
"value": {
"dtype": "DT_GRAPHS",
"values": [
{
"dtype": "DT_FLOAT64",
"strVal": "output"
}
]
}
}
],
"outputType": {
"dataType": "DT_STRING",
"tensorType": {
"elemType": "DT_FLOAT16",
"shape": {
"dim": [
{
"size": "1"
}
]
}
}
}
},
{
"input": [
{
"name": "7",
"type": "DATA_EDGE"
}
],
"name": "2",
"opType": "Conv2D",
"scope": "Default",
"attribute": [
{
"name": "output_names",
"value": {
"dtype": "DT_GRAPHS",
"values": [
{
"dtype": "DT_FLOAT64",
"strVal": "output"
}
]
}
}
],
"outputType": {
"dataType": "DT_STRING",
"tensorType": {
"elemType": "DT_FLOAT16",
"shape": {
"dim": [
{
"size": "1"
}
]
}
}
}
},
{
"input": [
{
"name": "8",
"type": "DATA_EDGE"
}
],
"name": "3",
"opType": "Conv2D",
"scope": "Default",
"attribute": [
{
"name": "output_names",
"value": {
"dtype": "DT_GRAPHS",
"values": [
{
"dtype": "DT_FLOAT64",
"strVal": "output"
}
]
}
}
],
"outputType": {
"dataType": "DT_STRING",
"tensorType": {
"elemType": "DT_FLOAT16",
"shape": {
"dim": [
{
"size": "1"
}
]
}
}
}
},
{
"input": [
{
"name": "14",
"type": "DATA_EDGE"
}
],
"name": "4",
"opType": "Conv2D",
"scope": "Default",
"attribute": [
{
"name": "output_names",
"value": {
"dtype": "DT_GRAPHS",
"values": [
{
"dtype": "DT_FLOAT64",
"strVal": "output"
}
]
}
}
],
"outputType": {
"dataType": "DT_STRING",
"tensorType": {
"elemType": "DT_FLOAT16",
"shape": {
"dim": [
{
"size": "1"
}
]
}
}
}
},
{
"input": [
{
"name": "10",
"type": "DATA_EDGE"
}
],
"name": "5",
"opType": "Conv2D",
"scope": "Default",
"attribute": [
{
"name": "output_names",
"value": {
"dtype": "DT_GRAPHS",
"values": [
{
"dtype": "DT_FLOAT64",
"strVal": "output"
}
]
}
}
],
"outputType": {
"dataType": "DT_STRING",
"tensorType": {
"elemType": "DT_FLOAT16",
"shape": {
"dim": [
{
"size": "1"
}
]
}
}
}
},
{
"input": [
{
"name": "data",
"type": "DATA_EDGE"
}
],
"name": "6",
"opType": "Add",
"scope": "Default",
"attribute": [
{
"name": "output_names",
"value": {
"dtype": "DT_GRAPHS",
"values": [
{
"dtype": "DT_FLOAT64",
"strVal": "output"
}
]
}
}
],
"outputType": {
"dataType": "DT_STRING",
"tensorType": {
"elemType": "DT_FLOAT16",
"shape": {
"dim": [
{
"size": "1"
}
]
}
}
}
},
{
"input": [
{
"name": "data",
"type": "DATA_EDGE"
}
],
"name": "7",
"opType": "Sub",
"scope": "Default",
"attribute": [
{
"name": "output_names",
"value": {
"dtype": "DT_GRAPHS",
"values": [
{
"dtype": "DT_FLOAT64",
"strVal": "output"
}
]
}
}
],
"outputType": {
"dataType": "DT_STRING",
"tensorType": {
"elemType": "DT_FLOAT16",
"shape": {
"dim": [
{
"size": "1"
}
]
}
}
}
},
{
"input": [
{
"name": "data",
"type": "DATA_EDGE"
}
],
"name": "8",
"opType": "Sqrt",
"scope": "Default",
"attribute": [
{
"name": "output_names",
"value": {
"dtype": "DT_GRAPHS",
"values": [
{
"dtype": "DT_FLOAT64",
"strVal": "output"
}
]
}
}
],
"outputType": {
"dataType": "DT_STRING",
"tensorType": {
"elemType": "DT_FLOAT16",
"shape": {
"dim": [
{
"size": "1"
}
]
}
}
}
},
{
"input": [
{
"name": "5",
"type": "DATA_EDGE"
}
],
"name": "9",
"opType": "Reshape",
"scope": "Default",
"attribute": [
{
"name": "output_names",
"value": {
"dtype": "DT_GRAPHS",
"values": [
{
"dtype": "DT_FLOAT64",
"strVal": "output"
}
]
}
}
],
"outputType": {
"dataType": "DT_STRING",
"tensorType": {
"elemType": "DT_FLOAT16",
"shape": {
"dim": [
{
"size": "1"
}
]
}
}
}
},
{
"input": [
{
"name": "data",
"type": "DATA_EDGE"
}
],
"name": "10",
"opType": "Mul",
"scope": "Default",
"attribute": [
{
"name": "output_names",
"value": {
"dtype": "DT_GRAPHS",
"values": [
{
"dtype": "DT_FLOAT64",
"strVal": "output"
}
]
}
}
],
"outputType": {
"dataType": "DT_STRING",
"tensorType": {
"elemType": "DT_FLOAT16",
"shape": {
"dim": [
{
"size": "1"
}
]
}
}
}
},
{
"input": [
{
"name": "9",
"type": "DATA_EDGE"
}
],
"name": "11",
"opType": "Add",
"scope": "Default",
"attribute": [
{
"name": "output_names",
"value": {
"dtype": "DT_GRAPHS",
"values": [
{
"dtype": "DT_FLOAT64",
"strVal": "output"
}
]
}
}
],
"outputType": {
"dataType": "DT_STRING",
"tensorType": {
"elemType": "DT_FLOAT16",
"shape": {
"dim": [
{
"size": "1"
}
]
}
}
}
},
{
"input": [
{
"name": "9",
"type": "DATA_EDGE"
}
],
"name": "12",
"opType": "Relu",
"scope": "Default",
"attribute": [
{
"name": "output_names",
"value": {
"dtype": "DT_GRAPHS",
"values": [
{
"dtype": "DT_FLOAT64",
"strVal": "output"
}
]
}
}
],
"outputType": {
"dataType": "DT_STRING",
"tensorType": {
"elemType": "DT_FLOAT16",
"shape": {
"dim": [
{
"size": "1"
}
]
}
}
}
},
{
"input": [
{
"name": "9",
"type": "DATA_EDGE"
}
],
"name": "13",
"opType": "Dense",
"scope": "Default",
"attribute": [
{
"name": "output_names",
"value": {
"dtype": "DT_GRAPHS",
"values": [
{
"dtype": "DT_FLOAT64",
"strVal": "output"
}
]
}
}
],
"outputType": {
"dataType": "DT_STRING",
"tensorType": {
"elemType": "DT_FLOAT16",
"shape": {
"dim": [
{
"size": "1"
}
]
}
}
}
},
{
"input": [],
"name": "14",
"opType": "Reshape",
"scope": "Default",
"attribute": [
{
"name": "output_names",
"value": {
"dtype": "DT_GRAPHS",
"values": [
{
"dtype": "DT_FLOAT64",
"strVal": "output"
}
]
}
}
],
"outputType": {
"dataType": "DT_STRING",
"tensorType": {
"elemType": "DT_FLOAT16",
"shape": {
"dim": [
{
"size": "1"
}
]
}
}
}
}
],
"name": "849_848_847_424_1_construct",
"parameters": [
{
"name": "data",
"type": {
"dataType": "DT_STRING",
"tensorType": {
"elemType": "DT_FLOAT16",
"shape": {
"dim": [
{
"size": "1"
},
{
"size": "3"
},
{
"size": "224"
},
{
"size": "224"
}
]
}
}
}
}
]
}
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册