LLM_ENGINE_DataType DType() const

接口功能

获取推理输入张量保存的数据类型。

接口格式

LLM_ENGINE_DataType DType() const;

接口参数

使用样例

返回值

LLM_ENGINE_DataType_enum类型

意义

TYPE_INVALID

0

非法类型

TYPE_BOOL

1

bool类型

TYPE_UINT8

2

uint8类型

TYPE_UINT16

3

uint16类型

TYPE_UINT32

4

uint32类型

TYPE_UINT64

5

uint64类型

TYPE_INT8

6

int8类型

TYPE_INT16

7

int16类型

TYPE_INT32

8

int32类型

TYPE_INT64

9

int64类型

TYPE_FP16

10

float16类型

TYPE_FP32

11

float32类型

TYPE_FP64

12

float64类型

TYPE_STRING

13

string类型

TYPE_BF16

14

bf16类型

TYPE_BUTT

15

保留值