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/tutorial-1st-experiment-hello-world.md
+23-9Lines changed: 23 additions & 9 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -33,11 +33,21 @@ In this tutorial, you will:
33
33
## Prerequisites
34
34
35
35
- Complete [Quickstart: Set up your workspace to get started with Azure Machine Learning](quickstart-create-resources.md) to create a workspace, compute instance, and compute cluster to use in this tutorial series.
36
-
- If an older compute instance is used, install `azure-ai-ml` by running the below command in a notebook cell. New compute instances will have this package pre-installed.
37
36
38
-
```python
39
-
pip install azure-ai-ml
40
-
```
37
+
- The Azure Machine Learning Python SDK v2 (preview) installed.
38
+
39
+
To install the SDK you can either,
40
+
* Create a compute instance, which automatically installs the SDK and is pre-configured for ML workflows. For more information, see [Create and manage an Azure Machine Learning compute instance](how-to-create-manage-compute-instance.md).
41
+
42
+
* Use the following commands to install Azure ML Python SDK v2:
43
+
* Uninstall previous preview version:
44
+
```python
45
+
pip uninstall azure-ai-ml
46
+
```
47
+
* Install the Azure ML Python SDK v2:
48
+
```python
49
+
pip install azure-ai-ml
50
+
```
41
51
42
52
## Create and run a Python script
43
53
@@ -89,14 +99,18 @@ Select the **...** at the end of **get-started** folder to create a new file. Cr
89
99
# get-started/run-hello.py
90
100
from azure.ai.ml import MLClient, command, Input
91
101
from azure.identity import DefaultAzureCredential
102
+
from azureml.core import Workspace
103
+
104
+
# get details of the current Azure ML workspace
105
+
ws = Workspace.from_config()
92
106
93
107
# default authentication flow for Azure applications
0 commit comments