Skip to content

Commit 0480665

Browse files
AbeOmorLarry Franks
andauthored
Apply suggestions from code review
Co-authored-by: Larry Franks <[email protected]>
1 parent 9355728 commit 0480665

File tree

1 file changed

+28
-28
lines changed

1 file changed

+28
-28
lines changed

articles/machine-learning/how-to-setup-mlops-github-azureml.md

Lines changed: 28 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -20,12 +20,12 @@ ms.custom: cli-v2, sdk-v2, github-actions-azure
2020
Azure Machine Learning allows you to integrate with [GitHub Actions](https://docs.github.com/actions) to automate the machine learning lifecycle. Some of the operations you can automate are:
2121

2222
* Deployment of Azure Machine Learning infrastructure.
23-
* Data preparation (extract, transform, load operations)
24-
* Training machine learning models with on-demand scale-out and scale-up
25-
* Deployment of machine learning models as public or private web services
26-
* Monitoring deployed machine learning models (such as for performance analysis)
23+
* Data preparation (extract, transform, load operations).
24+
* Training machine learning models with on-demand scale-out and scale-up.
25+
* Deployment of machine learning models as public or private web services.
26+
* Monitoring deployed machine learning models (such as for performance analysis).
2727

28-
In this article, you learn about using Azure Machine Learning to set up an end-to-end MLOps pipeline that runs a linear regression to predict taxi fares in NYC. The pipeline is made up of components, each serving different functions, which can be registered with the workspace, versioned, and reused with various inputs and outputs. you're going to be using the [recommended Azure architecture for MLOps](/azure/architecture/data-guide/technology-choices/machine-learning-operations-v2) and [Azure MLOps (v2) solution accelerator](https://github.com/Azure/mlops-v2) to quickly setup an MLOps project in Azure Machine Learning.
28+
In this article, you learn about using Azure Machine Learning to set up an end-to-end MLOps pipeline that runs a linear regression to predict taxi fares in NYC. The pipeline is made up of components, each serving different functions, which can be registered with the workspace, versioned, and reused with various inputs and outputs. You'll be using the [recommended Azure architecture for MLOps](/azure/architecture/data-guide/technology-choices/machine-learning-operations-v2) and [Azure MLOps (v2) solution accelerator](https://github.com/Azure/mlops-v2) to quickly setup an MLOps project in Azure Machine Learning.
2929

3030
> [!TIP]
3131
> We recommend you understand some of the [recommended Azure architectures](/azure/architecture/data-guide/technology-choices/machine-learning-operations-v2) for MLOps before implementing any solution. You'll need to pick the best architecture for your given Machine learning project.
@@ -161,7 +161,7 @@ This step deploys the training pipeline to the Machine Learning workspace create
161161
> [!TIP]
162162
> Make sure you understand the [Architectural Patterns](/azure/architecture/data-guide/technology-choices/machine-learning-operations-v2) of the solution accelerator before you checkout the MLOps v2 repo and deploy the infrastructure. In examples you'll use the [classical ML project type](/azure/architecture/data-guide/technology-choices/machine-learning-operations-v2#classical-machine-learning-architecture).
163163
164-
### Configure Machine Learning environment parameters
164+
### Configure machine learning environment parameters
165165
1. Go to your repository and select the `config-infra-prod.yml` file in the root. Change the following parameters to your liking, and then **commit** the changes.
166166
167167
This config file uses the namespace and postfix values the names of the artifacts to ensure uniqueness. Update the following section in the config to your liking. Default values and settings in the files are show below:
@@ -177,31 +177,31 @@ This step deploys the training pipeline to the Machine Learning workspace create
177177
enable_monitoring: false
178178
```
179179
> [!NOTE]
180-
> If you are running a Deep Learning workload such as CV or NLP, ensure your GPU compute is available in your deployment zone.
181-
> The enable_monitoring flag in these files defaults to False. Enabling this flag will add additional elements to the deployment to support Azure ML monitoring based on https://github.com/microsoft/AzureML-Observability. This will include an ADX cluster and increase the deployment time and cost of the MLOps solution.
180+
> If you are running a deep learning workload such as CV or NLP, ensure your GPU compute is available in your deployment zone.
181+
> The enable_monitoring flag in these files defaults to False. Enabling this flag will add additional elements to the deployment to support Azure Machine Learning monitoring based on https://github.com/microsoft/AzureML-Observability. This will include an ADX cluster and increase the deployment time and cost of the MLOps solution.
182182
183-
### Deploy Machine Learning infrastructure
183+
### Deploy machine learning infrastructure
184184
185185
1. In your GitHub project repository (ex: taxi-fare-regression), select **Actions**
186186
187187
![GitHub actions](./media/how-to-setup-mlops-azureml/gh-actions.png)
188188
189-
This displays the pre-defined GitHub workflows associated with your project. For a classical machine learning project, the available workflows look similar to this:
189+
This displays the pre-defined GitHub workflows associated with your project. For a classical machine learning project, the available workflows look similar to this:
190190
191191
![GitHub workflows](./media/how-to-setup-mlops-azureml/gh-workflows.png)
192192
193-
1. Select would be **tf-gha-deploy-infra.yml**. This would deploy the Azure ML infrastructure using GitHub Actions and Terraform.
193+
1. Select would be **tf-gha-deploy-infra.yml**. This would deploy the Azure Machine Learning infrastructure using GitHub Actions and Terraform.
194194
195195
![GitHub deploy-infra](./media/how-to-setup-mlops-azureml/gh-deploy-infra.png)
196196
197197
1. On the right side of the page, select **Run workflow** and select the branch to run the workflow on. This may deploy Dev Infrastructure if you've created a dev branch or Prod infrastructure if deploying from main. Monitor the workflow for successful completion.
198198

199199
![GitHub infra pipeline](./media/how-to-setup-mlops-azureml/gh-infra-pipeline.png)
200200

201-
1. When the pipeline has complete successfully, you can find your Azure ML Workspace and associated resources by logging in to the Azure Portal. Next, a model training and scoring pipelines will be deployed into the new Machine Learning environment.
201+
1. When the pipeline has complete successfully, you can find your Azure ML Workspace and associated resources by logging in to the Azure portal. Next, a model training and scoring pipelines will be deployed into the new machine learning environment.
202202

203203

204-
## Sample Training and Deployment Scenario
204+
## Sample training and deployment scenario
205205

206206
The solution accelerator includes code and data for a sample end-to-end machine learning pipeline which runs a linear regression to predict taxi fares in NYC. The pipeline is made up of components, each serving different functions, which can be registered with the workspace, versioned, and reused with various inputs and outputs. Sample pipelines and workflows for the Computer Vision and NLP scenarios will have different steps and deployment steps.
207207

@@ -228,9 +228,9 @@ This training pipeline contains the following steps:
228228
- Input: Trained model and the deploy flag.
229229
- Output: Registered model in Machine Learning.
230230

231-
## Deploying the Model Training Pipeline
231+
## Deploying the model training pipeline
232232

233-
Next, you will deploy the model training pipeline to your new Machine Learning workspace. This pipeline will create a compute cluster instance, register a training environment defining the necessary Docker image and python packages, register a training dataset, then start the training pipeline described in the last section. When the job is complete, the trained model will be registered in the Azure ML workspace and be available for deployment.
233+
Next, you will deploy the model training pipeline to your new machine learning workspace. This pipeline will create a compute cluster instance, register a training environment defining the necessary Docker image and python packages, register a training dataset, then start the training pipeline described in the last section. When the job is complete, the trained model will be registered in the Azure Machine Learning workspace and be available for deployment.
234234

235235
1. In your GitHub project repository (example: taxi-fare-regression), select **Actions**
236236

@@ -240,57 +240,57 @@ Next, you will deploy the model training pipeline to your new Machine Learning w
240240

241241
![Pipeline Run](./media/how-to-setup-mlops-azureml/gh-training-pipeline.png)
242242

243-
1. Once completed, a successful run will register the model in the Machine Learning workspace.
243+
1. Once completed, a successful run will register the model in the machine learning workspace.
244244

245245
![Training Step](./media/how-to-setup-mlops-azureml/gh-training-step.png)
246246

247247
> [!NOTE]
248248
> If you want to check the output of each individual step, for example to view output of a failed run, click a job output, and then click each step in the job to view any output of that step.
249249

250-
With the trained model registered in the Machine learning workspace, you are ready to deploy the model for scoring.
250+
With the trained model registered in the machine learning workspace, you are ready to deploy the model for scoring.
251251

252-
### Deploying the Trained Model
252+
### Deploying the trained model
253253

254-
This scenario includes prebuilt workflows for two approaches to deploying a trained model, batch scoring or a deploying a model to an endpoint for real-time scoring. You may run either or both of these workflows to test the performance of the model in your Azure ML workspace.
254+
This scenario includes prebuilt workflows for two approaches to deploying a trained model, batch scoring or a deploying a model to an endpoint for real-time scoring. You may run either or both of these workflows to test the performance of the model in your Azure Machine Learning workspace.
255255

256256
1. In your GitHub project repository (ex: taxi-fare-regression), select **Actions**
257257

258258
![GitHub actions pages](./media/how-to-setup-mlops-azureml/gh-actions.png)
259259

260-
### Online Endpoint
260+
### Online endpoint
261261

262-
1. Select the **deploy-online-endpoint-pipeline** from the workflows listed on the left and click **Run workflow** to execute the online endpoint deployment pipeline workflow. The steps in this pipeline will create an online endpoint in your Machine Learning workspace, create a deployment of your model to this endpoint, then allocate traffic to the endpoint.
262+
1. Select the **deploy-online-endpoint-pipeline** from the workflows listed on the left and click **Run workflow** to execute the online endpoint deployment pipeline workflow. The steps in this pipeline will create an online endpoint in your machine learning workspace, create a deployment of your model to this endpoint, then allocate traffic to the endpoint.
263263

264264
![GitHub online endpoint](./media/how-to-setup-mlops-azureml/gh-online-endpoint.png)
265265

266-
Once completed, you will find the online endpoint deployed in the Azure ML workspace and available for testing.
266+
Once completed, you will find the online endpoint deployed in the Azure Machine Learning workspace and available for testing.
267267

268268
![Machine Learning taxi online endpoint](./media/how-to-setup-mlops-azureml/aml-taxi-oep.png)
269269

270-
1. To test this deployment, go to the **Endpoints** tab in your Machine Learning workspace, select the endpoint and click the **Test** Tab. You can use the sample input data located in the cloned repo at `/data/taxi-request.json` to test the endpoint.
270+
1. To test this deployment, go to the **Endpoints** tab in your machine learning workspace, select the endpoint and click the **Test** Tab. You can use the sample input data located in the cloned repo at `/data/taxi-request.json` to test the endpoint.
271271

272272
![AzureML taxi Online endpoint test](./media/how-to-setup-mlops-azureml/azureml-online-endpoint-test.png)
273273

274-
### Batch Endpoint
274+
### Batch endpoint
275275

276-
1. Select the **deploy-batch-endpoint-pipeline** from the workflows and click **Run workflow** to execute the batch endpoint deployment pipeline workflow. The steps in this pipeline will create a new AmlCompute cluster on which to execute batch scoring, create the batch endpoint in your Machine Learning workspace, then create a deployment of your model to this endpoint.
276+
1. Select the **deploy-batch-endpoint-pipeline** from the workflows and click **Run workflow** to execute the batch endpoint deployment pipeline workflow. The steps in this pipeline will create a new Azure Machine Learning compute cluster on which to execute batch scoring, create the batch endpoint in your machine learning workspace, then create a deployment of your model to this endpoint.
277277

278278
![GitHub batch endpoint](./media/how-to-setup-mlops-azureml/gh-batch-endpoint.png)
279279

280-
2. Once completed, you will find the batch endpoint deployed in the Azure ML workspace and available for testing.
280+
2. Once completed, you will find the batch endpoint deployed in the Azure Machine Learning workspace and available for testing.
281281

282282
![Machine Learning taxi batch endpoint](./media/how-to-setup-mlops-azureml/aml-taxi-bep.png)
283283

284284
## Moving to production
285285

286286
Example scenarios can be trained and deployed both for Dev and Prod branches and environments. When you are satisfied with the performance of the model training pipeline, model, and deployment in Testing, Dev pipelines and models can be replicated and deployed in the Production environment.
287287

288-
The sample training and deployment Machine Learning pipelines and GitHub workflows can be used as a starting point to adapt your own modeling code and data.
288+
The sample training and deployment machine learning pipelines and GitHub workflows can be used as a starting point to adapt your own modeling code and data.
289289

290290
## Clean up resources
291291

292292
1. If you're not going to continue to use your pipeline, delete your Azure DevOps project.
293-
1. In Azure portal, delete your resource group and Machine Learning instance.
293+
1. In Azure portal, delete your resource group and Azure Machine Learning instance.
294294
295295
## Next steps
296296

0 commit comments

Comments
 (0)