deepseek-ai · text

deepseek-math-7b-instruct

deepseek-ai/deepseek-math-7b-instruct

deepseek-math-7b-instruct at Q4_K_M is exactly 4,221,964,704 bytes (3.93 GiB / 4.22 GB) — an effective 4.888 bits per weight, not the nominal 4. Its KV cache at 32K is 15.00 GiB.

From the file· summed from 1 file(s)From the file· KV per layer
Parameters
6.9B
Architecture
llama
30 layers
Context
4,096
native (config.json)
License
other

Shipped quantizations

exact bytes, summed from published files
QuantSizeExact bytesEffective bpwTensorsPublisher
Q2_K2.53 GiB2,717,028,7683.146MaziyarPanahi
Q2_K2.53 GiB2,718,422,5923.147QuantFactory
Q2_K2.53 GiB2,718,834,5923.147mradermacher
IQ3_XS2.79 GiB2,994,020,2563.466mradermacher
Q3_K_S2.92 GiB3,136,623,0083.631MaziyarPanahi
Q3_K_S2.92 GiB3,138,016,8323.633QuantFactory
IQ3_S2.92 GiB3,138,428,8323.633mradermacher
Q3_K_S2.92 GiB3,138,428,8323.633mradermacher
IQ3_M3.06 GiB3,290,087,3283.809mradermacher
Q3_K_M3.22 GiB3,459,797,4084.005MaziyarPanahi
Q3_K_M3.22 GiB3,461,191,2324.007QuantFactory
Q3_K_M3.22 GiB3,461,603,2324.007mradermacher
Q3_K_L3.49 GiB3,744,879,0084.335MaziyarPanahi
Q3_K_L3.49 GiB3,746,272,8324.337QuantFactory
Q3_K_L3.49 GiB3,746,684,8324.338mradermacher
IQ4_XS3.56 GiB3,818,774,4324.421mradermacher
Q4_03.73 GiB4,000,060,9924.631QuantFactory
Q4_K_S3.75 GiB4,023,964,0644.659MaziyarPanahi
Q4_K_S3.75 GiB4,025,357,8884.660QuantFactory
Q4_K_S3.75 GiB4,025,769,8884.661mradermacher
Q4_K_M3.93 GiB4,221,964,7044.888MaziyarPanahi
Q4_K_M3.93 GiB4,223,358,5284.889QuantFactory
Q4_K_M3.93 GiB4,223,770,5284.890mradermacher
Q4_14.10 GiB4,405,728,8325.100QuantFactory
Q5_K_S4.48 GiB4,810,002,8485.568MaziyarPanahi
Q5_04.48 GiB4,811,396,6725.570QuantFactory
Q5_K_S4.48 GiB4,811,396,6725.570QuantFactory
Q5_K_S4.48 GiB4,811,808,6725.571mradermacher
Q5_K_M4.59 GiB4,925,034,9125.702MaziyarPanahi
Q5_K_M4.59 GiB4,926,428,7365.703QuantFactory
Q5_K_M4.59 GiB4,926,840,7365.704mradermacher
Q5_14.86 GiB5,217,064,5126.040QuantFactory
Q6_K5.28 GiB5,672,047,0086.566MaziyarPanahi
Q6_K5.28 GiB5,673,440,8326.568QuantFactory
Q6_K5.28 GiB5,673,852,8326.569mradermacher
Q8_06.84 GiB7,345,590,6888.504MaziyarPanahi
Q8_06.84 GiB7,346,984,5128.505QuantFactory
Q8_06.84 GiB7,347,396,5128.506mradermacher

KV cache by context

computed per layer
ContextKV cache (f16)Flat formulaOverstated byFull / windowed / recurrent
4,0961.88 GiB1.88 GiB30 / 0 / 0
8,1923.75 GiB3.75 GiB30 / 0 / 0
16,3847.50 GiB7.50 GiB30 / 0 / 0
32,76815.00 GiB15.00 GiB30 / 0 / 0
65,53630.00 GiB30.00 GiB30 / 0 / 0
131,07260.00 GiB60.00 GiB30 / 0 / 0

Compare with

same modality, comparable size

Will it run on your card?

full quant x context sweep

Why other calculators give a different number

A parameters × bits ÷ 8 estimate puts Q4_K_M at roughly 3.62 GiB. The real file is 3.93 GiB, because a quantization is a mixture and some tensors are always kept at higher precision.

Architecture

from config.json
Layers
30
Attention heads
32
KV heads
32
Head dim
128
Hidden size
4096
Vocab
102,400
Sliding window
none
SWA period
MLA
no
Experts
Experts per token
use_sliding_window

Questions people ask

How much VRAM does deepseek-math-7b-instruct need?
Q4_K_M is exactly 4,221,964,704 bytes (3.93 GiB) in weights. Add the KV cache, which depends on your context length, plus roughly half a gigabyte of runtime overhead.
How large is deepseek-math-7b-instruct's KV cache?
15.00 GiB at 32K context with an f16 cache, computed per layer. Quantizing the cache to q8_0 roughly halves it, which is often the difference between a context length fitting and not.
Which quantization of deepseek-math-7b-instruct should I use?
Q4_K_M is the usual default. Pick the largest quantization that fits your card at the context you actually need — the table above gives exact sizes for every one published.