From 47d230b3cd043306463e2b76bd8023f867427ea2 Mon Sep 17 00:00:00 2001 From: Daniel Han Date: Tue, 23 Jul 2024 11:13:15 -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 295d92f629..ff4d19c543 100644 --- a/unsloth/models/llama.py +++ b/unsloth/models/llama.py @@ -1010,7 +1010,7 @@ class LlamaRotaryEmbedding(torch.nn.Module): pass def forward(self, x, position_ids=None, seq_len=None): - print(x, position_ids, seq_len) + print(__LINE__, x, position_ids, seq_len) # x: [bs, num_attention_heads, seq_len, head_size] if seq_len > self.current_rope_size: self._set_cos_sin_cache(seq_len=seq_len, device=x.device, dtype=x.dtype) @@ -1127,6 +1127,7 @@ class LlamaExtendedRotaryEmbedding(torch.nn.Module): def forward(self, x, position_ids=None, seq_len=None): # x: [bs, num_attention_heads, seq_len, head_size] + print(__LINE__, x, position_ids, seq_len) if seq_len > self.current_rope_size: self._set_cos_sin_cache(seq_len=seq_len, device=x.device, dtype=x.dtype)