Datasets:
Add files using upload-large-folder tool
Browse files- parse/train/BJMvBjC5YQ/BJMvBjC5YQ.md +428 -0
- parse/train/BJMvBjC5YQ/BJMvBjC5YQ_content_list.json +0 -0
- parse/train/BJMvBjC5YQ/BJMvBjC5YQ_middle.json +0 -0
- parse/train/BJMvBjC5YQ/BJMvBjC5YQ_model.json +0 -0
- parse/train/Byg9bxrtwS/Byg9bxrtwS.md +661 -0
- parse/train/Byg9bxrtwS/Byg9bxrtwS_content_list.json +0 -0
- parse/train/Byg9bxrtwS/Byg9bxrtwS_middle.json +0 -0
- parse/train/Byg9bxrtwS/Byg9bxrtwS_model.json +0 -0
- parse/train/PhtFY9plHk/PhtFY9plHk.md +417 -0
- parse/train/PhtFY9plHk/PhtFY9plHk_content_list.json +1163 -0
- parse/train/PhtFY9plHk/PhtFY9plHk_middle.json +0 -0
- parse/train/PhtFY9plHk/PhtFY9plHk_model.json +0 -0
- parse/train/Re_VXFOyyO/Re_VXFOyyO.md +375 -0
- parse/train/Re_VXFOyyO/Re_VXFOyyO_content_list.json +1701 -0
- parse/train/Re_VXFOyyO/Re_VXFOyyO_middle.json +0 -0
- parse/train/Re_VXFOyyO/Re_VXFOyyO_model.json +0 -0
- parse/train/r1f0YiCctm/r1f0YiCctm.md +256 -0
- parse/train/r1f0YiCctm/r1f0YiCctm_content_list.json +1120 -0
- parse/train/r1f0YiCctm/r1f0YiCctm_middle.json +0 -0
- parse/train/r1f0YiCctm/r1f0YiCctm_model.json +0 -0
parse/train/BJMvBjC5YQ/BJMvBjC5YQ.md
ADDED
|
@@ -0,0 +1,428 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# CUTTING DOWN TRAINING MEMORY BY RE-FOWARDING
|
| 2 |
+
|
| 3 |
+
Anonymous authors Paper under double-blind review
|
| 4 |
+
|
| 5 |
+
# ABSTRACT
|
| 6 |
+
|
| 7 |
+
Deep Neutral Networks(DNNs) require huge GPU memory when training on modern image/video databases. Unfortunately, the GPU memory as a hardware resource is always finite, which limits the image resolution, batch size, and learning rate that could be used for better DNN performance. In this paper, we propose a novel training approach, called Re-forwarding, that substantially reduces memory usage in training. Our approach automatically finds a subset of vertices in a DNN computation graph, and stores tensors only at these vertices during the first forward. During backward, extra local forwards (called the Re-forwarding process) are conducted to compute the missing tensors between the subset of vertices. The total memory cost becomes the sum of (1) the memory cost at the subset of vertices and (2) the maximum memory cost among local re-forwards. Re-forwarding trades training time overheads for memory and does not compromise any performance in testing. We propose theories and algorithms that achieve the optimal memory solutions for DNNs with either linear or arbitrary computation graphs. Experiments show that Re-forwarding cuts down up-to $8 0 \%$ of training memory on popular DNNs such as Alexnet, VGG, ResNet, Densenet and Inception net.
|
| 8 |
+
|
| 9 |
+
# 1 INTRODUCTION
|
| 10 |
+
|
| 11 |
+
The standard DNN training process consists of two alternated stages: forward and backward. Fig. 1 (a) illustrates an example of feed-forward neural networks. In the forward stage, the network takes an input tensor, $[ B a t \bar { c } h S i z e \times C h a n n e l \times W i d t h \times H e i g h t ]$ , and computes the tensors at each layer until producing the output. In the backward stage, difference between the output and ground truth is passed back along the network to compute the gradients at each layer. The regular training approach saves tensors at all layers during forward, because they are all needed to compute gradients during backward. The total memory cost is the sum of cost over all layers.
|
| 12 |
+
|
| 13 |
+
In popular backbone DNNs for feature extraction of images, such as AlexNet (Krizhevsky et al. (2012)), VGG (Simonyan & Zisserman (2014)) and ResNet (He et al. (2016)), the memory cost increases quadratically with the input image resolution and network depth. For example, given an median size input tensor of (32, 3, 224, 224), ResNet101 requires around $5 0 0 0 ~ \mathrm { M B }$ . In more challenging tasks, DNNs that detect small objects and large number of object categories require input image resolution of more than $6 0 0 \times 6 0 0$ (Ren et al. (2015); Singh et al. (2017); Redmon & Farhadi (2018)). The memory issue is worse for video-based DNNs, such as CDC (Shou et al. (2017)), C3D (Ji et al. (2013)) and 3D-ResNet (Hara et al. (2017)). To model complex activities in video, the input tensor may contain 64 frames. Moreover, DNN training takes much more memory than testing. In order to train DNNs with large databases and big learning rate, the batch size can be up to 64. In training DNN compositions, such as Generative adversarial networks (GANs), multiple generator and discriminator networks are simultaneously stored in GPU memory.
|
| 14 |
+
|
| 15 |
+
Existing efforts to address memory issues presented three main approaches: (1) Better single GPUs. Recent GPUs provide larger memory at the expense of exponentially growing price and power consumption. For instance, from TitanXp, Quadro P6000 to Tesla V100, for 1-2.7 times increase in memory, the prices increase 2.8-8.5 times. (2) Parallelization among multiple GPUs (Dean et al. (2012); Shi et al. (2009); Langford et al. (2009); Mcdonald et al. (2009); McDonald et al. (2010); Zinkevich et al. (2010); Agarwal et al. (2014); Agarwal & Duchi (2011)), which requires expensive clusters, introduces substantial I/O cost, and does not reduce the total memory cost. (3) Low-level heuristic techniques. Optimization of computation graphs (Aho et al. (1986)), which merges inplace operations into non-inplace operations to cut down memory. Liveness analysis (Aho et al. (1986)), which dynamically recycles garbage tensors in training epochs. These approaches are specific to certain DNN structures, data and tasks.
|
| 16 |
+
|
| 17 |
+

|
| 18 |
+
Figure 1: Regular Training Approach vs. Re-forwarding (our). (a) The regular approach saves all tensors during forward, and uses these tensors to compute gradients during backward. (b) Reforwarding (our) saves a subset of tensors during the first forward, and conducts “Re-forward” to compute tensors for gradients during backward.
|
| 19 |
+
|
| 20 |
+
To address above issues, we propose a fundamental approach that explores trade-off between memory and computation power of GPUs. Note that recent affordable GPUs, although limited in memory ( 12GB), provide exceptional improvement in GPU cores and FLOPS. Trading computational time for memory is a very attractive solution that make it possible to train very heavy DNNs with finite GPU memory. Our approach only saves tensors at a subset of layers during the first forward, and conduct only extra local forwards to compute the missing tensors needed during backward. We call the extra forward process as Re-forwarding. The total memory cost is the sum of (1) the cost at the subset of layers and (2) the maximum memory cost among local re-forwards. Training with Reforwarding, see Fig. 1 (b), leads to substantial memory reduction. We propose sophisticate theories and efficient algorithms that achieve the optimal memory solution of arbitrary computation graphs.
|
| 21 |
+
|
| 22 |
+
# 2 RELATED WORK
|
| 23 |
+
|
| 24 |
+
To alleviate the memory pressure from a single GPU processor, many researchers utilized the wellestablished techniques for distributed computation (Dean et al. (2012); Shi et al. (2009); Langford et al. (2009); Mcdonald et al. (2009); McDonald et al. (2010); Zinkevich et al. (2010); Agarwal et al. (2014); Agarwal & Duchi (2011)). These techniques distribute memory pressure to possibly infinite GPUs or server clusters, but do not reduce the total memory cost of DNNs.
|
| 25 |
+
|
| 26 |
+
Other researchers reduced the memory on finite hardware by optimizing computation graph of DNN and performing liveness analysis. The computation graph of DNNs describes the dependencies of tensors among layers. Liveness analysis recycles garbage to manage memory. These ideas were originated from compiler optimization (Aho et al. (1986)) and has been widely adopted by deep learning frameworks: Theano (Bastien et al. (2012); Bergstra et al. (2010)), MXNet (Chen et al. (2015)), Tensorflow (Abadi et al. (2016)) and CNTK (Yu et al. (2014)). Some other techniques efficiently swap data between CPU and GPU (Wang et al. (2018); Rhu et al. (2016)). These techniques usually cost extra I/O time and still do not actually reduce the total memory cost.
|
| 27 |
+
|
| 28 |
+
The closest work to our approach, Chen et al.(Chen et al. (2016)), uses the gradient checkpoints (similar to the subset of layers in Re-forwarding). However, (Chen et al. (2016)) only worked on linear computation graph via a heuristic algorithm. Our approach generates optimal solutions for both linear and arbitrary computation graphs. Our algorithm reduces training memory by manipulating high-level tensors, therefore is generalizable to any DNNs and their compositions. All previous techniques are compatible to our approach and can further improve the memory efficiency of DNN training.
|
| 29 |
+
|
| 30 |
+
# 3 LINEAR COMPUTATION GRAPH (LCG)
|
| 31 |
+
|
| 32 |
+
Denote a computation graph as $G = \left( E , V \right)$ . $E = \{ e _ { i } \}$ and $V = \{ v _ { i } \}$ are the edges and vertices in the computation graph, respectively. In deep neural networks, the vertices represent the tensors and the edges represent operations. Denote function $l ( \cdot )$ as a measure of memory cost. $V _ { R }$ is the subset of vertices saved during the first forward. $l ( v _ { i } )$ is defined as the memory cost of storing vertex $v _ { i }$ . For two adjacent vertices $v _ { i }$ and $v _ { j }$ in set $V _ { R }$ , the memory cost during re-forwarding from $v _ { i }$ to $v _ { j }$ defined as . Using th $\begin{array} { r } { l ( v _ { i } , v _ { j } ) = \sum _ { t = i + 1 } ^ { j - 1 } l ( v _ { t } ) } \end{array}$ , which is the sum of cost over all the vertices between cost of training with re-forwarding is formulated as $v _ { i }$ and $v _ { j }$
|
| 33 |
+
|
| 34 |
+
$$
|
| 35 |
+
\operatorname* { m i n } _ { V _ { R } } \sum _ { i } l ( v _ { i } ) + \operatorname* { m a x } _ { j } l ( v _ { j } , v _ { j + 1 } ) ,
|
| 36 |
+
$$
|
| 37 |
+
|
| 38 |
+
where the first term is the sum of the memory cost of all the stored tensors, and the second term is the maximal cost among the re-forwards.
|
| 39 |
+
|
| 40 |
+
For easy illustration, we start by formulating Re-forwarding on Linear Computation Graphs (LCG) (Fig. 2 (a)). For LCGs, Eqn. 1 can be solved in two cases.
|
| 41 |
+
|
| 42 |
+

|
| 43 |
+
Figure 2: (a) Linear Computation Graph (LCG). “s” denotes the start vertex,“t” denotes the end vertex. (b) Arbitrary Computation Graph (ACG). The structure between $\mathbf { \dot { s } } ^ { \mathbf { \gamma } }$ and “t” vertices may contain arbitrary branches and connections.
|
| 44 |
+
|
| 45 |
+
Case(1) LCG with Identical Vertex Cost: Suppose a LCG has $N$ vertices, each of which has the same cost $\begin{array} { r } { l ( v _ { i } ) = \frac { 1 } { N } } \end{array}$ and the total cost is 1. Obviously, the optimal solution is reached when vertices in $V _ { R }$ are distributed evenly in the LCG. Suppose the number of vertices in $V _ { R }$ is $k$ . The total cost is then $\textstyle { \frac { k } { N } } + { \frac { 1 } { k } }$ . The optimal solution of Eqn. 1 is $k = \sqrt { N }$ , and the optimal total cost is $\textstyle { \frac { 2 } { \sqrt { N } } }$ .
|
| 46 |
+
|
| 47 |
+
Case (2) LCG with Non-identical Vertex Cost: When the assumption of identical cost does not hold, the solution to Eqn. 1 does not have an analytic form. Denote the maximal Re-forward cost $\operatorname* { m a x } _ { j } l ( v _ { j } , v _ { j + 1 } )$ as a constant $C$ , and the solution to Eqn. 1 is reduced to solving for $\operatorname* { m i n } _ { V _ { R } } \sum _ { i } l ( v _ { i } )$ .
|
| 48 |
+
|
| 49 |
+
# Algorithm 1 Linear Computation Graph (LCG) Solver
|
| 50 |
+
|
| 51 |
+
<table><tr><td>1: for each vertex pair (Ui,Uj) in G do</td><td></td></tr><tr><td>2:</td><td>Set the maximal term as l(Ui, Uj)</td></tr><tr><td>3:</td><td>Construct Accessibility Graph</td></tr><tr><td>4:</td><td>Find the shortest path in the Accessibility Graph as the solution</td></tr><tr><td>5:</td><td>Compute the actual total cost of the solution</td></tr><tr><td>6: 7:</td><td>Save the solution if it's better. Suppose the actual max term of this solution is B,and l(vi,Uj) = C,skip the loops where</td></tr></table>
|
| 52 |
+
|
| 53 |
+
All the Re-forward costs in an optimal solution satisfy the constraint $l ( v _ { j } , v _ { j + 1 } ) \le C$ . We solve Eqn. 1 by constructing a new graph, called Accessibility Graph $G ^ { A } = \left( E ^ { A } , V \right)$ . The edges of $G ^ { A }$ , called Accessibility Edge $e _ { i j } ^ { A }$ , exists between vertex $v _ { i }$ and $v _ { j }$ if and only if $l ( v _ { i } , v _ { j } ) \leq C$ . Now the problem of solving $\operatorname* { m i n } _ { V _ { R } } \sum _ { i } l ( v _ { i } )$ is equivalent to finding the shortest path from the source vertex and the target vertex in the Accessibility Graph. Notice that in the optimal solution, the max term equal the one maximal term among all $l ( v _ { i } , v _ { i + 1 } )$ terms. To traverse all possible max terms, we can simply compute the loss of every vertex pair and use it as a possible max term. Given a max term $C$ , suppose the actual max term of the solution under $C$ is $B$ and $B < C$ . It’s obvious that for all the max terms $B \leq m a x < C$ , the solution would be the same solution. Therefore, these max terms can be skipped. Algorithm 1 summarizes the process for searching an optimal solution for
|
| 54 |
+
|
| 55 |
+
LCG. Suppose there are $N$ vertices in the computation graph, the time complexity of Algorithm 1 is $O ( N ^ { 4 } ) ^ { \bar { 1 } }$ .
|
| 56 |
+
|
| 57 |
+
# 4 ARBITRARY COMPUTATION GRAPH(ACG)
|
| 58 |
+
|
| 59 |
+
As generalization of DNNs with LCG, we present theory2 and algorithms for DNNs with Arbitrary Computation Graphs (ACG), in particular the acyclic directed graphs(Fig. 2 (b)).
|
| 60 |
+
|
| 61 |
+
# 4.1 ASSUMPTION FOR OPTIMALITY
|
| 62 |
+
|
| 63 |
+
The optimal solution of Re-forwarding corresponds to an optimal division of ACG, such that memory cost (Eqn. 1) is minimum. We denote that an ACG is divided into end-to-end segments by a set of vertices. These end-to-end segments can have multiple endpoint vertices, for example, multiple source vertices and multiple target vertices. In this paper, as an assumption and also for simplification, these end-to-end segments are narrowed down to those with only one source vertex and one target vertex.
|
| 64 |
+
|
| 65 |
+
Another assumption in the case of ACG is imposed on the operation that has multiple inputs: one can compute the gradients of output with respect to the gradients of inputs without using the current value of inputs. Examples of operations that meet this assumption are: concatenation (the gradient of output is also the concatenation of the gradient of input), add (the gradient of output equals the gradient of input), etc. An example that breaks this assumption is multiplication (the gradient of input depends on the input). Fortunately, most of the popular networks meet this assumption. A simple way to remove this assumption is to store all the input tensors of this multi-input operation. However, this is not modeled by our loss function and may lead to sub-optimal solution.
|
| 66 |
+
|
| 67 |
+
In summary, there are only two assumptions in our approach: (1) the segment in a solution only has two endpoints (source and target). (2) the multi-input operation can compute the gradients of output without using the current value of input. Under these two assumptions, our approach is optimal for ACGs.
|
| 68 |
+
|
| 69 |
+
# 4.2 DEFINITION AND THEOREM
|
| 70 |
+
|
| 71 |
+

|
| 72 |
+
Figure 3: Closed Set Examples: (a) Closed set in a graph. there cannot exist a closed set between $v _ { 2 }$ and $v _ { 4 }$ because $v _ { 3 }$ depends on $v _ { 1 }$ . There can exist a closed set between $v _ { 1 }$ and $v _ { 3 }$ because $v _ { 2 }$ doesn’t depend on any other vertex. (b) Splittable Closed Set (Type 1). $v _ { 2 }$ is the splitting vertex of $s _ { 1 3 }$ . (c) Branched Closed Set (Type 2). (d) Non-branched Closed Set (Type 3).
|
| 73 |
+
|
| 74 |
+
Definition 1. Closed Set: $A$ set s containing vertices and edges is a closed set if and only if it satisfies the following three properties: 1. All the vertices of $s$ have a common ancestor $v _ { i }$ and $a$ common descendent $v _ { j }$ ; 2. Denote the vertex subset of s as $V$ , edge subset as $E$ , and the set of edges between two arbitrary vertices of $V \cup \{ v _ { i } , v _ { j } \}$ is $E ^ { \prime }$ , the edge from $v _ { i }$ to $v _ { j }$ (if exists) as $e _ { i j }$ . $E$ must either be $E ^ { \prime }$ or $E ^ { \prime } - \left\{ e _ { i j } \right\}$ ; 3. An arbitrary ${ \bar { v } } _ { 1 } \in V$ doesn’t have edge with another arbitrary $v _ { 2 } \not \in V \cup \{ v _ { i } , v _ { j } \}$ . For multiple valid closed sets between $v _ { i }$ and $v _ { j }$ , we denote the largest one as $s _ { i j }$
|
| 75 |
+
|
| 76 |
+
In the definition of Closed Set, property 1 corresponds to the two endpoint assumption in section 4.1 where the two endpoints become $v _ { i }$ and $v _ { j }$ in the definition. Property 2 confines the edge subsets of $s$ to be one of two cases: $E ^ { \prime }$ or $E ^ { \prime } - \{ e _ { i j } \}$ . Both cases are valid although they have different edges. Property 3 guarantees the independence of such a set $s$ , meaning that the vertices within $s$ have no connections with other vertices outside $s \cup \{ v _ { i } , v _ { j } \}$ . As there might be multiple valid closed sets between $v _ { i }$ and $v _ { j }$ , which corresponds to the Branched Closed Set in Definition 5, we denote the largest closed set between $v _ { i }$ and $v _ { j }$ as $s _ { i j }$ and denote smaller closed set with an extra superscript, such as $s _ { i j } ^ { 1 }$ .
|
| 77 |
+
|
| 78 |
+
Definition 3. Splitting Vertex: A vertex $v _ { t } \in s _ { i j }$ is a splitting vertex of $s _ { i j }$ if and only if $s _ { i t }$ exists, $s _ { t j }$ exists and $s _ { i j } = s _ { i t } \cup s _ { t j } \cup \{ v _ { t } \}$ and $s _ { i t } \cap s _ { t j } ^ { \mathsf { ^ { * } } } = \varnothing$
|
| 79 |
+
|
| 80 |
+
Definition 4. Splittable Closed Set (Type 1): closed set with at least $I$ splitting vertex.
|
| 81 |
+
|
| 82 |
+
The definition of Splitting Vertex is to describe whether a closed set can be divided into two linearly arranged closed set. A closed set is splittable if it has at least 1 splitting vertex and is defined as Closed Set Type 1.
|
| 83 |
+
|
| 84 |
+
Definition 5. Branched Closed Set (Type 2): A closed set is branched if it has $O$ splitting vertex and can be divided into branches: $s _ { i j } = s _ { i j } ^ { 1 } \cup s _ { i j } ^ { 2 }$ and $s _ { i j } ^ { 1 } \cap s _ { i j } ^ { 2 } = \emptyset$
|
| 85 |
+
|
| 86 |
+
Definition 6. Non-branched Closed Set (Type 3): A closed set $s _ { i j }$ is non-branched if it has $O$ splitting vertex and no branch: $\mathbb { A } s _ { i j } ^ { 1 } \subsetneq s _ { i j }$
|
| 87 |
+
|
| 88 |
+
Among closed set with no splitting vertex, we categorize closed set with branches as Closed Set Type 2, and closed set without branches as Closed Set Type 3. The examples of different types of closed set are shown in Fig. 3.
|
| 89 |
+
|
| 90 |
+

|
| 91 |
+
Figure 4: Example divisions of three types of closed sets. Members of a division are colored differently. (a) Division of closed set type 1. The division is $\{ [ s _ { 1 2 } ] , [ s _ { 2 3 } ] \}$ (b) Division of closed set type 2. The division is $\{ [ s _ { 1 2 } ^ { 1 } ] , [ s _ { 1 2 } ^ { \check { 2 } } ] , [ s _ { 1 2 } ^ { 3 } ] \}$ (c) Division of closed set type 3. The division is $\{ [ s _ { 1 2 } ] , [ s _ { 1 3 } ] , [ s _ { 2 3 } ] , [ s _ { 2 4 } ] , [ s _ { 3 4 } ] \}$
|
| 92 |
+
|
| 93 |
+
Definition 7. Maximal Split: $\{ [ s _ { p q } ] \}$ is a maximal split of non-branched $s _ { i j }$ if $\mathbf { \dot { \theta } } [ s _ { i j } ] = \cup \{ [ s _ { p q } ] \}$ and $\forall s _ { a b } , s _ { c d } \in \{ [ s _ { p q } ] \} , s _ { a b } \cap s _ { c d } \stackrel { \sim } { = } \hat { \emptyset }$ and $\mathcal { \bar { A } } \{ [ s _ { p q } ^ { \prime } ] \} \subsetneq \mathbf { \bar { \{ } } [ s _ { p q } ] \}$ such that $\cup \{ [ s _ { p q } ^ { \prime } ] \} = \left[ s _ { k t } \right] \subsetneq [ \bar { s _ { i j } } ]$
|
| 94 |
+
|
| 95 |
+
Definition 8. Division of Closed Set: For type 1, its division is the linear segments separated by all its splitting vertices; for type 2, its division is all its branches, any of which cannot be divided into more branches; for type 3, its division is its maximal split.
|
| 96 |
+
|
| 97 |
+
For closed set type 1, it can be divided into linearly arranged segments. For closed set type 2, it can be divided into branches. So here we investigate the division of closed set type 3. As we don’t want trivial division, for example, division that is formed by every edge in the closed set, we define Maximal Split to describe the split such that each member of the split is as large as possible. An example of maximal split is shown in Fig. 4 (c). In the definition of maximal split, the term maximal is implied by saying that any subset of this split cannot be combined into a single closed set. If it can, then the maximal split will be formed by this larger closed set and all the rest of the previous split. For closed set type 3, we use its maximal split as its division.
|
| 98 |
+
|
| 99 |
+
Definition 9. Division Tree: Division tree is a representation of a computation graph, where the root node is the whole computation graph, the leaf nodes are all the single tensors in the computation graph, and for a non-leaf node, its children is the members of its division.
|
| 100 |
+
|
| 101 |
+
With the division of 3 types of closed sets, the computation graph can be reorganized into a division tree (Figure 5) where a non-leaf node would be a closed set and its children would be its corresponding division. The root node is the whole computation graph, the largest closed set, and the leaf nodes would be single tensors in the computation graph. With division tree, we can apply divide-and-conquer to search for optimal solution.
|
| 102 |
+
|
| 103 |
+

|
| 104 |
+
Figure 5: In this tree, the root node is the whole computation graph. All the leaf nodes are single tensors. Every other node except root and leaves is a member of the division of its parent.
|
| 105 |
+
|
| 106 |
+
Theorem 1. The division tree of a computation graph is unique and complete.
|
| 107 |
+
|
| 108 |
+
The uniqueness of the division tree indicates that the optimal solution of the division tree would also be the optimal solution of the whole computation graph. The completeness indicates that the division tree has included all the possible members of solution and represents the whole search space for the optimal solution. Theorem 1 is proved in the appendix.
|
| 109 |
+
|
| 110 |
+
# 4.3 ALGORITHM
|
| 111 |
+
|
| 112 |
+
We search optimal solutions for ACGs by solving several sub-problems using Algorithm 2-4 respectively. Based on these components, we present our final solver as Algorithm 5.
|
| 113 |
+
|
| 114 |
+
Algorithm 2 judges whether a vertex is a splitting vertex of a closed set. This algorithm mainly follows the Definition 3 and uses vertex set to check the property of a splitting vertex. With this algorithm, we can judge whether a closed set is type 1 and get its division if it is. Suppose there are $N$ vertices in $s _ { i j }$ , the time complexity of Algorithm 2 is $\bar { O ( N ^ { 2 } ) }$ .
|
| 115 |
+
|
| 116 |
+
1: Let $\{ v _ { i n } \}$ be the vertices of all the vertices within $\left[ s _ { i j } \right]$ that have paths to $v _ { t }$ . Let $\{ v _ { o u t } \}$ be the vertices of all the vertices within $\left[ s _ { i j } \right]$ that have paths from $v _ { t }$ .
|
| 117 |
+
2: if $\{ v _ { i n } \} \cup \{ V _ { o u t } \} \cup \{ v _ { t } \} = \{ v | v \in \lbrack s _ { i j } ^ { - } \rbrack \}$ and $\{ v _ { i n } \} \cap \{ V _ { o u t } \} = \emptyset$ and $\mathcal { \nexists } v _ { 1 } \in \{ v _ { i n } \} , v _ { 2 } \in \{ v _ { o u t } \}$ , $v _ { 1 } , v _ { 2 }$ have connections then
|
| 118 |
+
3: Return true
|
| 119 |
+
4: else
|
| 120 |
+
5: Return False
|
| 121 |
+
|
| 122 |
+
Algorithm 3 examines whether a closed set is branched. It uses a growing algorithm to check whether an independent subpart of this closed set can form a closed set. If a non-trivial closed set $s _ { i j }$ has an edge from $v _ { i }$ to $v _ { j }$ , then it’s branched because this edge itself can be treated as a closed set. Combined with Algorithm 2, we can know the type of a closed set and get its division if it’s type 2. Suppose there are $N$ vertices in $s _ { i j }$ , the time complexity of Algorithm 3 is $O ( N ^ { 2 } )$ .
|
| 123 |
+
|
| 124 |
+
Algorithm 4 addresses the problem of finding the maximal split, the division of a closed set type $3 \ s _ { i j }$ . First get all the possible closed sets within $s _ { i j }$ and use a property of maximal split to judge whether this closed set is a member of the maximal split. The property is: there cannot exist another closed set $s _ { a b } \subsetneq s _ { i j }$ but contains any member of this maximal split. This property is proved in Lemma 6 of the appendix. Suppose there are $N$ vertices in $s _ { i j }$ , the time complexity of Algorithm 4 is $O ( N ^ { 4 } )$ .
|
| 125 |
+
|
| 126 |
+
Algorithm 5 is the solver for ACGs. First, the division tree of the computation graph is built. Similar to the linear solver, a max term list is formed by the cost of all the possible closed sets for traverse. Given a max term, we propose a greedy idea: for a closed set, never expand it unless the its cost exceed the max term. In other word, if the max term doesn’t allow a leap over this closed set, we expand it, otherwise, do not expand it. Because once expanded, some cost of other vertices inside this closed set might be introduced, and the cost will never be smaller than unexpanded. If some children of the closed set type 1 are expanded, the rest reforms a few linear segments and still can be solved by the linear solver. If some children of the closed set type 2 or 3 are expanded, the other
|
| 127 |
+
|
| 128 |
+
1: if $s _ { i j }$ has at least 1 vertex then
|
| 129 |
+
2: if $s _ { i j }$ includes an edge from $v _ { i }$ to $v _ { j }$ then
|
| 130 |
+
3: Return true
|
| 131 |
+
4: else
|
| 132 |
+
5: Initialize a vertex set $s = \{ v _ { k } \}$ . $v _ { k } \in s _ { i j }$ is a randomly chosen vertex.
|
| 133 |
+
6: while True do
|
| 134 |
+
7: For any $v _ { t } \in s _ { i j } , v _ { t } \notin s$ that has connection to any $v _ { k } \in s$ , add $v _ { t }$ to $s$ .
|
| 135 |
+
8: if No more vertex can be added to $s$ then
|
| 136 |
+
9: Break
|
| 137 |
+
10: if $s = \{ v \in s _ { i j } \}$ then
|
| 138 |
+
11: Return false
|
| 139 |
+
12: else
|
| 140 |
+
13: Return true
|
| 141 |
+
14: else
|
| 142 |
+
15: Return false
|
| 143 |
+
1: for each vertex pair $( v _ { k } , v _ { t } )$ except $( v _ { i } , v _ { j } )$ in $\left[ s _ { i j } \right]$ do
|
| 144 |
+
2: For all the vertices $\{ v \}$ that have paths from $v _ { k }$ and have paths to $v _ { t }$ .
|
| 145 |
+
3: if $\nexists v _ { 2 } \notin \{ v \}$ and $v _ { 2 } \neq v _ { k } , v _ { t } , v _ { 2 }$ has connection to a $v _ { 1 } \in \{ v \}$ then
|
| 146 |
+
4: Form a closed set $s _ { k t }$ with all these vertices.
|
| 147 |
+
5: for each formed closed set $s _ { k t }$ do
|
| 148 |
+
6: If there doesn’t exist a $s _ { a b }$ such that $s _ { k t } \subsetneq s _ { a b } \subsetneq s _ { i j }$ , put $s _ { k t }$ into the maximal split.
|
| 149 |
+
|
| 150 |
+
members remain unexpanded and need no changes. Suppose there are $N$ vertices in computation graph, the time complexity of Algorithm 5 is $\bar { O ( N ^ { 4 } ) }$ .
|
| 151 |
+
|
| 152 |
+
# Algorithm 5 Arbitrary Computation Graph (ACG) Solver
|
| 153 |
+
|
| 154 |
+
1: Get all possible closed set and their costs. Use their costs to form the max term list.
|
| 155 |
+
2: Reorganize the computation graph into a division tree: from the root node (the computation graph), build its children from its division, until all the leaf nodes are single tensors.
|
| 156 |
+
3: for each possible max term $m$ in max term list $\{ m \}$ do
|
| 157 |
+
4: if current closed set is type 1 then
|
| 158 |
+
5: For all the children that have cost larger than current max term. Expand them and solve the next level.
|
| 159 |
+
6: All the expanded children have separated the current closed set to linear segments. Solve all the linear segments with current max term.
|
| 160 |
+
7: else
|
| 161 |
+
8: For all the children that have cost larger than current max term. Expand them and solve the next level.
|
| 162 |
+
9: All the other members remain unexpanded.
|
| 163 |
+
10: Summarize the total loss, save the current solution if it’s better.
|
| 164 |
+
|
| 165 |
+
# 5 EXPERIMENT
|
| 166 |
+
|
| 167 |
+
We evaluated Re-forwarding on two main groups of neural networks (1) networks with linear structures, such as Alexnet (Krizhevsky et al. (2012)) and vgg series (Simonyan & Zisserman (2014)). (2) networks with non-linear structures, such as Resnet series (He et al. (2016)), Densenet series (Huang et al. (2017)) and Inception net (Szegedy et al. (2016)). For each network in Table 1, an computation graph is built such that every vertex is a Float32 tensor, every edge is an operation, and the memory cost of a vertex is its tensor size (measured in MB). We compared Re-forwarding with Chen (Chen et al. (2016)) and the regular training approach. Note that Chen et al. (2016) only worked on linear computation graphs. To compare with (Chen et al. (2016)) on non-linear networks, we manually re-organized all the non-linear computation graphs into linear computation graphs with their splitting vertices, and fed them to Chen et al. (2016) (see Table 1 “Chen et al. (2016) manual (MB)”). Our Re-forwarding approach directly works on arbitrary computation graphs. We have also included a customized network (“CustomNet”), on which even the manual version of Chen’s approach is not applicable. Our approach directly works on all networks. The computation graph of this network is visualized in the appendix.
|
| 168 |
+
|
| 169 |
+
Table 1: Training memory usage and time overhead of the regular, Chen et al. (2016), Chen et al. (2016) manual and Re-forwarding (ours) approach on linear and non-linear computation graph.
|
| 170 |
+
|
| 171 |
+
<table><tr><td rowspan="2">Linear network</td><td rowspan="2">Regular (MB)</td><td rowspan="2">Chen et al.(2016) (MB)</td><td rowspan="2">Re-forwarding (ours) (MB)</td><td rowspan="2">off (ours)</td><td rowspan="2">Memory CutRegular Training</td><td rowspan="2">Space Efficient Training Time (s)</td><td rowspan="2">Time Overhead</td></tr><tr><td>Time (s)</td></tr><tr><td>Alexnet batch 1024</td><td>3550</td><td>3108</td><td>2620</td><td>26%</td><td>1.295</td><td>1.816</td><td>40%</td></tr><tr><td>Vgg11 batch 64</td><td>2976</td><td>2292</td><td>1802</td><td>39%</td><td>0.606</td><td>0.819</td><td>35%</td></tr><tr><td>Vgg13 batch 64</td><td>4152</td><td>2586</td><td>2586</td><td>38%</td><td>1.020</td><td>1.333</td><td>31%</td></tr><tr><td>Vgg16 batch 64</td><td>4470</td><td>2894</td><td>2586</td><td>42%</td><td>1.307</td><td>1.696</td><td>30%</td></tr><tr><td>Vgg19 batch 64</td><td>4788</td><td>2894</td><td>2502</td><td>48%</td><td>1.593</td><td>2.060</td><td>29%</td></tr><tr><td rowspan="2">Non-linear network</td><td rowspan="2">Regular</td><td rowspan="2">Chen et al. (2016)</td><td rowspan="2">Re-forwarding</td><td rowspan="2">Memory Cut</td><td rowspan="2">Regular Training</td><td rowspan="2">Space Efficient</td><td rowspan="2">Time</td></tr><tr><td></td></tr><tr><td></td><td>(MB)</td><td>manual (MB)</td><td>(ours) (MB)</td><td>off (ours)</td><td>Time (s)</td><td>Training Time (s)</td><td>Overhead</td></tr><tr><td>Resnet18 batch 256</td><td>5402</td><td>2898</td><td>2898</td><td>46%</td><td>1.144</td><td>1.599</td><td>40%</td></tr><tr><td>Resnet34 batch 128</td><td>3900</td><td>1936</td><td>1544</td><td>60%</td><td>1.041</td><td>1.419</td><td>36%</td></tr><tr><td>Resnet50 batch 64</td><td>5206</td><td>2332</td><td>1798</td><td>65%</td><td>0.740</td><td>1.027</td><td>40%</td></tr><tr><td>Resnetl01 batch 32</td><td>3812</td><td>1216</td><td>970</td><td>75%</td><td>0.624</td><td>0.853</td><td>37%</td></tr><tr><td>Resnetl52 batch 16</td><td>2810 3984</td><td>636</td><td>564</td><td>80%</td><td>0.450</td><td>0.628</td><td>39%</td></tr><tr><td>Densenet121 batch 32 Densenet161 batch 16</td><td>3658</td><td>1012 744</td><td>776 616</td><td>81%</td><td>0.558</td><td>0.789</td><td>42%</td></tr><tr><td>Densenet169 batch 32</td><td>4826</td><td>998</td><td>848</td><td>83% 82%</td><td>0.511 0.714</td><td>0.708</td><td>39%</td></tr><tr><td>Densenet201 batch 16</td><td>3164</td><td>600</td><td>582</td><td>82%</td><td>0.449</td><td>1.022</td><td>43%</td></tr><tr><td>Inceptionv3 batch 32</td><td>2976</td><td>1026</td><td>910</td><td></td><td></td><td>0.651</td><td>45%</td></tr><tr><td></td><td></td><td></td><td></td><td>69%</td><td>0.563</td><td>0.763</td><td>35%</td></tr><tr><td>CustomNet batch 64</td><td>3233</td><td>Not Applicable</td><td>1353</td><td>58%</td><td>1.226</td><td>1.648</td><td>34%</td></tr></table>
|
| 172 |
+
|
| 173 |
+
All experiments were conducted in Pytorch. To remove irrelevant GPU memory cost, such as model and Pytorch CUDA interface cost, all training memory costs were measured with two different input sizes and compute the difference between two measurements. For example, to measure the memory cost of Alexnet with input size $[ B a t c h S i z e , C h a n n e l , W i d t h , H e i g h t ] = [ 1 6 , 3 , 2 2 4 , 2 2 4 ] .$ , we first record the training memory of input [16, 3, 224, 224] as $r _ { 1 }$ , and input [32, 3, 224, 224] as $r _ { 2 }$ . The actual memory cost given [16, 3, 224, 224] input is measured as $r _ { 2 } \mathrm { ~ - ~ } r _ { 1 }$ . To use existing DNN implementations, the input of Inception net is $[ B a t c h S i z e , 3 , 3 0 0 , 3 0 0 ]$ , and the input of all other networks is $[ B a t c h S i z e , 3 , 2 2 4 , 2 \bar { 2 4 } ]$ . We also measure the training time (time of 1 training iteration) for the regular approach and our approach. Each time is measured as the average of 20 iterations. Our approach has the same training time as Chen’s approach and its manual version, see “Space Efficient Training Time” in Table 1.
|
| 174 |
+
|
| 175 |
+
Table. 1 shows that Re-forwarding cuts down huge amount of memory from the regular approach at reasonable time overheads: $2 6 \%$ space off and $4 0 \%$ time overhead for Alexnet, around $4 0 \%$ space off and $4 0 \%$ time overhead for $\mathrm { V g g }$ series. For Resnet series, the deeper network, the more memory was cut down. On the deepest Resnet152, $8 0 \%$ space off was achieved with only $3 9 \%$ time overhead. For Densenet series, more than $8 0 \%$ space off was achieved with around $4 0 \%$ time overhead. Notice that, Chen et al. (2016) only works on linear networks. Its results on non-linear networks were manually synthesized. Re-forwarding directly works on non-linear networks and constantly outperformed Chen et al. (2016) and its “manual” version. This supports our claim that Re-forwarding is optimal.
|
| 176 |
+
|
| 177 |
+
# 6 CONCLUSION
|
| 178 |
+
|
| 179 |
+
Re-forwarding is a fundamental approach that explores trade-off between memory and computation power of GPUs. By saving tensors at a subset of layers during forward, and conducting extra local forwards for backward, Re-forwarding makes it possible to train very heavy DNNs with finite GPU memory. To our knowledge, our theoretical and algorithmic results are the first top-down work that achieve an optimal memory solution for arbitrary computation graphs in DNNs. Re-forwarding can be further embedded and optimized with any low-level techniques such as distributed computing, GPU/CPU swapping, computation graph optimization and liveness analysis.
|
| 180 |
+
|
| 181 |
+
# REFERENCES
|
| 182 |
+
|
| 183 |
+
Mart´ın Abadi, Ashish Agarwal, Paul Barham, Eugene Brevdo, Zhifeng Chen, Craig Citro, Greg S Corrado, Andy Davis, Jeffrey Dean, Matthieu Devin, et al. Tensorflow: Large-scale machine learning on heterogeneous distributed systems. arXiv preprint arXiv:1603.04467, 2016.
|
| 184 |
+
|
| 185 |
+
Alekh Agarwal and John C Duchi. Distributed delayed stochastic optimization. In Advances in Neural Information Processing Systems, pp. 873–881, 2011.
|
| 186 |
+
|
| 187 |
+
Alekh Agarwal, Olivier Chapelle, Miroslav Dud´ık, and John Langford. A reliable effective terascale linear learning system. The Journal of Machine Learning Research, 15(1):1111–1133, 2014.
|
| 188 |
+
|
| 189 |
+
Alfred V Aho, Ravi Sethi, and Jeffrey D Ullman. Compilers, principles, techniques. Addison Wesley, 7(8):9, 1986.
|
| 190 |
+
|
| 191 |
+
Fred´ eric Bastien, Pascal Lamblin, Razvan Pascanu, James Bergstra, Ian Goodfellow, Arnaud Berg- ´ eron, Nicolas Bouchard, David Warde-Farley, and Yoshua Bengio. Theano: new features and speed improvements. arXiv preprint arXiv:1211.5590, 2012.
|
| 192 |
+
|
| 193 |
+
James Bergstra, Olivier Breuleux, Fred´ eric Bastien, Pascal Lamblin, Razvan Pascanu, Guillaume ´ Desjardins, Joseph Turian, David Warde-Farley, and Yoshua Bengio. Theano: A cpu and gpu math compiler in python. In Proc. 9th Python in Science Conf, volume 1, 2010.
|
| 194 |
+
|
| 195 |
+
Tianqi Chen, Mu Li, Yutian Li, Min Lin, Naiyan Wang, Minjie Wang, Tianjun Xiao, Bing Xu, Chiyuan Zhang, and Zheng Zhang. Mxnet: A flexible and efficient machine learning library for heterogeneous distributed systems. arXiv preprint arXiv:1512.01274, 2015.
|
| 196 |
+
|
| 197 |
+
Tianqi Chen, Bing Xu, Chiyuan Zhang, and Carlos Guestrin. Training deep nets with sublinear memory cost. arXiv preprint arXiv:1604.06174, 2016.
|
| 198 |
+
|
| 199 |
+
Jeffrey Dean, Greg Corrado, Rajat Monga, Kai Chen, Matthieu Devin, Mark Mao, Andrew Senior, Paul Tucker, Ke Yang, Quoc V Le, et al. Large scale distributed deep networks. In Advances in neural information processing systems, pp. 1223–1231, 2012.
|
| 200 |
+
|
| 201 |
+
Kensho Hara, Hirokatsu Kataoka, and Yutaka Satoh. Learning spatio-temporal features with 3d residual networks for action recognition. In Proceedings of the ICCV Workshop on Action, Gesture, and Emotion Recognition, volume 2, pp. 4, 2017.
|
| 202 |
+
|
| 203 |
+
Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. Deep residual learning for image recognition. In Proceedings of the IEEE conference on computer vision and pattern recognition, pp. 770–778, 2016.
|
| 204 |
+
|
| 205 |
+
Gao Huang, Zhuang Liu, Kilian Q Weinberger, and Laurens van der Maaten. Densely connected convolutional networks. In Proceedings of the IEEE conference on computer vision and pattern recognition, volume 1, pp. 3, 2017.
|
| 206 |
+
|
| 207 |
+
Shuiwang Ji, Wei Xu, Ming Yang, and Kai Yu. 3d convolutional neural networks for human action recognition. IEEE transactions on pattern analysis and machine intelligence, 35(1):221–231, 2013.
|
| 208 |
+
|
| 209 |
+
Alex Krizhevsky, Ilya Sutskever, and Geoffrey E Hinton. Imagenet classification with deep convolutional neural networks. In Advances in neural information processing systems, pp. 1097–1105, 2012.
|
| 210 |
+
|
| 211 |
+
John Langford, Alexander J Smola, and Martin Zinkevich. Slow learners are fast. Advances in Neural Information Processing Systems, 22:2331–2339, 2009.
|
| 212 |
+
|
| 213 |
+
Ryan Mcdonald, Mehryar Mohri, Nathan Silberman, Dan Walker, and Gideon S Mann. Efficient large-scale distributed training of conditional maximum entropy models. In Advances in Neural Information Processing Systems, pp. 1231–1239, 2009.
|
| 214 |
+
|
| 215 |
+
Ryan McDonald, Keith Hall, and Gideon Mann. Distributed training strategies for the structured perceptron. In Human Language Technologies: The 2010 Annual Conference of the North American Chapter of the Association for Computational Linguistics, pp. 456–464. Association for Computational Linguistics, 2010.
|
| 216 |
+
|
| 217 |
+
Joseph Redmon and Ali Farhadi. Yolov3: An incremental improvement. CoRR, abs/1804.02767, 2018. URL http://arxiv.org/abs/1804.02767.
|
| 218 |
+
|
| 219 |
+
Shaoqing Ren, Kaiming He, Ross Girshick, and Jian Sun. Faster r-cnn: Towards real-time object detection with region proposal networks. In Advances in neural information processing systems, pp. 91–99, 2015.
|
| 220 |
+
|
| 221 |
+
Minsoo Rhu, Natalia Gimelshein, Jason Clemons, Arslan Zulfiqar, and Stephen W Keckler. vdnn: Virtualized deep neural networks for scalable, memory-efficient neural network design. In Microarchitecture (MICRO), 2016 49th Annual IEEE/ACM International Symposium on, pp. 1–13. IEEE, 2016.
|
| 222 |
+
|
| 223 |
+
Qinfeng Shi, James Petterson, Gideon Dror, John Langford, Alex Smola, Alex Strehl, and Vishy Vishwanathan. Hash kernels. In Artificial intelligence and statistics, pp. 496–503, 2009.
|
| 224 |
+
|
| 225 |
+
Zheng Shou, Jonathan Chan, Alireza Zareian, Kazuyuki Miyazawa, and Shih-Fu Chang. Cdc: convolutional-de-convolutional networks for precise temporal action localization in untrimmed videos. In 2017 IEEE Conference on Computer Vision and Pattern Recognition (CVPR), pp. 1417–1426. IEEE, 2017.
|
| 226 |
+
|
| 227 |
+
Karen Simonyan and Andrew Zisserman. Very deep convolutional networks for large-scale image recognition. arXiv preprint arXiv:1409.1556, 2014.
|
| 228 |
+
|
| 229 |
+
Bharat Singh, Hengduo Li, Abhishek Sharma, and Larry S. Davis. R-FCN-3000 at 30fps: Decoupling detection and classification. CoRR, abs/1712.01802, 2017. URL http://arxiv.org/ abs/1712.01802.
|
| 230 |
+
|
| 231 |
+
Christian Szegedy, Vincent Vanhoucke, Sergey Ioffe, Jon Shlens, and Zbigniew Wojna. Rethinking the inception architecture for computer vision. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pp. 2818–2826, 2016.
|
| 232 |
+
|
| 233 |
+
Linnan Wang, Jinmian Ye, Yiyang Zhao, Wei Wu, Ang Li, Shuaiwen Leon Song, Zenglin Xu, and Tim Kraska. Superneurons: Dynamic gpu memory management for training deep neural networks. arXiv preprint arXiv:1801.04380, 2018.
|
| 234 |
+
|
| 235 |
+
Dong Yu, Adam Eversole, Mike Seltzer, Kaisheng Yao, Zhiheng Huang, Brian Guenter, Oleksii Kuchaiev, Yu Zhang, Frank Seide, Huaming Wang, et al. An introduction to computational networks and the computational network toolkit. Microsoft Technical Report MSR-TR-2014–112, 2014.
|
| 236 |
+
|
| 237 |
+
Martin Zinkevich, Markus Weimer, Lihong Li, and Alex J Smola. Parallelized stochastic gradient descent. In Advances in neural information processing systems, pp. 2595–2603, 2010.
|
| 238 |
+
|
| 239 |
+
# A PROOF
|
| 240 |
+
|
| 241 |
+
A.1 LEMMAS
|
| 242 |
+
|
| 243 |
+
Lemma 1. If $s _ { i j } \cap s _ { k t } \neq \emptyset$ and $s _ { i j } \notin s _ { k t }$ and $s _ { k t } \notin s _ { i j }$ , then $s _ { i j } \cap s _ { k t } = s _ { k j }$ or $s _ { i j } \cap s _ { k t } = s _ { i t }$
|
| 244 |
+
|
| 245 |
+
Proof. Let $[ s _ { i j } ] \cap [ s _ { k t } ] = s = \{ v , e \}$ . Let $v _ { p }$ be the source vertex of $s$ , $v _ { q }$ be the target vertex of $s$ . If $v _ { p } \neq v _ { i }$ and $v _ { p } \ne v _ { k }$ and $v _ { q } \neq v _ { j }$ and $v _ { q } \ne v _ { t }$ , then $v _ { i } , v _ { k }$ has path to $v _ { p }$ and $v _ { j } , v _ { t }$ has path from $v _ { q }$ . Therefore, $v _ { p }$ has at least 2 immediate parents $v _ { a } , v _ { b }$ with $v _ { a } \in [ s _ { i j } ] , \bar { v _ { a } } \notin [ \bar { s _ { k t } } ] , v _ { b } \in [ s _ { k t } ] , v _ { b } \notin$ $\left[ s _ { i j } \right]$ . If so, the independence of $s _ { i j }$ and $s _ { k t }$ is violated. Therefore, $v _ { p }$ must be $v _ { i }$ or $v _ { k }$ .
|
| 246 |
+
|
| 247 |
+
Same on $v _ { q } , v _ { q }$ must be $v _ { j }$ or $v _ { t }$
|
| 248 |
+
|
| 249 |
+
If $v _ { p } = v _ { i } , v _ { q } = v _ { j }$ , then $s _ { i j } \subset s _ { k t }$ . If $v _ { p } = v _ { k } , v _ { q } = v _ { t }$ , then $s _ { k t } \subset s _ { i j }$ . Therefore, $v _ { p } = v _ { i } , v _ { q } = v _ { t }$ or $v _ { p } = v _ { k } , v _ { q } = v _ { j }$ . Suppose $v _ { p } = v _ { k } , v _ { q } = v _ { j }$ , let’s prove $s$ is a closed set.
|
| 250 |
+
|
| 251 |
+
With $s \subset s _ { k t }$ , $\forall v _ { 1 } \in s$ , $v _ { 1 }$ has no edge with $v _ { 2 } \notin [ s _ { k t } ]$ . With $s \subset s _ { i j } , \forall v _ { 1 } \in s , v _ { 1 }$ has no edge with $v _ { 2 } \notin [ s _ { i j } ]$ . Therefore, $\forall v _ { 1 } \in s$ , $v _ { 1 }$ has no edge with $\bar { v _ { 2 } } \notin [ s ]$ . The independence of $s$ is guaranteed.
|
| 252 |
+
|
| 253 |
+
In the discussion before, we can see the source vertex $v _ { p }$ of $s$ must be either $v _ { i }$ or $v _ { k }$ . If $v _ { i }$ and $v _ { k }$ are both the source vertices of $s$ , then $v _ { i } \in [ s _ { k t } ]$ and $v _ { k } \in [ s _ { i j } ]$ , $v _ { i }$ has path to $v _ { k }$ and $v _ { k }$ has path to $v _ { i }$ , which will force $v _ { i } = v _ { k }$ because the $s _ { i j }$ , $s _ { k t }$ is acyclic. Same on $v _ { q }$ , $s$ can only have 1 source vertex and 1 target vertex. Therefore, $s$ is closed set.
|
| 254 |
+
|
| 255 |
+
Therefore, $s _ { i j } \cap s _ { k t } = s _ { k j }$ or $s _ { i j } \cap s _ { k t } = s _ { i t }$
|
| 256 |
+
|
| 257 |
+
Lemma 2. The intersection of two closets $s = s _ { i } \cap s _ { j } \neq \emptyset$ is also a closet
|
| 258 |
+
|
| 259 |
+
Proof. Given the independence of $s _ { i }$ and $s _ { j }$ , the independence of $s$ is obvious. The remaining thing is whether $s$ only has 1 source vertex and 1 target vertex. In the proof of Lemma 1, we can see any source or target vertex of $s$ will eventually become source or target vertex of $s _ { i }$ and $s _ { j }$ . With simple discussion, we can have this lemma. □
|
| 260 |
+
|
| 261 |
+
Lemma 3. If $s _ { i j } \cap s _ { k t } = s _ { k j } \neq \emptyset$ , then $v _ { k }$ is the splitting vertex of $s _ { i j }$ and $v _ { j }$ is the splitting vertex of $s _ { k t }$
|
| 262 |
+
|
| 263 |
+
Proof. Let’s first prove that $v _ { k }$ is the splitting vertex of $s _ { i j }$
|
| 264 |
+
|
| 265 |
+
Let $s = s _ { i j } - \left[ s _ { k j } \right)$ . Obviously, $s _ { i j } = s \cup s _ { k j } \cup \{ v _ { k } \}$ and $s \cap s _ { k j } = \emptyset$ . We only need to prove that $s$ is closed set. For convenience, let’s denote $[ \bar { s } ] = s \cup \{ v _ { i } , v _ { k } \}$
|
| 266 |
+
|
| 267 |
+
$v _ { i }$ is obviously the only source vertex of $[ s ]$ because $v _ { i }$ is source vertex of $\left[ s _ { i j } \right]$ . We discuss the target vertex here. If $v _ { k }$ is not the target vertex of $[ s ]$ , as $v _ { k } \in [ s ]$ , $v _ { k }$ must have path to the target vertex $v$ of [s] and $v$ also has path to $v _ { j }$ as $v \in s _ { i j }$ . Because $v \notin [ s _ { k j } ]$ , in the path from $v$ to $v _ { j }$ , there exists an edge that connects a vertex $v _ { 1 } \in s$ with a vertex $v _ { 2 } \in s _ { k t }$ which violates the independence of $s _ { k t }$ . Therefore, the target vertex of [s] can only be $v _ { k }$ .
|
| 268 |
+
|
| 269 |
+
As $s \subset [ s _ { i j } )$ , $\forall v _ { 1 } \in s$ , $v _ { 1 }$ has no edge with $v _ { 2 } \notin [ s _ { i j } )$ . As $s _ { k j }$ is close, $\forall v _ { 1 } \in s , v _ { 1 }$ has no edge with $v _ { 2 } \in s _ { k j }$ . $\forall v _ { 1 } \in s$ , $v _ { 1 }$ can only have edge with $v _ { 2 } \in [ s ]$ . Thus the independence of $s$ is guaranteed. Therefore, $s$ is closed set, $v _ { k }$ is the splitting vertex of $s _ { i j }$ .
|
| 270 |
+
|
| 271 |
+
Same on $v _ { j } , v _ { j }$ is the splitting vertex of $s _ { k t }$
|
| 272 |
+
|
| 273 |
+
Lemma 4. If $s _ { i j }$ has $n$ splitting vertices $\{ v _ { 1 } , v _ { 2 } , . . . , v _ { n } \}$ , then $s _ { i j } ~ = ~ s _ { i 1 } \cup s _ { 1 2 } \cup \ldots \cup s _ { n j } \cup$ $\{ v _ { 1 } , v _ { 2 } , . . . , v _ { n } \}$
|
| 274 |
+
|
| 275 |
+
Proof. If $n = 2$ , the splitting vertices are $v _ { 1 } , v _ { 2 }$ , $s _ { i j } = s _ { i 1 } \cup s _ { 1 j } \cup \{ v _ { 1 } \} = s _ { i 2 } \cup s _ { 2 j } \cup \{ v _ { 2 } \}$ . Let $v _ { 1 } \in s _ { i 2 } , v _ { 1 } \neq v _ { 2 }$ , then $s _ { 1 j } \cap s _ { i 2 } = s _ { 1 2 } \neq \emptyset$ . According to Lemma 3, $v _ { 1 }$ is splitting vertex of $s _ { i 2 }$ and $v _ { 2 }$ is splitting vertex of $s _ { 1 j }$ . Therefore, $s _ { i j } = s _ { i 1 } \cup s _ { 1 2 } \cup s _ { 2 j } \cup \{ v _ { 1 } , v _ { 2 } \}$ .
|
| 276 |
+
|
| 277 |
+
For $n > 2$ , the lemma can be proved by repetitively using the conclusion in $n = 2$ .
|
| 278 |
+
|
| 279 |
+
Lemma 5. If the non-branched $s _ { i j }$ has a maximal split $\{ [ s _ { p q } ] \}$ , and $| \{ [ s _ { p q } ] \} | > 2$ , denote $\{ v \}$ as all the endpoint vertices of $[ s ] \in \{ [ s _ { p q } ] \}$ . Then $\forall v \in \{ v \} , v \neq v _ { i } , v _ { j }$ , $v$ is the endpoint vertex of at least 3 members of the maximal split.
|
| 280 |
+
|
| 281 |
+
Proof. If $v _ { b }$ is the endpoint vertex of only 2 members of the maximal split, suppose the 2 members are $s _ { a b }$ and $s _ { b c }$ . If so, $s _ { a b }$ and $s _ { b c }$ can be merged into $s _ { a c }$ . If $s _ { a c } \neq s _ { i j }$ , this violates the definition of maximal split. Otherwise, it violates the condition that $s _ { i j }$ is non-branched and $| \{ [ s _ { p q } ] \} | > 2$ . It is impossible that the 2 members are $s _ { a b }$ and $s _ { c b }$ because in this way $v _ { b }$ has no path to $v _ { j }$ and violates the definition of closed set. If $v _ { b }$ is the endpoint vertex of only 1 member of the maximal split, then $v _ { b }$ must be either $v _ { i }$ or $v _ { j }$ . Therefore, this lemma is proved.
|
| 282 |
+
|
| 283 |
+
Lemma 6. Any member of a maximal split can not be the subset of another closed set $s \subsetneq s _ { i j }$
|
| 284 |
+
|
| 285 |
+
Proof. Suppose the source vertex of $s$ is $v _ { 1 }$ and target vertex is $v _ { 2 }$ , a member $s _ { x y }$ of the maximal split is inside $s$ .
|
| 286 |
+
|
| 287 |
+
Suppose a member $s _ { a b }$ of the maximal split has its source vertex $v _ { a }$ inside $s$ and target vertex $v _ { b }$ outside $s$ . Then the boundary vertex (the vertex that has edges to the non-overlapping parts of both sets) must be $v _ { 2 }$ , otherwise the independence of $s$ will be violated. Notice that $v _ { 2 }$ is inside $s _ { a b }$ and the independence of $s _ { a b }$ needs to be guaranteed, for $\forall v _ { p } \in s , v _ { p } \notin s \cap s _ { a b } , v _ { q } \in s \cap s _ { a b } ,$ $v _ { p }$ has no edge with $v _ { q }$ . Therefore, $v _ { a }$ is a splitting vertex of $s$ .
|
| 288 |
+
|
| 289 |
+
Similarly, if $s _ { b a }$ has its target vertex $v _ { a }$ inside $s$ and source vertex $v _ { b }$ outside $s$ , the boundary vertex must be $v _ { 1 }$ and $v _ { a }$ is a splitting vertex of $s$ .
|
| 290 |
+
|
| 291 |
+
For the closed set $s$ , from the discussion above, we know that there are at most 2 members of the maximal split that can overlap with $s$ . Other members must be either completely inside $s$ or completely outside $s$ . Let’s discuss the number of members that overlaps with $s$ .
|
| 292 |
+
|
| 293 |
+
If there are 0 member that overlaps with $s$ , $s$ is the union of a subset of members of the maximal split, which violates the definition of maximal split.
|
| 294 |
+
|
| 295 |
+
If there is 1 member that overlaps with $s$ , suppose the corresponding splitting vertex is $v _ { b }$ , and the boundary vertex is actually $v _ { 2 }$ . Then $s _ { 1 b }$ is a closed set containing $s _ { x y }$ and corresponds to the situation of 0 member overlapping. $s _ { 1 b }$ is the union of a subset of members of the maximal split, and violates the definition of maximal split.
|
| 296 |
+
|
| 297 |
+
If there are 2 members that overlaps with $s$ , suppose they generate two different splitting vertex $v _ { a }$ and $v _ { b }$ . Then $s _ { a b }$ is a closed set containing $s _ { x y }$ and corresponds to the situation of 0 member overlapping. $s _ { a b }$ is the union of a subset of members of the maximal split, and violates the definition of maximal split.
|
| 298 |
+
|
| 299 |
+
If they generate the same splitting vertex $v _ { b }$ , from lemma 5, $v _ { b }$ is also the endpoint vertex of at least 1 other member $s _ { a b }$ which has to be inside $s$ . Suppose the two overlapping members are $s _ { c b }$ that contains $v _ { 1 }$ , and $s _ { b d }$ that contains $v _ { 2 }$ . As the source vertex of $s$ , $v _ { 1 }$ has path to $v _ { b }$ and $v _ { 1 }$ has path to $v _ { a }$ , which implies $v _ { b }$ has path to $v _ { a }$ . As the target vertex of $s$ , $v _ { 2 }$ has path from $v _ { b }$ and $v _ { 2 }$ has path from $v _ { a }$ , which implies $v _ { b }$ has path from $v _ { a }$ . This conflicts with the fact that $s$ is acyclic. Therefore, this case is not possible.
|
| 300 |
+
|
| 301 |
+
Therefore, this lemma is proved.
|
| 302 |
+
|
| 303 |
+
Lemma 7. If non-branched $s _ { i j }$ has at least 1 vertex but has 0 splitting vertex, then its maximal split has length $> 2$
|
| 304 |
+
|
| 305 |
+
Proof. As $s _ { i j }$ is not branched, the members of its maximal split cannot have the starting vertex as $v _ { i }$ and the ending vertex as $v _ { j }$ at the same time. If $s _ { i j }$ has at least 1 vertex, and its maximal split has length 2, then its maximal split must be $\{ [ s _ { i k } ] , [ s _ { k j } ] \}$ , and $v _ { k }$ will be the splitting vertex of $s _ { i j }$ , which violates that $s _ { i j }$ has no splitting vertex.
|
| 306 |
+
|
| 307 |
+
If $s _ { i j }$ has at least 1 vertex without splitting vertex, it has at least 2 edges and cannot have a trivial length 1 maximal split. Therefore, its maximal split has length $> 2$ □
|
| 308 |
+
|
| 309 |
+
# A.2 UNIQUENESS OF DIVISION TREE
|
| 310 |
+
|
| 311 |
+
To prove this uniqueness, we simply discuss the division uniqueness of closed set type 1, 2 and 3.
|
| 312 |
+
|
| 313 |
+
A.2.1 UNIQUENESS OF DIVISION OF CLOSED SET TYPE 1
|
| 314 |
+
|
| 315 |
+
Proof. By the definition of this division and Lemma 4, the uniqueness of the division is equivalent to the uniqueness of the splitting vertex set of a closed set type 1. The splitting vertex set is obviously unique. □
|
| 316 |
+
|
| 317 |
+
# A.2.2 UNIQUENESS OF DIVISION OF CLOSED SET TYPE 2
|
| 318 |
+
|
| 319 |
+
Proof. If there exists another division, there must be a branch member $s _ { i j } ^ { 1 }$ in division 1 and a branch member $s _ { i j } ^ { 2 }$ in division 2, where $s _ { i j } ^ { 1 } \cap s _ { i j } ^ { 2 } \neq \emptyset$ and $s _ { i j } ^ { 1 } \neq s _ { i j } ^ { 2 }$ .
|
| 320 |
+
|
| 321 |
+
Denote $s = s _ { i j } ^ { 1 } \cap s _ { i j } ^ { 2 }$ . By Lemma 1 and 2, $s = s _ { i j } ^ { 3 }$ is also a closed set. As $s _ { i j } ^ { 1 }$ and $s _ { i j } ^ { 2 }$ cannot be divided into more branches, $s = s _ { i j } ^ { 1 } = s _ { i j } ^ { 2 }$ . Therefore, the division of closed set type 2 is unique.
|
| 322 |
+
|
| 323 |
+
# A.2.3 UNIQUENESS OF DIVISION OF CLOSED SET TYPE 3
|
| 324 |
+
|
| 325 |
+
Proof. As the closed set in the division tree has at least 1 vertex, with Lemma 7, we know that the division, i.e. maximal split of a closed set type $3 \ s _ { i j }$ within the division tree will have length $> 2$ . Denote this maximal split as $\{ [ s _ { p q } ] \}$ , we only need to prove this maximal split is unique.
|
| 326 |
+
|
| 327 |
+
Suppose there is a another different maximal split $\{ [ s _ { p q } ^ { \prime } ] \}$ , let us only check the difference between $\{ [ s _ { p q } ] \}$ and $\{ [ s _ { p q } ^ { \prime } ] \}$ . Denote $\{ [ s _ { k t } ] \}$ and $\{ [ s _ { k t } ^ { \prime } ] \}$ with $\{ [ s _ { p q } ] \} - \{ [ s _ { k t } ] \} = \{ [ s _ { p q } ^ { \prime } ] \} - \{ [ s _ { k t } ^ { \prime } ] \}$ and $\mathbb { A } s \in \{ [ s _ { k t } ] \} , \dot { s ^ { \prime } } \in \{ [ s _ { k t } ^ { \prime } ] \} , s = s ^ { \prime }$ . As $\{ [ s _ { p q } ] \} - \{ [ s _ { k t } ] \} = \{ [ s _ { p q } ^ { \prime } ] \} - \{ [ s _ { k t } ^ { \prime } ] \}$ , we have $\cup \{ [ s _ { k t } ] \} =$ $\cup \{ [ s _ { k t } ^ { \prime } ] \}$
|
| 328 |
+
|
| 329 |
+
Obviously, $| \{ [ s _ { k t } ] \} | \ge 2$ and $| \{ [ s _ { k t } ^ { \prime } ] \} | \ge 2$ . Denote $\{ v \}$ as all the endpoint vertices of $[ s ] \in \{ [ s _ { k t } ] \}$ , and $\{ v ^ { \prime } \}$ for $\{ [ s _ { k t } ^ { \prime } ] \}$ . Obviously $\{ v \} \neq \emptyset$ and $\{ v ^ { \prime } \} \ne \bar { \emptyset }$ . As $s _ { i j }$ is non-branched, $\{ v \} \cup \{ v _ { i } , v _ { j } \} -$ $\{ v _ { i } , v _ { j } \} \neq \emptyset$ and $\{ v ^ { \prime } \} \cup \{ v _ { i } , v _ { j } \} - \{ v _ { i } , v _ { j } \} \neq \emptyset$ .
|
| 330 |
+
|
| 331 |
+
Suppose $s _ { a b }$ $, s _ { b c } \in \{ [ s _ { k t } ] \}$ , according to Lemma 5, there’s at least 1 other member that has $v _ { b }$ as endpoint vertex. Suppose the other endpoint of this member is $v _ { d }$ . Let’s discuss whether $v _ { b } \in \{ v ^ { \prime } \}$ and whether $v _ { d } \in \cup \{ [ s _ { k t } ] \}$ .
|
| 332 |
+
|
| 333 |
+
If $v _ { d } \not \in \cup \{ [ s _ { k t } ] \}$ , then $v _ { b }$ must occur in $\{ v ^ { \prime } \}$ . Otherwise, $v _ { b }$ would be inside a closed set which would be violated by $v _ { d }$ . Given $v _ { b } \in \{ v ^ { \prime } \}$ , as $s _ { a b } \notin \{ [ s _ { k t } ^ { \prime } ] \}$ , suppose $s _ { e b } \in \{ [ s _ { k t } ^ { \prime } ] \}$ and $s _ { a b } \cap s _ { e b } \neq \emptyset$ . If $v _ { a } \in s _ { e b }$ , from Lemma 1, $s _ { e b }$ cannot be close. If $v _ { e } \in s _ { a b }$ , from Lemma 5, $s _ { a b }$ cannot be close. In this case, there cannot exist another different maximal split.
|
| 334 |
+
|
| 335 |
+
If $v _ { d } \in \cup \{ [ s _ { k t } ] \}$ , then $s _ { b d } \in \{ \left[ s _ { k t } \right] \}$ . If $v _ { b } \in \{ v ^ { \prime } \}$ , we can use the same logic above to show this is impossible. Therefore, $v _ { b } \notin \{ v ^ { \prime } \}$ and $s _ { b d }$ is included by a closed set $s$ . From Lemma 6, this is impossible. In this case, there cannot exist another different maximal split.
|
| 336 |
+
|
| 337 |
+
In all the cases, there cannot exist another different maximal split. Therefore, the maximal split is unique. □
|
| 338 |
+
|
| 339 |
+
# A.3 COMPLETENESS OF DIVISION TREE
|
| 340 |
+
|
| 341 |
+
Similar with the uniqueness, the completeness of division tree is equivalent to the completeness of the division of a closed set. To prove this completeness, we simply discuss the division completeness of closed set type 1, 2 and 3.
|
| 342 |
+
|
| 343 |
+
An equivalent statement of the division completeness is: there doesn’t exist a closed set whose head is in one member of the division and whose tail is in another member of the division.
|
| 344 |
+
|
| 345 |
+
# A.3.1 COMPLETENESS OF DIVISION OF CLOSED SET TYPE 1
|
| 346 |
+
|
| 347 |
+
Proof. Suppose there exists a closed set $s$ whose head $v _ { p }$ is in one member $s _ { 1 }$ and whose tail $v _ { q }$ is in another member $s _ { 2 }$ .
|
| 348 |
+
|
| 349 |
+
If $v _ { p }$ is not an endpoint of $s _ { 1 }$ , then according to Lemma 3, $v _ { p }$ is also a splitting vertex in $s _ { 1 }$ and can break $s _ { 1 }$ into smaller segments, which makes $v _ { p }$ also the splitting vertex of the whole closed set. However, $v _ { p }$ is not the splitting vertex of the whole closed set $s _ { i j }$ . This also applies to $v _ { q }$ . Therefore, the division of closed set type 1 is complete. □
|
| 350 |
+
|
| 351 |
+
# A.3.2 COMPLETENESS OF DIVISION OF CLOSED SET TYPE 2
|
| 352 |
+
|
| 353 |
+
Proof. Suppose there exists a closed set $s$ whose head $v _ { p }$ is in one branch $s _ { i j } ^ { 1 }$ and whose tail $v _ { q }$ is in another branch $s _ { i j } ^ { 2 }$ . As $s$ crosses $s _ { i j } ^ { 1 }$ and $s _ { i j } ^ { 2 }$ , there exists a boundary vertex $v$ in $s$ , which belongs to $[ s _ { i j } ^ { 1 } ]$ and has direct connection with a vertex outside $[ s _ { i j } ^ { 1 } ]$ . If $v$ is not $v _ { i }$ or $v _ { j }$ , it will violate the independence of $s _ { i j }$ . If $v = v _ { i }$ , as $v _ { i }$ is the head of both $s _ { i j } ^ { 1 }$ and $s _ { i j } ^ { 2 }$ , it cannot be the boundary vertex, same when $v = v _ { j }$ . Therefore, there cannot exist such a closed set $s$ . The division of closed set type 2 is complete. □
|
| 354 |
+
|
| 355 |
+
# A.3.3 COMPLETENESS OF DIVISION OF CLOSED SET TYPE 3
|
| 356 |
+
|
| 357 |
+
Proof. Suppose there exists a closed set $s$ whose head $v _ { p }$ is in one member $s _ { 1 }$ and whose tail $v _ { q }$ is in another member $s _ { 2 }$ . Same with closed set type 2, the boundary vertex $v$ has to be the endpoint vertex of $s _ { 1 }$ or the independence of $s _ { 1 }$ will be violated. According to Lemma 5, $v$ is the endpoint vertex of at least 3 members, meaning that $v$ will at least have 1 connection with another closed set $s _ { 3 }$ . To maintain the independence of $s$ , $s$ has to include $s _ { 3 }$ as well. However, $s _ { 3 }$ also has its endpoints. This will propagate until $s$ becomes the whole closed set. Therefore, there cannot exist such a closed set $s$ . The division of closed set type 3 is complete. □
|
| 358 |
+
|
| 359 |
+
# B COMPLEXITY ANALYSIS
|
| 360 |
+
|
| 361 |
+
# B.1 ALGORITHM 1
|
| 362 |
+
|
| 363 |
+
Suppose there are $N$ vertices in the computation graph. There are $O ( N ^ { 2 } )$ vertex pairs. For each vertex pair, the time cost is mainly on constructing accessibility graph and finding the shortest path. Denote the source vertex of the whole computation graph as $v _ { 0 }$ . To construct an accessibility graph, first we traverse the linear computation graph, record the accumulated sum $l ( v _ { 0 } , v _ { i } )$ for each vertex $v _ { i }$ , and form a table of $l ( v _ { i } , v _ { j } ) { \ ' } = l ( v _ { 0 } , { \bar { v } } _ { j } ) { \ ' } - l ( v _ { 0 } , v _ { i } ) - l ( v _ { i } )$ . These steps will cost $O ( N ^ { 2 } )$ . Then we traverse each $( v _ { i } , v _ { j } )$ pair to form the edges of the accessibility graph, which also cost $O ( N ^ { 2 } )$ . Solving the shortest path problem in accessibility graph will also cost $O ( N ^ { 2 } )$ as the accessibility graph has $N$ vertices. Therefore, the overall time complexity of Algorithm 1 would be $O ( N ^ { 4 } )$ .
|
| 364 |
+
|
| 365 |
+
The space complexity would be $O ( N ^ { 2 } )$ for the table of $l ( v _ { i } , v _ { j } )$ and the accessibility graph itself.
|
| 366 |
+
|
| 367 |
+
# B.2 ALGORITHM 2
|
| 368 |
+
|
| 369 |
+
Suppose there are $N$ vertices in the closed set $s _ { i j }$ . In step 1, getting $\{ v _ { i n } \}$ and $\{ v _ { o u t } \}$ will cost $O ( N )$ time for traversing the ancestors and descendents of $v _ { t }$ . In our implementation, an array $a$ of length $N$ is used to represent $\{ v _ { i n } \}$ and $\{ v _ { o u t } \}$ : $a _ { i } = 1$ indicates $v _ { i } \in \overline { { \{ v _ { i n } \} } }$ , $a _ { i } = 2$ indicates $v _ { i } \in \{ v _ { o u t } \}$ and $a _ { i } = 0$ indicates $v _ { i } \notin \{ v _ { i n } \} \cup \{ v _ { o u t } \}$ . Then the union check and intersection check in step 2 can be done in $O ( N )$ . The connection check in step 2 traverses the edges and costs $O ( N ^ { 2 } )$ . Other steps are $O ( 1 )$ . Therefore, the overall time complexity of Algorithm 2 would be $O ( N ^ { 2 } )$ .
|
| 370 |
+
|
| 371 |
+
The space complexity would be $O ( N )$ for the array to represent $\{ v _ { i n } \}$ and $\{ v _ { o u t } \}$
|
| 372 |
+
|
| 373 |
+
# B.3 ALGORITHM 3
|
| 374 |
+
|
| 375 |
+
Suppose there are $N$ vertices in the closed set $s _ { i j }$ . The most time consuming part will be from step 5 to step 13. Other steps are $O ( 1 )$ . In step 5 to step 13, every edge between two vertices in $s _ { i j }$ is at most visited once and there are $O ( N ^ { 2 } )$ edges. Therefore, the overall time complexity of Algorithm 3 would be $O ( N ^ { 2 } )$ .
|
| 376 |
+
|
| 377 |
+
In our implementation, an array of length $N$ is used to represent the vertex set $s = \{ v _ { k } \}$ . Therefore, the space complexity would be $O ( N )$ .
|
| 378 |
+
|
| 379 |
+
# B.4 ALGORITHM 4
|
| 380 |
+
|
| 381 |
+
Suppose there are $N$ vertices in the closed set $s _ { i j }$ and there are $O ( N ^ { 2 } )$ vertex pairs. For each vertex pair, the connection check in step 2-4 will cost $O ( N ^ { 2 } )$ , similar to the connection check in Algorithm 2. Thus step 1-4 will cost $O ( N ^ { 4 } )$ . In our implementation, for each vertex in the closed set $s _ { i j }$ , we select the largest formed closed set $s _ { k t }$ that contains this vertex. The closed set number is then reduced to $O ( N )$ and step 5-6 can be done in $O ( N ^ { 3 } )$ . Therefore, the overall time complexity of Algorithm 4 would be $O ( N ^ { 4 } )$
|
| 382 |
+
|
| 383 |
+
As $O ( N ^ { 2 } )$ closed sets can be formed in step 1-4 and each closed set is a smaller DAG with $O ( N )$ vertices and cost $O ( N ^ { 2 } )$ space, the space complexity would be $O ( N ^ { 4 } )$ for all these closed sets.
|
| 384 |
+
|
| 385 |
+
# B.5 ALGORITHM 5
|
| 386 |
+
|
| 387 |
+
Step 1 is similar to step 1-4 in Algorithm 4 with $s _ { i j }$ being the whole computation graph. Therefore, the overall time complexity for step 1 is $O ( N ^ { 4 } )$ .
|
| 388 |
+
|
| 389 |
+
In step 2, the complexity of building division tree is related to the complexity of getting the division of a closed set. For closed set type 1, Algorithm 2 is called for each vertex to get all splitting vertices. Thus getting the division of closed set type 1 cost $O ( N ^ { 3 } )$ time. For closed set type 2, Algorithm 3 is used to solve for its division and costs $O ( N ^ { 2 } )$ time. For type 3, Algorithm 4 is called to solve for its division. Notice that we have already stored all possible closed sets in step 1, step 1-4 in Algorithm 4 can be skipped and thus the time complexity of getting the division of closed set type 3 is reduced to $O ( N ^ { 3 } )$ . Therefore, getting the division of an arbitrary closed set costs $O ( N ^ { 3 } )$ time. In depth $i$ of the division tree, suppose there are $k$ closed sets, and the number of vertices of $j$ th closed sets is $a _ { j }$ . To build depth $i + 1$ of the division tree, we need to get the division of all these closed sets, which will cost $\textstyle \sum _ { j } O ( a _ { j } ^ { 3 } )$ . As $\textstyle \sum _ { j } a _ { j } \leq N$ , we have $\begin{array} { r } { \sum _ { j } O ( a _ { j } ^ { 3 } ) \le O ( N ^ { 3 } ) } \end{array}$ . As the depth of division tree is at most $N$ , the overall time complexity of step 2 would be $O ( N ^ { 4 } )$ .
|
| 390 |
+
|
| 391 |
+
For step 3-10, if the computation graph is linear, the ACG solver will reduce to LCG solver and has complexity $O ( N ^ { 4 } )$ . If the computation graph is non-linear, the length of $\{ m \}$ would be $O ( N ^ { 2 } )$ for there are $O ( N ^ { 2 } )$ vertex pair. For a max term $m$ , from step 4-10, the actual time costing part will be step 6 which calls the LCG solver, and other steps would be $O ( 1 )$ . Suppose the LCG solver is called $k$ times, solving problems of $a _ { 1 } , a _ { 2 } , . . . , a _ { k }$ vertices. The total complexity of this would be $O ( a _ { 1 } ^ { 4 } ) + O ( a _ { 2 } ^ { 4 } ) + \ldots + \bar { O } ( a _ { k } ^ { 4 } )$ . Notice that $a _ { 1 } + a _ { 2 } + \ldots + a _ { k } \leq N$ for the fact that any vertex in the computation graph would not be solved twice by LCG solver, we have $a _ { 1 } ^ { 4 } + a _ { 2 } ^ { 4 } + \ldots + a _ { k } ^ { 4 } \leq N ^ { 4 }$ . Therefore the time complexity of step 3-10 is ${ \cal O } \dot { ( } N ^ { 4 } )$ .
|
| 392 |
+
|
| 393 |
+
Step 1 would cost $O ( N ^ { 4 } )$ space to store all the possible closed sets. Step 2 would cost $O ( N ^ { 2 } )$ space for the division tree. Step 3-10 would cost $\dot { O } ( N ^ { 2 } )$ space for calling LCG solver.
|
| 394 |
+
|
| 395 |
+
In conclusion, the overall time complexity of Algorithm 5 is $O ( N ^ { 4 } )$ and the overall space complexity of Algorithm 5 is $O ( N ^ { 4 } )$ .
|
| 396 |
+
|
| 397 |
+
Table 2: Actual Runtime of ACG Solver and Theoretical Analysis
|
| 398 |
+
|
| 399 |
+
<table><tr><td>Linear network</td><td>Number of vertices</td><td>Runtime (s)</td><td>Measured Memory Cutoff</td><td>TheoreticalMemory Cutoff</td></tr><tr><td>Alexnet Vgg11</td><td>12 17</td><td>0.03 0.09</td><td>26% 39%</td><td>42% 50%</td></tr><tr><td>Vgg13 Vgg16</td><td>19 22</td><td>0.15 0.26</td><td>38% 42%</td><td>47%</td></tr><tr><td>Vgg19</td><td>25</td><td>0.44</td><td>48%</td><td>51%</td></tr><tr><td>Non-linear networkNumber of vertices</td><td></td><td>Runtime (s)</td><td>Measured Memory Cutoff</td><td>53%</td></tr><tr><td>Resnet18 Resnet34</td><td>51 91</td><td>0.09</td><td>46%</td><td>TheoreticalMemory Cutoff 63%</td></tr><tr><td>Resnet50</td><td>125</td><td>0.53 1.27</td><td>60% 65%</td><td>73% 75%</td></tr><tr><td>Resnet101 Resnet152</td><td>244</td><td>12.40</td><td>75%</td><td>81%</td></tr><tr><td>Densenet121</td><td>363 306</td><td>59.34 293.75</td><td>80%</td><td>84%</td></tr><tr><td>Densenet161</td><td>406</td><td>1537.82</td><td>81%</td><td>81%</td></tr><tr><td>Densenet169</td><td>426</td><td>2356.47</td><td>83% 82%</td><td>84%</td></tr><tr><td>Densenet201</td><td>506</td><td>7335.35</td><td>82%</td><td>84%</td></tr><tr><td>Inceptionv3</td><td>219</td><td>7.68</td><td>69%</td><td>86%</td></tr><tr><td>Custom</td><td>35</td><td>0.05</td><td>58%</td><td>76% 68%</td></tr></table>
|
| 400 |
+
|
| 401 |
+
# C RUNTIME AND THEORETICAL ANALYSIS
|
| 402 |
+
|
| 403 |
+
The number of vertices in the computation graph and the runtime of ACG Solver (Algorithm 5) for each network are listed in Table 2. All the runtimes were measured on a single core of CPU i7-8700.
|
| 404 |
+
|
| 405 |
+
Notice that the runtime is measured on only 1 cpu core, it can be massively reduced by parallelization on multiple cpu cores. The runtime can also be further reduced through a better implementation as our implementation is a prototype.
|
| 406 |
+
|
| 407 |
+
Although it might be concerning that the runtime is too much for some deep networks, it is still relatively small compared to training processes which might cost days or even weeks. More importantly, solving the optimal solution for a network is an one-time effort. The optimal solutions for all popular networks will be released online for people to use without taking the time to run ACG solver.
|
| 408 |
+
|
| 409 |
+
To see how well the reality matches with the theory, we also compare the measured memory cut off and theoretical memory cut off (given by Algorithm 5) in Table 2. Observe that all the measured memory cut off are slightly lower than theoretical memory cut off. This is because, in implementation, we assume that the whole input tensors of each operation are always stored for backward. In reality, some operations only need to store small tensors for backward. For example, batchnormalization only needs a few statistics for backward and doesn’t need the whole input tensor.
|
| 410 |
+
|
| 411 |
+
# D VISUALIZATION
|
| 412 |
+
|
| 413 |
+
We visualize the computation graph of Alexnet, vgg11, vgg13, vgg16 ,vgg19 and CustomNet and the solution of our approach (in green) and the solution of Chen’s approach (in red). In the computation graphs, the cost of each vertex and the actual operation of each edge are also marked. The cost of each vertex is the size of this tensor during forward given the input as [1, 3, 224, 224] $( [ 1 , 3 , 3 0 0 , 3 0 0 ]$ for inception v3). For example, in Alexnet, the input is [1, 3, 224, 224] and thus the source vertex has the cost $1 5 0 5 2 8 = 1 \times 3 \times 2 2 4 \times 2 2 4$ . After 2D convolution and relu, the tensor becomes [1, 64, 55, 55] and thus the second vertex has the cost $1 9 3 6 0 0 = 1 \times 6 4 \times 5 5 \times 5 5$ .
|
| 414 |
+
|
| 415 |
+

|
| 416 |
+
Figure 6: Endpoint vertices found on Alexnet
|
| 417 |
+
|
| 418 |
+

|
| 419 |
+
Figure 7: Endpoint vertices found on vgg11
|
| 420 |
+
|
| 421 |
+

|
| 422 |
+
Figure 8: Endpoint vertices found on vgg13
|
| 423 |
+
|
| 424 |
+

|
| 425 |
+
Figure 9: Endpoint vertices found on vgg16
|
| 426 |
+
|
| 427 |
+

|
| 428 |
+
Figure 10: Endpoint vertices found on CustomNet, Selected vertices(green) of our approach, Chen’s approach not applicable
|
parse/train/BJMvBjC5YQ/BJMvBjC5YQ_content_list.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
parse/train/BJMvBjC5YQ/BJMvBjC5YQ_middle.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
parse/train/BJMvBjC5YQ/BJMvBjC5YQ_model.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
parse/train/Byg9bxrtwS/Byg9bxrtwS.md
ADDED
|
@@ -0,0 +1,661 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# KERNEL AND RICH REGIMES IN OVERPARAMETRIZED MODELS
|
| 2 |
+
|
| 3 |
+
Anonymous authors Paper under double-blind review
|
| 4 |
+
|
| 5 |
+
# ABSTRACT
|
| 6 |
+
|
| 7 |
+
A recent line of work studies overparametrized neural networks in the “kernel regime,” i.e. when the network behaves during training as a kernelized linear predictor, and thus training with gradient descent has the effect of finding the minimum RKHS norm solution. This stands in contrast to other studies which demonstrate how gradient descent on overparametrized multilayer networks can induce rich implicit biases that are not RKHS norms. Building on an observation by Chizat and Bach (2018), we show how the scale of the initialization controls the transition between the “kernel” (aka lazy) and “rich” (aka active) regimes and affects generalization properties in multilayer homogeneous models. We provide a complete and detailed analysis for a simple two-layer model that already exhibits an interesting and meaningful transition between the kernel and rich regimes, and we demonstrate the transition for more complex matrix factorization models and multilayer non-linear networks.
|
| 8 |
+
|
| 9 |
+
# 1 INTRODUCTION
|
| 10 |
+
|
| 11 |
+
A string of recent papers study neural networks trained with gradient descent in the “kernel regime.” They observe that, in a certain regime, networks trained with gradient descent behave as kernel methods (Jacot et al., 2018; Daniely et al., 2016; Daniely, 2017). This allows one to prove convergence to zero error solutions in overparametrized settings (Du et al., 2018; 2019; Allen-Zhu et al., 2018), and also implies gradient descent will converge to the minimum norm solution (in the corresponding RKHS) (Chizat and Bach, 2018; Arora et al., 2019b; Mei et al., 2019) and more generally that models inherit the inductive bias and generalization behavior of the RKHS. This suggests that, in a certain regime, deep models can be equivalently replaced by kernel methods with the “right” kernel, and deep learning boils down to a kernel method with a fixed kernel determined by the architecture and initialization, and thus it can only learn problems learnable by some kernel.
|
| 12 |
+
|
| 13 |
+
This contrasts with other recent results that show how in deep models, including infinitely overparametrized networks, training with gradient descent induces an inductive bias that cannot be represented as an RKHS norm. For example, analytic and/or empirical results suggest that gradient descent on deep linear convolutional networks implicitly biases toward minimizing the $L _ { p }$ bridge penalty, for $p \stackrel { \cdot } { = } 2 / \mathrm { d e p t h } \le 1 .$ , in the frequency domain (Gunasekar et al., 2018b); weight decay on an infinite width single input ReLU implicitly biases towards minimizing the second order total variations $\int { \left| f ^ { \prime \prime } ( x ) \right| d x }$ of the learned function (Savarese et al., 2019); and gradient descent on a overparametrized matrix factorization, which can be thought of as a two layer linear network, induces nuclear norm minimization of the learned matrix (Gunasekar et al., 2017) and can ensure low rank matrix recovery (Li et al., 2018). All these natural inductive biases $\scriptstyle L _ { p }$ bridge penalty for $p < 1$ , total variation norm, nuclear norm) are not Hilbert norms, and therefore cannot be captured by a kernel. This suggests that training deep models with gradient descent can behave very differently from kernel methods, and have much richer inductive biases.
|
| 14 |
+
|
| 15 |
+
One might then ask whether the kernel approximation indeed captures the behavior of deep learning in a relevant and interesting regime, or does the success of deep learning come when learning escapes this regime? In order to understand this, we must first carefully understand when each of these regimes hold, and how the transition between the “kernel” regime and the “rich” regime happens.
|
| 16 |
+
|
| 17 |
+
Some investigations of the kernel regime emphasized the number of parameters (“width”) going to infinity as leading to this regime. However Chizat and Bach (2018) identified the scale of the model as a quantity controlling entry into the kernel regime. Their results suggest that for any number of parameters (any width), a model can be approximated by a kernel when its scale at initialization goes to infinity (see details in Section 3). Considering models with increasing (or infinite) width, the relevant regime (kernel or rich) is determined by how the scaling at initialization behaves as the width goes to infinity. In this paper we elaborate and expand of this view, carefully studying how the scale of initialization effects the model behaviour for $D$ -homogeneous models.
|
| 18 |
+
|
| 19 |
+
In Section 4 we provide a complete and detailed study for a simple 2-homogeneous model that can be viewed as linear regression with squared parametrization, or as a “diagonal” linear neural network. For this model we can exactly characterize the implicit bias of training with gradient descent, as a function of the scale $\alpha$ of initialization, and see how this implicit bias becomes the $\ell _ { 2 }$ norm in the $\alpha \infty$ kernel regime, but the $\ell _ { 1 }$ norm in the $\alpha 0$ rich regime. We can therefore understand how, e.g. for a high dimensional sparse regression problem, where it is necessary to discover the relevant features, we can get good generalization when the initialization scale $\alpha$ is small, but not when $\alpha$ is large. Deeper networks corresponds to higher orders of homogeneity, and so in Section 5 we extend our study to a $D$ -homogeneous model, studying the effects of $D$ . In Sections 6 and 7, we demonstrate similar transitions experimentally in matrix factorization and non-linear networks.
|
| 20 |
+
|
| 21 |
+
# 2 SETUP AND PRELIMINARIES
|
| 22 |
+
|
| 23 |
+
We consider models $f : \mathbb { R } ^ { p } \times \mathcal { X } \mathbb { R }$ which map parameters $\mathbf { w _ { \lambda } } \in \mathbb { R } ^ { p }$ and examples $\mathbf { x } \in \mathcal { X }$ to predictions $f ( \mathbf { w } , \mathbf { x } ) \in \mathbb { R }$ . We denote the predictor implemented by the parameters w as $h _ { \mathbf { w } } = F ( \mathbf { w } )$ such that $h _ { \mathbf { w } } ( \mathbf { x } ) = f ( \mathbf { w } , \mathbf { x } )$ . Much of our focus will on models, such a linear networks, which are linear in $\mathbf { x }$ (but not on the parameters w!), in which case $F ( \mathbf { w } ) \in \mathcal { X } ^ { * }$ is a linear predictor and can be represented as a vector $\beta _ { \mathbf { w } }$ with $f ( \mathbf { w } , \mathbf { x } ) = \langle \beta _ { \mathbf { w } } , \mathbf { x } \rangle$ . Such models are essentially alternate parametrizations of linear models, but as we shall see that change of parametrization is crucial.
|
| 24 |
+
|
| 25 |
+
In this paper, we consider models that are $D$ -positive homogeneous in the parameters w, for some integer $D \geq 1$ , meaning that for any $c \in \mathbb { R } _ { + }$ , ${ \dot { F } } ( c { \cdot } { \mathbf { w } } ) = c ^ { D } { \check { F } } ( { \mathbf { w } } )$ and $f ( c \cdot \mathbf { \bar { w } } , \mathbf { x } ) = c ^ { D } f ( \mathbf { w } , \mathbf { x } )$ . We refer to such models simply as $D$ -homogeneous. Many interesting model classes have this property, including multi-layer ReLU networks with fully connected and convolutional layers, layered linear neural networks, and matrix factorization where $D$ corresponds to the depth of the network.
|
| 26 |
+
|
| 27 |
+
Consider a training set $\{ ( { \mathbf { x } ^ { ( n ) } , y ^ { ( n ) } } ) \} _ { n = 1 } ^ { N }$ consisting of $N$ examples of input label pairs. For a given loss function $\ell : \mathbb { R } \times \mathbb { R } \to \mathbb { R }$ , the loss of the model parametrized by w is $\begin{array} { r } { L ( F ( \mathbf { w } ) ) = \sum _ { n = 1 } ^ { N } \ell ( f ( \mathbf { w } , \mathbf { x } ^ { ( n ) } ) , y ^ { ( n ) } ) } \end{array}$ . We will focus mostly on the squared loss $\ell _ { \mathrm { s q } } ( \hat { y } , y ) =$ $( \hat { y } - y ) ^ { 2 }$ . We slightly abuse notation and use $f ( \mathbf { w } , X ) \in \mathbb { R } ^ { N }$ to denote the vector of predictions $[ f ( \mathbf { w } , \mathbf { x } ^ { ( 1 ) } ) , \dots , f ( \mathbf { w } , \mathbf { x } ^ { ( N ) } ) ]$ and so for the squared loss we can write $L ( \mathbf { w } ) = \| f ( \mathbf { w } , X ) - \mathbf { y } \| _ { 2 } ^ { 2 }$ , where $\mathbf { y } \in \mathbb { R } ^ { N }$ is the vector of target labels.
|
| 28 |
+
|
| 29 |
+
Minimizing the loss $L ( \mathbf { w } )$ using gradient descent amounts to iteratively updating the parameters
|
| 30 |
+
|
| 31 |
+
$$
|
| 32 |
+
\mathbf { w } ( k + 1 ) = \mathbf { w } ( k ) - \eta \nabla L ( \mathbf { w } ( k ) ) .
|
| 33 |
+
$$
|
| 34 |
+
|
| 35 |
+
We consider gradient descent with infinitesimally small stepsize $\eta$ , i.e. gradient flow dynamics
|
| 36 |
+
|
| 37 |
+
$$
|
| 38 |
+
\begin{array} { r } { \dot { \mathbf { w } } ( t ) = - \nabla L ( \mathbf { w } ( t ) ) . } \end{array}
|
| 39 |
+
$$
|
| 40 |
+
|
| 41 |
+
We are particularly interested in the scale of initialization and we capture it through a scalar parameter $\alpha \in \mathbb { R } _ { + }$ . For scale $\alpha$ , we will denote by ${ \bf w } _ { \alpha } ( t )$ the gradient flow path (2) with the initial condition $\mathbf { w } _ { \alpha } ( 0 ) = \alpha \mathbf { w } _ { 0 }$ for some fixed $\mathbf { w } _ { 0 }$ . We use $\dot { h _ { \alpha } } ( t ) = F ( \mathbf { w } _ { \alpha } ( t ) )$ , and for linear predictors $\beta _ { \alpha } ( t ) = \beta _ { \mathbf { w } _ { \alpha } ( t ) }$ , to denote the dynamics on the predictor $F ( \mathbf { w } )$ induced by the gradient flow on w.
|
| 42 |
+
|
| 43 |
+
In many cases, we expect the dynamics to converge to a minimizer of $L ( \mathbf { w } )$ , though proving this happens will not be our main focus. Rather, we are interested in the underdetermined case, $N \ll p$ , where there are generally many minimizers of $L ( \mathbf { w } )$ , all with $f ( \mathbf { w } , X ) = \mathbf { y }$ and $L ( \mathbf { w } ) = 0$ . Our main focus is which of the many minimizers does gradient flow converge to. That is, we want to characterize $\begin{array} { r } { \mathbf { w } _ { \alpha } ( \infty ) = \operatorname* { l i m } _ { t \infty } \mathbf { w } _ { \alpha } ( t ) } \end{array}$ or, more importantly, the predictor $h _ { \alpha } ( \infty ) = F ( \mathbf { w } _ { \alpha } ( \infty ) )$ or $\beta _ { \alpha } ( \infty ) = \beta _ { \mathbf { w } _ { \alpha } ( \infty ) }$ we converge to, and how these depend on the scale $\alpha$ . In underdetermined problems, where there are many zero error solutions, simply fitting the data using the model does not provide enough inductive bias to ensure generalization. But in many cases, the specific solution reached by gradient flow (or some other optimization procedure) has special structure, or minimizes some implicit regularizer, and this structure or regularizer provides the needed inductive bias (Gunasekar et al., 2018b;a; Soudry et al., 2018; Ji and Telgarsky, 2018).
|
| 44 |
+
|
| 45 |
+
# 3 THE KERNEL REGIME
|
| 46 |
+
|
| 47 |
+
Gradient descent/flow considers only the first-order approximation of the model w.r.t. w:
|
| 48 |
+
|
| 49 |
+
$$
|
| 50 |
+
f ( \mathbf { w } , \mathbf { x } ) = f ( \mathbf { w } ( t ) , x ) + \langle \mathbf { w } - \mathbf { w } ( t ) , \nabla _ { \mathbf { w } } f ( \mathbf { w } ( t ) , \mathbf { x } ) \rangle + O ( \| \mathbf { w } - \mathbf { w } ( t ) \| ^ { 2 } ) .
|
| 51 |
+
$$
|
| 52 |
+
|
| 53 |
+
That is, locally around any ${ \bf w } ( t )$ , gradient flow operates on the model as if it were an affine model $f ( \mathbf { w } , \mathbf { x } ) \approx f _ { 0 } ( \mathbf { x } ) + \left. \mathbf { w } , \phi _ { \mathbf { w } ( t ) } ( \mathbf { x } ) \right.$ with feature map $\phi _ { \mathbf { w } ( t ) } ( \mathbf { x } ) = \nabla _ { \mathbf { w } } f ( \mathbf { w } ( t ) , \mathbf { x } )$ , corresponding to the tangent kernel $K _ { \mathbf { w } ( t ) } ( x , x ^ { \prime } ) = \langle \nabla _ { \mathbf { w } } f ( \mathbf { w } ( t ) , \mathbf { x } ) , \nabla _ { \mathbf { w } } f ( \mathbf { w } ( t ) , \mathbf { x } ) \rangle$ (Jacot et al., 2018; Zou et al., 2018; Yang, 2019; Lee et al., 2019). Of particular interest is the tangent kernel at initialization, $K _ { { \bf w } _ { \alpha } ( 0 ) } = \bar { \alpha } ^ { 2 ( D - 1 ) } K _ { 0 }$ where we denote $K _ { 0 } = K _ { \mathbf { w } _ { 0 } }$ .
|
| 54 |
+
|
| 55 |
+
The “kernel regime” refers to a situation in which the tangent kernel $K _ { \mathbf w ( t ) }$ does not change over the course of optimization, and less formally to the regime where it does not change significantly, i.e. where $\forall t K _ { \mathbf { w } ( t ) } \approx K _ { \mathbf { w } ( 0 ) }$ . In this regime, training the model is exactly equivalent to training an affine model $\tilde { f } ( \mathbf { w } , \mathbf { x } ) = \alpha ^ { D } f ( \mathbf { w } _ { 0 } , \mathbf { x } ) + \left. \mathbf { w } , \alpha ^ { D - 1 } \phi _ { 0 } ( \mathbf { x } ) \right.$ with kernelized gradient descent/flow with the kernel $\alpha ^ { 2 ( D - 1 ) } K _ { 0 }$ and a “bias term” of $\alpha ^ { D } f ( \mathbf { w } _ { 0 } , \mathbf { x } )$ . To avoid handling this bias term, and in particular its scaling, Chizat and Bach (2018) suggest using “unbiased” initializations such that $F ( \mathbf { w } _ { 0 } ) = 0$ , so that the bias term vanishes. This can often be achieved by replicating units or components with opposite signs at initialization, which is the approach we use here (see Sections 4–6 for examples and details).
|
| 56 |
+
|
| 57 |
+
For underdetermined problem with multiple solutions $f ( \mathbf { w } , X ) = \mathbf { y }$ , unbiased kernel gradient flow (or gradient descent) converges to the minimum norm solution ${ \hat { h } } _ { K } = \arg \operatorname* { m i n } _ { h ( X ) = \mathbf { y } } \left\| h \right\| _ { K }$ , where $\left\| h \right\| _ { K }$ is the RKHS norm corresponding to the kernel. And so, in the kernel regime, we will have that $\overset { \vartriangle } { \boldsymbol { h } } ( \infty ) = \hat { \boldsymbol { h } } _ { K _ { 0 } }$ , and the implicit bias of training is precisely given by the kernel.
|
| 58 |
+
|
| 59 |
+
When does the “kernel regime” happen? Chizat and Bach (2018) showed that for any homogeneous1 model satisfying some technical conditions, the kernel regime is reached as $\alpha \to \infty$ . That is, as we increase the scale of initialization, the dynamics converge to the kernel gradient flow dynamics with the kernel $K _ { 0 }$ , and we have $\begin{array} { r } { \operatorname* { l i m } _ { \alpha \to \infty } h _ { \alpha } ( \infty ) = \hat { h } _ { K } } \end{array}$ . In Sections 4 and 5 we prove this limit directly for our specific models, and we also demonstrate it empirically for matrix factorization and deep networks in Sections 6 and 7.
|
| 60 |
+
|
| 61 |
+
In contrast, and as we shall see in later sections, the $\alpha 0$ small initialization limit often leads to a very different and rich inductive bias, e.g. inducing sparsity or low-rank structure (Gunasekar et al., 2017; Li et al., 2018; Gunasekar et al., 2018b), that allows for generalization in many settings where kernel methods would not. We refer to this limit reached as $\alpha 0$ as the “rich regime.” This regime is also referred to as the “active” or “adaptive” regime (Chizat and Bach, 2018) since the tangent kernel $K _ { \mathbf w ( t ) }$ changes over the course of training, in a sense adapting to the data. We argue that this regime is the one that truly allows us to exploit the power of depth, and thus is the more relevant regime for understanding the success of deep learning.
|
| 62 |
+
|
| 63 |
+
# 4 DETAILED STUDY OF A SIMPLE DEPTH-2 MODEL
|
| 64 |
+
|
| 65 |
+
We study in detail a simple 2-homogeneous model. Consider the class of linear functions over $\chi = \mathbb { R } ^ { d }$ , with squared parameterization as follows:
|
| 66 |
+
|
| 67 |
+
$$
|
| 68 |
+
f ( \mathbf { w } , \mathbf { x } ) = \sum _ { i = 1 } ^ { d } ( \mathbf { w } _ { + , i } ^ { 2 } - \mathbf { w } _ { - , i } ^ { 2 } ) \mathbf { x } _ { i } = \langle \beta _ { \mathbf { w } } , \mathbf { x } \rangle , { \mathrm { ~ w h e r e ~ } } \mathbf { w } = { \binom { \mathbf { w } _ { + } } { \mathbf { w } _ { - } } } \in \mathbb { R } ^ { 2 d } { \mathrm { ~ a n d ~ } } \beta _ { \mathbf { w } } = \mathbf { w } _ { + } ^ { 2 } - \mathbf { w } _ { - } ^ { 2 } .
|
| 69 |
+
$$
|
| 70 |
+
|
| 71 |
+
where we use the notation $\mathbf { z } ^ { 2 }$ for $\mathbf { z } \in \mathbb { R } ^ { d }$ to denote elementwise squaring. We consider initializing all weights equally with $\mathbf { w } _ { 0 } = \mathbf { 1 }$ .
|
| 72 |
+
|
| 73 |
+
This is nothing but a linear regression model, except with an unconventional parametrization. The model can also be thought of as a “diagonal” linear neural network (i.e. where the weight matrices have diagonal structure) with $2 d$ units. A standard diagonal linear network would have $d$ units, with each unit connected to just a single input unit with weights $u _ { i }$ and the output with weight $v _ { i }$ , thus implementing the model $\begin{array} { r } { f ( ( \bar { \bf u } , \bar { \bf v } ) , \bar { \bf x } ) = \sum _ { i } { \bf u } _ { i } { \bf v } _ { i } { \bf x } _ { i } } \end{array}$ . But if at initialization $| { \mathbf { } } u _ { i } | = | \bar { \mathbf { } } { \mathbf { } } v _ { i } |$ , their magnitude will remain equal and their signs will not flip throughout training, and so we can equivalently replace both with a single weight $\mathbf { w } _ { i }$ , yielding the model $f ( \mathbf { w } , \mathbf { x } ) = \left. \mathbf { w } ^ { 2 } , \mathbf { x } \right.$ .
|
| 74 |
+
|
| 75 |
+
The reason for using both $\mathbf { w } _ { + }$ and $\mathbf { w } _ { - }$ (or $2 d$ units) is two-fold. First, it ensures that the image of $F ( \mathbf { w } )$ is all (signed) linear functions, and thus the model is truly equivalent to standard linear regression. Second, it allows for initialization at $F ( \alpha \mathbf { w } _ { 0 } ) = 0$ without this being a saddle point from which gradient flow will never escape.2
|
| 76 |
+
|
| 77 |
+
The model (4) is perhaps the simplest non-trivial $D$ -homogeneous model for $D > 1$ , and we chose it for this reason, as it already exhibits distinct and interesting kernel and rich regimes. Furthermore, we can completely understand both the implicit regularization driving this model and the transition between the regimes analytically.
|
| 78 |
+
|
| 79 |
+
Consider the behavior of the limit of gradient flow (2) as a function of the initialization, in the underdetermined $N \ll d$ case where there are many possible solutions $X { \boldsymbol { \beta } } = \mathbf { y }$ . The tangent kernel at initialization is $K _ { 0 } ( { \bf x } , { \bf x } ^ { \prime } ) = 8 \alpha ^ { 2 } \left. { \bf x } , { \bf x } ^ { \prime } \right.$ , i.e. a scaling of the standard inner product kernel, so $\| \beta \| _ { K _ { 0 } } \propto \| \beta \| _ { 2 }$ . Thus, in the kernel regime, gradient flow leads to the minimum $\ell _ { 2 }$ norm solution, $\beta _ { L 2 } ^ { * } \doteq \arg \operatorname* { m i n } _ { X \beta = y } \| \beta \| _ { 2 }$ . Following Chizat and Bach (2018) and the discussion in Section 3, we thus expect that $\begin{array} { r } { \operatorname* { l i m } _ { \alpha \to \infty } \beta _ { \alpha } ( \infty ) = \beta _ { L 2 } ^ { * } } \end{array}$ , and we also show this below.
|
| 80 |
+
|
| 81 |
+
In contrast, Gunasekar et al. (2017) shows that as $\alpha 0$ , gradient flow leads instead to the minimum $\ell _ { 1 }$ norm solution $\begin{array} { r } { \operatorname* { l i m } _ { \alpha \to 0 } \beta _ { \alpha } ( \infty ) = \beta _ { L 1 } ^ { * } \doteq \arg \operatorname* { m i n } _ { X \beta = y } \| \beta \| _ { 1 } } \end{array}$ . This is the “rich regime.” Comparing this with the kernel regime, we already see two very distinct behaviors and, in high dimensions, two very different inductive biases. In particular, the rich regime’s bias is not an RKHS norm for any choice of kernel. Can we charactarize and understand the transition between the two regimes as $\alpha$ transitions from very small to very large? The following theorem does just that.
|
| 82 |
+
|
| 83 |
+
Theorem 1. For any $0 < \alpha < \infty$
|
| 84 |
+
|
| 85 |
+
$$
|
| 86 |
+
{ \displaystyle \beta _ { \alpha } ( \infty ) = \hat { \beta } _ { \alpha } \doteq \arg \operatorname* { m i n } _ { \beta } Q _ { \alpha } ( \beta ) \ s . t . \ X \beta = \bf y } ,
|
| 87 |
+
$$
|
| 88 |
+
|
| 89 |
+
$$
|
| 90 |
+
\begin{array} { r } { Q _ { \alpha } \left( \beta \right) = \sum _ { i = 1 } ^ { d } q \left( \frac { \beta _ { i } } { \alpha ^ { 2 } } \right) a n d q ( z ) = \int _ { 0 } ^ { z } \operatorname { a r c s i n h } \left( \frac { u } { 2 } \right) d u = 2 - \sqrt { 4 + z ^ { 2 } } + z \operatorname { a r c s i n h } \left( \frac { z } { 2 } \right) } \end{array}
|
| 91 |
+
$$
|
| 92 |
+
|
| 93 |
+
Proof sketch The proof in Appendix A proceeds by showing the gradient flow dynamics on w lead to a solution of the form
|
| 94 |
+
|
| 95 |
+
$$
|
| 96 |
+
\beta _ { \alpha } ( \infty ) = \alpha ^ { 2 } \left( \exp \left( - 4 X ^ { \top } \int _ { 0 } ^ { \infty } r _ { \alpha } ( t ) d t \right) - \exp \left( 4 X ^ { \top } \int _ { 0 } ^ { \infty } r _ { \alpha } ( t ) d t \right) \right)
|
| 97 |
+
$$
|
| 98 |
+
|
| 99 |
+
where $\pmb { r } _ { \alpha } ( t ) = X \beta _ { \alpha } ( t ) - \mathbf { y }$ . While evaluating the integral would be very difficult, the fact that
|
| 100 |
+
|
| 101 |
+
$$
|
| 102 |
+
{ \displaystyle \beta _ { \alpha } ( \infty ) \in \left\{ \alpha ^ { 2 } \left( \exp \left( - X ^ { \top } { \bar { r } } \right) - \exp \left( X ^ { \top } { \bar { r } } \right) : { \bar { r } } \in \mathbb { R } ^ { N } \right) \right\} }
|
| 103 |
+
$$
|
| 104 |
+
|
| 105 |
+
already provides a dual certificate for the KKT conditions for $\mathrm { m i n } _ { \beta } Q _ { \alpha } \left( \beta \right)$ s.t. $X { \boldsymbol { \beta } } = \mathbf { y }$
|
| 106 |
+
|
| 107 |
+
In light of Theorem 1, the function $Q _ { \alpha }$ (referred to elsewhere as the “hypentropy” function (Ghai et al., 2019)) can be understood as an implicit regularizer which biases the gradient flow solution towards one particular zero-error solution out of the many possibilities. As $\alpha$ ranges from 0 to $\infty$ , the $Q _ { \alpha }$ regularizer interpolates between the $\ell _ { 1 }$ and $\ell _ { 2 }$ norms, as illustrated (labelled $D = 2$ ) in Figure 2a, which shows the coordinate function $q$ . As $\alpha \infty$ we have that $\beta _ { i } / \alpha ^ { 2 } 0$ , and so the behaviour of $Q _ { \alpha } ( \beta )$ is controlled by the behaviour of $q ( z )$ around $z = 0$ . In this regime $\begin{array} { r } { q ( z ) = \frac { z ^ { 2 } } { 4 } + O ( z ^ { 4 } ) } \end{array}$ is quadratic, and so $\begin{array} { r } { Q _ { \alpha } ( \beta ) { \tilde { \propto } } \sum _ { i } \beta _ { i } ^ { 2 } = \left\| \beta \right\| _ { 2 } ^ { 2 } } \end{array}$ . On the other hand when $\alpha 0$ $\beta _ { i } / \alpha ^ { 2 } \to \infty$ is governed by the asymptotic behaviour $q ( z ) = \Theta ( z \log z )$ as $z \infty$ . In this regime $\begin{array} { r } { Q _ { \alpha } ( \beta ) { \tilde { \propto } } \sum _ { i } \frac { \beta _ { i } } { \alpha ^ { 2 } } \log \frac { \beta _ { i } } { \alpha ^ { 2 } } \propto \| \beta \| _ { 1 } + o ( 1 ) } \end{array}$ . For any initialization scale $\alpha$ , the function $Q _ { \alpha }$ describes exactly how training will interpolate between the kernel and rich regimes. The following Theorems, proven in Appendix B, provide a quantitative statement of how the $\ell _ { 1 }$ and $\ell _ { 2 }$ norms are approached as $\alpha 0$ and $\alpha \to \infty$ respectively:
|
| 108 |
+
|
| 109 |
+

|
| 110 |
+
Figure 1: In (a), the population error of the gradient flow solution vs. $\alpha$ in the sparse regression problem described in Section 4. In (b), the excess $\ell _ { 1 }$ norm (blue) and excess $\ell _ { 2 }$ norm (red) of the gradient flow solution, i.e. $\left\| \beta _ { \alpha } ( \infty ) \right\| _ { 1 } - \left\| \beta _ { L 1 } ^ { * } \right\| _ { 1 }$ and $\left\| \beta _ { \alpha } ( \infty ) \right\| _ { 2 } - \left\| \beta _ { L 2 } ^ { * } \right\| _ { 2 }$ . In (c), the largest $\alpha$ such that $\beta _ { \alpha } ( \infty )$ achieves population error at most 0.025 is shown. The dashed line indicates the number of samples needed by $\beta _ { L 1 } ^ { * }$ .
|
| 111 |
+
|
| 112 |
+
Theorem 2. For any $0 < \epsilon < d$
|
| 113 |
+
|
| 114 |
+
$$
|
| 115 |
+
\begin{array} { r l } & { \alpha \leq \operatorname* { m i n } \left. \left( 2 ( 1 + \epsilon ) \| \beta _ { L 1 } ^ { * } \| _ { 1 } \right) ^ { - \frac { 2 + \epsilon } { 2 \epsilon } } , \exp \left( - d / ( \epsilon \| \beta _ { L 1 } ^ { * } \| _ { 1 } ) \right) \right. \implies \| \hat { \beta } _ { \alpha } \| _ { 1 } \leq ( 1 + \epsilon ) \| \beta _ { L 1 } ^ { * } \| _ { 1 } } \\ & { \qquad \alpha \geq \sqrt { 2 ( 1 + \epsilon ) ( 1 + 2 / \epsilon ) \| \beta _ { L 2 } ^ { * } \| _ { 2 } } \implies \| \hat { \beta } _ { \alpha } \| _ { 2 } ^ { 2 } \leq ( 1 + \epsilon ) \| \beta _ { L 2 } ^ { * } \| _ { 2 } ^ { 2 } } \end{array}
|
| 116 |
+
$$
|
| 117 |
+
|
| 118 |
+
Theorem 2 indicates a certain asymmetry between reaching the rich and kernel regimes: polynomially large $\alpha$ suffices to approximate $\beta _ { L 2 } ^ { * }$ to a very high degree of accuracy. On the other hand, exponentially small $\alpha$ is sufficient to approximate $\beta _ { L 1 } ^ { * }$ , and Lemma 2 in Appendix B proves that $\alpha \leq d ^ { - \Omega ( 1 / \epsilon ) }$ is necessary in order for $Q _ { \alpha }$ to be proportional to the $\ell _ { 1 }$ norm, which indicates that $\alpha$ must be exceedingly small to approximate $\beta _ { L 1 } ^ { * }$ for certain problems.
|
| 119 |
+
|
| 120 |
+
This suggestive of an explanation for the difficulty of demonstrating rich regime behavior empirically in matrix factorization problems (Gunasekar et al., 2017; Arora et al., 2019a). If the initialization really needs to be exponentially small, then conducting experiments in this regime may be infeasible for practical reasons.
|
| 121 |
+
|
| 122 |
+
In order to understand the effects of initialization on generalization, consider a simple sparse regression problem, where $\mathbf { x } ^ { ( 1 ) } , \ldots , \mathbf { x } ^ { ( N ) } \sim N ( 0 , I )$ and $\dot { y } ^ { ( n ) } = \big \langle \beta ^ { * } , \mathbf { x } ^ { ( n ) } \big \rangle + N ( 0 , \bar { 0 . } 0 1 )$ where $\beta ^ { * }$ is $r ^ { * }$ -sparse and its non-zero entries are $1 / \sqrt { r ^ { * } }$ . When $N \leq d$ , gradient flow will reach a zero training error solution, however, not all of these solutions will generalize the same. With $N = \Theta ( r ^ { * } \log d )$ samples, the rich regime, i.e. the minimum $\ell _ { 1 }$ norm solution will generalize well. However, even though we can fit the training data perfectly well, we should not expect any generalization in the kernel regime with this sample size $N = \Omega ( d )$ samples would be needed that regime), see Figure 1c. In this case, to generalize well may require using very small initialization, and generalization will improve as we decrease $\alpha$ . From an optimization perspective this is unfortunate because ${ \bf w } = 0$ is a saddle point, so taking $\alpha 0$ drastically increases the time needed to escape the saddle point.
|
| 123 |
+
|
| 124 |
+
Thus, there is a tension here between generalization and optimization: a smaller $\alpha$ might improve generalization, but it makes optimization trickier. This suggests that in practice we would want to compromise, and operate just at the edge of the rich regime, using the largest $\alpha$ that still allows for generalization. This is borne out in our neural network experiments in Section 7, where standard initialization schemes correspond to being right on the edge of entering the kernel regime, where we expect models to both generalize well and avoid serious optimization difficulties.
|
| 125 |
+
|
| 126 |
+
The tension between optimization and generalization can also be seen through a tradeoff between the sample size and the largest $\alpha$ we can use and still generalize. In Figure 1c, for each sample size $N$ , we plot the largest $\alpha$ for which the gradient flow solution $\hat { \beta } _ { \alpha }$ achieves population risk below some threshold. As $N$ approaches the number of samples needed for $\beta _ { L 1 } ^ { * }$ to generalize (the vertical dashed line), $\alpha$ must become extremely small. However, generalization is much easier when the number of samples is only slightly larger, and we can use much more moderate initialization.
|
| 127 |
+
|
| 128 |
+

|
| 129 |
+
Figure 2: (a) $q _ { D } ( z )$ for several values of $D$ . (b) The ratio $\frac { Q _ { \alpha } ^ { D } ( e _ { 1 } ) } { Q _ { \alpha } ^ { D } ( \mathbf { 1 } _ { d } / \| \mathbf { 1 } _ { d } \| _ { 2 } ) }$ as a function of $\alpha$ , where $e _ { 1 } ~ =$ $[ 1 , 0 , 0 , \ldots , 0 ]$ is the first standard basis vector and $\mathbf { 1 } _ { d } ~ = ~ [ 1 , 1 , \ldots , 1 ]$ is the all ones vector in $\mathbb { R } ^ { d }$ . This captures the transition between approximating the √ $\ell _ { 2 }$ norm (where the ratio is 1) and the $\ell _ { 1 }$ norm (where the ratio is $1 / \sqrt { d } )$ . (c) sparse regression simulation as in Figure 1, using different order models. The y-axis is $\alpha ^ { D }$ (the scale of $\beta$ at initialization) needed to recover the planted predictor to accuracy 0.025. The dashed line indicates the number of samples needed in order for $\beta _ { L 1 } ^ { * }$ to approximate the plant.
|
| 130 |
+
|
| 131 |
+
# 5 HIGHER ORDER MODELS
|
| 132 |
+
|
| 133 |
+
In the previous Section, we considered a 2-homogeneous model, corresponding to a simple depth-2 “diagonal” network. Deeper models correspond to higher order homogeneity (a depth- $D$ ReLU or linear network is $D$ -homogeneous), motivating us to understand the effect of the order of homogeneity on the transition between the regimes. We therefore generalize our model and consider:
|
| 134 |
+
|
| 135 |
+
$$
|
| 136 |
+
F _ { D } ( \mathbf { w } ) = \beta _ { \mathbf { w } , D } = \mathbf { w } _ { + } ^ { D } - \mathbf { w } _ { - } ^ { D } \quad \mathrm { a n d } \quad f _ { D } ( \mathbf { w } , \mathbf { x } ) = \langle \mathbf { w } _ { + } ^ { D } - \mathbf { w } _ { - } ^ { D } , \mathbf { x } \rangle
|
| 137 |
+
$$
|
| 138 |
+
|
| 139 |
+
We again consider initializing all weights equally so $\mathbf { w } _ { 0 } = \mathbf { 1 }$ . As before, this is just a linear regression model with an unconventional parametrization. It is equivalent to a depth- $D$ matrix factorization model with commutative measurement matrices, as studied by Arora et al. (2019a), and can be thought of as a depth- $D$ diagonal linear network.
|
| 140 |
+
|
| 141 |
+
We can again study the effect of the scale of the initialization $\alpha$ on the implicit bias. Let $\beta _ { \alpha , D } ( \infty )$ denote the limit of gradient flow on w when initialized at $\alpha 1$ for the $D$ -homogeneous model. Using the same approach as in Section 4, in Appendix $\textrm { C }$ we show:
|
| 142 |
+
|
| 143 |
+
Theorem 3. For any $\alpha$ and $D \geq 3 ,$ , if gradient flow reaches a solution $X \beta _ { \alpha , D } ( \infty ) = y$ , then
|
| 144 |
+
|
| 145 |
+
$$
|
| 146 |
+
\beta _ { \alpha , D } ( \infty ) = \arg \operatorname* { m i n } _ { \beta } Q _ { \alpha } ^ { D } ( \beta ) \ s . t \ \mathbf { X } \beta = \mathbf { y }
|
| 147 |
+
$$
|
| 148 |
+
|
| 149 |
+
where $\begin{array} { r } { Q _ { \alpha } ^ { D } ( \beta ) = \sum _ { i = 1 } ^ { d } q _ { D } \big ( \beta _ { i } / \alpha ^ { D } \big ) } \end{array}$ and $q _ { D } = \int h _ { D } ^ { - 1 }$ is the antiderivative of the unique inverse of $h _ { D } ( z ) = ( 1 - z ) ^ { - \frac { D } { D - 2 } } - ( 1 + z ) ^ { - \frac { D } { D - 2 } }$ on $[ - 1 , 1 ]$ . Furthermore, $\begin{array} { r } { \operatorname* { l i m } _ { \alpha \to 0 } \beta _ { \alpha , D } ( \infty ) = \beta _ { L 1 } ^ { * } } \end{array}$ and $\begin{array} { r } { \operatorname* { l i m } _ { \alpha \to \infty } \beta _ { \alpha , D } ( \infty ) = \beta _ { L 2 } ^ { * } } \end{array}$ .
|
| 150 |
+
|
| 151 |
+
In the two extremes we see that we again get the minimum $\ell _ { 2 }$ solution in the kernel regime, and more interestingly, for any depth $D \geq 2$ , we get the same minimum $\ell _ { 1 }$ norm solution in the rich regime, as has also been observed by Arora et al. (2019a). The fact that the rich regime solution does not change with depth is perhaps surprising, and does not agree from what is obtained with explicit regularization (regularizing $\lVert \boldsymbol { w } \rVert _ { 2 }$ is equivalent to $\| \beta \| _ { 2 / D }$ regularization), nor with implicit regularization on logistic-type loss Gunasekar et al. (2017).
|
| 152 |
+
|
| 153 |
+
Although the two extremes do not change as we go beyond $D = 2$ , what does change is the intermediate regime (the regularizer $Q _ { \alpha } ^ { D }$ is unique and cannot be obtained with any other order $D ^ { \prime } \neq D$ ), as well as the sharpness of the transition into the extreme regimes, as illustrated in Figures 2a-2c. The most striking difference is that for order $D > 2$ the scale of $\alpha$ needed to approximate the $\ell _ { 1 }$ is polynomial rather then exponential, yielding a much quicker transition to the “rich regime”, and allowing near-optimal sparse regression with reasonable initialization scales. Increasing $D$ further hastens the transition. This might also help explain some of the empirical observations about the benefit of depth in deep matrix factorization Arora et al. (2019a).
|
| 154 |
+
|
| 155 |
+

|
| 156 |
+
Figure 3: Regimes in Matrix Completion We generated a $1 0 \times 1 0$ rank-one matrix completion problem with ground truth $M ^ { * } = u ^ { * } ( v ^ { * } ) ^ { \top }$ by generating $u ^ { \ast } , v ^ { \ast } \in \mathbb { R } ^ { 1 0 }$ with i.i.d. $\mathcal { N } ( 0 , 1 )$ entries and observing $N = 6 0$ random entries $\Omega$ . We fit the observed entries by minimizing the squared loss on a matrix factorization model $F ( U , V ) = U V ^ { \top }$ with $U , V ~ \in ~ \mathbb { R } ^ { d \times 2 k }$ . For different scalings $\alpha$ , we examine the matrix $M ( \infty )$ reached by gradient flow on $U , V$ (solved using python ODE solvers) and plot (i) the reconstruction error on unobserved entries $\begin{array} { r } { \sum _ { i j \notin \Omega } ( M _ { i j } ^ { * } - M ( \infty ) _ { i j } ) ^ { 2 } } \end{array}$ , and (ii) the amount by which the unobserved entries changed during optimization $\begin{array} { r } { \sum _ { i j \notin \Omega } ( M ( \infty ) _ { i j } - M ( 0 ) _ { i j } ) ^ { 2 } } \end{array}$ . In (a) we used $k = 2 d$ and initialized to $U _ { 0 } = V _ { 0 } = \alpha I$ . In (b) for varying $k$ , we initialized to $U _ { 0 } = \alpha \bar { U } _ { 0 }$ and $V _ { 0 } = \alpha \bar { V } _ { 0 }$ with $\bar { U } _ { 0 } , \bar { V } _ { 0 } \in \mathbb { R } ^ { d \times k }$ with i.i.d. $\mathcal { N } ( 0 , 1 )$ entries. For large $k$ , the tangent kernel converges to the kernel corresponding to the Frobenius norm.
|
| 157 |
+
|
| 158 |
+
# 6 DEMONSTRATION IN MATRIX COMPLETION
|
| 159 |
+
|
| 160 |
+
We now turn to a more complex depth two model, namely a matrix factorization model, and demonstrate similar transitions empirically. Specifically, we consider the model over matrix inputs $X \in \mathbb { R } ^ { d \times d }$ defined by $f ( ( U , { \dot { V } } ) , X ) \mathbf { \bar { \Psi } } = \left. { \dot { U } } V ^ { \top } , X \right.$ , where $U , V \in \mathbb { R } ^ { d \times k }$ . This corresponds to linear predictors over matrix arguments specified by $F ( U , V ) = U V ^ { \top }$ . In overparameterized regime with $k \geq d$ , the parameterization itself does not introduce any explicit rank constraints. We consider here a random low rank matrix completion problem where Xn = eine>jn represents an uniform random observation of entry $( i _ { n } , j _ { n } )$ of a planted low rank matrix $M ^ { * }$ of rank $r ^ { * } \ll d$ : $y _ { n } = \langle M ^ { * } , X _ { n } \rangle = M _ { i j } ^ { * }$ . For underdetermined problems where $N \ll d ^ { 2 }$ , there are many trivial global minimizers, most of which are not low rank and hence will not guarantee recovery. As was demonstrated empirically by Gunasekar et al. (2017) and also proven rigorously for Gaussian measurements by Li et al. (2018), as $\alpha 0$ gradient flow implicitly regularizes the nuclear norm, which for random measurements leads to recovery of ground truth (Candès and Recht, 2009; Recht et al., 2010): these are very different and rich implicit biases that are not RKHS norms.
|
| 161 |
+
|
| 162 |
+
Crucially, the reconstruction results in Gunasekar et al. (2017) and Li et al. (2018) are dependent on initialization with scale $\alpha 0$ . Here we further explore the role of initialization. Similar to Section 4, in order to get unbiased 0 initialization, we consider $k \geq 2 d$ and initialization of the form $U ( 0 ) = \alpha \left[ U _ { 0 } , - U _ { 0 } \right]$ and $V ( 0 ) = \alpha \left[ V _ { 0 } , V _ { 0 } \right]$ , where $U _ { 0 } , V _ { 0 } \in \mathbb { R } ^ { d \times k / 2 }$ . We will study implicit bias of gradient flow over the factorized parameterization with above initialization.
|
| 163 |
+
|
| 164 |
+
For matrix completion problems with $X = e _ { i _ { X } } e _ { j _ { X } } ^ { \top }$ , the tangent kernel at initialization is given by $K _ { 0 } ( X , X ^ { \prime } ) \propto \langle U _ { 0 } [ i _ { X } , : ] , U _ { 0 } [ i _ { X ^ { \prime } } , : ] \rangle { \bf 1 } ( j _ { X } = j _ { X ^ { \prime } } ) + \langle V _ { 0 } [ j _ { X } , : ] , V _ { 0 } [ j _ { X ^ { \prime } } , : ] \rangle { \bf 1 } ( i _ { X } = i _ { X ^ { \prime } } )$ . This defaults to the trivial delta kernel $K ( X , X ^ { \prime } ) = { \bf 1 } ( i _ { X } = i _ { X ^ { \prime } } ) \cdot { \bf 1 } ( j _ { X } = j _ { X ^ { \prime } } )$ for the two special cases (a) $U _ { 0 } , V _ { 0 }$ have orthogonal columns (e.g. $U _ { 0 } = V _ { 0 } = I \rangle$ ), or (b) $U _ { 0 } , V _ { 0 }$ have independent Gaussian entries and $k \infty$ . In these cases, minimizing the RKHS norm of the tangent kernel corresponds to returning a zero imputed matrix (minimum Frobenius norm solution). Figure 3 demonstrates the behaviour of gradient flow updates in the “rich" regime (where for $\alpha 0$ recovers the ground truth) and in the “kernel" regime (where for large $\alpha$ , there are no updates to the unobserved entries).
|
| 165 |
+
|
| 166 |
+
# 7 NEURAL NETWORK EXPERIMENTS
|
| 167 |
+
|
| 168 |
+
In the preceding sections, we intentionally focused on the simplest possible models in which a kernel-to-rich transition can be observed, in order to isolate this phenomena and understand it in detail. In those simple models, we were able to obtain a complete analytic description of the transition. Obtaining such a precise description in more complex models is somewhat optimistic at this point, as we do not yet have a satisfying description of even just the rich regime. Instead, we now provide empirical evidence suggesting that also for non-linear and realistic networks, the scale of initialization induces a transition into and out of a “kernel” regime, and that to reach good generalization we must operate outside of the “kernel” regime. To track whether we are in the “kernel” regime, we track how much the gradient $\nabla _ { \mathbf { w } } { f } ( \mathbf { w } ( t ) , \mathbf { x } )$ changes throughout training. In particular, we define the gradient distance to be the cosine distance between the initial tangent kernel feature map $\nabla _ { \mathbf { w } } { f } ( \mathbf { w } ( 0 ) , \mathbf { x } )$ and the final tangent kernel feature map $\nabla _ { \mathbf { w } } { f } ( \mathbf { w } ( T ) , \mathbf { x } )$ .
|
| 169 |
+
|
| 170 |
+
In Figures 4a and $^ { 4 \mathrm { b } }$ , we see that also for a non-linear ReLU network, we remain in the kernel regime when the initialization is large, and that exiting from the kernel regime is necessary in order to achieve small test error on the synthetic data. Interestingly, when $\alpha ^ { D ^ { - } } \approx 1$ , the models achieve good test error but have smaller gradient distance which, not coincidentally, corresponds to using the out-of-the-box Uniform He initialization. This lies on the boundary between the rich and kernel regimes, which is desirable due to the learning vs. optimization tradeoffs discussed in Section 4. On MNIST data, Figure 4e shows that previously published successes with training overly wide depth-2 ReLU networks without explicit regularization (e.g. Neyshabur et al., 2014) relies on the initialization being small, i.e. being outside of the “kernel regime”. In fact, the $2 . 4 \%$ test error reached for large initialization is no better than what can be achieved with a linear model over a random feature map. Turning to a more realistic network, 4f shows similar behavior when training a VGG11-like network on CIFAR10.
|
| 171 |
+
|
| 172 |
+
So far, we attempted to use the best fixed stepsize for each initialization (i.e. achieving the best test error). But as demonstrated in Figures 4c and 4d, the stepsize choice can also have a significant effect, with larger stepsizes allowing one to exit the kernel regime even at an initialization scale where a smaller stepsize would remain trapped in the kernel regime. Further analytic and empirical studies are necessary in order to understand the joint behavior of the stepsize and initialization scale.
|
| 173 |
+
|
| 174 |
+
# 8 DISCUSSION
|
| 175 |
+
|
| 176 |
+
The main point of this paper is to emphasize the distinction between the “kernel” regime in training overparametrized multi-layered networks, and the “rich” (active, adaptive) regime, show how the scaling of the initialization can transition between them, and understand this transition in detail. We argue that rich inductive bias that enables generalization may arise in the rich regime, but that focusing on the kernel regime restricts us to only what can be done with an RKHS. By studying the transition we also see a tension between generalization and optimization, which suggests we would tend to operate just on the edge of the rich regime, and so understanding this transition, rather then just the extremes, is important. Furthermore, we see that at the edge of the rich regime, the implicit bias of gradient descent differs substantively from that of explicit regularization. Although in our theoretical study we focused on a simple model so that we can carry out a complete and exact analysis analytically, our experiments show that this is representative of the behaviour also in other homogeneous models, and serve as a basis of a more general understanding.
|
| 177 |
+
|
| 178 |
+
Effect of Width Our treatment focused on the effect of scale on the transition between the regimes, and we saw that, as pointed out by Chizat and Bach, we can observe a very meaningful transition between a kernel and rich regime even for finite width parametric models. The transition becomes even more interesting if the width of the model (the number of units per layer, and so also the number of parameters) increases towards infinity. In this case, we must be careful as to how the initialization of each individual unit scales when the total number of units increase, and which regime we fall in to is controlled by the relative scaling of the width and the scale of individual units at initialization. This is demonstrated, for example, in Figure 5, which shows the regime change in matrix factorization problems, from minimum Frobenius norm recovery (the kernel regime) to minimum nuclear norm recovery (the rich regime), as a function of both the number of factors $k$ and the scale of initialization of each factor $\alpha$ . As is expected, the scale $\alpha$ at which we see the transition decreases as the model becomes wider, but further study is necessary to obtain a complete understanding of this scaling.
|
| 179 |
+
|
| 180 |
+
A particularly interesting aspect of infinite width networks is that, unlike for fixed-width networks, it may be possible to scale $\alpha$ relative to the width $k$ such that at the infinite-width limit we would have an (asymptotically) unbiased predictor at initialization $\mathrm { l i m } _ { k \to \infty } F _ { k } ( { \bf w } ( 0 ) ) = 0$ , or at least a non-exploding initialization $\mathrm { l i m } \mathrm { s u p } _ { k \to \infty } \| F _ { k } ( \mathbf { w } ( 0 ) ) \| = O ( 1 )$ , even with random initialization (without a doubling trick leading to artificially unbiased initialization), while still being in the kernel regime. For two-layer networks with ReLU activation, Arora et al. (2019b) showed that with width $k \stackrel { \cdot } { \geq } \mathrm { p o l y } ( 1 / \operatorname* { m a x } _ { \| x \| _ { 2 } \leq 1 , N } \| f _ { 0 } ( x ) \| )$ the gradient dynamics stay in the kernel regime forever.
|
| 181 |
+
|
| 182 |
+

|
| 183 |
+
Figure 4: Synthetic Data: we generated a small regression training set in $\mathbb { R } ^ { 2 }$ by sampling 10 points uniformly from the unit circle, and labelling them with a 1 hidden layer teacher network with 3 hidden units. We trained overparametrized depth- $. D$ , ReLU networks with 30 units per layer with squared loss using full GD and a small stepsize 0.01. The weights of the network are set using the Uniform He initialization, and then multiplied by $\alpha$ . The model is trained until $\approx 0$ training loss. Shown in (a) and (b) are the test error and grad distance vs. the depth-adjusted scale of the initialization, $\overline { { \alpha } } ^ { D }$ , when a small constant stepsize is used. for (c) and (d), we fix $\alpha$ near the transition into the kernel regime, and show the test error and grad distance vs. the stepsize. MNIST: we trained a depth-2 with 5000 hidden units with cross-entropy loss using SGD until it reached $100 \%$ training accuracy. The stepsizes were optimally tuned for each $\alpha$ individually. In (e), the dashed line shows the test error of the resulting network vs. $\alpha$ . We repeated the experiment, but froze the bottom layer and only trained the output layer until convergence. The solid line shows the test error of this predictor vs $\alpha$ . CIFAR10: we trained a VGG11-like deep convolutional network with cross-entropy loss using SGD and a small stepsize $1 0 ^ { - 4 }$ for 2000 epochs; all models reached $100 \%$ training accuracy. In (f), the dashed line shows the final test error vs. $\alpha$ . We repeated the experiment freezing the bottom 10 layers and training only the output layer–the solid line shows this model’s test error. See Appendix E for full details about all of the experiments.
|
| 184 |
+
|
| 185 |
+
# REFERENCES
|
| 186 |
+
|
| 187 |
+
Zeyuan Allen-Zhu, Yuanzhi Li, and Zhao Song. A convergence theory for deep learning via overparameterization. arXiv preprint arXiv:1811.03962, 2018.
|
| 188 |
+
|
| 189 |
+
Sanjeev Arora, Nadav Cohen, Wei Hu, and Yuping Luo. Implicit regularization in deep matrix factorization. arXiv preprint arXiv:1905.13655, 2019a.
|
| 190 |
+
|
| 191 |
+
Sanjeev Arora, Simon S Du, Wei Hu, Zhiyuan Li, and Ruosong Wang. Fine-grained analysis of optimization and generalization for overparameterized two-layer neural networks. arXiv preprint arXiv:1901.08584, 2019b.
|
| 192 |
+
|
| 193 |
+
Emmanuel J Candès and Benjamin Recht. Exact matrix completion via convex optimization. Foundations of Computational mathematics, 9(6):717–772, 2009.
|
| 194 |
+
|
| 195 |
+
Lenaic Chizat and Francis Bach. A note on lazy training in supervised differentiable programming. arXiv preprint arXiv:1812.07956, 2018.
|
| 196 |
+
|
| 197 |
+
Amit Daniely. SGD learns the conjugate kernel class of the network. In Advances in Neural Information Processing Systems, pages 2422–2430, 2017.
|
| 198 |
+
|
| 199 |
+
Amit Daniely, Roy Frostig, and Yoram Singer. Toward deeper understanding of neural networks: The power of initialization and a dual view on expressivity. In Advances In Neural Information Processing Systems, pages 2253–2261, 2016.
|
| 200 |
+
|
| 201 |
+
Simon S Du, Jason D Lee, Haochuan Li, Liwei Wang, and Xiyu Zhai. Gradient descent finds global minima of deep neural networks. arXiv preprint arXiv:1811.03804, 2018.
|
| 202 |
+
|
| 203 |
+
Simon S. Du, Xiyu Zhai, Barnabas Poczos, and Aarti Singh. Gradient descent provably optimizes over-parameterized neural networks. In International Conference on Learning Representations, 2019.
|
| 204 |
+
|
| 205 |
+
Rong Ge, Furong Huang, Chi Jin, and Yang Yuan. Escaping from saddle points—online stochastic gradient for tensor decomposition. In Proceedings of The 28th Conference on Learning Theory, pages 797–842, 2015.
|
| 206 |
+
|
| 207 |
+
Udaya Ghai, Elad Hazan, and Yoram Singer. Exponentiated gradient meets gradient descent. arXiv preprint arXiv:1902.01903, 2019.
|
| 208 |
+
|
| 209 |
+
Suriya Gunasekar, Blake E Woodworth, Srinadh Bhojanapalli, Behnam Neyshabur, and Nati Srebro. Implicit regularization in matrix factorization. In Advances in Neural Information Processing Systems, pages 6151–6159, 2017.
|
| 210 |
+
|
| 211 |
+
Suriya Gunasekar, Jason Lee, Daniel Soudry, and Nathan Srebro. Characterizing implicit bias in terms of optimization geometry. arXiv preprint arXiv:1802.08246, 2018a.
|
| 212 |
+
|
| 213 |
+
Suriya Gunasekar, Jason Lee, Daniel Soudry, and Nathan Srebro. Implicit bias of gradient descent on linear convolutional networks. arXiv preprint arXiv:1806.00468, 2018b.
|
| 214 |
+
|
| 215 |
+
Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. Delving deep into rectifiers: Surpassing human-level performance on imagenet classification. In Proceedings of the IEEE international conference on computer vision, pages 1026–1034, 2015.
|
| 216 |
+
|
| 217 |
+
Arthur Jacot, Franck Gabriel, and Clément Hongler. Neural tangent kernel: Convergence and generalization in neural networks. arXiv preprint arXiv:1806.07572, 2018.
|
| 218 |
+
|
| 219 |
+
Ziwei Ji and Matus Telgarsky. Gradient descent aligns the layers of deep linear networks. arXiv preprint arXiv:1810.02032, 2018.
|
| 220 |
+
|
| 221 |
+
Jaehoon Lee, Lechao Xiao, Samuel S Schoenholz, Yasaman Bahri, Jascha Sohl-Dickstein, and Jeffrey Pennington. Wide neural networks of any depth evolve as linear models under gradient descent. arXiv preprint arXiv:1902.06720, 2019.
|
| 222 |
+
|
| 223 |
+
Yuanzhi Li, Tengyu Ma, and Hongyang Zhang. Algorithmic regularization in over-parameterized matrix sensing and neural networks with quadratic activations. In Conference On Learning Theory, pages 2–47, 2018.
|
| 224 |
+
|
| 225 |
+
Song Mei, Theodor Misiakiewicz, and Andrea Montanari. Mean-field theory of two-layers neural networks: dimension-free bounds and kernel limit. arXiv preprint arXiv:1902.06015, 2019.
|
| 226 |
+
|
| 227 |
+
Behnam Neyshabur, Ryota Tomioka, and Nathan Srebro. In search of the real inductive bias: On the role of implicit regularization in deep learning. arXiv preprint arXiv:1412.6614, 2014.
|
| 228 |
+
|
| 229 |
+
Benjamin Recht, Maryam Fazel, and Pablo A Parrilo. Guaranteed minimum-rank solutions of linear matrix equations via nuclear norm minimization. SIAM review, 52(3):471–501, 2010.
|
| 230 |
+
|
| 231 |
+
Pedro Savarese, Itay Evron, Daniel Soudry, and Nathan Srebro. How do infinite width bounded norm networks look in function space? arXiv preprint arXiv:1902.05040, 2019.
|
| 232 |
+
|
| 233 |
+
Daniel Soudry, Elad Hoffer, Mor Shpigel Nacson, Suriya Gunasekar, and Nathan Srebro. The implicit bias of gradient descent on separable data. Journal of Machine Learning Research, 19(70), 2018.
|
| 234 |
+
|
| 235 |
+
Greg Yang. Scaling limits of wide neural networks with weight sharing: Gaussian process behavior, gradient independence, and neural tangent kernel derivation. arXiv preprint arXiv:1902.04760, 2019.
|
| 236 |
+
|
| 237 |
+
Peng Zhao, Yun Yang, and Qiao-Chu He. Implicit regularization via hadamard product overparametrization in high-dimensional linear regression. 03 2019.
|
| 238 |
+
|
| 239 |
+
Difan Zou, Yuan Cao, Dongruo Zhou, and Quanquan Gu. Stochastic gradient descent optimizes over-parameterized deep relu networks. arXiv preprint arXiv:1811.08888, 2018.
|
| 240 |
+
|
| 241 |
+
# A PROOF OF THEOREM 1
|
| 242 |
+
|
| 243 |
+
It is straightforward, given the expression for $Q _ { \alpha }$ , to prove that $\hat { \beta } _ { \alpha }$ is the minimum $Q _ { \alpha }$ solution to $X { \boldsymbol { \beta } } = \mathbf { y }$ . In other words, if we had been able to guess from the beginning that the implicit bias would be governed by $Q _ { \alpha }$ , it would have been easy to prove this fact. However, a key contribution of this work is in developing a method for determining what the implicit bias is when we do not already have a good guess.
|
| 244 |
+
|
| 245 |
+
We will first describe a general approach for deriving the implied regularizer reached at the limit of some gradient flow dynamics which minimize the loss. In particular, our approach will apply whenever solutions of the gradient flow dynamics can be written as $\beta _ { \alpha } ( t ) = f _ { \alpha } \dot { ( } \dot { X } ^ { \top } \nu ( t ) )$ for some $\nu ( t )$ .
|
| 246 |
+
|
| 247 |
+
The first step is to analyze the gradient flow dynamics of $\beta _ { \alpha }$ and show that
|
| 248 |
+
|
| 249 |
+
$$
|
| 250 |
+
\begin{array} { c } { { X \beta _ { \alpha } ( \infty ) = \mathbf { y } } } \\ { { \beta _ { \alpha } ( \infty ) = f _ { \alpha } ( X ^ { \top } \boldsymbol { \nu } ( \infty ) ) } } \end{array}
|
| 251 |
+
$$
|
| 252 |
+
|
| 253 |
+
for some function $f _ { \alpha }$ and some vector $\nu ( \infty )$ . It is not important for our approach to know exactly what $\nu ( \infty )$ is. This is useful because calculating this $\nu ( \infty )$ will often be difficult, even for the simple examples we consider.
|
| 254 |
+
|
| 255 |
+
The next step is to suppose that there is some function $Q _ { \alpha }$ such that
|
| 256 |
+
|
| 257 |
+
$$
|
| 258 |
+
\beta _ { \alpha } ( \infty ) = \underset { \beta } { \arg \operatorname* { m i n } } Q _ { \alpha } ( \beta ) \quad \mathrm { s . t . } \quad X \beta = \mathbf { y }
|
| 259 |
+
$$
|
| 260 |
+
|
| 261 |
+
and to write down the KKT optimality conditions for (10):
|
| 262 |
+
|
| 263 |
+
$$
|
| 264 |
+
\begin{array} { c } { { X { \boldsymbol { \beta } } ^ { * } = \mathbf { y } } } \\ { { \exists \nu \ \nabla Q _ { \alpha } \left( { \boldsymbol { \beta } } ^ { * } \right) = X ^ { \top } \nu } } \end{array}
|
| 265 |
+
$$
|
| 266 |
+
|
| 267 |
+
Finally, we connect (9) with (11). Specifically, $\beta _ { \alpha } ( \infty )$ satisfies the first KKT condition, and, if $\beta _ { \alpha } ( \infty ) = \beta ^ { * }$ then by taking $\nu = \nu ( \infty )$ we have
|
| 268 |
+
|
| 269 |
+
$$
|
| 270 |
+
\nabla Q _ { \alpha } \left( \beta _ { \alpha } ( \infty ) \right) = \nabla Q _ { \alpha } \left( f _ { \alpha } ( X ^ { \top } \nu ) \right) = X ^ { \top } \nu
|
| 271 |
+
$$
|
| 272 |
+
|
| 273 |
+
It follows that $\nabla Q _ { \alpha } ( \beta ) = f _ { \alpha } ^ { - 1 } ( \beta )$ . Therefore, to derive $Q _ { \alpha }$ we simply invert $f _ { \alpha }$ and integrate its inverse. We prove Theorems 1 and 3 using this method.
|
| 274 |
+
|
| 275 |
+
Theorem 1. For any $0 < \alpha < \infty$
|
| 276 |
+
|
| 277 |
+
$$
|
| 278 |
+
{ \displaystyle \beta _ { \alpha } ( \infty ) = \hat { \beta } _ { \alpha } \doteq \arg \operatorname* { m i n } _ { \beta } Q _ { \alpha } ( \beta ) \ s . t . \ X \beta = \bf y } ,
|
| 279 |
+
$$
|
| 280 |
+
|
| 281 |
+
$$
|
| 282 |
+
\begin{array} { r } { Q _ { \alpha } \left( \beta \right) = \sum _ { i = 1 } ^ { d } q \left( \frac { \beta _ { i } } { \alpha ^ { 2 } } \right) a n d q ( z ) = \int _ { 0 } ^ { z } \mathrm { a r c s i n h } \left( \frac { u } { 2 } \right) d u = 2 - \sqrt { 4 + z ^ { 2 } } + z \mathrm { a r c s i n h } \left( \frac { z } { 2 } \right) } \end{array}
|
| 283 |
+
$$
|
| 284 |
+
|
| 285 |
+
Proof. We begin by calculating the gradient flow dynamics on w, since the linear predictor $\beta _ { \alpha } ( \infty )$ is given by $F$ applied to the limit of the gradient flow dynamics on w. Recalling that $\tilde { X } = [ X \quad - X ]$ ,
|
| 286 |
+
|
| 287 |
+
$$
|
| 288 |
+
\begin{array} { r } { \dot { \mathbf { w } } _ { \alpha } ( t ) = - \nabla L ( \mathbf { w } _ { \alpha } ( t ) ) = - \nabla \left( \left\| \tilde { X } \mathbf { w } _ { \alpha } ( t ) ^ { 2 } - y \right\| _ { 2 } ^ { 2 } \right) = - 2 \tilde { X } ^ { \top } r _ { \alpha } ( t ) \circ \mathbf { w } _ { \alpha } ( t ) } \end{array}
|
| 289 |
+
$$
|
| 290 |
+
|
| 291 |
+
where the residual $r _ { \alpha } ( t ) \triangleq \tilde { X } \mathbf { w } _ { \alpha } ( t ) ^ { 2 } - y$ , and $a \circ b$ denotes the element-wise product of $a$ and $b$ . It is easily confirmed that these dynamics have a solution:
|
| 292 |
+
|
| 293 |
+
$$
|
| 294 |
+
{ \bf w } _ { \alpha } ( t ) = { \bf w } _ { \alpha } ( 0 ) \circ \exp \left( - 2 \tilde { X } ^ { \top } \int _ { 0 } ^ { t } r _ { \alpha } ( s ) d s \right)
|
| 295 |
+
$$
|
| 296 |
+
|
| 297 |
+
This immediately gives an expression for $\beta _ { \alpha } ( t )$ :
|
| 298 |
+
|
| 299 |
+
$$
|
| 300 |
+
\begin{array} { l } { { \displaystyle { \beta _ { \alpha } ( t ) = { \bf w } _ { \alpha , + } ( t ) ^ { 2 } - { \bf w } _ { \alpha , - } ( t ) ^ { 2 } \qquad } } } \\ { { \displaystyle ~ = \alpha ^ { 2 } \left( \exp \left( - 4 X ^ { \top } \int _ { 0 } ^ { t } r _ { \alpha } ( s ) d s \right) - \exp \left( 4 X ^ { \top } \int _ { 0 } ^ { t } r _ { \alpha } ( s ) d s \right) \right) } } \\ { { \displaystyle ~ = 2 \alpha ^ { 2 } \sinh \left( - 4 X ^ { \top } \int _ { 0 } ^ { t } r _ { \alpha } ( s ) d s \right) } } \end{array}
|
| 301 |
+
$$
|
| 302 |
+
|
| 303 |
+
In addition, this problem satisfies the strict saddle property (Ge et al., 2015) (Zhao et al., 2019, Lemma 2.1), therefore gradient flow will converge to a zero-error solution, i.e. $X \beta _ { \alpha } ( \infty ) = y$ . Thus, we conclude that $\beta _ { \alpha } ( \infty )$ is a global minimum with zero error, i.e. $X \beta _ { \alpha } ( \infty ) = \mathbf { y }$ .
|
| 304 |
+
|
| 305 |
+
Thus, we have established that
|
| 306 |
+
|
| 307 |
+
$$
|
| 308 |
+
\begin{array} { c } { { X \beta _ { \alpha } ( \infty ) = \mathbf { y } } } \\ { { \beta _ { \alpha } ( \infty ) = f _ { \alpha } ( X ^ { \top } \boldsymbol { \nu } ( \infty ) ) } } \end{array}
|
| 309 |
+
$$
|
| 310 |
+
|
| 311 |
+
for $f _ { \alpha } ( z ) = 2 \alpha ^ { 2 } \sinh ( z )$ and $\begin{array} { r } { \nu ( \infty ) = - 4 \int _ { 0 } ^ { t } r _ { \alpha } ( s ) d s } \end{array}$ . This corresponds to (9) from our general approach detailed above. Continuing from (12) we have that
|
| 312 |
+
|
| 313 |
+
$$
|
| 314 |
+
\nabla Q _ { \alpha } ( \beta ) = f _ { \alpha } ^ { - 1 } ( \beta ) = \operatorname { a r c s i n h } \left( \beta / 2 \alpha ^ { 2 } \right)
|
| 315 |
+
$$
|
| 316 |
+
|
| 317 |
+
Integrating this expression completes the proof.
|
| 318 |
+
|
| 319 |
+
# B PROOF OF THEOREM 2
|
| 320 |
+
|
| 321 |
+
Lemma 1. For any $\beta \in \mathbb { R } ^ { d }$
|
| 322 |
+
|
| 323 |
+
$$
|
| 324 |
+
\alpha \leq \alpha _ { 1 } \left( \epsilon , \left. \beta \right. _ { 1 } , d \right) : = \operatorname* { m i n } \left. 1 , \sqrt { \left. \beta \right. _ { 1 } } , \left( 2 \left. \beta \right. _ { 1 } \right) ^ { - \frac { 1 } { 2 \epsilon } } , \exp \left( - \frac { d } { 2 \epsilon \left. \beta \right. _ { 1 } } \right) \right.
|
| 325 |
+
$$
|
| 326 |
+
|
| 327 |
+
guarantees that
|
| 328 |
+
|
| 329 |
+
$$
|
| 330 |
+
\| \beta \| _ { 1 } \left( 1 - \epsilon \right) \le \frac { \alpha ^ { 2 } } { \ln ( 1 / \alpha ^ { 2 } ) } Q ( \beta / \alpha ^ { 2 } ) \le \| \beta \| _ { 1 } \left( 1 + \epsilon \right)
|
| 331 |
+
$$
|
| 332 |
+
|
| 333 |
+
Proof. First, we show that $Q ( \beta / \alpha ^ { 2 } ) = Q _ { \alpha } ( | \beta | / \alpha ^ { 2 } )$ . Observe that $g ( x ) = x \arcsin ( x / 2 )$ is even because $x$ and arcsin $( x / 2 )$ are odd. Therefore,
|
| 334 |
+
|
| 335 |
+
$$
|
| 336 |
+
\begin{array} { l } { { \displaystyle Q ( \beta / \alpha ^ { 2 } ) = \sum _ { i = 1 } ^ { d } 2 - \sqrt { 4 + \frac { \beta _ { i } ^ { 2 } } { \alpha ^ { 4 } } } + \frac { \beta _ { i } } { \alpha ^ { 2 } } \operatorname { a r c s i n h } \left( \frac { \beta _ { i } } { 2 \alpha ^ { 2 } } \right) } } \\ { { \displaystyle ~ = \sum _ { i = 1 } ^ { d } 2 - \sqrt { 4 + \frac { \beta _ { i } ^ { 2 } } { \alpha ^ { 4 } } } + g \left( \frac { \beta _ { i } } { \alpha ^ { 2 } } \right) } } \\ { { \displaystyle ~ = \sum _ { i = 1 } ^ { d } 2 - \sqrt { 4 + \frac { | \beta _ { i } | ^ { 2 } } { \alpha ^ { 4 } } } + g \left( \left| \frac { \beta _ { i } } { \alpha ^ { 2 } } \right| \right) } } \\ { { \displaystyle ~ = Q _ { \alpha } ( | \beta | / \alpha ^ { 2 } ) } } \end{array}
|
| 337 |
+
$$
|
| 338 |
+
|
| 339 |
+
Therefore, we can rewrite
|
| 340 |
+
|
| 341 |
+
$$
|
| 342 |
+
{ \begin{array} { r l } { { \frac { \alpha ^ { 2 } } { \ln ( 1 / \alpha ^ { 2 } ) } } Q ( \beta / \alpha ^ { 2 } ) = { \frac { \alpha ^ { 2 } } { \ln ( 1 / \alpha ^ { 2 } ) } } Q ( | \beta | / \alpha ^ { 2 } ) } \\ & { = \displaystyle \sum _ { i = 1 } ^ { d } { \frac { 2 \alpha ^ { 2 } } { \ln ( 1 / \alpha ^ { 2 } ) } } - { \frac { { \sqrt { 4 \alpha ^ { 4 } + \beta _ { i } ^ { 2 } } } } { \ln ( 1 / \alpha ^ { 2 } ) } } + { \frac { | \beta _ { i } | } { \ln ( 1 / \alpha ^ { 2 } ) } } \operatorname { a r c s i n h } \left( { \frac { | \beta _ { i } | } { 2 \alpha ^ { 2 } } } \right) } \\ & { = \displaystyle \sum _ { i = 1 } ^ { d } { \frac { 2 \alpha ^ { 2 } } { \ln ( 1 / \alpha ^ { 2 } ) } } - { \frac { { \sqrt { 4 \alpha ^ { 4 } + \beta _ { i } ^ { 2 } } } } { \ln ( 1 / \alpha ^ { 2 } ) } } + { \frac { | \beta _ { i } | } { \ln ( 1 / \alpha ^ { 2 } ) } } \ln \left( { \frac { | \beta _ { i } | } { 2 \alpha ^ { 2 } } } + { \sqrt { 1 + { \frac { \beta _ { i } ^ { 2 } } { 4 \alpha ^ { 4 } } } } } \right) } \\ & { = \displaystyle \sum _ { i = 1 } ^ { d } { \frac { 2 \alpha ^ { 2 } } { \ln ( 1 / \alpha ^ { 2 } ) } } - { \frac { { \sqrt { 4 \alpha ^ { 4 } + \beta _ { i } ^ { 2 } } } } { \ln ( 1 / \alpha ^ { 2 } ) } } + | \beta _ { i } | \left( 1 + { \frac { \ln \left( { \frac { | \beta _ { i } | } { 2 } } + { \sqrt { \alpha ^ { 4 } + { \frac { \beta _ { i } ^ { 2 } } { 4 } } } } \right) } { \ln ( 1 / \alpha ^ { 2 } ) } } \right) } \end{array} }
|
| 343 |
+
$$
|
| 344 |
+
|
| 345 |
+
Using the fact that
|
| 346 |
+
|
| 347 |
+
$$
|
| 348 |
+
\left| a \right| \leq \sqrt { a ^ { 2 } + b ^ { 2 } } \leq \left| a \right| + \left| b \right|
|
| 349 |
+
$$
|
| 350 |
+
|
| 351 |
+
we can bound for $\alpha < 1$
|
| 352 |
+
|
| 353 |
+
$$
|
| 354 |
+
\begin{array} { r l } { \displaystyle \frac { \alpha ^ { 2 } } { \ln ( 1 / \alpha ^ { 2 } ) } Q ( \beta / \alpha ^ { 2 } ) \le \sum _ { i = 1 } ^ { d } \displaystyle \frac { 2 \alpha ^ { 2 } } { \ln ( 1 / \alpha ^ { 2 } ) } - \frac { 2 \alpha ^ { 2 } } { \ln ( 1 / \alpha ^ { 2 } ) } + | \beta _ { i } | \left( 1 + \frac { \ln \left( \frac { | \beta _ { i } | } { 2 } + \alpha ^ { 2 } + \frac { | \beta _ { i } | } { 2 } \right) } { \ln ( 1 / \alpha ^ { 2 } ) } \right) } & { } \\ { \displaystyle } & { = \sum _ { i = 1 } ^ { d } | \beta _ { i } | \left( 1 + \frac { \ln \left( | \beta _ { i } | + \alpha ^ { 2 } \right) } { \ln ( 1 / \alpha ^ { 2 } ) } \right) } \\ { \displaystyle } & { \le \| \beta \| _ { 1 } \left( 1 + \operatorname* { m a x } _ { i \in [ d ] } \frac { \ln \left( | \beta _ { i } | + \alpha ^ { 2 } \right) } { \ln ( 1 / \alpha ^ { 2 } ) } \right) } \\ { \displaystyle } & { \le \| \beta \| _ { 1 } \left( 1 + \frac { \ln \left( \| \beta \| _ { 1 } + \alpha ^ { 2 } \right) } { \ln ( 1 / \alpha ^ { 2 } ) } \right) } \end{array}
|
| 355 |
+
$$
|
| 356 |
+
|
| 357 |
+
So, for any $\alpha \leq \operatorname* { m i n } \left. 1 , \sqrt { \| \beta \| _ { 1 } } , ( 2 \| \beta \| _ { 1 } ) ^ { - \frac { 1 } { 2 \epsilon } } \right.$ , then
|
| 358 |
+
|
| 359 |
+
$$
|
| 360 |
+
\begin{array} { l } { \displaystyle \frac { \alpha ^ { 2 } } { \ln \left( 1 / \alpha ^ { 2 } \right) } Q ( \beta / \alpha ^ { 2 } ) \leq \| \beta \| _ { 1 } \left( 1 + \frac { \ln \left( \| \beta \| _ { 1 } + \alpha ^ { 2 } \right) } { \ln ( 1 / \alpha ^ { 2 } ) } \right) } \\ { \leq \| \beta \| _ { 1 } \left( 1 + \frac { \ln \left( 2 \| \beta \| _ { 1 } \right) } { \ln ( 1 / \alpha ^ { 2 } ) } \right) } \\ { \leq \| \beta \| _ { 1 } \left( 1 + \epsilon \right) } \end{array}
|
| 361 |
+
$$
|
| 362 |
+
|
| 363 |
+
On the other hand, using (27) and (28) again,
|
| 364 |
+
|
| 365 |
+
$$
|
| 366 |
+
\begin{array} { l } { \displaystyle \frac { \alpha ^ { 2 } } { \ln ( 1 / \alpha ^ { 2 } ) } Q ( \beta / \alpha ^ { 2 } ) \geq \displaystyle \sum _ { i = 1 } ^ { d } \frac { 2 \alpha ^ { 2 } } { \ln ( 1 / \alpha ^ { 2 } ) } - \frac { | \beta _ { i } | + 2 \alpha ^ { 2 } } { \ln ( 1 / \alpha ^ { 2 } ) } + | \beta _ { i } | \left( 1 + \frac { \ln \left( | \beta _ { i } | \right) } { \ln ( 1 / \alpha ^ { 2 } ) } \right) } \\ { \displaystyle = \sum _ { i = 1 } ^ { d } | \beta _ { i } | \left( 1 + \frac { \ln \left( | \beta _ { i } | \right) - 1 } { \ln ( 1 / \alpha ^ { 2 } ) } \right) } \end{array}
|
| 367 |
+
$$
|
| 368 |
+
|
| 369 |
+
Using the inequality $\begin{array} { r } { \ln ( x ) \geq 1 - \frac { 1 } { x } } \end{array}$ , this can be further lower bounded by
|
| 370 |
+
|
| 371 |
+
$$
|
| 372 |
+
\begin{array} { r l r } { { \frac { \alpha ^ { 2 } } { \ln ( 1 / \alpha ^ { 2 } ) } Q ( \beta / \alpha ^ { 2 } ) \geq \sum _ { i = 1 } ^ { d } | \beta _ { i } | - \frac { 1 } { \ln ( 1 / \alpha ^ { 2 } ) } } } \\ & { } & { = \| \beta \| _ { 1 } - \frac { d } { \ln ( 1 / \alpha ^ { 2 } ) } } \end{array}
|
| 373 |
+
$$
|
| 374 |
+
|
| 375 |
+
$\begin{array} { r } { \alpha \le \exp \left( - \frac { d } { 2 \epsilon \| \beta \| _ { 1 } } \right) } \end{array}$
|
| 376 |
+
|
| 377 |
+
$$
|
| 378 |
+
\frac { \alpha ^ { 2 } } { \ln ( 1 / \alpha ^ { 2 } ) } Q ( \beta / \alpha ^ { 2 } ) \geq \| \beta \| _ { 1 } \left( 1 - \epsilon \right)
|
| 379 |
+
$$
|
| 380 |
+
|
| 381 |
+
We conclude that for $\begin{array} { r } { \alpha \leq \operatorname* { m i n } \left. 1 , \sqrt { \| \beta \| _ { 1 } } , ( 2 \| \beta \| _ { 1 } ) ^ { - \frac { 1 } { 2 \epsilon } } , \exp \left( - \frac { d } { 2 \epsilon \| \beta \| _ { 1 } } \right) \right. } \end{array}$
|
| 382 |
+
|
| 383 |
+
$$
|
| 384 |
+
\| \beta \| _ { 1 } \left( 1 - \epsilon \right) \le \frac { \alpha ^ { 2 } } { \ln ( 1 / \alpha ^ { 2 } ) } Q ( \beta / \alpha ^ { 2 } ) \le \| \beta \| _ { 1 } \left( 1 + \epsilon \right)
|
| 385 |
+
$$
|
| 386 |
+
|
| 387 |
+
Lemma 2. Fix any $\epsilon > 0$ and $d \geq \operatorname* { m a x } \left. e , 1 2 ^ { 4 \epsilon } \right.$ . Then for any $\alpha \geq d ^ { - \frac { 1 } { 4 } - \frac { 1 } { 8 \epsilon } }$ , $Q ( \beta / \alpha ^ { 2 } ) \not \propto \| \beta \| _ { 1 } i n$ the sense that there exist vectors $v , w$ such that
|
| 388 |
+
|
| 389 |
+
$$
|
| 390 |
+
{ \frac { Q \left( { \frac { 1 } { \alpha ^ { 2 } } } v \right) } { \left\| v \right\| _ { 1 } } } \geq ( 1 + \epsilon ) { \frac { Q \left( { \frac { 1 } { \alpha ^ { 2 } } } w \right) } { \left\| w \right\| _ { 1 } } }
|
| 391 |
+
$$
|
| 392 |
+
|
| 393 |
+
Proof. First, recall that
|
| 394 |
+
|
| 395 |
+
$$
|
| 396 |
+
\begin{array} { l } { { q \left( \displaystyle \frac { 1 } { c \alpha ^ { 2 } } \right) = 2 - \sqrt { 4 + \displaystyle \frac { 1 } { c ^ { 2 } \alpha ^ { 4 } } } + \displaystyle \frac { 1 } { c \alpha ^ { 2 } } \operatorname { a r c s i n h } \left( \displaystyle \frac { 1 } { 2 c \alpha ^ { 2 } } \right) } } \\ { { = \displaystyle \frac { 1 } { c \alpha ^ { 2 } } \left( 2 c \alpha ^ { 2 } - \sqrt { 4 c ^ { 2 } \alpha ^ { 4 } + 1 } + \ln \left( \displaystyle \frac { 1 } { 2 c \alpha ^ { 2 } } + \sqrt { 1 + \displaystyle \frac { 1 } { 4 c ^ { 2 } \alpha ^ { 4 } } } \right) \right) } } \\ { { = \displaystyle \frac { 1 } { c \alpha ^ { 2 } } \left( 2 c \alpha ^ { 2 } - \sqrt { 4 c ^ { 2 } \alpha ^ { 4 } + 1 } + \ln \left( \displaystyle \frac { 1 } { c \alpha ^ { 2 } } \right) + \ln \left( \displaystyle \frac { 1 } { 2 } + \sqrt { c ^ { 2 } \alpha ^ { 4 } + \displaystyle \frac { 1 } { 2 } } \right) \right) } } \end{array}
|
| 397 |
+
$$
|
| 398 |
+
|
| 399 |
+
Thus,
|
| 400 |
+
|
| 401 |
+
$$
|
| 402 |
+
- 1 + \ln \left( \frac { 1 } { c \alpha ^ { 2 } } \right) \le c \alpha ^ { 2 } q \left( \frac { 1 } { c \alpha ^ { 2 } } \right) \le 3 c \alpha ^ { 2 } - 1 + \ln \left( \frac { 1 } { c \alpha ^ { 2 } } \right)
|
| 403 |
+
$$
|
| 404 |
+
|
| 405 |
+
Now, consider the ratio
|
| 406 |
+
|
| 407 |
+
$$
|
| 408 |
+
{ \begin{array} { r l } & { { \frac { Q \left( { \frac { 1 } { \alpha ^ { 2 } } } e _ { 1 } \right) } { Q \left( { \frac { 1 } { \alpha ^ { 2 } } } { \frac { \mathbf { 1 } _ { d } } { \| \mathbf { 1 } _ { d } \| _ { 2 } } } \right) } } = { \frac { q \left( { \frac { 1 } { \alpha ^ { 2 } } } \right) } { d q \left( { \frac { 1 } { \alpha ^ { 2 } { \sqrt { d } } } } \right) } } } \\ & { \qquad = { \frac { 1 } { \sqrt { d } } } { \frac { \alpha ^ { 2 } q \left( { \frac { 1 } { \alpha ^ { 2 } } } \right) } { \alpha ^ { 2 } { \sqrt { d } } q \left( { \frac { 1 } { \alpha ^ { 2 } { \sqrt { d } } } } \right) } } } \end{array} }
|
| 409 |
+
$$
|
| 410 |
+
|
| 411 |
+
Using (46), we conclude
|
| 412 |
+
|
| 413 |
+
$$
|
| 414 |
+
\begin{array} { r l r } & { } & { \sqrt { d } \frac { Q \left( \frac { 1 } { \alpha ^ { 2 } } e _ { 1 } \right) } { Q \left( \frac { 1 } { \alpha ^ { 2 } } \frac { 1 } { \| \mathbf { 1 } _ { d } \| _ { 2 } } \right) } \ge \frac { - 1 + \ln \left( \frac { 1 } { \alpha ^ { 2 } } \right) } { 3 \sqrt { d } \alpha ^ { 2 } - 1 + \ln \left( \frac { 1 } { \alpha ^ { 2 } \sqrt { d } } \right) } \qquad } \\ & { } & { = \frac { - 1 + \ln \left( \frac { 1 } { \alpha ^ { 2 } } \right) } { 3 \sqrt { d } \alpha ^ { 2 } - 1 + \ln \left( \frac { 1 } { \alpha ^ { 2 } } \right) - \frac { 1 } { 2 } \ln ( d ) } } \\ & { } & { = 1 + \frac { \ln ( d ) - 6 \sqrt { d } \alpha ^ { 2 } } { 6 \sqrt { d } \alpha ^ { 2 } - 2 + 2 \ln \left( \frac { 1 } { \alpha ^ { 2 } \sqrt { d } } \right) } } \end{array}
|
| 415 |
+
$$
|
| 416 |
+
|
| 417 |
+
Fix any $\epsilon > 0$ and $d \geq \operatorname* { m a x } \left\{ e , 1 2 ^ { 4 \epsilon } \right\}$ , and set $\alpha = d ^ { - \frac { 1 } { 4 } - \frac { 1 } { 8 \epsilon } }$ . Then
|
| 418 |
+
|
| 419 |
+
$$
|
| 420 |
+
\begin{array} { r l r } { \ } & { \ } & { 2 d ^ { \frac { 1 } { 4 \epsilon } } \geq 6 \quad \mathrm { a n d } \quad \frac { d ^ { \frac { 1 } { 4 \epsilon } } } { 2 } \ln d \geq 6 } \\ & { \implies 2 d ^ { \frac { 1 } { 4 \epsilon } } - 6 + \frac { d ^ { \frac { 1 } { 4 \epsilon } } } { 2 \epsilon } \ln d - \frac { 6 } { \epsilon } \geq 0 } \\ & { \implies \Big ( \frac { 1 } { \epsilon } - \frac { 1 } { 2 \epsilon } \Big ) \ln d - \frac { 6 } { \epsilon } d ^ { - \frac { 1 } { 4 \epsilon } } \geq 6 d ^ { - \frac { 1 } { 4 \epsilon } } - 2 } \\ & { \implies \frac { 1 } { \epsilon } \ln d - \frac { 6 } { \epsilon } d ^ { - \frac { 1 } { 4 \epsilon } } \geq 6 d ^ { - \frac { 1 } { 4 \epsilon } } - 2 + \frac { 1 } { 2 \epsilon } \ln d } \\ & { \implies \ln \left( d \right) - 6 \alpha ^ { 2 } \sqrt { d } \geq \epsilon \left( 6 \alpha ^ { 2 } \sqrt { d } - 2 + 2 \ln \left( \frac { 1 } { \alpha ^ { 2 } \sqrt { d } } \right) \right) } \end{array}
|
| 421 |
+
$$
|
| 422 |
+
|
| 423 |
+
This implies that the second term of (51) is at least $\epsilon$ . We conclude that for any $\epsilon > 0$ and $d \geq$ max $\{ e , 1 2 ^ { 4 \epsilon } \}$ , $\alpha = d ^ { - \frac { 1 } { 4 } - \frac { 1 } { 8 \epsilon } }$ implies that
|
| 424 |
+
|
| 425 |
+
$$
|
| 426 |
+
\frac { Q \left( \frac { 1 } { \alpha ^ { 2 } } e _ { 1 } \right) } { Q \left( \frac { 1 } { \alpha ^ { 2 } } \frac { \mathbf { 1 } _ { d } } { \left\| \mathbf { 1 } _ { d } \right\| _ { 2 } } \right) } \geq ( 1 + \epsilon ) \frac { \left\| e _ { 1 } \right\| _ { 1 } } { \left\| \frac { \mathbf { 1 } _ { d } } { \left\| \mathbf { 1 } _ { d } \right\| _ { 2 } } \right\| _ { 1 } }
|
| 427 |
+
$$
|
| 428 |
+
|
| 429 |
+
Consequently, for at least one of these two vectors, $Q$ is not proportional to the $\ell _ { 1 }$ norm up to accuracy $O ( \epsilon )$ for this value of $\alpha$ .
|
| 430 |
+
|
| 431 |
+
It is straightforward to confirm that
|
| 432 |
+
|
| 433 |
+
$$
|
| 434 |
+
\frac { d } { d \alpha } \frac { Q \left( \frac { 1 } { \alpha ^ { 2 } } e _ { 1 } \right) } { Q \left( \frac { 1 } { \alpha ^ { 2 } } \frac { 1 _ { d } } { \left\| \mathbf { 1 } _ { d } \right\| _ { 2 } } \right) } \ge 0
|
| 435 |
+
$$
|
| 436 |
+
|
| 437 |
+
which concludes the proof.
|
| 438 |
+
|
| 439 |
+
Lemma 3. For any $\beta \in \mathbb { R } ^ { d }$ ,
|
| 440 |
+
|
| 441 |
+
$$
|
| 442 |
+
\alpha \ge \alpha _ { 2 } ( \epsilon , \| w \| _ { 2 } ) : = \sqrt { \| \beta \| _ { 2 } } \left( 1 + \epsilon ^ { - \frac { 1 } { 4 } } \right)
|
| 443 |
+
$$
|
| 444 |
+
|
| 445 |
+
guarantees that
|
| 446 |
+
|
| 447 |
+
$$
|
| 448 |
+
\left( 1 - \epsilon \right) \left\| \beta \right\| _ { 2 } ^ { 2 } \leq 4 \alpha ^ { 4 } Q ( \beta / \alpha ^ { 2 } ) \leq ( 1 + \epsilon ) \left\| \beta \right\| _ { 2 } ^ { 2 }
|
| 449 |
+
$$
|
| 450 |
+
|
| 451 |
+
Proof. The regularizer $Q$ can be written
|
| 452 |
+
|
| 453 |
+
$$
|
| 454 |
+
Q ( \beta / \alpha ^ { 2 } ) = \sum _ { i = 1 } ^ { d } \int _ { 0 } ^ { \beta _ { i } / \alpha ^ { 2 } } \mathrm { a r c s i n h } \left( { \frac { t } { 2 } } \right) d t
|
| 455 |
+
$$
|
| 456 |
+
|
| 457 |
+
Let $\begin{array} { r } { \phi ( z ) = \int _ { 0 } ^ { z / \alpha ^ { 2 } } \ d z } \end{array}$ arcsinh $\left( { \frac { t } { 2 } } \right) d t$ , then
|
| 458 |
+
|
| 459 |
+
$$
|
| 460 |
+
\begin{array} { c } { { \phi ( 0 ) = 0 } } \\ { { \left. \begin{array} { l } { { \phi ^ { \prime } ( 0 ) = { \frac { 1 } { \alpha ^ { 2 } } } } } \\ { { \left( { \frac { \mathcal { Z } } { \partial \alpha ^ { 2 } } } \right) ^ { \mathrm { a r c s i n h } } \left( { \frac { \mathcal { Z } } { \mathrm { 2 } \alpha ^ { 2 } } } \right) } \end{array} _ { z = 0 } = 0 } } } \\ \right| { { \left. \begin{array} { l } { { \phi ^ { \prime \prime } ( 0 ) = { \frac { 1 } { \alpha ^ { 4 } \sqrt { 4 + { \frac { { \mathcal { Z } } } { \alpha ^ { 2 } } } } } } } } \\ { { \left( { \mathcal { S } ^ { \prime \prime } ( 0 ) = { \frac { - { \mathcal { Z } } } { \alpha ^ { 8 } } } } \right) ^ { \mathrm { b / { Z } } } } } \end{array} \right| _ { z = 0 } = { \frac { 1 } { 2 \alpha ^ { 4 } } } } } \\ { { { \left. \begin{array} { l } { { \phi ^ { \prime \prime \prime } ( 0 ) = { \frac { - { \mathcal { Z } } } { \alpha ^ { 8 } \left( 4 + { \frac { { \mathcal { Z } } } { \alpha ^ { 2 } } } \right) ^ { 3 / 2 } } } } } \\ { { \left( { \mathcal { S } ^ { \prime \prime } ( z ) = { \frac { 1 } { \alpha ^ { 1 2 } } } } \right) ^ { \mathrm { b / { Z } } } { \left( 4 + { \frac { { \mathcal { Z } } ^ { 2 } } { \alpha ^ { 4 } } } \right) } ^ { \mathrm { b / { Z } } } { \left( - { \frac { 1 } { \alpha ^ { 8 } \left( 4 + { \frac { { \mathcal { Z } } } { \alpha ^ { 4 } } } \right)} ^ { 3 / 2 } } \right)} } } \end{array} \right| _ { z = 0 } = 0 } } } \end{array}
|
| 461 |
+
$$
|
| 462 |
+
|
| 463 |
+
Also, note that
|
| 464 |
+
|
| 465 |
+
$$
|
| 466 |
+
\begin{array} { c } { | \phi ^ { \prime \prime \prime \prime } ( z ) | = \displaystyle \frac { \left| 2 z ^ { 2 } - 4 \alpha ^ { 4 } \right| } { \alpha ^ { 1 2 } \left( 4 + \frac { z ^ { 2 } } { \alpha ^ { 4 } } \right) ^ { 5 / 2 } } } \\ { \leq \displaystyle \frac { z ^ { 2 } + 2 \alpha ^ { 4 } } { 1 6 \alpha ^ { 1 2 } } } \end{array}
|
| 467 |
+
$$
|
| 468 |
+
|
| 469 |
+
Therefore, by Taylor’s theorem, for some $\xi$ with $| \xi | \leq | z |$
|
| 470 |
+
|
| 471 |
+
$$
|
| 472 |
+
\begin{array} { r l r } & { } & { \left| \phi ( z ) - { \frac { z ^ { 2 } } { 4 \alpha ^ { 4 } } } \right| = { \frac { \phi ^ { \prime \prime \prime \prime } ( \xi ) } { 4 ! } } z ^ { 4 } } \\ & { } & { \implies \left| \phi ( z ) - { \frac { z ^ { 2 } } { 4 \alpha ^ { 4 } } } \right| \le \displaystyle \operatorname* { s u p } _ { | \xi | \le | z | } { \frac { \phi ^ { \prime \prime \prime \prime } ( \xi ) } { 4 ! } } z ^ { 4 } \le { \frac { z ^ { 6 } + 2 \alpha ^ { 4 } z ^ { 4 } } { 3 8 4 \alpha ^ { 1 2 } } } = { \frac { z ^ { 2 } } { 4 \alpha ^ { 4 } } } { \frac { z ^ { 4 } + 2 \alpha ^ { 4 } z ^ { 2 } } { 9 6 \alpha ^ { 8 } } } } \end{array}
|
| 473 |
+
$$
|
| 474 |
+
|
| 475 |
+
Therefore, for any $\beta \in \mathbb { R } ^ { d }$
|
| 476 |
+
|
| 477 |
+
$$
|
| 478 |
+
\begin{array} { l } { \displaystyle \big \| \alpha ^ { 4 } Q _ { \alpha } ( \beta ) - \| \beta \| _ { 2 } ^ { 2 } \\Big | = 4 \alpha ^ { 4 } \left| \displaystyle \sum _ { i = 1 } ^ { d } \phi ( \beta _ { i } ) - \displaystyle \frac { \beta _ { i } ^ { 2 } } { 4 \alpha ^ { 4 } } \right| } \\ { \displaystyle \qquad \leq 4 \alpha ^ { 4 } \displaystyle \sum _ { i = 1 } ^ { d } \left| \phi ( \beta _ { i } ) - \displaystyle \frac { \beta _ { i } ^ { 2 } } { 4 \alpha ^ { 4 } } \right| } \\ { \displaystyle \qquad \leq \displaystyle \sum _ { i = 1 } ^ { d } \beta _ { i } ^ { 2 } \cdot \displaystyle \frac { \beta _ { i } ^ { 4 } + 2 \alpha ^ { 4 } \beta _ { i } ^ { 2 } } { 9 6 \alpha ^ { 8 } } } \\ { \displaystyle \qquad \leq \| \beta \| _ { 2 \operatorname* { m a x } } ^ { 2 } \beta _ { i } ^ { 4 } + 2 \alpha ^ { 4 } \beta _ { i } ^ { 2 } } \end{array}
|
| 479 |
+
$$
|
| 480 |
+
|
| 481 |
+
Therefore, $\alpha \geq \sqrt { \| \beta \| _ { 2 } } \left( 1 + \epsilon ^ { - \frac { 1 } { 4 } } \right)$ ensures
|
| 482 |
+
|
| 483 |
+
$$
|
| 484 |
+
\left( 1 - \epsilon \right) \left\| \beta \right\| _ { 2 } ^ { 2 } \leq 4 \alpha ^ { 4 } Q ( \beta / \alpha ^ { 2 } ) \leq ( 1 + \epsilon ) \left\| \beta \right\| _ { 2 } ^ { 2 }
|
| 485 |
+
$$
|
| 486 |
+
|
| 487 |
+
Theorem 2. For any $0 < \epsilon < d$
|
| 488 |
+
|
| 489 |
+
$$
|
| 490 |
+
\begin{array} { r l } & { \alpha \leq \operatorname* { m i n } \left. \left( 2 ( 1 + \epsilon ) \| \beta _ { L 1 } ^ { * } \| _ { 1 } \right) ^ { - \frac { 2 + \epsilon } { 2 \epsilon } } , \exp \left( - d / ( \epsilon \| \beta _ { L 1 } ^ { * } \| _ { 1 } ) \right) \right. \implies \| \hat { \beta } _ { \alpha } \| _ { 1 } \leq ( 1 + \epsilon ) \| \beta _ { L 1 } ^ { * } \| _ { 1 } } \\ & { \qquad \alpha \geq \sqrt { 2 ( 1 + \epsilon ) ( 1 + 2 / \epsilon ) \| \beta _ { L 2 } ^ { * } \| _ { 2 } } \implies \| \hat { \beta } _ { \alpha } \| _ { 2 } ^ { 2 } \leq ( 1 + \epsilon ) \| \beta _ { L 2 } ^ { * } \| _ { 2 } ^ { 2 } } \end{array}
|
| 491 |
+
$$
|
| 492 |
+
|
| 493 |
+
Proof. We prove the $\ell _ { 1 }$ and $\ell _ { 2 }$ statements separately.
|
| 494 |
+
|
| 495 |
+
$\ell _ { 1 }$ approximation First, we will prove that $\left\| \hat { \beta } _ { \alpha } \right\| _ { 1 } < ( 1 + 2 \epsilon ) \| \beta _ { L 1 } ^ { * } \| _ { 1 }$ . By Lemma 1, since $\alpha \leq$ $\alpha _ { 1 } \left( \frac { \epsilon } { 2 + \epsilon } , ( 1 + 2 \epsilon ) \| \beta _ { L 1 } ^ { * } \| _ { 1 } , d \right)$ , for all $\beta$ with $\left\| \beta \right\| _ { 1 } \leq \left( 1 + 2 \epsilon \right) \left\| \beta _ { L 1 } ^ { * } \right\| _ { 1 }$ we have
|
| 496 |
+
|
| 497 |
+
$$
|
| 498 |
+
\| \beta \| _ { 1 } \left( 1 - \frac { \epsilon } { 2 + \epsilon } \right) \le \frac { \alpha ^ { 2 } } { \ln ( 1 / \alpha ^ { 2 } ) } Q ( \beta / \alpha ^ { 2 } ) \le \| \beta \| _ { 1 } \left( 1 + \frac { \epsilon } { 2 + \epsilon } \right)
|
| 499 |
+
$$
|
| 500 |
+
|
| 501 |
+
Let $\beta$ be such that $X \beta = y$ and $\| \beta \| _ { 1 } = \left( 1 + 2 \epsilon \right) \| \beta _ { L 1 } ^ { * } \| _ { 1 }$ . Then
|
| 502 |
+
|
| 503 |
+
$$
|
| 504 |
+
\begin{array} { r l } { \frac { \alpha ^ { 2 } } { \ln ( 1 / \mu ^ { 2 } ) } Q ( \beta / \alpha ^ { 2 } ) \geq \left( 1 - \frac { \epsilon } { 2 + \epsilon } \right) \| \beta \| _ { 1 } } & { } \\ & { = \left( 1 - \frac { \epsilon } { 2 + \epsilon } \right) \left( 1 + 2 \epsilon \right) \| \beta _ { \Delta ^ { * } } ^ { * } \| _ { 1 } } \\ & { \geq \frac { \left( 1 - \frac { \epsilon } { 2 + \epsilon } \right) } { \left( 1 + \frac { \epsilon } { 2 + \epsilon } \right) } ( 1 + 2 \epsilon ) \frac { \alpha ^ { 2 } } { \ln ( 1 / \mu ^ { 2 } ) } Q ( \beta _ { L _ { 1 } / \alpha ^ { 2 } } ^ { * } ) } \\ & { = \frac { 1 + 2 \epsilon } { 1 + \epsilon } \frac { \alpha ^ { 2 } } { \ln ( 1 / \mu ^ { 2 } ) } Q ( \beta _ { L _ { 1 } / \alpha ^ { 2 } } ^ { * } ) } \\ & { > \frac { \alpha ^ { 2 } } { \ln ( 1 / \mu ^ { 2 } ) } Q ( \beta _ { \Delta ^ { * } } ^ { * } / \alpha ^ { 2 } ) } \\ & { \geq \frac { \alpha ^ { 2 } } { \ln ( 1 / \mu ^ { 2 } ) ^ { 2 } } Q ( \beta _ { \Delta ^ { * } } / \alpha ^ { 2 } ) } \end{array}
|
| 505 |
+
$$
|
| 506 |
+
|
| 507 |
+
Therefore, $\beta \neq \hat { \beta } _ { \alpha }$ . Furthermore, let $\beta$ be any solution $X \beta = y$ with $\| \beta \| _ { 1 } > ( 1 + 2 \epsilon ) \| \beta _ { L 1 } ^ { * } \| _ { 1 }$ . It is easily confirmed that there exists $c \in \mathsf { \Gamma } ( 0 , 1 )$ such that the point $\beta ^ { \prime } ~ = ~ ( 1 - c ) \beta + c \beta _ { L 1 } ^ { * }$ is satisfies both $X \beta ^ { \prime } = y$ and $\| \beta ^ { \prime } \| _ { 1 } = \left( 1 + 2 \epsilon \right) \| \beta _ { L 1 } ^ { * } \| _ { 1 }$ . By the convexity of $Q$ , this implies $Q ( \beta / \alpha ^ { 2 } ) \ge Q ( \beta ^ { \prime } / \alpha ^ { 2 } ) > Q _ { \alpha } ( \hat { \beta } _ { \alpha } / \alpha ^ { 2 } )$ . Thus a $\beta$ with a large $\ell _ { 1 }$ norm cannot be a solution, even if $\frac { \alpha ^ { 2 } } { \ln ( 1 / \alpha ^ { 2 } ) } Q ( \beta / \alpha ^ { 2 } ) \not \approx \| \beta \| _ { 1 }$ .
|
| 508 |
+
|
| 509 |
+
Since $\left\| \hat { \beta } _ { \alpha } \right\| _ { 1 } < ( 1 + 2 \epsilon ) \| \beta _ { L 1 } ^ { * } \| _ { 1 }$ , we conclude
|
| 510 |
+
|
| 511 |
+
$$
|
| 512 |
+
\begin{array} { r l } & { \left\| \hat { \beta } _ { \alpha } \right\| _ { 1 } \le \displaystyle \frac { 1 } { 1 - \frac { \epsilon } { 2 + \epsilon } } \frac { \alpha ^ { 2 } } { \ln ( 1 / \alpha ^ { 2 } ) } Q ( \hat { \beta } _ { \alpha } / \alpha ^ { 2 } ) } \\ & { \qquad \le \displaystyle \frac { 1 } { 1 - \frac { \epsilon } { 2 + \epsilon } } \frac { \alpha ^ { 2 } } { \ln ( 1 / \alpha ^ { 2 } ) } Q ( \beta _ { L 1 } ^ { * } / \alpha ^ { 2 } ) } \\ & { \qquad \le \displaystyle \frac { 1 + \frac { \epsilon } { 2 + \epsilon } } { 1 - \frac { \epsilon } { 2 + \epsilon } } \| \beta _ { L 1 } ^ { * } \| _ { 1 } } \\ & { \qquad = ( 1 + \epsilon ) \| \beta _ { L 1 } ^ { * } \| _ { 1 } } \end{array}
|
| 513 |
+
$$
|
| 514 |
+
|
| 515 |
+
First, we will prove that $\begin{array} { r l r } { \left\| \hat { \beta } _ { \alpha } \right\| _ { 2 } } & { { } < } & { ( 1 + 2 \epsilon ) \left\| \beta _ { L 2 } ^ { * } \right\| _ { 2 } } \end{array}$ . By Lemma 3, since $\alpha \_ { } \geq$ $\begin{array} { r } { \alpha _ { 2 } \left( \frac { \epsilon } { 2 + \epsilon } , ( 1 + 2 \epsilon ) \left\| \beta _ { L 2 } ^ { * } \right\| _ { 2 } \right) } \end{array}$ , for all $\beta$ with $\left\| \beta \right\| _ { 2 } \leq \left( 1 + 2 \epsilon \right) \left\| \beta _ { L 2 } ^ { * } \right\| _ { 2 }$ we have
|
| 516 |
+
|
| 517 |
+
$$
|
| 518 |
+
\left\| \beta \right\| _ { 2 } ^ { 2 } \left( 1 - \frac { \epsilon } { 2 + \epsilon } \right) \leq 4 \alpha ^ { 4 } Q ( \beta / \alpha ^ { 2 } ) \leq \left\| \beta \right\| _ { 2 } ^ { 2 } \left( 1 + \frac { \epsilon } { 2 + \epsilon } \right)
|
| 519 |
+
$$
|
| 520 |
+
|
| 521 |
+
Let $\beta$ be such that $X \beta = y$ and $\left\| \beta \right\| _ { 2 } = \left( 1 + 2 \epsilon \right) \left\| \beta _ { L 2 } ^ { * } \right\| _ { 2 }$ . Then
|
| 522 |
+
|
| 523 |
+
$$
|
| 524 |
+
\begin{array} { r l } & { 4 \alpha ^ { 4 } Q ( \beta / \alpha ^ { 2 } ) \geq \left( 1 - \frac { \epsilon } { 2 + \epsilon } \right) \| \beta \| _ { 2 } ^ { 2 } } \\ & { \quad \quad \quad = \left( 1 - \frac { \epsilon } { 2 + \epsilon } \right) \left( 1 + 2 \epsilon \right) \| \beta _ { L ^ { 2 } } ^ { * } \| _ { 2 } ^ { 2 } } \\ & { \quad \quad \quad \geq \frac { \left( 1 - \frac { \epsilon } { 2 + \epsilon } \right) } { \left( 1 + \frac { \epsilon } { 2 + \epsilon } \right) } ( 1 + 2 \epsilon ) 4 \alpha ^ { 4 } Q ( \beta _ { L 2 } ^ { * } / \alpha ^ { 2 } ) } \\ & { \quad \quad \quad = \frac { 1 + 2 \epsilon } { 1 + \epsilon } 4 \alpha ^ { 4 } Q ( \beta _ { L 2 } ^ { * } / \alpha ^ { 2 } ) } \\ & { \quad \quad \quad > 4 \alpha ^ { 4 } Q ( \beta _ { L 2 } ^ { * } / \alpha ^ { 2 } ) } \\ & { \quad \quad \quad \geq 4 \alpha ^ { 4 } Q ( \beta _ { \delta \alpha } ^ { * } / \alpha ^ { 2 } ) } \end{array}
|
| 525 |
+
$$
|
| 526 |
+
|
| 527 |
+
Therefore, $\beta \neq \hat { \beta } _ { \alpha }$ . Furthermore, let $\beta$ be any solution $X \beta = y$ with $\left\| \beta \right\| _ { 2 } > \left( 1 + 2 \epsilon \right) \left\| \beta _ { L 2 } ^ { * } \right\| _ { 2 }$ . It is easily confirmed that there exists $c \in ( 0 , 1 )$ such that the point $\beta ^ { \prime } = ( 1 - c \bar { ) } \beta + c \beta _ { \bot 2 } ^ { \ast }$ satisfies $\bar { X } \beta ^ { \prime } =$ $y$ and $\| \beta ^ { \prime } \| _ { 2 } = \left( 1 + 2 \epsilon \right) \| \beta _ { L 2 } ^ { * } \| _ { 2 }$ . By the convexity of $Q$ , this implies $Q ( \beta / \alpha ^ { 2 } ) \stackrel { - } { \ } \ge Q ( \beta ^ { \prime } / \alpha ^ { 2 } ) \ >$ $Q ( \beta _ { L 2 } ^ { * } / \alpha ^ { 2 } )$ . Thus a $\beta$ with a large $\ell _ { 2 }$ norm cannot be a solution, even if $4 \alpha ^ { 4 } Q ( \beta / \alpha ^ { 2 } ) \not \approx \| \beta \| _ { 2 } ^ { 2 }$ .
|
| 528 |
+
|
| 529 |
+
Since $\left\| \hat { \beta } _ { \alpha } \right\| _ { 2 } < ( 1 + 2 \epsilon ) \| \beta _ { 2 } ^ { * } \| _ { 2 }$ , we conclude
|
| 530 |
+
|
| 531 |
+
$$
|
| 532 |
+
\begin{array} { l } { \displaystyle \left\| \hat { \beta } _ { \alpha } \right\| _ { 2 } ^ { 2 } \leq \frac { 1 } { 1 - \frac { \epsilon } { 2 + \epsilon } } 4 \alpha ^ { 4 } Q ( \hat { \beta } _ { \alpha } / \alpha ^ { 2 } ) } \\ { \displaystyle \leq \frac { 1 } { 1 - \frac { \epsilon } { 2 + \epsilon } } 4 \alpha ^ { 4 } Q ( \beta _ { L 2 } ^ { * } / \alpha ^ { 2 } ) } \\ { \displaystyle \leq \frac { 1 + \frac { \epsilon } { 2 + \epsilon } } { 1 - \frac { \epsilon } { 2 + \epsilon } } \| \beta _ { L 2 } ^ { * } \| _ { 2 } ^ { 2 } } \\ { \displaystyle = ( 1 + \epsilon ) \| \beta _ { L 2 } ^ { * } \| _ { 2 } ^ { 2 } } \end{array}
|
| 533 |
+
$$
|
| 534 |
+
|
| 535 |
+
# C PROOF OF THEOREM 3
|
| 536 |
+
|
| 537 |
+
Lemma 4. For the $D$ -homogeneous model (8),
|
| 538 |
+
|
| 539 |
+
$$
|
| 540 |
+
\forall t \ \left\| X ^ { \top } \int _ { 0 } ^ { t } r ( \tau ) d \tau \right\| _ { \infty } \leq \frac { \alpha ^ { 2 - D } } { D ( D - 2 ) }
|
| 541 |
+
$$
|
| 542 |
+
|
| 543 |
+
Proof. For the order- $D$ unbiased model $\beta ( t ) = \mathbf { w } _ { + } ^ { D } - \mathbf { w } _ { - } ^ { D }$ , the gradient flow dynamics are
|
| 544 |
+
|
| 545 |
+
$$
|
| 546 |
+
\begin{array} { l } { \displaystyle \dot { \mathbf { w } } _ { + } ( t ) = - \frac { d L } { d \mathbf { w } _ { + } } = - D X ^ { \top } r ( t ) \circ \mathbf { w } _ { + } ^ { D - 1 } ( t ) , \mathbf { w } _ { + } ( 0 ) = \alpha \mathbf { 1 } } \\ { \displaystyle \implies \mathbf { w } _ { + } ( t ) = \left( \alpha ^ { 2 - D } 1 + D ( D - 2 ) X ^ { \top } \int _ { 0 } ^ { t } r ( \tau ) d \tau \right) ^ { - \frac { 1 } { D - 2 } } } \end{array}
|
| 547 |
+
$$
|
| 548 |
+
|
| 549 |
+
Where $\circ$ denotes elementwise multiplication, $r ( t ) = X \beta ( t ) - y$ , and where all exponentiation is elementwise. Similarly,
|
| 550 |
+
|
| 551 |
+
$$
|
| 552 |
+
\begin{array} { l } { { \displaystyle \dot { \bf w } _ { - } ( t ) = - \frac { d L } { d { \bf w } _ { - } } = D X ^ { \top } r ( t ) \circ { \bf w } _ { - } ^ { D - 1 } ( t ) , ~ { \bf w } _ { - } ( 0 ) = \alpha 1 } } \\ { { \displaystyle \implies { \bf w } _ { - } ( t ) = \left( \alpha ^ { 2 - D } 1 - D ( D - 2 ) X ^ { \top } \int _ { 0 } ^ { t } r ( \tau ) d \tau \right) ^ { - \frac { 1 } { D - 2 } } } } \end{array}
|
| 553 |
+
$$
|
| 554 |
+
|
| 555 |
+
First, we observe that $\forall _ { t } \forall _ { i } \mathbf { w } _ { + } ( t ) _ { i } \geq 0$ and $\forall _ { t } \forall _ { i } \mathbf { w } _ { - } ( t ) _ { i } \geq 0$ . This is because at time 0 $\mathbf { \nabla } , \mathbf { w } _ { + } ( 0 ) _ { i } =$ $\mathbf { w } _ { - } ( 0 ) _ { i } = { \boldsymbol { \alpha } } > 0$ ; the gradient flow dynamics are continuous; and ${ \bf w } _ { + } ( t ) _ { i } = 0 \implies \dot { \bf w } _ { + } ( t ) _ { i } = 0$ and $\mathbf { w } _ { - } ( t ) _ { i } = 0 \implies \dot { \mathbf { w } } _ { - } ( t ) _ { i } = 0$ .
|
| 556 |
+
|
| 557 |
+
Consequently,
|
| 558 |
+
|
| 559 |
+
$$
|
| 560 |
+
\begin{array} { c } { { 0 \leq { \bf w } _ { + } ( t ) _ { i } ^ { 2 - D } = \alpha ^ { 2 - D } + D ( D - 2 ) \left[ X ^ { \top } \displaystyle \int _ { 0 } ^ { t } r ( \tau ) d \tau \right] _ { i } } } \\ { { 0 \leq { \bf w } _ { - } ( t ) _ { i } ^ { 2 - D } = \alpha ^ { 2 - D } - D ( D - 2 ) \left[ X ^ { \top } \displaystyle \int _ { 0 } ^ { t } r ( \tau ) d \tau \right] _ { i } } } \\ { { \Longrightarrow - \alpha ^ { 2 - D } \leq D ( D - 2 ) \left[ X ^ { \top } \displaystyle \int _ { 0 } ^ { t } r ( \tau ) d \tau \right] _ { i } \leq \alpha ^ { 2 - D } } } \end{array}
|
| 561 |
+
$$
|
| 562 |
+
|
| 563 |
+
which concludes the proof.
|
| 564 |
+
|
| 565 |
+
Theorem 3. For any $\alpha$ and $D \geq 3 ,$ , if gradient flow reaches a solution $X \beta _ { \alpha , D } ( \infty ) = y$ , then
|
| 566 |
+
|
| 567 |
+
$$
|
| 568 |
+
\beta _ { \alpha , D } ( \infty ) = \arg \operatorname* { m i n } _ { \beta } Q _ { \alpha } ^ { D } ( \beta ) \ s . t \ \mathbf { X } \beta = \mathbf { y }
|
| 569 |
+
$$
|
| 570 |
+
|
| 571 |
+
where $\begin{array} { r } { Q _ { \alpha } ^ { D } ( \beta ) = \sum _ { i = 1 } ^ { d } q _ { D } \big ( \beta _ { i } / \alpha ^ { D } \big ) } \end{array}$ and $q _ { D } = \int h _ { D } ^ { - 1 }$ is the antiderivative of the unique inverse of $h _ { D } ( z ) = ( 1 - z ) ^ { - \frac { D } { D - 2 } } - ( 1 + z ) ^ { - \frac { D } { D - 2 } }$ on $[ - 1 , 1 ]$ . Furthermore, $\begin{array} { r } { \operatorname* { l i m } _ { \alpha \to 0 } \beta _ { \alpha , D } ( \infty ) = \beta _ { L 1 } ^ { * } } \end{array}$ and $\begin{array} { r } { \operatorname* { l i m } _ { \alpha \to \infty } \beta _ { \alpha , D } ( \infty ) = \beta _ { L 2 } ^ { * } } \end{array}$ .
|
| 572 |
+
|
| 573 |
+
Proof. For the order- $D$ unbiased model $\beta ( t ) = \mathbf { w } _ { + } ^ { D } - \mathbf { w } _ { - } ^ { D }$ , the gradient flow dynamics are
|
| 574 |
+
|
| 575 |
+
$$
|
| 576 |
+
\begin{array} { c } { { \displaystyle \dot { \mathbf { w } } ( t ) = \frac { d L } { d \mathbf { w } } = - D \tilde { X } ^ { \top } r ( t ) \circ \mathbf { w } ^ { D - 1 } , \mathbf { w } ( 0 ) = \alpha 1 } } \\ { { \displaystyle \implies \mathbf { w } ( t ) = \left( \alpha ^ { 2 - D } + D ( D - 2 ) \tilde { X } ^ { \top } \int _ { 0 } ^ { t } r ( \tau ) d \tau \right) ^ { - \frac { D } { D - 2 } } } } \\ { { \displaystyle \implies \beta ( t ) = \alpha ^ { D } \left( 1 + \alpha ^ { D - 2 } D ( D - 2 ) { X } ^ { \top } \int _ { 0 } ^ { t } r ( \tau ) d \tau \right) ^ { - \frac { D } { D - 2 } } } } \\ { { \displaystyle - \alpha ^ { D } \left( 1 - \alpha ^ { D - 2 } D ( D - 2 ) { X } ^ { \top } \int _ { 0 } ^ { t } r ( \tau ) d \tau \right) ^ { - \frac { D } { D - 2 } } } } \end{array}
|
| 577 |
+
$$
|
| 578 |
+
|
| 579 |
+
where $\tilde { X } = [ X ~ - X ]$ and $r ( t ) = X \beta ( t ) - y$ . Supposing $\beta ( t )$ converges to a zero-error solution,
|
| 580 |
+
|
| 581 |
+
$$
|
| 582 |
+
X \beta ( \infty ) = \mathbf { y } \beta ( \infty ) = \alpha ^ { D } h _ { D } ( X ^ { \top } \nu ( \infty ) )
|
| 583 |
+
$$
|
| 584 |
+
|
| 585 |
+
where $\begin{array} { r } { \nu ( \infty ) = - \alpha ^ { D - 2 } D ( D - 2 ) \int _ { 0 } ^ { \infty } r ( \tau ) d \tau } \end{array}$ and the function $h _ { D }$ is applied elementwise and is defined
|
| 586 |
+
|
| 587 |
+
$$
|
| 588 |
+
h _ { D } ( z ) = ( 1 - z ) ^ { - \frac { D } { D - 2 } } - ( 1 + z ) ^ { - \frac { D } { D - 2 } }
|
| 589 |
+
$$
|
| 590 |
+
|
| 591 |
+
By Lemma 4, $\begin{array} { r } { \left\| \boldsymbol X ^ { \top } \boldsymbol \nu \right\| _ { \infty } \leq 1 } \end{array}$ , so the domain of $h _ { D }$ is the interval $[ - 1 , 1 ]$ , upon which it is monotonically increasing from $\tilde { h } _ { D } ( - 1 ) = - \infty$ to $h _ { D } ( 1 ) = \infty$ . Therefore, there exists an inverse mapping $h _ { D } ^ { - 1 } ( t )$ with domain $[ - \infty , \infty ]$ and range $[ - 1 , 1 ]$ .
|
| 592 |
+
|
| 593 |
+
This inverse mapping unfortunately does not have a simple closed form. Nevertheless, it is the root of a rational equation. Using the approach outlined in Appendix A (12), we conclude:
|
| 594 |
+
|
| 595 |
+
$$
|
| 596 |
+
Q _ { \alpha } ^ { D } ( \beta ) = \sum _ { i } \int _ { 0 } ^ { \beta _ { i } / \alpha ^ { D } } h _ { D } ^ { - 1 } ( t ) d t
|
| 597 |
+
$$
|
| 598 |
+
|
| 599 |
+
Rich regime Next, we show that if gradient flow reaches a solution $X \beta _ { \alpha , D } ( \infty ) ~ = ~ y$ , then $\begin{array} { r } { \operatorname* { l i m } _ { \alpha \to 0 } \bar { \beta } _ { \alpha , D } ( \infty ) = \beta _ { L 1 } ^ { * } } \end{array}$ for any $D$ . This is implied by the work of Arora et al. (2019a), but we include it here for an alternative, simpler proof for our special case, and for completeness’s sake.
|
| 600 |
+
|
| 601 |
+
The KKT conditions for $\beta = \beta _ { L 1 } ^ { * }$ are $X \beta = y$ and $\exists \nu \operatorname { s i g n } ( \beta ) = X ^ { \top } \nu$ (where $\mathrm { s i g n } ( 0 ) = [ - 1 , 1 ] )$ . The first condition is satisfied by assumption. Define $\nu$ as above. We will demonstrate that the second condition holds too in the limit as $\alpha 0$ .
|
| 602 |
+
|
| 603 |
+
First, by Lemma 4, $\left\| X ^ { \top } \nu \right\| _ { \infty } \ \leq \ 1$ for all $\alpha$ and $D$ . Thus, for any coordinates $i$ such that $\begin{array} { r } { \operatorname* { l i m } _ { \alpha \to 0 } [ \beta _ { \alpha , D } ( \infty ) ] _ { i } ~ = ~ \mathrm { ~ \ddot { 0 } ~ } } \end{array}$ , the second KKT condition holds. Consider now $i$ for which $\mathrm { l i m } _ { \alpha \to 0 } [ \beta _ { \alpha , D } ( \infty ) ] _ { i } > 0$ . As shown above,
|
| 604 |
+
|
| 605 |
+
$$
|
| 606 |
+
\begin{array} { l } { { \displaystyle \operatorname* { l i m } _ { \alpha \to 0 } [ \beta _ { \alpha , D } ( \infty ) ] _ { i } = \operatorname* { l i m } _ { \alpha \to 0 } \alpha ^ { D } \left( 1 - [ X ^ { \top } \nu ] _ { i } \right) ^ { - \frac { D } { D - 2 } } - \alpha ^ { D } \left( 1 + [ X ^ { \top } \nu ] _ { i } \right) ^ { - \frac { D } { D - 2 } } > 0 } \ ~ } \\ { { \displaystyle \qquad \implies \ \operatorname* { l i m } _ { \alpha \to 0 } \alpha ^ { D } \left( 1 - [ X ^ { \top } \nu ] _ { i } \right) ^ { - \frac { D } { D - 2 } } > 0 } } \end{array}
|
| 607 |
+
$$
|
| 608 |
+
|
| 609 |
+
This and $[ X ^ { \top } \nu ] _ { i } \leq 1$ implies $\begin{array} { r } { \operatorname* { l i m } _ { \alpha \to 0 } [ X ^ { \top } \nu ] _ { i } = 1 } \end{array}$ , and thus the positive coordinates satisfy the second KKT condition. An identical argument can be made for the negative coordinates.
|
| 610 |
+
|
| 611 |
+

|
| 612 |
+
Figure 5: The plots demonstrate the regimes where gradient flow implicitly minimizes nuclear norm and $\ell _ { 2 }$ norm, respectively.
|
| 613 |
+
|
| 614 |
+
Kernel Regime Finally, we show that if gradient flow reaches a solution $X \beta _ { \alpha , D } ( \infty ) = y$ , then $\begin{array} { r } { \operatorname* { l i m } _ { \alpha \to \infty } \beta _ { \alpha , D } ( \infty ) = \beta _ { L 2 } ^ { * } } \end{array}$ for any $D$ .
|
| 615 |
+
|
| 616 |
+
First, since $X$ and $y$ are finite, there exists a solution $\beta ^ { * }$ whose entries are all finite, and thus all the entries of $\beta _ { \alpha , D } ( \infty )$ , which is the $Q _ { \alpha } ^ { D }$ -minimizing solution, will be finite.
|
| 617 |
+
|
| 618 |
+
The KKT conditions for $\beta = \beta _ { L 2 } ^ { * }$ are $X \beta = y$ and $\exists \mu \beta = X ^ { \top } \mu$ . The first condition is satisfied by assumption. Defining $\nu$ as above, we have
|
| 619 |
+
|
| 620 |
+
$$
|
| 621 |
+
\begin{array} { c } { \displaystyle \underset { \alpha \infty } { \operatorname* { l i m } } [ \beta _ { \alpha , D } ( \infty ) ] _ { i } = \displaystyle \operatorname* { l i m } _ { \alpha 0 } \alpha ^ { D } ( 1 - [ X ^ { \top } \nu ] _ { i } ) ^ { - \frac { D } { D - 2 } } - \alpha ^ { D } ( 1 + [ X ^ { \top } \nu ] _ { i } ) ^ { - \frac { D } { D - 2 } } < \infty } \\ { \displaystyle \implies \underset { \alpha \infty } { \operatorname* { l i m } } [ X ^ { \top } \nu ] _ { i } = 0 } \end{array}
|
| 622 |
+
$$
|
| 623 |
+
|
| 624 |
+
Consequently, defining $\begin{array} { r } { \mu = \frac { 2 D \alpha ^ { D } } { D - 2 } \nu } \end{array}$ , and observing that for small $z$ ,
|
| 625 |
+
|
| 626 |
+
$$
|
| 627 |
+
( 1 - z ) ^ { - { \frac { D } { D - 2 } } } - ( 1 + z ) ^ { - { \frac { D } { D - 2 } } } = { \frac { 2 D } { D - 2 } } z + O ( z ^ { 3 } )
|
| 628 |
+
$$
|
| 629 |
+
|
| 630 |
+
we conclude
|
| 631 |
+
|
| 632 |
+
$$
|
| 633 |
+
\begin{array} { l } { \displaystyle \underset { \alpha \infty } { \operatorname* { l i m } } \frac { [ \beta _ { \alpha , D } ( \infty ) ] _ { i } } { [ X ^ { \top } \mu ] _ { i } } = \underset { \alpha 0 } { \operatorname* { l i m } } \frac { \alpha ^ { D } ( 1 - [ X ^ { \top } \nu ] _ { i } ) ^ { - \frac { D } { D - 2 } } - \alpha ^ { D } ( 1 + [ X ^ { \top } \nu ] _ { i } ) ^ { - \frac { D } { D - 2 } } } { [ X ^ { \top } \mu ] _ { i } } } \\ { = \displaystyle \operatorname* { l i m } _ { \alpha 0 } \frac { \alpha ^ { D } ( \frac { 2 D } { D - 2 } [ X ^ { \top } \nu ] _ { i } + O ( [ X ^ { \top } \nu ] _ { i } ^ { 3 } ) ) } { \frac { 2 D \alpha ^ { D } } { D - 2 } [ X ^ { \top } \nu ] _ { i } } } \\ { = 1 + \displaystyle \operatorname* { l i m } _ { \alpha 0 } O ( [ X ^ { \top } \nu ] _ { i } ^ { 2 } ) } \\ { = 1 } \end{array}
|
| 634 |
+
$$
|
| 635 |
+
|
| 636 |
+
Thus, the KKT conditions are satisfied for $\begin{array} { r } { \operatorname* { l i m } _ { \alpha \to \infty } \beta _ { \alpha , D } ( \infty ) = \beta _ { L 2 } ^ { * } } \end{array}$
|
| 637 |
+
|
| 638 |
+
# D MATRIX EXPERIMENTS
|
| 639 |
+
|
| 640 |
+
In the appendix, we provide additional results similar to those in Section 6. First, in Figure 5, we plot the implicit regularization behavior of gradient flow limits with identity initialization as in Figure 3(a): in “rich" regime (small $\alpha$ ) we recover the minimum nuclear norm solution $M _ { N N } ^ { * } = \ \mathrm { a r g } \operatorname* { m i n } _ { P _ { \Omega } ( M ) = y } \left. M \right. _ { \star }$ , while “kernel" regime recovers the minimum Frobenius norm solution $\begin{array} { r } { M _ { L @ } ^ { * } = \arg \operatorname* { m i n } _ { P \Omega ( M ) = y } \left\| M \right\| _ { 2 } } \end{array}$
|
| 641 |
+
|
| 642 |
+
# E NEURAL NETWORK EXPERIMENTS
|
| 643 |
+
|
| 644 |
+
Synthetic Experiments We construct a synthetic training set with $N = 1 0$ points drawn uniformly from the unit circle in $\mathbb { R } ^ { 2 }$ and labelled by a teacher model with 1 hidden layer of 3 units. We train fully connected ReLU networks with depths 2, 3, and 5 with 30 units per layer to minimize the square loss using full gradient descent with constant stepsize 0.01 until the training loss is below $1 \bar { 0 } ^ { - 9 }$ . We use Uniform He initialization for the weights and then multiply them by $\alpha$ .
|
| 645 |
+
|
| 646 |
+
Here, we describe the details of the neural network implementations for the MNIST and CIFAR10 experiments.
|
| 647 |
+
|
| 648 |
+

|
| 649 |
+
Figure 6: Training curves for the CIFAR10 experiments
|
| 650 |
+
|
| 651 |
+
MNIST Since our theoretical results hold for the squared loss and gradient flow dynamics, here we empirically assess whether different regimes can be observed when training neural networks following standard practices.
|
| 652 |
+
|
| 653 |
+
We train a fully-connected neural network with a single hidden layer composed of 5000 units on the MNIST dataset, where weights are initialized as $\alpha \mathbf { w } _ { 0 }$ , $\mathbf { w } _ { 0 } \sim \dot { \mathcal { N } } \left( 0 , \sqrt { \frac { 2 } { n _ { i n } } } \right)$ , $n _ { i n }$ denoting the number of units in the previous layer, as suggested by He et al. (2015). SGD with a batch size of 256 is used to minimize the cross-entropy loss over the 60000 training points, and error over the 10000 test samples are used as measure of generalization. For each value of $\alpha$ , we search over learning rates $( 0 . 5 , 0 . 0 1 , 0 . 0 5 , \dots )$ and use the one which resulted in best generalization.
|
| 654 |
+
|
| 655 |
+
There is a visible phase transition in Figure $_ { 4 \mathrm { e } }$ in terms of generalization $( \approx 1 . 4 \%$ error for $\alpha \leq 2$ , and $\approx 2 . 4 \%$ error for $\alpha \geq 5 0$ ), even though every network reached $1 0 0 \%$ training accuracy and less than $1 0 ^ { - 5 }$ cross-entropy loss. The black line indicates the test error $( 2 . 7 \% )$ when training only the output layer of the network, as a proxy for the performance of a linear predictor with features given by a fixed, randomly-initialized hidden layer.
|
| 656 |
+
|
| 657 |
+
CIFAR10 We trained a VGG11-like architecture, which is as follows: 64-M-128-M-256-256-M512-512-M-512-512-M-FC (numbers represent the number of channels in a convolution layers with no bias, M is a maxpooling layer, and FC is a fully connected layer). Weights were initialized using Uniform He initialization multiplied by $\alpha$ . No data augmentation was used, and training done using SGD with batch size of 128 and learning rate of 0.0001. All experiments ran for 2000 epochs, and reached $1 0 0 \%$ train accuracy except when training only the last layer, which reached $5 0 . 3 8 \%$ train accuracy with $\mathrm { L R } = 0 . 0 0 1$ (chosen after hyperparameter tuning).
|
| 658 |
+
|
| 659 |
+
In addition, to approximate the test error in the kernel regime, we experimented with freezing the bottom layers and only training the output layer for both datasets (the solid lines in Figures 4e and 4f).
|
| 660 |
+
|
| 661 |
+
Figure 6 illustrates some of the optimization difficulties that arise from using smaller $\alpha$ as discussed in Section 4.
|
parse/train/Byg9bxrtwS/Byg9bxrtwS_content_list.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
parse/train/Byg9bxrtwS/Byg9bxrtwS_middle.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
parse/train/Byg9bxrtwS/Byg9bxrtwS_model.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
parse/train/PhtFY9plHk/PhtFY9plHk.md
ADDED
|
@@ -0,0 +1,417 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Auto-tuning Matrix Multiplication and Convolution for Deep Learning on CPUs
|
| 2 |
+
|
| 3 |
+
Anonymous Author(s)
|
| 4 |
+
Affiliation
|
| 5 |
+
Address
|
| 6 |
+
email
|
| 7 |
+
|
| 8 |
+
# Abstract
|
| 9 |
+
|
| 10 |
+
1 Deep learning (DL) compilers have emerged aiming to reduce the gap between
|
| 11 |
+
2 abundant, fast-growing DL models and the lag of high performance implemen
|
| 12 |
+
3 tations of these models on diverse hardware devices. In this work, we introduce
|
| 13 |
+
4 several optimization strategies, combining analytic ideal cache models with ma
|
| 14 |
+
5 chine learning models trained with real hardware measures, and integrate them into
|
| 15 |
+
6 a unified auto-tuning framework, called AutoMCL, to improve the performance
|
| 16 |
+
7 of DL compilers on both the operation level and the end-to-end model inference.
|
| 17 |
+
8 We evaluate AutoMCL and compare it with state-of-the-art on multiple CPUs.
|
| 18 |
+
9 End-to-end evaluations show that AutoMCL outperforms TensforFlow on fully
|
| 19 |
+
10 connected and convolutional neural networks with respectively a geometric mean
|
| 20 |
+
11 of $9 . 2 9 \times$ and $1 . 5 4 \times$ speedup. Over the baseline AutoTVM, on average, AutoMCL
|
| 21 |
+
12 achieves respectively $1 . 3 7 \times$ and $2 . 1 6 \times$ speedup in inference and optimization time
|
| 22 |
+
13 for fully connected neural networks and gains ${ \bar { 2 } } . 5 5 \%$ performance improvement in
|
| 23 |
+
14 inference for convolutional neural networks with $1 . 9 1 \%$ more optimization cost.
|
| 24 |
+
|
| 25 |
+
# 15 1 Introduction
|
| 26 |
+
|
| 27 |
+
16 Deep learning models have found wide applications in image and sound recognition, natural language
|
| 28 |
+
17 translation, game playing, etc. The success of deep learning benefits greatly from the accessibility
|
| 29 |
+
18 of DL frameworks, such as TensforFlow [4], PyTorch [19] and MXNet [8], which not only ease the
|
| 30 |
+
19 burden of coding but also provide high performance supports through efficient low-level libraries,
|
| 31 |
+
20 such as Intel oneMKL [2] or NVIDIA cuDNN [3]. However, it is difficult to make the library
|
| 32 |
+
21 development, which requires tremendous manual engineering effort entangled with hardwares and
|
| 33 |
+
22 often takes months or even years to finish, keep pace with the rapid innovation of DL models. As
|
| 34 |
+
23 a result, many newly introduced neural networks or operators may lack optimal implementation
|
| 35 |
+
24 support on the target hardwares, thus hindering the further innovation of DL models. To address
|
| 36 |
+
25 this challenge, DL compilers (e.g. TVM [9] and TensorComprehensions [25]) emerged [16], whose
|
| 37 |
+
26 goal is to automatically compile high-level declarations of DL operators into efficient low-level code
|
| 38 |
+
27 across various hardware devices, including CPUs, GPUs, FPGAs, and ASICs.
|
| 39 |
+
28 To make the DL compilers appealing, it is essential to keep their performance competitive or even
|
| 40 |
+
29 superior to that of DL frameworks or hand-optimized libraries. To achieve this, state-of-the-art DL
|
| 41 |
+
30 compilers, such as TVM and its successor AutoTVM [10], extend the decoupled compute/schedule
|
| 42 |
+
31 principle of Halide [20] to separate target hardware intrinsics from computation description and
|
| 43 |
+
32 optimization sequence specification composed of transform primitives to ease the process of high
|
| 44 |
+
33 level optimization, and leverage machine learning to automate low-level optimizations. The success
|
| 45 |
+
34 of DL compilers relies on high-quality schedules as well as effective searching and learning strategies
|
| 46 |
+
35 to find optimal parameters. Recently, new progress have been made on automating the design of
|
| 47 |
+
36 schedule primitives, enlarging the parameter space to expose more tuning opportunities and utilizing
|
| 48 |
+
37 heuristic and learning approaches, in particular reinforcement learning, to explore the parameter
|
| 49 |
+
38 space more effectively to find optimal candidates. Among these work, AdaTune [15], Ansor [29],
|
| 50 |
+
39 CHAMELEON [5], FlexTensor [30] and Cortex [11] are built on top of TVM while the value function
|
| 51 |
+
40 method [23] and TIRAMISU [6] are respectively based on Halide and the polyhedral model.
|
| 52 |
+
41 Most of these optimizations have been focusing on the loop level optimizations, such as loop tiling,
|
| 53 |
+
42 loop split and fuse, loop unroll, loop reordering, vectorization, etc. The algorithm level optimization,
|
| 54 |
+
43 on the other hand, is hard to automate and still requires human’s expertise. Moreover, while enlarging
|
| 55 |
+
44 the tuning space may potentially include better candidates, it also calls more effort to find the optimal
|
| 56 |
+
45 solution and often leads to getting suboptimal solution in limited budget. Thus, it remains a great
|
| 57 |
+
46 challenge to prune the parameter space efficiently to avoid unnecessary exploration, which may also
|
| 58 |
+
47 help increase the chance of optimal solutions to be picked earlier. A purely analytical modeling
|
| 59 |
+
48 approach for optimizing convolutions [17] was recently proposed towards this direction.
|
| 60 |
+
49 In this work, we propose several new strategies aiming to leverage both analytic model and machine
|
| 61 |
+
50 learning to generate more efficient code in shorter compilation time targeting on the CPU platforms,
|
| 62 |
+
51 the ubiquity of which implies that a great number of users can benefit from such improvement. Our
|
| 63 |
+
52 main contributions are three-fold:
|
| 64 |
+
|
| 65 |
+
• We introduce new strategies for initializing and filtering the tiling size space for matrix multiplication and convolution based on analytic models.
|
| 66 |
+
• We introduce several new competitive schedules for matrix multiplication and convolution in both algorithm and loop level to enlarge the schedule space.
|
| 67 |
+
• We integrate the proposed strategies into a new auto-tuning framework called AutoMCL, which leverages TVM’s frontend computational graph optimization and backend code generation functionalities. We conduct operator level and end-to-end evaluations showing that the overall performance of AutoMCL is superior to AutoTVM in both inference and optimization time on typical fully connected or convolutional neural networks.
|
| 68 |
+
|
| 69 |
+
# 62 2 Background
|
| 70 |
+
|
| 71 |
+
63 The operations matrix multiplication and convolution appear widely in many deep neural networks
|
| 72 |
+
64 and improving their performance is critical to speed up the the training and inference. Matrix multi
|
| 73 |
+
65 plication has been implemented on CPU in many basic linear algebra libraries, such as ATLAS [27],
|
| 74 |
+
66 GotoBLAS [13] and Intel oneMKL [2]. The convolution operation was also implemented on CPU in
|
| 75 |
+
67 several standalone libraries, such as Intel oneDNN [1]. In the context of deep learning, there is a a
|
| 76 |
+
68 strong demand to deploy a well-trained model to a great variety and amount of devices such that the
|
| 77 |
+
69 model can infer in real time on the target hardwares. This offers new challenges and opportunities for
|
| 78 |
+
70 auto-tuning the performance of these two operations for fixed size input tensors [28, 18].
|
| 79 |
+
71 Matrix multiplication and 2D-convolution operators. Mathematically, the matrix multiplica
|
| 80 |
+
72 tion operator matmul takes two matrices $A _ { M \times K }$ and $B _ { K \times N }$ as input and computes their prod
|
| 81 |
+
73 uct and 74 $C _ { M \times N }$ . In this paper, we woomputes a new matrix umeby $D _ { M \times K }$
|
| 82 |
+
$W _ { N \times K }$ $C _ { M \times N }$ $\begin{array} { r } { C _ { i j } : = \sum _ { k = 0 } ^ { \mathbf { \bar { K } } - 1 } A _ { i k } B _ { j k } } \end{array}$
|
| 83 |
+
operator conv2d, in its simplest form, takes a tensor $D$ of dimensions $\bar { B } \times I C \times D H \times D W$ ,
|
| 84 |
+
76 a tensor $W$ of dimensions $O C \times I C \times K H \times K W$ , two stride sizes $s _ { 1 } , s _ { 2 }$ , and produces
|
| 85 |
+
77 a tensor $C$ of dimensions $B \times O C \times O H \times O W$ , where $O H \ = \ ( D H - K H ) / s _ { 1 } + 1$
|
| 86 |
+
78 and $O W \ = \ ( D W - K W ) / s _ { 2 } + 1$ . Each element of $C$ is computed according to the rule
|
| 87 |
+
79 PIC−1i=0 PKH−1ky=0 PKW −1kx=0 Db,i,s1y+ky,s2x+kx Wo,i,ky,kx . In general, it may also takes
|
| 88 |
+
80 two padding sizes $P H$ , $P W$ and two dilation sizes $d _ { 1 }$ , $d _ { 2 }$ and produces a tensor of dimen
|
| 89 |
+
81 sions $B \times O C \times O H \times O W$ , where $O H = ( D H + 2 P H - ( \bar { K } H - 1 ) d _ { 1 } - 1 ) / s _ { 1 } + 1$ and
|
| 90 |
+
82 $O W = ( D W + 2 P W - ( K W - 1 ) d _ { 2 } - 1 ) / s _ { 2 } + 1$ .
|
| 91 |
+
83 Ideal cache model. The ideal cache model was introduced in [12] for studying the cache complexity
|
| 92 |
+
84 of algorithms. It assumes that the computer has a two-level memory hierarchy consisting of an ideal
|
| 93 |
+
85 cache of $Z$ words with cache line size $C$ , where $Z \gg C$ , and an arbitrarily large main memory. To
|
| 94 |
+
86 access a word in main memory, it first searches it in cache. If the word does not reside in the cache,
|
| 95 |
+
87 a cache miss occurs and a cache line containing the word is loaded into the cache from the main
|
| 96 |
+
88 memory. It assumes that the cache is fully associative and the line with furthest access in the future
|
| 97 |
+
89 will be replaced if new data is loaded into a full cache. The cache complexity counts the number of
|
| 98 |
+
90 cache misses. For instance, the (worst) cache complexity for scanning $n$ words continuously stored in
|
| 99 |
+
91 an array is $\lceil n / C \rceil + 1$ . In general, the cache complexity of an algorithm operating on a tensor largely
|
| 100 |
+
92 depends on the layout of the tensor and the ordering for visiting the dimensions of the tensor.
|
| 101 |
+
|
| 102 |
+
# 93 3 Components of AutoMCL
|
| 103 |
+
|
| 104 |
+
94 We design a few optimization passes and evaluate the effectiveness of each optimization strategy 95 individually and only append experimentally proven working optimizations to our framework. Fig. 1 provides an overview of the framework, named AutoMCL.
|
| 105 |
+
|
| 106 |
+

|
| 107 |
+
Figure 1: Flow of AutoMCL with the new strategies introduced in this work highlighted.
|
| 108 |
+
|
| 109 |
+
97 Enlarging the space of schedules. The DL compiler TVM provides two default computes for the
|
| 110 |
+
98 matrix multiplication operator, namely DNMM and RPMM and one default compute CONV for gen
|
| 111 |
+
99 eral 2D-convolution. We introduce another four alternative computes TMM, TTMM, DPMM, LPMM
|
| 112 |
+
100 for matrix multiplication and two alternative computes Im2colDNMM332 and Im2colRPMMV for
|
| 113 |
+
101 convolution by converting convolution to matrix multiplication in an im2col manner. Table 1 summa
|
| 114 |
+
102 rizes the specification of each compute for matrix multiplication. The computes for convolution can
|
| 115 |
+
103 be found in the supplemental material. We manually write schedule template for each new compute
|
| 116 |
+
104 and improve the default schedule templates for DNMM, RPMM, CONV respectively as DNMM332
|
| 117 |
+
105 (single-level tiling to double-level tiling), RPMMV (adding missing vectorization for some loop) and
|
| 118 |
+
106 CONVOpt (loop reordering according to the cache complexity analysis in Theorem 2 and its remark).
|
| 119 |
+
107 We analyze the cache complexity with the ideal cache model for each schedule template, stated as
|
| 120 |
+
108 Theorem 1 and Theorem 2, whose detailed proof can be found in the supplemental material. Note
|
| 121 |
+
109 that all the nested loops will be tiled in the schedules. This would lead to a better cache complexity if
|
| 122 |
+
110 the data required for computing a tile all fit in cache. This assumption depends both on the tile and
|
| 123 |
+
111 cache size but should not depend on the input tensor size (with the kernel sizes as an exception since
|
| 124 |
+
112 they are usually small). Table 2 and Table 3 summarize the assumptions.
|
| 125 |
+
113 Let $V _ { \ell }$ be the length of vectorization, $C _ { \ell }$ be the cache line size, $Z$ be the cache size, and $D _ { \ell }$ be the
|
| 126 |
+
114 size of tensor data type in bytes. Let $V _ { w } : = V _ { \ell } / D _ { \ell } , C _ { w } : = C _ { \ell } / D _ { \ell } , Z _ { w } : = Z / D _ { \ell }$ .
|
| 127 |
+
|
| 128 |
+
Table 1: Compute specification for matrix multiplication
|
| 129 |
+
|
| 130 |
+
<table><tr><td>Name</td><td>Specification (Mt,Kt, Nt are parameters.)</td></tr><tr><td>TMM</td><td>Cy=∑-DuW</td></tr><tr><td>TTMM</td><td>Wk:=WCy=∑-1Dyk*W K-1</td></tr><tr><td>DNMM</td><td>CCy,x,ki :=∑K/K Kt-1 CCy,xki K/Kt-1 1 Dy,k*Kt+k *Wx*Kt+k; Cy,x :=∑ ∑ki=0</td></tr><tr><td>LPMM</td><td>K-1PDy PDyok,y :=Dy*Mt+y;Cyx=∑ Py/Mt,k,y mod Mt * Wx,k</td></tr><tr><td>RPMM</td><td>PWxok,xi :=Wxo*Nt+xi,k;Cy,x :=∑-1 K-1 Dy,k *PW x/Nt,k,x mod Nt</td></tr><tr><td>DPMM</td><td>PDyo,k,yi i= Dyo*Mt+yik; PWxok,xi := Wxo*Nt+xi,k Cy,x :=∑k=01</td></tr></table>
|
| 131 |
+
|
| 132 |
+
Theorem 1. Assume that 115 $\begin{array} { r } { T _ { m } ( M _ { t } , K _ { t } , N _ { t } ) < \frac { Z _ { w } } { C _ { w } } } \end{array}$ and $M _ { t } | M , K _ { t } | K , N _ { t } | N ,$ , the cache complexity 116 $C _ { m } ( M , K , N , M _ { t } , K _ { t } , N _ { t } )$ for each schedule is listed as below:
|
| 133 |
+
|
| 134 |
+
$$
|
| 135 |
+
\begin{array} { r l } { \mathrm { T M M : } \quad } & { \frac { M } { M _ { k } } \frac { N } { N _ { k } } \left( M _ { k } \left( \left[ \frac { K _ { k } } { C _ { w } } \right] + 1 \right) \frac { K _ { k } } { K _ { k } } + N _ { k } \left( \left[ \frac { K _ { k } } { C _ { w } } \right] + 1 \right) \frac { K _ { k } } { K _ { k } } + M _ { t } \left( \left[ \frac { N _ { k } } { C _ { w } } \right] + 1 \right) \right) } \\ { \mathrm { T M M : } \quad } & { \frac { K _ { k } } { K _ { k } } \frac { N } { N _ { k } } \left( K _ { t } \left( \left[ \frac { K _ { k } } { C _ { w } } \right] + 1 \right) + N _ { t } \left( \left[ \frac { K _ { k } } { C _ { w } } \right] + 1 \right) \right) } \\ & { + \frac { N _ { t } } { M _ { k } } \frac { N _ { k } } { K _ { k } } \left( M _ { k } \left( \left[ \frac { K _ { k } } { C _ { w } } \right] + 1 \right) \frac { K _ { k } } { K _ { k } } + K _ { t } \left[ \left( \frac { K _ { k } } { C _ { w } } \right] + 1 \right) \frac { K _ { k } } { K _ { k } } + M _ { t } \left( \left[ \frac { N _ { k } } { C _ { w } } \right] + 1 \right) \right) } \\ { \mathrm { D M M : } \quad } & { \frac { M _ { k } } { M _ { k } } \frac { N } { N _ { k } } \left( \left[ \frac { K _ { k } } { K _ { k } } \right] \left( M _ { k } + N _ { k } \right) \left( \left[ \frac { K _ { k } } { K _ { k } } \right] + 1 \right) + M _ { k } \left( \left[ \frac { K _ { k } K _ { k } } { K _ { k } } \right] + 1 \right) + M _ { t } \left( \left[ \frac { K _ { k } } { C _ { w } } \right] + 1 \right) \right) } \\ { \mathrm { L P M M : } \quad } & { \frac { M _ { k } } { M _ { k } } \left( \left[ \frac { K _ { k } } { C _ { w } } \right] + 1 \right) + M \left( \left[ \frac { K _ { k } } { K _ { k } } \right] + 1 \right) + \left[ \frac { M _ { k } } { M _ { k } } \right] } \\ & + \frac { M _ { k } } { N _ { k } } \frac N _ k \end{array}
|
| 136 |
+
$$
|
| 137 |
+
|
| 138 |
+
Theorem 2. Assume that 117 $\begin{array} { r } { T _ { c } ( M _ { t } , K _ { t } , N _ { t } ) < \frac { Z _ { w } } { C _ { w } } } \end{array}$ and $O W _ { t } | O W , I C _ { t } | I C , O C _ { t } | O C ,$ , the cache com118 plexity for CONVOpt is:
|
| 139 |
+
|
| 140 |
+
$$
|
| 141 |
+
\begin{array} { r l } & { \quad [ \frac { B * ( D H + 2 P H ) + I ( C * ( D W + 2 P W ) ) } { C _ { w } } ] + 1 + ( B + D H + I C * ( \lceil \frac { D W } { C _ { w } } \rceil + 1 ) ) } \\ & { + \ O C * ( \lceil \frac { \mathbf { K C } } { C _ { w } } * ( \lceil \frac { \mathbf { K H } + \mathbf { K W } * \mathbf { H C } _ { w } } { C _ { w } } \rceil + 1 ) ) } \\ & { + I C * R H * K W * \frac { O C } { C _ { w } } * ( \lfloor \frac { O C _ { w } } { C _ { w } } \rceil + 1 ) + ( B * \frac { O C } { O C _ { w } } * O H * \frac { O W } { O W _ { 1 } } * ( \lfloor \frac { O W _ { 1 } * O C _ { u } } { C _ { w } } \rceil + 1 ) ) } \\ & { + B * \frac { O C } { O C _ { w } } * O H * \frac { O W } { O W _ { * } } * I C * K R H * ( ( \frac { O C } { C _ { w } } ) + 1 ) } \\ & { + B * \frac { O C } { O C _ { w } } * I C * \partial H * \frac { O W } { O W _ { * } } * R H * ( ( \frac { ( E _ { w } - 1 ) + ( E W - 1 ) + ( K W - 1 ) * d _ { 2 } + 1 ) } { C _ { w } } ) } \\ & { + B * \frac { O C } { O C _ { w } } * I C * O H * \frac { O W } { O W _ { * } } * R H * ( ( \frac { ( E _ { w } + O ) } { ( \sum _ { w } * O H * ( \log C _ { w } ) } + ( \frac { O C _ { w } } { C _ { w } } ) + 1 ) ) } \\ & { + B * \frac { O C } { O C _ { w } } * O H * O W * ( \lceil \frac { O C _ { w } } { C _ { w } } \rceil + 1 ) + ( B * O H * O W * \frac { O C } { O C _ { w } } * ( \lceil \frac { O C _ { w } } { C _ { w } } \rceil + 1 ) ) } \\ & { + B * O C * O H * \frac { O W } { O W _ { w } } * ( [ \frac { O M } { O W _ { w } } ] + 1 ) , } \end{array}
|
| 142 |
+
$$
|
| 143 |
+
|
| 144 |
+
119 and the cache complexity of Im2col-CONV is:
|
| 145 |
+
|
| 146 |
+
$$
|
| 147 |
+
\begin{array} { r l } & { \quad \lceil \frac { B * I C * ( D H + 2 P H ) * ( D W + 2 P W ) } { C _ { w } } \rceil + 1 + \left( \lceil \frac { B * I C * D H * D W } { C _ { w } } \rceil + 1 \right) } \\ & { + \frac { B * O H * O W * I C } { I C t } * ( \lceil \frac { I C _ { t } * K H * K W } { C _ { w } } \rceil + 1 ) + \left( 2 * O C * \frac { I C } { T C _ { t } } * ( \lceil \frac { K H * K W * I C _ { t } } { C _ { w } } \rceil + 1 ) \right) } \\ & { + B * O H * O W * I C * K H * ( \lceil \frac { O ( W _ { t } - 1 ) * s _ { 2 } + ( K W - 1 ) * d _ { 2 } + 1 } { C _ { w } } \rceil + 1 ) } \\ & { + C _ { m } ( B * O H * O W , I C * K H * K W , O C , O W _ { t } , I C _ { t } * K H * K W , O C _ { t } ) } \\ & { + B * O C * O H * \lceil \frac { O W } { O W _ { t } } \rceil * ( \lceil \frac { O W _ { t } } { C _ { w } } \rceil + 1 ) + \left( B * O H * O W * \lceil \frac { O C } { O C _ { t } } \rceil * ( \lceil \frac { O C _ { t } } { C _ { w } } \rceil + 1 ) \right) . } \end{array}
|
| 148 |
+
$$
|
| 149 |
+
|
| 150 |
+
120 Remark 1. For the cache complexity of CONV in TVM, we only need to replace the bold part in
|
| 151 |
+
121 Table $^ 3$ with $\begin{array} { r } { O C _ { t } \ast I C _ { t } \ast \big ( \lceil \frac { K W } { C _ { w } } \rceil + \dot { 1 } \big ) ^ { \ast } K W \ast I C _ { t } \ast \big ( \lceil O C _ { t } / \dot { C } _ { w } \rceil + 1 \big ) } \end{array}$ and $( l )$ in Theorem 2 by
|
| 152 |
+
122 $\begin{array} { r } { O C \ast I C \ast K H \ast \left( \left\lceil \frac { K W } { C _ { w } } \right\rceil + 1 \right) } \end{array}$ . It is usually larger than that of CONVOpt for the same tiling size.
|
| 153 |
+
123 Learning to choose schedules. We first evaluate the performance of each schedule on a dataset
|
| 154 |
+
124 consisting of matrices with sizes ranging from small to large. The experiments, reported in Section 4,
|
| 155 |
+
125 show that each one can be exclusively the best for certain types of sizes. We then choose the top
|
| 156 |
+
126 four best performed schedules as candidates and train a boosted tree model by Xgboost [7], with the
|
| 157 |
+
127 matrix size as input feature, to automatically select the best one for a particular size.
|
| 158 |
+
|
| 159 |
+
Table 2: Values of $T _ { m }$ for different schedules for matrix multiplication (from top to bottom: TMM, TTMM, DNMM, LPMM, RPMM, DPMM)
|
| 160 |
+
|
| 161 |
+
<table><tr><td>Tm(Mt,Kt,Nt)</td></tr><tr><td>Mt([1+1) + Nt([1+1) + Mt(「1+1)</td></tr><tr><td>Kt([1+1)+ max (Nt([1+1),Mt(「1+1) +Mt([+1)</td></tr><tr><td></td></tr><tr><td>Mt(1+1)+max(Mt([1+1),(Mt +Nt)(1+1))</td></tr><tr><td>Cw</td></tr><tr><td>[1+N[1+mx(M(1+1),(1+1)+1+1)) 1+max</td></tr><tr><td>(11+Mt,[1+t,[1+mx(M(1+1),[1++2)) 1 +max</td></tr></table>
|
| 162 |
+
|
| 163 |
+
Table 3: Values of $T _ { c }$ for convolution schedules (top: CONVOpt, bottom: Im2col-CONV)
|
| 164 |
+
|
| 165 |
+
<table><tr><td colspan="2">Tc(OWt,ICt,OCt)</td></tr><tr><td>max</td><td>OCt *([KH*KW*ICt1+1) +KH* KW *ICt *(fg +1+1), Cw Cw 1+1),([0Wx0Ct]+1)+0Wt * ([ Cw +KH* KW*ICt*([C] 0Ct] 1+1), C Cw C Ct1+1)+0Ct*( OWt*(「9 0Wt1 1+1) C C</td></tr><tr><td>max</td><td>(OWt-1)*s2+(KW-1)*d2+1 +1), OWt *([KH*KW*ICt]+1)+ICt *([ 2*OCt*([KH*KW*ICt]+1),OCt *( C OWt 1+1)+OWt*([ C+1+1), C Cw Tm(OWt,ICt * KH * KW,OCt)</td></tr></table>
|
| 166 |
+
|
| 167 |
+
128 Initializing the tiling size space. Suppose that there are $m$ dimensions to be tiled and the size of
|
| 168 |
+
129 each dimension is $X _ { i }$ , $i = 1 , \ldots , m$ . Then the number of valid one-level tilings is $\Pi _ { i = 1 } ^ { m } X _ { i }$ , which
|
| 169 |
+
130 is one billion for $X _ { i } ~ = ~ 1 0 0 0$ . Thus one has to set up a reasonable initial tiling size space. For
|
| 170 |
+
131 instance, in TVM, there are two basic strategies depending on the tiling size being a factor of $X _ { i }$ or a
|
| 171 |
+
132 power of 2. Suppose that there are $m$ dimensions $X _ { 1 } , \ldots , X _ { m }$ to be tiled, and each dimension has a
|
| 172 |
+
nested tiling of levels 133 direct product of the 134 $d _ { i }$ , s $i = 1 , \ldots , m$ f, trategy is a. We adopt $\begin{array} { r } { G _ { i } : = \{ ( X _ { i } ^ { ( 0 ) } , \dots , X _ { i } ^ { ( d _ { i } ) } ) \ | \ \prod _ { j = 0 } ^ { d _ { i } } \bar { X } _ { i } ^ { ( j ) } = X _ { i } \} } \end{array}$ $i = 1 , \ldots , m$ this factor strategy for 2D-convolution. For matrix multiplication, we propose a more sophisticated
|
| 173 |
+
136 strategy, motivated by both the factor strategy of TVM and the analytic model of [21] to balance
|
| 174 |
+
137 cache locality and load balancing among parallel threads. This strategy is described by Algorithm 1.
|
| 175 |
+
|
| 176 |
+
138 Filtering the tiling size space. Let $G ( Z _ { t } , Y _ { t } , X _ { t } )$ be the initial tiling size space for the com
|
| 177 |
+
139 pute/schedule pair $( O , S )$ , where $Z _ { t } , Y _ { t } , X _ { t }$ denote the innermost tiling sizes for the tiled dimensions
|
| 178 |
+
140 $Z , Y , X$ . Let $T ( X _ { t } , Y _ { t } , X _ { t } )$ be the cache fit formula $T _ { c }$ or $T _ { m }$ . Let $X$ be the dimension for vectoriza
|
| 179 |
+
141 tion and $X _ { t }$ be the tiling size for this dimension. We would only consider the tiling size satisfying
|
| 180 |
+
142 both $X \geq \operatorname* { m i n } ( X _ { t } , V _ { w } )$ and $T < Z _ { w } / C _ { w }$ and filter out the rest ones from $G$ .
|
| 181 |
+
143 Learning to choose optimal configurations. Except for the default schedule CONV of TVM, the
|
| 182 |
+
144 configuration space for all the schedules considered in this work is solely formed by different tiling
|
| 183 |
+
145 sizes. The schedule CONV has another knob unroll_kw to decide whether to unroll the for loop
|
| 184 |
+
146 involving the kernel dimension $K W$ . The size of the configuration space in our experiments is
|
| 185 |
+
147 usually less than 10, 000 thanks to the initialization and filter strategies. For this moderate size, we
|
| 186 |
+
148 find that the rather direct tuning strategy described by Algorithm 2 works quite well in practice.
|
| 187 |
+
|
| 188 |
+
# 149 4 Evaluation
|
| 189 |
+
|
| 190 |
+
150 We developed AutoMCL on top of TVM (0.6.0) and it will be released in open source. Three Intel
|
| 191 |
+
151 CPUs (Intel i7-G9700F, Intel i7-9750H, Intel i9-9900) and one AMD CPU (AMD-Ryzen9-3900X) are
|
| 192 |
+
152 used for evaluation. More detailed hardware information can be found in the supplemental material.
|
| 193 |
+
153 We first evaluate each optimization strategy individually based on TVM on randomly generated
|
| 194 |
+
154 datasets consisting of tensors of various sizes, in order to see if a particular optimization can speed up
|
| 195 |
+
155 either optimization time or inference time. Then we evaluate the whole integrated framework on both
|
| 196 |
+
156 the operation and the end-to-end level for typical fully connected and convolutional neural networks.
|
| 197 |
+
157 The maximum number of trials for the whole tuning and the early stopping are set respectively as
|
| 198 |
+
158 10, 000 and 400 for most of the experiments. The only exception is the end-to-end evaluation of
|
| 199 |
+
159 CNNs, where we set the two numbers respectively as 500 and 300.
|
| 200 |
+
|
| 201 |
+
# Algorithm 1: InitConfigSpace(O, S)
|
| 202 |
+
|
| 203 |
+
Input: A compute/schedule pair $( O , S )$ for matmul, the number of parallel threads $p$ .
|
| 204 |
+
Output: The initial configure space $G$ for tiling.
|
| 205 |
+
1 begin
|
| 206 |
+
2 if $S$ has 1-level tiling then
|
| 207 |
+
3 initialize $G ^ { \prime } , G _ { x } , G _ { y } , G _ { k } , G _ { y x }$ respectively as $\varnothing$ ;
|
| 208 |
+
4 for all factors $p _ { y }$ of $p$ do
|
| 209 |
+
5 $p _ { x } : = p / p _ { y }$ ; let $G _ { y }$ and $G _ { x }$ be respectively all the factors of $\lceil M / p _ { y } \rceil$ and $\lceil N / p _ { x } \rceil$ ;
|
| 210 |
+
6 $G _ { y x } : = \{ ( M _ { t } , N _ { t } ) \mid M _ { t } \in G _ { y } , N _ { t } \in G _ { x } \}$
|
| 211 |
+
7 let $G _ { k }$ be all the factors of $K \colon G : = \{ ( 1 , M _ { t } , 1 , N _ { t } , K _ { t } ) \mid ( M _ { t } , N _ { t } ) \in G _ { y x } , K _ { t } \in G _ { k } \} ;$
|
| 212 |
+
8 else if $S$ has 2-level tiling then
|
| 213 |
+
9 initialize $G ^ { \prime } , G _ { x } , G _ { y } , G _ { k } , G _ { y x }$ respectively as $\varnothing$ ;
|
| 214 |
+
10 for all factors $p _ { y }$ of $p$ do
|
| 215 |
+
11 $p _ { x } : = p / p _ { y }$ ;
|
| 216 |
+
12 $\begin{array} { r l } & { \mathrm { l e t } G _ { y } : = \big \{ ( M _ { o } , M _ { t } ) : M _ { o } M _ { t } | [ M / p _ { y } ] \big \} ; G _ { x } : = \big \{ ( N _ { o } , N _ { t } ) : N _ { o } N _ { t } | [ N / p _ { x } ] ; } \\ & { G _ { y x } : = \big \{ ( M _ { o } , M _ { t } , N _ { o } , N _ { t } ) \big | \big ( M _ { o } , M _ { t } \big ) \in G _ { y } , \big ( N _ { o } , N _ { t } \big ) \in G _ { x } \big \} } \end{array}$
|
| 217 |
+
13
|
| 218 |
+
14 let $G _ { k }$ be all the factors of $K$ ;
|
| 219 |
+
15 $G : = \{ ( M _ { o } , M _ { t } , N _ { o } , N _ { t } , K _ { t } ) \mid ( M _ { o } , M _ { t } , N _ { o } , N _ { t } ) \in G _ { y x } , K _ { t } \in G _ { k } \} ;$
|
| 220 |
+
$^ { \prime * }$ Due to limitation of TVM, it is additionally rquired that $M _ { t } | M$ for
|
| 221 |
+
LPMM, $N _ { t } | N$ for RPMM and $M _ { t } | M , N _ { t } | N$ for DPMM. \*
|
| 222 |
+
16 return G
|
| 223 |
+
|
| 224 |
+
# $\overline { { \mathrm { A l g o r i t h m ~ } 2 } } \colon \mathsf { A u t o C o n f i g } ( O , S , G , m , n , b )$
|
| 225 |
+
|
| 226 |
+
Input: The compute/schedule pair $( O , S )$ , the configuration space $G$ for $( O , S )$ , the maximum
|
| 227 |
+
number of trials $m$ , the batch size $n$ for restarting training, the batch size $b$ for a parallel run.
|
| 228 |
+
Output: The optimal configuration.
|
| 229 |
+
1 begin
|
| 230 |
+
2 $D : = \varnothing ; t : = 0$ ; randomly pop $n$ configurations from $G$ and put in $N$ ;
|
| 231 |
+
3 while true do
|
| 232 |
+
4 while $N \neq \emptyset$ do
|
| 233 |
+
5 choose $b$ configurations $B$ from $N ; N : = N \setminus B$ ;
|
| 234 |
+
6 in parallel, run the code compiled from the tuple $( O , S , c )$ , $c \in B$ , on hardware;
|
| 235 |
+
7 add $B$ examples labelled with (averaged) running timings to $D ; t : = t + | N |$ ;
|
| 236 |
+
8 if $G \neq \emptyset$ and $t < m$ then
|
| 237 |
+
9 train a ML model with $D$ and predict the running timings of $( O , S , c )$ , $c \in G$ ;
|
| 238 |
+
10 pop the best (shortest predicted timing) $n$ configurations $N$ from $G$ ;
|
| 239 |
+
11 else
|
| 240 |
+
12 break;
|
| 241 |
+
13 return the configurations in $D$ with the shortest running time
|
| 242 |
+
160 Comparison of different schedules. To make a fair comparison, we create two testing datasets
|
| 243 |
+
161 consisting of examples of various dimension sizes for matrix multiplication and convolution. For
|
| 244 |
+
162 matrix multiplication, a dimension size is chosen in three different scales, with small size in $\{ 1 , 8 , 1 6 \}$ ,
|
| 245 |
+
163 medium size in $\{ 6 4 , 2 5 6 \}$ and large size in $\{ 1 0 2 4 , 4 0 9 6 \}$ , which creates $7 ^ { 3 }$ different combinations.
|
| 246 |
+
164 We remove 5 extreme size cases and add additional 120 examples with each dimension randomly
|
| 247 |
+
165 taking values in 1..4096. For convolution, we create a dataset of the same size (458) as matrix mul
|
| 248 |
+
166 tiplication. The dimensions of each convolution example $\left( D _ { B \times I C \times D H \times D W } \right.$ , $W _ { O C \times I C \times K H \times K W } )$
|
| 249 |
+
167 with stride $s$ and padding size $p$ randomly take values by the following rule: $B \in \{ 1 , 3 2 , 1 2 8 \}$ ,
|
| 250 |
+
168 $I C \in \{ 2 ^ { 0 } \cdot \cdot \cdot 2 ^ { 1 4 } \bar \}$ , $O C ^ { - } \in \{ 2 ^ { 0 } . . 2 ^ { 1 4 } \}$ , $D H = D W \in \{ 1 \cdot \cdot \cdot 2 5 6 \}$ , $K H = K W \in \{ 1 , 3 , 5 , 7 \}$ ,
|
| 251 |
+
169 $s \in \{ 1 , 2 \}$ , $p = \lfloor ( K H - 1 ) / 2 \rfloor$ . In addition, we only keep examples with each dimension size less
|
| 252 |
+
170 than 4096 in their im2col representations.
|
| 253 |
+
171 Fig. 2 reports the proportions of examples with the shortest running time or the lowest cache misses
|
| 254 |
+
172 (measured by the ideal cache model) for different schedules implementing matrix multiplication or
|
| 255 |
+
173 convolution. The experiments show that each schedule can be exclusively the best for certain types of
|
| 256 |
+
174 tensor sizes. Here we allow a 0.02 tolerance for being the best. Our manually improved schedule
|
| 257 |
+
175 DNMM332, RPMMV and CONVOpt indeed work better than their counterparts. Moreover, the real
|
| 258 |
+
176 and the theoretical measure correlate quite well for the “top performed” schedules, except for the two
|
| 259 |
+
based on DNMM, which however have a different vectorization dimension from the others.
|
| 260 |
+
178 Evaluation of automatic schedule chosen. With performing exclusively the best on at least $5 \%$ of
|
| 261 |
+
179 the dataset as a criterion, four “top performed” schedules DNMM332, RPMMV, LPMM, TMM are
|
| 262 |
+
180 selected for matmul and three are selected for conv2d. For matmul, we adopt Xgboost to automatically
|
| 263 |
+
181 choose the best schedule among the four for a given problem size. The dataset is the same as the
|
| 264 |
+
182 one in last subsection, from which 40 randomly chosen examples are reserved for the testing dataset
|
| 265 |
+
183 and the rest for the training dataset. Fig. 3 reports the performance on the testing dataset, where
|
| 266 |
+
184 AutoSchedule denotes the learned schedule and OptSchedule stands for choosing schedules in a static
|
| 267 |
+
185 manner as TVM but with DNMM and RPMM replaced respectively by DNMM332 and RPMMV.
|
| 268 |
+
For conv2d, the learning approach does not work quite well and we instead use CONVOpt as the
|
| 269 |
+
187 default implementation since it performs better than CONV while having the same advantage as
|
| 270 |
+
188 CONV on leveraging NCHWc layout optimization [18] in the end-to-end inference.
|
| 271 |
+
189 Evaluation of tiling size space initialization and filter. Fig. 4 illustrates how the two default
|
| 272 |
+
190 schedules for matmul (DNMM when $M \leq 1 6$ and RPMM when $M > 1 6$ ) perform when being
|
| 273 |
+
191 combined with different strategies for initializing the tiling size space. The left image shows the
|
| 274 |
+
192 speedup over the base (factor). The middle and right images show the space swell ratio over the
|
| 275 |
+
193 base (factor). Our strategy pfactor shrinks the tiling size space more than $4 0 \%$ for matrices with
|
| 276 |
+
194 powers of 2 sizes without an obvious performance loss. For the dataset consisting of matrices of
|
| 277 |
+
195 prime number sizes, pfactor brings 1.2 speedup on average.
|
| 278 |
+
|
| 279 |
+

|
| 280 |
+
Figure 2: Performance of different candidate schedules for matmul and conv2d.
|
| 281 |
+
|
| 282 |
+

|
| 283 |
+
Figure 3: Performance of OptSchedule and AutoSchedule for matmul.
|
| 284 |
+
|
| 285 |
+
196 Fig. 5 show that the filter strategy further reduces tiling space size while not loosing performance.
|
| 286 |
+
|
| 287 |
+

|
| 288 |
+
Figure 4: Performance of different initialization strategy for matmul.
|
| 289 |
+
|
| 290 |
+

|
| 291 |
+
Figure 5: Performance of the proposed filter strategy for pruning the tiling size space.
|
| 292 |
+
|
| 293 |
+
197 Comparison of different configuration space exploiting strategies. Fig. 6 compares AutoTVM’s 198 exploration module $\mathbf { \Delta S A { + R A N K } } )$ ) and AutoMCL’s performance model (REG) on tuning GEMMs of 199 different sizes. The left and right image show the average performance of tuned matrix multiplications and the average tuning time.
|
| 294 |
+
|
| 295 |
+

|
| 296 |
+
Figure 6: Comparison between AutoTVM and AutoMCL on exploring the configuration space.
|
| 297 |
+
|
| 298 |
+
201 Evaluation of AutoMCL on the operation and the end-to-end level. Now we evaluate the per
|
| 299 |
+
202 formance of AutoMCL, which integrates all the optimization strategies introduced in Section 3, on
|
| 300 |
+
203 optimizing matmul and conv2d for both fully connected neural networks (FCNNs) [26] and typical
|
| 301 |
+
204 convolutional neural networks (CNNs) ResNet-50 [14], Inception-v3[24], and VGG16 [22].
|
| 302 |
+
205 Ablation analysis. We analyze the effects of adding different optimizations on the performance,
|
| 303 |
+
206 where $O S$ and $A S$ stand for using respectively the optimized and the automatically chosen schedules.
|
| 304 |
+
|
| 305 |
+

|
| 306 |
+
Figure 7: Evaluating the operations matmul and conv2d for FCNNs and CNNs.
|
| 307 |
+
|
| 308 |
+

|
| 309 |
+
Figure 8: End-to-end evaluation on FCNNs with batch size ${ \mathrm { : = } } 2 ^ { i }$ $\Sigma ^ { i } , i = 0 , \dots , 9$ on an Intel CPU.
|
| 310 |
+
|
| 311 |
+

|
| 312 |
+
Figure 9: End-to-end evaluation on CNNs.
|
| 313 |
+
|
| 314 |
+

|
| 315 |
+
Figure 10: Ablation analysis on a dense layer and a convolution layer from CNNs.
|
| 316 |
+
|
| 317 |
+
# 207 5 Conclusion
|
| 318 |
+
|
| 319 |
+
208 In this paper, we have introduced a framework AutoMCL to auto-tune the matrix multiplication and
|
| 320 |
+
209 the 2D-convolution operations in fully connected and convolutional neural networks by leveraging
|
| 321 |
+
210 both analytic and machine learning models. Experiments show that it outperforms AutoTVM on both
|
| 322 |
+
211 inference speed and optimization cost for FCNNs and is competitive to AutoTVM for CNNs. In the
|
| 323 |
+
212 future, we plan to further improve its performance by designing better strategies on automatically
|
| 324 |
+
213 choosing the optimal schedule.
|
| 325 |
+
|
| 326 |
+
# References
|
| 327 |
+
|
| 328 |
+
[1] Intel oneDNN. https://01.org/oneDNN.
|
| 329 |
+
|
| 330 |
+
[2] Intel oneMKL. https://software.intel.com/content/www/us/en/develop/tools/ oneapi/components/onemkl.html.
|
| 331 |
+
|
| 332 |
+
[3] NVIDIA cuDNN. https://developer.nvidia.com/cudnn.
|
| 333 |
+
|
| 334 |
+
[4] Martín Abadi, Paul Barham, Jianmin Chen, Zhifeng Chen, Andy Davis, Jeffrey Dean, Matthieu Devin, Sanjay Ghemawat, Geoffrey Irving, Michael Isard, et al. Tensorflow: A system for large-scale machine learning. In 12th {USENIX} symposium on operating systems design and implementation $\left\{ O S D I \right\} 1 { \bar { 6 } } )$ , pages 265–283, 2016.
|
| 335 |
+
|
| 336 |
+
[5] Byung Hoon Ahn, Prannoy Pilligundla, Amir Yazdanbakhsh, and Hadi Esmaeilzadeh. Chameleon: Adaptive code optimization for expedited deep neural network compilation. arXiv preprint arXiv:2001.08743, 2020.
|
| 337 |
+
|
| 338 |
+
[6] Riyadh Baghdadi, Abdelkader Nadir Debbagh, Kamel Abdous, Fatima Zohra Benhamida, Alex Renda, Jonathan Elliott Frankle, Michael Carbin, and Saman Amarasinghe. Tiramisu: A polyhedral compiler for dense and sparse deep learning, 2020.
|
| 339 |
+
|
| 340 |
+
[7] Tianqi Chen and Carlos Guestrin. Xgboost: A scalable tree boosting system. In Proceedings of the 22nd acm sigkdd international conference on knowledge discovery and data mining, pages 785–794, 2016.
|
| 341 |
+
|
| 342 |
+
[8] Tianqi Chen, Mu Li, Yutian Li, Min Lin, Naiyan Wang, Minjie Wang, Tianjun Xiao, Bing Xu, Chiyuan Zhang, and Zheng Zhang. Mxnet: A flexible and efficient machine learning library for heterogeneous distributed systems. arXiv preprint arXiv:1512.01274, 2015.
|
| 343 |
+
|
| 344 |
+
[9] Tianqi Chen, Thierry Moreau, Ziheng Jiang, Lianmin Zheng, Eddie Yan, Haichen Shen, Meghan Cowan, Leyuan Wang, Yuwei Hu, Luis Ceze, et al. TVM: An automated end-to-end optimizing compiler for deep learning. In 13th USENIX Symposium on Operating Systems Design and Implementation (OSDI 18), pages 578–594, 2018.
|
| 345 |
+
|
| 346 |
+
[10] Tianqi Chen, Lianmin Zheng, Eddie Yan, Ziheng Jiang, Thierry Moreau, Luis Ceze, Carlos Guestrin, and Arvind Krishnamurthy. Learning to optimize tensor programs. Advances in Neural Information Processing Systems, 31:3389–3400, 2018.
|
| 347 |
+
|
| 348 |
+
[11] Pratik Fegade, Tianqi Chen, Phil Gibbons, and Todd Mowry. Cortex: A compiler for recursive deep learning models. CoRR, abs/2011.01383, 2020.
|
| 349 |
+
|
| 350 |
+
[12] Matteo Frigo, Charles E. Leiserson, Harald Prokop, and Sridhar Ramachandran. Cache-oblivious algorithms. ACM Trans. Algorithms, 8(1), January 2012.
|
| 351 |
+
|
| 352 |
+
[13] Kazushige Goto and Robert A van de Geijn. Anatomy of high-performance matrix multiplication. ACM Transactions on Mathematical Software (TOMS), 34(3):1–25, 2008.
|
| 353 |
+
|
| 354 |
+
[14] Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. Deep residual learning for image recognition. In 2016 IEEE Conference on Computer Vision and Pattern Recognition (CVPR), pages 770–778, 2016.
|
| 355 |
+
|
| 356 |
+
[15] Menghao Li, Minjia Zhang, Chi Wang, and Mingqin Li. Adatune: Adaptive tensor program compilation made efficient. Advances in Neural Information Processing Systems, 33, 2020.
|
| 357 |
+
|
| 358 |
+
[16] Mingzhen Li, Yi Liu, Xiaoyan Liu, Qingxiao Sun, Xin You, Hailong Yang, Zhongzhi Luan, Lin Gan, Guangwen Yang, and Depei Qian. The deep learning compiler: A comprehensive survey. IEEE Transactions on Parallel and Distributed Systems, 32(3):708–727, 2020.
|
| 359 |
+
|
| 360 |
+
[17] Rui Li, Yufan Xu, Aravind Sukumaran-Rajam, Atanas Rountev, and P. Sadayappan. Analytical characterization and design space exploration for optimization of cnns. In Proceedings of the 26th ACM International Conference on Architectural Support for Programming Languages and Operating Systems, ASPLOS 2021, page 928–942, New York, NY, USA, 2021. Association for Computing Machinery.
|
| 361 |
+
|
| 362 |
+
[18] Yizhi Liu, Yao Wang, Ruofei Yu, Mu Li, Vin Sharma, and Yida Wang. Optimizing CNN model inference on cpus. In 2019 USENIX Annual Technical Conference (USENIX ATC 19), pages 1025–1040, Renton, WA, July 2019. USENIX Association.
|
| 363 |
+
[19] Adam Paszke, Sam Gross, Francisco Massa, Adam Lerer, James Bradbury, Gregory Chanan, Trevor Killeen, Zeming Lin, Natalia Gimelshein, Luca Antiga, et al. Pytorch: An imperative style, high-performance deep learning library. arXiv preprint arXiv:1912.01703, 2019.
|
| 364 |
+
[20] Jonathan Ragan-Kelley, Connelly Barnes, Andrew Adams, Sylvain Paris, Frédo Durand, and Saman Amarasinghe. Halide: A language and compiler for optimizing parallelism, locality, and recomputation in image processing pipelines. SIGPLAN Not., 48(6):519–530, June 2013.
|
| 365 |
+
[21] Yukinori Sato, Tomoya Yuki, and Toshio Endo. An autotuning framework for scalable execution of tiled code via iterative polyhedral compilation. ACM Transactions on Architecture and Code Optimization (TACO), 15(4):1–23, 2019.
|
| 366 |
+
[22] Karen Simonyan and Andrew Zisserman. Very deep convolutional networks for large-scale image recognition. In Yoshua Bengio and Yann LeCun, editors, 3rd International Conference on Learning Representations, ICLR 2015, San Diego, CA, USA, May 7-9, 2015, Conference Track Proceedings, 2015.
|
| 367 |
+
[23] Benoit Steiner, Chris Cummins, Horace He, and Hugh Leather. Value learning for throughput optimization of deep learning workloads. In Proceedings of the 4th MLSys Conference, San Jose, CA, USA, 2021.
|
| 368 |
+
[24] Christian Szegedy, Vincent Vanhoucke, Sergey Ioffe, Jon Shlens, and Zbigniew Wojna. Rethinking the inception architecture for computer vision. In 2016 IEEE Conference on Computer Vision and Pattern Recognition (CVPR), pages 2818–2826, 2016.
|
| 369 |
+
[25] Nicolas Vasilache, Oleksandr Zinenko, Theodoros Theodoridis, Priya Goyal, Zachary DeVito, William S Moses, Sven Verdoolaege, Andrew Adams, and Albert Cohen. Tensor comprehensions: Framework-agnostic high-performance machine learning abstractions. arXiv preprint arXiv:1802.04730, 2018.
|
| 370 |
+
[26] Yu Emma Wang, Gu-Yeon Wei, and David Brooks. Benchmarking tpu, gpu, and cpu platforms for deep learning. arXiv preprint arXiv:1907.10701, 2019.
|
| 371 |
+
[27] R. Clinton Whaley and Jack J Dongarra. Automatically tuned linear algebra software. In SC’98: Proceedings of the 1998 ACM/IEEE conference on Supercomputing, pages 38–38. IEEE, 1998.
|
| 372 |
+
[28] Huaqing Zhang, Xiaolin Cheng, Hui Zang, and Dae Hoon Park. Compiler-level matrix multiplication optimization for deep learning. arXiv preprint arXiv:1909.10616, 2019.
|
| 373 |
+
[29] Lianmin Zheng, Chengfan Jia, Minmin Sun, Zhao Wu, Cody Hao Yu, Ameer Haj-Ali, Yida Wang, Jun Yang, Danyang Zhuo, Koushik Sen, et al. Ansor: Generating high-performance tensor programs for deep learning. In 14th {USENIX} Symposium on Operating Systems Design and Implementation $\langle \bar \langle O S D I \} \bar { 2 0 } \rangle$ , pages 863–879, 2020.
|
| 374 |
+
[30] Size Zheng, Yun Liang, Shuo Wang, Renze Chen, and Kaiwen Sheng. Flextensor: An automatic schedule exploration and optimization framework for tensor computation on heterogeneous system. In Proceedings of the Twenty-Fifth International Conference on Architectural Support for Programming Languages and Operating Systems, pages 859–873, 2020.
|
| 375 |
+
|
| 376 |
+
# 301 Checklist
|
| 377 |
+
|
| 378 |
+
The checklist follows the references. Please read the checklist guidelines carefully for information on how to answer these questions. For each question, change the default [TODO] to [Yes] , [No] , or [N/A] . You are strongly encouraged to include a justification to your answer, either by referencing the appropriate section of your paper or providing a brief inline description. For example:
|
| 379 |
+
|
| 380 |
+
• Did you include the license to the code and datasets? [Yes] See Section ??.
|
| 381 |
+
|
| 382 |
+
• Did you include the license to the code and datasets? [No] The code and the data are proprietary.
|
| 383 |
+
• Did you include the license to the code and datasets? [N/A]
|
| 384 |
+
|
| 385 |
+
Please do not modify the questions and only use the provided macros for your answers. Note that the Checklist section does not count towards the page limit. In your paper, please delete this instructions block and only keep the Checklist section heading above along with the questions/answers below.
|
| 386 |
+
|
| 387 |
+
1. For all authors...
|
| 388 |
+
|
| 389 |
+
(a) Do the main claims made in the abstract and introduction accurately reflect the paper’s contributions and scope? [Yes]
|
| 390 |
+
(b) Did you describe the limitations of your work? [Yes] See Section 4 on “Evaluation of automatic schedule chosen”.
|
| 391 |
+
(c) Did you discuss any potential negative societal impacts of your work? [N/A]
|
| 392 |
+
(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
|
| 393 |
+
|
| 394 |
+
2. If you are including theoretical results...
|
| 395 |
+
|
| 396 |
+
(a) Did you state the full set of assumptions of all theoretical results? [Yes] (b) Did you include complete proofs of all theoretical results? [Yes] , but only in the supplemental material due to space limit.
|
| 397 |
+
|
| 398 |
+
3. If you ran experiments...
|
| 399 |
+
|
| 400 |
+
(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes] , in the supplemental material.
|
| 401 |
+
(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] , in the supplemental material.
|
| 402 |
+
(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [Yes] , see Section 4 on “Ablation analysis”
|
| 403 |
+
(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] , in the supplemental material.
|
| 404 |
+
|
| 405 |
+
4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
|
| 406 |
+
|
| 407 |
+
(a) If your work uses existing assets, did you cite the creators? [Yes]
|
| 408 |
+
(b) Did you mention the license of the assets? [Yes] , in the supplemental material.
|
| 409 |
+
(c) Did you include any new assets either in the supplemental material or as a URL? [Yes]
|
| 410 |
+
(d) Did you discuss whether and how consent was obtained from people whose data you’re using/curating? [N/A]
|
| 411 |
+
(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A]
|
| 412 |
+
|
| 413 |
+
5. If you used crowdsourcing or conducted research with human subjects...
|
| 414 |
+
|
| 415 |
+
(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
|
| 416 |
+
(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
|
| 417 |
+
(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
|
parse/train/PhtFY9plHk/PhtFY9plHk_content_list.json
ADDED
|
@@ -0,0 +1,1163 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
[
|
| 2 |
+
{
|
| 3 |
+
"type": "text",
|
| 4 |
+
"text": "Auto-tuning Matrix Multiplication and Convolution for Deep Learning on CPUs ",
|
| 5 |
+
"text_level": 1,
|
| 6 |
+
"bbox": [
|
| 7 |
+
186,
|
| 8 |
+
122,
|
| 9 |
+
813,
|
| 10 |
+
172
|
| 11 |
+
],
|
| 12 |
+
"page_idx": 0
|
| 13 |
+
},
|
| 14 |
+
{
|
| 15 |
+
"type": "text",
|
| 16 |
+
"text": "Anonymous Author(s) \nAffiliation \nAddress \nemail ",
|
| 17 |
+
"bbox": [
|
| 18 |
+
423,
|
| 19 |
+
226,
|
| 20 |
+
580,
|
| 21 |
+
281
|
| 22 |
+
],
|
| 23 |
+
"page_idx": 0
|
| 24 |
+
},
|
| 25 |
+
{
|
| 26 |
+
"type": "text",
|
| 27 |
+
"text": "Abstract ",
|
| 28 |
+
"text_level": 1,
|
| 29 |
+
"bbox": [
|
| 30 |
+
462,
|
| 31 |
+
318,
|
| 32 |
+
535,
|
| 33 |
+
334
|
| 34 |
+
],
|
| 35 |
+
"page_idx": 0
|
| 36 |
+
},
|
| 37 |
+
{
|
| 38 |
+
"type": "text",
|
| 39 |
+
"text": "1 Deep learning (DL) compilers have emerged aiming to reduce the gap between \n2 abundant, fast-growing DL models and the lag of high performance implemen \n3 tations of these models on diverse hardware devices. In this work, we introduce \n4 several optimization strategies, combining analytic ideal cache models with ma \n5 chine learning models trained with real hardware measures, and integrate them into \n6 a unified auto-tuning framework, called AutoMCL, to improve the performance \n7 of DL compilers on both the operation level and the end-to-end model inference. \n8 We evaluate AutoMCL and compare it with state-of-the-art on multiple CPUs. \n9 End-to-end evaluations show that AutoMCL outperforms TensforFlow on fully \n10 connected and convolutional neural networks with respectively a geometric mean \n11 of $9 . 2 9 \\times$ and $1 . 5 4 \\times$ speedup. Over the baseline AutoTVM, on average, AutoMCL \n12 achieves respectively $1 . 3 7 \\times$ and $2 . 1 6 \\times$ speedup in inference and optimization time \n13 for fully connected neural networks and gains ${ \\bar { 2 } } . 5 5 \\%$ performance improvement in \n14 inference for convolutional neural networks with $1 . 9 1 \\%$ more optimization cost. ",
|
| 40 |
+
"bbox": [
|
| 41 |
+
148,
|
| 42 |
+
349,
|
| 43 |
+
767,
|
| 44 |
+
544
|
| 45 |
+
],
|
| 46 |
+
"page_idx": 0
|
| 47 |
+
},
|
| 48 |
+
{
|
| 49 |
+
"type": "text",
|
| 50 |
+
"text": "15 1 Introduction ",
|
| 51 |
+
"text_level": 1,
|
| 52 |
+
"bbox": [
|
| 53 |
+
148,
|
| 54 |
+
570,
|
| 55 |
+
312,
|
| 56 |
+
588
|
| 57 |
+
],
|
| 58 |
+
"page_idx": 0
|
| 59 |
+
},
|
| 60 |
+
{
|
| 61 |
+
"type": "text",
|
| 62 |
+
"text": "16 Deep learning models have found wide applications in image and sound recognition, natural language \n17 translation, game playing, etc. The success of deep learning benefits greatly from the accessibility \n18 of DL frameworks, such as TensforFlow [4], PyTorch [19] and MXNet [8], which not only ease the \n19 burden of coding but also provide high performance supports through efficient low-level libraries, \n20 such as Intel oneMKL [2] or NVIDIA cuDNN [3]. However, it is difficult to make the library \n21 development, which requires tremendous manual engineering effort entangled with hardwares and \n22 often takes months or even years to finish, keep pace with the rapid innovation of DL models. As \n23 a result, many newly introduced neural networks or operators may lack optimal implementation \n24 support on the target hardwares, thus hindering the further innovation of DL models. To address \n25 this challenge, DL compilers (e.g. TVM [9] and TensorComprehensions [25]) emerged [16], whose \n26 goal is to automatically compile high-level declarations of DL operators into efficient low-level code \n27 across various hardware devices, including CPUs, GPUs, FPGAs, and ASICs. \n28 To make the DL compilers appealing, it is essential to keep their performance competitive or even \n29 superior to that of DL frameworks or hand-optimized libraries. To achieve this, state-of-the-art DL \n30 compilers, such as TVM and its successor AutoTVM [10], extend the decoupled compute/schedule \n31 principle of Halide [20] to separate target hardware intrinsics from computation description and \n32 optimization sequence specification composed of transform primitives to ease the process of high \n33 level optimization, and leverage machine learning to automate low-level optimizations. The success \n34 of DL compilers relies on high-quality schedules as well as effective searching and learning strategies \n35 to find optimal parameters. Recently, new progress have been made on automating the design of \n36 schedule primitives, enlarging the parameter space to expose more tuning opportunities and utilizing \n37 heuristic and learning approaches, in particular reinforcement learning, to explore the parameter \n38 space more effectively to find optimal candidates. Among these work, AdaTune [15], Ansor [29], \n39 CHAMELEON [5], FlexTensor [30] and Cortex [11] are built on top of TVM while the value function \n40 method [23] and TIRAMISU [6] are respectively based on Halide and the polyhedral model. \n41 Most of these optimizations have been focusing on the loop level optimizations, such as loop tiling, \n42 loop split and fuse, loop unroll, loop reordering, vectorization, etc. The algorithm level optimization, \n43 on the other hand, is hard to automate and still requires human’s expertise. Moreover, while enlarging \n44 the tuning space may potentially include better candidates, it also calls more effort to find the optimal \n45 solution and often leads to getting suboptimal solution in limited budget. Thus, it remains a great \n46 challenge to prune the parameter space efficiently to avoid unnecessary exploration, which may also \n47 help increase the chance of optimal solutions to be picked earlier. A purely analytical modeling \n48 approach for optimizing convolutions [17] was recently proposed towards this direction. \n49 In this work, we propose several new strategies aiming to leverage both analytic model and machine \n50 learning to generate more efficient code in shorter compilation time targeting on the CPU platforms, \n51 the ubiquity of which implies that a great number of users can benefit from such improvement. Our \n52 main contributions are three-fold: ",
|
| 63 |
+
"bbox": [
|
| 64 |
+
147,
|
| 65 |
+
603,
|
| 66 |
+
825,
|
| 67 |
+
768
|
| 68 |
+
],
|
| 69 |
+
"page_idx": 0
|
| 70 |
+
},
|
| 71 |
+
{
|
| 72 |
+
"type": "text",
|
| 73 |
+
"text": "",
|
| 74 |
+
"bbox": [
|
| 75 |
+
145,
|
| 76 |
+
775,
|
| 77 |
+
825,
|
| 78 |
+
900
|
| 79 |
+
],
|
| 80 |
+
"page_idx": 0
|
| 81 |
+
},
|
| 82 |
+
{
|
| 83 |
+
"type": "text",
|
| 84 |
+
"text": "",
|
| 85 |
+
"bbox": [
|
| 86 |
+
147,
|
| 87 |
+
92,
|
| 88 |
+
825,
|
| 89 |
+
147
|
| 90 |
+
],
|
| 91 |
+
"page_idx": 1
|
| 92 |
+
},
|
| 93 |
+
{
|
| 94 |
+
"type": "text",
|
| 95 |
+
"text": "",
|
| 96 |
+
"bbox": [
|
| 97 |
+
147,
|
| 98 |
+
154,
|
| 99 |
+
825,
|
| 100 |
+
265
|
| 101 |
+
],
|
| 102 |
+
"page_idx": 1
|
| 103 |
+
},
|
| 104 |
+
{
|
| 105 |
+
"type": "text",
|
| 106 |
+
"text": "",
|
| 107 |
+
"bbox": [
|
| 108 |
+
147,
|
| 109 |
+
270,
|
| 110 |
+
825,
|
| 111 |
+
325
|
| 112 |
+
],
|
| 113 |
+
"page_idx": 1
|
| 114 |
+
},
|
| 115 |
+
{
|
| 116 |
+
"type": "text",
|
| 117 |
+
"text": "• We introduce new strategies for initializing and filtering the tiling size space for matrix multiplication and convolution based on analytic models. \n• We introduce several new competitive schedules for matrix multiplication and convolution in both algorithm and loop level to enlarge the schedule space. \n• We integrate the proposed strategies into a new auto-tuning framework called AutoMCL, which leverages TVM’s frontend computational graph optimization and backend code generation functionalities. We conduct operator level and end-to-end evaluations showing that the overall performance of AutoMCL is superior to AutoTVM in both inference and optimization time on typical fully connected or convolutional neural networks. ",
|
| 118 |
+
"bbox": [
|
| 119 |
+
215,
|
| 120 |
+
332,
|
| 121 |
+
825,
|
| 122 |
+
458
|
| 123 |
+
],
|
| 124 |
+
"page_idx": 1
|
| 125 |
+
},
|
| 126 |
+
{
|
| 127 |
+
"type": "text",
|
| 128 |
+
"text": "62 2 Background ",
|
| 129 |
+
"text_level": 1,
|
| 130 |
+
"bbox": [
|
| 131 |
+
148,
|
| 132 |
+
478,
|
| 133 |
+
308,
|
| 134 |
+
494
|
| 135 |
+
],
|
| 136 |
+
"page_idx": 1
|
| 137 |
+
},
|
| 138 |
+
{
|
| 139 |
+
"type": "text",
|
| 140 |
+
"text": "63 The operations matrix multiplication and convolution appear widely in many deep neural networks \n64 and improving their performance is critical to speed up the the training and inference. Matrix multi \n65 plication has been implemented on CPU in many basic linear algebra libraries, such as ATLAS [27], \n66 GotoBLAS [13] and Intel oneMKL [2]. The convolution operation was also implemented on CPU in \n67 several standalone libraries, such as Intel oneDNN [1]. In the context of deep learning, there is a a \n68 strong demand to deploy a well-trained model to a great variety and amount of devices such that the \n69 model can infer in real time on the target hardwares. This offers new challenges and opportunities for \n70 auto-tuning the performance of these two operations for fixed size input tensors [28, 18]. \n71 Matrix multiplication and 2D-convolution operators. Mathematically, the matrix multiplica \n72 tion operator matmul takes two matrices $A _ { M \\times K }$ and $B _ { K \\times N }$ as input and computes their prod \n73 uct and 74 $C _ { M \\times N }$ . In this paper, we woomputes a new matrix umeby $D _ { M \\times K }$ \n$W _ { N \\times K }$ $C _ { M \\times N }$ $\\begin{array} { r } { C _ { i j } : = \\sum _ { k = 0 } ^ { \\mathbf { \\bar { K } } - 1 } A _ { i k } B _ { j k } } \\end{array}$ \noperator conv2d, in its simplest form, takes a tensor $D$ of dimensions $\\bar { B } \\times I C \\times D H \\times D W$ , \n76 a tensor $W$ of dimensions $O C \\times I C \\times K H \\times K W$ , two stride sizes $s _ { 1 } , s _ { 2 }$ , and produces \n77 a tensor $C$ of dimensions $B \\times O C \\times O H \\times O W$ , where $O H \\ = \\ ( D H - K H ) / s _ { 1 } + 1$ \n78 and $O W \\ = \\ ( D W - K W ) / s _ { 2 } + 1$ . Each element of $C$ is computed according to the rule \n79 PIC−1i=0 PKH−1ky=0 PKW −1kx=0 Db,i,s1y+ky,s2x+kx Wo,i,ky,kx . In general, it may also takes \n80 two padding sizes $P H$ , $P W$ and two dilation sizes $d _ { 1 }$ , $d _ { 2 }$ and produces a tensor of dimen \n81 sions $B \\times O C \\times O H \\times O W$ , where $O H = ( D H + 2 P H - ( \\bar { K } H - 1 ) d _ { 1 } - 1 ) / s _ { 1 } + 1$ and \n82 $O W = ( D W + 2 P W - ( K W - 1 ) d _ { 2 } - 1 ) / s _ { 2 } + 1$ . \n83 Ideal cache model. The ideal cache model was introduced in [12] for studying the cache complexity \n84 of algorithms. It assumes that the computer has a two-level memory hierarchy consisting of an ideal \n85 cache of $Z$ words with cache line size $C$ , where $Z \\gg C$ , and an arbitrarily large main memory. To \n86 access a word in main memory, it first searches it in cache. If the word does not reside in the cache, \n87 a cache miss occurs and a cache line containing the word is loaded into the cache from the main \n88 memory. It assumes that the cache is fully associative and the line with furthest access in the future \n89 will be replaced if new data is loaded into a full cache. The cache complexity counts the number of \n90 cache misses. For instance, the (worst) cache complexity for scanning $n$ words continuously stored in \n91 an array is $\\lceil n / C \\rceil + 1$ . In general, the cache complexity of an algorithm operating on a tensor largely \n92 depends on the layout of the tensor and the ordering for visiting the dimensions of the tensor. ",
|
| 141 |
+
"bbox": [
|
| 142 |
+
147,
|
| 143 |
+
510,
|
| 144 |
+
825,
|
| 145 |
+
622
|
| 146 |
+
],
|
| 147 |
+
"page_idx": 1
|
| 148 |
+
},
|
| 149 |
+
{
|
| 150 |
+
"type": "text",
|
| 151 |
+
"text": "",
|
| 152 |
+
"bbox": [
|
| 153 |
+
145,
|
| 154 |
+
637,
|
| 155 |
+
826,
|
| 156 |
+
813
|
| 157 |
+
],
|
| 158 |
+
"page_idx": 1
|
| 159 |
+
},
|
| 160 |
+
{
|
| 161 |
+
"type": "text",
|
| 162 |
+
"text": "",
|
| 163 |
+
"bbox": [
|
| 164 |
+
147,
|
| 165 |
+
828,
|
| 166 |
+
825,
|
| 167 |
+
911
|
| 168 |
+
],
|
| 169 |
+
"page_idx": 1
|
| 170 |
+
},
|
| 171 |
+
{
|
| 172 |
+
"type": "text",
|
| 173 |
+
"text": "",
|
| 174 |
+
"bbox": [
|
| 175 |
+
147,
|
| 176 |
+
90,
|
| 177 |
+
825,
|
| 178 |
+
147
|
| 179 |
+
],
|
| 180 |
+
"page_idx": 2
|
| 181 |
+
},
|
| 182 |
+
{
|
| 183 |
+
"type": "text",
|
| 184 |
+
"text": "93 3 Components of AutoMCL ",
|
| 185 |
+
"text_level": 1,
|
| 186 |
+
"bbox": [
|
| 187 |
+
155,
|
| 188 |
+
165,
|
| 189 |
+
421,
|
| 190 |
+
183
|
| 191 |
+
],
|
| 192 |
+
"page_idx": 2
|
| 193 |
+
},
|
| 194 |
+
{
|
| 195 |
+
"type": "text",
|
| 196 |
+
"text": "94 We design a few optimization passes and evaluate the effectiveness of each optimization strategy 95 individually and only append experimentally proven working optimizations to our framework. Fig. 1 provides an overview of the framework, named AutoMCL. ",
|
| 197 |
+
"bbox": [
|
| 198 |
+
147,
|
| 199 |
+
196,
|
| 200 |
+
825,
|
| 201 |
+
238
|
| 202 |
+
],
|
| 203 |
+
"page_idx": 2
|
| 204 |
+
},
|
| 205 |
+
{
|
| 206 |
+
"type": "image",
|
| 207 |
+
"img_path": "images/8c8e9d226059a7d9e5c5c99ae18f30948a4366d82185e13f14c4da5c69eeaded.jpg",
|
| 208 |
+
"image_caption": [
|
| 209 |
+
"Figure 1: Flow of AutoMCL with the new strategies introduced in this work highlighted. "
|
| 210 |
+
],
|
| 211 |
+
"image_footnote": [],
|
| 212 |
+
"bbox": [
|
| 213 |
+
276,
|
| 214 |
+
253,
|
| 215 |
+
722,
|
| 216 |
+
401
|
| 217 |
+
],
|
| 218 |
+
"page_idx": 2
|
| 219 |
+
},
|
| 220 |
+
{
|
| 221 |
+
"type": "text",
|
| 222 |
+
"text": "97 Enlarging the space of schedules. The DL compiler TVM provides two default computes for the \n98 matrix multiplication operator, namely DNMM and RPMM and one default compute CONV for gen \n99 eral 2D-convolution. We introduce another four alternative computes TMM, TTMM, DPMM, LPMM \n100 for matrix multiplication and two alternative computes Im2colDNMM332 and Im2colRPMMV for \n101 convolution by converting convolution to matrix multiplication in an im2col manner. Table 1 summa \n102 rizes the specification of each compute for matrix multiplication. The computes for convolution can \n103 be found in the supplemental material. We manually write schedule template for each new compute \n104 and improve the default schedule templates for DNMM, RPMM, CONV respectively as DNMM332 \n105 (single-level tiling to double-level tiling), RPMMV (adding missing vectorization for some loop) and \n106 CONVOpt (loop reordering according to the cache complexity analysis in Theorem 2 and its remark). \n107 We analyze the cache complexity with the ideal cache model for each schedule template, stated as \n108 Theorem 1 and Theorem 2, whose detailed proof can be found in the supplemental material. Note \n109 that all the nested loops will be tiled in the schedules. This would lead to a better cache complexity if \n110 the data required for computing a tile all fit in cache. This assumption depends both on the tile and \n111 cache size but should not depend on the input tensor size (with the kernel sizes as an exception since \n112 they are usually small). Table 2 and Table 3 summarize the assumptions. \n113 Let $V _ { \\ell }$ be the length of vectorization, $C _ { \\ell }$ be the cache line size, $Z$ be the cache size, and $D _ { \\ell }$ be the \n114 size of tensor data type in bytes. Let $V _ { w } : = V _ { \\ell } / D _ { \\ell } , C _ { w } : = C _ { \\ell } / D _ { \\ell } , Z _ { w } : = Z / D _ { \\ell }$ . ",
|
| 223 |
+
"bbox": [
|
| 224 |
+
142,
|
| 225 |
+
455,
|
| 226 |
+
826,
|
| 227 |
+
594
|
| 228 |
+
],
|
| 229 |
+
"page_idx": 2
|
| 230 |
+
},
|
| 231 |
+
{
|
| 232 |
+
"type": "table",
|
| 233 |
+
"img_path": "images/fc6292112f71b8d405555dea18ef5b69c243e767da8f84688fe069b9a10220c1.jpg",
|
| 234 |
+
"table_caption": [
|
| 235 |
+
"Table 1: Compute specification for matrix multiplication "
|
| 236 |
+
],
|
| 237 |
+
"table_footnote": [],
|
| 238 |
+
"table_body": "<table><tr><td>Name</td><td>Specification (Mt,Kt, Nt are parameters.)</td></tr><tr><td>TMM</td><td>Cy=∑-DuW</td></tr><tr><td>TTMM</td><td>Wk:=WCy=∑-1Dyk*W K-1</td></tr><tr><td>DNMM</td><td>CCy,x,ki :=∑K/K Kt-1 CCy,xki K/Kt-1 1 Dy,k*Kt+k *Wx*Kt+k; Cy,x :=∑ ∑ki=0</td></tr><tr><td>LPMM</td><td>K-1PDy PDyok,y :=Dy*Mt+y;Cyx=∑ Py/Mt,k,y mod Mt * Wx,k</td></tr><tr><td>RPMM</td><td>PWxok,xi :=Wxo*Nt+xi,k;Cy,x :=∑-1 K-1 Dy,k *PW x/Nt,k,x mod Nt</td></tr><tr><td>DPMM</td><td>PDyo,k,yi i= Dyo*Mt+yik; PWxok,xi := Wxo*Nt+xi,k Cy,x :=∑k=01</td></tr></table>",
|
| 239 |
+
"bbox": [
|
| 240 |
+
189,
|
| 241 |
+
630,
|
| 242 |
+
805,
|
| 243 |
+
781
|
| 244 |
+
],
|
| 245 |
+
"page_idx": 2
|
| 246 |
+
},
|
| 247 |
+
{
|
| 248 |
+
"type": "text",
|
| 249 |
+
"text": "",
|
| 250 |
+
"bbox": [
|
| 251 |
+
140,
|
| 252 |
+
792,
|
| 253 |
+
825,
|
| 254 |
+
877
|
| 255 |
+
],
|
| 256 |
+
"page_idx": 2
|
| 257 |
+
},
|
| 258 |
+
{
|
| 259 |
+
"type": "text",
|
| 260 |
+
"text": "",
|
| 261 |
+
"bbox": [
|
| 262 |
+
142,
|
| 263 |
+
882,
|
| 264 |
+
821,
|
| 265 |
+
912
|
| 266 |
+
],
|
| 267 |
+
"page_idx": 2
|
| 268 |
+
},
|
| 269 |
+
{
|
| 270 |
+
"type": "text",
|
| 271 |
+
"text": "Theorem 1. Assume that 115 $\\begin{array} { r } { T _ { m } ( M _ { t } , K _ { t } , N _ { t } ) < \\frac { Z _ { w } } { C _ { w } } } \\end{array}$ and $M _ { t } | M , K _ { t } | K , N _ { t } | N ,$ , the cache complexity 116 $C _ { m } ( M , K , N , M _ { t } , K _ { t } , N _ { t } )$ for each schedule is listed as below: ",
|
| 272 |
+
"bbox": [
|
| 273 |
+
142,
|
| 274 |
+
89,
|
| 275 |
+
823,
|
| 276 |
+
123
|
| 277 |
+
],
|
| 278 |
+
"page_idx": 3
|
| 279 |
+
},
|
| 280 |
+
{
|
| 281 |
+
"type": "equation",
|
| 282 |
+
"img_path": "images/4fd374084272f33a3af4dbe961348bb8f367fa6b13dbb6d7c8aedff172546bbc.jpg",
|
| 283 |
+
"text": "$$\n\\begin{array} { r l } { \\mathrm { T M M : } \\quad } & { \\frac { M } { M _ { k } } \\frac { N } { N _ { k } } \\left( M _ { k } \\left( \\left[ \\frac { K _ { k } } { C _ { w } } \\right] + 1 \\right) \\frac { K _ { k } } { K _ { k } } + N _ { k } \\left( \\left[ \\frac { K _ { k } } { C _ { w } } \\right] + 1 \\right) \\frac { K _ { k } } { K _ { k } } + M _ { t } \\left( \\left[ \\frac { N _ { k } } { C _ { w } } \\right] + 1 \\right) \\right) } \\\\ { \\mathrm { T M M : } \\quad } & { \\frac { K _ { k } } { K _ { k } } \\frac { N } { N _ { k } } \\left( K _ { t } \\left( \\left[ \\frac { K _ { k } } { C _ { w } } \\right] + 1 \\right) + N _ { t } \\left( \\left[ \\frac { K _ { k } } { C _ { w } } \\right] + 1 \\right) \\right) } \\\\ & { + \\frac { N _ { t } } { M _ { k } } \\frac { N _ { k } } { K _ { k } } \\left( M _ { k } \\left( \\left[ \\frac { K _ { k } } { C _ { w } } \\right] + 1 \\right) \\frac { K _ { k } } { K _ { k } } + K _ { t } \\left[ \\left( \\frac { K _ { k } } { C _ { w } } \\right] + 1 \\right) \\frac { K _ { k } } { K _ { k } } + M _ { t } \\left( \\left[ \\frac { N _ { k } } { C _ { w } } \\right] + 1 \\right) \\right) } \\\\ { \\mathrm { D M M : } \\quad } & { \\frac { M _ { k } } { M _ { k } } \\frac { N } { N _ { k } } \\left( \\left[ \\frac { K _ { k } } { K _ { k } } \\right] \\left( M _ { k } + N _ { k } \\right) \\left( \\left[ \\frac { K _ { k } } { K _ { k } } \\right] + 1 \\right) + M _ { k } \\left( \\left[ \\frac { K _ { k } K _ { k } } { K _ { k } } \\right] + 1 \\right) + M _ { t } \\left( \\left[ \\frac { K _ { k } } { C _ { w } } \\right] + 1 \\right) \\right) } \\\\ { \\mathrm { L P M M : } \\quad } & { \\frac { M _ { k } } { M _ { k } } \\left( \\left[ \\frac { K _ { k } } { C _ { w } } \\right] + 1 \\right) + M \\left( \\left[ \\frac { K _ { k } } { K _ { k } } \\right] + 1 \\right) + \\left[ \\frac { M _ { k } } { M _ { k } } \\right] } \\\\ & + \\frac { M _ { k } } { N _ { k } } \\frac N _ k \\end{array}\n$$",
|
| 284 |
+
"text_format": "latex",
|
| 285 |
+
"bbox": [
|
| 286 |
+
181,
|
| 287 |
+
130,
|
| 288 |
+
813,
|
| 289 |
+
351
|
| 290 |
+
],
|
| 291 |
+
"page_idx": 3
|
| 292 |
+
},
|
| 293 |
+
{
|
| 294 |
+
"type": "text",
|
| 295 |
+
"text": "Theorem 2. Assume that 117 $\\begin{array} { r } { T _ { c } ( M _ { t } , K _ { t } , N _ { t } ) < \\frac { Z _ { w } } { C _ { w } } } \\end{array}$ and $O W _ { t } | O W , I C _ { t } | I C , O C _ { t } | O C ,$ , the cache com118 plexity for CONVOpt is: ",
|
| 296 |
+
"bbox": [
|
| 297 |
+
137,
|
| 298 |
+
356,
|
| 299 |
+
823,
|
| 300 |
+
388
|
| 301 |
+
],
|
| 302 |
+
"page_idx": 3
|
| 303 |
+
},
|
| 304 |
+
{
|
| 305 |
+
"type": "equation",
|
| 306 |
+
"img_path": "images/e9c9f7bffe2e3f896a23653d785af39aef7c1a3c131ab0cad1f24f565ee559a6.jpg",
|
| 307 |
+
"text": "$$\n\\begin{array} { r l } & { \\quad [ \\frac { B * ( D H + 2 P H ) + I ( C * ( D W + 2 P W ) ) } { C _ { w } } ] + 1 + ( B + D H + I C * ( \\lceil \\frac { D W } { C _ { w } } \\rceil + 1 ) ) } \\\\ & { + \\ O C * ( \\lceil \\frac { \\mathbf { K C } } { C _ { w } } * ( \\lceil \\frac { \\mathbf { K H } + \\mathbf { K W } * \\mathbf { H C } _ { w } } { C _ { w } } \\rceil + 1 ) ) } \\\\ & { + I C * R H * K W * \\frac { O C } { C _ { w } } * ( \\lfloor \\frac { O C _ { w } } { C _ { w } } \\rceil + 1 ) + ( B * \\frac { O C } { O C _ { w } } * O H * \\frac { O W } { O W _ { 1 } } * ( \\lfloor \\frac { O W _ { 1 } * O C _ { u } } { C _ { w } } \\rceil + 1 ) ) } \\\\ & { + B * \\frac { O C } { O C _ { w } } * O H * \\frac { O W } { O W _ { * } } * I C * K R H * ( ( \\frac { O C } { C _ { w } } ) + 1 ) } \\\\ & { + B * \\frac { O C } { O C _ { w } } * I C * \\partial H * \\frac { O W } { O W _ { * } } * R H * ( ( \\frac { ( E _ { w } - 1 ) + ( E W - 1 ) + ( K W - 1 ) * d _ { 2 } + 1 ) } { C _ { w } } ) } \\\\ & { + B * \\frac { O C } { O C _ { w } } * I C * O H * \\frac { O W } { O W _ { * } } * R H * ( ( \\frac { ( E _ { w } + O ) } { ( \\sum _ { w } * O H * ( \\log C _ { w } ) } + ( \\frac { O C _ { w } } { C _ { w } } ) + 1 ) ) } \\\\ & { + B * \\frac { O C } { O C _ { w } } * O H * O W * ( \\lceil \\frac { O C _ { w } } { C _ { w } } \\rceil + 1 ) + ( B * O H * O W * \\frac { O C } { O C _ { w } } * ( \\lceil \\frac { O C _ { w } } { C _ { w } } \\rceil + 1 ) ) } \\\\ & { + B * O C * O H * \\frac { O W } { O W _ { w } } * ( [ \\frac { O M } { O W _ { w } } ] + 1 ) , } \\end{array}\n$$",
|
| 308 |
+
"text_format": "latex",
|
| 309 |
+
"bbox": [
|
| 310 |
+
197,
|
| 311 |
+
395,
|
| 312 |
+
799,
|
| 313 |
+
609
|
| 314 |
+
],
|
| 315 |
+
"page_idx": 3
|
| 316 |
+
},
|
| 317 |
+
{
|
| 318 |
+
"type": "text",
|
| 319 |
+
"text": "119 and the cache complexity of Im2col-CONV is: ",
|
| 320 |
+
"bbox": [
|
| 321 |
+
142,
|
| 322 |
+
613,
|
| 323 |
+
482,
|
| 324 |
+
627
|
| 325 |
+
],
|
| 326 |
+
"page_idx": 3
|
| 327 |
+
},
|
| 328 |
+
{
|
| 329 |
+
"type": "equation",
|
| 330 |
+
"img_path": "images/9624b6c692d1995026812789109dd6cbaedcc796f8b7ba7f056cc6330ac39ff2.jpg",
|
| 331 |
+
"text": "$$\n\\begin{array} { r l } & { \\quad \\lceil \\frac { B * I C * ( D H + 2 P H ) * ( D W + 2 P W ) } { C _ { w } } \\rceil + 1 + \\left( \\lceil \\frac { B * I C * D H * D W } { C _ { w } } \\rceil + 1 \\right) } \\\\ & { + \\frac { B * O H * O W * I C } { I C t } * ( \\lceil \\frac { I C _ { t } * K H * K W } { C _ { w } } \\rceil + 1 ) + \\left( 2 * O C * \\frac { I C } { T C _ { t } } * ( \\lceil \\frac { K H * K W * I C _ { t } } { C _ { w } } \\rceil + 1 ) \\right) } \\\\ & { + B * O H * O W * I C * K H * ( \\lceil \\frac { O ( W _ { t } - 1 ) * s _ { 2 } + ( K W - 1 ) * d _ { 2 } + 1 } { C _ { w } } \\rceil + 1 ) } \\\\ & { + C _ { m } ( B * O H * O W , I C * K H * K W , O C , O W _ { t } , I C _ { t } * K H * K W , O C _ { t } ) } \\\\ & { + B * O C * O H * \\lceil \\frac { O W } { O W _ { t } } \\rceil * ( \\lceil \\frac { O W _ { t } } { C _ { w } } \\rceil + 1 ) + \\left( B * O H * O W * \\lceil \\frac { O C } { O C _ { t } } \\rceil * ( \\lceil \\frac { O C _ { t } } { C _ { w } } \\rceil + 1 ) \\right) . } \\end{array}\n$$",
|
| 332 |
+
"text_format": "latex",
|
| 333 |
+
"bbox": [
|
| 334 |
+
179,
|
| 335 |
+
632,
|
| 336 |
+
815,
|
| 337 |
+
779
|
| 338 |
+
],
|
| 339 |
+
"page_idx": 3
|
| 340 |
+
},
|
| 341 |
+
{
|
| 342 |
+
"type": "text",
|
| 343 |
+
"text": "120 Remark 1. For the cache complexity of CONV in TVM, we only need to replace the bold part in \n121 Table $^ 3$ with $\\begin{array} { r } { O C _ { t } \\ast I C _ { t } \\ast \\big ( \\lceil \\frac { K W } { C _ { w } } \\rceil + \\dot { 1 } \\big ) ^ { \\ast } K W \\ast I C _ { t } \\ast \\big ( \\lceil O C _ { t } / \\dot { C } _ { w } \\rceil + 1 \\big ) } \\end{array}$ and $( l )$ in Theorem 2 by \n122 $\\begin{array} { r } { O C \\ast I C \\ast K H \\ast \\left( \\left\\lceil \\frac { K W } { C _ { w } } \\right\\rceil + 1 \\right) } \\end{array}$ . It is usually larger than that of CONVOpt for the same tiling size. \n123 Learning to choose schedules. We first evaluate the performance of each schedule on a dataset \n124 consisting of matrices with sizes ranging from small to large. The experiments, reported in Section 4, \n125 show that each one can be exclusively the best for certain types of sizes. We then choose the top \n126 four best performed schedules as candidates and train a boosted tree model by Xgboost [7], with the \n127 matrix size as input feature, to automatically select the best one for a particular size. ",
|
| 344 |
+
"bbox": [
|
| 345 |
+
140,
|
| 346 |
+
781,
|
| 347 |
+
825,
|
| 348 |
+
832
|
| 349 |
+
],
|
| 350 |
+
"page_idx": 3
|
| 351 |
+
},
|
| 352 |
+
{
|
| 353 |
+
"type": "text",
|
| 354 |
+
"text": "",
|
| 355 |
+
"bbox": [
|
| 356 |
+
140,
|
| 357 |
+
842,
|
| 358 |
+
825,
|
| 359 |
+
912
|
| 360 |
+
],
|
| 361 |
+
"page_idx": 3
|
| 362 |
+
},
|
| 363 |
+
{
|
| 364 |
+
"type": "table",
|
| 365 |
+
"img_path": "images/8a26518e1c55c8c41867abbae6f9dcdc0505482dca59e6c4cea973fb60f37c44.jpg",
|
| 366 |
+
"table_caption": [
|
| 367 |
+
"Table 2: Values of $T _ { m }$ for different schedules for matrix multiplication (from top to bottom: TMM, TTMM, DNMM, LPMM, RPMM, DPMM) "
|
| 368 |
+
],
|
| 369 |
+
"table_footnote": [],
|
| 370 |
+
"table_body": "<table><tr><td>Tm(Mt,Kt,Nt)</td></tr><tr><td>Mt([1+1) + Nt([1+1) + Mt(「1+1)</td></tr><tr><td>Kt([1+1)+ max (Nt([1+1),Mt(「1+1) +Mt([+1)</td></tr><tr><td></td></tr><tr><td>Mt(1+1)+max(Mt([1+1),(Mt +Nt)(1+1))</td></tr><tr><td>Cw</td></tr><tr><td>[1+N[1+mx(M(1+1),(1+1)+1+1)) 1+max</td></tr><tr><td>(11+Mt,[1+t,[1+mx(M(1+1),[1++2)) 1 +max</td></tr></table>",
|
| 371 |
+
"bbox": [
|
| 372 |
+
176,
|
| 373 |
+
127,
|
| 374 |
+
833,
|
| 375 |
+
284
|
| 376 |
+
],
|
| 377 |
+
"page_idx": 4
|
| 378 |
+
},
|
| 379 |
+
{
|
| 380 |
+
"type": "table",
|
| 381 |
+
"img_path": "images/ff30b30ccd64513469d9f76b72fe10e4c63134e17ef69ca33ac45b085e951299.jpg",
|
| 382 |
+
"table_caption": [
|
| 383 |
+
"Table 3: Values of $T _ { c }$ for convolution schedules (top: CONVOpt, bottom: Im2col-CONV) "
|
| 384 |
+
],
|
| 385 |
+
"table_footnote": [],
|
| 386 |
+
"table_body": "<table><tr><td colspan=\"2\">Tc(OWt,ICt,OCt)</td></tr><tr><td>max</td><td>OCt *([KH*KW*ICt1+1) +KH* KW *ICt *(fg +1+1), Cw Cw 1+1),([0Wx0Ct]+1)+0Wt * ([ Cw +KH* KW*ICt*([C] 0Ct] 1+1), C Cw C Ct1+1)+0Ct*( OWt*(「9 0Wt1 1+1) C C</td></tr><tr><td>max</td><td>(OWt-1)*s2+(KW-1)*d2+1 +1), OWt *([KH*KW*ICt]+1)+ICt *([ 2*OCt*([KH*KW*ICt]+1),OCt *( C OWt 1+1)+OWt*([ C+1+1), C Cw Tm(OWt,ICt * KH * KW,OCt)</td></tr></table>",
|
| 387 |
+
"bbox": [
|
| 388 |
+
191,
|
| 389 |
+
325,
|
| 390 |
+
823,
|
| 391 |
+
477
|
| 392 |
+
],
|
| 393 |
+
"page_idx": 4
|
| 394 |
+
},
|
| 395 |
+
{
|
| 396 |
+
"type": "text",
|
| 397 |
+
"text": "128 Initializing the tiling size space. Suppose that there are $m$ dimensions to be tiled and the size of \n129 each dimension is $X _ { i }$ , $i = 1 , \\ldots , m$ . Then the number of valid one-level tilings is $\\Pi _ { i = 1 } ^ { m } X _ { i }$ , which \n130 is one billion for $X _ { i } ~ = ~ 1 0 0 0$ . Thus one has to set up a reasonable initial tiling size space. For \n131 instance, in TVM, there are two basic strategies depending on the tiling size being a factor of $X _ { i }$ or a \n132 power of 2. Suppose that there are $m$ dimensions $X _ { 1 } , \\ldots , X _ { m }$ to be tiled, and each dimension has a \nnested tiling of levels 133 direct product of the 134 $d _ { i }$ , s $i = 1 , \\ldots , m$ f, trategy is a. We adopt $\\begin{array} { r } { G _ { i } : = \\{ ( X _ { i } ^ { ( 0 ) } , \\dots , X _ { i } ^ { ( d _ { i } ) } ) \\ | \\ \\prod _ { j = 0 } ^ { d _ { i } } \\bar { X } _ { i } ^ { ( j ) } = X _ { i } \\} } \\end{array}$ $i = 1 , \\ldots , m$ this factor strategy for 2D-convolution. For matrix multiplication, we propose a more sophisticated \n136 strategy, motivated by both the factor strategy of TVM and the analytic model of [21] to balance \n137 cache locality and load balancing among parallel threads. This strategy is described by Algorithm 1. ",
|
| 398 |
+
"bbox": [
|
| 399 |
+
140,
|
| 400 |
+
505,
|
| 401 |
+
826,
|
| 402 |
+
650
|
| 403 |
+
],
|
| 404 |
+
"page_idx": 4
|
| 405 |
+
},
|
| 406 |
+
{
|
| 407 |
+
"type": "text",
|
| 408 |
+
"text": "138 Filtering the tiling size space. Let $G ( Z _ { t } , Y _ { t } , X _ { t } )$ be the initial tiling size space for the com \n139 pute/schedule pair $( O , S )$ , where $Z _ { t } , Y _ { t } , X _ { t }$ denote the innermost tiling sizes for the tiled dimensions \n140 $Z , Y , X$ . Let $T ( X _ { t } , Y _ { t } , X _ { t } )$ be the cache fit formula $T _ { c }$ or $T _ { m }$ . Let $X$ be the dimension for vectoriza \n141 tion and $X _ { t }$ be the tiling size for this dimension. We would only consider the tiling size satisfying \n142 both $X \\geq \\operatorname* { m i n } ( X _ { t } , V _ { w } )$ and $T < Z _ { w } / C _ { w }$ and filter out the rest ones from $G$ . \n143 Learning to choose optimal configurations. Except for the default schedule CONV of TVM, the \n144 configuration space for all the schedules considered in this work is solely formed by different tiling \n145 sizes. The schedule CONV has another knob unroll_kw to decide whether to unroll the for loop \n146 involving the kernel dimension $K W$ . The size of the configuration space in our experiments is \n147 usually less than 10, 000 thanks to the initialization and filter strategies. For this moderate size, we \n148 find that the rather direct tuning strategy described by Algorithm 2 works quite well in practice. ",
|
| 409 |
+
"bbox": [
|
| 410 |
+
142,
|
| 411 |
+
654,
|
| 412 |
+
825,
|
| 413 |
+
726
|
| 414 |
+
],
|
| 415 |
+
"page_idx": 4
|
| 416 |
+
},
|
| 417 |
+
{
|
| 418 |
+
"type": "text",
|
| 419 |
+
"text": "",
|
| 420 |
+
"bbox": [
|
| 421 |
+
140,
|
| 422 |
+
731,
|
| 423 |
+
825,
|
| 424 |
+
815
|
| 425 |
+
],
|
| 426 |
+
"page_idx": 4
|
| 427 |
+
},
|
| 428 |
+
{
|
| 429 |
+
"type": "text",
|
| 430 |
+
"text": "149 4 Evaluation ",
|
| 431 |
+
"text_level": 1,
|
| 432 |
+
"bbox": [
|
| 433 |
+
143,
|
| 434 |
+
835,
|
| 435 |
+
295,
|
| 436 |
+
853
|
| 437 |
+
],
|
| 438 |
+
"page_idx": 4
|
| 439 |
+
},
|
| 440 |
+
{
|
| 441 |
+
"type": "text",
|
| 442 |
+
"text": "150 We developed AutoMCL on top of TVM (0.6.0) and it will be released in open source. Three Intel \n151 CPUs (Intel i7-G9700F, Intel i7-9750H, Intel i9-9900) and one AMD CPU (AMD-Ryzen9-3900X) are \n152 used for evaluation. More detailed hardware information can be found in the supplemental material. \n153 We first evaluate each optimization strategy individually based on TVM on randomly generated \n154 datasets consisting of tensors of various sizes, in order to see if a particular optimization can speed up \n155 either optimization time or inference time. Then we evaluate the whole integrated framework on both \n156 the operation and the end-to-end level for typical fully connected and convolutional neural networks. \n157 The maximum number of trials for the whole tuning and the early stopping are set respectively as \n158 10, 000 and 400 for most of the experiments. The only exception is the end-to-end evaluation of \n159 CNNs, where we set the two numbers respectively as 500 and 300. ",
|
| 443 |
+
"bbox": [
|
| 444 |
+
142,
|
| 445 |
+
868,
|
| 446 |
+
825,
|
| 447 |
+
911
|
| 448 |
+
],
|
| 449 |
+
"page_idx": 4
|
| 450 |
+
},
|
| 451 |
+
{
|
| 452 |
+
"type": "text",
|
| 453 |
+
"text": "",
|
| 454 |
+
"bbox": [
|
| 455 |
+
140,
|
| 456 |
+
92,
|
| 457 |
+
825,
|
| 458 |
+
189
|
| 459 |
+
],
|
| 460 |
+
"page_idx": 5
|
| 461 |
+
},
|
| 462 |
+
{
|
| 463 |
+
"type": "text",
|
| 464 |
+
"text": "Algorithm 1: InitConfigSpace(O, S) ",
|
| 465 |
+
"text_level": 1,
|
| 466 |
+
"bbox": [
|
| 467 |
+
174,
|
| 468 |
+
207,
|
| 469 |
+
428,
|
| 470 |
+
223
|
| 471 |
+
],
|
| 472 |
+
"page_idx": 5
|
| 473 |
+
},
|
| 474 |
+
{
|
| 475 |
+
"type": "text",
|
| 476 |
+
"text": "Input: A compute/schedule pair $( O , S )$ for matmul, the number of parallel threads $p$ . \nOutput: The initial configure space $G$ for tiling. \n1 begin \n2 if $S$ has 1-level tiling then \n3 initialize $G ^ { \\prime } , G _ { x } , G _ { y } , G _ { k } , G _ { y x }$ respectively as $\\varnothing$ ; \n4 for all factors $p _ { y }$ of $p$ do \n5 $p _ { x } : = p / p _ { y }$ ; let $G _ { y }$ and $G _ { x }$ be respectively all the factors of $\\lceil M / p _ { y } \\rceil$ and $\\lceil N / p _ { x } \\rceil$ ; \n6 $G _ { y x } : = \\{ ( M _ { t } , N _ { t } ) \\mid M _ { t } \\in G _ { y } , N _ { t } \\in G _ { x } \\}$ \n7 let $G _ { k }$ be all the factors of $K \\colon G : = \\{ ( 1 , M _ { t } , 1 , N _ { t } , K _ { t } ) \\mid ( M _ { t } , N _ { t } ) \\in G _ { y x } , K _ { t } \\in G _ { k } \\} ;$ \n8 else if $S$ has 2-level tiling then \n9 initialize $G ^ { \\prime } , G _ { x } , G _ { y } , G _ { k } , G _ { y x }$ respectively as $\\varnothing$ ; \n10 for all factors $p _ { y }$ of $p$ do \n11 $p _ { x } : = p / p _ { y }$ ; \n12 $\\begin{array} { r l } & { \\mathrm { l e t } G _ { y } : = \\big \\{ ( M _ { o } , M _ { t } ) : M _ { o } M _ { t } | [ M / p _ { y } ] \\big \\} ; G _ { x } : = \\big \\{ ( N _ { o } , N _ { t } ) : N _ { o } N _ { t } | [ N / p _ { x } ] ; } \\\\ & { G _ { y x } : = \\big \\{ ( M _ { o } , M _ { t } , N _ { o } , N _ { t } ) \\big | \\big ( M _ { o } , M _ { t } \\big ) \\in G _ { y } , \\big ( N _ { o } , N _ { t } \\big ) \\in G _ { x } \\big \\} } \\end{array}$ \n13 \n14 let $G _ { k }$ be all the factors of $K$ ; \n15 $G : = \\{ ( M _ { o } , M _ { t } , N _ { o } , N _ { t } , K _ { t } ) \\mid ( M _ { o } , M _ { t } , N _ { o } , N _ { t } ) \\in G _ { y x } , K _ { t } \\in G _ { k } \\} ;$ \n$^ { \\prime * }$ Due to limitation of TVM, it is additionally rquired that $M _ { t } | M$ for \nLPMM, $N _ { t } | N$ for RPMM and $M _ { t } | M , N _ { t } | N$ for DPMM. \\* \n16 return G ",
|
| 477 |
+
"bbox": [
|
| 478 |
+
155,
|
| 479 |
+
226,
|
| 480 |
+
815,
|
| 481 |
+
516
|
| 482 |
+
],
|
| 483 |
+
"page_idx": 5
|
| 484 |
+
},
|
| 485 |
+
{
|
| 486 |
+
"type": "text",
|
| 487 |
+
"text": "",
|
| 488 |
+
"bbox": [
|
| 489 |
+
199,
|
| 490 |
+
506,
|
| 491 |
+
256,
|
| 492 |
+
520
|
| 493 |
+
],
|
| 494 |
+
"page_idx": 5
|
| 495 |
+
},
|
| 496 |
+
{
|
| 497 |
+
"type": "text",
|
| 498 |
+
"text": "$\\overline { { \\mathrm { A l g o r i t h m ~ } 2 } } \\colon \\mathsf { A u t o C o n f i g } ( O , S , G , m , n , b )$ ",
|
| 499 |
+
"text_level": 1,
|
| 500 |
+
"bbox": [
|
| 501 |
+
178,
|
| 502 |
+
559,
|
| 503 |
+
465,
|
| 504 |
+
574
|
| 505 |
+
],
|
| 506 |
+
"page_idx": 5
|
| 507 |
+
},
|
| 508 |
+
{
|
| 509 |
+
"type": "text",
|
| 510 |
+
"text": "Input: The compute/schedule pair $( O , S )$ , the configuration space $G$ for $( O , S )$ , the maximum \nnumber of trials $m$ , the batch size $n$ for restarting training, the batch size $b$ for a parallel run. \nOutput: The optimal configuration. \n1 begin \n2 $D : = \\varnothing ; t : = 0$ ; randomly pop $n$ configurations from $G$ and put in $N$ ; \n3 while true do \n4 while $N \\neq \\emptyset$ do \n5 choose $b$ configurations $B$ from $N ; N : = N \\setminus B$ ; \n6 in parallel, run the code compiled from the tuple $( O , S , c )$ , $c \\in B$ , on hardware; \n7 add $B$ examples labelled with (averaged) running timings to $D ; t : = t + | N |$ ; \n8 if $G \\neq \\emptyset$ and $t < m$ then \n9 train a ML model with $D$ and predict the running timings of $( O , S , c )$ , $c \\in G$ ; \n10 pop the best (shortest predicted timing) $n$ configurations $N$ from $G$ ; \n11 else \n12 break; \n13 return the configurations in $D$ with the shortest running time \n160 Comparison of different schedules. To make a fair comparison, we create two testing datasets \n161 consisting of examples of various dimension sizes for matrix multiplication and convolution. For \n162 matrix multiplication, a dimension size is chosen in three different scales, with small size in $\\{ 1 , 8 , 1 6 \\}$ , \n163 medium size in $\\{ 6 4 , 2 5 6 \\}$ and large size in $\\{ 1 0 2 4 , 4 0 9 6 \\}$ , which creates $7 ^ { 3 }$ different combinations. \n164 We remove 5 extreme size cases and add additional 120 examples with each dimension randomly \n165 taking values in 1..4096. For convolution, we create a dataset of the same size (458) as matrix mul \n166 tiplication. The dimensions of each convolution example $\\left( D _ { B \\times I C \\times D H \\times D W } \\right.$ , $W _ { O C \\times I C \\times K H \\times K W } )$ \n167 with stride $s$ and padding size $p$ randomly take values by the following rule: $B \\in \\{ 1 , 3 2 , 1 2 8 \\}$ , \n168 $I C \\in \\{ 2 ^ { 0 } \\cdot \\cdot \\cdot 2 ^ { 1 4 } \\bar \\}$ , $O C ^ { - } \\in \\{ 2 ^ { 0 } . . 2 ^ { 1 4 } \\}$ , $D H = D W \\in \\{ 1 \\cdot \\cdot \\cdot 2 5 6 \\}$ , $K H = K W \\in \\{ 1 , 3 , 5 , 7 \\}$ , \n169 $s \\in \\{ 1 , 2 \\}$ , $p = \\lfloor ( K H - 1 ) / 2 \\rfloor$ . In addition, we only keep examples with each dimension size less \n170 than 4096 in their im2col representations. \n171 Fig. 2 reports the proportions of examples with the shortest running time or the lowest cache misses \n172 (measured by the ideal cache model) for different schedules implementing matrix multiplication or \n173 convolution. The experiments show that each schedule can be exclusively the best for certain types of \n174 tensor sizes. Here we allow a 0.02 tolerance for being the best. Our manually improved schedule \n175 DNMM332, RPMMV and CONVOpt indeed work better than their counterparts. Moreover, the real \n176 and the theoretical measure correlate quite well for the “top performed” schedules, except for the two \nbased on DNMM, which however have a different vectorization dimension from the others. \n178 Evaluation of automatic schedule chosen. With performing exclusively the best on at least $5 \\%$ of \n179 the dataset as a criterion, four “top performed” schedules DNMM332, RPMMV, LPMM, TMM are \n180 selected for matmul and three are selected for conv2d. For matmul, we adopt Xgboost to automatically \n181 choose the best schedule among the four for a given problem size. The dataset is the same as the \n182 one in last subsection, from which 40 randomly chosen examples are reserved for the testing dataset \n183 and the rest for the training dataset. Fig. 3 reports the performance on the testing dataset, where \n184 AutoSchedule denotes the learned schedule and OptSchedule stands for choosing schedules in a static \n185 manner as TVM but with DNMM and RPMM replaced respectively by DNMM332 and RPMMV. \nFor conv2d, the learning approach does not work quite well and we instead use CONVOpt as the \n187 default implementation since it performs better than CONV while having the same advantage as \n188 CONV on leveraging NCHWc layout optimization [18] in the end-to-end inference. \n189 Evaluation of tiling size space initialization and filter. Fig. 4 illustrates how the two default \n190 schedules for matmul (DNMM when $M \\leq 1 6$ and RPMM when $M > 1 6$ ) perform when being \n191 combined with different strategies for initializing the tiling size space. The left image shows the \n192 speedup over the base (factor). The middle and right images show the space swell ratio over the \n193 base (factor). Our strategy pfactor shrinks the tiling size space more than $4 0 \\%$ for matrices with \n194 powers of 2 sizes without an obvious performance loss. For the dataset consisting of matrices of \n195 prime number sizes, pfactor brings 1.2 speedup on average. ",
|
| 511 |
+
"bbox": [
|
| 512 |
+
158,
|
| 513 |
+
578,
|
| 514 |
+
826,
|
| 515 |
+
816
|
| 516 |
+
],
|
| 517 |
+
"page_idx": 5
|
| 518 |
+
},
|
| 519 |
+
{
|
| 520 |
+
"type": "text",
|
| 521 |
+
"text": "",
|
| 522 |
+
"bbox": [
|
| 523 |
+
140,
|
| 524 |
+
842,
|
| 525 |
+
826,
|
| 526 |
+
911
|
| 527 |
+
],
|
| 528 |
+
"page_idx": 5
|
| 529 |
+
},
|
| 530 |
+
{
|
| 531 |
+
"type": "text",
|
| 532 |
+
"text": "",
|
| 533 |
+
"bbox": [
|
| 534 |
+
140,
|
| 535 |
+
92,
|
| 536 |
+
826,
|
| 537 |
+
174
|
| 538 |
+
],
|
| 539 |
+
"page_idx": 6
|
| 540 |
+
},
|
| 541 |
+
{
|
| 542 |
+
"type": "text",
|
| 543 |
+
"text": "",
|
| 544 |
+
"bbox": [
|
| 545 |
+
140,
|
| 546 |
+
181,
|
| 547 |
+
825,
|
| 548 |
+
279
|
| 549 |
+
],
|
| 550 |
+
"page_idx": 6
|
| 551 |
+
},
|
| 552 |
+
{
|
| 553 |
+
"type": "image",
|
| 554 |
+
"img_path": "images/ef46923e27feb47700aba70a6229a718f1a38a7e394c97512ee503196b70b60b.jpg",
|
| 555 |
+
"image_caption": [
|
| 556 |
+
"Figure 2: Performance of different candidate schedules for matmul and conv2d. "
|
| 557 |
+
],
|
| 558 |
+
"image_footnote": [],
|
| 559 |
+
"bbox": [
|
| 560 |
+
191,
|
| 561 |
+
299,
|
| 562 |
+
792,
|
| 563 |
+
390
|
| 564 |
+
],
|
| 565 |
+
"page_idx": 6
|
| 566 |
+
},
|
| 567 |
+
{
|
| 568 |
+
"type": "text",
|
| 569 |
+
"text": "",
|
| 570 |
+
"bbox": [
|
| 571 |
+
140,
|
| 572 |
+
436,
|
| 573 |
+
825,
|
| 574 |
+
563
|
| 575 |
+
],
|
| 576 |
+
"page_idx": 6
|
| 577 |
+
},
|
| 578 |
+
{
|
| 579 |
+
"type": "image",
|
| 580 |
+
"img_path": "images/3509de60c202a8dcd360e84b92e3a4073e0b8b1d5e35bc53ea3d46c86b0fab53.jpg",
|
| 581 |
+
"image_caption": [
|
| 582 |
+
"Figure 3: Performance of OptSchedule and AutoSchedule for matmul. "
|
| 583 |
+
],
|
| 584 |
+
"image_footnote": [],
|
| 585 |
+
"bbox": [
|
| 586 |
+
225,
|
| 587 |
+
582,
|
| 588 |
+
761,
|
| 589 |
+
712
|
| 590 |
+
],
|
| 591 |
+
"page_idx": 6
|
| 592 |
+
},
|
| 593 |
+
{
|
| 594 |
+
"type": "text",
|
| 595 |
+
"text": "",
|
| 596 |
+
"bbox": [
|
| 597 |
+
143,
|
| 598 |
+
758,
|
| 599 |
+
826,
|
| 600 |
+
787
|
| 601 |
+
],
|
| 602 |
+
"page_idx": 6
|
| 603 |
+
},
|
| 604 |
+
{
|
| 605 |
+
"type": "text",
|
| 606 |
+
"text": "",
|
| 607 |
+
"bbox": [
|
| 608 |
+
140,
|
| 609 |
+
794,
|
| 610 |
+
825,
|
| 611 |
+
891
|
| 612 |
+
],
|
| 613 |
+
"page_idx": 6
|
| 614 |
+
},
|
| 615 |
+
{
|
| 616 |
+
"type": "text",
|
| 617 |
+
"text": "196 Fig. 5 show that the filter strategy further reduces tiling space size while not loosing performance. ",
|
| 618 |
+
"bbox": [
|
| 619 |
+
143,
|
| 620 |
+
897,
|
| 621 |
+
812,
|
| 622 |
+
911
|
| 623 |
+
],
|
| 624 |
+
"page_idx": 6
|
| 625 |
+
},
|
| 626 |
+
{
|
| 627 |
+
"type": "image",
|
| 628 |
+
"img_path": "images/d655b08c1bac41404ad140ae73a178f00f98ec22573eb497408fc34f8e114452.jpg",
|
| 629 |
+
"image_caption": [
|
| 630 |
+
"Figure 4: Performance of different initialization strategy for matmul. "
|
| 631 |
+
],
|
| 632 |
+
"image_footnote": [],
|
| 633 |
+
"bbox": [
|
| 634 |
+
187,
|
| 635 |
+
98,
|
| 636 |
+
803,
|
| 637 |
+
194
|
| 638 |
+
],
|
| 639 |
+
"page_idx": 7
|
| 640 |
+
},
|
| 641 |
+
{
|
| 642 |
+
"type": "image",
|
| 643 |
+
"img_path": "images/531607c632b344d88799d1faa5158db4293cc24281863f21e0cb59b6f8afc491.jpg",
|
| 644 |
+
"image_caption": [
|
| 645 |
+
"Figure 5: Performance of the proposed filter strategy for pruning the tiling size space. "
|
| 646 |
+
],
|
| 647 |
+
"image_footnote": [],
|
| 648 |
+
"bbox": [
|
| 649 |
+
240,
|
| 650 |
+
238,
|
| 651 |
+
736,
|
| 652 |
+
330
|
| 653 |
+
],
|
| 654 |
+
"page_idx": 7
|
| 655 |
+
},
|
| 656 |
+
{
|
| 657 |
+
"type": "text",
|
| 658 |
+
"text": "197 Comparison of different configuration space exploiting strategies. Fig. 6 compares AutoTVM’s 198 exploration module $\\mathbf { \\Delta S A { + R A N K } } )$ ) and AutoMCL’s performance model (REG) on tuning GEMMs of 199 different sizes. The left and right image show the average performance of tuned matrix multiplications and the average tuning time. ",
|
| 659 |
+
"bbox": [
|
| 660 |
+
140,
|
| 661 |
+
380,
|
| 662 |
+
826,
|
| 663 |
+
436
|
| 664 |
+
],
|
| 665 |
+
"page_idx": 7
|
| 666 |
+
},
|
| 667 |
+
{
|
| 668 |
+
"type": "image",
|
| 669 |
+
"img_path": "images/eb25960695b6e5c537a2efc02711412619232eb02605a8fe66bbc9ed68e57967.jpg",
|
| 670 |
+
"image_caption": [
|
| 671 |
+
"Figure 6: Comparison between AutoTVM and AutoMCL on exploring the configuration space. "
|
| 672 |
+
],
|
| 673 |
+
"image_footnote": [],
|
| 674 |
+
"bbox": [
|
| 675 |
+
241,
|
| 676 |
+
462,
|
| 677 |
+
736,
|
| 678 |
+
568
|
| 679 |
+
],
|
| 680 |
+
"page_idx": 7
|
| 681 |
+
},
|
| 682 |
+
{
|
| 683 |
+
"type": "text",
|
| 684 |
+
"text": "201 Evaluation of AutoMCL on the operation and the end-to-end level. Now we evaluate the per \n202 formance of AutoMCL, which integrates all the optimization strategies introduced in Section 3, on \n203 optimizing matmul and conv2d for both fully connected neural networks (FCNNs) [26] and typical \n204 convolutional neural networks (CNNs) ResNet-50 [14], Inception-v3[24], and VGG16 [22]. \n205 Ablation analysis. We analyze the effects of adding different optimizations on the performance, \n206 where $O S$ and $A S$ stand for using respectively the optimized and the automatically chosen schedules. ",
|
| 685 |
+
"bbox": [
|
| 686 |
+
140,
|
| 687 |
+
616,
|
| 688 |
+
825,
|
| 689 |
+
672
|
| 690 |
+
],
|
| 691 |
+
"page_idx": 7
|
| 692 |
+
},
|
| 693 |
+
{
|
| 694 |
+
"type": "image",
|
| 695 |
+
"img_path": "images/7cf29364f6f25a2a9f02107bb23519926b9f0fc917ce9ffc62cdebd39490d789.jpg",
|
| 696 |
+
"image_caption": [
|
| 697 |
+
"Figure 7: Evaluating the operations matmul and conv2d for FCNNs and CNNs. "
|
| 698 |
+
],
|
| 699 |
+
"image_footnote": [],
|
| 700 |
+
"bbox": [
|
| 701 |
+
194,
|
| 702 |
+
689,
|
| 703 |
+
785,
|
| 704 |
+
886
|
| 705 |
+
],
|
| 706 |
+
"page_idx": 7
|
| 707 |
+
},
|
| 708 |
+
{
|
| 709 |
+
"type": "image",
|
| 710 |
+
"img_path": "images/c87ec4c59d989cf61e812f3f357249e3d6cd6f8d120e1279240d29e7433fcec2.jpg",
|
| 711 |
+
"image_caption": [
|
| 712 |
+
"Figure 8: End-to-end evaluation on FCNNs with batch size ${ \\mathrm { : = } } 2 ^ { i }$ $\\Sigma ^ { i } , i = 0 , \\dots , 9$ on an Intel CPU. "
|
| 713 |
+
],
|
| 714 |
+
"image_footnote": [],
|
| 715 |
+
"bbox": [
|
| 716 |
+
186,
|
| 717 |
+
88,
|
| 718 |
+
776,
|
| 719 |
+
253
|
| 720 |
+
],
|
| 721 |
+
"page_idx": 8
|
| 722 |
+
},
|
| 723 |
+
{
|
| 724 |
+
"type": "image",
|
| 725 |
+
"img_path": "images/1d5b5476ffdb5fc5dd333ceacfc9c0dd81b02828ebac456256445f1162f901f0.jpg",
|
| 726 |
+
"image_caption": [
|
| 727 |
+
"Figure 9: End-to-end evaluation on CNNs. "
|
| 728 |
+
],
|
| 729 |
+
"image_footnote": [],
|
| 730 |
+
"bbox": [
|
| 731 |
+
191,
|
| 732 |
+
313,
|
| 733 |
+
785,
|
| 734 |
+
436
|
| 735 |
+
],
|
| 736 |
+
"page_idx": 8
|
| 737 |
+
},
|
| 738 |
+
{
|
| 739 |
+
"type": "text",
|
| 740 |
+
"text": "",
|
| 741 |
+
"bbox": [
|
| 742 |
+
140,
|
| 743 |
+
494,
|
| 744 |
+
830,
|
| 745 |
+
523
|
| 746 |
+
],
|
| 747 |
+
"page_idx": 8
|
| 748 |
+
},
|
| 749 |
+
{
|
| 750 |
+
"type": "image",
|
| 751 |
+
"img_path": "images/2285c798e0e163709eee386c79d258d38b9929be6ed3d97255a0ec9ffe4217fa.jpg",
|
| 752 |
+
"image_caption": [
|
| 753 |
+
"Figure 10: Ablation analysis on a dense layer and a convolution layer from CNNs. "
|
| 754 |
+
],
|
| 755 |
+
"image_footnote": [],
|
| 756 |
+
"bbox": [
|
| 757 |
+
186,
|
| 758 |
+
559,
|
| 759 |
+
785,
|
| 760 |
+
724
|
| 761 |
+
],
|
| 762 |
+
"page_idx": 8
|
| 763 |
+
},
|
| 764 |
+
{
|
| 765 |
+
"type": "text",
|
| 766 |
+
"text": "207 5 Conclusion ",
|
| 767 |
+
"text_level": 1,
|
| 768 |
+
"bbox": [
|
| 769 |
+
142,
|
| 770 |
+
790,
|
| 771 |
+
299,
|
| 772 |
+
808
|
| 773 |
+
],
|
| 774 |
+
"page_idx": 8
|
| 775 |
+
},
|
| 776 |
+
{
|
| 777 |
+
"type": "text",
|
| 778 |
+
"text": "208 In this paper, we have introduced a framework AutoMCL to auto-tune the matrix multiplication and \n209 the 2D-convolution operations in fully connected and convolutional neural networks by leveraging \n210 both analytic and machine learning models. Experiments show that it outperforms AutoTVM on both \n211 inference speed and optimization cost for FCNNs and is competitive to AutoTVM for CNNs. In the \n212 future, we plan to further improve its performance by designing better strategies on automatically \n213 choosing the optimal schedule. ",
|
| 779 |
+
"bbox": [
|
| 780 |
+
140,
|
| 781 |
+
827,
|
| 782 |
+
825,
|
| 783 |
+
911
|
| 784 |
+
],
|
| 785 |
+
"page_idx": 8
|
| 786 |
+
},
|
| 787 |
+
{
|
| 788 |
+
"type": "text",
|
| 789 |
+
"text": "References ",
|
| 790 |
+
"text_level": 1,
|
| 791 |
+
"bbox": [
|
| 792 |
+
171,
|
| 793 |
+
90,
|
| 794 |
+
267,
|
| 795 |
+
106
|
| 796 |
+
],
|
| 797 |
+
"page_idx": 9
|
| 798 |
+
},
|
| 799 |
+
{
|
| 800 |
+
"type": "text",
|
| 801 |
+
"text": "[1] Intel oneDNN. https://01.org/oneDNN. ",
|
| 802 |
+
"bbox": [
|
| 803 |
+
179,
|
| 804 |
+
113,
|
| 805 |
+
498,
|
| 806 |
+
128
|
| 807 |
+
],
|
| 808 |
+
"page_idx": 9
|
| 809 |
+
},
|
| 810 |
+
{
|
| 811 |
+
"type": "text",
|
| 812 |
+
"text": "[2] Intel oneMKL. https://software.intel.com/content/www/us/en/develop/tools/ oneapi/components/onemkl.html. ",
|
| 813 |
+
"bbox": [
|
| 814 |
+
179,
|
| 815 |
+
137,
|
| 816 |
+
821,
|
| 817 |
+
166
|
| 818 |
+
],
|
| 819 |
+
"page_idx": 9
|
| 820 |
+
},
|
| 821 |
+
{
|
| 822 |
+
"type": "text",
|
| 823 |
+
"text": "[3] NVIDIA cuDNN. https://developer.nvidia.com/cudnn. ",
|
| 824 |
+
"bbox": [
|
| 825 |
+
183,
|
| 826 |
+
175,
|
| 827 |
+
629,
|
| 828 |
+
190
|
| 829 |
+
],
|
| 830 |
+
"page_idx": 9
|
| 831 |
+
},
|
| 832 |
+
{
|
| 833 |
+
"type": "text",
|
| 834 |
+
"text": "[4] Martín Abadi, Paul Barham, Jianmin Chen, Zhifeng Chen, Andy Davis, Jeffrey Dean, Matthieu Devin, Sanjay Ghemawat, Geoffrey Irving, Michael Isard, et al. Tensorflow: A system for large-scale machine learning. In 12th {USENIX} symposium on operating systems design and implementation $\\left\\{ O S D I \\right\\} 1 { \\bar { 6 } } )$ , pages 265–283, 2016. ",
|
| 835 |
+
"bbox": [
|
| 836 |
+
184,
|
| 837 |
+
199,
|
| 838 |
+
823,
|
| 839 |
+
256
|
| 840 |
+
],
|
| 841 |
+
"page_idx": 9
|
| 842 |
+
},
|
| 843 |
+
{
|
| 844 |
+
"type": "text",
|
| 845 |
+
"text": "[5] Byung Hoon Ahn, Prannoy Pilligundla, Amir Yazdanbakhsh, and Hadi Esmaeilzadeh. Chameleon: Adaptive code optimization for expedited deep neural network compilation. arXiv preprint arXiv:2001.08743, 2020. ",
|
| 846 |
+
"bbox": [
|
| 847 |
+
179,
|
| 848 |
+
263,
|
| 849 |
+
825,
|
| 850 |
+
306
|
| 851 |
+
],
|
| 852 |
+
"page_idx": 9
|
| 853 |
+
},
|
| 854 |
+
{
|
| 855 |
+
"type": "text",
|
| 856 |
+
"text": "[6] Riyadh Baghdadi, Abdelkader Nadir Debbagh, Kamel Abdous, Fatima Zohra Benhamida, Alex Renda, Jonathan Elliott Frankle, Michael Carbin, and Saman Amarasinghe. Tiramisu: A polyhedral compiler for dense and sparse deep learning, 2020. ",
|
| 857 |
+
"bbox": [
|
| 858 |
+
179,
|
| 859 |
+
315,
|
| 860 |
+
825,
|
| 861 |
+
359
|
| 862 |
+
],
|
| 863 |
+
"page_idx": 9
|
| 864 |
+
},
|
| 865 |
+
{
|
| 866 |
+
"type": "text",
|
| 867 |
+
"text": "[7] Tianqi Chen and Carlos Guestrin. Xgboost: A scalable tree boosting system. In Proceedings of the 22nd acm sigkdd international conference on knowledge discovery and data mining, pages 785–794, 2016. ",
|
| 868 |
+
"bbox": [
|
| 869 |
+
179,
|
| 870 |
+
367,
|
| 871 |
+
825,
|
| 872 |
+
410
|
| 873 |
+
],
|
| 874 |
+
"page_idx": 9
|
| 875 |
+
},
|
| 876 |
+
{
|
| 877 |
+
"type": "text",
|
| 878 |
+
"text": "[8] Tianqi Chen, Mu Li, Yutian Li, Min Lin, Naiyan Wang, Minjie Wang, Tianjun Xiao, Bing Xu, Chiyuan Zhang, and Zheng Zhang. Mxnet: A flexible and efficient machine learning library for heterogeneous distributed systems. arXiv preprint arXiv:1512.01274, 2015. ",
|
| 879 |
+
"bbox": [
|
| 880 |
+
178,
|
| 881 |
+
417,
|
| 882 |
+
823,
|
| 883 |
+
462
|
| 884 |
+
],
|
| 885 |
+
"page_idx": 9
|
| 886 |
+
},
|
| 887 |
+
{
|
| 888 |
+
"type": "text",
|
| 889 |
+
"text": "[9] Tianqi Chen, Thierry Moreau, Ziheng Jiang, Lianmin Zheng, Eddie Yan, Haichen Shen, Meghan Cowan, Leyuan Wang, Yuwei Hu, Luis Ceze, et al. TVM: An automated end-to-end optimizing compiler for deep learning. In 13th USENIX Symposium on Operating Systems Design and Implementation (OSDI 18), pages 578–594, 2018. ",
|
| 890 |
+
"bbox": [
|
| 891 |
+
176,
|
| 892 |
+
469,
|
| 893 |
+
823,
|
| 894 |
+
527
|
| 895 |
+
],
|
| 896 |
+
"page_idx": 9
|
| 897 |
+
},
|
| 898 |
+
{
|
| 899 |
+
"type": "text",
|
| 900 |
+
"text": "[10] Tianqi Chen, Lianmin Zheng, Eddie Yan, Ziheng Jiang, Thierry Moreau, Luis Ceze, Carlos Guestrin, and Arvind Krishnamurthy. Learning to optimize tensor programs. Advances in Neural Information Processing Systems, 31:3389–3400, 2018. ",
|
| 901 |
+
"bbox": [
|
| 902 |
+
179,
|
| 903 |
+
535,
|
| 904 |
+
823,
|
| 905 |
+
579
|
| 906 |
+
],
|
| 907 |
+
"page_idx": 9
|
| 908 |
+
},
|
| 909 |
+
{
|
| 910 |
+
"type": "text",
|
| 911 |
+
"text": "[11] Pratik Fegade, Tianqi Chen, Phil Gibbons, and Todd Mowry. Cortex: A compiler for recursive deep learning models. CoRR, abs/2011.01383, 2020. ",
|
| 912 |
+
"bbox": [
|
| 913 |
+
178,
|
| 914 |
+
587,
|
| 915 |
+
825,
|
| 916 |
+
617
|
| 917 |
+
],
|
| 918 |
+
"page_idx": 9
|
| 919 |
+
},
|
| 920 |
+
{
|
| 921 |
+
"type": "text",
|
| 922 |
+
"text": "[12] Matteo Frigo, Charles E. Leiserson, Harald Prokop, and Sridhar Ramachandran. Cache-oblivious algorithms. ACM Trans. Algorithms, 8(1), January 2012. ",
|
| 923 |
+
"bbox": [
|
| 924 |
+
178,
|
| 925 |
+
625,
|
| 926 |
+
823,
|
| 927 |
+
655
|
| 928 |
+
],
|
| 929 |
+
"page_idx": 9
|
| 930 |
+
},
|
| 931 |
+
{
|
| 932 |
+
"type": "text",
|
| 933 |
+
"text": "[13] Kazushige Goto and Robert A van de Geijn. Anatomy of high-performance matrix multiplication. ACM Transactions on Mathematical Software (TOMS), 34(3):1–25, 2008. ",
|
| 934 |
+
"bbox": [
|
| 935 |
+
174,
|
| 936 |
+
662,
|
| 937 |
+
823,
|
| 938 |
+
693
|
| 939 |
+
],
|
| 940 |
+
"page_idx": 9
|
| 941 |
+
},
|
| 942 |
+
{
|
| 943 |
+
"type": "text",
|
| 944 |
+
"text": "[14] Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. Deep residual learning for image recognition. In 2016 IEEE Conference on Computer Vision and Pattern Recognition (CVPR), pages 770–778, 2016. ",
|
| 945 |
+
"bbox": [
|
| 946 |
+
176,
|
| 947 |
+
700,
|
| 948 |
+
823,
|
| 949 |
+
743
|
| 950 |
+
],
|
| 951 |
+
"page_idx": 9
|
| 952 |
+
},
|
| 953 |
+
{
|
| 954 |
+
"type": "text",
|
| 955 |
+
"text": "[15] Menghao Li, Minjia Zhang, Chi Wang, and Mingqin Li. Adatune: Adaptive tensor program compilation made efficient. Advances in Neural Information Processing Systems, 33, 2020. ",
|
| 956 |
+
"bbox": [
|
| 957 |
+
166,
|
| 958 |
+
751,
|
| 959 |
+
825,
|
| 960 |
+
781
|
| 961 |
+
],
|
| 962 |
+
"page_idx": 9
|
| 963 |
+
},
|
| 964 |
+
{
|
| 965 |
+
"type": "text",
|
| 966 |
+
"text": "[16] Mingzhen Li, Yi Liu, Xiaoyan Liu, Qingxiao Sun, Xin You, Hailong Yang, Zhongzhi Luan, Lin Gan, Guangwen Yang, and Depei Qian. The deep learning compiler: A comprehensive survey. IEEE Transactions on Parallel and Distributed Systems, 32(3):708–727, 2020. ",
|
| 967 |
+
"bbox": [
|
| 968 |
+
173,
|
| 969 |
+
790,
|
| 970 |
+
823,
|
| 971 |
+
833
|
| 972 |
+
],
|
| 973 |
+
"page_idx": 9
|
| 974 |
+
},
|
| 975 |
+
{
|
| 976 |
+
"type": "text",
|
| 977 |
+
"text": "[17] Rui Li, Yufan Xu, Aravind Sukumaran-Rajam, Atanas Rountev, and P. Sadayappan. Analytical characterization and design space exploration for optimization of cnns. In Proceedings of the 26th ACM International Conference on Architectural Support for Programming Languages and Operating Systems, ASPLOS 2021, page 928–942, New York, NY, USA, 2021. Association for Computing Machinery. ",
|
| 978 |
+
"bbox": [
|
| 979 |
+
174,
|
| 980 |
+
842,
|
| 981 |
+
825,
|
| 982 |
+
912
|
| 983 |
+
],
|
| 984 |
+
"page_idx": 9
|
| 985 |
+
},
|
| 986 |
+
{
|
| 987 |
+
"type": "text",
|
| 988 |
+
"text": "[18] Yizhi Liu, Yao Wang, Ruofei Yu, Mu Li, Vin Sharma, and Yida Wang. Optimizing CNN model inference on cpus. In 2019 USENIX Annual Technical Conference (USENIX ATC 19), pages 1025–1040, Renton, WA, July 2019. USENIX Association. \n[19] Adam Paszke, Sam Gross, Francisco Massa, Adam Lerer, James Bradbury, Gregory Chanan, Trevor Killeen, Zeming Lin, Natalia Gimelshein, Luca Antiga, et al. Pytorch: An imperative style, high-performance deep learning library. arXiv preprint arXiv:1912.01703, 2019. \n[20] Jonathan Ragan-Kelley, Connelly Barnes, Andrew Adams, Sylvain Paris, Frédo Durand, and Saman Amarasinghe. Halide: A language and compiler for optimizing parallelism, locality, and recomputation in image processing pipelines. SIGPLAN Not., 48(6):519–530, June 2013. \n[21] Yukinori Sato, Tomoya Yuki, and Toshio Endo. An autotuning framework for scalable execution of tiled code via iterative polyhedral compilation. ACM Transactions on Architecture and Code Optimization (TACO), 15(4):1–23, 2019. \n[22] Karen Simonyan and Andrew Zisserman. Very deep convolutional networks for large-scale image recognition. In Yoshua Bengio and Yann LeCun, editors, 3rd International Conference on Learning Representations, ICLR 2015, San Diego, CA, USA, May 7-9, 2015, Conference Track Proceedings, 2015. \n[23] Benoit Steiner, Chris Cummins, Horace He, and Hugh Leather. Value learning for throughput optimization of deep learning workloads. In Proceedings of the 4th MLSys Conference, San Jose, CA, USA, 2021. \n[24] Christian Szegedy, Vincent Vanhoucke, Sergey Ioffe, Jon Shlens, and Zbigniew Wojna. Rethinking the inception architecture for computer vision. In 2016 IEEE Conference on Computer Vision and Pattern Recognition (CVPR), pages 2818–2826, 2016. \n[25] Nicolas Vasilache, Oleksandr Zinenko, Theodoros Theodoridis, Priya Goyal, Zachary DeVito, William S Moses, Sven Verdoolaege, Andrew Adams, and Albert Cohen. Tensor comprehensions: Framework-agnostic high-performance machine learning abstractions. arXiv preprint arXiv:1802.04730, 2018. \n[26] Yu Emma Wang, Gu-Yeon Wei, and David Brooks. Benchmarking tpu, gpu, and cpu platforms for deep learning. arXiv preprint arXiv:1907.10701, 2019. \n[27] R. Clinton Whaley and Jack J Dongarra. Automatically tuned linear algebra software. In SC’98: Proceedings of the 1998 ACM/IEEE conference on Supercomputing, pages 38–38. IEEE, 1998. \n[28] Huaqing Zhang, Xiaolin Cheng, Hui Zang, and Dae Hoon Park. Compiler-level matrix multiplication optimization for deep learning. arXiv preprint arXiv:1909.10616, 2019. \n[29] Lianmin Zheng, Chengfan Jia, Minmin Sun, Zhao Wu, Cody Hao Yu, Ameer Haj-Ali, Yida Wang, Jun Yang, Danyang Zhuo, Koushik Sen, et al. Ansor: Generating high-performance tensor programs for deep learning. In 14th {USENIX} Symposium on Operating Systems Design and Implementation $\\langle \\bar \\langle O S D I \\} \\bar { 2 0 } \\rangle$ , pages 863–879, 2020. \n[30] Size Zheng, Yun Liang, Shuo Wang, Renze Chen, and Kaiwen Sheng. Flextensor: An automatic schedule exploration and optimization framework for tensor computation on heterogeneous system. In Proceedings of the Twenty-Fifth International Conference on Architectural Support for Programming Languages and Operating Systems, pages 859–873, 2020. ",
|
| 989 |
+
"bbox": [
|
| 990 |
+
150,
|
| 991 |
+
83,
|
| 992 |
+
828,
|
| 993 |
+
791
|
| 994 |
+
],
|
| 995 |
+
"page_idx": 10
|
| 996 |
+
},
|
| 997 |
+
{
|
| 998 |
+
"type": "text",
|
| 999 |
+
"text": "301 Checklist ",
|
| 1000 |
+
"text_level": 1,
|
| 1001 |
+
"bbox": [
|
| 1002 |
+
145,
|
| 1003 |
+
797,
|
| 1004 |
+
253,
|
| 1005 |
+
814
|
| 1006 |
+
],
|
| 1007 |
+
"page_idx": 10
|
| 1008 |
+
},
|
| 1009 |
+
{
|
| 1010 |
+
"type": "text",
|
| 1011 |
+
"text": "The checklist follows the references. Please read the checklist guidelines carefully for information on how to answer these questions. For each question, change the default [TODO] to [Yes] , [No] , or [N/A] . You are strongly encouraged to include a justification to your answer, either by referencing the appropriate section of your paper or providing a brief inline description. For example: ",
|
| 1012 |
+
"bbox": [
|
| 1013 |
+
174,
|
| 1014 |
+
829,
|
| 1015 |
+
825,
|
| 1016 |
+
886
|
| 1017 |
+
],
|
| 1018 |
+
"page_idx": 10
|
| 1019 |
+
},
|
| 1020 |
+
{
|
| 1021 |
+
"type": "text",
|
| 1022 |
+
"text": "• Did you include the license to the code and datasets? [Yes] See Section ??. ",
|
| 1023 |
+
"bbox": [
|
| 1024 |
+
215,
|
| 1025 |
+
897,
|
| 1026 |
+
722,
|
| 1027 |
+
911
|
| 1028 |
+
],
|
| 1029 |
+
"page_idx": 10
|
| 1030 |
+
},
|
| 1031 |
+
{
|
| 1032 |
+
"type": "text",
|
| 1033 |
+
"text": "• Did you include the license to the code and datasets? [No] The code and the data are proprietary. \n• Did you include the license to the code and datasets? [N/A] ",
|
| 1034 |
+
"bbox": [
|
| 1035 |
+
215,
|
| 1036 |
+
90,
|
| 1037 |
+
825,
|
| 1038 |
+
138
|
| 1039 |
+
],
|
| 1040 |
+
"page_idx": 11
|
| 1041 |
+
},
|
| 1042 |
+
{
|
| 1043 |
+
"type": "text",
|
| 1044 |
+
"text": "Please do not modify the questions and only use the provided macros for your answers. Note that the Checklist section does not count towards the page limit. In your paper, please delete this instructions block and only keep the Checklist section heading above along with the questions/answers below. ",
|
| 1045 |
+
"bbox": [
|
| 1046 |
+
142,
|
| 1047 |
+
150,
|
| 1048 |
+
828,
|
| 1049 |
+
193
|
| 1050 |
+
],
|
| 1051 |
+
"page_idx": 11
|
| 1052 |
+
},
|
| 1053 |
+
{
|
| 1054 |
+
"type": "text",
|
| 1055 |
+
"text": "1. For all authors... ",
|
| 1056 |
+
"bbox": [
|
| 1057 |
+
214,
|
| 1058 |
+
204,
|
| 1059 |
+
339,
|
| 1060 |
+
218
|
| 1061 |
+
],
|
| 1062 |
+
"page_idx": 11
|
| 1063 |
+
},
|
| 1064 |
+
{
|
| 1065 |
+
"type": "text",
|
| 1066 |
+
"text": "(a) Do the main claims made in the abstract and introduction accurately reflect the paper’s contributions and scope? [Yes] \n(b) Did you describe the limitations of your work? [Yes] See Section 4 on “Evaluation of automatic schedule chosen”. \n(c) Did you discuss any potential negative societal impacts of your work? [N/A] \n(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes] ",
|
| 1067 |
+
"bbox": [
|
| 1068 |
+
238,
|
| 1069 |
+
223,
|
| 1070 |
+
825,
|
| 1071 |
+
329
|
| 1072 |
+
],
|
| 1073 |
+
"page_idx": 11
|
| 1074 |
+
},
|
| 1075 |
+
{
|
| 1076 |
+
"type": "text",
|
| 1077 |
+
"text": "2. If you are including theoretical results... ",
|
| 1078 |
+
"bbox": [
|
| 1079 |
+
214,
|
| 1080 |
+
332,
|
| 1081 |
+
493,
|
| 1082 |
+
347
|
| 1083 |
+
],
|
| 1084 |
+
"page_idx": 11
|
| 1085 |
+
},
|
| 1086 |
+
{
|
| 1087 |
+
"type": "text",
|
| 1088 |
+
"text": "(a) Did you state the full set of assumptions of all theoretical results? [Yes] (b) Did you include complete proofs of all theoretical results? [Yes] , but only in the supplemental material due to space limit. ",
|
| 1089 |
+
"bbox": [
|
| 1090 |
+
236,
|
| 1091 |
+
351,
|
| 1092 |
+
825,
|
| 1093 |
+
396
|
| 1094 |
+
],
|
| 1095 |
+
"page_idx": 11
|
| 1096 |
+
},
|
| 1097 |
+
{
|
| 1098 |
+
"type": "text",
|
| 1099 |
+
"text": "3. If you ran experiments... ",
|
| 1100 |
+
"bbox": [
|
| 1101 |
+
212,
|
| 1102 |
+
400,
|
| 1103 |
+
393,
|
| 1104 |
+
414
|
| 1105 |
+
],
|
| 1106 |
+
"page_idx": 11
|
| 1107 |
+
},
|
| 1108 |
+
{
|
| 1109 |
+
"type": "text",
|
| 1110 |
+
"text": "(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes] , in the supplemental material. \n(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] , in the supplemental material. \n(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [Yes] , see Section 4 on “Ablation analysis” \n(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] , in the supplemental material. ",
|
| 1111 |
+
"bbox": [
|
| 1112 |
+
238,
|
| 1113 |
+
419,
|
| 1114 |
+
825,
|
| 1115 |
+
551
|
| 1116 |
+
],
|
| 1117 |
+
"page_idx": 11
|
| 1118 |
+
},
|
| 1119 |
+
{
|
| 1120 |
+
"type": "text",
|
| 1121 |
+
"text": "4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets... ",
|
| 1122 |
+
"bbox": [
|
| 1123 |
+
215,
|
| 1124 |
+
555,
|
| 1125 |
+
823,
|
| 1126 |
+
570
|
| 1127 |
+
],
|
| 1128 |
+
"page_idx": 11
|
| 1129 |
+
},
|
| 1130 |
+
{
|
| 1131 |
+
"type": "text",
|
| 1132 |
+
"text": "(a) If your work uses existing assets, did you cite the creators? [Yes] \n(b) Did you mention the license of the assets? [Yes] , in the supplemental material. \n(c) Did you include any new assets either in the supplemental material or as a URL? [Yes] \n(d) Did you discuss whether and how consent was obtained from people whose data you’re using/curating? [N/A] \n(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A] ",
|
| 1133 |
+
"bbox": [
|
| 1134 |
+
238,
|
| 1135 |
+
574,
|
| 1136 |
+
823,
|
| 1137 |
+
681
|
| 1138 |
+
],
|
| 1139 |
+
"page_idx": 11
|
| 1140 |
+
},
|
| 1141 |
+
{
|
| 1142 |
+
"type": "text",
|
| 1143 |
+
"text": "5. If you used crowdsourcing or conducted research with human subjects... ",
|
| 1144 |
+
"bbox": [
|
| 1145 |
+
214,
|
| 1146 |
+
685,
|
| 1147 |
+
705,
|
| 1148 |
+
700
|
| 1149 |
+
],
|
| 1150 |
+
"page_idx": 11
|
| 1151 |
+
},
|
| 1152 |
+
{
|
| 1153 |
+
"type": "text",
|
| 1154 |
+
"text": "(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A] \n(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A] \n(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A] ",
|
| 1155 |
+
"bbox": [
|
| 1156 |
+
238,
|
| 1157 |
+
704,
|
| 1158 |
+
825,
|
| 1159 |
+
792
|
| 1160 |
+
],
|
| 1161 |
+
"page_idx": 11
|
| 1162 |
+
}
|
| 1163 |
+
]
|
parse/train/PhtFY9plHk/PhtFY9plHk_middle.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
parse/train/PhtFY9plHk/PhtFY9plHk_model.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
parse/train/Re_VXFOyyO/Re_VXFOyyO.md
ADDED
|
@@ -0,0 +1,375 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# On the Convergence and Sample Efficiency of Variance-Reduced Policy Gradient Method
|
| 2 |
+
|
| 3 |
+
Junyu Zhang Department of Industrial Systems Engineering and Management National University of Singapore Singapore, 119077 junyuz@nus.edu.sg
|
| 4 |
+
|
| 5 |
+
Chengzhuo Ni Department of Electrical and Computer Engineering Princeton University Princeton, NJ, 08544 chengzhuo.ni@princeton.edu
|
| 6 |
+
|
| 7 |
+
Zheng Yu Department of Electrical and Computer Engineering Princeton University Princeton, NJ, 08544 zhengy@princeton.edu
|
| 8 |
+
|
| 9 |
+
Csaba Szepesvari Department of Computer Science University of Alberta Edmonton, Alberta, Canada T6G 2E8 szepesva@ualberta.ca
|
| 10 |
+
|
| 11 |
+
Mengdi Wang Department of Electrical and Computer Engineering Princeton University Princeton, NJ, 08544 mengdiw@princeton.edu
|
| 12 |
+
|
| 13 |
+
# Abstract
|
| 14 |
+
|
| 15 |
+
Policy gradient (PG) gives rise to a rich class of reinforcement learning (RL) methods. Recently, there has been an emerging trend to accelerate the existing PG methods such as REINFORCE by the variance reduction techniques. However, all existing variance-reduced PG methods heavily rely on an uncheckable importance weight assumption made for every single iteration of the algorithms. In this paper, a simple gradient truncation mechanism is proposed to address this issue. Moreover, we design a Truncated Stochastic Incremental Variance-Reduced Policy Gradient (TSIVR-PG) method, which is able to maximize not only a cumulative sum of rewards but also a general utility function over a policy’s long-term visiting distribution. We show an $\tilde { \mathcal { O } } ( \epsilon ^ { - 3 } )$ sample complexity for TSIVR-PG to find an $\epsilon$ -stationary policy. By assuming the overparameterization of policy and exploiting the hidden convexity of the problem, we further show that TSIVR-PG converges to global $\epsilon$ -optimal policy with $\tilde { \mathcal { O } } ( \epsilon ^ { - 2 } )$ samples.
|
| 16 |
+
|
| 17 |
+
# 1 Introduction
|
| 18 |
+
|
| 19 |
+
In this paper, we investigate the theoretical properties of Policy Gradient (PG) methods for Reinforcement Learning (RL) [43]. In view of RL as a policy optimization problem, the PG method
|
| 20 |
+
|
| 21 |
+
parameterizes the policy function and conduct gradient ascent search to improve the policy. In this paper, we consider the soft-max policy parameterization
|
| 22 |
+
|
| 23 |
+
$$
|
| 24 |
+
\pi _ { \theta } ( a | s ) = \frac { \exp \{ \psi ( s , a ; \theta ) \} } { \sum _ { a ^ { \prime } } \exp \{ \psi ( s , a ^ { \prime } ; \theta ) \} }
|
| 25 |
+
$$
|
| 26 |
+
|
| 27 |
+
where $( s , a )$ is a state-action pair and $\psi$ is some smooth function. Potentially, one can set the function $\psi$ to be some deep neural network with weights $\theta$ and input $( s , a )$ . The main problem considered in this paper is the policy optimization for a general utility function:
|
| 28 |
+
|
| 29 |
+
$$
|
| 30 |
+
\operatorname* { m a x } _ { \theta } R ( \pi _ { \theta } ) : = F ( \lambda ^ { \pi _ { \theta } } ) ,
|
| 31 |
+
$$
|
| 32 |
+
|
| 33 |
+
where $F$ is a general smooth function, and $\lambda ^ { \pi _ { \theta } }$ denotes the unnormalized state-action occupancy measure (also referred to as the visitation measure). For any policy $\pi$ and initial state distribution $\xi$ ,
|
| 34 |
+
|
| 35 |
+
$$
|
| 36 |
+
\lambda ^ { \pi } ( s , a ) : = \sum _ { t = 0 } ^ { + \infty } \gamma ^ { t } \cdot \mathbb { P } \Big ( s _ { t } = s , a _ { t } = a \big | \pi , s _ { 0 } \sim \xi \Big ) ,
|
| 37 |
+
$$
|
| 38 |
+
|
| 39 |
+
where $\gamma$ stands for the discount factor and $\mathbb { P }$ denotes the probability of a certain event. When $F$ is linear, the problem reduces to the standard policy optimization problem where the objective is to maximize a cumulative sum of rewards. When $F$ is nonlinear, problem (2) goes beyond standard Markov decision problems: examples include the max-entropy exploration [16], risk-sensitive RL [50], certain set constrained RL [27], and so on.
|
| 40 |
+
|
| 41 |
+
In the standard cumulative-return case (i.e., $F$ is linear), numerous works have studied PG methods in various scenarios, see e.g. [47, 5, 58, 22, 21, 37, 38, 23]. When directly optimizing over the policy space without any parameterization, the policy mirror descent (PMD) method [23] achieves an $\bar { \mathcal { O } } ( \epsilon ^ { - 2 } )$ sample complexity to find an $\mathcal { O } ( \epsilon )$ -optimal solution. However, for the more practical parameterized policy optimization, to the authors’ best knowledge, the most recent variant of PG methods, using the SARAH/Spider stochastic variance reduction technique [13, 29], find a local $\epsilon$ -stationary policy using $\mathcal { O } ( \epsilon ^ { - 3 } )$ samples [48, 33]. This poses a contrast with the known $\tilde { O } ( \epsilon ^ { - 2 } )$ sample complexity results that can be achieved by various value-based methods [4, 42, 41] and are provably matching information-theoretic lower bounds [12, 3, 4]. In this paper, we attempt to close this gap and prove an $\tilde { \mathcal { O } } ( \epsilon ^ { - 2 } )$ sample complexity bound for a PG method. Most importantly, when it comes to PG estimation, the application of the variance reduction technique typically relies on certain off-policy PG estimator, resulting in the difficulty of distribution shift. We notice that none of the existing variance-reduced PG methods attempt to address this challenge. Instead, they directly make an uncheckable assumption that the variance of the importance weight is bounded for every policy pair encountered in running the algorithm, see e.g. [31, 48, 49, 33]. In this paper, we propose a simple gradient truncation mechanism to fix this issue.
|
| 42 |
+
|
| 43 |
+
Next, let us go beyond cumulative return and consider policy optimization for a general utility where $F$ may be nonlinear. However, much less is known in this setting. The nonlinearity of $F$ invalidates the concept of Q-function and value function, leading to the failure of policy gradient theorem [44]. To overcome such difficulty, [51] showed that the policy gradient for the general utilities is the solution to a min-max problem. However, estimating a single PG is highly nontrivial in this case. It is still unclear how to make PG methods to use samples in a most efficient way.
|
| 44 |
+
|
| 45 |
+
In this paper, we aim to investigate the convergence and sample efficiency of the PG method, using episodic sampling, for both linear $F$ (i.e., cumulative rewards) and nonlinear $F$ (i.e., general utility). Observe that problem (2) is an instance of the Stochastic Composite Optimization (SCO) problem [45, 46]: $\mathrm { m i n } _ { x } ^ { - } f ( \mathbb { E } _ { \nu } [ g _ { \nu } ( x ) ] )$ , which involves an inner expectation that corresponds to the occupancy measure $\lambda ^ { \pi }$ . Motivated by this view point, we attempt to develop stochastic policy gradient method with provable finite-sample efficiency bounds.
|
| 46 |
+
|
| 47 |
+
Main results. Our main results are summarized below.
|
| 48 |
+
|
| 49 |
+
• We propose the TSIVR-PG algorithm to solve problem (2) via episodic sampling. It provides a conceptually simple stochastic gradient approach for solving general utility RL. • We provide a gradient truncation mechanism to address the distribution shift difficulty in variance-reduced PG methods. Such difficulty has never been addressed in previous works.
|
| 50 |
+
|
| 51 |
+
• We show that TSIVR-PG finds an $\epsilon$ -stationary policy using $\tilde { O } ( \epsilon ^ { - 3 } )$ samples if $F$ and $\psi$ are general smooth functions. When $F$ is concave and $\psi$ satisfies certain overparameterization condition, we show that TSIVR-PG obtains a gloal $\epsilon$ -optimal policy using $\bar { O } ( \epsilon ^ { - 2 } )$ samples.
|
| 52 |
+
|
| 53 |
+
Technical contribution. Our analysis technique is also of independent interest in the relating areas.
|
| 54 |
+
|
| 55 |
+
• For stochastic composite optimization (SCO), most existing algorithms require estimating the Jacobian matrix of the inner mapping, which corresponds to $\nabla _ { \boldsymbol { \theta } } \lambda ^ { \pi _ { \boldsymbol { \theta } } }$ in our setting. This is in practice prohibitive if the Jacobian matrix has high dimensions, which is exactly the case in our problem. Unlike SCO algorithms such as [24, 54, 53, etc.], our analysis enables us to avoid the Jacobian matrix estimation.
|
| 56 |
+
For the stochastic variance-reduced gradient methods, our analysis implies a convergence of SARAH/Spider methods to global optimality and a new $\mathcal { O } ( \epsilon ^ { - 2 } )$ sample complexity for nonconvex problems with “hidden convexity” structure, which has not been studied in the optimization community yet.
|
| 57 |
+
|
| 58 |
+
# 2 Related Works
|
| 59 |
+
|
| 60 |
+
Policy gradient gives rises to a rich family of RL algorithms, such as REINFORCE and many of its variants [47, 5, 58], as well as extensions such as the natural policy gradient methods [20, 32], the actor-critic methods [22, 21, 28], the trust-region policy optimization [37, 57, 39], and the proximal policy optimization method [38, 25], etc. In this paper we mainly focus on REINFORCE-type methods, where many of them need $\tilde { \mathcal { O } } ( \epsilon ^ { - 4 } )$ samples to find an $\epsilon$ -stationary solution, including the vanilla REINFORCE [47], as well as its variants with baseline [58, 43] and GPOMDP [5], etc. By incorporating the stochastic variance reduction techniques, the sample efficiency of PG methods can be further improved. In [31], the SVRG [19] variance reduction scheme is adopted and an $\mathcal { O } ( \epsilon ^ { - 4 } )$ sample complexity is achieved, which is later improved to $\mathcal { O } ( \epsilon ^ { - 1 0 / 3 } )$ by [48]. With additional Hessian information, [40] achieved an $\mathcal { O } ( \epsilon ^ { - 3 } )$ complexity. By utilizing a more efficient SARAH/Spider [29, 13] variance reduction scheme, people are able to achieve $\mathcal { O } ( \epsilon ^ { - 3 } )$ sample complexity without second-order information [48, 33]. We would like to comment that these results are only for finding $\epsilon$ -stationary (rather than near-optimal) solutions, and all of them requires an uncheckable condition on the importance weights in every iteration.
|
| 61 |
+
|
| 62 |
+
Recently, for cumulative reward, a series of works have started to study the convergence of policy gradient method to global optimal solutions [1, 14, 56, 6, 26, 7, 9, 55]. In particular, [51] exploited the hidden convexity property of the MDP problem and established the convergence to global optimality for general utility RL problem, as long as the policy gradient can be computed exactly.
|
| 63 |
+
|
| 64 |
+
Our approach is related to the stochastic composite optimization (SCO) [45, 46]. For the general composition problem, there have been numerous developments, including momentum-based and multi-time-scale algorithms [45, 46, 15], and various composite stochastic variance-reduced algorithms [24, 17, 52, 54]. Our approach is also inspired by variance reduction techniques that were initially used for stochastic convex optimization, see [19, 36, 11, 29]; and were later on extended to the stochastic nonconvex optimization problems [2, 34, 18, 35, 13, 30]. In particular, we will utilize the SARAH/Spider scheme [13, 30].
|
| 65 |
+
|
| 66 |
+
# 3 Problem Formulation
|
| 67 |
+
|
| 68 |
+
Consider an MDP with a general utility function, denoted as $\mathbf { M D P } ( S , { \mathcal { A } } , { \mathcal { P } } , \gamma , F )$ , where $s$ is a finite state space, $\mathcal { A }$ is a finite action space, $\gamma \in ( 0 , 1 )$ is a discount factor, and $F$ is some general utility function. For each state $s \in S$ , a transition to state $s ^ { \prime } \in \varDelta$ occurs when selecting an action $a \in { \mathcal { A } }$ following the distribution $\textstyle { \mathcal { P } } ( \cdot | a , s )$ . For each state $s \in S$ , a policy $\pi$ gives a distribution $\pi ( \cdot | s )$ over the action space $\mathcal { A }$ . Let $\xi$ be the initial state distribution and let the unnormalized state-action occupancy measure $\lambda ^ { \pi }$ be defined by (3), we define the general utility function $F$ as a smooth function of the occupancy measure, and the goal of the general utility MDP is to maximize $F ( \lambda ^ { \pi } )$ . With the policy $\pi _ { \theta }$ being parameterized by (1), we propose to solve problem (2), which is
|
| 69 |
+
|
| 70 |
+
$$
|
| 71 |
+
\operatorname* { m a x } _ { \theta } R ( \pi _ { \theta } ) : = F \left( \lambda ^ { \pi _ { \theta } } \right) .
|
| 72 |
+
$$
|
| 73 |
+
|
| 74 |
+
For notational convenience, we often write $\lambda ( \theta )$ instead of $\lambda ^ { \pi _ { \theta } }$ . Such utility function is very general and includes many important problems in RL. We provide a few examples where $F$ are concave.
|
| 75 |
+
|
| 76 |
+
Example 3.1 (Cumulative reward). When $F \left( \lambda ^ { \pi _ { \theta } } \right) = \left. r , \lambda ^ { \pi _ { \theta } } \right.$ , for some $r \in \mathbb { R } ^ { | S | | \mathcal { A } | }$ . Then we recover the standard cumulative sum of rewards: $\begin{array} { r } { R ( \pi _ { \theta } ) = \mathbb { E } \big [ \sum _ { t = 0 } ^ { + \infty } \gamma ^ { t } \cdot r ( s _ { t } , a _ { t } ) \big | \pi _ { \theta } , s _ { 0 } \sim \xi \big ] } \end{array}$ .
|
| 77 |
+
|
| 78 |
+
Example 3.2 (Maximal entropy exploration). Let $\begin{array} { r } { \mu ^ { \pi _ { \theta } } ( s ) = ( 1 - \gamma ) \sum _ { a } \lambda ^ { \pi _ { \theta } } ( s , a ) } \end{array}$ , $\forall s \in S$ be the state occupancy measure, which is the margin of $\lambda ^ { \pi _ { \theta } }$ over $s$ . Let $F ( \cdot )$ be the entropy function, then we recover the objective for maximal entropy exploration $\begin{array} { r } { \left[ { I 6 } \right] : R ( \pi _ { \theta } ) = - \sum _ { s \in \mathcal { S } } \mu ^ { \bar { \pi _ { \theta } } } ( s ) \log \mu ^ { \pi _ { \theta } } ( s ) } \end{array}$ .
|
| 79 |
+
|
| 80 |
+
Example 3.3 (RL with Set Constraint). Let $\mathbf { z } ( s _ { t } , a _ { t } ) \in \mathbb { R } ^ { d }$ be a vector feedback received in each step. The cumulative feedback is $\begin{array} { r } { \mathbf { u } ( \pi _ { \theta } ) : = \mathbb { E } \big [ \sum _ { t = 0 } ^ { + \infty } \gamma ^ { t } \cdot \mathbf { z } ( s _ { t } , a _ { t } ) | s _ { 0 } \sim \xi , \pi _ { \theta } \big ] = M \lambda ^ { \pi _ { \theta } } } \end{array}$ for some matrix $M \in \mathbb { R } ^ { d \times | S | | A | }$ . [27] proposed a set-constrained RL problem which aims to find a policy $\pi$ s.t. $u ( \pi ) \in U$ for some convex set $U$ . This problem can be formulated as an instance of (2) by letting $F ( \cdot )$ be the negative squared distance: $\begin{array} { r } { R ( \pi _ { \theta } ) = - \operatorname* { m i n } _ { \mathbf { u } ^ { \prime } \in U } \| \mathbf { u } ^ { \prime } - \mathbf { u } ( \pi _ { \theta } ) \| ^ { 2 } } \end{array}$ .
|
| 81 |
+
|
| 82 |
+
# 4 The TSIVR-PG Algorithm
|
| 83 |
+
|
| 84 |
+
In this section, we propose a Truncated Stochastic Incremental Variance-Reduced Policy Gradient (TSIVR-PG) method, which is inspired by techniques of variance reduction and off-policy estimation. A gradient truncation mechanism is proposed to provably control the importance weights in off-policy sampling.
|
| 85 |
+
|
| 86 |
+
# 4.1 Off-Policy PG Estimation
|
| 87 |
+
|
| 88 |
+
Policy Gradient First, let us derive the policy gradient of the general utility. Let $V ^ { \pi _ { \theta } } ( r )$ be the cumulative reward under policy $\pi _ { \theta }$ , initial distribution $\xi$ and reward function $r$ . By Example 3.1, $V ^ { \pi _ { \theta } } ( r ) = \langle \lambda ( \theta ) , r \rangle$ , the chain rule and policy gradient theorem [44] indicates that
|
| 89 |
+
|
| 90 |
+
$$
|
| 91 |
+
\nabla _ { \theta } V ^ { \pi _ { \theta } } ( r ) = \left[ \nabla _ { \theta } \lambda ( \theta ) \right] ^ { \top } r = \mathbb { E } _ { \xi , \pi _ { \theta } } \Big [ \sum _ { t = 0 } ^ { + \infty } \gamma ^ { t } \cdot r ( s _ { t } , a _ { t } ) \cdot \Big ( \sum _ { t ^ { \prime } = 0 } ^ { t } \nabla _ { \theta } \log \pi _ { \theta } ( a _ { t ^ { \prime } } | s _ { t ^ { \prime } } ) \Big ) \Big ] ,
|
| 92 |
+
$$
|
| 93 |
+
|
| 94 |
+
where $\nabla _ { \boldsymbol { \theta } } \lambda ( \boldsymbol { \theta } )$ is the Jacobian matrix of the vector mapping $\lambda ( \theta )$ . That is, policy gradient theorem actually provides a way for computing the Jacobian-vector product for the occupancy measure. Following the above observation and the chain rule, we have
|
| 95 |
+
|
| 96 |
+
$$
|
| 97 |
+
\nabla _ { \boldsymbol { \theta } } R ( \pi _ { \boldsymbol { \theta } } ) = \left[ \nabla _ { \boldsymbol { \theta } } \lambda ( \boldsymbol { \theta } ) \right] ^ { \top } \nabla _ { \lambda } F ( \lambda ( \boldsymbol { \theta } ) ) = \nabla _ { \boldsymbol { \theta } } V ^ { \pi _ { \boldsymbol { \theta } } } ( r ) \vert _ { r = \nabla _ { \lambda } F ( \lambda ( \boldsymbol { \theta } ) ) } .
|
| 98 |
+
$$
|
| 99 |
+
|
| 100 |
+
Therefore, we can estimate the policy gradient using the typical REINFORCE as long as we pick the “quasi-reward function" as $r : = \nabla _ { \lambda } F ( \lambda ( \theta ) )$ . To find this quasi-reward, we need to estimate the state-action occupancy measure $\lambda ( \theta )$ (unless $F$ is linear).
|
| 101 |
+
|
| 102 |
+
Importance Sampling Weight Let $\tau = \left\{ s _ { 0 } , a _ { 0 } , s _ { 1 } , a _ { 1 } , \cdot \cdot \cdot , s _ { H - 1 } , a _ { H - 1 } \right\}$ be a length- $H$ trajectory generated under the initial distribution $\xi$ and the behavioral policy $\pi _ { \theta _ { 1 } }$ . For any target policy $\pi _ { \boldsymbol { \theta } _ { 2 } }$ , we define the importance sampling weight as
|
| 103 |
+
|
| 104 |
+
$$
|
| 105 |
+
\omega _ { t } ( \tau | \theta _ { 1 } , \theta _ { 2 } ) = \frac { \Pi _ { h = 0 } ^ { t } \pi _ { \theta _ { 2 } } ( a _ { h } | s _ { h } ) } { \Pi _ { t = 0 } ^ { h } \pi _ { \theta _ { 1 } } ( a _ { h } | s _ { h } ) } , \qquad 0 \le t \le H - 1 .
|
| 106 |
+
$$
|
| 107 |
+
|
| 108 |
+
It is worth noting that such importance sampling weight is inevitable in the stochastic variance reduced policy gradient methods, see [31, 48, 49, 33, 25]. In these works, the authors usually directly assume $\mathrm { \bar { V a r } } ( \bar { \omega _ { H - 1 } } ( \tau | \theta _ { 1 } , \theta _ { 2 } ) ) \leq W$ for all the policy pairs encountered in every iteration of their algorithms. However, such assumption is too strong and is uncheckable.
|
| 109 |
+
|
| 110 |
+
Based on the above notation of behavioral and target policies, as long as the importance sampling weights, we present the following off-policy occupancy and policy gradient estimators.
|
| 111 |
+
|
| 112 |
+
Off-Policy Occupancy Measure Estimator Denote $\mathbf { e } _ { s a }$ the vector with $( s , a )$ -th entry being 1 while other entries being 0. We define the following estimator for $\lambda ( \theta _ { 2 } )$
|
| 113 |
+
|
| 114 |
+
$$
|
| 115 |
+
\widehat { \lambda } _ { \omega } ( \tau | \theta _ { 1 } , \theta _ { 2 } ) : = \sum _ { t = 0 } ^ { H - 1 } \gamma ^ { t } \cdot \omega _ { t } ( \tau | \theta _ { 1 } , \theta _ { 2 } ) \cdot \mathbf { e } _ { s _ { t } a _ { t } } .
|
| 116 |
+
$$
|
| 117 |
+
|
| 118 |
+
When $\theta _ { 2 } = \theta _ { 1 }$ , $\omega _ { t } ( \tau | \theta _ { 1 } , \theta _ { 2 } ) \equiv 1$ and $\widehat { \lambda } _ { \omega } ( \tau | \theta _ { 1 } , \theta _ { 2 } )$ becomes the on-policy (discounted) empirical distribution, for which we use the simplified notion $\widehat { \lambda } ( \tau | \theta _ { 2 } ) : = \widehat { \lambda } _ { \omega } ( \tau | \mathbf { \bar { \theta } } _ { 2 } , \mathbf { \bar { \theta } } _ { 2 } )$ .
|
| 119 |
+
|
| 120 |
+
Off-Policy Policy Gradient Estimator Let $r \in \mathbb { R } ^ { | S | | A | }$ be any quasi-reward vector. We aim to estimate the Jacobian-vector product $[ \nabla _ { \boldsymbol { \theta } } \lambda ( \boldsymbol { \theta } _ { 2 } ) ] ^ { \top } r$ for target policy $\pi _ { \theta _ { 2 } }$ by
|
| 121 |
+
|
| 122 |
+
$$
|
| 123 |
+
\widehat { g } _ { \omega } ( \tau | \theta _ { 1 } , \theta _ { 2 } , r ) : = \sum _ { t = 0 } ^ { H - 1 } \gamma ^ { t } \cdot \omega _ { t } ( \tau | \theta _ { 1 } , \theta _ { 2 } ) \cdot r ( s _ { t } , a _ { t } ) \cdot \Big ( \sum _ { t ^ { \prime } = 0 } ^ { t } \nabla _ { \theta } \log \pi _ { \theta _ { 2 } } ( a _ { t ^ { \prime } } | s _ { t ^ { \prime } } ) \Big ) .
|
| 124 |
+
$$
|
| 125 |
+
|
| 126 |
+
When $\theta _ { 2 } = \theta _ { 1 }$ , $\omega _ { t } ( \tau | \theta _ { 1 } , \theta _ { 2 } ) \equiv 1$ and $\widehat { g } _ { \omega } ( \tau | \theta _ { 1 } , \theta _ { 2 } , r )$ becomes the on-policy REINFORCE estimator with quasi-reward function $r$ b. In this case, we use the simplified notion $\widehat { g } ( \tau | \theta _ { 2 } , r ) : = \widehat { g } _ { \omega } ( \tau | \theta _ { 2 } , \theta _ { 2 } , r )$ . Estimators $\widehat { \lambda } _ { \omega } ( \tau | \theta _ { 1 } , \theta _ { 2 } )$ and $\widehat { g } _ { \omega } ( \tau | \theta _ { 1 } , \theta _ { 2 } , r )$ are almost unbiased. In details, $\| \mathbb { E } _ { \tau \sim \pi _ { \theta _ { 1 } } } [ \widehat { \lambda } _ { \omega } ( \tau | \theta _ { 1 } , \theta _ { 2 } ) ] -$ $\lambda ( \theta _ { 2 } ) \lVert \leq \mathcal { O } ( \gamma ^ { H } )$ and $\begin{array} { r } { \big \| \mathbb { E } _ { \tau \sim \pi _ { \theta _ { 1 } } } \big [ \widehat { g } _ { \omega } ( \tau | \theta _ { 1 } , \theta _ { 2 } , r ) \big ] - \big [ \nabla _ { \theta } \lambda ( \theta _ { 2 } ) \big ] ^ { \top } r \big \| \leq \mathcal { O } ( H \cdot \gamma ^ { H } ) } \end{array}$ ; see details in Appendix 1 bE. Therefore the bias due to truncation is almost negligible if $H$ is properly selected.
|
| 127 |
+
|
| 128 |
+
# 4.2 The TSIVR-PG Algorithm
|
| 129 |
+
|
| 130 |
+
To achieve the $\tilde { \mathcal { O } } ( \epsilon ^ { - 2 } )$ sample complexity, we propose an epoch-wise algorithm called Truncated Stochastic Incremental Variance-Reduced PG (TSIVR-PG) Algorithm. Let ${ \bf { \bar { \boldsymbol { \theta } } } } _ { 0 } ^ { i }$ be the starting point of the $i$ -th epoch, TSIVR-PG constructs the estimators for $\lambda ( \theta _ { 0 } ^ { i } )$ , quasi-reward $\nabla _ { \lambda } F ( \lambda ( \theta _ { 0 } ^ { i } ) { \bar { ) } }$ and the policy gradient $\nabla _ { \theta } F ( \lambda ( \theta _ { 0 } ^ { i } ) )$ by
|
| 131 |
+
|
| 132 |
+
$$
|
| 133 |
+
\lambda _ { 0 } ^ { i } = \frac { 1 } { N } \sum _ { \tau \in \mathcal { N } _ { i } } \widehat { \lambda } ( \tau | \theta _ { 0 } ^ { i } ) , ~ r _ { 0 } ^ { i } = \nabla _ { \lambda } F ( \lambda _ { 0 } ^ { i } ) ~ \mathrm { a n d } ~ g _ { 0 } ^ { i } = \frac { 1 } { N } \sum _ { \tau \in \mathcal { N } _ { i } } \widehat { g } ( \tau | \theta _ { 0 } ^ { i } , r _ { 0 } ^ { i } ) .
|
| 134 |
+
$$
|
| 135 |
+
|
| 136 |
+
where ${ \mathcal { N } } _ { i }$ is a set of $N$ independent length- $H$ trajectories sampled under $\pi _ { \theta _ { 0 } ^ { i } }$ . When $j \geq 1$
|
| 137 |
+
|
| 138 |
+
$$
|
| 139 |
+
\lambda _ { j } ^ { i } = \frac { 1 } { B } \sum _ { \tau \in \mathscr { B } _ { j } ^ { i } } \left( \widehat { \lambda } ( \tau | \theta _ { j } ^ { i } ) - \widehat { \lambda } _ { \omega } ( \tau | \theta _ { j } ^ { i } , \theta _ { j - 1 } ^ { i } ) \right) + \lambda _ { j - 1 } ^ { i } , \qquad r _ { j } ^ { i } = \nabla _ { \lambda } F ( \lambda _ { j } ^ { i } )
|
| 140 |
+
$$
|
| 141 |
+
|
| 142 |
+
$$
|
| 143 |
+
g _ { j } ^ { i } = \frac { 1 } { B } \sum _ { \tau \in B _ { j } ^ { i } } \left( \widehat { g } \left( \tau | \theta _ { j } ^ { i } , r _ { j - 1 } ^ { i } \right) - \widehat { g } _ { \omega } \left( \tau | \theta _ { j } ^ { i } , \theta _ { j - 1 } ^ { i } , r _ { j - 2 } ^ { i } \right) \right) + g _ { j - 1 } ^ { i } ,
|
| 144 |
+
$$
|
| 145 |
+
|
| 146 |
+
where $B _ { j } ^ { i }$ is a set of $B$ independent length- $H$ trajectories sampled under $\pi _ { \theta _ { j } ^ { i } }$ , and we default $r _ { - 1 } ^ { i } : = r _ { 0 } ^ { i }$ . Specifically, $\widehat { g } _ { \omega } ( \tau | \theta _ { j } ^ { i } , \theta _ { j - 1 } ^ { i } , r _ { j - 2 } ^ { i } )$ is used instead of $\widehat { g } _ { \omega } ( \tau | \theta _ { j } ^ { i } , \theta _ { j - 1 } ^ { i } , r _ { j - 1 } ^ { i } )$ for independence issue. The b bdetails of the TSIVR-PG algorithm are stated in Algorithm 1.
|
| 147 |
+
|
| 148 |
+
# Algorithm 1: The TSIVR-PG Algorithm
|
| 149 |
+
|
| 150 |
+

|
| 151 |
+
|
| 152 |
+
It is worth noting that the truncated gradient step (11) is equivalent to a trust region subproblem:
|
| 153 |
+
|
| 154 |
+
$$
|
| 155 |
+
\theta _ { j + 1 } ^ { i } = \underset { \| \theta - \theta _ { j } ^ { i } \| \leq \delta } { \operatorname { a r g m a x } } ~ { F } ( \lambda ( \theta _ { j } ^ { i } ) ) + \langle g _ { j } ^ { i } , \theta - \theta _ { j } ^ { i } \rangle + \frac { 1 } { 2 \eta } \| \theta - \theta _ { j } ^ { i } \| ^ { 2 }
|
| 156 |
+
$$
|
| 157 |
+
|
| 158 |
+
where the approximate Hessian matrix is simply chosen as $( \eta ) ^ { - 1 } \cdot I$ .
|
| 159 |
+
|
| 160 |
+
# 5 Sample Efficiency of TSIVR-PG
|
| 161 |
+
|
| 162 |
+
In this section, we analyze the finite-sample performance of TSIVR-PG. We first show that TSIVR-PG finds an $\epsilon$ -stationary solution with $\bar { \mathcal { O } } ( \bar { \epsilon } ^ { - 3 } )$ samples. Given additional assumptions, we show that TSIVR-PG finds a global $\epsilon$ -optimal solution with $\tilde { \mathcal { O } } ( \epsilon ^ { - 2 } )$ samples .
|
| 163 |
+
|
| 164 |
+
# 5.1 Convergence Towards Stationary Points
|
| 165 |
+
|
| 166 |
+
Since we focus on the soft-max policy parameterization where $\begin{array} { r } { \pi _ { \theta } ( a | s ) = \frac { \exp \{ \psi ( s , a ; \theta ) \} } { \sum _ { a ^ { \prime } } \exp \{ \psi ( s , a ^ { \prime } ; \theta ) \} } } \end{array}$ P a0 exp{ψ(s,a0;θ)} , we make the following assumptions on the parameterization function $\psi$ and the utility $F$ .
|
| 167 |
+
|
| 168 |
+
Assumption 5.1. $\psi ( s , a ; \cdot )$ is twice differentiable for all s and $a$ . There $\exists \ell _ { \psi } , L _ { \psi } > 0$ s.t.
|
| 169 |
+
|
| 170 |
+
$$
|
| 171 |
+
\operatorname* { m a x } _ { s \in S , a \in A } \operatorname* { s u p } _ { \theta } \| \nabla _ { \theta } \psi ( s , a ; \theta ) \| \leq \ell _ { \psi } \quad a n d \quad \operatorname* { m a x } _ { s \in S , a \in A } \operatorname* { s u p } _ { \theta } \| \nabla _ { \theta } ^ { 2 } \psi ( s , a ; \theta ) \| \leq L _ { h } ,
|
| 172 |
+
$$
|
| 173 |
+
|
| 174 |
+
where $\| \cdot \|$ stands for $L _ { 2 }$ norm and spectral norm for vector and matrix respectively.
|
| 175 |
+
|
| 176 |
+
Assumption 5.2. $F$ is a smooth and possibly nonconvex function. There exists $\ell _ { \lambda , \infty } > 0$ such that $\| \nabla _ { \lambda } F ( \lambda ) \| _ { \infty } \leq \ell _ { \lambda , \infty } .$ . And there exist constants $L _ { \lambda , \infty } , L _ { \lambda } > 0$ s.t. it holds for $\forall \lambda , \lambda ^ { \prime }$ that
|
| 177 |
+
|
| 178 |
+
$$
|
| 179 |
+
\begin{array} { r } { \| \nabla _ { \lambda } F ( \lambda ) - \nabla _ { \lambda } F ( \lambda ^ { \prime } ) \| _ { \infty } \leq L _ { \lambda } \| \lambda - \lambda ^ { \prime } \| _ { 2 } \quad a n d \quad \| \nabla _ { \lambda } F ( \lambda ) - \nabla _ { \lambda } F ( \lambda ^ { \prime } ) \| _ { \infty } \leq L _ { \lambda , \infty } \| \lambda - \lambda ^ { \prime } \| _ { 1 } . } \end{array}
|
| 180 |
+
$$
|
| 181 |
+
|
| 182 |
+
Based on the above assumptions, we have the following supporting lemmas.
|
| 183 |
+
|
| 184 |
+
Lemma 5.3. Given Assumption 5.1 and 5.2, the following results hold: (i). For any policy parameter $\theta$ and any state-action pair $( s , a )$ , the following inequalities hold: $\| \nabla _ { \theta } \log \pi _ { \theta } ( a | s ) \| \le 2 \ell _ { \psi }$ , $\| \nabla _ { \theta } ^ { 2 } \log \pi _ { \theta } ( a | s ) \| \le 2 ( L _ { \psi } + \ell _ { \psi } ^ { 2 } )$ , and $\begin{array} { r } { \| \nabla _ { \theta } F ( \lambda ( \theta ) ) \| \le \frac { 2 \ell _ { \psi } \cdot \ell _ { \lambda , \infty } } { ( 1 - \gamma ) ^ { 2 } } } \end{array}$ (ii). For any policy parameters $\theta _ { 1 }$ and $\theta _ { 2 }$ , it holds that $\begin{array} { r } { \left. \lambda ^ { \pi _ { \theta _ { 1 } } } - \lambda ^ { \pi _ { \theta _ { 2 } } } \right. _ { 1 } \leq \frac { 2 \ell _ { \psi } } { ( 1 - \gamma ) ^ { 2 } } \cdot \left. \theta _ { 1 } - \theta _ { 2 } \right. } \end{array}$ . (iii). The objective function $F \circ \lambda ( \cdot )$ is $L _ { \theta }$ -smooth, with $\begin{array} { r } { L _ { \theta } = \frac { 4 L _ { \lambda , \infty } \cdot \ell _ { \psi } ^ { 2 } } { ( 1 - \gamma ) ^ { 4 } } + \frac { 8 \ell _ { \psi } ^ { 2 } \cdot \ell _ { \lambda , \infty } } { ( 1 - \gamma ) ^ { 3 } } + \frac { 2 \ell _ { \lambda , \infty } \cdot ( L _ { \psi } + \ell _ { \psi } ^ { 2 } ) } { ( 1 - \gamma ) ^ { 2 } } , } \end{array}$ .
|
| 185 |
+
|
| 186 |
+
To measure the convergence, we propose to use the gradient mapping defined as follows:
|
| 187 |
+
|
| 188 |
+
$$
|
| 189 |
+
\mathcal { G } _ { \eta } ( \theta ) = \frac { \theta _ { + } - \theta } { \eta } , \quad \mathrm { w h e r e } \quad \theta _ { + } = \left\{ \begin{array} { l l } { \theta + \eta \cdot g } & { , \mathrm { ~ i f ~ } \eta \| g \| \le \delta , } \\ { \theta + \delta \cdot g / \| g \| } & { , \mathrm { ~ o t h e r w i s e } } \end{array} \right.
|
| 190 |
+
$$
|
| 191 |
+
|
| 192 |
+
where $g = \nabla _ { \boldsymbol { \theta } } F ( \lambda ( \boldsymbol { \theta } ) )$ . We remark that, $\mathbb { E } [ \| \mathcal { G } _ { \eta } ( \theta _ { j } ^ { i } ) \| ^ { 2 } ]$ is more suitable for the ascent analysis of the truncated gradient updates, compared with the commonly used $\mathbb { E } [ \| \nabla _ { \theta } F ( \lambda ( \theta _ { j } ^ { i } ) ) \| ^ { 2 } ]$ . Note that ${ \mathcal G } _ { \boldsymbol \eta } ( \boldsymbol \theta ) = \nabla F ( \lambda ( { \boldsymbol \theta } ) )$ if $\lVert \mathcal { G } _ { \eta } ( { \boldsymbol { \theta } } ) \rVert \leq \delta$ and $\| \nabla F ( \lambda ( \theta ) ) \|$ is bounded for any $\theta$ . Based on such observation, we have the following lemma to validate the choice of the proposed stationarity measure.
|
| 193 |
+
|
| 194 |
+
Lemma 5.4. For any random vector $\theta$ , $\mathbb { E } [ \lVert \mathcal { G } _ { \eta } ( \theta ) \rVert ] \le \epsilon$ implies $\mathbb { E } [ \| \nabla _ { \theta } F ( \lambda ( \theta ) ) \| ] \le \mathcal { O } ( \delta ^ { - 1 } \cdot \epsilon ) .$ .
|
| 195 |
+
|
| 196 |
+
Based on the notion of $\mathcal { G } _ { \eta }$ , we characterize the per-iteration ascent as follows.
|
| 197 |
+
|
| 198 |
+
Lemma 5.5. Let the iterates be generated by Algorithm $^ { l }$ . Then it holds that
|
| 199 |
+
|
| 200 |
+
$$
|
| 201 |
+
F ( \lambda ( \theta _ { j + 1 } ^ { i } ) ) \geq F ( \lambda ( \theta _ { j } ^ { i } ) ) + \frac { \eta } { 4 } \| \mathcal { G } _ { \eta } ( \theta _ { j } ^ { i } ) \| ^ { 2 } + \Big ( \frac { 1 } { 2 \eta } - L _ { \theta } \Big ) \| \theta _ { j + 1 } ^ { i } - \theta _ { j } ^ { i } \| ^ { 2 } - \Big ( \frac { \eta } { 2 } + \frac { 1 } { 2 L _ { \theta } } \Big ) \| \nabla _ { \theta } F ( \lambda ( \theta _ { j } ^ { i } ) ) - g _ { j } ^ { i } \| ^ { 2 } .
|
| 202 |
+
$$
|
| 203 |
+
|
| 204 |
+
This suggests us to bound mean-squared-error $\mathbb { E } [ \| \nabla _ { \theta } F ( \lambda ( \theta _ { j } ^ { i } ) ) - g _ { j } ^ { i } \| ^ { 2 } ]$ . For this purpose, we need to bound the importance sampling weight, by utilizing the soft-max form of policy parameterization (1).
|
| 205 |
+
|
| 206 |
+
Lemma 5.6. For any behavioral policy $\pi _ { \theta _ { 1 } }$ and target policy $\pi _ { \boldsymbol { \theta } _ { 2 } }$ parameterized by (1), the importance weight satisfies $\omega _ { t } ( \tau | \theta _ { 1 } , \theta _ { 2 } ) \leq \exp \big \{ 2 ( t + 1 ) \ell _ { \psi } \| \theta _ { 1 } - \theta _ { 2 } \| \big \}$ , for $\forall 0 \leq t \leq H - 1$ .
|
| 207 |
+
|
| 208 |
+
Since TSIVR-PG only uses importance weights for two consecutive iterations $\theta _ { j } ^ { i } , \theta _ { j - 1 } ^ { i }$ while forcing $\| \theta _ { j } ^ { i } - \theta _ { j - 1 } ^ { i } \| \leq \delta$ by the truncated gradient step (11), we have $\omega _ { H - 1 } ( \tau | \theta _ { j } ^ { i } , \theta _ { j - 1 } ^ { i } ) \leq \exp \{ 2 H \ell _ { \psi } \delta \}$ w.p. 1. As we will see later, the effective horizon $H$ only has a mild magnitude of $\mathcal { O } \big ( ( 1 - \gamma ) ^ { - 1 } { \cdot } \log ( 1 / \epsilon ) \big )$ , the truncation radius only need to satisfy $\delta = \mathcal { O } ( H ^ { - 1 } \ell _ { \psi } ^ { - 1 } )$ s.t. $\omega _ { t - 1 } \big ( \tau \vert \theta _ { j } ^ { i } , \theta _ { j - 1 } ^ { i } \big ) = \mathcal { O } ( 1 )$ , for $\forall t \leq H - 1$ . Consequently, combining Lemma 5.3, 5.6 and Lemma B.1 of [48] gives the following result.
|
| 209 |
+
|
| 210 |
+
Lemma 5.7. Let policy $\pi _ { \theta }$ be parameterized by (1) with function $\psi$ satisfying Assumption 5.1. Suppose behavioral policy $\pi _ { \theta _ { 1 } }$ and target policy $\pi _ { \theta _ { 2 } }$ satisfy $\lVert { \boldsymbol { \theta } } _ { 1 } - { \boldsymbol { \theta } } _ { 2 } \rVert \leq \delta$ , then
|
| 211 |
+
|
| 212 |
+
$\begin{array} { r } { \mathbb { E } [ \omega _ { t } ( \tau | \theta _ { 1 } , \theta _ { 2 } ) ] = 1 \quad a n d \quad \mathrm { V a r } \left( \omega _ { t } ( \tau | \theta _ { 1 } , \theta _ { 2 } ) \right) \leq C _ { \omega } ( t + 1 ) \cdot \| \theta _ { 1 } - \theta _ { 2 } \| ^ { 2 } , } \end{array}$ where $\tau$ is sampled under policy $\pi _ { \theta _ { 1 } }$ , and $C _ { \omega } ( t ) = t \big ( 4 \ell _ { \psi } ^ { 2 } ( t + \textstyle { \frac { 1 } { 2 } } ) + 2 L _ { \psi } \big ) ( e ^ { 4 \ell _ { \psi } \delta t } + 1 ) .$
|
| 213 |
+
|
| 214 |
+
As a result, we can bound the mean-squared-error of the $g _ { j } ^ { i }$ as follows.
|
| 215 |
+
|
| 216 |
+
Lemma 5.8. For the $P G$ estimators $g _ { j } ^ { i }$ , we have
|
| 217 |
+
|
| 218 |
+
$$
|
| 219 |
+
\mathbb { S } \bigg [ \| g _ { j } ^ { i } - \nabla _ { \theta } F ( \lambda ( \theta _ { j } ^ { i } ) ) \| ^ { 2 } \bigg ] \leq \frac { C _ { 1 } } { N } + C _ { 2 } \gamma ^ { 2 H } + \frac { C _ { 3 } } { B } \cdot \sum _ { j ^ { \prime } = 1 } ^ { j } \mathbb { E } \left[ \| \theta _ { j ^ { \prime } - 1 } ^ { i } - \theta _ { j ^ { \prime } } ^ { i } \| ^ { 2 } \right] + C _ { 4 } \mathbb { E } \left[ \| \theta _ { j - 1 } ^ { i } - \theta _ { j } ^ { i } \| ^ { 2 } \right]
|
| 220 |
+
$$
|
| 221 |
+
|
| 222 |
+
for some constants $C _ { 1 } , . . , C _ { 4 } > 0 .$ . In case $j = 0$ , we default $\textstyle \sum _ { j ^ { \prime } = 1 } ^ { 0 } \cdot = 0$
|
| 223 |
+
|
| 224 |
+
The expression of constants $C _ { i }$ ’s are complicated, we provide their detailed formula in the appendix. If we set H = O log(1/) and $\begin{array} { r } { \delta \le \frac { 1 } { 2 H \ell _ { \psi } } } \end{array}$ , then $C _ { i }$ only depends polynomially on the Lipschitz constants, $\log ( \epsilon ^ { - 1 } )$ , and $( 1 - \gamma ) ^ { - 1 }$ . Combining Lemma 5.5, 5.8, and 5.4 gives Theorem 5.9.
|
| 225 |
+
|
| 226 |
+
Theorem 5.9. For Algorithm $^ { l }$ , we choose $\begin{array} { r } { H = \frac { 2 \log ( 1 / \epsilon ) } { 1 - \gamma } } \end{array}$ , $\begin{array} { r } { \delta = \frac { 1 } { 2 H \ell _ { \psi } } } \end{array}$ , $B = m = \epsilon ^ { - 1 }$ , $N = \epsilon ^ { - 2 }$ η = 11+(C3+C4)/L2θ · 12Lθ . After running the algorithm for T = −1 epochs and output θout from $\{ \theta _ { j } ^ { i } \} _ { j = 0 , \cdots , m - 1 } ^ { i = 1 , \cdots , T }$ uniformly at random, we have $\mathbb { E } [ \| \mathcal { G } _ { \eta } ( \theta _ { o u t } ) \| ] \le \mathcal { O } ( \epsilon )$ . The total number of samples is $\dot { T } \times ( ( m - 1 ) B + N ) \times H = \tilde { \mathcal { O } } ( \epsilon ^ { - 3 } )$ . By Lemma 5.4, we also have $\mathbb { E } [ \| \nabla _ { \theta } F ( \lambda ( \theta _ { o u t } ) ) \| ] \le { \mathcal { O } } ( \epsilon )$ .
|
| 227 |
+
|
| 228 |
+
# 5.2 Convergence Towards Global Optimality
|
| 229 |
+
|
| 230 |
+
Next, we provide a mechanism to establish the convergence of TSIVR-PG to global optimality. For this purpose, we introduce the hidden convexity of the general utility RL problem. In addition to the smoothness of $F$ (Assumption 5.2), we further assume its concavity, formally stated as follows.
|
| 231 |
+
|
| 232 |
+
Assumption 5.10. Function $F$ is a concave function of the state-action occupancy measure.
|
| 233 |
+
|
| 234 |
+
Let $\mathcal { L }$ be the image of the mapping $\lambda ( \theta )$ . Then the parameterized policy optimization problem (2) can be rewritten as an equivalent occupancy optimization problem:
|
| 235 |
+
|
| 236 |
+
$$
|
| 237 |
+
\begin{array} { r } { \operatorname* { m a x } _ { \theta } F ( \lambda ( \theta ) ) \qquad \Longleftrightarrow \qquad \operatorname* { m a x } _ { \mu \in \mathcal { L } } F ( \mu ) . } \end{array}
|
| 238 |
+
$$
|
| 239 |
+
|
| 240 |
+
When the policy parameterization is powerful enough to represent any policy, the image $\mathcal { L }$ is a convex polytope, see e.g. [10]. Since $F$ is concave, the occupancy optimization problem is a convex optimization problem. In this case, if the mapping $\lambda ( \cdot )$ is invertible (see [51]), we may view the original problem (2) as a reformulation of a convex problem by a change of variable: $\theta = \lambda ^ { - 1 } ( \mu )$ . We call this property “hidden convexity”. However, requiring $\lambda ( \cdot )$ to be invertible is too restrictive, and it doesn’t even hold for simple soft-max policy with $\psi ( s , a ; \theta ) = \theta _ { s a }$ where multiple $\theta$ correspond to a same policy. Therefore, we adopt a weaker assumption where (i). $\pi _ { \theta }$ can represent any policy (ii). a continuous inverse $\lambda ^ { - 1 } ( \cdot )$ can be locally defined over a subset of $\theta$ .
|
| 241 |
+
|
| 242 |
+
Assumption 5.11. For policy parameterization of form (1), $\theta$ overparametrizes the set of policies in the following sense. $( i )$ . For any $\theta$ and $\lambda ( \theta )$ , there exist (relative) neighourhoods $\theta \in \mathcal { U } _ { \theta } \subset B ( \theta , \delta )$ and $\lambda ( \theta ) \in \mathcal { V } _ { \lambda ( \theta ) } \subset \lambda ( B ( \theta , \delta ) )$ s.t. $\left( \lambda | _ { \mathcal { U } _ { \theta } } \right) ( \cdot )$ forms a bijection between $\mathcal { U } _ { \theta }$ and $\mathcal { V } _ { \lambda ( \theta ) }$ , where $\left( \lambda | _ { \mathcal { U } _ { \theta } } \right) ( \cdot )$ is the confinement of $\lambda$ onto $\mathcal { U } _ { \theta }$ . We assume $( \lambda | _ { \mathcal { U } _ { \theta } } ) ^ { - 1 } ( \cdot )$ is $\ell _ { \theta }$ -Lipschitz continuous for any $\theta$ . (ii). Let $\pi _ { \theta ^ { \ast } }$ be the optimal policy. Assume there exists ¯ small enough, s.t. $( 1 - \epsilon ) \lambda ( \theta ) + \epsilon \lambda ( \theta ^ { * } ) \in$ $\mathcal { V } _ { \lambda ( \theta ) } f o r \forall \epsilon \le \bar { \epsilon } , \forall \theta$ .
|
| 243 |
+
|
| 244 |
+
Based on Assumption 5.11, we replace Lemma 5.5 with the following lemma.
|
| 245 |
+
|
| 246 |
+
$$
|
| 247 |
+
\begin{array} { r l r } { \displaystyle F ( \lambda ( \theta ^ { * } ) ) - F ( \lambda ( \theta _ { j + 1 } ^ { i } ) ) \ \le \ ( 1 - \epsilon ) \left( F ( \lambda ( \theta ^ { * } ) ) - F ( \lambda ( \theta _ { j } ^ { i } ) ) \right) } & { { } } & { { ( 1 5 ) } } \\ { \displaystyle + \left( L _ { \theta } + \frac { 1 } { 2 \eta } \right) \frac { 2 \epsilon ^ { 2 } \ell _ { \theta } ^ { 2 } } { ( 1 - \gamma ) ^ { 2 } } - \left( \frac { 1 } { 2 \eta } - L _ { \theta } \right) \| \theta _ { j + 1 } ^ { i } - \theta _ { j } ^ { i } \| ^ { 2 } + \frac { 1 } { L _ { \theta } } \| g _ { j } ^ { i } - \nabla _ { \theta } F ( \lambda ( \theta _ { j } ^ { i } ) ) \| ^ { 2 } . } & { } & { } \end{array}
|
| 248 |
+
$$
|
| 249 |
+
|
| 250 |
+
The analysis of Lemma 5.12 is very different from its nonconvex optimization counterpart (Lemma 5.5). Next, we derive the sample complexity of the TSIVR-PG algorithm given Lemma 5.12 and 5.8.
|
| 251 |
+
|
| 252 |
+
Theorem 5.13. For TSIVR-PG method (Algorithm $^ { l }$ ), let $\epsilon \in ( 0 , \bar { \epsilon } )$ be the target accuracy. If we choose $H , m , B , N$ and $\delta$ according to Theorem 5.9. and we let the stepsize to be small enough s.t. $\begin{array} { r } { \eta \le \frac { 1 } { 2 L _ { \theta } + 8 ( C _ { 3 } + C _ { 4 } ) / L _ { \theta } } } \end{array}$ , then after at most $T = \log _ { 2 } ( \epsilon ^ { - 1 } )$ epochs, $\mathbb { E } \big [ F \big ( \hat { \lambda } ( \theta ^ { * } ) \big ) - F \big ( \lambda ( \tilde { \theta } _ { T } ) \big ) \big ] \leq \mathcal { O } ( \epsilon )$ The total number of samples taken is $T \times ( ( m - 1 ) B + N ) \times H = \tilde { \mathcal { O } } ( \epsilon ^ { - 2 } )$ .
|
| 253 |
+
|
| 254 |
+
# 6 Numerical Experiments
|
| 255 |
+
|
| 256 |
+
# 6.1 Maximizing Cumulative Reward.
|
| 257 |
+
|
| 258 |
+
In this experiment, we aim to evaluate the performance of the TSIVR-PG algorithm for maximizing the cumulative sum of reward. As the benchmarks, we also implement the SVRPG [49], the SRVRPG [48], the HSPGA [33], and the REINFORCE [47] algorithms. Our experiment is performed on benchmark RL environments including the FrozenLake, Acrobot and Cartpole that are available from OpenAI gym [8], which is a well-known toolkit for developing and comparing reinforcement learning algorithms. For all the algorithms, their batch sizes are chosen according to their theory. In details, let $\epsilon$ be any target accuracy. For both TSIVR-PG and SRVR-PG, we set $N = \Theta ( \epsilon ^ { - 2 } )$ , $B = m = \Theta ( \epsilon ^ { - 1 } )$ . For SVRPG, we set $N = \Theta ( \epsilon ^ { - 2 } )$ , $B = \Theta ( \epsilon ^ { - 4 / 3 } )$ and $m = \Theta ( \epsilon ^ { - 2 / 3 } )$ . For HSPGA, we set $B ^ { \prime } = \Theta ( \epsilon ^ { - 1 } )$ , other parameters are calculated according to formulas in [33] given $B$ . For REINFORCE, we set the batchsize to be $N = \Theta ( \epsilon ^ { - 2 } )$ . The parameter $\varepsilon$ and the stepsize/learning rate are tuned for each individual algorithm using a grid search. For each algorithm, we run the experiment for multiple times with random initialization of the policy parameters. The curve is obtained by first calculating the moving average of the most recent 50 episodes, and then calculate the median of the return over the outcomes of different runs. The upper and lower bounds of the shaded area are calculated as the $\textstyle { \frac { 1 } { 4 } }$ and $\frac 3 4$ quantiles over the outcomes. We run the experiment for 10 times for the FrozenLake environment and 50 times for the other environments. The detailed parameters used in the experiments are presented in the Appendix.
|
| 259 |
+
|
| 260 |
+
FrozenLake The FrozenLake8x8 environment is a tabular MDP with finite state and action spaces.
|
| 261 |
+
For this environment, the policy is parameterized with $\psi ( s , a ; \theta ) = \theta _ { s a }$ .
|
| 262 |
+
|
| 263 |
+
Cartpole and Acrobot Both the Cartpole environment and the Acrobot environment are environments with a discrete action space and a continuous state space. For both environments, we use a neural network with two hidden layers with width 64 for both layers to model the policy.
|
| 264 |
+
|
| 265 |
+
Result We plot our experiment outcomes in Figure 6.1. The experiments show that given enough episodes, all of the algorithms are able to solve the tasks, achieving nearly optimal returns. And as expected, the REINFORCE algorithm takes the longest time to find the optimal policy. While the other algorithms yield a faster convergence speed, the TSIVR-PG algorithm consistently outperforms the other benchmark algorithms under all of the environments, showing the advantage of our method.
|
| 266 |
+
|
| 267 |
+
# 6.2 Validating the $\tilde { \mathcal { O } } ( \epsilon ^ { - 2 } )$ Sample Complexity
|
| 268 |
+
|
| 269 |
+
Besides the comparison between different benchmark algorithms, we also perform a validation experiment showing that for certain environments, the convergence rate of TSIVR-PG is close to the theoretical guarantee. Because the parameters $N , B , m$ are dependent on the target accuracy $\epsilon$ , in this section we adopt a different way to set up these parameters: We first set a fixed epoch $E$ , and perform experiments using different values of the parameter √ $N$ . The parameter $B$ and $m$ are set according to our choice of $N$ by $B = m = \sqrt { N }$ . The performance of the algorithm output is calculated as the average score of the last few episodes, which is then averaged over 10 independent runs. Again, we use the FrozenLake8x8 environment to do the experiment. Because FrozenLake8x8 is a tabular environment whose transition and reward function can be easily obtained from the document, we can calculate it’s optimal value simply by value iteration, which takes 0.4146 when we choose $\gamma = 0 . 9 9$ . In this way, we calculate the gap between the algorithm return and the optimal value, and get log-log figure w.r.t. the gap and the number of episodes calculated by $E ( N + B m ) = 2 E N$ .
|
| 270 |
+
|
| 271 |
+

|
| 272 |
+
Figure 1: The performance curves of TSIVR-PG and benchmark algorithms under different environments. The curve is the median return over multiple runs and the shaded areas are calculated as the $\textstyle { \frac { 1 } { 4 } }$ and $\textstyle { \frac { 3 } { 4 } }$ quantiles of the experiment outcomes.
|
| 273 |
+
|
| 274 |
+
Result The result is shown in the first sub-figure of Figure 6.3, where the blue curve is the gap between the average return of experiment outcome and the optimal value and the shaded area is the range of one standard deviation of the logarithm value. In addition, we add a orange dotted line to fit the convergence curve, whose slope takes value $- 0 . 4 9 6$ , which nearly matches the $O ( \epsilon ^ { - 2 } )$ theoretical bound (slope $- 0 . 5 )$ .
|
| 275 |
+
|
| 276 |
+
# 6.3 Maximizing Non-linear Objective Function
|
| 277 |
+
|
| 278 |
+
The TSIVR-PG algorithm is designed not only to solve typical RL problems, but is also able to solve a broader class of problems where the objective function is a general concave function. Unfortunately, none of the benchmark algorithms proposed in the previous section have the ability to solve this kind of problem. To evaluate the performance of our algorithm, we choose another benchmark algorithm, which is the MaxEnt algorithm [16]. In the experiment, we use FrozenLake8x8 environment since it’s more tractable to compute $\lambda$ for a discrete state space. We set the objective function as
|
| 279 |
+
|
| 280 |
+
$$
|
| 281 |
+
F ( \lambda ) = \sum _ { s \in S } \log { \Bigg ( } \sum _ { a \in { \mathcal { A } } } \lambda _ { s , a } + \sigma { \Bigg ) } ,
|
| 282 |
+
$$
|
| 283 |
+
|
| 284 |
+
where $\sigma$ is a fixed small constant. We choose $\sigma = 0 . 1 2 5$ in our experiment. The orders of $N , B , m$ are set in the same way as those in section 6.1. For the MaxEnt algorithm, note that in the original paper, the nonlinear objective function assumes the input value is the stationary state distribution $d ^ { \pi }$ , but the input value can easily be changed into our $\lambda$ without changing the steps of the algorithm much. The result is illustrated in Fig. 6.3. From the result, we may see that our algorithm consistently outperforms the benchmark.
|
| 285 |
+
|
| 286 |
+
# 7 Broader Impact
|
| 287 |
+
|
| 288 |
+
There has been an emerging trend of applying stochastic variance reduction technique to enhance the performance of the policy gradient methods. However, all the existing variance-reduced policy gradient methods depend on an algorithm-dependent assumption that is made to every single iteration in running the algorithm, which actually may not be satisfied by many of these algorithms. We propose a simple yet effective mechanism to fix such dilemma for applying the SARAH/Spider variance reduction scheme in policy gradient methods. Our analysis can also be applied to other schemes such as STORM and Hybrid SARAH-SGD. Beyond that, we also show how the hidden convexity and overparameterization of the RL problem can help stochastic variance-reduced policy gradient methods to converge to global optima and yield better sample complexity.
|
| 289 |
+
|
| 290 |
+

|
| 291 |
+
Figure 2: Left: Empirical Evaluation of the Convergence Rate of TSIVR-PG. The optimality gap achieved by TSIVR-PG decreases as the sample size increases, nearly matching the $\epsilon ^ { - 2 }$ sample complexity theory (orange line). Right: Performance Curve ofTSIVR-PG and MaxEnt for Maximizing Non-linear Objective Functions. The curve is the median return over 10 runs and the shaded areas are calculated as the $\textstyle { \frac { 1 } { 4 } }$ and $\frac 3 4$ quantiles of the experiment outcomes.
|
| 292 |
+
|
| 293 |
+
# 8 Limitation
|
| 294 |
+
|
| 295 |
+
To compute the policy gradient for the general utility function, one needs to compute gradient of the function $\mathrm { F }$ with respect to the state-action occupancy measure. Although for many instances, including standard cumulative sum of reward (Example 3.1) and set constrained RL (Example 3.3), estimating the occupancy measure is not necessary. There are many instances where estimating the occupancy measure is unavoidable. Due to the curse of dimensionality, the need for estimating the occupancy measure is a potential limitation if the state and action spaces are continuous and high-dimensional. One potential solution is to incorporate a function approximation for the occupancy measure, in a similar style of the Q-function approximation in the actor-critic method. We leave this for future development.
|
| 296 |
+
|
| 297 |
+
# References
|
| 298 |
+
|
| 299 |
+
[1] Alekh Agarwal, Sham M Kakade, Jason D Lee, and Gaurav Mahajan. Optimality and approximation with policy gradient methods in markov decision processes. In Conference on Learning Theory, pages 64–66. PMLR, 2020.
|
| 300 |
+
[2] Zeyuan Allen-Zhu and Elad Hazan. Variance reduction for faster non-convex optimization. In International conference on machine learning, pages 699–707, 2016.
|
| 301 |
+
[3] Mohammad Gheshlaghi Azar, Rémi Munos, Mohammad Ghavamzadeh, and Hilbert Kappen. Reinforcement learning with a near optimal rate of convergence. 2011.
|
| 302 |
+
[4] Mohammad Gheshlaghi Azar, Rémi Munos, and Hilbert J Kappen. Minimax pac bounds on the sample complexity of reinforcement learning with a generative model. Machine learning, 91(3):325–349, 2013.
|
| 303 |
+
[5] Jonathan Baxter and Peter L Bartlett. Infinite-horizon policy-gradient estimation. Journal of Artificial Intelligence Research, 15:319–350, 2001.
|
| 304 |
+
[6] Jalaj Bhandari and Daniel Russo. Global optimality guarantees for policy gradient methods. arXiv preprint arXiv:1906.01786, 2019.
|
| 305 |
+
[7] Jalaj Bhandari and Daniel Russo. A note on the linear convergence of policy gradient methods. arXiv preprint arXiv:2007.11120, 2020.
|
| 306 |
+
[8] Greg Brockman, Vicki Cheung, Ludwig Pettersson, Jonas Schneider, John Schulman, Jie Tang, and Wojciech Zaremba. Openai gym. arXiv preprint arXiv:1606.01540, 2016.
|
| 307 |
+
[9] Shicong Cen, Chen Cheng, Yuxin Chen, Yuting Wei, and Yuejie Chi. Fast global convergence of natural policy gradient methods with entropy regularization. arXiv preprint arXiv:2007.06558, 2020.
|
| 308 |
+
[10] Yichen Chen, Lihong Li, and Mengdi Wang. Scalable bilinear pi learning using state and action features. arXiv preprint arXiv:1804.10328, 2018.
|
| 309 |
+
[11] Aaron Defazio, Francis Bach, and Simon Lacoste-Julien. Saga: A fast incremental gradient method with support for non-strongly convex composite objectives. Advances in neural information processing systems, 27:1646–1654, 2014.
|
| 310 |
+
[12] Eyal Even-Dar, Shie Mannor, Yishay Mansour, and Sridhar Mahadevan. Action elimination and stopping conditions for the multi-armed bandit and reinforcement learning problems. Journal of machine learning research, 7(6), 2006.
|
| 311 |
+
[13] Cong Fang, Chris Junchi Li, Zhouchen Lin, and Tong Zhang. Spider: Near-optimal nonconvex optimization via stochastic path-integrated differential estimator. In Advances in Neural Information Processing Systems, pages 689–699, 2018.
|
| 312 |
+
[14] Maryam Fazel, Rong Ge, Sham M Kakade, and Mehran Mesbahi. Global convergence of policy gradient methods for the linear quadratic regulator. arXiv preprint arXiv:1801.05039, 2018.
|
| 313 |
+
[15] Saeed Ghadimi, Andrzej Ruszczynski, and Mengdi Wang. A single timescale stochastic approximation method for nested stochastic optimization. SIAM Journal on Optimization, 30(1):960–979, 2020.
|
| 314 |
+
[16] Elad Hazan, Sham Kakade, Karan Singh, and Abby Van Soest. Provably efficient maximum entropy exploration. In International Conference on Machine Learning, pages 2681–2691. PMLR, 2019.
|
| 315 |
+
[17] Zhouyuan Huo, Bin Gu, Ji Liu, and Heng Huang. Accelerated method for stochastic composition optimization with nonsmooth regularization. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 32, 2018.
|
| 316 |
+
[18] Sashank J Reddi, Suvrit Sra, Barnabas Poczos, and Alexander J Smola. Proximal stochastic methods for nonsmooth nonconvex finite-sum optimization. Advances in neural information processing systems, 29:1145–1153, 2016.
|
| 317 |
+
[19] Rie Johnson and Tong Zhang. Accelerating stochastic gradient descent using predictive variance reduction. Advances in neural information processing systems, 26:315–323, 2013.
|
| 318 |
+
[20] Sham M Kakade. A natural policy gradient. Advances in neural information processing systems, 14:1531–1538, 2001.
|
| 319 |
+
[21] Vijay R Konda and John N Tsitsiklis. Actor-critic algorithms. In Advances in neural information processing systems, pages 1008–1014, 2000.
|
| 320 |
+
[22] Vijaymohan R Konda and Vivek S Borkar. Actor-critic–type learning algorithms for markov decision processes. SIAM Journal on control and Optimization, 38(1):94–123, 1999.
|
| 321 |
+
[23] Guanghui Lan. Policy mirror descent for reinforcement learning: Linear convergence, new sampling complexity, and generalized problem classes. arXiv preprint arXiv:2102.00135, 2021.
|
| 322 |
+
[24] Xiangru Lian, Mengdi Wang, and Ji Liu. Finite-sum composition optimization via variance reduced gradient descent. In Artificial Intelligence and Statistics, pages 1159–1167. PMLR, 2017.
|
| 323 |
+
[25] Boyi Liu, Qi Cai, Zhuoran Yang, and Zhaoran Wang. Neural trust region/proximal policy optimization attains globally optimal policy. In Advances in Neural Information Processing Systems, pages 10565–10576, 2019.
|
| 324 |
+
[26] Jincheng Mei, Chenjun Xiao, Csaba Szepesvari, and Dale Schuurmans. On the global convergence rates of softmax policy gradient methods. arXiv preprint arXiv:2005.06392, 2020.
|
| 325 |
+
|
| 326 |
+
[27] Sobhan Miryoosefi, Kianté Brantley, Hal Daume III, Miro Dudik, and Robert E Schapire. Reinforcement learning with convex constraints. In Advances in Neural Information Processing Systems, pages 14093–14102, 2019.
|
| 327 |
+
|
| 328 |
+
[28] Volodymyr Mnih, Adria Puigdomenech Badia, Mehdi Mirza, Alex Graves, Timothy Lillicrap, Tim Harley, David Silver, and Koray Kavukcuoglu. Asynchronous methods for deep reinforcement learning. In International conference on machine learning, pages 1928–1937, 2016.
|
| 329 |
+
|
| 330 |
+
[29] Lam M Nguyen, Jie Liu, Katya Scheinberg, and Martin Takác. Sarah: A novel method for ˇ machine learning problems using stochastic recursive gradient. arXiv preprint arXiv:1703.00102, 2017.
|
| 331 |
+
|
| 332 |
+
[30] Lam M Nguyen, Marten van Dijk, Dzung T Phan, Phuong Ha Nguyen, Tsui-Wei Weng, and Jayant R Kalagnanam. Finite-sum smooth optimization with sarah. arXiv preprint arXiv:1901.07648, 2019.
|
| 333 |
+
|
| 334 |
+
[31] Matteo Papini, Damiano Binaghi, Giuseppe Canonaco, Matteo Pirotta, and Marcello Restelli. Stochastic variance-reduced policy gradient. arXiv preprint arXiv:1806.05618, 2018.
|
| 335 |
+
|
| 336 |
+
[32] Jan Peters and Stefan Schaal. Natural actor-critic. Neurocomputing, 71(7-9):1180–1190, 2008.
|
| 337 |
+
|
| 338 |
+
[33] Nhan H Pham, Lam M Nguyen, Dzung T Phan, Phuong Ha Nguyen, Marten van Dijk, and Quoc Tran-Dinh. A hybrid stochastic policy gradient algorithm for reinforcement learning. arXiv preprint arXiv:2003.00430, 2020.
|
| 339 |
+
|
| 340 |
+
[34] Sashank J Reddi, Ahmed Hefny, Suvrit Sra, Barnabas Poczos, and Alex Smola. Stochastic variance reduction for nonconvex optimization. In International conference on machine learning, pages 314–323, 2016.
|
| 341 |
+
|
| 342 |
+
[35] Sashank J Reddi, Suvrit Sra, Barnabás Póczos, and Alex Smola. Fast incremental method for nonconvex optimization. arXiv preprint arXiv:1603.06159, 2016.
|
| 343 |
+
|
| 344 |
+
[36] Mark Schmidt, Nicolas Le Roux, and Francis Bach. Minimizing finite sums with the stochastic average gradient. Mathematical Programming, 162(1-2):83–112, 2017.
|
| 345 |
+
|
| 346 |
+
[37] John Schulman, Sergey Levine, Pieter Abbeel, Michael Jordan, and Philipp Moritz. Trust region policy optimization. In International conference on machine learning, pages 1889–1897, 2015.
|
| 347 |
+
|
| 348 |
+
[38] John Schulman, Filip Wolski, Prafulla Dhariwal, Alec Radford, and Oleg Klimov. Proximal policy optimization algorithms. arXiv preprint arXiv:1707.06347, 2017.
|
| 349 |
+
|
| 350 |
+
[39] Lior Shani, Yonathan Efroni, and Shie Mannor. Adaptive trust region policy optimization: Global convergence and faster rates for regularized mdps. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 34, pages 5668–5675, 2020.
|
| 351 |
+
|
| 352 |
+
[40] Zebang Shen, Alejandro Ribeiro, Hamed Hassani, Hui Qian, and Chao Mi. Hessian aided policy gradient. In International Conference on Machine Learning, pages 5729–5738, 2019.
|
| 353 |
+
|
| 354 |
+
[41] Aaron Sidford, Mengdi Wang, Xian Wu, Lin F Yang, and Yinyu Ye. Near-optimal time and sample complexities for solving discounted markov decision process with a generative model. arXiv preprint arXiv:1806.01492, 2018.
|
| 355 |
+
|
| 356 |
+
[42] Aaron Sidford, Mengdi Wang, Xian Wu, and Yinyu Ye. Variance reduced value iteration and faster algorithms for solving markov decision processes. In Proceedings of the Twenty-Ninth Annual ACM-SIAM Symposium on Discrete Algorithms, pages 770–787. SIAM, 2018.
|
| 357 |
+
|
| 358 |
+
[43] Richard S Sutton and Andrew G Barto. Reinforcement learning: An introduction. MIT press, 2018.
|
| 359 |
+
|
| 360 |
+
[44] Richard S Sutton, David A McAllester, Satinder P Singh, and Yishay Mansour. Policy gradient methods for reinforcement learning with function approximation. In Advances in neural information processing systems, pages 1057–1063, 2000.
|
| 361 |
+
|
| 362 |
+
[45] Mengdi Wang, Ethan X Fang, and Han Liu. Stochastic compositional gradient descent: algorithms for minimizing compositions of expected-value functions. Mathematical Programming, 161(1-2):419–449, 2017.
|
| 363 |
+
[46] Mengdi Wang, Ji Liu, and Ethan X Fang. Accelerating stochastic composition optimization. The Journal of Machine Learning Research, 18(1):3721–3743, 2017.
|
| 364 |
+
[47] Ronald J Williams. Simple statistical gradient-following algorithms for connectionist reinforcement learning. Machine learning, 8(3-4):229–256, 1992.
|
| 365 |
+
[48] Pan Xu, Felicia Gao, and Quanquan Gu. Sample efficient policy gradient methods with recursive variance reduction. arXiv preprint arXiv:1909.08610, 2019.
|
| 366 |
+
[49] Pan Xu, Felicia Gao, and Quanquan Gu. An improved convergence analysis of stochastic variance-reduced policy gradient. In Uncertainty in Artificial Intelligence, pages 541–551. PMLR, 2020.
|
| 367 |
+
[50] Junyu Zhang, Amrit Singh Bedi, Mengdi Wang, and Alec Koppel. Cautious reinforcement learning via distributional risk in the dual domain. arXiv preprint arXiv:2002.12475, 2020.
|
| 368 |
+
[51] Junyu Zhang, Alec Koppel, Amrit Singh Bedi, Csaba Szepesvari, and Mengdi Wang. Variational policy gradient method for reinforcement learning with general utilities. arXiv preprint arXiv:2007.02151, 2020.
|
| 369 |
+
[52] Junyu Zhang and Lin Xiao. A composite randomized incremental gradient method. In International Conference on Machine Learning, pages 7454–7462, 2019.
|
| 370 |
+
[53] Junyu Zhang and Lin Xiao. Multi-level composite stochastic optimization via nested variance reduction. arXiv preprint arXiv:1908.11468, 2019.
|
| 371 |
+
[54] Junyu Zhang and Lin Xiao. A stochastic composite gradient method with incremental variance reduction. In Advances in Neural Information Processing Systems, pages 9078–9088, 2019.
|
| 372 |
+
[55] Junzi Zhang, Jongho Kim, Brendan O’Donoghue, and Stephen Boyd. Sample efficient reinforcement learning with reinforce. arXiv preprint arXiv:2010.11364, 2020.
|
| 373 |
+
[56] Kaiqing Zhang, Alec Koppel, Hao Zhu, and Tamer Ba¸sar. Global convergence of policy gradient methods to (almost) locally optimal policies. arXiv preprint arXiv:1906.08383, 2019.
|
| 374 |
+
[57] Mingming Zhao, Yongfeng Li, and Zaiwen Wen. A stochastic trust-region framework for policy optimization. arXiv preprint arXiv:1911.11640, 2019.
|
| 375 |
+
[58] Tingting Zhao, Hirotaka Hachiya, Gang Niu, and Masashi Sugiyama. Analysis and improvement of policy gradient estimation. Neural Networks, 26:118–129, 2012.
|
parse/train/Re_VXFOyyO/Re_VXFOyyO_content_list.json
ADDED
|
@@ -0,0 +1,1701 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
[
|
| 2 |
+
{
|
| 3 |
+
"type": "text",
|
| 4 |
+
"text": "On the Convergence and Sample Efficiency of Variance-Reduced Policy Gradient Method ",
|
| 5 |
+
"text_level": 1,
|
| 6 |
+
"bbox": [
|
| 7 |
+
223,
|
| 8 |
+
122,
|
| 9 |
+
777,
|
| 10 |
+
172
|
| 11 |
+
],
|
| 12 |
+
"page_idx": 0
|
| 13 |
+
},
|
| 14 |
+
{
|
| 15 |
+
"type": "text",
|
| 16 |
+
"text": "Junyu Zhang Department of Industrial Systems Engineering and Management National University of Singapore Singapore, 119077 junyuz@nus.edu.sg ",
|
| 17 |
+
"bbox": [
|
| 18 |
+
287,
|
| 19 |
+
226,
|
| 20 |
+
710,
|
| 21 |
+
296
|
| 22 |
+
],
|
| 23 |
+
"page_idx": 0
|
| 24 |
+
},
|
| 25 |
+
{
|
| 26 |
+
"type": "text",
|
| 27 |
+
"text": "Chengzhuo Ni Department of Electrical and Computer Engineering Princeton University Princeton, NJ, 08544 chengzhuo.ni@princeton.edu ",
|
| 28 |
+
"bbox": [
|
| 29 |
+
326,
|
| 30 |
+
316,
|
| 31 |
+
671,
|
| 32 |
+
386
|
| 33 |
+
],
|
| 34 |
+
"page_idx": 0
|
| 35 |
+
},
|
| 36 |
+
{
|
| 37 |
+
"type": "text",
|
| 38 |
+
"text": "Zheng Yu Department of Electrical and Computer Engineering Princeton University Princeton, NJ, 08544 zhengy@princeton.edu ",
|
| 39 |
+
"bbox": [
|
| 40 |
+
191,
|
| 41 |
+
407,
|
| 42 |
+
534,
|
| 43 |
+
477
|
| 44 |
+
],
|
| 45 |
+
"page_idx": 0
|
| 46 |
+
},
|
| 47 |
+
{
|
| 48 |
+
"type": "text",
|
| 49 |
+
"text": "Csaba Szepesvari Department of Computer Science University of Alberta Edmonton, Alberta, Canada T6G 2E8 szepesva@ualberta.ca ",
|
| 50 |
+
"bbox": [
|
| 51 |
+
557,
|
| 52 |
+
407,
|
| 53 |
+
808,
|
| 54 |
+
477
|
| 55 |
+
],
|
| 56 |
+
"page_idx": 0
|
| 57 |
+
},
|
| 58 |
+
{
|
| 59 |
+
"type": "text",
|
| 60 |
+
"text": "Mengdi Wang Department of Electrical and Computer Engineering Princeton University Princeton, NJ, 08544 mengdiw@princeton.edu ",
|
| 61 |
+
"bbox": [
|
| 62 |
+
326,
|
| 63 |
+
498,
|
| 64 |
+
671,
|
| 65 |
+
568
|
| 66 |
+
],
|
| 67 |
+
"page_idx": 0
|
| 68 |
+
},
|
| 69 |
+
{
|
| 70 |
+
"type": "text",
|
| 71 |
+
"text": "Abstract ",
|
| 72 |
+
"text_level": 1,
|
| 73 |
+
"bbox": [
|
| 74 |
+
462,
|
| 75 |
+
603,
|
| 76 |
+
535,
|
| 77 |
+
619
|
| 78 |
+
],
|
| 79 |
+
"page_idx": 0
|
| 80 |
+
},
|
| 81 |
+
{
|
| 82 |
+
"type": "text",
|
| 83 |
+
"text": "Policy gradient (PG) gives rise to a rich class of reinforcement learning (RL) methods. Recently, there has been an emerging trend to accelerate the existing PG methods such as REINFORCE by the variance reduction techniques. However, all existing variance-reduced PG methods heavily rely on an uncheckable importance weight assumption made for every single iteration of the algorithms. In this paper, a simple gradient truncation mechanism is proposed to address this issue. Moreover, we design a Truncated Stochastic Incremental Variance-Reduced Policy Gradient (TSIVR-PG) method, which is able to maximize not only a cumulative sum of rewards but also a general utility function over a policy’s long-term visiting distribution. We show an $\\tilde { \\mathcal { O } } ( \\epsilon ^ { - 3 } )$ sample complexity for TSIVR-PG to find an $\\epsilon$ -stationary policy. By assuming the overparameterization of policy and exploiting the hidden convexity of the problem, we further show that TSIVR-PG converges to global $\\epsilon$ -optimal policy with $\\tilde { \\mathcal { O } } ( \\epsilon ^ { - 2 } )$ samples. ",
|
| 84 |
+
"bbox": [
|
| 85 |
+
232,
|
| 86 |
+
635,
|
| 87 |
+
766,
|
| 88 |
+
818
|
| 89 |
+
],
|
| 90 |
+
"page_idx": 0
|
| 91 |
+
},
|
| 92 |
+
{
|
| 93 |
+
"type": "text",
|
| 94 |
+
"text": "1 Introduction ",
|
| 95 |
+
"text_level": 1,
|
| 96 |
+
"bbox": [
|
| 97 |
+
174,
|
| 98 |
+
842,
|
| 99 |
+
312,
|
| 100 |
+
859
|
| 101 |
+
],
|
| 102 |
+
"page_idx": 0
|
| 103 |
+
},
|
| 104 |
+
{
|
| 105 |
+
"type": "text",
|
| 106 |
+
"text": "In this paper, we investigate the theoretical properties of Policy Gradient (PG) methods for Reinforcement Learning (RL) [43]. In view of RL as a policy optimization problem, the PG method ",
|
| 107 |
+
"bbox": [
|
| 108 |
+
176,
|
| 109 |
+
873,
|
| 110 |
+
826,
|
| 111 |
+
902
|
| 112 |
+
],
|
| 113 |
+
"page_idx": 0
|
| 114 |
+
},
|
| 115 |
+
{
|
| 116 |
+
"type": "text",
|
| 117 |
+
"text": "parameterizes the policy function and conduct gradient ascent search to improve the policy. In this paper, we consider the soft-max policy parameterization ",
|
| 118 |
+
"bbox": [
|
| 119 |
+
171,
|
| 120 |
+
90,
|
| 121 |
+
825,
|
| 122 |
+
119
|
| 123 |
+
],
|
| 124 |
+
"page_idx": 1
|
| 125 |
+
},
|
| 126 |
+
{
|
| 127 |
+
"type": "equation",
|
| 128 |
+
"img_path": "images/af2cfe8ecff03c1bae333a5da2b66f87c131df0ee49c65eb232a598d2a6f62f7.jpg",
|
| 129 |
+
"text": "$$\n\\pi _ { \\theta } ( a | s ) = \\frac { \\exp \\{ \\psi ( s , a ; \\theta ) \\} } { \\sum _ { a ^ { \\prime } } \\exp \\{ \\psi ( s , a ^ { \\prime } ; \\theta ) \\} }\n$$",
|
| 130 |
+
"text_format": "latex",
|
| 131 |
+
"bbox": [
|
| 132 |
+
388,
|
| 133 |
+
127,
|
| 134 |
+
609,
|
| 135 |
+
162
|
| 136 |
+
],
|
| 137 |
+
"page_idx": 1
|
| 138 |
+
},
|
| 139 |
+
{
|
| 140 |
+
"type": "text",
|
| 141 |
+
"text": "where $( s , a )$ is a state-action pair and $\\psi$ is some smooth function. Potentially, one can set the function $\\psi$ to be some deep neural network with weights $\\theta$ and input $( s , a )$ . The main problem considered in this paper is the policy optimization for a general utility function: ",
|
| 142 |
+
"bbox": [
|
| 143 |
+
173,
|
| 144 |
+
170,
|
| 145 |
+
825,
|
| 146 |
+
212
|
| 147 |
+
],
|
| 148 |
+
"page_idx": 1
|
| 149 |
+
},
|
| 150 |
+
{
|
| 151 |
+
"type": "equation",
|
| 152 |
+
"img_path": "images/93f08575981d3189c51ebe3c59de94e864d2773efb12cdad27f25aefef9d7654.jpg",
|
| 153 |
+
"text": "$$\n\\operatorname* { m a x } _ { \\theta } R ( \\pi _ { \\theta } ) : = F ( \\lambda ^ { \\pi _ { \\theta } } ) ,\n$$",
|
| 154 |
+
"text_format": "latex",
|
| 155 |
+
"bbox": [
|
| 156 |
+
418,
|
| 157 |
+
219,
|
| 158 |
+
578,
|
| 159 |
+
242
|
| 160 |
+
],
|
| 161 |
+
"page_idx": 1
|
| 162 |
+
},
|
| 163 |
+
{
|
| 164 |
+
"type": "text",
|
| 165 |
+
"text": "where $F$ is a general smooth function, and $\\lambda ^ { \\pi _ { \\theta } }$ denotes the unnormalized state-action occupancy measure (also referred to as the visitation measure). For any policy $\\pi$ and initial state distribution $\\xi$ , ",
|
| 166 |
+
"bbox": [
|
| 167 |
+
174,
|
| 168 |
+
250,
|
| 169 |
+
826,
|
| 170 |
+
279
|
| 171 |
+
],
|
| 172 |
+
"page_idx": 1
|
| 173 |
+
},
|
| 174 |
+
{
|
| 175 |
+
"type": "equation",
|
| 176 |
+
"img_path": "images/a6d7622fad1799184da9078a958dee07514c70d8d4f2480dee7f21243ce6122b.jpg",
|
| 177 |
+
"text": "$$\n\\lambda ^ { \\pi } ( s , a ) : = \\sum _ { t = 0 } ^ { + \\infty } \\gamma ^ { t } \\cdot \\mathbb { P } \\Big ( s _ { t } = s , a _ { t } = a \\big | \\pi , s _ { 0 } \\sim \\xi \\Big ) ,\n$$",
|
| 178 |
+
"text_format": "latex",
|
| 179 |
+
"bbox": [
|
| 180 |
+
313,
|
| 181 |
+
286,
|
| 182 |
+
651,
|
| 183 |
+
329
|
| 184 |
+
],
|
| 185 |
+
"page_idx": 1
|
| 186 |
+
},
|
| 187 |
+
{
|
| 188 |
+
"type": "text",
|
| 189 |
+
"text": "where $\\gamma$ stands for the discount factor and $\\mathbb { P }$ denotes the probability of a certain event. When $F$ is linear, the problem reduces to the standard policy optimization problem where the objective is to maximize a cumulative sum of rewards. When $F$ is nonlinear, problem (2) goes beyond standard Markov decision problems: examples include the max-entropy exploration [16], risk-sensitive RL [50], certain set constrained RL [27], and so on. ",
|
| 190 |
+
"bbox": [
|
| 191 |
+
174,
|
| 192 |
+
334,
|
| 193 |
+
825,
|
| 194 |
+
405
|
| 195 |
+
],
|
| 196 |
+
"page_idx": 1
|
| 197 |
+
},
|
| 198 |
+
{
|
| 199 |
+
"type": "text",
|
| 200 |
+
"text": "In the standard cumulative-return case (i.e., $F$ is linear), numerous works have studied PG methods in various scenarios, see e.g. [47, 5, 58, 22, 21, 37, 38, 23]. When directly optimizing over the policy space without any parameterization, the policy mirror descent (PMD) method [23] achieves an $\\bar { \\mathcal { O } } ( \\epsilon ^ { - 2 } )$ sample complexity to find an $\\mathcal { O } ( \\epsilon )$ -optimal solution. However, for the more practical parameterized policy optimization, to the authors’ best knowledge, the most recent variant of PG methods, using the SARAH/Spider stochastic variance reduction technique [13, 29], find a local $\\epsilon$ -stationary policy using $\\mathcal { O } ( \\epsilon ^ { - 3 } )$ samples [48, 33]. This poses a contrast with the known $\\tilde { O } ( \\epsilon ^ { - 2 } )$ sample complexity results that can be achieved by various value-based methods [4, 42, 41] and are provably matching information-theoretic lower bounds [12, 3, 4]. In this paper, we attempt to close this gap and prove an $\\tilde { \\mathcal { O } } ( \\epsilon ^ { - 2 } )$ sample complexity bound for a PG method. Most importantly, when it comes to PG estimation, the application of the variance reduction technique typically relies on certain off-policy PG estimator, resulting in the difficulty of distribution shift. We notice that none of the existing variance-reduced PG methods attempt to address this challenge. Instead, they directly make an uncheckable assumption that the variance of the importance weight is bounded for every policy pair encountered in running the algorithm, see e.g. [31, 48, 49, 33]. In this paper, we propose a simple gradient truncation mechanism to fix this issue. ",
|
| 201 |
+
"bbox": [
|
| 202 |
+
173,
|
| 203 |
+
411,
|
| 204 |
+
825,
|
| 205 |
+
638
|
| 206 |
+
],
|
| 207 |
+
"page_idx": 1
|
| 208 |
+
},
|
| 209 |
+
{
|
| 210 |
+
"type": "text",
|
| 211 |
+
"text": "Next, let us go beyond cumulative return and consider policy optimization for a general utility where $F$ may be nonlinear. However, much less is known in this setting. The nonlinearity of $F$ invalidates the concept of Q-function and value function, leading to the failure of policy gradient theorem [44]. To overcome such difficulty, [51] showed that the policy gradient for the general utilities is the solution to a min-max problem. However, estimating a single PG is highly nontrivial in this case. It is still unclear how to make PG methods to use samples in a most efficient way. ",
|
| 212 |
+
"bbox": [
|
| 213 |
+
174,
|
| 214 |
+
643,
|
| 215 |
+
825,
|
| 216 |
+
728
|
| 217 |
+
],
|
| 218 |
+
"page_idx": 1
|
| 219 |
+
},
|
| 220 |
+
{
|
| 221 |
+
"type": "text",
|
| 222 |
+
"text": "In this paper, we aim to investigate the convergence and sample efficiency of the PG method, using episodic sampling, for both linear $F$ (i.e., cumulative rewards) and nonlinear $F$ (i.e., general utility). Observe that problem (2) is an instance of the Stochastic Composite Optimization (SCO) problem [45, 46]: $\\mathrm { m i n } _ { x } ^ { - } f ( \\mathbb { E } _ { \\nu } [ g _ { \\nu } ( x ) ] )$ , which involves an inner expectation that corresponds to the occupancy measure $\\lambda ^ { \\pi }$ . Motivated by this view point, we attempt to develop stochastic policy gradient method with provable finite-sample efficiency bounds. ",
|
| 223 |
+
"bbox": [
|
| 224 |
+
174,
|
| 225 |
+
733,
|
| 226 |
+
825,
|
| 227 |
+
818
|
| 228 |
+
],
|
| 229 |
+
"page_idx": 1
|
| 230 |
+
},
|
| 231 |
+
{
|
| 232 |
+
"type": "text",
|
| 233 |
+
"text": "Main results. Our main results are summarized below. ",
|
| 234 |
+
"bbox": [
|
| 235 |
+
174,
|
| 236 |
+
823,
|
| 237 |
+
534,
|
| 238 |
+
838
|
| 239 |
+
],
|
| 240 |
+
"page_idx": 1
|
| 241 |
+
},
|
| 242 |
+
{
|
| 243 |
+
"type": "text",
|
| 244 |
+
"text": "• We propose the TSIVR-PG algorithm to solve problem (2) via episodic sampling. It provides a conceptually simple stochastic gradient approach for solving general utility RL. • We provide a gradient truncation mechanism to address the distribution shift difficulty in variance-reduced PG methods. Such difficulty has never been addressed in previous works. ",
|
| 245 |
+
"bbox": [
|
| 246 |
+
214,
|
| 247 |
+
849,
|
| 248 |
+
826,
|
| 249 |
+
911
|
| 250 |
+
],
|
| 251 |
+
"page_idx": 1
|
| 252 |
+
},
|
| 253 |
+
{
|
| 254 |
+
"type": "text",
|
| 255 |
+
"text": "• We show that TSIVR-PG finds an $\\epsilon$ -stationary policy using $\\tilde { O } ( \\epsilon ^ { - 3 } )$ samples if $F$ and $\\psi$ are general smooth functions. When $F$ is concave and $\\psi$ satisfies certain overparameterization condition, we show that TSIVR-PG obtains a gloal $\\epsilon$ -optimal policy using $\\bar { O } ( \\epsilon ^ { - 2 } )$ samples. ",
|
| 256 |
+
"bbox": [
|
| 257 |
+
217,
|
| 258 |
+
90,
|
| 259 |
+
823,
|
| 260 |
+
135
|
| 261 |
+
],
|
| 262 |
+
"page_idx": 2
|
| 263 |
+
},
|
| 264 |
+
{
|
| 265 |
+
"type": "text",
|
| 266 |
+
"text": "Technical contribution. Our analysis technique is also of independent interest in the relating areas. ",
|
| 267 |
+
"bbox": [
|
| 268 |
+
171,
|
| 269 |
+
146,
|
| 270 |
+
821,
|
| 271 |
+
161
|
| 272 |
+
],
|
| 273 |
+
"page_idx": 2
|
| 274 |
+
},
|
| 275 |
+
{
|
| 276 |
+
"type": "text",
|
| 277 |
+
"text": "• For stochastic composite optimization (SCO), most existing algorithms require estimating the Jacobian matrix of the inner mapping, which corresponds to $\\nabla _ { \\boldsymbol { \\theta } } \\lambda ^ { \\pi _ { \\boldsymbol { \\theta } } }$ in our setting. This is in practice prohibitive if the Jacobian matrix has high dimensions, which is exactly the case in our problem. Unlike SCO algorithms such as [24, 54, 53, etc.], our analysis enables us to avoid the Jacobian matrix estimation. \nFor the stochastic variance-reduced gradient methods, our analysis implies a convergence of SARAH/Spider methods to global optimality and a new $\\mathcal { O } ( \\epsilon ^ { - 2 } )$ sample complexity for nonconvex problems with “hidden convexity” structure, which has not been studied in the optimization community yet. ",
|
| 278 |
+
"bbox": [
|
| 279 |
+
215,
|
| 280 |
+
172,
|
| 281 |
+
825,
|
| 282 |
+
305
|
| 283 |
+
],
|
| 284 |
+
"page_idx": 2
|
| 285 |
+
},
|
| 286 |
+
{
|
| 287 |
+
"type": "text",
|
| 288 |
+
"text": "2 Related Works ",
|
| 289 |
+
"text_level": 1,
|
| 290 |
+
"bbox": [
|
| 291 |
+
174,
|
| 292 |
+
325,
|
| 293 |
+
330,
|
| 294 |
+
343
|
| 295 |
+
],
|
| 296 |
+
"page_idx": 2
|
| 297 |
+
},
|
| 298 |
+
{
|
| 299 |
+
"type": "text",
|
| 300 |
+
"text": "Policy gradient gives rises to a rich family of RL algorithms, such as REINFORCE and many of its variants [47, 5, 58], as well as extensions such as the natural policy gradient methods [20, 32], the actor-critic methods [22, 21, 28], the trust-region policy optimization [37, 57, 39], and the proximal policy optimization method [38, 25], etc. In this paper we mainly focus on REINFORCE-type methods, where many of them need $\\tilde { \\mathcal { O } } ( \\epsilon ^ { - 4 } )$ samples to find an $\\epsilon$ -stationary solution, including the vanilla REINFORCE [47], as well as its variants with baseline [58, 43] and GPOMDP [5], etc. By incorporating the stochastic variance reduction techniques, the sample efficiency of PG methods can be further improved. In [31], the SVRG [19] variance reduction scheme is adopted and an $\\mathcal { O } ( \\epsilon ^ { - 4 } )$ sample complexity is achieved, which is later improved to $\\mathcal { O } ( \\epsilon ^ { - 1 0 / 3 } )$ by [48]. With additional Hessian information, [40] achieved an $\\mathcal { O } ( \\epsilon ^ { - 3 } )$ complexity. By utilizing a more efficient SARAH/Spider [29, 13] variance reduction scheme, people are able to achieve $\\mathcal { O } ( \\epsilon ^ { - 3 } )$ sample complexity without second-order information [48, 33]. We would like to comment that these results are only for finding $\\epsilon$ -stationary (rather than near-optimal) solutions, and all of them requires an uncheckable condition on the importance weights in every iteration. ",
|
| 301 |
+
"bbox": [
|
| 302 |
+
173,
|
| 303 |
+
358,
|
| 304 |
+
825,
|
| 305 |
+
554
|
| 306 |
+
],
|
| 307 |
+
"page_idx": 2
|
| 308 |
+
},
|
| 309 |
+
{
|
| 310 |
+
"type": "text",
|
| 311 |
+
"text": "Recently, for cumulative reward, a series of works have started to study the convergence of policy gradient method to global optimal solutions [1, 14, 56, 6, 26, 7, 9, 55]. In particular, [51] exploited the hidden convexity property of the MDP problem and established the convergence to global optimality for general utility RL problem, as long as the policy gradient can be computed exactly. ",
|
| 312 |
+
"bbox": [
|
| 313 |
+
174,
|
| 314 |
+
560,
|
| 315 |
+
825,
|
| 316 |
+
617
|
| 317 |
+
],
|
| 318 |
+
"page_idx": 2
|
| 319 |
+
},
|
| 320 |
+
{
|
| 321 |
+
"type": "text",
|
| 322 |
+
"text": "Our approach is related to the stochastic composite optimization (SCO) [45, 46]. For the general composition problem, there have been numerous developments, including momentum-based and multi-time-scale algorithms [45, 46, 15], and various composite stochastic variance-reduced algorithms [24, 17, 52, 54]. Our approach is also inspired by variance reduction techniques that were initially used for stochastic convex optimization, see [19, 36, 11, 29]; and were later on extended to the stochastic nonconvex optimization problems [2, 34, 18, 35, 13, 30]. In particular, we will utilize the SARAH/Spider scheme [13, 30]. ",
|
| 323 |
+
"bbox": [
|
| 324 |
+
174,
|
| 325 |
+
622,
|
| 326 |
+
825,
|
| 327 |
+
720
|
| 328 |
+
],
|
| 329 |
+
"page_idx": 2
|
| 330 |
+
},
|
| 331 |
+
{
|
| 332 |
+
"type": "text",
|
| 333 |
+
"text": "3 Problem Formulation ",
|
| 334 |
+
"text_level": 1,
|
| 335 |
+
"bbox": [
|
| 336 |
+
174,
|
| 337 |
+
741,
|
| 338 |
+
387,
|
| 339 |
+
758
|
| 340 |
+
],
|
| 341 |
+
"page_idx": 2
|
| 342 |
+
},
|
| 343 |
+
{
|
| 344 |
+
"type": "text",
|
| 345 |
+
"text": "Consider an MDP with a general utility function, denoted as $\\mathbf { M D P } ( S , { \\mathcal { A } } , { \\mathcal { P } } , \\gamma , F )$ , where $s$ is a finite state space, $\\mathcal { A }$ is a finite action space, $\\gamma \\in ( 0 , 1 )$ is a discount factor, and $F$ is some general utility function. For each state $s \\in S$ , a transition to state $s ^ { \\prime } \\in \\varDelta$ occurs when selecting an action $a \\in { \\mathcal { A } }$ following the distribution $\\textstyle { \\mathcal { P } } ( \\cdot | a , s )$ . For each state $s \\in S$ , a policy $\\pi$ gives a distribution $\\pi ( \\cdot | s )$ over the action space $\\mathcal { A }$ . Let $\\xi$ be the initial state distribution and let the unnormalized state-action occupancy measure $\\lambda ^ { \\pi }$ be defined by (3), we define the general utility function $F$ as a smooth function of the occupancy measure, and the goal of the general utility MDP is to maximize $F ( \\lambda ^ { \\pi } )$ . With the policy $\\pi _ { \\theta }$ being parameterized by (1), we propose to solve problem (2), which is ",
|
| 346 |
+
"bbox": [
|
| 347 |
+
173,
|
| 348 |
+
772,
|
| 349 |
+
826,
|
| 350 |
+
885
|
| 351 |
+
],
|
| 352 |
+
"page_idx": 2
|
| 353 |
+
},
|
| 354 |
+
{
|
| 355 |
+
"type": "equation",
|
| 356 |
+
"img_path": "images/cfd909e68ee6c05f18984503333ea28a827a0c0dadc785f4295c2ae671f6505b.jpg",
|
| 357 |
+
"text": "$$\n\\operatorname* { m a x } _ { \\theta } R ( \\pi _ { \\theta } ) : = F \\left( \\lambda ^ { \\pi _ { \\theta } } \\right) .\n$$",
|
| 358 |
+
"text_format": "latex",
|
| 359 |
+
"bbox": [
|
| 360 |
+
415,
|
| 361 |
+
892,
|
| 362 |
+
581,
|
| 363 |
+
915
|
| 364 |
+
],
|
| 365 |
+
"page_idx": 2
|
| 366 |
+
},
|
| 367 |
+
{
|
| 368 |
+
"type": "text",
|
| 369 |
+
"text": "For notational convenience, we often write $\\lambda ( \\theta )$ instead of $\\lambda ^ { \\pi _ { \\theta } }$ . Such utility function is very general and includes many important problems in RL. We provide a few examples where $F$ are concave. ",
|
| 370 |
+
"bbox": [
|
| 371 |
+
173,
|
| 372 |
+
90,
|
| 373 |
+
823,
|
| 374 |
+
119
|
| 375 |
+
],
|
| 376 |
+
"page_idx": 3
|
| 377 |
+
},
|
| 378 |
+
{
|
| 379 |
+
"type": "text",
|
| 380 |
+
"text": "Example 3.1 (Cumulative reward). When $F \\left( \\lambda ^ { \\pi _ { \\theta } } \\right) = \\left. r , \\lambda ^ { \\pi _ { \\theta } } \\right.$ , for some $r \\in \\mathbb { R } ^ { | S | | \\mathcal { A } | }$ . Then we recover the standard cumulative sum of rewards: $\\begin{array} { r } { R ( \\pi _ { \\theta } ) = \\mathbb { E } \\big [ \\sum _ { t = 0 } ^ { + \\infty } \\gamma ^ { t } \\cdot r ( s _ { t } , a _ { t } ) \\big | \\pi _ { \\theta } , s _ { 0 } \\sim \\xi \\big ] } \\end{array}$ . ",
|
| 381 |
+
"bbox": [
|
| 382 |
+
173,
|
| 383 |
+
123,
|
| 384 |
+
823,
|
| 385 |
+
157
|
| 386 |
+
],
|
| 387 |
+
"page_idx": 3
|
| 388 |
+
},
|
| 389 |
+
{
|
| 390 |
+
"type": "text",
|
| 391 |
+
"text": "Example 3.2 (Maximal entropy exploration). Let $\\begin{array} { r } { \\mu ^ { \\pi _ { \\theta } } ( s ) = ( 1 - \\gamma ) \\sum _ { a } \\lambda ^ { \\pi _ { \\theta } } ( s , a ) } \\end{array}$ , $\\forall s \\in S$ be the state occupancy measure, which is the margin of $\\lambda ^ { \\pi _ { \\theta } }$ over $s$ . Let $F ( \\cdot )$ be the entropy function, then we recover the objective for maximal entropy exploration $\\begin{array} { r } { \\left[ { I 6 } \\right] : R ( \\pi _ { \\theta } ) = - \\sum _ { s \\in \\mathcal { S } } \\mu ^ { \\bar { \\pi _ { \\theta } } } ( s ) \\log \\mu ^ { \\pi _ { \\theta } } ( s ) } \\end{array}$ . ",
|
| 392 |
+
"bbox": [
|
| 393 |
+
173,
|
| 394 |
+
160,
|
| 395 |
+
826,
|
| 396 |
+
204
|
| 397 |
+
],
|
| 398 |
+
"page_idx": 3
|
| 399 |
+
},
|
| 400 |
+
{
|
| 401 |
+
"type": "text",
|
| 402 |
+
"text": "Example 3.3 (RL with Set Constraint). Let $\\mathbf { z } ( s _ { t } , a _ { t } ) \\in \\mathbb { R } ^ { d }$ be a vector feedback received in each step. The cumulative feedback is $\\begin{array} { r } { \\mathbf { u } ( \\pi _ { \\theta } ) : = \\mathbb { E } \\big [ \\sum _ { t = 0 } ^ { + \\infty } \\gamma ^ { t } \\cdot \\mathbf { z } ( s _ { t } , a _ { t } ) | s _ { 0 } \\sim \\xi , \\pi _ { \\theta } \\big ] = M \\lambda ^ { \\pi _ { \\theta } } } \\end{array}$ for some matrix $M \\in \\mathbb { R } ^ { d \\times | S | | A | }$ . [27] proposed a set-constrained RL problem which aims to find a policy $\\pi$ s.t. $u ( \\pi ) \\in U$ for some convex set $U$ . This problem can be formulated as an instance of (2) by letting $F ( \\cdot )$ be the negative squared distance: $\\begin{array} { r } { R ( \\pi _ { \\theta } ) = - \\operatorname* { m i n } _ { \\mathbf { u } ^ { \\prime } \\in U } \\| \\mathbf { u } ^ { \\prime } - \\mathbf { u } ( \\pi _ { \\theta } ) \\| ^ { 2 } } \\end{array}$ . ",
|
| 403 |
+
"bbox": [
|
| 404 |
+
173,
|
| 405 |
+
208,
|
| 406 |
+
825,
|
| 407 |
+
286
|
| 408 |
+
],
|
| 409 |
+
"page_idx": 3
|
| 410 |
+
},
|
| 411 |
+
{
|
| 412 |
+
"type": "text",
|
| 413 |
+
"text": "4 The TSIVR-PG Algorithm ",
|
| 414 |
+
"text_level": 1,
|
| 415 |
+
"bbox": [
|
| 416 |
+
174,
|
| 417 |
+
303,
|
| 418 |
+
428,
|
| 419 |
+
321
|
| 420 |
+
],
|
| 421 |
+
"page_idx": 3
|
| 422 |
+
},
|
| 423 |
+
{
|
| 424 |
+
"type": "text",
|
| 425 |
+
"text": "In this section, we propose a Truncated Stochastic Incremental Variance-Reduced Policy Gradient (TSIVR-PG) method, which is inspired by techniques of variance reduction and off-policy estimation. A gradient truncation mechanism is proposed to provably control the importance weights in off-policy sampling. ",
|
| 426 |
+
"bbox": [
|
| 427 |
+
173,
|
| 428 |
+
334,
|
| 429 |
+
826,
|
| 430 |
+
392
|
| 431 |
+
],
|
| 432 |
+
"page_idx": 3
|
| 433 |
+
},
|
| 434 |
+
{
|
| 435 |
+
"type": "text",
|
| 436 |
+
"text": "4.1 Off-Policy PG Estimation ",
|
| 437 |
+
"text_level": 1,
|
| 438 |
+
"bbox": [
|
| 439 |
+
174,
|
| 440 |
+
406,
|
| 441 |
+
392,
|
| 442 |
+
421
|
| 443 |
+
],
|
| 444 |
+
"page_idx": 3
|
| 445 |
+
},
|
| 446 |
+
{
|
| 447 |
+
"type": "text",
|
| 448 |
+
"text": "Policy Gradient First, let us derive the policy gradient of the general utility. Let $V ^ { \\pi _ { \\theta } } ( r )$ be the cumulative reward under policy $\\pi _ { \\theta }$ , initial distribution $\\xi$ and reward function $r$ . By Example 3.1, $V ^ { \\pi _ { \\theta } } ( r ) = \\langle \\lambda ( \\theta ) , r \\rangle$ , the chain rule and policy gradient theorem [44] indicates that ",
|
| 449 |
+
"bbox": [
|
| 450 |
+
173,
|
| 451 |
+
431,
|
| 452 |
+
825,
|
| 453 |
+
476
|
| 454 |
+
],
|
| 455 |
+
"page_idx": 3
|
| 456 |
+
},
|
| 457 |
+
{
|
| 458 |
+
"type": "equation",
|
| 459 |
+
"img_path": "images/94e7559e28be61b03d5a13759b16ae39bcce62a0c633b2a9cc0e0b381298d008.jpg",
|
| 460 |
+
"text": "$$\n\\nabla _ { \\theta } V ^ { \\pi _ { \\theta } } ( r ) = \\left[ \\nabla _ { \\theta } \\lambda ( \\theta ) \\right] ^ { \\top } r = \\mathbb { E } _ { \\xi , \\pi _ { \\theta } } \\Big [ \\sum _ { t = 0 } ^ { + \\infty } \\gamma ^ { t } \\cdot r ( s _ { t } , a _ { t } ) \\cdot \\Big ( \\sum _ { t ^ { \\prime } = 0 } ^ { t } \\nabla _ { \\theta } \\log \\pi _ { \\theta } ( a _ { t ^ { \\prime } } | s _ { t ^ { \\prime } } ) \\Big ) \\Big ] ,\n$$",
|
| 461 |
+
"text_format": "latex",
|
| 462 |
+
"bbox": [
|
| 463 |
+
207,
|
| 464 |
+
481,
|
| 465 |
+
756,
|
| 466 |
+
523
|
| 467 |
+
],
|
| 468 |
+
"page_idx": 3
|
| 469 |
+
},
|
| 470 |
+
{
|
| 471 |
+
"type": "text",
|
| 472 |
+
"text": "where $\\nabla _ { \\boldsymbol { \\theta } } \\lambda ( \\boldsymbol { \\theta } )$ is the Jacobian matrix of the vector mapping $\\lambda ( \\theta )$ . That is, policy gradient theorem actually provides a way for computing the Jacobian-vector product for the occupancy measure. Following the above observation and the chain rule, we have ",
|
| 473 |
+
"bbox": [
|
| 474 |
+
174,
|
| 475 |
+
530,
|
| 476 |
+
823,
|
| 477 |
+
571
|
| 478 |
+
],
|
| 479 |
+
"page_idx": 3
|
| 480 |
+
},
|
| 481 |
+
{
|
| 482 |
+
"type": "equation",
|
| 483 |
+
"img_path": "images/e1b831b8f6b9bc60368ede5034530d1bf7ab5a3f10cf3356cc22a8e7a5cbac59.jpg",
|
| 484 |
+
"text": "$$\n\\nabla _ { \\boldsymbol { \\theta } } R ( \\pi _ { \\boldsymbol { \\theta } } ) = \\left[ \\nabla _ { \\boldsymbol { \\theta } } \\lambda ( \\boldsymbol { \\theta } ) \\right] ^ { \\top } \\nabla _ { \\lambda } F ( \\lambda ( \\boldsymbol { \\theta } ) ) = \\nabla _ { \\boldsymbol { \\theta } } V ^ { \\pi _ { \\boldsymbol { \\theta } } } ( r ) \\vert _ { r = \\nabla _ { \\lambda } F ( \\lambda ( \\boldsymbol { \\theta } ) ) } .\n$$",
|
| 485 |
+
"text_format": "latex",
|
| 486 |
+
"bbox": [
|
| 487 |
+
295,
|
| 488 |
+
578,
|
| 489 |
+
700,
|
| 490 |
+
599
|
| 491 |
+
],
|
| 492 |
+
"page_idx": 3
|
| 493 |
+
},
|
| 494 |
+
{
|
| 495 |
+
"type": "text",
|
| 496 |
+
"text": "Therefore, we can estimate the policy gradient using the typical REINFORCE as long as we pick the “quasi-reward function\" as $r : = \\nabla _ { \\lambda } F ( \\lambda ( \\theta ) )$ . To find this quasi-reward, we need to estimate the state-action occupancy measure $\\lambda ( \\theta )$ (unless $F$ is linear). ",
|
| 497 |
+
"bbox": [
|
| 498 |
+
173,
|
| 499 |
+
604,
|
| 500 |
+
823,
|
| 501 |
+
647
|
| 502 |
+
],
|
| 503 |
+
"page_idx": 3
|
| 504 |
+
},
|
| 505 |
+
{
|
| 506 |
+
"type": "text",
|
| 507 |
+
"text": "Importance Sampling Weight Let $\\tau = \\left\\{ s _ { 0 } , a _ { 0 } , s _ { 1 } , a _ { 1 } , \\cdot \\cdot \\cdot , s _ { H - 1 } , a _ { H - 1 } \\right\\}$ be a length- $H$ trajectory generated under the initial distribution $\\xi$ and the behavioral policy $\\pi _ { \\theta _ { 1 } }$ . For any target policy $\\pi _ { \\boldsymbol { \\theta } _ { 2 } }$ , we define the importance sampling weight as ",
|
| 508 |
+
"bbox": [
|
| 509 |
+
173,
|
| 510 |
+
652,
|
| 511 |
+
821,
|
| 512 |
+
694
|
| 513 |
+
],
|
| 514 |
+
"page_idx": 3
|
| 515 |
+
},
|
| 516 |
+
{
|
| 517 |
+
"type": "equation",
|
| 518 |
+
"img_path": "images/2f2dca9d68e5ed93f6f7d11c0650855bac0dac8a9f37c1ff9e7776ad7fcfa49d.jpg",
|
| 519 |
+
"text": "$$\n\\omega _ { t } ( \\tau | \\theta _ { 1 } , \\theta _ { 2 } ) = \\frac { \\Pi _ { h = 0 } ^ { t } \\pi _ { \\theta _ { 2 } } ( a _ { h } | s _ { h } ) } { \\Pi _ { t = 0 } ^ { h } \\pi _ { \\theta _ { 1 } } ( a _ { h } | s _ { h } ) } , \\qquad 0 \\le t \\le H - 1 .\n$$",
|
| 520 |
+
"text_format": "latex",
|
| 521 |
+
"bbox": [
|
| 522 |
+
302,
|
| 523 |
+
700,
|
| 524 |
+
665,
|
| 525 |
+
736
|
| 526 |
+
],
|
| 527 |
+
"page_idx": 3
|
| 528 |
+
},
|
| 529 |
+
{
|
| 530 |
+
"type": "text",
|
| 531 |
+
"text": "It is worth noting that such importance sampling weight is inevitable in the stochastic variance reduced policy gradient methods, see [31, 48, 49, 33, 25]. In these works, the authors usually directly assume $\\mathrm { \\bar { V a r } } ( \\bar { \\omega _ { H - 1 } } ( \\tau | \\theta _ { 1 } , \\theta _ { 2 } ) ) \\leq W$ for all the policy pairs encountered in every iteration of their algorithms. However, such assumption is too strong and is uncheckable. ",
|
| 532 |
+
"bbox": [
|
| 533 |
+
173,
|
| 534 |
+
741,
|
| 535 |
+
825,
|
| 536 |
+
797
|
| 537 |
+
],
|
| 538 |
+
"page_idx": 3
|
| 539 |
+
},
|
| 540 |
+
{
|
| 541 |
+
"type": "text",
|
| 542 |
+
"text": "Based on the above notation of behavioral and target policies, as long as the importance sampling weights, we present the following off-policy occupancy and policy gradient estimators. ",
|
| 543 |
+
"bbox": [
|
| 544 |
+
173,
|
| 545 |
+
803,
|
| 546 |
+
823,
|
| 547 |
+
833
|
| 548 |
+
],
|
| 549 |
+
"page_idx": 3
|
| 550 |
+
},
|
| 551 |
+
{
|
| 552 |
+
"type": "text",
|
| 553 |
+
"text": "Off-Policy Occupancy Measure Estimator Denote $\\mathbf { e } _ { s a }$ the vector with $( s , a )$ -th entry being 1 while other entries being 0. We define the following estimator for $\\lambda ( \\theta _ { 2 } )$ ",
|
| 554 |
+
"bbox": [
|
| 555 |
+
173,
|
| 556 |
+
837,
|
| 557 |
+
823,
|
| 558 |
+
867
|
| 559 |
+
],
|
| 560 |
+
"page_idx": 3
|
| 561 |
+
},
|
| 562 |
+
{
|
| 563 |
+
"type": "equation",
|
| 564 |
+
"img_path": "images/889d85bbd47f54eea15371ebb06b2fa2de2e65dc9cb3f5557f14f8bfff7b68e7.jpg",
|
| 565 |
+
"text": "$$\n\\widehat { \\lambda } _ { \\omega } ( \\tau | \\theta _ { 1 } , \\theta _ { 2 } ) : = \\sum _ { t = 0 } ^ { H - 1 } \\gamma ^ { t } \\cdot \\omega _ { t } ( \\tau | \\theta _ { 1 } , \\theta _ { 2 } ) \\cdot \\mathbf { e } _ { s _ { t } a _ { t } } .\n$$",
|
| 566 |
+
"text_format": "latex",
|
| 567 |
+
"bbox": [
|
| 568 |
+
331,
|
| 569 |
+
872,
|
| 570 |
+
632,
|
| 571 |
+
916
|
| 572 |
+
],
|
| 573 |
+
"page_idx": 3
|
| 574 |
+
},
|
| 575 |
+
{
|
| 576 |
+
"type": "text",
|
| 577 |
+
"text": "When $\\theta _ { 2 } = \\theta _ { 1 }$ , $\\omega _ { t } ( \\tau | \\theta _ { 1 } , \\theta _ { 2 } ) \\equiv 1$ and $\\widehat { \\lambda } _ { \\omega } ( \\tau | \\theta _ { 1 } , \\theta _ { 2 } )$ becomes the on-policy (discounted) empirical distribution, for which we use the simplified notion $\\widehat { \\lambda } ( \\tau | \\theta _ { 2 } ) : = \\widehat { \\lambda } _ { \\omega } ( \\tau | \\mathbf { \\bar { \\theta } } _ { 2 } , \\mathbf { \\bar { \\theta } } _ { 2 } )$ . ",
|
| 578 |
+
"bbox": [
|
| 579 |
+
174,
|
| 580 |
+
88,
|
| 581 |
+
826,
|
| 582 |
+
125
|
| 583 |
+
],
|
| 584 |
+
"page_idx": 4
|
| 585 |
+
},
|
| 586 |
+
{
|
| 587 |
+
"type": "text",
|
| 588 |
+
"text": "Off-Policy Policy Gradient Estimator Let $r \\in \\mathbb { R } ^ { | S | | A | }$ be any quasi-reward vector. We aim to estimate the Jacobian-vector product $[ \\nabla _ { \\boldsymbol { \\theta } } \\lambda ( \\boldsymbol { \\theta } _ { 2 } ) ] ^ { \\top } r$ for target policy $\\pi _ { \\theta _ { 2 } }$ by ",
|
| 589 |
+
"bbox": [
|
| 590 |
+
171,
|
| 591 |
+
128,
|
| 592 |
+
825,
|
| 593 |
+
160
|
| 594 |
+
],
|
| 595 |
+
"page_idx": 4
|
| 596 |
+
},
|
| 597 |
+
{
|
| 598 |
+
"type": "equation",
|
| 599 |
+
"img_path": "images/752626da31a5d9dd2acb1ef79102dfad58e59066818053039ef406e44a174f85.jpg",
|
| 600 |
+
"text": "$$\n\\widehat { g } _ { \\omega } ( \\tau | \\theta _ { 1 } , \\theta _ { 2 } , r ) : = \\sum _ { t = 0 } ^ { H - 1 } \\gamma ^ { t } \\cdot \\omega _ { t } ( \\tau | \\theta _ { 1 } , \\theta _ { 2 } ) \\cdot r ( s _ { t } , a _ { t } ) \\cdot \\Big ( \\sum _ { t ^ { \\prime } = 0 } ^ { t } \\nabla _ { \\theta } \\log \\pi _ { \\theta _ { 2 } } ( a _ { t ^ { \\prime } } | s _ { t ^ { \\prime } } ) \\Big ) .\n$$",
|
| 601 |
+
"text_format": "latex",
|
| 602 |
+
"bbox": [
|
| 603 |
+
236,
|
| 604 |
+
167,
|
| 605 |
+
759,
|
| 606 |
+
212
|
| 607 |
+
],
|
| 608 |
+
"page_idx": 4
|
| 609 |
+
},
|
| 610 |
+
{
|
| 611 |
+
"type": "text",
|
| 612 |
+
"text": "When $\\theta _ { 2 } = \\theta _ { 1 }$ , $\\omega _ { t } ( \\tau | \\theta _ { 1 } , \\theta _ { 2 } ) \\equiv 1$ and $\\widehat { g } _ { \\omega } ( \\tau | \\theta _ { 1 } , \\theta _ { 2 } , r )$ becomes the on-policy REINFORCE estimator with quasi-reward function $r$ b. In this case, we use the simplified notion $\\widehat { g } ( \\tau | \\theta _ { 2 } , r ) : = \\widehat { g } _ { \\omega } ( \\tau | \\theta _ { 2 } , \\theta _ { 2 } , r )$ . Estimators $\\widehat { \\lambda } _ { \\omega } ( \\tau | \\theta _ { 1 } , \\theta _ { 2 } )$ and $\\widehat { g } _ { \\omega } ( \\tau | \\theta _ { 1 } , \\theta _ { 2 } , r )$ are almost unbiased. In details, $\\| \\mathbb { E } _ { \\tau \\sim \\pi _ { \\theta _ { 1 } } } [ \\widehat { \\lambda } _ { \\omega } ( \\tau | \\theta _ { 1 } , \\theta _ { 2 } ) ] -$ $\\lambda ( \\theta _ { 2 } ) \\lVert \\leq \\mathcal { O } ( \\gamma ^ { H } )$ and $\\begin{array} { r } { \\big \\| \\mathbb { E } _ { \\tau \\sim \\pi _ { \\theta _ { 1 } } } \\big [ \\widehat { g } _ { \\omega } ( \\tau | \\theta _ { 1 } , \\theta _ { 2 } , r ) \\big ] - \\big [ \\nabla _ { \\theta } \\lambda ( \\theta _ { 2 } ) \\big ] ^ { \\top } r \\big \\| \\leq \\mathcal { O } ( H \\cdot \\gamma ^ { H } ) } \\end{array}$ ; see details in Appendix 1 bE. Therefore the bias due to truncation is almost negligible if $H$ is properly selected. ",
|
| 613 |
+
"bbox": [
|
| 614 |
+
173,
|
| 615 |
+
219,
|
| 616 |
+
828,
|
| 617 |
+
308
|
| 618 |
+
],
|
| 619 |
+
"page_idx": 4
|
| 620 |
+
},
|
| 621 |
+
{
|
| 622 |
+
"type": "text",
|
| 623 |
+
"text": "4.2 The TSIVR-PG Algorithm ",
|
| 624 |
+
"text_level": 1,
|
| 625 |
+
"bbox": [
|
| 626 |
+
174,
|
| 627 |
+
324,
|
| 628 |
+
398,
|
| 629 |
+
340
|
| 630 |
+
],
|
| 631 |
+
"page_idx": 4
|
| 632 |
+
},
|
| 633 |
+
{
|
| 634 |
+
"type": "text",
|
| 635 |
+
"text": "To achieve the $\\tilde { \\mathcal { O } } ( \\epsilon ^ { - 2 } )$ sample complexity, we propose an epoch-wise algorithm called Truncated Stochastic Incremental Variance-Reduced PG (TSIVR-PG) Algorithm. Let ${ \\bf { \\bar { \\boldsymbol { \\theta } } } } _ { 0 } ^ { i }$ be the starting point of the $i$ -th epoch, TSIVR-PG constructs the estimators for $\\lambda ( \\theta _ { 0 } ^ { i } )$ , quasi-reward $\\nabla _ { \\lambda } F ( \\lambda ( \\theta _ { 0 } ^ { i } ) { \\bar { ) } }$ and the policy gradient $\\nabla _ { \\theta } F ( \\lambda ( \\theta _ { 0 } ^ { i } ) )$ by ",
|
| 636 |
+
"bbox": [
|
| 637 |
+
173,
|
| 638 |
+
352,
|
| 639 |
+
826,
|
| 640 |
+
410
|
| 641 |
+
],
|
| 642 |
+
"page_idx": 4
|
| 643 |
+
},
|
| 644 |
+
{
|
| 645 |
+
"type": "equation",
|
| 646 |
+
"img_path": "images/e9cb399b7e9aebd85707d990c38576350bd33b08aa8d59164135b924519a80ce.jpg",
|
| 647 |
+
"text": "$$\n\\lambda _ { 0 } ^ { i } = \\frac { 1 } { N } \\sum _ { \\tau \\in \\mathcal { N } _ { i } } \\widehat { \\lambda } ( \\tau | \\theta _ { 0 } ^ { i } ) , ~ r _ { 0 } ^ { i } = \\nabla _ { \\lambda } F ( \\lambda _ { 0 } ^ { i } ) ~ \\mathrm { a n d } ~ g _ { 0 } ^ { i } = \\frac { 1 } { N } \\sum _ { \\tau \\in \\mathcal { N } _ { i } } \\widehat { g } ( \\tau | \\theta _ { 0 } ^ { i } , r _ { 0 } ^ { i } ) .\n$$",
|
| 648 |
+
"text_format": "latex",
|
| 649 |
+
"bbox": [
|
| 650 |
+
251,
|
| 651 |
+
416,
|
| 652 |
+
745,
|
| 653 |
+
455
|
| 654 |
+
],
|
| 655 |
+
"page_idx": 4
|
| 656 |
+
},
|
| 657 |
+
{
|
| 658 |
+
"type": "text",
|
| 659 |
+
"text": "where ${ \\mathcal { N } } _ { i }$ is a set of $N$ independent length- $H$ trajectories sampled under $\\pi _ { \\theta _ { 0 } ^ { i } }$ . When $j \\geq 1$ ",
|
| 660 |
+
"bbox": [
|
| 661 |
+
169,
|
| 662 |
+
463,
|
| 663 |
+
767,
|
| 664 |
+
481
|
| 665 |
+
],
|
| 666 |
+
"page_idx": 4
|
| 667 |
+
},
|
| 668 |
+
{
|
| 669 |
+
"type": "equation",
|
| 670 |
+
"img_path": "images/e8befa743bc209f0e87f78cecf0c7aa91b5a931cb7c4b9db651875e0e1564ddd.jpg",
|
| 671 |
+
"text": "$$\n\\lambda _ { j } ^ { i } = \\frac { 1 } { B } \\sum _ { \\tau \\in \\mathscr { B } _ { j } ^ { i } } \\left( \\widehat { \\lambda } ( \\tau | \\theta _ { j } ^ { i } ) - \\widehat { \\lambda } _ { \\omega } ( \\tau | \\theta _ { j } ^ { i } , \\theta _ { j - 1 } ^ { i } ) \\right) + \\lambda _ { j - 1 } ^ { i } , \\qquad r _ { j } ^ { i } = \\nabla _ { \\lambda } F ( \\lambda _ { j } ^ { i } )\n$$",
|
| 672 |
+
"text_format": "latex",
|
| 673 |
+
"bbox": [
|
| 674 |
+
259,
|
| 675 |
+
489,
|
| 676 |
+
738,
|
| 677 |
+
532
|
| 678 |
+
],
|
| 679 |
+
"page_idx": 4
|
| 680 |
+
},
|
| 681 |
+
{
|
| 682 |
+
"type": "equation",
|
| 683 |
+
"img_path": "images/8f31081665338f72bc2bedacb19fa1502eefc426ddd52dc5cb5f8faae00d4653.jpg",
|
| 684 |
+
"text": "$$\ng _ { j } ^ { i } = \\frac { 1 } { B } \\sum _ { \\tau \\in B _ { j } ^ { i } } \\left( \\widehat { g } \\left( \\tau | \\theta _ { j } ^ { i } , r _ { j - 1 } ^ { i } \\right) - \\widehat { g } _ { \\omega } \\left( \\tau | \\theta _ { j } ^ { i } , \\theta _ { j - 1 } ^ { i } , r _ { j - 2 } ^ { i } \\right) \\right) + g _ { j - 1 } ^ { i } ,\n$$",
|
| 685 |
+
"text_format": "latex",
|
| 686 |
+
"bbox": [
|
| 687 |
+
287,
|
| 688 |
+
537,
|
| 689 |
+
709,
|
| 690 |
+
580
|
| 691 |
+
],
|
| 692 |
+
"page_idx": 4
|
| 693 |
+
},
|
| 694 |
+
{
|
| 695 |
+
"type": "text",
|
| 696 |
+
"text": "where $B _ { j } ^ { i }$ is a set of $B$ independent length- $H$ trajectories sampled under $\\pi _ { \\theta _ { j } ^ { i } }$ , and we default $r _ { - 1 } ^ { i } : = r _ { 0 } ^ { i }$ . Specifically, $\\widehat { g } _ { \\omega } ( \\tau | \\theta _ { j } ^ { i } , \\theta _ { j - 1 } ^ { i } , r _ { j - 2 } ^ { i } )$ is used instead of $\\widehat { g } _ { \\omega } ( \\tau | \\theta _ { j } ^ { i } , \\theta _ { j - 1 } ^ { i } , r _ { j - 1 } ^ { i } )$ for independence issue. The b bdetails of the TSIVR-PG algorithm are stated in Algorithm 1. ",
|
| 697 |
+
"bbox": [
|
| 698 |
+
173,
|
| 699 |
+
587,
|
| 700 |
+
826,
|
| 701 |
+
635
|
| 702 |
+
],
|
| 703 |
+
"page_idx": 4
|
| 704 |
+
},
|
| 705 |
+
{
|
| 706 |
+
"type": "text",
|
| 707 |
+
"text": "Algorithm 1: The TSIVR-PG Algorithm ",
|
| 708 |
+
"text_level": 1,
|
| 709 |
+
"bbox": [
|
| 710 |
+
176,
|
| 711 |
+
655,
|
| 712 |
+
444,
|
| 713 |
+
671
|
| 714 |
+
],
|
| 715 |
+
"page_idx": 4
|
| 716 |
+
},
|
| 717 |
+
{
|
| 718 |
+
"type": "image",
|
| 719 |
+
"img_path": "images/a8e423a213ad93b7a19be46310610581722d1489004c901e81e20724fd888475.jpg",
|
| 720 |
+
"image_caption": [],
|
| 721 |
+
"image_footnote": [],
|
| 722 |
+
"bbox": [
|
| 723 |
+
160,
|
| 724 |
+
674,
|
| 725 |
+
807,
|
| 726 |
+
900
|
| 727 |
+
],
|
| 728 |
+
"page_idx": 4
|
| 729 |
+
},
|
| 730 |
+
{
|
| 731 |
+
"type": "text",
|
| 732 |
+
"text": "It is worth noting that the truncated gradient step (11) is equivalent to a trust region subproblem: ",
|
| 733 |
+
"bbox": [
|
| 734 |
+
168,
|
| 735 |
+
90,
|
| 736 |
+
803,
|
| 737 |
+
107
|
| 738 |
+
],
|
| 739 |
+
"page_idx": 5
|
| 740 |
+
},
|
| 741 |
+
{
|
| 742 |
+
"type": "equation",
|
| 743 |
+
"img_path": "images/083863854bb11a8b006147f268f4936b4251c8c13e760da568e576820e818ef3.jpg",
|
| 744 |
+
"text": "$$\n\\theta _ { j + 1 } ^ { i } = \\underset { \\| \\theta - \\theta _ { j } ^ { i } \\| \\leq \\delta } { \\operatorname { a r g m a x } } ~ { F } ( \\lambda ( \\theta _ { j } ^ { i } ) ) + \\langle g _ { j } ^ { i } , \\theta - \\theta _ { j } ^ { i } \\rangle + \\frac { 1 } { 2 \\eta } \\| \\theta - \\theta _ { j } ^ { i } \\| ^ { 2 }\n$$",
|
| 745 |
+
"text_format": "latex",
|
| 746 |
+
"bbox": [
|
| 747 |
+
307,
|
| 748 |
+
112,
|
| 749 |
+
691,
|
| 750 |
+
150
|
| 751 |
+
],
|
| 752 |
+
"page_idx": 5
|
| 753 |
+
},
|
| 754 |
+
{
|
| 755 |
+
"type": "text",
|
| 756 |
+
"text": "where the approximate Hessian matrix is simply chosen as $( \\eta ) ^ { - 1 } \\cdot I$ . ",
|
| 757 |
+
"bbox": [
|
| 758 |
+
173,
|
| 759 |
+
156,
|
| 760 |
+
625,
|
| 761 |
+
172
|
| 762 |
+
],
|
| 763 |
+
"page_idx": 5
|
| 764 |
+
},
|
| 765 |
+
{
|
| 766 |
+
"type": "text",
|
| 767 |
+
"text": "5 Sample Efficiency of TSIVR-PG ",
|
| 768 |
+
"text_level": 1,
|
| 769 |
+
"bbox": [
|
| 770 |
+
173,
|
| 771 |
+
190,
|
| 772 |
+
475,
|
| 773 |
+
208
|
| 774 |
+
],
|
| 775 |
+
"page_idx": 5
|
| 776 |
+
},
|
| 777 |
+
{
|
| 778 |
+
"type": "text",
|
| 779 |
+
"text": "In this section, we analyze the finite-sample performance of TSIVR-PG. We first show that TSIVR-PG finds an $\\epsilon$ -stationary solution with $\\bar { \\mathcal { O } } ( \\bar { \\epsilon } ^ { - 3 } )$ samples. Given additional assumptions, we show that TSIVR-PG finds a global $\\epsilon$ -optimal solution with $\\tilde { \\mathcal { O } } ( \\epsilon ^ { - 2 } )$ samples . ",
|
| 780 |
+
"bbox": [
|
| 781 |
+
173,
|
| 782 |
+
222,
|
| 783 |
+
826,
|
| 784 |
+
268
|
| 785 |
+
],
|
| 786 |
+
"page_idx": 5
|
| 787 |
+
},
|
| 788 |
+
{
|
| 789 |
+
"type": "text",
|
| 790 |
+
"text": "5.1 Convergence Towards Stationary Points ",
|
| 791 |
+
"text_level": 1,
|
| 792 |
+
"bbox": [
|
| 793 |
+
173,
|
| 794 |
+
284,
|
| 795 |
+
493,
|
| 796 |
+
300
|
| 797 |
+
],
|
| 798 |
+
"page_idx": 5
|
| 799 |
+
},
|
| 800 |
+
{
|
| 801 |
+
"type": "text",
|
| 802 |
+
"text": "Since we focus on the soft-max policy parameterization where $\\begin{array} { r } { \\pi _ { \\theta } ( a | s ) = \\frac { \\exp \\{ \\psi ( s , a ; \\theta ) \\} } { \\sum _ { a ^ { \\prime } } \\exp \\{ \\psi ( s , a ^ { \\prime } ; \\theta ) \\} } } \\end{array}$ P a0 exp{ψ(s,a0;θ)} , we make the following assumptions on the parameterization function $\\psi$ and the utility $F$ . ",
|
| 803 |
+
"bbox": [
|
| 804 |
+
173,
|
| 805 |
+
309,
|
| 806 |
+
825,
|
| 807 |
+
344
|
| 808 |
+
],
|
| 809 |
+
"page_idx": 5
|
| 810 |
+
},
|
| 811 |
+
{
|
| 812 |
+
"type": "text",
|
| 813 |
+
"text": "Assumption 5.1. $\\psi ( s , a ; \\cdot )$ is twice differentiable for all s and $a$ . There $\\exists \\ell _ { \\psi } , L _ { \\psi } > 0$ s.t. ",
|
| 814 |
+
"bbox": [
|
| 815 |
+
173,
|
| 816 |
+
347,
|
| 817 |
+
758,
|
| 818 |
+
363
|
| 819 |
+
],
|
| 820 |
+
"page_idx": 5
|
| 821 |
+
},
|
| 822 |
+
{
|
| 823 |
+
"type": "equation",
|
| 824 |
+
"img_path": "images/c42924d214e56f1f472307024ee1a3f2ff19d345e2c2801fb42a4a1f138f3fc5.jpg",
|
| 825 |
+
"text": "$$\n\\operatorname* { m a x } _ { s \\in S , a \\in A } \\operatorname* { s u p } _ { \\theta } \\| \\nabla _ { \\theta } \\psi ( s , a ; \\theta ) \\| \\leq \\ell _ { \\psi } \\quad a n d \\quad \\operatorname* { m a x } _ { s \\in S , a \\in A } \\operatorname* { s u p } _ { \\theta } \\| \\nabla _ { \\theta } ^ { 2 } \\psi ( s , a ; \\theta ) \\| \\leq L _ { h } ,\n$$",
|
| 826 |
+
"text_format": "latex",
|
| 827 |
+
"bbox": [
|
| 828 |
+
240,
|
| 829 |
+
369,
|
| 830 |
+
754,
|
| 831 |
+
396
|
| 832 |
+
],
|
| 833 |
+
"page_idx": 5
|
| 834 |
+
},
|
| 835 |
+
{
|
| 836 |
+
"type": "text",
|
| 837 |
+
"text": "where $\\| \\cdot \\|$ stands for $L _ { 2 }$ norm and spectral norm for vector and matrix respectively. ",
|
| 838 |
+
"bbox": [
|
| 839 |
+
171,
|
| 840 |
+
402,
|
| 841 |
+
730,
|
| 842 |
+
417
|
| 843 |
+
],
|
| 844 |
+
"page_idx": 5
|
| 845 |
+
},
|
| 846 |
+
{
|
| 847 |
+
"type": "text",
|
| 848 |
+
"text": "Assumption 5.2. $F$ is a smooth and possibly nonconvex function. There exists $\\ell _ { \\lambda , \\infty } > 0$ such that $\\| \\nabla _ { \\lambda } F ( \\lambda ) \\| _ { \\infty } \\leq \\ell _ { \\lambda , \\infty } .$ . And there exist constants $L _ { \\lambda , \\infty } , L _ { \\lambda } > 0$ s.t. it holds for $\\forall \\lambda , \\lambda ^ { \\prime }$ that ",
|
| 849 |
+
"bbox": [
|
| 850 |
+
174,
|
| 851 |
+
421,
|
| 852 |
+
826,
|
| 853 |
+
452
|
| 854 |
+
],
|
| 855 |
+
"page_idx": 5
|
| 856 |
+
},
|
| 857 |
+
{
|
| 858 |
+
"type": "equation",
|
| 859 |
+
"img_path": "images/e8cda9603eb3ee21ec0412986f36554d074dda84f7b50bb830cf9de293a504c8.jpg",
|
| 860 |
+
"text": "$$\n\\begin{array} { r } { \\| \\nabla _ { \\lambda } F ( \\lambda ) - \\nabla _ { \\lambda } F ( \\lambda ^ { \\prime } ) \\| _ { \\infty } \\leq L _ { \\lambda } \\| \\lambda - \\lambda ^ { \\prime } \\| _ { 2 } \\quad a n d \\quad \\| \\nabla _ { \\lambda } F ( \\lambda ) - \\nabla _ { \\lambda } F ( \\lambda ^ { \\prime } ) \\| _ { \\infty } \\leq L _ { \\lambda , \\infty } \\| \\lambda - \\lambda ^ { \\prime } \\| _ { 1 } . } \\end{array}\n$$",
|
| 861 |
+
"text_format": "latex",
|
| 862 |
+
"bbox": [
|
| 863 |
+
189,
|
| 864 |
+
455,
|
| 865 |
+
823,
|
| 866 |
+
474
|
| 867 |
+
],
|
| 868 |
+
"page_idx": 5
|
| 869 |
+
},
|
| 870 |
+
{
|
| 871 |
+
"type": "text",
|
| 872 |
+
"text": "Based on the above assumptions, we have the following supporting lemmas. ",
|
| 873 |
+
"bbox": [
|
| 874 |
+
176,
|
| 875 |
+
486,
|
| 876 |
+
673,
|
| 877 |
+
502
|
| 878 |
+
],
|
| 879 |
+
"page_idx": 5
|
| 880 |
+
},
|
| 881 |
+
{
|
| 882 |
+
"type": "text",
|
| 883 |
+
"text": "Lemma 5.3. Given Assumption 5.1 and 5.2, the following results hold: (i). For any policy parameter $\\theta$ and any state-action pair $( s , a )$ , the following inequalities hold: $\\| \\nabla _ { \\theta } \\log \\pi _ { \\theta } ( a | s ) \\| \\le 2 \\ell _ { \\psi }$ , $\\| \\nabla _ { \\theta } ^ { 2 } \\log \\pi _ { \\theta } ( a | s ) \\| \\le 2 ( L _ { \\psi } + \\ell _ { \\psi } ^ { 2 } )$ , and $\\begin{array} { r } { \\| \\nabla _ { \\theta } F ( \\lambda ( \\theta ) ) \\| \\le \\frac { 2 \\ell _ { \\psi } \\cdot \\ell _ { \\lambda , \\infty } } { ( 1 - \\gamma ) ^ { 2 } } } \\end{array}$ (ii). For any policy parameters $\\theta _ { 1 }$ and $\\theta _ { 2 }$ , it holds that $\\begin{array} { r } { \\left. \\lambda ^ { \\pi _ { \\theta _ { 1 } } } - \\lambda ^ { \\pi _ { \\theta _ { 2 } } } \\right. _ { 1 } \\leq \\frac { 2 \\ell _ { \\psi } } { ( 1 - \\gamma ) ^ { 2 } } \\cdot \\left. \\theta _ { 1 } - \\theta _ { 2 } \\right. } \\end{array}$ . (iii). The objective function $F \\circ \\lambda ( \\cdot )$ is $L _ { \\theta }$ -smooth, with $\\begin{array} { r } { L _ { \\theta } = \\frac { 4 L _ { \\lambda , \\infty } \\cdot \\ell _ { \\psi } ^ { 2 } } { ( 1 - \\gamma ) ^ { 4 } } + \\frac { 8 \\ell _ { \\psi } ^ { 2 } \\cdot \\ell _ { \\lambda , \\infty } } { ( 1 - \\gamma ) ^ { 3 } } + \\frac { 2 \\ell _ { \\lambda , \\infty } \\cdot ( L _ { \\psi } + \\ell _ { \\psi } ^ { 2 } ) } { ( 1 - \\gamma ) ^ { 2 } } , } \\end{array}$ . ",
|
| 884 |
+
"bbox": [
|
| 885 |
+
173,
|
| 886 |
+
505,
|
| 887 |
+
826,
|
| 888 |
+
599
|
| 889 |
+
],
|
| 890 |
+
"page_idx": 5
|
| 891 |
+
},
|
| 892 |
+
{
|
| 893 |
+
"type": "text",
|
| 894 |
+
"text": "To measure the convergence, we propose to use the gradient mapping defined as follows: ",
|
| 895 |
+
"bbox": [
|
| 896 |
+
168,
|
| 897 |
+
608,
|
| 898 |
+
756,
|
| 899 |
+
623
|
| 900 |
+
],
|
| 901 |
+
"page_idx": 5
|
| 902 |
+
},
|
| 903 |
+
{
|
| 904 |
+
"type": "equation",
|
| 905 |
+
"img_path": "images/4401b4e51d316d3c121e290e11627962217e74d30671ab0139a631956aae1a9c.jpg",
|
| 906 |
+
"text": "$$\n\\mathcal { G } _ { \\eta } ( \\theta ) = \\frac { \\theta _ { + } - \\theta } { \\eta } , \\quad \\mathrm { w h e r e } \\quad \\theta _ { + } = \\left\\{ \\begin{array} { l l } { \\theta + \\eta \\cdot g } & { , \\mathrm { ~ i f ~ } \\eta \\| g \\| \\le \\delta , } \\\\ { \\theta + \\delta \\cdot g / \\| g \\| } & { , \\mathrm { ~ o t h e r w i s e } } \\end{array} \\right.\n$$",
|
| 907 |
+
"text_format": "latex",
|
| 908 |
+
"bbox": [
|
| 909 |
+
271,
|
| 910 |
+
630,
|
| 911 |
+
723,
|
| 912 |
+
665
|
| 913 |
+
],
|
| 914 |
+
"page_idx": 5
|
| 915 |
+
},
|
| 916 |
+
{
|
| 917 |
+
"type": "text",
|
| 918 |
+
"text": "where $g = \\nabla _ { \\boldsymbol { \\theta } } F ( \\lambda ( \\boldsymbol { \\theta } ) )$ . We remark that, $\\mathbb { E } [ \\| \\mathcal { G } _ { \\eta } ( \\theta _ { j } ^ { i } ) \\| ^ { 2 } ]$ is more suitable for the ascent analysis of the truncated gradient updates, compared with the commonly used $\\mathbb { E } [ \\| \\nabla _ { \\theta } F ( \\lambda ( \\theta _ { j } ^ { i } ) ) \\| ^ { 2 } ]$ . Note that ${ \\mathcal G } _ { \\boldsymbol \\eta } ( \\boldsymbol \\theta ) = \\nabla F ( \\lambda ( { \\boldsymbol \\theta } ) )$ if $\\lVert \\mathcal { G } _ { \\eta } ( { \\boldsymbol { \\theta } } ) \\rVert \\leq \\delta$ and $\\| \\nabla F ( \\lambda ( \\theta ) ) \\|$ is bounded for any $\\theta$ . Based on such observation, we have the following lemma to validate the choice of the proposed stationarity measure. ",
|
| 919 |
+
"bbox": [
|
| 920 |
+
173,
|
| 921 |
+
671,
|
| 922 |
+
826,
|
| 923 |
+
734
|
| 924 |
+
],
|
| 925 |
+
"page_idx": 5
|
| 926 |
+
},
|
| 927 |
+
{
|
| 928 |
+
"type": "text",
|
| 929 |
+
"text": "Lemma 5.4. For any random vector $\\theta$ , $\\mathbb { E } [ \\lVert \\mathcal { G } _ { \\eta } ( \\theta ) \\rVert ] \\le \\epsilon$ implies $\\mathbb { E } [ \\| \\nabla _ { \\theta } F ( \\lambda ( \\theta ) ) \\| ] \\le \\mathcal { O } ( \\delta ^ { - 1 } \\cdot \\epsilon ) .$ . ",
|
| 930 |
+
"bbox": [
|
| 931 |
+
171,
|
| 932 |
+
737,
|
| 933 |
+
803,
|
| 934 |
+
755
|
| 935 |
+
],
|
| 936 |
+
"page_idx": 5
|
| 937 |
+
},
|
| 938 |
+
{
|
| 939 |
+
"type": "text",
|
| 940 |
+
"text": "Based on the notion of $\\mathcal { G } _ { \\eta }$ , we characterize the per-iteration ascent as follows. ",
|
| 941 |
+
"bbox": [
|
| 942 |
+
174,
|
| 943 |
+
762,
|
| 944 |
+
684,
|
| 945 |
+
779
|
| 946 |
+
],
|
| 947 |
+
"page_idx": 5
|
| 948 |
+
},
|
| 949 |
+
{
|
| 950 |
+
"type": "text",
|
| 951 |
+
"text": "Lemma 5.5. Let the iterates be generated by Algorithm $^ { l }$ . Then it holds that ",
|
| 952 |
+
"bbox": [
|
| 953 |
+
173,
|
| 954 |
+
781,
|
| 955 |
+
679,
|
| 956 |
+
797
|
| 957 |
+
],
|
| 958 |
+
"page_idx": 5
|
| 959 |
+
},
|
| 960 |
+
{
|
| 961 |
+
"type": "equation",
|
| 962 |
+
"img_path": "images/6e5fa1a0a40a51bb1fc62361749bf8433920369e4853241d33b72933e1aeb827.jpg",
|
| 963 |
+
"text": "$$\nF ( \\lambda ( \\theta _ { j + 1 } ^ { i } ) ) \\geq F ( \\lambda ( \\theta _ { j } ^ { i } ) ) + \\frac { \\eta } { 4 } \\| \\mathcal { G } _ { \\eta } ( \\theta _ { j } ^ { i } ) \\| ^ { 2 } + \\Big ( \\frac { 1 } { 2 \\eta } - L _ { \\theta } \\Big ) \\| \\theta _ { j + 1 } ^ { i } - \\theta _ { j } ^ { i } \\| ^ { 2 } - \\Big ( \\frac { \\eta } { 2 } + \\frac { 1 } { 2 L _ { \\theta } } \\Big ) \\| \\nabla _ { \\theta } F ( \\lambda ( \\theta _ { j } ^ { i } ) ) - g _ { j } ^ { i } \\| ^ { 2 } .\n$$",
|
| 964 |
+
"text_format": "latex",
|
| 965 |
+
"bbox": [
|
| 966 |
+
171,
|
| 967 |
+
803,
|
| 968 |
+
810,
|
| 969 |
+
835
|
| 970 |
+
],
|
| 971 |
+
"page_idx": 5
|
| 972 |
+
},
|
| 973 |
+
{
|
| 974 |
+
"type": "text",
|
| 975 |
+
"text": "This suggests us to bound mean-squared-error $\\mathbb { E } [ \\| \\nabla _ { \\theta } F ( \\lambda ( \\theta _ { j } ^ { i } ) ) - g _ { j } ^ { i } \\| ^ { 2 } ]$ . For this purpose, we need to bound the importance sampling weight, by utilizing the soft-max form of policy parameterization (1). ",
|
| 976 |
+
"bbox": [
|
| 977 |
+
173,
|
| 978 |
+
848,
|
| 979 |
+
825,
|
| 980 |
+
878
|
| 981 |
+
],
|
| 982 |
+
"page_idx": 5
|
| 983 |
+
},
|
| 984 |
+
{
|
| 985 |
+
"type": "text",
|
| 986 |
+
"text": "Lemma 5.6. For any behavioral policy $\\pi _ { \\theta _ { 1 } }$ and target policy $\\pi _ { \\boldsymbol { \\theta } _ { 2 } }$ parameterized by (1), the importance weight satisfies $\\omega _ { t } ( \\tau | \\theta _ { 1 } , \\theta _ { 2 } ) \\leq \\exp \\big \\{ 2 ( t + 1 ) \\ell _ { \\psi } \\| \\theta _ { 1 } - \\theta _ { 2 } \\| \\big \\}$ , for $\\forall 0 \\leq t \\leq H - 1$ . ",
|
| 987 |
+
"bbox": [
|
| 988 |
+
171,
|
| 989 |
+
882,
|
| 990 |
+
828,
|
| 991 |
+
914
|
| 992 |
+
],
|
| 993 |
+
"page_idx": 5
|
| 994 |
+
},
|
| 995 |
+
{
|
| 996 |
+
"type": "text",
|
| 997 |
+
"text": "Since TSIVR-PG only uses importance weights for two consecutive iterations $\\theta _ { j } ^ { i } , \\theta _ { j - 1 } ^ { i }$ while forcing $\\| \\theta _ { j } ^ { i } - \\theta _ { j - 1 } ^ { i } \\| \\leq \\delta$ by the truncated gradient step (11), we have $\\omega _ { H - 1 } ( \\tau | \\theta _ { j } ^ { i } , \\theta _ { j - 1 } ^ { i } ) \\leq \\exp \\{ 2 H \\ell _ { \\psi } \\delta \\}$ w.p. 1. As we will see later, the effective horizon $H$ only has a mild magnitude of $\\mathcal { O } \\big ( ( 1 - \\gamma ) ^ { - 1 } { \\cdot } \\log ( 1 / \\epsilon ) \\big )$ , the truncation radius only need to satisfy $\\delta = \\mathcal { O } ( H ^ { - 1 } \\ell _ { \\psi } ^ { - 1 } )$ s.t. $\\omega _ { t - 1 } \\big ( \\tau \\vert \\theta _ { j } ^ { i } , \\theta _ { j - 1 } ^ { i } \\big ) = \\mathcal { O } ( 1 )$ , for $\\forall t \\leq H - 1$ . Consequently, combining Lemma 5.3, 5.6 and Lemma B.1 of [48] gives the following result. ",
|
| 998 |
+
"bbox": [
|
| 999 |
+
173,
|
| 1000 |
+
90,
|
| 1001 |
+
826,
|
| 1002 |
+
171
|
| 1003 |
+
],
|
| 1004 |
+
"page_idx": 6
|
| 1005 |
+
},
|
| 1006 |
+
{
|
| 1007 |
+
"type": "text",
|
| 1008 |
+
"text": "Lemma 5.7. Let policy $\\pi _ { \\theta }$ be parameterized by (1) with function $\\psi$ satisfying Assumption 5.1. Suppose behavioral policy $\\pi _ { \\theta _ { 1 } }$ and target policy $\\pi _ { \\theta _ { 2 } }$ satisfy $\\lVert { \\boldsymbol { \\theta } } _ { 1 } - { \\boldsymbol { \\theta } } _ { 2 } \\rVert \\leq \\delta$ , then ",
|
| 1009 |
+
"bbox": [
|
| 1010 |
+
173,
|
| 1011 |
+
174,
|
| 1012 |
+
825,
|
| 1013 |
+
204
|
| 1014 |
+
],
|
| 1015 |
+
"page_idx": 6
|
| 1016 |
+
},
|
| 1017 |
+
{
|
| 1018 |
+
"type": "text",
|
| 1019 |
+
"text": "$\\begin{array} { r } { \\mathbb { E } [ \\omega _ { t } ( \\tau | \\theta _ { 1 } , \\theta _ { 2 } ) ] = 1 \\quad a n d \\quad \\mathrm { V a r } \\left( \\omega _ { t } ( \\tau | \\theta _ { 1 } , \\theta _ { 2 } ) \\right) \\leq C _ { \\omega } ( t + 1 ) \\cdot \\| \\theta _ { 1 } - \\theta _ { 2 } \\| ^ { 2 } , } \\end{array}$ where $\\tau$ is sampled under policy $\\pi _ { \\theta _ { 1 } }$ , and $C _ { \\omega } ( t ) = t \\big ( 4 \\ell _ { \\psi } ^ { 2 } ( t + \\textstyle { \\frac { 1 } { 2 } } ) + 2 L _ { \\psi } \\big ) ( e ^ { 4 \\ell _ { \\psi } \\delta t } + 1 ) .$ ",
|
| 1020 |
+
"bbox": [
|
| 1021 |
+
171,
|
| 1022 |
+
210,
|
| 1023 |
+
743,
|
| 1024 |
+
251
|
| 1025 |
+
],
|
| 1026 |
+
"page_idx": 6
|
| 1027 |
+
},
|
| 1028 |
+
{
|
| 1029 |
+
"type": "text",
|
| 1030 |
+
"text": "As a result, we can bound the mean-squared-error of the $g _ { j } ^ { i }$ as follows. ",
|
| 1031 |
+
"bbox": [
|
| 1032 |
+
173,
|
| 1033 |
+
261,
|
| 1034 |
+
635,
|
| 1035 |
+
279
|
| 1036 |
+
],
|
| 1037 |
+
"page_idx": 6
|
| 1038 |
+
},
|
| 1039 |
+
{
|
| 1040 |
+
"type": "text",
|
| 1041 |
+
"text": "Lemma 5.8. For the $P G$ estimators $g _ { j } ^ { i }$ , we have ",
|
| 1042 |
+
"bbox": [
|
| 1043 |
+
173,
|
| 1044 |
+
282,
|
| 1045 |
+
493,
|
| 1046 |
+
299
|
| 1047 |
+
],
|
| 1048 |
+
"page_idx": 6
|
| 1049 |
+
},
|
| 1050 |
+
{
|
| 1051 |
+
"type": "equation",
|
| 1052 |
+
"img_path": "images/c7fd140b79a4ddad795757d488bab9a48098847c3213b90f125d4dbe3ebed487.jpg",
|
| 1053 |
+
"text": "$$\n\\mathbb { S } \\bigg [ \\| g _ { j } ^ { i } - \\nabla _ { \\theta } F ( \\lambda ( \\theta _ { j } ^ { i } ) ) \\| ^ { 2 } \\bigg ] \\leq \\frac { C _ { 1 } } { N } + C _ { 2 } \\gamma ^ { 2 H } + \\frac { C _ { 3 } } { B } \\cdot \\sum _ { j ^ { \\prime } = 1 } ^ { j } \\mathbb { E } \\left[ \\| \\theta _ { j ^ { \\prime } - 1 } ^ { i } - \\theta _ { j ^ { \\prime } } ^ { i } \\| ^ { 2 } \\right] + C _ { 4 } \\mathbb { E } \\left[ \\| \\theta _ { j - 1 } ^ { i } - \\theta _ { j } ^ { i } \\| ^ { 2 } \\right]\n$$",
|
| 1054 |
+
"text_format": "latex",
|
| 1055 |
+
"bbox": [
|
| 1056 |
+
181,
|
| 1057 |
+
305,
|
| 1058 |
+
823,
|
| 1059 |
+
351
|
| 1060 |
+
],
|
| 1061 |
+
"page_idx": 6
|
| 1062 |
+
},
|
| 1063 |
+
{
|
| 1064 |
+
"type": "text",
|
| 1065 |
+
"text": "for some constants $C _ { 1 } , . . , C _ { 4 } > 0 .$ . In case $j = 0$ , we default $\\textstyle \\sum _ { j ^ { \\prime } = 1 } ^ { 0 } \\cdot = 0$ ",
|
| 1066 |
+
"bbox": [
|
| 1067 |
+
174,
|
| 1068 |
+
356,
|
| 1069 |
+
656,
|
| 1070 |
+
376
|
| 1071 |
+
],
|
| 1072 |
+
"page_idx": 6
|
| 1073 |
+
},
|
| 1074 |
+
{
|
| 1075 |
+
"type": "text",
|
| 1076 |
+
"text": "The expression of constants $C _ { i }$ ’s are complicated, we provide their detailed formula in the appendix. If we set H = O\u0000 log(1/\u000f) \u0001 and $\\begin{array} { r } { \\delta \\le \\frac { 1 } { 2 H \\ell _ { \\psi } } } \\end{array}$ , then $C _ { i }$ only depends polynomially on the Lipschitz constants, $\\log ( \\epsilon ^ { - 1 } )$ , and $( 1 - \\gamma ) ^ { - 1 }$ . Combining Lemma 5.5, 5.8, and 5.4 gives Theorem 5.9. ",
|
| 1077 |
+
"bbox": [
|
| 1078 |
+
173,
|
| 1079 |
+
385,
|
| 1080 |
+
825,
|
| 1081 |
+
435
|
| 1082 |
+
],
|
| 1083 |
+
"page_idx": 6
|
| 1084 |
+
},
|
| 1085 |
+
{
|
| 1086 |
+
"type": "text",
|
| 1087 |
+
"text": "Theorem 5.9. For Algorithm $^ { l }$ , we choose $\\begin{array} { r } { H = \\frac { 2 \\log ( 1 / \\epsilon ) } { 1 - \\gamma } } \\end{array}$ , $\\begin{array} { r } { \\delta = \\frac { 1 } { 2 H \\ell _ { \\psi } } } \\end{array}$ , $B = m = \\epsilon ^ { - 1 }$ , $N = \\epsilon ^ { - 2 }$ η = 11+(C3+C4)/L2θ · 12Lθ . After running the algorithm for T = \u000f−1 epochs and output θout from $\\{ \\theta _ { j } ^ { i } \\} _ { j = 0 , \\cdots , m - 1 } ^ { i = 1 , \\cdots , T }$ uniformly at random, we have $\\mathbb { E } [ \\| \\mathcal { G } _ { \\eta } ( \\theta _ { o u t } ) \\| ] \\le \\mathcal { O } ( \\epsilon )$ . The total number of samples is $\\dot { T } \\times ( ( m - 1 ) B + N ) \\times H = \\tilde { \\mathcal { O } } ( \\epsilon ^ { - 3 } )$ . By Lemma 5.4, we also have $\\mathbb { E } [ \\| \\nabla _ { \\theta } F ( \\lambda ( \\theta _ { o u t } ) ) \\| ] \\le { \\mathcal { O } } ( \\epsilon )$ . ",
|
| 1088 |
+
"bbox": [
|
| 1089 |
+
173,
|
| 1090 |
+
439,
|
| 1091 |
+
826,
|
| 1092 |
+
517
|
| 1093 |
+
],
|
| 1094 |
+
"page_idx": 6
|
| 1095 |
+
},
|
| 1096 |
+
{
|
| 1097 |
+
"type": "text",
|
| 1098 |
+
"text": "5.2 Convergence Towards Global Optimality ",
|
| 1099 |
+
"text_level": 1,
|
| 1100 |
+
"bbox": [
|
| 1101 |
+
173,
|
| 1102 |
+
530,
|
| 1103 |
+
498,
|
| 1104 |
+
546
|
| 1105 |
+
],
|
| 1106 |
+
"page_idx": 6
|
| 1107 |
+
},
|
| 1108 |
+
{
|
| 1109 |
+
"type": "text",
|
| 1110 |
+
"text": "Next, we provide a mechanism to establish the convergence of TSIVR-PG to global optimality. For this purpose, we introduce the hidden convexity of the general utility RL problem. In addition to the smoothness of $F$ (Assumption 5.2), we further assume its concavity, formally stated as follows. ",
|
| 1111 |
+
"bbox": [
|
| 1112 |
+
173,
|
| 1113 |
+
555,
|
| 1114 |
+
826,
|
| 1115 |
+
598
|
| 1116 |
+
],
|
| 1117 |
+
"page_idx": 6
|
| 1118 |
+
},
|
| 1119 |
+
{
|
| 1120 |
+
"type": "text",
|
| 1121 |
+
"text": "Assumption 5.10. Function $F$ is a concave function of the state-action occupancy measure. ",
|
| 1122 |
+
"bbox": [
|
| 1123 |
+
173,
|
| 1124 |
+
602,
|
| 1125 |
+
779,
|
| 1126 |
+
617
|
| 1127 |
+
],
|
| 1128 |
+
"page_idx": 6
|
| 1129 |
+
},
|
| 1130 |
+
{
|
| 1131 |
+
"type": "text",
|
| 1132 |
+
"text": "Let $\\mathcal { L }$ be the image of the mapping $\\lambda ( \\theta )$ . Then the parameterized policy optimization problem (2) can be rewritten as an equivalent occupancy optimization problem: ",
|
| 1133 |
+
"bbox": [
|
| 1134 |
+
171,
|
| 1135 |
+
626,
|
| 1136 |
+
820,
|
| 1137 |
+
655
|
| 1138 |
+
],
|
| 1139 |
+
"page_idx": 6
|
| 1140 |
+
},
|
| 1141 |
+
{
|
| 1142 |
+
"type": "equation",
|
| 1143 |
+
"img_path": "images/cbb79ad5128d6f57ab3ad4e8b1a10f9f2d0e72efac68d0bc5df354c418f70de5.jpg",
|
| 1144 |
+
"text": "$$\n\\begin{array} { r } { \\operatorname* { m a x } _ { \\theta } F ( \\lambda ( \\theta ) ) \\qquad \\Longleftrightarrow \\qquad \\operatorname* { m a x } _ { \\mu \\in \\mathcal { L } } F ( \\mu ) . } \\end{array}\n$$",
|
| 1145 |
+
"text_format": "latex",
|
| 1146 |
+
"bbox": [
|
| 1147 |
+
343,
|
| 1148 |
+
661,
|
| 1149 |
+
653,
|
| 1150 |
+
678
|
| 1151 |
+
],
|
| 1152 |
+
"page_idx": 6
|
| 1153 |
+
},
|
| 1154 |
+
{
|
| 1155 |
+
"type": "text",
|
| 1156 |
+
"text": "When the policy parameterization is powerful enough to represent any policy, the image $\\mathcal { L }$ is a convex polytope, see e.g. [10]. Since $F$ is concave, the occupancy optimization problem is a convex optimization problem. In this case, if the mapping $\\lambda ( \\cdot )$ is invertible (see [51]), we may view the original problem (2) as a reformulation of a convex problem by a change of variable: $\\theta = \\lambda ^ { - 1 } ( \\mu )$ . We call this property “hidden convexity”. However, requiring $\\lambda ( \\cdot )$ to be invertible is too restrictive, and it doesn’t even hold for simple soft-max policy with $\\psi ( s , a ; \\theta ) = \\theta _ { s a }$ where multiple $\\theta$ correspond to a same policy. Therefore, we adopt a weaker assumption where (i). $\\pi _ { \\theta }$ can represent any policy (ii). a continuous inverse $\\lambda ^ { - 1 } ( \\cdot )$ can be locally defined over a subset of $\\theta$ . ",
|
| 1157 |
+
"bbox": [
|
| 1158 |
+
173,
|
| 1159 |
+
681,
|
| 1160 |
+
825,
|
| 1161 |
+
794
|
| 1162 |
+
],
|
| 1163 |
+
"page_idx": 6
|
| 1164 |
+
},
|
| 1165 |
+
{
|
| 1166 |
+
"type": "text",
|
| 1167 |
+
"text": "Assumption 5.11. For policy parameterization of form (1), $\\theta$ overparametrizes the set of policies in the following sense. $( i )$ . For any $\\theta$ and $\\lambda ( \\theta )$ , there exist (relative) neighourhoods $\\theta \\in \\mathcal { U } _ { \\theta } \\subset B ( \\theta , \\delta )$ and $\\lambda ( \\theta ) \\in \\mathcal { V } _ { \\lambda ( \\theta ) } \\subset \\lambda ( B ( \\theta , \\delta ) )$ s.t. $\\left( \\lambda | _ { \\mathcal { U } _ { \\theta } } \\right) ( \\cdot )$ forms a bijection between $\\mathcal { U } _ { \\theta }$ and $\\mathcal { V } _ { \\lambda ( \\theta ) }$ , where $\\left( \\lambda | _ { \\mathcal { U } _ { \\theta } } \\right) ( \\cdot )$ is the confinement of $\\lambda$ onto $\\mathcal { U } _ { \\theta }$ . We assume $( \\lambda | _ { \\mathcal { U } _ { \\theta } } ) ^ { - 1 } ( \\cdot )$ is $\\ell _ { \\theta }$ -Lipschitz continuous for any $\\theta$ . (ii). Let $\\pi _ { \\theta ^ { \\ast } }$ be the optimal policy. Assume there exists \u000f¯ small enough, s.t. $( 1 - \\epsilon ) \\lambda ( \\theta ) + \\epsilon \\lambda ( \\theta ^ { * } ) \\in$ $\\mathcal { V } _ { \\lambda ( \\theta ) } f o r \\forall \\epsilon \\le \\bar { \\epsilon } , \\forall \\theta$ . ",
|
| 1168 |
+
"bbox": [
|
| 1169 |
+
173,
|
| 1170 |
+
797,
|
| 1171 |
+
825,
|
| 1172 |
+
888
|
| 1173 |
+
],
|
| 1174 |
+
"page_idx": 6
|
| 1175 |
+
},
|
| 1176 |
+
{
|
| 1177 |
+
"type": "text",
|
| 1178 |
+
"text": "Based on Assumption 5.11, we replace Lemma 5.5 with the following lemma. ",
|
| 1179 |
+
"bbox": [
|
| 1180 |
+
173,
|
| 1181 |
+
896,
|
| 1182 |
+
686,
|
| 1183 |
+
912
|
| 1184 |
+
],
|
| 1185 |
+
"page_idx": 6
|
| 1186 |
+
},
|
| 1187 |
+
{
|
| 1188 |
+
"type": "equation",
|
| 1189 |
+
"img_path": "images/82712a1d82e6420bdf10fd1c709533c7c25a5274b6457b34233217b8ce59ce1f.jpg",
|
| 1190 |
+
"text": "$$\n\\begin{array} { r l r } { \\displaystyle F ( \\lambda ( \\theta ^ { * } ) ) - F ( \\lambda ( \\theta _ { j + 1 } ^ { i } ) ) \\ \\le \\ ( 1 - \\epsilon ) \\left( F ( \\lambda ( \\theta ^ { * } ) ) - F ( \\lambda ( \\theta _ { j } ^ { i } ) ) \\right) } & { { } } & { { ( 1 5 ) } } \\\\ { \\displaystyle + \\left( L _ { \\theta } + \\frac { 1 } { 2 \\eta } \\right) \\frac { 2 \\epsilon ^ { 2 } \\ell _ { \\theta } ^ { 2 } } { ( 1 - \\gamma ) ^ { 2 } } - \\left( \\frac { 1 } { 2 \\eta } - L _ { \\theta } \\right) \\| \\theta _ { j + 1 } ^ { i } - \\theta _ { j } ^ { i } \\| ^ { 2 } + \\frac { 1 } { L _ { \\theta } } \\| g _ { j } ^ { i } - \\nabla _ { \\theta } F ( \\lambda ( \\theta _ { j } ^ { i } ) ) \\| ^ { 2 } . } & { } & { } \\end{array}\n$$",
|
| 1191 |
+
"text_format": "latex",
|
| 1192 |
+
"bbox": [
|
| 1193 |
+
178,
|
| 1194 |
+
109,
|
| 1195 |
+
815,
|
| 1196 |
+
167
|
| 1197 |
+
],
|
| 1198 |
+
"page_idx": 7
|
| 1199 |
+
},
|
| 1200 |
+
{
|
| 1201 |
+
"type": "text",
|
| 1202 |
+
"text": "The analysis of Lemma 5.12 is very different from its nonconvex optimization counterpart (Lemma 5.5). Next, we derive the sample complexity of the TSIVR-PG algorithm given Lemma 5.12 and 5.8. ",
|
| 1203 |
+
"bbox": [
|
| 1204 |
+
169,
|
| 1205 |
+
176,
|
| 1206 |
+
823,
|
| 1207 |
+
207
|
| 1208 |
+
],
|
| 1209 |
+
"page_idx": 7
|
| 1210 |
+
},
|
| 1211 |
+
{
|
| 1212 |
+
"type": "text",
|
| 1213 |
+
"text": "Theorem 5.13. For TSIVR-PG method (Algorithm $^ { l }$ ), let $\\epsilon \\in ( 0 , \\bar { \\epsilon } )$ be the target accuracy. If we choose $H , m , B , N$ and $\\delta$ according to Theorem 5.9. and we let the stepsize to be small enough s.t. $\\begin{array} { r } { \\eta \\le \\frac { 1 } { 2 L _ { \\theta } + 8 ( C _ { 3 } + C _ { 4 } ) / L _ { \\theta } } } \\end{array}$ , then after at most $T = \\log _ { 2 } ( \\epsilon ^ { - 1 } )$ epochs, $\\mathbb { E } \\big [ F \\big ( \\hat { \\lambda } ( \\theta ^ { * } ) \\big ) - F \\big ( \\lambda ( \\tilde { \\theta } _ { T } ) \\big ) \\big ] \\leq \\mathcal { O } ( \\epsilon )$ The total number of samples taken is $T \\times ( ( m - 1 ) B + N ) \\times H = \\tilde { \\mathcal { O } } ( \\epsilon ^ { - 2 } )$ . ",
|
| 1214 |
+
"bbox": [
|
| 1215 |
+
174,
|
| 1216 |
+
209,
|
| 1217 |
+
825,
|
| 1218 |
+
273
|
| 1219 |
+
],
|
| 1220 |
+
"page_idx": 7
|
| 1221 |
+
},
|
| 1222 |
+
{
|
| 1223 |
+
"type": "text",
|
| 1224 |
+
"text": "6 Numerical Experiments ",
|
| 1225 |
+
"text_level": 1,
|
| 1226 |
+
"bbox": [
|
| 1227 |
+
176,
|
| 1228 |
+
291,
|
| 1229 |
+
405,
|
| 1230 |
+
309
|
| 1231 |
+
],
|
| 1232 |
+
"page_idx": 7
|
| 1233 |
+
},
|
| 1234 |
+
{
|
| 1235 |
+
"type": "text",
|
| 1236 |
+
"text": "6.1 Maximizing Cumulative Reward. ",
|
| 1237 |
+
"text_level": 1,
|
| 1238 |
+
"bbox": [
|
| 1239 |
+
174,
|
| 1240 |
+
323,
|
| 1241 |
+
444,
|
| 1242 |
+
338
|
| 1243 |
+
],
|
| 1244 |
+
"page_idx": 7
|
| 1245 |
+
},
|
| 1246 |
+
{
|
| 1247 |
+
"type": "text",
|
| 1248 |
+
"text": "In this experiment, we aim to evaluate the performance of the TSIVR-PG algorithm for maximizing the cumulative sum of reward. As the benchmarks, we also implement the SVRPG [49], the SRVRPG [48], the HSPGA [33], and the REINFORCE [47] algorithms. Our experiment is performed on benchmark RL environments including the FrozenLake, Acrobot and Cartpole that are available from OpenAI gym [8], which is a well-known toolkit for developing and comparing reinforcement learning algorithms. For all the algorithms, their batch sizes are chosen according to their theory. In details, let $\\epsilon$ be any target accuracy. For both TSIVR-PG and SRVR-PG, we set $N = \\Theta ( \\epsilon ^ { - 2 } )$ , $B = m = \\Theta ( \\epsilon ^ { - 1 } )$ . For SVRPG, we set $N = \\Theta ( \\epsilon ^ { - 2 } )$ , $B = \\Theta ( \\epsilon ^ { - 4 / 3 } )$ and $m = \\Theta ( \\epsilon ^ { - 2 / 3 } )$ . For HSPGA, we set $B ^ { \\prime } = \\Theta ( \\epsilon ^ { - 1 } )$ , other parameters are calculated according to formulas in [33] given $B$ . For REINFORCE, we set the batchsize to be $N = \\Theta ( \\epsilon ^ { - 2 } )$ . The parameter $\\varepsilon$ and the stepsize/learning rate are tuned for each individual algorithm using a grid search. For each algorithm, we run the experiment for multiple times with random initialization of the policy parameters. The curve is obtained by first calculating the moving average of the most recent 50 episodes, and then calculate the median of the return over the outcomes of different runs. The upper and lower bounds of the shaded area are calculated as the $\\textstyle { \\frac { 1 } { 4 } }$ and $\\frac 3 4$ quantiles over the outcomes. We run the experiment for 10 times for the FrozenLake environment and 50 times for the other environments. The detailed parameters used in the experiments are presented in the Appendix. ",
|
| 1249 |
+
"bbox": [
|
| 1250 |
+
173,
|
| 1251 |
+
348,
|
| 1252 |
+
826,
|
| 1253 |
+
585
|
| 1254 |
+
],
|
| 1255 |
+
"page_idx": 7
|
| 1256 |
+
},
|
| 1257 |
+
{
|
| 1258 |
+
"type": "text",
|
| 1259 |
+
"text": "FrozenLake The FrozenLake8x8 environment is a tabular MDP with finite state and action spaces. \nFor this environment, the policy is parameterized with $\\psi ( s , a ; \\theta ) = \\theta _ { s a }$ . ",
|
| 1260 |
+
"bbox": [
|
| 1261 |
+
173,
|
| 1262 |
+
590,
|
| 1263 |
+
823,
|
| 1264 |
+
619
|
| 1265 |
+
],
|
| 1266 |
+
"page_idx": 7
|
| 1267 |
+
},
|
| 1268 |
+
{
|
| 1269 |
+
"type": "text",
|
| 1270 |
+
"text": "Cartpole and Acrobot Both the Cartpole environment and the Acrobot environment are environments with a discrete action space and a continuous state space. For both environments, we use a neural network with two hidden layers with width 64 for both layers to model the policy. ",
|
| 1271 |
+
"bbox": [
|
| 1272 |
+
174,
|
| 1273 |
+
626,
|
| 1274 |
+
825,
|
| 1275 |
+
667
|
| 1276 |
+
],
|
| 1277 |
+
"page_idx": 7
|
| 1278 |
+
},
|
| 1279 |
+
{
|
| 1280 |
+
"type": "text",
|
| 1281 |
+
"text": "Result We plot our experiment outcomes in Figure 6.1. The experiments show that given enough episodes, all of the algorithms are able to solve the tasks, achieving nearly optimal returns. And as expected, the REINFORCE algorithm takes the longest time to find the optimal policy. While the other algorithms yield a faster convergence speed, the TSIVR-PG algorithm consistently outperforms the other benchmark algorithms under all of the environments, showing the advantage of our method. ",
|
| 1282 |
+
"bbox": [
|
| 1283 |
+
174,
|
| 1284 |
+
672,
|
| 1285 |
+
825,
|
| 1286 |
+
743
|
| 1287 |
+
],
|
| 1288 |
+
"page_idx": 7
|
| 1289 |
+
},
|
| 1290 |
+
{
|
| 1291 |
+
"type": "text",
|
| 1292 |
+
"text": "6.2 Validating the $\\tilde { \\mathcal { O } } ( \\epsilon ^ { - 2 } )$ Sample Complexity ",
|
| 1293 |
+
"text_level": 1,
|
| 1294 |
+
"bbox": [
|
| 1295 |
+
173,
|
| 1296 |
+
771,
|
| 1297 |
+
504,
|
| 1298 |
+
787
|
| 1299 |
+
],
|
| 1300 |
+
"page_idx": 7
|
| 1301 |
+
},
|
| 1302 |
+
{
|
| 1303 |
+
"type": "text",
|
| 1304 |
+
"text": "Besides the comparison between different benchmark algorithms, we also perform a validation experiment showing that for certain environments, the convergence rate of TSIVR-PG is close to the theoretical guarantee. Because the parameters $N , B , m$ are dependent on the target accuracy $\\epsilon$ , in this section we adopt a different way to set up these parameters: We first set a fixed epoch $E$ , and perform experiments using different values of the parameter √ $N$ . The parameter $B$ and $m$ are set according to our choice of $N$ by $B = m = \\sqrt { N }$ . The performance of the algorithm output is calculated as the average score of the last few episodes, which is then averaged over 10 independent runs. Again, we use the FrozenLake8x8 environment to do the experiment. Because FrozenLake8x8 is a tabular environment whose transition and reward function can be easily obtained from the document, we can calculate it’s optimal value simply by value iteration, which takes 0.4146 when we choose $\\gamma = 0 . 9 9$ . In this way, we calculate the gap between the algorithm return and the optimal value, and get log-log figure w.r.t. the gap and the number of episodes calculated by $E ( N + B m ) = 2 E N$ . ",
|
| 1305 |
+
"bbox": [
|
| 1306 |
+
173,
|
| 1307 |
+
797,
|
| 1308 |
+
825,
|
| 1309 |
+
911
|
| 1310 |
+
],
|
| 1311 |
+
"page_idx": 7
|
| 1312 |
+
},
|
| 1313 |
+
{
|
| 1314 |
+
"type": "image",
|
| 1315 |
+
"img_path": "images/113dec4478a5bb803d33ae7bcbc1c6a9ed5bb05461108a494743bd82ec9c746f.jpg",
|
| 1316 |
+
"image_caption": [
|
| 1317 |
+
"Figure 1: The performance curves of TSIVR-PG and benchmark algorithms under different environments. The curve is the median return over multiple runs and the shaded areas are calculated as the $\\textstyle { \\frac { 1 } { 4 } }$ and $\\textstyle { \\frac { 3 } { 4 } }$ quantiles of the experiment outcomes. "
|
| 1318 |
+
],
|
| 1319 |
+
"image_footnote": [],
|
| 1320 |
+
"bbox": [
|
| 1321 |
+
184,
|
| 1322 |
+
95,
|
| 1323 |
+
803,
|
| 1324 |
+
210
|
| 1325 |
+
],
|
| 1326 |
+
"page_idx": 8
|
| 1327 |
+
},
|
| 1328 |
+
{
|
| 1329 |
+
"type": "text",
|
| 1330 |
+
"text": "",
|
| 1331 |
+
"bbox": [
|
| 1332 |
+
174,
|
| 1333 |
+
303,
|
| 1334 |
+
825,
|
| 1335 |
+
359
|
| 1336 |
+
],
|
| 1337 |
+
"page_idx": 8
|
| 1338 |
+
},
|
| 1339 |
+
{
|
| 1340 |
+
"type": "text",
|
| 1341 |
+
"text": "Result The result is shown in the first sub-figure of Figure 6.3, where the blue curve is the gap between the average return of experiment outcome and the optimal value and the shaded area is the range of one standard deviation of the logarithm value. In addition, we add a orange dotted line to fit the convergence curve, whose slope takes value $- 0 . 4 9 6$ , which nearly matches the $O ( \\epsilon ^ { - 2 } )$ theoretical bound (slope $- 0 . 5 )$ . ",
|
| 1342 |
+
"bbox": [
|
| 1343 |
+
174,
|
| 1344 |
+
364,
|
| 1345 |
+
825,
|
| 1346 |
+
435
|
| 1347 |
+
],
|
| 1348 |
+
"page_idx": 8
|
| 1349 |
+
},
|
| 1350 |
+
{
|
| 1351 |
+
"type": "text",
|
| 1352 |
+
"text": "6.3 Maximizing Non-linear Objective Function ",
|
| 1353 |
+
"text_level": 1,
|
| 1354 |
+
"bbox": [
|
| 1355 |
+
173,
|
| 1356 |
+
458,
|
| 1357 |
+
513,
|
| 1358 |
+
474
|
| 1359 |
+
],
|
| 1360 |
+
"page_idx": 8
|
| 1361 |
+
},
|
| 1362 |
+
{
|
| 1363 |
+
"type": "text",
|
| 1364 |
+
"text": "The TSIVR-PG algorithm is designed not only to solve typical RL problems, but is also able to solve a broader class of problems where the objective function is a general concave function. Unfortunately, none of the benchmark algorithms proposed in the previous section have the ability to solve this kind of problem. To evaluate the performance of our algorithm, we choose another benchmark algorithm, which is the MaxEnt algorithm [16]. In the experiment, we use FrozenLake8x8 environment since it’s more tractable to compute $\\lambda$ for a discrete state space. We set the objective function as ",
|
| 1365 |
+
"bbox": [
|
| 1366 |
+
173,
|
| 1367 |
+
487,
|
| 1368 |
+
826,
|
| 1369 |
+
571
|
| 1370 |
+
],
|
| 1371 |
+
"page_idx": 8
|
| 1372 |
+
},
|
| 1373 |
+
{
|
| 1374 |
+
"type": "equation",
|
| 1375 |
+
"img_path": "images/6b91b9912d5dbf1cb986e9563c488b3b405af53c56c828059d25feb0458bf36c.jpg",
|
| 1376 |
+
"text": "$$\nF ( \\lambda ) = \\sum _ { s \\in S } \\log { \\Bigg ( } \\sum _ { a \\in { \\mathcal { A } } } \\lambda _ { s , a } + \\sigma { \\Bigg ) } ,\n$$",
|
| 1377 |
+
"text_format": "latex",
|
| 1378 |
+
"bbox": [
|
| 1379 |
+
383,
|
| 1380 |
+
585,
|
| 1381 |
+
611,
|
| 1382 |
+
626
|
| 1383 |
+
],
|
| 1384 |
+
"page_idx": 8
|
| 1385 |
+
},
|
| 1386 |
+
{
|
| 1387 |
+
"type": "text",
|
| 1388 |
+
"text": "where $\\sigma$ is a fixed small constant. We choose $\\sigma = 0 . 1 2 5$ in our experiment. The orders of $N , B , m$ are set in the same way as those in section 6.1. For the MaxEnt algorithm, note that in the original paper, the nonlinear objective function assumes the input value is the stationary state distribution $d ^ { \\pi }$ , but the input value can easily be changed into our $\\lambda$ without changing the steps of the algorithm much. The result is illustrated in Fig. 6.3. From the result, we may see that our algorithm consistently outperforms the benchmark. ",
|
| 1389 |
+
"bbox": [
|
| 1390 |
+
173,
|
| 1391 |
+
638,
|
| 1392 |
+
825,
|
| 1393 |
+
722
|
| 1394 |
+
],
|
| 1395 |
+
"page_idx": 8
|
| 1396 |
+
},
|
| 1397 |
+
{
|
| 1398 |
+
"type": "text",
|
| 1399 |
+
"text": "7 Broader Impact ",
|
| 1400 |
+
"text_level": 1,
|
| 1401 |
+
"bbox": [
|
| 1402 |
+
174,
|
| 1403 |
+
750,
|
| 1404 |
+
339,
|
| 1405 |
+
767
|
| 1406 |
+
],
|
| 1407 |
+
"page_idx": 8
|
| 1408 |
+
},
|
| 1409 |
+
{
|
| 1410 |
+
"type": "text",
|
| 1411 |
+
"text": "There has been an emerging trend of applying stochastic variance reduction technique to enhance the performance of the policy gradient methods. However, all the existing variance-reduced policy gradient methods depend on an algorithm-dependent assumption that is made to every single iteration in running the algorithm, which actually may not be satisfied by many of these algorithms. We propose a simple yet effective mechanism to fix such dilemma for applying the SARAH/Spider variance reduction scheme in policy gradient methods. Our analysis can also be applied to other schemes such as STORM and Hybrid SARAH-SGD. Beyond that, we also show how the hidden convexity and overparameterization of the RL problem can help stochastic variance-reduced policy gradient methods to converge to global optima and yield better sample complexity. ",
|
| 1412 |
+
"bbox": [
|
| 1413 |
+
174,
|
| 1414 |
+
786,
|
| 1415 |
+
825,
|
| 1416 |
+
911
|
| 1417 |
+
],
|
| 1418 |
+
"page_idx": 8
|
| 1419 |
+
},
|
| 1420 |
+
{
|
| 1421 |
+
"type": "image",
|
| 1422 |
+
"img_path": "images/f23d45ae8b402744b15190fe4b1ebc36fade921b2375232dad7ccdf7b4a51f84.jpg",
|
| 1423 |
+
"image_caption": [
|
| 1424 |
+
"Figure 2: Left: Empirical Evaluation of the Convergence Rate of TSIVR-PG. The optimality gap achieved by TSIVR-PG decreases as the sample size increases, nearly matching the $\\epsilon ^ { - 2 }$ sample complexity theory (orange line). Right: Performance Curve ofTSIVR-PG and MaxEnt for Maximizing Non-linear Objective Functions. The curve is the median return over 10 runs and the shaded areas are calculated as the $\\textstyle { \\frac { 1 } { 4 } }$ and $\\frac 3 4$ quantiles of the experiment outcomes. "
|
| 1425 |
+
],
|
| 1426 |
+
"image_footnote": [],
|
| 1427 |
+
"bbox": [
|
| 1428 |
+
179,
|
| 1429 |
+
102,
|
| 1430 |
+
792,
|
| 1431 |
+
272
|
| 1432 |
+
],
|
| 1433 |
+
"page_idx": 9
|
| 1434 |
+
},
|
| 1435 |
+
{
|
| 1436 |
+
"type": "text",
|
| 1437 |
+
"text": "8 Limitation ",
|
| 1438 |
+
"text_level": 1,
|
| 1439 |
+
"bbox": [
|
| 1440 |
+
173,
|
| 1441 |
+
380,
|
| 1442 |
+
294,
|
| 1443 |
+
397
|
| 1444 |
+
],
|
| 1445 |
+
"page_idx": 9
|
| 1446 |
+
},
|
| 1447 |
+
{
|
| 1448 |
+
"type": "text",
|
| 1449 |
+
"text": "To compute the policy gradient for the general utility function, one needs to compute gradient of the function $\\mathrm { F }$ with respect to the state-action occupancy measure. Although for many instances, including standard cumulative sum of reward (Example 3.1) and set constrained RL (Example 3.3), estimating the occupancy measure is not necessary. There are many instances where estimating the occupancy measure is unavoidable. Due to the curse of dimensionality, the need for estimating the occupancy measure is a potential limitation if the state and action spaces are continuous and high-dimensional. One potential solution is to incorporate a function approximation for the occupancy measure, in a similar style of the Q-function approximation in the actor-critic method. We leave this for future development. ",
|
| 1450 |
+
"bbox": [
|
| 1451 |
+
173,
|
| 1452 |
+
412,
|
| 1453 |
+
826,
|
| 1454 |
+
536
|
| 1455 |
+
],
|
| 1456 |
+
"page_idx": 9
|
| 1457 |
+
},
|
| 1458 |
+
{
|
| 1459 |
+
"type": "text",
|
| 1460 |
+
"text": "References ",
|
| 1461 |
+
"text_level": 1,
|
| 1462 |
+
"bbox": [
|
| 1463 |
+
174,
|
| 1464 |
+
558,
|
| 1465 |
+
266,
|
| 1466 |
+
573
|
| 1467 |
+
],
|
| 1468 |
+
"page_idx": 9
|
| 1469 |
+
},
|
| 1470 |
+
{
|
| 1471 |
+
"type": "text",
|
| 1472 |
+
"text": "[1] Alekh Agarwal, Sham M Kakade, Jason D Lee, and Gaurav Mahajan. Optimality and approximation with policy gradient methods in markov decision processes. In Conference on Learning Theory, pages 64–66. PMLR, 2020. \n[2] Zeyuan Allen-Zhu and Elad Hazan. Variance reduction for faster non-convex optimization. In International conference on machine learning, pages 699–707, 2016. \n[3] Mohammad Gheshlaghi Azar, Rémi Munos, Mohammad Ghavamzadeh, and Hilbert Kappen. Reinforcement learning with a near optimal rate of convergence. 2011. \n[4] Mohammad Gheshlaghi Azar, Rémi Munos, and Hilbert J Kappen. Minimax pac bounds on the sample complexity of reinforcement learning with a generative model. Machine learning, 91(3):325–349, 2013. \n[5] Jonathan Baxter and Peter L Bartlett. Infinite-horizon policy-gradient estimation. Journal of Artificial Intelligence Research, 15:319–350, 2001. \n[6] Jalaj Bhandari and Daniel Russo. Global optimality guarantees for policy gradient methods. arXiv preprint arXiv:1906.01786, 2019. \n[7] Jalaj Bhandari and Daniel Russo. A note on the linear convergence of policy gradient methods. arXiv preprint arXiv:2007.11120, 2020. \n[8] Greg Brockman, Vicki Cheung, Ludwig Pettersson, Jonas Schneider, John Schulman, Jie Tang, and Wojciech Zaremba. Openai gym. arXiv preprint arXiv:1606.01540, 2016. \n[9] Shicong Cen, Chen Cheng, Yuxin Chen, Yuting Wei, and Yuejie Chi. Fast global convergence of natural policy gradient methods with entropy regularization. arXiv preprint arXiv:2007.06558, 2020. \n[10] Yichen Chen, Lihong Li, and Mengdi Wang. Scalable bilinear pi learning using state and action features. arXiv preprint arXiv:1804.10328, 2018. \n[11] Aaron Defazio, Francis Bach, and Simon Lacoste-Julien. Saga: A fast incremental gradient method with support for non-strongly convex composite objectives. Advances in neural information processing systems, 27:1646–1654, 2014. \n[12] Eyal Even-Dar, Shie Mannor, Yishay Mansour, and Sridhar Mahadevan. Action elimination and stopping conditions for the multi-armed bandit and reinforcement learning problems. Journal of machine learning research, 7(6), 2006. \n[13] Cong Fang, Chris Junchi Li, Zhouchen Lin, and Tong Zhang. Spider: Near-optimal nonconvex optimization via stochastic path-integrated differential estimator. In Advances in Neural Information Processing Systems, pages 689–699, 2018. \n[14] Maryam Fazel, Rong Ge, Sham M Kakade, and Mehran Mesbahi. Global convergence of policy gradient methods for the linear quadratic regulator. arXiv preprint arXiv:1801.05039, 2018. \n[15] Saeed Ghadimi, Andrzej Ruszczynski, and Mengdi Wang. A single timescale stochastic approximation method for nested stochastic optimization. SIAM Journal on Optimization, 30(1):960–979, 2020. \n[16] Elad Hazan, Sham Kakade, Karan Singh, and Abby Van Soest. Provably efficient maximum entropy exploration. In International Conference on Machine Learning, pages 2681–2691. PMLR, 2019. \n[17] Zhouyuan Huo, Bin Gu, Ji Liu, and Heng Huang. Accelerated method for stochastic composition optimization with nonsmooth regularization. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 32, 2018. \n[18] Sashank J Reddi, Suvrit Sra, Barnabas Poczos, and Alexander J Smola. Proximal stochastic methods for nonsmooth nonconvex finite-sum optimization. Advances in neural information processing systems, 29:1145–1153, 2016. \n[19] Rie Johnson and Tong Zhang. Accelerating stochastic gradient descent using predictive variance reduction. Advances in neural information processing systems, 26:315–323, 2013. \n[20] Sham M Kakade. A natural policy gradient. Advances in neural information processing systems, 14:1531–1538, 2001. \n[21] Vijay R Konda and John N Tsitsiklis. Actor-critic algorithms. In Advances in neural information processing systems, pages 1008–1014, 2000. \n[22] Vijaymohan R Konda and Vivek S Borkar. Actor-critic–type learning algorithms for markov decision processes. SIAM Journal on control and Optimization, 38(1):94–123, 1999. \n[23] Guanghui Lan. Policy mirror descent for reinforcement learning: Linear convergence, new sampling complexity, and generalized problem classes. arXiv preprint arXiv:2102.00135, 2021. \n[24] Xiangru Lian, Mengdi Wang, and Ji Liu. Finite-sum composition optimization via variance reduced gradient descent. In Artificial Intelligence and Statistics, pages 1159–1167. PMLR, 2017. \n[25] Boyi Liu, Qi Cai, Zhuoran Yang, and Zhaoran Wang. Neural trust region/proximal policy optimization attains globally optimal policy. In Advances in Neural Information Processing Systems, pages 10565–10576, 2019. \n[26] Jincheng Mei, Chenjun Xiao, Csaba Szepesvari, and Dale Schuurmans. On the global convergence rates of softmax policy gradient methods. arXiv preprint arXiv:2005.06392, 2020. ",
|
| 1473 |
+
"bbox": [
|
| 1474 |
+
179,
|
| 1475 |
+
580,
|
| 1476 |
+
828,
|
| 1477 |
+
912
|
| 1478 |
+
],
|
| 1479 |
+
"page_idx": 9
|
| 1480 |
+
},
|
| 1481 |
+
{
|
| 1482 |
+
"type": "text",
|
| 1483 |
+
"text": "",
|
| 1484 |
+
"bbox": [
|
| 1485 |
+
171,
|
| 1486 |
+
49,
|
| 1487 |
+
828,
|
| 1488 |
+
919
|
| 1489 |
+
],
|
| 1490 |
+
"page_idx": 10
|
| 1491 |
+
},
|
| 1492 |
+
{
|
| 1493 |
+
"type": "text",
|
| 1494 |
+
"text": "[27] Sobhan Miryoosefi, Kianté Brantley, Hal Daume III, Miro Dudik, and Robert E Schapire. Reinforcement learning with convex constraints. In Advances in Neural Information Processing Systems, pages 14093–14102, 2019. ",
|
| 1495 |
+
"bbox": [
|
| 1496 |
+
171,
|
| 1497 |
+
90,
|
| 1498 |
+
823,
|
| 1499 |
+
133
|
| 1500 |
+
],
|
| 1501 |
+
"page_idx": 11
|
| 1502 |
+
},
|
| 1503 |
+
{
|
| 1504 |
+
"type": "text",
|
| 1505 |
+
"text": "[28] Volodymyr Mnih, Adria Puigdomenech Badia, Mehdi Mirza, Alex Graves, Timothy Lillicrap, Tim Harley, David Silver, and Koray Kavukcuoglu. Asynchronous methods for deep reinforcement learning. In International conference on machine learning, pages 1928–1937, 2016. ",
|
| 1506 |
+
"bbox": [
|
| 1507 |
+
173,
|
| 1508 |
+
142,
|
| 1509 |
+
826,
|
| 1510 |
+
199
|
| 1511 |
+
],
|
| 1512 |
+
"page_idx": 11
|
| 1513 |
+
},
|
| 1514 |
+
{
|
| 1515 |
+
"type": "text",
|
| 1516 |
+
"text": "[29] Lam M Nguyen, Jie Liu, Katya Scheinberg, and Martin Takác. Sarah: A novel method for ˇ machine learning problems using stochastic recursive gradient. arXiv preprint arXiv:1703.00102, 2017. ",
|
| 1517 |
+
"bbox": [
|
| 1518 |
+
173,
|
| 1519 |
+
209,
|
| 1520 |
+
825,
|
| 1521 |
+
251
|
| 1522 |
+
],
|
| 1523 |
+
"page_idx": 11
|
| 1524 |
+
},
|
| 1525 |
+
{
|
| 1526 |
+
"type": "text",
|
| 1527 |
+
"text": "[30] Lam M Nguyen, Marten van Dijk, Dzung T Phan, Phuong Ha Nguyen, Tsui-Wei Weng, and Jayant R Kalagnanam. Finite-sum smooth optimization with sarah. arXiv preprint arXiv:1901.07648, 2019. ",
|
| 1528 |
+
"bbox": [
|
| 1529 |
+
173,
|
| 1530 |
+
261,
|
| 1531 |
+
825,
|
| 1532 |
+
304
|
| 1533 |
+
],
|
| 1534 |
+
"page_idx": 11
|
| 1535 |
+
},
|
| 1536 |
+
{
|
| 1537 |
+
"type": "text",
|
| 1538 |
+
"text": "[31] Matteo Papini, Damiano Binaghi, Giuseppe Canonaco, Matteo Pirotta, and Marcello Restelli. Stochastic variance-reduced policy gradient. arXiv preprint arXiv:1806.05618, 2018. ",
|
| 1539 |
+
"bbox": [
|
| 1540 |
+
173,
|
| 1541 |
+
313,
|
| 1542 |
+
825,
|
| 1543 |
+
343
|
| 1544 |
+
],
|
| 1545 |
+
"page_idx": 11
|
| 1546 |
+
},
|
| 1547 |
+
{
|
| 1548 |
+
"type": "text",
|
| 1549 |
+
"text": "[32] Jan Peters and Stefan Schaal. Natural actor-critic. Neurocomputing, 71(7-9):1180–1190, 2008. ",
|
| 1550 |
+
"bbox": [
|
| 1551 |
+
174,
|
| 1552 |
+
352,
|
| 1553 |
+
825,
|
| 1554 |
+
367
|
| 1555 |
+
],
|
| 1556 |
+
"page_idx": 11
|
| 1557 |
+
},
|
| 1558 |
+
{
|
| 1559 |
+
"type": "text",
|
| 1560 |
+
"text": "[33] Nhan H Pham, Lam M Nguyen, Dzung T Phan, Phuong Ha Nguyen, Marten van Dijk, and Quoc Tran-Dinh. A hybrid stochastic policy gradient algorithm for reinforcement learning. arXiv preprint arXiv:2003.00430, 2020. ",
|
| 1561 |
+
"bbox": [
|
| 1562 |
+
176,
|
| 1563 |
+
377,
|
| 1564 |
+
823,
|
| 1565 |
+
420
|
| 1566 |
+
],
|
| 1567 |
+
"page_idx": 11
|
| 1568 |
+
},
|
| 1569 |
+
{
|
| 1570 |
+
"type": "text",
|
| 1571 |
+
"text": "[34] Sashank J Reddi, Ahmed Hefny, Suvrit Sra, Barnabas Poczos, and Alex Smola. Stochastic variance reduction for nonconvex optimization. In International conference on machine learning, pages 314–323, 2016. ",
|
| 1572 |
+
"bbox": [
|
| 1573 |
+
176,
|
| 1574 |
+
429,
|
| 1575 |
+
823,
|
| 1576 |
+
472
|
| 1577 |
+
],
|
| 1578 |
+
"page_idx": 11
|
| 1579 |
+
},
|
| 1580 |
+
{
|
| 1581 |
+
"type": "text",
|
| 1582 |
+
"text": "[35] Sashank J Reddi, Suvrit Sra, Barnabás Póczos, and Alex Smola. Fast incremental method for nonconvex optimization. arXiv preprint arXiv:1603.06159, 2016. ",
|
| 1583 |
+
"bbox": [
|
| 1584 |
+
174,
|
| 1585 |
+
481,
|
| 1586 |
+
823,
|
| 1587 |
+
511
|
| 1588 |
+
],
|
| 1589 |
+
"page_idx": 11
|
| 1590 |
+
},
|
| 1591 |
+
{
|
| 1592 |
+
"type": "text",
|
| 1593 |
+
"text": "[36] Mark Schmidt, Nicolas Le Roux, and Francis Bach. Minimizing finite sums with the stochastic average gradient. Mathematical Programming, 162(1-2):83–112, 2017. ",
|
| 1594 |
+
"bbox": [
|
| 1595 |
+
174,
|
| 1596 |
+
518,
|
| 1597 |
+
823,
|
| 1598 |
+
549
|
| 1599 |
+
],
|
| 1600 |
+
"page_idx": 11
|
| 1601 |
+
},
|
| 1602 |
+
{
|
| 1603 |
+
"type": "text",
|
| 1604 |
+
"text": "[37] John Schulman, Sergey Levine, Pieter Abbeel, Michael Jordan, and Philipp Moritz. Trust region policy optimization. In International conference on machine learning, pages 1889–1897, 2015. ",
|
| 1605 |
+
"bbox": [
|
| 1606 |
+
176,
|
| 1607 |
+
558,
|
| 1608 |
+
823,
|
| 1609 |
+
588
|
| 1610 |
+
],
|
| 1611 |
+
"page_idx": 11
|
| 1612 |
+
},
|
| 1613 |
+
{
|
| 1614 |
+
"type": "text",
|
| 1615 |
+
"text": "[38] John Schulman, Filip Wolski, Prafulla Dhariwal, Alec Radford, and Oleg Klimov. Proximal policy optimization algorithms. arXiv preprint arXiv:1707.06347, 2017. ",
|
| 1616 |
+
"bbox": [
|
| 1617 |
+
174,
|
| 1618 |
+
595,
|
| 1619 |
+
825,
|
| 1620 |
+
626
|
| 1621 |
+
],
|
| 1622 |
+
"page_idx": 11
|
| 1623 |
+
},
|
| 1624 |
+
{
|
| 1625 |
+
"type": "text",
|
| 1626 |
+
"text": "[39] Lior Shani, Yonathan Efroni, and Shie Mannor. Adaptive trust region policy optimization: Global convergence and faster rates for regularized mdps. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 34, pages 5668–5675, 2020. ",
|
| 1627 |
+
"bbox": [
|
| 1628 |
+
174,
|
| 1629 |
+
635,
|
| 1630 |
+
825,
|
| 1631 |
+
679
|
| 1632 |
+
],
|
| 1633 |
+
"page_idx": 11
|
| 1634 |
+
},
|
| 1635 |
+
{
|
| 1636 |
+
"type": "text",
|
| 1637 |
+
"text": "[40] Zebang Shen, Alejandro Ribeiro, Hamed Hassani, Hui Qian, and Chao Mi. Hessian aided policy gradient. In International Conference on Machine Learning, pages 5729–5738, 2019. ",
|
| 1638 |
+
"bbox": [
|
| 1639 |
+
173,
|
| 1640 |
+
686,
|
| 1641 |
+
825,
|
| 1642 |
+
717
|
| 1643 |
+
],
|
| 1644 |
+
"page_idx": 11
|
| 1645 |
+
},
|
| 1646 |
+
{
|
| 1647 |
+
"type": "text",
|
| 1648 |
+
"text": "[41] Aaron Sidford, Mengdi Wang, Xian Wu, Lin F Yang, and Yinyu Ye. Near-optimal time and sample complexities for solving discounted markov decision process with a generative model. arXiv preprint arXiv:1806.01492, 2018. ",
|
| 1649 |
+
"bbox": [
|
| 1650 |
+
174,
|
| 1651 |
+
726,
|
| 1652 |
+
823,
|
| 1653 |
+
768
|
| 1654 |
+
],
|
| 1655 |
+
"page_idx": 11
|
| 1656 |
+
},
|
| 1657 |
+
{
|
| 1658 |
+
"type": "text",
|
| 1659 |
+
"text": "[42] Aaron Sidford, Mengdi Wang, Xian Wu, and Yinyu Ye. Variance reduced value iteration and faster algorithms for solving markov decision processes. In Proceedings of the Twenty-Ninth Annual ACM-SIAM Symposium on Discrete Algorithms, pages 770–787. SIAM, 2018. ",
|
| 1660 |
+
"bbox": [
|
| 1661 |
+
173,
|
| 1662 |
+
777,
|
| 1663 |
+
825,
|
| 1664 |
+
821
|
| 1665 |
+
],
|
| 1666 |
+
"page_idx": 11
|
| 1667 |
+
},
|
| 1668 |
+
{
|
| 1669 |
+
"type": "text",
|
| 1670 |
+
"text": "[43] Richard S Sutton and Andrew G Barto. Reinforcement learning: An introduction. MIT press, 2018. ",
|
| 1671 |
+
"bbox": [
|
| 1672 |
+
171,
|
| 1673 |
+
830,
|
| 1674 |
+
825,
|
| 1675 |
+
859
|
| 1676 |
+
],
|
| 1677 |
+
"page_idx": 11
|
| 1678 |
+
},
|
| 1679 |
+
{
|
| 1680 |
+
"type": "text",
|
| 1681 |
+
"text": "[44] Richard S Sutton, David A McAllester, Satinder P Singh, and Yishay Mansour. Policy gradient methods for reinforcement learning with function approximation. In Advances in neural information processing systems, pages 1057–1063, 2000. ",
|
| 1682 |
+
"bbox": [
|
| 1683 |
+
174,
|
| 1684 |
+
868,
|
| 1685 |
+
826,
|
| 1686 |
+
911
|
| 1687 |
+
],
|
| 1688 |
+
"page_idx": 11
|
| 1689 |
+
},
|
| 1690 |
+
{
|
| 1691 |
+
"type": "text",
|
| 1692 |
+
"text": "[45] Mengdi Wang, Ethan X Fang, and Han Liu. Stochastic compositional gradient descent: algorithms for minimizing compositions of expected-value functions. Mathematical Programming, 161(1-2):419–449, 2017. \n[46] Mengdi Wang, Ji Liu, and Ethan X Fang. Accelerating stochastic composition optimization. The Journal of Machine Learning Research, 18(1):3721–3743, 2017. \n[47] Ronald J Williams. Simple statistical gradient-following algorithms for connectionist reinforcement learning. Machine learning, 8(3-4):229–256, 1992. \n[48] Pan Xu, Felicia Gao, and Quanquan Gu. Sample efficient policy gradient methods with recursive variance reduction. arXiv preprint arXiv:1909.08610, 2019. \n[49] Pan Xu, Felicia Gao, and Quanquan Gu. An improved convergence analysis of stochastic variance-reduced policy gradient. In Uncertainty in Artificial Intelligence, pages 541–551. PMLR, 2020. \n[50] Junyu Zhang, Amrit Singh Bedi, Mengdi Wang, and Alec Koppel. Cautious reinforcement learning via distributional risk in the dual domain. arXiv preprint arXiv:2002.12475, 2020. \n[51] Junyu Zhang, Alec Koppel, Amrit Singh Bedi, Csaba Szepesvari, and Mengdi Wang. Variational policy gradient method for reinforcement learning with general utilities. arXiv preprint arXiv:2007.02151, 2020. \n[52] Junyu Zhang and Lin Xiao. A composite randomized incremental gradient method. In International Conference on Machine Learning, pages 7454–7462, 2019. \n[53] Junyu Zhang and Lin Xiao. Multi-level composite stochastic optimization via nested variance reduction. arXiv preprint arXiv:1908.11468, 2019. \n[54] Junyu Zhang and Lin Xiao. A stochastic composite gradient method with incremental variance reduction. In Advances in Neural Information Processing Systems, pages 9078–9088, 2019. \n[55] Junzi Zhang, Jongho Kim, Brendan O’Donoghue, and Stephen Boyd. Sample efficient reinforcement learning with reinforce. arXiv preprint arXiv:2010.11364, 2020. \n[56] Kaiqing Zhang, Alec Koppel, Hao Zhu, and Tamer Ba¸sar. Global convergence of policy gradient methods to (almost) locally optimal policies. arXiv preprint arXiv:1906.08383, 2019. \n[57] Mingming Zhao, Yongfeng Li, and Zaiwen Wen. A stochastic trust-region framework for policy optimization. arXiv preprint arXiv:1911.11640, 2019. \n[58] Tingting Zhao, Hirotaka Hachiya, Gang Niu, and Masashi Sugiyama. Analysis and improvement of policy gradient estimation. Neural Networks, 26:118–129, 2012. ",
|
| 1693 |
+
"bbox": [
|
| 1694 |
+
171,
|
| 1695 |
+
89,
|
| 1696 |
+
828,
|
| 1697 |
+
652
|
| 1698 |
+
],
|
| 1699 |
+
"page_idx": 12
|
| 1700 |
+
}
|
| 1701 |
+
]
|
parse/train/Re_VXFOyyO/Re_VXFOyyO_middle.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
parse/train/Re_VXFOyyO/Re_VXFOyyO_model.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
parse/train/r1f0YiCctm/r1f0YiCctm.md
ADDED
|
@@ -0,0 +1,256 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# MINIMAL RANDOM CODE LEARNING: GETTING BITS BACK FROM COMPRESSED MODEL PARAMETERS
|
| 2 |
+
|
| 3 |
+
Marton Havasi Department of Engineering University of Cambridge mh740@cam.ac.uk
|
| 4 |
+
|
| 5 |
+
Robert Peharz Department of Engineering University of Cambridge rp587@cam.ac.uk
|
| 6 |
+
|
| 7 |
+
Jose Miguel Hern ´ andez-Lobato ´
|
| 8 |
+
Department of Engineering
|
| 9 |
+
University of Cambridge,
|
| 10 |
+
Microsoft Research,
|
| 11 |
+
Alan Turing Institute
|
| 12 |
+
jmh233@cam.ac.uk
|
| 13 |
+
|
| 14 |
+
# ABSTRACT
|
| 15 |
+
|
| 16 |
+
While deep neural networks are a highly successful model class, their large memory footprint puts considerable strain on energy consumption, communication bandwidth, and storage requirements. Consequently, model size reduction has become an utmost goal in deep learning. A typical approach is to train a set of deterministic weights, while applying certain techniques such as pruning and quantization, in order that the empirical weight distribution becomes amenable to Shannon-style coding schemes. However, as shown in this paper, relaxing weight determinism and using a full variational distribution over weights allows for more efficient coding schemes and consequently higher compression rates. In particular, following the classical bits-back argument, we encode the network weights using a random sample, requiring only a number of bits corresponding to the KullbackLeibler divergence between the sampled variational distribution and the encoding distribution. By imposing a constraint on the Kullback-Leibler divergence, we are able to explicitly control the compression rate, while optimizing the expected loss on the training set. The employed encoding scheme can be shown to be close to the optimal information-theoretical lower bound, with respect to the employed variational family. Our method sets new state-of-the-art in neural network compression, as it strictly dominates previous approaches in a Pareto sense: On the benchmarks LeNet-5/MNIST and VGG-16/CIFAR-10, our approach yields the best test performance for a fixed memory budget, and vice versa, it achieves the highest compression rates for a fixed test performance.
|
| 17 |
+
|
| 18 |
+
# 1 INTRODUCTION
|
| 19 |
+
|
| 20 |
+
With the celebrated success of deep learning models and their ever increasing presence, it has become a key challenge to increase their efficiency. In particular, the rather substantial memory requirements in neural networks can often conflict with storage and communication constraints, especially in mobile applications. Moreover, as discussed in Han et al. (2015), memory accesses are up to three orders of magnitude more costly than arithmetic operations in terms of energy consumption. Thus, compressing deep learning models has become a priority goal with a beneficial economic and ecological impact.
|
| 21 |
+
|
| 22 |
+
Traditional approaches to model compression usually rely on three main techniques: pruning, quantization and coding. For example, Deep Compression (Han et al., 2016) proposes a pipeline employing all three of these techniques in a systematic manner. From an information-theoretic perspective, the central routine is coding, while pruning and quantization can be seen as helper heuristics to reduce the entropy of the empirical weight-distribution, leading to shorter encoding lengths (Shannon, 1948). Also, the recently proposed Bayesian Compression (Louizos et al., 2017) falls into this scheme, despite being motivated by the so-called bits-back argument (Hinton & Van Camp, 1993) which theoretically allows for higher compression rates.1 While the bits-back argument certainly motivated the use of variational inference in Bayesian Compression, the downstream encoding is still akin to Deep Compression (and other approaches). In particular, the variational distribution is merely used to derive a deterministic set of weights, which is subsequently encoded with Shannonstyle coding. This approach, however, does not fully exploit the coding efficiency postulated by the bits-back argument.
|
| 23 |
+
|
| 24 |
+
In this paper, we step aside from the pruning-quantization pipeline and propose a novel coding method which approximately realizes bits-back efficiency. In particular, we refrain from constructing a deterministic weight-set but rather encode a random weight-set from the full variational posterior. This is fundamentally different from first drawing a weight-set and subsequently encoding it – this would be no more efficient than previous approaches. Rather, the coding scheme developed here is allowed to pick a random weight-set which can be cheaply encoded. By using results from Harsha et al. (2010), we show that such an coding scheme always exists and that the bits-back argument indeed represents a theoretical lower bound for its coding efficiency. Moreover, we propose a practical scheme which produces an approximate sample from the variational distribution and which can indeed be encoded with this efficiency. Since our algorithm learns a distribution over weightsets and derives a random message from it, while minimizing the resulting code length, we dub it Minimal Random Code Learning (MIRACLE).
|
| 25 |
+
|
| 26 |
+
From a practical perspective, MIRACLE has the advantage that it offers explicit control over the expected loss and the compression size. This is distinct from previous techniques, which require tedious tuning of various hyper-parameters and/or thresholds in order to achieve a certain coding goal. In our method, we can simply control the KL-divergence using a penalty factor, which directly reflects the achieved code length (plus a small overhead), while simultaneously optimizing the expected training loss. As a result, we were able to trace the trade-off curve for compression size versus classification performance (Figure 1). We clearly outperform previous state-of-the-art in a Pareto sense: For any desired compression rate, our encoding achieves better performance on the test set; vice versa, for a certain performance on the test set, our method achieves the highest compression. To summarize, our main contributions are:
|
| 27 |
+
|
| 28 |
+
• We introduce MIRACLE, an innovative compression algorithm that exploits the noise resistance of deep learning models by training a variational distribution and efficiently encodes a random set of weights.
|
| 29 |
+
• Our method is easy to implement and offers explicit control over the loss and the compression size.
|
| 30 |
+
• We provide theoretical justification that our algorithm gets close to the theoretical lower bound on the encoding length.
|
| 31 |
+
• The potency of MIRACLE is demonstrated on two common compression tasks, where it clearly outperforms previous state-of-the-art methods for compressing neural networks.
|
| 32 |
+
|
| 33 |
+
In the following section, we discuss related work and introduce required background. In Section 3 we introduce our method. Section 4 presents our experimental results and Section 5 concludes the paper.
|
| 34 |
+
|
| 35 |
+
# 2 RELATED WORK
|
| 36 |
+
|
| 37 |
+
There is an ample amount of research on compressing neural networks, so that we will only discuss the most prominent ones, and those which are related to our work. An early approach is Optimal Brain Damage (LeCun et al., 1990) which employs the Hessian of the network weights in order to determine whether weights can be pruned without significantly impacting training performance. A related but simpler approach was proposed in Han et al. (2015), where small weights are truncated to zero, alternated with re-training. This simple approach yielded – somewhat surprisingly – networks which are one order of magnitude smaller, without impairing performance. The approach was refined into a systematic pipeline called Deep Compression, where magnitude-based weight pruning is followed by weight quantization (clustering weights) and Huffman coding (Huffman, 1952). While its compression ratio $\sim 5 0 \times$ ) has been surpassed since, many of the subsequent works took lessons from this paper.
|
| 38 |
+
|
| 39 |
+
HashNet proposed by Chen et al. (2015) also follows a simple and surprisingly effective approach: They exploit the fact that training of neural networks is resistant to imposing random constraints on the weights. In particular, they use hashing to enforce groups of weights to share the same value, yielding memory reductions of up to $6 4 \times$ with gracefully degrading performance. Weightless encoding by Reagen et al. (2018) demonstrates that neural networks are resilient to weight noise, and exploits this fact for a lossy compression algorithm. The recently proposed Bayesian Compression (Louizos et al., 2017) uses a Bayesian variational framework and is motivated by the bits-back argument (Hinton & Van Camp, 1993). Since this work is the closest to ours, albeit with important differences, we discuss Bayesian Compression and the bits-back argument in more detail.
|
| 40 |
+
|
| 41 |
+
The basic approach is to equip the network weights $\pmb { w }$ with a prior $p$ and to approximate the posterior using the standard variational framework, i.e. maximize the evidence lower bound (ELBO) for a given dataset $\mathcal { D }$
|
| 42 |
+
|
| 43 |
+
$$
|
| 44 |
+
\mathbb { E } _ { q _ { \phi } } [ \log p ( \mathcal { D } | \boldsymbol { w } ) ] - \mathrm { K L } ( q _ { \phi } | | p ) ,
|
| 45 |
+
$$
|
| 46 |
+
|
| 47 |
+
w.r.t. the variational distribution $q _ { \phi }$ , parameterized by $\phi$ . The bits-back argument (Hinton & Van Camp, 1993) establishes a connection between the Bayesian variational framework and the Minimum Description Length (MDL) principle (Grunwald, 2007). Assuming a large dataset ¨ $\mathcal { D }$ of input-target pairs, we aim to use the neural network to transmit the targets with a minimal message, while the inputs are assumed to be public. To this end, we draw a weight-set $\ b { w } ^ { * }$ from $q _ { \phi }$ , which has been obtained by maximizing (1); note that knowing a particular weight $\ b { w } ^ { * }$ set conveys a message of length $\mathrm { H } [ q _ { \phi } ]$ (H refers to the Shannon entropy of the distribution). The weight-set $\ b { w } ^ { * }$ is used to encode the residual of the targets, and is itself encoded with the prior distribution $p$ , yielding a message of length $\mathbb { E } _ { q _ { \phi } } [ - \log p ( \mathcal { D } | \pmb { w } ) ] + \mathbb { E } _ { q _ { \phi } } [ \log p ]$ . This message allows the receiver to perfectly reconstruct the original targets, and consequently the variational distribution $q _ { \phi }$ , by running the same (deterministic) algorithm as used by the sender. Consequently, with $q _ { \phi }$ at hand, the receiver is able to retrieve an auxiliary message encoded in $\ b { w } ^ { * }$ . When subtracting the length of this “free message” from the original $\mathbb { E } _ { q _ { \phi } } [ \log p ]$ nats,2 we yield a net cost of $\begin{array} { r } { \mathrm { K L } ( q _ { \phi } | | \boldsymbol { \bar { p } } ) = \mathbb { E } _ { q _ { \phi } } [ \log \frac { q _ { \phi } } { p } ] } \end{array}$ nats for encoding the weights, i.e. we recover the ELBO (1) as negative MDL (Hinton & Van Camp, 1993).
|
| 48 |
+
|
| 49 |
+
In (Hinton & Zemel, 1994; Frey & Hinton, 1997) coding schemes were proposed which practically exploited the bits-back argument for the purpose of coding data. However, it is not clear how these free bits can be spent solely for the purpose of model compression, as we only want to store a representation of our model, while discarding the training data. Therefore, while Bayesian Compression is certainly motivated by the bits-back argument, it actually does not strive for the postulated coding efficiency $\mathrm { K L } ( q _ { \phi } | | p )$ . Rather, this method imposes a sparsity inducing prior distribution to aid the pruning process. Moreover, high posterior variance is translated into reduced precision which constitutes a heuristic for quantization. In the end, Bayesian Compression merely produces a deterministic weight-set $\ b { w } ^ { * }$ which is encoded similar as in preceding works.
|
| 50 |
+
|
| 51 |
+
In particular, all previous approaches essentially use the following coding scheme, or a (sometimes sub-optimal) variant of it. After a deterministic weight-set $\ b { w } ^ { * }$ has been obtained, involving potential pruning and quantization techniques, one interprets $\ b { w } ^ { * }$ as a sequence of i.i.d. variables, taking values from a finite alphabet. Then one assumes the coding distribution $\begin{array} { r } { p ^ { \prime } ( w ) = \frac { 1 } { N } \sum _ { i = 1 } ^ { N } \delta _ { w _ { i } ^ { * } } ( w ) } \end{array}$ where denotes the Kronecker delta at . According to Shannon’s source coding theorem (Shannon, 1948), $\ b { w } ^ { * }$ can be coded with no less than $N \mathrm { H } [ p ^ { \prime } ]$ nats, which is asymptotically achieved by Huffman coding, like in Han et al. (2016). Note that the Shannon lower bound can be written as
|
| 52 |
+
|
| 53 |
+
$$
|
| 54 |
+
N \mathrm { H } [ p ^ { \prime } ] = - \sum _ { i = 1 } ^ { N } \log p ^ { \prime } ( w _ { i } ^ { * } ) = - \log p ^ { \prime } ( w ^ { * } ) = \sum _ { w } \delta _ { w ^ { * } } ( w ) \log \frac { \delta _ { w ^ { * } } ( w ) } { p ^ { \prime } ( w ) } = \mathrm { K L } ( \delta _ { w ^ { * } } | | p ^ { \prime } ) ,
|
| 55 |
+
$$
|
| 56 |
+
|
| 57 |
+
where we have set $\begin{array} { r } { p ^ { \prime } ( \pmb { w } ) = \prod _ { i } p ^ { \prime } ( \pmb { w } _ { i } ) } \end{array}$ . Thus, these Shannon-style coding schemes are in some sense optimal, when the variational family is restricted to point-measures, i.e. deterministic weights. By extending the variational family to comprise more general distributions $q$ , the coding length $\mathrm { K L } ( q | | p )$ could be drastically reduced. In the following, we develop such a method which exploits the uncertainty represented by $q$ in order to encode a random weight-set with short coding length.
|
| 58 |
+
|
| 59 |
+
# 3 MINIMAL RANDOM CODE LEARNING
|
| 60 |
+
|
| 61 |
+
Consider the scenario where we want to train a neural network but our memory budget is constrained to $C$ nats. As illustrated in the previous section, a variational approach offers – in principle – a simple and elegant solution. Before we proceed, we note that we do not consider our approach to be a strictly Bayesian one, but rather based on the MDL principle, although these two are of course highly related (Grunwald, 2007). In particular, we refer to ¨ $p$ as an encoding distribution rather than a prior, and moreover we will use a framework akin to the $\beta$ -VAE (Higgins et al., 2017) which better reflects our goal of efficient coding. The crucial difference to the $\beta$ -VAE being that we encode parameters rather than data.
|
| 62 |
+
|
| 63 |
+
Now, similar to Louizos et al. (2017), we first fix a suitable network architecture, select an encoding distribution $p$ and a parameterized variational family $q _ { \phi }$ for the network weights $\textbf { \em w }$ . We consider, however, a slightly different variational objective related to the $\beta$ -VAE:
|
| 64 |
+
|
| 65 |
+
$$
|
| 66 |
+
\mathcal { L } ( \phi ) = \underbrace { \mathbb { E } _ { q _ { \phi } } [ \log p ( \mathcal { D } | \boldsymbol { w } ) ] } _ { \mathrm { n e g a t i v e ~ l o s s } } - \beta \underbrace { \mathrm { K L } ( q _ { \phi } | | p ) } _ { \mathrm { m o d e l ~ c o m p l e x i t y } } .
|
| 67 |
+
$$
|
| 68 |
+
|
| 69 |
+
This objective directly reflects our goal of achieving both a good training performance (loss term) and being able to represent our model with a short code (model complexity), at least according to the bits-back argument. After obtaining $q _ { \phi }$ by maximizing (3), a weight-set drawn from $q _ { \phi }$ will perform comparable to a deterministically trained network, since the variance of the negative loss term will be comparatively small to the mean, and since the KL term regularizes the model. Thus, our declared goal is to draw a sample from $q _ { \phi }$ such that this sample can be encoded as efficiently as possible. This problem can be formulated as the following communication problem.
|
| 70 |
+
|
| 71 |
+
Alice observes a training data set $( X , Y ) = { \mathcal { D } }$ drawn from an unknown distribution $p ( D )$ . She trains a variational distribution $q _ { \phi } ( { \pmb w } )$ by optimizing (3) for a given $\beta$ using a deterministic algorithm. Subsequently, she wishes to send a message $M ( \mathcal D )$ to Bob, which allows him to generate a sample distributed according to $q _ { \phi }$ . How long does this message need to be?
|
| 72 |
+
|
| 73 |
+
The answer to this question depends on the unknown data distribution $p ( D )$ , so we need to make an assumption about it. Since the variational parameters $\phi$ depend on the realized dataset $\mathcal { D }$ , we can interpret the variational distribution as a conditional distribution $q ( { \pmb w } | D ) : = q _ { \phi } ( { \pmb w } )$ , giving rise to the joint $q ( { \pmb w } , D ) = q ( { \pmb w } | D ) p ( D )$ . Now, our assumption about $p ( D )$ is that $\begin{array} { r } { \int q ( { \pmb w } | \mathcal { D } ) p ( \mathcal { D } ) \mathrm { d } \mathcal { D } = } \end{array}$ $p ( \pmb { w } )$ , that is, the variational distribution $q _ { \phi }$ yields the assumed encoding distribution $p ( \pmb { w } )$ , when averaged over all possible datasets. Note that this a similar strong assumption as in a Bayesian setting, where we assume that the data distribution is given as $\begin{array} { r } { p ( \boldsymbol { D } ) = \bar { \int } p ( \boldsymbol { D } | \boldsymbol { w } ) p ( \boldsymbol { w } ) \mathrm { d } \bar { \boldsymbol { w } } } \end{array}$ . In this setting, it follows immediately from the data processing inequality (Harsha et al., 2010) that in expectation the message length $| M |$ cannot be smaller than $\mathrm { K L } ( q _ { \phi } | | p )$ :
|
| 74 |
+
|
| 75 |
+
$$
|
| 76 |
+
\mathbb { E } _ { D } [ | M | ] \ge \mathrm { H } [ M ] \ge \mathrm { I } [ D : M ] \ge \mathrm { I } [ D : w ] = \int \mathrm { K L } ( q ( w | \mathcal { D } ) | | p ( w ) ) \mathrm { d } \mathcal { D } = \mathbb { E } _ { D } [ \mathrm { K L } ( q _ { \phi } | | p ) ] ,
|
| 77 |
+
$$
|
| 78 |
+
|
| 79 |
+
where I refers to the mutual information and in the third inequality we applied the data processing inequality for Markov chain $D \to M \to w$ . As discussed by Harsha et al. (2010), the inequality $\mathbb { E } _ { D } [ | \dot { M } | ] \ge \mathbb { E } _ { D } [ \mathrm { K L } ( q _ { \phi } | | p ) ]$ can be very loose. However, as they further show, the message length can be brought close to the lower bound, $i f$ Alice and Bob are allowed to share a source of randomness:
|
| 80 |
+
|
| 81 |
+
Theorem 3.1 (Harsha et al. (2010)) Given random variables $D$ , $\pmb { w }$ and a random string $R$ , let a protocol $\Pi$ be defined via a message function $M ( D , R )$ and a decoder function $w ( M , R )$ , i.e. $\Pi ( D ) = { \pmb w } ( M ( D , R ) , R )$ . Let $\mathrm { T } _ { \Pi } ( D ) : = \mathbb { E } _ { R } [ | { \cal M } ( D , R ) | ]$ be the expected message length for data $D$ , and let the minimal expected message length be defined as
|
| 82 |
+
|
| 83 |
+
$$
|
| 84 |
+
\operatorname { T } [ D : \pmb { w } ] : = \operatorname* { m i n } _ { \Pi } ~ \mathbb { E } _ { D } [ T _ { \Pi } ( D ) ] ,
|
| 85 |
+
$$
|
| 86 |
+
|
| 87 |
+
where $\Pi$ ranges over all protocols such that $D , w$ and $D , \Pi ( D )$ have the same distribution. Then
|
| 88 |
+
|
| 89 |
+
$$
|
| 90 |
+
\begin{array} { r } { \operatorname { I } [ D : w ] \leq \operatorname { T } [ D : w ] \leq \operatorname { I } [ D : w ] + 2 \log ( \operatorname { I } [ D : w ] + 1 ) + O ( 1 ) . } \end{array}
|
| 91 |
+
$$
|
| 92 |
+
|
| 93 |
+
The results of Harsha et al. (2010) establish a characterization of the mutual information in terms of minimal coding a conditional sample. For our purposes, Theorem 3.1 guarantees that in principle
|
| 94 |
+
|
| 95 |
+
# Algorithm 1 Minimal Random Coding
|
| 96 |
+
|
| 97 |
+
<table><tr><td>1:</td><td>procedure ENCODE(q,p)</td></tr><tr><td>2:</td><td>K ← exp(KL(qΦllp)) K-1</td></tr><tr><td>3:</td><td>draw K samples {wk}k-1, wk ~ p</td></tr><tr><td>4:</td><td>ak←q(wk) p(wk)</td></tr><tr><td>5:</td><td>q(wk) := ak for k ∈{0...K-1}</td></tr><tr><td>6:</td><td>draw a sample wk* ~ q</td></tr><tr><td>7:</td><td>return wk*, k*</td></tr><tr><td></td><td>8:end procedure</td></tr><tr><td></td><td></td></tr></table>
|
| 98 |
+
|
| 99 |
+
there is an algorithm which realizes near bits-back efficiency. Furthermore, the theorem shows that this is indeed a fundamental lower bound, i.e. that such an algorithm is optimal for the considered setting. To this end, we need to refer to a “common ground”, i.e. a shared random source $\mathcal { R }$ , where w.l.o.g. we can assume that this source is an infinite list of samples from our encoding distribution $p$ . In practice, this can be realized via a pseudo-random generator with a public seed.
|
| 100 |
+
|
| 101 |
+
# 3.1 THE BASIC ALGORITHM
|
| 102 |
+
|
| 103 |
+
While Harsha et al. (2010) provide a constructive proof using a variant of rejection sampling (see Appendix A), this algorithm is in fact intractable, because it requires keeping track of the acceptance probabilities over the whole sample domain. Therefore, we propose an alternative method to produce an approximate sample from $q _ { \phi }$ , depicted in Algorithm 1. This algorithm takes as inputs the trained variational distribution $q _ { \phi }$ and the encoding distribution $p$ . We first draw $K = \exp ( \mathrm { K L } ( q _ { \phi } | | p ) )$ samples from $p$ , using the shared random generator. Subsequently, we craft a discrete proxy distribution $\tilde { q }$ , which has support only on these $K$ samples, and where the probability mass for each sample is proportional to the importance weights $\begin{array} { r } { a _ { k } = \frac { q _ { \phi } ( \pmb { w } _ { k } ) } { p ( \pmb { w } _ { k } ) } } \end{array}$ . Finally, we draw a sample from $\tilde { q }$ and return its index $k ^ { * }$ and the sample ${ \pmb w } _ { k ^ { * } }$ itself. Since any number $0 \leq k ^ { * } < K$ can be easily encoded with $\mathrm { K L } ( q _ { \phi } | | p )$ nats, we achieve our aimed coding efficiency. Decoding the sample is easy: simply draw the $k ^ { * \mathrm { t h } }$ sample ${ \pmb w } _ { k ^ { * } }$ from the shared random generator (e.g. by resetting the random seed).
|
| 104 |
+
|
| 105 |
+
While this algorithm is remarkably simple and easy to implement, there is of course the question of whether it is a correct thing to do. Moreover, an immediate caveat is that the number $K$ of required samples grows exponentially in $\mathrm { K L } ( q _ { \phi } | | p )$ , which is clearly infeasible for encoding a practical neural network. The first point is addressed in the next section, while the latter is discussed in Section 3.3, together with other practical considerations.
|
| 106 |
+
|
| 107 |
+
# 3.2 THEORETICAL ANALYSIS
|
| 108 |
+
|
| 109 |
+
The proxy distribution $\tilde { q }$ in Algorithm 1 is based on an importance sampling scheme, as its probability masses are defined to be proportional to the usual importance weights $\begin{array} { r } { a _ { k } = \frac { q _ { \phi } ( { \pmb w } _ { k } ) } { p ( { \pmb w } _ { k } ) } } \end{array}$ . Under mild assumptions $( q _ { \phi } , p$ continuous; $a _ { k } < \infty ,$ ) it is easy to verify that $\tilde { q }$ converges to $q _ { \phi }$ in distribution for $K \infty$ ; thus in the limit, Algorithm 1 samples from the correct distribution. However, since we collect only $K = \exp ( \mathrm { K L } ( q _ { \phi } | \bar { | } p ) )$ samples in order to achieve a short coding length, $\tilde { q }$ will be biased. Fortunately, it turns out that $K$ is just in the right order for this bias to be small.
|
| 110 |
+
|
| 111 |
+
Theorem 3.2 (Low Bias of Proxy Distribution) Let $q _ { \phi }$ , p be distributions over $\pmb { w }$ . Let $t \geq 0$ and $\tilde { q }$ be a discrete distribution constructed by drawing $K = \exp ( \mathrm { K L } ( q _ { \phi } | | p ) + t )$ samples $\{ w _ { k } \} _ { k = 0 } ^ { K - 1 }$ from p and defining q˜(wk) := P qφ(wk)/p(wk)0 qφ(wk0 )/p(w 0 ) . Furthermore, let $f ( w )$ be a measurable function and $| | f | | _ { q _ { \phi } } = \sqrt { \mathbb { E } _ { q _ { \phi } } [ f ^ { 2 } ] }$ be its 2-norm under $q _ { \phi }$ . Then it holds that
|
| 112 |
+
|
| 113 |
+
$$
|
| 114 |
+
\mathbb { P } \left( \left| \mathbb { E } _ { \tilde { q } } [ f ] - \mathbb { E } _ { q _ { \phi } } [ f ] \right| \geq \frac { 2 \vert \vert f \vert \vert _ { q _ { \phi } } \epsilon } { 1 - \epsilon } \right) \leq 2 \epsilon
|
| 115 |
+
$$
|
| 116 |
+
|
| 117 |
+
where
|
| 118 |
+
|
| 119 |
+
$$
|
| 120 |
+
\epsilon = \left( e ^ { - t / 4 } + 2 \sqrt { \mathbb { P } \left( \log \left( q \phi / p \right) > \mathrm { K L } \left( q _ { \phi } | | p \right) + t / 2 \right) } \right) ^ { 1 / 2 } .
|
| 121 |
+
$$
|
| 122 |
+
|
| 123 |
+
# Algorithm 2 Minimal Random Code Learning (MIRACLE)
|
| 124 |
+
|
| 125 |
+
<table><tr><td colspan="3">procedure LEARN(D,model with parameters w,C,Cloc, Io,I)</td></tr><tr><td>1: 2:</td><td>randomly split w into B = blocks {wo,...wB-1} Coc</td><td></td></tr><tr><td>3: 4:</td><td>O←{0,...,B-1} βb ←∈βo,forb∈{0,...,B-1}</td><td>> The blocks that have not yet been encoded</td></tr><tr><td>5:</td><td>VARIATIONAL UPDATES(IO)</td><td></td></tr><tr><td>6:</td><td>while O≠ do</td><td></td></tr><tr><td>7:</td><td>draw random b from O</td><td></td></tr><tr><td>8:</td><td></td><td></td></tr><tr><td>9:</td><td>○←0/{b}</td><td> from Algorithm 1</td></tr><tr><td></td><td>w*,kb=ENCODE(q(wb),p(wb))</td><td></td></tr><tr><td>10:</td><td>Wb ← w* (fixing the value of wb)</td><td></td></tr><tr><td>11:</td><td>VARIATIONAL UPDATES(I)</td><td></td></tr><tr><td>12:</td><td>end while</td><td></td></tr><tr><td>13: 14:</td><td>return [ko,..., kB-1]</td><td></td></tr><tr><td>end procedure</td><td></td><td></td></tr><tr><td></td><td></td><td></td></tr><tr><td>15: 16:</td><td>procedure VARIATIONAL UPDATES(I)</td><td></td></tr><tr><td></td><td>LO := Eqt({ub}b∈o)[logp(D|w)] -∑b∈o βKL(q(wb)llp(wb))</td><td></td></tr><tr><td>17:</td><td>for i ∈[0,...,I-1] do</td><td></td></tr><tr><td>18:</td><td>Perform stochastic gradient update of Lo</td><td></td></tr><tr><td>19:</td><td>for b ∈Odo</td><td></td></tr><tr><td>20:</td><td>if KL(q(wb)llp(wb))> Ctoc then</td><td></td></tr><tr><td>21:</td><td>βb←(1+∈β)×βb</td><td></td></tr><tr><td>22:</td><td>else</td><td></td></tr><tr><td>23:</td><td></td><td></td></tr><tr><td>24:</td><td>βb←βb/(1+∈β)</td><td></td></tr><tr><td>25:</td><td>end if</td><td></td></tr><tr><td></td><td>end for</td><td></td></tr><tr><td>26:</td><td>end for</td><td></td></tr><tr><td>27:</td><td></td><td></td></tr><tr><td></td><td>end procedure</td><td></td></tr><tr><td></td><td></td><td></td></tr><tr><td></td><td></td><td></td></tr><tr><td></td><td></td><td></td></tr><tr><td></td><td></td><td></td></tr><tr><td></td><td></td><td></td></tr></table>
|
| 126 |
+
|
| 127 |
+
Theorem 3.2 is a corollary of Chatterjee & Diaconis (2018), Theorem 1.2, by noting that
|
| 128 |
+
|
| 129 |
+
$$
|
| 130 |
+
\mathbb { E } _ { \tilde { q } } [ f ] = \frac { 1 } { \sum _ { k ^ { \prime } } \frac { q _ { \phi } ( { \pmb w } _ { k ^ { \prime } } ) } { p ( { \pmb w } _ { k ^ { \prime } } ) } } \sum _ { k } f ( { \pmb w } _ { k } ) \frac { q _ { \phi } ( { \pmb w } _ { k } ) } { p ( { \pmb w } _ { k } ) } ,
|
| 131 |
+
$$
|
| 132 |
+
|
| 133 |
+
which is precisely the importance sampling estimator for unnormalized distributions (denoted as $J _ { n }$ in (Chatterjee & Diaconis, 2018)), i.e. their Theorem 1.2 directly yields Theorem 3.2. Note that the term $\bar { e } ^ { - t / 4 }$ decays quickly with $t$ , and, since $\log { q _ { \phi } } / p$ is typically concentrated around its expected value $\mathrm { K L } ( q | | p )$ , the second term in (8) also quickly becomes negligible. Thus, roughly speaking, Theorem 3.2 establishes that $\mathbb { E } _ { q _ { \phi } } [ f ] \approx \mathbb { E } _ { \widetilde { q } } [ f ]$ with high probability, for any measurable function $f$ . This is in particular true for the function $\begin{array} { r } { f ( \pmb { w } ) = \log p ( \mathcal { D } | \pmb { w } ) - \beta \log \frac { q _ { \phi } ( \pmb { w } ) } { p ( \pmb { w } ) } } \end{array}$ . Note that the expectation of this function is just the variational objective (3) we optimized to yield $q _ { \phi }$ in the first place. Thus, since $\mathbb { E } _ { \tilde { q } } [ f ] \approx \mathbb { E } _ { q _ { \phi } } [ f ] = \mathcal { L } ( \phi )$ , replacing $q _ { \phi }$ by $\tilde { q }$ is well justified. Thereby, any sample of $\tilde { q }$ can trivially be encoded with $\mathrm { K L } ( q _ { \phi } | | p )$ nats, and decoded by simple reference to a pseudo-random generator.
|
| 134 |
+
|
| 135 |
+
Note that according to Theorem 3.2 we should actually take a number of samples somewhat larger than $\exp ( \mathrm { K L } ( q _ { \phi } | | p ) )$ in order to make $\epsilon$ sufficiently small. In particular, the results in (Chatterjee & Diaconis, 2018) also imply that a too small number of samples will typically be quite off the targeted expectation (for the worst-case $f$ ). However, although our choice of number of samples is at a critical point, in our experiments this number of samples yielded very good results.
|
| 136 |
+
|
| 137 |
+
# 3.3 PRACTICAL IMPLEMENTATION
|
| 138 |
+
|
| 139 |
+
In this section, we describe the application of Algorithm 1 within a practical learning algorithm – Minimal Random Code Learning (MIRACLE) – depicted in Algorithm 2. For both $q _ { \phi }$ and $p$ we used Gaussians with diagonal covariance matrices. For $q _ { \phi }$ , all means and standard deviations constituted the variational parameters $\phi$ . The mean of $p$ was fixed to zero, and the standard deviation was shared within each layer of the encoded network. These shared parameters of $p$ where learned jointly with $q _ { \phi }$ , i.e. the encoding distribution was also adapted to the task. This choice of distributions allowed us to use the reparameterization trick for effective variational training and furthermore, $\mathrm { K L } ( q _ { \phi } | | p )$ can be computed analytically.
|
| 140 |
+
|
| 141 |
+

|
| 142 |
+
Figure 1: The error rate and the compression size for various compression methods. Lower left is better.
|
| 143 |
+
|
| 144 |
+
Since generating $K = \exp ( \mathrm { K L } ( q _ { \phi } | | p ) )$ samples is infeasible for any reasonable $\mathrm { K L } ( q _ { \phi } | | p )$ , we divided the overall problem into sub-problems. To this end, we set a global coding goal of $C$ nats and a local coding goal of $C _ { l o c }$ nats. We randomly split the weight vector $\textbf { \em w }$ into $\begin{array} { r } { B \ = \ \lceil \frac { C } { C _ { l o c } } \rceil } \end{array}$ equally sized blocks, and assigned each block an allowance of $C _ { l o c }$ nats. For example, fixing $C _ { l o c }$ to 11.09 nats $\approx 1 6$ bits, corresponds to $K = 6 5 5 3 6$ samples which need to be drawn per block. We imposed block-wise KL constraints using block-wise penalty factors $\beta _ { b }$ , which were automatically annealed via multiplication/division with $( 1 + \epsilon _ { \beta } )$ during the variational updates (see Algorithm 2). Note that the random splitting into $B$ blocks can be efficiently coded via the shared random generator, and only the number $B$ needs communicated.
|
| 145 |
+
|
| 146 |
+
Before encoding any weights, we made sure that variational learning had converged by training for a large number of iterations $I _ { 0 } = 1 0 ^ { 4 }$ . After that, we alternated between encoding single blocks and updating the variational distribution not-yet coded weights, by spending $I$ intermediate variational iterations. To this end, we define a variational objective $\mathcal { L } _ { \mathcal { O } }$ w.r.t. to blocks which have not been coded yet, while weights of already encoded blocks were fixed to their encoded value. Intuitively, this allows to compensate for poor choices in earlier encoded blocks, and was crucial for good performance. Theoretically, this amounts to a rich auto-regressive variational family $q _ { \phi }$ , as the blocks which remain to be updated are effectively conditioned on the weights which have already been encoded. We also found that the hashing trick (Chen et al., 2015) further improves performance (not depicted in Algorithm 2 for simplicity). The hashing trick randomly conditions weights to share the same value. While Chen et al. (2015) apply it to reduce the entropy, in our case it helps to restrict the optimization space and reduces the dimensionality of both $p$ and $q _ { \phi }$ . We found that this typically improves the compression rate by a factor of $\sim 1 . 5 \times$ .
|
| 147 |
+
|
| 148 |
+
# 4 EXPERIMENTAL RESULTS
|
| 149 |
+
|
| 150 |
+
The experiments3 were conducted on two common benchmarks: LeNet-5 on MNIST and VGG-16 on CIFAR-10. As baselines we used three recent state-of-the-art methods, namely Deep Compression (Han et al., 2016), Weightless encoding (Reagen et al., 2018) and Bayesian Compression (Louizos et al., 2017). The performance of the baseline methods are quoted from their respective source materials.
|
| 151 |
+
|
| 152 |
+
Table 1: Numerical performance of the compression algorithms.
|
| 153 |
+
|
| 154 |
+
<table><tr><td>Model</td><td>Compression</td><td>Size</td><td>Ratio</td><td>Test error</td></tr><tr><td rowspan="6">LeNet-5on MNIST</td><td>Uncompressed model</td><td>1720 kB</td><td>1×</td><td>0.7 %</td></tr><tr><td>Deep Compression</td><td>44 kB</td><td>39×</td><td>0.8 %</td></tr><tr><td>Weightless 5</td><td>4.52 kB</td><td>382×</td><td>1.0 %</td></tr><tr><td>Bayesian Compression</td><td>2.3 kB</td><td>771×</td><td>1.0 %</td></tr><tr><td>MIRACLE (Lowest error)</td><td>3.03 kB</td><td>555×</td><td>0.69 %</td></tr><tr><td>MIRACLE (Highest compression)</td><td>1.52 kB</td><td>1110×</td><td>0.96 %</td></tr><tr><td rowspan="5">VGG-16 on CIFAR-10</td><td>Uncompressed model</td><td>60 MB</td><td>1×</td><td>6.5 %</td></tr><tr><td>Bayesian Compression</td><td>642 kB</td><td>95×</td><td>8.6 %</td></tr><tr><td>Bayesian Compression</td><td>525 kB</td><td>116×</td><td>9.2 %</td></tr><tr><td>MIRACLE (Lowest error)</td><td>417kB</td><td>147×</td><td>6.57 %</td></tr><tr><td>MIRACLE (Highest compression)</td><td>168 kB</td><td>365×</td><td>10.0 %</td></tr></table>
|
| 155 |
+
|
| 156 |
+
For training MIRACLE, we used Adam (Kingma & Ba, 2014) with the default learning rate $( 1 0 ^ { - 3 } )$ and we set $\dot { \epsilon } _ { \beta 0 } = 1 0 ^ { - 8 }$ and $\epsilon _ { \beta } = 5 \times 1 0 ^ { - 5 }$ . For VGG, the means of the weights were initialized using a pretrained model.4 We recommend applying the hashing trick mainly to reduce the size of the largest layers. In particular, we applied the hashing trick was to layers 2 and 3 in LeNet-5 to reduce their sizes by $2 \times$ and $6 4 \times$ respectively and to layers 10-16 in VGG to reduce their sizes $8 \times$ . The local coding goal $C _ { l o c }$ was fixed at 20 bits for LeNet-5 and it was varied between 15 and 5 bits for VGG ( $B$ was kept constant). For the number of intermediate variational updates $I$ , we used $I = 5 0$ for LeNet-5 and $I = 1$ for VGG, in order to keep training time reasonable $\approx 1$ day on a single NVIDIA P100 for VGG).
|
| 157 |
+
|
| 158 |
+
The performance trade-offs (test error rate and compression size) of MIRACLE along with the baseline methods and the uncompressed model are shown in Figure 1 and Table 1. For MIRACLE we can easily construct the Pareto frontier, by starting with a large coding goal $C$ (i.e. allowing a large coding length) and successively reducing it. Constructing such a Pareto frontier for other methods is delicate, as it requires re-tuning hyper-parameters which are often only indirectly related to the compression size – for MIRACLE it is directly reflected via the KL-term. We see that MIRACLE is Pareto-better than the competitors: for a given test error rate, we achieve better compression, while for a given model size we achieve lower test error.
|
| 159 |
+
|
| 160 |
+
# 5 CONCLUSION
|
| 161 |
+
|
| 162 |
+
In this paper we followed through the philosophy of the bits-back argument for the goal of coding model parameters. The basic insight here is that restricting to a single deterministic weight-set and aiming to coding it in a classic Shannon-style is greedy and in fact sub-optimal. Neural networks – and other deep learning models – are highly overparameterized, and consequently there are many “good” parameterizations. Thus, rather than focusing on a single weight set, we showed that this fact can be exploited for coding, by selecting a “cheap” weight set out of the set of “good” ones. Our algorithm is backed by solid recent information-theoretic insights, yet it is simple to implement. We demonstrated that the presented coding algorithm clearly outperforms previous state-of-the-art. An important question remaining for future work is how efficient MIRACLE can be made in terms of memory accesses and consequently for energy consumption and inference time. There lies clear potential in this direction, as any single weight can be recovered by its block-index and relative index within each block. By smartly keeping track of these addresses, and using pseudo-random generators as algorithmic lookup-tables, we could design an inference machine which is able to directly run our compressed models, which might lead to considerable savings in memory accesses.
|
| 163 |
+
|
| 164 |
+
# ACKNOWLEDGEMENTS
|
| 165 |
+
|
| 166 |
+
We want to thank Christian Steinruecken, Oliver Janzer, Kris Stensbo-Smidt and Siddharth Swaroop ´ for their helpful comments. This project has received funding from the European Union’s Horizon 2020 research and innovation programme under the Marie Skłodowska-Curie Grant Agreement No. 797223 — HYBSPN. Furthermore, we acknowledge EPSRC and Intel for their support.
|
| 167 |
+
|
| 168 |
+
# REFERENCES
|
| 169 |
+
|
| 170 |
+
S. Chatterjee and P. Diaconis. The sample size required in importance sampling. The Annals of Applied Probability, 28(2):1099–1135, 2018.
|
| 171 |
+
W. Chen, J. Wilson, S. Tyree, K. Weinberger, and Y. Chen. Compressing neural networks with the hashing trick. In Proceedings of ICML, pp. 2285–2294, 2015.
|
| 172 |
+
B. J. Frey and G. E. Hinton. Efficient stochastic source coding and an application to a bayesian network source model. The Computer Journal, 40(2 and 3):157–165, 1997.
|
| 173 |
+
P. D. Grunwald. ¨ The minimum description length principle. MIT press, 2007.
|
| 174 |
+
Song Han, Jeff Pool, John Tran, and William Dally. Learning both weights and connections for efficient neural network. In Advances in Neural Information Processing Systems (NIPS), pp. 1135–1143, 2015.
|
| 175 |
+
Song Han, Huizi Mao, and William J Dally. Deep compression: Compressing deep neural networks with pruning, trained quantization and huffman coding. International Conference on Learning Representations (ICLR), 2016.
|
| 176 |
+
P. Harsha, R. Jain, D. McAllester, and J. Radhakrishnan. The communication complexity of correlation. IEEE Transactions on Information Theory, 1(56):438–449, 2010.
|
| 177 |
+
I. Higgins, L. Matthey, A. Pal, C. Burgess, X. Glorot, M. Botvinick, S. Mohamed, and A. Lerchner. Beta-VAE: Learning basic visual concepts with a constrained variational framework. In ICLR, 2017.
|
| 178 |
+
G. E. Hinton and D. Van Camp. Keeping the neural networks simple by minimizing the description length of the weights. In Proceedings of the sixth annual conference on Computational learning theory, pp. 5–13. ACM, 1993.
|
| 179 |
+
G. E. Hinton and R. S. Zemel. Autoencoders, minimum description length and helmholtz free energy. In Proceedings of NIPS, pp. 3–10, 1994.
|
| 180 |
+
David A Huffman. A method for the construction of minimum-redundancy codes. Proceedings of the IRE, 40(9):1098–1101, 1952.
|
| 181 |
+
D. P. Kingma and J. Ba. Adam: A method for stochastic optimization. arXiv preprint arXiv:1412.6980, 2014.
|
| 182 |
+
Y. LeCun, J. S. Denker, and S. A. Solla. Optimal brain damage. In Proceedings of NIPS, pp. 598–605, 1990.
|
| 183 |
+
C. Louizos, K. Ullrich, and M. Welling. Bayesian compression for deep learning. In Proceedings of NIPS, pp. 3288–3298, 2017.
|
| 184 |
+
B. Reagen, U. Gupta, R. Adolf, M. M. Mitzenmacher, A. M. Rush, G.-Y. Wei, and D. Brooks. Weightless: Lossy weight encoding for deep neural network compression. International Conference on Machine Learning, 2018.
|
| 185 |
+
C. E. Shannon. A mathematical theory of communication. Bell System Technical Journal, 27(3): 379–423, 1948.
|
| 186 |
+
P. M. B. Vitanyi and M. Li. An introduction to Kolmogorov complexity and its applications, volume 34. Springer Heidelberg, 1997.
|
| 187 |
+
|
| 188 |
+
# Algorithm 3 Greedy Rejection Sampling
|
| 189 |
+
|
| 190 |
+
1: procedure SAMPLE(q, p)
|
| 191 |
+
2: $p _ { 0 } ( { \pmb w } ) 0$ for $\pmb { w } \in \mathcal { W }$
|
| 192 |
+
3: $p _ { 0 } ^ { * } \gets 0$
|
| 193 |
+
4: for $i \gets 0$ to $\infty$ do
|
| 194 |
+
5: $\begin{array} { r l } & { \alpha _ { i } ( \pmb { w } ) \operatorname* { m i n } \{ q ( \pmb { w } ) - p _ { i - 1 } ( \pmb { w } ) , ( 1 - p _ { i - 1 } ^ { * } ) p ( \pmb { w } ) \} } \\ & { p _ { i } ( \pmb { w } ) p _ { i - 1 } ( \pmb { w } ) + \alpha _ { i } ( \pmb { w } ) } \\ & { p _ { i } ^ { * } \sum _ { \pmb { w } \in \mathscr { W } } p _ { i } ( \pmb { w } ) } \\ & { \mathrm { d r a w ~ s a m p l e ~ } \pmb { w } _ { i } \sim p } \\ & { \beta _ { i } \frac { \alpha _ { i } ( \pmb { w } _ { i } ) } { ( 1 - p _ { i - 1 } ^ { * } ) p ( \pmb { w } _ { i } ) } } \end{array}$
|
| 195 |
+
6:
|
| 196 |
+
7:
|
| 197 |
+
8:
|
| 198 |
+
9:
|
| 199 |
+
10: draw $\epsilon \sim \mathcal { U } ( 0 , 1 )$
|
| 200 |
+
11: if $\epsilon \leq \beta _ { i }$ then
|
| 201 |
+
12: return ${ \pmb w } _ { i }$ , $i$
|
| 202 |
+
13: end if
|
| 203 |
+
14: end for
|
| 204 |
+
15: end procedure
|
| 205 |
+
|
| 206 |
+
# A GREEDY REJECTION SAMPLING BY HARSHA ET AL. (2010)
|
| 207 |
+
|
| 208 |
+
In order to prove the upper bound, to which Harsha et al. (2010) refer as the ‘one-shot reverse Shannon theorem’, they exhibit a rejection sampling procedure. However, instead of using the classical rejection with acceptance probabilities $\frac { q } { M p }$ where $\begin{array} { r } { M = \operatorname* { m a x } { \frac { q } { p } } } \end{array}$ , they propose a greedier version. The core idea is that every sample should be accepted with as high probability as possible while keeping the overall acceptance probability of each element below the target distribution.
|
| 209 |
+
|
| 210 |
+
For this algorithm we assume discrete $p$ and $q$ over the set $\mathcal { W }$ and an infinite sequence of samples $\{ w _ { i } \} _ { i = 1 } ^ { \infty }$ from $p$ .
|
| 211 |
+
|
| 212 |
+
Let $\alpha _ { i } ( \pmb { w } )$ with $i \in \mathrm { N }$ and $\pmb { w } \in \mathcal { W }$ be the probability that the procedure outputs the ith sample with ${ \pmb w } _ { i } = { \pmb w }$ . For the sampling method to be unbiased, we have to ensure that
|
| 213 |
+
|
| 214 |
+
$$
|
| 215 |
+
q ( { \pmb w } ) = \sum _ { i = 0 } ^ { \infty } \alpha _ { i } ( { \pmb w } ) .
|
| 216 |
+
$$
|
| 217 |
+
|
| 218 |
+
Let $\begin{array} { r } { p _ { i } ( { \pmb w } ) = \sum _ { j = 0 } ^ { i } \alpha _ { j } ( { \pmb w } ) } \end{array}$ be the probability that the procedure halts within $j \le i$ iteration and it outputs ${ \pmb w } _ { j } = { \pmb w }$ . Let $\begin{array} { r } { p _ { i } ^ { * } = \sum _ { w \in \mathcal { W } } p _ { i } ( w ) } \end{array}$ be the probability that procedure halts within $i$ iterations. Let
|
| 219 |
+
|
| 220 |
+
$$
|
| 221 |
+
\begin{array} { r l } & { \alpha _ { i } ( \pmb { w } ) = \operatorname* { m i n } \{ q ( \pmb { w } ) - p _ { i - 1 } ( \pmb { w } ) , ( 1 - p _ { i - 1 } ^ { * } ) p ( \pmb { w } ) \} } \\ & { p _ { i } ( \pmb { w } ) = p _ { i - 1 } ( \pmb { w } ) + \alpha _ { i } ( \pmb { w } ) . } \end{array}
|
| 222 |
+
$$
|
| 223 |
+
|
| 224 |
+
Since $P ( \pmb { w } _ { i } = \pmb { w } ) = p ( \pmb { w } )$ , $\alpha _ { i } ( \pmb { w } )$ can be at most $( 1 - p _ { i - 1 } ^ { * } ) p ( \pmb { w } )$ . The proposed strategy is greedy because it accepts the ith sample with as high probability as possible under the constraint that $\begin{array} { r } { \dot { p _ { i } } ( { \pmb w } ) \leq q ( { \pmb w } ) } \end{array}$ .
|
| 225 |
+
|
| 226 |
+
Under the proposed formula for $\alpha _ { i } ( \pmb { w } )$ , the acceptance probability for the $i$ th sample ${ \pmb w } _ { i }$ is
|
| 227 |
+
|
| 228 |
+
$$
|
| 229 |
+
\beta _ { i } = \frac { \alpha _ { i } ( { \pmb w } _ { i } ) } { ( 1 - p _ { i - 1 } ^ { * } ) p ( { \pmb w } ) }
|
| 230 |
+
$$
|
| 231 |
+
|
| 232 |
+
The pseudo code is shown in Algorithm 3. Note that the algorithm requires computing $\alpha _ { i } ( { \pmb w } )$ for the whole set $\mathcal { W }$ in every iteration which makes it intractable for large $\mathcal { W }$ .
|
| 233 |
+
|
| 234 |
+
# A.1 PROOF OUTLINE
|
| 235 |
+
|
| 236 |
+
For the details of the proof, please refer to the source material (Harsha et al., 2010).
|
| 237 |
+
|
| 238 |
+
To show that the procedure is unbiased, one has to prove that
|
| 239 |
+
|
| 240 |
+
$$
|
| 241 |
+
q ( { \pmb w } ) = \operatorname* { l i m } _ { i \infty } p _ { i } ( { \pmb w } ) .
|
| 242 |
+
$$
|
| 243 |
+
|
| 244 |
+
This is shown by proving that $q ( \pmb { w } ) - p _ { i } ( \pmb { w } ) \leq q ( \pmb { w } ) ( 1 - p ( \pmb { w } ) ) ^ { i } \mathrm { \ : f o r \ : } i \in \mathrm { N } .$
|
| 245 |
+
|
| 246 |
+
In order to bound the encoding length, one has to first show that if the accepted sample has index $^ { i * }$ , then
|
| 247 |
+
|
| 248 |
+
$$
|
| 249 |
+
\begin{array} { r } { \operatorname { E } [ \log i ^ { * } ] \leq \operatorname { K L } ( q | | p ) + O ( 1 ) . } \end{array}
|
| 250 |
+
$$
|
| 251 |
+
|
| 252 |
+
Following this, one can employ the prefix-free binary encoding of Vitanyi & Li (1997). Let $l ( n )$ be the length of the encoding for $n \in \mathrm { N }$ using the encoding scheme proposed by Vitanyi $\&$ Li (1997). Their method is proven to have $| l ( n ) | = \bar { \log { n } } + 2 \bar { \log { \log ( n + \bar { 1 } ) } } \bar { + } O ( 1 )$ , from which the upper bound follows:
|
| 253 |
+
|
| 254 |
+
$$
|
| 255 |
+
\begin{array} { r } { \mathrm { T } ^ { \mathcal { R } } [ D : W ] \leq \mathrm { E } | l ( i ^ { * } ) | \leq \mathrm { K L } ( q | | p ) + 2 \log ( \mathrm { K L } ( q | | p ) + 1 ) + O ( 1 ) . } \end{array}
|
| 256 |
+
$$
|
parse/train/r1f0YiCctm/r1f0YiCctm_content_list.json
ADDED
|
@@ -0,0 +1,1120 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
[
|
| 2 |
+
{
|
| 3 |
+
"type": "text",
|
| 4 |
+
"text": "MINIMAL RANDOM CODE LEARNING: GETTING BITS BACK FROM COMPRESSED MODEL PARAMETERS ",
|
| 5 |
+
"text_level": 1,
|
| 6 |
+
"bbox": [
|
| 7 |
+
176,
|
| 8 |
+
98,
|
| 9 |
+
823,
|
| 10 |
+
146
|
| 11 |
+
],
|
| 12 |
+
"page_idx": 0
|
| 13 |
+
},
|
| 14 |
+
{
|
| 15 |
+
"type": "text",
|
| 16 |
+
"text": "Marton Havasi Department of Engineering University of Cambridge mh740@cam.ac.uk ",
|
| 17 |
+
"bbox": [
|
| 18 |
+
183,
|
| 19 |
+
170,
|
| 20 |
+
364,
|
| 21 |
+
226
|
| 22 |
+
],
|
| 23 |
+
"page_idx": 0
|
| 24 |
+
},
|
| 25 |
+
{
|
| 26 |
+
"type": "text",
|
| 27 |
+
"text": "Robert Peharz Department of Engineering University of Cambridge rp587@cam.ac.uk ",
|
| 28 |
+
"bbox": [
|
| 29 |
+
385,
|
| 30 |
+
170,
|
| 31 |
+
566,
|
| 32 |
+
227
|
| 33 |
+
],
|
| 34 |
+
"page_idx": 0
|
| 35 |
+
},
|
| 36 |
+
{
|
| 37 |
+
"type": "text",
|
| 38 |
+
"text": "Jose Miguel Hern ´ andez-Lobato ´ \nDepartment of Engineering \nUniversity of Cambridge, \nMicrosoft Research, \nAlan Turing Institute \njmh233@cam.ac.uk ",
|
| 39 |
+
"bbox": [
|
| 40 |
+
588,
|
| 41 |
+
170,
|
| 42 |
+
810,
|
| 43 |
+
253
|
| 44 |
+
],
|
| 45 |
+
"page_idx": 0
|
| 46 |
+
},
|
| 47 |
+
{
|
| 48 |
+
"type": "text",
|
| 49 |
+
"text": "ABSTRACT ",
|
| 50 |
+
"text_level": 1,
|
| 51 |
+
"bbox": [
|
| 52 |
+
454,
|
| 53 |
+
290,
|
| 54 |
+
544,
|
| 55 |
+
305
|
| 56 |
+
],
|
| 57 |
+
"page_idx": 0
|
| 58 |
+
},
|
| 59 |
+
{
|
| 60 |
+
"type": "text",
|
| 61 |
+
"text": "While deep neural networks are a highly successful model class, their large memory footprint puts considerable strain on energy consumption, communication bandwidth, and storage requirements. Consequently, model size reduction has become an utmost goal in deep learning. A typical approach is to train a set of deterministic weights, while applying certain techniques such as pruning and quantization, in order that the empirical weight distribution becomes amenable to Shannon-style coding schemes. However, as shown in this paper, relaxing weight determinism and using a full variational distribution over weights allows for more efficient coding schemes and consequently higher compression rates. In particular, following the classical bits-back argument, we encode the network weights using a random sample, requiring only a number of bits corresponding to the KullbackLeibler divergence between the sampled variational distribution and the encoding distribution. By imposing a constraint on the Kullback-Leibler divergence, we are able to explicitly control the compression rate, while optimizing the expected loss on the training set. The employed encoding scheme can be shown to be close to the optimal information-theoretical lower bound, with respect to the employed variational family. Our method sets new state-of-the-art in neural network compression, as it strictly dominates previous approaches in a Pareto sense: On the benchmarks LeNet-5/MNIST and VGG-16/CIFAR-10, our approach yields the best test performance for a fixed memory budget, and vice versa, it achieves the highest compression rates for a fixed test performance. ",
|
| 62 |
+
"bbox": [
|
| 63 |
+
233,
|
| 64 |
+
321,
|
| 65 |
+
764,
|
| 66 |
+
613
|
| 67 |
+
],
|
| 68 |
+
"page_idx": 0
|
| 69 |
+
},
|
| 70 |
+
{
|
| 71 |
+
"type": "text",
|
| 72 |
+
"text": "1 INTRODUCTION ",
|
| 73 |
+
"text_level": 1,
|
| 74 |
+
"bbox": [
|
| 75 |
+
176,
|
| 76 |
+
640,
|
| 77 |
+
336,
|
| 78 |
+
655
|
| 79 |
+
],
|
| 80 |
+
"page_idx": 0
|
| 81 |
+
},
|
| 82 |
+
{
|
| 83 |
+
"type": "text",
|
| 84 |
+
"text": "With the celebrated success of deep learning models and their ever increasing presence, it has become a key challenge to increase their efficiency. In particular, the rather substantial memory requirements in neural networks can often conflict with storage and communication constraints, especially in mobile applications. Moreover, as discussed in Han et al. (2015), memory accesses are up to three orders of magnitude more costly than arithmetic operations in terms of energy consumption. Thus, compressing deep learning models has become a priority goal with a beneficial economic and ecological impact. ",
|
| 85 |
+
"bbox": [
|
| 86 |
+
174,
|
| 87 |
+
671,
|
| 88 |
+
825,
|
| 89 |
+
768
|
| 90 |
+
],
|
| 91 |
+
"page_idx": 0
|
| 92 |
+
},
|
| 93 |
+
{
|
| 94 |
+
"type": "text",
|
| 95 |
+
"text": "Traditional approaches to model compression usually rely on three main techniques: pruning, quantization and coding. For example, Deep Compression (Han et al., 2016) proposes a pipeline employing all three of these techniques in a systematic manner. From an information-theoretic perspective, the central routine is coding, while pruning and quantization can be seen as helper heuristics to reduce the entropy of the empirical weight-distribution, leading to shorter encoding lengths (Shannon, 1948). Also, the recently proposed Bayesian Compression (Louizos et al., 2017) falls into this scheme, despite being motivated by the so-called bits-back argument (Hinton & Van Camp, 1993) which theoretically allows for higher compression rates.1 While the bits-back argument certainly motivated the use of variational inference in Bayesian Compression, the downstream encoding is still akin to Deep Compression (and other approaches). In particular, the variational distribution is merely used to derive a deterministic set of weights, which is subsequently encoded with Shannonstyle coding. This approach, however, does not fully exploit the coding efficiency postulated by the bits-back argument. ",
|
| 96 |
+
"bbox": [
|
| 97 |
+
174,
|
| 98 |
+
776,
|
| 99 |
+
825,
|
| 100 |
+
887
|
| 101 |
+
],
|
| 102 |
+
"page_idx": 0
|
| 103 |
+
},
|
| 104 |
+
{
|
| 105 |
+
"type": "text",
|
| 106 |
+
"text": "",
|
| 107 |
+
"bbox": [
|
| 108 |
+
174,
|
| 109 |
+
103,
|
| 110 |
+
825,
|
| 111 |
+
172
|
| 112 |
+
],
|
| 113 |
+
"page_idx": 1
|
| 114 |
+
},
|
| 115 |
+
{
|
| 116 |
+
"type": "text",
|
| 117 |
+
"text": "In this paper, we step aside from the pruning-quantization pipeline and propose a novel coding method which approximately realizes bits-back efficiency. In particular, we refrain from constructing a deterministic weight-set but rather encode a random weight-set from the full variational posterior. This is fundamentally different from first drawing a weight-set and subsequently encoding it – this would be no more efficient than previous approaches. Rather, the coding scheme developed here is allowed to pick a random weight-set which can be cheaply encoded. By using results from Harsha et al. (2010), we show that such an coding scheme always exists and that the bits-back argument indeed represents a theoretical lower bound for its coding efficiency. Moreover, we propose a practical scheme which produces an approximate sample from the variational distribution and which can indeed be encoded with this efficiency. Since our algorithm learns a distribution over weightsets and derives a random message from it, while minimizing the resulting code length, we dub it Minimal Random Code Learning (MIRACLE). ",
|
| 118 |
+
"bbox": [
|
| 119 |
+
173,
|
| 120 |
+
181,
|
| 121 |
+
825,
|
| 122 |
+
347
|
| 123 |
+
],
|
| 124 |
+
"page_idx": 1
|
| 125 |
+
},
|
| 126 |
+
{
|
| 127 |
+
"type": "text",
|
| 128 |
+
"text": "From a practical perspective, MIRACLE has the advantage that it offers explicit control over the expected loss and the compression size. This is distinct from previous techniques, which require tedious tuning of various hyper-parameters and/or thresholds in order to achieve a certain coding goal. In our method, we can simply control the KL-divergence using a penalty factor, which directly reflects the achieved code length (plus a small overhead), while simultaneously optimizing the expected training loss. As a result, we were able to trace the trade-off curve for compression size versus classification performance (Figure 1). We clearly outperform previous state-of-the-art in a Pareto sense: For any desired compression rate, our encoding achieves better performance on the test set; vice versa, for a certain performance on the test set, our method achieves the highest compression. To summarize, our main contributions are: ",
|
| 129 |
+
"bbox": [
|
| 130 |
+
174,
|
| 131 |
+
354,
|
| 132 |
+
825,
|
| 133 |
+
492
|
| 134 |
+
],
|
| 135 |
+
"page_idx": 1
|
| 136 |
+
},
|
| 137 |
+
{
|
| 138 |
+
"type": "text",
|
| 139 |
+
"text": "• We introduce MIRACLE, an innovative compression algorithm that exploits the noise resistance of deep learning models by training a variational distribution and efficiently encodes a random set of weights. \n• Our method is easy to implement and offers explicit control over the loss and the compression size. \n• We provide theoretical justification that our algorithm gets close to the theoretical lower bound on the encoding length. \n• The potency of MIRACLE is demonstrated on two common compression tasks, where it clearly outperforms previous state-of-the-art methods for compressing neural networks. ",
|
| 140 |
+
"bbox": [
|
| 141 |
+
217,
|
| 142 |
+
505,
|
| 143 |
+
825,
|
| 144 |
+
645
|
| 145 |
+
],
|
| 146 |
+
"page_idx": 1
|
| 147 |
+
},
|
| 148 |
+
{
|
| 149 |
+
"type": "text",
|
| 150 |
+
"text": "In the following section, we discuss related work and introduce required background. In Section 3 we introduce our method. Section 4 presents our experimental results and Section 5 concludes the paper. ",
|
| 151 |
+
"bbox": [
|
| 152 |
+
176,
|
| 153 |
+
656,
|
| 154 |
+
825,
|
| 155 |
+
699
|
| 156 |
+
],
|
| 157 |
+
"page_idx": 1
|
| 158 |
+
},
|
| 159 |
+
{
|
| 160 |
+
"type": "text",
|
| 161 |
+
"text": "2 RELATED WORK ",
|
| 162 |
+
"text_level": 1,
|
| 163 |
+
"bbox": [
|
| 164 |
+
176,
|
| 165 |
+
718,
|
| 166 |
+
344,
|
| 167 |
+
736
|
| 168 |
+
],
|
| 169 |
+
"page_idx": 1
|
| 170 |
+
},
|
| 171 |
+
{
|
| 172 |
+
"type": "text",
|
| 173 |
+
"text": "There is an ample amount of research on compressing neural networks, so that we will only discuss the most prominent ones, and those which are related to our work. An early approach is Optimal Brain Damage (LeCun et al., 1990) which employs the Hessian of the network weights in order to determine whether weights can be pruned without significantly impacting training performance. A related but simpler approach was proposed in Han et al. (2015), where small weights are truncated to zero, alternated with re-training. This simple approach yielded – somewhat surprisingly – networks which are one order of magnitude smaller, without impairing performance. The approach was refined into a systematic pipeline called Deep Compression, where magnitude-based weight pruning is followed by weight quantization (clustering weights) and Huffman coding (Huffman, 1952). While its compression ratio $\\sim 5 0 \\times$ ) has been surpassed since, many of the subsequent works took lessons from this paper. ",
|
| 174 |
+
"bbox": [
|
| 175 |
+
174,
|
| 176 |
+
751,
|
| 177 |
+
825,
|
| 178 |
+
877
|
| 179 |
+
],
|
| 180 |
+
"page_idx": 1
|
| 181 |
+
},
|
| 182 |
+
{
|
| 183 |
+
"type": "text",
|
| 184 |
+
"text": "",
|
| 185 |
+
"bbox": [
|
| 186 |
+
173,
|
| 187 |
+
103,
|
| 188 |
+
823,
|
| 189 |
+
132
|
| 190 |
+
],
|
| 191 |
+
"page_idx": 2
|
| 192 |
+
},
|
| 193 |
+
{
|
| 194 |
+
"type": "text",
|
| 195 |
+
"text": "HashNet proposed by Chen et al. (2015) also follows a simple and surprisingly effective approach: They exploit the fact that training of neural networks is resistant to imposing random constraints on the weights. In particular, they use hashing to enforce groups of weights to share the same value, yielding memory reductions of up to $6 4 \\times$ with gracefully degrading performance. Weightless encoding by Reagen et al. (2018) demonstrates that neural networks are resilient to weight noise, and exploits this fact for a lossy compression algorithm. The recently proposed Bayesian Compression (Louizos et al., 2017) uses a Bayesian variational framework and is motivated by the bits-back argument (Hinton & Van Camp, 1993). Since this work is the closest to ours, albeit with important differences, we discuss Bayesian Compression and the bits-back argument in more detail. ",
|
| 196 |
+
"bbox": [
|
| 197 |
+
173,
|
| 198 |
+
138,
|
| 199 |
+
825,
|
| 200 |
+
265
|
| 201 |
+
],
|
| 202 |
+
"page_idx": 2
|
| 203 |
+
},
|
| 204 |
+
{
|
| 205 |
+
"type": "text",
|
| 206 |
+
"text": "The basic approach is to equip the network weights $\\pmb { w }$ with a prior $p$ and to approximate the posterior using the standard variational framework, i.e. maximize the evidence lower bound (ELBO) for a given dataset $\\mathcal { D }$ ",
|
| 207 |
+
"bbox": [
|
| 208 |
+
174,
|
| 209 |
+
271,
|
| 210 |
+
825,
|
| 211 |
+
311
|
| 212 |
+
],
|
| 213 |
+
"page_idx": 2
|
| 214 |
+
},
|
| 215 |
+
{
|
| 216 |
+
"type": "equation",
|
| 217 |
+
"img_path": "images/9afa9d34cb98c88f053777d4f47b72e5dcbb60e8dd7de517f3fbabbe05f6f1fa.jpg",
|
| 218 |
+
"text": "$$\n\\mathbb { E } _ { q _ { \\phi } } [ \\log p ( \\mathcal { D } | \\boldsymbol { w } ) ] - \\mathrm { K L } ( q _ { \\phi } | | p ) ,\n$$",
|
| 219 |
+
"text_format": "latex",
|
| 220 |
+
"bbox": [
|
| 221 |
+
392,
|
| 222 |
+
310,
|
| 223 |
+
602,
|
| 224 |
+
329
|
| 225 |
+
],
|
| 226 |
+
"page_idx": 2
|
| 227 |
+
},
|
| 228 |
+
{
|
| 229 |
+
"type": "text",
|
| 230 |
+
"text": "w.r.t. the variational distribution $q _ { \\phi }$ , parameterized by $\\phi$ . The bits-back argument (Hinton & Van Camp, 1993) establishes a connection between the Bayesian variational framework and the Minimum Description Length (MDL) principle (Grunwald, 2007). Assuming a large dataset ¨ $\\mathcal { D }$ of input-target pairs, we aim to use the neural network to transmit the targets with a minimal message, while the inputs are assumed to be public. To this end, we draw a weight-set $\\ b { w } ^ { * }$ from $q _ { \\phi }$ , which has been obtained by maximizing (1); note that knowing a particular weight $\\ b { w } ^ { * }$ set conveys a message of length $\\mathrm { H } [ q _ { \\phi } ]$ (H refers to the Shannon entropy of the distribution). The weight-set $\\ b { w } ^ { * }$ is used to encode the residual of the targets, and is itself encoded with the prior distribution $p$ , yielding a message of length $\\mathbb { E } _ { q _ { \\phi } } [ - \\log p ( \\mathcal { D } | \\pmb { w } ) ] + \\mathbb { E } _ { q _ { \\phi } } [ \\log p ]$ . This message allows the receiver to perfectly reconstruct the original targets, and consequently the variational distribution $q _ { \\phi }$ , by running the same (deterministic) algorithm as used by the sender. Consequently, with $q _ { \\phi }$ at hand, the receiver is able to retrieve an auxiliary message encoded in $\\ b { w } ^ { * }$ . When subtracting the length of this “free message” from the original $\\mathbb { E } _ { q _ { \\phi } } [ \\log p ]$ nats,2 we yield a net cost of $\\begin{array} { r } { \\mathrm { K L } ( q _ { \\phi } | | \\boldsymbol { \\bar { p } } ) = \\mathbb { E } _ { q _ { \\phi } } [ \\log \\frac { q _ { \\phi } } { p } ] } \\end{array}$ nats for encoding the weights, i.e. we recover the ELBO (1) as negative MDL (Hinton & Van Camp, 1993). ",
|
| 231 |
+
"bbox": [
|
| 232 |
+
173,
|
| 233 |
+
330,
|
| 234 |
+
825,
|
| 235 |
+
526
|
| 236 |
+
],
|
| 237 |
+
"page_idx": 2
|
| 238 |
+
},
|
| 239 |
+
{
|
| 240 |
+
"type": "text",
|
| 241 |
+
"text": "In (Hinton & Zemel, 1994; Frey & Hinton, 1997) coding schemes were proposed which practically exploited the bits-back argument for the purpose of coding data. However, it is not clear how these free bits can be spent solely for the purpose of model compression, as we only want to store a representation of our model, while discarding the training data. Therefore, while Bayesian Compression is certainly motivated by the bits-back argument, it actually does not strive for the postulated coding efficiency $\\mathrm { K L } ( q _ { \\phi } | | p )$ . Rather, this method imposes a sparsity inducing prior distribution to aid the pruning process. Moreover, high posterior variance is translated into reduced precision which constitutes a heuristic for quantization. In the end, Bayesian Compression merely produces a deterministic weight-set $\\ b { w } ^ { * }$ which is encoded similar as in preceding works. ",
|
| 242 |
+
"bbox": [
|
| 243 |
+
174,
|
| 244 |
+
532,
|
| 245 |
+
825,
|
| 246 |
+
659
|
| 247 |
+
],
|
| 248 |
+
"page_idx": 2
|
| 249 |
+
},
|
| 250 |
+
{
|
| 251 |
+
"type": "text",
|
| 252 |
+
"text": "In particular, all previous approaches essentially use the following coding scheme, or a (sometimes sub-optimal) variant of it. After a deterministic weight-set $\\ b { w } ^ { * }$ has been obtained, involving potential pruning and quantization techniques, one interprets $\\ b { w } ^ { * }$ as a sequence of i.i.d. variables, taking values from a finite alphabet. Then one assumes the coding distribution $\\begin{array} { r } { p ^ { \\prime } ( w ) = \\frac { 1 } { N } \\sum _ { i = 1 } ^ { N } \\delta _ { w _ { i } ^ { * } } ( w ) } \\end{array}$ where denotes the Kronecker delta at . According to Shannon’s source coding theorem (Shannon, 1948), $\\ b { w } ^ { * }$ can be coded with no less than $N \\mathrm { H } [ p ^ { \\prime } ]$ nats, which is asymptotically achieved by Huffman coding, like in Han et al. (2016). Note that the Shannon lower bound can be written as ",
|
| 253 |
+
"bbox": [
|
| 254 |
+
174,
|
| 255 |
+
665,
|
| 256 |
+
825,
|
| 257 |
+
766
|
| 258 |
+
],
|
| 259 |
+
"page_idx": 2
|
| 260 |
+
},
|
| 261 |
+
{
|
| 262 |
+
"type": "equation",
|
| 263 |
+
"img_path": "images/d4759bc415aabc79eb059f456e5535c9955deaf6ee46fe0a15f07b6ee2c6aec5.jpg",
|
| 264 |
+
"text": "$$\nN \\mathrm { H } [ p ^ { \\prime } ] = - \\sum _ { i = 1 } ^ { N } \\log p ^ { \\prime } ( w _ { i } ^ { * } ) = - \\log p ^ { \\prime } ( w ^ { * } ) = \\sum _ { w } \\delta _ { w ^ { * } } ( w ) \\log \\frac { \\delta _ { w ^ { * } } ( w ) } { p ^ { \\prime } ( w ) } = \\mathrm { K L } ( \\delta _ { w ^ { * } } | | p ^ { \\prime } ) ,\n$$",
|
| 265 |
+
"text_format": "latex",
|
| 266 |
+
"bbox": [
|
| 267 |
+
194,
|
| 268 |
+
770,
|
| 269 |
+
781,
|
| 270 |
+
813
|
| 271 |
+
],
|
| 272 |
+
"page_idx": 2
|
| 273 |
+
},
|
| 274 |
+
{
|
| 275 |
+
"type": "text",
|
| 276 |
+
"text": "where we have set $\\begin{array} { r } { p ^ { \\prime } ( \\pmb { w } ) = \\prod _ { i } p ^ { \\prime } ( \\pmb { w } _ { i } ) } \\end{array}$ . Thus, these Shannon-style coding schemes are in some sense optimal, when the variational family is restricted to point-measures, i.e. deterministic weights. By extending the variational family to comprise more general distributions $q$ , the coding length $\\mathrm { K L } ( q | | p )$ could be drastically reduced. In the following, we develop such a method which exploits the uncertainty represented by $q$ in order to encode a random weight-set with short coding length. ",
|
| 277 |
+
"bbox": [
|
| 278 |
+
174,
|
| 279 |
+
818,
|
| 280 |
+
825,
|
| 281 |
+
888
|
| 282 |
+
],
|
| 283 |
+
"page_idx": 2
|
| 284 |
+
},
|
| 285 |
+
{
|
| 286 |
+
"type": "text",
|
| 287 |
+
"text": "3 MINIMAL RANDOM CODE LEARNING ",
|
| 288 |
+
"text_level": 1,
|
| 289 |
+
"bbox": [
|
| 290 |
+
174,
|
| 291 |
+
102,
|
| 292 |
+
517,
|
| 293 |
+
118
|
| 294 |
+
],
|
| 295 |
+
"page_idx": 3
|
| 296 |
+
},
|
| 297 |
+
{
|
| 298 |
+
"type": "text",
|
| 299 |
+
"text": "Consider the scenario where we want to train a neural network but our memory budget is constrained to $C$ nats. As illustrated in the previous section, a variational approach offers – in principle – a simple and elegant solution. Before we proceed, we note that we do not consider our approach to be a strictly Bayesian one, but rather based on the MDL principle, although these two are of course highly related (Grunwald, 2007). In particular, we refer to ¨ $p$ as an encoding distribution rather than a prior, and moreover we will use a framework akin to the $\\beta$ -VAE (Higgins et al., 2017) which better reflects our goal of efficient coding. The crucial difference to the $\\beta$ -VAE being that we encode parameters rather than data. ",
|
| 300 |
+
"bbox": [
|
| 301 |
+
173,
|
| 302 |
+
132,
|
| 303 |
+
825,
|
| 304 |
+
244
|
| 305 |
+
],
|
| 306 |
+
"page_idx": 3
|
| 307 |
+
},
|
| 308 |
+
{
|
| 309 |
+
"type": "text",
|
| 310 |
+
"text": "Now, similar to Louizos et al. (2017), we first fix a suitable network architecture, select an encoding distribution $p$ and a parameterized variational family $q _ { \\phi }$ for the network weights $\\textbf { \\em w }$ . We consider, however, a slightly different variational objective related to the $\\beta$ -VAE: ",
|
| 311 |
+
"bbox": [
|
| 312 |
+
173,
|
| 313 |
+
251,
|
| 314 |
+
825,
|
| 315 |
+
294
|
| 316 |
+
],
|
| 317 |
+
"page_idx": 3
|
| 318 |
+
},
|
| 319 |
+
{
|
| 320 |
+
"type": "equation",
|
| 321 |
+
"img_path": "images/6d516c31b69bd93f7a9b8e0e2c4f9f7405c61ab8ffb04ee987bfccde83843640.jpg",
|
| 322 |
+
"text": "$$\n\\mathcal { L } ( \\phi ) = \\underbrace { \\mathbb { E } _ { q _ { \\phi } } [ \\log p ( \\mathcal { D } | \\boldsymbol { w } ) ] } _ { \\mathrm { n e g a t i v e ~ l o s s } } - \\beta \\underbrace { \\mathrm { K L } ( q _ { \\phi } | | p ) } _ { \\mathrm { m o d e l ~ c o m p l e x i t y } } .\n$$",
|
| 323 |
+
"text_format": "latex",
|
| 324 |
+
"bbox": [
|
| 325 |
+
354,
|
| 326 |
+
297,
|
| 327 |
+
643,
|
| 328 |
+
337
|
| 329 |
+
],
|
| 330 |
+
"page_idx": 3
|
| 331 |
+
},
|
| 332 |
+
{
|
| 333 |
+
"type": "text",
|
| 334 |
+
"text": "This objective directly reflects our goal of achieving both a good training performance (loss term) and being able to represent our model with a short code (model complexity), at least according to the bits-back argument. After obtaining $q _ { \\phi }$ by maximizing (3), a weight-set drawn from $q _ { \\phi }$ will perform comparable to a deterministically trained network, since the variance of the negative loss term will be comparatively small to the mean, and since the KL term regularizes the model. Thus, our declared goal is to draw a sample from $q _ { \\phi }$ such that this sample can be encoded as efficiently as possible. This problem can be formulated as the following communication problem. ",
|
| 335 |
+
"bbox": [
|
| 336 |
+
173,
|
| 337 |
+
340,
|
| 338 |
+
825,
|
| 339 |
+
439
|
| 340 |
+
],
|
| 341 |
+
"page_idx": 3
|
| 342 |
+
},
|
| 343 |
+
{
|
| 344 |
+
"type": "text",
|
| 345 |
+
"text": "Alice observes a training data set $( X , Y ) = { \\mathcal { D } }$ drawn from an unknown distribution $p ( D )$ . She trains a variational distribution $q _ { \\phi } ( { \\pmb w } )$ by optimizing (3) for a given $\\beta$ using a deterministic algorithm. Subsequently, she wishes to send a message $M ( \\mathcal D )$ to Bob, which allows him to generate a sample distributed according to $q _ { \\phi }$ . How long does this message need to be? ",
|
| 346 |
+
"bbox": [
|
| 347 |
+
174,
|
| 348 |
+
445,
|
| 349 |
+
825,
|
| 350 |
+
502
|
| 351 |
+
],
|
| 352 |
+
"page_idx": 3
|
| 353 |
+
},
|
| 354 |
+
{
|
| 355 |
+
"type": "text",
|
| 356 |
+
"text": "The answer to this question depends on the unknown data distribution $p ( D )$ , so we need to make an assumption about it. Since the variational parameters $\\phi$ depend on the realized dataset $\\mathcal { D }$ , we can interpret the variational distribution as a conditional distribution $q ( { \\pmb w } | D ) : = q _ { \\phi } ( { \\pmb w } )$ , giving rise to the joint $q ( { \\pmb w } , D ) = q ( { \\pmb w } | D ) p ( D )$ . Now, our assumption about $p ( D )$ is that $\\begin{array} { r } { \\int q ( { \\pmb w } | \\mathcal { D } ) p ( \\mathcal { D } ) \\mathrm { d } \\mathcal { D } = } \\end{array}$ $p ( \\pmb { w } )$ , that is, the variational distribution $q _ { \\phi }$ yields the assumed encoding distribution $p ( \\pmb { w } )$ , when averaged over all possible datasets. Note that this a similar strong assumption as in a Bayesian setting, where we assume that the data distribution is given as $\\begin{array} { r } { p ( \\boldsymbol { D } ) = \\bar { \\int } p ( \\boldsymbol { D } | \\boldsymbol { w } ) p ( \\boldsymbol { w } ) \\mathrm { d } \\bar { \\boldsymbol { w } } } \\end{array}$ . In this setting, it follows immediately from the data processing inequality (Harsha et al., 2010) that in expectation the message length $| M |$ cannot be smaller than $\\mathrm { K L } ( q _ { \\phi } | | p )$ : ",
|
| 357 |
+
"bbox": [
|
| 358 |
+
173,
|
| 359 |
+
507,
|
| 360 |
+
825,
|
| 361 |
+
636
|
| 362 |
+
],
|
| 363 |
+
"page_idx": 3
|
| 364 |
+
},
|
| 365 |
+
{
|
| 366 |
+
"type": "equation",
|
| 367 |
+
"img_path": "images/35f9f501e260b9b92ece5a8468e0da8cd17301ec339147b0d1a155455714cc60.jpg",
|
| 368 |
+
"text": "$$\n\\mathbb { E } _ { D } [ | M | ] \\ge \\mathrm { H } [ M ] \\ge \\mathrm { I } [ D : M ] \\ge \\mathrm { I } [ D : w ] = \\int \\mathrm { K L } ( q ( w | \\mathcal { D } ) | | p ( w ) ) \\mathrm { d } \\mathcal { D } = \\mathbb { E } _ { D } [ \\mathrm { K L } ( q _ { \\phi } | | p ) ] ,\n$$",
|
| 369 |
+
"text_format": "latex",
|
| 370 |
+
"bbox": [
|
| 371 |
+
184,
|
| 372 |
+
640,
|
| 373 |
+
792,
|
| 374 |
+
672
|
| 375 |
+
],
|
| 376 |
+
"page_idx": 3
|
| 377 |
+
},
|
| 378 |
+
{
|
| 379 |
+
"type": "text",
|
| 380 |
+
"text": "where I refers to the mutual information and in the third inequality we applied the data processing inequality for Markov chain $D \\to M \\to w$ . As discussed by Harsha et al. (2010), the inequality $\\mathbb { E } _ { D } [ | \\dot { M } | ] \\ge \\mathbb { E } _ { D } [ \\mathrm { K L } ( q _ { \\phi } | | p ) ]$ can be very loose. However, as they further show, the message length can be brought close to the lower bound, $i f$ Alice and Bob are allowed to share a source of randomness: ",
|
| 381 |
+
"bbox": [
|
| 382 |
+
174,
|
| 383 |
+
675,
|
| 384 |
+
825,
|
| 385 |
+
746
|
| 386 |
+
],
|
| 387 |
+
"page_idx": 3
|
| 388 |
+
},
|
| 389 |
+
{
|
| 390 |
+
"type": "text",
|
| 391 |
+
"text": "Theorem 3.1 (Harsha et al. (2010)) Given random variables $D$ , $\\pmb { w }$ and a random string $R$ , let a protocol $\\Pi$ be defined via a message function $M ( D , R )$ and a decoder function $w ( M , R )$ , i.e. $\\Pi ( D ) = { \\pmb w } ( M ( D , R ) , R )$ . Let $\\mathrm { T } _ { \\Pi } ( D ) : = \\mathbb { E } _ { R } [ | { \\cal M } ( D , R ) | ]$ be the expected message length for data $D$ , and let the minimal expected message length be defined as ",
|
| 392 |
+
"bbox": [
|
| 393 |
+
173,
|
| 394 |
+
756,
|
| 395 |
+
825,
|
| 396 |
+
814
|
| 397 |
+
],
|
| 398 |
+
"page_idx": 3
|
| 399 |
+
},
|
| 400 |
+
{
|
| 401 |
+
"type": "equation",
|
| 402 |
+
"img_path": "images/22102d26cd06b75d21dec985024b2426da072b70f866b56ce1a49dc97d0e54cc.jpg",
|
| 403 |
+
"text": "$$\n\\operatorname { T } [ D : \\pmb { w } ] : = \\operatorname* { m i n } _ { \\Pi } ~ \\mathbb { E } _ { D } [ T _ { \\Pi } ( D ) ] ,\n$$",
|
| 404 |
+
"text_format": "latex",
|
| 405 |
+
"bbox": [
|
| 406 |
+
393,
|
| 407 |
+
818,
|
| 408 |
+
602,
|
| 409 |
+
840
|
| 410 |
+
],
|
| 411 |
+
"page_idx": 3
|
| 412 |
+
},
|
| 413 |
+
{
|
| 414 |
+
"type": "text",
|
| 415 |
+
"text": "where $\\Pi$ ranges over all protocols such that $D , w$ and $D , \\Pi ( D )$ have the same distribution. Then ",
|
| 416 |
+
"bbox": [
|
| 417 |
+
171,
|
| 418 |
+
845,
|
| 419 |
+
810,
|
| 420 |
+
861
|
| 421 |
+
],
|
| 422 |
+
"page_idx": 3
|
| 423 |
+
},
|
| 424 |
+
{
|
| 425 |
+
"type": "equation",
|
| 426 |
+
"img_path": "images/13036dca670cf00977e3ea11d889adb5425255aaae9a523ab83b864c4da13f56.jpg",
|
| 427 |
+
"text": "$$\n\\begin{array} { r } { \\operatorname { I } [ D : w ] \\leq \\operatorname { T } [ D : w ] \\leq \\operatorname { I } [ D : w ] + 2 \\log ( \\operatorname { I } [ D : w ] + 1 ) + O ( 1 ) . } \\end{array}\n$$",
|
| 428 |
+
"text_format": "latex",
|
| 429 |
+
"bbox": [
|
| 430 |
+
282,
|
| 431 |
+
866,
|
| 432 |
+
714,
|
| 433 |
+
883
|
| 434 |
+
],
|
| 435 |
+
"page_idx": 3
|
| 436 |
+
},
|
| 437 |
+
{
|
| 438 |
+
"type": "text",
|
| 439 |
+
"text": "The results of Harsha et al. (2010) establish a characterization of the mutual information in terms of minimal coding a conditional sample. For our purposes, Theorem 3.1 guarantees that in principle ",
|
| 440 |
+
"bbox": [
|
| 441 |
+
173,
|
| 442 |
+
895,
|
| 443 |
+
823,
|
| 444 |
+
924
|
| 445 |
+
],
|
| 446 |
+
"page_idx": 3
|
| 447 |
+
},
|
| 448 |
+
{
|
| 449 |
+
"type": "text",
|
| 450 |
+
"text": "Algorithm 1 Minimal Random Coding ",
|
| 451 |
+
"text_level": 1,
|
| 452 |
+
"bbox": [
|
| 453 |
+
174,
|
| 454 |
+
103,
|
| 455 |
+
431,
|
| 456 |
+
118
|
| 457 |
+
],
|
| 458 |
+
"page_idx": 4
|
| 459 |
+
},
|
| 460 |
+
{
|
| 461 |
+
"type": "table",
|
| 462 |
+
"img_path": "images/c17e6ecf4b55caf66d1256330084ab7fbaf472e9bc3950d5792f692b1323670f.jpg",
|
| 463 |
+
"table_caption": [],
|
| 464 |
+
"table_footnote": [],
|
| 465 |
+
"table_body": "<table><tr><td>1:</td><td>procedure ENCODE(q,p)</td></tr><tr><td>2:</td><td>K ← exp(KL(qΦllp)) K-1</td></tr><tr><td>3:</td><td>draw K samples {wk}k-1, wk ~ p</td></tr><tr><td>4:</td><td>ak←q(wk) p(wk)</td></tr><tr><td>5:</td><td>q(wk) := ak for k ∈{0...K-1}</td></tr><tr><td>6:</td><td>draw a sample wk* ~ q</td></tr><tr><td>7:</td><td>return wk*, k*</td></tr><tr><td></td><td>8:end procedure</td></tr><tr><td></td><td></td></tr></table>",
|
| 466 |
+
"bbox": [
|
| 467 |
+
179,
|
| 468 |
+
122,
|
| 469 |
+
508,
|
| 470 |
+
252
|
| 471 |
+
],
|
| 472 |
+
"page_idx": 4
|
| 473 |
+
},
|
| 474 |
+
{
|
| 475 |
+
"type": "text",
|
| 476 |
+
"text": "there is an algorithm which realizes near bits-back efficiency. Furthermore, the theorem shows that this is indeed a fundamental lower bound, i.e. that such an algorithm is optimal for the considered setting. To this end, we need to refer to a “common ground”, i.e. a shared random source $\\mathcal { R }$ , where w.l.o.g. we can assume that this source is an infinite list of samples from our encoding distribution $p$ . In practice, this can be realized via a pseudo-random generator with a public seed. ",
|
| 477 |
+
"bbox": [
|
| 478 |
+
173,
|
| 479 |
+
277,
|
| 480 |
+
825,
|
| 481 |
+
348
|
| 482 |
+
],
|
| 483 |
+
"page_idx": 4
|
| 484 |
+
},
|
| 485 |
+
{
|
| 486 |
+
"type": "text",
|
| 487 |
+
"text": "3.1 THE BASIC ALGORITHM ",
|
| 488 |
+
"text_level": 1,
|
| 489 |
+
"bbox": [
|
| 490 |
+
174,
|
| 491 |
+
364,
|
| 492 |
+
385,
|
| 493 |
+
378
|
| 494 |
+
],
|
| 495 |
+
"page_idx": 4
|
| 496 |
+
},
|
| 497 |
+
{
|
| 498 |
+
"type": "text",
|
| 499 |
+
"text": "While Harsha et al. (2010) provide a constructive proof using a variant of rejection sampling (see Appendix A), this algorithm is in fact intractable, because it requires keeping track of the acceptance probabilities over the whole sample domain. Therefore, we propose an alternative method to produce an approximate sample from $q _ { \\phi }$ , depicted in Algorithm 1. This algorithm takes as inputs the trained variational distribution $q _ { \\phi }$ and the encoding distribution $p$ . We first draw $K = \\exp ( \\mathrm { K L } ( q _ { \\phi } | | p ) )$ samples from $p$ , using the shared random generator. Subsequently, we craft a discrete proxy distribution $\\tilde { q }$ , which has support only on these $K$ samples, and where the probability mass for each sample is proportional to the importance weights $\\begin{array} { r } { a _ { k } = \\frac { q _ { \\phi } ( \\pmb { w } _ { k } ) } { p ( \\pmb { w } _ { k } ) } } \\end{array}$ . Finally, we draw a sample from $\\tilde { q }$ and return its index $k ^ { * }$ and the sample ${ \\pmb w } _ { k ^ { * } }$ itself. Since any number $0 \\leq k ^ { * } < K$ can be easily encoded with $\\mathrm { K L } ( q _ { \\phi } | | p )$ nats, we achieve our aimed coding efficiency. Decoding the sample is easy: simply draw the $k ^ { * \\mathrm { t h } }$ sample ${ \\pmb w } _ { k ^ { * } }$ from the shared random generator (e.g. by resetting the random seed). ",
|
| 500 |
+
"bbox": [
|
| 501 |
+
173,
|
| 502 |
+
390,
|
| 503 |
+
825,
|
| 504 |
+
553
|
| 505 |
+
],
|
| 506 |
+
"page_idx": 4
|
| 507 |
+
},
|
| 508 |
+
{
|
| 509 |
+
"type": "text",
|
| 510 |
+
"text": "While this algorithm is remarkably simple and easy to implement, there is of course the question of whether it is a correct thing to do. Moreover, an immediate caveat is that the number $K$ of required samples grows exponentially in $\\mathrm { K L } ( q _ { \\phi } | | p )$ , which is clearly infeasible for encoding a practical neural network. The first point is addressed in the next section, while the latter is discussed in Section 3.3, together with other practical considerations. ",
|
| 511 |
+
"bbox": [
|
| 512 |
+
174,
|
| 513 |
+
558,
|
| 514 |
+
825,
|
| 515 |
+
628
|
| 516 |
+
],
|
| 517 |
+
"page_idx": 4
|
| 518 |
+
},
|
| 519 |
+
{
|
| 520 |
+
"type": "text",
|
| 521 |
+
"text": "3.2 THEORETICAL ANALYSIS ",
|
| 522 |
+
"text_level": 1,
|
| 523 |
+
"bbox": [
|
| 524 |
+
176,
|
| 525 |
+
645,
|
| 526 |
+
392,
|
| 527 |
+
659
|
| 528 |
+
],
|
| 529 |
+
"page_idx": 4
|
| 530 |
+
},
|
| 531 |
+
{
|
| 532 |
+
"type": "text",
|
| 533 |
+
"text": "The proxy distribution $\\tilde { q }$ in Algorithm 1 is based on an importance sampling scheme, as its probability masses are defined to be proportional to the usual importance weights $\\begin{array} { r } { a _ { k } = \\frac { q _ { \\phi } ( { \\pmb w } _ { k } ) } { p ( { \\pmb w } _ { k } ) } } \\end{array}$ . Under mild assumptions $( q _ { \\phi } , p$ continuous; $a _ { k } < \\infty ,$ ) it is easy to verify that $\\tilde { q }$ converges to $q _ { \\phi }$ in distribution for $K \\infty$ ; thus in the limit, Algorithm 1 samples from the correct distribution. However, since we collect only $K = \\exp ( \\mathrm { K L } ( q _ { \\phi } | \\bar { | } p ) )$ samples in order to achieve a short coding length, $\\tilde { q }$ will be biased. Fortunately, it turns out that $K$ is just in the right order for this bias to be small. ",
|
| 534 |
+
"bbox": [
|
| 535 |
+
173,
|
| 536 |
+
670,
|
| 537 |
+
825,
|
| 538 |
+
761
|
| 539 |
+
],
|
| 540 |
+
"page_idx": 4
|
| 541 |
+
},
|
| 542 |
+
{
|
| 543 |
+
"type": "text",
|
| 544 |
+
"text": "Theorem 3.2 (Low Bias of Proxy Distribution) Let $q _ { \\phi }$ , p be distributions over $\\pmb { w }$ . Let $t \\geq 0$ and $\\tilde { q }$ be a discrete distribution constructed by drawing $K = \\exp ( \\mathrm { K L } ( q _ { \\phi } | | p ) + t )$ samples $\\{ w _ { k } \\} _ { k = 0 } ^ { K - 1 }$ from p and defining q˜(wk) := P qφ(wk)/p(wk)0 qφ(wk0 )/p(w 0 ) . Furthermore, let $f ( w )$ be a measurable function and $| | f | | _ { q _ { \\phi } } = \\sqrt { \\mathbb { E } _ { q _ { \\phi } } [ f ^ { 2 } ] }$ be its 2-norm under $q _ { \\phi }$ . Then it holds that ",
|
| 545 |
+
"bbox": [
|
| 546 |
+
173,
|
| 547 |
+
770,
|
| 548 |
+
825,
|
| 549 |
+
840
|
| 550 |
+
],
|
| 551 |
+
"page_idx": 4
|
| 552 |
+
},
|
| 553 |
+
{
|
| 554 |
+
"type": "equation",
|
| 555 |
+
"img_path": "images/0f50f823c58026a0fa940b6d6cb728c78603590ee416dc246217a7eaf79005dd.jpg",
|
| 556 |
+
"text": "$$\n\\mathbb { P } \\left( \\left| \\mathbb { E } _ { \\tilde { q } } [ f ] - \\mathbb { E } _ { q _ { \\phi } } [ f ] \\right| \\geq \\frac { 2 \\vert \\vert f \\vert \\vert _ { q _ { \\phi } } \\epsilon } { 1 - \\epsilon } \\right) \\leq 2 \\epsilon\n$$",
|
| 557 |
+
"text_format": "latex",
|
| 558 |
+
"bbox": [
|
| 559 |
+
362,
|
| 560 |
+
843,
|
| 561 |
+
635,
|
| 562 |
+
878
|
| 563 |
+
],
|
| 564 |
+
"page_idx": 4
|
| 565 |
+
},
|
| 566 |
+
{
|
| 567 |
+
"type": "text",
|
| 568 |
+
"text": "where ",
|
| 569 |
+
"bbox": [
|
| 570 |
+
173,
|
| 571 |
+
881,
|
| 572 |
+
215,
|
| 573 |
+
895
|
| 574 |
+
],
|
| 575 |
+
"page_idx": 4
|
| 576 |
+
},
|
| 577 |
+
{
|
| 578 |
+
"type": "equation",
|
| 579 |
+
"img_path": "images/8dc9689346bc123f48fd1864d5bf0c4ed6fb914dfdb1d2516a8246b99c11c409.jpg",
|
| 580 |
+
"text": "$$\n\\epsilon = \\left( e ^ { - t / 4 } + 2 \\sqrt { \\mathbb { P } \\left( \\log \\left( q \\phi / p \\right) > \\mathrm { K L } \\left( q _ { \\phi } | | p \\right) + t / 2 \\right) } \\right) ^ { 1 / 2 } .\n$$",
|
| 581 |
+
"text_format": "latex",
|
| 582 |
+
"bbox": [
|
| 583 |
+
313,
|
| 584 |
+
890,
|
| 585 |
+
683,
|
| 586 |
+
929
|
| 587 |
+
],
|
| 588 |
+
"page_idx": 4
|
| 589 |
+
},
|
| 590 |
+
{
|
| 591 |
+
"type": "text",
|
| 592 |
+
"text": "Algorithm 2 Minimal Random Code Learning (MIRACLE) ",
|
| 593 |
+
"text_level": 1,
|
| 594 |
+
"bbox": [
|
| 595 |
+
173,
|
| 596 |
+
103,
|
| 597 |
+
570,
|
| 598 |
+
118
|
| 599 |
+
],
|
| 600 |
+
"page_idx": 5
|
| 601 |
+
},
|
| 602 |
+
{
|
| 603 |
+
"type": "table",
|
| 604 |
+
"img_path": "images/4acf3b5f14e3b09c6b7930e206cc60976521e58ec6d4cc940ce18baf25dc0adc.jpg",
|
| 605 |
+
"table_caption": [],
|
| 606 |
+
"table_footnote": [],
|
| 607 |
+
"table_body": "<table><tr><td colspan=\"3\">procedure LEARN(D,model with parameters w,C,Cloc, Io,I)</td></tr><tr><td>1: 2:</td><td>randomly split w into B = blocks {wo,...wB-1} Coc</td><td></td></tr><tr><td>3: 4:</td><td>O←{0,...,B-1} βb ←∈βo,forb∈{0,...,B-1}</td><td>> The blocks that have not yet been encoded</td></tr><tr><td>5:</td><td>VARIATIONAL UPDATES(IO)</td><td></td></tr><tr><td>6:</td><td>while O≠ do</td><td></td></tr><tr><td>7:</td><td>draw random b from O</td><td></td></tr><tr><td>8:</td><td></td><td></td></tr><tr><td>9:</td><td>○←0/{b}</td><td> from Algorithm 1</td></tr><tr><td></td><td>w*,kb=ENCODE(q(wb),p(wb))</td><td></td></tr><tr><td>10:</td><td>Wb ← w* (fixing the value of wb)</td><td></td></tr><tr><td>11:</td><td>VARIATIONAL UPDATES(I)</td><td></td></tr><tr><td>12:</td><td>end while</td><td></td></tr><tr><td>13: 14:</td><td>return [ko,..., kB-1]</td><td></td></tr><tr><td>end procedure</td><td></td><td></td></tr><tr><td></td><td></td><td></td></tr><tr><td>15: 16:</td><td>procedure VARIATIONAL UPDATES(I)</td><td></td></tr><tr><td></td><td>LO := Eqt({ub}b∈o)[logp(D|w)] -∑b∈o βKL(q(wb)llp(wb))</td><td></td></tr><tr><td>17:</td><td>for i ∈[0,...,I-1] do</td><td></td></tr><tr><td>18:</td><td>Perform stochastic gradient update of Lo</td><td></td></tr><tr><td>19:</td><td>for b ∈Odo</td><td></td></tr><tr><td>20:</td><td>if KL(q(wb)llp(wb))> Ctoc then</td><td></td></tr><tr><td>21:</td><td>βb←(1+∈β)×βb</td><td></td></tr><tr><td>22:</td><td>else</td><td></td></tr><tr><td>23:</td><td></td><td></td></tr><tr><td>24:</td><td>βb←βb/(1+∈β)</td><td></td></tr><tr><td>25:</td><td>end if</td><td></td></tr><tr><td></td><td>end for</td><td></td></tr><tr><td>26:</td><td>end for</td><td></td></tr><tr><td>27:</td><td></td><td></td></tr><tr><td></td><td>end procedure</td><td></td></tr><tr><td></td><td></td><td></td></tr><tr><td></td><td></td><td></td></tr><tr><td></td><td></td><td></td></tr><tr><td></td><td></td><td></td></tr><tr><td></td><td></td><td></td></tr></table>",
|
| 608 |
+
"bbox": [
|
| 609 |
+
173,
|
| 610 |
+
123,
|
| 611 |
+
825,
|
| 612 |
+
520
|
| 613 |
+
],
|
| 614 |
+
"page_idx": 5
|
| 615 |
+
},
|
| 616 |
+
{
|
| 617 |
+
"type": "text",
|
| 618 |
+
"text": "Theorem 3.2 is a corollary of Chatterjee & Diaconis (2018), Theorem 1.2, by noting that ",
|
| 619 |
+
"bbox": [
|
| 620 |
+
173,
|
| 621 |
+
545,
|
| 622 |
+
753,
|
| 623 |
+
560
|
| 624 |
+
],
|
| 625 |
+
"page_idx": 5
|
| 626 |
+
},
|
| 627 |
+
{
|
| 628 |
+
"type": "equation",
|
| 629 |
+
"img_path": "images/e3d7e0d3e8a6e1b5df3c9a9172565f53934b03190ea4523c26d17f8c925a5c77.jpg",
|
| 630 |
+
"text": "$$\n\\mathbb { E } _ { \\tilde { q } } [ f ] = \\frac { 1 } { \\sum _ { k ^ { \\prime } } \\frac { q _ { \\phi } ( { \\pmb w } _ { k ^ { \\prime } } ) } { p ( { \\pmb w } _ { k ^ { \\prime } } ) } } \\sum _ { k } f ( { \\pmb w } _ { k } ) \\frac { q _ { \\phi } ( { \\pmb w } _ { k } ) } { p ( { \\pmb w } _ { k } ) } ,\n$$",
|
| 631 |
+
"text_format": "latex",
|
| 632 |
+
"bbox": [
|
| 633 |
+
357,
|
| 634 |
+
566,
|
| 635 |
+
638,
|
| 636 |
+
608
|
| 637 |
+
],
|
| 638 |
+
"page_idx": 5
|
| 639 |
+
},
|
| 640 |
+
{
|
| 641 |
+
"type": "text",
|
| 642 |
+
"text": "which is precisely the importance sampling estimator for unnormalized distributions (denoted as $J _ { n }$ in (Chatterjee & Diaconis, 2018)), i.e. their Theorem 1.2 directly yields Theorem 3.2. Note that the term $\\bar { e } ^ { - t / 4 }$ decays quickly with $t$ , and, since $\\log { q _ { \\phi } } / p$ is typically concentrated around its expected value $\\mathrm { K L } ( q | | p )$ , the second term in (8) also quickly becomes negligible. Thus, roughly speaking, Theorem 3.2 establishes that $\\mathbb { E } _ { q _ { \\phi } } [ f ] \\approx \\mathbb { E } _ { \\widetilde { q } } [ f ]$ with high probability, for any measurable function $f$ . This is in particular true for the function $\\begin{array} { r } { f ( \\pmb { w } ) = \\log p ( \\mathcal { D } | \\pmb { w } ) - \\beta \\log \\frac { q _ { \\phi } ( \\pmb { w } ) } { p ( \\pmb { w } ) } } \\end{array}$ . Note that the expectation of this function is just the variational objective (3) we optimized to yield $q _ { \\phi }$ in the first place. Thus, since $\\mathbb { E } _ { \\tilde { q } } [ f ] \\approx \\mathbb { E } _ { q _ { \\phi } } [ f ] = \\mathcal { L } ( \\phi )$ , replacing $q _ { \\phi }$ by $\\tilde { q }$ is well justified. Thereby, any sample of $\\tilde { q }$ can trivially be encoded with $\\mathrm { K L } ( q _ { \\phi } | | p )$ nats, and decoded by simple reference to a pseudo-random generator. ",
|
| 643 |
+
"bbox": [
|
| 644 |
+
173,
|
| 645 |
+
612,
|
| 646 |
+
825,
|
| 647 |
+
762
|
| 648 |
+
],
|
| 649 |
+
"page_idx": 5
|
| 650 |
+
},
|
| 651 |
+
{
|
| 652 |
+
"type": "text",
|
| 653 |
+
"text": "Note that according to Theorem 3.2 we should actually take a number of samples somewhat larger than $\\exp ( \\mathrm { K L } ( q _ { \\phi } | | p ) )$ in order to make $\\epsilon$ sufficiently small. In particular, the results in (Chatterjee & Diaconis, 2018) also imply that a too small number of samples will typically be quite off the targeted expectation (for the worst-case $f$ ). However, although our choice of number of samples is at a critical point, in our experiments this number of samples yielded very good results. ",
|
| 654 |
+
"bbox": [
|
| 655 |
+
174,
|
| 656 |
+
768,
|
| 657 |
+
825,
|
| 658 |
+
839
|
| 659 |
+
],
|
| 660 |
+
"page_idx": 5
|
| 661 |
+
},
|
| 662 |
+
{
|
| 663 |
+
"type": "text",
|
| 664 |
+
"text": "3.3 PRACTICAL IMPLEMENTATION ",
|
| 665 |
+
"text_level": 1,
|
| 666 |
+
"bbox": [
|
| 667 |
+
176,
|
| 668 |
+
856,
|
| 669 |
+
426,
|
| 670 |
+
869
|
| 671 |
+
],
|
| 672 |
+
"page_idx": 5
|
| 673 |
+
},
|
| 674 |
+
{
|
| 675 |
+
"type": "text",
|
| 676 |
+
"text": "In this section, we describe the application of Algorithm 1 within a practical learning algorithm – Minimal Random Code Learning (MIRACLE) – depicted in Algorithm 2. For both $q _ { \\phi }$ and $p$ we used Gaussians with diagonal covariance matrices. For $q _ { \\phi }$ , all means and standard deviations constituted the variational parameters $\\phi$ . The mean of $p$ was fixed to zero, and the standard deviation was shared within each layer of the encoded network. These shared parameters of $p$ where learned jointly with $q _ { \\phi }$ , i.e. the encoding distribution was also adapted to the task. This choice of distributions allowed us to use the reparameterization trick for effective variational training and furthermore, $\\mathrm { K L } ( q _ { \\phi } | | p )$ can be computed analytically. ",
|
| 677 |
+
"bbox": [
|
| 678 |
+
176,
|
| 679 |
+
882,
|
| 680 |
+
825,
|
| 681 |
+
924
|
| 682 |
+
],
|
| 683 |
+
"page_idx": 5
|
| 684 |
+
},
|
| 685 |
+
{
|
| 686 |
+
"type": "image",
|
| 687 |
+
"img_path": "images/9526ee351f39d45224c618d150ea2d03337628087046127a193c2a9588f39509.jpg",
|
| 688 |
+
"image_caption": [
|
| 689 |
+
"Figure 1: The error rate and the compression size for various compression methods. Lower left is better. "
|
| 690 |
+
],
|
| 691 |
+
"image_footnote": [],
|
| 692 |
+
"bbox": [
|
| 693 |
+
181,
|
| 694 |
+
112,
|
| 695 |
+
794,
|
| 696 |
+
318
|
| 697 |
+
],
|
| 698 |
+
"page_idx": 6
|
| 699 |
+
},
|
| 700 |
+
{
|
| 701 |
+
"type": "text",
|
| 702 |
+
"text": "",
|
| 703 |
+
"bbox": [
|
| 704 |
+
174,
|
| 705 |
+
386,
|
| 706 |
+
823,
|
| 707 |
+
455
|
| 708 |
+
],
|
| 709 |
+
"page_idx": 6
|
| 710 |
+
},
|
| 711 |
+
{
|
| 712 |
+
"type": "text",
|
| 713 |
+
"text": "Since generating $K = \\exp ( \\mathrm { K L } ( q _ { \\phi } | | p ) )$ samples is infeasible for any reasonable $\\mathrm { K L } ( q _ { \\phi } | | p )$ , we divided the overall problem into sub-problems. To this end, we set a global coding goal of $C$ nats and a local coding goal of $C _ { l o c }$ nats. We randomly split the weight vector $\\textbf { \\em w }$ into $\\begin{array} { r } { B \\ = \\ \\lceil \\frac { C } { C _ { l o c } } \\rceil } \\end{array}$ equally sized blocks, and assigned each block an allowance of $C _ { l o c }$ nats. For example, fixing $C _ { l o c }$ to 11.09 nats $\\approx 1 6$ bits, corresponds to $K = 6 5 5 3 6$ samples which need to be drawn per block. We imposed block-wise KL constraints using block-wise penalty factors $\\beta _ { b }$ , which were automatically annealed via multiplication/division with $( 1 + \\epsilon _ { \\beta } )$ during the variational updates (see Algorithm 2). Note that the random splitting into $B$ blocks can be efficiently coded via the shared random generator, and only the number $B$ needs communicated. ",
|
| 714 |
+
"bbox": [
|
| 715 |
+
174,
|
| 716 |
+
462,
|
| 717 |
+
825,
|
| 718 |
+
589
|
| 719 |
+
],
|
| 720 |
+
"page_idx": 6
|
| 721 |
+
},
|
| 722 |
+
{
|
| 723 |
+
"type": "text",
|
| 724 |
+
"text": "Before encoding any weights, we made sure that variational learning had converged by training for a large number of iterations $I _ { 0 } = 1 0 ^ { 4 }$ . After that, we alternated between encoding single blocks and updating the variational distribution not-yet coded weights, by spending $I$ intermediate variational iterations. To this end, we define a variational objective $\\mathcal { L } _ { \\mathcal { O } }$ w.r.t. to blocks which have not been coded yet, while weights of already encoded blocks were fixed to their encoded value. Intuitively, this allows to compensate for poor choices in earlier encoded blocks, and was crucial for good performance. Theoretically, this amounts to a rich auto-regressive variational family $q _ { \\phi }$ , as the blocks which remain to be updated are effectively conditioned on the weights which have already been encoded. We also found that the hashing trick (Chen et al., 2015) further improves performance (not depicted in Algorithm 2 for simplicity). The hashing trick randomly conditions weights to share the same value. While Chen et al. (2015) apply it to reduce the entropy, in our case it helps to restrict the optimization space and reduces the dimensionality of both $p$ and $q _ { \\phi }$ . We found that this typically improves the compression rate by a factor of $\\sim 1 . 5 \\times$ . ",
|
| 725 |
+
"bbox": [
|
| 726 |
+
174,
|
| 727 |
+
597,
|
| 728 |
+
825,
|
| 729 |
+
776
|
| 730 |
+
],
|
| 731 |
+
"page_idx": 6
|
| 732 |
+
},
|
| 733 |
+
{
|
| 734 |
+
"type": "text",
|
| 735 |
+
"text": "4 EXPERIMENTAL RESULTS ",
|
| 736 |
+
"text_level": 1,
|
| 737 |
+
"bbox": [
|
| 738 |
+
176,
|
| 739 |
+
799,
|
| 740 |
+
418,
|
| 741 |
+
814
|
| 742 |
+
],
|
| 743 |
+
"page_idx": 6
|
| 744 |
+
},
|
| 745 |
+
{
|
| 746 |
+
"type": "text",
|
| 747 |
+
"text": "The experiments3 were conducted on two common benchmarks: LeNet-5 on MNIST and VGG-16 on CIFAR-10. As baselines we used three recent state-of-the-art methods, namely Deep Compression (Han et al., 2016), Weightless encoding (Reagen et al., 2018) and Bayesian Compression (Louizos et al., 2017). The performance of the baseline methods are quoted from their respective source materials. ",
|
| 748 |
+
"bbox": [
|
| 749 |
+
174,
|
| 750 |
+
830,
|
| 751 |
+
825,
|
| 752 |
+
900
|
| 753 |
+
],
|
| 754 |
+
"page_idx": 6
|
| 755 |
+
},
|
| 756 |
+
{
|
| 757 |
+
"type": "table",
|
| 758 |
+
"img_path": "images/15e94a033a6807f0ff241dd3676bc881ed6ee05957a92e3d3daf0b8d0c002b92.jpg",
|
| 759 |
+
"table_caption": [
|
| 760 |
+
"Table 1: Numerical performance of the compression algorithms. "
|
| 761 |
+
],
|
| 762 |
+
"table_footnote": [],
|
| 763 |
+
"table_body": "<table><tr><td>Model</td><td>Compression</td><td>Size</td><td>Ratio</td><td>Test error</td></tr><tr><td rowspan=\"6\">LeNet-5on MNIST</td><td>Uncompressed model</td><td>1720 kB</td><td>1×</td><td>0.7 %</td></tr><tr><td>Deep Compression</td><td>44 kB</td><td>39×</td><td>0.8 %</td></tr><tr><td>Weightless 5</td><td>4.52 kB</td><td>382×</td><td>1.0 %</td></tr><tr><td>Bayesian Compression</td><td>2.3 kB</td><td>771×</td><td>1.0 %</td></tr><tr><td>MIRACLE (Lowest error)</td><td>3.03 kB</td><td>555×</td><td>0.69 %</td></tr><tr><td>MIRACLE (Highest compression)</td><td>1.52 kB</td><td>1110×</td><td>0.96 %</td></tr><tr><td rowspan=\"5\">VGG-16 on CIFAR-10</td><td>Uncompressed model</td><td>60 MB</td><td>1×</td><td>6.5 %</td></tr><tr><td>Bayesian Compression</td><td>642 kB</td><td>95×</td><td>8.6 %</td></tr><tr><td>Bayesian Compression</td><td>525 kB</td><td>116×</td><td>9.2 %</td></tr><tr><td>MIRACLE (Lowest error)</td><td>417kB</td><td>147×</td><td>6.57 %</td></tr><tr><td>MIRACLE (Highest compression)</td><td>168 kB</td><td>365×</td><td>10.0 %</td></tr></table>",
|
| 764 |
+
"bbox": [
|
| 765 |
+
178,
|
| 766 |
+
127,
|
| 767 |
+
820,
|
| 768 |
+
318
|
| 769 |
+
],
|
| 770 |
+
"page_idx": 7
|
| 771 |
+
},
|
| 772 |
+
{
|
| 773 |
+
"type": "text",
|
| 774 |
+
"text": "For training MIRACLE, we used Adam (Kingma & Ba, 2014) with the default learning rate $( 1 0 ^ { - 3 } )$ and we set $\\dot { \\epsilon } _ { \\beta 0 } = 1 0 ^ { - 8 }$ and $\\epsilon _ { \\beta } = 5 \\times 1 0 ^ { - 5 }$ . For VGG, the means of the weights were initialized using a pretrained model.4 We recommend applying the hashing trick mainly to reduce the size of the largest layers. In particular, we applied the hashing trick was to layers 2 and 3 in LeNet-5 to reduce their sizes by $2 \\times$ and $6 4 \\times$ respectively and to layers 10-16 in VGG to reduce their sizes $8 \\times$ . The local coding goal $C _ { l o c }$ was fixed at 20 bits for LeNet-5 and it was varied between 15 and 5 bits for VGG ( $B$ was kept constant). For the number of intermediate variational updates $I$ , we used $I = 5 0$ for LeNet-5 and $I = 1$ for VGG, in order to keep training time reasonable $\\approx 1$ day on a single NVIDIA P100 for VGG). ",
|
| 775 |
+
"bbox": [
|
| 776 |
+
173,
|
| 777 |
+
348,
|
| 778 |
+
825,
|
| 779 |
+
474
|
| 780 |
+
],
|
| 781 |
+
"page_idx": 7
|
| 782 |
+
},
|
| 783 |
+
{
|
| 784 |
+
"type": "text",
|
| 785 |
+
"text": "The performance trade-offs (test error rate and compression size) of MIRACLE along with the baseline methods and the uncompressed model are shown in Figure 1 and Table 1. For MIRACLE we can easily construct the Pareto frontier, by starting with a large coding goal $C$ (i.e. allowing a large coding length) and successively reducing it. Constructing such a Pareto frontier for other methods is delicate, as it requires re-tuning hyper-parameters which are often only indirectly related to the compression size – for MIRACLE it is directly reflected via the KL-term. We see that MIRACLE is Pareto-better than the competitors: for a given test error rate, we achieve better compression, while for a given model size we achieve lower test error. ",
|
| 786 |
+
"bbox": [
|
| 787 |
+
173,
|
| 788 |
+
482,
|
| 789 |
+
825,
|
| 790 |
+
593
|
| 791 |
+
],
|
| 792 |
+
"page_idx": 7
|
| 793 |
+
},
|
| 794 |
+
{
|
| 795 |
+
"type": "text",
|
| 796 |
+
"text": "5 CONCLUSION ",
|
| 797 |
+
"text_level": 1,
|
| 798 |
+
"bbox": [
|
| 799 |
+
176,
|
| 800 |
+
619,
|
| 801 |
+
318,
|
| 802 |
+
636
|
| 803 |
+
],
|
| 804 |
+
"page_idx": 7
|
| 805 |
+
},
|
| 806 |
+
{
|
| 807 |
+
"type": "text",
|
| 808 |
+
"text": "In this paper we followed through the philosophy of the bits-back argument for the goal of coding model parameters. The basic insight here is that restricting to a single deterministic weight-set and aiming to coding it in a classic Shannon-style is greedy and in fact sub-optimal. Neural networks – and other deep learning models – are highly overparameterized, and consequently there are many “good” parameterizations. Thus, rather than focusing on a single weight set, we showed that this fact can be exploited for coding, by selecting a “cheap” weight set out of the set of “good” ones. Our algorithm is backed by solid recent information-theoretic insights, yet it is simple to implement. We demonstrated that the presented coding algorithm clearly outperforms previous state-of-the-art. An important question remaining for future work is how efficient MIRACLE can be made in terms of memory accesses and consequently for energy consumption and inference time. There lies clear potential in this direction, as any single weight can be recovered by its block-index and relative index within each block. By smartly keeping track of these addresses, and using pseudo-random generators as algorithmic lookup-tables, we could design an inference machine which is able to directly run our compressed models, which might lead to considerable savings in memory accesses. ",
|
| 809 |
+
"bbox": [
|
| 810 |
+
173,
|
| 811 |
+
655,
|
| 812 |
+
825,
|
| 813 |
+
849
|
| 814 |
+
],
|
| 815 |
+
"page_idx": 7
|
| 816 |
+
},
|
| 817 |
+
{
|
| 818 |
+
"type": "text",
|
| 819 |
+
"text": "ACKNOWLEDGEMENTS ",
|
| 820 |
+
"text_level": 1,
|
| 821 |
+
"bbox": [
|
| 822 |
+
176,
|
| 823 |
+
103,
|
| 824 |
+
367,
|
| 825 |
+
117
|
| 826 |
+
],
|
| 827 |
+
"page_idx": 8
|
| 828 |
+
},
|
| 829 |
+
{
|
| 830 |
+
"type": "text",
|
| 831 |
+
"text": "We want to thank Christian Steinruecken, Oliver Janzer, Kris Stensbo-Smidt and Siddharth Swaroop ´ for their helpful comments. This project has received funding from the European Union’s Horizon 2020 research and innovation programme under the Marie Skłodowska-Curie Grant Agreement No. 797223 — HYBSPN. Furthermore, we acknowledge EPSRC and Intel for their support. ",
|
| 832 |
+
"bbox": [
|
| 833 |
+
174,
|
| 834 |
+
133,
|
| 835 |
+
825,
|
| 836 |
+
189
|
| 837 |
+
],
|
| 838 |
+
"page_idx": 8
|
| 839 |
+
},
|
| 840 |
+
{
|
| 841 |
+
"type": "text",
|
| 842 |
+
"text": "REFERENCES ",
|
| 843 |
+
"text_level": 1,
|
| 844 |
+
"bbox": [
|
| 845 |
+
174,
|
| 846 |
+
210,
|
| 847 |
+
285,
|
| 848 |
+
226
|
| 849 |
+
],
|
| 850 |
+
"page_idx": 8
|
| 851 |
+
},
|
| 852 |
+
{
|
| 853 |
+
"type": "text",
|
| 854 |
+
"text": "S. Chatterjee and P. Diaconis. The sample size required in importance sampling. The Annals of Applied Probability, 28(2):1099–1135, 2018. \nW. Chen, J. Wilson, S. Tyree, K. Weinberger, and Y. Chen. Compressing neural networks with the hashing trick. In Proceedings of ICML, pp. 2285–2294, 2015. \nB. J. Frey and G. E. Hinton. Efficient stochastic source coding and an application to a bayesian network source model. The Computer Journal, 40(2 and 3):157–165, 1997. \nP. D. Grunwald. ¨ The minimum description length principle. MIT press, 2007. \nSong Han, Jeff Pool, John Tran, and William Dally. Learning both weights and connections for efficient neural network. In Advances in Neural Information Processing Systems (NIPS), pp. 1135–1143, 2015. \nSong Han, Huizi Mao, and William J Dally. Deep compression: Compressing deep neural networks with pruning, trained quantization and huffman coding. International Conference on Learning Representations (ICLR), 2016. \nP. Harsha, R. Jain, D. McAllester, and J. Radhakrishnan. The communication complexity of correlation. IEEE Transactions on Information Theory, 1(56):438–449, 2010. \nI. Higgins, L. Matthey, A. Pal, C. Burgess, X. Glorot, M. Botvinick, S. Mohamed, and A. Lerchner. Beta-VAE: Learning basic visual concepts with a constrained variational framework. In ICLR, 2017. \nG. E. Hinton and D. Van Camp. Keeping the neural networks simple by minimizing the description length of the weights. In Proceedings of the sixth annual conference on Computational learning theory, pp. 5–13. ACM, 1993. \nG. E. Hinton and R. S. Zemel. Autoencoders, minimum description length and helmholtz free energy. In Proceedings of NIPS, pp. 3–10, 1994. \nDavid A Huffman. A method for the construction of minimum-redundancy codes. Proceedings of the IRE, 40(9):1098–1101, 1952. \nD. P. Kingma and J. Ba. Adam: A method for stochastic optimization. arXiv preprint arXiv:1412.6980, 2014. \nY. LeCun, J. S. Denker, and S. A. Solla. Optimal brain damage. In Proceedings of NIPS, pp. 598–605, 1990. \nC. Louizos, K. Ullrich, and M. Welling. Bayesian compression for deep learning. In Proceedings of NIPS, pp. 3288–3298, 2017. \nB. Reagen, U. Gupta, R. Adolf, M. M. Mitzenmacher, A. M. Rush, G.-Y. Wei, and D. Brooks. Weightless: Lossy weight encoding for deep neural network compression. International Conference on Machine Learning, 2018. \nC. E. Shannon. A mathematical theory of communication. Bell System Technical Journal, 27(3): 379–423, 1948. \nP. M. B. Vitanyi and M. Li. An introduction to Kolmogorov complexity and its applications, volume 34. Springer Heidelberg, 1997. ",
|
| 855 |
+
"bbox": [
|
| 856 |
+
169,
|
| 857 |
+
219,
|
| 858 |
+
826,
|
| 859 |
+
922
|
| 860 |
+
],
|
| 861 |
+
"page_idx": 8
|
| 862 |
+
},
|
| 863 |
+
{
|
| 864 |
+
"type": "text",
|
| 865 |
+
"text": "Algorithm 3 Greedy Rejection Sampling ",
|
| 866 |
+
"text_level": 1,
|
| 867 |
+
"bbox": [
|
| 868 |
+
176,
|
| 869 |
+
103,
|
| 870 |
+
444,
|
| 871 |
+
118
|
| 872 |
+
],
|
| 873 |
+
"page_idx": 9
|
| 874 |
+
},
|
| 875 |
+
{
|
| 876 |
+
"type": "text",
|
| 877 |
+
"text": "1: procedure SAMPLE(q, p) \n2: $p _ { 0 } ( { \\pmb w } ) 0$ for $\\pmb { w } \\in \\mathcal { W }$ \n3: $p _ { 0 } ^ { * } \\gets 0$ \n4: for $i \\gets 0$ to $\\infty$ do \n5: $\\begin{array} { r l } & { \\alpha _ { i } ( \\pmb { w } ) \\operatorname* { m i n } \\{ q ( \\pmb { w } ) - p _ { i - 1 } ( \\pmb { w } ) , ( 1 - p _ { i - 1 } ^ { * } ) p ( \\pmb { w } ) \\} } \\\\ & { p _ { i } ( \\pmb { w } ) p _ { i - 1 } ( \\pmb { w } ) + \\alpha _ { i } ( \\pmb { w } ) } \\\\ & { p _ { i } ^ { * } \\sum _ { \\pmb { w } \\in \\mathscr { W } } p _ { i } ( \\pmb { w } ) } \\\\ & { \\mathrm { d r a w ~ s a m p l e ~ } \\pmb { w } _ { i } \\sim p } \\\\ & { \\beta _ { i } \\frac { \\alpha _ { i } ( \\pmb { w } _ { i } ) } { ( 1 - p _ { i - 1 } ^ { * } ) p ( \\pmb { w } _ { i } ) } } \\end{array}$ \n6: \n7: \n8: \n9: \n10: draw $\\epsilon \\sim \\mathcal { U } ( 0 , 1 )$ \n11: if $\\epsilon \\leq \\beta _ { i }$ then \n12: return ${ \\pmb w } _ { i }$ , $i$ \n13: end if \n14: end for \n15: end procedure ",
|
| 878 |
+
"bbox": [
|
| 879 |
+
178,
|
| 880 |
+
122,
|
| 881 |
+
588,
|
| 882 |
+
342
|
| 883 |
+
],
|
| 884 |
+
"page_idx": 9
|
| 885 |
+
},
|
| 886 |
+
{
|
| 887 |
+
"type": "text",
|
| 888 |
+
"text": "A GREEDY REJECTION SAMPLING BY HARSHA ET AL. (2010) ",
|
| 889 |
+
"text_level": 1,
|
| 890 |
+
"bbox": [
|
| 891 |
+
174,
|
| 892 |
+
364,
|
| 893 |
+
704,
|
| 894 |
+
382
|
| 895 |
+
],
|
| 896 |
+
"page_idx": 9
|
| 897 |
+
},
|
| 898 |
+
{
|
| 899 |
+
"type": "text",
|
| 900 |
+
"text": "In order to prove the upper bound, to which Harsha et al. (2010) refer as the ‘one-shot reverse Shannon theorem’, they exhibit a rejection sampling procedure. However, instead of using the classical rejection with acceptance probabilities $\\frac { q } { M p }$ where $\\begin{array} { r } { M = \\operatorname* { m a x } { \\frac { q } { p } } } \\end{array}$ , they propose a greedier version. The core idea is that every sample should be accepted with as high probability as possible while keeping the overall acceptance probability of each element below the target distribution. ",
|
| 901 |
+
"bbox": [
|
| 902 |
+
173,
|
| 903 |
+
395,
|
| 904 |
+
825,
|
| 905 |
+
469
|
| 906 |
+
],
|
| 907 |
+
"page_idx": 9
|
| 908 |
+
},
|
| 909 |
+
{
|
| 910 |
+
"type": "text",
|
| 911 |
+
"text": "For this algorithm we assume discrete $p$ and $q$ over the set $\\mathcal { W }$ and an infinite sequence of samples $\\{ w _ { i } \\} _ { i = 1 } ^ { \\infty }$ from $p$ . ",
|
| 912 |
+
"bbox": [
|
| 913 |
+
173,
|
| 914 |
+
474,
|
| 915 |
+
823,
|
| 916 |
+
505
|
| 917 |
+
],
|
| 918 |
+
"page_idx": 9
|
| 919 |
+
},
|
| 920 |
+
{
|
| 921 |
+
"type": "text",
|
| 922 |
+
"text": "Let $\\alpha _ { i } ( \\pmb { w } )$ with $i \\in \\mathrm { N }$ and $\\pmb { w } \\in \\mathcal { W }$ be the probability that the procedure outputs the ith sample with ${ \\pmb w } _ { i } = { \\pmb w }$ . For the sampling method to be unbiased, we have to ensure that ",
|
| 923 |
+
"bbox": [
|
| 924 |
+
173,
|
| 925 |
+
510,
|
| 926 |
+
823,
|
| 927 |
+
539
|
| 928 |
+
],
|
| 929 |
+
"page_idx": 9
|
| 930 |
+
},
|
| 931 |
+
{
|
| 932 |
+
"type": "equation",
|
| 933 |
+
"img_path": "images/687d594b312b945156aec29978607478f0afd2c562988aae8be262855bfef65b.jpg",
|
| 934 |
+
"text": "$$\nq ( { \\pmb w } ) = \\sum _ { i = 0 } ^ { \\infty } \\alpha _ { i } ( { \\pmb w } ) .\n$$",
|
| 935 |
+
"text_format": "latex",
|
| 936 |
+
"bbox": [
|
| 937 |
+
431,
|
| 938 |
+
541,
|
| 939 |
+
566,
|
| 940 |
+
583
|
| 941 |
+
],
|
| 942 |
+
"page_idx": 9
|
| 943 |
+
},
|
| 944 |
+
{
|
| 945 |
+
"type": "text",
|
| 946 |
+
"text": "Let $\\begin{array} { r } { p _ { i } ( { \\pmb w } ) = \\sum _ { j = 0 } ^ { i } \\alpha _ { j } ( { \\pmb w } ) } \\end{array}$ be the probability that the procedure halts within $j \\le i$ iteration and it outputs ${ \\pmb w } _ { j } = { \\pmb w }$ . Let $\\begin{array} { r } { p _ { i } ^ { * } = \\sum _ { w \\in \\mathcal { W } } p _ { i } ( w ) } \\end{array}$ be the probability that procedure halts within $i$ iterations. Let ",
|
| 947 |
+
"bbox": [
|
| 948 |
+
173,
|
| 949 |
+
595,
|
| 950 |
+
823,
|
| 951 |
+
635
|
| 952 |
+
],
|
| 953 |
+
"page_idx": 9
|
| 954 |
+
},
|
| 955 |
+
{
|
| 956 |
+
"type": "equation",
|
| 957 |
+
"img_path": "images/a7d99d1cb5b3e0485b3bf966e612aa34b0cc7e9dd015e454e012691035fd0043.jpg",
|
| 958 |
+
"text": "$$\n\\begin{array} { r l } & { \\alpha _ { i } ( \\pmb { w } ) = \\operatorname* { m i n } \\{ q ( \\pmb { w } ) - p _ { i - 1 } ( \\pmb { w } ) , ( 1 - p _ { i - 1 } ^ { * } ) p ( \\pmb { w } ) \\} } \\\\ & { p _ { i } ( \\pmb { w } ) = p _ { i - 1 } ( \\pmb { w } ) + \\alpha _ { i } ( \\pmb { w } ) . } \\end{array}\n$$",
|
| 959 |
+
"text_format": "latex",
|
| 960 |
+
"bbox": [
|
| 961 |
+
331,
|
| 962 |
+
635,
|
| 963 |
+
669,
|
| 964 |
+
675
|
| 965 |
+
],
|
| 966 |
+
"page_idx": 9
|
| 967 |
+
},
|
| 968 |
+
{
|
| 969 |
+
"type": "text",
|
| 970 |
+
"text": "Since $P ( \\pmb { w } _ { i } = \\pmb { w } ) = p ( \\pmb { w } )$ , $\\alpha _ { i } ( \\pmb { w } )$ can be at most $( 1 - p _ { i - 1 } ^ { * } ) p ( \\pmb { w } )$ . The proposed strategy is greedy because it accepts the ith sample with as high probability as possible under the constraint that $\\begin{array} { r } { \\dot { p _ { i } } ( { \\pmb w } ) \\leq q ( { \\pmb w } ) } \\end{array}$ . ",
|
| 971 |
+
"bbox": [
|
| 972 |
+
174,
|
| 973 |
+
681,
|
| 974 |
+
825,
|
| 975 |
+
724
|
| 976 |
+
],
|
| 977 |
+
"page_idx": 9
|
| 978 |
+
},
|
| 979 |
+
{
|
| 980 |
+
"type": "text",
|
| 981 |
+
"text": "Under the proposed formula for $\\alpha _ { i } ( \\pmb { w } )$ , the acceptance probability for the $i$ th sample ${ \\pmb w } _ { i }$ is ",
|
| 982 |
+
"bbox": [
|
| 983 |
+
168,
|
| 984 |
+
731,
|
| 985 |
+
767,
|
| 986 |
+
746
|
| 987 |
+
],
|
| 988 |
+
"page_idx": 9
|
| 989 |
+
},
|
| 990 |
+
{
|
| 991 |
+
"type": "equation",
|
| 992 |
+
"img_path": "images/3e35358f93f80f07cc7e5c3c5e51a0338d77c2d22a44eab8cca963f5603e4067.jpg",
|
| 993 |
+
"text": "$$\n\\beta _ { i } = \\frac { \\alpha _ { i } ( { \\pmb w } _ { i } ) } { ( 1 - p _ { i - 1 } ^ { * } ) p ( { \\pmb w } ) }\n$$",
|
| 994 |
+
"text_format": "latex",
|
| 995 |
+
"bbox": [
|
| 996 |
+
423,
|
| 997 |
+
748,
|
| 998 |
+
573,
|
| 999 |
+
785
|
| 1000 |
+
],
|
| 1001 |
+
"page_idx": 9
|
| 1002 |
+
},
|
| 1003 |
+
{
|
| 1004 |
+
"type": "text",
|
| 1005 |
+
"text": "The pseudo code is shown in Algorithm 3. Note that the algorithm requires computing $\\alpha _ { i } ( { \\pmb w } )$ for the whole set $\\mathcal { W }$ in every iteration which makes it intractable for large $\\mathcal { W }$ . ",
|
| 1006 |
+
"bbox": [
|
| 1007 |
+
173,
|
| 1008 |
+
795,
|
| 1009 |
+
826,
|
| 1010 |
+
824
|
| 1011 |
+
],
|
| 1012 |
+
"page_idx": 9
|
| 1013 |
+
},
|
| 1014 |
+
{
|
| 1015 |
+
"type": "text",
|
| 1016 |
+
"text": "A.1 PROOF OUTLINE",
|
| 1017 |
+
"text_level": 1,
|
| 1018 |
+
"bbox": [
|
| 1019 |
+
176,
|
| 1020 |
+
840,
|
| 1021 |
+
333,
|
| 1022 |
+
854
|
| 1023 |
+
],
|
| 1024 |
+
"page_idx": 9
|
| 1025 |
+
},
|
| 1026 |
+
{
|
| 1027 |
+
"type": "text",
|
| 1028 |
+
"text": "For the details of the proof, please refer to the source material (Harsha et al., 2010). ",
|
| 1029 |
+
"bbox": [
|
| 1030 |
+
173,
|
| 1031 |
+
864,
|
| 1032 |
+
720,
|
| 1033 |
+
881
|
| 1034 |
+
],
|
| 1035 |
+
"page_idx": 9
|
| 1036 |
+
},
|
| 1037 |
+
{
|
| 1038 |
+
"type": "text",
|
| 1039 |
+
"text": "To show that the procedure is unbiased, one has to prove that ",
|
| 1040 |
+
"bbox": [
|
| 1041 |
+
173,
|
| 1042 |
+
887,
|
| 1043 |
+
575,
|
| 1044 |
+
902
|
| 1045 |
+
],
|
| 1046 |
+
"page_idx": 9
|
| 1047 |
+
},
|
| 1048 |
+
{
|
| 1049 |
+
"type": "equation",
|
| 1050 |
+
"img_path": "images/11ec06da1c43841141902cadb00569985532b86c78d5380e155e694544ba1054.jpg",
|
| 1051 |
+
"text": "$$\nq ( { \\pmb w } ) = \\operatorname* { l i m } _ { i \\infty } p _ { i } ( { \\pmb w } ) .\n$$",
|
| 1052 |
+
"text_format": "latex",
|
| 1053 |
+
"bbox": [
|
| 1054 |
+
428,
|
| 1055 |
+
905,
|
| 1056 |
+
570,
|
| 1057 |
+
928
|
| 1058 |
+
],
|
| 1059 |
+
"page_idx": 9
|
| 1060 |
+
},
|
| 1061 |
+
{
|
| 1062 |
+
"type": "text",
|
| 1063 |
+
"text": "This is shown by proving that $q ( \\pmb { w } ) - p _ { i } ( \\pmb { w } ) \\leq q ( \\pmb { w } ) ( 1 - p ( \\pmb { w } ) ) ^ { i } \\mathrm { \\ : f o r \\ : } i \\in \\mathrm { N } .$ ",
|
| 1064 |
+
"bbox": [
|
| 1065 |
+
173,
|
| 1066 |
+
102,
|
| 1067 |
+
674,
|
| 1068 |
+
119
|
| 1069 |
+
],
|
| 1070 |
+
"page_idx": 10
|
| 1071 |
+
},
|
| 1072 |
+
{
|
| 1073 |
+
"type": "text",
|
| 1074 |
+
"text": "In order to bound the encoding length, one has to first show that if the accepted sample has index $^ { i * }$ , then ",
|
| 1075 |
+
"bbox": [
|
| 1076 |
+
174,
|
| 1077 |
+
125,
|
| 1078 |
+
826,
|
| 1079 |
+
152
|
| 1080 |
+
],
|
| 1081 |
+
"page_idx": 10
|
| 1082 |
+
},
|
| 1083 |
+
{
|
| 1084 |
+
"type": "equation",
|
| 1085 |
+
"img_path": "images/56221cfefb9dd5137f3b7ad96c1bb95d544196cb8a4f0a6d5b70d07d57de6e9d.jpg",
|
| 1086 |
+
"text": "$$\n\\begin{array} { r } { \\operatorname { E } [ \\log i ^ { * } ] \\leq \\operatorname { K L } ( q | | p ) + O ( 1 ) . } \\end{array}\n$$",
|
| 1087 |
+
"text_format": "latex",
|
| 1088 |
+
"bbox": [
|
| 1089 |
+
397,
|
| 1090 |
+
151,
|
| 1091 |
+
601,
|
| 1092 |
+
169
|
| 1093 |
+
],
|
| 1094 |
+
"page_idx": 10
|
| 1095 |
+
},
|
| 1096 |
+
{
|
| 1097 |
+
"type": "text",
|
| 1098 |
+
"text": "Following this, one can employ the prefix-free binary encoding of Vitanyi & Li (1997). Let $l ( n )$ be the length of the encoding for $n \\in \\mathrm { N }$ using the encoding scheme proposed by Vitanyi $\\&$ Li (1997). Their method is proven to have $| l ( n ) | = \\bar { \\log { n } } + 2 \\bar { \\log { \\log ( n + \\bar { 1 } ) } } \\bar { + } O ( 1 )$ , from which the upper bound follows: ",
|
| 1099 |
+
"bbox": [
|
| 1100 |
+
173,
|
| 1101 |
+
171,
|
| 1102 |
+
825,
|
| 1103 |
+
228
|
| 1104 |
+
],
|
| 1105 |
+
"page_idx": 10
|
| 1106 |
+
},
|
| 1107 |
+
{
|
| 1108 |
+
"type": "equation",
|
| 1109 |
+
"img_path": "images/b1ec07169eb434afee8503a783fad0fb9fea983c83b412ba31650015f8a512d3.jpg",
|
| 1110 |
+
"text": "$$\n\\begin{array} { r } { \\mathrm { T } ^ { \\mathcal { R } } [ D : W ] \\leq \\mathrm { E } | l ( i ^ { * } ) | \\leq \\mathrm { K L } ( q | | p ) + 2 \\log ( \\mathrm { K L } ( q | | p ) + 1 ) + O ( 1 ) . } \\end{array}\n$$",
|
| 1111 |
+
"text_format": "latex",
|
| 1112 |
+
"bbox": [
|
| 1113 |
+
271,
|
| 1114 |
+
233,
|
| 1115 |
+
723,
|
| 1116 |
+
252
|
| 1117 |
+
],
|
| 1118 |
+
"page_idx": 10
|
| 1119 |
+
}
|
| 1120 |
+
]
|
parse/train/r1f0YiCctm/r1f0YiCctm_middle.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
parse/train/r1f0YiCctm/r1f0YiCctm_model.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|