Skip to content

Commit d0e091a

Browse files
committed
Fix
Signed-off-by: Guyue Huang <guyueh@nvidia.com>
1 parent 71c1c70 commit d0e091a

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

nemo_rl/models/generation/vllm/vllm_worker.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -452,8 +452,11 @@ def _patch_vllm_hermes_tool_parser_thread_safety():
452452

453453
# Use Ray for distributed execution in parallel mode
454454
vllm_kwargs["distributed_executor_backend"] = "ray"
455+
elif self.expert_parallel_size > 1:
456+
vllm_kwargs["distributed_executor_backend"] = "mp"
455457
else:
456-
# For non-parallel mode, explicitly set executor to mp; Otherwise, it will fall back to
458+
# For non-parallel mode, explicitly set executor to None to avoid Ray issues
459+
vllm_kwargs["distributed_executor_backend"] = None
457460
# ray, which causes hang when we vllm_dp > 1 (i.e., ep_size > tp_size)
458461
vllm_kwargs["distributed_executor_backend"] = "mp"
459462

0 commit comments

Comments
 (0)