8 weeksBeginner45 min a dayWeek 1 free

ML foundations in 8 weeks

Start from arrays and finish with a small neural network. One topic a week, mostly Easy problems, about 30 to 45 minutes a day. Good before you start the interview plans.

Start hereCompute every pairwise distance without a Python loop0 of 51 steps done on this device · Week 1 · Problem
Start
Week 1You are here

NumPy foundations

0 of 6 done · 6 problems
  1. ProblemCompute every pairwise distance without a Python loopEasy
  2. ProblemOne-hot encode class labels with fancy indexingEasy
  3. ProblemRank leaderboard scores so ties share a placeEasy
  4. ProblemUndo a length sort with the inverse permutation from argsortEasy
  5. ProblemRemap sparse token ids to a compact vocabulary with np.uniqueEasy
  6. ProblemAverage values per group id with weighted bincountEasy
Week 2

Linear algebra

0 of 6 done · 6 problems
  1. ProblemBuild a cosine similarity matrix for a set of embeddingsEasy
  2. ProblemMeasure how much a rank-k approximation loses with the SVDEasy
  3. ProblemProject vectors onto the span of a few basis vectorsEasy
  4. ProblemCount the numerical rank of a matrix from its singular valuesEasy
  5. ProblemCompute a matrix's 2-norm condition number from its singular valuesEasy
  6. ProblemFind the main direction of your data with PCAMedium
Week 3

Calculus and gradients

0 of 6 done · 6 problems
  1. ProblemCheck a gradient with central differencesEasy
  2. ProblemDifferentiate a quadratic form when the matrix is not symmetricEasy
  3. ProblemDerive the gradient of mean squared error for a linear modelEasy
  4. ProblemBuild a Jacobian with central finite differencesEasy
  5. ProblemClassify a critical point from its HessianEasy
  6. ProblemDerive the gradient of softmax plus cross-entropyMedium
Week 4

Probability and statistics

0 of 6 done · 6 problems
  1. ProblemTrack mean and variance of a stream in one passEasy
  2. ProblemCompute the KL divergence between two diagonal GaussiansEasy
  3. ProblemCompare two token distributions with Jensen-Shannon divergenceEasy
  4. ProblemSample categories from fixed uniforms with the inverse CDFEasy
  5. ProblemCompute the mean and variance of a discrete random variable and of aX + bEasy
  6. ProblemUpdate a discrete posterior over hypotheses after each observationEasy
Week 5

Working with data

0 of 7 done · 7 problems
  1. ProblemStandardise features without leaking test dataEasy
  2. ProblemScale features with the median and IQR so outliers do not dominateEasy
  3. ProblemEncode hour of day and day of week as sine and cosine featuresEasy
  4. ProblemSummarise API calls per model with named groupby aggregationsEasy
  5. ProblemKeep only the latest subscription record per userEasy
  6. ProblemTotal the tokens each model used on successful API callsEasy
  7. ProblemFind users whose total API spend is over a budget with HAVINGEasy
Week 6

Your first models

0 of 6 done · 6 problems
  1. ProblemFit linear regression in one line with the normal equationEasy
  2. ProblemFit a polynomial curve by expanding x into powersEasy
  3. ProblemCompute the elastic net penalty and its gradientEasy
  4. ProblemClassify points by majority vote of their nearest neighboursEasy
  5. ProblemRun one epoch of the perceptron learning ruleEasy
  6. ProblemClassify by the nearest class centroidEasy
Week 7

Judging and grouping

0 of 6 done · 6 problems
  1. ProblemCompute precision, recall and F1 from predictionsEasy
  2. ProblemMeasure how overconfident a classifier is with expected calibration errorEasy
  3. ProblemBuild a confusion matrixEasy
  4. ProblemRun one iteration of k-meansEasy
  5. ProblemPick spread-out starting centroids with farthest-first seedingEasy
  6. ProblemReport the explained variance ratio of PCAEasy
Week 8

A small neural network

0 of 8 done · 7 problems
  1. ProblemImplement GELU, the activation inside GPT and BERTEasy
  2. ProblemCompute softplus without overflowing on large inputsEasy
  3. ProblemBinary cross-entropy straight from logitsEasy
  4. ProblemCross-entropy with label smoothing from raw logitsEasy
  5. ProblemBackward pass of a dense layerEasy
  6. ProblemCompute Xavier and He initialisation scales for dense and conv weightsEasy
  7. ProblemCount the parameters of an MLPEasy
  8. MockTimed mock: ML Engineer

Progress is saved in this browser. Solved problems, lessons you marked done and mocks you took tick themselves; tick anything else by hand.

Other plans: AI Engineer in 4 weeks, ML Engineer in 6 weeks, LLM internals in 3 weeks, Interview sprint in 2 weeks, ML and LLM engineer in 4 weeks.