Chapter 2 · Machine learning basics
Training vs inference
Training is learning the parameters (slow, once); inference is using them to answer (fast, every time).
Chapter 2 · Machine learning basics
Training is learning the parameters (slow, once); inference is using them to answer (fast, every time).
Training is the workshop: slow, heavy and done once. Inference is the conveyor belt: the finished machine answers one item at a time, quickly.
The model sees many examples and takes many small steps, adjusting its parameters to lower the loss. This is the slow, costly part.
In train mode, add training rounds and watch the line and loss improve. Switch to use mode to ask the frozen model questions.
Knobs are changing: slope 0, intercept 0. It is still learning. Add more rounds.
Bars use a log scale so the tiny one stays visible. Teaching version: step counts are rough estimates, not timings.
When you chat with a trained AI, which phase is running?
Do the model's parameters change during inference?
Which costs more work overall?