Free | No tracking | Every fact with a source|German and English

Glossary / Hardware

Offloading – explained simply

Offloading means that parts of a model are stored in normal RAM instead of VRAM, so it can run at all, even if more slowly.

Also: CPU offloading, GPU offloading, n-gpu-layers, num_gpu

If a model does not fit entirely in VRAM, the program can split it up: part stays in VRAM, the rest in RAM. llama.cpp calls this hybrid CPU+GPU computation to partially speed up models that are larger than VRAM. Image programs can also move model parts that are not currently needed into RAM.

Put simply: the workbench (VRAM) is too small, so part of the tool is on the shelf (RAM). Every time you need it, you have to walk over there. That is why speed often drops noticeably as soon as even a small part is offloaded.

In Ollama, the ollama ps command shows you in the PROCESSOR column how the model is split up, for example 100% GPU or 48%/52% CPU/GPU.

What does that mean for you? If a language model suddenly responds very slowly, check with ollama ps whether it has been partially offloaded, and otherwise choose a smaller quantization or context length.

Related terms

Errors where that matters

Sources