Skip to content

Commit d3a9c44

Browse files
committed
Merge branch 'main' of https://github.com/MicrosoftDocs/azure-docs-pr into updateHarmonyConnect
2 parents 8803824 + 5d4a688 commit d3a9c44

9 files changed

+109
-34
lines changed

articles/machine-learning/how-to-create-manage-compute-instance.md

Lines changed: 54 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -137,9 +137,10 @@ Where the file *create-instance.yml* is:
137137

138138
* Enable SSH access. Follow the [detailed SSH access instructions](#enable-ssh-access) below.
139139
* Enable virtual network. Specify the **Resource group**, **Virtual network**, and **Subnet** to create the compute instance inside an Azure Virtual Network (vnet). You can also select __No public IP__ (preview) to prevent the creation of a public IP address, which requires a private link workspace. You must also satisfy these [network requirements](./how-to-secure-training-vnet.md) for virtual network setup.
140-
* Assign the computer to another user. For more about assigning to other users, see [Create on behalf of](#create-on-behalf-of-preview).inel
140+
* Assign the computer to another user. For more about assigning to other users, see [Create on behalf of](#create-on-behalf-of-preview)
141141
* Provision with a setup script (preview) - for more information about how to create and use a setup script, see [Customize the compute instance with a script](how-to-customize-compute-instance.md).
142142
* Add schedule (preview). Schedule times for the compute instance to automatically start and/or shutdown. See [schedule details](#schedule-automatic-start-and-stop-preview) below.
143+
* Enable auto-stop (preview). Configure a compute instance to automatically shutdown if it is inactive. See [configure auto-stop](#configure-auto-stop-preview) for more details.
143144

144145

145146

@@ -157,6 +158,58 @@ SSH access is disabled by default. SSH access can't be changed after creation.
157158

158159
---
159160

161+
## Configure auto-stop (preview)
162+
To avoid getting charged for a compute instance that is switched on but inactive, you can configure auto-stop.
163+
164+
A compute instance is considered inactive if the below conditions are met:
165+
* No active Jupyter Kernel sessions (this translates to no Notebooks usage via Jupyter, JupyterLab or Interactive notebooks)
166+
* No active Jupyter terminal sessions
167+
* No active AzureML runs or experiments
168+
* No SSH connections
169+
* No VS code connections; you must close your VS Code connection for your compute instance to be considered inactive. Sessions are auto-terminated if VS code detects no activity for 3 hours.
170+
171+
Note that activity on custom applications installed on the compute instance is not considered. There are also some basic bounds around inactivity time periods; CI must be inactive for a minimum of 15 mins and a maximum of 3 days.
172+
173+
This setting can be configured during CI creation or for existing CIs via the following interfaces:
174+
* AzureML Studio
175+
176+
:::image type="content" source="media/how-to-create-attach-studio/idle-shutdown-advanced-settings.jpg" alt-text="Screenshot of the Advanced Settings page for creating a compute instance":::
177+
:::image type="content" source="media/how-to-create-attach-studio/idle-shutdown-update.jpg" alt-text="Screenshot of the compute instance details page showing how to update an existing compute instance with idle shutdown":::
178+
179+
* REST API
180+
181+
Endpoint:
182+
```
183+
POST https://management.azure.com/subscriptions/{SUB_ID}/resourceGroups/{RG_NAME}/providers/Microsoft.MachineLearningServices/workspaces/{WS_NAME}/computes/{CI_NAME}/updateIdleShutdownSetting?api-version=2021-07-01
184+
```
185+
Body:
186+
```JSON
187+
{
188+
"idleTimeBeforeShutdown": "PT30M" // this must be a string in ISO 8601 format
189+
}
190+
```
191+
192+
* CLIv2 (YAML) -- only configurable during new CI creation
193+
194+
```YAML
195+
# Note that this is just a snippet for the idle shutdown property. Refer to the "Create" Azure CLI section for more information.
196+
idle_time_before_shutdown_minutes: 30
197+
```
198+
199+
* Python SDKv2 -- only configurable during new CI creation
200+
201+
```Python
202+
ComputeInstance(name=ci_basic_name, size="STANDARD_DS3_v2", idle_time_before_shutdown_minutes="30")
203+
```
204+
205+
* ARM Templates -- only configurable during new CI creation
206+
```JSON
207+
// Note that this is just a snippet for the idle shutdown property in an ARM template
208+
{
209+
"idleTimeBeforeShutdown":"PT30M" // this must be a string in ISO 8601 format
210+
}
211+
```
212+
160213
## Create on behalf of (preview)
161214
162215
As an administrator, you can create a compute instance on behalf of a data scientist and assign the instance to them with:

articles/machine-learning/how-to-deploy-custom-container.md

Lines changed: 2 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -34,35 +34,12 @@ Custom container deployments can use web servers other than the default Python F
3434
3535
## Prerequisites
3636

37-
* You must have an Azure resource group, in which you (or the service principal you use) need to have `Contributor` access. You'll have such a resource group if you configured your ML extension per the above article.
37+
[!INCLUDE [cli & sdk](../../includes/machine-learning-cli-sdk-v2-prereqs.md)]
3838

39-
* You must have an Azure Machine Learning workspace. You'll have such a workspace if you configured your ML extension per the above article.
39+
* You, or the service principal you use, must have `Contributor` access to the Azure Resource Group that contains your workspace. You'll have such a resource group if you configured your workspace using the quickstart article.
4040

4141
* To deploy locally, you must have [Docker engine](https://docs.docker.com/engine/install/) running locally. This step is **highly recommended**. It will help you debug issues.
4242

43-
# [Azure CLI](#tab/cli)
44-
45-
* Install and configure the Azure CLI and ML extension. For more information, see [Install, set up, and use the CLI (v2)](how-to-configure-cli.md).
46-
47-
* If you've not already set the defaults for Azure CLI, you should save your default settings. To avoid having to repeatedly pass in the values, run:
48-
49-
```azurecli
50-
az account set --subscription <subscription id>
51-
az configure --defaults workspace=<azureml workspace name> group=<resource group>
52-
```
53-
54-
# [Python SDK](#tab/python)
55-
56-
* If you haven't installed Python SDK v2, please install with this command:
57-
58-
```azurecli
59-
pip install --pre azure-ai-ml
60-
```
61-
62-
For more information, see [Install the Azure Machine Learning SDK v2 for Python](/python/api/overview/azure/ml/installv2).
63-
64-
---
65-
6643
## Download source code
6744

6845
To follow along with this tutorial, download the source code below.

articles/machine-learning/how-to-deploy-managed-online-endpoint-sdk-v2.md

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,10 +26,8 @@ In this article, you learn how to deploy your machine learning model to managed
2626

2727
## Prerequisites
2828

29-
* If you don't have an Azure subscription, create a free account before you begin. Try the [free or paid version of Azure Machine Learning](https://azure.microsoft.com/free/) today.
30-
* The [Azure Machine Learning SDK v2 for Python](/python/api/overview/azure/ml/installv2).
31-
* You must have an Azure resource group, and you (or the service principal you use) must have Contributor access to it.
32-
* You must have an Azure Machine Learning workspace.
29+
[!INCLUDE [sdk](../../includes/machine-learning-sdk-v2-prereqs.md)]
30+
3331
* To deploy locally, you must install [Docker Engine](https://docs.docker.com/engine/) on your local computer. We highly recommend this option, so it's easier to debug issues.
3432

3533
### Clone examples repository
178 KB
Loading
152 KB
Loading

articles/machine-learning/tutorial-create-secure-workspace.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -436,7 +436,7 @@ For more information on creating a compute cluster and compute cluster, includin
436436
When Azure Container Registry is behind the virtual network, Azure Machine Learning can't use it to directly build Docker images (used for training and deployment). Instead, configure the workspace to use the compute cluster you created earlier. Use the following steps to create a compute cluster and configure the workspace to use it to build images:
437437

438438
1. Navigate to [https://shell.azure.com/](https://shell.azure.com/) to open the Azure Cloud Shell.
439-
1. From the Cloud Shell, use the following command to install the 1.0 CLI for Azure Machine Learning:
439+
1. From the Cloud Shell, use the following command to install the 2.0 CLI for Azure Machine Learning:
440440

441441
```azurecli-interactive
442442
az extension add -n ml

includes/machine-learning-cli-prereqs.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,17 +2,17 @@
22
author: blackmist
33
ms.service: machine-learning
44
ms.topic: include
5-
ms.date: 10/26/2021
5+
ms.date: 09/14/2022
66
ms.author: larryfr
77
---
88

99
Before following the steps in this article, make sure you have the following prerequisites:
1010

1111
* An Azure subscription. If you don't have an Azure subscription, create a free account before you begin. Try the [free or paid version of Azure Machine Learning](https://azure.microsoft.com/free/).
1212

13-
* The [Azure CLI](/cli/azure/) and the `ml` extension to the Azure CLI. For more information, see [Install, set up, and use the CLI (v2) (preview)](../articles/machine-learning/how-to-configure-cli.md).
13+
* The [Azure CLI](/cli/azure/) and the `ml` extension to the Azure CLI. For more information, see [Install, set up, and use the CLI (v2)](../articles/machine-learning/how-to-configure-cli.md).
1414

1515
> [!IMPORTANT]
1616
> The CLI examples in this article assume that you are using the Bash (or compatible) shell. For example, from a Linux system or [Windows Subsystem for Linux](/windows/wsl/about).
1717
18-
* An Azure Machine Learning workspace. If you don't have one, use the steps in the [Install, set up, and use the CLI (v2) (preview)](../articles/machine-learning/how-to-configure-cli.md) to create one.
18+
* An Azure Machine Learning workspace. If you don't have one, use the steps in the [Install, set up, and use the CLI (v2)](../articles/machine-learning/how-to-configure-cli.md) to create one.
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
---
2+
author: blackmist
3+
ms.service: machine-learning
4+
ms.topic: include
5+
ms.date: 09/14/2022
6+
ms.author: larryfr
7+
---
8+
9+
Before following the steps in this article, make sure you have the following prerequisites:
10+
11+
* An Azure subscription. If you don't have an Azure subscription, create a free account before you begin. Try the [free or paid version of Azure Machine Learning](https://azure.microsoft.com/free/).
12+
13+
* An Azure Machine Learning workspace. If you don't have one, use the steps in the [Quickstart: Create workspace resources](../articles/machine-learning/quickstart-create-resources.md) article to create one.
14+
15+
* The [Azure CLI](/cli/azure/) and the `ml` extension to the Azure CLI. For more information, see [Install, set up, and use the CLI (v2)](../articles/machine-learning/how-to-configure-cli.md).
16+
17+
> [!IMPORTANT]
18+
> The CLI examples in this article assume that you are using the Bash (or compatible) shell. For example, from a Linux system or [Windows Subsystem for Linux](/windows/wsl/about).
19+
20+
* To install the Python SDK v2 (preview), use the following command:
21+
22+
```bash
23+
pip install --pre azure-ai-ml
24+
```
25+
26+
For more information, see [Install the Python SDK v2 for Azure Machine Learning](https://aka.ms/sdk-v2-install) (preview).
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
---
2+
author: blackmist
3+
ms.service: machine-learning
4+
ms.topic: include
5+
ms.date: 09/14/2022
6+
ms.author: larryfr
7+
---
8+
9+
Before following the steps in this article, make sure you have the following prerequisites:
10+
11+
* An Azure subscription. If you don't have an Azure subscription, create a free account before you begin. Try the [free or paid version of Azure Machine Learning](https://azure.microsoft.com/free/).
12+
13+
* An Azure Machine Learning workspace. If you don't have one, use the steps in the [Quickstart: Create workspace resources](../articles/machine-learning/quickstart-create-resources.md) article to create one.
14+
15+
* To install the Python SDK v2, use the following command:
16+
17+
```bash
18+
pip install --pre azure-ai-ml
19+
```
20+
21+
For more information, see [Install the Python SDK v2 for Azure Machine Learning](https://aka.ms/sdk-v2-install) (preview).

0 commit comments

Comments
 (0)