You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: exllamav2/device.py
+53Lines changed: 53 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -182,6 +182,59 @@ def prepare_sincos(self):
182
182
cfg.l3_rope_original_max_position_embeddings,
183
183
)
184
184
185
+
# YaRN
186
+
# Adapted from transformers: https://github.com/huggingface/transformers/blob/2e24ee4dfa39cc0bc264b89edbccc373c8337086/src/transformers/modeling_rope_utils.py#L163
187
+
188
+
elifcfg.alt_rope_method=="yarn":
189
+
190
+
partial_rotary_factor=1.0# Placeholder, assume no partial_rotary_factor in config.
0 commit comments