Browse Source

!604 TransOpWithoutReshapeFusionPass

From: @dimitri_rose
Reviewed-by: @xchu42,@ji_chen
Signed-off-by: @ji_chen
tags/v1.2.0
mindspore-ci-bot Gitee 4 years ago
parent
commit
fb7effb93f
1 changed files with 6 additions and 2 deletions
  1. +6
    -2
      ge/graph/passes/transop_without_reshape_fusion_pass.cc

+ 6
- 2
ge/graph/passes/transop_without_reshape_fusion_pass.cc View File

@@ -736,8 +736,12 @@ void TransOpWithoutReshapeFusionPass::RemoveNousedNodes(const ComputeGraphPtr &g

GE_IF_BOOL_EXEC(!op_desc->SetExtAttr(kRemainNode, true), GELOGE(INTERNAL_ERROR, "set ext attr failed"); return);
GELOGI("remove node:%s", node->GetName().c_str());
if (graph->RemoveNode(node) != GRAPH_SUCCESS) {
GELOGW("remove node failed!node:%s", node->GetName().c_str());
if (GraphUtils::IsolateNode(node, {0}) != GRAPH_SUCCESS) {
GELOGW("Isolate node: %s failed.", node->GetName().c_str());
continue;
}
if (GraphUtils::RemoveNodeWithoutRelink(graph, node) != GRAPH_SUCCESS) {
GELOGW("Remove node: %s failed.", node->GetName().c_str());
continue;
}
}


Loading…
Cancel
Save