Search Tools

Compare single-GPU training state and assumed activation memory to estimate microbatch capacity.

An approximation that depends on activation and workspace estimates. It does not guarantee runtime peak VRAM usage.

For example, enter 1,000 for 1 billion parameters. Assumes all parameters are trainable.

Both modes assume FP32 gradients at 4 B/parameter.

Assumes all parameter states reside on the GPU. Temporary update workspace is separate.

Samples processed in one forward/backward pass. This differs from the effective batch size after gradient accumulation.

Estimated incremental memory per sample for the same input length, model, and checkpointing setup. It is not estimated automatically.

Capacity available for computation on one GPU. Advertised GB and GiB are different units.

Memory reserved in advance. Enter 0 only if you have determined that no reserve is needed.

Results

Results update automatically when the required values are entered.

Method, applicability and sources

Calculation method

P=parameter count (millions×10^6); b=microbatch samples per GPU; a=activation memory (MiB/sample); R=reserve for workspace and other overhead (GiB). Weights: 4P bytes for FP32 or (4+2)P bytes for mixed FP16. Gradients: 4P bytes. Optimizer states: 8P for AdamW, 4P for Momentum SGD, or 0 bytes for SGD. Required capacity (GiB)=[weights+gradients+optimizer states+b×a×2^20]÷2^30+R. For GPU capacity V(GiB), maximum microbatch=max(0, floor((V×2^30−fixed state bytes−R×2^30)/(a×2^20))). Display is capped at 100,000 samples. Memory is added directly, assuming activations scale linearly with batch size.

Worked example (hypothetical values)

With 1,000 million parameters, mixed FP16, and AdamW, fixed states occupy 18,000,000,000 bytes (about 16.764 GiB). At 512 MiB per sample, a batch of 2, and a 1 GiB reserve, required VRAM is about 18.764 GiB. A 32 GiB GPU supports an estimated maximum microbatch of 28 samples.

Applicability and limitations

Planning estimate for conventional training with all weights, gradients, and optimizer states held on one GPU. Excludes distributed training, ZeRO/FSDP, quantization, LoRA, partial-parameter training, offloading, automatic prediction of activation savings from gradient checkpointing, guaranteed peak memory, KV caches, inference memory, and GPU pricing.

Method and sources

Method: E085-training-vram-budget-v1.0 (2026-11-13). Data recorded: 2026-11-13.