You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: articles/machine-learning/how-to-manage-runs.md
+31-9Lines changed: 31 additions & 9 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -260,20 +260,42 @@ creating a batch of runs is more efficient than creating them one by one.
260
260
261
261
### Submit child runs
262
262
263
-
Child runs can also be submitted from a parent run. This allows you to create hierarchies of parent and child runs, each running on different
264
-
compute targets, connected by common parent run ID.
263
+
Child runs can also be submitted from a parent run. This allows you to create hierarchies of parent and child runs.
265
264
266
-
Use the ['submit_child()'](https://docs.microsoft.com/python/api/azureml-core/azureml.core.run.run?view=azure-ml-py#submit-child-config--tags-none----kwargs-)
267
-
method to submit a child run from within a parent run. To do this in the parent run script, get the run context and submit the child run
268
-
using the ``submit_child`` method of the context instance.
265
+
You may wish your child runs to use a different run configuration than the parent run. For instance, you might use a less-powerful, CPU-based configuration for the parent, while using GPU-based configurations for your children. Another common desire is to pass each child different arguments and data. To customize a child run, pass a `RunConfiguration`object to the child's `ScriptRunConfig` constructor. This code example, which would be part of the parent `ScriptRunConfig` object's script:
266
+
267
+
- Creates a `RunConfiguration` retrieving a named compute resource `"gpu-compute"`
268
+
- Iterates over different argument values to be passed to the children `ScriptRunConfig` objects
269
+
- Creates and submits a new child run, using the custom compute resource and argument
# Experiment will "complete" successfully at this point.
291
+
# Instead of returning immediately, block until child runs complete
292
+
293
+
for child in run.get_children():
294
+
child.wait_for_completion()
275
295
```
276
296
297
+
To create many child runs with identical configurations, arguments, and inputs efficiently, use the [`create_children()`](https://docs.microsoft.com/python/api/azureml-core/azureml.core.run.run?view=azure-ml-py#create-children-count-none--tag-key-none--tag-values-none-) method. Because each creation results in a network call, creating a batch of runs is more efficient than creating them one by one.
298
+
277
299
Within a child run, you can view the parent run ID:
0 commit comments