The core of the paper's explanation is that the function mapping hyperparameters to performance has low effective dimensionality. For example, consider performance over two hyperparameters x and y given by f(x,y)=g(x)+h(y)≈g(x), determined almost entirely by x (the figure at the top).
- 9 trials on a grid: a 3×3 grid has only 3 values of x. The remaining 6 trials only change y, which does not matter, and keep testing the same places on g(x).
- 9 random trials: all 9 trials have different values of x, so g(x) is examined at 9 places.
If you knew in advance which hyperparameters matter, you could build a grid that is fine only along those axes. But the paper analyzed the performance function with a Gaussian process and confirmed the following two points (Figure 7).
- Only some hyperparameters matter: even for a neural network with 7 hyperparameters, the effective dimensionality was 1–4 depending on the dataset.
- Which hyperparameters matter differs by dataset: the learning rate mattered on every dataset, but beyond that, on some datasets the time at which the learning rate starts to decay mattered, on others the strength of weight decay (L2 penalty), and on others the number of hidden units.
So it is hard to build in advance a grid that suits every problem, while random search achieves "the same efficiency as searching only the important dimensions" on every problem.
The number of trials needed can be estimated with probability. If the good region occupies a fraction v/V of the volume of the search range, the probability that at least one of T random trials lands in it is (Section 4):
1−(1−Vv)T
If the good region is 1% of the whole, 100 trials land in it with about 63% probability and 300 trials with about 95%. If it is 5% of the whole, 60 trials give about 95%. This probability does not depend on the number of hyperparameters being searched.
As an analogy, when searching for a long, thin treasure buried somewhere in a field, digging on a grid means that rows parallel to the treasure keep missing no matter how much you dig. Digging at scattered spots gives more chances to cross the treasure's row with the same number of holes.