There are many references explaining how to train a model on Azure Machine Learning. There're also plenty of documents demonstrating how to deploy the trained model. However, even for experienced users it may be challenging to know what will the final consumption look like. Azure pricing calculator is an excellent tool to predict the possible price, however, on Azure Machine Learning, there may be some underlying issues, that are not at all evident. In this short article we are going to uncover some of these hidden facilities. Up we go!
Compute Pricing
The price is mainly impacted by compute resources associated with Azure Machine Learning Services. They vary by configuration and family, and should be chosen according to the usage context. For instance, huge language models like BERT will require GPU instances due to their volume. On Azure Machine Learning there are compute clusters and compute instances.
A managed compute resource is created and managed by Azure Machine Learning. This compute is optimized for machine learning workloads. Azure Machine Learning compute clusters and compute instances are the only managed computes.
You can create Azure Machine Learning compute instances or compute clusters from:
The Python SDK and CLI:
The R SDK (preview).
An Azure Resource Manager template. For an example template, see Create an Azure Machine Learning compute cluster.
A machine learning extension for the Azure CLI.
When created, these compute resources are automatically part of your workspace, unlike other kinds of compute targets.
Note : When a compute cluster is idle, it autoscales to 0 nodes, so you don't pay when it's not in use. A compute instance is always on and doesn't autoscale. You should stop the compute instance when you aren't using it to avoid extra cost..
For more details on pricing for computational instances, please refer to the official documentation.
Deployment Pricing
If Azure Machine Learning is only used for model deployment, the steps performed by Azure Machine Learning are:
Build a Container Image for the trained model
Deploy the model to "dev" using Azure Container Instances (ACI)
Deploy the model to production using Azure Kubernetes Service (AKS)
All these steps do not involve compute instance creation, so no computational cost is considered. More details are provided in the next session (Managed compute resource).
If you train your model locally and deploy it as web service using the SDK, on your instance three resources will be deployed that will incur additional charges
Azure Container Registry Basic account
Azure Block Blob Storage (general purpose v1)
Key Vault
Azure Container Registry Basic account
Here's an example of Container Registry
Region: West Europe
Currency: US Dollar
Azure Block Blob Storage (general purpose v1)
Region: West Europe
Currency: US Dollar
Data storage prices pay-as-you-go
All prices are per GB per month.
Key Vault
Vaults are offered in two service tiers—standard and premium.
Hope this was useful!
Comments