mirror of
https://git.datalinker.icu/vllm-project/vllm.git
synced 2025-12-10 05:25:00 +08:00
Fix pre-commit (and XPU) on main (#28556)
Signed-off-by: Harry Mellor <19981378+hmellor@users.noreply.github.com>
This commit is contained in:
parent
10138c92a5
commit
54aecd9ed5
@ -1145,7 +1145,7 @@ class IpexMxfp4MoEMethod(Mxfp4MoEMethod):
|
|||||||
) -> torch.Tensor:
|
) -> torch.Tensor:
|
||||||
assert activation == "swigluoai", (
|
assert activation == "swigluoai", (
|
||||||
"Only swiglu_oai activation is supported for IPEX MXFP4 MoE"
|
"Only swiglu_oai activation is supported for IPEX MXFP4 MoE"
|
||||||
) # noqa:
|
)
|
||||||
hidden_size_pad = round_up(self.original_hidden_size, 128)
|
hidden_size_pad = round_up(self.original_hidden_size, 128)
|
||||||
x_pad = torch.nn.functional.pad(x, (0, hidden_size_pad - x.size(-1)))
|
x_pad = torch.nn.functional.pad(x, (0, hidden_size_pad - x.size(-1)))
|
||||||
hidden_states = layer.ipex_fusion(
|
hidden_states = layer.ipex_fusion(
|
||||||
|
|||||||
@ -64,8 +64,6 @@ class XPUPlatform(Platform):
|
|||||||
|
|
||||||
if use_sparse:
|
if use_sparse:
|
||||||
raise NotImplementedError("Sparse Attention is not supported on XPU.")
|
raise NotImplementedError("Sparse Attention is not supported on XPU.")
|
||||||
if not use_v1:
|
|
||||||
raise ValueError("XPU backend only supports V1.")
|
|
||||||
if selected_backend == AttentionBackendEnum.TRITON_ATTN:
|
if selected_backend == AttentionBackendEnum.TRITON_ATTN:
|
||||||
logger.info_once("Using Triton backend.")
|
logger.info_once("Using Triton backend.")
|
||||||
return AttentionBackendEnum.TRITON_ATTN.get_path()
|
return AttentionBackendEnum.TRITON_ATTN.get_path()
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user