Mixed precision training is a computational technique that uses both lower-precision (e.g., 16-bit floating-point, FP16 or BF16) and higher-precision (32-bit floating-point, FP32) numerical formats during neural network training to accelerate computation and reduce memory consumption. It leverages specialized hardware like NVIDIA Tensor Cores to perform operations faster on the lower-precision tensors, while maintaining a master copy of weights in FP32 to preserve numerical stability for critical steps like gradient accumulation and weight updates.
Glossary
Mixed Precision Training

What is Mixed Precision Training?
Mixed precision training is a computational technique that uses lower-precision data types for most operations and higher precision for critical parts to accelerate training and reduce memory usage.
The technique employs loss scaling to prevent underflow of small gradient values when using FP16. Gradients computed in FP16 are scaled up before the optimizer step, then unscaled when applied to the FP32 master weights. This approach, central to frameworks like PyTorch's Automatic Mixed Precision (AMP), can double training speed and halve GPU memory usage, enabling the training of larger models or the use of bigger batch sizes without sacrificing final model accuracy.
Key Features and Benefits
Mixed precision training accelerates neural network training by strategically using lower-precision (e.g., FP16, BF16) and higher-precision (FP32) data types for different operations, balancing speed, memory, and numerical stability.
Memory Footprint Reduction
Using 16-bit floating-point (FP16) or Brain Floating Point (BF16) halves the memory required per parameter compared to standard 32-bit (FP32). This enables:
- Training larger models or using larger batch sizes on the same GPU hardware.
- Storing more optimizer states and activations in memory.
- A direct reduction in GPU memory bandwidth pressure, which is often a training bottleneck.
Increased Computational Throughput
Modern AI accelerators like NVIDIA Tensor Cores and Google TPUs are optimized for lower-precision matrix operations. Using FP16/BF16 allows these specialized units to perform many more FLOPS (Floating Point Operations Per Second). This results in:
- Faster forward and backward passes during training.
- Significant reductions in per-iteration training time.
- More efficient utilization of expensive hardware.
Maintained Numerical Stability
A pure lower-precision training can fail due to numerical underflow (values rounding to zero) and overflow (values exceeding range). Mixed precision maintains stability via:
- Master Weights: Keeping a master copy of weights in FP32 for precision.
- Loss Scaling: Automatically scaling the loss value before backward pass to preserve small gradients.
- Precision Casting: Performing sensitive operations (e.g., weight updates, normalization layers) in FP32.
BF16 for Enhanced Stability
BF16 (bfloat16) is an alternative 16-bit format that preserves the same exponent range as FP32 (8 bits) while reducing mantissa bits (7 bits). This design offers a key advantage:
- Greatly reduces the risk of overflow/underflow compared to FP16.
- Often requires less or no loss scaling.
- Becoming the preferred format on hardware that supports it (e.g., TPUs, NVIDIA Ampere+ GPUs).
Synergy with Other Optimizations
Mixed precision training is a foundational technique that combines effectively with other scaling methods:
- Gradient Checkpointing: Saves memory on activations, which are now stored in lower precision.
- Model Parallelism & ZeRO: Further reduces memory footprint when partitioned weights are in lower precision.
- Quantization-Aware Training (QAT): Serves as a precursor for deploying quantized models for inference.
Precision Data Types: Comparison
A comparison of floating-point and integer formats used in mixed precision training, detailing their bit-width, dynamic range, memory footprint, and primary use cases.
| Feature | FP32 (Single) | FP16 (Half) | BF16 (Brain Float) | INT8 |
|---|---|---|---|---|
Full Name | 32-bit Floating Point | 16-bit Floating Point | Brain Floating Point 16 | 8-bit Integer |
Total Bits | 32 | 16 | 16 | 8 |
Sign Bits | 1 | 1 | 1 | 1 |
Exponent Bits | 8 | 5 | 8 | N/A |
Mantissa/Significand Bits | 23 | 10 | 7 | 7 |
Dynamic Range (approx.) | ~1e-38 to ~3e38 | ~5.96e-8 to ~65504 | ~1.18e-38 to ~3.39e38 | -128 to 127 |
Memory per Parameter | 4 bytes | 2 bytes | 2 bytes | 1 byte |
Primary Use in Mixed Precision | Master Weights & Gradients | Forward/Backward Activations | Forward/Backward Activations & Gradients | Quantized Inference / Weights |
Resilience to Underflow | ||||
Hardware Support (Modern GPUs/TPUs) | ||||
Typical Speedup vs. FP32 | 1x (Baseline) | 2-3x | 2-3x |
|
Frequently Asked Questions
Mixed precision training is a computational technique that uses lower-precision data types (like FP16 or BF16) for most operations and higher precision (FP32) for critical parts like weight updates to accelerate training and reduce memory usage.
Mixed precision training is a computational technique that uses lower-precision numerical formats (primarily 16-bit floating-point, or FP16/BF16) for most operations during neural network training, while maintaining higher precision (32-bit floating-point, or FP32) for a small subset of critical operations to preserve numerical stability and model accuracy. This hybrid approach leverages the speed and memory efficiency of lower-precision arithmetic on modern hardware accelerators like GPUs and TPUs, which are optimized for such computations, while using FP32 as a 'master copy' for weights and for operations vulnerable to underflow, such as gradient accumulation and weight updates. The technique is a cornerstone of modern large language model (LLM) training, enabling the training of models that would otherwise exceed available GPU memory.
Enabling Efficiency, Speed & Accuracy
Intelligent Analysis, Decision & Execution
We build AI systems for teams that need search across company data, workflow automation across tools, or AI features inside products and internal software.
Talk to Us
Search across company data
Give teams answers from docs, tickets, runbooks, and product data with sources and permissions.
Useful when people spend too long searching or get different answers from different systems.

Automate internal workflows
Use AI to route work, draft outputs, trigger actions, and keep approvals and logs in place.
Useful when repetitive work moves across multiple tools and teams.

Add AI to products and internal tools
Build assistants, guided actions, or decision support into the software your team or customers already use.
Useful when AI needs to be part of the product, not a separate tool.
Related Terms
Mixed precision training is part of a broader ecosystem of techniques designed to optimize the memory and compute efficiency of large-scale model training. The following terms are foundational to understanding its context and implementation.
Floating-Point Precision (FP16, BF16, FP32)
Floating-point precision defines the format for representing real numbers in computing, balancing range and accuracy. Lower precision types like FP16 (16-bit) and BF16 (bfloat16) use fewer bits, reducing memory footprint and accelerating computation but with a risk of numerical overflow/underflow. FP32 (32-bit single-precision) is the traditional standard, offering greater numerical stability for critical operations like weight updates. Mixed precision training strategically uses both: low precision for most tensor operations and high precision for a master copy of weights and sensitive calculations.
Gradient Checkpointing
Gradient checkpointing is a memory optimization technique that trades compute for memory. During the forward pass, it selectively saves only a subset of layer activations (the checkpoints) instead of all. During the backward pass, it re-computes the unsaved intermediate activations from the nearest checkpoint. This dramatically reduces memory consumption, often by a factor of 4-5x, enabling the training of larger models or longer sequences. It is frequently used in conjunction with mixed precision training to manage total memory overhead.
ZeRO (Zero Redundancy Optimizer)
ZeRO is a family of memory optimization techniques for distributed data-parallel training, implemented in libraries like Microsoft's DeepSpeed. It partitions the three primary model states—optimizer states, gradients, and parameters—across GPUs to eliminate memory redundancy.
- ZeRO Stage 1: Partitions optimizer states.
- ZeRO Stage 2: Partitions gradients as well.
- ZeRO Stage 3: Partitions all model parameters. ZeRO enables the training of models with trillions of parameters. When combined with mixed precision, ZeRO-Offload can further move optimizer states and gradients to CPU memory.
Quantization
Quantization is a model compression technique that reduces the numerical precision of a model's weights and activations, typically from 32-bit floats to 8-bit integers (INT8) or 4-bit integers. Unlike mixed precision training, quantization is primarily used for inference to reduce model size and latency. However, Quantization-Aware Training (QAT) simulates lower precision during training to preserve accuracy. Related techniques like QLoRA combine 4-bit quantization with parameter-efficient fine-tuning, enabling fine-tuning of large models on consumer hardware.
Automatic Mixed Precision (AMP)
Automatic Mixed Precision (AMP) is an implementation tool that automates the application of mixed precision training. Libraries like NVIDIA's Apex (PyTorch) and TensorFlow's native AMP handle:
- Cast selection: Automatically choosing FP16 or FP32 for each operation.
- Loss scaling: Automatically scaling the loss to prevent gradient underflow in FP16.
- Master weight updates: Maintaining a master copy of weights in FP32 for precision. AMP allows developers to implement mixed precision with minimal code changes, abstracting away the manual management of casts and scaling.
Tensor Cores (GPU Hardware)
Tensor Cores are specialized processing units on modern NVIDIA GPUs (Volta architecture and later) designed to perform mixed-precision matrix operations at extremely high throughput. They are optimized for operations like D = A * B + C, where A and B are FP16 matrices, C and D can be FP16 or FP32. This hardware acceleration is the primary driver for the speedups (up to 3x) seen in mixed precision training. Utilizing Tensor Cores requires operations to meet specific size alignment criteria (e.g., matrix dimensions multiples of 8).

About the author
Prasad Kumkar
CEO & MD, Inference Systems
Prasad Kumkar is the CEO & MD of Inference Systems and writes about AI systems architecture, LLM infrastructure, model serving, evaluation, and production deployment. Over 5+ years, he has worked across computer vision models, L5 autonomous vehicle systems, and LLM research, with a focus on taking complex AI ideas into real-world engineering systems.
His work and writing cover AI systems, large language models, AI agents, multimodal systems, autonomous systems, inference optimization, RAG, evaluation, and production AI engineering.
Partnered with leading AI, data, and software stack.
How We Work
Custom AI workflows for your Business
One-fit-all AI don't work for modern businesses. At Inferensys, we aim to understand your business & custom requirements; which we use to define most efficient agentic workflows, the data, and the tools for your business.
01
Review the use case
We understand the task, the users, and where AI can actually help.
Read more02
Pick the right approach
We define what needs search, automation, or product integration.
Read more03
Build the first useful version
We implement the part that proves the value first.
Read more04
Improve from there
We add the checks and visibility needed to keep it useful.
Read moreThe first call is a practical review of your use case and the right next step.
Talk to Us