Skip to content

Commit 5c32e80

Browse files
committed
fix: Fix input setup after upstream merge
Branch: GraniteFour Signed-off-by: Gabe Goodhart <ghart@us.ibm.com>
1 parent 2e1431f commit 5c32e80

File tree

1 file changed

+3
-7
lines changed

1 file changed

+3
-7
lines changed

src/llama-model.cpp

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -14031,11 +14031,7 @@ struct llm_build_granite_hybrid : public llm_graph_context_mamba, public llm_gra
1403114031

1403214032
inpL = build_inp_embd(model.tok_embd);
1403314033

14034-
const auto * mctx_hyb = static_cast<const llama_memory_hybrid_context *>(mctx);
14035-
14036-
auto * inp_rs = build_rs_inp(mctx_hyb->get_recr());
14037-
14038-
auto * inp_attn = build_attn_inp_kv_unified(mctx_hyb->get_attn());
14034+
auto * inp = build_inp_mem_hybrid();
1403914035

1404014036
ggml_tensor * inp_out_ids = build_inp_out_ids();
1404114037

@@ -14056,11 +14052,11 @@ struct llm_build_granite_hybrid : public llm_graph_context_mamba, public llm_gra
1405614052

1405714053
if (hparams.is_recurrent(il)) {
1405814054
// ssm layer //
14059-
cur = build_mamba2_layer(inp_rs, gf, cur, model, ubatch, il);
14055+
cur = build_mamba2_layer(inp->get_recr(), gf, cur, model, ubatch, il);
1406014056
} else {
1406114057
// attention layer //
1406214058
cur = build_attention_layer(
14063-
gf, cur, inp_pos, inp_attn, model,
14059+
gf, cur, inp_pos, inp->get_attn(), model,
1406414060
n_embd_head, use_rope, il);
1406514061
}
1406614062

0 commit comments

Comments
 (0)