Skip to content

Commit 744706b

Browse files
add 'node_rank' to torchrun cmd (#751)
* add 'node_rank' to torchrun cmd * add comment
1 parent 966c96f commit 744706b

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

torchx/components/dist.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -261,6 +261,9 @@ def ddp(
261261
nnodes_rep,
262262
"--nproc_per_node",
263263
str(nproc_per_node),
264+
# node_rank is only used when rdzv_backend is 'static'
265+
"--node_rank",
266+
f"{macros.replica_id}",
264267
"--tee",
265268
"3",
266269
"--role",

0 commit comments

Comments
 (0)