AI Terms Dictionary

A comprehensive multilingual AI terminology dictionary

Definition

In machine learning, an epoch represents a single iteration over the entire training dataset. During each epoch, the model processes all training examples, updates its weights via backpropagation, and minimizes the loss function. Multiple epochs are typically required for the model to converge to optimal parameters. The number of epochs is a hyperparameter that must be tuned; too few may lead to underfitting, while too many can cause overfitting, where the model memorizes noise rather than learning general patterns.

Summary

One complete pass of the training dataset through the machine learning algorithm during model training.

Key Concepts

Use Cases

Code Example

1
2
3
4
5
6
7
for epoch in range(num_epochs):
    for inputs, labels in dataloader:
        optimizer.zero_grad()
        outputs = model(inputs)
        loss = criterion(outputs, labels)
        loss.backward()
        optimizer.step()