Skip to content

Commit 9a43384

Browse files
committed
update samples from Release-134 as a part of SDK release
1 parent 6c6227c commit 9a43384

File tree

10 files changed

+67
-20
lines changed

10 files changed

+67
-20
lines changed

configuration.ipynb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@
103103
"source": [
104104
"import azureml.core\n",
105105
"\n",
106-
"print(\"This notebook was created using version 1.40.0 of the Azure ML SDK\")\n",
106+
"print(\"This notebook was created using version Latest of the Azure ML SDK\")\n",
107107
"print(\"You are currently using version\", azureml.core.VERSION, \"of the Azure ML SDK\")"
108108
]
109109
},

how-to-use-azureml/automated-machine-learning/automl_env.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,10 +21,10 @@ dependencies:
2121

2222
- pip:
2323
# Required packages for AzureML execution, history, and data preparation.
24-
- azureml-widgets~=1.40.0
24+
- azureml-widgets~=Latest
2525
- pytorch-transformers==1.0.0
2626
- spacy==2.2.4
2727
- pystan==2.19.1.1
2828
- https://aka.ms/automl-resources/packages/en_core_web_sm-2.1.0.tar.gz
29-
- -r https://automlsdkdataresources.blob.core.windows.net/validated-requirements/1.40.0/validated_win32_requirements.txt [--no-deps]
29+
- -r https://automlsdkdataresources.blob.core.windows.net/validated-requirements/Latest/validated_win32_requirements.txt [--no-deps]
3030
- arch==4.14

how-to-use-azureml/automated-machine-learning/automl_env_linux.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,10 +24,10 @@ dependencies:
2424

2525
- pip:
2626
# Required packages for AzureML execution, history, and data preparation.
27-
- azureml-widgets~=1.40.0
27+
- azureml-widgets~=Latest
2828
- pytorch-transformers==1.0.0
2929
- spacy==2.2.4
3030
- pystan==2.19.1.1
3131
- https://aka.ms/automl-resources/packages/en_core_web_sm-2.1.0.tar.gz
32-
- -r https://automlsdkdataresources.blob.core.windows.net/validated-requirements/1.40.0/validated_linux_requirements.txt [--no-deps]
32+
- -r https://automlsdkdataresources.blob.core.windows.net/validated-requirements/Latest/validated_linux_requirements.txt [--no-deps]
3333
- arch==4.14

how-to-use-azureml/automated-machine-learning/automl_env_mac.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,10 +25,10 @@ dependencies:
2525

2626
- pip:
2727
# Required packages for AzureML execution, history, and data preparation.
28-
- azureml-widgets~=1.40.0
28+
- azureml-widgets~=Latest
2929
- pytorch-transformers==1.0.0
3030
- spacy==2.2.4
3131
- pystan==2.19.1.1
3232
- https://aka.ms/automl-resources/packages/en_core_web_sm-2.1.0.tar.gz
33-
- -r https://automlsdkdataresources.blob.core.windows.net/validated-requirements/1.40.0/validated_darwin_requirements.txt [--no-deps]
33+
- -r https://automlsdkdataresources.blob.core.windows.net/validated-requirements/Latest/validated_darwin_requirements.txt [--no-deps]
3434
- arch==4.14

how-to-use-azureml/automated-machine-learning/experimental/classification-credit-card-fraud-local-managed/auto-ml-classification-credit-card-fraud-local-managed.ipynb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@
9292
"metadata": {},
9393
"outputs": [],
9494
"source": [
95-
"print(\"This notebook was created using version 1.40.0 of the Azure ML SDK\")\n",
95+
"print(\"This notebook was created using version Latest of the Azure ML SDK\")\n",
9696
"print(\"You are currently using version\", azureml.core.VERSION, \"of the Azure ML SDK\")"
9797
]
9898
},

how-to-use-azureml/automated-machine-learning/experimental/regression-model-proxy/auto-ml-regression-model-proxy.ipynb

Lines changed: 18 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,6 @@
7575
"from azureml.core.experiment import Experiment\n",
7676
"from azureml.core.workspace import Workspace\n",
7777
"from azureml.core.dataset import Dataset\n",
78-
"from azureml.data.dataset_factory import TabularDatasetFactory\n",
7978
"from azureml.train.automl import AutoMLConfig"
8079
]
8180
},
@@ -92,7 +91,7 @@
9291
"metadata": {},
9392
"outputs": [],
9493
"source": [
95-
"print(\"This notebook was created using version 1.40.0 of the Azure ML SDK\")\n",
94+
"print(\"This notebook was created using version Latest of the Azure ML SDK\")\n",
9695
"print(\"You are currently using version\", azureml.core.VERSION, \"of the Azure ML SDK\")"
9796
]
9897
},
@@ -197,10 +196,10 @@
197196
"source": [
198197
"ds = ws.get_default_datastore()\n",
199198
"\n",
200-
"train_data = TabularDatasetFactory.register_pandas_dataframe(\n",
199+
"train_data = Dataset.Tabular.register_pandas_dataframe(\n",
201200
" train_data.to_pandas_dataframe(), target=(ds, \"machineTrainData\"), name=\"train_data\")\n",
202201
"\n",
203-
"test_data = TabularDatasetFactory.register_pandas_dataframe(\n",
202+
"test_data = Dataset.Tabular.register_pandas_dataframe(\n",
204203
" test_data.to_pandas_dataframe(), target=(ds, \"machineTestData\"), name=\"test_data\")"
205204
]
206205
},
@@ -328,7 +327,8 @@
328327
"metadata": {},
329328
"source": [
330329
"#### Show hyperparameters\n",
331-
"Show the model pipeline used for the best run with its hyperparameters."
330+
"Show the model pipeline used for the best run with its hyperparameters.\n",
331+
"For ensemble pipelines it shows the iterations and algorithms that are ensembled."
332332
]
333333
},
334334
{
@@ -337,8 +337,19 @@
337337
"metadata": {},
338338
"outputs": [],
339339
"source": [
340-
"run_properties = json.loads(best_run.get_details()['properties']['pipeline_script'])\n",
341-
"print(json.dumps(run_properties, indent = 1)) "
340+
"run_properties = best_run.get_details()['properties']\n",
341+
"pipeline_script = json.loads(run_properties['pipeline_script'])\n",
342+
"print(json.dumps(pipeline_script, indent = 1)) \n",
343+
"\n",
344+
"if 'ensembled_iterations' in run_properties:\n",
345+
" print(\"\")\n",
346+
" print(\"Ensembled Iterations\")\n",
347+
" print(run_properties['ensembled_iterations'])\n",
348+
" \n",
349+
"if 'ensembled_algorithms' in run_properties:\n",
350+
" print(\"\")\n",
351+
" print(\"Ensembled Algorithms\")\n",
352+
" print(run_properties['ensembled_algorithms'])"
342353
]
343354
},
344355
{

how-to-use-azureml/explain-model/azure-integration/gpu-explanation/train-explain-model-gpu-tree-explainer.ipynb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@
106106
"metadata": {},
107107
"outputs": [],
108108
"source": [
109-
"print(\"This notebook was created using version 1.40.0 of the Azure ML SDK\")\n",
109+
"print(\"This notebook was created using version Latest of the Azure ML SDK\")\n",
110110
"print(\"You are currently using version\", azureml.core.VERSION, \"of the Azure ML SDK\")"
111111
]
112112
},

how-to-use-azureml/responsible-ai/auto-ml-regression-responsibleai/auto-ml-regression-responsibleai.ipynb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@
9595
"metadata": {},
9696
"outputs": [],
9797
"source": [
98-
"print(\"This notebook was created using version 1.40.0 of the Azure ML SDK\")\n",
98+
"print(\"This notebook was created using version Latest of the Azure ML SDK\")\n",
9999
"print(\"You are currently using version\", azureml.core.VERSION, \"of the Azure ML SDK\")"
100100
]
101101
},

how-to-use-azureml/track-and-monitor-experiments/logging-api/logging-api.ipynb

Lines changed: 38 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@
100100
"\n",
101101
"# Check core SDK version number\n",
102102
"\n",
103-
"print(\"This notebook was created using SDK version 1.40.0, you are currently running version\", azureml.core.VERSION)"
103+
"print(\"This notebook was created using SDK version Latest, you are currently running version\", azureml.core.VERSION)"
104104
]
105105
},
106106
{
@@ -363,6 +363,43 @@
363363
"run.log_image(name='Hyperbolic Tangent', plot=plt)"
364364
]
365365
},
366+
{
367+
"cell_type": "markdown",
368+
"metadata": {},
369+
"source": [
370+
"### Logging for when more Metric Names are required\n",
371+
"\n",
372+
"Limits on logging are internally enforced to ensure a smooth experience, however these can sometimes be limiting, particularly in terms of the limit on metric names.\n",
373+
"\n",
374+
"The \"Logging Vectors\" or \"Logging Tables\" examples previously can be expanded upon to use up to 15 columns to increase this limit, with the information still being presented in Run Details as a chart, and being directly comparable in experiment reports.\n",
375+
"\n",
376+
"**Note:** see [Azure Machine Learning Limits Documentation](https://aka.ms/azure-machine-learning-limits) for more information on service limits.\n",
377+
"**Note:** tables logged into the run are expected to be relatively small. Logging very large tables into Azure ML can result in reduced performance. If you need to store large amounts of data associated with the run, you can write the data to file that will be uploaded."
378+
]
379+
},
380+
{
381+
"cell_type": "code",
382+
"execution_count": null,
383+
"metadata": {},
384+
"outputs": [],
385+
"source": [
386+
"import random\n",
387+
"metricNames = [ \"Accuracy\", \"Precision\", \"Recall\" ]\n",
388+
"columnNames = [ \"expected\", \"actual\", \"calculated\", \"inferred\", \"determined\", \"predicted\", \"forecast\", \"speculated\", \"assumed\", \"required\", \"intended\", \"deduced\", \"theorized\", \"hoped\", \"hypothesized\" ]\n",
389+
"\n",
390+
"for step in range(1000):\n",
391+
" for metricName in metricNames:\n",
392+
"\n",
393+
" metricKeyValueDictionary={}\n",
394+
" for column in columnNames:\n",
395+
" metricKeyValueDictionary[column] = random.randrange(0, step + 1)\n",
396+
"\n",
397+
" run.log_row(\n",
398+
" metricName,\n",
399+
" \"Example row for metric \" + metricName,\n",
400+
" **metricKeyValueDictionary)"
401+
]
402+
},
366403
{
367404
"cell_type": "markdown",
368405
"metadata": {},
@@ -498,7 +535,6 @@
498535
"metadata": {},
499536
"outputs": [],
500537
"source": [
501-
"import os\n",
502538
"os.makedirs('files', exist_ok=True)\n",
503539
"\n",
504540
"for f in run.get_file_names():\n",

setup-environment/configuration.ipynb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@
102102
"source": [
103103
"import azureml.core\n",
104104
"\n",
105-
"print(\"This notebook was created using version 1.40.0 of the Azure ML SDK\")\n",
105+
"print(\"This notebook was created using version Latest of the Azure ML SDK\")\n",
106106
"print(\"You are currently using version\", azureml.core.VERSION, \"of the Azure ML SDK\")"
107107
]
108108
},

0 commit comments

Comments
 (0)