Module 1: Mathematical Foundations
1 min read·
What you need first
- Python lists and loops, and school algebra. No earlier module.
- A Google account for Colab. Nothing in this module calls a model or needs a key.
- If you can already write a matrix product, a gradient step and a confidence interval in NumPy, skim the lessons and go to the lab.
What you will build
The start of the kestrel repository: the shared data as kestrel/data.py with its fingerprint tests, the lessons' kestrel/maths/ files, a pinned requirements.txt, the ADR template, and kestrel/baseline_logit.py, logistic regression from scratch checked against scikit-learn.
Lessons
| File | Title | Minutes | Depth |
|---|---|---|---|
01-linear-algebra.md | Lesson 1: Parcels as vectors: the linear algebra of a model | 50 | Essential |
02-calculus-and-optimisation.md | Lesson 2: Walking downhill: gradients and how models learn | 50 | Essential, Optional |
03-probability-and-statistics.md | Lesson 3: How sure are you? Probability for model builders | 55 | Essential, Recommended |
Extras
04-module-lab.md, Lab: The Kestrel repository and a first baseline (50 minutes): the repository in your Drive, the data and its tests, the maths files and the from-scratch baseline.05-incident-file.md, Incident: A squared probability went before a jury (30 minutes): the statistics in R v Clark (Court of Appeal, 2003), replayed on Kestrel's route-days, where counting beats multiplying.