Skip to content

Quantization: How to Run a Large Model on Weak Hardware

Cover: Quantization

Want to run a 70B model but only have 24 GB of VRAM? Quantization comes to the rescue — a way to compress the model so it fits in memory almost without quality loss.

What is Quantization

Usually, model weights are stored in 16-bit precision. Quantization reduces the precision of numbers to 8, 4, or even 2 bits. The numbers become coarser, but the model takes up much less space.

A simple analogy: instead of writing «3.14159265», write «3.14». You lose a bit of precision, but save space.

flowchart LR
    A[Weights FP16<br>14 GB] -->|compression| B[Weights Q4<br>4 GB]
    B --> C[Model fits in<br>less VRAM]

Why It Works

Modern models are huge, but their knowledge is distributed across billions of weights. A slight coarsening of numbers doesn't break this structure — the model continues to understand text, just with numbers that are «rounded».

How Much Can You Gain

Model 16 bits 4 bits
7B ~14 GB ~4 GB
13B ~26 GB ~8 GB
70B ~140 GB ~40 GB

A 70B model quantized to 4 bits already fits on a card with 48 GB — that's the level of one RTX A6000.

Formats and Tools

  • GGUF — format for local launch through Ollama and LM Studio.
  • GPTQ / AWQ — popular quantization methods.
  • QLoRA — fine-tuning on top of a quantized model.

What Is Lost

Quantization is not free. The 2-bit version suffers the most: the model may start getting confused with facts and «drifting» in reasoning. For most tasks, 4-bit quantization is the sweet spot.

Getting Started

  1. Take Ollama.
  2. Launch the model with the desired quantization level.
  3. Compare quality on your tasks.
  4. If it's satisfactory — you're great, you just saved gigabytes.

See Also