mirror of
https://git.datalinker.icu/vllm-project/vllm.git
synced 2026-01-04 18:07:28 +08:00
[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>
This commit is contained in:
parent
dbfbf9f324
commit
51dd14ac2b
@ -497,6 +497,8 @@ class CoreEngineActorManager:
|
||||
)
|
||||
placement_groups.append(pg)
|
||||
local_dp_ranks.append(i)
|
||||
if len(placement_groups) == dp_size:
|
||||
break
|
||||
|
||||
if len(placement_groups) < dp_size:
|
||||
raise ValueError(
|
||||
@ -506,6 +508,13 @@ class CoreEngineActorManager:
|
||||
"Available resources: "
|
||||
f"{available_resources}"
|
||||
)
|
||||
assert len(placement_groups) == dp_size, (
|
||||
f"Created {len(placement_groups)} DP placement groups, expected {dp_size}"
|
||||
)
|
||||
assert len(local_dp_ranks) == dp_size, (
|
||||
f"local_dp_ranks length {len(local_dp_ranks)} does not match "
|
||||
f"expected {dp_size}"
|
||||
)
|
||||
return placement_groups, local_dp_ranks
|
||||
|
||||
@staticmethod
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user