Indicates whether an input is a data-dependent input. Functions such as Tiling and InferShape depend on specific data of such inputs when implemented. The input data is on the host. You can obtain the input data by using GetInputTensor of the TilingContext class or GetInputTensor of the InferShapeContext class in the Tiling or InferShape function.
OpParamDef &ValueDepend(Option value_depend); OpParamDef &ValueDepend(Option value_depend, DependScope scope);
| Parameter | Input/Output | Description |
|---|---|---|
| value_depend | Input | The options of value_depend are as follows: - REQUIRED: The operator input must be of the Const type. The system checks whether the operator input is of the Const type. If the verification is passed, the input value is fed to the operator. Otherwise, an error is reported. - OPTIONAL: The operator input is not necessarily of the Const type. However, the input is fed to the operator only when it is of the Const type. |
| scope | Input | The scope type is the enumeration DependScope. The options are as follows: - ALL: The implementation of functions such as Tiling and InferShape depends on the input data. The behavior is the same as that of calling the ValueDepend API of a single parameter. - TILING: Refers to the tensor value during tiling. Tiling offload is supported. |
Only the operator input can be configured. The input DataType must be DT_INT64, DT_FLOAT, or DT_BOOL.