Skip to content

Commit c15475e

Browse files
authored
fix: Fix fsdp config check (#2266)
Signed-off-by: Boxiang Wang <boxiangw@nvidia.com>
1 parent 63af02a commit c15475e

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

‎src/megatron/bridge/training/config.py‎

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1629,8 +1629,10 @@ def validate(self) -> None:
16291629
"Megatron FSDP only supports fsdp_dtensor checkpoint format"
16301630
)
16311631

1632-
if self.ddp.average_in_collective:
1633-
print_rank_0("average_in_collective is not supported with Megatron FSDP, setting to True")
1632+
if self.ddp.average_in_collective and not self.ddp.disable_symmetric_registration:
1633+
print_rank_0(
1634+
"average_in_collective is not supported with NCCL symmetric registration, setting to False"
1635+
)
16341636
self.ddp.average_in_collective = False
16351637

16361638
# reuse_grad_buf_for_mxfp8_param_ag is not supported with Megatron FSDP

0 commit comments

Comments
 (0)