@tduncan / Nvidia-Optimization-Stack-VLLM Mirror · read-only / commits / 51dd14ac2b
Fork 0

A high-throughput and memory-efficient inference and serving engine for LLMs

Mirrored from https://github.com/tduncan-lum/Nvidia-Optimization-Stack---VLLM.git

Synced Nov 14, 05:30 UTC

[Bugfix][DP] Fix creating too many DP Placement Groups (#26880)

Signed-off-by: Kebe <mail@kebe7jun.com> Signed-off-by: Rui Qiao <ruisearch42@gmail.com> Co-authored-by: Rui Qiao <ruisearch42@gmail.com>

Kebe committed Oct 24, 2025 at 05:16 UTC 51dd14ac2b9a17cbc8eb91fe0f39311f1d594f63
1 file changed +9
vllm/v1/engine/utils.py
+9
@@ -497,6 +497,8 @@ class CoreEngineActorManager:
497 )
498 placement_groups.append(pg)
499 local_dp_ranks.append(i)
500 + if len(placement_groups) == dp_size:
501 + break
502
503 if len(placement_groups) < dp_size:
504 raise ValueError(
@@ -506,6 +508,13 @@ class CoreEngineActorManager:
508 "Available resources: "
509 f"{available_resources}"
510 )
511 + assert len(placement_groups) == dp_size, (
512 + f"Created {len(placement_groups)} DP placement groups, expected {dp_size}"
513 + )
514 + assert len(local_dp_ranks) == dp_size, (
515 + f"local_dp_ranks length {len(local_dp_ranks)} does not match "
516 + f"expected {dp_size}"
517 + )
518 return placement_groups, local_dp_ranks
519
520 @staticmethod