Skip to content

Commit 4153dc6

Browse files
add 'node_rank' to torchrun cmd (pytorch#751)
* add 'node_rank' to torchrun cmd * add comment
1 parent 35556be commit 4153dc6

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
@@ -262,6 +262,9 @@ def ddp(
262262
nnodes_rep,
263263
"--nproc_per_node",
264264
str(nproc_per_node),
265+
# node_rank is only used when rdzv_backend is 'static'
266+
"--node_rank",
267+
f"{macros.replica_id}",
265268
"--tee",
266269
"3",
267270
"--role",

0 commit comments

Comments
 (0)