Interactive engineering utilities

LLM inference calculators and tools

Back-of-the-envelope capacity, roofline latency, token-cost, and launch-configuration calculators built with explicit formulas so you can verify every assumption before renting GPUs.

Recommended capacity-planning workflow

  1. Check model support. Look up your checkpoint and quantization format in the model compatibility directory.
  2. Budget VRAM and concurrency. Compute resident weights and KV-cache tensors in the GPU memory calculator to pick single-GPU vs. tensor-parallel hardware.
  3. Predict TTFT and TPOT regimes. Use the roofline calculator to see whether your batch size is memory-bandwidth-bound or compute-bound.
  4. Price usable goodput and launch. Check break-even utilization in the cost calculator, generate a pinned server command in the command builder, and benchmark with percentile latency metrics.

Frequently asked questions

How accurate are these back-of-the-envelope inference calculators?

They use exact parameter byte sizes, KV-cache tensor formulas, vendor datasheet Tensor Core FLOPs, and GPU memory bandwidths. Real throughput and VRAM usage also include framework buffers, CUDA graph capture memory, paged block fragmentation, and request scheduling overhead, so verify final figures by benchmarking your pinned container.

What should I set for additional memory allowance?

Leave 1.5 to 4 GiB per GPU for PyTorch runtime state, CUDA graphs, temporary prefill activations, and quantization metadata. Long contexts or high chunked-prefill token budgets need more activation headroom.

Why does single-request decode run memory-bandwidth-bound on an H100?

Generating one token at batch size 1 performs roughly 2 FLOPs per parameter while reading all resident weights from HBM, yielding an arithmetic intensity near 1 to 2 FLOPs per byte. An H100 BF16 Tensor Core reaches peak compute only near 295 FLOPs per byte, so decode waits on memory bandwidth until batching amortizes weight reads.

When does self-hosting GPUs become cheaper than a token API?

Self-hosting beats per-token APIs when sustained 24/7 traffic keeps your fleet above the break-even utilization threshold. Spiky or low-volume workloads often cost less per million tokens on a metered API because idle GPU hours stay expensive.