Back to Learning

AI Next Labs / Learning

Foundations: where memory and compute go in LLM training

Transformer shapes, the 16 bytes per parameter, activation memory, FLOPs, gradient accumulation and recomputation, with step-through diagrams.

Published

Written by Jaydeep Raijada.

Every parallelism strategy exists because something doesn't fit on one GPU or doesn't run fast enough there. This lesson builds the mental model they all rely on: what a transformer computes, what has to be kept in memory while it trains, and how much of each there is.

Part 0 of 8 in the 5D Parallelism series. Previous: Overview. Next: Data parallelism.

Work through the interactive lesson below: step through each diagram, try the controls, and check yourself with the questions at the end.

References