Skip to content

Commit 5e58a70

Browse files
committed
fix colab issue
1 parent 0c27214 commit 5e58a70

File tree

1 file changed

+29
-30
lines changed

1 file changed

+29
-30
lines changed

tutorial_deep_learning_basics/deep_learning_basics.ipynb

Lines changed: 29 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
"cell_type": "markdown",
1212
"metadata": {
1313
"colab_type": "text",
14-
"id": "S5Uhzt6vVIB2"
14+
"id": ""
1515
},
1616
"source": [
1717
"<table align=\"center\">\n",
@@ -33,7 +33,7 @@
3333
"cell_type": "markdown",
3434
"metadata": {
3535
"colab_type": "text",
36-
"id": "FbVhjPpzn6BM"
36+
"id": ""
3737
},
3838
"source": [
3939
"# Deep Learning Basics\n",
@@ -80,7 +80,7 @@
8080
"metadata": {
8181
"colab": {},
8282
"colab_type": "code",
83-
"id": "dzLKpmZICaWN"
83+
"id": ""
8484
},
8585
"outputs": [
8686
{
@@ -149,7 +149,7 @@
149149
"cell_type": "markdown",
150150
"metadata": {
151151
"colab_type": "text",
152-
"id": "59veuiEZCaW4"
152+
"id": ""
153153
},
154154
"source": [
155155
"### Build the model\n",
@@ -169,7 +169,7 @@
169169
"metadata": {
170170
"colab": {},
171171
"colab_type": "code",
172-
"id": "Lhan11blCaW7"
172+
"id": ""
173173
},
174174
"outputs": [],
175175
"source": [
@@ -189,7 +189,7 @@
189189
"cell_type": "markdown",
190190
"metadata": {
191191
"colab_type": "text",
192-
"id": "qKF6uW-BCaW-"
192+
"id": ""
193193
},
194194
"source": [
195195
"### Train the model\n",
@@ -209,7 +209,7 @@
209209
"metadata": {
210210
"colab": {},
211211
"colab_type": "code",
212-
"id": "xvwvpA64CaW_"
212+
"id": ""
213213
},
214214
"outputs": [
215215
{
@@ -295,7 +295,7 @@
295295
"cell_type": "markdown",
296296
"metadata": {
297297
"colab_type": "text",
298-
"id": "oEw4bZgGCaXB"
298+
"id": ""
299299
},
300300
"source": [
301301
"Next, compare how the model performs on the test dataset:"
@@ -307,7 +307,7 @@
307307
"metadata": {
308308
"colab": {},
309309
"colab_type": "code",
310-
"id": "VflXLEeECaXC"
310+
"id": ""
311311
},
312312
"outputs": [
313313
{
@@ -330,7 +330,7 @@
330330
"cell_type": "markdown",
331331
"metadata": {
332332
"colab_type": "text",
333-
"id": "yWfgsmVXCaXG"
333+
"id": ""
334334
},
335335
"source": [
336336
"Compare the RMSE measure you get to the [Kaggle leaderboard](https://www.kaggle.com/c/boston-housing/leaderboard). An RMSE of 2.651 puts us in 5th place."
@@ -360,7 +360,7 @@
360360
"cell_type": "markdown",
361361
"metadata": {
362362
"colab_type": "text",
363-
"id": "DLdCchMdCaWQ"
363+
"id": ""
364364
},
365365
"source": [
366366
"The MNIST dataset containss 70,000 grayscale images of handwritten digits at a resolution of 28 by 28 pixels. The task is to take one of these images as input and predict the most likely digit contained in the image (along with a relative confidence in this prediction):\n",
@@ -376,7 +376,7 @@
376376
"metadata": {
377377
"colab": {},
378378
"colab_type": "code",
379-
"id": "7MqDQO0KCaWS"
379+
"id": ""
380380
},
381381
"outputs": [],
382382
"source": [
@@ -391,7 +391,7 @@
391391
"cell_type": "markdown",
392392
"metadata": {
393393
"colab_type": "text",
394-
"id": "Wz7l27Lz9S1P"
394+
"id": ""
395395
},
396396
"source": [
397397
"We scale these values to a range of 0 to 1 before feeding to the neural network model. For this, we divide the values by 255. It's important that the *training set* and the *testing set* are preprocessed in the same way:"
@@ -403,7 +403,7 @@
403403
"metadata": {
404404
"colab": {},
405405
"colab_type": "code",
406-
"id": "bW5WzIPlCaWv"
406+
"id": ""
407407
},
408408
"outputs": [],
409409
"source": [
@@ -420,7 +420,7 @@
420420
"cell_type": "markdown",
421421
"metadata": {
422422
"colab_type": "text",
423-
"id": "Ee638AlnCaWz"
423+
"id": ""
424424
},
425425
"source": [
426426
"Display the first 5 images from the *training set* and display the class name below each image. Verify that the data is in the correct format and we're ready to build and train the network."
@@ -432,7 +432,7 @@
432432
"metadata": {
433433
"colab": {},
434434
"colab_type": "code",
435-
"id": "oZTImqg_CaW1"
435+
"id": ""
436436
},
437437
"outputs": [
438438
{
@@ -461,7 +461,7 @@
461461
"cell_type": "markdown",
462462
"metadata": {
463463
"colab_type": "text",
464-
"id": "59veuiEZCaW4"
464+
"id": ""
465465
},
466466
"source": [
467467
"### Build the model\n",
@@ -475,7 +475,7 @@
475475
"metadata": {
476476
"colab": {},
477477
"colab_type": "code",
478-
"id": "9ODch-OFCaW4"
478+
"id": ""
479479
},
480480
"outputs": [],
481481
"source": [
@@ -502,7 +502,7 @@
502502
"cell_type": "markdown",
503503
"metadata": {
504504
"colab_type": "text",
505-
"id": "gut8A_7rCaW6"
505+
"id": ""
506506
},
507507
"source": [
508508
"Before the model is ready for training, it needs a few more settings. These are added during the model's *compile* step:\n",
@@ -518,7 +518,7 @@
518518
"metadata": {
519519
"colab": {},
520520
"colab_type": "code",
521-
"id": "Lhan11blCaW7"
521+
"id": ""
522522
},
523523
"outputs": [],
524524
"source": [
@@ -531,7 +531,7 @@
531531
"cell_type": "markdown",
532532
"metadata": {
533533
"colab_type": "text",
534-
"id": "qKF6uW-BCaW-"
534+
"id": ""
535535
},
536536
"source": [
537537
"### Train the model\n",
@@ -551,7 +551,7 @@
551551
"metadata": {
552552
"colab": {},
553553
"colab_type": "code",
554-
"id": "xvwvpA64CaW_"
554+
"id": ""
555555
},
556556
"outputs": [
557557
{
@@ -579,7 +579,7 @@
579579
"cell_type": "markdown",
580580
"metadata": {
581581
"colab_type": "text",
582-
"id": "W3ZVOhugCaXA"
582+
"id": ""
583583
},
584584
"source": [
585585
"As the model trains, the loss and accuracy metrics are displayed. This model reaches an accuracy of about 98.68% on the training data."
@@ -589,7 +589,7 @@
589589
"cell_type": "markdown",
590590
"metadata": {
591591
"colab_type": "text",
592-
"id": "oEw4bZgGCaXB"
592+
"id": ""
593593
},
594594
"source": [
595595
"### Evaluate accuracy\n",
@@ -603,7 +603,7 @@
603603
"metadata": {
604604
"colab": {},
605605
"colab_type": "code",
606-
"id": "VflXLEeECaXC"
606+
"id": ""
607607
},
608608
"outputs": [
609609
{
@@ -627,7 +627,7 @@
627627
"cell_type": "markdown",
628628
"metadata": {
629629
"colab_type": "text",
630-
"id": "yWfgsmVXCaXG"
630+
"id": ""
631631
},
632632
"source": [
633633
"Often times, the accuracy on the test dataset is a little less than the accuracy on the training dataset. This gap between training accuracy and test accuracy is an example of *overfitting*. In our case, the accuracy is better at 99.19%! This is, in part, due to successful regularization accomplished with the Dropout layers."
@@ -637,7 +637,7 @@
637637
"cell_type": "markdown",
638638
"metadata": {
639639
"colab_type": "text",
640-
"id": "xsoS7CPDCaXH"
640+
"id": ""
641641
},
642642
"source": [
643643
"### Make predictions\n",
@@ -653,7 +653,7 @@
653653
"metadata": {
654654
"colab": {},
655655
"colab_type": "code",
656-
"id": "Gl91RPhdCaXI"
656+
"id": ""
657657
},
658658
"outputs": [
659659
{
@@ -771,7 +771,7 @@
771771
"cell_type": "markdown",
772772
"metadata": {
773773
"colab_type": "text",
774-
"id": "x9Kk1voUCaXJ"
774+
"id": ""
775775
},
776776
"source": [
777777
"The above shows the prediction of the network by choosing the neuron with the highest output. While the output layer values add 1 to one, these do not reflect well-calibrated measures of \"uncertainty\". Often, the network is overly confident about the top choice that does not reflect a learned measure of probability. If everything ran correctly you should get an animation like this:\n",
@@ -793,7 +793,6 @@
793793
"colab": {
794794
"collapsed_sections": [],
795795
"name": "tutorial_deep_learning_basics.ipynb",
796-
"private_outputs": true,
797796
"provenance": [],
798797
"toc_visible": true,
799798
"version": "0.3.2"

0 commit comments

Comments
 (0)