Skip to content

Commit 5889656

Browse files
nvinayvarma189norvig
authored andcommitted
Fixed errors in notebooks (#910)
* corrected cell type * fixed umbrella_prior not defined error * minor changes
1 parent 769fb74 commit 5889656

File tree

3 files changed

+4
-5
lines changed

3 files changed

+4
-5
lines changed

knowledge.ipynb

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1233,10 +1233,8 @@
12331233
]
12341234
},
12351235
{
1236-
"cell_type": "code",
1237-
"execution_count": null,
1236+
"cell_type": "markdown",
12381237
"metadata": {},
1239-
"outputs": [],
12401238
"source": [
12411239
"Lets look at the pseudocode for this algorithm"
12421240
]

learning_apps.ipynb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -93,15 +93,15 @@
9393
"Training images size: (60000, 784)\n",
9494
"Training labels size: (60000,)\n",
9595
"Testing images size: (10000, 784)\n",
96-
"Training labels size: (10000,)\n"
96+
"Testing labels size: (10000,)\n"
9797
]
9898
}
9999
],
100100
"source": [
101101
"print(\"Training images size:\", train_img.shape)\n",
102102
"print(\"Training labels size:\", train_lbl.shape)\n",
103103
"print(\"Testing images size:\", test_img.shape)\n",
104-
"print(\"Training labels size:\", test_lbl.shape)"
104+
"print(\"Testing labels size:\", test_lbl.shape)"
105105
]
106106
},
107107
{

probability.ipynb

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1728,6 +1728,7 @@
17281728
}
17291729
],
17301730
"source": [
1731+
"umbrella_prior = [0.5, 0.5]\n",
17311732
"belief_day_1 = forward(hmm, umbrella_prior, ev=True)\n",
17321733
"print ('The probability of raining on day 1 is {:.2f}'.format(belief_day_1[0]))"
17331734
]

0 commit comments

Comments
 (0)