SymbolId

Applicable Products

All processors

Header File/Library File

  • Header file: #include <ge/compliant_node_builder.h>
  • Library files: libeager_style_graph_builder_base.so and libeager_style_graph_builder_base_static.a

Function Usage

Sets the symbol identifier of the input, which is used for dynamic shape inference or symbolic expression to establish the symbol association between the input and output.

Prototype

1
IrInputDefV2 &SymbolId(const char_t *symbol_id)

Parameters

Parameter

Input/Output

Description

symbol_id

Input

Symbol ID of the input tensor, which is used for:

  • Dynamic shape scenario: It identifies dynamic dimensions (such as batch_size, height, and width).
  • Symbolic inference: It establishes the symbolic relationship between the input and output (similar to the variable symbol in mathematical formulas).
  • Shape association: When multiple tensors share the same symbol, the shape relationship between them can be inferred.

Returns

Parameter

Type

Description

-

IrInputDefV2 &

Reference to the IR input definition class, which supports chain calls.

Restrictions

None