You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: articles/machine-learning/service/how-to-train-sklearn.md
+9-14Lines changed: 9 additions & 14 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -34,7 +34,7 @@ Run this code on either of these environments:
34
34
-[Create a workspace configuration file](setup-create-workspace.md#write-a-configuration-file)
35
35
-[Download the sample script file](https://github.com/Azure/MachineLearningNotebooks/tree/master/how-to-use-azureml/training/train-hyperparameter-tune-deploy-with-sklearn)`train_iris.py`
36
36
37
-
You can also find a completed [Jupyter Notebook version](https://github.com/Azure/MachineLearningNotebooks/blob/master/how-to-use-azureml/training/train-hyperparameter-tune-deploy-with-keras/train-hyperparameter-tune-deploy-with-sklearn.ipynb) of this guide on the GitHub samples page. The notebook includes expanded sections covering intelligent hyperparameter tuning, model deployment, and notebook widgets.
37
+
You can also find a completed [Jupyter Notebook version](https://github.com/Azure/MachineLearningNotebooks/blob/master/how-to-use-azureml/training/train-hyperparameter-tune-deploy-with-keras/train-hyperparameter-tune-deploy-with-sklearn.ipynb) of this guide on the GitHub samples page. The notebook includes an expanded section covering intelligent hyperparameter tuning.
38
38
39
39
## Set up the experiment
40
40
@@ -163,25 +163,20 @@ As the Run is executed, it goes through the following stages:
163
163
164
164
-**Post-Processing**: The ./outputs folder of the run is copied over to the run history.
165
165
166
-
## Register or download a model
166
+
## Save and register the model
167
167
168
-
Once you've trained the model, you can register it to your workspace. Model registration lets you store and version your models in your workspace to simplify [model management and deployment](concept-model-management-and-deployment.md).
168
+
Once you've trained the model, you can save and register it to your workspace. Model registration lets you store and version your models in your workspace to simplify [model management and deployment](concept-model-management-and-deployment.md).
169
+
170
+
To save the model, include the following code to your training script, train_iris.py.
169
171
170
-
```Python
171
-
model = run.register_model(model_name='sklearn-iris', model_path='outputs/model')
172
+
```Python
173
+
save model code
172
174
```
173
175
174
-
You can also download a local copy of the model by using the Run object. In the training script `train_iris.py`, a Scikit-learn saver object persists the model to a local folder (local to the compute target). You can use the Run object to download a copy.
0 commit comments