GetDataType
Function Usage
Obtains the data type of a tensor.
Prototype
1 | ge::DataType GetDataType() const |
Parameters
None
Constraints
None
Examples
1 2 3 | StorageShape sh({1, 2, 3}, {1, 2, 3}); TensorV2 t = {sh, {ge::FORMAT_ND, ge::FORMAT_FRACTAL_NZ, {}}, kOnHost, ge::DT_FLOAT, nullptr}; auto dt = t.GetDataType(); // ge::DT_FLOAT |
Parent topic: TensorV2