mirror of
https://github.com/vllm-project/vllm.git
synced 2025-10-20 14:53:52 +08:00
[Bugfix] Fix _get_lora_device for HQQ marlin (#12090)
Signed-off-by: Varun Sundar Rabindranath <varun@neuralmagic.com> Co-authored-by: Varun Sundar Rabindranath <varun@neuralmagic.com>
This commit is contained in:
committed by
GitHub
parent
70755e819e
commit
ebd8c669ef
@ -51,6 +51,9 @@ def _get_lora_device(base_layer: nn.Module) -> torch.device:
|
||||
# marlin
|
||||
elif hasattr(base_layer, "B"):
|
||||
return base_layer.B.device
|
||||
# HQQ marlin
|
||||
elif hasattr(base_layer, "W_q"):
|
||||
return base_layer.W_q.device
|
||||
else:
|
||||
raise ValueError(f"Unsupported base layer: {base_layer}")
|
||||
|
||||
|
Reference in New Issue
Block a user