Representation Benefits of Deep Feedforward Networks
Matus Telgarsky
Overview
Let positive integer , number of layers , and number of nodes per layer be given with . Then there exists a collection of points with and such that
For example, approaching the error of the -layer network (which has nodes and weights) with layers requires at least nodes, and with layers needs at least nodes.
The purpose of this note is to provide an elementary proof of Theorem 1.1 and its refinement Theorem 1.2, which amongst other improvements will use a recurrent neural network in the upper bound. Section 2 will present the proof, and Section 3 will tie these results to the literature on neural network expressive power and circuit complexity, which by contrast makes use of product nodes rather than standard feedforward networks when showing the benefits of depth.
There are three refinements to make: the classification problem will be specified, the perfect network will be an even simpler recurrent network, and need not be .
Let -ap (the -alternating-point problem) denote the set of uniformly spaced points within with alternating labels, as depicted in Figure 1; that is, the points with , and when is even, and otherwise . As the values pass from left to right, the labels change as often as possible; the key is that adding a constant number of nodes in a flat network only corrects predictions on a constant number of points, whereas adding a constant number of nodes in a deep network can correct predictions on a constant fraction of the points.
Let denote iterations of a recurrent network with layers of at most nodes each, defined as follows. Every consists of some fixed network applied times:
Consequently, , but the former has parameters whereas the latter has parameters.
This more refined result can thus say, for example, that on the -ap one needs exponentially (in ) many parameters when boosting decision stumps, linearly many parameters with a deep network, and constantly many parameters with a recurrent network.
Analysis
This section will first prove the lower bound via a counting argument, simply tracking the number of times a function within can cross 1/2. The upper bound will exhibit a network in which can be composed with itself times to exactly fit the -ap. These bounds together prove Theorem 1.2, which in turn implies Theorem 1.1.
The lower bound is proved in two stages. First, composing and summing sawtooth functions must also yield a sawtooth function, thus elements of are sawtooth whenever is. Secondly, a sawtooth function can not cross very often, meaning it can’t hope to match the quickly changing labels of the -ap.
To start, is sawtooth as follows.
The proof is straightforward and deferred momentarily. The key observation is that adding together sawtooth functions grows the number of regions very slowly, whereas composition grows the number very quickly, an early sign of the benefits of depth.
Given a sawtooth function, its classification error on the -ap may be lower bounded as follows.
To close, the proof of Section 2.1 proceeds as follows. First note how adding and composing sawtooths grows their complexity.
First consider , and moreover any intervals and . Necessarily, has a single slope along . Consequently, is -sawtooth, where is the set of all intersections of intervals from and , meaning . By sorting the left endpoints of elements of and , it follows that (the other intersections are empty).
Now consider , and in particular consider the image for some interval . is affine with a single slope along , therefore is being considered along a single unbroken interval . However, nothing prevents from hitting all the elements of ; since was arbitrary, it holds that is -sawtooth. ∎
The proof of Section 2.1 follows by induction over layers of .
The proof proceeds by induction over layers, showing the output of each node in layer is -sawtooth as a function of the neural network input. For the first layer, each node starts by computing , which is itself affine and thus 1-sawtooth, so the full node computation is -sawtooth by Section 2.1. Thereafter, the input to layer with is a collection of functions with and being -sawtooth by the inductive hypothesis; consequently, is -sawtooth by Section 2.1, whereby applying yields a -sawtooth function (once again by Section 2.1). ∎
2 Upper bound
Note that ; for instance, . The upper bounds will use .
These compositions may be written as follows.
Let real and positive integer be given, and choose the unique nonnegative integer and real so that . Then
The proof proceeds by induction on the number of compositions . When , there is nothing to show. For the inductive step, the mirroring property of pre-composition with combined with the symmetry of (by the inductive hypothesis) implies that every satisfies
Consequently, it suffices to consider , which by the mirroring property means . Since the unique nonnegative integer and real satisfy , the inductive hypothesis applied to grants
Before closing this subsection, it is interesting to view in one more way, namely its effect on provided by the -ap with . Observe that is an -ap with all points duplicated except , and an additional point with -coordinate .
3 Proof of Theorems 1.2 and 1.1
It suffices to prove Theorem 1.2, which yields Theorem 1.1 since is 2-sawtooth, whereby the condition implies
and the upper bound transfers since .
Related work
The standard classical result on the representation power of neural networks is due to Cybenko (1989), who proved that neural networks can approximate continuous functions over arbitrarily well. This result, however, is for flat networks.
An early result showing the benefits of depth is due to Håstad (1986), who established, via an incredible proof, that boolean circuits consisting only of and gates and or gates require exponential size in order to approximate the parity function well. These gates correspond to multiplication and addition over the boolean domain, and moreover the parity function is the Fourier basis over the boolean domain; as mentioned above, as used here is a piecewise affine approximation of a Fourier basis, and it was suggested previously by Bengio and LeCun (2007) that Fourier transforms admit efficient representations with deep networks. Lastly, note that Håstad (1986)’s work has one of the same weaknesses as the present result, namely of only controlling a countable family of functions which is in no sense dense.
More generally, networks consisting of sum and product nodes, but now over the reals, have been studied in the machine learning literature, where it was showed by Bengio and Delalleau (2011) that again there is an exponential benefit to depth. While this result was again for a countable class of functions, more recent work by Cohen et al. (2015) aims to give a broader characterization.
Lastly, while this note was only concerned with finite sets of points, it is worthwhile to mention the relevance of representation power to statistical questions. Namely, by the seminal result of Anthony and Bartlett (1999, Theorem 8.14), the VC dimension of is at most , indicating that these exponential representation benefits directly translate into statistical savings. Interestingly, note that has an exponentially large Lipschitz constant (exactly ), and thus an elementary statistical analysis via Lipschitz constants and Rademacher complexity (Bartlett and Mendelson, 2002) can inadvertently erase the benefits of depth as presented here.