Skip to content

Commit e40f51f

Browse files
authored
docs: Fix a few typos (#94)
There are small typos in: - code/ch01/README.md - code/ch12/optional-streamlined-neuralnet.py - faq/ai-and-ml.md - faq/naive-bayes-vartypes.md - faq/scale-training-test.md Fixes: - Should read `were` rather than `weere`. - Should read `occurrences` rather than `occurences`. - Should read `laborious` rather than `labrorious`. - Should read `initializing` rather than `initalizing`. - Should read `distribution` rather than `distribtion`. - Should read `dataset` rather than `datast`.
1 parent 23853c5 commit e40f51f

5 files changed

+5
-5
lines changed

code/ch01/README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ The version numbers of the major Python packages that were used for writing this
9393

9494
## Python/Jupyter Notebook
9595

96-
Some readers weere wondering about the `.ipynb` of the code files -- these files are IPython notebooks. I chose IPython notebooks over plain Python `.py` scripts, because I think that they are just great for data analysis projects! IPython notebooks allow us to have everything in one place: Our code, the results from executing the code, plots of our data, and documentation that supports the handy Markdown and powerful LaTeX syntax!
96+
Some readers were wondering about the `.ipynb` of the code files -- these files are IPython notebooks. I chose IPython notebooks over plain Python `.py` scripts, because I think that they are just great for data analysis projects! IPython notebooks allow us to have everything in one place: Our code, the results from executing the code, plots of our data, and documentation that supports the handy Markdown and powerful LaTeX syntax!
9797

9898
![](./images/ipynb_ex1.png)
9999

code/ch12/optional-streamlined-neuralnet.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ class NeuralNetMLP(object):
2525
minibatche_size : int (default: 1)
2626
Number of training samples per minibatch.
2727
seed : int (default: None)
28-
Random seed for initalizing weights and shuffling.
28+
Random seed for initializing weights and shuffling.
2929
3030
Attributes
3131
-----------

faq/ai-and-ml.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# How are Artificial Intelligence and Machine Learning related?
22

3-
Artifical Intellicence (AI) started as a subfield of computer science with the focus on solving tasks that humans can but computers can't do (for instance, image recognition). AI can be approached in many ways, for example, writing a computer program that implements a set of rules devised by domain experts. Now, hand-crafting rules can be very labrorious and time consuming.
3+
Artifical Intellicence (AI) started as a subfield of computer science with the focus on solving tasks that humans can but computers can't do (for instance, image recognition). AI can be approached in many ways, for example, writing a computer program that implements a set of rules devised by domain experts. Now, hand-crafting rules can be very laborious and time consuming.
44

55
The field of machine learning -- originally, we can consider it as a subfield of AI -- was concerned with the development of algorithms so that computers can automatically learn (predictive) models from data.
66

faq/naive-bayes-vartypes.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ To come back to the original question, let us consider the multi-variate Bernoul
4242

4343

4444
We use the Bernoulli distribution to compute the likelihood of a binary variable.
45-
For example, we could estimate P(x<sub>k</sub>=1 | &omega;<sub>j</sub>) via MLE as the frequency of occurences in the training set:
45+
For example, we could estimate P(x<sub>k</sub>=1 | &omega;<sub>j</sub>) via MLE as the frequency of occurrences in the training set:
4646
&theta; = P&#770;(x<sub>k</sub>=1 | &omega;<sub>j</sub>) = N<sub>x<sub>k</sub>, &omega;<sub>j</sub></sub> / N<sub> &omega;<sub>j</sub></sub>
4747
which reads "number of training samples in class &omega;<sub>j</sub> that have the property x<sub>k</sub>=1 (N<sub>x<sub>k</sub>, &omega;<sub>j</sub></sub>) divided by by all training samples in &omega;<sub>j</sub></sub> (N<sub> &omega;<sub>j</sub></sub>)." In context of text classification, this is basically the set of documents in class &omega;<sub>j</sub> that contain a particular word divided by all documents in &omega;<sub>j</sub>.
4848
Now, we can compute the likelihood of the binary feature vector **x** given class &omega;<sub>j</sub> as

faq/scale-training-test.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ Now, let's say our model has learned the following hypotheses: It classifies sam
5959
- sample5: 6 cm -> class ?
6060
- sample6: 7 cm -> class ?
6161

62-
If we look at the "unstandardized “length in cm" values in our training datast, it is intuitive to say that all of these samples are likely belonging to class 2. However, if we standardize these by re-computing the *standard deviation* and and *mean* from the new data, we would get similar values as before (i.e., properties of a standard normal distribtion) in the training set and our classifier would (probably incorrectly) assign the “class 2” label to the samples 4 and 5.
62+
If we look at the "unstandardized “length in cm" values in our training dataset, it is intuitive to say that all of these samples are likely belonging to class 2. However, if we standardize these by re-computing the *standard deviation* and and *mean* from the new data, we would get similar values as before (i.e., properties of a standard normal distribution) in the training set and our classifier would (probably incorrectly) assign the “class 2” label to the samples 4 and 5.
6363

6464
- sample5: -1.21 -> class 2
6565
- sample6: 0 -> class 2

0 commit comments

Comments
 (0)