Practice Labs: Math for ML (MML Book)ΒΆ
Source PDF: Mathematics for Machine Learning Book: Mathematics for Machine Learning by Marc Peter Deisenroth, A. Aldo Faisal, Cheng Soon Ong (Cambridge University Press, 2020)
This book covers the mathematical foundations that underpin machine learning: linear algebra, calculus, probability, optimization, and four central ML algorithms (regression, PCA, GMM, SVM).
LabsΒΆ
Lab |
Topic |
Book Chapter |
Key Concepts |
|---|---|---|---|
Linear Algebra |
Ch 2 |
Systems of equations, Gaussian elimination, vector spaces, basis, rank, linear mappings |
|
Analytic Geometry |
Ch 3 |
Norms, inner products, Gram-Schmidt, orthogonal projections, rotations |
|
Matrix Decompositions |
Ch 4 |
Eigenvalues, Cholesky, SVD, low-rank approximation |
|
Vector Calculus |
Ch 5 |
Gradients, Jacobians, backpropagation, Hessians, Taylor series |
|
Probability & Distributions |
Ch 6 |
Bayesβ theorem, Gaussian, exponential family, conjugacy |
|
Continuous Optimization |
Ch 7 |
Gradient descent, momentum, Lagrange multipliers, Newtonβs method, convexity |
|
Linear Regression |
Ch 8-9 |
MLE, Bayesian regression, overfitting, cross-validation |
|
PCA |
Ch 10 |
Maximum variance, projection, scree plot, high-dimensional PCA |
|
Gaussian Mixture Models |
Ch 11 |
GMM, EM algorithm, K-Means, model selection |
|
Support Vector Machines |
Ch 12 |
Margin maximization, hinge loss, kernels, soft margin |
How to UseΒΆ
Each lab is a Jupyter notebook with theory (markdown) and fully implemented code cells
Read the theory cells, study the implementations, and run each cell
Open in Jupyter:
jupyter notebook lab_01_linear_algebra.ipynb
PrerequisitesΒΆ
Python 3.8+
NumPy
Matplotlib
Suggested OrderΒΆ
The book has two parts. Follow Part I (math foundations) first, then Part II (ML applications):
Part I: Mathematical Foundations
Lab 01 - Linear Algebra (the language of ML)
Lab 02 - Analytic Geometry (geometry of data)
Lab 03 - Matrix Decompositions (factoring matrices)
Lab 04 - Vector Calculus (training and optimization)
Lab 05 - Probability & Distributions (uncertainty)
Lab 06 - Optimization (finding best parameters)
Part II: Central ML Problems 7. Lab 07 - Linear Regression (prediction) 8. Lab 08 - PCA (dimensionality reduction) 9. Lab 09 - Gaussian Mixtures (density estimation) 10. Lab 10 - SVM (classification)