Skip to content

Commit 6586066

Browse files
authored
Update how-to-use-batch-endpoint.md
1 parent e9ce167 commit 6586066

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

articles/machine-learning/batch-inference/how-to-use-batch-endpoint.md

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -819,13 +819,15 @@ Although you can invoke a specific deployment inside of an endpoint, you will us
819819

820820
# [Azure ML CLI](#tab/cli)
821821

822-
```bash
823-
az ml batch-endpoint update --name $ENDPOINT_NAME --set defaults.deployment_name=$DEPLOYMENT_NAME
824-
```
822+
:::code language="azurecli" source="~/azureml-examples-main/cli/batch-score.sh" ID="update_default_deployment" :::
825823

826824
# [Azure ML SDK for Python](#tab/sdk)
827825

828-
:::code language="azurecli" source="~/azureml-examples-main/cli/batch-score.sh" ID="update_default_deployment" :::
826+
```python
827+
endpoint = ml_client.batch_endpoints.get(endpoint_name)
828+
endpoint.defaults.deployment_name = deployment.name
829+
ml_client.batch_endpoints.begin_create_or_update(endpoint)
830+
```
829831

830832
# [studio](#tab/studio)
831833

0 commit comments

Comments
 (0)