Skip to content

Commit 6c55d53

Browse files
committed
Extra edits
1 parent b89509f commit 6c55d53

File tree

1 file changed

+10
-8
lines changed

1 file changed

+10
-8
lines changed

articles/machine-learning/how-to-track-experiments-mlflow.md

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ Use MLflow to search for experiments inside of your workspace. See the following
6969
mlflow.get_experiment('1234-5678-90AB-CDEFG')
7070
```
7171

72-
### Search experiments
72+
### Searching experiments
7373

7474
The `search_experiments()` method, available since Mlflow 2.0, lets you search for experiments that match criteria using `filter_string`.
7575

@@ -131,7 +131,7 @@ By default, MLflow returns the data in Pandas `Dataframe` format, which makes it
131131

132132
All metrics and parameters are also returned when querying runs. However, for metrics that contain multiple values (for instance, a loss curve, or a PR curve), only the last value of the metric is returned. If you want to retrieve all the values of a given metric, uses `mlflow.get_metric_history` method. See [Getting params and metrics from a run](#getting-params-and-metrics-from-a-run) for an example.
133133

134-
### Order runs
134+
### Ordering runs
135135

136136
By default, experiments are ordered descending by `start_time`, which is the time the experiment was queued in Azure Machine Learning. However, you can change this default by using the parameter `order_by`.
137137

@@ -168,7 +168,7 @@ By default, experiments are ordered descending by `start_time`, which is the tim
168168
> [!WARNING]
169169
> Using `order_by` with expressions containing `metrics.*`, `params.*`, or `tags.*` in the parameter `order_by` isn't currently supported. Please use the `order_values` method from Pandas as shown in the example.
170170

171-
### Filter runs
171+
### Filtering runs
172172

173173
You can also look for a run with a specific combination in the hyperparameters using the parameter `filter_string`. Use `params` to access run's parameters, `metrics` to access metrics logged in the run, and `attributes` to access run information details. MLflow supports expressions joined by the AND keyword (the syntax doesn't support OR):
174174

@@ -246,6 +246,7 @@ You can also look for a run with a specific combination in the hyperparameters u
246246
When you filter runs by status, MLflow uses a different convention to name the different possible status of a run compared to Azure Machine Learning. The following table shows the possible values:
247247

248248
| Azure Machine Learning job status | MLFlow's `attributes.status` | Meaning |
249+
| :-: | :-: | :-: |
249250
| Not started | `Scheduled` | The job/run was received by Azure Machine Learning. |
250251
| Queue | `Scheduled` | The job/run is scheduled for running, but it hasn't started yet. |
251252
| Preparing | `Scheduled` | The job/run hasn't started yet, but a compute was allocated for its execution and it's preparing the environment and its inputs. |
@@ -261,7 +262,7 @@ mlflow.search_runs(experiment_ids=[ "1234-5678-90AB-CDEFG" ],
261262
filter_string="attributes.status = 'Failed'")
262263
```
263264

264-
## Gett metrics, parameters, artifacts, and models
265+
## Getting metrics, parameters, artifacts, and models
265266

266267
The method `search_runs` returns a Pandas `Dataframe` that contains a limited amount of information by default. You can get Python objects if needed, which might be useful to get details about them. Use the `output_format` parameter to control how output is returned:
267268

@@ -280,7 +281,7 @@ last_run = runs[-1]
280281
print("Last run ID:", last_run.info.run_id)
281282
```
282283

283-
### Get params and metrics from a run
284+
### Getting params and metrics from a run
284285

285286
When runs are returned using `output_format="list"`, you can easily access parameters using the key `data`:
286287

@@ -301,7 +302,7 @@ client = mlflow.tracking.MlflowClient()
301302
client.get_metric_history("1234-5678-90AB-CDEFG", "log_loss")
302303
```
303304

304-
### Get artifacts from a run
305+
### Getting artifacts from a run
305306

306307
MLflow can query any artifact logged by a run. Artifacts can't be accessed using the run object itself, and the MLflow client should be used instead:
307308

@@ -321,7 +322,7 @@ file_path = mlflow.artifacts.download_artifacts(
321322
> [!NOTE]
322323
> In legacy versions of MLflow (<2.0), use the method `MlflowClient.download_artifacts()` instead.
323324

324-
### Get models from a run
325+
### Getting models from a run
325326

326327
Models can also be logged in the run and then retrieved directly from it. To retrieve it, you need to know the artifact's path where it's stored. The method `list_artifacts` can be used to find artifacts that represent a model since MLflow models are always folders. You can download a model by indicating the path where the model is stored using the `download_artifact` method:
327328

@@ -347,7 +348,7 @@ model = mlflow.xgboost.load_model(f"runs:/{last_run.info.run_id}/{artifact_path}
347348
> [!TIP]
348349
> To query and load models registered in the model registry, see [Manage models registries in Azure Machine Learning with MLflow](how-to-manage-models-mlflow.md).
349350

350-
## Get child (nested) runs
351+
## Getting child (nested) runs
351352

352353
MLflow supports the concept of child (nested) runs. They're useful when you need to spin off training routines that must be tracked independently from the main training process. Hyper-parameter tuning optimization processes or Azure Machine Learning pipelines are typical examples of jobs that generate multiple child runs. You can query all the child runs of a specific run using the property tag `mlflow.parentRunId`, which contains the run ID of the parent run.
353354

@@ -379,6 +380,7 @@ The [MLflow with Azure Machine Learning notebooks](https://github.com/Azure/azur
379380
The MLflow SDK exposes several methods to retrieve runs, including options to control what is returned and how. Use the following table to learn about which of those methods are currently supported in MLflow when connected to Azure Machine Learning:
380381

381382
| Feature | Supported by MLflow | Supported by Azure Machine Learning |
383+
| :-: | :-: | :-: |
382384
| Ordering runs by attributes | **&check;** | **&check;** |
383385
| Ordering runs by metrics | **&check;** | <sup>1</sup> |
384386
| Ordering runs by parameters | **&check;** | <sup>1</sup> |

0 commit comments

Comments
 (0)