From 1cb4f52010b030646c93261dd07bbc3cfe56651d Mon Sep 17 00:00:00 2001 From: youkaichao Date: Wed, 8 Jan 2025 22:58:41 +0800 Subject: [PATCH] fix Signed-off-by: youkaichao --- vllm/model_executor/layers/activation.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/vllm/model_executor/layers/activation.py b/vllm/model_executor/layers/activation.py index 46d4670bfe4f9..b8a302cf5087f 100644 --- a/vllm/model_executor/layers/activation.py +++ b/vllm/model_executor/layers/activation.py @@ -61,7 +61,7 @@ class SiluAndMul(CustomOp): def __init__(self): super().__init__() - if current_platform.is_cuda_alike(): + if current_platform.is_cuda_alike() or current_platform.is_cpu(): self.op = torch.ops._C.silu_and_mul elif current_platform.is_xpu(): import intel_extension_for_pytorch as ipex