Replace

Applicability

Product

Supported or Not

Atlas A3 training products/Atlas A3 inference products

Atlas A2 training products/Atlas A2 inference products

Atlas 200I/500 A2 inference products

Atlas inference products

Atlas training products

Header File/Library File

  • Header file: #include <ge/fusion/graph_rewriter.h>
  • Library file: libge_compiler.so

Function Usage

Replaces the operators within the given subgraph boundary with a replacement graph.

Prototype

1
2
static Status Replace(const SubgraphBoundary &subgraph, const Graph &replacement)
static Status Replace(const SubgraphBoundary &subgraph, Graph &&replacement)

Parameters

Parameter

Input/Output

Description

subgraph

Input

Subgraph boundary for replacement.

replacement

Input

Replacement graph, which describes the graph structure to be replaced with.

Returns

Parameter

Type

Description

-

Status

Whether the replacement is successful.

Constraints

None