LESSON 30.04 · 6 STAGES · 2 CONTROLS · 2 CHECKSPRO · PREVIEW
Weight-only quantization
Store the weights in 4 bits and watch a decode step read fewer bytes.
Pro lesson. Stage 1 is free to watch. Pro opens all 6 stages, 2 controls and 2 checks, in this lesson and every other.
Go Pro · $8.25/moEXPLAINER · 30.04 · QUANT BAYFP16 · 64 WEIGHTS · 128 B
01
Stage 1 of 6 · FP16 weights
The layer holds 64 FP16 weights of 2 bytes each. Each decode step reads all 128 B from HBM.
Explain it simply
Each square is one weight of a small layer. Each weight takes 2 bytes. To write one token, the GPU reads every weight from its main memory. The teal cells on top are the input for this token.
An 8 by 8 grid of FP16 weights, 128 bytes in HBM. A row of 8 activations sits on top.
Weights are random, not trained.
activations x (FP16)weights, codes, scales, weight readoutput ŷ, compute timeerror
Toy: one 8 × 8 layer; speed for an 8B model (Llama 3 8B shape) on an H100
MATH · STAGE 1HOVER A SYMBOL OR A SHAPE
The bytes are the weight count times the bits per weight over 8.
PRO LESSON · YOU WATCHED STAGE 1 OF 6
Unlock the full explainer
- 5 more stages and 2 live controls
- 2 mix-up cards and 2 predict-then-reveal checks
- Watch it as a narrated video, in three voices
- Every Pro lesson and capstone · 656 in total
$99 a year, or $15 a month. Cancel any time.