Global AI Workshops
  • Welcome
  • Getting started
    • Lab 1 - Get Azure Access
    • Lab 2 - Setup Dev Environment
  • The Azure Function that can see
    • Introduction
    • Lab 1 - Train your model
    • Lab 2 - Create the Function
    • Clean up
  • Cognitive Services
    • Lab 1 - Cognitive Search
    • Lab 2 - Bot Composer
  • Azure machine learning
    • Introduction
    • Lab 1 - AML Workspace Setup
    • Lab 2 - Data
    • Lab 3 - Train your model
    • Lab 4 - Deploy to an ACI
      • Lab 4.2 - Deploy to ACI using the Azure Portal
      • Lab 4.1 - Deploy to ACI using Python
    • Lab 5 - Deploy to Managed Endpoint
    • Clean Up
Powered by GitBook
On this page
  • Create a Azure Machine Learning Workspace
  • Create a resource group
  • Create the Azure Machine Learning Workspace
  • Make things easier
  • Create a Compute Cluster
  • Setup completed

Was this helpful?

  1. Azure machine learning

Lab 1 - AML Workspace Setup

PreviousIntroductionNextLab 2 - Data

Last updated 3 years ago

Was this helpful?

Create a Azure Machine Learning Workspace

To get started we need to setup a few resources in Azure. Please follow this .

Create a resource group

The Azure Machine Learning workspace must be created inside a resource group. You can use an existing resource group or create a new one. To create a new resource group, use the following command. Replace with the name to use for this resource group. Replace with the Azure region to use for this resource group:

Example name and location:

  • resource group name: pytorchworkshop

  • location: WestEurope or eastus

Location: Choose eastus or WestEurope, this is needed for the compute we are using later.

az group create --name <resource-group-name> --location <location>

Create the Azure Machine Learning Workspace

To create a new workspace where the services are automatically created, use the following command:

az ml workspace create -w <workspace-name> -g <resource-group-name>

If the az ml command does not work run: az extension add -n ml -y

You can now view your workspace by visiting

Make things easier

After every az ml command you have to type "-w <workspace-name> -g <resource-group-name>". You can make everything a bit easier by settings the values for this parameters by default.

az configure --defaults workspace=<workspace-name> group=<resource-group-name>

Create a Compute Cluster

To train our model we need an Azure Machine Learning Compute cluster. To create a new compute cluster, use the following command.

This command will create an Azure Machine Learning Compute cluster with 1 node that is always on and is using STANDARD_NC6 virtual Machines.

To speed up the training process you can use a GPU enabled NC6 machine

az ml compute create --type amlcompute -n gpu-cluster --min-instances 0 --max-instances 1 --size STANDARD_NC6

Creating compute can take a few minutes to complete

To see the list of created compute in your workspace you can type:

az ml compute list --output table

Setup completed

The setup of your workspace with compute is now completed

View your created Azure Machine Learning Compute cluster on

guide to setup your dev environment
https://ml.azure.com
https://ml.azure.com