Lesson 1.4 · 7 min read · about 50 min to master at a very slow pace

Notation, Probability and Jargon

The maths toolkit: vectors, matrices and index notation, expectation and variance with a worked example, and the ML vocabulary you will meet throughout the course.

Not startedJump to quiz

Notation

SymbolMeaning
, Lower case: vectors (column vectors by default)
, Upper case: matrices
Transpose: the column vector written as a row
Subscript: component of
Training example (an index, not a power)
Partial derivative of the objective with respect to
The gradient: all partial derivatives of collected in a vector

The four tools you need are linear algebra (layers are matrix products), calculus (especially the chain rule, for backpropagation), optimisation (gradient descent) and probability (outputs as probabilities, losses as likelihoods).

Expectation and variance

A discrete random variable has a probability mass function whose probabilities sum to 1; a continuous one has a density, and probabilities are areas under it.

Worked example

is 0 with probability 0.75 and 10 with probability 0.25.

  • Standard deviation , in the same units as .

Vocabulary

TermMeaning
Parametric modelDescribed by a fixed set of parameters, such as or a network's weights
HyperparameterA setting chosen outside gradient-based learning: learning rate, number of layers, width, dropout rate
BiasTwo meanings: the bias term of a neuron, or systematic error (the bias–variance trade-off). A third, social bias, is about unfair outcomes for groups.
OverfittingFitting the training examples, noise included, so closely that new examples are predicted badly
RegularisationAny change to learning meant to improve generalisation rather than training error (Section 9)

Stuck? Common doubts

Questions real learners asked while studying this lesson. They stay closed so they don't spoil your own thinking: open only the ones you need.

First passWhat is the difference between a parameter and a hyperparameter?

Parameters (weights and biases) are learned by gradient descent. Hyperparameters are choices made around that process: the learning rate, how many layers and units, the batch size, the dropout rate. They are chosen using validation data (Section 8), not by gradient descent.

First passWhat is the difference between parametric and non-parametric models?

A parametric model has a fixed shape described by a fixed number of parameters, however much data you have. Linear regression is always : more data improves the s but doesn't add new ones. A neural network is parametric too: its size is fixed by the architecture.

A non-parametric model's complexity grows with the data. K-nearest neighbours keeps every training example and predicts from the closest ones, so the "model" is the dataset itself.

Going deeperDoes non-parametric mean the model has no parameters?

No. It means there is no fixed, finite set of parameters that defines the model. K-nearest neighbours still has settings such as and the distance measure, but those are hyperparameters you choose, not values learned from data. What grows with the data is everything the model must store: all training points.

Cheatsheet

Expectation and variance

; . Std dev .

Index, not power

is training example ; is a square. Write a legend of indices before long derivations.

See every cheatsheet by category →

Check your understanding

Score 75% or more to master this lesson and earn XP. Answer first, then check.

Q1calculate is 0 with probability 0.75 and 10 with probability 0.25. What are and ?
Q2conceptWhich of these is a hyperparameter rather than a parameter?
Q3interpretA lecturer says a model "has high bias". In a discussion of underfitting, what do they mean?
Q4conceptIf is a column vector , what is for ?
Q5conceptWhy is the standard deviation often reported instead of the variance?