From 54a0ddeba4ac597fba9ac225b29038968c99b367 Mon Sep 17 00:00:00 2001 From: Daniel Han Date: Fri, 21 Mar 2025 16:58:00 -0700 Subject: [PATCH] Update llama.py --- unsloth/models/llama.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/unsloth/models/llama.py b/unsloth/models/llama.py index 4dfe214cf0..5ad41aadcc 100644 --- a/unsloth/models/llama.py +++ b/unsloth/models/llama.py @@ -654,6 +654,7 @@ def LlamaModel_fast_forward( inputs_embeds = self.embed_tokens(input_ids) inputs_embeds = inputs_embeds.to(_get_dtype(self.config.torch_dtype)) + print(inputs_embeds.shape) # Normalized from Gemma IS_GEMMA = self.config.model_type.startswith("gemma") @@ -1170,7 +1171,7 @@ def CausalLM_fast_forward(fast_forward_inference): if not return_dict: output = (logits,) + outputs[1:] return (loss,) + output if loss is not None else output - print(outputs.past_key_values, outputs.past_key_values[0][0].shape) + # print(outputs.past_key_values, outputs.past_key_values[0][0].shape) raise return CausalLMOutputWithPast( loss = loss,