mirror of
https://git.datalinker.icu/vllm-project/vllm.git
synced 2025-12-14 17:36:55 +08:00
[Fix] Fall back to Gloo when NCCL backend is unavailable (#19641)
Signed-off-by: conroy-cheers <conroy@corncheese.org>
This commit is contained in:
parent
6bc7b57315
commit
0860087aff
@ -938,6 +938,13 @@ def init_distributed_environment(
|
|||||||
assert distributed_init_method is not None, (
|
assert distributed_init_method is not None, (
|
||||||
"distributed_init_method must be provided when initializing "
|
"distributed_init_method must be provided when initializing "
|
||||||
"distributed environment")
|
"distributed environment")
|
||||||
|
if not torch.distributed.is_backend_available(backend):
|
||||||
|
logger.warning(
|
||||||
|
"Distributed backend %s is not available; "
|
||||||
|
"falling back to gloo.", backend)
|
||||||
|
assert torch.distributed.is_gloo_available(), (
|
||||||
|
"Fallback Gloo backend is not available.")
|
||||||
|
backend = "gloo"
|
||||||
# this backend is used for WORLD
|
# this backend is used for WORLD
|
||||||
torch.distributed.init_process_group(
|
torch.distributed.init_process_group(
|
||||||
backend=backend,
|
backend=backend,
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user