b

DiscoverSearch
About
My stuff
Proving the Lottery Ticket Hypothesis: Pruning is All You Need
2020·arXiv
Abstract
Abstract

The lottery ticket hypothesis (Frankle and Carbin, 2018), states that a randomly-initialized network contains a small subnetwork such that, when trained in isolation, can compete with the performance of the original network. We prove an even stronger hypothesis (as was also conjectured in Ramanujan et al., 2019), showing that for every bounded distribution and every target network with bounded weights, a sufficiently over-parameterized neural network with random weights contains a subnetwork with roughly the same accuracy as the target network, without any further training.

Neural network pruning is a popular method to reduce the size of a trained model, allowing efficient computation during inference time, with minimal loss in accuracy. However, such a method still requires the process of training an over-parameterized network, as training a pruned network from scratch seems to fail (see [10]). Recently, a work by Frankle and Carbin [10] has presented a surprising phenomenon: pruned neural networks can be trained to achieve good performance, when resetting their weights to their initial values. Hence, the authors state the lottery ticket hypothesis: a randomly-initialized neural network contains a subnetwork such that, when trained in isolation, can match the performance of the original network.

This observation has attracted great interest, with various follow-up works trying to understand this intriguing phenomenon. Specifically, very recent works by Zhou et al. [37], Ramanujan et al. [27] presented algorithms to find subnetworks that already achieve good performance, without any training. [27] stated the following conjecture: a sufficiently over-parameterized neural network with random initialization contains a subnetwork that achieves competitive accuracy (with respect to the large trained network), without any training. This conjecture can be viewed as a stronger version of the lottery ticket hypothesis.

In this work, we prove this stronger conjecture, in the case of over-parameterized neural networks. Moreover, we differentiate between two types of subnetworks: subnetworks where specific weights are removed (weight-subnetworks) and subnetworks where entire neurons are removed (neuron-subnetworks). First, we show that a ReLU network of arbitrary depth l can be approximated by finding a weight-subnetwork of a random network of depth 2l and sufficient width. Second, we show that depth-two (one hidden-layer) networks have neuron-subnetworks that are competitive with the best random-features classifier (i.e. the best classifier achieved when training only the second layer of the network). Hence, we imply that for shallow networks, training the second layer of the network is equivalent to pruning entire neurons of a sufficiently large random network. In all our results, the size of initial network is polynomial in the problem parameters. In the case of the weight-subnetwork, we show that the number of parameters in the pruned network is similar, up to a constant factor, to the number of parameters in the target network.

As far as we are aware, this is the first work that gives theoretical evidence to the existence of good subnetworks within a randomly initialized neural network (i.e., proving the strong lottery ticket hypothesis). Our results imply that fundamentally, pruning a randomly initialized network is as strong as optimizing the value of the weights. Hence, while the common method for finding a good network is to train its parameters, our work demonstrates that in fact, all you need is a good pruning mechanism. This gives a strong motivation to develop algorithms that focus on pruning the weights rather than optimizing their values.

1.1 Related Work

Neural Network Pruning Pruning neural networks is a popular method to compress large models, allowing them to run on devices with limited resources. Over the years, a variety of pruning methods were suggested, showing that neural network models can be reduced by up to 90%, with minimal performance loss. These methods differ in two aspects: how to prune (the pruning criterion), and what to prune (spe-cific weights vs. entire neurons or convolutional channels). Works by LeCun et al. [16], Hassibi and Stork [14], Dong et al. [7] explored the efficiency of network pruning based on second derivative conditions. Another popular method is pruning based on the magnitude of the weights [13]. Other pruning techniques remove neurons with zero activation [15], or other measures of redundancy [22, 32]. While weight-based pruning achieves the best results in terms of network compression, the gain in terms of inference time is not optimal, as it cannot be efficiently utilized by modern hardware. To get an effective gain in performance, recent works suggested methods to prune entire neurons or convolutional channels [35, 18, 23, 20].

In our work, we show that surprisingly, pruning a random network achieves results that are competitive with optimizing the weights. Furthermore, we compare neuron-based pruning to weight-based pruning, and show that the latter can achieve strictly stronger performance. We are unaware of any theoretical work studying the power and limitation of such pruning methods.

Lottery Ticket Hypothesis In [10], Frankle and Carbin stated the original lottery ticket hypothesis: A randomly-initialized, dense neural network contains a subnetwork that is initialized such that when trained in isolation it can match the test accuracy of the original network after training for at most the same number of iterations. This conjecture, if it is true, has rather promising practical implications - it suggests that the inefficient process of training a large network is in fact unnecessary, as one only needs to find a good small subnetwork, and then train it separately. While finding a good subnetwork is not trivial, it might still be simpler than training a neural network with millions of parameters.

A follow up work by Zhou et al. [37] claims that the “winning-tickets”, i.e., the good initial subnetwork, already has better-than-random performance on the data, without any training. With this in mind, they suggest an algorithm to find a good subnetwork within a randomly initialized network that achieves good accuracy. Building upon this work, another work by Ramanujan et al. [27] suggests an improved algorithm which finds an untrained subnetwork that approaches state-of-the-art performance, for various architectures and datasets. Following these observations, [27] suggested a complementary conjceture to the original lottery ticket hypothesis: within a sufficiently overparameterized neural network with random weights (e.g. at initialization), there exists a subnetwork that achieves competitive accuracy.

While these results raise very intriguing claims, they are all based on empirical observations alone. Our work aims to give theoretical evidence to these empirical results. We prove the latter conjecture, stated in [27], in the case of deep and shallow neural networks. To the best of our knowledge, this is the first theoretical work aiming to explain the strong lottery ticket conjecture, as stated in [27].

Over-parameterization and random features A popular recent line of works showed how gradient methods over highly over-parameterized neural networks can learn various target functions in polynomial time (e.g. [2],[6],[3],[5]). However, recent works (e.g. [36], [12], [11]) show the limitations of the analysis in the above approach, and compare the power of the analysis to that of random features. In particular, [36] show that this approach cannot efficiently approximate a single ReLU neuron, even if the distribution is standard Gaussian. In this work we show that finding a shallow neuron-subnetwork is equivalent to learning with random features, and that weight-subnetworks is a strictly stronger model in the sense that it can efficiently approximate ReLU neurons, under mild assumptions on the distribution (namely, that it is bounded).

1.2 Notations

We introduce some notations that will be used in the sequel. We denote by  X = {x ∈ Rd : ∥x∥2 ≤ 1} 1our instance space. For a distribution  D over X × Y, we denote the squared-loss of a hypothesis  h : X → Rby:

image

For two matrices  A, B ∈ Rm×n, we denote by  A ⊙ B = [Ai,jBi,j]i,jthe Hadamard (element-wise) product between  A and B. We use U([−c, c]k)to denote the uniform distribution on some cube around zero, and by  N(0, Σ)a normal distribution with mean zero and covariance matrix  Σ. For a matrix H we denote by λmin(H)its minimal eigenvalue. For a matrix A, we denote by  ∥A∥2 the L2operator norm of A, namely ∥A∥2 := λmax(A) where λmaxis the largest singular value of A. We denote by  ∥A∥maxthe max norm of A, namely ∥A∥max := maxi,j |Ai,j|.

In this section we provide our main result, showing that a network of depth l can be approximated by pruning a random network of depth 2l. We show this for a setting where we are allowed to prune specific weights, and are not limited to removing entire neurons (i.e. finding weight-subnetworks). Neuron-subnetworks are discussed in the next section. We further focus on networks with the ReLU activation,  σ(x) = max{x, 0}.We define a network  G : Rd → R of depth l and width2 nin the following way:

image

Where we have:

G(1)(x) = σ(W G(1)x) for W G(1) ∈ Rd×n.

G(i)(x) = σ(W G(i)x) for W G(i) ∈ Rn×n, for every 1 < i < l.

G(l)(x) = W G(l)x for W G(l) ∈ Rn×1

A weight-subnetwork �G of Gis a network of width n and depth l, with weights  W �G(i) := B(i)⊙W G(i)for some mask  B(i) ∈ {0, 1}nin×nout. Our main theorem in this section shows that for every target network of depth l with bounded weights, a random network of depth 2l and polynomial width contains with high probability a subnetwork that approximates the target network:

Theorem 2.1. Fix some  ǫ, δ ∈ (0, 1). Let Fbe some target network of depth l such that for every  i ∈ [l] wehave  ∥W F (i)∥2 ≤ 1,∥W F (i)∥max ≤ 1√nin (where nin = d for i = 1 and nin = n for i > 1). Let G be anetwork of width  poly(d, n, l, 1ǫ, log 1δ) and depth 2l, where we initialize  W G(i) from U([−1, 1]). Then, w.p at least  1 − δthere exists a weight-subnetwork �G of Gsuch that:

image

Furthermore, the number of active (non-zero) weights in �G is O(dn + n2l).

Remark 2.2. We note that the initialization scheme of the network considered in Thm. 2.1 is not standard Xavier initialization. The reason is that in standard Xavier initialization the weights are normalized such that the gradient’s variance at initialization will not depend on the network’s size. Here we don’t calculate the gradient but only prune some of the neurons. Thus, the magnitude of the weights does not depend on the width of the network. That said, the theorem can be easily extended to any initialization which is a uniform distribution on some interval around zero, by correctly scaling the network’s output.

Since the number of parameters in the function  F is dn+n2(l−2)+n, the above shows that the number of active weights in the pruned network is similar, up to a constant factor, to the number of parameters in F. Note that the width of the random network has polynomial dependence on the input dimension d, the width of the target network n and its depth l. While the dependence on the width and depth of the target network is unavoidable, the dependence on the input dimension may seem to somewhat weaken the result. Since neural networks are often used on high-dimensional inputs, such dependence on the input dimension might make our result problematic for practical settings in the high-dimension regimes. However, we note that such dependence could be avoided, when making some additional assumptions on the target network. Specifically, if we assume that the target network has sparse weights in the first layer, i.e. - each neuron in the first layer has at most s non-zero weights, then we get dependence on the sparsity s, rather than on the input dimension d. This is shown formally in the appendix.

The full proof of Thm. 2.1 can be found in Appendix A, and here we give a sketch of the main arguments. The basic building block of the proof is showing how to approximate a single ReLU neuron of the form x �→ σ(⟨w∗, x⟩)by a two layer network. Using the equality  a = σ(a) − σ(−a), we can write the neuron as:

image

Now, consider a two layer network of width k and a single output neuron, with a pruning matrix B for the first layer. It can be written as  x �→ σ��kj=1 ujσ��dt=1 Bj,tWj,txt��.Suppose we pick, for every i, two indexes  j1(i), j2(i), and set the matrix  B s.t. Bj1(i),i, Bj2(i),i = 1and all the rest of the elements of B are

zero. It follows that the pruned network can be rewritten as

image

Comparing the right-hand sides of Equations 1 and 2, we observe that they will be at most  ǫ away fromeach other provided that for every  i, sign(uj1(i)) ̸= sign(uj2(i)),����uj1(i)�� Wj1(i),i − sign(uj1(i))w∗i�� ≤ ǫ/2dand����uj2(i)�� Wj2(i),i − sign(uj2(i))w∗i�� ≤ ǫ/2d. Finally, fixing i and picking  uj1(i), uj2(i), Wj1(i),i, Wj2(i),iat random, the requirements would be fulfilled with probability of  Ω(ǫ/d). Hence, if  k ≫ d/ǫ, for every i we would be able to find an appropriate  j1(i), j2(i)with high probability. Note that the number of weights we are actually using is 2d, which is only factor of 2 larger than the number of original weights required to express a single neuron.

The construction above can be easily extended to show how a depth two ReLU network can approximate a single ReLU layer (simply apply the construction for every neuron). By stacking the approximations, we obtain an approximation of a full network. Since every layer in the original network requires two layers in the newly constructed pruned network, we require a twice deeper network than the original one.

We can derive a slightly stronger result in the case where the target network is a depth-two network. Specifically, we can show that a depth-two network can be approximated by pruning a depth-three random network (rather than pruning a depth-four network, as implied from Thm. 2.1):

Theorem 2.3. Fix some target two-layer neural network  F of width n, and fix ǫ, δ ∈ (0, 1). Let G be a ran-dom three-layer neural network of width  poly�d, n, 1ǫ, log� 1δ��, with weights initialized from  U([−1, 1]).Then, with probability at least  1 − δ, there exists a weight-subnetwork �G of G, such that:

image

Furthermore, the number of active (non-zero) weights in �G is O(dn).

2.1 Universality and Computational Efficiency of Pruning

We showed that in terms of expressive power, pruning weights in a randomly initialized over-parameterized network can approximate a target ReLU network of any depth. Using well-known results in the literature of neural networks, this result implies two interesting corollaries:

Universal Approximation Using Weight Pruning It has been long known that neural networks are universal approximators: they are able to approximate an arbitrary function up to arbitrary accuracy (for example, see [33, 28]). Since we show that pruning a network with random weights can approximate any target network, this implies that pruning a random network is also a universal approximation scheme.

Pruning Weights is Computationally Hard It is well known in the literature of neural networks that learning even a depth-two ReLU network is computationally hard in the general case (see [19, 21, 4]). From these results, it is immediate that weight-pruning of random ReLU networks, deep or shallow, is computationally hard as well. Indeed, if we had an efficient algorithm that finds an optimal weight-subnetwork of a three-layer network, from Thm. 2.3 this algorithm approximates the best depth-two network (for some fixed width). But in general, approximating the best depth-two network on an arbitrary distribution is computationally hard (under certain hardness assumptions), which leads to a contradiction. So, there is no efficient algorithm that is guaranteed to return an optimal weight-subnetwork for any input distribution.

In this section we analyze the power of pruning entire neurons in a depth-two network. The main question we are interested in is the following: suppose that a function f can be well approximated by a depth-two network g of polynomial width (in the relevant parameters). Is the function f also well approximated by pruning entire neurons of a randomly initialized depth-two network of a polynomial width? Here we show that the answer is negative, and in fact pruning entire neurons is equivalent to the well known random features model (e.g. [25], [26]). Intuitively, we show that whenever training only the last layer of the network suffices, it is also possible to construct a good sub-network by pruning entire neurons.

Formally, consider a width k two-layer neural network defined by  g : Rd → Ras follows:

image

where  ui is the i-th coordinate of  u and wi is the i-th row of W. A network  ˜g is aneuron-subnetwork of g if there exists a vector  b ∈ {0, 1}k such that:

image

So,  ˜g is also a 2-layer neural network, which contains a subset of the neuron of g. Next, we define the random features model:

Definition 3.1. Suppose we sample  w1, . . . , wk ∼ Dfrom some distribution D, a random features model over  w1, . . . , wkand activation  σis any function of the form:

image

Training a 2-layer random features model is done by training only the second layer, i.e. training only the weights  u1, . . . , uk. This is equivalent to training a linear model over the features  σ(⟨wi, x⟩), which are chosen randomly. We show that neuron-subnetworks are competitive with random features:

Theorem 3.2. Let D be any distribution over  X × [−1, +1], and let σ : R → R be L-Lipschitz with σ(0) ≤ L. Let ǫ, δ > 0, n ∈ N and D∗ a distribution over  {w : ∥w∥ ≤ 1}such that for  w1, . . . , wn ∼ D∗w.p  > 1 − δthere exist  u1, . . . , un ∈ R such that |ui| ≤ Cand the function  f(x) = �ni=1 uiσ(⟨wi, x⟩)satisfies that  LD(f) ≤ ǫ. Let k ≥ poly�C, n, L, 1ǫ , 1δ�, and suppose we initialize a 2-layer neural network g with width  k where wi ∼ D∗, and ui ∼ U([−1, 1]). Then there exists a neuron-subnetwork  ˜g of g andconstant  c > 0 such that LD(c˜g) ≤ ǫ.

The full proof can be found in Appendix B. Thm. 3.2 shows that for any distribution over the data, if a random features model can achieve small loss, then it is also possible to find a neuron-subnetwork of a randomly initialized network (with enough width) that achieves the same loss. This means that pruning neurons is competitive with the random features model. On the other hand, if for some distribution over the data it is possible to find a neuron-subnetwork of a randomly initialized network that achieves small loss, then clearly it is possible to find a random features model that achieves the same loss. Indeed, we can set the weights of the random features model to be the same as in the neuron-subnetwork, where pruned weights are equal to zero.

To summarize, Thm. 3.2 and the argument above shows an equivalence between random features and neuron-subnetworks: For a distribution D, there is a random features model f with k features such that LD(f) ≤ ǫif-and-only-if for a randomly initialized network with width polynomial in  k, 1ǫ and 1δ , w.p> 1 − δthere exists a neuron-subnetwork  ˜g such that LD(˜g) ≤ ǫ.

A few recent works (e.g. [36], [12], [11]) studied the limitations of random features. In particular, [36] show that a random features model cannot approximate a single ReLU neuron even under standard Gaussian distribution, unless the amount of features or the magnitude of the weights (or both) are exponential in the input dimension. Thus, the above equivalence also shows a limitation of neuron-subnetworks - they cannot efficiently approximate a single ReLU neuron, just as random features can’t. This means that the weight-subnetwork model shown in Sec. 2 is significantly stronger than the neuron-subnetwork model.

The intuition behind the proof of Thm. 3.2 is the following: Assume we initialize a 2-layer neural network of width  n = k · m where kis as in the theorem, and m is some large number (that depends on

ǫ, 1δ). We think of it as initializing m different networks of width k, and from the assumption, for most of these networks there exists a random features model that achieves small loss. For each of these networks we prune a neuron if its randomly initialized weight in the second layer is far from its corresponding random features model’s weight. Note that since we initialize the weights i.i.d., then we prune each neuron with the same probability and independently of the other neurons. To finish the proof, we use a concentration of measure argument to show that averaging many such pruned networks competes with the random features model, and thus also achieves small loss on the input distribution.

3.1 Learning Finite Datasets and RKHS Functions via Neuron-Subnetworks

In this subsection we show that pruning entire neurons may prove beneficial, despite the inherent limitations discussed previously. We focus on two popular families of problems, which are known to be solvable by training depth-two networks:

1. Overfitting a finite sample:  S = {(x1, y1), . . . , (xm, ym) ∈ X × [−1, 1]}. This is equivalent to find-ing a neuron-subnetwork which minimizes the empirical risk on the sample S. This setting is considered in various recent works (for example in [9], [8], [1]).

2. Learning RKHS: given an activation function  σ : R → Rwe consider a target function from the following set of functions:

image

image

The main theorem of this section is the following:

Theorem 3.3. Let  ǫ, δ > 0 and let σ : R → R be L-Lipschitz with  σ(0) ≤ L. Let gbe a randomly initialized 2-layer neural network of width  k such that wi ∼ U��− 1√d, 1√d

image

2. (RKHS function) Let  f ∈ FC. If k ≥ poly�C, L, log� 1δ�, 1ǫ�then w.p > 1 − δthere exists a neuron-subnetwork  ˜gand a constant c > 0 such that:

image

Remark 3.4. For the finite dataset case, the assumption on the minimal eigenvalue  λof the matrix H is standard and assumed in similar forms in other works which approximate a finite dataset using random features approach (see [9], [8], [24]).

In both versions of the theorem, the network’s width does not depend on the dimension of the input data. It does depend on the “complexity” of the target distribution. In the finite dataset case the network’s width depends on the number of examples m and on the value of 1λ. In the RKHS function case, it depends on the constant C which defines the size of the function class  FCfrom which the target function is taken.

Note that in a binary classification task (where that labels are  ±1) over a finite dataset, Thm. 3.3 shows that we can achieve zero loss (with respect to the  0 − 1loss), even if we don’t scale  ˜g(x)by a constant c. To show this, we use Thm. 3.3 with  ǫ = 1/2to get that for every pair (x, y) in the finite dataset we have |c˜g(x) − y| ≤ 1/2, since c > 0 and y ∈ {1, −1}we get that sign(˜g(x)) = sign(y).

We give a short proof intuition for Thm. 3.3, the full proof is in appendix C. We initialize a 2-layer neural network of width  k = k1 · k2, this can be thought as initializing  k2different networks, each of width k1. The idea is to choose  k1large enough so that w.h.p. a random features model with  k1features would be able to approximate the target (either finite dataset or RKHS function). Next, for each network of size  k1 weprune a neuron if it is far from its corresponding random features model. We finish by using a concentration of measure argument to conclude that averaging over  k2such networks (for a large enough  k2) yields a good approximation of the target.

Remark 3.5. The proof of Thm. 3.3 actually provides an algorithm for pruning 2-layer neural networks:

Randomly initialize a 2-layer neural network of width  k = k1 · k2.

For each subnetwork of width  k1- optimize a linear predictor over the random weights from the first layer.

Let  ǫbe a confidence parameter, prune each neuron if its distance from the corresponding weight of the trained linear predictor is more than  ǫ.

This algorithm runs in polynomial time, but it is obviously very naive. However, it does demonstrate that there exists a polynomial time algorithm for pruning neurons in shallow networks. We leave a study of more efficient algorithms for future work.

We have shown strong positive results on the expressive power of pruned random networks. However, as we mentioned previously, our results imply that there is no efficient algorithm for weight-pruning of a random network, by reduction from hardness results on learning neural networks. Hence, weight-pruning is similar to weight-optimization in the following sense: in both methods there exists a good solution, but finding it is computationally hard in the worst case. That said, similarly to weight optimization, heuristic algorithms for pruning might work well in practice, as shown in [37, 27]. Furthermore, pruning algorithms may enjoy some advantages over standard weight-optimization algorithms. First, while weight-optimization requires training very large networks and results in large models and inefficient inference, weight-pruning by design achieves networks with preferable inference-time performance. Second, weight-optimization is largely done with gradient-based algorithms, which have been shown to be suboptimal in various cases (see [30, 31]). Pruning algorithms, on the other hand, can possibly rely on very different algorithmic techniques, that might avoid the pitfalls of gradient-descent.

To conclude, in this work we showed some initial motivations for studying algorithms for pruning random networks, which we believe set the ground for numerous future directions. An immediate future research direction is to come up with a heuristic pruning algorithm that works well in practice, and provide provable guarantees under mild distributional assumptions. Other interesting questions for future research include understanding to what extent the polynomial dependencies of the size of the neural network before pruning can be improved, and generalizing the results to other architectures such as convolutional layers and ResNets.

Acknowledgements: This research is supported by the European Research Council (TheoryDL project), and by European Research Council (ERC) grant 754705.

[1] Z. Allen-Zhu, Y. Li, and Z. Song. A convergence theory for deep learning via over-parameterization. arXiv preprint arXiv:1811.03962, 2018.

[2] Z. Allen-Zhu, Y. Li, and Y. Liang. Learning and generalization in overparameterized neural networks, going beyond two layers. In Advances in Neural Information Processing Systems, 2019.

[3] S. Arora, S. S. Du, W. Hu, Z. Li, and R. Wang. Fine-grained analysis of optimization and generalization for overparameterized two-layer neural networks. arXiv preprint arXiv:1901.08584, 2019.

[4] D. Boob, S. S. Dey, and G. Lan. Complexity of training relu neural network. arXiv preprint arXiv:1809.10787, 2018.

[5] Y. Cao and Q. Gu. A generalization theory of gradient descent for learning over-parameterized deep ReLU networks. arXiv preprint arXiv:1902.01384, 2019.

[6] A. Daniely. SGD learns the conjugate kernel class of the network. In Advances in Neural Information Processing Systems, pages 2422–2430, 2017.

[7] X. Dong, S. Chen, and S. Pan. Learning to prune deep neural networks via layer-wise optimal brain surgeon. In Advances in Neural Information Processing Systems, pages 4857–4867, 2017.

[8] S. S. Du, J. D. Lee, H. Li, L. Wang, and X. Zhai. Gradient descent finds global minima of deep neural networks. arXiv preprint arXiv:1811.03804, 2018.

[9] S. S. Du, X. Zhai, B. Poczos, and A. Singh. Gradient descent provably optimizes over-parameterized neural networks. arXiv preprint arXiv:1810.02054, 2018.

[10] J. Frankle and M. Carbin. The lottery ticket hypothesis: Finding sparse, trainable neural networks. arXiv preprint arXiv:1803.03635, 2018.

[11] B. Ghorbani, S. Mei, T. Misiakiewicz, and A. Montanari. Limitations of lazy training of two-layers neural networks. arXiv preprint arXiv:1906.08899, 2019.

[12] B. Ghorbani, S. Mei, T. Misiakiewicz, and A. Montanari. Linearized two-layers neural networks in high dimension. arXiv preprint arXiv:1904.12191, 2019.

[13] S. Han, J. Pool, J. Tran, and W. Dally. Learning both weights and connections for efficient neural network. In Advances in neural information processing systems, pages 1135–1143, 2015.

[14] B. Hassibi and D. G. Stork. Second order derivatives for network pruning: Optimal brain surgeon. In Advances in neural information processing systems, pages 164–171, 1993.

[15] H. Hu, R. Peng, Y.-W. Tai, and C.-K. Tang. Network trimming: A data-driven neuron pruning approach towards efficient deep architectures. arXiv preprint arXiv:1607.03250, 2016.

[16] Y. LeCun, J. S. Denker, and S. A. Solla. Optimal brain damage. In Advances in neural information processing systems, pages 598–605, 1990.

[17] M. Leshno, V. Y. Lin, A. Pinkus, and S. Schocken. Multilayer feedforward networks with a nonpoly- nomial activation function can approximate any function. Neural networks, 6(6):861–867, 1993.

[18] H. Li, A. Kadav, I. Durdanovic, H. Samet, and H. P. Graf. Pruning filters for efficient convnets. arXiv preprint arXiv:1608.08710, 2016.

[19] R. Livni, S. Shalev-Shwartz, and O. Shamir. On the computational efficiency of training neural net- works. In Advances in Neural Information Processing Systems, pages 855–863, 2014.

[20] J.-H. Luo, J. Wu, and W. Lin. Thinet: A filter level pruning method for deep neural network com- pression. In Proceedings of the IEEE international conference on computer vision, pages 5058–5066, 2017.

[21] P. Manurangsi and D. Reichman. The computational complexity of training relu (s). arXiv preprint arXiv:1810.04207, 2018.

[22] Z. Mariet and S. Sra. Diversity networks: Neural network compression using determinantal point processes. arXiv preprint arXiv:1511.05077, 2015.

[23] D. Molchanov, A. Ashukha, and D. Vetrov. Variational dropout sparsifies deep neural networks. In Proceedings of the 34th International Conference on Machine Learning-Volume 70, pages 2498–2507. JMLR. org, 2017.

[24] A. Panigrahi, A. Shetty, and N. Goyal. Effect of activation functions on the training of overparametrized neural nets. arXiv preprint arXiv:1908.05660, 2019.

[25] A. Rahimi and B. Recht. Random features for large-scale kernel machines. In Advances in neural information processing systems, pages 1177–1184, 2008.

[26] A. Rahimi and B. Recht. Uniform approximation of functions with random bases. In 2008 46th Annual Allerton Conference on Communication, Control, and Computing, pages 555–561. IEEE, 2008.

[27] V. Ramanujan, M. Wortsman, A. Kembhavi, A. Farhadi, and M. Rastegari. What’s hidden in a ran- domly weighted neural network? arXiv preprint arXiv:1911.13299, 2019.

[28] F. Scarselli and A. C. Tsoi. Universal approximation using feedforward neural networks: A survey of some existing methods, and some new results. Neural networks, 11(1):15–37, 1998.

[29] S. Shalev-Shwartz and S. Ben-David. Understanding machine learning: From theory to algorithms. Cambridge university press, 2014.

[30] S. Shalev-Shwartz, O. Shamir, and S. Shammah. Failures of gradient-based deep learning. In Proceedings of the 34th International Conference on Machine Learning-Volume 70, pages 3067–3075. JMLR. org, 2017.

[31] O. Shamir. Distribution-specific hardness of learning neural networks. The Journal of Machine Learning Research, 19(1):1135–1163, 2018.

[32] S. Srinivas and R. V. Babu. Data-free parameter pruning for deep neural networks. arXiv preprint arXiv:1507.06149, 2015.

[33] M. Stinchcombe and H. White. Universal approximation using feedforward networks with nonsigmoid hidden layer activation functions. In IJCNN International Joint Conference on Neural Networks, 1989.

[34] Y. Sun, A. Gilbert, and A. Tewari. Random ReLU features: Universality, approximation, and compo- sition. arXiv preprint arXiv:1810.04374, 2018.

[35] T.-J. Yang, Y.-H. Chen, and V. Sze. Designing energy-efficient convolutional neural networks us- ing energy-aware pruning. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 5687–5695, 2017.

[36] G. Yehudai and O. Shamir. On the power and limitations of random features for understanding neural networks. In Advances in Neural Information Processing Systems, 2019.

[37] H. Zhou, J. Lan, R. Liu, and J. Yosinski. Deconstructing lottery tickets: Zeros, signs, and the super- mask. arXiv preprint arXiv:1905.01067, 2019.

We prove the theorem in a general manner, where we assume that each vector  w∗ is s-sparse, that is, it only has s non-zero coordinates. To prove Thm. 2.3 we assign s = d. We start by showing that the function  x �→ αxican be approximated by prunning a two-layer network:

Lemma A.1. Let  s ∈ [d], and fix some scalar  α ∈ [− 1√s, 1√s], index i ∈ [d], and some ǫ, δ > 0. Letw(1), . . . , w(k) ∈ Rd chosen randomly from  U([−1, 1]d), and u(1), . . . , u(k) ∈ [−1, 1]chosen randomly from U([−1, 1]). Then, for  k ≥ 4ǫ2 log(2δ), w.p at least  1 − δthere exists a binary mask  b(1), . . . , b(k) ∈ {0, 1}d,such that  g(x) = �j u(j)σ(⟨w(j) ⊙ b(j), x⟩) satisfies |g(x) − αxi| ≤ 2ǫ, for ∥x∥∞ ≤ 1. Furthermore, we have �j ∥b(j)∥0 ≤ 2 and maxj ∥b(j)∥0 ≤ 1.

Proof. If  |α| ≤ ǫthen choosing  b(1) = · · · = b(k) = (0, . . . , 0)gives the required. Assume  |α| ≥ ǫ, andassume w.l.o.g that  α > 0. Fix some j ∈ [k′]. Note that:

image

where we used the assumption that  k ≥ 4ǫ2 log(2δ), and similarly:

image

Therefore, using the union bound, w.p at least  1 − δthere exist  j, j′ such that |w(j)i − α| ≤ ǫ, |u(j) − 1| ≤ ǫand  |w(j′)i + α| ≤ ǫ, |u(j′) + 1| ≤ ǫ and since |α| ≥ ǫ we get j ̸= j′. Now, setting  b(j)i = 1, b(j′)i = 1, andthe rest to zero, we get that:

image

We will use the fact that  σ(a) − σ(−a) = a for every a ∈ R. If xi ≥ 0, we get that  g(x) = u(j)w(j)i xi andtherefore:

image

In a similar fashion, we get that for  xi < 0 we have |g(x) − αxi| = |xi||u(j′)w(j′)i − α| ≤ 2ǫ, which gives the required. Since we have  ∥b(j)∥0 = 1, ∥b(j′)∥0 = 1 and ∥b(j′′)∥0 = 0 for every j′′ ̸= j, j′, the maskachieves the required.

Using the previous result, we can show that a linear function  x �→ ⟨w∗, x⟩can be implemented by pruning a two layer network:

image

that  g(x) = �ki=1 uiσ(⟨w(i) ⊙b(i), x⟩) satisfies |g(x)−⟨w∗, x⟩| ≤ ǫ, for ∥x∥∞ ≤ 1. Furthermore, we have �i ∥b(i)∥0 ≤ 2s and maxi ∥b(i)∥0 ≤ 1.

Proof. We assume  k = s ·�16s2ǫ2 log(2sδ )�(otherwise, mask excessive neurons), and let  k′ := ks. With slight

abuse of notation, we denote  w(i,j) := w(j+k′i), u(i,j) := uj+k′i and b(i,j) := b(j+k′i). Let I := {i ∈[d] : w∗i ̸= 0}. By the assumption on  w∗ we have |I| ≤ s, and we assume w.l.o.g. that  I ⊆ [s]. Fix somei ∈ [s], and denote  gi(x) = �j u(i,j)σ(⟨w(i,j) ⊙ b(i,j), x⟩). Let ǫ′ = ǫ2s and δ′ = δs, then from Lemma A.1, with probability at least  1 − δ′ there exists a binary mask  b(i,1), . . . , b(i,k′) ∈ {0, 1}d with �j ∥b(i,j)∥0 ≤ 2such that  |gi(x) − w∗i xi| ≤ 2ǫ′ = ǫs for every x ∈ Rd with ∥x∥∞ ≤ 1. Now, using the union bound we get that with probability at least  1 − δ, the above holds for all  i ∈ [s], and so:

image

Now, we can show that a network with a single neuron can be approximated by prunning a three-layer network:

Lemma A.3. Let  s ∈ [d], and fix some  w∗ ∈ [− 1√s, 1√s]d with ∥w∗∥0 ≤ s, some v∗ ∈ [−1, 1] andsome  ǫ, δ > 0. Let w(1), . . . , w(k1) ∈ Rd chosen randomly from  U([−1, 1]d), u(1), . . . , u(k2) ∈ [−1, 1]k1chosen randomly from  U([−1, 1]k1), and v ∈ [−1, 1]k2 chosen randomly from  U([−1, 1]k2). Then, for k1 ≥ s·�64s2ǫ2 log(4sδ )�, k2 ≥ 2ǫ log(2δ), w.p at least  1−δthere exists a binary mask  b(1), . . . , b(k1) ∈ {0, 1}d,

ˆb ∈ {0, 1}k2, such that  g(x) = �k2i=1 ˆbiviσ(�k1j=1 u(i)j σ(⟨w(j) ⊙b(j), x⟩)) satisfies |g(x)−v∗σ(⟨w∗, x⟩)| ≤ǫ, for ∥x∥2 ≤ 1. Furthermore, we have �j ∥b(j)∥0 ≤ 2s and maxj ∥b(j)∥0 ≤ 1.

Proof. Let  ǫ′ = ǫ2, and note that for every  i ∈ [k2] we have P [|vi − v∗| ≤ ǫ′] ≥ ǫ′. Therefore, the probability that for some  i ∈ [k2]it holds that  |vi − v∗| ≤ ǫ′ is at least  1 − (1 − ǫ′)k2 ≥ 1 − e−k2ǫ′ ≥ 1 − δ2, where weuse the fact that  k2 ≥ 1ǫ′ log(2δ ). Now, assume this holds for  i ∈ [k2]. Let ˆbj =1{j = i}, and so:

image

Then, from Lemma A.2, with probability at least  1 − δ2 there exists  b(1), . . . , b(k1)s.t. for every  ∥x∥∞ ≤ 1:

image

And therefore, for every  ∥x∥2 ≤ 1:

image

Finally, we show that pruning a three-layer network can approximate a network with n neurons, since it is only a sum of networks with 1 neuron, as analyzed in the previous lemma:

Lemma A.4. Let  s ∈ [d], and fix some  w(1)∗, . . . , w(n)∗ ∈ [−1, 1]d with ∥w(i)∗∥0 ≤ s, v∗ ∈ [−1, 1]n andlet  f(x) = �ni=1 v∗i σ(⟨w(i)∗, x⟩). Fix some ǫ, δ > 0. Let w(1), . . . , w(k1) ∈ Rdchosen randomly from U([−1, 1]d), u(1), . . . , u(k2) ∈ [−1, 1]k1 chosen randomly from  U([−1, 1]k1), and v ∈ [−1, 1]k2 chosenrandomly from  U([−1, 1]k2). Then, for  k1 ≥ ns·�64s2n2ǫ2 log(4nsδ )�, k2 ≥ 2nǫ log(2nδ ), w.p at least  1−δ there

exists a binary mask  b(1), . . . , b(k1) ∈ {0, 1}d, ˜b(1), . . . ,˜b(k2) ∈ {0, 1}k1, ˆb ∈ {0, 1}k2, such that g(x) = �k2i=1 ˆbiviσ(�k1j=1 ˜b(i)j u(i)j σ(⟨w(j) ⊙ b(j), x⟩)) satisfies |g(x) − f(x)| ≤ ǫ, for ∥x∥2 ≤ 1. Furthermore, we have �j ∥b(j)∥0 ≤ 2s and maxj ∥b(j)∥0 ≤ 1.

Proof. Denote  k′1 = k1n , k′2 = k2n and assume k′1, k′2 ∈ N(otherwise mask exceeding neurons). With slight abuse of notation, we denote  w(i,j) := w(j+k′1i), u(i,j) :=�u(j+ik′2)ik′1 , . . . , u(j+ik′2)(i+1)k′1

image

Now, by setting ˜b(j+k′1i)l =1{ik′1 ≤ l < (i+1)k′1}we get that  g(x) = �ni=1 gi(x). Now, from Lemma A.3 we get that with probability at least  1 − δn we have��gi(x) − v∗i σ(⟨w(i)∗, x⟩)�� ≤ ǫn for every ∥x∥2 ≤ 1.Using the union bound, we get that with probability at least  1 − δ, for ∥x∥2 ≤ 1 we have |g(x) − f(x)| ≤�ni=1��gi(x) − v∗i σ(⟨w(i)∗, x⟩)�� ≤ ǫ.

image

In a similar fashion, we can prove a result for deep networks. We start by showing that a single layer can be approximated by pruning:

Lemma A.5. Let  s ∈ [d], and fix some  w(1)∗, . . . , w(n)∗ ∈ [− 1√s, 1√s]d with ∥w(i)∗∥0 ≤ s and let F :Rd → Rn such that F(x)i = σ(⟨w(i)∗, x⟩). Fix some ǫ, δ > 0. Let w(1), . . . , w(k) ∈ Rd chosen randomly from  U([−1, 1]d) and u(1), . . . , u(n) ∈ [−1, 1]k chosen randomly from  U([−1, 1]k). Then, for  k ≥ ns ·

ǫ2 log(2nsδ )�, w.p at least  1 − δthere exists a binary mask  b(1), . . . , b(k) ∈ {0, 1}d, ˜b(1), . . . ,˜b(n) ∈

{0, 1}k1, ˆb ∈ {0, 1}k, such that for  G : Rd → Rn with G(x)i = σ(�kj=1 ˜b(i)j u(i)j σ(⟨w(j) ⊙ b(j), x⟩)) wehave  ∥G(x)−F(x)∥2 ≤ ǫ, for ∥x∥∞ ≤ 1. Furthermore, we have �j ∥b(j)∥0 ≤ 2sn and �i ∥˜b(i)∥0 ≤ 2sn.

Proof. Denote  k′ = kn and assume k′ ∈ N(otherwise mask exceeding neurons). With slight abuse of notation, we denote  w(i,j) := w(j+k′i), b(i,j) := b(j+k′i) and we denote  ˜u(i) :=�u(i)ik′, . . . , u(i)(i+1)k′�. Definefor every  i ∈ [n]:

image

Now, by setting ˜b(j+k′1i)l =1{ik′1 ≤ l < (i + 1)k′1}we get that  G(x)i = σ(gi(x)). Now, from Lemma A.2 with  ǫ′ = ǫ√n and δ′ = δn, since k ≥ s ·�16s2(ǫ′)2 log(2sδ′ )�we get that with probability at least  1 − δn we have

��gi(x) − ⟨w(i)∗, x⟩�� ≤ ǫ√n for every ∥x∥∞ ≤ 1. Using the union bound, we get that with probability at least 1 − δ, for ∥x∥∞ ≤ 1 we have:

image

Notice that Lemma A.2 also gives �j ∥b(i,j)∥0 ≤ 2s and so �ni=1�j ∥b(i,j)∥0 ≤ 2sn. Since we can set ˜b(i)j = 0 for every i, j with b(i,j) = 0, we get the same bound on �i ∥˜b(i)∥0.

Using the above, we can show that a deep network can be approximated by pruning. We show this result with the assumption that each neuron in the network has only s non-zero weights. To get a similar result without this assumption, as is stated in Thm. 2.1, we can simply choose s to be its maximal value - either d for the first layer of n for intermediate layers.

Theorem A.6. (formal statement of Thm. 2.1, when  s = max{n, d}). Let s, n ∈ N, and fix some W (1)∗, . . . , W (l)∗ such that W (1)∗ ∈ [− 1√s, 1√s]d×n, W (2)∗, . . . , W (l−1)∗ ∈ [− 1√n, 1√n]n×n and W (l)∗ ∈

[− 1√n, 1√n]n×1. Assume that for every  i ∈ [l] we have ∥W (i)∗∥2 ≤ 1 and maxj ∥W (i)j ∥0 ≤ s. DenoteF (i)(x) = σ(W (i)∗x) for i < l and F (l)(x) = W (l)∗x, and let F(x) := F (l) ◦ · · · ◦ F (1)(x). Fix someǫ, δ ∈ (0, 1). Let W (1), . . . , W (l), U (1), . . . , U (l) such that W (1) is chosen randomly from  U([−1, 1]d×k),W (2), . . . , W (l) is chosen randomly from  U([−1, 1]n×k), U (1), . . . , U (l−1) chosen from  U([−1, 1]k×n) andU (l) chosen from  U([−1, 1]k). Then, for  k ≥ ns ·�64s2l2nǫ2 log(2nslδ )�, w.p. at least  1 − δthere exist  B(i) abinary mask for  W (i) with matching dimensions, and ˜B(i) a binary mask for  U (i) with matching dimensions, s.t.:

image

Where we denote  G = G(l) ◦ · · · ◦ G(1), with G(i)(x) := σ( ˜B(i) ◦ U (i)σ(B(i) ◦ W (i)x)) for every i < l andG(l)(x) := ˜B(l) ◦ U (l)σ(B(l) ◦ W (l)x). Furthermore, we have  ∥B(i)∥0 ≤ 2sn and ∥ ˜B(i)∥0 ≤ 2sn.

Proof. Fix some i < l. From A.5, with probability at least  1 − δl there exists a choice for  ˜B(i), B(i) suchthat for every  ∥x∥∞ ≤ 1 we have ∥F (i)(x) − G(i)(x)∥2 ≤ ǫ2l. Note that we want to show that every layer is well approximated given the output of the previous layer, which can slightly deviate from the output of the original network. So, we need to relax the condition of Lemma A.5 to  ∥x∥∞ ≤ 2in order to allow these small deviations from the target network.

Notice that if  ∥x∥∞ ≤ 2, from homogeneity of  G(i), F (i) to positive scalars we get that:

image

Similarly, from Lemma A.2, with probability at least  1− δl it holds that��F (l)(x) − G(l)(x)�� ≤ ǫl for every xwith  ∥x∥∞ ≤ 2. Assume that all the above holds, and using the union bound this happens with probability at least  1 − δ. Notice that for every  x we have ∥F (i)(x)∥2 ≤ ∥W (i)∗x∥2 ≤ ∥W (i)∗∥2∥x∥2 ≤ ∥x∥2, and so∥F (i) ◦ · · · ◦ F (1)(x)∥2 ≤ ∥F (i−1) ◦ · · · ◦ F (1)(x)∥2 ≤ · · · ≤ ∥x∥2. Fix some x with ∥x∥2 ≤ 1and denote x(i) = F (i) ◦ · · · ◦ F (1)(x) and ˆx(i) = G(i) ◦ · · · ◦ G(1)(x). Now, we will show that  ∥x(i) − ˆx(i)∥2 ≤ iǫl forevery  i ≤ l, by induction on i. The case i = 0 is trivial, and assume the above holds for  i − 1. Notice that

in this case we have  ∥ˆx(i−1)∥∞ ≤ ∥ˆx(i−1)∥2 ≤ ∥x(i−1)∥2 + ∥x(i−1) − ˆx(i−1)∥2 ≤ 2. Therefore:

image

From the above, we get that  |F(x) − G(x)| = ∥x(l) − ˆx(l)∥2 ≤ ǫ.

First we will need the following lemma, which intuitively shows a generalization bound over linear predictors, where each coordinate of each sample is pruned with equal probability and independently.

Lemma B.1. Let  k > 0, and v(1), . . . , v(k) ∈ [−1, 1]d. Let ˆv(j) be Bernoulli random variables such that for each j, with probability  ǫ we have ˆv(j) = 1ǫv(j), and with probability  1 − ǫ we have ˆv(j) = 0. Then we have w.p  > 1 − δ that:

image

Proof. Note that for each  j ∈ [k]we have that  E�ˆv(j)� = v(j), thus for every vector  z ∈ Rd, alsoE�1k�kj=1⟨ˆv(j), z⟩�= 1k�kj=1⟨v(j), z⟩. Hence, using a standard argument about Rademacher complexity (see [29] Lemma 26.2) we have that:

image

where  ξ1, . . . , ξkare standard Rademacher random variables. Set  ˜v(j) = ˆv(j)−v(j) ,using Cauchy-Schwartz we can bound Eq. (3) by:

image

Next, we can use Jensen’s inequality on Eq. (4) to bound it

image

Finally, using the fact that  ∥˜v(j)∥2 ≤ ∥ˆv(j)∥2 + ∥v(j)∥2 ≤ 1ǫ2∥v(j)∥2 + ∥v(j)∥2 ≤ 2dǫ2we have that:

image

In order to prove the lemma we will use McDiarmid’s inequality to get guarantees with high probability. Note that for every  l ∈ [k], by taking ˜ˆv(l) instead of ˆv(l) we have for every  z with ∥z∥ ≤ L that:

image

By using Mcdiarmid’s theorem we get

image

setting the r.h.s to  δ, and t =

image

Next, we show the main argument, which states that by pruning a neuronds from a large enough 2-layer neural network, it can approximate any other 2-layer neural network for which the weights in the first layer are the same, and the weights in the second layer are bounded.

Lemma B.2. Let  k1 ∈ N and ǫ, δ, M > 0and assume that  σ is L-Lipschitz with  σ(0) ≤ L. Let

image

P (∥wi∥ ≤ 1) = 1 and u(j)i ∼ U([−1, 1]). Let v(1), . . . , v(k2) ∈ Rk1 with ∥v(j)∥∞ ≤ M for every j ∈ [k2],and define  f (j)(x) = �k1i=1 v(j)i σ�⟨w(j)i , x⟩�. Then there exist  b(1), . . . , b(k2) ∈ {0, 1}k1 such that for the functions  ˜g(j)(x) = �k1i=1 b(j)i · u(j)i σ�⟨w(j)i , x⟩�w.p > 1 − δ we have:

image

where  c1 = 8k1Lǫ

image

image

Set the following vectors:  ˆv(j) = 2ǫ′

image

z(j) : Rd → Rk1 with z(j)i (x) = σ�⟨w(j)i , x⟩�. Now, the functions  f (j)(x)can be written as  f (j)(x) =

⟨v(j), z(j)(x)⟩, we denote

image

Our goal is to bound the following, when the supremum is taken over  ∥x∥ ≤ 1:

image

where  c1 = 2ǫ′ = 8k1Lǫ . We will now bound each expression in Eq. (5) with high probability. For the first expression, we first bound:

image

Fix  i ∈ [k1] and set X(j)i := supx����ˆu(j)i − ˆv(j)i �· z(j)i (x)���and note that for every  x with ∥x∥ ≤ 1 wehave that  supx���z(j)i (x)��� ≤ 2L. For the random variables  X(j)i we get:

image

We now use Hoeffding’s inequality to get that:

image

image

For the second expression in Eq. (5) we first note that for all  j ∈ [k2] we have maxx:∥x∥≤1 ∥z(j)(x)∥ ≤2L√k1. Hence we can bound the second expression

image

Using Lemma B.1 on the above term, w.p  > 1 − δ2 we have that:

image

Combining Eq. (6) with Eq. (7), applying union bound and taking  k2 ≥256L4k41 log( 2δ)ǫ4, we can now use the bound in Eq. (5) to get w.p  > 1 − δ:

image

We are now ready to prove the main theorem:

Proof of Thm. 3.2. Set  m = 256 log( 2nδ )C4n4L4ǫ4 ·log( 1δ)2δ3and initialize a 2-layer neural network with width k := m · nand initialization as described in the theorem, denote  g(x) = �mj=1�ni=1 u(j)i σ(⟨w(j)i , x⟩) asthis network. By the assumption of the theorem, for each  j ∈ [m] w.p > 1 − δthere exists a vector  v(j)with  ∥v(j)∥∞ ≤ Csuch that the function  f (j)(x) = �ni=1 v(j)i σ(⟨w(j)i , x⟩)satisfy that  LD�f (j)� ≤ ǫ.Let  Zjbe the random variable such that  Zj = 0if there exists a vector  v(j) that satisfies the above, and Zj = 1otherwise. the random variables  Zjare i.i.d since we initialize each  w(j)i i.i.d, and P(Zj = 1) = δ,E[Zj] = δ. Denote Z = �mj=1 Zj, then E[Z] = mδ. We use Hoeffding’s inequality on Z to get that:

image

Replacing the r.h.s with  δand setting  t = δwe get that if  m >log( 1δ)2δ2 then w.p > 1−δwe have that  Z ≤ 2δ.In particular, there are at least  m0 = 256 log( 2nδ )C4n4L4ǫ4indices (denote them w.l.o.g  j = 1, . . . , m0) suchthat for every  j ∈ [m0]there exists a vector  v(j) with ∥v(j)∥∞ ≤ Csuch that the function  f (j)(x) =�ni=1 v(j)i σ(⟨w(j)i , x⟩)satisfy that  LD�f (j)�≤ ǫ.

We now use Lemma B.2 with  δ, ǫC and v(1), . . . , v(m0)to get that w.p  > 1 − δthat there exists a neuron- subnetwork  ˜g(x)and constant  c′ > 0such that:

image

Set  c = C · c′, the loss of  c˜g(x)can be bounded by:

image

We will bound each term of the above expression. Using Eq. (8) we have:

image

For the second term in Eq. (9) we have that:

image

re-scaling  ǫfinishes the proof.

We first show that a finite dataset, under mild assumptions on the data, can be approximated using a random features model. The proof of the following lemma is exactly the same as the proof of Lemma 3.1 in [9].

Lemma C.1. Let  δ > 0, x1, . . . , xm ∈ Rd, and let H be the m × mmatrix with:

image

Assume that  λmin(H) = λ > 0, then for k >64m2 log2( mδ )λ2 , w.p > 1 − δover sampling of  w1, . . . , wk wehave that  λmin( ˜H) ≥ 34λ where:

image

Using the lemma above, and under the assumptions made on the data, w.h.p a two-layer network of size ˜O�m2λ2�can overfit the data:

Proposition C.2. Let  δ > 0, x1, . . . , xm ∈ Rd and y1, . . . , ym ∈ {±1}. Assume that  λmin(H) = λ > 0,and  σ is L-Lipschitz then for  k >64m2 log2( mδ )λ2 w.p 1 − δover sampling of  w1, . . . , wk there is u ∈ Rk with∥u∥∞ ≤ 4Lm3λ such that for every  j = 1, . . . , m we have �ki=1 uiσ(⟨wi, xj⟩) = yj

Proof. Set  X to be the k × mmatrix defined by  Xi,j = σ(⟨wi, xj⟩). By our assumption and the choice of k, w.p > 1 − δwe have that ˜H = X⊤Xis invertible, and has a minimal eigenvalue of at least 34λ. Defineu = y(X⊤X)−1X⊤, it is easy to see that uX = y, furthermore:

image

For the second variation of Thm. 3.3 we consider functions from the class of functions  FC. Here we use Theorem 3.3 from [36]:

image

with  σ(0) ≤ L, and cd =�√d2�da normalization term. Assume that  max∥w∥≤1|g(w)| ≤ Cfor a constant

C. Then for every  δ > 0 if w1, . . . , wkare drawn i.i.d from the uniform distribution on�−1√d, 1√d�d, w.p> 1 − δthere is a function of the form

image

To prove the main theorem, we use the same argument as in the proof of Thm. 3.2, that pruning neurons can approximate random features models. Here the size of the target random features model depends on the complexity of the target (either a finite dataset or RKHS function).

Proof of Thm. 3.3. Although the proof for the two variations of the theorem are similar, for clarity and ease of notations we will prove them separately.

image

λ2 , fromProposition C.2 w.p  > 1−δ1we get the following: There exists some  v(j) ∈ Rk1 with ∥v(j)∥∞ ≤ 4Lm3λsuch that for the function  f (j)(x) := �k1i=1 v(j)i σ�⟨w(j)i , x⟩�, and for every l = 1, . . . , m, we have f (j)(xl) = yl. Using union bound over all choices of j, we get that w.p  > 1 − δ2 the above hold for every  j ∈ [k2].

image

λ4ǫ4. Using Lemma B.2 with v(1), . . . , v(k2) and ǫ′ we have that there exist  b(1), . . . , b(k2) such that for the functions  ˜g(j)(x) =�k1i=1 b(j)i · u(j)i σ�⟨w(j)i , x⟩�we get:

image

where  c1 = 8k1Lǫ . Denote ˜g(x) = �k2j=1 g(j)(x) and set c = c1Mk2 = 32k1Lm3λǫk2 . Using Eq. (12) we have that for every l = 1, . . . , m:

image

ǫ2, from Thm. C.3 w.p > 1−δ1we get the following: There exists some  v(j) ∈ Rk1 with ∥v(j)∥∞ ≤ Ck1 ≤ 1such that for the function  f (j)(x) := �k1i=1 v(j)i σ�⟨w(j)i , x⟩�we have supx:∥x∥≤1��f (j)(x) − f(x)�� ≤ ǫ2. Using union

image


Designed for Accessibility and to further Open Science