Skip to content

Pruning

Method of model compression: weights or entire neurons that have little impact on the result are removed from the network. Analogous to gardening — trimming the excess.

How it works

  1. Evaluate the importance of each weight (usually by size).
  2. Remove the least significant ones — zero them out or cut them.
  3. Retrain the model slightly if necessary to compensate for the loss.

Types

  • Unstructured pruning — zero out individual weights randomly;
  • Structured pruning — remove entire channels, rows, or neurons. This variant actually speeds up calculations on regular hardware.

Pros and Cons

  • Pros: less memory and computation.
  • Cons: aggressive pruning can degrade model quality, and unstructured pruning does not always provide a real speedup.

See also

← All terms