Skip to content

update samples from Release-200 as a part of 1.54.0 SDK stable release #1951

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Nov 23, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 1 addition & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
# Azure Machine Learning Python SDK notebooks


** **With the introduction of AzureML SDK v2, this samples repository for the v1 SDK is now deprecated and will not be monitored or updated. Users are encouraged to visit the [v2 SDK samples repository](https://github.com/Azure/azureml-examples) instead for up-to-date and enhanced examples of how to build, train, and deploy machine learning models with AzureML's newest features.** **

### **With the introduction of AzureML SDK v2, this samples repository for the v1 SDK is now deprecated and will not be monitored or updated. Users are encouraged to visit the [v2 SDK samples repository](https://github.com/Azure/azureml-examples) instead for up-to-date and enhanced examples of how to build, train, and deploy machine learning models with AzureML's newest features.**

Welcome to the Azure Machine Learning Python SDK notebooks repository!

Expand Down
2 changes: 1 addition & 1 deletion configuration.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@
"source": [
"import azureml.core\n",
"\n",
"print(\"This notebook was created using version 1.53.0 of the Azure ML SDK\")\n",
"print(\"This notebook was created using version 1.54.0 of the Azure ML SDK\")\n",
"print(\"You are currently using version\", azureml.core.VERSION, \"of the Azure ML SDK\")"
]
},
Expand Down
15 changes: 8 additions & 7 deletions how-to-use-azureml/automated-machine-learning/automl_env.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,21 +7,22 @@ dependencies:
# The python interpreter version.
# Azure ML only supports 3.7.0 and later.
- pip==22.3.1
- python>=3.8,<3.9
- holidays==0.10.3
- pandas==1.3.5
- python>=3.9,<3.10
- holidays==0.29
- scipy==1.10.1
- Cython==0.29.14
- tqdm==4.66.1
# TODO: Remove this requirement when azureml-responsibleai will
# upgrade responsibleai to version to >=0.30.0
- scikit-learn<1.1

- pip:
# Required packages for AzureML execution, history, and data preparation.
- azureml-widgets~=1.53.0
- azureml-defaults~=1.53.0
- -r https://automlsdkdataresources.blob.core.windows.net/validated-requirements/1.53.2/validated_win32_requirements.txt [--no-deps]
- azureml-widgets~=1.54.0
- azureml-defaults~=1.54.0
- -r https://automlsdkdataresources.blob.core.windows.net/validated-requirements/1.54.0/validated_win32_requirements.txt [--no-deps]
- matplotlib==3.7.1
- xgboost==1.3.3
- prophet==1.1.4
- pandas==1.3.5
- cmdstanpy==1.1.0
- setuptools-git==1.2
21 changes: 10 additions & 11 deletions how-to-use-azureml/automated-machine-learning/automl_env_linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,27 +7,26 @@ dependencies:
# The python interpreter version.
# Azure ML only supports 3.7 and later.
- pip==22.3.1
- python>=3.8,<3.9
- python>=3.9,<3.10
- matplotlib==3.7.1
- numpy==1.22.3
- cython==0.29.14
- numpy>=1.21.6,<=1.23.5
- urllib3==1.26.7
- scipy==1.10.1
- scikit-learn==1.1.3
# TODO: Upgrade this requirement to 1.1.3 when azureml-responsibleai will
# upgrade responsibleai to version to >=0.30.0
- scikit-learn<1.1
- py-xgboost<=1.3.3
- holidays==0.10.3
- conda-forge::prophet==1.1.4
- holidays==0.29
- pytorch::pytorch=1.11.0
- cudatoolkit=10.1.243
- notebook
- scikit-learn<1.1

- pip:
# Required packages for AzureML execution, history, and data preparation.
- azureml-widgets~=1.53.0
- azureml-defaults~=1.53.0
- azureml-widgets~=1.54.0
- azureml-defaults~=1.54.0
- pytorch-transformers==1.0.0
- spacy==2.2.4
- pystan==2.19.1.1
- prophet==1.1.4
- https://aka.ms/automl-resources/packages/en_core_web_sm-2.1.0.tar.gz
- -r https://automlsdkdataresources.blob.core.windows.net/validated-requirements/1.53.2/validated_linux_requirements.txt [--no-deps]
- -r https://automlsdkdataresources.blob.core.windows.net/validated-requirements/1.54.0/validated_linux_requirements.txt [--no-deps]
17 changes: 8 additions & 9 deletions how-to-use-azureml/automated-machine-learning/automl_env_mac.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,23 +7,22 @@ dependencies:
# The python interpreter version.
# Currently Azure ML only supports 3.7 and later.
- pip==22.3.1
- python>=3.8,<3.9
- numpy==1.22.3
- cython==0.29.14
- python>=3.9,<3.10
- numpy>=1.21.6,<=1.23.5
- scipy==1.10.1
- scikit-learn==1.1.3
- holidays==0.10.3
# TODO: Upgrade this requirement to 1.1.3 when azureml-responsibleai will
# upgrade responsibleai to version to >=0.30.0
- scikit-learn<1.1
- holidays==0.29

- pip:
# Required packages for AzureML execution, history, and data preparation.
- azureml-widgets~=1.53.0
- azureml-defaults~=1.53.0
- azureml-widgets~=1.54.0
- azureml-defaults~=1.54.0
- pytorch-transformers==1.0.0
- spacy==2.2.4
- pystan==2.19.1.1
- prophet==1.1.4
- xgboost==1.3.3
- matplotlib==3.7.1
- https://aka.ms/automl-resources/packages/en_core_web_sm-2.1.0.tar.gz
- -r https://automlsdkdataresources.blob.core.windows.net/validated-requirements/1.53.2/validated_darwin_requirements.txt [--no-deps]
- -r https://automlsdkdataresources.blob.core.windows.net/validated-requirements/1.54.0/validated_darwin_requirements.txt [--no-deps]
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@
"metadata": {},
"outputs": [],
"source": [
"print(\"This notebook was created using version 1.53.0 of the Azure ML SDK\")\n",
"print(\"This notebook was created using version 1.54.0 of the Azure ML SDK\")\n",
"print(\"You are currently using version\", azureml.core.VERSION, \"of the Azure ML SDK\")"
]
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@
"metadata": {},
"outputs": [],
"source": [
"print(\"This notebook was created using version 1.53.0 of the Azure ML SDK\")\n",
"print(\"This notebook was created using version 1.54.0 of the Azure ML SDK\")\n",
"print(\"You are currently using version\", azureml.core.VERSION, \"of the Azure ML SDK\")"
]
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@
"metadata": {},
"outputs": [],
"source": [
"print(\"This notebook was created using version 1.53.0 of the Azure ML SDK\")\n",
"print(\"This notebook was created using version 1.54.0 of the Azure ML SDK\")\n",
"print(\"You are currently using version\", azureml.core.VERSION, \"of the Azure ML SDK\")"
]
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@
"metadata": {},
"outputs": [],
"source": [
"print(\"This notebook was created using version 1.53.0 of the Azure ML SDK\")\n",
"print(\"This notebook was created using version 1.54.0 of the Azure ML SDK\")\n",
"print(\"You are currently using version\", azureml.core.VERSION, \"of the Azure ML SDK\")"
]
},
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,21 @@
{
"cells": [
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Copyright (c) Microsoft Corporation. All rights reserved.\n",
"\n",
"Licensed under the MIT License."
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"![Impressions](https://PixelServer20190423114238.azurewebsites.net/api/impressions/MachineLearningNotebooks/how-to-use-azureml/automated-machine-learning/forecasting-pipelines/auto-ml-forecasting-pipelines.png)"
]
},
{
"cell_type": "markdown",
"metadata": {},
Expand Down Expand Up @@ -55,7 +71,6 @@
"import logging\n",
"import os\n",
"\n",
"from matplotlib import pyplot as plt\n",
"import pandas as pd\n",
"\n",
"import azureml.core\n",
Expand Down Expand Up @@ -441,8 +456,6 @@
"metadata": {},
"outputs": [],
"source": [
"from azureml.pipeline.core import PipelineData\n",
"\n",
"# The model name with which to register the trained model in the workspace.\n",
"model_name_str = \"ojmodel\"\n",
"model_name = PipelineParameter(\"model_name\", default_value=model_name_str)\n",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,21 @@
{
"cells": [
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Copyright (c) Microsoft Corporation. All rights reserved.\n",
"\n",
"Licensed under the MIT License."
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"![Impressions](https://PixelServer20190423114238.azurewebsites.net/api/impressions/MachineLearningNotebooks/how-to-use-azureml/automated-machine-learning/local-run-classification-credit-card-fraud/auto-ml-classification-credit-card-fraud-local.png)"
]
},
{
"cell_type": "markdown",
"metadata": {},
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,21 @@
{
"cells": [
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Copyright (c) Microsoft Corporation. All rights reserved.\n",
"\n",
"Licensed under the MIT License."
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"![Impressions](https://PixelServer20190423114238.azurewebsites.net/api/impressions/MachineLearningNotebooks/how-to-use-azureml/automated-machine-learning/regression/auto-ml-regression.png)"
]
},
{
"cell_type": "markdown",
"metadata": {},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -260,7 +260,7 @@
"source": [
"from azureml.core.conda_dependencies import CondaDependencies \n",
"\n",
"myenv = CondaDependencies.create(pip_packages=[\"numpy\", \"onnxruntime\", \"azureml-core\", \"azureml-defaults\"])\n",
"myenv = CondaDependencies.create(pip_packages=[\"numpy\", \"onnxruntime==1.15.1\", \"azureml-core\", \"azureml-defaults\"])\n",
"\n",
"with open(\"myenv.yml\",\"w\") as f:\n",
" f.write(myenv.serialize_to_string())"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -334,7 +334,7 @@
"from azureml.core.conda_dependencies import CondaDependencies \n",
"\n",
"\n",
"myenv = CondaDependencies.create(pip_packages=[\"numpy\", \"onnxruntime\", \"azureml-core\", \"azureml-defaults\"])\n",
"myenv = CondaDependencies.create(pip_packages=[\"numpy\", \"onnxruntime==1.15.1\", \"azureml-core\", \"azureml-defaults\"])\n",
"\n",
"with open(\"myenv.yml\",\"w\") as f:\n",
" f.write(myenv.serialize_to_string())"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -319,7 +319,7 @@
"source": [
"from azureml.core.conda_dependencies import CondaDependencies \n",
"\n",
"myenv = CondaDependencies.create(pip_packages=[\"numpy\", \"onnxruntime\", \"azureml-core\", \"azureml-defaults\"])\n",
"myenv = CondaDependencies.create(pip_packages=[\"numpy\", \"onnxruntime==1.15.1\", \"azureml-core\", \"azureml-defaults\"])\n",
"\n",
"with open(\"myenv.yml\",\"w\") as f:\n",
" f.write(myenv.serialize_to_string())"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -242,7 +242,7 @@
"from azureml.core.conda_dependencies import CondaDependencies \n",
"\n",
"\n",
"myenv = CondaDependencies.create(pip_packages=[\"numpy\", \"onnxruntime\", \"azureml-core\", \"azureml-defaults\"])\n",
"myenv = CondaDependencies.create(pip_packages=[\"numpy\", \"onnxruntime==1.15.1\", \"azureml-core\", \"azureml-defaults\"])\n",
"\n",
"with open(\"myenv.yml\",\"w\") as f:\n",
" f.write(myenv.serialize_to_string())"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -416,7 +416,7 @@
"source": [
"from azureml.core.conda_dependencies import CondaDependencies \n",
"\n",
"myenv = CondaDependencies.create(pip_packages=[\"numpy\",\"onnxruntime\",\"azureml-core\", \"azureml-defaults\"])\n",
"myenv = CondaDependencies.create(pip_packages=[\"numpy\",\"onnxruntime==1.15.1\",\"azureml-core\", \"azureml-defaults\"])\n",
"\n",
"with open(\"myenv.yml\",\"w\") as f:\n",
" f.write(myenv.serialize_to_string())"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -282,7 +282,7 @@
"source": [
"### Create an environment\n",
"\n",
"In this tutorial, we will use one of Azure ML's curated PyTorch environments for training. [Curated environments](https://docs.microsoft.com/azure/machine-learning/how-to-use-environments#use-a-curated-environment) are available in your workspace by default. Specifically, we will use the PyTorch 1.6 GPU curated environment."
"In this tutorial, we will use one of Azure ML's curated PyTorch environments for training. [Curated environments](https://docs.microsoft.com/azure/machine-learning/how-to-use-environments#use-a-curated-environment) are available in your workspace by default. Specifically, we will use the PyTorch 2.0 GPU curated environment."
]
},
{
Expand All @@ -293,7 +293,7 @@
"source": [
"from azureml.core import Environment\n",
"\n",
"pytorch_env = Environment.get(ws, name='azureml-acpt-pytorch-1.11-cuda11.3')"
"pytorch_env = Environment.get(ws, name='azureml-acpt-pytorch-1.13-cuda11.7')"
]
},
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@
"\n",
"# Check core SDK version number\n",
"\n",
"print(\"This notebook was created using SDK version 1.53.0, you are currently running version\", azureml.core.VERSION)"
"print(\"This notebook was created using SDK version 1.54.0, you are currently running version\", azureml.core.VERSION)"
]
},
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,9 @@ def convert(imgf, labelf, outf, n):
mounted_output_path = sys.argv[2]
os.makedirs(mounted_output_path, exist_ok=True)

convert(os.path.join(mounted_input_path, 'mnist-fashion/train-images-idx3-ubyte'),
os.path.join(mounted_input_path, 'mnist-fashion/train-labels-idx1-ubyte'),
convert(os.path.join(mounted_input_path, 'train-images-idx3-ubyte'),
os.path.join(mounted_input_path, 'train-labels-idx1-ubyte'),
os.path.join(mounted_output_path, 'mnist_train.csv'), 60000)
convert(os.path.join(mounted_input_path, 'mnist-fashion/t10k-images-idx3-ubyte'),
os.path.join(mounted_input_path, 'mnist-fashion/t10k-labels-idx1-ubyte'),
convert(os.path.join(mounted_input_path, 't10k-images-idx3-ubyte'),
os.path.join(mounted_input_path, 't10k-labels-idx1-ubyte'),
os.path.join(mounted_output_path, 'mnist_test.csv'), 10000)
1 change: 0 additions & 1 deletion index.md
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,6 @@ Machine Learning notebook samples and encourage efficient retrieval of topics an
|:----|:-----|:-------:|:----------------:|:-----------------:|:------------:|:------------:|
| [Deploy MNIST digit recognition with ONNX Runtime](https://github.com/Azure/MachineLearningNotebooks/blob/master//how-to-use-azureml/deployment/onnx/onnx-inference-mnist-deploy.ipynb) | Image Classification | MNIST | Local | Azure Container Instance | ONNX | ONNX Model Zoo |
| [Deploy Facial Expression Recognition (FER+) with ONNX Runtime](https://github.com/Azure/MachineLearningNotebooks/blob/master//how-to-use-azureml/deployment/onnx/onnx-inference-facial-expression-recognition-deploy.ipynb) | Facial Expression Recognition | Emotion FER | Local | Azure Container Instance | ONNX | ONNX Model Zoo |
| :star:[Register model and deploy as webservice](https://github.com/Azure/MachineLearningNotebooks/blob/master//how-to-use-azureml/deployment/deploy-to-cloud/model-register-and-deploy.ipynb) | Deploy a model with Azure Machine Learning | Diabetes | None | Azure Container Instance | Scikit-learn | None |
| [Train MNIST in PyTorch, convert, and deploy with ONNX Runtime](https://github.com/Azure/MachineLearningNotebooks/blob/master//how-to-use-azureml/deployment/onnx/onnx-train-pytorch-aml-deploy-mnist.ipynb) | Image Classification | MNIST | AML Compute | Azure Container Instance | ONNX | ONNX Converter |
| [Deploy ResNet50 with ONNX Runtime](https://github.com/Azure/MachineLearningNotebooks/blob/master//how-to-use-azureml/deployment/onnx/onnx-modelzoo-aml-deploy-resnet50.ipynb) | Image Classification | ImageNet | Local | Azure Container Instance | ONNX | ONNX Model Zoo |
| :star:[Convert and deploy TinyYolo with ONNX Runtime](https://github.com/Azure/MachineLearningNotebooks/blob/master//how-to-use-azureml/deployment/onnx/onnx-convert-aml-deploy-tinyyolo.ipynb) | Object Detection | PASCAL VOC | local | Azure Container Instance | ONNX | ONNX Converter |
Expand Down
2 changes: 1 addition & 1 deletion setup-environment/configuration.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@
"source": [
"import azureml.core\n",
"\n",
"print(\"This notebook was created using version 1.53.0 of the Azure ML SDK\")\n",
"print(\"This notebook was created using version 1.54.0 of the Azure ML SDK\")\n",
"print(\"You are currently using version\", azureml.core.VERSION, \"of the Azure ML SDK\")"
]
},
Expand Down