From e34393f975de67f1c08fed85198b0f06ffec6090 Mon Sep 17 00:00:00 2001 From: Daniel Han-Chen Date: Mon, 22 Jan 2024 04:25:37 +1100 Subject: [PATCH] Update llama.py --- unsloth/models/llama.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/unsloth/models/llama.py b/unsloth/models/llama.py index fc45368339..5e62b58053 100644 --- a/unsloth/models/llama.py +++ b/unsloth/models/llama.py @@ -108,7 +108,7 @@ def LlamaAttention_fast_forward_inference( head_dim = self.head_dim # assert(n_kv_heads * n_groups == n_heads) - Xn = hidden_states.view(n_heads, head_dim) + Xn = hidden_states.view(1, self.hidden_size) K1, V1 = past_key_value # LoRA or general matrix multiplication