mirror of
https://github.com/huggingface/text-generation-inference.git
synced 2025-09-12 04:44:52 +00:00
fix: add noop in TensorParallelAdapterRowLinear too
This commit is contained in:
parent
3c9b28eaec
commit
c927cffbf7
@ -258,6 +258,9 @@ class TensorParallelAdapterRowLinear(LoraLinear):
|
||||
) -> torch.Tensor:
|
||||
result = self.base_layer(input)
|
||||
|
||||
if self.layer_name is None:
|
||||
return result
|
||||
|
||||
# Fused all-gather + all-reduce from S-LoRA paper: https://arxiv.org/abs/2311.03285
|
||||
stride = result.shape[-1] // self.process_group.size()
|
||||
start_idx = self.process_group.rank() * stride
|
||||
|
Loading…
Reference in New Issue
Block a user