fromValue static method
Implementation
static ggml_op fromValue(int value) => switch (value) {
0 => GGML_OP_NONE,
1 => GGML_OP_DUP,
2 => GGML_OP_ADD,
3 => GGML_OP_ADD1,
4 => GGML_OP_ACC,
5 => GGML_OP_SUB,
6 => GGML_OP_MUL,
7 => GGML_OP_DIV,
8 => GGML_OP_SQR,
9 => GGML_OP_SQRT,
10 => GGML_OP_LOG,
11 => GGML_OP_SIN,
12 => GGML_OP_COS,
13 => GGML_OP_SUM,
14 => GGML_OP_SUM_ROWS,
15 => GGML_OP_MEAN,
16 => GGML_OP_ARGMAX,
17 => GGML_OP_COUNT_EQUAL,
18 => GGML_OP_REPEAT,
19 => GGML_OP_REPEAT_BACK,
20 => GGML_OP_CONCAT,
21 => GGML_OP_SILU_BACK,
22 => GGML_OP_NORM,
23 => GGML_OP_RMS_NORM,
24 => GGML_OP_RMS_NORM_BACK,
25 => GGML_OP_GROUP_NORM,
26 => GGML_OP_MUL_MAT,
27 => GGML_OP_MUL_MAT_ID,
28 => GGML_OP_OUT_PROD,
29 => GGML_OP_SCALE,
30 => GGML_OP_SET,
31 => GGML_OP_CPY,
32 => GGML_OP_CONT,
33 => GGML_OP_RESHAPE,
34 => GGML_OP_VIEW,
35 => GGML_OP_PERMUTE,
36 => GGML_OP_TRANSPOSE,
37 => GGML_OP_GET_ROWS,
38 => GGML_OP_GET_ROWS_BACK,
39 => GGML_OP_DIAG,
40 => GGML_OP_DIAG_MASK_INF,
41 => GGML_OP_DIAG_MASK_ZERO,
42 => GGML_OP_SOFT_MAX,
43 => GGML_OP_SOFT_MAX_BACK,
44 => GGML_OP_ROPE,
45 => GGML_OP_ROPE_BACK,
46 => GGML_OP_CLAMP,
47 => GGML_OP_CONV_TRANSPOSE_1D,
48 => GGML_OP_IM2COL,
49 => GGML_OP_IM2COL_BACK,
50 => GGML_OP_CONV_TRANSPOSE_2D,
51 => GGML_OP_POOL_1D,
52 => GGML_OP_POOL_2D,
53 => GGML_OP_POOL_2D_BACK,
54 => GGML_OP_UPSCALE,
55 => GGML_OP_PAD,
56 => GGML_OP_ARANGE,
57 => GGML_OP_TIMESTEP_EMBEDDING,
58 => GGML_OP_ARGSORT,
59 => GGML_OP_LEAKY_RELU,
60 => GGML_OP_FLASH_ATTN_EXT,
61 => GGML_OP_FLASH_ATTN_BACK,
62 => GGML_OP_SSM_CONV,
63 => GGML_OP_SSM_SCAN,
64 => GGML_OP_WIN_PART,
65 => GGML_OP_WIN_UNPART,
66 => GGML_OP_GET_REL_POS,
67 => GGML_OP_ADD_REL_POS,
68 => GGML_OP_RWKV_WKV6,
69 => GGML_OP_UNARY,
70 => GGML_OP_MAP_UNARY,
71 => GGML_OP_MAP_BINARY,
72 => GGML_OP_MAP_CUSTOM1_F32,
73 => GGML_OP_MAP_CUSTOM2_F32,
74 => GGML_OP_MAP_CUSTOM3_F32,
75 => GGML_OP_MAP_CUSTOM1,
76 => GGML_OP_MAP_CUSTOM2,
77 => GGML_OP_MAP_CUSTOM3,
78 => GGML_OP_CROSS_ENTROPY_LOSS,
79 => GGML_OP_CROSS_ENTROPY_LOSS_BACK,
80 => GGML_OP_OPT_STEP_ADAMW,
81 => GGML_OP_COUNT,
_ => throw ArgumentError("Unknown value for ggml_op: $value"),
};