APM_51434_EP · Master X-HEC · 2026–27
Introduction to Machine Learning (ML1)
Practical sessions (PC) with the material for each session. One tutorial group, September–December 2026.
Practical sessions
Material for each session, as individual files. If you would like the correction of a TD or a Lab, please ask Paul Mangold.
Linear regression
Least squares, normal equations, convexity and existence of the solution, OLS and GLS, polynomial regression, ridge and lasso regularisation.
- Lab 1, statement (notebook)Download · 32 KB
- Summary sheet (PDF)Download · 996 KB
k-nearest neighbours
Distances and NumPy broadcasting, a k-NN classifier written from scratch, generalisation as a function of k, next-word prediction.
- Lab 2, statement (notebook)Download · 74 KB
- Lab 2, fill-in version (notebook)Download · 91 KB
- Revision sheet (PDF)Download · 996 KB
- Calculation details (PDF)Download · 132 KB
Probability, bias–variance and decision trees
Conditional expectation and the bias–variance decomposition, VC dimension of trees, CART on boolean formulas and on regression data, random forests, the Titanic dataset.
- TD 3, statement (PDF)Download · 196 KB
- Revision sheet: probability, expectation and conditioning (PDF)Download · 195 KB
- Lab 3, statement (notebook)Download · 23 KB
- Lab 3, fill-in version (notebook)Download · 31 KB
Logistic regression
Coming soon.
Regularisation and variable selection
Coming soon.
Cross-validation and model selection
Coming soon.
Metrics and fairness
Coming soon.