EsSetInt64AttrForTensor
Applicability
Product |
Supported or Not |
|---|---|
√ |
|
√ |
|
√ |
|
√ |
|
√ |
Header File/Library File
- Header file: #include <ge/esb_funcs.h>
- Library files: libeager_style_graph_builder_base.so and libeager_style_graph_builder_base_static.a
Function Usage
Sets the int64 attribute of a tensor.
Prototype
1 | uint32_t EsSetInt64AttrForTensor(EsCTensorHolder *tensor, const char *attr_name, int64_t value) |
Parameters
Parameter |
Input/Output |
Description |
|---|---|---|
tensor |
Input |
Pointer to the tensor holder. |
attr_name |
Input |
Attribute name. |
value |
Input |
Attribute value. |
Returns
Parameter |
Type |
Description |
|---|---|---|
- |
uint32_t |
0: success; non-zero value: failure |
Constraints
None
Examples
1 2 3 | EsCGraphBuilder *graph = EsCreateGraphBuilder("test_graph"); auto *tensor = EsCreateGraphInput(graph, 0); uint32_t result = EsSetInt64AttrForTensor(tensor, "int64_attr", 10); |
Parent topic: C/C++ APIs