MST0052 · Lecture 2 · Extra
Colour says when a layer is worth learning, not how important it is. We take them from the bottom up.
If nobody tells you otherwise, assume Ubuntu. It is what wsl --install gives you, what most cloud images boot, and what the tutorial you are reading was written against.
wsl --install
The window that draws the text. Ghostty and WezTerm are the current favourites; iTerm2 on macOS, Windows Terminal on Windows.
The program reading what you type. bash is what scripts assume, zsh is the macOS default, fish is friendlier but not POSIX.
bash
zsh
fish
ls, grep, ssh are separate programs, identical in every window and every shell. These are what you actually learn.
ls
grep
ssh
Small programs, one job each, composed with | — the design that outlived every GUI built to replace it. Worth learning early: tab completion, Ctrl-R to search your history, and tmux so a remote training run survives your laptop closing.
|
Ctrl-R
tmux
WSL 2 · one-time setup, then you are on Linux
git — every change has an author, a message and a way back. Commit code and configuration. Never commit data, and never commit keys.
git
python -m venv .venv and a requirements.txt. Another machine has to be able to rebuild yours from the file alone.
python -m venv .venv
requirements.txt
docker build -t churn . then docker run --rm churn. Underneath, every managed cloud training and serving service runs your code exactly like this.
docker build -t churn .
docker run --rm churn
A Linux VM by the hour. A GPU box for training. Spot instances cheaper, if your job can survive being interrupted.
A bucket — S3, GCS, Azure Blob. Cheap and effectively unlimited, but not a filesystem: you get and put whole objects.
get
put
Someone else operates the training job, the endpoint, the database. Dearer per hour, far cheaper in your time.
The bill is what people actually get wrong. A GPU instance runs roughly $1–4 an hour depending on provider — a forgotten one is a four-figure bill by the end of the month. Set a budget alert on day one, and stop instances you are not using.
Warehouses you will hear named: BigQuery, Snowflake, Databricks, Postgres. On disk expect parquet rather than CSV — columnar, typed, compressed, often several times smaller. pandas.read_sql and pandas.read_parquet are the bridges back to this course.
pandas.read_sql
pandas.read_parquet
What some other system sends
Your side, answering
Start it with uvicorn app:app. That is the whole difference between a model you have and a model other people can use.
uvicorn app:app
Run it as python train.py --data churn.csv --model rf --seed 7 — and that line goes straight into the methods section of your report. Same shape as git commit -m, docker run --rm, aws s3 cp: a verb, then flags. Learn to read one and you can read all of them.
python train.py --data churn.csv --model rf --seed 7
git commit -m
docker run --rm
aws s3 cp
MLflow, Weights & Biases — which run produced that number, and with what settings?
Airflow, Prefect, dbt — something has to run the pipeline at 04:00 every morning.
The world keeps changing; your training data does not. Accuracy decays quietly.
GitHub Actions — tests and checks run on every commit, not when someone remembers.
Which version is live, who approved it, and how do you roll it back?
How containers get scheduled across machines. Almost certainly someone else's job.
Only one of these is a statistics problem — and drift is the one most likely to bite a model you built yourself.
The terminal · virtual environments · git · your pipeline as a script
SQL · Docker · one cloud, any cloud · calling and serving an API
Orchestration · model registries · Kubernetes
Setup instructions for all four are on the Tools page of the course site.