From 79550f8b47b710c6ae66bb374b406d25a862a3b0 Mon Sep 17 00:00:00 2001 From: drbh Date: Wed, 29 Jan 2025 16:10:17 +0000 Subject: [PATCH] fix: remove check for default rope type --- server/text_generation_server/layers/rotary.py | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/server/text_generation_server/layers/rotary.py b/server/text_generation_server/layers/rotary.py index 8132478c..b40d413a 100644 --- a/server/text_generation_server/layers/rotary.py +++ b/server/text_generation_server/layers/rotary.py @@ -88,10 +88,8 @@ class PositionRotaryEmbedding(nn.Module): rope_type = rope_scaling.get("rope_type", rope_scaling.get("type", None)) mrope_section = rope_scaling.get("mrope_section", None) - # only apply mrope if sections are provided and the rope type is mrope or default - if mrope_section is not None and ( - rope_type == "mrope" or rope_type == "default" - ): + # only apply mrope if sections are provided and the rope type is mrope and a section is provided + if mrope_section is not None and rope_type == "mrope": mrope_section = rope_scaling.get("mrope_section") return RotaryPositionEmbeddingMultimodalSections( inv_freq, scaling_factor, mrope_section