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-use-mlflow-cli-runs.md
+9-6Lines changed: 9 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -42,12 +42,15 @@ See [MLflow and Azure Machine Learning](concept-mlflow.md) for all supported MLf
42
42
43
43
## Track runs from your local machine
44
44
45
-
MLflow Tracking with Azure Machine Learning lets you store the logged metrics and artifacts runs that were executed on your local machine into your Azure Machine Learning workspace. Make sure you are logged in to your Azure account, otherwise your the tracking URI returns an empty string.
45
+
MLflow Tracking with Azure Machine Learning lets you store the logged metrics and artifacts runs that were executed on your local machine into your Azure Machine Learning workspace.
46
46
47
47
### Set up tracking environment
48
48
49
49
To track a local run, you need to point your local machine to the Azure Machine Learning MLflow Tracking URI.
50
50
51
+
>[!IMPORTANT]
52
+
> Make sure you are logged in to your Azure account, otherwise the tracking URI returns an empty string.
53
+
51
54
# [MLflow SDK](#tab/mlflow)
52
55
53
56
The following code uses `mlflow` and the [`subprocess`](https://docs.python.org/3/library/subprocess.html) classes in Python to run the Azure Machine Learning CLI (v2) command to retrieve the unique MLFLow tracking URI associated with your workspace. Then the method [`set_tracking_uri()`](https://mlflow.org/docs/latest/python_api/mlflow.html#mlflow.set_tracking_uri) points the MLflow tracking URI to that URI.
@@ -56,23 +59,23 @@ The following code uses `mlflow` and the [`subprocess`](https://docs.python.org/
56
59
import mlflow
57
60
import subprocess
58
61
59
-
#Get MLFLow URI through the Azure ML CLI (v2) and convert to string
62
+
#Get MLfLow URI through the Azure ML CLI (v2) and convert to string
Another option is to set one of the MLflow environment variables [MLFLOW_TRACKING_URI](https://mlflow.org/docs/latest/tracking.html#logging-to-a-tracking-server) directly in your terminal.
78
+
Another option is to set one of the MLflow environment variables [MLFLOW_TRACKING_URI](https://mlflow.org/docs/latest/tracking.html#logging-to-a-tracking-server) directly in your terminal.
76
79
77
80
```Azure CLI
78
81
# Configure MLflow to communicate with a Azure Machine Learning-hosted tracking server
@@ -84,7 +87,7 @@ export MLFLOW_TRACKING_URI=$(az ml workspace show --query mlflow_tracking_uri |
84
87
85
88
### Set experiment name
86
89
87
-
All MLflow runs are logged to the active experiment, which can be set using MLflow SDK or the Azure CLI.
90
+
All MLflow runs are logged to the active experiment, which can be set with the MLflow SDK or Azure CLI.
88
91
89
92
# [MLflow SDK](#tab/mlflow)
90
93
@@ -130,7 +133,7 @@ MLflow Tracking with Azure Machine Learning lets you store the logged metrics an
130
133
131
134
First, you should create a `src` subdirectory and create a file with your training code in a `train.py` file in the `src` subdirectory. All your training code will go into the `src` subdirectory, including `train.py`.
132
135
133
-
The training code is taken from this [MLFLow example](https://github.com/Azure/azureml-examples/blob/main/cli/jobs/basics/src/hello-mlflow.py) in the Azure Machine Learning example repo.
136
+
The training code is taken from this [MLfLow example](https://github.com/Azure/azureml-examples/blob/main/cli/jobs/basics/src/hello-mlflow.py) in the Azure Machine Learning example repo.
In this article, learn how to enable MLflow's tracking URI and logging API, collectively known as [MLflow Tracking](https://mlflow.org/docs/latest/quickstart.html#using-the-tracking-api), to connect Azure Machine Learning as the backend of your MLflow experiments.
19
19
20
+
> [!TIP]
21
+
> For a more streamlined experience, see how to [Track experiments with the MLflow SDK or the Azure Machine Learning CLI (v2) (preview)](how-to-use-mlflow-cli.md)
22
+
20
23
Supported capabilities include:
21
24
22
25
+ Track and log experiment metrics and artifacts in your [Azure Machine Learning workspace](./concept-azure-machine-learning-architecture.md#workspace). If you already use MLflow Tracking for your experiments, the workspace provides a centralized, secure, and scalable location to store training metrics and models.
@@ -123,7 +126,7 @@ run.get_metrics()
123
126
124
127
## Manage models
125
128
126
-
Register and track your models with the [Azure Machine Learning model registry](concept-model-management-and-deployment.md#register-package-and-deploy-models-from-anywhere) which supports the MLflow model registry. Azure Machine Learning models are aligned with the MLflow model schema making it easy to export and import these models across different workflows. The MLflow related metadata such as, run ID is also tagged with the registered model for traceability. Users can submit training runs, register, and deploy models produced from MLflow runs.
129
+
Register and track your models with the [Azure Machine Learning model registry](concept-model-management-and-deployment.md#register-package-and-deploy-models-from-anywhere), which supports the MLflow model registry. Azure Machine Learning models are aligned with the MLflow model schema making it easy to export and import these models across different workflows. The MLflow related metadata such as, run ID is also tagged with the registered model for traceability. Users can submit training runs, register, and deploy models produced from MLflow runs.
127
130
128
131
If you want to deploy and register your production ready model in one step, see [Deploy and register MLflow models](how-to-deploy-mlflow-models.md).
0 commit comments