Views
No views yet
| Method | GPTQ (Hessian-based error compensation) |
| Scheme | W4A16 (INT4 weights, FP16 activations) |
| Format | pack-quantized (compressed-tensors) |
| Group size | 128 |
| Dampening | 0.01 |
| Act order | static |
| Calibration | 512 samples from ultrachat_200k, 2048 seq len |
| Ignored layers | lm_head, vision/audio embedders |
| Original size | ~24 GB |
| Quantized size | ~9.2 GB |
| Variant | GSM8K (flexible) | GSM8K (strict) | Size | Compression |
|---|---|---|---|---|
| Baseline BF16 | 87.57% | 86.58% | ~24 GB | 1.0x |
| FP8 Dynamic | 87.95% | 86.96% | ~15 GB | 1.6x |
| W8A16 INT8 | 86.96% | 86.13% | ~15 GB | 1.6x |
| W4A16 GPTQ | 85.29% | 84.00% | ~9.2 GB | 2.6x |
1from vllm import LLM, SamplingParams
2
3model = LLM("soyrsoyr/gemma-4-12b-it-W4A16-GPTQ")
4output = model.generate("Hello, world!", SamplingParams(max_tokens=100))1from llmcompressor import oneshot
2from llmcompressor.modifiers.gptq import GPTQModifier
3
4recipe = GPTQModifier(
5 targets="Linear",
6 scheme="W4A16",
7 ignore=["lm_head", "re:.*embed_vision.*", "re:.*embed_audio.*", "re:.*vision_embedder.*"],
8 dampening_frac=0.01,
9 actorder="static",
10 block_size=128,
11)
12oneshot(model=model, dataset=ds, recipe=recipe, max_seq_length=2048, num_calibration_samples=512)