Unverified Commit 6bb2bc71 authored by Yanwen Lin's avatar Yanwen Lin Committed by GitHub
Browse files

[Bugfix] Force using spawn multiprocess method when it's the WSL platform (#32749)


Signed-off-by: default avatarYanwen Lin <lyw1124278064@gmail.com>
parent c80f92c1
...@@ -16,6 +16,7 @@ import psutil ...@@ -16,6 +16,7 @@ import psutil
import vllm.envs as envs import vllm.envs as envs
from vllm.logger import init_logger from vllm.logger import init_logger
from vllm.platforms.interface import in_wsl
from vllm.ray.lazy_utils import is_in_ray_actor from vllm.ray.lazy_utils import is_in_ray_actor
from .platform_utils import cuda_is_initialized, xpu_is_initialized from .platform_utils import cuda_is_initialized, xpu_is_initialized
...@@ -132,6 +133,9 @@ def _maybe_force_spawn(): ...@@ -132,6 +133,9 @@ def _maybe_force_spawn():
elif xpu_is_initialized(): elif xpu_is_initialized():
reasons.append("XPU is initialized") reasons.append("XPU is initialized")
if in_wsl():
reasons.append("WSL is detected and NVML is not compatible with fork")
if reasons: if reasons:
logger.warning( logger.warning(
"We must use the `spawn` multiprocessing start method. " "We must use the `spawn` multiprocessing start method. "
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment