[Minor] Improve the style and fix flaky tests (#1584)

This commit is contained in:
Lianmin Zheng
2024-10-06 00:10:48 -07:00
committed by GitHub
parent 2422de5193
commit 9244f27f0a
7 changed files with 15 additions and 7 deletions

View File

@@ -594,7 +594,9 @@ def set_weight_attrs(
def broadcast_pyobj(
data: List[Any], rank: int, dist_group: torch.distributed.ProcessGroup
data: List[Any],
rank: int,
dist_group: Optional[torch.distributed.ProcessGroup] = None,
):
"""Broadcast inputs from rank=0 to all other ranks with torch.dist backend."""