MCPcopy Create free account
hub / github.com/appdevforall/CodeOnTheGo / iq2_data_index

Function iq2_data_index

subprojects/llama.cpp/ggml/src/ggml-quants.c:2620–2625  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2618};
2619
2620static inline int iq2_data_index(enum ggml_type type) {
2621 GGML_ASSERT(type == GGML_TYPE_IQ2_XXS || type == GGML_TYPE_IQ2_XS || type == GGML_TYPE_IQ1_S || type == GGML_TYPE_IQ1_M || type == GGML_TYPE_IQ2_S);
2622 return type == GGML_TYPE_IQ2_XXS ? 0 :
2623 type == GGML_TYPE_IQ2_XS ? 1 :
2624 type == GGML_TYPE_IQ1_S || type == GGML_TYPE_IQ1_M ? 2 : 3;
2625}
2626
2627static inline int iq2_grid_size(enum ggml_type type) {
2628 GGML_ASSERT(type == GGML_TYPE_IQ2_XXS || type == GGML_TYPE_IQ2_XS || type == GGML_TYPE_IQ1_S || type == GGML_TYPE_IQ1_M || type == GGML_TYPE_IQ2_S);

Callers 7

iq2xs_init_implFunction · 0.85
iq2xs_free_implFunction · 0.85
quantize_row_iq2_xs_implFunction · 0.85
quantize_row_iq1_s_implFunction · 0.85
quantize_row_iq1_m_implFunction · 0.85
quantize_row_iq2_s_implFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected