A high-throughput and memory-efficient inference and serving engine for LLMs
Mirrored from https://github.com/tduncan-lum/Nvidia-Optimization-Stack---VLLM.git
Synced Nov 15, 11:00 UTC
[Misc] Delete LoRA-related redundancy code (#17841)
Signed-off-by: Jee Jee Li <pandaleefree@gmail.com>
Jee Jee Li committed
May 8, 2025 at 21:02 UTC
a944f8ede7361a5233e112a575ff77c4aaa268a5
4 files changed
+3
-17
vllm/lora/models.py
+1
-1
@@ -344,7 +344,7 @@ class LoRAModelManager(AdapterModelManager):
344
345
self.supported_lora_modules = get_supported_lora_modules(self.model)
346
assert self.supported_lora_modules, "No supported LoRA modules found in"
347
- f"{self.model.__class__.__name__}."
347
+ f" {self.model.__class__.__name__}."
348
if lora_config.long_lora_scaling_factors:
349
# We need to replace rotary emb layer to do batch computation
350
# for long lora.
vllm/model_executor/models/grok1.py
+1
-3
@@ -504,9 +504,7 @@ class Grok1ForCausalLM(nn.Module, SupportsLoRA, SupportsPP):
504
self.unpadded_vocab_size,
505
config.hidden_size,
506
org_num_embeddings=config.vocab_size,
507
- padding_size=DEFAULT_VOCAB_PADDING_SIZE
508
- # We need bigger padding if using lora for kernel compatibility
509
- if not lora_config else lora_config.lora_vocab_padding_size,
507
+ padding_size=DEFAULT_VOCAB_PADDING_SIZE,
508
quant_config=quant_config,
509
prefix=maybe_prefix(prefix, "lm_head"),
510
)
vllm/model_executor/models/nemotron_nas.py
-8
@@ -334,14 +334,6 @@ class DeciLMForCausalLM(nn.Module, SupportsLoRA, SupportsPP, HasNoOps):
334
}
335
336
# LoRA specific attributes
337
- supported_lora_modules = [
338
- "qkv_proj",
339
- "o_proj",
340
- "gate_up_proj",
341
- "down_proj",
342
- "embed_tokens",
343
- "lm_head",
344
- ]
337
embedding_modules = {
338
"embed_tokens": "input_embeddings",
339
"lm_head": "output_embeddings",
vllm/model_executor/models/phi4mm.py
+1
-5
@@ -955,11 +955,7 @@ class Phi4MMForCausalLM(nn.Module, SupportsLoRA, SupportsMultiModal):
955
self.unpadded_vocab_size,
956
config.hidden_size,
957
org_num_embeddings=config.vocab_size,
958
- padding_size=(
959
- DEFAULT_VOCAB_PADDING_SIZE
960
- # We need bigger padding if using lora for kernel
961
- # compatibility
962
- if not lora_config else lora_config.lora_vocab_padding_size),
958
+ padding_size=DEFAULT_VOCAB_PADDING_SIZE,
959
quant_config=quant_config,
960
)
961
if config.tie_word_embeddings: