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 14, 05:30 UTC
[Bugfix] Fix ReplicatedLinearWithLoRA (#27065)
Signed-off-by: Jee Jee Li <pandaleefree@gmail.com>
Jee Jee Li committed
Oct 17, 2025 at 12:43 UTC
87bc0c492f324a2b8b7566c9aa222921b514d4dc
1 file changed
+12
vllm/lora/layers/replicated_linear.py
+12
@@ -56,3 +56,15 @@ class ReplicatedLinearWithLoRA(BaseLinearLayerWithLoRA):
56
model_config: PretrainedConfig | None,
57
) -> bool:
58
return type(source_layer) is ReplicatedLinear
59
+
60
+ def slice_lora_a(
61
+ self, lora_a: torch.Tensor | list[torch.Tensor | None]
62
+ ) -> torch.Tensor | list[torch.Tensor | None]:
63
+ """Slice lora a if splitting for tensor parallelism."""
64
+ return lora_a
65
+
66
+ def slice_lora_b(
67
+ self, lora_b: torch.Tensor | list[torch.Tensor | None]
68
+ ) -> torch.Tensor | list[torch.Tensor | None]:
69
+ """Slice lora b if splitting with tensor parallelism."""
70
+ return lora_b