Estimating VRAM and Budget for Local Deployment of MoE Large Models
A practical guide to estimating VRAM, memory bandwidth, and budget for locally deploying a trillion-parameter MoE model, covering three performance tiers from basic feasibility to multi-user serving.
Define the Target Before Calculating the Budget
Most disputes over local deployment costs stem from unclear goals. For the same model, the hardware required to “just run it” versus “serve multiple users stably at low latency” can differ by an order of magnitude. Before estimating costs, performance targets should be written down as verifiable metrics.
This article uses a model with roughly 2.8 trillion total parameters based on a sparse Mixture-of-Experts (MoE) architecture as an example. The figures are estimated from publicly available architectural information and general calculation methods, not official data. Once model weights and official benchmarks are published, each item must be verified through actual testing.
Real-world requirements typically fall into three tiers:
- Just needs to run. For functional validation, offline batch processing, or small-scale trials. As long as VRAM plus host memory can hold the weights, and a few tokens per second of output speed is acceptable, this is the cheapest option.
- Single user at about 25 tokens/s. This is the common experience threshold for interactive chat, requiring sufficient effective memory bandwidth during the decoding phase.
- 10 concurrent users, each still above 25 tokens/s, at no lower than 8-bit floating point precision. This is the target for production serving. The system needs a total throughput of about 250 tokens/s, plus context caches reserved for each concurrent request.
How to Calculate the VRAM Lower Bound
The first hurdle is whether the weights fit entirely into storage. The formula is:
Weight storage = Total parameters × effective bit width ÷ 8
The effective bit width must account for scaling factors. For 4-bit weights, if every 32 elements share one 8-bit scaling factor, the effective bit width is 4 + 8/32 = 4.25 bits. Plugging in 2.8 trillion parameters:
2.8×10¹² × 4.25 ÷ 8 ≈ 1487.5 GB
With 8-bit floating point, where every 128 elements share one 8-bit scaling factor, the effective bit width is about 8.06 bits, and the weights come to roughly 2822 GB.
Total VRAM requirements must also include the KV cache, workspace, and alignment overhead:
Total VRAM ≈ (weights + KV cache) × (1 + workspace and alignment overhead ratio)
An overhead ratio of 10% to 15% is reasonable for initial planning; final figures should be confirmed through testing.
The KV cache is calculated as:
KV cache = 2 × number of layers × KV heads × head dimension × context length × concurrency × bytes per element
Using a set of assumed parameters as an example: 60 layers, 8 KV heads, head dimension 128, BF16 (2 bytes per element), 32768-token context, and 10 concurrent requests, the result is about 80.5 GB. The actual layer count and head configuration must follow the official architecture information. Models using linear attention or hybrid attention typically grow their cache more slowly, but still need to be measured against the actual architecture.
One more point worth noting: an 8-GPU server with 80 GB per card has 640 GB of VRAM in total. Even 4-bit weights at the 1487.5 GB lower bound won’t fit, so you must span multiple servers or leverage host memory.
How MoE Architecture Affects VRAM and Bandwidth
MoE deployment requires distinguishing two things: storage footprint and compute consumption.
- Storage is sized by total parameters. The router cannot know in advance which experts the next token will select, so all experts must be loaded into storage.
- Compute is sized by active parameters. Each token only passes through a small number of selected experts, so compute requirements are far lower than a dense model of the same total parameter count.
“A low activation ratio” does not mean “a low hardware barrier.” This is where many early estimates go wrong.
Single-user decoding speed is limited by memory bandwidth and can be estimated with a rough upper bound:
Decoding speed upper bound ≈ effective memory bandwidth ÷ weight bytes actually read per token
The bytes actually read per token should be calculated using active parameters, not total parameters. Assuming 50B active parameters with 4-bit quantization, each token reads about 50×10⁹ × 4.25 ÷ 8 ≈ 26.6 GB. To reach 25 tokens/s, you would theoretically need about 25 × 26.6 ≈ 665 GB/s of effective bandwidth. Considering non-contiguous memory access from expert routing, communication overhead, and kernel synchronization, real-world efficiency may be only about half that—in other words, roughly 1.3 TB/s. The 50B figure here is an example assumption; replace it with the officially published active parameter count for formal estimates.
Hardware and Budget for the Three Tiers
The table below is estimated using the formulas above. GPU counts assume 80 GB per card and include a 10% overhead margin.
| Target | Precision | VRAM + memory lower bound | Estimated GPUs (80 GB each) |
|---|---|---|---|
| Just needs to run | 4-bit | About 1.65 TB (1487.5 GB weights plus a small KV cache) | Can span VRAM and host memory; doesn’t need to fit entirely in VRAM |
| Single user at 25 tokens/s | 4-bit | About 1.65 TB, plus bandwidth requirements | At least 21, 24 recommended |
| 10 concurrent at 25 tokens/s | 8-bit | About 3.2 TB (2822 GB weights plus 80.5 GB KV cache) | At least 40 with tight margins; 48+ recommended |
The GPU count for the third tier grows with context length. Doubling the context roughly doubles the KV cache.
Budgets should be broken down along the following lines rather than focusing only on GPU prices:
Total budget = GPU count × unit GPU price + servers and racks + network switching + power, cooling, and facility upgrades + operations and spares over a fixed period
This article does not quote specific prices. During procurement, fill in each item with actual quotes. In terms of GPU count, the third tier is roughly twice the second tier, so the GPU portion of the third tier’s cost is usually close to double as well.
Two Routes: SuperNodes and CPU-GPU Heterogeneous Deployment
Partial official deployment
