MCPcopy Create free account
hub / github.com/antirez/ds4 / metal_graph_stream_map_output

Function metal_graph_stream_map_output

ds4.c:13126–13137  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

13124 float *index_comp = xmalloc((size_t)DS4_N_INDEXER_HEAD_DIM * sizeof(index_comp[0]));
13125 if (compressor_decode_one(index_comp, model,
13126 layer->indexer_compressor_kv,
13127 layer->indexer_compressor_gate,
13128 layer->indexer_compressor_ape,
13129 layer->indexer_compressor_norm,
13130 attn_norm,
13131 cache->index_state_kv,
13132 cache->index_state_score,
13133 DS4_N_INDEXER_HEAD_DIM,
13134 ratio,
13135 il,
13136 pos)) {
13137 kv_cache_push_comp(cache->index_comp_kv, &cache->n_index_comp, cache->comp_cap, DS4_N_INDEXER_HEAD_DIM, index_comp);
13138 }
13139 free(index_comp);
13140

Tested by

no test coverage detected