Cancel all child runs in Azure ML

Nikki 76 Reputation points
2022-04-06T13:54:59.717+00:00

How to I properly cancel all child runs in an Azure ML experiment? When I use the code below as expected from documentation, I get an error. "RunConfigurationException:
Message: Error in deserialization. dict fields don't have list element type information. field=output_data, list_element_type=<class 'azureml.core.runconfig.OutputData'>...} with exception init() missing 2 required positional arguments: 'datastore_name' and 'relative_path'"

run = Run.get(ws, 'run-id-123456789')

for child in run.get_children():
print(child.get_details())
try:
child.cancel()
except Exception as e:
print(e)
continue

The datasets and runs were configured properly because they run just fine.

Azure Machine Learning
Azure Machine Learning
An Azure machine learning service for building and deploying models.
2,653 questions
{count} votes

Accepted answer
  1. Jaya 136 Reputation points
    2022-05-02T15:52:35.547+00:00

    You should cancel all the children run by canceling the parent.

    Any benefit to cancel child once a time? Just curious


0 additional answers

Sort by: Most helpful