Skip to content

Curse of Dimensionality

The problem of high-dimensional spaces: the more features there are, the worse intuitive ideas about distance work.

What the Problem Is

Four histograms of the distance distribution at dimensionality 1, 2, 10 and 100: the distribution collapses into a narrow peak
The more dimensions, the smaller the difference between neighbors. The histograms show the distribution of distances between random points. In one-dimensional space the nearest and the farthest point differ greatly, and the distribution is wide. As dimensionality grows, the distances move closer together, and with a hundred features almost every pair of points ends up at roughly the same distance — the very notion of a 'nearest neighbor' loses its meaning.

As dimensionality grows:

  • the volume of the space grows exponentially, and the data in it becomes 'sparse';
  • the distances between random points converge — the 'nearest' neighbor is hardly different from a 'far' one;
  • maintaining the same density of points requires exponentially more data.

Who It Affects

First of all metric methods such as KNN and clustering: they rely on distances, and those lose their meaning.

What People Do

  • reduce dimensionality (with PCA, for example);
  • select features;
  • use models that do not rely on distances.

See Also

← All Terms