Training step
A training step is an iteration in which a model is updated during training using data and an optimization objective.
Deep Learning with R, Third Edition
A training step is one iteration that evaluates a model on a batch, computes its loss and gradients, and updates its parameters.
- How it is used
- Updates model weights for one batch and serves as the repeated unit of an epoch.
- How deep it goes
- Works through prediction, loss, gradient, and update code, then extends the procedure to backend-specific custom steps and metric handling.
- Examples
- Uses MNIST batches and a two-dimensional linear classifier, with TensorFlow, PyTorch, and JAX implementations.
- What you can do after
- Build it from scratch for a batch, or apply it through a custom Keras train_step() while retaining fit().
Read how Deep Learning with R, Third Edition explains training step →
Deep Learning with Python, Third Edition
A single update of a model on one batch, consisting of prediction, loss computation, gradient computation, and weight adjustment.
- How it is used
- Defines the per-batch weight update repeated by epochs and customizable within Keras fit().
- How deep it goes
- Works through predictions, loss, automatic gradients, and updates, then implements backend-specific steps; defers manual backpropagation derivatives.
- Examples
- Uses handwritten-digit batches, a JAX linear classifier, and custom Keras train_step() implementations.
- What you can do after
- Build it from scratch as a backend-specific per-batch update, or apply it via a custom Keras train_step() inside fit().
Read how Deep Learning with Python, Third Edition explains training step →
Related concepts
- fit methodused by · A fit method is an operation that learns or estimates model parameters, structure, or transformation statistics from supplied data.
- Keras modelpart of · A Keras model is a trainable object representing a neural-network computation and providing interfaces for training, evaluation, prediction, and saving.
- epochcontrasts with · In machine learning, an epoch is one complete pass through the training data during model training or optimization.
- batch sizeconfigured by · Batch size is the number of items grouped together for processing or computation as a single batch.
- Time-LLMconfigured by · Time-LLM is a language-model-based framework that adapts existing large language models for time-series forecasting.
These guides are generated from the text of Manning books by Manning's knowledge graph and link to the sections they draw on. The full books are available on liveBook and at manning.com.

