Skip to content

Commit b1dbf33

Browse files
aivanoufacebook-github-bot
authored andcommitted
Correct dist.ddp component (#93)
Summary: Pull Request resolved: #93 Correct dist.ddp component with proper args env and resource Reviewed By: kiukchung Differential Revision: D29433684 fbshipit-source-id: 5a439b85f3ef6330f632793008c28dbc299e2899
1 parent a573c54 commit b1dbf33

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

torchx/components/dist.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,8 @@ def ddp(
3535
Args:
3636
image: container image.
3737
entrypoint: script or binary to run within the image.
38-
resource: Registered named resource.
38+
resource: Optional resource identifier. The resource parameter
39+
gets ignored when running on the local scheduler.
3940
nnodes: Number of nodes.
4041
nproc_per_node: Number of processes per node.
4142
name: Name of the application.
@@ -56,8 +57,8 @@ def ddp(
5657
entrypoint=entrypoint,
5758
resource=resource or specs.NULL_RESOURCE,
5859
num_replicas=nnodes,
59-
script_args=list(script_args),
60-
script_envs=env,
60+
args=list(script_args),
61+
env=env,
6162
nproc_per_node=nproc_per_node,
6263
nnodes=nnodes,
6364
max_restarts=0,

0 commit comments

Comments
 (0)