Training loss jumps up and down wildly from step to step instead of falling steadily. Which hyperparameter change is a sensible first step?
- Exam domain
- ML Model and Foundation Model (FM) Development24% of the exam
- Difficulty
- Medium
- In this mock
- 22 questions on this domainPractise this domain
Why the exam asks this
Task 2.2: Train, fine-tune, and customize models for ML and AI solutions.
Objective in the exam guide: Skill 2.2.7: Adjust fundamental hyperparameters (for example, epoch, steps, batch size).
Reading a loss curve and adjusting basic hyperparameters is the most common day-to-day training task.
Why A is the answer
Lower the learning rate, and consider a larger batch size
Erratic loss often means steps are too large or too noisy; a lower learning rate or larger batch smooths training.
Remember: Erratic loss: smaller steps (learning rate) or less noisy steps (batch size).
How it works
The learning rate sets how big each update is. Too large, and the model overshoots, so loss jumps around.
Batch size sets how many examples each update uses. Small batches give noisy updates.
Lowering the learning rate, or raising the batch size, usually smooths training.
Clues in the question
The words that point to the answer, and what each one tells you.
- Jumps up and down wildly
- Unstable updates.
In detail
- Epochs, steps and batch size control how long and how smoothly the model trains.
- Changing one hyperparameter at a time shows which one helped.
Side by side with look-alikes
| Change | Effect on erratic loss |
|---|---|
| Lower learning rate | Smoother |
| Larger batch size | Less noisy |
| Higher learning rate | Worse |
| More epochs | No fix |
Every option, checked
Knowing why each wrong option fails is how you rule it out on exam day.
A. Lower the learning rate, and consider a larger batch sizeRight
Erratic loss: smaller steps (learning rate) or less noisy steps (batch size).
B. Train for far more epochsWrong
More epochs repeat the unstable steps.
C. Remove the validation setWrong
Removing validation hides problems.
D. Increase the learning rateWrongMost tempting
A higher learning rate makes the swings worse.
Why it tempts: A higher rate can speed training when loss falls slowly. But here the steps are already too large.
In practice
- Change one hyperparameter at a time and compare loss curves.
Use case
An illustrative scenario, not a real incident.
Halving the learning rate turns a jagged loss curve into a steady decline.
See how it works
xychart-beta x-axis ["1", "2", "3", "4", "5", "6", "7"] y-axis "Loss" 0 --> 1.2 line [1.0, 0.6, 0.95, 0.5, 0.9, 0.55, 0.85] line [1.0, 0.85, 0.72, 0.62, 0.54, 0.47, 0.42]
How to read this chart
- The jagged line is training with a learning rate that is too high.
- The smooth line is the same model with a lower learning rate.
- Loss now falls steadily instead of swinging.