Neural Networks: Zero to Hero

Based on Andrej Karpathy’s course.

A hands-on course that builds neural networks from scratch, one video at a time, from a tiny automatic-differentiation engine up to a GPT. Each module is one lecture; each module has one or more guided coding projects you complete locally in Claude Code with an AI tutor.

Start the track

Work through it locally with your AI tutor. It checks each project against the tests.

Free · no signup to start · you keep the code

Roadmap

Build from micrograd to GPT.

What you’ll learn

Automatic differentiationComputation graphBackpropagationChain ruleReverse-mode autodiffGradientsNeural networksMulti-layer perceptronGradient descentLoss functionsForward and backward passTraining loopLanguage modelingBigramsProbability distributionsPyTorch tensorsBroadcastingSamplingNegative log-likelihoodSmoothingOne-hot encodingLogitsSoftmaxRegularizationPyTorch autogradEmbeddingsHidden layersMLPsCross-entropy lossMinibatch SGDTrain/dev/test splitsOverfittingLearning-rate tuningTensor internalsInitializationTanh saturationDead neuronsVanishing gradientsKaiming initBatchNormRunning statisticsTrain/eval modesTraining diagnosticsThe chain rule at tensor scaleMatmul gradientsBroadcasting in reverseGradient accumulationSoftmax/cross-entropy backwardBatchNorm backwardScatter-addNumerical exactnessManual optimizationModules and containersHierarchical fusionview/reshape semanticsBatchNorm over 3D inputsBroadcasting-hidden bugsShape-driven debuggingContext scalingArchitecture as a scaling betEqual-budget comparisonsNext-token predictionSelf-attentionQueries, keys, and valuesCausal maskingMulti-head attentionResidual connectionsLayerNormPositional embeddingsThe Transformer blockAutoregressive generationUTF-8 and code pointsByte-pair encodingPair statisticsThe merge operationVocabulary mintingMint-order encodingRegex pre-splittingSpecial tokensCompression ratioWhy LLMs can't spellFused multi-head attentionWeight tyingGELU and frozen approximationsResidual-stream init scalingState-dict surgeryCheckpoint fingerprintingTemperature and top-k samplingWarmup-cosine schedulesLM-based eval scoring