File tree Expand file tree Collapse file tree 1 file changed +7
-2
lines changed
advanced_functionality/mxnet_mnist_byom Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change 133
133
"outputs" : [],
134
134
"source" : [
135
135
" from mnist import train\n " ,
136
- " model = train(data = data)"
136
+ " model = train(data = data, num_cpus=0, num_gpus=1 )"
137
137
]
138
138
},
139
139
{
140
140
"cell_type" : " markdown" ,
141
141
"metadata" : {},
142
142
"source" : [
143
+ " If you want to run the training on a cpu or if you are on an instance with cpus only, pass appropriate arguments. \n " ,
144
+ " \n " ,
143
145
" ## Set up hosting for the model\n " ,
144
146
" \n " ,
145
147
" ### Export the model from mxnet\n " ,
228
230
"metadata" : {},
229
231
"outputs" : [],
230
232
"source" : [
233
+ " import logging\n " ,
234
+ " logging.getLogger().setLevel(logging.WARNING)\n " ,
235
+ " \n " ,
231
236
" predictor = sagemaker_model.deploy(initial_instance_count=1,\n " ,
232
237
" instance_type='ml.c4.xlarge')"
233
238
]
304
309
},
305
310
"outputs" : [],
306
311
"source" : [
307
- " # sagemaker.Session().delete_endpoint(predictor.endpoint)"
312
+ " sagemaker.Session().delete_endpoint(predictor.endpoint)"
308
313
]
309
314
},
310
315
{
You can’t perform that action at this time.
0 commit comments