Microsoft Azure Machine Learning Client Library for Python
Project description
The azure-ai-ml is a Python SDK package (aka AML SDKv2) for Azure Machine Learning, which allows users to:
Submit training jobs
Manage data, models, environments
Perform managed inferencing (real time and batch)
Stitch together multiple tasks and production workflows using Azure ML pipelines
Source code | Package (PyPI) | Product documentation | Samples
This package has been tested with Python 3.7, 3.8, 3.9 and 3.10.
For a more complete set of Azure libraries, see https://aka.ms/azsdk/python/all
The SDK v2 is useful in the following scenarios:
- Move from simple to complex concepts incrementally. SDK v2 allows you to:
Construct a single command.
Add a hyperparameter sweep on top of that command
Add the command with various others into a pipeline one after the other.
This construction is useful, given the iterative nature of machine learning.
Reusable components in pipelines
Azure ML introduces components for managing and reusing common logic across pipelines. This functionality is available only via CLI v2 and SDK v2.
Managed inferencing
Azure ML offers endpoints to streamline model deployments for both real-time and batch inference deployments. This functionality is available only via CLI v2 and SDK v2.
Getting started
Read through this Install and set up SDK (v2)
Read through this Train models with the Azure ML Python SDK v2 (preview)
Read through this Tutorial: Create production ML pipelines with Python SDK v2 (preview) in a Jupyter notebook
Prerequisites
Python 3.7 later is required to use this package.
You must have an Azure subscription.
Install the package
Install the Azure ML client library for Python with pip:
pip install --pre azure-ai-ml
Authenticate the client
from azure.ai.ml import MLClient
from azure.identity import DefaultAzureCredential
ml_client = MLClient(
DefaultAzureCredential(), subscription_id, resource_group, workspace
)
Examples
View our samples
Troubleshooting
General
Azure ML clients raise exceptions defined in Azure Core.
from azure.core.exceptions import HttpResponseError
try:
ml_client.compute.get("cpu-cluster")
except HttpResponseError as error:
print("Request failed: {}".format(error.message))
Logging
This library uses the standard logging library for logging. Basic information about HTTP sessions (URLs, headers, etc.) is logged at INFO level.
Detailed DEBUG level logging, including request/response bodies and unredacted headers, can be enabled on a client with the logging_enable argument.
See full SDK logging documentation with examples here <https://docs.microsoft.com/azure/developer/python/azure-sdk-logging>.
Telemetry
The Azure ML Python SDK includes a telemetry feature that collects usage and failure data about the SDK and sends it to Microsoft when you use the SDK. Telemetry data helps the SDK team understand how the SDK is used so it can be improved and the information about failures helps the team resolve problems and fix bugs. The SDK telemetry feature is enabled by default. To opt out of the telemetry feature, set the AZUREML_SDKV2_TELEMETRY_OPTOUT environment variable to 1 or true.
Change Log
Initial prerelease
initial prerelease
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
Built Distribution
File details
Details for the file azure_ai_ml-0.1.0b3-py3-none-any.whl
.
File metadata
- Download URL: azure_ai_ml-0.1.0b3-py3-none-any.whl
- Upload date:
- Size: 2.3 MB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.0 CPython/3.8.12
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3e22fb8842117667189e76af11124912ff6e31dfae09f6f1916ed31cafd6844b |
|
MD5 | 324d74f5c8f3c33a481a8093607af4af |
|
BLAKE2b-256 | 5cf90c632893935b470a6934a1fba11854f5e67c047fed4eacb59dfab852eefc |