ZHANGYUXUAN-zR commited on
Commit
e20b6d0
·
verified ·
1 Parent(s): 157dc6c

Add files using upload-large-folder tool

Browse files
parse/train/B1gjs6EtDr/B1gjs6EtDr.md ADDED
@@ -0,0 +1,329 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # EFFICIENT CONTENT-BASED SPARSE ATTENTION WITH ROUTING TRANSFORMERS
2
+
3
+ Anonymous authors Paper under double-blind review
4
+
5
+ # ABSTRACT
6
+
7
+ Self-attention has recently been adopted for a wide range of sequence modeling problems. Despite its effectiveness, self-attention suffers quadratic compute and memory requirements with respect to sequence length. Successful approaches to reduce this complexity focused on attention to local sliding windows or a small set of locations independent of content. Our work proposes to learn dynamic sparse attention patterns that avoid allocating computation and memory to attend to content unrelated to the query of interest. This work builds upon two lines of research: it combines the modeling flexibility of prior work on content-based sparse attention with the efficiency gains from approaches based on local, temporal sparse attention. Our model, the Routing Transformer, endows self-attention with a sparse routing module based on online $k$ -means while reducing the overall complexity of attention to $O ( n ^ { 1 . 5 } d )$ from $O ( n ^ { 2 } d )$ for sequence length $n$ and hidden dimension $d$ . We show that our model outperforms comparable sparse attention models on language modeling on Wikitext $- 1 0 3$ (15.8 vs 18.3 perplexity) as well as on image generation on ImageNet-64 (3.43 vs 3.44 bits/dim) while using fewer self-attention layers.
8
+
9
+ # 1 INTRODUCTION
10
+
11
+ Generative models of sequences have witnessed rapid progress driven by the application of attention to neural networks. In particular, Bahdanau et al. (2014); Cho et al. (2014); Vaswani et al. (2017) relied on attention to drastically improve the state-of-the art in machine translation. Subsequent research (Radford et al., 2018; Devlin et al., 2018; Liu et al., 2019; Yang et al., 2019) demonstrated the power of self-attention in learning powerful representations of language to address several natural language processing tasks. Self-attention also brought impressive progress for generative modeling outside of language, e.g. image (Parmar et al., 2018; Menick and Kalchbrenner, 2018; Child et al., 2019) and music generation (Huang et al., 2018; Child et al., 2019).
12
+
13
+ Self-attention operates over sequences in a step-wise manner: at every time-step, attention assigns an attention weight to each previous input element (representation of past time-steps) and uses these weights to compute the representation of the current time-step as a weighted sum of the past input elements (Vaswani et al., 2017). Self-attention (Shaw et al., 2018) is a particular case of attention (Bahdanau et al., 2014; Chorowski et al., 2015; Luong et al., 2015).
14
+
15
+ Self-attention is commonly used in auto-regressive generative models. These models generate observations step-by-step, modeling the probability of the next symbol given the previously generated ones. At every time step, self-attentive generative models can directly focus on any part of the previous context. In contrast, recurrent neural networks (RNNs) and convolutional neural networks (CNNs) have direct interactions with only a local neighborhood of context around the current time step.
16
+
17
+ This advantage however comes at a price: unlike recurrent networks or convolution networks, the time and space complexity of self-attention is quadratic in $n$ , the length of the sequence. Specifically, for every position $i \leq n$ , self-attention computes weights for its whole context of length $i$ , which induces a complexity of $\textstyle \sum _ { i \leq n } i = n ( n - 1 ) / 2$ . This makes it difficult to scale attention based models to modeling long sequences. However, long sequences are the norm in many domains, including music, image, speech or video generation.
18
+
19
+ Therefore, an important research direction is to investigate sparse and memory efficient forms of attention in order to scale to tasks with long sequence lengths. Previous work has proposed data independent or fixed sparsity patterns bounding temporal dependencies, such as local or strided attention. At each time step, the model attends only to a fix number of time steps in the past (Child et al., 2019). Extensions to local attention have suggested learning the length of the temporal sparsity for each attention module in the network (Sukhbaatar et al., 2019). These strategies draw their inspiration from RNNs and CNNs and bound their complexity by attending only to representations summarizing a local neighborhood of the current time step. Their attention matrices (matrices containing the attention weights for every pair of previous, current time-step) are natively sparse and requires instantiating only non-zero entries. While these approaches have achieved good results, fixing the sparsity pattern of a content based mechanism such as self-attention can limit its ability to pool in information from large contexts.
20
+
21
+ As an alternative to local attention, Correia et al. (2019) considers content-based sparsity, an approach allowing for arbitrary sparsity patterns. This formulation however does require instantiating a full dense attention matrix prior to sparsification through variants of $L _ { 0 }$ -sparsity or sparsemax approximations (Blondel et al., 2019).
22
+
23
+ The present work builds upon these two lines of research and proposes to retain the modeling flexibility of content-based sparse attention while leveraging the efficiency of natively sparse attention matrices. Our formulation avoids sparsemax variants and relies on clustering of attention instead. Each attention module considers a clustering of the space: the current time-step only attends to context belonging to the same cluster. In other word, the current time-step query is routed to a limited number of context through its cluster assignment. This strategy draws inspiration from the application of $k$ -means clustering to Non-negative Matrix Factorization (NMF) (Lee and Seung, 2001; Ding et al., 2005; Kim and Park, 2008), which is relevant to the sparsification of non-negative matrices like attention matrices.
24
+
25
+ Our proposed model, Routing Transformer, combines our efficient clustered-based sparse attention with classical local attention to reach excellent performance both for language and image generation. These results are obtained without the need to maintain attention matrices larger than batch length which is the case with the segment level recurrence mechanism used in Dai et al. (2019); Sukhbaatar et al. (2019). We present experimental results on language modeling (Wikitext $- 1 0 3$ and enwik-8) and unconditional image generation (ImageNet-64). Routing Transformer sets new state-of-the-art while having comparable or fewer number of self-attention layers and heads, both on Wikitext-103 (15.8 vs 18.3 perplexity) and on ImageNet-64 (3.43 vs 3.44 bits/dim). We also report competitive results on enwik-8 (0.99 vs 0.98 perplexity).
26
+
27
+ # 2 RELATED WORK
28
+
29
+ Attention with Temporal Sparsity: Research on efficient attention neural models parallels the advent of attention-based architectures. In the context of speech recognition, Jaitly et al. (2015) proposed the Neural Transducer which segments sequences in non-overlapping chunks and attention is performed in each chunk independently. Limiting attention to a fixed temporal context around the current prediction has also been explored in Chorowski et al. (2015), while Chiu and Raffel (2017) dynamically segment the sequence into variable sized-chunks.
30
+
31
+ Hierarchical attention strategies have also been explored: the model first considers which part of the inputs should be attended to before computing full attention in a contiguous neighborhood of the selected area (Gregor et al., 2015; Xu et al., 2015; Luong et al., 2015). Later, hierarchical attention has been simplified by Liu et al. (2018) that alternates coarse layers (attending to the whole sequence at a lower temporal resolution) with local layers (attending to a neighborhood of the current prediction).
32
+
33
+ This alternating strategy is also employed by Child et al. (2019), which introduces bounded and strided attention, i.e. attending to a fixed context in the past at a subsampled temporal resolution. This work formalizes such a strategy using a sparse attention formalism, showing how it relates to full attention with a specific sparsity pattern in the attention matrix. It shows that sparse attention is sufficient to get state-of-the-art results in modeling long sequences over language modeling, image generation and music generation. Sukhbaatar et al. (2019) builds upon this work and shows that is it is possible to obtain further sparsity by letting the model learn the length of the temporal context for each attention module. This work also makes use of the attention cache introduced in Dai et al. (2019), a memory mechanism to train models over temporal contexts which extend beyond the length of the training batches.
34
+
35
+ Attention with Content-Based Sparsity: The above work mainly relies on two efficient ideas: attending to less elements by only considering a fixed bounded local context in the past, and attending to less elements by decreasing the temporal resolution of context. These ideas do not allow arbitrary sparsity patterns in attention matrices. Content-based sparse attention has been introduced to allow for richer patterns and more expressive models. Martins and Kreutzer (2017); Malaviya et al. (2018) propose to compute attention weights with variants of sparsemax. Correia et al. (2019) generalizes this approach to every layer in a Transformer using entmax which allows for more efficient inference. This line of work allows for learning arbitrary sparsity attention patterns from data, based on the content of the current query and past context. However, sparsity here cannot be leveraged to improve space and time complexity since sparsemax/entmax formulations require instantiating the full attention matrix prior to sparsification. This is a drawback compared to temporal sparsity approaches. Our work is motivated by bridging this gap and allows for arbitrary sparsity patterns while avoiding to instantiate non-zero entries of attention matrices.
36
+
37
+ Sparse Computation beyond Attention: Learning models with sparse representations/activations for saving time and computation has addressed in the past in various context. Previous work often refers to this goal as gating for conditional computation. Gating techniques relying on sampling and straight-through gradient estimators are common (Bengio et al., 2013; Eigen et al., 2013; Cho and Bengio, 2014). Conditional computation can also be addressed with reinforcement learning (Denoyer and Gallinari, 2014; Indurthi et al., 2019). In the domain of language modeling, a related work is the sparsely gated Mixture-of-experts (MOE) (Shazeer et al., 2017) where sparsity is induced by experts and a trainable gating network controls the routing strategy to each sub-network.
38
+
39
+ # 3 SELF-ATTENTIVE AUTO-REGRESSIVE SEQUENCE MODELING
40
+
41
+ Auto-regressive sequence models decompose the probability of a sequence $\mathbf { x } = ( x _ { 1 } , \ldots , x _ { n } )$ as
42
+
43
+ $$
44
+ p ( \mathbf { x } ) = \prod _ { i = 1 } ^ { n } p _ { \theta } ( x _ { i + 1 } | \boldsymbol { x } _ { \le i } ) .
45
+ $$
46
+
47
+ In neural models, the conditional distribution $p _ { \theta } ( x _ { i + 1 } | x _ { \leq i } )$ is modeled by a neural network with learned parameters $\theta$ and these parameters are typically learned to maximize the likelihood of the training data. In particular, Transformer architectures have shown to reach state-of-the-art accuracy in several domains, including language modeling (Vaswani et al., 2017; Radford et al., 2018), image generation (Parmar et al., 2018) and music generation (Huang et al., 2018). Transformer models compose a series of attention modules. Each module refines the input representation by taking a weighted average of the representations from the previous modules.
48
+
49
+ For every module, the input representation is a sequence of $n$ vectors $\mathbf { x } = ( x _ { 1 } , \ldots , x _ { n } )$ from a continuous space of dimension $d$ . Thus one may actually treat the input sequence as a $n \times d$ matrix $X$ . A self-attention layer operates on this representation. It first applies three linear projections,
50
+
51
+ $$
52
+ Q = X W _ { Q } , \quad K = X W _ { K } , \quad V = X W _ { V } ,
53
+ $$
54
+
55
+ where $Q , K$ and $V$ are referred to as keys, queries and values, while $W _ { Q } , W _ { K } , W _ { V }$ are learned projection matrices.
56
+
57
+ The key and the query matrices determine the $n \times n$ attention matrix $A = \operatorname { s o f t m a x } \left( Q K ^ { \top } \right)$ , where the softmax operator over matrices denotes that the softmax function has been applied to each row. $A$ may be interpreted as a matrix of weights in $[ 0 , 1 ]$ where $A _ { i j }$ denotes how much query position $i$ at the next layer must pay attention to key position $j$ at the previous layer. In the case of self-attention for auto-regressive models, queries attend only over keys from previous time-steps, i.e.
58
+
59
+ $$
60
+ A = \operatorname { s o f t m a x } \left( \operatorname { l t r } ( Q K ^ { \top } ) \right)
61
+ $$
62
+
63
+ where ltr denotes the lower triangular operator. Given the attention matrix $A$ , the next layer representation $X ^ { \prime }$ is computed simply as $A V$ . In summary,
64
+
65
+ $$
66
+ X _ { i } ^ { \prime } = \sum _ { j \leq i } ^ { n } A _ { i j } V _ { j } ,
67
+ $$
68
+
69
+ In practice, Transformer (Vaswani et al., 2017) adds several extensions to this basic self-attention mechanism. In particular, the result $X ^ { \prime }$ of performing self-attention is scaled by $1 / { \sqrt { d } }$ . Moreover, each layer relies on multiple attention heads, i.e. each layer performs multiple projections onto triplet (queries, keys, values) and attention is performed for each head. The attention results from all heads are then concatenated. This strategy allows each head to specialize on different aspects of the input sequence. In addition, Transformer further processes the result of attention through a learnable non-linear transformation (multi-layer perceptron, mlp) followed by a residual connection and a normalization step, i.e.
70
+
71
+ $$
72
+ \begin{array} { l c r } { { X ^ { \prime } = \mathrm { l a y e r n o r m } ( X ^ { \prime } + X ) } } \\ { { X ^ { \prime \prime } = \mathrm { l a y e r n o r m } ( \mathrm { m l p } ( X ^ { \prime } ) + X ) , } } \end{array}
73
+ $$
74
+
75
+ where layernorm denotes the parameterized normalization step from Ba et al. (2016). A full Transformer model is therefore a chain of attention modules (Eq. 6) preceded by an embedding module (learnable representation for symbols and their positions) and followed by a logistic classification module (learnable linear classifier to predict the next symbol).
76
+
77
+ Our work is interested in the application of the Transformer to long sequences, a challenging problem since space and time complexity of attention is quadratic in sequence length $n$ . We describe various approaches to sparse attention including ours in the next section.
78
+
79
+ # 4 EFFICIENT CONTENT-DEPENDENT SPARSE ATTENTION
80
+
81
+ Attention-based models can be problematic for long sequences. For a sequence of length $n$ , the full attention matrix $A$ , as introduced in Section 3, is $n \times n$ -dimensional and can be prohibitive to instantiate. This motivates sparse attention models, i.e. models relying on attention matrices which have a majority of zero entries.
82
+
83
+ For each query, a sparse attention model defines a set of keys which can be attended to. In the following, we introduce the set $S _ { i }$ as the set of key positions that the query at position $i$ can attend to, i.e.
84
+
85
+ $$
86
+ X _ { i } ^ { \prime } = \sum _ { j \in S _ { i } } A _ { i j } V _ { j } .
87
+ $$
88
+
89
+ For example, classical causal self attention can attend to every key prior to the current query, which translates to $S _ { i } = \{ j \mid j < i \}$ . Most previous work on attention sparsity defined such sets purely based on positions, independently of actual query and key vectors. For example, local attention (Luong et al., 2015) considers attending only to a $k$ -long time window prior to the current query, $S _ { i } = \bar { \{ j | i - k \leq j < i \} } ,$ . Child et al. (2019) propose block sparse attention where half the heads perform local attention, and half the heads perform strided attention given by $S _ { i } = \{ j \ | \ i - j$ $( \mathrm { m o d } \ k ) = 0 , j < i \}$ . Sukhbaatar et al. (2019) is also a variant of local attention where the cardinality of $| S _ { i } |$ is learned from data with an $L _ { 1 }$ penalty to trade-off sparsity with modeling accuracy.
90
+
91
+ These local attention sparsity variants are effective in practice since correlation between observations naturally decrease with time for many problems. In our experiments, we actually find that local attention is a surprisingly strong baseline in both image generation and language modeling: for e.g., a scaled up ImageTransformer (Parmar et al., 2018) gets 3.48 bits/dim compared to the 3.44 bits/dim reported in (Child et al., 2019). Similarly, scaled up versions of Transformer with local attention and the relative positional encoding scheme of Shaw et al. (2018) are able to get 19.8 perplexity on Wikitext $- 1 0 3$ and 1.10 bits per byte on enwik-8, while the state-of-the-art results using Transformer-XL (Dai et al., 2019) are 18.3 and 0.99 respectively. From an efficiency perspective, local attention is also interesting since sparsity patterns are regular, contiguous in memory and known in advance.
92
+
93
+ In this work, however, we are interested in a more generic formulation of attention sparsity and would like the sparsity pattern to be informed by the data, i.e., $\begin{array} { r } { \boldsymbol { S } = f ( \mathbf { x } ) } \end{array}$ . This approach has several modeling advantages: it can accommodate data without a clear ordering over observations. For temporal data, it can also discover patterns with greater sparsity if some types of queries have a longer lasting effect on future observations than others. Content-based sparse attention should however be carefully implemented if we need to avoid instantiating full attention matrices at any point in time.
94
+
95
+ For instance, Correia et al. (2019) infer sparsity from data but their formulation instantiates a full attention matrix before finding its sparse counterpart. Next section explains how a natively sparse approach can actually be devised inspired by non-negative matrix factorization (NMF).
96
+
97
+ # 4.1 CLUSTER ATTENTION WITH NON-NEGATIVE LOW RANK APPROXIMATIONS
98
+
99
+ For any given $n \times n$ matrix $A$ , a low-rank non-negative approximation to it is of the form $H = F G ^ { \top }$ where $\bar { F , G } \in \mathbb { R } ^ { n \times k }$ and $F , G \geq 0$ . This factorization can be interpreted as follows: $n$ total items are routed to $k$ representatives determined by the attention matrix $F$ , while each of the representative $k$ items perform full attention on the $n$ items determined by matrix $G$ . Therefore, the whole attention matrix passes through a bottleneck of size $k$ .
100
+
101
+ NMF studies algorithms to find such approximations (Tandon and Sra, 2010), for instance minimizing the Frobenius norm,
102
+
103
+ $$
104
+ H = \arg \operatorname* { m i n } _ { G ^ { \top } G = I , F , G \geq 0 } \left\| A - F G ^ { \top } \right\| ^ { 2 } .
105
+ $$
106
+
107
+ Different algorithms have been proposed for that problem, with different trade-offs in terms of theoretical guarantees, actual accuracy and efficiency (Lee and Seung, 2001; Hoyer, 2004; Gemulla et al., 2011). In particular, $k$ -means clustering (Lloyd, 1982) has been studied as a tractable approximation to non-negative low-rank matrix factorization problem (Ding et al., 2005; Kim and Park, 2008).
108
+
109
+ This relation between $k$ -means and NMF motivates our work but cannot however be applied directly in our case. In particular, we want to avoid instantiating $A$ before approximating it. Furthermore, although we are interested in low rank sparsity patterns, our application context does not require $H$ itself to be low rank. We therefore propose a simpler strategy where $k$ -means is applied to find the routing pattern, while the attention matrix itself remains full rank. Moreover, our approach maintains a single set of cluster centroids shared across examples, which allows for fast training and inference. We describe this strategy in the next section.
110
+
111
+ # 4.2 ROUTING ATTENTION WITH CLUSTERING
112
+
113
+ Our strategy follows the motivation we delineated in the previous section: we model sparse attention matrices with a low rank sparsity patterns relying on $k$ -means clustering. Our strategy first assigns queries and keys to clusters. Then only queries and keys from the same cluster are considered for attention.
114
+
115
+ Precisely, our model projects keys $K$ and queries $Q$ into a routing matrix $R \in \mathbb { R } ^ { n \times d }$ as follows
116
+
117
+ $$
118
+ R = [ Q , K ] \left[ W _ { R } \right]
119
+ $$
120
+
121
+ where $W _ { R }$ is a fixed random orthonormal $d \times d$ routing projection matrix. The vectors of $R$ undergo $k$ -means clustering in order to factorize the full attention matrix. The clustering parameters are the centroid vectors $( \mu _ { 1 } , \cdot \cdot \cdot , \mu _ { k } ) \in \mathbb { R } ^ { k \times d }$ . These parameters are model parameters shared across sequences. There are learned online along with the rest of the parameters, as delineated in Bottou and Bengio (1995). Once cluster membership for each position $i$ in the sequence is determined, we denote with $C _ { i }$ the cluster corresponding to the routing vector $R _ { i }$ . This allows us to define our sparse attention strategy as
122
+
123
+ $$
124
+ X _ { i } ^ { \prime } = \sum _ { j \in C _ { i } , j \leq i } A _ { i j } V _ { j }
125
+ $$
126
+
127
+ where $C _ { i }$ denotes the cluster of the vector $R _ { i }$ . In summary, queries are routed to keys belonging to the same cluster. Therefore, our attention sparsity pattern is of rank $k$ , i.e. $F G ^ { \mathsf { T } }$ where $F$ and $G$ are binary matrices denoting cluster memberships of queries and keys respectively. Note that since we route both queries and keys via the routing matrix $R$ , it follows that $F = G$ . It is important to note that this low rank property only concerns the sparsity pattern, while the resulting attention matrix $\operatorname { l t r } ( F G ^ { \top } * A ) = \operatorname { l t r } ( { \dot { F } } F ^ { \top } * { \dot { A } } )$ can however be of higher rank ( $^ *$ denotes element-wise product).
128
+
129
+ As a last technical point, we work with keys and values which are unitary vectors, projecting them onto the unit ball immediately before computing them. This differentiable normalization (Ba et al.,
130
+
131
+ 2016) is useful to link cluster memberships with proximity of queries and keys, as outlined below. We also assume that the max norm of $W _ { Q }$ and $W _ { K }$ are close to each other - for more details see Appendix A. This can be enforced by adding an auxiliary loss or by explicitly setting $W _ { Q } = W _ { K }$ . Since $W _ { R }$ is a distance preserving transform, we can write
132
+
133
+ $$
134
+ \begin{array} { r l } & { \| R _ { i } - R _ { j } \| ^ { 2 } = \| W _ { R } ( Q _ { i } + K _ { i } ) - W _ { R } ( Q _ { j } + K _ { j } ) \| ^ { 2 } } \\ & { \qquad \gtrapprox \| W _ { R } \| ^ { 2 } \left( \| Q _ { i } - K _ { j } \| ^ { 2 } + \| Q _ { j } - K _ { i } \| ^ { 2 } \right) } \\ & { \qquad = 4 - 2 \left( Q _ { i } ^ { \top } K _ { j } + Q _ { j } ^ { \top } K _ { i } \right) . } \end{array}
135
+ $$
136
+
137
+ Thus, it follows that $\begin{array} { r } { \| R _ { i } - R _ { j } \| \le \varepsilon \Rightarrow Q _ { i } ^ { \top } K _ { j } + Q _ { j } ^ { \top } K _ { i } \ge 2 - \varepsilon ^ { 2 } / 2 } \end{array}$ . This means that, $\| R _ { i } - R _ { j } \| \leq$ $\varepsilon \Rightarrow Q _ { i } ^ { \top } K _ { j } \geq 1 - \varepsilon ^ { 2 } / 4$ . Therefore, when two time steps $i > j$ are assigned the same cluster due to a small $\| R _ { i } - R _ { j } \|$ distance, it also means that their attention weight $Q _ { i } ^ { \top } K _ { j }$ is high. This analysis shows that our clustering routing strategy preserves large attention weights as non-zero entries.
138
+
139
+ Since, we route attention via the matrix $R$ we dub our model Routing Transformer. The computational complexity of this variant of sparse attention is $O ( n k d + n ^ { 2 } d / k )$ . Cluster assignments correspond to the first term, i.e. it compares $n$ routing vectors to all $k$ centroids in a space of size $d$ . Query/key dot products corresponds to the second term, i.e. assuming balanced clusters, each of the $n$ queries is compared to √ $n / k$ in its cluster through a dot product of dimension $d$ . Therefore the optimal choice of $k$ is $\sqrt { n }$ as in Child et al. (2019), thereby reducing overall memory and computational cost to $O \left( n ^ { 1 . 5 } \dot { d } \right)$ instead of $O ( n ^ { 2 } d )$ (Vaswani et al., 2017).
140
+
141
+ In practice, we apply regular online $k$ -means to train the cluster centroids. However, in order to infer balanced routing patterns, we define the sets $C _ { i }$ to be of equal size roughly $n / k \sim \sqrt { n }$ , i.e. for every centroid $\mu _ { i }$ we sort tokens by distance to $\mu _ { i }$ and cluster membership is determined by this threshold (top-k). This strategy is simple and efficient. In particular, it guarantees that all clusters have the same size, which is extremely interesting in terms of computational efficiency on parallel hardware like graphic cards. As a downside, this assignment does not guarantee that each point belongs to a single cluster. In the future, we want to investigate using balanced variants of $k$ -means (Malinen and Fränti, 2014) which is not common in an online setting.
142
+
143
+ # 5 EXPERIMENTS
144
+
145
+ We evaluate our sparse attention model on various generative modeling tasks including text and image generation. The following sections report our results on Wikitext $- 1 0 3$ (Merity et al., 2016), enwik-8 (Mahoney, 2011), as well as ImageNet-64. We find that local attention is a surprisingly strong baseline and that our Routing Transformer outperforms Transformer-XL (Dai et al., 2019) and the Sparse Transformer model of (Child et al., 2019) on all tasks. In all our models, we allocate half the heads to do local attention and the other half to route attention as in Equation 10. We use the Adam optimizer (Kingma and Ba, 2014) with learning rate $2 \times 1 0 ^ { - 4 }$ with $\beta _ { 1 } = 0 . 9$ and $\beta _ { 2 } = 0 . 9 8$ following the learning rate schedule described in Vaswani et al. (2017).
146
+
147
+ # 5.1 WIKITEXT-103
148
+
149
+ Wikitext-103 (Merity et al., 2016) is a large public benchmark data-set for testing long term dependencies in word-level language models. It contains over 100 million tokens from 28K articles extracted from Wikipedia with an average of 3.6K tokens per article, which makes it a reference data-set to model long-term textual dependencies. We train a 10 layer Routing Transformer with 16 heads using the relative position encoding of Shaw et al. (2018) and with attention and ReLU dropout rate of 0.3 each. For routing attention as in Section 4.2 we choose $k = 1 6$ and attention window to be 256 during both training and evaluation. We describe our results in Table 2 and compare it to other recent work on sparse or recurrent attention such as Adaptive Inputs (Baevski and Auli, 2018) and TransformerXL (Dai et al., 2019) as well as a local attention with relative position encoding baseline (Huang et al., 2018). We find that local attention is a great inductive bias for sparse attention and is better than the adaptive methods proposed in Baevski and Auli (2018); Sukhbaatar et al. (2019). Moreover, our Routing Transformer model is able to get a test perplexity of 15.8 improving on the 18.3 obtained by TransformerXL (Dai et al., 2019) while having fewer self-attention layers, and without the need for segment level recurrence.
150
+
151
+ # 5.2 ENWIK-8
152
+
153
+ The enwik-8 (Mahoney, 2011) is a data-set to benchmark text compression algorithms in the context of the Hutter prize. This data-set consists of the first 100M bytes of unprocessed Wikipedia. It is typically used to evaluate character-level language models. Similar to the prior work of Dai et al. (2019); Child et al. (2019) we use a sequence length $n = 8 1 9 2$ and benchmark our results against various baselines including local attention. We train a 24 layer model with 8 attention heads with an attention and ReLU dropout rate of 0.4 each and using the relative position encoding of Shaw et al. (2018). For routing attention as in Section 4.2 we set $k = 3 2$ and attention window 256. We report perplexity of 0.99 like TransformerXL and Sparse Transformer, slightly under 0.98 from Adaptive Transformer. We show how samples of our model differs from Transformer with local attention in Appendix C.
154
+
155
+ # 5.3 IMAGENET $6 4 \times 6 4$
156
+
157
+ In order to evaluate the ability of our model to capture long term dependencies on a modality other than text, we report results on the ImageNet $6 4 \times 6 4$ data-set as used in Child et al. (2019). For auto-regressive image generation, this data-set consists of images of $6 4 \times 6 4 \times 3$ bytes represented as long sequences of length 12, 288 presented in raster scan, red-green-blue order. We train a 24 layer model with 16 attention heads, with half the heads performing local attention, and the other half routing attention as in Section 3. For routing attention we set $k = 8$ , attention window 2048, batch size 1 and train our model for roughly 70 epochs as in (Child et al., 2019). We compare our model to a scaled-up ImageTransformer model with local attention (Parmar et al., 2018) and the SparseTransformer model of Child et al. (2019).
158
+
159
+ We find that local attention (Parmar et al., 2018) is a strong baseline for image generation, obtaining 3.48 bits/dim when scaled up to 24 layers and 16 heads, compared to later work like Sub-scale Pixel Networks (SPN) (Menick and Kalchbrenner, 2018). Our Routing Transformer model achieves a performance of 3.425 bits/dim (see Table 1) compared to the previous state-of-the-art of 3.437 bits/dim (Child et al., 2019), thereby showing the advantage of the content based sparsity formulation of Section 4.2.
160
+
161
+ Table 1: Results on image generation on ImageNet $6 4 \times 6 4$ in bits/dim.
162
+
163
+ <table><tr><td>Model</td><td></td><td></td><td>|Layers|Heads|Bits/dim</td></tr><tr><td>Glow (Kingma and Dhariwal, 2018)</td><td></td><td></td><td>3.81</td></tr><tr><td>PixelCNN(Van den Oord et al., 2016)</td><td></td><td></td><td>3.57</td></tr><tr><td>PixelSNAIL (Chen et al., 2017)</td><td></td><td></td><td>3.52</td></tr><tr><td>SPN (Menick and Kalchbrenner, 2018)</td><td>=</td><td>、</td><td>3.52</td></tr><tr><td>ImageTransformer (Parmar etal., 2018)</td><td>24</td><td>16</td><td>3.48</td></tr><tr><td>Sparse Transformer (Child et al., 2019)</td><td>48</td><td>16</td><td>3.44</td></tr><tr><td>Routing Transformer</td><td>24</td><td>16</td><td>3.43</td></tr></table>
164
+
165
+ Table 2: Results on language modeling on Wikitext $- 1 0 3$ data-set. Local Transformer refers to Transformer (Vaswani et al., 2017) with relative position encoding (Shaw et al., 2018) together with local attention. Perplexity is reported on the test set.
166
+
167
+ <table><tr><td>Model</td><td></td><td></td><td>Layers|Heads|Perplexity</td></tr><tr><td>LSTMs (Grave et al., 2016)</td><td></td><td>=</td><td>40.8</td></tr><tr><td>QRNNs (Merity et al., 2018)</td><td>=</td><td>1</td><td>33.0</td></tr><tr><td>Adaptive Transformer (Sukhbaatar et al., 2019)</td><td>36</td><td>8</td><td>20.6</td></tr><tr><td>Local Transformer</td><td>16</td><td>16</td><td>19.8</td></tr><tr><td>Adaptive Input (Baevski and Auli, 2018)</td><td>16</td><td>16</td><td>18.7</td></tr><tr><td>TransformerXL (Dai et al., 2019)</td><td>18</td><td>16</td><td>18.3</td></tr><tr><td>Routing Transformer</td><td>10</td><td>16</td><td>15.8</td></tr></table>
168
+
169
+ Table 3: Results on language modeling on enwik-8 data-set. Local Transformer refers to Transformer (Vaswani et al., 2017) with relative position encoding (Shaw et al., 2018) together with local attention. Bits per byte (bpc) is reported on the test set.
170
+
171
+ <table><tr><td>Model</td><td></td><td></td><td>|Layers |Heads 丨Bits per byte</td></tr><tr><td>T64 (Al-Rfou et al., 2019)</td><td>64</td><td>2</td><td>1.13</td></tr><tr><td>Local Transformer</td><td>24</td><td>8</td><td>1.10</td></tr><tr><td>TransformerXL (Dai et al., 2019)</td><td>24</td><td>8</td><td>0.99</td></tr><tr><td>Sparse Transformer (Child et al., 2019)</td><td>30</td><td>8</td><td>0.99</td></tr><tr><td>Adaptive Transformer (Sukhbaatar et al., 2019)</td><td>24</td><td>8</td><td>0.98</td></tr><tr><td>Routing Transformer</td><td>12</td><td>8</td><td>0.99</td></tr></table>
172
+
173
+ # 6 ANALYSIS
174
+
175
+ We evaluate the difference in attention patterns between local and routed attention and compute the Jensen-Shannon divergence between local attention and routed attention for a random subset of heads in our network on the Wikitext-103 data-set. The divergence is computed over the entire sequence length of 4096. We average over 10 runs and all the self-attention layers, and report means and standard deviations of the JSD in Table 4. For mean JSD per layer, see Appendix B. Note that the JSD is always non-negative and is upper-bounded by 0.6931 when computed using the natural logarithm. We observe that the divergence between the different local heads is always very low compared to the divergence between local and routing attention heads, which is almost always very close to the upper-bound of 0.6931. Divergence between different routing attention heads falls somewhere in between, being closer to the upper-bound. This shows that the attention distribution inferred by the routing attention of Section 4.2 is highly non-local in nature and different heads specialize in attending to very different parts of the input.
176
+
177
+ <table><tr><td></td><td></td><td> JSD(localllocal) | JSD(local||routing) | JSD(routingllrouting)</td></tr><tr><td>0.1776±0.0649|0.6044±0.0181</td><td></td><td>0.4181 ± 0.0415</td></tr></table>
178
+
179
+ Table 4: Jensen-Shannon divergence between the attention distributions of a random local attention head and a random head that routes attention as in Section 3 averaged across all layers on the Wikitext $- 1 0 3$ data-set. We report means and standard deviations computed over 10 runs.
180
+
181
+ # 7 CONCLUSION
182
+
183
+ Transformer models constitutes the state-of-the-art in auto-regressive generative models for sequential data. Their space-time complexity is however quadratic in sequence length, due to their attention modules. Our work proposes a sparse attention model, the Routing Transformer. It relies on contentbased sparse attention motivated by non-negative matrix factorization. Compared with local attention models, it does not require fixed attention patterns but enjoys similar space-time complexity. In contrast with prior work on content-based sparse attention, it does not require computing a full attention matrix but still selects sparsity patterns based on content similarity.
184
+
185
+ Our experiments over text and image generation draw two main conclusions. First, we show that a carefully tuned local attention model establishes a strong baseline on modern benchmark, even compared to recent state-of-the-art models. Second, we show that the Routing Transformer redefines the state-of-the-art in large long sequence benchmarks of Wikitext-103 and ImageNet-64, while being very close to do so on enwik-8 as well. Our analysis also shows that routed attention modules offer complementary attention patterns when compared to local attention.
186
+
187
+ Overall, our work contributes an efficient attention mechanism that applies to the modeling of long sequences and redefines the state of the art for auto-regressive generative modeling. Our approach could prove useful in domains where the inputs are already sparse, such as 3D point clouds, social networks or protein interactions.
188
+
189
+ # REFERENCES
190
+
191
+ Rami Al-Rfou, Dokook Choe, Noah Constant, Mandy Guo, and Llion Jones. Character-level language modeling with deeper self-attention. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 33, pages 3159–3166, 2019. 8
192
+
193
+ Jimmy Lei Ba, Jamie Ryan Kiros, and Geoffrey E Hinton. Layer normalization. arXiv preprint arXiv:1607.06450, 2016. URL http://arxiv.org/abs/1607.06450. 4, 5
194
+
195
+ Alexei Baevski and Michael Auli. Adaptive input representations for neural language modeling. arXiv preprint arXiv:1809.10853, 2018. 6, 7
196
+
197
+ Dzmitry Bahdanau, Kyunghyun Cho, and Yoshua Bengio. Neural machine translation by jointly learning to align and translate. CoRR, abs/1409.0473, 2014. URL http://arxiv.org/abs/ 1409.0473. 1
198
+
199
+ Yoshua Bengio, Nicholas Léonard, and Aaron Courville. Estimating or propagating gradients through stochastic neurons for conditional computation. arXiv preprint arXiv:1308.3432, 2013. 3
200
+
201
+ Mathieu Blondel, André F. T. Martins, and Vlad Niculae. Learning classifiers with fenchel-young losses: Generalized entropies, margins, and algorithms. In The 22nd International Conference on Artificial Intelligence and Statistics, AISTATS 2019, 16-18 April 2019, Naha, Okinawa, Japan, pages 606–615, 2019. URL http://proceedings.mlr.press/v89/blondel19a. html. 2
202
+
203
+ Leon Bottou and Yoshua Bengio. Convergence properties of the k-means algorithms. In Advances in neural information processing systems, pages 585–592, 1995. 5
204
+
205
+ Xi Chen, Nikhil Mishra, Mostafa Rohaninejad, and Pieter Abbeel. Pixelsnail: An improved autoregressive generative model. arXiv preprint arXiv:1712.09763, 2017. 7
206
+
207
+ Rewon Child, Scott Gray, Alec Radford, and Ilya Sutskever. Generating long sequences with sparse transformers. arXiv preprint arXiv:1904.10509, 2019. 1, 2, 4, 6, 7, 8
208
+
209
+ Chung-Cheng Chiu and Colin Raffel. Monotonic chunkwise attention. arXiv preprint arXiv:1712.05382, 2017. 2
210
+
211
+ Kyunghyun Cho and Yoshua Bengio. Exponentially increasing the capacity-to-computation ratio for conditional computation in deep learning. arXiv preprint arXiv:1406.7362, 2014. 3
212
+
213
+ Kyunghyun Cho, Bart van Merrienboer, Caglar Gulcehre, Fethi Bougares, Holger Schwenk, and Yoshua Bengio. Learning phrase representations using RNN encoder-decoder for statistical machine translation. CoRR, abs/1406.1078, 2014. URL http://arxiv.org/abs/1406.1078. 1
214
+
215
+ Jan K Chorowski, Dzmitry Bahdanau, Dmitriy Serdyuk, Kyunghyun Cho, and Yoshua Bengio. Attention-based models for speech recognition. In Advances in neural information processing systems, pages 577–585, 2015. 1, 2
216
+
217
+ Gonçalo M. Correia, Vlad Niculae, and André F. T. Martins. Adaptively sparse transformers, 2019. 2, 3, 5
218
+
219
+ Zihang Dai, Zhilin Yang, Yiming Yang, William W Cohen, Jaime Carbonell, Quoc V Le, and Ruslan Salakhutdinov. Transformer-xl: Attentive language models beyond a fixed-length context. arXiv preprint arXiv:1901.02860, 2019. 2, 3, 4, 6, 7, 8
220
+
221
+ Ludovic Denoyer and Patrick Gallinari. Deep sequential neural network. arXiv preprint arXiv:1410.0510, 2014. 3
222
+
223
+ Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. Bert: Pre-training of deep bidirectional transformers for language understanding. arXiv preprint arXiv:1810.04805, 2018. 1
224
+
225
+ Chris Ding, Xiaofeng He, and Horst D Simon. On the equivalence of nonnegative matrix factorization and spectral clustering. In Proceedings of the 2005 SIAM International Conference on Data Mining, pages 606–610. SIAM, 2005. 2, 5
226
+
227
+ David Eigen, Marc’Aurelio Ranzato, and Ilya Sutskever. Learning factored representations in a deep mixture of experts. arXiv preprint arXiv:1312.4314, 2013. 3
228
+
229
+ Rainer Gemulla, Erik Nijkamp, Peter J. Haas, and Yannis Sismanis. Large-scale matrix factorization with distributed stochastic gradient descent. In SIGKDD International Conference on Knowledge Discovery and Data Mining, KDD ’11, 2011. 5
230
+
231
+ Edouard Grave, Armand Joulin, and Nicolas Usunier. Improving neural language models with a continuous cache. arXiv preprint arXiv:1612.04426, 2016. 7
232
+
233
+ Karol Gregor, Ivo Danihelka, Alex Graves, Danilo Jimenez Rezende, and Daan Wierstra. Draw: A recurrent neural network for image generation. arXiv preprint arXiv:1502.04623, 2015. 2
234
+
235
+ Patrik O Hoyer. Non-negative matrix factorization with sparseness constraints. Journal of machine learning research, 5(Nov):1457–1469, 2004. 5
236
+
237
+ Cheng-Zhi Anna Huang, Ashish Vaswani, Jakob Uszkoreit, Ian Simon, Curtis Hawthorne, Noam Shazeer, Andrew M Dai, Matthew D Hoffman, Monica Dinculescu, and Douglas Eck. Music transformer: Generating music with long-term structure. 2018. 1, 3, 6
238
+
239
+ Sathish Reddy Indurthi, Insoo Chung, and Sangha Kim. Look harder: A neural machine translation model with hard attention. In Proceedings of the 57th Conference of the Association for Computational Linguistics, pages 3037–3043, 2019. 3
240
+
241
+ Navdeep Jaitly, David Sussillo, Quoc V Le, Oriol Vinyals, Ilya Sutskever, and Samy Bengio. A neural transducer. arXiv preprint arXiv:1511.04868, 2015. 2
242
+
243
+ Jingu Kim and Haesun Park. Sparse nonnegative matrix factorization for clustering. Technical report, Georgia Institute of Technology, 2008. 2, 5
244
+
245
+ Diederik P. Kingma and Jimmy Ba. Adam: A method for stochastic optimization. CoRR, abs/1412.6980, 2014. URL http://arxiv.org/abs/1412.6980. 6
246
+
247
+ Durk P Kingma and Prafulla Dhariwal. Glow: Generative flow with invertible 1x1 convolutions. In Advances in Neural Information Processing Systems, pages 10215–10224, 2018. 7
248
+
249
+ Daniel D Lee and H Sebastian Seung. Algorithms for non-negative matrix factorization. In Advances in neural information processing systems, pages 556–562, 2001. 2, 5
250
+
251
+ Peter J Liu, Mohammad Saleh, Etienne Pot, Ben Goodrich, Ryan Sepassi, Lukasz Kaiser, and Noam Shazeer. Generating wikipedia by summarizing long sequences. arXiv preprint arXiv:1801.10198, 2018. 2
252
+
253
+ Xiaodong Liu, Pengcheng He, Weizhu Chen, and Jianfeng Gao. Multi-task deep neural networks for natural language understanding. arXiv preprint arXiv:1901.11504, 2019. 1
254
+
255
+ Stuart Lloyd. Least squares quantization in pcm. IEEE transactions on information theory, 28(2): 129–137, 1982. 5
256
+
257
+ Minh-Thang Luong, Hieu Pham, and Christopher D Manning. Effective approaches to attention-based neural machine translation. arXiv preprint arXiv:1508.04025, 2015. 1, 2, 4
258
+
259
+ Matt Mahoney. Large text compression benchmark. URL: http://www. mattmahoney. net/text/text. html, 2011. 6, 7
260
+
261
+ Chaitanya Malaviya, Pedro Ferreira, and André F. T. Martins. Sparse and constrained attention for neural machine translation. In Proceedings of the 56th Annual Meeting of the Association for Computational Linguistics (Volume 2: Short Papers), pages 370–376, Melbourne, Australia, July 2018. Association for Computational Linguistics. doi: 10.18653/v1/P18-2059. URL https: //www.aclweb.org/anthology/P18-2059. 3
262
+
263
+ Mikko I Malinen and Pasi Fränti. Balanced k-means for clustering. In Joint IAPR International Workshops on Statistical Techniques in Pattern Recognition (SPR) and Structural and Syntactic Pattern Recognition (SSPR), pages 32–41. Springer, 2014. 6
264
+
265
+ André F. T. Martins and Julia Kreutzer. Learning what’s easy: Fully differentiable neural easy-first taggers. In Proceedings of the 2017 Conference on Empirical Methods in Natural Language Processing, pages 349–362, Copenhagen, Denmark, September 2017. Association for Computational Linguistics. doi: 10.18653/v1/D17-1036. URL https://www.aclweb.org/anthology/ D17-1036. 3
266
+
267
+ Jacob Menick and Nal Kalchbrenner. Generating high fidelity images with subscale pixel networks and multidimensional upscaling. arXiv preprint arXiv:1812.01608, 2018. 1, 7
268
+
269
+ Stephen Merity, Caiming Xiong, James Bradbury, and Richard Socher. Pointer sentinel mixture models. arXiv preprint arXiv:1609.07843, 2016. 6
270
+
271
+ Stephen Merity, Nitish Shirish Keskar, and Richard Socher. An analysis of neural language modeling at multiple scales. arXiv preprint arXiv:1803.08240, 2018. 7
272
+
273
+ Niki Parmar, Ashish Vaswani, Jakob Uszkoreit, Łukasz Kaiser, Noam Shazeer, Alexander Ku, and Dustin Tran. Image transformer. arXiv preprint arXiv:1802.05751, 2018. 1, 3, 4, 7
274
+
275
+ Alec Radford, Karthik Narasimhan, Tim Salimans, and Ilya Sutskever. Improving language understanding by generative pre-training. URL https://s3-us-west-2. amazonaws. com/openaiassets/research-covers/languageunsupervised/language understanding paper. pdf, 2018. 1, 3
276
+
277
+ Peter Shaw, Jakob Uszkoreit, and Ashish Vaswani. Self-attention with relative position representations. arXiv preprint arXiv:1803.02155, 2018. 1, 4, 6, 7, 8
278
+
279
+ Noam Shazeer, Azalia Mirhoseini, Krzysztof Maziarz, Andy Davis, Quoc Le, Geoffrey Hinton, and Jeff Dean. Outrageously large neural networks: The sparsely-gated mixture-of-experts layer. arXiv preprint arXiv:1701.06538, 2017. 3
280
+
281
+ Sainbayar Sukhbaatar, Edouard Grave, Piotr Bojanowski, and Armand Joulin. Adaptive attention span in transformers. arXiv preprint arXiv:1905.07799, 2019. 2, 4, 6, 7, 8
282
+
283
+ R. Tandon and S. Sra. Sparse nonnegative matrix approximation: new formulations and algorithms. Technical Report 193, Max Planck Institute for Biological Cybernetics, Tübingen, Germany, September 2010. 5
284
+
285
+ Aaron Van den Oord, Nal Kalchbrenner, Lasse Espeholt, Oriol Vinyals, Alex Graves, et al. Conditional image generation with pixelcnn decoders. In Advances in neural information processing systems, pages 4790–4798, 2016. 7
286
+
287
+ Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N. Gomez, Lukasz Kaiser, and Illia Polosukhin. Attention is all you need. CoRR, 2017. URL http: //arxiv.org/abs/1706.03762. 1, 3, 4, 6, 7, 8
288
+
289
+ Kelvin Xu, Jimmy Lei Ba, Ryan Kiros, Kyunghyun Cho, Aaron Courville, Ruslan Salakhutdinov, Richard S. Zemel, and Yoshua Bengio. Show, attend and tell: Neural image caption generation with visual attention. In ICML, 2015. 2
290
+
291
+ Zhilin Yang, Zihang Dai, Yiming Yang, Jaime Carbonell, Ruslan Salakhutdinov, and Quoc V Le. Xlnet: Generalized autoregressive pretraining for language understanding. arXiv preprint arXiv:1906.08237, 2019. 1
292
+
293
+ # A MATRIX NORM ANALYSIS
294
+
295
+ In order to formally derive Equation 11, we assume that the linear projection matrices $W _ { Q }$ and $W _ { K }$ used to infer the queries and keys respectively are close to each other in max norm. More precisely, we assume the existence of a $\delta \geq 0$ such that $\left\| W _ { Q } - W _ { K } \right\| _ { \infty } \leq \delta$ . This assumption implies that for any vector $u \in \mathbb { R } ^ { d }$ it holds that:
296
+
297
+ $$
298
+ u W _ { Q } \leq u W _ { K } + \delta \mathbf { 1 } \left\| u \right\| _ { \infty } ,
299
+ $$
300
+
301
+ where the inequality is entry-wise and 1 is the vector in $\mathbb { R } ^ { d }$ with all 1’s. In this case we first show that for any pair $i , j$ the queries and keys satisfy the following:
302
+
303
+ $$
304
+ \begin{array} { r l } & { ( Q _ { i } - K _ { j } ) ^ { \top } ( Q _ { j } - K _ { i } ) = ( X _ { i } W _ { Q } - X _ { j } W _ { K } ) ^ { \top } ( X _ { j } W _ { Q } - X _ { i } W _ { K } ) } \\ & { \qquad \leq ( \delta { \mathbf { 1 } \| X _ { i } \| _ { \infty } } + ( X _ { i } - X _ { j } ) W _ { K } ) ^ { \top } ( \delta { \mathbf { 1 } \| X _ { j } \| _ { \infty } } - ( X _ { i } - X _ { j } ) W _ { K } ) } \\ & { \qquad \leq \delta ^ { 2 } \| { \mathbf { 1 } \| ^ { 2 } \operatorname* { m a x } \{ \| X _ { i } \| _ { \infty } , \| X _ { j } \| _ { \infty } \} ^ { 2 } } - \| ( X _ { i } - X _ { j } ) W _ { K } \| ^ { 2 } } \end{array}
305
+ $$
306
+
307
+ Therefore, for small enough $\delta$ , we get that $( Q _ { i } - Q _ { j } ) ^ { \top } ( Q _ { j } - K _ { i } ) \lessapprox 0$ and so Equation 11 follows:
308
+
309
+ $$
310
+ \begin{array} { r l } & { \| R _ { i } - R _ { j } \| ^ { 2 } = \| W _ { R } ( Q _ { i } + K _ { i } ) - W _ { R } ( Q _ { j } + K _ { j } ) \| ^ { 2 } } \\ & { \qquad = \| W _ { R } \| ^ { 2 } \left( \| Q _ { i } - K _ { j } \| ^ { 2 } + \| Q _ { j } - K _ { i } \| ^ { 2 } - 2 ( Q _ { i } - K _ { j } ) ^ { \top } ( Q _ { j } - K _ { i } ) \right) } \\ & { \qquad \gtrapprox \| W _ { R } \| ^ { 2 } \left( \| Q _ { i } - K _ { j } \| ^ { 2 } + \| Q _ { j } - K _ { i } \| ^ { 2 } \right) . } \end{array}
311
+ $$
312
+
313
+ Note that a special case of this assumption is when $W _ { Q } = W _ { K }$ , i.e. queries and keys are shared, in which case $\delta = 0$ .
314
+
315
+ # B JENSEN-SHANNON DIVERGENCE OF ATTENTION DISTRIBUTIONS
316
+
317
+ In Table 4 we presented the Jensen-Shannon divergence between random local heads and random routing attention heads averaged across the 10 layers of the Routing Transformer model on Wikitext $- 1 0 3$ . Table 5 presents the mean and standard deviations of the JSD per layer instead of averaging them.
318
+
319
+ <table><tr><td rowspan=1 colspan=1></td><td rowspan=1 colspan=1>JSD(local || local)</td><td rowspan=1 colspan=1> JSD(locallrouting) | JSD(routingllrouting)</td><td rowspan=1 colspan=1> JSD(locallrouting) | JSD(routingllrouting)</td></tr><tr><td rowspan=1 colspan=1>layer0</td><td rowspan=1 colspan=1>0.0038 ± 0.0018</td><td rowspan=1 colspan=1>0.4706 ± 0.0319</td><td rowspan=10 colspan=1>0.1579 ± 0.05760.5820 ± 0.01040.4015 ± 0.01210.4144 ± 0.02640.4191 ± 0.08790.4687 ± 0.04490.5175 ± 0.04690.4350 ± 0.01390.4268 ± 0.02910.3581 ± 0.0019</td></tr><tr><td rowspan=1 colspan=1>layer 1</td><td rowspan=1 colspan=1>0.3071 ± 0.1217</td><td rowspan=1 colspan=1>0.6674 ± 0.0153</td></tr><tr><td rowspan=1 colspan=1>layer2</td><td rowspan=1 colspan=1>0.2164 ± 0.0803</td><td rowspan=1 colspan=1>0.5896 ± 0.0249</td></tr><tr><td rowspan=1 colspan=1>layer3</td><td rowspan=1 colspan=1>0.1163 ± 0.0336</td><td rowspan=2 colspan=1>0.6047 ± 0.01810.6266 ± 0.0062</td></tr><tr><td rowspan=1 colspan=1>layer4</td><td rowspan=1 colspan=1>0.1840 ± 0.0562</td></tr><tr><td rowspan=1 colspan=1>layer5</td><td rowspan=1 colspan=1>0.2284 ± 0.0225</td><td rowspan=2 colspan=1>0.6463 ± 0.01550.6471 ± 0.0040</td></tr><tr><td rowspan=1 colspan=1>layer6</td><td rowspan=1 colspan=1>0.1901 ± 0.0525</td></tr><tr><td rowspan=1 colspan=1>layer7</td><td rowspan=1 colspan=1>0.1566 ± 0.0685</td><td rowspan=1 colspan=1>0.5798 ± 0.0235</td></tr><tr><td rowspan=1 colspan=1>layer8</td><td rowspan=1 colspan=1>0.1638 ± 0.0739</td><td rowspan=1 colspan=1>0.5993 ± 0.0148</td></tr><tr><td rowspan=1 colspan=1>layer9</td><td rowspan=1 colspan=1>0.2095 ± 0.0560</td><td rowspan=1 colspan=1>0.6127 ± 0.0053</td></tr></table>
320
+
321
+ Table 5: Jensen-Shannon divergence between the attention distributions of a random local attention head and a random head that routes attention as in Section 3 per layer on the Wikitext-103 dataset. We report means and standard deviations computed over 10 runs and use the natural logarithm so that divergences are upper-bounded by 0.6931.
322
+
323
+ # C SAMPLES
324
+
325
+ We generate samples from the Routing Transformer model for the task of character level language modeling on the enwik-8 data-set. We compare the generation to that from a Local Transformer model with the same number of self-attention layers and attention heads. For both the models we generate unconditional samples using random sampling with a temperature of 1.0. The generation from the Routing Transformer is in Table 6 while the generation from Local Transformer is in Table 7, with spelling mistakes highlighted in red. Comparing the two samples we see that the Local Transformer makes significantly more spelling mistakes, especially for long words and phrases.
326
+
327
+ <table><tr><td>Modern Least Rule to bon air and dogmatic television articles several systems: expanding the world usually.The story differs,that would its part flex poetry will support the very little able to put the name by oppose the stories and motorcycle transecurity and biggest life, see the guardian article and looks extraction of large story in storage by meanching up biggest among other items. During that time,Nevis had biggest the Very left record of the party&#x27;s tissues. The London meaning;biggest guardians of the West; in the 198Os and 198Os.The composer Albert Director boards the capture to the beginning. The Son Revised publicity and Revisionism board was way of to enough a descendant the President solely changed from [[Eddie Tellingl], but in fact that assembly was to become common. The President has poor party detonation the decisions; Telling guards [[Pope University of New York]], especially [[Canes CombustionlCanes],and thus [[bankruptcylbankruptcy]] student [Advisor]] include the latter that the swash of its populatiis churches, not in steel [Libertarianism peaceful anti-instancelsave the matter&#x27;s pieces]],and has been languaged efforts taken in 58,OoO sections of anthropic perimeter. The great precision exists in 2OO4,with an assistant to feature vault on other great Peaceful themes in America, the nose of highly [[artificial rate]]es,the discussions of cause, simply soon because they order to setting out the institution political party activity.As of 2004, anthropology saves them as chiefs derivation from the princess of the Executability can be run all</td></tr><tr><td>down by deriving the executability to understand the scientific additional British family traitirity. These intermediate are unproperly equipped, more unprofitability the officiely competite mass best science fiction between the notion of a brought Executive school. This project proves the materiel of controversy and high-school intervention and thoughts of as specurety. [Danceholding]],one can specure even as the mission to bind its dusting intervention. At its original time, he current in the cost of moral intervention, in an 2OO6 slight, tracement saw for the passagecomic belief between the city and applying its uncurrent binary placement, one applies to specure the [biographylbiographyll of regions, his conserved reference election in the letter the most part of the [Dominicus]]. [Algebraizing theorylAlgebrric]] [[critic]]s,which operate the [[third typelthird]] of uncut in to the [[militity]] of the country,her brother&#x27;s deduction may not be denying cases of militity. In the period,[[Bninity Memoryll</td></tr><tr><td>plus how [Jewish PhilologylPhilosophyl] with a series of voruments of each other can be defined as part of [[p-cyclic memory]],which have been ruleful out for military conventions and have unknown orders,of their proposition (because of the political magnitude circumference of other classness and [forgeryll). This highly proposing not with a member of [John Hope (fiction)lJohn Hope]]: Their chief acceptance,or that rapidly proposes C-them by bluetooth sentiments another time.The sentence of the [[North American Executive DepartmentlDED]] was did not believe the pocket currently by critic,and the reaction by 2OO4 roughly 400 people and King John Hope was used by the capabalance of other executive organizers in the circumstance of the chief post-John chief of the 3000 pects. Independences improved [North American_powers_turning_ in_the_educationlnorth of the Education]] For throughout the end of [[199O]].After prizes of those of the John Hope,Generic Atempts - from London rivers Genero helped to prevent any anti-country packaging in London.Long term helped by all the Jury before the Council of Zoroastries develop for packet (since [[199Oll) which conspires, anypreventing them,which offered the Native American forces to meet them up them to be referred to unto [[first Friendlsouthwest the first VO]]. The symbol was based on the canon of [[St. Franciscol] that bring through this force,some position of north the Graduate Agency (which constituted a third) or the other medium in the Friend.Military as</td></tr></table>
328
+
329
+ 0 ]]oter sonries as refrien ritu] serm host teen serm hostul ritu’; baron, in one ritu’;. Refriendamonium rite host teen confriendamonium in the ritu’s role of ritual resolution. The ritual monitor was baron mentalists for hostilities on the rational series; this river was dubion until the confriendamonitor, emerged with this concept into intermedies in one witnessing. They introduced the series of not confriendamonium (very relief). They continued to increase the time / India’s power down. The ritual production to batted conway choosing by the products of the whole choosing as happens as [[alignment]], and an aircraft happened to the kind. As it returned to the operation of the whole producting the large small scale axis. They were reproduced as logts (intwiting they also affected this drip to the easily life) and our shall materials and provided a relative shallow to the motorum. Batted chirality as to the operations of the ANCUP system material to comment adults was bad, as an invasive shallow to be pressure that the program, the subject of ANCUP has been celebrated, since the easily long easily more commonly functions should easily be proved to prevent and group divisions. Batted chirality from the relative community that the controversies came under the writing community led to the legal revolt From the time and from a program that they had become explicitly especially in the following year. In [[1984]], and depictions of the government by a subject were used, proved by manticians, confering from their structure at [[Mid From Los Angeles|Los Angeles]], disputes control and implementing the programming of Hannibal at least proposionals of the [[dependency of Philharmos and Winds would make control of the protest actress from much of their sources, making any process thates of [[contention]] of channing the column to inland any time where at neardy Rube. Philharmos gives protest to any great b(axis). Namely one of his reigns characterization of unofficial competitive structural did attempt to win some results, myrmonisms, which have been successfully greatly monthly. But Anamos meant that his reasons to his harmonists analog was cold and officials success, quickly denominate a Japanese continued to bring the army various times some full terms of the suffix of an obficial réligious religions were surcessful older in Coloniaas and was set. One London, last names, comprising him to succedulate to him deeper. Over the remarkable Submission was, Submission might be a mussel upon his loyal rebuilding dynasty, a program and young by Coloniaas (erasmol), the troops law, with their humans. Less, Miss missions and Cathar with their significance, the troops led by the massive society of the Holy Roman Holy Mission document in the Coloniaan Committee, hence is headby which the course of Summoniacs, ”Black Writers”, recognizing him the body, Suspense), within the next member of the troops. ;ref name=Cathar Lesson de Les Rise is derived from the 1990s. Suspense that she missed the course of the erasmolents, part of the character in the member of the 1990s Character acted in some of his coar, the 4 bill belonging to the eight members of the member of the 1990s. It was threatened in 1997, and let directly affluencing in saltiming exponents within the study emerge in the 1990s and [[canon]]s working in 1992, and roadly fought in other sections to saltimine races. But failed to thought in the significant shot [[Leibniz]]. (Fulham banned 1990 to 1999, when primitively [[eldest]]), his deadly 299 primitive style of ”Aghai 2001”. Symmonists were silicated by the [[Joey Forces]] and Net. Making the eldest years, he published a finite similar racing, revealed by him a straight just greatly killed beyond a latest-sale public bridge that two great first soundtracking, which ”’Bolumeck Coal”’. ”[[Mononymile]] beginning, Dom., the head of the same racing of him of the eldest day1. Japanese amount in the storm of the sense of Caw celebrated on Monthly appearing instead of cross-music. When overslanding”’ (which during his visual) is raised in both the placement and which different from the storm, recent elements, Bolumeck Winters Sense Miller which runs up raising ameth.;Caj is analogy.
parse/train/B1gjs6EtDr/B1gjs6EtDr_content_list.json ADDED
@@ -0,0 +1,1731 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [
2
+ {
3
+ "type": "text",
4
+ "text": "EFFICIENT CONTENT-BASED SPARSE ATTENTION WITH ROUTING TRANSFORMERS ",
5
+ "text_level": 1,
6
+ "bbox": [
7
+ 176,
8
+ 98,
9
+ 821,
10
+ 146
11
+ ],
12
+ "page_idx": 0
13
+ },
14
+ {
15
+ "type": "text",
16
+ "text": "Anonymous authors Paper under double-blind review ",
17
+ "bbox": [
18
+ 183,
19
+ 170,
20
+ 398,
21
+ 198
22
+ ],
23
+ "page_idx": 0
24
+ },
25
+ {
26
+ "type": "text",
27
+ "text": "ABSTRACT ",
28
+ "text_level": 1,
29
+ "bbox": [
30
+ 454,
31
+ 234,
32
+ 544,
33
+ 251
34
+ ],
35
+ "page_idx": 0
36
+ },
37
+ {
38
+ "type": "text",
39
+ "text": "Self-attention has recently been adopted for a wide range of sequence modeling problems. Despite its effectiveness, self-attention suffers quadratic compute and memory requirements with respect to sequence length. Successful approaches to reduce this complexity focused on attention to local sliding windows or a small set of locations independent of content. Our work proposes to learn dynamic sparse attention patterns that avoid allocating computation and memory to attend to content unrelated to the query of interest. This work builds upon two lines of research: it combines the modeling flexibility of prior work on content-based sparse attention with the efficiency gains from approaches based on local, temporal sparse attention. Our model, the Routing Transformer, endows self-attention with a sparse routing module based on online $k$ -means while reducing the overall complexity of attention to $O ( n ^ { 1 . 5 } d )$ from $O ( n ^ { 2 } d )$ for sequence length $n$ and hidden dimension $d$ . We show that our model outperforms comparable sparse attention models on language modeling on Wikitext $- 1 0 3$ (15.8 vs 18.3 perplexity) as well as on image generation on ImageNet-64 (3.43 vs 3.44 bits/dim) while using fewer self-attention layers. ",
40
+ "bbox": [
41
+ 233,
42
+ 268,
43
+ 764,
44
+ 489
45
+ ],
46
+ "page_idx": 0
47
+ },
48
+ {
49
+ "type": "text",
50
+ "text": "1 INTRODUCTION ",
51
+ "text_level": 1,
52
+ "bbox": [
53
+ 176,
54
+ 520,
55
+ 336,
56
+ 536
57
+ ],
58
+ "page_idx": 0
59
+ },
60
+ {
61
+ "type": "text",
62
+ "text": "Generative models of sequences have witnessed rapid progress driven by the application of attention to neural networks. In particular, Bahdanau et al. (2014); Cho et al. (2014); Vaswani et al. (2017) relied on attention to drastically improve the state-of-the art in machine translation. Subsequent research (Radford et al., 2018; Devlin et al., 2018; Liu et al., 2019; Yang et al., 2019) demonstrated the power of self-attention in learning powerful representations of language to address several natural language processing tasks. Self-attention also brought impressive progress for generative modeling outside of language, e.g. image (Parmar et al., 2018; Menick and Kalchbrenner, 2018; Child et al., 2019) and music generation (Huang et al., 2018; Child et al., 2019). ",
63
+ "bbox": [
64
+ 174,
65
+ 553,
66
+ 825,
67
+ 665
68
+ ],
69
+ "page_idx": 0
70
+ },
71
+ {
72
+ "type": "text",
73
+ "text": "Self-attention operates over sequences in a step-wise manner: at every time-step, attention assigns an attention weight to each previous input element (representation of past time-steps) and uses these weights to compute the representation of the current time-step as a weighted sum of the past input elements (Vaswani et al., 2017). Self-attention (Shaw et al., 2018) is a particular case of attention (Bahdanau et al., 2014; Chorowski et al., 2015; Luong et al., 2015). ",
74
+ "bbox": [
75
+ 174,
76
+ 671,
77
+ 825,
78
+ 741
79
+ ],
80
+ "page_idx": 0
81
+ },
82
+ {
83
+ "type": "text",
84
+ "text": "Self-attention is commonly used in auto-regressive generative models. These models generate observations step-by-step, modeling the probability of the next symbol given the previously generated ones. At every time step, self-attentive generative models can directly focus on any part of the previous context. In contrast, recurrent neural networks (RNNs) and convolutional neural networks (CNNs) have direct interactions with only a local neighborhood of context around the current time step. ",
85
+ "bbox": [
86
+ 173,
87
+ 748,
88
+ 825,
89
+ 832
90
+ ],
91
+ "page_idx": 0
92
+ },
93
+ {
94
+ "type": "text",
95
+ "text": "This advantage however comes at a price: unlike recurrent networks or convolution networks, the time and space complexity of self-attention is quadratic in $n$ , the length of the sequence. Specifically, for every position $i \\leq n$ , self-attention computes weights for its whole context of length $i$ , which induces a complexity of $\\textstyle \\sum _ { i \\leq n } i = n ( n - 1 ) / 2$ . This makes it difficult to scale attention based models to modeling long sequences. However, long sequences are the norm in many domains, including music, image, speech or video generation. ",
96
+ "bbox": [
97
+ 174,
98
+ 838,
99
+ 825,
100
+ 924
101
+ ],
102
+ "page_idx": 0
103
+ },
104
+ {
105
+ "type": "text",
106
+ "text": "Therefore, an important research direction is to investigate sparse and memory efficient forms of attention in order to scale to tasks with long sequence lengths. Previous work has proposed data independent or fixed sparsity patterns bounding temporal dependencies, such as local or strided attention. At each time step, the model attends only to a fix number of time steps in the past (Child et al., 2019). Extensions to local attention have suggested learning the length of the temporal sparsity for each attention module in the network (Sukhbaatar et al., 2019). These strategies draw their inspiration from RNNs and CNNs and bound their complexity by attending only to representations summarizing a local neighborhood of the current time step. Their attention matrices (matrices containing the attention weights for every pair of previous, current time-step) are natively sparse and requires instantiating only non-zero entries. While these approaches have achieved good results, fixing the sparsity pattern of a content based mechanism such as self-attention can limit its ability to pool in information from large contexts. ",
107
+ "bbox": [
108
+ 174,
109
+ 103,
110
+ 825,
111
+ 270
112
+ ],
113
+ "page_idx": 1
114
+ },
115
+ {
116
+ "type": "text",
117
+ "text": "As an alternative to local attention, Correia et al. (2019) considers content-based sparsity, an approach allowing for arbitrary sparsity patterns. This formulation however does require instantiating a full dense attention matrix prior to sparsification through variants of $L _ { 0 }$ -sparsity or sparsemax approximations (Blondel et al., 2019). ",
118
+ "bbox": [
119
+ 176,
120
+ 277,
121
+ 823,
122
+ 333
123
+ ],
124
+ "page_idx": 1
125
+ },
126
+ {
127
+ "type": "text",
128
+ "text": "The present work builds upon these two lines of research and proposes to retain the modeling flexibility of content-based sparse attention while leveraging the efficiency of natively sparse attention matrices. Our formulation avoids sparsemax variants and relies on clustering of attention instead. Each attention module considers a clustering of the space: the current time-step only attends to context belonging to the same cluster. In other word, the current time-step query is routed to a limited number of context through its cluster assignment. This strategy draws inspiration from the application of $k$ -means clustering to Non-negative Matrix Factorization (NMF) (Lee and Seung, 2001; Ding et al., 2005; Kim and Park, 2008), which is relevant to the sparsification of non-negative matrices like attention matrices. ",
129
+ "bbox": [
130
+ 174,
131
+ 339,
132
+ 825,
133
+ 465
134
+ ],
135
+ "page_idx": 1
136
+ },
137
+ {
138
+ "type": "text",
139
+ "text": "Our proposed model, Routing Transformer, combines our efficient clustered-based sparse attention with classical local attention to reach excellent performance both for language and image generation. These results are obtained without the need to maintain attention matrices larger than batch length which is the case with the segment level recurrence mechanism used in Dai et al. (2019); Sukhbaatar et al. (2019). We present experimental results on language modeling (Wikitext $- 1 0 3$ and enwik-8) and unconditional image generation (ImageNet-64). Routing Transformer sets new state-of-the-art while having comparable or fewer number of self-attention layers and heads, both on Wikitext-103 (15.8 vs 18.3 perplexity) and on ImageNet-64 (3.43 vs 3.44 bits/dim). We also report competitive results on enwik-8 (0.99 vs 0.98 perplexity). ",
140
+ "bbox": [
141
+ 174,
142
+ 472,
143
+ 825,
144
+ 597
145
+ ],
146
+ "page_idx": 1
147
+ },
148
+ {
149
+ "type": "text",
150
+ "text": "2 RELATED WORK ",
151
+ "text_level": 1,
152
+ "bbox": [
153
+ 176,
154
+ 623,
155
+ 343,
156
+ 640
157
+ ],
158
+ "page_idx": 1
159
+ },
160
+ {
161
+ "type": "text",
162
+ "text": "Attention with Temporal Sparsity: Research on efficient attention neural models parallels the advent of attention-based architectures. In the context of speech recognition, Jaitly et al. (2015) proposed the Neural Transducer which segments sequences in non-overlapping chunks and attention is performed in each chunk independently. Limiting attention to a fixed temporal context around the current prediction has also been explored in Chorowski et al. (2015), while Chiu and Raffel (2017) dynamically segment the sequence into variable sized-chunks. ",
163
+ "bbox": [
164
+ 174,
165
+ 659,
166
+ 825,
167
+ 742
168
+ ],
169
+ "page_idx": 1
170
+ },
171
+ {
172
+ "type": "text",
173
+ "text": "Hierarchical attention strategies have also been explored: the model first considers which part of the inputs should be attended to before computing full attention in a contiguous neighborhood of the selected area (Gregor et al., 2015; Xu et al., 2015; Luong et al., 2015). Later, hierarchical attention has been simplified by Liu et al. (2018) that alternates coarse layers (attending to the whole sequence at a lower temporal resolution) with local layers (attending to a neighborhood of the current prediction). ",
174
+ "bbox": [
175
+ 174,
176
+ 750,
177
+ 825,
178
+ 819
179
+ ],
180
+ "page_idx": 1
181
+ },
182
+ {
183
+ "type": "text",
184
+ "text": "This alternating strategy is also employed by Child et al. (2019), which introduces bounded and strided attention, i.e. attending to a fixed context in the past at a subsampled temporal resolution. This work formalizes such a strategy using a sparse attention formalism, showing how it relates to full attention with a specific sparsity pattern in the attention matrix. It shows that sparse attention is sufficient to get state-of-the-art results in modeling long sequences over language modeling, image generation and music generation. Sukhbaatar et al. (2019) builds upon this work and shows that is it is possible to obtain further sparsity by letting the model learn the length of the temporal context for each attention module. This work also makes use of the attention cache introduced in Dai et al. (2019), a memory mechanism to train models over temporal contexts which extend beyond the length of the training batches. ",
185
+ "bbox": [
186
+ 174,
187
+ 825,
188
+ 825,
189
+ 924
190
+ ],
191
+ "page_idx": 1
192
+ },
193
+ {
194
+ "type": "text",
195
+ "text": "",
196
+ "bbox": [
197
+ 174,
198
+ 103,
199
+ 825,
200
+ 146
201
+ ],
202
+ "page_idx": 2
203
+ },
204
+ {
205
+ "type": "text",
206
+ "text": "Attention with Content-Based Sparsity: The above work mainly relies on two efficient ideas: attending to less elements by only considering a fixed bounded local context in the past, and attending to less elements by decreasing the temporal resolution of context. These ideas do not allow arbitrary sparsity patterns in attention matrices. Content-based sparse attention has been introduced to allow for richer patterns and more expressive models. Martins and Kreutzer (2017); Malaviya et al. (2018) propose to compute attention weights with variants of sparsemax. Correia et al. (2019) generalizes this approach to every layer in a Transformer using entmax which allows for more efficient inference. This line of work allows for learning arbitrary sparsity attention patterns from data, based on the content of the current query and past context. However, sparsity here cannot be leveraged to improve space and time complexity since sparsemax/entmax formulations require instantiating the full attention matrix prior to sparsification. This is a drawback compared to temporal sparsity approaches. Our work is motivated by bridging this gap and allows for arbitrary sparsity patterns while avoiding to instantiate non-zero entries of attention matrices. ",
207
+ "bbox": [
208
+ 174,
209
+ 152,
210
+ 825,
211
+ 333
212
+ ],
213
+ "page_idx": 2
214
+ },
215
+ {
216
+ "type": "text",
217
+ "text": "Sparse Computation beyond Attention: Learning models with sparse representations/activations for saving time and computation has addressed in the past in various context. Previous work often refers to this goal as gating for conditional computation. Gating techniques relying on sampling and straight-through gradient estimators are common (Bengio et al., 2013; Eigen et al., 2013; Cho and Bengio, 2014). Conditional computation can also be addressed with reinforcement learning (Denoyer and Gallinari, 2014; Indurthi et al., 2019). In the domain of language modeling, a related work is the sparsely gated Mixture-of-experts (MOE) (Shazeer et al., 2017) where sparsity is induced by experts and a trainable gating network controls the routing strategy to each sub-network. ",
218
+ "bbox": [
219
+ 173,
220
+ 339,
221
+ 825,
222
+ 452
223
+ ],
224
+ "page_idx": 2
225
+ },
226
+ {
227
+ "type": "text",
228
+ "text": "3 SELF-ATTENTIVE AUTO-REGRESSIVE SEQUENCE MODELING ",
229
+ "text_level": 1,
230
+ "bbox": [
231
+ 176,
232
+ 470,
233
+ 714,
234
+ 487
235
+ ],
236
+ "page_idx": 2
237
+ },
238
+ {
239
+ "type": "text",
240
+ "text": "Auto-regressive sequence models decompose the probability of a sequence $\\mathbf { x } = ( x _ { 1 } , \\ldots , x _ { n } )$ as ",
241
+ "bbox": [
242
+ 173,
243
+ 501,
244
+ 799,
245
+ 516
246
+ ],
247
+ "page_idx": 2
248
+ },
249
+ {
250
+ "type": "equation",
251
+ "img_path": "images/2e6062450dec622cddd50e9e58ebad970f25cc332aa213c50aab78a0bb0d8c70.jpg",
252
+ "text": "$$\np ( \\mathbf { x } ) = \\prod _ { i = 1 } ^ { n } p _ { \\theta } ( x _ { i + 1 } | \\boldsymbol { x } _ { \\le i } ) .\n$$",
253
+ "text_format": "latex",
254
+ "bbox": [
255
+ 411,
256
+ 517,
257
+ 584,
258
+ 558
259
+ ],
260
+ "page_idx": 2
261
+ },
262
+ {
263
+ "type": "text",
264
+ "text": "In neural models, the conditional distribution $p _ { \\theta } ( x _ { i + 1 } | x _ { \\leq i } )$ is modeled by a neural network with learned parameters $\\theta$ and these parameters are typically learned to maximize the likelihood of the training data. In particular, Transformer architectures have shown to reach state-of-the-art accuracy in several domains, including language modeling (Vaswani et al., 2017; Radford et al., 2018), image generation (Parmar et al., 2018) and music generation (Huang et al., 2018). Transformer models compose a series of attention modules. Each module refines the input representation by taking a weighted average of the representations from the previous modules. ",
265
+ "bbox": [
266
+ 173,
267
+ 559,
268
+ 825,
269
+ 656
270
+ ],
271
+ "page_idx": 2
272
+ },
273
+ {
274
+ "type": "text",
275
+ "text": "For every module, the input representation is a sequence of $n$ vectors $\\mathbf { x } = ( x _ { 1 } , \\ldots , x _ { n } )$ from a continuous space of dimension $d$ . Thus one may actually treat the input sequence as a $n \\times d$ matrix $X$ . A self-attention layer operates on this representation. It first applies three linear projections, ",
276
+ "bbox": [
277
+ 174,
278
+ 662,
279
+ 825,
280
+ 705
281
+ ],
282
+ "page_idx": 2
283
+ },
284
+ {
285
+ "type": "equation",
286
+ "img_path": "images/e4140fdb320297cd552caba68db325d5840ae77382429b185acbaa3944f98c34.jpg",
287
+ "text": "$$\nQ = X W _ { Q } , \\quad K = X W _ { K } , \\quad V = X W _ { V } ,\n$$",
288
+ "text_format": "latex",
289
+ "bbox": [
290
+ 354,
291
+ 707,
292
+ 640,
293
+ 723
294
+ ],
295
+ "page_idx": 2
296
+ },
297
+ {
298
+ "type": "text",
299
+ "text": "where $Q , K$ and $V$ are referred to as keys, queries and values, while $W _ { Q } , W _ { K } , W _ { V }$ are learned projection matrices. ",
300
+ "bbox": [
301
+ 171,
302
+ 724,
303
+ 825,
304
+ 752
305
+ ],
306
+ "page_idx": 2
307
+ },
308
+ {
309
+ "type": "text",
310
+ "text": "The key and the query matrices determine the $n \\times n$ attention matrix $A = \\operatorname { s o f t m a x } \\left( Q K ^ { \\top } \\right)$ , where the softmax operator over matrices denotes that the softmax function has been applied to each row. $A$ may be interpreted as a matrix of weights in $[ 0 , 1 ]$ where $A _ { i j }$ denotes how much query position $i$ at the next layer must pay attention to key position $j$ at the previous layer. In the case of self-attention for auto-regressive models, queries attend only over keys from previous time-steps, i.e. ",
311
+ "bbox": [
312
+ 174,
313
+ 758,
314
+ 825,
315
+ 830
316
+ ],
317
+ "page_idx": 2
318
+ },
319
+ {
320
+ "type": "equation",
321
+ "img_path": "images/47e6090c19beea63f6053a266e6cf7c15a915da2f877556c1fb94d1a9a933cc5.jpg",
322
+ "text": "$$\nA = \\operatorname { s o f t m a x } \\left( \\operatorname { l t r } ( Q K ^ { \\top } ) \\right)\n$$",
323
+ "text_format": "latex",
324
+ "bbox": [
325
+ 408,
326
+ 830,
327
+ 589,
328
+ 849
329
+ ],
330
+ "page_idx": 2
331
+ },
332
+ {
333
+ "type": "text",
334
+ "text": "where ltr denotes the lower triangular operator. Given the attention matrix $A$ , the next layer representation $X ^ { \\prime }$ is computed simply as $A V$ . In summary, ",
335
+ "bbox": [
336
+ 171,
337
+ 851,
338
+ 825,
339
+ 878
340
+ ],
341
+ "page_idx": 2
342
+ },
343
+ {
344
+ "type": "equation",
345
+ "img_path": "images/87b9db1cbd74ee770ae31c858277576ff0a11289638b26792a1fc5f910a5c690.jpg",
346
+ "text": "$$\nX _ { i } ^ { \\prime } = \\sum _ { j \\leq i } ^ { n } A _ { i j } V _ { j } ,\n$$",
347
+ "text_format": "latex",
348
+ "bbox": [
349
+ 441,
350
+ 878,
351
+ 555,
352
+ 921
353
+ ],
354
+ "page_idx": 2
355
+ },
356
+ {
357
+ "type": "text",
358
+ "text": "In practice, Transformer (Vaswani et al., 2017) adds several extensions to this basic self-attention mechanism. In particular, the result $X ^ { \\prime }$ of performing self-attention is scaled by $1 / { \\sqrt { d } }$ . Moreover, each layer relies on multiple attention heads, i.e. each layer performs multiple projections onto triplet (queries, keys, values) and attention is performed for each head. The attention results from all heads are then concatenated. This strategy allows each head to specialize on different aspects of the input sequence. In addition, Transformer further processes the result of attention through a learnable non-linear transformation (multi-layer perceptron, mlp) followed by a residual connection and a normalization step, i.e. ",
359
+ "bbox": [
360
+ 173,
361
+ 103,
362
+ 825,
363
+ 217
364
+ ],
365
+ "page_idx": 3
366
+ },
367
+ {
368
+ "type": "equation",
369
+ "img_path": "images/8a2f10b1ac334b29197663e9e06ba536962b2b9580764c64ababecb9aeeafc7b.jpg",
370
+ "text": "$$\n\\begin{array} { l c r } { { X ^ { \\prime } = \\mathrm { l a y e r n o r m } ( X ^ { \\prime } + X ) } } \\\\ { { X ^ { \\prime \\prime } = \\mathrm { l a y e r n o r m } ( \\mathrm { m l p } ( X ^ { \\prime } ) + X ) , } } \\end{array}\n$$",
371
+ "text_format": "latex",
372
+ "bbox": [
373
+ 383,
374
+ 223,
375
+ 614,
376
+ 262
377
+ ],
378
+ "page_idx": 3
379
+ },
380
+ {
381
+ "type": "text",
382
+ "text": "where layernorm denotes the parameterized normalization step from Ba et al. (2016). A full Transformer model is therefore a chain of attention modules (Eq. 6) preceded by an embedding module (learnable representation for symbols and their positions) and followed by a logistic classification module (learnable linear classifier to predict the next symbol). ",
383
+ "bbox": [
384
+ 174,
385
+ 267,
386
+ 825,
387
+ 324
388
+ ],
389
+ "page_idx": 3
390
+ },
391
+ {
392
+ "type": "text",
393
+ "text": "Our work is interested in the application of the Transformer to long sequences, a challenging problem since space and time complexity of attention is quadratic in sequence length $n$ . We describe various approaches to sparse attention including ours in the next section. ",
394
+ "bbox": [
395
+ 174,
396
+ 330,
397
+ 825,
398
+ 373
399
+ ],
400
+ "page_idx": 3
401
+ },
402
+ {
403
+ "type": "text",
404
+ "text": "4 EFFICIENT CONTENT-DEPENDENT SPARSE ATTENTION ",
405
+ "text_level": 1,
406
+ "bbox": [
407
+ 176,
408
+ 392,
409
+ 661,
410
+ 410
411
+ ],
412
+ "page_idx": 3
413
+ },
414
+ {
415
+ "type": "text",
416
+ "text": "Attention-based models can be problematic for long sequences. For a sequence of length $n$ , the full attention matrix $A$ , as introduced in Section 3, is $n \\times n$ -dimensional and can be prohibitive to instantiate. This motivates sparse attention models, i.e. models relying on attention matrices which have a majority of zero entries. ",
417
+ "bbox": [
418
+ 174,
419
+ 425,
420
+ 825,
421
+ 481
422
+ ],
423
+ "page_idx": 3
424
+ },
425
+ {
426
+ "type": "text",
427
+ "text": "For each query, a sparse attention model defines a set of keys which can be attended to. In the following, we introduce the set $S _ { i }$ as the set of key positions that the query at position $i$ can attend to, i.e. ",
428
+ "bbox": [
429
+ 174,
430
+ 488,
431
+ 825,
432
+ 530
433
+ ],
434
+ "page_idx": 3
435
+ },
436
+ {
437
+ "type": "equation",
438
+ "img_path": "images/c4b32d2795a3bb4bb00c734317ff6b0ef63bca0dc948fbdcd80d3d99b03dec63.jpg",
439
+ "text": "$$\nX _ { i } ^ { \\prime } = \\sum _ { j \\in S _ { i } } A _ { i j } V _ { j } .\n$$",
440
+ "text_format": "latex",
441
+ "bbox": [
442
+ 437,
443
+ 534,
444
+ 560,
445
+ 570
446
+ ],
447
+ "page_idx": 3
448
+ },
449
+ {
450
+ "type": "text",
451
+ "text": "For example, classical causal self attention can attend to every key prior to the current query, which translates to $S _ { i } = \\{ j \\mid j < i \\}$ . Most previous work on attention sparsity defined such sets purely based on positions, independently of actual query and key vectors. For example, local attention (Luong et al., 2015) considers attending only to a $k$ -long time window prior to the current query, $S _ { i } = \\bar { \\{ j | i - k \\leq j < i \\} } ,$ . Child et al. (2019) propose block sparse attention where half the heads perform local attention, and half the heads perform strided attention given by $S _ { i } = \\{ j \\ | \\ i - j$ $( \\mathrm { m o d } \\ k ) = 0 , j < i \\}$ . Sukhbaatar et al. (2019) is also a variant of local attention where the cardinality of $| S _ { i } |$ is learned from data with an $L _ { 1 }$ penalty to trade-off sparsity with modeling accuracy. ",
452
+ "bbox": [
453
+ 173,
454
+ 575,
455
+ 825,
456
+ 688
457
+ ],
458
+ "page_idx": 3
459
+ },
460
+ {
461
+ "type": "text",
462
+ "text": "These local attention sparsity variants are effective in practice since correlation between observations naturally decrease with time for many problems. In our experiments, we actually find that local attention is a surprisingly strong baseline in both image generation and language modeling: for e.g., a scaled up ImageTransformer (Parmar et al., 2018) gets 3.48 bits/dim compared to the 3.44 bits/dim reported in (Child et al., 2019). Similarly, scaled up versions of Transformer with local attention and the relative positional encoding scheme of Shaw et al. (2018) are able to get 19.8 perplexity on Wikitext $- 1 0 3$ and 1.10 bits per byte on enwik-8, while the state-of-the-art results using Transformer-XL (Dai et al., 2019) are 18.3 and 0.99 respectively. From an efficiency perspective, local attention is also interesting since sparsity patterns are regular, contiguous in memory and known in advance. ",
463
+ "bbox": [
464
+ 174,
465
+ 693,
466
+ 825,
467
+ 833
468
+ ],
469
+ "page_idx": 3
470
+ },
471
+ {
472
+ "type": "text",
473
+ "text": "In this work, however, we are interested in a more generic formulation of attention sparsity and would like the sparsity pattern to be informed by the data, i.e., $\\begin{array} { r } { \\boldsymbol { S } = f ( \\mathbf { x } ) } \\end{array}$ . This approach has several modeling advantages: it can accommodate data without a clear ordering over observations. For temporal data, it can also discover patterns with greater sparsity if some types of queries have a longer lasting effect on future observations than others. Content-based sparse attention should however be carefully implemented if we need to avoid instantiating full attention matrices at any point in time. ",
474
+ "bbox": [
475
+ 174,
476
+ 839,
477
+ 825,
478
+ 924
479
+ ],
480
+ "page_idx": 3
481
+ },
482
+ {
483
+ "type": "text",
484
+ "text": "For instance, Correia et al. (2019) infer sparsity from data but their formulation instantiates a full attention matrix before finding its sparse counterpart. Next section explains how a natively sparse approach can actually be devised inspired by non-negative matrix factorization (NMF). ",
485
+ "bbox": [
486
+ 174,
487
+ 103,
488
+ 826,
489
+ 146
490
+ ],
491
+ "page_idx": 4
492
+ },
493
+ {
494
+ "type": "text",
495
+ "text": "4.1 CLUSTER ATTENTION WITH NON-NEGATIVE LOW RANK APPROXIMATIONS ",
496
+ "text_level": 1,
497
+ "bbox": [
498
+ 174,
499
+ 161,
500
+ 736,
501
+ 178
502
+ ],
503
+ "page_idx": 4
504
+ },
505
+ {
506
+ "type": "text",
507
+ "text": "For any given $n \\times n$ matrix $A$ , a low-rank non-negative approximation to it is of the form $H = F G ^ { \\top }$ where $\\bar { F , G } \\in \\mathbb { R } ^ { n \\times k }$ and $F , G \\geq 0$ . This factorization can be interpreted as follows: $n$ total items are routed to $k$ representatives determined by the attention matrix $F$ , while each of the representative $k$ items perform full attention on the $n$ items determined by matrix $G$ . Therefore, the whole attention matrix passes through a bottleneck of size $k$ . ",
508
+ "bbox": [
509
+ 173,
510
+ 188,
511
+ 825,
512
+ 258
513
+ ],
514
+ "page_idx": 4
515
+ },
516
+ {
517
+ "type": "text",
518
+ "text": "NMF studies algorithms to find such approximations (Tandon and Sra, 2010), for instance minimizing the Frobenius norm, ",
519
+ "bbox": [
520
+ 173,
521
+ 265,
522
+ 823,
523
+ 294
524
+ ],
525
+ "page_idx": 4
526
+ },
527
+ {
528
+ "type": "equation",
529
+ "img_path": "images/50087fa5230f00ecea2d5efac1f868e5560d748ec850856526dceea78f02148d.jpg",
530
+ "text": "$$\nH = \\arg \\operatorname* { m i n } _ { G ^ { \\top } G = I , F , G \\geq 0 } \\left\\| A - F G ^ { \\top } \\right\\| ^ { 2 } .\n$$",
531
+ "text_format": "latex",
532
+ "bbox": [
533
+ 369,
534
+ 297,
535
+ 629,
536
+ 328
537
+ ],
538
+ "page_idx": 4
539
+ },
540
+ {
541
+ "type": "text",
542
+ "text": "Different algorithms have been proposed for that problem, with different trade-offs in terms of theoretical guarantees, actual accuracy and efficiency (Lee and Seung, 2001; Hoyer, 2004; Gemulla et al., 2011). In particular, $k$ -means clustering (Lloyd, 1982) has been studied as a tractable approximation to non-negative low-rank matrix factorization problem (Ding et al., 2005; Kim and Park, 2008). ",
543
+ "bbox": [
544
+ 174,
545
+ 333,
546
+ 825,
547
+ 390
548
+ ],
549
+ "page_idx": 4
550
+ },
551
+ {
552
+ "type": "text",
553
+ "text": "This relation between $k$ -means and NMF motivates our work but cannot however be applied directly in our case. In particular, we want to avoid instantiating $A$ before approximating it. Furthermore, although we are interested in low rank sparsity patterns, our application context does not require $H$ itself to be low rank. We therefore propose a simpler strategy where $k$ -means is applied to find the routing pattern, while the attention matrix itself remains full rank. Moreover, our approach maintains a single set of cluster centroids shared across examples, which allows for fast training and inference. We describe this strategy in the next section. ",
554
+ "bbox": [
555
+ 173,
556
+ 396,
557
+ 826,
558
+ 494
559
+ ],
560
+ "page_idx": 4
561
+ },
562
+ {
563
+ "type": "text",
564
+ "text": "4.2 ROUTING ATTENTION WITH CLUSTERING ",
565
+ "text_level": 1,
566
+ "bbox": [
567
+ 174,
568
+ 511,
569
+ 504,
570
+ 525
571
+ ],
572
+ "page_idx": 4
573
+ },
574
+ {
575
+ "type": "text",
576
+ "text": "Our strategy follows the motivation we delineated in the previous section: we model sparse attention matrices with a low rank sparsity patterns relying on $k$ -means clustering. Our strategy first assigns queries and keys to clusters. Then only queries and keys from the same cluster are considered for attention. ",
577
+ "bbox": [
578
+ 174,
579
+ 536,
580
+ 825,
581
+ 593
582
+ ],
583
+ "page_idx": 4
584
+ },
585
+ {
586
+ "type": "text",
587
+ "text": "Precisely, our model projects keys $K$ and queries $Q$ into a routing matrix $R \\in \\mathbb { R } ^ { n \\times d }$ as follows ",
588
+ "bbox": [
589
+ 171,
590
+ 599,
591
+ 797,
592
+ 616
593
+ ],
594
+ "page_idx": 4
595
+ },
596
+ {
597
+ "type": "equation",
598
+ "img_path": "images/580a83d1d81c35124867a8b440b9503eb9f523aa7c815e13843290bd002ece1f.jpg",
599
+ "text": "$$\nR = [ Q , K ] \\left[ W _ { R } \\right]\n$$",
600
+ "text_format": "latex",
601
+ "bbox": [
602
+ 434,
603
+ 621,
604
+ 563,
605
+ 655
606
+ ],
607
+ "page_idx": 4
608
+ },
609
+ {
610
+ "type": "text",
611
+ "text": "where $W _ { R }$ is a fixed random orthonormal $d \\times d$ routing projection matrix. The vectors of $R$ undergo $k$ -means clustering in order to factorize the full attention matrix. The clustering parameters are the centroid vectors $( \\mu _ { 1 } , \\cdot \\cdot \\cdot , \\mu _ { k } ) \\in \\mathbb { R } ^ { k \\times d }$ . These parameters are model parameters shared across sequences. There are learned online along with the rest of the parameters, as delineated in Bottou and Bengio (1995). Once cluster membership for each position $i$ in the sequence is determined, we denote with $C _ { i }$ the cluster corresponding to the routing vector $R _ { i }$ . This allows us to define our sparse attention strategy as ",
612
+ "bbox": [
613
+ 173,
614
+ 660,
615
+ 825,
616
+ 758
617
+ ],
618
+ "page_idx": 4
619
+ },
620
+ {
621
+ "type": "equation",
622
+ "img_path": "images/5baba919a5fd1028cb57ad95d5774f08ea00e92896f76346a9e1dda0333c9378.jpg",
623
+ "text": "$$\nX _ { i } ^ { \\prime } = \\sum _ { j \\in C _ { i } , j \\leq i } A _ { i j } V _ { j }\n$$",
624
+ "text_format": "latex",
625
+ "bbox": [
626
+ 428,
627
+ 763,
628
+ 570,
629
+ 800
630
+ ],
631
+ "page_idx": 4
632
+ },
633
+ {
634
+ "type": "text",
635
+ "text": "where $C _ { i }$ denotes the cluster of the vector $R _ { i }$ . In summary, queries are routed to keys belonging to the same cluster. Therefore, our attention sparsity pattern is of rank $k$ , i.e. $F G ^ { \\mathsf { T } }$ where $F$ and $G$ are binary matrices denoting cluster memberships of queries and keys respectively. Note that since we route both queries and keys via the routing matrix $R$ , it follows that $F = G$ . It is important to note that this low rank property only concerns the sparsity pattern, while the resulting attention matrix $\\operatorname { l t r } ( F G ^ { \\top } * A ) = \\operatorname { l t r } ( { \\dot { F } } F ^ { \\top } * { \\dot { A } } )$ can however be of higher rank ( $^ *$ denotes element-wise product). ",
636
+ "bbox": [
637
+ 173,
638
+ 804,
639
+ 825,
640
+ 890
641
+ ],
642
+ "page_idx": 4
643
+ },
644
+ {
645
+ "type": "text",
646
+ "text": "As a last technical point, we work with keys and values which are unitary vectors, projecting them onto the unit ball immediately before computing them. This differentiable normalization (Ba et al., ",
647
+ "bbox": [
648
+ 173,
649
+ 895,
650
+ 823,
651
+ 924
652
+ ],
653
+ "page_idx": 4
654
+ },
655
+ {
656
+ "type": "text",
657
+ "text": "2016) is useful to link cluster memberships with proximity of queries and keys, as outlined below. We also assume that the max norm of $W _ { Q }$ and $W _ { K }$ are close to each other - for more details see Appendix A. This can be enforced by adding an auxiliary loss or by explicitly setting $W _ { Q } = W _ { K }$ . Since $W _ { R }$ is a distance preserving transform, we can write ",
658
+ "bbox": [
659
+ 176,
660
+ 103,
661
+ 825,
662
+ 159
663
+ ],
664
+ "page_idx": 5
665
+ },
666
+ {
667
+ "type": "equation",
668
+ "img_path": "images/df9fbe3049635e1311ce651d764612aa7cc3d1cca7baef46578f1e618acec1a7.jpg",
669
+ "text": "$$\n\\begin{array} { r l } & { \\| R _ { i } - R _ { j } \\| ^ { 2 } = \\| W _ { R } ( Q _ { i } + K _ { i } ) - W _ { R } ( Q _ { j } + K _ { j } ) \\| ^ { 2 } } \\\\ & { \\qquad \\gtrapprox \\| W _ { R } \\| ^ { 2 } \\left( \\| Q _ { i } - K _ { j } \\| ^ { 2 } + \\| Q _ { j } - K _ { i } \\| ^ { 2 } \\right) } \\\\ & { \\qquad = 4 - 2 \\left( Q _ { i } ^ { \\top } K _ { j } + Q _ { j } ^ { \\top } K _ { i } \\right) . } \\end{array}\n$$",
670
+ "text_format": "latex",
671
+ "bbox": [
672
+ 316,
673
+ 164,
674
+ 679,
675
+ 234
676
+ ],
677
+ "page_idx": 5
678
+ },
679
+ {
680
+ "type": "text",
681
+ "text": "Thus, it follows that $\\begin{array} { r } { \\| R _ { i } - R _ { j } \\| \\le \\varepsilon \\Rightarrow Q _ { i } ^ { \\top } K _ { j } + Q _ { j } ^ { \\top } K _ { i } \\ge 2 - \\varepsilon ^ { 2 } / 2 } \\end{array}$ . This means that, $\\| R _ { i } - R _ { j } \\| \\leq$ $\\varepsilon \\Rightarrow Q _ { i } ^ { \\top } K _ { j } \\geq 1 - \\varepsilon ^ { 2 } / 4$ . Therefore, when two time steps $i > j$ are assigned the same cluster due to a small $\\| R _ { i } - R _ { j } \\|$ distance, it also means that their attention weight $Q _ { i } ^ { \\top } K _ { j }$ is high. This analysis shows that our clustering routing strategy preserves large attention weights as non-zero entries. ",
682
+ "bbox": [
683
+ 173,
684
+ 238,
685
+ 825,
686
+ 301
687
+ ],
688
+ "page_idx": 5
689
+ },
690
+ {
691
+ "type": "text",
692
+ "text": "Since, we route attention via the matrix $R$ we dub our model Routing Transformer. The computational complexity of this variant of sparse attention is $O ( n k d + n ^ { 2 } d / k )$ . Cluster assignments correspond to the first term, i.e. it compares $n$ routing vectors to all $k$ centroids in a space of size $d$ . Query/key dot products corresponds to the second term, i.e. assuming balanced clusters, each of the $n$ queries is compared to √ $n / k$ in its cluster through a dot product of dimension $d$ . Therefore the optimal choice of $k$ is $\\sqrt { n }$ as in Child et al. (2019), thereby reducing overall memory and computational cost to $O \\left( n ^ { 1 . 5 } \\dot { d } \\right)$ instead of $O ( n ^ { 2 } d )$ (Vaswani et al., 2017). ",
693
+ "bbox": [
694
+ 174,
695
+ 308,
696
+ 825,
697
+ 406
698
+ ],
699
+ "page_idx": 5
700
+ },
701
+ {
702
+ "type": "text",
703
+ "text": "In practice, we apply regular online $k$ -means to train the cluster centroids. However, in order to infer balanced routing patterns, we define the sets $C _ { i }$ to be of equal size roughly $n / k \\sim \\sqrt { n }$ , i.e. for every centroid $\\mu _ { i }$ we sort tokens by distance to $\\mu _ { i }$ and cluster membership is determined by this threshold (top-k). This strategy is simple and efficient. In particular, it guarantees that all clusters have the same size, which is extremely interesting in terms of computational efficiency on parallel hardware like graphic cards. As a downside, this assignment does not guarantee that each point belongs to a single cluster. In the future, we want to investigate using balanced variants of $k$ -means (Malinen and Fränti, 2014) which is not common in an online setting. ",
704
+ "bbox": [
705
+ 174,
706
+ 412,
707
+ 825,
708
+ 523
709
+ ],
710
+ "page_idx": 5
711
+ },
712
+ {
713
+ "type": "text",
714
+ "text": "5 EXPERIMENTS ",
715
+ "text_level": 1,
716
+ "bbox": [
717
+ 176,
718
+ 544,
719
+ 326,
720
+ 560
721
+ ],
722
+ "page_idx": 5
723
+ },
724
+ {
725
+ "type": "text",
726
+ "text": "We evaluate our sparse attention model on various generative modeling tasks including text and image generation. The following sections report our results on Wikitext $- 1 0 3$ (Merity et al., 2016), enwik-8 (Mahoney, 2011), as well as ImageNet-64. We find that local attention is a surprisingly strong baseline and that our Routing Transformer outperforms Transformer-XL (Dai et al., 2019) and the Sparse Transformer model of (Child et al., 2019) on all tasks. In all our models, we allocate half the heads to do local attention and the other half to route attention as in Equation 10. We use the Adam optimizer (Kingma and Ba, 2014) with learning rate $2 \\times 1 0 ^ { - 4 }$ with $\\beta _ { 1 } = 0 . 9$ and $\\beta _ { 2 } = 0 . 9 8$ following the learning rate schedule described in Vaswani et al. (2017). ",
727
+ "bbox": [
728
+ 174,
729
+ 575,
730
+ 825,
731
+ 686
732
+ ],
733
+ "page_idx": 5
734
+ },
735
+ {
736
+ "type": "text",
737
+ "text": "5.1 WIKITEXT-103 ",
738
+ "text_level": 1,
739
+ "bbox": [
740
+ 174,
741
+ 703,
742
+ 320,
743
+ 718
744
+ ],
745
+ "page_idx": 5
746
+ },
747
+ {
748
+ "type": "text",
749
+ "text": "Wikitext-103 (Merity et al., 2016) is a large public benchmark data-set for testing long term dependencies in word-level language models. It contains over 100 million tokens from 28K articles extracted from Wikipedia with an average of 3.6K tokens per article, which makes it a reference data-set to model long-term textual dependencies. We train a 10 layer Routing Transformer with 16 heads using the relative position encoding of Shaw et al. (2018) and with attention and ReLU dropout rate of 0.3 each. For routing attention as in Section 4.2 we choose $k = 1 6$ and attention window to be 256 during both training and evaluation. We describe our results in Table 2 and compare it to other recent work on sparse or recurrent attention such as Adaptive Inputs (Baevski and Auli, 2018) and TransformerXL (Dai et al., 2019) as well as a local attention with relative position encoding baseline (Huang et al., 2018). We find that local attention is a great inductive bias for sparse attention and is better than the adaptive methods proposed in Baevski and Auli (2018); Sukhbaatar et al. (2019). Moreover, our Routing Transformer model is able to get a test perplexity of 15.8 improving on the 18.3 obtained by TransformerXL (Dai et al., 2019) while having fewer self-attention layers, and without the need for segment level recurrence. ",
750
+ "bbox": [
751
+ 174,
752
+ 729,
753
+ 825,
754
+ 924
755
+ ],
756
+ "page_idx": 5
757
+ },
758
+ {
759
+ "type": "text",
760
+ "text": "5.2 ENWIK-8 ",
761
+ "text_level": 1,
762
+ "bbox": [
763
+ 174,
764
+ 103,
765
+ 277,
766
+ 117
767
+ ],
768
+ "page_idx": 6
769
+ },
770
+ {
771
+ "type": "text",
772
+ "text": "The enwik-8 (Mahoney, 2011) is a data-set to benchmark text compression algorithms in the context of the Hutter prize. This data-set consists of the first 100M bytes of unprocessed Wikipedia. It is typically used to evaluate character-level language models. Similar to the prior work of Dai et al. (2019); Child et al. (2019) we use a sequence length $n = 8 1 9 2$ and benchmark our results against various baselines including local attention. We train a 24 layer model with 8 attention heads with an attention and ReLU dropout rate of 0.4 each and using the relative position encoding of Shaw et al. (2018). For routing attention as in Section 4.2 we set $k = 3 2$ and attention window 256. We report perplexity of 0.99 like TransformerXL and Sparse Transformer, slightly under 0.98 from Adaptive Transformer. We show how samples of our model differs from Transformer with local attention in Appendix C. ",
773
+ "bbox": [
774
+ 173,
775
+ 130,
776
+ 826,
777
+ 268
778
+ ],
779
+ "page_idx": 6
780
+ },
781
+ {
782
+ "type": "text",
783
+ "text": "5.3 IMAGENET $6 4 \\times 6 4$ ",
784
+ "text_level": 1,
785
+ "bbox": [
786
+ 176,
787
+ 285,
788
+ 349,
789
+ 299
790
+ ],
791
+ "page_idx": 6
792
+ },
793
+ {
794
+ "type": "text",
795
+ "text": "In order to evaluate the ability of our model to capture long term dependencies on a modality other than text, we report results on the ImageNet $6 4 \\times 6 4$ data-set as used in Child et al. (2019). For auto-regressive image generation, this data-set consists of images of $6 4 \\times 6 4 \\times 3$ bytes represented as long sequences of length 12, 288 presented in raster scan, red-green-blue order. We train a 24 layer model with 16 attention heads, with half the heads performing local attention, and the other half routing attention as in Section 3. For routing attention we set $k = 8$ , attention window 2048, batch size 1 and train our model for roughly 70 epochs as in (Child et al., 2019). We compare our model to a scaled-up ImageTransformer model with local attention (Parmar et al., 2018) and the SparseTransformer model of Child et al. (2019). ",
796
+ "bbox": [
797
+ 174,
798
+ 310,
799
+ 825,
800
+ 436
801
+ ],
802
+ "page_idx": 6
803
+ },
804
+ {
805
+ "type": "text",
806
+ "text": "We find that local attention (Parmar et al., 2018) is a strong baseline for image generation, obtaining 3.48 bits/dim when scaled up to 24 layers and 16 heads, compared to later work like Sub-scale Pixel Networks (SPN) (Menick and Kalchbrenner, 2018). Our Routing Transformer model achieves a performance of 3.425 bits/dim (see Table 1) compared to the previous state-of-the-art of 3.437 bits/dim (Child et al., 2019), thereby showing the advantage of the content based sparsity formulation of Section 4.2. ",
807
+ "bbox": [
808
+ 173,
809
+ 443,
810
+ 825,
811
+ 526
812
+ ],
813
+ "page_idx": 6
814
+ },
815
+ {
816
+ "type": "table",
817
+ "img_path": "images/76b4f6d2c2dc254950463017844552630bcf1ae850c8478a35d03d41dd489d4d.jpg",
818
+ "table_caption": [
819
+ "Table 1: Results on image generation on ImageNet $6 4 \\times 6 4$ in bits/dim. "
820
+ ],
821
+ "table_footnote": [],
822
+ "table_body": "<table><tr><td>Model</td><td></td><td></td><td>|Layers|Heads|Bits/dim</td></tr><tr><td>Glow (Kingma and Dhariwal, 2018)</td><td></td><td></td><td>3.81</td></tr><tr><td>PixelCNN(Van den Oord et al., 2016)</td><td></td><td></td><td>3.57</td></tr><tr><td>PixelSNAIL (Chen et al., 2017)</td><td></td><td></td><td>3.52</td></tr><tr><td>SPN (Menick and Kalchbrenner, 2018)</td><td>=</td><td>、</td><td>3.52</td></tr><tr><td>ImageTransformer (Parmar etal., 2018)</td><td>24</td><td>16</td><td>3.48</td></tr><tr><td>Sparse Transformer (Child et al., 2019)</td><td>48</td><td>16</td><td>3.44</td></tr><tr><td>Routing Transformer</td><td>24</td><td>16</td><td>3.43</td></tr></table>",
823
+ "bbox": [
824
+ 253,
825
+ 536,
826
+ 741,
827
+ 670
828
+ ],
829
+ "page_idx": 6
830
+ },
831
+ {
832
+ "type": "table",
833
+ "img_path": "images/e85571b5e648e5fe0016405aea6b4a42e5d0ede7e23536eaae1fb8bdf3e6c157.jpg",
834
+ "table_caption": [
835
+ "Table 2: Results on language modeling on Wikitext $- 1 0 3$ data-set. Local Transformer refers to Transformer (Vaswani et al., 2017) with relative position encoding (Shaw et al., 2018) together with local attention. Perplexity is reported on the test set. "
836
+ ],
837
+ "table_footnote": [],
838
+ "table_body": "<table><tr><td>Model</td><td></td><td></td><td>Layers|Heads|Perplexity</td></tr><tr><td>LSTMs (Grave et al., 2016)</td><td></td><td>=</td><td>40.8</td></tr><tr><td>QRNNs (Merity et al., 2018)</td><td>=</td><td>1</td><td>33.0</td></tr><tr><td>Adaptive Transformer (Sukhbaatar et al., 2019)</td><td>36</td><td>8</td><td>20.6</td></tr><tr><td>Local Transformer</td><td>16</td><td>16</td><td>19.8</td></tr><tr><td>Adaptive Input (Baevski and Auli, 2018)</td><td>16</td><td>16</td><td>18.7</td></tr><tr><td>TransformerXL (Dai et al., 2019)</td><td>18</td><td>16</td><td>18.3</td></tr><tr><td>Routing Transformer</td><td>10</td><td>16</td><td>15.8</td></tr></table>",
839
+ "bbox": [
840
+ 223,
841
+ 724,
842
+ 771,
843
+ 858
844
+ ],
845
+ "page_idx": 6
846
+ },
847
+ {
848
+ "type": "table",
849
+ "img_path": "images/64c0d32d4e3c5b7a84a9c0021118df9190b55999f4bf3400884425ccbf543ddf.jpg",
850
+ "table_caption": [
851
+ "Table 3: Results on language modeling on enwik-8 data-set. Local Transformer refers to Transformer (Vaswani et al., 2017) with relative position encoding (Shaw et al., 2018) together with local attention. Bits per byte (bpc) is reported on the test set. "
852
+ ],
853
+ "table_footnote": [],
854
+ "table_body": "<table><tr><td>Model</td><td></td><td></td><td>|Layers |Heads 丨Bits per byte</td></tr><tr><td>T64 (Al-Rfou et al., 2019)</td><td>64</td><td>2</td><td>1.13</td></tr><tr><td>Local Transformer</td><td>24</td><td>8</td><td>1.10</td></tr><tr><td>TransformerXL (Dai et al., 2019)</td><td>24</td><td>8</td><td>0.99</td></tr><tr><td>Sparse Transformer (Child et al., 2019)</td><td>30</td><td>8</td><td>0.99</td></tr><tr><td>Adaptive Transformer (Sukhbaatar et al., 2019)</td><td>24</td><td>8</td><td>0.98</td></tr><tr><td>Routing Transformer</td><td>12</td><td>8</td><td>0.99</td></tr></table>",
855
+ "bbox": [
856
+ 215,
857
+ 101,
858
+ 779,
859
+ 220
860
+ ],
861
+ "page_idx": 7
862
+ },
863
+ {
864
+ "type": "text",
865
+ "text": "6 ANALYSIS ",
866
+ "text_level": 1,
867
+ "bbox": [
868
+ 174,
869
+ 299,
870
+ 290,
871
+ 314
872
+ ],
873
+ "page_idx": 7
874
+ },
875
+ {
876
+ "type": "text",
877
+ "text": "We evaluate the difference in attention patterns between local and routed attention and compute the Jensen-Shannon divergence between local attention and routed attention for a random subset of heads in our network on the Wikitext-103 data-set. The divergence is computed over the entire sequence length of 4096. We average over 10 runs and all the self-attention layers, and report means and standard deviations of the JSD in Table 4. For mean JSD per layer, see Appendix B. Note that the JSD is always non-negative and is upper-bounded by 0.6931 when computed using the natural logarithm. We observe that the divergence between the different local heads is always very low compared to the divergence between local and routing attention heads, which is almost always very close to the upper-bound of 0.6931. Divergence between different routing attention heads falls somewhere in between, being closer to the upper-bound. This shows that the attention distribution inferred by the routing attention of Section 4.2 is highly non-local in nature and different heads specialize in attending to very different parts of the input. ",
878
+ "bbox": [
879
+ 173,
880
+ 329,
881
+ 825,
882
+ 497
883
+ ],
884
+ "page_idx": 7
885
+ },
886
+ {
887
+ "type": "table",
888
+ "img_path": "images/10a1d9038697fdce9cafa84ae1dacd10afdc94a2f9713f56d302418b71e21cd7.jpg",
889
+ "table_caption": [],
890
+ "table_footnote": [],
891
+ "table_body": "<table><tr><td></td><td></td><td> JSD(localllocal) | JSD(local||routing) | JSD(routingllrouting)</td></tr><tr><td>0.1776±0.0649|0.6044±0.0181</td><td></td><td>0.4181 ± 0.0415</td></tr></table>",
892
+ "bbox": [
893
+ 251,
894
+ 508,
895
+ 736,
896
+ 551
897
+ ],
898
+ "page_idx": 7
899
+ },
900
+ {
901
+ "type": "text",
902
+ "text": "Table 4: Jensen-Shannon divergence between the attention distributions of a random local attention head and a random head that routes attention as in Section 3 averaged across all layers on the Wikitext $- 1 0 3$ data-set. We report means and standard deviations computed over 10 runs. ",
903
+ "bbox": [
904
+ 174,
905
+ 565,
906
+ 825,
907
+ 608
908
+ ],
909
+ "page_idx": 7
910
+ },
911
+ {
912
+ "type": "text",
913
+ "text": "7 CONCLUSION ",
914
+ "text_level": 1,
915
+ "bbox": [
916
+ 176,
917
+ 642,
918
+ 318,
919
+ 659
920
+ ],
921
+ "page_idx": 7
922
+ },
923
+ {
924
+ "type": "text",
925
+ "text": "Transformer models constitutes the state-of-the-art in auto-regressive generative models for sequential data. Their space-time complexity is however quadratic in sequence length, due to their attention modules. Our work proposes a sparse attention model, the Routing Transformer. It relies on contentbased sparse attention motivated by non-negative matrix factorization. Compared with local attention models, it does not require fixed attention patterns but enjoys similar space-time complexity. In contrast with prior work on content-based sparse attention, it does not require computing a full attention matrix but still selects sparsity patterns based on content similarity. ",
926
+ "bbox": [
927
+ 174,
928
+ 672,
929
+ 825,
930
+ 770
931
+ ],
932
+ "page_idx": 7
933
+ },
934
+ {
935
+ "type": "text",
936
+ "text": "Our experiments over text and image generation draw two main conclusions. First, we show that a carefully tuned local attention model establishes a strong baseline on modern benchmark, even compared to recent state-of-the-art models. Second, we show that the Routing Transformer redefines the state-of-the-art in large long sequence benchmarks of Wikitext-103 and ImageNet-64, while being very close to do so on enwik-8 as well. Our analysis also shows that routed attention modules offer complementary attention patterns when compared to local attention. ",
937
+ "bbox": [
938
+ 174,
939
+ 777,
940
+ 825,
941
+ 861
942
+ ],
943
+ "page_idx": 7
944
+ },
945
+ {
946
+ "type": "text",
947
+ "text": "Overall, our work contributes an efficient attention mechanism that applies to the modeling of long sequences and redefines the state of the art for auto-regressive generative modeling. Our approach could prove useful in domains where the inputs are already sparse, such as 3D point clouds, social networks or protein interactions. ",
948
+ "bbox": [
949
+ 174,
950
+ 867,
951
+ 823,
952
+ 924
953
+ ],
954
+ "page_idx": 7
955
+ },
956
+ {
957
+ "type": "text",
958
+ "text": "REFERENCES ",
959
+ "text_level": 1,
960
+ "bbox": [
961
+ 174,
962
+ 103,
963
+ 287,
964
+ 117
965
+ ],
966
+ "page_idx": 8
967
+ },
968
+ {
969
+ "type": "text",
970
+ "text": "Rami Al-Rfou, Dokook Choe, Noah Constant, Mandy Guo, and Llion Jones. Character-level language modeling with deeper self-attention. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 33, pages 3159–3166, 2019. 8 ",
971
+ "bbox": [
972
+ 174,
973
+ 126,
974
+ 823,
975
+ 169
976
+ ],
977
+ "page_idx": 8
978
+ },
979
+ {
980
+ "type": "text",
981
+ "text": "Jimmy Lei Ba, Jamie Ryan Kiros, and Geoffrey E Hinton. Layer normalization. arXiv preprint arXiv:1607.06450, 2016. URL http://arxiv.org/abs/1607.06450. 4, 5 ",
982
+ "bbox": [
983
+ 169,
984
+ 176,
985
+ 825,
986
+ 207
987
+ ],
988
+ "page_idx": 8
989
+ },
990
+ {
991
+ "type": "text",
992
+ "text": "Alexei Baevski and Michael Auli. Adaptive input representations for neural language modeling. arXiv preprint arXiv:1809.10853, 2018. 6, 7 ",
993
+ "bbox": [
994
+ 171,
995
+ 215,
996
+ 825,
997
+ 244
998
+ ],
999
+ "page_idx": 8
1000
+ },
1001
+ {
1002
+ "type": "text",
1003
+ "text": "Dzmitry Bahdanau, Kyunghyun Cho, and Yoshua Bengio. Neural machine translation by jointly learning to align and translate. CoRR, abs/1409.0473, 2014. URL http://arxiv.org/abs/ 1409.0473. 1 ",
1004
+ "bbox": [
1005
+ 174,
1006
+ 253,
1007
+ 823,
1008
+ 296
1009
+ ],
1010
+ "page_idx": 8
1011
+ },
1012
+ {
1013
+ "type": "text",
1014
+ "text": "Yoshua Bengio, Nicholas Léonard, and Aaron Courville. Estimating or propagating gradients through stochastic neurons for conditional computation. arXiv preprint arXiv:1308.3432, 2013. 3 ",
1015
+ "bbox": [
1016
+ 173,
1017
+ 305,
1018
+ 825,
1019
+ 334
1020
+ ],
1021
+ "page_idx": 8
1022
+ },
1023
+ {
1024
+ "type": "text",
1025
+ "text": "Mathieu Blondel, André F. T. Martins, and Vlad Niculae. Learning classifiers with fenchel-young losses: Generalized entropies, margins, and algorithms. In The 22nd International Conference on Artificial Intelligence and Statistics, AISTATS 2019, 16-18 April 2019, Naha, Okinawa, Japan, pages 606–615, 2019. URL http://proceedings.mlr.press/v89/blondel19a. html. 2 ",
1026
+ "bbox": [
1027
+ 173,
1028
+ 342,
1029
+ 826,
1030
+ 412
1031
+ ],
1032
+ "page_idx": 8
1033
+ },
1034
+ {
1035
+ "type": "text",
1036
+ "text": "Leon Bottou and Yoshua Bengio. Convergence properties of the k-means algorithms. In Advances in neural information processing systems, pages 585–592, 1995. 5 ",
1037
+ "bbox": [
1038
+ 173,
1039
+ 422,
1040
+ 825,
1041
+ 452
1042
+ ],
1043
+ "page_idx": 8
1044
+ },
1045
+ {
1046
+ "type": "text",
1047
+ "text": "Xi Chen, Nikhil Mishra, Mostafa Rohaninejad, and Pieter Abbeel. Pixelsnail: An improved autoregressive generative model. arXiv preprint arXiv:1712.09763, 2017. 7 ",
1048
+ "bbox": [
1049
+ 176,
1050
+ 460,
1051
+ 823,
1052
+ 489
1053
+ ],
1054
+ "page_idx": 8
1055
+ },
1056
+ {
1057
+ "type": "text",
1058
+ "text": "Rewon Child, Scott Gray, Alec Radford, and Ilya Sutskever. Generating long sequences with sparse transformers. arXiv preprint arXiv:1904.10509, 2019. 1, 2, 4, 6, 7, 8 ",
1059
+ "bbox": [
1060
+ 174,
1061
+ 498,
1062
+ 825,
1063
+ 527
1064
+ ],
1065
+ "page_idx": 8
1066
+ },
1067
+ {
1068
+ "type": "text",
1069
+ "text": "Chung-Cheng Chiu and Colin Raffel. Monotonic chunkwise attention. arXiv preprint arXiv:1712.05382, 2017. 2 ",
1070
+ "bbox": [
1071
+ 173,
1072
+ 536,
1073
+ 825,
1074
+ 565
1075
+ ],
1076
+ "page_idx": 8
1077
+ },
1078
+ {
1079
+ "type": "text",
1080
+ "text": "Kyunghyun Cho and Yoshua Bengio. Exponentially increasing the capacity-to-computation ratio for conditional computation in deep learning. arXiv preprint arXiv:1406.7362, 2014. 3 ",
1081
+ "bbox": [
1082
+ 171,
1083
+ 574,
1084
+ 823,
1085
+ 603
1086
+ ],
1087
+ "page_idx": 8
1088
+ },
1089
+ {
1090
+ "type": "text",
1091
+ "text": "Kyunghyun Cho, Bart van Merrienboer, Caglar Gulcehre, Fethi Bougares, Holger Schwenk, and Yoshua Bengio. Learning phrase representations using RNN encoder-decoder for statistical machine translation. CoRR, abs/1406.1078, 2014. URL http://arxiv.org/abs/1406.1078. 1 ",
1092
+ "bbox": [
1093
+ 174,
1094
+ 612,
1095
+ 825,
1096
+ 655
1097
+ ],
1098
+ "page_idx": 8
1099
+ },
1100
+ {
1101
+ "type": "text",
1102
+ "text": "Jan K Chorowski, Dzmitry Bahdanau, Dmitriy Serdyuk, Kyunghyun Cho, and Yoshua Bengio. Attention-based models for speech recognition. In Advances in neural information processing systems, pages 577–585, 2015. 1, 2 ",
1103
+ "bbox": [
1104
+ 171,
1105
+ 664,
1106
+ 823,
1107
+ 707
1108
+ ],
1109
+ "page_idx": 8
1110
+ },
1111
+ {
1112
+ "type": "text",
1113
+ "text": "Gonçalo M. Correia, Vlad Niculae, and André F. T. Martins. Adaptively sparse transformers, 2019. 2, 3, 5 ",
1114
+ "bbox": [
1115
+ 171,
1116
+ 715,
1117
+ 825,
1118
+ 746
1119
+ ],
1120
+ "page_idx": 8
1121
+ },
1122
+ {
1123
+ "type": "text",
1124
+ "text": "Zihang Dai, Zhilin Yang, Yiming Yang, William W Cohen, Jaime Carbonell, Quoc V Le, and Ruslan Salakhutdinov. Transformer-xl: Attentive language models beyond a fixed-length context. arXiv preprint arXiv:1901.02860, 2019. 2, 3, 4, 6, 7, 8 ",
1125
+ "bbox": [
1126
+ 174,
1127
+ 753,
1128
+ 823,
1129
+ 797
1130
+ ],
1131
+ "page_idx": 8
1132
+ },
1133
+ {
1134
+ "type": "text",
1135
+ "text": "Ludovic Denoyer and Patrick Gallinari. Deep sequential neural network. arXiv preprint arXiv:1410.0510, 2014. 3 ",
1136
+ "bbox": [
1137
+ 169,
1138
+ 805,
1139
+ 825,
1140
+ 834
1141
+ ],
1142
+ "page_idx": 8
1143
+ },
1144
+ {
1145
+ "type": "text",
1146
+ "text": "Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. Bert: Pre-training of deep bidirectional transformers for language understanding. arXiv preprint arXiv:1810.04805, 2018. 1 ",
1147
+ "bbox": [
1148
+ 173,
1149
+ 843,
1150
+ 823,
1151
+ 873
1152
+ ],
1153
+ "page_idx": 8
1154
+ },
1155
+ {
1156
+ "type": "text",
1157
+ "text": "Chris Ding, Xiaofeng He, and Horst D Simon. On the equivalence of nonnegative matrix factorization and spectral clustering. In Proceedings of the 2005 SIAM International Conference on Data Mining, pages 606–610. SIAM, 2005. 2, 5 ",
1158
+ "bbox": [
1159
+ 176,
1160
+ 882,
1161
+ 823,
1162
+ 924
1163
+ ],
1164
+ "page_idx": 8
1165
+ },
1166
+ {
1167
+ "type": "text",
1168
+ "text": "David Eigen, Marc’Aurelio Ranzato, and Ilya Sutskever. Learning factored representations in a deep mixture of experts. arXiv preprint arXiv:1312.4314, 2013. 3 ",
1169
+ "bbox": [
1170
+ 169,
1171
+ 103,
1172
+ 823,
1173
+ 132
1174
+ ],
1175
+ "page_idx": 9
1176
+ },
1177
+ {
1178
+ "type": "text",
1179
+ "text": "Rainer Gemulla, Erik Nijkamp, Peter J. Haas, and Yannis Sismanis. Large-scale matrix factorization with distributed stochastic gradient descent. In SIGKDD International Conference on Knowledge Discovery and Data Mining, KDD ’11, 2011. 5 ",
1180
+ "bbox": [
1181
+ 176,
1182
+ 140,
1183
+ 823,
1184
+ 184
1185
+ ],
1186
+ "page_idx": 9
1187
+ },
1188
+ {
1189
+ "type": "text",
1190
+ "text": "Edouard Grave, Armand Joulin, and Nicolas Usunier. Improving neural language models with a continuous cache. arXiv preprint arXiv:1612.04426, 2016. 7 ",
1191
+ "bbox": [
1192
+ 171,
1193
+ 193,
1194
+ 823,
1195
+ 222
1196
+ ],
1197
+ "page_idx": 9
1198
+ },
1199
+ {
1200
+ "type": "text",
1201
+ "text": "Karol Gregor, Ivo Danihelka, Alex Graves, Danilo Jimenez Rezende, and Daan Wierstra. Draw: A recurrent neural network for image generation. arXiv preprint arXiv:1502.04623, 2015. 2 ",
1202
+ "bbox": [
1203
+ 173,
1204
+ 229,
1205
+ 823,
1206
+ 260
1207
+ ],
1208
+ "page_idx": 9
1209
+ },
1210
+ {
1211
+ "type": "text",
1212
+ "text": "Patrik O Hoyer. Non-negative matrix factorization with sparseness constraints. Journal of machine learning research, 5(Nov):1457–1469, 2004. 5 ",
1213
+ "bbox": [
1214
+ 171,
1215
+ 268,
1216
+ 823,
1217
+ 297
1218
+ ],
1219
+ "page_idx": 9
1220
+ },
1221
+ {
1222
+ "type": "text",
1223
+ "text": "Cheng-Zhi Anna Huang, Ashish Vaswani, Jakob Uszkoreit, Ian Simon, Curtis Hawthorne, Noam Shazeer, Andrew M Dai, Matthew D Hoffman, Monica Dinculescu, and Douglas Eck. Music transformer: Generating music with long-term structure. 2018. 1, 3, 6 ",
1224
+ "bbox": [
1225
+ 176,
1226
+ 306,
1227
+ 825,
1228
+ 349
1229
+ ],
1230
+ "page_idx": 9
1231
+ },
1232
+ {
1233
+ "type": "text",
1234
+ "text": "Sathish Reddy Indurthi, Insoo Chung, and Sangha Kim. Look harder: A neural machine translation model with hard attention. In Proceedings of the 57th Conference of the Association for Computational Linguistics, pages 3037–3043, 2019. 3 ",
1235
+ "bbox": [
1236
+ 176,
1237
+ 358,
1238
+ 825,
1239
+ 401
1240
+ ],
1241
+ "page_idx": 9
1242
+ },
1243
+ {
1244
+ "type": "text",
1245
+ "text": "Navdeep Jaitly, David Sussillo, Quoc V Le, Oriol Vinyals, Ilya Sutskever, and Samy Bengio. A neural transducer. arXiv preprint arXiv:1511.04868, 2015. 2 ",
1246
+ "bbox": [
1247
+ 173,
1248
+ 409,
1249
+ 823,
1250
+ 439
1251
+ ],
1252
+ "page_idx": 9
1253
+ },
1254
+ {
1255
+ "type": "text",
1256
+ "text": "Jingu Kim and Haesun Park. Sparse nonnegative matrix factorization for clustering. Technical report, Georgia Institute of Technology, 2008. 2, 5 ",
1257
+ "bbox": [
1258
+ 174,
1259
+ 446,
1260
+ 823,
1261
+ 477
1262
+ ],
1263
+ "page_idx": 9
1264
+ },
1265
+ {
1266
+ "type": "text",
1267
+ "text": "Diederik P. Kingma and Jimmy Ba. Adam: A method for stochastic optimization. CoRR, abs/1412.6980, 2014. URL http://arxiv.org/abs/1412.6980. 6 ",
1268
+ "bbox": [
1269
+ 174,
1270
+ 486,
1271
+ 823,
1272
+ 515
1273
+ ],
1274
+ "page_idx": 9
1275
+ },
1276
+ {
1277
+ "type": "text",
1278
+ "text": "Durk P Kingma and Prafulla Dhariwal. Glow: Generative flow with invertible 1x1 convolutions. In Advances in Neural Information Processing Systems, pages 10215–10224, 2018. 7 ",
1279
+ "bbox": [
1280
+ 174,
1281
+ 522,
1282
+ 823,
1283
+ 553
1284
+ ],
1285
+ "page_idx": 9
1286
+ },
1287
+ {
1288
+ "type": "text",
1289
+ "text": "Daniel D Lee and H Sebastian Seung. Algorithms for non-negative matrix factorization. In Advances in neural information processing systems, pages 556–562, 2001. 2, 5 ",
1290
+ "bbox": [
1291
+ 173,
1292
+ 560,
1293
+ 825,
1294
+ 590
1295
+ ],
1296
+ "page_idx": 9
1297
+ },
1298
+ {
1299
+ "type": "text",
1300
+ "text": "Peter J Liu, Mohammad Saleh, Etienne Pot, Ben Goodrich, Ryan Sepassi, Lukasz Kaiser, and Noam Shazeer. Generating wikipedia by summarizing long sequences. arXiv preprint arXiv:1801.10198, 2018. 2 ",
1301
+ "bbox": [
1302
+ 174,
1303
+ 598,
1304
+ 825,
1305
+ 641
1306
+ ],
1307
+ "page_idx": 9
1308
+ },
1309
+ {
1310
+ "type": "text",
1311
+ "text": "Xiaodong Liu, Pengcheng He, Weizhu Chen, and Jianfeng Gao. Multi-task deep neural networks for natural language understanding. arXiv preprint arXiv:1901.11504, 2019. 1 ",
1312
+ "bbox": [
1313
+ 174,
1314
+ 650,
1315
+ 823,
1316
+ 680
1317
+ ],
1318
+ "page_idx": 9
1319
+ },
1320
+ {
1321
+ "type": "text",
1322
+ "text": "Stuart Lloyd. Least squares quantization in pcm. IEEE transactions on information theory, 28(2): 129–137, 1982. 5 ",
1323
+ "bbox": [
1324
+ 174,
1325
+ 688,
1326
+ 823,
1327
+ 717
1328
+ ],
1329
+ "page_idx": 9
1330
+ },
1331
+ {
1332
+ "type": "text",
1333
+ "text": "Minh-Thang Luong, Hieu Pham, and Christopher D Manning. Effective approaches to attention-based neural machine translation. arXiv preprint arXiv:1508.04025, 2015. 1, 2, 4 ",
1334
+ "bbox": [
1335
+ 174,
1336
+ 726,
1337
+ 825,
1338
+ 756
1339
+ ],
1340
+ "page_idx": 9
1341
+ },
1342
+ {
1343
+ "type": "text",
1344
+ "text": "Matt Mahoney. Large text compression benchmark. URL: http://www. mattmahoney. net/text/text. html, 2011. 6, 7 ",
1345
+ "bbox": [
1346
+ 173,
1347
+ 763,
1348
+ 825,
1349
+ 794
1350
+ ],
1351
+ "page_idx": 9
1352
+ },
1353
+ {
1354
+ "type": "text",
1355
+ "text": "Chaitanya Malaviya, Pedro Ferreira, and André F. T. Martins. Sparse and constrained attention for neural machine translation. In Proceedings of the 56th Annual Meeting of the Association for Computational Linguistics (Volume 2: Short Papers), pages 370–376, Melbourne, Australia, July 2018. Association for Computational Linguistics. doi: 10.18653/v1/P18-2059. URL https: //www.aclweb.org/anthology/P18-2059. 3 ",
1356
+ "bbox": [
1357
+ 174,
1358
+ 801,
1359
+ 825,
1360
+ 872
1361
+ ],
1362
+ "page_idx": 9
1363
+ },
1364
+ {
1365
+ "type": "text",
1366
+ "text": "Mikko I Malinen and Pasi Fränti. Balanced k-means for clustering. In Joint IAPR International Workshops on Statistical Techniques in Pattern Recognition (SPR) and Structural and Syntactic Pattern Recognition (SSPR), pages 32–41. Springer, 2014. 6 ",
1367
+ "bbox": [
1368
+ 174,
1369
+ 882,
1370
+ 825,
1371
+ 924
1372
+ ],
1373
+ "page_idx": 9
1374
+ },
1375
+ {
1376
+ "type": "text",
1377
+ "text": "André F. T. Martins and Julia Kreutzer. Learning what’s easy: Fully differentiable neural easy-first taggers. In Proceedings of the 2017 Conference on Empirical Methods in Natural Language Processing, pages 349–362, Copenhagen, Denmark, September 2017. Association for Computational Linguistics. doi: 10.18653/v1/D17-1036. URL https://www.aclweb.org/anthology/ D17-1036. 3 ",
1378
+ "bbox": [
1379
+ 174,
1380
+ 103,
1381
+ 826,
1382
+ 172
1383
+ ],
1384
+ "page_idx": 10
1385
+ },
1386
+ {
1387
+ "type": "text",
1388
+ "text": "Jacob Menick and Nal Kalchbrenner. Generating high fidelity images with subscale pixel networks and multidimensional upscaling. arXiv preprint arXiv:1812.01608, 2018. 1, 7 ",
1389
+ "bbox": [
1390
+ 173,
1391
+ 183,
1392
+ 821,
1393
+ 212
1394
+ ],
1395
+ "page_idx": 10
1396
+ },
1397
+ {
1398
+ "type": "text",
1399
+ "text": "Stephen Merity, Caiming Xiong, James Bradbury, and Richard Socher. Pointer sentinel mixture models. arXiv preprint arXiv:1609.07843, 2016. 6 ",
1400
+ "bbox": [
1401
+ 174,
1402
+ 219,
1403
+ 821,
1404
+ 250
1405
+ ],
1406
+ "page_idx": 10
1407
+ },
1408
+ {
1409
+ "type": "text",
1410
+ "text": "Stephen Merity, Nitish Shirish Keskar, and Richard Socher. An analysis of neural language modeling at multiple scales. arXiv preprint arXiv:1803.08240, 2018. 7 ",
1411
+ "bbox": [
1412
+ 174,
1413
+ 257,
1414
+ 821,
1415
+ 286
1416
+ ],
1417
+ "page_idx": 10
1418
+ },
1419
+ {
1420
+ "type": "text",
1421
+ "text": "Niki Parmar, Ashish Vaswani, Jakob Uszkoreit, Łukasz Kaiser, Noam Shazeer, Alexander Ku, and Dustin Tran. Image transformer. arXiv preprint arXiv:1802.05751, 2018. 1, 3, 4, 7 ",
1422
+ "bbox": [
1423
+ 174,
1424
+ 295,
1425
+ 823,
1426
+ 325
1427
+ ],
1428
+ "page_idx": 10
1429
+ },
1430
+ {
1431
+ "type": "text",
1432
+ "text": "Alec Radford, Karthik Narasimhan, Tim Salimans, and Ilya Sutskever. Improving language understanding by generative pre-training. URL https://s3-us-west-2. amazonaws. com/openaiassets/research-covers/languageunsupervised/language understanding paper. pdf, 2018. 1, 3 ",
1433
+ "bbox": [
1434
+ 173,
1435
+ 333,
1436
+ 826,
1437
+ 376
1438
+ ],
1439
+ "page_idx": 10
1440
+ },
1441
+ {
1442
+ "type": "text",
1443
+ "text": "Peter Shaw, Jakob Uszkoreit, and Ashish Vaswani. Self-attention with relative position representations. arXiv preprint arXiv:1803.02155, 2018. 1, 4, 6, 7, 8 ",
1444
+ "bbox": [
1445
+ 174,
1446
+ 385,
1447
+ 823,
1448
+ 414
1449
+ ],
1450
+ "page_idx": 10
1451
+ },
1452
+ {
1453
+ "type": "text",
1454
+ "text": "Noam Shazeer, Azalia Mirhoseini, Krzysztof Maziarz, Andy Davis, Quoc Le, Geoffrey Hinton, and Jeff Dean. Outrageously large neural networks: The sparsely-gated mixture-of-experts layer. arXiv preprint arXiv:1701.06538, 2017. 3 ",
1455
+ "bbox": [
1456
+ 173,
1457
+ 422,
1458
+ 826,
1459
+ 465
1460
+ ],
1461
+ "page_idx": 10
1462
+ },
1463
+ {
1464
+ "type": "text",
1465
+ "text": "Sainbayar Sukhbaatar, Edouard Grave, Piotr Bojanowski, and Armand Joulin. Adaptive attention span in transformers. arXiv preprint arXiv:1905.07799, 2019. 2, 4, 6, 7, 8 ",
1466
+ "bbox": [
1467
+ 173,
1468
+ 474,
1469
+ 823,
1470
+ 503
1471
+ ],
1472
+ "page_idx": 10
1473
+ },
1474
+ {
1475
+ "type": "text",
1476
+ "text": "R. Tandon and S. Sra. Sparse nonnegative matrix approximation: new formulations and algorithms. Technical Report 193, Max Planck Institute for Biological Cybernetics, Tübingen, Germany, September 2010. 5 ",
1477
+ "bbox": [
1478
+ 176,
1479
+ 512,
1480
+ 825,
1481
+ 554
1482
+ ],
1483
+ "page_idx": 10
1484
+ },
1485
+ {
1486
+ "type": "text",
1487
+ "text": "Aaron Van den Oord, Nal Kalchbrenner, Lasse Espeholt, Oriol Vinyals, Alex Graves, et al. Conditional image generation with pixelcnn decoders. In Advances in neural information processing systems, pages 4790–4798, 2016. 7 ",
1488
+ "bbox": [
1489
+ 173,
1490
+ 564,
1491
+ 825,
1492
+ 606
1493
+ ],
1494
+ "page_idx": 10
1495
+ },
1496
+ {
1497
+ "type": "text",
1498
+ "text": "Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N. Gomez, Lukasz Kaiser, and Illia Polosukhin. Attention is all you need. CoRR, 2017. URL http: //arxiv.org/abs/1706.03762. 1, 3, 4, 6, 7, 8 ",
1499
+ "bbox": [
1500
+ 174,
1501
+ 614,
1502
+ 825,
1503
+ 659
1504
+ ],
1505
+ "page_idx": 10
1506
+ },
1507
+ {
1508
+ "type": "text",
1509
+ "text": "Kelvin Xu, Jimmy Lei Ba, Ryan Kiros, Kyunghyun Cho, Aaron Courville, Ruslan Salakhutdinov, Richard S. Zemel, and Yoshua Bengio. Show, attend and tell: Neural image caption generation with visual attention. In ICML, 2015. 2 ",
1510
+ "bbox": [
1511
+ 174,
1512
+ 666,
1513
+ 823,
1514
+ 709
1515
+ ],
1516
+ "page_idx": 10
1517
+ },
1518
+ {
1519
+ "type": "text",
1520
+ "text": "Zhilin Yang, Zihang Dai, Yiming Yang, Jaime Carbonell, Ruslan Salakhutdinov, and Quoc V Le. Xlnet: Generalized autoregressive pretraining for language understanding. arXiv preprint arXiv:1906.08237, 2019. 1 ",
1521
+ "bbox": [
1522
+ 174,
1523
+ 718,
1524
+ 826,
1525
+ 761
1526
+ ],
1527
+ "page_idx": 10
1528
+ },
1529
+ {
1530
+ "type": "text",
1531
+ "text": "A MATRIX NORM ANALYSIS ",
1532
+ "text_level": 1,
1533
+ "bbox": [
1534
+ 176,
1535
+ 102,
1536
+ 429,
1537
+ 118
1538
+ ],
1539
+ "page_idx": 11
1540
+ },
1541
+ {
1542
+ "type": "text",
1543
+ "text": "In order to formally derive Equation 11, we assume that the linear projection matrices $W _ { Q }$ and $W _ { K }$ used to infer the queries and keys respectively are close to each other in max norm. More precisely, we assume the existence of a $\\delta \\geq 0$ such that $\\left\\| W _ { Q } - W _ { K } \\right\\| _ { \\infty } \\leq \\delta$ . This assumption implies that for any vector $u \\in \\mathbb { R } ^ { d }$ it holds that: ",
1544
+ "bbox": [
1545
+ 174,
1546
+ 133,
1547
+ 825,
1548
+ 191
1549
+ ],
1550
+ "page_idx": 11
1551
+ },
1552
+ {
1553
+ "type": "equation",
1554
+ "img_path": "images/1f7431a005efbab14aba14d6f32c1e570225f279f8d5555c674e12407af17c62.jpg",
1555
+ "text": "$$\nu W _ { Q } \\leq u W _ { K } + \\delta \\mathbf { 1 } \\left\\| u \\right\\| _ { \\infty } ,\n$$",
1556
+ "text_format": "latex",
1557
+ "bbox": [
1558
+ 405,
1559
+ 199,
1560
+ 591,
1561
+ 217
1562
+ ],
1563
+ "page_idx": 11
1564
+ },
1565
+ {
1566
+ "type": "text",
1567
+ "text": "where the inequality is entry-wise and 1 is the vector in $\\mathbb { R } ^ { d }$ with all 1’s. In this case we first show that for any pair $i , j$ the queries and keys satisfy the following: ",
1568
+ "bbox": [
1569
+ 174,
1570
+ 224,
1571
+ 823,
1572
+ 253
1573
+ ],
1574
+ "page_idx": 11
1575
+ },
1576
+ {
1577
+ "type": "equation",
1578
+ "img_path": "images/60beba377a6edd6d986c427432ac38431c5b31d5c3e03088e6c2c220900f0269.jpg",
1579
+ "text": "$$\n\\begin{array} { r l } & { ( Q _ { i } - K _ { j } ) ^ { \\top } ( Q _ { j } - K _ { i } ) = ( X _ { i } W _ { Q } - X _ { j } W _ { K } ) ^ { \\top } ( X _ { j } W _ { Q } - X _ { i } W _ { K } ) } \\\\ & { \\qquad \\leq ( \\delta { \\mathbf { 1 } \\| X _ { i } \\| _ { \\infty } } + ( X _ { i } - X _ { j } ) W _ { K } ) ^ { \\top } ( \\delta { \\mathbf { 1 } \\| X _ { j } \\| _ { \\infty } } - ( X _ { i } - X _ { j } ) W _ { K } ) } \\\\ & { \\qquad \\leq \\delta ^ { 2 } \\| { \\mathbf { 1 } \\| ^ { 2 } \\operatorname* { m a x } \\{ \\| X _ { i } \\| _ { \\infty } , \\| X _ { j } \\| _ { \\infty } \\} ^ { 2 } } - \\| ( X _ { i } - X _ { j } ) W _ { K } \\| ^ { 2 } } \\end{array}\n$$",
1580
+ "text_format": "latex",
1581
+ "bbox": [
1582
+ 186,
1583
+ 258,
1584
+ 782,
1585
+ 324
1586
+ ],
1587
+ "page_idx": 11
1588
+ },
1589
+ {
1590
+ "type": "text",
1591
+ "text": "Therefore, for small enough $\\delta$ , we get that $( Q _ { i } - Q _ { j } ) ^ { \\top } ( Q _ { j } - K _ { i } ) \\lessapprox 0$ and so Equation 11 follows: ",
1592
+ "bbox": [
1593
+ 179,
1594
+ 329,
1595
+ 823,
1596
+ 348
1597
+ ],
1598
+ "page_idx": 11
1599
+ },
1600
+ {
1601
+ "type": "equation",
1602
+ "img_path": "images/4a9eb57a15eee14c8cb2582c0ff73d24fb7bf7d10adffe160843293fc16df366.jpg",
1603
+ "text": "$$\n\\begin{array} { r l } & { \\| R _ { i } - R _ { j } \\| ^ { 2 } = \\| W _ { R } ( Q _ { i } + K _ { i } ) - W _ { R } ( Q _ { j } + K _ { j } ) \\| ^ { 2 } } \\\\ & { \\qquad = \\| W _ { R } \\| ^ { 2 } \\left( \\| Q _ { i } - K _ { j } \\| ^ { 2 } + \\| Q _ { j } - K _ { i } \\| ^ { 2 } - 2 ( Q _ { i } - K _ { j } ) ^ { \\top } ( Q _ { j } - K _ { i } ) \\right) } \\\\ & { \\qquad \\gtrapprox \\| W _ { R } \\| ^ { 2 } \\left( \\| Q _ { i } - K _ { j } \\| ^ { 2 } + \\| Q _ { j } - K _ { i } \\| ^ { 2 } \\right) . } \\end{array}\n$$",
1604
+ "text_format": "latex",
1605
+ "bbox": [
1606
+ 210,
1607
+ 352,
1608
+ 758,
1609
+ 430
1610
+ ],
1611
+ "page_idx": 11
1612
+ },
1613
+ {
1614
+ "type": "text",
1615
+ "text": "Note that a special case of this assumption is when $W _ { Q } = W _ { K }$ , i.e. queries and keys are shared, in which case $\\delta = 0$ . ",
1616
+ "bbox": [
1617
+ 173,
1618
+ 434,
1619
+ 825,
1620
+ 463
1621
+ ],
1622
+ "page_idx": 11
1623
+ },
1624
+ {
1625
+ "type": "text",
1626
+ "text": "B JENSEN-SHANNON DIVERGENCE OF ATTENTION DISTRIBUTIONS ",
1627
+ "text_level": 1,
1628
+ "bbox": [
1629
+ 171,
1630
+ 483,
1631
+ 751,
1632
+ 500
1633
+ ],
1634
+ "page_idx": 11
1635
+ },
1636
+ {
1637
+ "type": "text",
1638
+ "text": "In Table 4 we presented the Jensen-Shannon divergence between random local heads and random routing attention heads averaged across the 10 layers of the Routing Transformer model on Wikitext $- 1 0 3$ . Table 5 presents the mean and standard deviations of the JSD per layer instead of averaging them. ",
1639
+ "bbox": [
1640
+ 174,
1641
+ 513,
1642
+ 826,
1643
+ 571
1644
+ ],
1645
+ "page_idx": 11
1646
+ },
1647
+ {
1648
+ "type": "table",
1649
+ "img_path": "images/881905370572e7a56f88e00b5cb8ef0bce6aa15d6074d7c9e03a7ab0bb125062.jpg",
1650
+ "table_caption": [],
1651
+ "table_footnote": [],
1652
+ "table_body": "<table><tr><td rowspan=1 colspan=1></td><td rowspan=1 colspan=1>JSD(local || local)</td><td rowspan=1 colspan=1> JSD(locallrouting) | JSD(routingllrouting)</td><td rowspan=1 colspan=1> JSD(locallrouting) | JSD(routingllrouting)</td></tr><tr><td rowspan=1 colspan=1>layer0</td><td rowspan=1 colspan=1>0.0038 ± 0.0018</td><td rowspan=1 colspan=1>0.4706 ± 0.0319</td><td rowspan=10 colspan=1>0.1579 ± 0.05760.5820 ± 0.01040.4015 ± 0.01210.4144 ± 0.02640.4191 ± 0.08790.4687 ± 0.04490.5175 ± 0.04690.4350 ± 0.01390.4268 ± 0.02910.3581 ± 0.0019</td></tr><tr><td rowspan=1 colspan=1>layer 1</td><td rowspan=1 colspan=1>0.3071 ± 0.1217</td><td rowspan=1 colspan=1>0.6674 ± 0.0153</td></tr><tr><td rowspan=1 colspan=1>layer2</td><td rowspan=1 colspan=1>0.2164 ± 0.0803</td><td rowspan=1 colspan=1>0.5896 ± 0.0249</td></tr><tr><td rowspan=1 colspan=1>layer3</td><td rowspan=1 colspan=1>0.1163 ± 0.0336</td><td rowspan=2 colspan=1>0.6047 ± 0.01810.6266 ± 0.0062</td></tr><tr><td rowspan=1 colspan=1>layer4</td><td rowspan=1 colspan=1>0.1840 ± 0.0562</td></tr><tr><td rowspan=1 colspan=1>layer5</td><td rowspan=1 colspan=1>0.2284 ± 0.0225</td><td rowspan=2 colspan=1>0.6463 ± 0.01550.6471 ± 0.0040</td></tr><tr><td rowspan=1 colspan=1>layer6</td><td rowspan=1 colspan=1>0.1901 ± 0.0525</td></tr><tr><td rowspan=1 colspan=1>layer7</td><td rowspan=1 colspan=1>0.1566 ± 0.0685</td><td rowspan=1 colspan=1>0.5798 ± 0.0235</td></tr><tr><td rowspan=1 colspan=1>layer8</td><td rowspan=1 colspan=1>0.1638 ± 0.0739</td><td rowspan=1 colspan=1>0.5993 ± 0.0148</td></tr><tr><td rowspan=1 colspan=1>layer9</td><td rowspan=1 colspan=1>0.2095 ± 0.0560</td><td rowspan=1 colspan=1>0.6127 ± 0.0053</td></tr></table>",
1653
+ "bbox": [
1654
+ 210,
1655
+ 583,
1656
+ 784,
1657
+ 752
1658
+ ],
1659
+ "page_idx": 11
1660
+ },
1661
+ {
1662
+ "type": "text",
1663
+ "text": "Table 5: Jensen-Shannon divergence between the attention distributions of a random local attention head and a random head that routes attention as in Section 3 per layer on the Wikitext-103 dataset. We report means and standard deviations computed over 10 runs and use the natural logarithm so that divergences are upper-bounded by 0.6931. ",
1664
+ "bbox": [
1665
+ 173,
1666
+ 766,
1667
+ 826,
1668
+ 823
1669
+ ],
1670
+ "page_idx": 11
1671
+ },
1672
+ {
1673
+ "type": "text",
1674
+ "text": "C SAMPLES ",
1675
+ "text_level": 1,
1676
+ "bbox": [
1677
+ 174,
1678
+ 849,
1679
+ 289,
1680
+ 866
1681
+ ],
1682
+ "page_idx": 11
1683
+ },
1684
+ {
1685
+ "type": "text",
1686
+ "text": "We generate samples from the Routing Transformer model for the task of character level language modeling on the enwik-8 data-set. We compare the generation to that from a Local Transformer model with the same number of self-attention layers and attention heads. For both the models we generate unconditional samples using random sampling with a temperature of 1.0. The generation from the Routing Transformer is in Table 6 while the generation from Local Transformer is in Table 7, with spelling mistakes highlighted in red. Comparing the two samples we see that the Local Transformer makes significantly more spelling mistakes, especially for long words and phrases. ",
1687
+ "bbox": [
1688
+ 174,
1689
+ 881,
1690
+ 825,
1691
+ 924
1692
+ ],
1693
+ "page_idx": 11
1694
+ },
1695
+ {
1696
+ "type": "text",
1697
+ "text": "",
1698
+ "bbox": [
1699
+ 174,
1700
+ 103,
1701
+ 825,
1702
+ 160
1703
+ ],
1704
+ "page_idx": 12
1705
+ },
1706
+ {
1707
+ "type": "table",
1708
+ "img_path": "images/fd971abab466d62030158e130027467d15fcfe89c889f839a504948a466399e8.jpg",
1709
+ "table_caption": [],
1710
+ "table_footnote": [],
1711
+ "table_body": "<table><tr><td>Modern Least Rule to bon air and dogmatic television articles several systems: expanding the world usually.The story differs,that would its part flex poetry will support the very little able to put the name by oppose the stories and motorcycle transecurity and biggest life, see the guardian article and looks extraction of large story in storage by meanching up biggest among other items. During that time,Nevis had biggest the Very left record of the party&#x27;s tissues. The London meaning;biggest guardians of the West; in the 198Os and 198Os.The composer Albert Director boards the capture to the beginning. The Son Revised publicity and Revisionism board was way of to enough a descendant the President solely changed from [[Eddie Tellingl], but in fact that assembly was to become common. The President has poor party detonation the decisions; Telling guards [[Pope University of New York]], especially [[Canes CombustionlCanes],and thus [[bankruptcylbankruptcy]] student [Advisor]] include the latter that the swash of its populatiis churches, not in steel [Libertarianism peaceful anti-instancelsave the matter&#x27;s pieces]],and has been languaged efforts taken in 58,OoO sections of anthropic perimeter. The great precision exists in 2OO4,with an assistant to feature vault on other great Peaceful themes in America, the nose of highly [[artificial rate]]es,the discussions of cause, simply soon because they order to setting out the institution political party activity.As of 2004, anthropology saves them as chiefs derivation from the princess of the Executability can be run all</td></tr><tr><td>down by deriving the executability to understand the scientific additional British family traitirity. These intermediate are unproperly equipped, more unprofitability the officiely competite mass best science fiction between the notion of a brought Executive school. This project proves the materiel of controversy and high-school intervention and thoughts of as specurety. [Danceholding]],one can specure even as the mission to bind its dusting intervention. At its original time, he current in the cost of moral intervention, in an 2OO6 slight, tracement saw for the passagecomic belief between the city and applying its uncurrent binary placement, one applies to specure the [biographylbiographyll of regions, his conserved reference election in the letter the most part of the [Dominicus]]. [Algebraizing theorylAlgebrric]] [[critic]]s,which operate the [[third typelthird]] of uncut in to the [[militity]] of the country,her brother&#x27;s deduction may not be denying cases of militity. In the period,[[Bninity Memoryll</td></tr><tr><td>plus how [Jewish PhilologylPhilosophyl] with a series of voruments of each other can be defined as part of [[p-cyclic memory]],which have been ruleful out for military conventions and have unknown orders,of their proposition (because of the political magnitude circumference of other classness and [forgeryll). This highly proposing not with a member of [John Hope (fiction)lJohn Hope]]: Their chief acceptance,or that rapidly proposes C-them by bluetooth sentiments another time.The sentence of the [[North American Executive DepartmentlDED]] was did not believe the pocket currently by critic,and the reaction by 2OO4 roughly 400 people and King John Hope was used by the capabalance of other executive organizers in the circumstance of the chief post-John chief of the 3000 pects. Independences improved [North American_powers_turning_ in_the_educationlnorth of the Education]] For throughout the end of [[199O]].After prizes of those of the John Hope,Generic Atempts - from London rivers Genero helped to prevent any anti-country packaging in London.Long term helped by all the Jury before the Council of Zoroastries develop for packet (since [[199Oll) which conspires, anypreventing them,which offered the Native American forces to meet them up them to be referred to unto [[first Friendlsouthwest the first VO]]. The symbol was based on the canon of [[St. Franciscol] that bring through this force,some position of north the Graduate Agency (which constituted a third) or the other medium in the Friend.Military as</td></tr></table>",
1712
+ "bbox": [
1713
+ 186,
1714
+ 116,
1715
+ 813,
1716
+ 871
1717
+ ],
1718
+ "page_idx": 13
1719
+ },
1720
+ {
1721
+ "type": "text",
1722
+ "text": "0 ]]oter sonries as refrien ritu] serm host teen serm hostul ritu’; baron, in one ritu’;. Refriendamonium rite host teen confriendamonium in the ritu’s role of ritual resolution. The ritual monitor was baron mentalists for hostilities on the rational series; this river was dubion until the confriendamonitor, emerged with this concept into intermedies in one witnessing. They introduced the series of not confriendamonium (very relief). They continued to increase the time / India’s power down. The ritual production to batted conway choosing by the products of the whole choosing as happens as [[alignment]], and an aircraft happened to the kind. As it returned to the operation of the whole producting the large small scale axis. They were reproduced as logts (intwiting they also affected this drip to the easily life) and our shall materials and provided a relative shallow to the motorum. Batted chirality as to the operations of the ANCUP system material to comment adults was bad, as an invasive shallow to be pressure that the program, the subject of ANCUP has been celebrated, since the easily long easily more commonly functions should easily be proved to prevent and group divisions. Batted chirality from the relative community that the controversies came under the writing community led to the legal revolt From the time and from a program that they had become explicitly especially in the following year. In [[1984]], and depictions of the government by a subject were used, proved by manticians, confering from their structure at [[Mid From Los Angeles|Los Angeles]], disputes control and implementing the programming of Hannibal at least proposionals of the [[dependency of Philharmos and Winds would make control of the protest actress from much of their sources, making any process thates of [[contention]] of channing the column to inland any time where at neardy Rube. Philharmos gives protest to any great b(axis). Namely one of his reigns characterization of unofficial competitive structural did attempt to win some results, myrmonisms, which have been successfully greatly monthly. But Anamos meant that his reasons to his harmonists analog was cold and officials success, quickly denominate a Japanese continued to bring the army various times some full terms of the suffix of an obficial réligious religions were surcessful older in Coloniaas and was set. One London, last names, comprising him to succedulate to him deeper. Over the remarkable Submission was, Submission might be a mussel upon his loyal rebuilding dynasty, a program and young by Coloniaas (erasmol), the troops law, with their humans. Less, Miss missions and Cathar with their significance, the troops led by the massive society of the Holy Roman Holy Mission document in the Coloniaan Committee, hence is headby which the course of Summoniacs, ”Black Writers”, recognizing him the body, Suspense), within the next member of the troops. ;ref name=Cathar Lesson de Les Rise is derived from the 1990s. Suspense that she missed the course of the erasmolents, part of the character in the member of the 1990s Character acted in some of his coar, the 4 bill belonging to the eight members of the member of the 1990s. It was threatened in 1997, and let directly affluencing in saltiming exponents within the study emerge in the 1990s and [[canon]]s working in 1992, and roadly fought in other sections to saltimine races. But failed to thought in the significant shot [[Leibniz]]. (Fulham banned 1990 to 1999, when primitively [[eldest]]), his deadly 299 primitive style of ”Aghai 2001”. Symmonists were silicated by the [[Joey Forces]] and Net. Making the eldest years, he published a finite similar racing, revealed by him a straight just greatly killed beyond a latest-sale public bridge that two great first soundtracking, which ”’Bolumeck Coal”’. ”[[Mononymile]] beginning, Dom., the head of the same racing of him of the eldest day1. Japanese amount in the storm of the sense of Caw celebrated on Monthly appearing instead of cross-music. When overslanding”’ (which during his visual) is raised in both the placement and which different from the storm, recent elements, Bolumeck Winters Sense Miller which runs up raising ameth.;Caj is analogy. ",
1723
+ "bbox": [
1724
+ 218,
1725
+ 174,
1726
+ 781,
1727
+ 810
1728
+ ],
1729
+ "page_idx": 14
1730
+ }
1731
+ ]
parse/train/B1gjs6EtDr/B1gjs6EtDr_middle.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/B1gjs6EtDr/B1gjs6EtDr_model.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/B1l3M64KwB/B1l3M64KwB.md ADDED
@@ -0,0 +1,232 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # HOW MANY WEIGHTS ARE ENOUGH : CAN TENSOR FACTORIZATION LEARN EFFICIENT POLICIES ?
2
+
3
+ Anonymous authors Paper under double-blind review
4
+
5
+ # ABSTRACT
6
+
7
+ Deep reinforcement learning requires a heavy price in terms of sample efficiency and overparameterization in the neural networks used for function approximation. In this work, we employ tensor factorization in order to learn more compact representations for reinforcement learning policies. We show empirically that in the low-data regime, it is possible to learn online policies with 2 to 10 times less total coefficients, with little to no loss of performance. We also leverage progress in second order optimization, and use the theory of wavelet scattering to further reduce the number of learned coefficients, by foregoing learning the topmost convolutional layer filters altogether. We evaluate our results on the Atari suite against recent baseline algorithms that represent the state-of-the-art in data efficiency, and get comparable results with an order of magnitude gain in weight parsimony.
8
+
9
+ # 1 INTRODUCTION
10
+
11
+ The successes of reinforcement learning (thereafter ’RL’), and specifically deep RL, come at a heavy computational price. It is well known that achieving human-level performance in domains such as Atari (Sutton & Barto, 2018; Mnih et al., 2013; Hessel et al., 2017) requires hundreds of millions of frames of environment interaction. As such, the problem of sample efficiency in RL is of critical importance. Several tracks of concurrent research are being investigated, and have reduced by orders of magnitude the number of environment interactions required for good performance beyond the previous benchmark of biologically-inspired episodic control methods (Blundell et al., 2016; Pritzel et al., 2017) to a couple hours of human gameplay time (van Hasselt et al., 2019; Kaiser et al., 2019).
12
+
13
+ However, while the data-efficiency of RL methods has seen recent drastic performance gains, the function approximators they use still require millions of learned weights, potentially still leaving them heavily overparameterized. Independently motivated by biological facts like the behavioural readiness of newborn animals, several authors (Gaier & Ha, 2019; Cuccu et al., 2018; Wang et al., 2019) have recently looked at doing away with learning so many weights for RL tasks. Smaller networks not only train faster, but may yet offer another avenue for gains in the form of better generalization (Zhang et al., 2016). Recent work from Gaier & Ha (2019) studies the effect of inductive bias of neural architectures in RL ; they forego training altogether, but transfer networks that only obtain ’better than chance performance on MNIST’. In similar fashion, Wang et al. (2019) investigate the effect of random projections in the restricted setting of imitation learning. Finally, Cuccu et al. (2018) manage human-level performance on the Atari suite using a separate dictionary learning procedure for their features, bypassing the usual end-to-end learning paradigm. The perspective of neural architecture search applied to RL appears difficult, if not computationally inextricable.
14
+
15
+ Concurrently, the study of biologically-inspired models of learning has exhibited two mathematical characterizations that might be critical in explaining how biological learning takes place so efficiently. First, the low-rank properties of learned perceptual manifolds (Chung et al., 2018; 2016) are giving rise to a rich theory borrowing from statistical physics. Second, another well known line of work has identified Gabor filters, and more generally wavelet filter-like structures, in the actual visual cortex of animals (Jones & Palmer, 1987), and linked those to sparsity-promoting methods and dictionary learning (Olshausen & Field, 1996; 1997; Hyvarinen & Hoyer, 2001). But these ¨ breakthroughs have not, so far, been reflected as inductive priors in the shape of modifications in deep RL neural networks architectures, which remain fairly fixed on the Atari domain.
16
+
17
+ Therefore the following questions remain: how parsimonious do function approximators in RL need to be, in order to maintain good performance? And can we be at once sample-efficient and weightefficient ? In this work, we turn to the mathematical theories of tensor factorization (Cichocki et al., 2009), second-order optimization (Amari, 1998; Martens & Grosse, 2015) and wavelet scattering (Mallat, 2011) to answer this question positively and empirically, in a model-free setting.
18
+
19
+ We propose to use these methods in order to save weights and therefore favour convergence of policies:
20
+
21
+ • We replace dense, fully-connected layers with tensor regression layers. • Optionally, we replace the topmost layer in the convolutional architecture with a scattering layer; the deeper convolutional layers are left untouched. • The (positive) impact of second-order optimization is also evaluated.
22
+
23
+ To the best of our knowledge, this is the first time those fields have been combined together in this context, and that tensor factorization is applied to deep RL.
24
+
25
+ # 2 BACKGROUND & RELATED WORK
26
+
27
+ # 2.1 DEEP REINFORCEMENT LEARNING
28
+
29
+ We consider the standard Markov Decision Process framework as in Sutton $\&$ Barto (2018). This setting is characterised by a tuple $\langle S , A , T , R , \gamma \rangle$ , where $S$ is a set of states, $A$ a set of actions, $R$ a reward function that is the immediate, intrinsic desirability of a certain state, $T$ a transition dynamics and $\gamma \in [ 0 , 1 ]$ a discount factor. The purpose of the RL problem is to to find a policy $\pi$ , which represents a mapping from states to a probability distribution over actions, that is optimal, i.e., that maximizes the expected cumulative discounted return $\scriptstyle \sum _ { k = 0 } ^ { \infty } \gamma ^ { k } R _ { t + k + 1 }$ at each state $s _ { t } ~ \in ~ S$ In Q-learning, the policy is given implicitly by acting greedily or $\epsilon$ -greedily with respect to learned action-value functions $\boldsymbol { q } ^ { \pi } ( s , a )$ , that are learned following the Bellman equation. In deep $Q$ -learning, $q _ { \theta }$ becomes parameterized by the weights $\theta$ of a neural network and one minimizes the expected Bellman loss :
30
+
31
+ $$
32
+ \mathbb { E } \left( R _ { t + 1 } + \gamma _ { t + 1 } \operatorname* { m a x } _ { a ^ { \prime } } q _ { \theta } \left( S _ { t + 1 } , a ^ { \prime } \right) - q _ { \theta } \left( S _ { t } , A _ { t } \right) \right) ^ { 2 }
33
+ $$
34
+
35
+ In practice, this is implemented stochastically via uniform sampling of transitions in an experience replay buffer, as is done in the seminal paper Mnih et al. (2013). Several algorithmic refinements to that approach exist. First, Double Q-learning (van Hasselt et al., 2015) proposes to decouple learning between two networks in order to alleviate the Q-value overestimation problem. Second, dueling Q-networks (Wang et al., 2015) explicitly decompose the learning of an action-value function $q _ { \theta } ( s , a )$ as the sum of an action-independent state-value, much like what is traditionally done in policy gradient methods (Sutton & Barto, 2018), implemented via a two-headed neural network architecture. Finally, prioritized RL (Schaul et al., 2015) proposes to replace the uniform sampling of transitions in the experience replay buffer with importance sampling, by prioritizing those transitions that present the most Bellman error (those transitions that are deemed the most ’surprising’ by the agent). Fortunato et al. (2017) use extra weights to learn the variance of the exploration noise in a granular fashion, while Bellemare et al. (2017) propose to learn a full distribution of action-values for each action and state. Combined, those methods form the basis of the Rainbow algorithm in Hessel et al. (2017).
36
+
37
+ # 2.2 TENSOR FACTORIZATION
38
+
39
+ Here we introduce notations and concepts from the tensor factorization literature. An intuition is that the two main decompositions below, $C P$ and Tucker decompositions, can be understood as multilinear algebra analogues of SVD or eigendecomposition.
40
+
41
+ CP decomposition. A tensor $\mathcal { X } \in \mathbb { R } ^ { I _ { 1 } \times I _ { 2 } \times \dots \times I _ { N } }$ , can be decomposed into a sum of $R$ rank-1 tensors, known as the Canonical-Polyadic decomposition, where $R$ is the rank of the decomposition. Its purpose is to find vectors u(1)k , u(2)k , · $\mathbf { u } _ { k } ^ { ( 1 ) } , \mathbf { u } _ { k } ^ { \top { 2 } ) } , \cdots , \mathbf { u } _ { k } ^ { ( N ) }$ , for $k = [ 1 \ldots R ]$ , as well as a vector of weights
42
+
43
+ $\pmb { \lambda } \in \mathbb { R } ^ { R }$ such that:
44
+
45
+ $$
46
+ \mathcal { X } = \sum _ { k = 1 } ^ { R } \underbrace { \lambda _ { k } \mathbf { u } _ { k } ^ { ( 1 ) } \circ \mathbf { u } _ { k } ^ { ( 2 ) } \circ \cdot \cdot \cdot \circ \mathbf { u } _ { k } ^ { ( N ) } } _ { \mathrm { r a n k - 1 ~ c o m p o n e n t s } }
47
+ $$
48
+
49
+ Tucker decomposition. A tensor $\mathcal { X } \in \mathbb { R } ^ { I _ { 1 } \times I _ { 2 } \times \dots \times I _ { N } }$ , can be decomposed into a low rank approximation including a core $\mathcal { G } \in \mathbb { R } ^ { R _ { 1 } \times R _ { 2 } \times \cdots \times R _ { N } }$ and a set of projection factors $\big ( \mathbf { U } ^ { ( 0 ) } , \cdots , \mathbf { U } ^ { ( \bar { N } - 1 ) } \big )$ , with $\mathbf { U } ^ { ( k ) } \in \mathbb { R } ^ { R _ { k } , \hat { I } _ { k } } , k \in \left( 0 , \cdots , N - 1 \right)$ that, when projected along the corresponding dimension of the core, reconstruct the full tensor $\mathcal { X }$ . The tensor in its decomposed form can be written:
50
+
51
+ $$
52
+ \boldsymbol { \mathcal { X } } = \boldsymbol { \mathcal { G } } \times _ { 1 } \mathbf { U } ^ { ( 1 ) } \times _ { 2 } \mathbf { U } ^ { ( 2 ) } \times \cdots \times _ { N } \mathbf { U } ^ { ( N ) } = \left[ \boldsymbol { \mathcal { G } } ; \mathbf { U } ^ { ( 1 ) } , \cdots , \mathbf { U } ^ { ( N ) } \right]
53
+ $$
54
+
55
+ Tensor regression layer. For two tensors $\begin{array} { r l r l r l } { { \mathcal { X } } } & { { } } & { \in } & { { } } & { \mathbb { R } ^ { K _ { 1 } \times \cdots \times K _ { x } \times I _ { 1 } \times \cdots \times I _ { N } } } \end{array}$ and $\qquad \mathcal { V } \qquad \in$ $\mathbb { R } ^ { I _ { 1 } \times \dots \times I _ { N } \times L _ { 1 } \times \dots \times L _ { y } }$ , we denote by $\begin{array} { r l r } { \langle { \mathcal X } , { \mathcal y } \rangle _ { N } } & { { } \in } & { \mathbb { R } ^ { K _ { 1 } \times \cdots \times K _ { x } \times L _ { 1 } \times \cdots \times L _ { y } } } \end{array}$ the contraction of $\mathcal { X }$ by $\mathcal { V }$ along their $N$ last modes; their generalized inner product is
56
+
57
+ $$
58
+ \langle \mathcal { X } , \mathcal { Y } \rangle _ { N } = \sum _ { i _ { 1 } = 1 } ^ { I _ { 1 } } \sum _ { i _ { 2 } = 1 } ^ { I _ { 2 } } \cdots \sum _ { i _ { n } = 1 } ^ { I _ { N } } \mathcal { X } _ { \ldots , i _ { 1 } , i _ { 2 } , \ldots , i _ { n } } \mathcal { Y } _ { i _ { 1 } , i _ { 2 } , \ldots , i _ { n } , \ldots }
59
+ $$
60
+
61
+ This makes it possible to define a tensor regression layer (Kossaifi et al., 2017b) that is differentiable and learnable end-to-end by gradient descent. Let us denote by $\mathcal { X } ~ \in ~ \mathbb { R } ^ { I _ { 1 } \times I _ { 2 } \times \dots \times I _ { N } }$ the input activation tensor for a sample and $\mathbf { y } \in \mathbb { R } ^ { I _ { N } }$ the label vector. A tensor regression layer estimates the regression weight tensor $\mathcal { W } \in { \dot { \mathbb { R } } } ^ { I _ { 1 } \times I _ { 2 } \times \dots \times I _ { N } }$ under a low-rank decomposition. In the case of a Tucker decomposition (as per our experiments) with ranks $( R _ { 1 } , \cdots , R _ { N } )$ , we have :
62
+
63
+ $$
64
+ \mathbf { y } = \langle \mathcal { X } , \mathcal { W } \rangle _ { N } + \mathbf { b } \qquad \mathrm { w i t h } \ \mathcal { W } = \mathcal { G } \times _ { 1 } \mathbf { U } ^ { ( 1 ) } \times _ { 2 } \mathbf { U } ^ { ( 2 ) } \cdot \cdot \cdot \times _ { N } \mathbf { U } ^ { ( N ) }
65
+ $$
66
+
67
+ as $\mathcal { G } \in \mathbb { R } ^ { R _ { 1 } \times \cdots \times R _ { N } }$ , $\mathbf { U } ^ { ( k ) } \in \mathbb { R } ^ { I _ { k } \times R _ { k } }$ for each $k$ in $[ 1 \ldots N ]$ and ${ \bf U } ^ { ( N ) } \in \mathbb { R } ^ { 1 \times R _ { N } }$
68
+
69
+ # 2.3 WAVELET SCATTERING
70
+
71
+ The wavelet scattering transform was originally introduced by Mallat (2011) and Bruna & Mallat (2012) as a non-linear extension to the classical wavelet filter bank decomposition. Its principle is as follows. Denoting by $x \circledast y [ n ]$ the 2-dimensional, circular convolution of two signals $x [ n ]$ and $y [ n ]$ , let us assume that we have pre-defined two wavelet filter banks available $\left\{ \psi _ { \lambda _ { 1 } } ^ { ( 1 ) } [ n ] \right\} _ { \lambda _ { 1 } \in \Lambda _ { 1 } }$ ¶ψ(2)λ2 [n]©λ2∈Λ2 , with $\lambda _ { 1 }$ and $\lambda _ { 2 }$ two frequency indices. These wavelet filters correspond to high frequencies, so we also give ourselves the data of a lowpass filter $\phi _ { J } [ n ]$ . Finally, and by opposition to traditional linear wavelet transforms, we also assume a given nonlinearity $\rho ( t )$ . Then the scattering transform is given by coefficients of order 0,1, and 2, respectively :
72
+
73
+ $$
74
+ \begin{array} { r l } { S _ { 0 } x [ n ] = x \circledast \phi _ { J } [ n ] } & { } \\ { S _ { 1 } x \left[ n , \lambda _ { 1 } \right] = \rho \left( x \circledast \psi _ { \lambda _ { 1 } } ^ { ( 1 ) } \right) \circledast \phi _ { J } [ n ] } & { \lambda _ { 1 } \in \Lambda _ { 1 } } \\ { S _ { 2 } x \left[ n , \lambda _ { 1 } , \lambda _ { 2 } \right] = \rho \left( \rho \left( x \circledast \psi _ { \lambda _ { 1 } } ^ { ( 1 ) } \right) \circledast \psi _ { \lambda _ { 2 } } ^ { ( 2 ) } \right) \circledast \phi _ { J } [ n ] } & { \lambda _ { 1 } \in \Lambda _ { 1 } , \lambda _ { 2 } \in \Lambda _ { 2 } \left( \lambda _ { 1 } \right) } \end{array}
75
+ $$
76
+
77
+ This can effectively be understood and implemented as a two-layer convolutional neural network whose weights are not learned but rather frozen and given by the coefficients of wavelets $\psi$ and $\phi$ (with Gabor filters as a special case (Mallat, 1998)). The difference with traditional filter banks comes from the iterated modulus/nonlinear activation function applied at each stage, much like in traditional deep learning convolutional neural networks. The generic mathematical definition involves order $n$ iterated scatterings, in the vein of $S _ { i } x$ above, but sometimes restricts nonlinearity $\rho$ to be a modulus function $| \cdot |$ . In practice, the potential of scattering transforms to accelerate learning by providing ready-made convolutional layers has been investigated in Oyallon et al. (2013) and Oyallon et al. (2018) and is a subject of active ongoing research. Scattering will be the second of our weight-saving methods.
78
+
79
+ # 2.4 SECOND ORDER OPTIMIZATION WITH K-FAC
80
+
81
+ While stochastic gradient descent is usually performed purely from gradient observations derived from auto-differentiation, faster, second order optimization methods first multiply the weights’ $\theta$ gradient vector $\nabla _ { \theta }$ by a preconditioning matrix, yielding the weight update $\theta _ { n + 1 } \dot { ~ } \dot { ~ } \dot { ~ } \theta _ { n } - \eta \dot { G } _ { n } ^ { - 1 } \nabla _ { \theta }$ with $\eta$ a step size. In the case of second order methods, the matrix $G _ { n } ^ { - 1 }$ is chosen to act as a tractable iterative approximation to the inverse Hessian or Empirical Fisher Information Matrix (Amari, 1998) of the neural network model in question. Kronecker-factored approximate curvature or K-FAC (Martens $\&$ Grosse, 2015) enforces a Kronecker decomposition of the type $G = A \otimes B$ , with $A$ and $B$ being smaller, architecture-dependent matrices. Unlike the above methods, K-FAC has been applied as a plug-in in the deep RL literature and shown to promote both anytime convergence properties as well as terminal accuracies (Wu et al., 2017).
82
+
83
+ # 3 OBSERVATIONS AND METHODS
84
+
85
+ # 3.1 EXPLORING TRAINED AGENTS
86
+
87
+ Stability of trained dense layers eigenvalues. In order to assess experimentally if tensor factorization can make sense in RL, we investigate the eigenvalues of the dense layers of a deep RL agent. Unlike the traditional supervised learning setting, the input data distribution to RL function approximators shifts as the agent explores its environment; as such, concentration properties of the eigenvalues of the linear layers cannot be guaranteed all the way throughout training. Since conditioning techniques such as batch normalization (Ioffe & Szegedy, 2015) are rarely used in deep RL, this is all the more important. Our experiments (see figure 1) show that the distribution of eigenvalues does not seem to widen significantly, at least during the initial phases of training we care about.
88
+
89
+ ![](images/d826828170c81e9f5a1a15742e69a5c084866508b1063b03fdc87d497398593d.jpg)
90
+ Figure 1: Eigenvalue histograms of the value-based linear layer during training. 50 agent runs dataefficient Rainbow (van Hasselt et al., 2019), of 100,000 steps on the Atari game Road Runner.
91
+
92
+ Furthermore and interestingly, it does not seem to deviate significantly from the one observed at initialization. All together, this suggests there might be some merit in learning low-rank policies.
93
+
94
+ # 3.2 ARCHITECTURAL MODIFICATIONS
95
+
96
+ Baseline. We then proceed to build upon the well-known Rainbow algorithm (Hessel et al., 2017). Rainbow uses a fairly standard shallow convolutional architecture like the seminal DQN paper of Mnih et al. (2013), and is an oft-cited baseline on the Atari suite. In spite of its performance, Rainbow often requires dozens of millions of a single game’s frames in order to perform well. Very recently, a ’data-efficient’ efficient version of Rainbow has been proposed by van Hasselt et al. (2019), with a view to match or beat the latest state-of-the-art results achieved by model-based RL methods. This is achieved with no major change in network architecture, but via a selection of mildly handtuned hyperparameters favouring efficiency against wall-clock running time (see appendix). We do take this as a baseline.
97
+
98
+ ![](images/30c60fbe868b4c678893e7e1101c5672ec51057da5085e6818f907a8a7ac506f.jpg)
99
+ Figure 2: Our architectural approach consists in replacing hidden layers in deep RL agents with tensor regression (top). Optionally we substitute the topmost convolutional layer with scattering (middle), and combine both methods (bottom).
100
+
101
+ Changes. We modify the architecture of the neural network function approximators used, in accordance with the principles described above, combining them to reflect inductive biases promoting fewer learnable parameters:
102
+
103
+ • We replace the fully-connected, linear layers used in Rainbow and data-efficient Rainbow with tensor regression layers (Kossaifi et al., 2017b) in order to learn low-rank policies (ranks in appendix). We use either the K-FAC second order stochastic optimizer, or the standard ADAM optimizer (Kingma & Ba, 2014). Optimization with K-FAC yields better results ceteris paribus and therefore works to counter performance loss due to using fewer weights. We combine the two methods with various rank (and therefore weight compression) ratios, targetting sensible compression ratios guided by deep learning intuition; and evaluate those on the same subset of Atari games as both van Hasselt et al. (2019); Kaiser et al. (2019). When possible, we replace the first convolutional layer in the approximating neural network with a scattering layer for further gains in terms of learnable weights. In that way, we investigate the impact of not actually learning one of the convolutional layer weights. Deep RL, paradoxically, tends to use shallow network architectures with two or three convolutional layers only, which makes it very fit for scattering methods. But since learned convolutional features discriminate well between high and low rewards, the promise of fully unsupervised scattering layers seems remote, without resorting to further ad-hoc methods like dictionary learning. Therefore we limit ourselves to one-step (one single layer) scatterings.
104
+
105
+ This is illustrated in figure 2. We then proceed to evaluate the merit of these changes.
106
+
107
+ # 4 EXPERIMENTAL RESULTS
108
+
109
+ # 4.1 PRIORITIZED TENSORIZED DQN
110
+
111
+ Proof of concept. We begin with showing proof of concept on the simple Pong Atari game. Our experimental setup consists in our own implementation of prioritized double DQN as a baseline (Schaul et al., 2015; van Hasselt et al., 2015). We replaced the densely connected layer of the original DQN architecture with a tensor regression layer implementing Tucker decomposition for different Tucker ranks, yielding different network compression factors.
112
+
113
+ Qualitative behaviour. First results, both in terms of learning performance and compression factor, can be seen in figure 3. Our two main findings are that first, the final performance of the agent remains unaffected by the tensor factorization, even with high compression rates - with respect to all network weights - of five times. In line with intuition, larger compression rates do however cause more delays in learning. Second, tensor factorization negatively affects stability during training - in tough compression regimes, the plateauing phases of learning curves feature occasional noisy drawdowns, illustrating the increased difficulty of learning, as seen in figure 4. Interestingly, approximation errors incurred by tensor regression noise do sometimes have poor consequences illustrated by those drawdowns, but overall seem to behave as additional exploration noise.
114
+
115
+ ![](images/aaaf6d5635b0bcb3fa1ae458b3489386aabe09bd71f45a1dbbd5b621bab9c01d.jpg)
116
+
117
+ ![](images/dd715b648e622ef26f5e95877b017a1ef30acc7687ff01a10af7360be1fb7c6d.jpg)
118
+ Figure 3: Prioritized tensorized DQN on Atari Pong. Original learning curve versus several learning curves for five different Tucker ranks factorizations and therefore parameter compression rates (3 different random seeds each, with a 30 episodes moving average for legibility). Best viewed in colour.
119
+ Figure 4: Focus on a typical single run of the tensorized DQN learning (score vs. number of thousand episodes). The overall shape of the typical learning curve is preserved, but drawdowns in the plateauing phase do appear.
120
+
121
+ # 4.2 DATA-EFFICIENT RAINBOW ON ATARI
122
+
123
+ Evaluation protocol. For all our Atari experiments, we used OpenAI Gym (Brockman et al., 2016), and a combination of PyTorch (Paszke et al., 2017), TensorLy (Kossaifi et al., 2016) and Kymatio (Andreux et al., 2018) for auto-differentiation. We evaluated our agents in the low-data regime of
124
+
125
+ 100,000 steps, on half the games, with 3 different random seeds for reproducibility (Henderson et al., 2017), taking the data-efficient Rainbow agent (van Hasselt et al., 2019) as our baseline. Our specific hyperparameters are described in appendix. We report our results in tables 1 and 2.
126
+ Table 1: Mean episode returns as reported in baselines SimPLe (Kaiser et al., 2019) and data-efficient Rainbow (van Hasselt et al., 2019), versus our agents, on 26 Atari games. ’Denoised’ is the NoisyNet ablation of Rainbow; ’TRL’ shows the performance of the data-efficient Rainbow with tensor regression layers substituted for linear ones.
127
+
128
+ <table><tr><td>Game</td><td>SimPLe</td><td>Rainbow</td><td>Denoised</td><td>TRL 2.5x</td><td>TRL 5x</td><td>TRL 10x</td></tr><tr><td>alien</td><td>405</td><td>740</td><td>684</td><td>688</td><td>454</td><td>566</td></tr><tr><td>amidar</td><td>88</td><td>189</td><td>154</td><td>118</td><td>86</td><td>84</td></tr><tr><td>assault</td><td>369</td><td>431</td><td>321</td><td>543</td><td>521</td><td>513</td></tr><tr><td>asterix</td><td>1090</td><td>471</td><td>500</td><td>459</td><td>554</td><td>363</td></tr><tr><td>bank_heist</td><td>8</td><td>51</td><td>77</td><td>59</td><td>134</td><td>42</td></tr><tr><td>battle_zone</td><td>5184</td><td>10125</td><td>9378</td><td>14466</td><td>13466</td><td>5744</td></tr><tr><td>boxing</td><td>9</td><td>0.2</td><td>1</td><td>-2</td><td>-2</td><td>-5</td></tr><tr><td>breakout</td><td>13</td><td>2</td><td>3</td><td>2</td><td>2</td><td>4</td></tr><tr><td>chopper_command</td><td>1247</td><td>862</td><td>1293</td><td>1255</td><td>1243</td><td>1106</td></tr><tr><td>crazy_climber</td><td>39828</td><td>16185</td><td>9977</td><td>3928</td><td>4225</td><td>2340</td></tr><tr><td>demon_attack</td><td>170</td><td>508</td><td>450</td><td>362</td><td>263</td><td>175</td></tr><tr><td>freeway</td><td>20</td><td>28</td><td>28</td><td>26</td><td>25</td><td>24</td></tr><tr><td>frostbite</td><td>255</td><td>867</td><td>1101</td><td>659</td><td>912</td><td>231</td></tr><tr><td>gopher</td><td>771</td><td>349</td><td>391</td><td>278</td><td>255</td><td>396</td></tr><tr><td>hero</td><td>1295</td><td>6857</td><td>3013</td><td>5351</td><td>3732</td><td>3321</td></tr><tr><td> jamesbond</td><td>125</td><td>302</td><td>295</td><td>215</td><td>213</td><td>218</td></tr><tr><td>kangaroo</td><td>323</td><td>779</td><td>1002</td><td>804</td><td>715</td><td>400</td></tr><tr><td>krull</td><td>4540</td><td>2852</td><td>2656</td><td>2333</td><td>2275</td><td>2308</td></tr><tr><td>kung_fu_master</td><td>17257</td><td>14346</td><td>4037</td><td>9392</td><td>4764</td><td>4031</td></tr><tr><td>ms_pacman</td><td>763</td><td>1204</td><td>1053</td><td>818</td><td>838</td><td>517</td></tr><tr><td>pong</td><td>5</td><td>-19</td><td>-20</td><td>-20</td><td>-19</td><td>-21</td></tr><tr><td>private_eye</td><td>58</td><td>98</td><td>100</td><td>51</td><td>100</td><td>1128</td></tr><tr><td>qbert</td><td>560</td><td>1153</td><td>672</td><td>697</td><td>581</td><td>733</td></tr><tr><td>road_runner</td><td>5169.4</td><td>9600</td><td>5426</td><td>6965</td><td>3914</td><td>1319</td></tr><tr><td>seaquest</td><td>371</td><td>354</td><td>387</td><td>345</td><td>350</td><td>287</td></tr><tr><td>up_n_down</td><td>2153</td><td>2877</td><td>5123</td><td>2197</td><td>2302</td><td>2179</td></tr><tr><td colspan="2">Average (vs.Rainbow)</td><td>100%</td><td>118%</td><td>96%</td><td>90%</td><td>71%</td></tr></table>
129
+
130
+ Table 1 shows proof of concept of the online learning of low-rank policies, with a loss of final performance varying in proportion to the compression in the low-rank linear layers, very much like in the deep learning literature (Kossaifi et al., 2017a;b). The number of coefficients in the original data-efficient Rainbow is of the order of magnitude of 1M and varies depending on the environment and its action-space size. The corresponding tensor regression layer ranks are in appendix, and chosen to target 400k, 200k and $1 0 0 \mathrm { k }$ coefficients respectively. While individual game results tend to decrease monotonously with increasing compression, we observe that they are noisy due to the nature of exploration in RL, and average scores reported correspond to the intuition that performance seems to decrease fast after a certain overparameterization threshold is crossed. To take this noisy character into account, we take care to be conservative and report the average of the final three episodes of the learned policy after 80k, 90k and $1 0 0 \mathrm { k }$ steps, respectively.
131
+
132
+ Denoised baseline. So as to not muddy the discussion and provide fair baselines, we do report on the NoisyNet (Fortunato et al., 2017) ablation of Rainbow (’Denoised’ columns), as the NoisyLinear layer doubles up the number of coefficients required and actually performs worse in our experiments. Its principle is that the variance of exploration noise represents a criticial tradeoff for performance (too little and one stalls, too much and one risks catastrophic updates), so it is sensible to treat it as a parameter to learn. However, in order to decouple both factors of overparametrization and exploration in the discussion of deep RL performance, we simply use a fixed exploration schedule. This denoised exploration baseline is an ablation we can then compare our tensorized methods to.
133
+
134
+ Second-order optimization. We then proceed to assess the impact of second-order optimization in architecture by substituting ADAM optimization for K-FAC, and introducing scattering, in table 2. In spite of our conservative reporting, the efficiency boost from using a second order scheme more than makes up for low-rank approximation error ( $109 \%$ performance) with five times less coefficients than van Hasselt et al. (2019), and learning with a full order of magnitude less coefficients $9 8 \%$ performance) is made possible by the combination of K-FAC and TRL. The results however do show a sharp drop in average performance when scattering is added. Interestingly enough some games perform relatively very well with that method, simultaneously showing proof of viability and of additional work required.
135
+
136
+ Table 2: Mean episode returns of our low-rank agents with second-order optimization and scattering. The Scattering column also includes KFAC optimization and TRL 5x, resulting in around $1 0 \mathrm { x }$ total weights efficiency gains.
137
+
138
+ <table><tr><td>Game</td><td>KFAC+Denoised</td><td>KFAC+TRL5x</td><td>KFAC+TRL10x</td><td>Scattering</td></tr><tr><td>alien</td><td>996</td><td>734</td><td>643</td><td>441</td></tr><tr><td>amidar</td><td>163</td><td>101</td><td>98</td><td>84</td></tr><tr><td>assault</td><td>501</td><td>491</td><td>496</td><td>434</td></tr><tr><td>asterix</td><td>537</td><td>549</td><td>526</td><td>502</td></tr><tr><td>bank_heist</td><td>100</td><td>73</td><td>57</td><td>29</td></tr><tr><td>battle_zone</td><td>8622</td><td>15178</td><td>6156</td><td>4311</td></tr><tr><td>boxing</td><td>0</td><td>-4</td><td>-1</td><td>-9</td></tr><tr><td>breakout</td><td>3</td><td>3</td><td>2</td><td>2</td></tr><tr><td>chopper_command</td><td>692</td><td>611</td><td>1302</td><td>441</td></tr><tr><td>crazy_climber</td><td>14242</td><td>12377</td><td>3546</td><td>740</td></tr><tr><td>demon_attack</td><td>582</td><td>434</td><td>318</td><td>692</td></tr><tr><td>freeway</td><td>26</td><td>26</td><td>24</td><td>19</td></tr><tr><td>frostbite</td><td>1760</td><td>718</td><td>1483</td><td>654</td></tr><tr><td>gopher</td><td>363</td><td>341</td><td>265</td><td>172</td></tr><tr><td>hero</td><td>4188</td><td>6284</td><td>4206</td><td>4127</td></tr><tr><td> jamesbond</td><td>263</td><td>327</td><td>217</td><td>48</td></tr><tr><td>kangaroo</td><td>2085</td><td>613</td><td>588</td><td>391</td></tr><tr><td>krull</td><td>2855</td><td>3441</td><td>3392</td><td>772</td></tr><tr><td>kung_fu_master</td><td>8481</td><td>10738</td><td>7357</td><td>233</td></tr><tr><td>ms-pacman</td><td>1137</td><td>920</td><td>867</td><td>613</td></tr><tr><td>pong</td><td>-19.3</td><td>-19</td><td>-19</td><td>-20</td></tr><tr><td>private_eye</td><td>56</td><td>100</td><td>100</td><td>0</td></tr><tr><td>qbert</td><td>731</td><td>520</td><td>538</td><td>475</td></tr><tr><td>road_runner</td><td>4516</td><td>8493</td><td>7224</td><td>1278</td></tr><tr><td>seaquest</td><td>349</td><td>317</td><td>520</td><td>213</td></tr><tr><td>up_n_down</td><td>2557</td><td>2291</td><td>2108</td><td>993</td></tr><tr><td>Average (vs.Rainbow)</td><td>114%</td><td>109%</td><td>98%</td><td>55%</td></tr></table>
139
+
140
+ # 5 CONCLUSION
141
+
142
+ We have demonstrated that in the low-data regime, it is possible to leverage biologically plausible characterizations of experience data (namely low-rank properties and wavelet scattering separability) to exhibit architectures that learn policies with an order of magnitude less weights than current state-of-the-art baselines, essentially without loss of performance, and in an online fashion. In particular, this provides a compelling alternative to methods like policy distillation (Rusu et al., 2015; Czarnecki et al., 2019). We do hope that this will lead to even further progress towards sample efficiency and speedy exploration methods. Further work will, first, focus on thorough evaluation and research of scattering architectures in order to achieve further gains, and second investigate additional, orthogonal biologically-friendly research directions such as promoting sparsity via, for instance, $L ^ { 1 }$ regularization. Finally, we are excited by the potential of tensor factorization to offer shared core tensors for policies in multi-task and meta-learning.
143
+
144
+ # REFERENCES
145
+
146
+ Shunichi Amari. Natural gradient works efficiently in learning. Neural Computation, 10:251–276, 1998.
147
+
148
+ M. Andreux, T. Angles, G. Exarchakis, R. Leonarduzzi, G. Rochette, L. Thiry, J. Zarka, S. Mallat, J. anden, E. Belilovsky, J. Bruna, V. Lostanlen, M. J. Hirn, E. Oyallon, S. Zhang, C. Cella, and ´ M. Eickenberg. Kymatio: Scattering Transforms in Python. arXiv e-prints, December 2018.
149
+
150
+ M. G. Bellemare, W. Dabney, and R. Munos. A Distributional Perspective on Reinforcement Learning. arXiv e-prints, July 2017.
151
+
152
+ C. Blundell, B. Uria, A. Pritzel, Y. Li, A. Ruderman, J. Z Leibo, J. Rae, D. Wierstra, and D. Hassabis. Model-Free Episodic Control. arXiv e-prints, June 2016.
153
+
154
+ G. Brockman, V. Cheung, L. Pettersson, J. Schneider, J. Schulman, J. Tang, and W. Zaremba. OpenAI Gym. arXiv e-prints, June 2016.
155
+
156
+ J. Bruna and S. Mallat. Invariant Scattering Convolution Networks. arXiv e-prints, March 2012.
157
+
158
+ S. Chung, D. D. Lee, and H. Sompolinsky. Linear readout of object manifolds. , 93(6):060301, June 2016. doi: 10.1103/PhysRevE.93.060301.
159
+
160
+ S. Chung, D. D. Lee, and H. Sompolinsky. Classification and Geometry of General Perceptual Manifolds. Physical Review X, 8(3):031003, July 2018. doi: 10.1103/PhysRevX.8.031003.
161
+
162
+ Andrzej Cichocki, Rafal Zdunek, Anh Huy Phan, and Sh. Amari. Nonnegative Matrix and Tensor Factorizations - Applications to Exploratory Multi-way Data Analysis and Blind Source Separation. 2009.
163
+
164
+ G. Cuccu, J. Togelius, and P. Cudre-Mauroux. Playing Atari with Six Neurons. arXiv e-prints, June 2018.
165
+
166
+ W. M. Czarnecki, R. Pascanu, S. Osindero, S. M. Jayakumar, G. Swirszcz, and M. Jaderberg. Distilling Policy Distillation. arXiv e-prints, February 2019.
167
+
168
+ M. Eickenberg, G. Exarchakis, M. Hirn, S. Mallat, and L. Thiry. Solid harmonic wavelet scattering for predictions of molecule properties. , 148(24):241732, June 2018. doi: 10.1063/1.5023798.
169
+
170
+ M. Fortunato, M. Gheshlaghi Azar, B. Piot, J. Menick, I. Osband, A. Graves, V. Mnih, R. Munos, D. Hassabis, O. Pietquin, C. Blundell, and S. Legg. Noisy Networks for Exploration. arXiv e-prints, June 2017.
171
+
172
+ A. Gaier and D. Ha. Weight Agnostic Neural Networks. arXiv e-prints, June 2019.
173
+
174
+ P. Henderson, R. Islam, P. Bachman, J. Pineau, D. Precup, and D. Meger. Deep Reinforcement Learning that Matters. arXiv e-prints, September 2017.
175
+
176
+ M. Hessel, J. Modayil, H. van Hasselt, T. Schaul, G. Ostrovski, W. Dabney, D. Horgan, B. Piot, M. Azar, and D. Silver. Rainbow: Combining Improvements in Deep Reinforcement Learning. arXiv e-prints, October 2017.
177
+
178
+ Aapo Hyvarinen and Patrik O. Hoyer. A two-layer sparse coding model learns simple and complex¨ cell receptive fields and topography from natural images. Vision Research, 41:2413–2423, 2001.
179
+
180
+ S. Ioffe and C. Szegedy. Batch Normalization: Accelerating Deep Network Training by Reducing Internal Covariate Shift. arXiv e-prints, February 2015.
181
+
182
+ Jeffrey P. Jones and Larry A. Palmer. An evaluation of the two-dimensional gabor filter model of simple receptive fields in cat striate cortex. Journal of neurophysiology, 58 6:1233–58, 1987.
183
+
184
+ L. Kaiser, M. Babaeizadeh, P. Milos, B. Osinski, R. H Campbell, K. Czechowski, D. Erhan, C. Finn, P. Kozakowski, S. Levine, A. Mohiuddin, R. Sepassi, G. Tucker, and H. Michalewski. ModelBased Reinforcement Learning for Atari. arXiv e-prints, March 2019.
185
+
186
+ D. P. Kingma and J. Ba. Adam: A Method for Stochastic Optimization. arXiv e-prints, December 2014.
187
+ J. Kossaifi, Y. Panagakis, A. Anandkumar, and M. Pantic. TensorLy: Tensor Learning in Python. arXiv e-prints, October 2016.
188
+ J. Kossaifi, A. Khanna, Z. C. Lipton, T. Furlanello, and A. Anandkumar. Tensor Contraction Layers for Parsimonious Deep Nets. arXiv e-prints, June 2017a.
189
+ J. Kossaifi, Z. C. Lipton, A. Khanna, T. Furlanello, and A. Anandkumar. Tensor Regression Networks. arXiv e-prints, July 2017b.
190
+ S. Mallat. Group Invariant Scattering. arXiv e-prints, January 2011.
191
+ Stephane Mallat. ´ A Wavelet Tour of Signal Processing. 1998.
192
+ James Martens and Roger B. Grosse. Optimizing neural networks with kronecker-factored approximate curvature. ArXiv, abs/1503.05671, 2015.
193
+ V. Mnih, K. Kavukcuoglu, D. Silver, A. Graves, I. Antonoglou, D. Wierstra, and M. Riedmiller. Playing Atari with Deep Reinforcement Learning. arXiv e-prints, December 2013.
194
+ Bruno A. Olshausen and David J. Field. Emergence of simple-cell receptive field properties by learning a sparse code for natural images. Nature, 381:607–609, 1996.
195
+ Bruno A. Olshausen and David J. Field. Sparse coding with an overcomplete basis set: A strategy employed by v1? Vision Research, 37:3311–3325, 1997.
196
+ E. Oyallon, S. Mallat, and L. Sifre. Generic Deep Networks with Wavelet Scattering. arXiv e-prints, December 2013.
197
+ E. Oyallon, S. Zagoruyko, G. Huang, N. Komodakis, S. Lacoste-Julien, M. Blaschko, and E. Belilovsky. Scattering Networks for Hybrid Representation Learning. arXiv e-prints, September 2018.
198
+ Adam Paszke, Sam Gross, Soumith Chintala, Gregory Chanan, Edward Yang, Zachary DeVito, Zeming Lin, Alban Desmaison, Luca Antiga, and Adam Lerer. Automatic differentiation in pytorch. 2017.
199
+ A. Pritzel, B. Uria, S. Srinivasan, A. Puigdomenech, O. Vinyals, D. Hassabis, D. Wierstra, and \` C. Blundell. Neural Episodic Control. arXiv e-prints, March 2017.
200
+ A. A. Rusu, S. Gomez Colmenarejo, C. Gulcehre, G. Desjardins, J. Kirkpatrick, R. Pascanu, V. Mnih, K. Kavukcuoglu, and R. Hadsell. Policy Distillation. arXiv e-prints, November 2015.
201
+ T. Schaul, J. Quan, I. Antonoglou, and D. Silver. Prioritized Experience Replay. arXiv e-prints, November 2015.
202
+ Richard S. Sutton and Andrew G. Barto. Reinforcement Learning: An Introduction. The MIT Press, second edition, 2018. URL http://incompleteideas.net/book/the-book-2nd. html.
203
+ H. van Hasselt, A. Guez, and D. Silver. Deep Reinforcement Learning with Double Q-learning. arXiv e-prints, September 2015.
204
+ H. van Hasselt, M. Hessel, and J. Aslanides. When to use parametric models in reinforcement learning? arXiv e-prints, June 2019.
205
+ R. Wang, C. Ciliberto, P. Amadori, and Y. Demiris. Random Expert Distillation: Imitation Learning via Expert Policy Support Estimation. arXiv e-prints, May 2019.
206
+ Z. Wang, T. Schaul, M. Hessel, H. van Hasselt, M. Lanctot, and N. de Freitas. Dueling Network Architectures for Deep Reinforcement Learning. arXiv e-prints, November 2015.
207
+ Y. Wu, E. Mansimov, S. Liao, R. Grosse, and J. Ba. Scalable trust-region method for deep reinforcement learning using Kronecker-factored approximation. arXiv e-prints, August 2017.
208
+ C. Zhang, S. Bengio, M. Hardt, B. Recht, and O. Vinyals. Understanding deep learning requires rethinking generalization. arXiv e-prints, November 2016.
209
+
210
+ # A APPENDIX
211
+
212
+ HYPERPARAMETERS AND REPRODUCIBILITY
213
+
214
+ Hyperparameters are as follows. First, our specific architecture-modified hyperparameters:
215
+
216
+ Table 3: Our additional, architecture-specific hyperparameters.
217
+
218
+ <table><tr><td>Specific architecture hyperparameters</td><td>Value</td></tr><tr><td>Scattering maximum log-scale J</td><td>3</td></tr><tr><td>Scattering volume width M</td><td>1</td></tr><tr><td>Scattering tensor input shape</td><td>(1,4,84,84)</td></tr><tr><td>Scattering tensor output shape</td><td>(1,16,11,11)</td></tr><tr><td>Scattering type</td><td>Harmonic 3D,see Andreux et al. (2018); Eickenberg et al. (2018)</td></tr><tr><td></td><td>128</td></tr><tr><td>Hidden linear layer rank constraint, 2.5x compression Final linear layer rank constraint, 2.5x compression</td><td>48</td></tr><tr><td>Hidden linear layer rank constraint,5x compression</td><td>32</td></tr><tr><td>Final linear layer rank constraint,5x compression</td><td>48</td></tr><tr><td>Hidden linear layer rank constraint,1Ox compression</td><td>16</td></tr><tr><td>Final linear layer rank constraint,1Ox compression</td><td>10</td></tr><tr><td>KFAC Tikhonov regularization parameter</td><td></td></tr><tr><td>KFAC Update frequency for inverses</td><td>0.1</td></tr><tr><td></td><td>100</td></tr></table>
219
+
220
+ Furthermore, we mirror the Data-Efficient Rainbow van Hasselt et al. (2019) baseline:
221
+ Table 4: Data-efficient Rainbow agent hyperparameters, as per van Hasselt et al. (2019).
222
+
223
+ <table><tr><td>Data-efficient Rainbow hyperparameters</td><td>Value</td></tr><tr><td>Grey-scaling</td><td>True</td></tr><tr><td>Observation down-sampling</td><td>(84,84)</td></tr><tr><td>Frames stacked</td><td>4</td></tr><tr><td>Action repetitions</td><td>4</td></tr><tr><td>Reward clipping</td><td>[-1, 1]</td></tr><tr><td>Terminal on loss of life</td><td>True</td></tr><tr><td>Max frames per episode</td><td>108K</td></tr><tr><td>Update</td><td>Distributional Double Q</td></tr><tr><td>Target network update period*</td><td>every 2000 updates</td></tr><tr><td>Support of Q-distribution</td><td>51 bins</td></tr><tr><td>Discount factor</td><td>0.99</td></tr><tr><td>Minibatch size</td><td>32</td></tr><tr><td>Optimizer</td><td>Adam</td></tr><tr><td>Optimizer: first moment decay</td><td>0.9</td></tr><tr><td>Optimizer: second moment decay</td><td>0.999</td></tr><tr><td>Optimizer: e</td><td>0.00015</td></tr><tr><td>Max gradient norm</td><td>10</td></tr><tr><td>Priority exponent</td><td>0.5</td></tr><tr><td>Priority correction**</td><td>0.4→1</td></tr><tr><td>Hardware</td><td>NVidia 1080TiGPU</td></tr><tr><td>Noisy nets parameter</td><td>0.1</td></tr><tr><td>Training frames</td><td>400,000</td></tr><tr><td>Min replay size for sampling</td><td>1600</td></tr><tr><td>Memory size</td><td>unbounded</td></tr><tr><td>Replay period every</td><td>1 steps</td></tr><tr><td>Multi-step return length</td><td>20</td></tr><tr><td>Q network:channels</td><td>32,64</td></tr><tr><td>Q network: filter size</td><td>5 5,5 5</td></tr><tr><td>Q network: stride</td><td>5,5</td></tr><tr><td>Q network: hidden units</td><td>256</td></tr><tr><td></td><td></td></tr><tr><td>Optimizer: learning rate</td><td>0.0001</td></tr></table>
224
+
225
+ Our codebase is available on request.
226
+
227
+ STANDARD DEVIATIONS FOR SCORE RUNS
228
+ Table 5: Standard deviations across seeds for runs presented Table 1.
229
+
230
+ <table><tr><td>Game</td><td>Denoised</td><td>TRL 2.5x</td><td>TRL 10x</td></tr><tr><td>alien</td><td>684±7</td><td>688 ±123</td><td>566±38</td></tr><tr><td>amidar</td><td>154 ± 21</td><td>118 ±12</td><td>84±15</td></tr><tr><td>assault</td><td>321 ± 224</td><td>543 ± 94</td><td>513± 64</td></tr><tr><td>asterix</td><td>500 ±124</td><td>459 ± 91</td><td>363 ± 66</td></tr><tr><td>bank_heist</td><td>77±23</td><td>59± 22</td><td>42±2</td></tr><tr><td>battle_zone</td><td>9378 ± 2042</td><td>14466 ± 2845</td><td>5744 ± 575</td></tr><tr><td>boxing</td><td>1±2</td><td>-2±1</td><td>-5±1</td></tr><tr><td>breakout</td><td>3 ±1.5</td><td>2±1</td><td>4±0.3</td></tr><tr><td>chopper_command</td><td>1293 ± 445</td><td>1255 ± 215</td><td>1106 ± 124</td></tr><tr><td>crazy_climber</td><td>9977 ± 3744</td><td>3928 ± 221</td><td>2340 ± 595</td></tr><tr><td>demon_attack</td><td>450 ± 49</td><td>362 ± 147</td><td>175±7</td></tr><tr><td>freeway</td><td>28 ±0.6</td><td>26±0</td><td>24 ± 0.5</td></tr><tr><td>frostbite</td><td>1101 ± 355</td><td>659 ± 523</td><td>231±1</td></tr><tr><td>gopher</td><td>391 ± 46</td><td>278 ±39</td><td>396 ± 24</td></tr><tr><td>hero</td><td>3013 ± 90</td><td>5351 ± 1948</td><td>3321 ± 598</td></tr><tr><td> jamesbond</td><td>295±57</td><td>215 ±42</td><td>218 ±22</td></tr><tr><td>kangaroo</td><td>1002 ± 587</td><td>804 ± 289</td><td>400 ± 278</td></tr><tr><td>krull</td><td>2656 ± 180</td><td>2333 ± 309</td><td>2308 ± 268</td></tr><tr><td>kung_fu_master</td><td>4037 ± 2962</td><td>9392 ± 6289</td><td>4031 ± 3068</td></tr><tr><td>ms_pacman</td><td>1053 ±193</td><td>818 ±94</td><td>517 ±38</td></tr><tr><td>pong</td><td>-20 ± 0.4</td><td>-20±0</td><td>-21 ± 0.1</td></tr><tr><td>private_eye</td><td>100±0</td><td>51± 59</td><td>1128 ± 1067</td></tr><tr><td>qbert</td><td>672 ± 144</td><td>697 ± 78</td><td>733 ± 291</td></tr><tr><td>road_runner</td><td>5426 ± 2830</td><td>6965 ± 6569</td><td>1319± 216</td></tr><tr><td>seaquest</td><td>387 ± 24</td><td>345 ± 40</td><td>287±87</td></tr><tr><td>up_n_down</td><td>5123 ± 3146</td><td>2197 ± 231</td><td>2179 ±178</td></tr><tr><td>Game</td><td>KFAC+Denoised</td><td>KFAC+TRL10x</td><td>Scattering</td></tr><tr><td>alien</td><td>996 ± 180</td><td>643 ± 51</td><td>441 ± 90</td></tr><tr><td>amidar</td><td>163 ± 15</td><td>98 ±26</td><td>84 ±11</td></tr><tr><td>assault</td><td>501 ± 85</td><td>496 ±129</td><td>434±304</td></tr><tr><td>asterix</td><td>537 ± 96</td><td>526 ±64</td><td>502 ± 91</td></tr><tr><td>bank_heist</td><td>100 ±14</td><td>57 ± 36</td><td>29 ±13</td></tr><tr><td>battle_zone</td><td>8622 ± 5358</td><td>6156 ± 1951</td><td>4311 ± 1517</td></tr><tr><td>boxing</td><td>0±2</td><td>-1±3</td><td>-9 ±12</td></tr><tr><td>breakout</td><td>3±1</td><td>2±2</td><td>2±0</td></tr><tr><td>chopper_command</td><td>692 ± 81</td><td>1302 ± 328</td><td>441 ± 80</td></tr><tr><td>crazy_climber</td><td>14242 ± 2936</td><td>3546 ±1231</td><td>740 ± 291</td></tr><tr><td>demon_attack</td><td>582 ±130</td><td>318 ±168</td><td>92±232</td></tr><tr><td>freeway</td><td>26±0</td><td>24±0</td><td>19 ±1</td></tr><tr><td>frostbite</td><td>1760 ± 448</td><td>1483 ± 466</td><td>654 ± 709</td></tr><tr><td>gopher</td><td>363 ±4</td><td>265 ± 67</td><td>172 ±3</td></tr><tr><td>hero</td><td>4188 ±1635</td><td>4206 ±1862</td><td>4127 ±1074</td></tr><tr><td>jamesbond</td><td>263 ±22</td><td>217±68</td><td>48±10</td></tr><tr><td>kangaroo</td><td>2085 ± 2055</td><td>588±5</td><td>391±52</td></tr><tr><td>krull</td><td>2855 ± 156</td><td>3392 ± 2205</td><td>772± 560</td></tr><tr><td>kung_fu_master</td><td>8481 ± 8270</td><td>7357 ± 9200</td><td>233± 205</td></tr><tr><td>ms_pacman</td><td>1137 ± 180</td><td>867 ±128</td><td>613 ±159</td></tr><tr><td>pong</td><td>-19 ± 0.6</td><td>-19 ±1</td><td>-20±0</td></tr><tr><td>private_eye</td><td>56±42</td><td>100±0</td><td>0±0</td></tr><tr><td>qbert</td><td>731 ± 256</td><td>538 ±114</td><td>475 ± 161</td></tr><tr><td>road_runner</td><td>4516 ± 2869</td><td>7224±4598</td><td>1278 ±463</td></tr><tr><td>seaquest</td><td>349 ± 63</td><td>520 ±97</td><td>213 ±96</td></tr><tr><td>_n_down</td><td>2557 ± 641</td><td>2108 ± 298</td><td>993 ± 244</td></tr></table>
231
+
232
+ Table 6: Standard deviations across seeds for runs presented Table 2.
parse/train/B1l3M64KwB/B1l3M64KwB_content_list.json ADDED
@@ -0,0 +1,1081 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [
2
+ {
3
+ "type": "text",
4
+ "text": "HOW MANY WEIGHTS ARE ENOUGH : CAN TENSOR FACTORIZATION LEARN EFFICIENT POLICIES ? ",
5
+ "text_level": 1,
6
+ "bbox": [
7
+ 176,
8
+ 99,
9
+ 781,
10
+ 146
11
+ ],
12
+ "page_idx": 0
13
+ },
14
+ {
15
+ "type": "text",
16
+ "text": "Anonymous authors Paper under double-blind review ",
17
+ "bbox": [
18
+ 183,
19
+ 170,
20
+ 398,
21
+ 198
22
+ ],
23
+ "page_idx": 0
24
+ },
25
+ {
26
+ "type": "text",
27
+ "text": "ABSTRACT ",
28
+ "text_level": 1,
29
+ "bbox": [
30
+ 454,
31
+ 234,
32
+ 544,
33
+ 251
34
+ ],
35
+ "page_idx": 0
36
+ },
37
+ {
38
+ "type": "text",
39
+ "text": "Deep reinforcement learning requires a heavy price in terms of sample efficiency and overparameterization in the neural networks used for function approximation. In this work, we employ tensor factorization in order to learn more compact representations for reinforcement learning policies. We show empirically that in the low-data regime, it is possible to learn online policies with 2 to 10 times less total coefficients, with little to no loss of performance. We also leverage progress in second order optimization, and use the theory of wavelet scattering to further reduce the number of learned coefficients, by foregoing learning the topmost convolutional layer filters altogether. We evaluate our results on the Atari suite against recent baseline algorithms that represent the state-of-the-art in data efficiency, and get comparable results with an order of magnitude gain in weight parsimony. ",
40
+ "bbox": [
41
+ 233,
42
+ 270,
43
+ 766,
44
+ 422
45
+ ],
46
+ "page_idx": 0
47
+ },
48
+ {
49
+ "type": "text",
50
+ "text": "1 INTRODUCTION ",
51
+ "text_level": 1,
52
+ "bbox": [
53
+ 176,
54
+ 458,
55
+ 336,
56
+ 474
57
+ ],
58
+ "page_idx": 0
59
+ },
60
+ {
61
+ "type": "text",
62
+ "text": "The successes of reinforcement learning (thereafter ’RL’), and specifically deep RL, come at a heavy computational price. It is well known that achieving human-level performance in domains such as Atari (Sutton & Barto, 2018; Mnih et al., 2013; Hessel et al., 2017) requires hundreds of millions of frames of environment interaction. As such, the problem of sample efficiency in RL is of critical importance. Several tracks of concurrent research are being investigated, and have reduced by orders of magnitude the number of environment interactions required for good performance beyond the previous benchmark of biologically-inspired episodic control methods (Blundell et al., 2016; Pritzel et al., 2017) to a couple hours of human gameplay time (van Hasselt et al., 2019; Kaiser et al., 2019). ",
63
+ "bbox": [
64
+ 174,
65
+ 492,
66
+ 825,
67
+ 604
68
+ ],
69
+ "page_idx": 0
70
+ },
71
+ {
72
+ "type": "text",
73
+ "text": "However, while the data-efficiency of RL methods has seen recent drastic performance gains, the function approximators they use still require millions of learned weights, potentially still leaving them heavily overparameterized. Independently motivated by biological facts like the behavioural readiness of newborn animals, several authors (Gaier & Ha, 2019; Cuccu et al., 2018; Wang et al., 2019) have recently looked at doing away with learning so many weights for RL tasks. Smaller networks not only train faster, but may yet offer another avenue for gains in the form of better generalization (Zhang et al., 2016). Recent work from Gaier & Ha (2019) studies the effect of inductive bias of neural architectures in RL ; they forego training altogether, but transfer networks that only obtain ’better than chance performance on MNIST’. In similar fashion, Wang et al. (2019) investigate the effect of random projections in the restricted setting of imitation learning. Finally, Cuccu et al. (2018) manage human-level performance on the Atari suite using a separate dictionary learning procedure for their features, bypassing the usual end-to-end learning paradigm. The perspective of neural architecture search applied to RL appears difficult, if not computationally inextricable. ",
74
+ "bbox": [
75
+ 174,
76
+ 611,
77
+ 825,
78
+ 791
79
+ ],
80
+ "page_idx": 0
81
+ },
82
+ {
83
+ "type": "text",
84
+ "text": "Concurrently, the study of biologically-inspired models of learning has exhibited two mathematical characterizations that might be critical in explaining how biological learning takes place so efficiently. First, the low-rank properties of learned perceptual manifolds (Chung et al., 2018; 2016) are giving rise to a rich theory borrowing from statistical physics. Second, another well known line of work has identified Gabor filters, and more generally wavelet filter-like structures, in the actual visual cortex of animals (Jones & Palmer, 1987), and linked those to sparsity-promoting methods and dictionary learning (Olshausen & Field, 1996; 1997; Hyvarinen & Hoyer, 2001). But these ¨ breakthroughs have not, so far, been reflected as inductive priors in the shape of modifications in deep RL neural networks architectures, which remain fairly fixed on the Atari domain. ",
85
+ "bbox": [
86
+ 174,
87
+ 797,
88
+ 825,
89
+ 924
90
+ ],
91
+ "page_idx": 0
92
+ },
93
+ {
94
+ "type": "text",
95
+ "text": "Therefore the following questions remain: how parsimonious do function approximators in RL need to be, in order to maintain good performance? And can we be at once sample-efficient and weightefficient ? In this work, we turn to the mathematical theories of tensor factorization (Cichocki et al., 2009), second-order optimization (Amari, 1998; Martens & Grosse, 2015) and wavelet scattering (Mallat, 2011) to answer this question positively and empirically, in a model-free setting. ",
96
+ "bbox": [
97
+ 174,
98
+ 103,
99
+ 825,
100
+ 174
101
+ ],
102
+ "page_idx": 1
103
+ },
104
+ {
105
+ "type": "text",
106
+ "text": "We propose to use these methods in order to save weights and therefore favour convergence of policies: ",
107
+ "bbox": [
108
+ 171,
109
+ 180,
110
+ 825,
111
+ 209
112
+ ],
113
+ "page_idx": 1
114
+ },
115
+ {
116
+ "type": "text",
117
+ "text": "• We replace dense, fully-connected layers with tensor regression layers. • Optionally, we replace the topmost layer in the convolutional architecture with a scattering layer; the deeper convolutional layers are left untouched. • The (positive) impact of second-order optimization is also evaluated. ",
118
+ "bbox": [
119
+ 215,
120
+ 220,
121
+ 825,
122
+ 289
123
+ ],
124
+ "page_idx": 1
125
+ },
126
+ {
127
+ "type": "text",
128
+ "text": "To the best of our knowledge, this is the first time those fields have been combined together in this context, and that tensor factorization is applied to deep RL. ",
129
+ "bbox": [
130
+ 174,
131
+ 300,
132
+ 825,
133
+ 329
134
+ ],
135
+ "page_idx": 1
136
+ },
137
+ {
138
+ "type": "text",
139
+ "text": "2 BACKGROUND & RELATED WORK ",
140
+ "text_level": 1,
141
+ "bbox": [
142
+ 174,
143
+ 349,
144
+ 488,
145
+ 366
146
+ ],
147
+ "page_idx": 1
148
+ },
149
+ {
150
+ "type": "text",
151
+ "text": "2.1 DEEP REINFORCEMENT LEARNING ",
152
+ "text_level": 1,
153
+ "bbox": [
154
+ 176,
155
+ 381,
156
+ 457,
157
+ 396
158
+ ],
159
+ "page_idx": 1
160
+ },
161
+ {
162
+ "type": "text",
163
+ "text": "We consider the standard Markov Decision Process framework as in Sutton $\\&$ Barto (2018). This setting is characterised by a tuple $\\langle S , A , T , R , \\gamma \\rangle$ , where $S$ is a set of states, $A$ a set of actions, $R$ a reward function that is the immediate, intrinsic desirability of a certain state, $T$ a transition dynamics and $\\gamma \\in [ 0 , 1 ]$ a discount factor. The purpose of the RL problem is to to find a policy $\\pi$ , which represents a mapping from states to a probability distribution over actions, that is optimal, i.e., that maximizes the expected cumulative discounted return $\\scriptstyle \\sum _ { k = 0 } ^ { \\infty } \\gamma ^ { k } R _ { t + k + 1 }$ at each state $s _ { t } ~ \\in ~ S$ In Q-learning, the policy is given implicitly by acting greedily or $\\epsilon$ -greedily with respect to learned action-value functions $\\boldsymbol { q } ^ { \\pi } ( s , a )$ , that are learned following the Bellman equation. In deep $Q$ -learning, $q _ { \\theta }$ becomes parameterized by the weights $\\theta$ of a neural network and one minimizes the expected Bellman loss : ",
164
+ "bbox": [
165
+ 173,
166
+ 406,
167
+ 826,
168
+ 545
169
+ ],
170
+ "page_idx": 1
171
+ },
172
+ {
173
+ "type": "equation",
174
+ "img_path": "images/52f3d174bcd33725358cdab66032a6c0d48a23f697f9df60f2a13effc3f42d38.jpg",
175
+ "text": "$$\n\\mathbb { E } \\left( R _ { t + 1 } + \\gamma _ { t + 1 } \\operatorname* { m a x } _ { a ^ { \\prime } } q _ { \\theta } \\left( S _ { t + 1 } , a ^ { \\prime } \\right) - q _ { \\theta } \\left( S _ { t } , A _ { t } \\right) \\right) ^ { 2 }\n$$",
176
+ "text_format": "latex",
177
+ "bbox": [
178
+ 328,
179
+ 542,
180
+ 666,
181
+ 573
182
+ ],
183
+ "page_idx": 1
184
+ },
185
+ {
186
+ "type": "text",
187
+ "text": "In practice, this is implemented stochastically via uniform sampling of transitions in an experience replay buffer, as is done in the seminal paper Mnih et al. (2013). Several algorithmic refinements to that approach exist. First, Double Q-learning (van Hasselt et al., 2015) proposes to decouple learning between two networks in order to alleviate the Q-value overestimation problem. Second, dueling Q-networks (Wang et al., 2015) explicitly decompose the learning of an action-value function $q _ { \\theta } ( s , a )$ as the sum of an action-independent state-value, much like what is traditionally done in policy gradient methods (Sutton & Barto, 2018), implemented via a two-headed neural network architecture. Finally, prioritized RL (Schaul et al., 2015) proposes to replace the uniform sampling of transitions in the experience replay buffer with importance sampling, by prioritizing those transitions that present the most Bellman error (those transitions that are deemed the most ’surprising’ by the agent). Fortunato et al. (2017) use extra weights to learn the variance of the exploration noise in a granular fashion, while Bellemare et al. (2017) propose to learn a full distribution of action-values for each action and state. Combined, those methods form the basis of the Rainbow algorithm in Hessel et al. (2017). ",
188
+ "bbox": [
189
+ 173,
190
+ 577,
191
+ 826,
192
+ 772
193
+ ],
194
+ "page_idx": 1
195
+ },
196
+ {
197
+ "type": "text",
198
+ "text": "2.2 TENSOR FACTORIZATION ",
199
+ "text_level": 1,
200
+ "bbox": [
201
+ 174,
202
+ 789,
203
+ 388,
204
+ 803
205
+ ],
206
+ "page_idx": 1
207
+ },
208
+ {
209
+ "type": "text",
210
+ "text": "Here we introduce notations and concepts from the tensor factorization literature. An intuition is that the two main decompositions below, $C P$ and Tucker decompositions, can be understood as multilinear algebra analogues of SVD or eigendecomposition. ",
211
+ "bbox": [
212
+ 176,
213
+ 815,
214
+ 823,
215
+ 858
216
+ ],
217
+ "page_idx": 1
218
+ },
219
+ {
220
+ "type": "text",
221
+ "text": "CP decomposition. A tensor $\\mathcal { X } \\in \\mathbb { R } ^ { I _ { 1 } \\times I _ { 2 } \\times \\dots \\times I _ { N } }$ , can be decomposed into a sum of $R$ rank-1 tensors, known as the Canonical-Polyadic decomposition, where $R$ is the rank of the decomposition. Its purpose is to find vectors u(1)k , u(2)k , · $\\mathbf { u } _ { k } ^ { ( 1 ) } , \\mathbf { u } _ { k } ^ { \\top { 2 } ) } , \\cdots , \\mathbf { u } _ { k } ^ { ( N ) }$ , for $k = [ 1 \\ldots R ]$ , as well as a vector of weights ",
222
+ "bbox": [
223
+ 174,
224
+ 876,
225
+ 825,
226
+ 925
227
+ ],
228
+ "page_idx": 1
229
+ },
230
+ {
231
+ "type": "text",
232
+ "text": "$\\pmb { \\lambda } \\in \\mathbb { R } ^ { R }$ such that: ",
233
+ "bbox": [
234
+ 173,
235
+ 103,
236
+ 295,
237
+ 118
238
+ ],
239
+ "page_idx": 2
240
+ },
241
+ {
242
+ "type": "equation",
243
+ "img_path": "images/023db72e8ff971a9f63a3deb1a50b6fbb19825085ee239def84f08d7228190f3.jpg",
244
+ "text": "$$\n\\mathcal { X } = \\sum _ { k = 1 } ^ { R } \\underbrace { \\lambda _ { k } \\mathbf { u } _ { k } ^ { ( 1 ) } \\circ \\mathbf { u } _ { k } ^ { ( 2 ) } \\circ \\cdot \\cdot \\cdot \\circ \\mathbf { u } _ { k } ^ { ( N ) } } _ { \\mathrm { r a n k - 1 ~ c o m p o n e n t s } }\n$$",
245
+ "text_format": "latex",
246
+ "bbox": [
247
+ 379,
248
+ 116,
249
+ 619,
250
+ 165
251
+ ],
252
+ "page_idx": 2
253
+ },
254
+ {
255
+ "type": "text",
256
+ "text": "Tucker decomposition. A tensor $\\mathcal { X } \\in \\mathbb { R } ^ { I _ { 1 } \\times I _ { 2 } \\times \\dots \\times I _ { N } }$ , can be decomposed into a low rank approximation including a core $\\mathcal { G } \\in \\mathbb { R } ^ { R _ { 1 } \\times R _ { 2 } \\times \\cdots \\times R _ { N } }$ and a set of projection factors $\\big ( \\mathbf { U } ^ { ( 0 ) } , \\cdots , \\mathbf { U } ^ { ( \\bar { N } - 1 ) } \\big )$ , with $\\mathbf { U } ^ { ( k ) } \\in \\mathbb { R } ^ { R _ { k } , \\hat { I } _ { k } } , k \\in \\left( 0 , \\cdots , N - 1 \\right)$ that, when projected along the corresponding dimension of the core, reconstruct the full tensor $\\mathcal { X }$ . The tensor in its decomposed form can be written: ",
257
+ "bbox": [
258
+ 173,
259
+ 178,
260
+ 826,
261
+ 241
262
+ ],
263
+ "page_idx": 2
264
+ },
265
+ {
266
+ "type": "equation",
267
+ "img_path": "images/fffac66168c6aa75c6f165d0d8a6d8da43c16f7020adff6252a566c3b7064b98.jpg",
268
+ "text": "$$\n\\boldsymbol { \\mathcal { X } } = \\boldsymbol { \\mathcal { G } } \\times _ { 1 } \\mathbf { U } ^ { ( 1 ) } \\times _ { 2 } \\mathbf { U } ^ { ( 2 ) } \\times \\cdots \\times _ { N } \\mathbf { U } ^ { ( N ) } = \\left[ \\boldsymbol { \\mathcal { G } } ; \\mathbf { U } ^ { ( 1 ) } , \\cdots , \\mathbf { U } ^ { ( N ) } \\right]\n$$",
269
+ "text_format": "latex",
270
+ "bbox": [
271
+ 271,
272
+ 248,
273
+ 710,
274
+ 272
275
+ ],
276
+ "page_idx": 2
277
+ },
278
+ {
279
+ "type": "text",
280
+ "text": "Tensor regression layer. For two tensors $\\begin{array} { r l r l r l } { { \\mathcal { X } } } & { { } } & { \\in } & { { } } & { \\mathbb { R } ^ { K _ { 1 } \\times \\cdots \\times K _ { x } \\times I _ { 1 } \\times \\cdots \\times I _ { N } } } \\end{array}$ and $\\qquad \\mathcal { V } \\qquad \\in$ $\\mathbb { R } ^ { I _ { 1 } \\times \\dots \\times I _ { N } \\times L _ { 1 } \\times \\dots \\times L _ { y } }$ , we denote by $\\begin{array} { r l r } { \\langle { \\mathcal X } , { \\mathcal y } \\rangle _ { N } } & { { } \\in } & { \\mathbb { R } ^ { K _ { 1 } \\times \\cdots \\times K _ { x } \\times L _ { 1 } \\times \\cdots \\times L _ { y } } } \\end{array}$ the contraction of $\\mathcal { X }$ by $\\mathcal { V }$ along their $N$ last modes; their generalized inner product is ",
281
+ "bbox": [
282
+ 173,
283
+ 287,
284
+ 826,
285
+ 332
286
+ ],
287
+ "page_idx": 2
288
+ },
289
+ {
290
+ "type": "equation",
291
+ "img_path": "images/00c2b73b1087f8cc0e2877d1fd71fb61217862ebb3b944d16984335daf6e9b3b.jpg",
292
+ "text": "$$\n\\langle \\mathcal { X } , \\mathcal { Y } \\rangle _ { N } = \\sum _ { i _ { 1 } = 1 } ^ { I _ { 1 } } \\sum _ { i _ { 2 } = 1 } ^ { I _ { 2 } } \\cdots \\sum _ { i _ { n } = 1 } ^ { I _ { N } } \\mathcal { X } _ { \\ldots , i _ { 1 } , i _ { 2 } , \\ldots , i _ { n } } \\mathcal { Y } _ { i _ { 1 } , i _ { 2 } , \\ldots , i _ { n } , \\ldots }\n$$",
293
+ "text_format": "latex",
294
+ "bbox": [
295
+ 313,
296
+ 338,
297
+ 681,
298
+ 383
299
+ ],
300
+ "page_idx": 2
301
+ },
302
+ {
303
+ "type": "text",
304
+ "text": "This makes it possible to define a tensor regression layer (Kossaifi et al., 2017b) that is differentiable and learnable end-to-end by gradient descent. Let us denote by $\\mathcal { X } ~ \\in ~ \\mathbb { R } ^ { I _ { 1 } \\times I _ { 2 } \\times \\dots \\times I _ { N } }$ the input activation tensor for a sample and $\\mathbf { y } \\in \\mathbb { R } ^ { I _ { N } }$ the label vector. A tensor regression layer estimates the regression weight tensor $\\mathcal { W } \\in { \\dot { \\mathbb { R } } } ^ { I _ { 1 } \\times I _ { 2 } \\times \\dots \\times I _ { N } }$ under a low-rank decomposition. In the case of a Tucker decomposition (as per our experiments) with ranks $( R _ { 1 } , \\cdots , R _ { N } )$ , we have : ",
305
+ "bbox": [
306
+ 173,
307
+ 390,
308
+ 825,
309
+ 462
310
+ ],
311
+ "page_idx": 2
312
+ },
313
+ {
314
+ "type": "equation",
315
+ "img_path": "images/65cffebc7e230b11530a13d1bb222d94b44e20e70cfc79e6b5ef0056bfa00397.jpg",
316
+ "text": "$$\n\\mathbf { y } = \\langle \\mathcal { X } , \\mathcal { W } \\rangle _ { N } + \\mathbf { b } \\qquad \\mathrm { w i t h } \\ \\mathcal { W } = \\mathcal { G } \\times _ { 1 } \\mathbf { U } ^ { ( 1 ) } \\times _ { 2 } \\mathbf { U } ^ { ( 2 ) } \\cdot \\cdot \\cdot \\times _ { N } \\mathbf { U } ^ { ( N ) }\n$$",
317
+ "text_format": "latex",
318
+ "bbox": [
319
+ 266,
320
+ 468,
321
+ 728,
322
+ 488
323
+ ],
324
+ "page_idx": 2
325
+ },
326
+ {
327
+ "type": "text",
328
+ "text": "as $\\mathcal { G } \\in \\mathbb { R } ^ { R _ { 1 } \\times \\cdots \\times R _ { N } }$ , $\\mathbf { U } ^ { ( k ) } \\in \\mathbb { R } ^ { I _ { k } \\times R _ { k } }$ for each $k$ in $[ 1 \\ldots N ]$ and ${ \\bf U } ^ { ( N ) } \\in \\mathbb { R } ^ { 1 \\times R _ { N } }$ ",
329
+ "bbox": [
330
+ 174,
331
+ 496,
332
+ 707,
333
+ 513
334
+ ],
335
+ "page_idx": 2
336
+ },
337
+ {
338
+ "type": "text",
339
+ "text": "2.3 WAVELET SCATTERING ",
340
+ "text_level": 1,
341
+ "bbox": [
342
+ 174,
343
+ 530,
344
+ 375,
345
+ 545
346
+ ],
347
+ "page_idx": 2
348
+ },
349
+ {
350
+ "type": "text",
351
+ "text": "The wavelet scattering transform was originally introduced by Mallat (2011) and Bruna & Mallat (2012) as a non-linear extension to the classical wavelet filter bank decomposition. Its principle is as follows. Denoting by $x \\circledast y [ n ]$ the 2-dimensional, circular convolution of two signals $x [ n ]$ and $y [ n ]$ , let us assume that we have pre-defined two wavelet filter banks available $\\left\\{ \\psi _ { \\lambda _ { 1 } } ^ { ( 1 ) } [ n ] \\right\\} _ { \\lambda _ { 1 } \\in \\Lambda _ { 1 } }$ ¶ψ(2)λ2 [n]©λ2∈Λ2 , with $\\lambda _ { 1 }$ and $\\lambda _ { 2 }$ two frequency indices. These wavelet filters correspond to high frequencies, so we also give ourselves the data of a lowpass filter $\\phi _ { J } [ n ]$ . Finally, and by opposition to traditional linear wavelet transforms, we also assume a given nonlinearity $\\rho ( t )$ . Then the scattering transform is given by coefficients of order 0,1, and 2, respectively : ",
352
+ "bbox": [
353
+ 173,
354
+ 556,
355
+ 826,
356
+ 688
357
+ ],
358
+ "page_idx": 2
359
+ },
360
+ {
361
+ "type": "equation",
362
+ "img_path": "images/186f4f2c8d07895d70caa3bf7732b43674d5b40f99b9fc225c999bd0553ee5ea.jpg",
363
+ "text": "$$\n\\begin{array} { r l } { S _ { 0 } x [ n ] = x \\circledast \\phi _ { J } [ n ] } & { } \\\\ { S _ { 1 } x \\left[ n , \\lambda _ { 1 } \\right] = \\rho \\left( x \\circledast \\psi _ { \\lambda _ { 1 } } ^ { ( 1 ) } \\right) \\circledast \\phi _ { J } [ n ] } & { \\lambda _ { 1 } \\in \\Lambda _ { 1 } } \\\\ { S _ { 2 } x \\left[ n , \\lambda _ { 1 } , \\lambda _ { 2 } \\right] = \\rho \\left( \\rho \\left( x \\circledast \\psi _ { \\lambda _ { 1 } } ^ { ( 1 ) } \\right) \\circledast \\psi _ { \\lambda _ { 2 } } ^ { ( 2 ) } \\right) \\circledast \\phi _ { J } [ n ] } & { \\lambda _ { 1 } \\in \\Lambda _ { 1 } , \\lambda _ { 2 } \\in \\Lambda _ { 2 } \\left( \\lambda _ { 1 } \\right) } \\end{array}\n$$",
364
+ "text_format": "latex",
365
+ "bbox": [
366
+ 241,
367
+ 698,
368
+ 754,
369
+ 776
370
+ ],
371
+ "page_idx": 2
372
+ },
373
+ {
374
+ "type": "text",
375
+ "text": "This can effectively be understood and implemented as a two-layer convolutional neural network whose weights are not learned but rather frozen and given by the coefficients of wavelets $\\psi$ and $\\phi$ (with Gabor filters as a special case (Mallat, 1998)). The difference with traditional filter banks comes from the iterated modulus/nonlinear activation function applied at each stage, much like in traditional deep learning convolutional neural networks. The generic mathematical definition involves order $n$ iterated scatterings, in the vein of $S _ { i } x$ above, but sometimes restricts nonlinearity $\\rho$ to be a modulus function $| \\cdot |$ . In practice, the potential of scattering transforms to accelerate learning by providing ready-made convolutional layers has been investigated in Oyallon et al. (2013) and Oyallon et al. (2018) and is a subject of active ongoing research. Scattering will be the second of our weight-saving methods. ",
376
+ "bbox": [
377
+ 173,
378
+ 784,
379
+ 826,
380
+ 924
381
+ ],
382
+ "page_idx": 2
383
+ },
384
+ {
385
+ "type": "text",
386
+ "text": "2.4 SECOND ORDER OPTIMIZATION WITH K-FAC ",
387
+ "text_level": 1,
388
+ "bbox": [
389
+ 178,
390
+ 103,
391
+ 526,
392
+ 117
393
+ ],
394
+ "page_idx": 3
395
+ },
396
+ {
397
+ "type": "text",
398
+ "text": "While stochastic gradient descent is usually performed purely from gradient observations derived from auto-differentiation, faster, second order optimization methods first multiply the weights’ $\\theta$ gradient vector $\\nabla _ { \\theta }$ by a preconditioning matrix, yielding the weight update $\\theta _ { n + 1 } \\dot { ~ } \\dot { ~ } \\dot { ~ } \\theta _ { n } - \\eta \\dot { G } _ { n } ^ { - 1 } \\nabla _ { \\theta }$ with $\\eta$ a step size. In the case of second order methods, the matrix $G _ { n } ^ { - 1 }$ is chosen to act as a tractable iterative approximation to the inverse Hessian or Empirical Fisher Information Matrix (Amari, 1998) of the neural network model in question. Kronecker-factored approximate curvature or K-FAC (Martens $\\&$ Grosse, 2015) enforces a Kronecker decomposition of the type $G = A \\otimes B$ , with $A$ and $B$ being smaller, architecture-dependent matrices. Unlike the above methods, K-FAC has been applied as a plug-in in the deep RL literature and shown to promote both anytime convergence properties as well as terminal accuracies (Wu et al., 2017). ",
399
+ "bbox": [
400
+ 173,
401
+ 130,
402
+ 825,
403
+ 268
404
+ ],
405
+ "page_idx": 3
406
+ },
407
+ {
408
+ "type": "text",
409
+ "text": "3 OBSERVATIONS AND METHODS ",
410
+ "text_level": 1,
411
+ "bbox": [
412
+ 176,
413
+ 289,
414
+ 462,
415
+ 304
416
+ ],
417
+ "page_idx": 3
418
+ },
419
+ {
420
+ "type": "text",
421
+ "text": "3.1 EXPLORING TRAINED AGENTS ",
422
+ "text_level": 1,
423
+ "bbox": [
424
+ 176,
425
+ 320,
426
+ 423,
427
+ 334
428
+ ],
429
+ "page_idx": 3
430
+ },
431
+ {
432
+ "type": "text",
433
+ "text": "Stability of trained dense layers eigenvalues. In order to assess experimentally if tensor factorization can make sense in RL, we investigate the eigenvalues of the dense layers of a deep RL agent. Unlike the traditional supervised learning setting, the input data distribution to RL function approximators shifts as the agent explores its environment; as such, concentration properties of the eigenvalues of the linear layers cannot be guaranteed all the way throughout training. Since conditioning techniques such as batch normalization (Ioffe & Szegedy, 2015) are rarely used in deep RL, this is all the more important. Our experiments (see figure 1) show that the distribution of eigenvalues does not seem to widen significantly, at least during the initial phases of training we care about. ",
434
+ "bbox": [
435
+ 173,
436
+ 347,
437
+ 826,
438
+ 470
439
+ ],
440
+ "page_idx": 3
441
+ },
442
+ {
443
+ "type": "image",
444
+ "img_path": "images/d826828170c81e9f5a1a15742e69a5c084866508b1063b03fdc87d497398593d.jpg",
445
+ "image_caption": [
446
+ "Figure 1: Eigenvalue histograms of the value-based linear layer during training. 50 agent runs dataefficient Rainbow (van Hasselt et al., 2019), of 100,000 steps on the Atari game Road Runner. "
447
+ ],
448
+ "image_footnote": [],
449
+ "bbox": [
450
+ 210,
451
+ 484,
452
+ 782,
453
+ 661
454
+ ],
455
+ "page_idx": 3
456
+ },
457
+ {
458
+ "type": "text",
459
+ "text": "Furthermore and interestingly, it does not seem to deviate significantly from the one observed at initialization. All together, this suggests there might be some merit in learning low-rank policies. ",
460
+ "bbox": [
461
+ 173,
462
+ 727,
463
+ 823,
464
+ 756
465
+ ],
466
+ "page_idx": 3
467
+ },
468
+ {
469
+ "type": "text",
470
+ "text": "3.2 ARCHITECTURAL MODIFICATIONS ",
471
+ "text_level": 1,
472
+ "bbox": [
473
+ 176,
474
+ 773,
475
+ 450,
476
+ 786
477
+ ],
478
+ "page_idx": 3
479
+ },
480
+ {
481
+ "type": "text",
482
+ "text": "Baseline. We then proceed to build upon the well-known Rainbow algorithm (Hessel et al., 2017). Rainbow uses a fairly standard shallow convolutional architecture like the seminal DQN paper of Mnih et al. (2013), and is an oft-cited baseline on the Atari suite. In spite of its performance, Rainbow often requires dozens of millions of a single game’s frames in order to perform well. Very recently, a ’data-efficient’ efficient version of Rainbow has been proposed by van Hasselt et al. (2019), with a view to match or beat the latest state-of-the-art results achieved by model-based RL methods. This is achieved with no major change in network architecture, but via a selection of mildly handtuned hyperparameters favouring efficiency against wall-clock running time (see appendix). We do take this as a baseline. ",
483
+ "bbox": [
484
+ 174,
485
+ 797,
486
+ 826,
487
+ 924
488
+ ],
489
+ "page_idx": 3
490
+ },
491
+ {
492
+ "type": "image",
493
+ "img_path": "images/30c60fbe868b4c678893e7e1101c5672ec51057da5085e6818f907a8a7ac506f.jpg",
494
+ "image_caption": [
495
+ "Figure 2: Our architectural approach consists in replacing hidden layers in deep RL agents with tensor regression (top). Optionally we substitute the topmost convolutional layer with scattering (middle), and combine both methods (bottom). "
496
+ ],
497
+ "image_footnote": [],
498
+ "bbox": [
499
+ 217,
500
+ 102,
501
+ 807,
502
+ 352
503
+ ],
504
+ "page_idx": 4
505
+ },
506
+ {
507
+ "type": "text",
508
+ "text": "Changes. We modify the architecture of the neural network function approximators used, in accordance with the principles described above, combining them to reflect inductive biases promoting fewer learnable parameters: ",
509
+ "bbox": [
510
+ 176,
511
+ 440,
512
+ 823,
513
+ 482
514
+ ],
515
+ "page_idx": 4
516
+ },
517
+ {
518
+ "type": "text",
519
+ "text": "• We replace the fully-connected, linear layers used in Rainbow and data-efficient Rainbow with tensor regression layers (Kossaifi et al., 2017b) in order to learn low-rank policies (ranks in appendix). We use either the K-FAC second order stochastic optimizer, or the standard ADAM optimizer (Kingma & Ba, 2014). Optimization with K-FAC yields better results ceteris paribus and therefore works to counter performance loss due to using fewer weights. We combine the two methods with various rank (and therefore weight compression) ratios, targetting sensible compression ratios guided by deep learning intuition; and evaluate those on the same subset of Atari games as both van Hasselt et al. (2019); Kaiser et al. (2019). When possible, we replace the first convolutional layer in the approximating neural network with a scattering layer for further gains in terms of learnable weights. In that way, we investigate the impact of not actually learning one of the convolutional layer weights. Deep RL, paradoxically, tends to use shallow network architectures with two or three convolutional layers only, which makes it very fit for scattering methods. But since learned convolutional features discriminate well between high and low rewards, the promise of fully unsupervised scattering layers seems remote, without resorting to further ad-hoc methods like dictionary learning. Therefore we limit ourselves to one-step (one single layer) scatterings. ",
520
+ "bbox": [
521
+ 215,
522
+ 493,
523
+ 825,
524
+ 748
525
+ ],
526
+ "page_idx": 4
527
+ },
528
+ {
529
+ "type": "text",
530
+ "text": "This is illustrated in figure 2. We then proceed to evaluate the merit of these changes. ",
531
+ "bbox": [
532
+ 176,
533
+ 760,
534
+ 728,
535
+ 775
536
+ ],
537
+ "page_idx": 4
538
+ },
539
+ {
540
+ "type": "text",
541
+ "text": "4 EXPERIMENTAL RESULTS ",
542
+ "text_level": 1,
543
+ "bbox": [
544
+ 176,
545
+ 795,
546
+ 416,
547
+ 811
548
+ ],
549
+ "page_idx": 4
550
+ },
551
+ {
552
+ "type": "text",
553
+ "text": "4.1 PRIORITIZED TENSORIZED DQN ",
554
+ "text_level": 1,
555
+ "bbox": [
556
+ 176,
557
+ 827,
558
+ 439,
559
+ 842
560
+ ],
561
+ "page_idx": 4
562
+ },
563
+ {
564
+ "type": "text",
565
+ "text": "Proof of concept. We begin with showing proof of concept on the simple Pong Atari game. Our experimental setup consists in our own implementation of prioritized double DQN as a baseline (Schaul et al., 2015; van Hasselt et al., 2015). We replaced the densely connected layer of the original DQN architecture with a tensor regression layer implementing Tucker decomposition for different Tucker ranks, yielding different network compression factors. ",
566
+ "bbox": [
567
+ 174,
568
+ 853,
569
+ 823,
570
+ 924
571
+ ],
572
+ "page_idx": 4
573
+ },
574
+ {
575
+ "type": "text",
576
+ "text": "Qualitative behaviour. First results, both in terms of learning performance and compression factor, can be seen in figure 3. Our two main findings are that first, the final performance of the agent remains unaffected by the tensor factorization, even with high compression rates - with respect to all network weights - of five times. In line with intuition, larger compression rates do however cause more delays in learning. Second, tensor factorization negatively affects stability during training - in tough compression regimes, the plateauing phases of learning curves feature occasional noisy drawdowns, illustrating the increased difficulty of learning, as seen in figure 4. Interestingly, approximation errors incurred by tensor regression noise do sometimes have poor consequences illustrated by those drawdowns, but overall seem to behave as additional exploration noise. ",
577
+ "bbox": [
578
+ 173,
579
+ 103,
580
+ 826,
581
+ 229
582
+ ],
583
+ "page_idx": 5
584
+ },
585
+ {
586
+ "type": "image",
587
+ "img_path": "images/aaaf6d5635b0bcb3fa1ae458b3489386aabe09bd71f45a1dbbd5b621bab9c01d.jpg",
588
+ "image_caption": [],
589
+ "image_footnote": [],
590
+ "bbox": [
591
+ 228,
592
+ 272,
593
+ 756,
594
+ 503
595
+ ],
596
+ "page_idx": 5
597
+ },
598
+ {
599
+ "type": "image",
600
+ "img_path": "images/dd715b648e622ef26f5e95877b017a1ef30acc7687ff01a10af7360be1fb7c6d.jpg",
601
+ "image_caption": [
602
+ "Figure 3: Prioritized tensorized DQN on Atari Pong. Original learning curve versus several learning curves for five different Tucker ranks factorizations and therefore parameter compression rates (3 different random seeds each, with a 30 episodes moving average for legibility). Best viewed in colour. ",
603
+ "Figure 4: Focus on a typical single run of the tensorized DQN learning (score vs. number of thousand episodes). The overall shape of the typical learning curve is preserved, but drawdowns in the plateauing phase do appear. "
604
+ ],
605
+ "image_footnote": [],
606
+ "bbox": [
607
+ 276,
608
+ 599,
609
+ 720,
610
+ 781
611
+ ],
612
+ "page_idx": 5
613
+ },
614
+ {
615
+ "type": "text",
616
+ "text": "4.2 DATA-EFFICIENT RAINBOW ON ATARI ",
617
+ "text_level": 1,
618
+ "bbox": [
619
+ 176,
620
+ 856,
621
+ 475,
622
+ 869
623
+ ],
624
+ "page_idx": 5
625
+ },
626
+ {
627
+ "type": "text",
628
+ "text": "Evaluation protocol. For all our Atari experiments, we used OpenAI Gym (Brockman et al., 2016), and a combination of PyTorch (Paszke et al., 2017), TensorLy (Kossaifi et al., 2016) and Kymatio (Andreux et al., 2018) for auto-differentiation. We evaluated our agents in the low-data regime of ",
629
+ "bbox": [
630
+ 174,
631
+ 882,
632
+ 825,
633
+ 924
634
+ ],
635
+ "page_idx": 5
636
+ },
637
+ {
638
+ "type": "table",
639
+ "img_path": "images/87adf403834724d487ea4996c2f7a03a4316e6300f7220f37798f3f414122f85.jpg",
640
+ "table_caption": [
641
+ "100,000 steps, on half the games, with 3 different random seeds for reproducibility (Henderson et al., 2017), taking the data-efficient Rainbow agent (van Hasselt et al., 2019) as our baseline. Our specific hyperparameters are described in appendix. We report our results in tables 1 and 2. ",
642
+ "Table 1: Mean episode returns as reported in baselines SimPLe (Kaiser et al., 2019) and data-efficient Rainbow (van Hasselt et al., 2019), versus our agents, on 26 Atari games. ’Denoised’ is the NoisyNet ablation of Rainbow; ’TRL’ shows the performance of the data-efficient Rainbow with tensor regression layers substituted for linear ones. "
643
+ ],
644
+ "table_footnote": [],
645
+ "table_body": "<table><tr><td>Game</td><td>SimPLe</td><td>Rainbow</td><td>Denoised</td><td>TRL 2.5x</td><td>TRL 5x</td><td>TRL 10x</td></tr><tr><td>alien</td><td>405</td><td>740</td><td>684</td><td>688</td><td>454</td><td>566</td></tr><tr><td>amidar</td><td>88</td><td>189</td><td>154</td><td>118</td><td>86</td><td>84</td></tr><tr><td>assault</td><td>369</td><td>431</td><td>321</td><td>543</td><td>521</td><td>513</td></tr><tr><td>asterix</td><td>1090</td><td>471</td><td>500</td><td>459</td><td>554</td><td>363</td></tr><tr><td>bank_heist</td><td>8</td><td>51</td><td>77</td><td>59</td><td>134</td><td>42</td></tr><tr><td>battle_zone</td><td>5184</td><td>10125</td><td>9378</td><td>14466</td><td>13466</td><td>5744</td></tr><tr><td>boxing</td><td>9</td><td>0.2</td><td>1</td><td>-2</td><td>-2</td><td>-5</td></tr><tr><td>breakout</td><td>13</td><td>2</td><td>3</td><td>2</td><td>2</td><td>4</td></tr><tr><td>chopper_command</td><td>1247</td><td>862</td><td>1293</td><td>1255</td><td>1243</td><td>1106</td></tr><tr><td>crazy_climber</td><td>39828</td><td>16185</td><td>9977</td><td>3928</td><td>4225</td><td>2340</td></tr><tr><td>demon_attack</td><td>170</td><td>508</td><td>450</td><td>362</td><td>263</td><td>175</td></tr><tr><td>freeway</td><td>20</td><td>28</td><td>28</td><td>26</td><td>25</td><td>24</td></tr><tr><td>frostbite</td><td>255</td><td>867</td><td>1101</td><td>659</td><td>912</td><td>231</td></tr><tr><td>gopher</td><td>771</td><td>349</td><td>391</td><td>278</td><td>255</td><td>396</td></tr><tr><td>hero</td><td>1295</td><td>6857</td><td>3013</td><td>5351</td><td>3732</td><td>3321</td></tr><tr><td> jamesbond</td><td>125</td><td>302</td><td>295</td><td>215</td><td>213</td><td>218</td></tr><tr><td>kangaroo</td><td>323</td><td>779</td><td>1002</td><td>804</td><td>715</td><td>400</td></tr><tr><td>krull</td><td>4540</td><td>2852</td><td>2656</td><td>2333</td><td>2275</td><td>2308</td></tr><tr><td>kung_fu_master</td><td>17257</td><td>14346</td><td>4037</td><td>9392</td><td>4764</td><td>4031</td></tr><tr><td>ms_pacman</td><td>763</td><td>1204</td><td>1053</td><td>818</td><td>838</td><td>517</td></tr><tr><td>pong</td><td>5</td><td>-19</td><td>-20</td><td>-20</td><td>-19</td><td>-21</td></tr><tr><td>private_eye</td><td>58</td><td>98</td><td>100</td><td>51</td><td>100</td><td>1128</td></tr><tr><td>qbert</td><td>560</td><td>1153</td><td>672</td><td>697</td><td>581</td><td>733</td></tr><tr><td>road_runner</td><td>5169.4</td><td>9600</td><td>5426</td><td>6965</td><td>3914</td><td>1319</td></tr><tr><td>seaquest</td><td>371</td><td>354</td><td>387</td><td>345</td><td>350</td><td>287</td></tr><tr><td>up_n_down</td><td>2153</td><td>2877</td><td>5123</td><td>2197</td><td>2302</td><td>2179</td></tr><tr><td colspan=\"2\">Average (vs.Rainbow)</td><td>100%</td><td>118%</td><td>96%</td><td>90%</td><td>71%</td></tr></table>",
646
+ "bbox": [
647
+ 176,
648
+ 162,
649
+ 825,
650
+ 566
651
+ ],
652
+ "page_idx": 6
653
+ },
654
+ {
655
+ "type": "text",
656
+ "text": "Table 1 shows proof of concept of the online learning of low-rank policies, with a loss of final performance varying in proportion to the compression in the low-rank linear layers, very much like in the deep learning literature (Kossaifi et al., 2017a;b). The number of coefficients in the original data-efficient Rainbow is of the order of magnitude of 1M and varies depending on the environment and its action-space size. The corresponding tensor regression layer ranks are in appendix, and chosen to target 400k, 200k and $1 0 0 \\mathrm { k }$ coefficients respectively. While individual game results tend to decrease monotonously with increasing compression, we observe that they are noisy due to the nature of exploration in RL, and average scores reported correspond to the intuition that performance seems to decrease fast after a certain overparameterization threshold is crossed. To take this noisy character into account, we take care to be conservative and report the average of the final three episodes of the learned policy after 80k, 90k and $1 0 0 \\mathrm { k }$ steps, respectively. ",
657
+ "bbox": [
658
+ 173,
659
+ 652,
660
+ 825,
661
+ 805
662
+ ],
663
+ "page_idx": 6
664
+ },
665
+ {
666
+ "type": "text",
667
+ "text": "Denoised baseline. So as to not muddy the discussion and provide fair baselines, we do report on the NoisyNet (Fortunato et al., 2017) ablation of Rainbow (’Denoised’ columns), as the NoisyLinear layer doubles up the number of coefficients required and actually performs worse in our experiments. Its principle is that the variance of exploration noise represents a criticial tradeoff for performance (too little and one stalls, too much and one risks catastrophic updates), so it is sensible to treat it as a parameter to learn. However, in order to decouple both factors of overparametrization and exploration in the discussion of deep RL performance, we simply use a fixed exploration schedule. This denoised exploration baseline is an ablation we can then compare our tensorized methods to. ",
668
+ "bbox": [
669
+ 174,
670
+ 811,
671
+ 825,
672
+ 924
673
+ ],
674
+ "page_idx": 6
675
+ },
676
+ {
677
+ "type": "text",
678
+ "text": "Second-order optimization. We then proceed to assess the impact of second-order optimization in architecture by substituting ADAM optimization for K-FAC, and introducing scattering, in table 2. In spite of our conservative reporting, the efficiency boost from using a second order scheme more than makes up for low-rank approximation error ( $109 \\%$ performance) with five times less coefficients than van Hasselt et al. (2019), and learning with a full order of magnitude less coefficients $9 8 \\%$ performance) is made possible by the combination of K-FAC and TRL. The results however do show a sharp drop in average performance when scattering is added. Interestingly enough some games perform relatively very well with that method, simultaneously showing proof of viability and of additional work required. ",
679
+ "bbox": [
680
+ 173,
681
+ 103,
682
+ 825,
683
+ 229
684
+ ],
685
+ "page_idx": 7
686
+ },
687
+ {
688
+ "type": "table",
689
+ "img_path": "images/df73e73003e8cb70d1114a5b3df2c69049798b929909d2cb31c6573f4e8d3d73.jpg",
690
+ "table_caption": [
691
+ "Table 2: Mean episode returns of our low-rank agents with second-order optimization and scattering. The Scattering column also includes KFAC optimization and TRL 5x, resulting in around $1 0 \\mathrm { x }$ total weights efficiency gains. "
692
+ ],
693
+ "table_footnote": [],
694
+ "table_body": "<table><tr><td>Game</td><td>KFAC+Denoised</td><td>KFAC+TRL5x</td><td>KFAC+TRL10x</td><td>Scattering</td></tr><tr><td>alien</td><td>996</td><td>734</td><td>643</td><td>441</td></tr><tr><td>amidar</td><td>163</td><td>101</td><td>98</td><td>84</td></tr><tr><td>assault</td><td>501</td><td>491</td><td>496</td><td>434</td></tr><tr><td>asterix</td><td>537</td><td>549</td><td>526</td><td>502</td></tr><tr><td>bank_heist</td><td>100</td><td>73</td><td>57</td><td>29</td></tr><tr><td>battle_zone</td><td>8622</td><td>15178</td><td>6156</td><td>4311</td></tr><tr><td>boxing</td><td>0</td><td>-4</td><td>-1</td><td>-9</td></tr><tr><td>breakout</td><td>3</td><td>3</td><td>2</td><td>2</td></tr><tr><td>chopper_command</td><td>692</td><td>611</td><td>1302</td><td>441</td></tr><tr><td>crazy_climber</td><td>14242</td><td>12377</td><td>3546</td><td>740</td></tr><tr><td>demon_attack</td><td>582</td><td>434</td><td>318</td><td>692</td></tr><tr><td>freeway</td><td>26</td><td>26</td><td>24</td><td>19</td></tr><tr><td>frostbite</td><td>1760</td><td>718</td><td>1483</td><td>654</td></tr><tr><td>gopher</td><td>363</td><td>341</td><td>265</td><td>172</td></tr><tr><td>hero</td><td>4188</td><td>6284</td><td>4206</td><td>4127</td></tr><tr><td> jamesbond</td><td>263</td><td>327</td><td>217</td><td>48</td></tr><tr><td>kangaroo</td><td>2085</td><td>613</td><td>588</td><td>391</td></tr><tr><td>krull</td><td>2855</td><td>3441</td><td>3392</td><td>772</td></tr><tr><td>kung_fu_master</td><td>8481</td><td>10738</td><td>7357</td><td>233</td></tr><tr><td>ms-pacman</td><td>1137</td><td>920</td><td>867</td><td>613</td></tr><tr><td>pong</td><td>-19.3</td><td>-19</td><td>-19</td><td>-20</td></tr><tr><td>private_eye</td><td>56</td><td>100</td><td>100</td><td>0</td></tr><tr><td>qbert</td><td>731</td><td>520</td><td>538</td><td>475</td></tr><tr><td>road_runner</td><td>4516</td><td>8493</td><td>7224</td><td>1278</td></tr><tr><td>seaquest</td><td>349</td><td>317</td><td>520</td><td>213</td></tr><tr><td>up_n_down</td><td>2557</td><td>2291</td><td>2108</td><td>993</td></tr><tr><td>Average (vs.Rainbow)</td><td>114%</td><td>109%</td><td>98%</td><td>55%</td></tr></table>",
695
+ "bbox": [
696
+ 174,
697
+ 242,
698
+ 825,
699
+ 645
700
+ ],
701
+ "page_idx": 7
702
+ },
703
+ {
704
+ "type": "text",
705
+ "text": "5 CONCLUSION ",
706
+ "text_level": 1,
707
+ "bbox": [
708
+ 176,
709
+ 726,
710
+ 318,
711
+ 742
712
+ ],
713
+ "page_idx": 7
714
+ },
715
+ {
716
+ "type": "text",
717
+ "text": "We have demonstrated that in the low-data regime, it is possible to leverage biologically plausible characterizations of experience data (namely low-rank properties and wavelet scattering separability) to exhibit architectures that learn policies with an order of magnitude less weights than current state-of-the-art baselines, essentially without loss of performance, and in an online fashion. In particular, this provides a compelling alternative to methods like policy distillation (Rusu et al., 2015; Czarnecki et al., 2019). We do hope that this will lead to even further progress towards sample efficiency and speedy exploration methods. Further work will, first, focus on thorough evaluation and research of scattering architectures in order to achieve further gains, and second investigate additional, orthogonal biologically-friendly research directions such as promoting sparsity via, for instance, $L ^ { 1 }$ regularization. Finally, we are excited by the potential of tensor factorization to offer shared core tensors for policies in multi-task and meta-learning. ",
718
+ "bbox": [
719
+ 173,
720
+ 757,
721
+ 825,
722
+ 910
723
+ ],
724
+ "page_idx": 7
725
+ },
726
+ {
727
+ "type": "text",
728
+ "text": "REFERENCES ",
729
+ "text_level": 1,
730
+ "bbox": [
731
+ 174,
732
+ 102,
733
+ 287,
734
+ 117
735
+ ],
736
+ "page_idx": 8
737
+ },
738
+ {
739
+ "type": "text",
740
+ "text": "Shunichi Amari. Natural gradient works efficiently in learning. Neural Computation, 10:251–276, 1998. ",
741
+ "bbox": [
742
+ 173,
743
+ 126,
744
+ 826,
745
+ 155
746
+ ],
747
+ "page_idx": 8
748
+ },
749
+ {
750
+ "type": "text",
751
+ "text": "M. Andreux, T. Angles, G. Exarchakis, R. Leonarduzzi, G. Rochette, L. Thiry, J. Zarka, S. Mallat, J. anden, E. Belilovsky, J. Bruna, V. Lostanlen, M. J. Hirn, E. Oyallon, S. Zhang, C. Cella, and ´ M. Eickenberg. Kymatio: Scattering Transforms in Python. arXiv e-prints, December 2018. ",
752
+ "bbox": [
753
+ 178,
754
+ 164,
755
+ 825,
756
+ 207
757
+ ],
758
+ "page_idx": 8
759
+ },
760
+ {
761
+ "type": "text",
762
+ "text": "M. G. Bellemare, W. Dabney, and R. Munos. A Distributional Perspective on Reinforcement Learning. arXiv e-prints, July 2017. ",
763
+ "bbox": [
764
+ 169,
765
+ 215,
766
+ 825,
767
+ 246
768
+ ],
769
+ "page_idx": 8
770
+ },
771
+ {
772
+ "type": "text",
773
+ "text": "C. Blundell, B. Uria, A. Pritzel, Y. Li, A. Ruderman, J. Z Leibo, J. Rae, D. Wierstra, and D. Hassabis. Model-Free Episodic Control. arXiv e-prints, June 2016. ",
774
+ "bbox": [
775
+ 173,
776
+ 253,
777
+ 826,
778
+ 284
779
+ ],
780
+ "page_idx": 8
781
+ },
782
+ {
783
+ "type": "text",
784
+ "text": "G. Brockman, V. Cheung, L. Pettersson, J. Schneider, J. Schulman, J. Tang, and W. Zaremba. OpenAI Gym. arXiv e-prints, June 2016. ",
785
+ "bbox": [
786
+ 176,
787
+ 292,
788
+ 826,
789
+ 321
790
+ ],
791
+ "page_idx": 8
792
+ },
793
+ {
794
+ "type": "text",
795
+ "text": "J. Bruna and S. Mallat. Invariant Scattering Convolution Networks. arXiv e-prints, March 2012. ",
796
+ "bbox": [
797
+ 173,
798
+ 330,
799
+ 805,
800
+ 347
801
+ ],
802
+ "page_idx": 8
803
+ },
804
+ {
805
+ "type": "text",
806
+ "text": "S. Chung, D. D. Lee, and H. Sompolinsky. Linear readout of object manifolds. , 93(6):060301, June 2016. doi: 10.1103/PhysRevE.93.060301. ",
807
+ "bbox": [
808
+ 174,
809
+ 354,
810
+ 823,
811
+ 385
812
+ ],
813
+ "page_idx": 8
814
+ },
815
+ {
816
+ "type": "text",
817
+ "text": "S. Chung, D. D. Lee, and H. Sompolinsky. Classification and Geometry of General Perceptual Manifolds. Physical Review X, 8(3):031003, July 2018. doi: 10.1103/PhysRevX.8.031003. ",
818
+ "bbox": [
819
+ 173,
820
+ 393,
821
+ 825,
822
+ 424
823
+ ],
824
+ "page_idx": 8
825
+ },
826
+ {
827
+ "type": "text",
828
+ "text": "Andrzej Cichocki, Rafal Zdunek, Anh Huy Phan, and Sh. Amari. Nonnegative Matrix and Tensor Factorizations - Applications to Exploratory Multi-way Data Analysis and Blind Source Separation. 2009. ",
829
+ "bbox": [
830
+ 173,
831
+ 431,
832
+ 823,
833
+ 474
834
+ ],
835
+ "page_idx": 8
836
+ },
837
+ {
838
+ "type": "text",
839
+ "text": "G. Cuccu, J. Togelius, and P. Cudre-Mauroux. Playing Atari with Six Neurons. arXiv e-prints, June 2018. ",
840
+ "bbox": [
841
+ 171,
842
+ 483,
843
+ 825,
844
+ 513
845
+ ],
846
+ "page_idx": 8
847
+ },
848
+ {
849
+ "type": "text",
850
+ "text": "W. M. Czarnecki, R. Pascanu, S. Osindero, S. M. Jayakumar, G. Swirszcz, and M. Jaderberg. Distilling Policy Distillation. arXiv e-prints, February 2019. ",
851
+ "bbox": [
852
+ 173,
853
+ 522,
854
+ 825,
855
+ 551
856
+ ],
857
+ "page_idx": 8
858
+ },
859
+ {
860
+ "type": "text",
861
+ "text": "M. Eickenberg, G. Exarchakis, M. Hirn, S. Mallat, and L. Thiry. Solid harmonic wavelet scattering for predictions of molecule properties. , 148(24):241732, June 2018. doi: 10.1063/1.5023798. ",
862
+ "bbox": [
863
+ 171,
864
+ 560,
865
+ 825,
866
+ 590
867
+ ],
868
+ "page_idx": 8
869
+ },
870
+ {
871
+ "type": "text",
872
+ "text": "M. Fortunato, M. Gheshlaghi Azar, B. Piot, J. Menick, I. Osband, A. Graves, V. Mnih, R. Munos, D. Hassabis, O. Pietquin, C. Blundell, and S. Legg. Noisy Networks for Exploration. arXiv e-prints, June 2017. ",
873
+ "bbox": [
874
+ 173,
875
+ 598,
876
+ 825,
877
+ 642
878
+ ],
879
+ "page_idx": 8
880
+ },
881
+ {
882
+ "type": "text",
883
+ "text": "A. Gaier and D. Ha. Weight Agnostic Neural Networks. arXiv e-prints, June 2019. ",
884
+ "bbox": [
885
+ 173,
886
+ 651,
887
+ 718,
888
+ 667
889
+ ],
890
+ "page_idx": 8
891
+ },
892
+ {
893
+ "type": "text",
894
+ "text": "P. Henderson, R. Islam, P. Bachman, J. Pineau, D. Precup, and D. Meger. Deep Reinforcement Learning that Matters. arXiv e-prints, September 2017. ",
895
+ "bbox": [
896
+ 171,
897
+ 675,
898
+ 825,
899
+ 705
900
+ ],
901
+ "page_idx": 8
902
+ },
903
+ {
904
+ "type": "text",
905
+ "text": "M. Hessel, J. Modayil, H. van Hasselt, T. Schaul, G. Ostrovski, W. Dabney, D. Horgan, B. Piot, M. Azar, and D. Silver. Rainbow: Combining Improvements in Deep Reinforcement Learning. arXiv e-prints, October 2017. ",
906
+ "bbox": [
907
+ 171,
908
+ 713,
909
+ 825,
910
+ 757
911
+ ],
912
+ "page_idx": 8
913
+ },
914
+ {
915
+ "type": "text",
916
+ "text": "Aapo Hyvarinen and Patrik O. Hoyer. A two-layer sparse coding model learns simple and complex¨ cell receptive fields and topography from natural images. Vision Research, 41:2413–2423, 2001. ",
917
+ "bbox": [
918
+ 169,
919
+ 766,
920
+ 823,
921
+ 796
922
+ ],
923
+ "page_idx": 8
924
+ },
925
+ {
926
+ "type": "text",
927
+ "text": "S. Ioffe and C. Szegedy. Batch Normalization: Accelerating Deep Network Training by Reducing Internal Covariate Shift. arXiv e-prints, February 2015. ",
928
+ "bbox": [
929
+ 171,
930
+ 804,
931
+ 823,
932
+ 834
933
+ ],
934
+ "page_idx": 8
935
+ },
936
+ {
937
+ "type": "text",
938
+ "text": "Jeffrey P. Jones and Larry A. Palmer. An evaluation of the two-dimensional gabor filter model of simple receptive fields in cat striate cortex. Journal of neurophysiology, 58 6:1233–58, 1987. ",
939
+ "bbox": [
940
+ 169,
941
+ 842,
942
+ 825,
943
+ 872
944
+ ],
945
+ "page_idx": 8
946
+ },
947
+ {
948
+ "type": "text",
949
+ "text": "L. Kaiser, M. Babaeizadeh, P. Milos, B. Osinski, R. H Campbell, K. Czechowski, D. Erhan, C. Finn, P. Kozakowski, S. Levine, A. Mohiuddin, R. Sepassi, G. Tucker, and H. Michalewski. ModelBased Reinforcement Learning for Atari. arXiv e-prints, March 2019. ",
950
+ "bbox": [
951
+ 179,
952
+ 881,
953
+ 823,
954
+ 924
955
+ ],
956
+ "page_idx": 8
957
+ },
958
+ {
959
+ "type": "text",
960
+ "text": "D. P. Kingma and J. Ba. Adam: A Method for Stochastic Optimization. arXiv e-prints, December 2014. \nJ. Kossaifi, Y. Panagakis, A. Anandkumar, and M. Pantic. TensorLy: Tensor Learning in Python. arXiv e-prints, October 2016. \nJ. Kossaifi, A. Khanna, Z. C. Lipton, T. Furlanello, and A. Anandkumar. Tensor Contraction Layers for Parsimonious Deep Nets. arXiv e-prints, June 2017a. \nJ. Kossaifi, Z. C. Lipton, A. Khanna, T. Furlanello, and A. Anandkumar. Tensor Regression Networks. arXiv e-prints, July 2017b. \nS. Mallat. Group Invariant Scattering. arXiv e-prints, January 2011. \nStephane Mallat. ´ A Wavelet Tour of Signal Processing. 1998. \nJames Martens and Roger B. Grosse. Optimizing neural networks with kronecker-factored approximate curvature. ArXiv, abs/1503.05671, 2015. \nV. Mnih, K. Kavukcuoglu, D. Silver, A. Graves, I. Antonoglou, D. Wierstra, and M. Riedmiller. Playing Atari with Deep Reinforcement Learning. arXiv e-prints, December 2013. \nBruno A. Olshausen and David J. Field. Emergence of simple-cell receptive field properties by learning a sparse code for natural images. Nature, 381:607–609, 1996. \nBruno A. Olshausen and David J. Field. Sparse coding with an overcomplete basis set: A strategy employed by v1? Vision Research, 37:3311–3325, 1997. \nE. Oyallon, S. Mallat, and L. Sifre. Generic Deep Networks with Wavelet Scattering. arXiv e-prints, December 2013. \nE. Oyallon, S. Zagoruyko, G. Huang, N. Komodakis, S. Lacoste-Julien, M. Blaschko, and E. Belilovsky. Scattering Networks for Hybrid Representation Learning. arXiv e-prints, September 2018. \nAdam Paszke, Sam Gross, Soumith Chintala, Gregory Chanan, Edward Yang, Zachary DeVito, Zeming Lin, Alban Desmaison, Luca Antiga, and Adam Lerer. Automatic differentiation in pytorch. 2017. \nA. Pritzel, B. Uria, S. Srinivasan, A. Puigdomenech, O. Vinyals, D. Hassabis, D. Wierstra, and \\` C. Blundell. Neural Episodic Control. arXiv e-prints, March 2017. \nA. A. Rusu, S. Gomez Colmenarejo, C. Gulcehre, G. Desjardins, J. Kirkpatrick, R. Pascanu, V. Mnih, K. Kavukcuoglu, and R. Hadsell. Policy Distillation. arXiv e-prints, November 2015. \nT. Schaul, J. Quan, I. Antonoglou, and D. Silver. Prioritized Experience Replay. arXiv e-prints, November 2015. \nRichard S. Sutton and Andrew G. Barto. Reinforcement Learning: An Introduction. The MIT Press, second edition, 2018. URL http://incompleteideas.net/book/the-book-2nd. html. \nH. van Hasselt, A. Guez, and D. Silver. Deep Reinforcement Learning with Double Q-learning. arXiv e-prints, September 2015. \nH. van Hasselt, M. Hessel, and J. Aslanides. When to use parametric models in reinforcement learning? arXiv e-prints, June 2019. \nR. Wang, C. Ciliberto, P. Amadori, and Y. Demiris. Random Expert Distillation: Imitation Learning via Expert Policy Support Estimation. arXiv e-prints, May 2019. \nZ. Wang, T. Schaul, M. Hessel, H. van Hasselt, M. Lanctot, and N. de Freitas. Dueling Network Architectures for Deep Reinforcement Learning. arXiv e-prints, November 2015. \nY. Wu, E. Mansimov, S. Liao, R. Grosse, and J. Ba. Scalable trust-region method for deep reinforcement learning using Kronecker-factored approximation. arXiv e-prints, August 2017. \nC. Zhang, S. Bengio, M. Hardt, B. Recht, and O. Vinyals. Understanding deep learning requires rethinking generalization. arXiv e-prints, November 2016. ",
961
+ "bbox": [
962
+ 169,
963
+ 54,
964
+ 830,
965
+ 925
966
+ ],
967
+ "page_idx": 9
968
+ },
969
+ {
970
+ "type": "text",
971
+ "text": "A APPENDIX ",
972
+ "text_level": 1,
973
+ "bbox": [
974
+ 176,
975
+ 102,
976
+ 299,
977
+ 117
978
+ ],
979
+ "page_idx": 10
980
+ },
981
+ {
982
+ "type": "text",
983
+ "text": "HYPERPARAMETERS AND REPRODUCIBILITY ",
984
+ "bbox": [
985
+ 176,
986
+ 135,
987
+ 485,
988
+ 150
989
+ ],
990
+ "page_idx": 10
991
+ },
992
+ {
993
+ "type": "text",
994
+ "text": "Hyperparameters are as follows. First, our specific architecture-modified hyperparameters: ",
995
+ "bbox": [
996
+ 171,
997
+ 161,
998
+ 766,
999
+ 178
1000
+ ],
1001
+ "page_idx": 10
1002
+ },
1003
+ {
1004
+ "type": "table",
1005
+ "img_path": "images/4b9decdfc2ffb46488dbc7e608c56d40695b477ff08ad225bfce526ecb42664b.jpg",
1006
+ "table_caption": [
1007
+ "Table 3: Our additional, architecture-specific hyperparameters. "
1008
+ ],
1009
+ "table_footnote": [],
1010
+ "table_body": "<table><tr><td>Specific architecture hyperparameters</td><td>Value</td></tr><tr><td>Scattering maximum log-scale J</td><td>3</td></tr><tr><td>Scattering volume width M</td><td>1</td></tr><tr><td>Scattering tensor input shape</td><td>(1,4,84,84)</td></tr><tr><td>Scattering tensor output shape</td><td>(1,16,11,11)</td></tr><tr><td>Scattering type</td><td>Harmonic 3D,see Andreux et al. (2018); Eickenberg et al. (2018)</td></tr><tr><td></td><td>128</td></tr><tr><td>Hidden linear layer rank constraint, 2.5x compression Final linear layer rank constraint, 2.5x compression</td><td>48</td></tr><tr><td>Hidden linear layer rank constraint,5x compression</td><td>32</td></tr><tr><td>Final linear layer rank constraint,5x compression</td><td>48</td></tr><tr><td>Hidden linear layer rank constraint,1Ox compression</td><td>16</td></tr><tr><td>Final linear layer rank constraint,1Ox compression</td><td>10</td></tr><tr><td>KFAC Tikhonov regularization parameter</td><td></td></tr><tr><td>KFAC Update frequency for inverses</td><td>0.1</td></tr><tr><td></td><td>100</td></tr></table>",
1011
+ "bbox": [
1012
+ 173,
1013
+ 191,
1014
+ 936,
1015
+ 397
1016
+ ],
1017
+ "page_idx": 10
1018
+ },
1019
+ {
1020
+ "type": "table",
1021
+ "img_path": "images/75dd38b4d6524649125888468f039355b9d912066f30c3a644e7d5c45072047a.jpg",
1022
+ "table_caption": [
1023
+ "Furthermore, we mirror the Data-Efficient Rainbow van Hasselt et al. (2019) baseline: ",
1024
+ "Table 4: Data-efficient Rainbow agent hyperparameters, as per van Hasselt et al. (2019). "
1025
+ ],
1026
+ "table_footnote": [],
1027
+ "table_body": "<table><tr><td>Data-efficient Rainbow hyperparameters</td><td>Value</td></tr><tr><td>Grey-scaling</td><td>True</td></tr><tr><td>Observation down-sampling</td><td>(84,84)</td></tr><tr><td>Frames stacked</td><td>4</td></tr><tr><td>Action repetitions</td><td>4</td></tr><tr><td>Reward clipping</td><td>[-1, 1]</td></tr><tr><td>Terminal on loss of life</td><td>True</td></tr><tr><td>Max frames per episode</td><td>108K</td></tr><tr><td>Update</td><td>Distributional Double Q</td></tr><tr><td>Target network update period*</td><td>every 2000 updates</td></tr><tr><td>Support of Q-distribution</td><td>51 bins</td></tr><tr><td>Discount factor</td><td>0.99</td></tr><tr><td>Minibatch size</td><td>32</td></tr><tr><td>Optimizer</td><td>Adam</td></tr><tr><td>Optimizer: first moment decay</td><td>0.9</td></tr><tr><td>Optimizer: second moment decay</td><td>0.999</td></tr><tr><td>Optimizer: e</td><td>0.00015</td></tr><tr><td>Max gradient norm</td><td>10</td></tr><tr><td>Priority exponent</td><td>0.5</td></tr><tr><td>Priority correction**</td><td>0.4→1</td></tr><tr><td>Hardware</td><td>NVidia 1080TiGPU</td></tr><tr><td>Noisy nets parameter</td><td>0.1</td></tr><tr><td>Training frames</td><td>400,000</td></tr><tr><td>Min replay size for sampling</td><td>1600</td></tr><tr><td>Memory size</td><td>unbounded</td></tr><tr><td>Replay period every</td><td>1 steps</td></tr><tr><td>Multi-step return length</td><td>20</td></tr><tr><td>Q network:channels</td><td>32,64</td></tr><tr><td>Q network: filter size</td><td>5 5,5 5</td></tr><tr><td>Q network: stride</td><td>5,5</td></tr><tr><td>Q network: hidden units</td><td>256</td></tr><tr><td></td><td></td></tr><tr><td>Optimizer: learning rate</td><td>0.0001</td></tr></table>",
1028
+ "bbox": [
1029
+ 284,
1030
+ 473,
1031
+ 714,
1032
+ 892
1033
+ ],
1034
+ "page_idx": 10
1035
+ },
1036
+ {
1037
+ "type": "text",
1038
+ "text": "Our codebase is available on request. ",
1039
+ "bbox": [
1040
+ 176,
1041
+ 104,
1042
+ 416,
1043
+ 117
1044
+ ],
1045
+ "page_idx": 11
1046
+ },
1047
+ {
1048
+ "type": "table",
1049
+ "img_path": "images/caf39fbb05b316cdc8a33c14f16f479579f321f6df06babff263ddb34eb6e541.jpg",
1050
+ "table_caption": [
1051
+ "STANDARD DEVIATIONS FOR SCORE RUNS ",
1052
+ "Table 5: Standard deviations across seeds for runs presented Table 1. "
1053
+ ],
1054
+ "table_footnote": [
1055
+ "Table 6: Standard deviations across seeds for runs presented Table 2. "
1056
+ ],
1057
+ "table_body": "<table><tr><td>Game</td><td>Denoised</td><td>TRL 2.5x</td><td>TRL 10x</td></tr><tr><td>alien</td><td>684±7</td><td>688 ±123</td><td>566±38</td></tr><tr><td>amidar</td><td>154 ± 21</td><td>118 ±12</td><td>84±15</td></tr><tr><td>assault</td><td>321 ± 224</td><td>543 ± 94</td><td>513± 64</td></tr><tr><td>asterix</td><td>500 ±124</td><td>459 ± 91</td><td>363 ± 66</td></tr><tr><td>bank_heist</td><td>77±23</td><td>59± 22</td><td>42±2</td></tr><tr><td>battle_zone</td><td>9378 ± 2042</td><td>14466 ± 2845</td><td>5744 ± 575</td></tr><tr><td>boxing</td><td>1±2</td><td>-2±1</td><td>-5±1</td></tr><tr><td>breakout</td><td>3 ±1.5</td><td>2±1</td><td>4±0.3</td></tr><tr><td>chopper_command</td><td>1293 ± 445</td><td>1255 ± 215</td><td>1106 ± 124</td></tr><tr><td>crazy_climber</td><td>9977 ± 3744</td><td>3928 ± 221</td><td>2340 ± 595</td></tr><tr><td>demon_attack</td><td>450 ± 49</td><td>362 ± 147</td><td>175±7</td></tr><tr><td>freeway</td><td>28 ±0.6</td><td>26±0</td><td>24 ± 0.5</td></tr><tr><td>frostbite</td><td>1101 ± 355</td><td>659 ± 523</td><td>231±1</td></tr><tr><td>gopher</td><td>391 ± 46</td><td>278 ±39</td><td>396 ± 24</td></tr><tr><td>hero</td><td>3013 ± 90</td><td>5351 ± 1948</td><td>3321 ± 598</td></tr><tr><td> jamesbond</td><td>295±57</td><td>215 ±42</td><td>218 ±22</td></tr><tr><td>kangaroo</td><td>1002 ± 587</td><td>804 ± 289</td><td>400 ± 278</td></tr><tr><td>krull</td><td>2656 ± 180</td><td>2333 ± 309</td><td>2308 ± 268</td></tr><tr><td>kung_fu_master</td><td>4037 ± 2962</td><td>9392 ± 6289</td><td>4031 ± 3068</td></tr><tr><td>ms_pacman</td><td>1053 ±193</td><td>818 ±94</td><td>517 ±38</td></tr><tr><td>pong</td><td>-20 ± 0.4</td><td>-20±0</td><td>-21 ± 0.1</td></tr><tr><td>private_eye</td><td>100±0</td><td>51± 59</td><td>1128 ± 1067</td></tr><tr><td>qbert</td><td>672 ± 144</td><td>697 ± 78</td><td>733 ± 291</td></tr><tr><td>road_runner</td><td>5426 ± 2830</td><td>6965 ± 6569</td><td>1319± 216</td></tr><tr><td>seaquest</td><td>387 ± 24</td><td>345 ± 40</td><td>287±87</td></tr><tr><td>up_n_down</td><td>5123 ± 3146</td><td>2197 ± 231</td><td>2179 ±178</td></tr><tr><td>Game</td><td>KFAC+Denoised</td><td>KFAC+TRL10x</td><td>Scattering</td></tr><tr><td>alien</td><td>996 ± 180</td><td>643 ± 51</td><td>441 ± 90</td></tr><tr><td>amidar</td><td>163 ± 15</td><td>98 ±26</td><td>84 ±11</td></tr><tr><td>assault</td><td>501 ± 85</td><td>496 ±129</td><td>434±304</td></tr><tr><td>asterix</td><td>537 ± 96</td><td>526 ±64</td><td>502 ± 91</td></tr><tr><td>bank_heist</td><td>100 ±14</td><td>57 ± 36</td><td>29 ±13</td></tr><tr><td>battle_zone</td><td>8622 ± 5358</td><td>6156 ± 1951</td><td>4311 ± 1517</td></tr><tr><td>boxing</td><td>0±2</td><td>-1±3</td><td>-9 ±12</td></tr><tr><td>breakout</td><td>3±1</td><td>2±2</td><td>2±0</td></tr><tr><td>chopper_command</td><td>692 ± 81</td><td>1302 ± 328</td><td>441 ± 80</td></tr><tr><td>crazy_climber</td><td>14242 ± 2936</td><td>3546 ±1231</td><td>740 ± 291</td></tr><tr><td>demon_attack</td><td>582 ±130</td><td>318 ±168</td><td>92±232</td></tr><tr><td>freeway</td><td>26±0</td><td>24±0</td><td>19 ±1</td></tr><tr><td>frostbite</td><td>1760 ± 448</td><td>1483 ± 466</td><td>654 ± 709</td></tr><tr><td>gopher</td><td>363 ±4</td><td>265 ± 67</td><td>172 ±3</td></tr><tr><td>hero</td><td>4188 ±1635</td><td>4206 ±1862</td><td>4127 ±1074</td></tr><tr><td>jamesbond</td><td>263 ±22</td><td>217±68</td><td>48±10</td></tr><tr><td>kangaroo</td><td>2085 ± 2055</td><td>588±5</td><td>391±52</td></tr><tr><td>krull</td><td>2855 ± 156</td><td>3392 ± 2205</td><td>772± 560</td></tr><tr><td>kung_fu_master</td><td>8481 ± 8270</td><td>7357 ± 9200</td><td>233± 205</td></tr><tr><td>ms_pacman</td><td>1137 ± 180</td><td>867 ±128</td><td>613 ±159</td></tr><tr><td>pong</td><td>-19 ± 0.6</td><td>-19 ±1</td><td>-20±0</td></tr><tr><td>private_eye</td><td>56±42</td><td>100±0</td><td>0±0</td></tr><tr><td>qbert</td><td>731 ± 256</td><td>538 ±114</td><td>475 ± 161</td></tr><tr><td>road_runner</td><td>4516 ± 2869</td><td>7224±4598</td><td>1278 ±463</td></tr><tr><td>seaquest</td><td>349 ± 63</td><td>520 ±97</td><td>213 ±96</td></tr><tr><td>_n_down</td><td>2557 ± 641</td><td>2108 ± 298</td><td>993 ± 244</td></tr></table>",
1058
+ "bbox": [
1059
+ 264,
1060
+ 165,
1061
+ 738,
1062
+ 554
1063
+ ],
1064
+ "page_idx": 11
1065
+ },
1066
+ {
1067
+ "type": "table",
1068
+ "img_path": "",
1069
+ "table_caption": [],
1070
+ "table_footnote": [
1071
+ ""
1072
+ ],
1073
+ "bbox": [
1074
+ 246,
1075
+ 305,
1076
+ 756,
1077
+ 693
1078
+ ],
1079
+ "page_idx": 12
1080
+ }
1081
+ ]
parse/train/HJaDJZ-0W/HJaDJZ-0W.md ADDED
@@ -0,0 +1,294 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # BLOCK-SPARSE RECURRENT NEURAL NETWORKS
2
+
3
+ Anonymous authors Paper under double-blind review
4
+
5
+ # ABSTRACT
6
+
7
+ Recurrent Neural Networks (RNNs) are used in state-of-the-art models in domains such as speech recognition, machine translation, and language modelling. Sparsity is a technique to reduce compute and memory requirements of deep learning models. Sparse RNNs are easier to deploy on devices and high-end server processors. Even though sparse operations need less compute and memory relative to their dense counterparts, the speed-up observed by using sparse operations is less than expected on different hardware platforms. In order to address this issue, we investigate two different approaches to induce block sparsity in RNNs: pruning blocks of weights in a layer and using group lasso regularization with pruning to create blocks of weights with zeros. Using these techniques, we can create block-sparse RNNs with sparsity ranging from $80 \%$ to $90 \%$ with a small loss in accuracy. This technique allows us to reduce the model size by roughly $1 0 \times$ . Additionally, we can prune a larger dense network to recover this loss in accuracy while maintaining high block sparsity and reducing the overall parameter count. Our technique works with a variety of block sizes up to $3 2 \times 3 2$ . Block-sparse RNNs eliminate overheads related to data storage and irregular memory accesses while increasing hardware efficiency compared to unstructured sparsity.
8
+
9
+ # 1 INTRODUCTION
10
+
11
+ Improvements in several applications such as speech recognition (Amodei et al., 2016), language modeling (Jozefowicz et al. ´ , 2016), and machine translation (Wu et al., 2016) are a result of large Recurrent Neural Networks (RNNs) trained on large scale datasets. As the datasets available to train these models have grown, so have model sizes. Deployment of such large models is compute and memory intensive.
12
+
13
+ Pruning weights of deep neural networks is an effective strategy to reduce the overall memory and compute requirements of these models (Narang et al., 2017; Han et al., 2015). However, these approaches induce random, unstructured sparsity in the weight matrices. Speed-up obtained with unstructured sparsity on various hardware platforms are often lower than expected (as shown in Narang et al. (2017); Narang & Diamos (2017)). Sparse formats do not efficiently utilize the hardware resources due to storage overheads and irregular memory access. Block sparsity can address these issues. Saving indices of non-zero blocks instead of indices for non-zero elements reduces the storage overhead by a factor of block size. Block-sparse formats store blocks contiguously in memory reducing irregular memory accesses.
14
+
15
+ Another disadvantage of unstructured sparsity is that it cannot directly exploit array-data-paths in modern processors. These include the $1 6 \times 1 6$ TensorCore units in the Volta GPU (NVIDIA, 2017) or the $2 5 6 \times 2 5 6$ hardware units in the Tensor Processing Unit (TPU) (Jouppi et al., 2017). Structured sparsity in the form of two-dimensional blocks allows us to take advantage of these faster units.
16
+
17
+ In order to induce block sparsity in RNNs, we propose a block pruning approach that zeros out blocks of weights in the matrix while the network is training. At the end of training, the algorithm creates a block-sparse RNN. In addition to this pruning technique, we examine the efficacy of group lasso regularization (Yuan & Lin, 2006b) to induce block sparsity in the network. We also combine group lasso regularization with block pruning.
18
+
19
+ We demonstrate that block pruning and group lasso regularization with pruning are successful in creating block-sparse RNNs. Inducing block sparsity with $4 \times 4$ blocks in vanilla RNNs and Gated Recurrent Units (GRUs) (Cho et al., 2014) results in $9 \%$ to $17 \%$ loss in accuracy compared to the dense baseline. Model size reduces by nearly $1 0 \times$ for speech recognition. Block sizes can be scaled up to $3 2 \times 3 2$ with our approach. We can also reduce accuracy loss by starting with a larger dense matrix than the baseline and then pruning it down while still reducing the number of parameters compared to the baseline. We demonstrate that this approach works with Long Short Term Memory (LSTM) (Hochreiter & Schmidhuber, 1997) cells for Language Modelling as well.
20
+
21
+ Our approach is agnostic to the optimization algorithm and does not require any hyper-parameter retuning (besides pruning and regularization hyper-parameters). Furthermore, since our approach does not require re-training the model, training time remains constant.
22
+
23
+ # 2 RELATED WORK
24
+
25
+ There have been several approaches to reduce the network size by pruning the model. Hanson & Pratt (1989) use several bias techniques to decay weights in a network. LeCun et al. (1989) and Hassibi et al. (1993) both use Hessian-based approaches to prune weights below a certain threshold. Simpler approaches like sorting or thresholding can be used to prune a neural network. Han et al. (2015) and Liu et al. (2015) prune Convolution Neural Networks (CNNs) while maintaining high accuracy. Yu et al. (2012) use a hard threshold to prune deep learning models. Narang et al. (2017) and Zhu & Gupta (2017) prune recurrent neural networks during the initial training run with a small accuracy loss using gradual pruning. Unlike our technique, all of the above approaches induce random, unstructured sparsity in neural networks.
26
+
27
+ Several approaches exist to induce structured sparsity in neural networks. Mao et al. (2017) use a simple threshold based technique to create structurally sparse CNNs. Yu et al. (2017) propose Scalpel, which prunes CNNs taking into account the underlying target hardware architecture. Wen et al. (2017) alter the structure of LSTMs to create cells with smaller memory footprint. They demonstrate that this technique works for language modeling on the Penn Tree Bank dataset. Our approach works with both vanilla RNN and GRU models trained on a large-scale datasets for speech recognition.
28
+
29
+ Regularization is a known method to induce sparsity in deep neural networks (Faraone et al., 2017; Fan et al., 2016). Group lasso regularization has been used as an efficient method for generating sparse structures (Yuan & Lin, 2006b; Kim & Xing, 2010). Wen et al. (2016) use group lasso regularization to induce structured sparsity in CNNs. Scardapane et al. (2017) also use group lasso regularization to induce sparisty in fully connected networks. To the best of our knowledge, none of these approaches have been used with RNNs trained on large-scale datasets.
30
+
31
+ Other approaches to reduce compute and memory footprint for deep learning models include quantization (Micikevicius et al., 2017; Vanhoucke et al., 2011; Rastegari et al., 2016; Gupta et al., 2015) and low-rank factorization (Denil et al., 2013; Denton et al., 2014). Our approach is orthogonal to these methods and can be combined with them.
32
+
33
+ # 3 IMPLEMENTATION
34
+
35
+ # 3.1 BLOCK PRUNING
36
+
37
+ Our approach to pruning deep learning models builds on the work by Narang et al. (2017). They propose a weight pruning algorithm that introduces random, unstructured sparsity in RNNs. In their work, they propose pruning weights below a monotonically increasing threshold. Their pruning strategy does not impose any structure on the weights.
38
+
39
+ We extend this approach to prune blocks of a matrix instead of individual weights. We divide the weight matrix into a grid of two-dimensional blocks with a fixed block size. Block size ranges between $4 \times 4$ to $3 2 \times 3 2$ in our experiments. In order to prune blocks, we pick the weight with the maximum magnitude to represent the entire block. If this maximum magnitude of a block is below the threshold, we set all the weights in that block to zeros. Figure 1 depicts the process of generating a block-sparse mask from a weight matrix for a given threshold. The block-sparse mask is multiplied with the weights to generate block-sparse weight matrix. The monotonically growing threshold () causes more blocks to be pruned as training progresses. We stop pruning more blocks after $40 \%$ of training has completed. All zeroed out blocks are held at zero until the end of training.
40
+
41
+ ![](images/43956c67f51eedb731c5c97436e5b3e9cdfdf7c433163dc3796f60388fc1bb3a.jpg)
42
+ Figure 1: Generating block-sparse masks from a weight matrix
43
+
44
+ Table 1: Heuristics to pick hyper-parameters for block-pruning
45
+
46
+ <table><tr><td>HYPER-PARAM</td><td>DESCRIPTION</td><td>HEURISTICVALUES</td></tr><tr><td>start_itr ramp_itr</td><td>Iteration to start pruning</td><td>Start of second epoch Start of 20% of total epochs</td></tr><tr><td>end_itr</td><td>Iteration to increase the rate of pruning Iteration to stop pruning more parame-</td><td>Start of 40% of total epochs</td></tr><tr><td>start_slope</td><td>ters Initial rate of increasing the threshold</td><td>See Equation 2</td></tr><tr><td>(0) ramp_slope</td><td>Rate of increasing threshold after ramp</td><td>1.20 to 1.70</td></tr><tr><td>() freq</td><td>iteration Number of iterations after whiché is updated</td><td>100</td></tr></table>
47
+
48
+ Narang et al. (2017) use six hyper-parameters to determine the threshold at a given iteration. Table 1 provides the description and heuristics (adapted for block pruning) for these hyper-parameters. The start slope and ramp slope determine the rate at which the threshold increases. In order to determine start slope, they recommend using weights from an existing dense model. To achieve $90 \%$ sparsity, they assign $q$ to the weight that is the 90th percentile of the absolute values in a weight matrix. Assuming $\phi$ is $1 . 5 \theta$ , they use Equation 1 to determine $\theta$ .
49
+
50
+ $$
51
+ \theta = { \frac { 2 \times q \times f r e q } { 2 \times ( r a m p . i t r - s t a r t . i t r ) + 3 \times ( e n d . i t r - r a m p . i t r ) } }
52
+ $$
53
+
54
+ For block pruning, we need to modify the start slope to take into account the number of elements in a block $( N _ { b } )$ . In order to calculate the start slope, we first calculate start slope for weight pruning $( \theta _ { w } )$ using the Equation 1. Given $\theta _ { w }$ , we suggest using Equation 2 to determine the initial slope $( \theta _ { b } )$ for block pruning. Based on empirical results, we have found that using this approach allows us to achieve block sparsity ranging from $8 5 \%$ to $9 5 \%$ . Further tuning of these hyper-parameters is required to achieve desired block sparsity.
55
+
56
+ $$
57
+ \theta _ { b } = \theta _ { w } \times \sqrt [ 4 ] { N _ { b } }
58
+ $$
59
+
60
+ We prune all the recurrent and fully connected layers in the network using the same block size. The pruning hyper-parameters are same for each type of layer in the network — recurrent weight layer and linear or fully connected layer.
61
+
62
+ # 3.2 GROUP LASSO REGULARIZATION
63
+
64
+ Group lasso is a type of weight regularization that works on groups of weights. For each group, we add a loss term proportional to the $\ell _ { 2 }$ norm of the group.
65
+
66
+ $$
67
+ L = L _ { \mathrm { t r a i n i n g } } + \lambda _ { g } \sum _ { g = 1 } ^ { G } \| w ^ { ( g ) } \| _ { 2 }
68
+ $$
69
+
70
+ where $w ^ { ( g ) }$ is a group of weights, $\| w ^ { ( g ) } \| _ { 2 }$ is the $\ell _ { 2 }$ norm of the group, and $G$ is the total number of groups. Our use of $\ell _ { 2 }$ norm is a variant of the more general group lasso defined in Yuan & Lin (2006a) as $\| n \| _ { K } = ( n ^ { \prime } K n ) ^ { 1 / 2 }$ .
71
+
72
+ A large enough $\lambda _ { g }$ will drive all weights within certain groups to zeros. The choice of grouping varies by application, and group lasso is widely-used to induce various kinds of structured sparsity (Wen et al., 2017; Scardapane et al., 2017). By choosing groups to exactly match our 2D grid of blocks, we can induce block-sparsity. Thus, group lasso is an existing sparsity algorithm that we can readily compare to our block pruning approach.
73
+
74
+ In addition, we extend group lasso to work with block pruning. The groups match the 2D grid of blocks used by the pruning algorithm. One interpretation of weight regularization is that less important weights are driven towards zero and more important weights retain large absolute values. Thus, group lasso guides the selection of blocks to prune. We apply group lasso to coincide with the pruning schedule. We use a relatively small $\lambda _ { g }$ to avoid underfitting due to excessive regularization. We turn off group lasso when the pruning schedule ends, which is typically after around $40 \%$ o f training epochs. Weights that were already set to zero remain unchanged after this point.
75
+
76
+ Group lasso is related to the well-known $\ell _ { 1 }$ regularization. In Appendix A, we discuss exploration of $\ell _ { 1 }$ regularization combined with weight pruning.
77
+
78
+ # 4 EXPERIMENTS
79
+
80
+ We present results on two different applications: Speech Recognition (Section 4.1) and Language Modelling (Section 4.2).
81
+
82
+ # 4.1 SPEECH RECOGNITION
83
+
84
+ We run block sparsity experiments on two different speech recognition models from Amodei et al. (2016). The RNN model consists of seven bidirectional vanilla recurrent layers with 1760 hidden units for a total of 67 million parameters. The GRU model consists of three recurrent layers with GRU cells with 2560 hidden units for a total of 115 million parameters. Both models use the Connectionist Temporal Classification (CTC) (Graves et al., 2006) cost function. We use a training set of 2100 hours of speech and validation set of 3.46 hours. The Character Error Rate (CER) results are reported on an independent test set, consisting of 2.9 hours of English data.
85
+
86
+ In order to introduce block sparsity in these models, we run two different types of experiments — Block Pruning (BP) and Group Lasso with block pruning (GLP). We prune weights in the recurrent layers (both linear and recurrent weights) and fully connected layers. Biases, batch-normalization parameters and weights in the convolutional and CTC layers are not pruned since they account for a small portion of the total weights in the network. No existing hyper-parameter changes were required for sparse training runs. The models are trained using Nesterov Stochastic Gradient Descent (SGD) with momentum. All models are trained for 25 epochs.
87
+
88
+ In Section 4.1.1, we report results for different sparse models pruned with $4 \times 4$ blocks and compare these results with other pruning approaches. In Section 4.1.2, we discuss the impact of varying the block size on the accuracy of the model.
89
+
90
+ # 4.1.1 BLOCK SPARSITY
91
+
92
+ Initially, we prune the dense RNN model. Using BP, we are able to reduce the parameter count for both these models by nearly $1 0 \times$ . As shown in Table 2, the block-sparse RNN model with 1760 hidden units has an overall block sparsity of $89 \%$ with a CER of 17.93.
93
+
94
+ As mentioned in Section 3, group lasso by itself can induce block-sparsity. However, as shown in Table 2, group lasso results in significantly worse CER than our block pruning approach. In order to achieve high sparsity $80 \%$ or higher) with group lasso, we need to set $\lambda _ { g }$ to a relatively high value. This high regularization factor hurts the model accuracy. The dense baseline model is trained without any regularization. Therefore, group lasso results in underfitting the training data due to the high value of $\lambda _ { g }$ . Group lasso could be more successful in inducing block-sparsity where the dense model overfits the training dataset.
95
+
96
+ Table 2: Bidirectional RNN model results. Block-Sparse models are trained with 4x4 blocks
97
+
98
+ <table><tr><td>MODEL</td><td>LAYER SIZE</td><td># PARAMS (in millions)</td><td>CER (% LOSS)</td><td>EPOCHS</td><td>PRUNING ALGORITHM</td></tr><tr><td>RNN Dense</td><td>1760</td><td>67</td><td>15.36 (0.0%)</td><td>25</td><td>N/A</td></tr><tr><td>RNN Block-Sparse</td><td>1760</td><td>10.9</td><td>30.14 (-96%)</td><td>25</td><td>Group lasso</td></tr><tr><td>RNN Sparse</td><td>1760</td><td>8.3</td><td>18.91 (-23%)</td><td>25</td><td>Yu et al. (2012)</td></tr><tr><td>RNN Sparse</td><td>1760</td><td>7.3</td><td>17.32 (-13%)</td><td>25</td><td>Narang et al. (2017)</td></tr><tr><td>RNN Sparse</td><td>1760</td><td>7.1</td><td>15.41 (-0.3%)</td><td>60</td><td>Han et al. (2015)</td></tr><tr><td>RNN Block-Sparse</td><td>1760</td><td>7.3</td><td>17.93 (-17%)</td><td>25</td><td>Ours (BP)</td></tr><tr><td>RNN Block-Sparse</td><td>2560</td><td>12.9</td><td>15.89 (-3.4%)</td><td>25</td><td>Ours (GLP)</td></tr><tr><td>RNN Block-Sparse</td><td>3072</td><td>25.8</td><td>15.66 (-1.9%)</td><td>25</td><td>Ours (BP)</td></tr></table>
99
+
100
+ Table 3: GRU model results with $4 \times 4$ blocks
101
+
102
+ <table><tr><td>MODEL</td><td>LAYER SIZE</td><td>#PARAMS (in millions)</td><td>CER (% LOSS)</td><td>EPOCHS</td><td>PRUNING ALGORITHM</td></tr><tr><td>GRU Dense</td><td>2560</td><td>115</td><td>15.42 (0.0%)</td><td>25</td><td>N/A</td></tr><tr><td>GRU Block-Sparse</td><td>2560</td><td>10.8</td><td>16.78 (-8.8%)</td><td>25</td><td>Ours (GLP)</td></tr><tr><td>GRU Block-Sparse</td><td>3584</td><td>25.6</td><td>16.23 (-5.3%)</td><td>25</td><td>Ours (BP)</td></tr></table>
103
+
104
+ Comparison to other pruning methods: In addition to group lasso, we compare our block pruning approach with three existing pruning methods. As shown in Table 2, our block-sparse model achieves better accuracy than the hard thresholding scheme in Yu et al. (2012). Sparse RNNs generated using Narang et al. (2017) is about $4 \%$ better than the block-sparse model. The sparse RNN model generated using iterative pruning (Han et al., 2015) is significantly better than than blocksparse model. However, this approach requires training the model for 60 epochs instead of 25 epochs for all other approaches. This results in 180 hours of additional training time for the RNN model. This $2 { - } 3 \times$ increase in training time may not be practical for state-of-the-art models trained on large datasets, which usually need weeks of training time. Additionally, all the above approaches generate random, unstructured sparsity in the model. In current hardware, the compute and memory savings with block sparsity are significantly higher than random sparsity. We discuss the performance aspect in more detail in Section 5.
105
+
106
+ Larger models: In order to recover the accuracy loss with our approach, we train sparse models with more hidden units in each recurrent layers. For RNN models, we increase the hidden layer size to 2560 and 3072. As shown in Table 2, the RNN sparse 3072 is only $1 . 9 \%$ worse than the dense baseline model. The 2560 and 3072 sparse RNN models reduce the overall parameter count by $5 \times$ and $2 . 5 \times$ respectively relative to the dense model with 1760 hidden units in each layer.
107
+
108
+ GRU model: Similar to the RNN models, the block-sparse GRU model can reduce the overall parameter count by $1 1 \times$ . As shown in Table 3, the block-sparse GRU model achieves slightly higher sparsity $( 9 0 \% )$ with a CER of 16.23 which is only $9 \%$ worse than the dense GRU model. This indicates that the block-sparse GRU model retains most of the capacity of the dense model. As demonstrated with the RNN model, pruning a larger GRU model with 3584 hidden nodes reduces the accuracy loss to about $5 \%$ while still shrinking the model by $4 . 5 \times$ relative to the dense model with 2560 hidden nodes in each layer.
109
+
110
+ # 4.1.2 BLOCK SIZE VARIATION
111
+
112
+ Table 4 shows that block pruning works for block sizes upto $3 2 \times 3 2$ . Increasing the block size to $1 6 \times 1 6$ and $3 2 \times 3 2$ requires reducing the sparsity to $8 3 . 6 \%$ and $7 9 . 1 \%$ respectively for RNN models to obtain good accuracy. Similar results hold true for the GRU model as well. Large sparse blocks reduce memory overhead for storing non zero values and can take advantage of array data-paths in modern processors. Therefore, even though large blocks achieve lower sparsity, they result in lower memory and compute requirements.
113
+
114
+ Table 4: Results for GRU model with 2560 layer size and bidirectional RNN model with 170 layer size pruned with different block sizes using BP.
115
+
116
+ <table><tr><td>MODEL</td><td>BLOCK SIZE</td><td>#PARAMS (in millions)</td><td>SPARSITY</td><td>CER (% LOSS)</td></tr><tr><td></td><td></td><td></td><td></td><td></td></tr><tr><td>RNN Block-Sparse</td><td>4x4</td><td>7.3</td><td>89.2%</td><td>17.93 (-17%)</td></tr><tr><td>RNN Block-Sparse</td><td>12x2</td><td>10.8</td><td>84.1%</td><td>16.96 (-10%)</td></tr><tr><td>RNN Block-Sparse</td><td>8x8</td><td>10.7</td><td>84.1%</td><td>17.66 (-15%)</td></tr><tr><td>RNN Block-Sparse</td><td>16x16</td><td>11.1</td><td>83.6%</td><td>17.10 (-11%)</td></tr><tr><td>RNN Block-Sparse</td><td>32x32</td><td>14.1</td><td>79.1%</td><td>16.67 (-8.5%)</td></tr><tr><td>GRU Block-Sparse</td><td>4x4</td><td>16.2</td><td>86.0%</td><td>16.97 (-10%)</td></tr><tr><td>GRU Block-Sparse</td><td>16x16</td><td>20.8</td><td>81.9%</td><td>16.84 (-9.2%)</td></tr></table>
117
+
118
+ Table 5: Word language modelling results on Penn Tree Bank using BP for $4 \times 4$ blocks.
119
+
120
+ <table><tr><td>MODEL</td><td>LAYER SIZE</td><td># PARAMS (in millions)</td><td>PERPLEXITY (% LOSS)</td><td>EPOCHS</td><td>PRUNING ALGORITHM</td></tr><tr><td>LSTM Dense</td><td>1500</td><td>66.0</td><td>78.29 (0.0%)</td><td>55</td><td>N/A</td></tr><tr><td></td><td></td><td></td><td></td><td></td><td></td></tr><tr><td>LSTM Block-Sparse LSTM Block-Sparse</td><td>1500 1500</td><td>23.1 11.6</td><td>77.04 (1.6%) 80.25 (-2.5%)</td><td>55 55</td><td>Ours (BP) Ours (BP)</td></tr><tr><td>LSTM Block-Sparse</td><td>1500</td><td>7.95</td><td>82.72 (-5.7%)</td><td>55</td><td>Ours (BP)</td></tr><tr><td></td><td></td><td></td><td></td><td></td><td></td></tr></table>
121
+
122
+ The exact choice of block size for a given application depends on the underlying hardware used for inference. For example, NVIDIA’s Volta processor supports $1 6 \times 1 6$ blocks whereas ARM processors support blocks of $1 2 \mathbf { x } 2$ . We demonstrate that our approach is agnostic to block size and can be used to generate block-sparse models for arbitrary blocks.
123
+
124
+ # 4.2 NEURAL LANGUAGE MODELLING
125
+
126
+ We conducted block pruning experiments on Penn Tree Bank (PTB) (Marcus et al., 1993) dataset using word level language models. For our experiments, we use the large LSTM model with 1500 hidden units from Zaremba et al. (2014). The hyperparameters are unchanged from the original model, except for slightly increased dropout keep probability which ranges from 0.4 to 0.52 for the sparse models. We prune weights in the embedding, LSTM and softmax layers of the model.
127
+
128
+ We report results on the test set using BP with $4 \times 4$ blocks in Table 5. Block pruning can reduce the parameter count by nearly $3 \times$ while retaining the accuracy of the dense model. With a $5 \%$ loss in accuracy, we can reduce the parameter count by $8 . 3 \times$ . There is a trade-off between sparsity and accuracy of the model. For inference, we would pick the model that meets the desired memory and compute budget. Further work remains in evaluating this technique for large scale datasets like the Billion word datasets (Chelba et al., 2013) for language modelling.
129
+
130
+ # 5 PERFORMANCE
131
+
132
+ Sparse formats incur at least three types of overhead: i) indexing overhead, ii) irregular memory accesses, and ii) incompatibility with array-data-paths, all of which are mitigated by using larger block sizes.
133
+
134
+ Indexing Overheads. Sparse formats use extra memory to track the location of each non-zero value. For example, the compressed-sparse-row (CSR) format uses between one and two extra index values for each non-zero value. Assuming that neural network weights and indices are represented with 16-bits as in Micikevicius et al. (2017), this is at least $1 0 0 \%$ overhead. Block sparsity reduces this overhead by a factor of the block size because the index is shared over the entire block. For example, using a block size of 4x4 reduces the memory bloat to $6 . 2 5 \%$ , and using a block size of 16x16 reduces it to less than $1 \%$ .
135
+
136
+ Irregular Memory Accesses. Caches lines, DRAM row buffers, and TLBs provide the best performance when memory is accessed in relatively large contiguous units (e.g. 64 bytes for cache lines, 4KB for a DRAM row) as opposed to in fine-grained random accesses. Block-sparse formats store blocks contiguously in memory, resulting in large coalesced accesses.
137
+
138
+ Array Data-Paths. Block-sparse models make it easier to exploit array-data-paths in modern processors. There are significant advantages of using these units, for example, on the Volta V100 GPU, they enable up to ${ 8 } \mathbf { { x } }$ higher throughput than the SIMD data-paths. In order to keep these units busy, the block size should be at least as large as the hardware data-path size ( $1 6 \times 1 6$ or larger on V100).
139
+
140
+ # 5.1 INFERENCE PERFORMANCE
141
+
142
+ Inference performance depends of three different factors: accuracy, latency of evaluation and memory requirements. In order to understand the trade-off between unstructured sparsity and block sparsity, we benchmark the General Matrix Multiply (GEMM) speed-up and memory reduction for a single layer in the speech recongition RNN model. We evaluate GEMM speed-up with batch size of 16 using NVIDIA’s CuSparse and CuBLAS libraries on a TitanX Maxwell GPU. Sparse matrices are represented in CSR or Block-CSR format depending on the sparsity structure. Memory savings are calculated using CSR and Block Sparse Row (BSR) from Scipy module in Python. We evaluate a single layer with different block sizes. We also evaluate the best unstructured sparsity result obtained using iterative pruning from Han et al. (2015).
143
+
144
+ As shown in Table 6, the unstructured sparsity model (Han et al., 2015) achieves the best accuracy but requires much longer training time and does not improve the compute time relative to the dense model. For a small loss in accuracy, block-sparse models can significantly reduce both compute and memory requirements. For example, layers with 16x16 block sparsity reduce memory consumption by $1 1 \times$ and speedup compute by $3 \times$ with a $10 \%$ loss in accuracy. Additionally, Figure 2 shows that block-sparse matrices achieve higher speed-up than unstructured sparsity for large batch sizes for RNN and GRU layers. The speed-up is achieved due to reducing irregular memory accesses and improving load balance. Future work involves efficient implementation of block-sparse kernels to take advantage of array-data-paths in modern processors.
145
+
146
+ Table 6: Accuracy, speed-up and memory reduction for sparse layers. Block-sparse layers achieve higher speedup and memory reduction with some loss in accuracy.
147
+
148
+ <table><tr><td>MODEL</td><td>LAYER SIZE</td><td>GEMM SPEEDUP</td><td>MEMORY SAVINGS</td><td>CER (% LOSS)</td><td>ALGORITHM</td></tr><tr><td></td><td></td><td></td><td></td><td></td><td></td></tr><tr><td>RNN Sparse</td><td>1760</td><td>1.0×</td><td>5.0×</td><td>15.41 (-0.3%)</td><td>Han et al. (2015)</td></tr><tr><td>RNN Block-Sparse</td><td>2560</td><td>1.1×</td><td>6.2×</td><td>15.89 (-3.4%)</td><td>BP (4x4)</td></tr><tr><td>RNN Block-Sparse</td><td>1760</td><td>1.5×</td><td>7.1×</td><td>16.67 (-8.5%)</td><td>BP (32x32)</td></tr><tr><td>RNN Block-Sparse</td><td>1760</td><td>3.0×</td><td>11×</td><td>17.10 (-11%)</td><td>BP (16x16)</td></tr><tr><td>RNN Block-Sparse</td><td>1760</td><td>1.9×</td><td>17×</td><td>17.93 (-17%)</td><td>BP (4x4)</td></tr></table>
149
+
150
+ # 6 IMPACT OF SPARSITY ON ACCURACY
151
+
152
+ Using our baseline RNN model, we run many Weight Pruning (WP) (using (Narang et al., 2017)) and block pruning experiments, varying hyper-parameters to produce a spectrum of results ranging from $70 \%$ to $9 7 \%$ sparsity. For these experiments, the models are trained for 20 epochs and the accuracy is reported on the validation set. As shown in Figure 3, models pruned using WP with sparsity less than $9 5 \%$ have relative accuracy ranging from $- 2 0 \%$ to $- 2 7 \%$ . Increasing the sparsity for the model beyond $9 5 \%$ results in $30 \%$ or more accuracy loss. This “accuracy cliff” is earlier for models pruned with block sparsity. For block size $4 \times 4$ , models with sparsity greater $90 \%$ yield a relative accuracy loss of $30 \%$ or higher. Similarly, for blocks of $1 6 \times 1 6$ , models with sparsity greater than $86 \%$ have $30 \%$ or more accuracy loss. A similar trend is observed for block size $3 2 \times 3 2$ . This indicates that there is a trade-off between sparsity and block-size for a given accuracy. Larger blocks reach the “accuracy cliff” sooner.
153
+
154
+ ![](images/77a2c488c33a18b5241dc112abc22b35692143a9c4e257b6ad57b3b19de142c9.jpg)
155
+
156
+ ![](images/2fb7fe20bdf392368dff38691958bb0bfa2b419980f1fe202dcd8c0bacb3fdb6.jpg)
157
+ Figure 2: Speed-up for sparse matrix multiply over GEMM. RNN matrix sizes are (1760,1760) with $90 \%$ sparsity and (1760, batch size). GRU matrix sizes are (7680,2560) with $9 5 \%$ sparsity and (2560, batch size). Block-sparse matrices achieve consistently good speedup across batch-sizes
158
+ Figure 3: Relative accuracy for different block sizes (4x4, 16x16) and WP for varying sparsity on the RNN 1760 model. Any models with relative accuracy worse than $- 7 5 \%$ are capped at $7 5 \%$ .
159
+
160
+ # 7 CONCLUSION AND FUTURE WORK
161
+
162
+ We have demonstrated that using block pruning and group lasso combined with pruning during training can build block-sparse RNNs that are about as accurate as the dense baseline models. The block-sparse models have significantly fewer parameters than the dense baselines reducing memory requirements. Block-sparse models can take advantage of the underlying hardware efficiently.
163
+
164
+ We would like to investigate if pruning can be performed even earlier in the training, thereby allowing us to train sparse models. Training sparse models would allow us to reap the benefits of sparsity during training resulting in lesser compute and memory demands. Further work remains to implement efficient block-sparse matrix multiplies for array-data-paths in modern processors that would provide increased speed-up during deployment.
165
+
166
+ # REFERENCES
167
+
168
+ Dario Amodei, Rishita Anubhai, Eric Battenberg, Carl Case, Jared Casper, Bryan Catanzaro, JingDong Chen, Mike Chrzanowski, Adam Coates, Greg Diamos, et al. Deep speech 2: End-to-end speech recognition in english and mandarin. In Proceedings of The 33rd International Conference on Machine Learning, pp. 173–182, 2016.
169
+
170
+ Ciprian Chelba, Tomas Mikolov, Mike Schuster, Qi Ge, Thorsten Brants, Phillipp Koehn, and Tony Robinson. One billion word benchmark for measuring progress in statistical language modeling. Technical report, Google, 2013. URL http://arxiv.org/abs/1312.3005.
171
+
172
+ Kyunghyun Cho, Bart Van Merrienboer, Caglar Gulcehre, Dzmitry Bahdanau, Fethi Bougares, Holger ¨ Schwenk, and Yoshua Bengio. Learning phrase representations using rnn encoder-decoder for statistical machine translation. arXiv preprint arXiv:1406.1078, 2014.
173
+
174
+ Misha Denil, Babak Shakibi, Laurent Dinh, Marc’Aurelio Ranzato, and Nando de Freitas. Predicting parameters in deep learning. CoRR, abs/1306.0543, 2013. URL http://arxiv.org/abs/1306.0543.
175
+
176
+ Emily Denton, Wojciech Zaremba, Joan Bruna, Yann LeCun, and Rob Fergus. Exploiting linear structure within convolutional networks for efficient evaluation. CoRR, abs/1404.0736, 2014. URL http://arxiv.org/ abs/1404.0736.
177
+
178
+ Qinwei Fan, Wei Wu, and Jacek M Zurada. Convergence of batch gradient learning with smoothing regularization and adaptive momentum for neural networks. SpringerPlus, 5(1):295, 2016.
179
+
180
+ Julian Faraone, Nicholas Fraser, Giulio Gamberdella, Michaela Blott, and Philip HW Leong. Compressing low precision deep neural networks using sparsity-induced regularization in ternary networks. arXiv preprint arXiv:1709.06262, 2017.
181
+
182
+ Alex Graves, Santiago Fernandez, Faustino Gomez, and J ´ urgen Schmidhuber. Connectionist temporal classi-¨ fication: labelling unsegmented sequence data with recurrent neural networks. In Proceedings of the $2 3 r d$ international conference on Machine learning, pp. 369–376. ACM, 2006.
183
+
184
+ Suyog Gupta, Ankur Agrawal, Kailash Gopalakrishnan, and Pritish Narayanan. Deep learning with limited numerical precision. In Proceedings of the 32nd International Conference on Machine Learning (ICML15), pp. 1737–1746, 2015.
185
+
186
+ Song Han, Huizi Mao, and William J Dally. Deep compression: Compressing deep neural networks with pruning, trained quantization and huffman coding. arXiv preprint arXiv:1510.00149, 2015.
187
+
188
+ Stephen Jose Hanson and Lorien Pratt. Advances in neural information processing systems 1. chapter Com-´ paring Biases for Minimal Network Construction with Back-propagation, pp. 177–185. Morgan Kaufmann Publishers Inc., San Francisco, CA, USA, 1989. ISBN 1-558-60015-9. URL http://dl.acm.org/ citation.cfm?id $=$ 89851.89872.
189
+
190
+ Babak Hassibi, David G Stork, and Gregory J Wolff. Optimal brain surgeon and general network pruning. In Neural Networks, 1993., IEEE International Conference on, pp. 293–299. IEEE, 1993.
191
+
192
+ Sepp Hochreiter and Jurgen Schmidhuber. Long short-term memory. ¨ Neural Comput., 9(8):1735–1780, November 1997. ISSN 0899-7667. doi: 10.1162/neco.1997.9.8.1735. URL http://dx.doi.org/ 10.1162/neco.1997.9.8.1735.
193
+
194
+ Norman P. Jouppi, Cliff Young, Nishant Patil, David Patterson, Gaurav Agrawal, Raminder Bajwa, Sarah Bates, Suresh Bhatia, Nan Boden, Al Borchers, Rick Boyle, Pierre-luc Cantin, Clifford Chao, Chris Clark, Jeremy Coriell, Mike Daley, Matt Dau, Jeffrey Dean, Ben Gelb, Tara Vazir Ghaemmaghami, Rajendra Gottipati, William Gulland, Robert Hagmann, Richard C. Ho, Doug Hogberg, John Hu, Robert Hundt, Dan Hurt, Julian Ibarz, Aaron Jaffey, Alek Jaworski, Alexander Kaplan, Harshit Khaitan, Andy Koch, Naveen Kumar, Steve Lacy, James Laudon, James Law, Diemthu Le, Chris Leary, Zhuyuan Liu, Kyle Lucke, Alan Lundin, Gordon MacKean, Adriana Maggiore, Maire Mahony, Kieran Miller, Rahul Nagarajan, Ravi Narayanaswami, Ray Ni, Kathy Nix, Thomas Norrie, Mark Omernick, Narayana Penukonda, Andy Phelps, Jonathan Ross, Amir Salek, Emad Samadiani, Chris Severn, Gregory Sizikov, Matthew Snelham, Jed Souter, Dan Steinberg, Andy Swing, Mercedes Tan, Gregory Thorson, Bo Tian, Horia Toma, Erick Tuttle, Vijay Vasudevan, Richard Walter, Walter Wang, Eric Wilcox, and Doe Hyun Yoon. In-datacenter performance analysis of a tensor processing unit. CoRR, abs/1704.04760, 2017. URL http://arxiv.org/abs/1704.04760.
195
+
196
+ Rafal Jozefowicz, Oriol Vinyals, Mike Schuster, Noam Shazeer, and Yonghui Wu. Exploring the limits of ´ language modeling. CoRR, abs/1602.02410, 2016. URL http://arxiv.org/abs/1602.02410.
197
+
198
+ Seyoung Kim and Eric P Xing. Tree-guided group lasso for multi-task regression with structured sparsity. 2010.
199
+
200
+ Yann LeCun, John S Denker, Sara A Solla, Richard E Howard, and Lawrence D Jackel. Optimal brain damage. In NIPs, volume 2, pp. 598–605, 1989.
201
+
202
+ Baoyuan Liu, Min Wang, Hassan Foroosh, Marshall Tappen, and Marianna Pensky. Sparse convolutional neural networks. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pp. 806–814, 2015.
203
+
204
+ Huizi Mao, Song Han, Jeff Pool, Wenshuo Li, Xingyu Liu, Yu Wang, and William Dally. Exploring the regularity of sparse structure in convolutional neural networks. 05 2017.
205
+
206
+ Mitchell P Marcus, Mary Ann Marcinkiewicz, and Beatrice Santorini. Building a large annotated corpus of english: The penn treebank. Computational linguistics, 19(2):313–330, 1993.
207
+
208
+ P. Micikevicius, S. Narang, J. Alben, G. Diamos, E. Elsen, D. Garcia, B. Ginsburg, M. Houston, O. Kuchaiev, G. Venkatesh, and H. Wu. Mixed Precision Training. ArXiv e-prints, October 2017.
209
+
210
+ Sharan Narang and Gregory Diamos. Deepbench. https://svail.github.io/ DeepBench-update/, 2017. Accessed: 2017-06-28.
211
+
212
+ Sharan Narang, Gregory Diamos, Shubho Sengupta, and Erich Elsen. Exploring sparsity in recurrent neural networks. arXiv preprint arXiv:1704.05119, 2017.
213
+
214
+ NVIDIA. NVIDIA Tesla V100 GPU Architecture. Technical report, 2017.
215
+
216
+ Mohammad Rastegari, Vicente Ordonez, Joseph Redmon, and Ali Farhadi. XNOR-Net: ImageNet Classification Using Binary Convolutional Neural Networks, pp. 525–542. Springer International Publishing, Cham, 2016. ISBN 978-3-319-46493-0. doi: 10.1007/978-3-319-46493-0 32. URL https: //doi.org/10.1007/978-3-319-46493-0_32.
217
+
218
+ Simone Scardapane, Danilo Comminiello, Amir Hussain, and Aurelio Uncini. Group sparse regularization for deep neural networks. Neurocomputing, 241:81–89, 2017.
219
+
220
+ Vincent Vanhoucke, Andrew Senior, and Mark Z. Mao. Improving the speed of neural networks on cpus. In Deep Learning and Unsupervised Feature Learning Workshop, NIPS 2011, 2011.
221
+
222
+ Wei Wen, Chunpeng Wu, Yandan Wang, Yiran Chen, and Hai Li. Learning structured sparsity in deep neural networks. In Advances in Neural Information Processing Systems, pp. 2074–2082, 2016.
223
+
224
+ Wei Wen, Yuxiong He, Samyam Rajbhandari, Wenhan Wang, Fang Liu, Bin Hu, Yiran Chen, and Hai Li. Learning intrinsic sparse structures within long short-term memory. arXiv preprint arXiv:1709.05027, 2017.
225
+
226
+ Yonghui Wu, Mike Schuster, Zhifeng Chen, Quoc V. Le, Mohammad Norouzi, Wolfgang Macherey, Maxim Krikun, Yuan Cao, Qin Gao, Klaus Macherey, Jeff Klingner, Apurva Shah, Melvin Johnson, Xiaobing Liu, Lukasz Kaiser, Stephan Gouws, Yoshikiyo Kato, Taku Kudo, Hideto Kazawa, Keith Stevens, George Kurian, Nishant Patil, Wei Wang, Cliff Young, Jason Smith, Jason Riesa, Alex Rudnick, Oriol Vinyals, Greg Corrado, Macduff Hughes, and Jeffrey Dean. Google’s neural machine translation system: Bridging the gap between human and machine translation. CoRR, abs/1609.08144, 2016. URL http://arxiv.org/abs/1609. 08144.
227
+
228
+ Dong Yu, Frank Seide, Gang Li, and Li Deng. Exploiting sparseness in deep neural networks for large vocabulary speech recognition. In 2012 IEEE International Conference on Acoustics, Speech and Signal Processing (ICASSP), pp. 4409–4412. IEEE, 2012.
229
+
230
+ Jiecao Yu, Andrew Lukefahr, David Palframan, Ganesh Dasika, Reetuparna Das, and Scott Mahlke. Scalpel: Customizing dnn pruning to the underlying hardware parallelism. In Proceedings of the 44th Annual International Symposium on Computer Architecture, pp. 548–560. ACM, 2017.
231
+
232
+ Ming Yuan and Yi Lin. Model selection and estimation in regression with grouped variables. 2006a.
233
+
234
+ Ming Yuan and Yi Lin. Model selection and estimation in regression with grouped variables. Journal of the Royal Statistical Society: Series B (Statistical Methodology), 68(1):49–67, 2006b.
235
+
236
+ Wojciech Zaremba, Ilya Sutskever, and Oriol Vinyals. Recurrent neural network regularization. CoRR, abs/1409.2329, 2014. URL http://arxiv.org/abs/1409.2329.
237
+
238
+ Michael Zhu and Suyog Gupta. To prune, or not to prune: exploring the efficacy of pruning for model compression. arXiv preprint arXiv:1710.01878, 2017.
239
+
240
+ # A $\ell _ { 1 }$ AND $\ell _ { 1 / 2 }$ REGULARIZATION
241
+
242
+ Prior to our work with group lasso regularization, we considered $\ell _ { 1 }$ and $\ell _ { 1 / 2 }$ regularizers to induce sparsity in the network. These regularizers act on individual weights and could aid in inducing unstructured sparsity in the network. $\ell _ { 1 }$ regularization is defined as:
243
+
244
+ $$
245
+ L = L _ { \mathrm { t r a i n i n g } } + \lambda \sum _ { i = 1 } ^ { k } \left| w _ { i } \right|
246
+ $$
247
+
248
+ where $| w _ { i } |$ is the absolute value of a weight and $k$ is the total number of weights. Note the gradient expression for each weight $w _ { j }$ :
249
+
250
+ $$
251
+ { \frac { \partial } { \partial w _ { j } } } \sum _ { i = 1 } ^ { k } | w _ { i } | = s g n ( w _ { j } )
252
+ $$
253
+
254
+ As with the group lasso experiments described in 3.2, we explore $\ell _ { 1 }$ regularization with and without pruning. The weight pruning (WP) algorithm from Narang et al. (2017) is used along with regularization. The motivation is the same as group lasso block sparsity experiments: either to guide pruning or to produce sparsity directly.
255
+
256
+ We also explore $\ell _ { 1 / 2 }$ regularization which is defined as:
257
+
258
+ $$
259
+ L = L _ { \mathrm { t r a i n i n g } } + \lambda \sum _ { i = 1 } ^ { k } | w _ { i } | ^ { 1 / 2 }
260
+ $$
261
+
262
+ Fan et al. (2016) uses $\ell _ { 1 / 2 }$ regularization to produce sparsity directly. The gradient for $\ell _ { 1 / 2 }$ regularization is $\scriptstyle { \frac { 1 } { 2 } } \left| w _ { j } \right| ^ { - 1 / 2 }$ . This term is smaller for weights with larger magnitude. Our expectation is that $\ell _ { 1 / 2 }$ will drive unimportant weights towards zero while leaving large weights relatively unaffected, thus avoiding the accuracy loss associated with excessive regularization.
263
+
264
+ For our $\ell _ { 1 }$ and $\ell _ { 1 / 2 }$ experiments, we use the Deep Speech 2 Bidirectional RNN baseline model described in Section 4. These models are trained for 25 epochs on our internal training dataset of 2000 hours. The results are reported on a independent test set consisting of 2.9 hours.
265
+
266
+ Table 7: $\ell _ { 1 }$ and $\ell _ { 1 / 2 }$ results with the bidirectional RNN model with 1760 hidden units
267
+
268
+ <table><tr><td>MODEL</td><td>#PARAMS (in millions)</td><td>SPARSITY</td><td>CER</td><td>RELATIVE PERF</td><td>PRUNING ALGORITHM</td></tr><tr><td></td><td></td><td></td><td></td><td></td><td></td></tr><tr><td>RNN Dense</td><td>67</td><td>0.0%</td><td>15.36</td><td>0.0%</td><td>N/A</td></tr><tr><td>RNN Sparse</td><td>7.3</td><td>89.2%</td><td>17.32</td><td>-12.8%</td><td>Weight pruning</td></tr><tr><td>RNN Sparse</td><td>11.2</td><td>83.6%</td><td>24.8</td><td>-61.5%</td><td>l1</td></tr><tr><td>RNN Sparse</td><td>7.4</td><td>89.1%</td><td>17.28</td><td>-12.5%</td><td>l1 with pruning</td></tr><tr><td>RNN Sparse</td><td>6.6</td><td>90.3%</td><td>18.50</td><td>-20.4%</td><td>l1/2 with pruning</td></tr></table>
269
+
270
+ Without pruning, $\ell _ { 1 }$ model results in significantly worse accuracy compared to the dense baseline. Combining $\ell _ { 1 }$ with weight pruning allows us to recover the loss in accuracy with similar sparsity. The $\ell _ { 1 / 2 }$ with pruning model performs worse than the $\ell _ { 1 }$ with pruning model. Comparing the two regularizers, this result indicates that $\ell _ { 1 }$ is better at guiding pruning than $\ell _ { 1 / 2 }$ , more suitable as a regularizer, or both.
271
+
272
+ Similar to group lasso experiments, $\ell _ { 1 }$ regularization experiments require a significantly higher $\lambda$ to achieve high sparsity without any pruning. We suspect that these regularizers would be more successful in inducing sparsity for models that overfit the training training dataset.
273
+
274
+ # B PRUNING CHARACTERISTICS
275
+
276
+ In this section, we discuss some pruning characteristics and how they relate to training and accuracy of the models.
277
+
278
+ # B.1 PRUNING SCHEDULE
279
+
280
+ In Figure 4a, we plot the pruning schedule of a recurrent and linear layer of the bidirectional model trained with Block Pruning (BP) and Weight Pruning (WP) (Narang et al., 2017) and Group lasso with block pruning (GLP). For all three algorithms, pruning begins just after the first epoch at 2700 iterations. The BP and GLP models result in a sharper curve with more weights being set to zero in a short span of iterations. In these experiments, we use the max function to reduce the blocks to a single value which could be the cause of the sharpness in pruning. Also the GLP model reaches $90 \%$ sparsity just before 10,000 iterations which is significantly earlier than the BP model. GLP training encourages sparsity early on in the training run by pushing the blocks of weights towards zero.
281
+
282
+ # B.2 OUTPUT CONNECTIONS
283
+
284
+ Figure 4b shows the histogram of the number of output connections for all the neurons in a network for two models with different sparsity pruned with BP. The $94 \%$ sparse model does significantly worse than the $89 \%$ sparse. For the model with $89 \%$ sparsity, only 180 neurons have all their output weights set to zero out of a total of 38270. This model produced good accuracy relative to the dense baseline. However, increasing the sparsity to $94 \%$ for the layer results in 1620 neurons having all zero output weights. Additionally, a lot more neurons have a smaller number of non-zero output weights.
285
+
286
+ ![](images/cf8909cb8007d8c56d86178dbf5138a82bbc5a635c84dcf15624555460165d5b.jpg)
287
+ Figure 4: Figure 4a shows the pruning schedule for two layers in the network for WP, GLP and BP models. The GLP and BP models use block size of $4 \mathbf { x } 4$ . Figure 4b plots the histogram of the number of output connections for all neurons in the network using block pruning with $4 \times 4$ blocks.
288
+
289
+ # B.3 SPARSITY VS LAYERS
290
+
291
+ Figure 5 shows the sparsity of all the recurrent layers in the network using BP and WP. All recurrent layers have the same pruning hyper-parameters. Layer 1 is the first recurrent layer and layer 14 is the final recurrent layer before the CTC cost layer. For both block pruning and weight pruning, we see that the initial layers are pruned more aggressively compared to the final layers. Increasing sparsity in the layers closer to the output results in poor accuracy. Additionally, the variance in sparsity across the layers increases with the block size. This increasing variance makes it harder to increase the block size beyond $3 2 \times 3 2$ with the same pruning hyper-parameters for all recurrent layers.
292
+
293
+ ![](images/e29ca40fca4c38e0eac458b2a8d3b7dfbe2215d5a98cc4e29b9ba5ef4b5aaa2f.jpg)
294
+ Figure 5: Sparsity of different recurrent layers in the network in the RNN model, pruned using BP and WP.
parse/train/HJaDJZ-0W/HJaDJZ-0W_content_list.json ADDED
@@ -0,0 +1,1593 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [
2
+ {
3
+ "type": "text",
4
+ "text": "BLOCK-SPARSE RECURRENT NEURAL NETWORKS",
5
+ "text_level": 1,
6
+ "bbox": [
7
+ 173,
8
+ 98,
9
+ 779,
10
+ 121
11
+ ],
12
+ "page_idx": 0
13
+ },
14
+ {
15
+ "type": "text",
16
+ "text": "Anonymous authors Paper under double-blind review ",
17
+ "bbox": [
18
+ 183,
19
+ 145,
20
+ 398,
21
+ 172
22
+ ],
23
+ "page_idx": 0
24
+ },
25
+ {
26
+ "type": "text",
27
+ "text": "ABSTRACT ",
28
+ "text_level": 1,
29
+ "bbox": [
30
+ 454,
31
+ 209,
32
+ 544,
33
+ 226
34
+ ],
35
+ "page_idx": 0
36
+ },
37
+ {
38
+ "type": "text",
39
+ "text": "Recurrent Neural Networks (RNNs) are used in state-of-the-art models in domains such as speech recognition, machine translation, and language modelling. Sparsity is a technique to reduce compute and memory requirements of deep learning models. Sparse RNNs are easier to deploy on devices and high-end server processors. Even though sparse operations need less compute and memory relative to their dense counterparts, the speed-up observed by using sparse operations is less than expected on different hardware platforms. In order to address this issue, we investigate two different approaches to induce block sparsity in RNNs: pruning blocks of weights in a layer and using group lasso regularization with pruning to create blocks of weights with zeros. Using these techniques, we can create block-sparse RNNs with sparsity ranging from $80 \\%$ to $90 \\%$ with a small loss in accuracy. This technique allows us to reduce the model size by roughly $1 0 \\times$ . Additionally, we can prune a larger dense network to recover this loss in accuracy while maintaining high block sparsity and reducing the overall parameter count. Our technique works with a variety of block sizes up to $3 2 \\times 3 2$ . Block-sparse RNNs eliminate overheads related to data storage and irregular memory accesses while increasing hardware efficiency compared to unstructured sparsity. ",
40
+ "bbox": [
41
+ 233,
42
+ 239,
43
+ 764,
44
+ 477
45
+ ],
46
+ "page_idx": 0
47
+ },
48
+ {
49
+ "type": "text",
50
+ "text": "1 INTRODUCTION ",
51
+ "text_level": 1,
52
+ "bbox": [
53
+ 176,
54
+ 502,
55
+ 336,
56
+ 517
57
+ ],
58
+ "page_idx": 0
59
+ },
60
+ {
61
+ "type": "text",
62
+ "text": "Improvements in several applications such as speech recognition (Amodei et al., 2016), language modeling (Jozefowicz et al. ´ , 2016), and machine translation (Wu et al., 2016) are a result of large Recurrent Neural Networks (RNNs) trained on large scale datasets. As the datasets available to train these models have grown, so have model sizes. Deployment of such large models is compute and memory intensive. ",
63
+ "bbox": [
64
+ 174,
65
+ 532,
66
+ 823,
67
+ 603
68
+ ],
69
+ "page_idx": 0
70
+ },
71
+ {
72
+ "type": "text",
73
+ "text": "Pruning weights of deep neural networks is an effective strategy to reduce the overall memory and compute requirements of these models (Narang et al., 2017; Han et al., 2015). However, these approaches induce random, unstructured sparsity in the weight matrices. Speed-up obtained with unstructured sparsity on various hardware platforms are often lower than expected (as shown in Narang et al. (2017); Narang & Diamos (2017)). Sparse formats do not efficiently utilize the hardware resources due to storage overheads and irregular memory access. Block sparsity can address these issues. Saving indices of non-zero blocks instead of indices for non-zero elements reduces the storage overhead by a factor of block size. Block-sparse formats store blocks contiguously in memory reducing irregular memory accesses. ",
74
+ "bbox": [
75
+ 174,
76
+ 609,
77
+ 825,
78
+ 734
79
+ ],
80
+ "page_idx": 0
81
+ },
82
+ {
83
+ "type": "text",
84
+ "text": "Another disadvantage of unstructured sparsity is that it cannot directly exploit array-data-paths in modern processors. These include the $1 6 \\times 1 6$ TensorCore units in the Volta GPU (NVIDIA, 2017) or the $2 5 6 \\times 2 5 6$ hardware units in the Tensor Processing Unit (TPU) (Jouppi et al., 2017). Structured sparsity in the form of two-dimensional blocks allows us to take advantage of these faster units. ",
85
+ "bbox": [
86
+ 174,
87
+ 742,
88
+ 823,
89
+ 797
90
+ ],
91
+ "page_idx": 0
92
+ },
93
+ {
94
+ "type": "text",
95
+ "text": "In order to induce block sparsity in RNNs, we propose a block pruning approach that zeros out blocks of weights in the matrix while the network is training. At the end of training, the algorithm creates a block-sparse RNN. In addition to this pruning technique, we examine the efficacy of group lasso regularization (Yuan & Lin, 2006b) to induce block sparsity in the network. We also combine group lasso regularization with block pruning. ",
96
+ "bbox": [
97
+ 174,
98
+ 805,
99
+ 823,
100
+ 875
101
+ ],
102
+ "page_idx": 0
103
+ },
104
+ {
105
+ "type": "text",
106
+ "text": "We demonstrate that block pruning and group lasso regularization with pruning are successful in creating block-sparse RNNs. Inducing block sparsity with $4 \\times 4$ blocks in vanilla RNNs and Gated Recurrent Units (GRUs) (Cho et al., 2014) results in $9 \\%$ to $17 \\%$ loss in accuracy compared to the dense baseline. Model size reduces by nearly $1 0 \\times$ for speech recognition. Block sizes can be scaled up to $3 2 \\times 3 2$ with our approach. We can also reduce accuracy loss by starting with a larger dense matrix than the baseline and then pruning it down while still reducing the number of parameters compared to the baseline. We demonstrate that this approach works with Long Short Term Memory (LSTM) (Hochreiter & Schmidhuber, 1997) cells for Language Modelling as well. ",
107
+ "bbox": [
108
+ 176,
109
+ 882,
110
+ 823,
111
+ 922
112
+ ],
113
+ "page_idx": 0
114
+ },
115
+ {
116
+ "type": "text",
117
+ "text": "",
118
+ "bbox": [
119
+ 174,
120
+ 103,
121
+ 825,
122
+ 174
123
+ ],
124
+ "page_idx": 1
125
+ },
126
+ {
127
+ "type": "text",
128
+ "text": "Our approach is agnostic to the optimization algorithm and does not require any hyper-parameter retuning (besides pruning and regularization hyper-parameters). Furthermore, since our approach does not require re-training the model, training time remains constant. ",
129
+ "bbox": [
130
+ 176,
131
+ 180,
132
+ 823,
133
+ 223
134
+ ],
135
+ "page_idx": 1
136
+ },
137
+ {
138
+ "type": "text",
139
+ "text": "2 RELATED WORK ",
140
+ "text_level": 1,
141
+ "bbox": [
142
+ 176,
143
+ 242,
144
+ 344,
145
+ 258
146
+ ],
147
+ "page_idx": 1
148
+ },
149
+ {
150
+ "type": "text",
151
+ "text": "There have been several approaches to reduce the network size by pruning the model. Hanson & Pratt (1989) use several bias techniques to decay weights in a network. LeCun et al. (1989) and Hassibi et al. (1993) both use Hessian-based approaches to prune weights below a certain threshold. Simpler approaches like sorting or thresholding can be used to prune a neural network. Han et al. (2015) and Liu et al. (2015) prune Convolution Neural Networks (CNNs) while maintaining high accuracy. Yu et al. (2012) use a hard threshold to prune deep learning models. Narang et al. (2017) and Zhu & Gupta (2017) prune recurrent neural networks during the initial training run with a small accuracy loss using gradual pruning. Unlike our technique, all of the above approaches induce random, unstructured sparsity in neural networks. ",
152
+ "bbox": [
153
+ 174,
154
+ 273,
155
+ 825,
156
+ 400
157
+ ],
158
+ "page_idx": 1
159
+ },
160
+ {
161
+ "type": "text",
162
+ "text": "Several approaches exist to induce structured sparsity in neural networks. Mao et al. (2017) use a simple threshold based technique to create structurally sparse CNNs. Yu et al. (2017) propose Scalpel, which prunes CNNs taking into account the underlying target hardware architecture. Wen et al. (2017) alter the structure of LSTMs to create cells with smaller memory footprint. They demonstrate that this technique works for language modeling on the Penn Tree Bank dataset. Our approach works with both vanilla RNN and GRU models trained on a large-scale datasets for speech recognition. ",
163
+ "bbox": [
164
+ 174,
165
+ 406,
166
+ 825,
167
+ 503
168
+ ],
169
+ "page_idx": 1
170
+ },
171
+ {
172
+ "type": "text",
173
+ "text": "Regularization is a known method to induce sparsity in deep neural networks (Faraone et al., 2017; Fan et al., 2016). Group lasso regularization has been used as an efficient method for generating sparse structures (Yuan & Lin, 2006b; Kim & Xing, 2010). Wen et al. (2016) use group lasso regularization to induce structured sparsity in CNNs. Scardapane et al. (2017) also use group lasso regularization to induce sparisty in fully connected networks. To the best of our knowledge, none of these approaches have been used with RNNs trained on large-scale datasets. ",
174
+ "bbox": [
175
+ 174,
176
+ 511,
177
+ 825,
178
+ 594
179
+ ],
180
+ "page_idx": 1
181
+ },
182
+ {
183
+ "type": "text",
184
+ "text": "Other approaches to reduce compute and memory footprint for deep learning models include quantization (Micikevicius et al., 2017; Vanhoucke et al., 2011; Rastegari et al., 2016; Gupta et al., 2015) and low-rank factorization (Denil et al., 2013; Denton et al., 2014). Our approach is orthogonal to these methods and can be combined with them. ",
185
+ "bbox": [
186
+ 174,
187
+ 602,
188
+ 825,
189
+ 657
190
+ ],
191
+ "page_idx": 1
192
+ },
193
+ {
194
+ "type": "text",
195
+ "text": "3 IMPLEMENTATION ",
196
+ "text_level": 1,
197
+ "bbox": [
198
+ 176,
199
+ 679,
200
+ 356,
201
+ 694
202
+ ],
203
+ "page_idx": 1
204
+ },
205
+ {
206
+ "type": "text",
207
+ "text": "3.1 BLOCK PRUNING ",
208
+ "text_level": 1,
209
+ "bbox": [
210
+ 176,
211
+ 709,
212
+ 334,
213
+ 723
214
+ ],
215
+ "page_idx": 1
216
+ },
217
+ {
218
+ "type": "text",
219
+ "text": "Our approach to pruning deep learning models builds on the work by Narang et al. (2017). They propose a weight pruning algorithm that introduces random, unstructured sparsity in RNNs. In their work, they propose pruning weights below a monotonically increasing threshold. Their pruning strategy does not impose any structure on the weights. ",
220
+ "bbox": [
221
+ 174,
222
+ 734,
223
+ 823,
224
+ 791
225
+ ],
226
+ "page_idx": 1
227
+ },
228
+ {
229
+ "type": "text",
230
+ "text": "We extend this approach to prune blocks of a matrix instead of individual weights. We divide the weight matrix into a grid of two-dimensional blocks with a fixed block size. Block size ranges between $4 \\times 4$ to $3 2 \\times 3 2$ in our experiments. In order to prune blocks, we pick the weight with the maximum magnitude to represent the entire block. If this maximum magnitude of a block is below the threshold, we set all the weights in that block to zeros. Figure 1 depicts the process of generating a block-sparse mask from a weight matrix for a given threshold. The block-sparse mask is multiplied with the weights to generate block-sparse weight matrix. The monotonically growing threshold (\u000f) causes more blocks to be pruned as training progresses. We stop pruning more blocks after $40 \\%$ of training has completed. All zeroed out blocks are held at zero until the end of training. ",
231
+ "bbox": [
232
+ 174,
233
+ 797,
234
+ 825,
235
+ 924
236
+ ],
237
+ "page_idx": 1
238
+ },
239
+ {
240
+ "type": "image",
241
+ "img_path": "images/43956c67f51eedb731c5c97436e5b3e9cdfdf7c433163dc3796f60388fc1bb3a.jpg",
242
+ "image_caption": [
243
+ "Figure 1: Generating block-sparse masks from a weight matrix "
244
+ ],
245
+ "image_footnote": [],
246
+ "bbox": [
247
+ 217,
248
+ 109,
249
+ 774,
250
+ 220
251
+ ],
252
+ "page_idx": 2
253
+ },
254
+ {
255
+ "type": "text",
256
+ "text": "Table 1: Heuristics to pick hyper-parameters for block-pruning ",
257
+ "bbox": [
258
+ 292,
259
+ 277,
260
+ 705,
261
+ 292
262
+ ],
263
+ "page_idx": 2
264
+ },
265
+ {
266
+ "type": "table",
267
+ "img_path": "images/3bc8d4ecfd5d412eb9978b14fdaba629feca65bb2212cae8e83ee8fa3c0b3803.jpg",
268
+ "table_caption": [],
269
+ "table_footnote": [],
270
+ "table_body": "<table><tr><td>HYPER-PARAM</td><td>DESCRIPTION</td><td>HEURISTICVALUES</td></tr><tr><td>start_itr ramp_itr</td><td>Iteration to start pruning</td><td>Start of second epoch Start of 20% of total epochs</td></tr><tr><td>end_itr</td><td>Iteration to increase the rate of pruning Iteration to stop pruning more parame-</td><td>Start of 40% of total epochs</td></tr><tr><td>start_slope</td><td>ters Initial rate of increasing the threshold</td><td>See Equation 2</td></tr><tr><td>(0) ramp_slope</td><td>Rate of increasing threshold after ramp</td><td>1.20 to 1.70</td></tr><tr><td>() freq</td><td>iteration Number of iterations after whiché is updated</td><td>100</td></tr></table>",
271
+ "bbox": [
272
+ 205,
273
+ 306,
274
+ 787,
275
+ 464
276
+ ],
277
+ "page_idx": 2
278
+ },
279
+ {
280
+ "type": "text",
281
+ "text": "Narang et al. (2017) use six hyper-parameters to determine the threshold at a given iteration. Table 1 provides the description and heuristics (adapted for block pruning) for these hyper-parameters. The start slope and ramp slope determine the rate at which the threshold increases. In order to determine start slope, they recommend using weights from an existing dense model. To achieve $90 \\%$ sparsity, they assign $q$ to the weight that is the 90th percentile of the absolute values in a weight matrix. Assuming $\\phi$ is $1 . 5 \\theta$ , they use Equation 1 to determine $\\theta$ . ",
282
+ "bbox": [
283
+ 173,
284
+ 494,
285
+ 826,
286
+ 579
287
+ ],
288
+ "page_idx": 2
289
+ },
290
+ {
291
+ "type": "equation",
292
+ "img_path": "images/a436ed365ead1c7b7dcbbb3b9e0f93f54d9a5b8b478b270fca4355b82c3f7567.jpg",
293
+ "text": "$$\n\\theta = { \\frac { 2 \\times q \\times f r e q } { 2 \\times ( r a m p . i t r - s t a r t . i t r ) + 3 \\times ( e n d . i t r - r a m p . i t r ) } }\n$$",
294
+ "text_format": "latex",
295
+ "bbox": [
296
+ 290,
297
+ 593,
298
+ 705,
299
+ 628
300
+ ],
301
+ "page_idx": 2
302
+ },
303
+ {
304
+ "type": "text",
305
+ "text": "For block pruning, we need to modify the start slope to take into account the number of elements in a block $( N _ { b } )$ . In order to calculate the start slope, we first calculate start slope for weight pruning $( \\theta _ { w } )$ using the Equation 1. Given $\\theta _ { w }$ , we suggest using Equation 2 to determine the initial slope $( \\theta _ { b } )$ for block pruning. Based on empirical results, we have found that using this approach allows us to achieve block sparsity ranging from $8 5 \\%$ to $9 5 \\%$ . Further tuning of these hyper-parameters is required to achieve desired block sparsity. ",
306
+ "bbox": [
307
+ 173,
308
+ 636,
309
+ 825,
310
+ 720
311
+ ],
312
+ "page_idx": 2
313
+ },
314
+ {
315
+ "type": "equation",
316
+ "img_path": "images/26814ee1bcd93d236fac4ee20ed14e8de94f12748931fb8650cdfcb6b7a4d55a.jpg",
317
+ "text": "$$\n\\theta _ { b } = \\theta _ { w } \\times \\sqrt [ 4 ] { N _ { b } }\n$$",
318
+ "text_format": "latex",
319
+ "bbox": [
320
+ 441,
321
+ 736,
322
+ 558,
323
+ 757
324
+ ],
325
+ "page_idx": 2
326
+ },
327
+ {
328
+ "type": "text",
329
+ "text": "We prune all the recurrent and fully connected layers in the network using the same block size. The pruning hyper-parameters are same for each type of layer in the network — recurrent weight layer and linear or fully connected layer. ",
330
+ "bbox": [
331
+ 174,
332
+ 765,
333
+ 826,
334
+ 809
335
+ ],
336
+ "page_idx": 2
337
+ },
338
+ {
339
+ "type": "text",
340
+ "text": "3.2 GROUP LASSO REGULARIZATION ",
341
+ "text_level": 1,
342
+ "bbox": [
343
+ 176,
344
+ 824,
345
+ 446,
346
+ 839
347
+ ],
348
+ "page_idx": 2
349
+ },
350
+ {
351
+ "type": "text",
352
+ "text": "Group lasso is a type of weight regularization that works on groups of weights. For each group, we add a loss term proportional to the $\\ell _ { 2 }$ norm of the group. ",
353
+ "bbox": [
354
+ 173,
355
+ 849,
356
+ 823,
357
+ 880
358
+ ],
359
+ "page_idx": 2
360
+ },
361
+ {
362
+ "type": "equation",
363
+ "img_path": "images/d418c7fafb095bf947654b163eb81c3905829602f64f3d43c6c46e850fdd0da7.jpg",
364
+ "text": "$$\nL = L _ { \\mathrm { t r a i n i n g } } + \\lambda _ { g } \\sum _ { g = 1 } ^ { G } \\| w ^ { ( g ) } \\| _ { 2 }\n$$",
365
+ "text_format": "latex",
366
+ "bbox": [
367
+ 397,
368
+ 883,
369
+ 599,
370
+ 928
371
+ ],
372
+ "page_idx": 2
373
+ },
374
+ {
375
+ "type": "text",
376
+ "text": "where $w ^ { ( g ) }$ is a group of weights, $\\| w ^ { ( g ) } \\| _ { 2 }$ is the $\\ell _ { 2 }$ norm of the group, and $G$ is the total number of groups. Our use of $\\ell _ { 2 }$ norm is a variant of the more general group lasso defined in Yuan & Lin (2006a) as $\\| n \\| _ { K } = ( n ^ { \\prime } K n ) ^ { 1 / 2 }$ . ",
377
+ "bbox": [
378
+ 174,
379
+ 102,
380
+ 825,
381
+ 147
382
+ ],
383
+ "page_idx": 3
384
+ },
385
+ {
386
+ "type": "text",
387
+ "text": "A large enough $\\lambda _ { g }$ will drive all weights within certain groups to zeros. The choice of grouping varies by application, and group lasso is widely-used to induce various kinds of structured sparsity (Wen et al., 2017; Scardapane et al., 2017). By choosing groups to exactly match our 2D grid of blocks, we can induce block-sparsity. Thus, group lasso is an existing sparsity algorithm that we can readily compare to our block pruning approach. ",
388
+ "bbox": [
389
+ 174,
390
+ 154,
391
+ 825,
392
+ 224
393
+ ],
394
+ "page_idx": 3
395
+ },
396
+ {
397
+ "type": "text",
398
+ "text": "In addition, we extend group lasso to work with block pruning. The groups match the 2D grid of blocks used by the pruning algorithm. One interpretation of weight regularization is that less important weights are driven towards zero and more important weights retain large absolute values. Thus, group lasso guides the selection of blocks to prune. We apply group lasso to coincide with the pruning schedule. We use a relatively small $\\lambda _ { g }$ to avoid underfitting due to excessive regularization. We turn off group lasso when the pruning schedule ends, which is typically after around $40 \\%$ o f training epochs. Weights that were already set to zero remain unchanged after this point. ",
399
+ "bbox": [
400
+ 174,
401
+ 231,
402
+ 825,
403
+ 328
404
+ ],
405
+ "page_idx": 3
406
+ },
407
+ {
408
+ "type": "text",
409
+ "text": "Group lasso is related to the well-known $\\ell _ { 1 }$ regularization. In Appendix A, we discuss exploration of $\\ell _ { 1 }$ regularization combined with weight pruning. ",
410
+ "bbox": [
411
+ 174,
412
+ 335,
413
+ 823,
414
+ 363
415
+ ],
416
+ "page_idx": 3
417
+ },
418
+ {
419
+ "type": "text",
420
+ "text": "4 EXPERIMENTS ",
421
+ "text_level": 1,
422
+ "bbox": [
423
+ 176,
424
+ 383,
425
+ 326,
426
+ 398
427
+ ],
428
+ "page_idx": 3
429
+ },
430
+ {
431
+ "type": "text",
432
+ "text": "We present results on two different applications: Speech Recognition (Section 4.1) and Language Modelling (Section 4.2). ",
433
+ "bbox": [
434
+ 176,
435
+ 415,
436
+ 823,
437
+ 444
438
+ ],
439
+ "page_idx": 3
440
+ },
441
+ {
442
+ "type": "text",
443
+ "text": "4.1 SPEECH RECOGNITION ",
444
+ "text_level": 1,
445
+ "bbox": [
446
+ 176,
447
+ 460,
448
+ 374,
449
+ 474
450
+ ],
451
+ "page_idx": 3
452
+ },
453
+ {
454
+ "type": "text",
455
+ "text": "We run block sparsity experiments on two different speech recognition models from Amodei et al. (2016). The RNN model consists of seven bidirectional vanilla recurrent layers with 1760 hidden units for a total of 67 million parameters. The GRU model consists of three recurrent layers with GRU cells with 2560 hidden units for a total of 115 million parameters. Both models use the Connectionist Temporal Classification (CTC) (Graves et al., 2006) cost function. We use a training set of 2100 hours of speech and validation set of 3.46 hours. The Character Error Rate (CER) results are reported on an independent test set, consisting of 2.9 hours of English data. ",
456
+ "bbox": [
457
+ 174,
458
+ 487,
459
+ 825,
460
+ 584
461
+ ],
462
+ "page_idx": 3
463
+ },
464
+ {
465
+ "type": "text",
466
+ "text": "In order to introduce block sparsity in these models, we run two different types of experiments — Block Pruning (BP) and Group Lasso with block pruning (GLP). We prune weights in the recurrent layers (both linear and recurrent weights) and fully connected layers. Biases, batch-normalization parameters and weights in the convolutional and CTC layers are not pruned since they account for a small portion of the total weights in the network. No existing hyper-parameter changes were required for sparse training runs. The models are trained using Nesterov Stochastic Gradient Descent (SGD) with momentum. All models are trained for 25 epochs. ",
467
+ "bbox": [
468
+ 174,
469
+ 590,
470
+ 825,
471
+ 689
472
+ ],
473
+ "page_idx": 3
474
+ },
475
+ {
476
+ "type": "text",
477
+ "text": "In Section 4.1.1, we report results for different sparse models pruned with $4 \\times 4$ blocks and compare these results with other pruning approaches. In Section 4.1.2, we discuss the impact of varying the block size on the accuracy of the model. ",
478
+ "bbox": [
479
+ 176,
480
+ 695,
481
+ 825,
482
+ 737
483
+ ],
484
+ "page_idx": 3
485
+ },
486
+ {
487
+ "type": "text",
488
+ "text": "4.1.1 BLOCK SPARSITY ",
489
+ "text_level": 1,
490
+ "bbox": [
491
+ 176,
492
+ 752,
493
+ 351,
494
+ 767
495
+ ],
496
+ "page_idx": 3
497
+ },
498
+ {
499
+ "type": "text",
500
+ "text": "Initially, we prune the dense RNN model. Using BP, we are able to reduce the parameter count for both these models by nearly $1 0 \\times$ . As shown in Table 2, the block-sparse RNN model with 1760 hidden units has an overall block sparsity of $89 \\%$ with a CER of 17.93. ",
501
+ "bbox": [
502
+ 176,
503
+ 776,
504
+ 823,
505
+ 819
506
+ ],
507
+ "page_idx": 3
508
+ },
509
+ {
510
+ "type": "text",
511
+ "text": "As mentioned in Section 3, group lasso by itself can induce block-sparsity. However, as shown in Table 2, group lasso results in significantly worse CER than our block pruning approach. In order to achieve high sparsity $80 \\%$ or higher) with group lasso, we need to set $\\lambda _ { g }$ to a relatively high value. This high regularization factor hurts the model accuracy. The dense baseline model is trained without any regularization. Therefore, group lasso results in underfitting the training data due to the high value of $\\lambda _ { g }$ . Group lasso could be more successful in inducing block-sparsity where the dense model overfits the training dataset. ",
512
+ "bbox": [
513
+ 174,
514
+ 825,
515
+ 825,
516
+ 924
517
+ ],
518
+ "page_idx": 3
519
+ },
520
+ {
521
+ "type": "table",
522
+ "img_path": "images/7459d830a8685f062d82f3db89e95e353bce7c3fdce34366c9bc4320c19dc0a5.jpg",
523
+ "table_caption": [
524
+ "Table 2: Bidirectional RNN model results. Block-Sparse models are trained with 4x4 blocks "
525
+ ],
526
+ "table_footnote": [],
527
+ "table_body": "<table><tr><td>MODEL</td><td>LAYER SIZE</td><td># PARAMS (in millions)</td><td>CER (% LOSS)</td><td>EPOCHS</td><td>PRUNING ALGORITHM</td></tr><tr><td>RNN Dense</td><td>1760</td><td>67</td><td>15.36 (0.0%)</td><td>25</td><td>N/A</td></tr><tr><td>RNN Block-Sparse</td><td>1760</td><td>10.9</td><td>30.14 (-96%)</td><td>25</td><td>Group lasso</td></tr><tr><td>RNN Sparse</td><td>1760</td><td>8.3</td><td>18.91 (-23%)</td><td>25</td><td>Yu et al. (2012)</td></tr><tr><td>RNN Sparse</td><td>1760</td><td>7.3</td><td>17.32 (-13%)</td><td>25</td><td>Narang et al. (2017)</td></tr><tr><td>RNN Sparse</td><td>1760</td><td>7.1</td><td>15.41 (-0.3%)</td><td>60</td><td>Han et al. (2015)</td></tr><tr><td>RNN Block-Sparse</td><td>1760</td><td>7.3</td><td>17.93 (-17%)</td><td>25</td><td>Ours (BP)</td></tr><tr><td>RNN Block-Sparse</td><td>2560</td><td>12.9</td><td>15.89 (-3.4%)</td><td>25</td><td>Ours (GLP)</td></tr><tr><td>RNN Block-Sparse</td><td>3072</td><td>25.8</td><td>15.66 (-1.9%)</td><td>25</td><td>Ours (BP)</td></tr></table>",
528
+ "bbox": [
529
+ 173,
530
+ 133,
531
+ 828,
532
+ 319
533
+ ],
534
+ "page_idx": 4
535
+ },
536
+ {
537
+ "type": "table",
538
+ "img_path": "images/fdb97edcd3ac13c0a126909e95069e6774b5c5a0c076ebde785f8e73ffddb9a5.jpg",
539
+ "table_caption": [
540
+ "Table 3: GRU model results with $4 \\times 4$ blocks "
541
+ ],
542
+ "table_footnote": [],
543
+ "table_body": "<table><tr><td>MODEL</td><td>LAYER SIZE</td><td>#PARAMS (in millions)</td><td>CER (% LOSS)</td><td>EPOCHS</td><td>PRUNING ALGORITHM</td></tr><tr><td>GRU Dense</td><td>2560</td><td>115</td><td>15.42 (0.0%)</td><td>25</td><td>N/A</td></tr><tr><td>GRU Block-Sparse</td><td>2560</td><td>10.8</td><td>16.78 (-8.8%)</td><td>25</td><td>Ours (GLP)</td></tr><tr><td>GRU Block-Sparse</td><td>3584</td><td>25.6</td><td>16.23 (-5.3%)</td><td>25</td><td>Ours (BP)</td></tr></table>",
544
+ "bbox": [
545
+ 187,
546
+ 371,
547
+ 808,
548
+ 474
549
+ ],
550
+ "page_idx": 4
551
+ },
552
+ {
553
+ "type": "text",
554
+ "text": "Comparison to other pruning methods: In addition to group lasso, we compare our block pruning approach with three existing pruning methods. As shown in Table 2, our block-sparse model achieves better accuracy than the hard thresholding scheme in Yu et al. (2012). Sparse RNNs generated using Narang et al. (2017) is about $4 \\%$ better than the block-sparse model. The sparse RNN model generated using iterative pruning (Han et al., 2015) is significantly better than than blocksparse model. However, this approach requires training the model for 60 epochs instead of 25 epochs for all other approaches. This results in 180 hours of additional training time for the RNN model. This $2 { - } 3 \\times$ increase in training time may not be practical for state-of-the-art models trained on large datasets, which usually need weeks of training time. Additionally, all the above approaches generate random, unstructured sparsity in the model. In current hardware, the compute and memory savings with block sparsity are significantly higher than random sparsity. We discuss the performance aspect in more detail in Section 5. ",
555
+ "bbox": [
556
+ 173,
557
+ 506,
558
+ 825,
559
+ 672
560
+ ],
561
+ "page_idx": 4
562
+ },
563
+ {
564
+ "type": "text",
565
+ "text": "Larger models: In order to recover the accuracy loss with our approach, we train sparse models with more hidden units in each recurrent layers. For RNN models, we increase the hidden layer size to 2560 and 3072. As shown in Table 2, the RNN sparse 3072 is only $1 . 9 \\%$ worse than the dense baseline model. The 2560 and 3072 sparse RNN models reduce the overall parameter count by $5 \\times$ and $2 . 5 \\times$ respectively relative to the dense model with 1760 hidden units in each layer. ",
566
+ "bbox": [
567
+ 174,
568
+ 679,
569
+ 825,
570
+ 750
571
+ ],
572
+ "page_idx": 4
573
+ },
574
+ {
575
+ "type": "text",
576
+ "text": "GRU model: Similar to the RNN models, the block-sparse GRU model can reduce the overall parameter count by $1 1 \\times$ . As shown in Table 3, the block-sparse GRU model achieves slightly higher sparsity $( 9 0 \\% )$ with a CER of 16.23 which is only $9 \\%$ worse than the dense GRU model. This indicates that the block-sparse GRU model retains most of the capacity of the dense model. As demonstrated with the RNN model, pruning a larger GRU model with 3584 hidden nodes reduces the accuracy loss to about $5 \\%$ while still shrinking the model by $4 . 5 \\times$ relative to the dense model with 2560 hidden nodes in each layer. ",
577
+ "bbox": [
578
+ 174,
579
+ 756,
580
+ 825,
581
+ 854
582
+ ],
583
+ "page_idx": 4
584
+ },
585
+ {
586
+ "type": "text",
587
+ "text": "4.1.2 BLOCK SIZE VARIATION ",
588
+ "text_level": 1,
589
+ "bbox": [
590
+ 176,
591
+ 871,
592
+ 398,
593
+ 885
594
+ ],
595
+ "page_idx": 4
596
+ },
597
+ {
598
+ "type": "text",
599
+ "text": "Table 4 shows that block pruning works for block sizes upto $3 2 \\times 3 2$ . Increasing the block size to $1 6 \\times 1 6$ and $3 2 \\times 3 2$ requires reducing the sparsity to $8 3 . 6 \\%$ and $7 9 . 1 \\%$ respectively for RNN models to obtain good accuracy. Similar results hold true for the GRU model as well. Large sparse blocks reduce memory overhead for storing non zero values and can take advantage of array data-paths in modern processors. Therefore, even though large blocks achieve lower sparsity, they result in lower memory and compute requirements. ",
600
+ "bbox": [
601
+ 176,
602
+ 895,
603
+ 823,
604
+ 924
605
+ ],
606
+ "page_idx": 4
607
+ },
608
+ {
609
+ "type": "table",
610
+ "img_path": "images/fe91c6a6817de4055dfc5a365f3ab82ed5690454abfdc255c93f72bc787868fa.jpg",
611
+ "table_caption": [
612
+ "Table 4: Results for GRU model with 2560 layer size and bidirectional RNN model with 170 layer size pruned with different block sizes using BP. "
613
+ ],
614
+ "table_footnote": [],
615
+ "table_body": "<table><tr><td>MODEL</td><td>BLOCK SIZE</td><td>#PARAMS (in millions)</td><td>SPARSITY</td><td>CER (% LOSS)</td></tr><tr><td></td><td></td><td></td><td></td><td></td></tr><tr><td>RNN Block-Sparse</td><td>4x4</td><td>7.3</td><td>89.2%</td><td>17.93 (-17%)</td></tr><tr><td>RNN Block-Sparse</td><td>12x2</td><td>10.8</td><td>84.1%</td><td>16.96 (-10%)</td></tr><tr><td>RNN Block-Sparse</td><td>8x8</td><td>10.7</td><td>84.1%</td><td>17.66 (-15%)</td></tr><tr><td>RNN Block-Sparse</td><td>16x16</td><td>11.1</td><td>83.6%</td><td>17.10 (-11%)</td></tr><tr><td>RNN Block-Sparse</td><td>32x32</td><td>14.1</td><td>79.1%</td><td>16.67 (-8.5%)</td></tr><tr><td>GRU Block-Sparse</td><td>4x4</td><td>16.2</td><td>86.0%</td><td>16.97 (-10%)</td></tr><tr><td>GRU Block-Sparse</td><td>16x16</td><td>20.8</td><td>81.9%</td><td>16.84 (-9.2%)</td></tr></table>",
616
+ "bbox": [
617
+ 228,
618
+ 145,
619
+ 771,
620
+ 304
621
+ ],
622
+ "page_idx": 5
623
+ },
624
+ {
625
+ "type": "table",
626
+ "img_path": "images/e4d07045d0a4a3599e95b66b98675146abaf856878da5a7462b26cc24b5884fb.jpg",
627
+ "table_caption": [
628
+ "Table 5: Word language modelling results on Penn Tree Bank using BP for $4 \\times 4$ blocks. "
629
+ ],
630
+ "table_footnote": [],
631
+ "table_body": "<table><tr><td>MODEL</td><td>LAYER SIZE</td><td># PARAMS (in millions)</td><td>PERPLEXITY (% LOSS)</td><td>EPOCHS</td><td>PRUNING ALGORITHM</td></tr><tr><td>LSTM Dense</td><td>1500</td><td>66.0</td><td>78.29 (0.0%)</td><td>55</td><td>N/A</td></tr><tr><td></td><td></td><td></td><td></td><td></td><td></td></tr><tr><td>LSTM Block-Sparse LSTM Block-Sparse</td><td>1500 1500</td><td>23.1 11.6</td><td>77.04 (1.6%) 80.25 (-2.5%)</td><td>55 55</td><td>Ours (BP) Ours (BP)</td></tr><tr><td>LSTM Block-Sparse</td><td>1500</td><td>7.95</td><td>82.72 (-5.7%)</td><td>55</td><td>Ours (BP)</td></tr><tr><td></td><td></td><td></td><td></td><td></td><td></td></tr></table>",
632
+ "bbox": [
633
+ 184,
634
+ 354,
635
+ 812,
636
+ 472
637
+ ],
638
+ "page_idx": 5
639
+ },
640
+ {
641
+ "type": "text",
642
+ "text": "",
643
+ "bbox": [
644
+ 174,
645
+ 503,
646
+ 825,
647
+ 560
648
+ ],
649
+ "page_idx": 5
650
+ },
651
+ {
652
+ "type": "text",
653
+ "text": "The exact choice of block size for a given application depends on the underlying hardware used for inference. For example, NVIDIA’s Volta processor supports $1 6 \\times 1 6$ blocks whereas ARM processors support blocks of $1 2 \\mathbf { x } 2$ . We demonstrate that our approach is agnostic to block size and can be used to generate block-sparse models for arbitrary blocks. ",
654
+ "bbox": [
655
+ 174,
656
+ 566,
657
+ 825,
658
+ 622
659
+ ],
660
+ "page_idx": 5
661
+ },
662
+ {
663
+ "type": "text",
664
+ "text": "4.2 NEURAL LANGUAGE MODELLING ",
665
+ "text_level": 1,
666
+ "bbox": [
667
+ 178,
668
+ 640,
669
+ 449,
670
+ 655
671
+ ],
672
+ "page_idx": 5
673
+ },
674
+ {
675
+ "type": "text",
676
+ "text": "We conducted block pruning experiments on Penn Tree Bank (PTB) (Marcus et al., 1993) dataset using word level language models. For our experiments, we use the large LSTM model with 1500 hidden units from Zaremba et al. (2014). The hyperparameters are unchanged from the original model, except for slightly increased dropout keep probability which ranges from 0.4 to 0.52 for the sparse models. We prune weights in the embedding, LSTM and softmax layers of the model. ",
677
+ "bbox": [
678
+ 174,
679
+ 667,
680
+ 825,
681
+ 737
682
+ ],
683
+ "page_idx": 5
684
+ },
685
+ {
686
+ "type": "text",
687
+ "text": "We report results on the test set using BP with $4 \\times 4$ blocks in Table 5. Block pruning can reduce the parameter count by nearly $3 \\times$ while retaining the accuracy of the dense model. With a $5 \\%$ loss in accuracy, we can reduce the parameter count by $8 . 3 \\times$ . There is a trade-off between sparsity and accuracy of the model. For inference, we would pick the model that meets the desired memory and compute budget. Further work remains in evaluating this technique for large scale datasets like the Billion word datasets (Chelba et al., 2013) for language modelling. ",
688
+ "bbox": [
689
+ 174,
690
+ 744,
691
+ 825,
692
+ 828
693
+ ],
694
+ "page_idx": 5
695
+ },
696
+ {
697
+ "type": "text",
698
+ "text": "5 PERFORMANCE ",
699
+ "text_level": 1,
700
+ "bbox": [
701
+ 176,
702
+ 849,
703
+ 334,
704
+ 864
705
+ ],
706
+ "page_idx": 5
707
+ },
708
+ {
709
+ "type": "text",
710
+ "text": "Sparse formats incur at least three types of overhead: i) indexing overhead, ii) irregular memory accesses, and ii) incompatibility with array-data-paths, all of which are mitigated by using larger block sizes. ",
711
+ "bbox": [
712
+ 176,
713
+ 882,
714
+ 823,
715
+ 922
716
+ ],
717
+ "page_idx": 5
718
+ },
719
+ {
720
+ "type": "text",
721
+ "text": "Indexing Overheads. Sparse formats use extra memory to track the location of each non-zero value. For example, the compressed-sparse-row (CSR) format uses between one and two extra index values for each non-zero value. Assuming that neural network weights and indices are represented with 16-bits as in Micikevicius et al. (2017), this is at least $1 0 0 \\%$ overhead. Block sparsity reduces this overhead by a factor of the block size because the index is shared over the entire block. For example, using a block size of 4x4 reduces the memory bloat to $6 . 2 5 \\%$ , and using a block size of 16x16 reduces it to less than $1 \\%$ . ",
722
+ "bbox": [
723
+ 174,
724
+ 103,
725
+ 825,
726
+ 200
727
+ ],
728
+ "page_idx": 6
729
+ },
730
+ {
731
+ "type": "text",
732
+ "text": "Irregular Memory Accesses. Caches lines, DRAM row buffers, and TLBs provide the best performance when memory is accessed in relatively large contiguous units (e.g. 64 bytes for cache lines, 4KB for a DRAM row) as opposed to in fine-grained random accesses. Block-sparse formats store blocks contiguously in memory, resulting in large coalesced accesses. ",
733
+ "bbox": [
734
+ 174,
735
+ 208,
736
+ 823,
737
+ 263
738
+ ],
739
+ "page_idx": 6
740
+ },
741
+ {
742
+ "type": "text",
743
+ "text": "Array Data-Paths. Block-sparse models make it easier to exploit array-data-paths in modern processors. There are significant advantages of using these units, for example, on the Volta V100 GPU, they enable up to ${ 8 } \\mathbf { { x } }$ higher throughput than the SIMD data-paths. In order to keep these units busy, the block size should be at least as large as the hardware data-path size ( $1 6 \\times 1 6$ or larger on V100). ",
744
+ "bbox": [
745
+ 174,
746
+ 271,
747
+ 823,
748
+ 327
749
+ ],
750
+ "page_idx": 6
751
+ },
752
+ {
753
+ "type": "text",
754
+ "text": "5.1 INFERENCE PERFORMANCE ",
755
+ "text_level": 1,
756
+ "bbox": [
757
+ 176,
758
+ 344,
759
+ 405,
760
+ 358
761
+ ],
762
+ "page_idx": 6
763
+ },
764
+ {
765
+ "type": "text",
766
+ "text": "Inference performance depends of three different factors: accuracy, latency of evaluation and memory requirements. In order to understand the trade-off between unstructured sparsity and block sparsity, we benchmark the General Matrix Multiply (GEMM) speed-up and memory reduction for a single layer in the speech recongition RNN model. We evaluate GEMM speed-up with batch size of 16 using NVIDIA’s CuSparse and CuBLAS libraries on a TitanX Maxwell GPU. Sparse matrices are represented in CSR or Block-CSR format depending on the sparsity structure. Memory savings are calculated using CSR and Block Sparse Row (BSR) from Scipy module in Python. We evaluate a single layer with different block sizes. We also evaluate the best unstructured sparsity result obtained using iterative pruning from Han et al. (2015). ",
767
+ "bbox": [
768
+ 173,
769
+ 369,
770
+ 825,
771
+ 496
772
+ ],
773
+ "page_idx": 6
774
+ },
775
+ {
776
+ "type": "text",
777
+ "text": "As shown in Table 6, the unstructured sparsity model (Han et al., 2015) achieves the best accuracy but requires much longer training time and does not improve the compute time relative to the dense model. For a small loss in accuracy, block-sparse models can significantly reduce both compute and memory requirements. For example, layers with 16x16 block sparsity reduce memory consumption by $1 1 \\times$ and speedup compute by $3 \\times$ with a $10 \\%$ loss in accuracy. Additionally, Figure 2 shows that block-sparse matrices achieve higher speed-up than unstructured sparsity for large batch sizes for RNN and GRU layers. The speed-up is achieved due to reducing irregular memory accesses and improving load balance. Future work involves efficient implementation of block-sparse kernels to take advantage of array-data-paths in modern processors. ",
778
+ "bbox": [
779
+ 174,
780
+ 502,
781
+ 825,
782
+ 627
783
+ ],
784
+ "page_idx": 6
785
+ },
786
+ {
787
+ "type": "text",
788
+ "text": "Table 6: Accuracy, speed-up and memory reduction for sparse layers. Block-sparse layers achieve higher speedup and memory reduction with some loss in accuracy. ",
789
+ "bbox": [
790
+ 173,
791
+ 640,
792
+ 823,
793
+ 670
794
+ ],
795
+ "page_idx": 6
796
+ },
797
+ {
798
+ "type": "table",
799
+ "img_path": "images/56c7a1d6fd4f454adabeb860e3f7b0f8051581591837907d0d5219556c07e8a6.jpg",
800
+ "table_caption": [],
801
+ "table_footnote": [],
802
+ "table_body": "<table><tr><td>MODEL</td><td>LAYER SIZE</td><td>GEMM SPEEDUP</td><td>MEMORY SAVINGS</td><td>CER (% LOSS)</td><td>ALGORITHM</td></tr><tr><td></td><td></td><td></td><td></td><td></td><td></td></tr><tr><td>RNN Sparse</td><td>1760</td><td>1.0×</td><td>5.0×</td><td>15.41 (-0.3%)</td><td>Han et al. (2015)</td></tr><tr><td>RNN Block-Sparse</td><td>2560</td><td>1.1×</td><td>6.2×</td><td>15.89 (-3.4%)</td><td>BP (4x4)</td></tr><tr><td>RNN Block-Sparse</td><td>1760</td><td>1.5×</td><td>7.1×</td><td>16.67 (-8.5%)</td><td>BP (32x32)</td></tr><tr><td>RNN Block-Sparse</td><td>1760</td><td>3.0×</td><td>11×</td><td>17.10 (-11%)</td><td>BP (16x16)</td></tr><tr><td>RNN Block-Sparse</td><td>1760</td><td>1.9×</td><td>17×</td><td>17.93 (-17%)</td><td>BP (4x4)</td></tr></table>",
803
+ "bbox": [
804
+ 179,
805
+ 685,
806
+ 818,
807
+ 803
808
+ ],
809
+ "page_idx": 6
810
+ },
811
+ {
812
+ "type": "text",
813
+ "text": "6 IMPACT OF SPARSITY ON ACCURACY ",
814
+ "text_level": 1,
815
+ "bbox": [
816
+ 174,
817
+ 837,
818
+ 509,
819
+ 852
820
+ ],
821
+ "page_idx": 6
822
+ },
823
+ {
824
+ "type": "text",
825
+ "text": "Using our baseline RNN model, we run many Weight Pruning (WP) (using (Narang et al., 2017)) and block pruning experiments, varying hyper-parameters to produce a spectrum of results ranging from $70 \\%$ to $9 7 \\%$ sparsity. For these experiments, the models are trained for 20 epochs and the accuracy is reported on the validation set. As shown in Figure 3, models pruned using WP with sparsity less than $9 5 \\%$ have relative accuracy ranging from $- 2 0 \\%$ to $- 2 7 \\%$ . Increasing the sparsity for the model beyond $9 5 \\%$ results in $30 \\%$ or more accuracy loss. This “accuracy cliff” is earlier for models pruned with block sparsity. For block size $4 \\times 4$ , models with sparsity greater $90 \\%$ yield a relative accuracy loss of $30 \\%$ or higher. Similarly, for blocks of $1 6 \\times 1 6$ , models with sparsity greater than $86 \\%$ have $30 \\%$ or more accuracy loss. A similar trend is observed for block size $3 2 \\times 3 2$ . This indicates that there is a trade-off between sparsity and block-size for a given accuracy. Larger blocks reach the “accuracy cliff” sooner. ",
826
+ "bbox": [
827
+ 174,
828
+ 867,
829
+ 823,
830
+ 924
831
+ ],
832
+ "page_idx": 6
833
+ },
834
+ {
835
+ "type": "image",
836
+ "img_path": "images/77a2c488c33a18b5241dc112abc22b35692143a9c4e257b6ad57b3b19de142c9.jpg",
837
+ "image_caption": [],
838
+ "image_footnote": [],
839
+ "bbox": [
840
+ 181,
841
+ 101,
842
+ 802,
843
+ 289
844
+ ],
845
+ "page_idx": 7
846
+ },
847
+ {
848
+ "type": "image",
849
+ "img_path": "images/2fb7fe20bdf392368dff38691958bb0bfa2b419980f1fe202dcd8c0bacb3fdb6.jpg",
850
+ "image_caption": [
851
+ "Figure 2: Speed-up for sparse matrix multiply over GEMM. RNN matrix sizes are (1760,1760) with $90 \\%$ sparsity and (1760, batch size). GRU matrix sizes are (7680,2560) with $9 5 \\%$ sparsity and (2560, batch size). Block-sparse matrices achieve consistently good speedup across batch-sizes ",
852
+ "Figure 3: Relative accuracy for different block sizes (4x4, 16x16) and WP for varying sparsity on the RNN 1760 model. Any models with relative accuracy worse than $- 7 5 \\%$ are capped at $7 5 \\%$ . "
853
+ ],
854
+ "image_footnote": [],
855
+ "bbox": [
856
+ 336,
857
+ 358,
858
+ 661,
859
+ 537
860
+ ],
861
+ "page_idx": 7
862
+ },
863
+ {
864
+ "type": "text",
865
+ "text": "",
866
+ "bbox": [
867
+ 174,
868
+ 604,
869
+ 825,
870
+ 702
871
+ ],
872
+ "page_idx": 7
873
+ },
874
+ {
875
+ "type": "text",
876
+ "text": "7 CONCLUSION AND FUTURE WORK ",
877
+ "text_level": 1,
878
+ "bbox": [
879
+ 174,
880
+ 722,
881
+ 495,
882
+ 738
883
+ ],
884
+ "page_idx": 7
885
+ },
886
+ {
887
+ "type": "text",
888
+ "text": "We have demonstrated that using block pruning and group lasso combined with pruning during training can build block-sparse RNNs that are about as accurate as the dense baseline models. The block-sparse models have significantly fewer parameters than the dense baselines reducing memory requirements. Block-sparse models can take advantage of the underlying hardware efficiently. ",
889
+ "bbox": [
890
+ 174,
891
+ 753,
892
+ 825,
893
+ 810
894
+ ],
895
+ "page_idx": 7
896
+ },
897
+ {
898
+ "type": "text",
899
+ "text": "We would like to investigate if pruning can be performed even earlier in the training, thereby allowing us to train sparse models. Training sparse models would allow us to reap the benefits of sparsity during training resulting in lesser compute and memory demands. Further work remains to implement efficient block-sparse matrix multiplies for array-data-paths in modern processors that would provide increased speed-up during deployment. ",
900
+ "bbox": [
901
+ 174,
902
+ 816,
903
+ 825,
904
+ 887
905
+ ],
906
+ "page_idx": 7
907
+ },
908
+ {
909
+ "type": "text",
910
+ "text": "REFERENCES ",
911
+ "text_level": 1,
912
+ "bbox": [
913
+ 174,
914
+ 104,
915
+ 267,
916
+ 117
917
+ ],
918
+ "page_idx": 8
919
+ },
920
+ {
921
+ "type": "text",
922
+ "text": "Dario Amodei, Rishita Anubhai, Eric Battenberg, Carl Case, Jared Casper, Bryan Catanzaro, JingDong Chen, Mike Chrzanowski, Adam Coates, Greg Diamos, et al. Deep speech 2: End-to-end speech recognition in english and mandarin. In Proceedings of The 33rd International Conference on Machine Learning, pp. 173–182, 2016. ",
923
+ "bbox": [
924
+ 173,
925
+ 125,
926
+ 825,
927
+ 176
928
+ ],
929
+ "page_idx": 8
930
+ },
931
+ {
932
+ "type": "text",
933
+ "text": "Ciprian Chelba, Tomas Mikolov, Mike Schuster, Qi Ge, Thorsten Brants, Phillipp Koehn, and Tony Robinson. One billion word benchmark for measuring progress in statistical language modeling. Technical report, Google, 2013. URL http://arxiv.org/abs/1312.3005. ",
934
+ "bbox": [
935
+ 178,
936
+ 185,
937
+ 821,
938
+ 224
939
+ ],
940
+ "page_idx": 8
941
+ },
942
+ {
943
+ "type": "text",
944
+ "text": "Kyunghyun Cho, Bart Van Merrienboer, Caglar Gulcehre, Dzmitry Bahdanau, Fethi Bougares, Holger ¨ Schwenk, and Yoshua Bengio. Learning phrase representations using rnn encoder-decoder for statistical machine translation. arXiv preprint arXiv:1406.1078, 2014. ",
945
+ "bbox": [
946
+ 174,
947
+ 234,
948
+ 823,
949
+ 273
950
+ ],
951
+ "page_idx": 8
952
+ },
953
+ {
954
+ "type": "text",
955
+ "text": "Misha Denil, Babak Shakibi, Laurent Dinh, Marc’Aurelio Ranzato, and Nando de Freitas. Predicting parameters in deep learning. CoRR, abs/1306.0543, 2013. URL http://arxiv.org/abs/1306.0543. ",
956
+ "bbox": [
957
+ 173,
958
+ 284,
959
+ 821,
960
+ 310
961
+ ],
962
+ "page_idx": 8
963
+ },
964
+ {
965
+ "type": "text",
966
+ "text": "Emily Denton, Wojciech Zaremba, Joan Bruna, Yann LeCun, and Rob Fergus. Exploiting linear structure within convolutional networks for efficient evaluation. CoRR, abs/1404.0736, 2014. URL http://arxiv.org/ abs/1404.0736. ",
967
+ "bbox": [
968
+ 173,
969
+ 320,
970
+ 823,
971
+ 358
972
+ ],
973
+ "page_idx": 8
974
+ },
975
+ {
976
+ "type": "text",
977
+ "text": "Qinwei Fan, Wei Wu, and Jacek M Zurada. Convergence of batch gradient learning with smoothing regularization and adaptive momentum for neural networks. SpringerPlus, 5(1):295, 2016. ",
978
+ "bbox": [
979
+ 171,
980
+ 368,
981
+ 823,
982
+ 396
983
+ ],
984
+ "page_idx": 8
985
+ },
986
+ {
987
+ "type": "text",
988
+ "text": "Julian Faraone, Nicholas Fraser, Giulio Gamberdella, Michaela Blott, and Philip HW Leong. Compressing low precision deep neural networks using sparsity-induced regularization in ternary networks. arXiv preprint arXiv:1709.06262, 2017. ",
989
+ "bbox": [
990
+ 173,
991
+ 405,
992
+ 821,
993
+ 444
994
+ ],
995
+ "page_idx": 8
996
+ },
997
+ {
998
+ "type": "text",
999
+ "text": "Alex Graves, Santiago Fernandez, Faustino Gomez, and J ´ urgen Schmidhuber. Connectionist temporal classi-¨ fication: labelling unsegmented sequence data with recurrent neural networks. In Proceedings of the $2 3 r d$ international conference on Machine learning, pp. 369–376. ACM, 2006. ",
1000
+ "bbox": [
1001
+ 176,
1002
+ 454,
1003
+ 823,
1004
+ 493
1005
+ ],
1006
+ "page_idx": 8
1007
+ },
1008
+ {
1009
+ "type": "text",
1010
+ "text": "Suyog Gupta, Ankur Agrawal, Kailash Gopalakrishnan, and Pritish Narayanan. Deep learning with limited numerical precision. In Proceedings of the 32nd International Conference on Machine Learning (ICML15), pp. 1737–1746, 2015. ",
1011
+ "bbox": [
1012
+ 176,
1013
+ 503,
1014
+ 821,
1015
+ 542
1016
+ ],
1017
+ "page_idx": 8
1018
+ },
1019
+ {
1020
+ "type": "text",
1021
+ "text": "Song Han, Huizi Mao, and William J Dally. Deep compression: Compressing deep neural networks with pruning, trained quantization and huffman coding. arXiv preprint arXiv:1510.00149, 2015. ",
1022
+ "bbox": [
1023
+ 169,
1024
+ 551,
1025
+ 823,
1026
+ 579
1027
+ ],
1028
+ "page_idx": 8
1029
+ },
1030
+ {
1031
+ "type": "text",
1032
+ "text": "Stephen Jose Hanson and Lorien Pratt. Advances in neural information processing systems 1. chapter Com-´ paring Biases for Minimal Network Construction with Back-propagation, pp. 177–185. Morgan Kaufmann Publishers Inc., San Francisco, CA, USA, 1989. ISBN 1-558-60015-9. URL http://dl.acm.org/ citation.cfm?id $=$ 89851.89872. ",
1033
+ "bbox": [
1034
+ 174,
1035
+ 588,
1036
+ 825,
1037
+ 640
1038
+ ],
1039
+ "page_idx": 8
1040
+ },
1041
+ {
1042
+ "type": "text",
1043
+ "text": "Babak Hassibi, David G Stork, and Gregory J Wolff. Optimal brain surgeon and general network pruning. In Neural Networks, 1993., IEEE International Conference on, pp. 293–299. IEEE, 1993. ",
1044
+ "bbox": [
1045
+ 173,
1046
+ 650,
1047
+ 823,
1048
+ 676
1049
+ ],
1050
+ "page_idx": 8
1051
+ },
1052
+ {
1053
+ "type": "text",
1054
+ "text": "Sepp Hochreiter and Jurgen Schmidhuber. Long short-term memory. ¨ Neural Comput., 9(8):1735–1780, November 1997. ISSN 0899-7667. doi: 10.1162/neco.1997.9.8.1735. URL http://dx.doi.org/ 10.1162/neco.1997.9.8.1735. ",
1055
+ "bbox": [
1056
+ 174,
1057
+ 686,
1058
+ 821,
1059
+ 726
1060
+ ],
1061
+ "page_idx": 8
1062
+ },
1063
+ {
1064
+ "type": "text",
1065
+ "text": "Norman P. Jouppi, Cliff Young, Nishant Patil, David Patterson, Gaurav Agrawal, Raminder Bajwa, Sarah Bates, Suresh Bhatia, Nan Boden, Al Borchers, Rick Boyle, Pierre-luc Cantin, Clifford Chao, Chris Clark, Jeremy Coriell, Mike Daley, Matt Dau, Jeffrey Dean, Ben Gelb, Tara Vazir Ghaemmaghami, Rajendra Gottipati, William Gulland, Robert Hagmann, Richard C. Ho, Doug Hogberg, John Hu, Robert Hundt, Dan Hurt, Julian Ibarz, Aaron Jaffey, Alek Jaworski, Alexander Kaplan, Harshit Khaitan, Andy Koch, Naveen Kumar, Steve Lacy, James Laudon, James Law, Diemthu Le, Chris Leary, Zhuyuan Liu, Kyle Lucke, Alan Lundin, Gordon MacKean, Adriana Maggiore, Maire Mahony, Kieran Miller, Rahul Nagarajan, Ravi Narayanaswami, Ray Ni, Kathy Nix, Thomas Norrie, Mark Omernick, Narayana Penukonda, Andy Phelps, Jonathan Ross, Amir Salek, Emad Samadiani, Chris Severn, Gregory Sizikov, Matthew Snelham, Jed Souter, Dan Steinberg, Andy Swing, Mercedes Tan, Gregory Thorson, Bo Tian, Horia Toma, Erick Tuttle, Vijay Vasudevan, Richard Walter, Walter Wang, Eric Wilcox, and Doe Hyun Yoon. In-datacenter performance analysis of a tensor processing unit. CoRR, abs/1704.04760, 2017. URL http://arxiv.org/abs/1704.04760. ",
1066
+ "bbox": [
1067
+ 178,
1068
+ 736,
1069
+ 825,
1070
+ 887
1071
+ ],
1072
+ "page_idx": 8
1073
+ },
1074
+ {
1075
+ "type": "text",
1076
+ "text": "Rafal Jozefowicz, Oriol Vinyals, Mike Schuster, Noam Shazeer, and Yonghui Wu. Exploring the limits of ´ language modeling. CoRR, abs/1602.02410, 2016. URL http://arxiv.org/abs/1602.02410. ",
1077
+ "bbox": [
1078
+ 173,
1079
+ 897,
1080
+ 823,
1081
+ 924
1082
+ ],
1083
+ "page_idx": 8
1084
+ },
1085
+ {
1086
+ "type": "text",
1087
+ "text": "Seyoung Kim and Eric P Xing. Tree-guided group lasso for multi-task regression with structured sparsity. 2010. ",
1088
+ "bbox": [
1089
+ 171,
1090
+ 103,
1091
+ 821,
1092
+ 131
1093
+ ],
1094
+ "page_idx": 9
1095
+ },
1096
+ {
1097
+ "type": "text",
1098
+ "text": "Yann LeCun, John S Denker, Sara A Solla, Richard E Howard, and Lawrence D Jackel. Optimal brain damage. In NIPs, volume 2, pp. 598–605, 1989. ",
1099
+ "bbox": [
1100
+ 174,
1101
+ 138,
1102
+ 821,
1103
+ 165
1104
+ ],
1105
+ "page_idx": 9
1106
+ },
1107
+ {
1108
+ "type": "text",
1109
+ "text": "Baoyuan Liu, Min Wang, Hassan Foroosh, Marshall Tappen, and Marianna Pensky. Sparse convolutional neural networks. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pp. 806–814, 2015. ",
1110
+ "bbox": [
1111
+ 173,
1112
+ 172,
1113
+ 823,
1114
+ 213
1115
+ ],
1116
+ "page_idx": 9
1117
+ },
1118
+ {
1119
+ "type": "text",
1120
+ "text": "Huizi Mao, Song Han, Jeff Pool, Wenshuo Li, Xingyu Liu, Yu Wang, and William Dally. Exploring the regularity of sparse structure in convolutional neural networks. 05 2017. ",
1121
+ "bbox": [
1122
+ 171,
1123
+ 220,
1124
+ 823,
1125
+ 247
1126
+ ],
1127
+ "page_idx": 9
1128
+ },
1129
+ {
1130
+ "type": "text",
1131
+ "text": "Mitchell P Marcus, Mary Ann Marcinkiewicz, and Beatrice Santorini. Building a large annotated corpus of english: The penn treebank. Computational linguistics, 19(2):313–330, 1993. ",
1132
+ "bbox": [
1133
+ 174,
1134
+ 255,
1135
+ 823,
1136
+ 282
1137
+ ],
1138
+ "page_idx": 9
1139
+ },
1140
+ {
1141
+ "type": "text",
1142
+ "text": "P. Micikevicius, S. Narang, J. Alben, G. Diamos, E. Elsen, D. Garcia, B. Ginsburg, M. Houston, O. Kuchaiev, G. Venkatesh, and H. Wu. Mixed Precision Training. ArXiv e-prints, October 2017. ",
1143
+ "bbox": [
1144
+ 173,
1145
+ 290,
1146
+ 823,
1147
+ 316
1148
+ ],
1149
+ "page_idx": 9
1150
+ },
1151
+ {
1152
+ "type": "text",
1153
+ "text": "Sharan Narang and Gregory Diamos. Deepbench. https://svail.github.io/ DeepBench-update/, 2017. Accessed: 2017-06-28. ",
1154
+ "bbox": [
1155
+ 176,
1156
+ 324,
1157
+ 823,
1158
+ 351
1159
+ ],
1160
+ "page_idx": 9
1161
+ },
1162
+ {
1163
+ "type": "text",
1164
+ "text": "Sharan Narang, Gregory Diamos, Shubho Sengupta, and Erich Elsen. Exploring sparsity in recurrent neural networks. arXiv preprint arXiv:1704.05119, 2017. ",
1165
+ "bbox": [
1166
+ 176,
1167
+ 359,
1168
+ 821,
1169
+ 386
1170
+ ],
1171
+ "page_idx": 9
1172
+ },
1173
+ {
1174
+ "type": "text",
1175
+ "text": "NVIDIA. NVIDIA Tesla V100 GPU Architecture. Technical report, 2017. ",
1176
+ "bbox": [
1177
+ 171,
1178
+ 393,
1179
+ 616,
1180
+ 409
1181
+ ],
1182
+ "page_idx": 9
1183
+ },
1184
+ {
1185
+ "type": "text",
1186
+ "text": "Mohammad Rastegari, Vicente Ordonez, Joseph Redmon, and Ali Farhadi. XNOR-Net: ImageNet Classification Using Binary Convolutional Neural Networks, pp. 525–542. Springer International Publishing, Cham, 2016. ISBN 978-3-319-46493-0. doi: 10.1007/978-3-319-46493-0 32. URL https: //doi.org/10.1007/978-3-319-46493-0_32. ",
1187
+ "bbox": [
1188
+ 173,
1189
+ 416,
1190
+ 825,
1191
+ 468
1192
+ ],
1193
+ "page_idx": 9
1194
+ },
1195
+ {
1196
+ "type": "text",
1197
+ "text": "Simone Scardapane, Danilo Comminiello, Amir Hussain, and Aurelio Uncini. Group sparse regularization for deep neural networks. Neurocomputing, 241:81–89, 2017. ",
1198
+ "bbox": [
1199
+ 174,
1200
+ 476,
1201
+ 823,
1202
+ 502
1203
+ ],
1204
+ "page_idx": 9
1205
+ },
1206
+ {
1207
+ "type": "text",
1208
+ "text": "Vincent Vanhoucke, Andrew Senior, and Mark Z. Mao. Improving the speed of neural networks on cpus. In Deep Learning and Unsupervised Feature Learning Workshop, NIPS 2011, 2011. ",
1209
+ "bbox": [
1210
+ 176,
1211
+ 510,
1212
+ 821,
1213
+ 537
1214
+ ],
1215
+ "page_idx": 9
1216
+ },
1217
+ {
1218
+ "type": "text",
1219
+ "text": "Wei Wen, Chunpeng Wu, Yandan Wang, Yiran Chen, and Hai Li. Learning structured sparsity in deep neural networks. In Advances in Neural Information Processing Systems, pp. 2074–2082, 2016. ",
1220
+ "bbox": [
1221
+ 173,
1222
+ 545,
1223
+ 823,
1224
+ 571
1225
+ ],
1226
+ "page_idx": 9
1227
+ },
1228
+ {
1229
+ "type": "text",
1230
+ "text": "Wei Wen, Yuxiong He, Samyam Rajbhandari, Wenhan Wang, Fang Liu, Bin Hu, Yiran Chen, and Hai Li. Learning intrinsic sparse structures within long short-term memory. arXiv preprint arXiv:1709.05027, 2017. ",
1231
+ "bbox": [
1232
+ 173,
1233
+ 579,
1234
+ 823,
1235
+ 607
1236
+ ],
1237
+ "page_idx": 9
1238
+ },
1239
+ {
1240
+ "type": "text",
1241
+ "text": "Yonghui Wu, Mike Schuster, Zhifeng Chen, Quoc V. Le, Mohammad Norouzi, Wolfgang Macherey, Maxim Krikun, Yuan Cao, Qin Gao, Klaus Macherey, Jeff Klingner, Apurva Shah, Melvin Johnson, Xiaobing Liu, Lukasz Kaiser, Stephan Gouws, Yoshikiyo Kato, Taku Kudo, Hideto Kazawa, Keith Stevens, George Kurian, Nishant Patil, Wei Wang, Cliff Young, Jason Smith, Jason Riesa, Alex Rudnick, Oriol Vinyals, Greg Corrado, Macduff Hughes, and Jeffrey Dean. Google’s neural machine translation system: Bridging the gap between human and machine translation. CoRR, abs/1609.08144, 2016. URL http://arxiv.org/abs/1609. 08144. ",
1242
+ "bbox": [
1243
+ 174,
1244
+ 613,
1245
+ 825,
1246
+ 703
1247
+ ],
1248
+ "page_idx": 9
1249
+ },
1250
+ {
1251
+ "type": "text",
1252
+ "text": "Dong Yu, Frank Seide, Gang Li, and Li Deng. Exploiting sparseness in deep neural networks for large vocabulary speech recognition. In 2012 IEEE International Conference on Acoustics, Speech and Signal Processing (ICASSP), pp. 4409–4412. IEEE, 2012. ",
1253
+ "bbox": [
1254
+ 173,
1255
+ 712,
1256
+ 821,
1257
+ 751
1258
+ ],
1259
+ "page_idx": 9
1260
+ },
1261
+ {
1262
+ "type": "text",
1263
+ "text": "Jiecao Yu, Andrew Lukefahr, David Palframan, Ganesh Dasika, Reetuparna Das, and Scott Mahlke. Scalpel: Customizing dnn pruning to the underlying hardware parallelism. In Proceedings of the 44th Annual International Symposium on Computer Architecture, pp. 548–560. ACM, 2017. ",
1264
+ "bbox": [
1265
+ 173,
1266
+ 758,
1267
+ 823,
1268
+ 797
1269
+ ],
1270
+ "page_idx": 9
1271
+ },
1272
+ {
1273
+ "type": "text",
1274
+ "text": "Ming Yuan and Yi Lin. Model selection and estimation in regression with grouped variables. 2006a. ",
1275
+ "bbox": [
1276
+ 169,
1277
+ 806,
1278
+ 766,
1279
+ 820
1280
+ ],
1281
+ "page_idx": 9
1282
+ },
1283
+ {
1284
+ "type": "text",
1285
+ "text": "Ming Yuan and Yi Lin. Model selection and estimation in regression with grouped variables. Journal of the Royal Statistical Society: Series B (Statistical Methodology), 68(1):49–67, 2006b. ",
1286
+ "bbox": [
1287
+ 173,
1288
+ 828,
1289
+ 820,
1290
+ 854
1291
+ ],
1292
+ "page_idx": 9
1293
+ },
1294
+ {
1295
+ "type": "text",
1296
+ "text": "Wojciech Zaremba, Ilya Sutskever, and Oriol Vinyals. Recurrent neural network regularization. CoRR, abs/1409.2329, 2014. URL http://arxiv.org/abs/1409.2329. ",
1297
+ "bbox": [
1298
+ 174,
1299
+ 863,
1300
+ 823,
1301
+ 888
1302
+ ],
1303
+ "page_idx": 9
1304
+ },
1305
+ {
1306
+ "type": "text",
1307
+ "text": "Michael Zhu and Suyog Gupta. To prune, or not to prune: exploring the efficacy of pruning for model compression. arXiv preprint arXiv:1710.01878, 2017. ",
1308
+ "bbox": [
1309
+ 171,
1310
+ 898,
1311
+ 825,
1312
+ 924
1313
+ ],
1314
+ "page_idx": 9
1315
+ },
1316
+ {
1317
+ "type": "text",
1318
+ "text": "A $\\ell _ { 1 }$ AND $\\ell _ { 1 / 2 }$ REGULARIZATION ",
1319
+ "text_level": 1,
1320
+ "bbox": [
1321
+ 176,
1322
+ 102,
1323
+ 459,
1324
+ 119
1325
+ ],
1326
+ "page_idx": 10
1327
+ },
1328
+ {
1329
+ "type": "text",
1330
+ "text": "Prior to our work with group lasso regularization, we considered $\\ell _ { 1 }$ and $\\ell _ { 1 / 2 }$ regularizers to induce sparsity in the network. These regularizers act on individual weights and could aid in inducing unstructured sparsity in the network. $\\ell _ { 1 }$ regularization is defined as: ",
1331
+ "bbox": [
1332
+ 174,
1333
+ 133,
1334
+ 825,
1335
+ 176
1336
+ ],
1337
+ "page_idx": 10
1338
+ },
1339
+ {
1340
+ "type": "equation",
1341
+ "img_path": "images/da3cf196cce5f26d16fcb69a172fc86fc5319041fb11d876b94862675e0e17fd.jpg",
1342
+ "text": "$$\nL = L _ { \\mathrm { t r a i n i n g } } + \\lambda \\sum _ { i = 1 } ^ { k } \\left| w _ { i } \\right|\n$$",
1343
+ "text_format": "latex",
1344
+ "bbox": [
1345
+ 415,
1346
+ 183,
1347
+ 584,
1348
+ 226
1349
+ ],
1350
+ "page_idx": 10
1351
+ },
1352
+ {
1353
+ "type": "text",
1354
+ "text": "where $| w _ { i } |$ is the absolute value of a weight and $k$ is the total number of weights. Note the gradient expression for each weight $w _ { j }$ : ",
1355
+ "bbox": [
1356
+ 176,
1357
+ 232,
1358
+ 823,
1359
+ 261
1360
+ ],
1361
+ "page_idx": 10
1362
+ },
1363
+ {
1364
+ "type": "equation",
1365
+ "img_path": "images/ec0b9ea9a5ab1223570be29911df540f4d23ad1ccec15a297d68206c0d832088.jpg",
1366
+ "text": "$$\n{ \\frac { \\partial } { \\partial w _ { j } } } \\sum _ { i = 1 } ^ { k } | w _ { i } | = s g n ( w _ { j } )\n$$",
1367
+ "text_format": "latex",
1368
+ "bbox": [
1369
+ 413,
1370
+ 260,
1371
+ 583,
1372
+ 304
1373
+ ],
1374
+ "page_idx": 10
1375
+ },
1376
+ {
1377
+ "type": "text",
1378
+ "text": "As with the group lasso experiments described in 3.2, we explore $\\ell _ { 1 }$ regularization with and without pruning. The weight pruning (WP) algorithm from Narang et al. (2017) is used along with regularization. The motivation is the same as group lasso block sparsity experiments: either to guide pruning or to produce sparsity directly. ",
1379
+ "bbox": [
1380
+ 174,
1381
+ 313,
1382
+ 825,
1383
+ 369
1384
+ ],
1385
+ "page_idx": 10
1386
+ },
1387
+ {
1388
+ "type": "text",
1389
+ "text": "We also explore $\\ell _ { 1 / 2 }$ regularization which is defined as: ",
1390
+ "bbox": [
1391
+ 174,
1392
+ 376,
1393
+ 540,
1394
+ 391
1395
+ ],
1396
+ "page_idx": 10
1397
+ },
1398
+ {
1399
+ "type": "equation",
1400
+ "img_path": "images/c61b361fb831c4fd3b88e27895963a687c0c01b2ca54c9203969b134763314b2.jpg",
1401
+ "text": "$$\nL = L _ { \\mathrm { t r a i n i n g } } + \\lambda \\sum _ { i = 1 } ^ { k } | w _ { i } | ^ { 1 / 2 }\n$$",
1402
+ "text_format": "latex",
1403
+ "bbox": [
1404
+ 403,
1405
+ 398,
1406
+ 593,
1407
+ 443
1408
+ ],
1409
+ "page_idx": 10
1410
+ },
1411
+ {
1412
+ "type": "text",
1413
+ "text": "Fan et al. (2016) uses $\\ell _ { 1 / 2 }$ regularization to produce sparsity directly. The gradient for $\\ell _ { 1 / 2 }$ regularization is $\\scriptstyle { \\frac { 1 } { 2 } } \\left| w _ { j } \\right| ^ { - 1 / 2 }$ . This term is smaller for weights with larger magnitude. Our expectation is that $\\ell _ { 1 / 2 }$ will drive unimportant weights towards zero while leaving large weights relatively unaffected, thus avoiding the accuracy loss associated with excessive regularization. ",
1414
+ "bbox": [
1415
+ 173,
1416
+ 455,
1417
+ 825,
1418
+ 515
1419
+ ],
1420
+ "page_idx": 10
1421
+ },
1422
+ {
1423
+ "type": "text",
1424
+ "text": "For our $\\ell _ { 1 }$ and $\\ell _ { 1 / 2 }$ experiments, we use the Deep Speech 2 Bidirectional RNN baseline model described in Section 4. These models are trained for 25 epochs on our internal training dataset of 2000 hours. The results are reported on a independent test set consisting of 2.9 hours. ",
1425
+ "bbox": [
1426
+ 174,
1427
+ 522,
1428
+ 825,
1429
+ 564
1430
+ ],
1431
+ "page_idx": 10
1432
+ },
1433
+ {
1434
+ "type": "table",
1435
+ "img_path": "images/5390a7d43a6c30331feeec980c86dd203532f2a9cb6e9839ea3d4c6731019353.jpg",
1436
+ "table_caption": [
1437
+ "Table 7: $\\ell _ { 1 }$ and $\\ell _ { 1 / 2 }$ results with the bidirectional RNN model with 1760 hidden units "
1438
+ ],
1439
+ "table_footnote": [],
1440
+ "table_body": "<table><tr><td>MODEL</td><td>#PARAMS (in millions)</td><td>SPARSITY</td><td>CER</td><td>RELATIVE PERF</td><td>PRUNING ALGORITHM</td></tr><tr><td></td><td></td><td></td><td></td><td></td><td></td></tr><tr><td>RNN Dense</td><td>67</td><td>0.0%</td><td>15.36</td><td>0.0%</td><td>N/A</td></tr><tr><td>RNN Sparse</td><td>7.3</td><td>89.2%</td><td>17.32</td><td>-12.8%</td><td>Weight pruning</td></tr><tr><td>RNN Sparse</td><td>11.2</td><td>83.6%</td><td>24.8</td><td>-61.5%</td><td>l1</td></tr><tr><td>RNN Sparse</td><td>7.4</td><td>89.1%</td><td>17.28</td><td>-12.5%</td><td>l1 with pruning</td></tr><tr><td>RNN Sparse</td><td>6.6</td><td>90.3%</td><td>18.50</td><td>-20.4%</td><td>l1/2 with pruning</td></tr></table>",
1441
+ "bbox": [
1442
+ 199,
1443
+ 608,
1444
+ 797,
1445
+ 726
1446
+ ],
1447
+ "page_idx": 10
1448
+ },
1449
+ {
1450
+ "type": "text",
1451
+ "text": "Without pruning, $\\ell _ { 1 }$ model results in significantly worse accuracy compared to the dense baseline. Combining $\\ell _ { 1 }$ with weight pruning allows us to recover the loss in accuracy with similar sparsity. The $\\ell _ { 1 / 2 }$ with pruning model performs worse than the $\\ell _ { 1 }$ with pruning model. Comparing the two regularizers, this result indicates that $\\ell _ { 1 }$ is better at guiding pruning than $\\ell _ { 1 / 2 }$ , more suitable as a regularizer, or both. ",
1452
+ "bbox": [
1453
+ 173,
1454
+ 744,
1455
+ 825,
1456
+ 815
1457
+ ],
1458
+ "page_idx": 10
1459
+ },
1460
+ {
1461
+ "type": "text",
1462
+ "text": "Similar to group lasso experiments, $\\ell _ { 1 }$ regularization experiments require a significantly higher $\\lambda$ to achieve high sparsity without any pruning. We suspect that these regularizers would be more successful in inducing sparsity for models that overfit the training training dataset. ",
1463
+ "bbox": [
1464
+ 174,
1465
+ 821,
1466
+ 825,
1467
+ 864
1468
+ ],
1469
+ "page_idx": 10
1470
+ },
1471
+ {
1472
+ "type": "text",
1473
+ "text": "B PRUNING CHARACTERISTICS ",
1474
+ "text_level": 1,
1475
+ "bbox": [
1476
+ 176,
1477
+ 102,
1478
+ 450,
1479
+ 118
1480
+ ],
1481
+ "page_idx": 11
1482
+ },
1483
+ {
1484
+ "type": "text",
1485
+ "text": "In this section, we discuss some pruning characteristics and how they relate to training and accuracy of the models. ",
1486
+ "bbox": [
1487
+ 174,
1488
+ 133,
1489
+ 823,
1490
+ 161
1491
+ ],
1492
+ "page_idx": 11
1493
+ },
1494
+ {
1495
+ "type": "text",
1496
+ "text": "B.1 PRUNING SCHEDULE ",
1497
+ "text_level": 1,
1498
+ "bbox": [
1499
+ 176,
1500
+ 179,
1501
+ 362,
1502
+ 193
1503
+ ],
1504
+ "page_idx": 11
1505
+ },
1506
+ {
1507
+ "type": "text",
1508
+ "text": "In Figure 4a, we plot the pruning schedule of a recurrent and linear layer of the bidirectional model trained with Block Pruning (BP) and Weight Pruning (WP) (Narang et al., 2017) and Group lasso with block pruning (GLP). For all three algorithms, pruning begins just after the first epoch at 2700 iterations. The BP and GLP models result in a sharper curve with more weights being set to zero in a short span of iterations. In these experiments, we use the max function to reduce the blocks to a single value which could be the cause of the sharpness in pruning. Also the GLP model reaches $90 \\%$ sparsity just before 10,000 iterations which is significantly earlier than the BP model. GLP training encourages sparsity early on in the training run by pushing the blocks of weights towards zero. ",
1509
+ "bbox": [
1510
+ 173,
1511
+ 205,
1512
+ 825,
1513
+ 316
1514
+ ],
1515
+ "page_idx": 11
1516
+ },
1517
+ {
1518
+ "type": "text",
1519
+ "text": "B.2 OUTPUT CONNECTIONS ",
1520
+ "text_level": 1,
1521
+ "bbox": [
1522
+ 176,
1523
+ 333,
1524
+ 383,
1525
+ 347
1526
+ ],
1527
+ "page_idx": 11
1528
+ },
1529
+ {
1530
+ "type": "text",
1531
+ "text": "Figure 4b shows the histogram of the number of output connections for all the neurons in a network for two models with different sparsity pruned with BP. The $94 \\%$ sparse model does significantly worse than the $89 \\%$ sparse. For the model with $89 \\%$ sparsity, only 180 neurons have all their output weights set to zero out of a total of 38270. This model produced good accuracy relative to the dense baseline. However, increasing the sparsity to $94 \\%$ for the layer results in 1620 neurons having all zero output weights. Additionally, a lot more neurons have a smaller number of non-zero output weights. ",
1532
+ "bbox": [
1533
+ 173,
1534
+ 359,
1535
+ 825,
1536
+ 457
1537
+ ],
1538
+ "page_idx": 11
1539
+ },
1540
+ {
1541
+ "type": "image",
1542
+ "img_path": "images/cf8909cb8007d8c56d86178dbf5138a82bbc5a635c84dcf15624555460165d5b.jpg",
1543
+ "image_caption": [
1544
+ "Figure 4: Figure 4a shows the pruning schedule for two layers in the network for WP, GLP and BP models. The GLP and BP models use block size of $4 \\mathbf { x } 4$ . Figure 4b plots the histogram of the number of output connections for all neurons in the network using block pruning with $4 \\times 4$ blocks. "
1545
+ ],
1546
+ "image_footnote": [],
1547
+ "bbox": [
1548
+ 194,
1549
+ 484,
1550
+ 771,
1551
+ 670
1552
+ ],
1553
+ "page_idx": 11
1554
+ },
1555
+ {
1556
+ "type": "text",
1557
+ "text": "B.3 SPARSITY VS LAYERS ",
1558
+ "text_level": 1,
1559
+ "bbox": [
1560
+ 176,
1561
+ 750,
1562
+ 369,
1563
+ 763
1564
+ ],
1565
+ "page_idx": 11
1566
+ },
1567
+ {
1568
+ "type": "text",
1569
+ "text": "Figure 5 shows the sparsity of all the recurrent layers in the network using BP and WP. All recurrent layers have the same pruning hyper-parameters. Layer 1 is the first recurrent layer and layer 14 is the final recurrent layer before the CTC cost layer. For both block pruning and weight pruning, we see that the initial layers are pruned more aggressively compared to the final layers. Increasing sparsity in the layers closer to the output results in poor accuracy. Additionally, the variance in sparsity across the layers increases with the block size. This increasing variance makes it harder to increase the block size beyond $3 2 \\times 3 2$ with the same pruning hyper-parameters for all recurrent layers. ",
1570
+ "bbox": [
1571
+ 173,
1572
+ 775,
1573
+ 825,
1574
+ 873
1575
+ ],
1576
+ "page_idx": 11
1577
+ },
1578
+ {
1579
+ "type": "image",
1580
+ "img_path": "images/e29ca40fca4c38e0eac458b2a8d3b7dfbe2215d5a98cc4e29b9ba5ef4b5aaa2f.jpg",
1581
+ "image_caption": [
1582
+ "Figure 5: Sparsity of different recurrent layers in the network in the RNN model, pruned using BP and WP. "
1583
+ ],
1584
+ "image_footnote": [],
1585
+ "bbox": [
1586
+ 303,
1587
+ 101,
1588
+ 692,
1589
+ 280
1590
+ ],
1591
+ "page_idx": 12
1592
+ }
1593
+ ]
parse/train/HJaDJZ-0W/HJaDJZ-0W_middle.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/HJaDJZ-0W/HJaDJZ-0W_model.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/pbXQtKXwLS/pbXQtKXwLS.md ADDED
@@ -0,0 +1,398 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # GUIDING NEURAL NETWORK INITIALIZATION VIA MARGINAL LIKELIHOOD MAXIMIZATION
2
+
3
+ Anonymous authors Paper under double-blind review
4
+
5
+ # ABSTRACT
6
+
7
+ We propose a simple approach to help guide hyperparameter selection for neural network initialization. We leverage the relationship between neural network and Gaussian process models having corresponding activation and covariance functions to infer the hyperparameter values desirable for model initialization. Our experiment shows that marginal likelihood maximization provides recommendations that yield near-optimal prediction performance on MNIST classification task under experiment constraints. Furthermore, our empirical results indicate consistency in the proposed technique, suggesting that computation cost for the procedure could be significantly reduced with smaller training sets.
8
+
9
+ # 1 INTRODUCTION
10
+
11
+ Training deep neural networks successfully can be challenging. However, with proper initialization trained models could improve their prediction performance. Various initialization strategies in neural network have been discussed extensively in numerous research works. Glorot and Bengio (2010) focused on linear cases and proposed the normalized initialization scheme (also known as Xavier-initialization). Their derivation was obtained by considering activation variances in the forward path and the gradient variance in back-propagation. He-initialization (He et al., 2015) was developed for very deep networks with rectifier nonlinearities. Their approach imposed a condition on the weight variances to control the variation in the input magnitudes. Because of its success, He-initialization has become the de facto choice for deep ReLU networks. While Glorot- and Heinitialization schemes recognize the importance of and make use of the hidden layer widths in their formulation, other methods were also suggested to improve training in deep neural networks.
12
+
13
+ Mishkin and Matas (2016) demonstrated that pre-initialization with orthonormal matrices followed by output variance normalization produces prediction performance comparable to, if not better than, standard techniques. Additionally, Schoenholz et al. (2017) developed the bound on the network depth based on the principle of ’Edge of Chaos’ given a particular set of initialization hyperparameters. Furthermore, Hayou et al. (2019) showed that theoretically and in practice proper initialization parameter tuning with appropriate activation function is important to model training for improved performance.
14
+
15
+ Neal (1996) showed that as a fully-connected, single-hidden-layer feedforward untrained neural network becomes infinitely wide, Gaussian prior distributions over the network hidden-to-output weights and biases converge to a Gaussian process, under the assumption that the parameters are independent. In other words, the untrained infinite neural network and its induced Gaussian process counterpart are equivalent. Also, as a result of the central limit theorem, the covariance between network output evaluated at different inputs can be represented as a function of the hidden node activation function. Intuitively, we could therefore relate the prediction performance of an untrained, finite-width, single-hidden-layer, fully-connected feedforward neural network to a Gaussian process model with a covariance function corresponding to the network’s activation function.
16
+
17
+ In this work we propose a simple and efficient method that learns from training data to guide the selection of initialization hyperparameters in neural networks. Marginal likelihood is a popular tool for choosing kernel hyperparameters in model selection. Its applications in convolutional Gaussian processes and deep kernel learning are discussed, respectively, in (van der Wilk et al., 2017; Wilson et al., 2016). Our method aims to synergize this powerful functionality of marginal likelihood and the relationship between untrained neural networks and Gaussian process models to make recommendations for neural network initialization. We first derive the covariance function corresponding to the activation function of the network whose prediction performance we wish to evaluate. We then employ marginal likelihood optimization for the Gaussian process model to learn hyperparameters from data. We hypothesize that the optimal set of hyperparameter values could improve initialization of the neural network.
18
+
19
+ # 2 APPROACH
20
+
21
+ To assess our proposed method, we build a neural network and a Gaussian process model with corresponding activation and covariance functions. With the Gaussian process we estimate the covariance hyperparameters from training data. These hyperparameter values are then applied in the neural network to evaluate and compare its prediction accuracy among various hyperparameter sets.
22
+
23
+ We first describe the structure of the neural network, followed by the Gaussian process model and the underlying reason for employing the marginal likelihood. Then, given the network activation function we proceed to derive a closed form representation of its counterpart covariance function.
24
+
25
+ # 2.1 SINGLE-HIDDEN-LAYER NEURAL NETWORKS
26
+
27
+ Our neural network model is a fully-connected, single-hidden-layer feedforward network with 2000 hidden nodes and rectified linear unit (ReLU) activation function. Following (Lee et al., 2018), we conduct our empirical study by considering classifying MNIST images as regression prediction. Inasmuch as the network is designed for regression, we choose the mean square error (MSE) loss as its objective function, along with Adam optimizer, and accuracy as the performance metric. In addition, one-hot encoding is utilized to generate class labels, where an incorrectly labeled class is designated -0.1, and a correctly labeled class 0.9 . For example, the one-hot representation of the integer 7 is given by [-0.1, -0.1, -0.1, -0.1, -0.1, -0.1, -0.1, 0.9, -0.1, -0.1].
28
+
29
+ ![](images/54731f17b5c85d9323726dd1860cf907a524807ca14936340cb33c5c88ef53d2.jpg)
30
+ Figure 1: A single-hidden-layer, fully-connected feedforward neural network for regression prediction. Left panel: Structural diagram of the neural network. Right panel: ReLU activation function: $\phi ( a ) : = ( \bar { a } ) _ { + } = \operatorname* { m a x } ( 0 , a ) = \bar { a }$ for $a \geq 0 ; \phi ( a ) = 0$ otherwise.
31
+
32
+ As shown in the left panel of Figure (1), the single-hidden-layer neural network has a set of inputs denoted by $x = \{ x _ { k } ^ { 0 } \} , k \in \{ 1 , 2 , \cdots , d _ { i n } \}$ with input layer width $d _ { i n } = N _ { 0 } = 2 8 { \mathrm { x } } 2 8 = 7 8 4 .$ . The model’s weight and bias parameters from $k ^ { t h }$ input node to $j ^ { t h }$ hidden node are $W _ { j k } ^ { 0 }$ iid∼ $\begin{array} { r } { \mathcal N ( 0 , \frac { \sigma _ { w } ^ { 2 } } { N _ { 0 } } ) , b _ { j } ^ { 0 } \overset { \mathrm { i i d } } { \sim } \mathcal N ( 0 , \sigma _ { b } ^ { 2 } ) } \end{array}$ , and $W _ { j k } ^ { 0 } \perp \perp b _ { j } ^ { 0 }$ . Similarly, the weight and bias parameters from $j ^ { t h }$ hid0den node to $i ^ { t h }$ output node with hidden layer width $N _ { 1 } = d _ { i n } = 2 0 0 0$ are $\begin{array} { r } { W _ { i j } ^ { 1 } \stackrel { \mathrm { i i d } } { \sim } \mathcal N ( 0 , \frac { \sigma _ { w } ^ { 2 } } { N _ { 1 } } ) , b _ { i } ^ { 1 } } \end{array}$ iid∼ $\mathcal { N } ( 0 , \sigma _ { b } ^ { 2 } )$ , and $W _ { i j } ^ { 1 } \perp \perp b _ { i } ^ { 1 }$ . For regression models the output layer has a single node, and therefore $i \in \{ 1 \}$ . The ReLU nonlinearity is depicted in the right panel of Figure (1).
33
+
34
+ The input to each hidden node nonlinearity (the pre-activation) is represented by $z _ { j } ^ { 0 } ( x ) = b _ { j } ^ { 0 } +$ $\textstyle \sum _ { k = 1 } ^ { d _ { i n } } W _ { j k } ^ { 0 } x _ { k } ^ { 0 }$ , while the hidden unit output after the nonlinearity (the post-activation) is denoted by $x _ { j } ^ { 1 } ( x ) = \phi ( z _ { j } ^ { 0 } ( x ) )$ , $j \in \{ 1 , 2 , \cdots , N _ { 1 } \}$ . Since we typically apply linear activation function in the output stage of a regression model, the model output is simply $\begin{array} { r } { z _ { i } ^ { 1 } ( x ) = b _ { i } ^ { 1 } + \sum _ { j = 1 } ^ { N _ { 1 } } W _ { i j } ^ { 1 } x _ { j } ^ { 1 } ( x ) } \end{array}$ .
35
+
36
+ # 2.2 GAUSSIAN PROCESSES
37
+
38
+ A Gaussian process (MacKay, 1998; Neal, 1998; Williams and Rasmussen, 2006; Bishop, 2006) is a set of random variables any finite collection of which follows a multivariate normal distribution. A Guassian process prediction model exploits this unique property and offers a Bayesian approach to solving machine learning problems. The model is completely specified by its mean function and covariance function.
39
+
40
+ By choosing a particular covariance function, a prior distribution over functions is induced which, together with observed inputs and targets, can be used to generate prediction distribution for making predictions and uncertainty measures on unknown test points. These capabilities allow Gaussian processes to be used effectively in many important machine learning applications such as human pose inference (Urtasun and Darrell, 2008) and object classification (Kapoor et al., 2010). Recent research works also apply Gaussian processes in deep structures for image classification (van der Wilk et al., 2017) and regression tasks (Wilson et al., 2016).
41
+
42
+ To help achieve optimal performance for Guassian process prediction we select a suitable covariance function and tune the model by adjusting hyperparameters characterizing the covariance function. This can be accomplished by applying the marginal likelihood which is a crucial feature that enables Gaussian processes to learn proper hyperparameter values from training data.
43
+
44
+ # 2.3 HYPERPARAMETERS AND MARGINAL LIKELIHOOD OPTIMIZATION
45
+
46
+ We briefly describe the procedure for estimating optimal hyperparamter values via maximizing the Gaussian process marginal likelihood function.
47
+
48
+ Consider a set of $N$ multidimensional input data $X ~ = ~ \{ x _ { i } \} _ { i = 1 } ^ { N }$ , $x _ { i } \in \mathcal { R } ^ { D }$ , and target set $y =$ $\{ y _ { i } \} _ { i = 1 } ^ { N }$ , $y _ { i } \in \mathcal R$ . For each input $x _ { i }$ we have a corresponding input-output pair $( x _ { i } , y _ { i } )$ , where the observed output target is given by $y _ { i } = f ( x _ { i } ) + \epsilon _ { i }$ , with data noise $\epsilon _ { i } \sim \mathcal { N } ( 0 , \sigma _ { n } ^ { 2 } )$ . We model the input-output latent function $f$ as a Gaussian process :
49
+
50
+ $$
51
+ f ( \boldsymbol { x } _ { i } ) \sim \mathcal { G P } \big ( \mu ( \boldsymbol { x } _ { i } ) , k ( \boldsymbol { x } _ { i } , \boldsymbol { x } _ { j } ) \big ) ,
52
+ $$
53
+
54
+ where we customarily set the mean function $\mu ( x _ { i } ) : = E [ f ( x _ { i } ) ] = 0$ , and denote $k ( x _ { i } , x _ { j } )$ as the covariance function.
55
+
56
+ The marginal likelihood (or evidence) (Williams and Rasmussen, 2006; Bishop, 2006) measures the probability of observed targets given input data and can be expressed as the integral of the product of likelihood and the prior, marginalized over the latent function $f$ :
57
+
58
+ $$
59
+ p ( y | X ) = \int p ( y , f | X ) d f = \int p ( y | f , X ) p ( f | X ) d f .
60
+ $$
61
+
62
+ $\{ y _ { i } \} _ { i = 1 } ^ { N } \stackrel { \smile } { = } \{ f ( x _ { i } ) + \epsilon _ { i } \} _ { i = 1 } ^ { N }$ can be obtaine, which gives us $y | \dot { X } \sim \mathcal { N } ( 0 , \mathcal { K } + \sigma _ { n } ^ { 2 } I )$ the iwhere $\mathcal { K } \breve { = } [ k ( x _ { i } , x _ { j } ) ] _ { i , j = 1 } ^ { \tilde { N } }$ ticinand $I$ $_ \mathrm { N }$ $\mathbf { N }$
63
+
64
+ $$
65
+ p ( y | X ) = \frac { 1 } { ( 2 \pi ) ^ { N / 2 } | K + \sigma _ { n } ^ { 2 } I | ^ { 1 / 2 } } \exp \Big ( - \frac { 1 } { 2 } y ^ { T } ( K + \sigma _ { n } ^ { 2 } I ) ^ { - 1 } y \Big ) .
66
+ $$
67
+
68
+ To facilitate computation, we evaluate the log marginal likelihood which is given by
69
+
70
+ $$
71
+ \log p ( y | X ) = - \frac { 1 } { 2 } { y } ^ { T } \bigl ( K + \sigma _ { n } ^ { 2 } I \bigr ) ^ { - 1 } y - \frac { 1 } { 2 } \mathrm { l o g } \left| K + \sigma _ { n } ^ { 2 } I \right| - \frac { N } { 2 } \mathrm { l o g } 2 \pi .
72
+ $$
73
+
74
+ We are reminded here that the marginal likelihood is applied directly on the entire training dataset, rather than a validation subset. In addition, Cholesky decomposition (Neal, 1998) can be employed to calculate the term $\left( \boldsymbol { \mathcal { K } } + \sigma _ { n } ^ { 2 } \boldsymbol { I } \right) ^ { - 1 }$ in equation (2).
75
+
76
+ # 2.4 RELU COVARIANCE FUNCTION
77
+
78
+ With the structure of the single-hidden-layer ReLU neural network defined, we proceed to study its corresponding ReLU Gaussian process.
79
+
80
+ The ReLU covariance function is developed to estimate the covariance at the output of the ReLU neural network model. Our alternative derivation was inspired by the work on arc-cosine family of kernels developed in (Cho and Saul, 2009). In our work we first derive the expectation of the product of post-activations, instead of on the input to the nonlinearity (Lee et al., 2018). Then, we apply the output layer activation function on the post-activation expected value. It can be shown that the resulting representations are equivalent. The complete derivation of our expression is provided in the Appendix 5.
81
+
82
+ Referring to Figure 1, we consider input vectors $x ^ { 0 } , y ^ { 0 } \in \mathcal { R } ^ { d _ { i n } }$ . The initial weight value is drawn randomly from the Gaussian distribution fW 0jk = N (0, σ2wdin ) and bias value from fb0j = N (0, σ2b ). The expected value of the product of post-activations at the output of the $j ^ { t h }$ hidden node is computed as
83
+
84
+ $$
85
+ \begin{array} { r l } & { E [ \mathbf { X } _ { j } ( { x } ^ { 0 } ) \mathbf { X } _ { j } ( { y } ^ { 0 } ) ] } \\ & { \ = \displaystyle \int \cdots \int _ { - \infty } ^ { \infty } \operatorname* { m a x } ( b _ { j } ^ { 0 } + w _ { j } ^ { 0 } \cdot { x } ^ { 0 } ) \operatorname* { m a x } ( b _ { j } ^ { 0 } + w _ { j } ^ { 0 } \cdot { y } ^ { 0 } ) f _ { b _ { j } ^ { 0 } , W _ { j } ^ { 0 } } ( b , w ) d w _ { j } ^ { 0 } d b _ { j } ^ { 0 } } \\ & { \ = \displaystyle \int \cdots \int _ { - \infty } ^ { \infty } ( b _ { j } ^ { 0 } + w _ { j } ^ { 0 } \cdot { x } ^ { 0 } ) _ { + } ( b _ { j } ^ { 0 } + w _ { j } ^ { 0 } \cdot { y } ^ { 0 } ) _ { + } f _ { b _ { j } ^ { 0 } , W _ { j } ^ { 0 } } ( b , w ) d w _ { j } ^ { 0 } d b } \end{array}
86
+ $$
87
+
88
+ Suppose we denote the pre-activations as
89
+
90
+ $$
91
+ \begin{array} { l } { { U = b _ { j } ^ { 0 } + W _ { j } ^ { 0 } \cdot x ^ { 0 } = b _ { j } ^ { 0 } + \displaystyle \sum _ { k = 1 } ^ { d _ { i n } } W _ { j k } ^ { 0 } x _ { k } ^ { 0 } \sim \mathcal N ( 0 , \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \| x \| ^ { 2 } ) , } } \\ { { \displaystyle V = b _ { j } ^ { 0 } + W _ { j } ^ { 0 } \cdot y ^ { 0 } = b _ { j } ^ { 0 } + \displaystyle \sum _ { k ^ { \prime } = 1 } ^ { d _ { i n } } W _ { j k ^ { \prime } } ^ { 0 } y _ { k ^ { \prime } } ^ { 0 } \sim \mathcal N ( 0 , \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \| y \| ^ { 2 } ) . } } \end{array}
92
+ $$
93
+
94
+ It can be shown that the random variables $U , V$ have a joint Gaussian distribution:
95
+
96
+ $$
97
+ { \binom { U } { V } } \sim { \mathcal { N } } ( 0 , \Sigma ) , { \mathrm { ~ w h e r e ~ } } \Sigma = { \binom { \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \| x \| ^ { 2 } } { \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } ( x \cdot y ) } } \quad \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } ( x \cdot y ) \quad ) ,
98
+ $$
99
+
100
+ for simplicity we let $x = x ^ { 0 } , y = y ^ { 0 }$ . We can therefore write expression (3) as
101
+
102
+ $$
103
+ \iint _ { 0 } ^ { \infty } u v \frac { 1 } { 2 \pi | \Sigma | ^ { \frac { 1 } { 2 } } } \exp \big ( - \frac { 1 } { 2 } ( u , v ) \Sigma ^ { - 1 } ( u , v ) ^ { T } \big ) d u d v .
104
+ $$
105
+
106
+ $$
107
+ \begin{array} { l } { { \displaystyle \Sigma ^ { - 1 } = \binom { a _ { 1 1 } } { a _ { 2 1 } } \mathrm { , ~ w h e r e ~ } a _ { 1 1 } = \frac { 1 } { D } ( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \| y \| ^ { 2 } ) \mathrm { , ~ } a _ { 2 2 } = \frac { 1 } { D } ( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \| x \| ^ { 2 } ) \mathrm { , ~ } } } \\ { { \displaystyle a _ { 1 2 } = a _ { 2 1 } = \frac { - 1 } { D } ( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } ( x \cdot y ) ) . } } \end{array}
108
+ $$
109
+
110
+ With polar coordinate transformation: $\begin{array} { r } { u \ = \ \frac { r } { \sqrt { a _ { 1 1 } } } \cos \alpha , v \ = \ \frac { r } { \sqrt { a _ { 2 2 } } } \sin \alpha . } \end{array}$ , expression (3) can be further reduced to
111
+
112
+ $$
113
+ \begin{array} { r l } & { \frac { 1 } { 4 \pi \mathcal { D } ^ { 1 / 2 } a _ { 1 1 } a _ { 2 2 } } \displaystyle \int _ { \alpha = 0 } ^ { \frac { \pi } { 2 } } \frac { 2 \sin 2 \alpha } { \left( 1 - \cos \phi \sin 2 \alpha \right) ^ { 2 } } d \alpha } \\ & { = \frac { 1 } { 2 \pi \mathcal { D } ^ { 1 / 2 } a _ { 1 1 } a _ { 2 2 } \sin ^ { 3 } \phi } \Big ( \sin ( \phi ) + ( \pi - \phi ) \cos ( \phi ) \Big ) , \mathrm { ~ w h e r e ~ } \phi = \cos ^ { - 1 } \Big ( \frac { - a _ { 1 2 } } { \sqrt { a _ { 1 1 } a _ { 2 2 } } } \Big ) . } \end{array}
114
+ $$
115
+
116
+ With some algebraic operations and after computing the entries in $\Sigma ^ { - 1 }$ , we arrive at
117
+
118
+ $$
119
+ \begin{array} { l } { { \displaystyle E [ { \bf X } _ { j } ( x ) { \bf X } _ { j } ( y ) ] } } \\ { { \displaystyle = \frac { 1 } { 2 \pi } \Big ( \sigma _ { b } ^ { 2 } + \| x \| ^ { 2 } \sigma _ { w } ^ { 2 } \Big ) ^ { \frac { 1 } { 2 } } \Big ( \sigma _ { b } ^ { 2 } + \| y \| ^ { 2 } \sigma _ { w } ^ { 2 } \Big ) ^ { \frac { 1 } { 2 } } \Big ( \sin \phi + ( \pi - \phi ) \cos \phi \Big ) } } \\ { { \displaystyle \mathrm { w h e r e ~ } \phi = \cos ^ { - 1 } \left\{ \frac { \sigma _ { b } ^ { 2 } + ( x \cdot y ) \sigma _ { w } ^ { 2 } } { \Big ( \sigma _ { b } ^ { 2 } + \| x \| ^ { 2 } \sigma _ { w } ^ { 2 } \Big ) ^ { 1 / 2 } \Big ( \sigma _ { b } ^ { 2 } + \| y \| ^ { 2 } \sigma _ { w } ^ { 2 } \Big ) ^ { 1 / 2 } } \right\} . } } \end{array}
120
+ $$
121
+
122
+ To compute the expected value, $\begin{array} { r } { E [ \mathbf { X } _ { j } ( x ) ] \ = \ \int \operatorname* { m a x } ( b + w \cdot x ) f _ { b _ { j } ^ { 0 } , W _ { j k } ^ { 0 } } ( b , w ) d w d b } \end{array}$ , we denote $U = b + w \cdot x \sim N ( 0 , \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \| x \| ^ { 2 } )$ , and apply the change in variable ${ \frac { 1 } { 2 \sigma ^ { 2 } } } u ^ { 2 } = t$ , where $\sigma ^ { 2 } = $ $\sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \lVert x \rVert ^ { 2 }$ to obtain
123
+
124
+ $$
125
+ \begin{array} { l } { { \displaystyle E [ { \bf X } _ { j } ( x ) ] = \int _ { - \infty } ^ { \infty } \left( u \right) + f _ { U } \left( u \right) d u } } \\ { ~ } \\ { { \displaystyle = \int _ { 0 } ^ { \infty } u \frac { 1 } { \sqrt { 2 \pi } \sigma } e ^ { - \frac { 1 } { 2 \sigma ^ { 2 } } u ^ { 2 } } d u } } \\ { { \displaystyle = \int _ { 0 } ^ { \infty } \sigma ^ { 2 } d u \frac { 1 } { \sqrt { 2 \pi } \sigma } e ^ { - t } } } \\ { { \displaystyle = \frac { \sigma } { \sqrt { 2 \pi } } } } \\ { { \displaystyle = \frac { \sqrt { \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } } \left| x \right| / 2 } { \sqrt { 2 \pi } } } } \end{array}
126
+ $$
127
+
128
+ The covariance function at the network output is therefore determined to be
129
+
130
+ $$
131
+ \begin{array} { l } { { \displaystyle E \Big [ \big ( b _ { i } ^ { 1 } + \sum _ { j = 1 } ^ { N _ { 1 } } W _ { i j } ^ { 1 } \mathbf { X } _ { j } ( x ) \big ) \big ( b _ { i } ^ { 1 } + \sum _ { k = 1 } ^ { N _ { 1 } } W _ { i k } ^ { 1 } \mathbf { X } _ { k } ( y ) \big ) \Big ] - E \Big [ b _ { i } ^ { 1 } + \sum _ { j = 1 } ^ { N _ { 1 } } W _ { i j } ^ { 1 } \mathbf { X } _ { j } ( x ) \Big ] \Big [ b _ { i } ^ { 1 } + \sum _ { k = 1 } ^ { N _ { 1 } } W _ { i k } ^ { 1 } \mathbf { X } _ { k } ( y ) \Big ] } } \\ { { \displaystyle = E [ ( b _ { i } ^ { 1 } ) ^ { 2 } ] + \sum _ { j = 1 } ^ { N _ { 1 } } E [ ( W _ { i j } ^ { 1 } ) ^ { 2 } ] E [ \mathbf { X } _ { j } ( x ) \mathbf { X } _ { j } ( y ) ] - \frac { 1 } { 2 \pi } \sqrt { \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \| x \| ^ { 2 } } \sqrt { \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \| y \| ^ { 2 } } } } \\ { { \displaystyle = \sigma _ { b } ^ { 2 } + \frac { \sigma _ { w } ^ { 2 } } { N _ { 1 } } N _ { 1 } E [ \mathbf { X } _ { j } ( x ) \mathbf { X } _ { j } ( y ) ] - \frac { 1 } { 2 \pi } \sqrt { \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \| x \| ^ { 2 } } \sqrt { \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \| y \| ^ { 2 } } } } \\ { { \displaystyle = \sigma _ { b } ^ { 2 } + \frac { \sigma _ { w } ^ { 2 } } { 2 \pi } \Big ( \sigma _ { b } ^ { 2 } + \| x \| ^ { 2 } \sigma _ { w } ^ { 2 } \Big ) ^ { \frac { 1 } { 2 } } \Big ( \sigma _ { b } ^ { 2 } + \| y \| ^ { 2 } \sigma _ { w } ^ { 2 } \Big ) ^ { \frac { 1 } { 2 } } \Big ( \sin \phi + ( \pi - \phi ) \cos \phi - 1 \Big ) . } } \end{array}
132
+ $$
133
+
134
+ # 2.5 GAUSSIAN PROCESS PREDICTION: A SIMULATION
135
+
136
+ Performing simulations allows us to explore and understand some properties of the models we wish to study. Simulation results also offer the opportunity for evaluating model precision and insight into observed events.
137
+
138
+ To demonstrate making predictions with Gaussian process regression model, we borrow equations from (Williams and Rasmussen, 2006) where the formulation of Gaussian process predictive distribution is treated in great detail.
139
+
140
+ Given the design matrix $X = \{ x _ { i } \} _ { i = 1 } ^ { N }$ , $\boldsymbol { x } _ { i } \in \mathcal { R } ^ { D }$ , observed targets $y = \{ y _ { i } \} _ { i = 1 } ^ { N }$ , $y _ { i } \in \mathcal { R }$ , unknown test data $X _ { * }$ , and their function values $f _ { * } : = f ( X _ { * } )$ , the joint distribution of the target and function values is computed as
141
+
142
+ $$
143
+ \biggl [ \mathop { y } _ { * } \biggr ] \sim N \biggl ( 0 , \left[ \begin{array} { c c } { K ( X , X ) + \sigma _ { n } ^ { 2 } I } & { K ( X , X _ { * } } \\ { K ( X _ { * } , X ) } & { K ( X _ { * } , X _ { * } ) } \end{array} \right] \biggr ) ,
144
+ $$
145
+
146
+ where $K ( X , X )$ represents the covariance matrix of all pairs of training points, $K ( X , X _ { * } )$ denotes that of pairs of training and test points, and $K ( X _ { * } , X _ { * } )$ gives the covariance matrix of pairs of test points.
147
+
148
+ The prediction distribution is the conditional distribution
149
+
150
+ $$
151
+ f _ { * } | X , y , X _ { * } \sim N ( \mu _ { * } , \Sigma _ { * } )
152
+ $$
153
+
154
+ $$
155
+ \begin{array} { l } { \operatorname { i o n } \mu _ { \ast } = K ( X _ { \ast } , X ) \big [ K ( X , X ) + \sigma _ { n } ^ { 2 } I \big ] ^ { - 1 } y } \\ { \Sigma _ { \ast } = K ( X _ { \ast } , X _ { \ast } ) - K ( X _ { \ast } , X ) \big [ K ( X , X ) + \sigma _ { n } ^ { 2 } I \big ] ^ { - 1 } K ( X , X _ { \ast } ) . } \end{array}
156
+ $$
157
+
158
+ The simulation starts out with setting the hyperparameters of the ReLU covariance function to (3.6, 0.02), chosen from $\sigma _ { w } ^ { 2 } \in [ 0 . 4 , 1 . 2 , 2 . 0 , \hat { 2 . } 8 , \hat { 3 . } 6 ]$ , and $\sigma _ { b } ^ { 2 } \in [ 0 . 0 0 0 1 , 0 . 0 1 , 0 . 0 2 ]$ . We randomly select a set of 70 training and 30 test location points from 100 values evenly spaced in the interval [0.0, 1.0]. Ten sample paths, as shown in the top left panel of Figure (2), are generated from the design Gaussian process model. Their sample mean produces 70 training target and 30 test values. We then estimate the optimal hyperparameters from the training targets via evaluating the marginal likelihood, equation (2), over the design ranges of $\sigma _ { w } ^ { 2 }$ and $\sigma _ { b } ^ { 2 }$ .
159
+
160
+ The maximum marginal likelihood is obtained at $\{ \tilde { \sigma } _ { w } ^ { 2 } , \tilde { \sigma } _ { b } ^ { 2 } \} = \{ 3 . 6 , 0 . 0 2 \}$ which is the design hyperparameter pair. The minimum marginal likelihood is obtained at $\{ \hat { \sigma } _ { w } ^ { 2 } , \hat { \sigma } _ { b } ^ { 2 } \} = \{ 3 . 6 , 0 . 0 0 0 \bar { 1 } \}$ . A Gaussian process model is then built with the optimal hyperparameter pair to make predictions for the 30 test location points. The model accuracy is assessed with a RMSE of 0.00051. Additionally we overlay the predicted and true test target values, as shown in the top middle panel of Figure (2), to detect any prediction errors. We plot the line of equality to further validate the estimated hyperparameters, as depicted in the top right panel of the figure.
161
+
162
+ The evaluation process is repeated applying the hyperparameter pair $\big \{ \hat { \sigma } _ { w } ^ { 2 } , \hat { \sigma } _ { b } ^ { 2 } \big \}$ which produces a prediction RMSE of 0.00188, over 3 times as large as the optimal case. The accuracy plots shown in the bottom panels of Figure (2) indicate some prediction errors.
163
+
164
+ ![](images/630c117a9a1155e2a76ef9d401390bae01718d2fe15527a6b199b7a27992f358.jpg)
165
+ Figure 2: Gaussian process regression prediction on simulated data. Top left: 10 sample paths generated from a Gaussian process model with hyperparameters $( \sigma _ { w } ^ { 2 } , \sigma _ { b } ^ { 2 } ) \overset { - } { = } ( 3 . 6 , 0 . 0 2 )$ . Top middle: Point-wise visual comparison between predicted and true target values for the optimal hyperparameter pair $\{ 3 . 6 , 0 . 0 \bar { 2 } \}$ , showing good prediction results. Top right: The line of equality further confirming the prediction accuracy. Bottom left: Point-wise visual comparison for hyperparameter pair $\lbrace 3 . 6 , 0 . 0 0 0 1 \rbrace$ . Bottom right: Prediction errors revealed with the line of equality.
166
+
167
+ Our simulation results agree with the principle that through optimizing the marginal likelihood of the Gaussian process model, we could estimate from training data the hyperparameter values most appropriate for its chosen covariance function.
168
+
169
+ # 3 MNIST CLASSIFICATION EXPERIMENT
170
+
171
+ We conduct a classification experiment on the MNIST handwritten digit dataset (LeCun, 1998) making use of corresponding ReLU neural network and Gaussian process models. As in (Lee et al., 2018), the classification task on the class labels is treated as Gaussian process regression (also known as kriging in spatial statistics (Cressie, 1993)).
172
+
173
+ It is necessary to point out that the goal of this work is to examine using the marginal likelihood to estimate the best available initial hyperparameter setting for neural networks, rather than determining the networks’ optimal structure.
174
+
175
+ Our experiment consists of three main steps: (A) searching within a given grid of hyperparameter values for the pair $\big \{ \tilde { \sigma } _ { w } ^ { 2 } , \tilde { \sigma } _ { b } ^ { 2 } \big \}$ that maximizes the log marginal likelihood function of the Gaussian procepoint $\{ \sigma _ { w } ^ { 2 } , \sigma _ { b } ^ { 2 } \}$ (B) evaluaincluding $\{ \tilde { \sigma _ { w } ^ { 2 } } , \tilde { \sigma } _ { b } ^ { 2 } \}$ ction accuracy of the corresponding neural network at each grid, and (C) assessing neural network performance over all tested
176
+
177
+ # 3.1 PROCEDURE
178
+
179
+ The workflow for the experiment is as follows: we set up a grid map of $\sigma _ { w } ^ { 2 } \in \{ 0 . 4 , 1 . 2 , 2 . 0 , 2 . 8 , 3 . 6 \}$ , $\sigma _ { b } ^ { 2 } \in \{ 0 . 0 , 1 . 0 , 2 . 0 \}$ . Then, $_ \mathrm { N }$ samples are randomly selected from the MNIST training set to form a training subset, where $\mathbf { N }$ is the training size. This is followed by computing the log marginal likelihood (equation 2) at each grid point. This allows us to identify the hyperparameter pair $\big \{ \tilde { \sigma } _ { w } ^ { 2 } , \tilde { \sigma } _ { b } ^ { 2 } \big \}$ that yields the maximum log marginal likelihood value.
180
+
181
+ On the neural network side, we build a fully-connected feedforward neural network with a single hidden layer width, hidden width, of 2000 nodes, Adam optimizer, and mse loss function. Since the network model is fully connected, the size of the input layer $d _ { i n }$ is 28(pixels) $\mathrm { ~ x ~ } 2 8 ( \mathrm { p i x e l s } ) = 7 8 4$ . Prior to training, the initialization parameters $\{ w , b \}$ are set by sampling the distributions $\mathcal { N } ( 0 , \sigma _ { w } ^ { 2 } / d _ { i n } )$ and $\bar { \mathcal { N } } ( 0 , \bar { \sigma _ { b } ^ { 2 } } )$ for weights and biases from the input to the hidden layer, and $\mathcal { N } ( 0 , \sigma _ { w } ^ { 2 } / 2 0 0 0 )$ and $\mathcal { N } ( 0 , \sigma _ { b } ^ { 2 } )$ for weights and biases from the hidden to the output layer. The neural network is then trained with the training subset generated previously. We compute the model classification accuracy on the MNIST test set and repeat the procedure over the entire grid map of hyperparameter pairs.
182
+
183
+ To investigate the usefulness of our proposed approach for assisting model initialization, we employ He-initialization approach as a benchmark to measure numerically and graphically our neural network performance over all tested hyperparameter pairs. Additionally, we check for recommendation consistency.
184
+
185
+ # 3.2 RESULTS
186
+
187
+ Applying the method described in Section 2.3 for estimating model hyperparameter pair we obtain a consistent recommendation of $( \sigma _ { w } ^ { 2 } , \sigma _ { b } ^ { 2 } ) = ( 3 . 6 , 0 . 0 )$ .
188
+
189
+ ![](images/a02e934840c15c37ef77e64fe0bb249ef6869918100ae28d9a2a1ef50254b665.jpg)
190
+ Figure 3: Comparing MNIST training accuracy over various training sizes. We observe that the convergence rate based on our method approaches that using He-initialization as the training size increases. This suggests that our technique may potentially be efficient for guiding deep neural network initialization. Left: train size $= 1 0 0 0$ . Middle: train size $\scriptstyle = 3 0 0 0$ . Right: train size $\mathord { = } 5 0 0 0$ .
191
+
192
+ After running 250 training epochs, convergence of the neural network model and its prediction accuracy are studied for different training sizes. We observe that training based on our initialization approach converges to that based on He-initialization as the size of training samples increases, as shown in Figure 3. This seems to suggest that our approach may be used as an efficient tool for recommending initialization in deep learning.
193
+
194
+ It is worth noting that the Gaussian process model marginal likelihood consistently suggests the hyperparameter pair $( \sigma _ { w } ^ { 2 } , \sigma _ { b } ^ { 2 } ) = ( 3 . \dot { 6 } , 0 )$ . The fact that the bias variance $\sigma _ { b } ^ { 2 }$ is estimated to be 0 coincides with the assumption that bias vector being 0 in (He et al., 2015).
195
+
196
+ Table 1 lists neural network model prediction accuracy based on, respectively, our approach and He-initialization scheme, against the best and the worst performers. The results indicate that more frequently our approach achieves slightly better accuracy than based on He-initialization. However, neither approach reliably gives an estimate of weight variance close to that for the best case.
197
+
198
+ Table 1: Single-hidden-layer fully-connected neural network model prediction accuracy on MNIST test set, and associated hyperparameter pair.
199
+
200
+ <table><tr><td rowspan="2">Size</td><td colspan="2">Best Case</td><td colspan="2">Worst Case</td><td colspan="2">He-Init</td><td colspan="2">Ours</td></tr><tr><td>Acc.</td><td>(,)</td><td>Acc.</td><td>(,0)</td><td>Acc.</td><td>(²,0)</td><td>Acc.</td><td>(,0)</td></tr><tr><td>10000</td><td>96.85</td><td>(2,0)</td><td>96.04</td><td>(0.4,2)</td><td>96.85</td><td>(2,0)</td><td>96.60</td><td>(3.6, 0)</td></tr><tr><td>20000</td><td>97.25</td><td>(2.8,0)</td><td>96.70</td><td>(3.6, 1)</td><td>97.01</td><td>(2,0)</td><td>97.09</td><td>(3.6,0)</td></tr><tr><td>30000</td><td>97.50</td><td>(1.2, 0)</td><td>96.91</td><td>(2,2)</td><td>97.07</td><td>(2,0)</td><td>97.29</td><td>(3.6,0)</td></tr><tr><td>40000</td><td>97.43</td><td>(0.4,0)</td><td>97.16</td><td>(0.4,2)</td><td>97.35</td><td>(2,0)</td><td>97.42</td><td>(3.6,0)</td></tr><tr><td>50000</td><td>97.71</td><td>(3.6,0)</td><td>97.29</td><td>(0.4,2)</td><td>97.50</td><td>(2,0)</td><td>97.71</td><td>(3.6,0)</td></tr></table>
201
+
202
+ # 4 DISCUSSION AND FUTURE WORK
203
+
204
+ In this work we propose a simple, consistent, and time-efficient method to guide the selection of initial hyperparameters for neural networks. We show that through maximizing the log marginal likelihood we can learn from training data hyperparameter setting that leads to accurate and efficient initialization in neural networks.
205
+
206
+ We develop an alternative representation of the ReLU covariance function to estimate the covariance at the output of the ReLU neural network model. We first derive the expectation of the product of post-activations. Then, we apply the output layer activation function on the post-activation expected value to generate the output covariance function. Utilizing marginal likelihood optimization with the derived ReLU covariance function we perform a simulation to demonstrate the effectiveness of Gaussian process regression.
207
+
208
+ We train a fully-connected single-hidden-layer neural network model to perform classification (treated as regression) on MNIST data set. The empirical results indicate that applying the recommended hyperparameter setting for initialization the neural network model performs well, with He-initialization scheme as the benchmark method.
209
+
210
+ A further examination of the results reveals consistency of the process. This implies that smaller training subsets could be used to provide reasonable recommendation for neural network initialization on sizable training data sets, reducing the computation time which is otherwise required for inverting considerably large covariance matrices.
211
+
212
+ The main goal of our future research is to investigate if our proposed method is adequate for deep neural networks with complicated data sets. We wish to ascertain if consistent recommendation could be attained by learning from larger data sets of color images via marginal likelihood maximization. We will attempt to derive or approximate multilayer covariance functions corresponding to various activation functions. Deep fully-connected neural network models will be built to perform classification on CIFAR-10 data set. Our hypothesis is that learning directly from training data helps to improve neural network initialization strategy.
213
+
214
+ # REFERENCES
215
+
216
+ Christopher Bishop. Pattern recognition and machine learning. 2006.
217
+
218
+ Youngmin Cho and Lawrence K. Saul. Kernel Methods for Deep Learning. In Y. Bengio, D. Schuurmans, J. D. Lafferty, C. K. I. Williams, and A. Culotta, editors, Advances in Neural Information Processing Systems 22, pages 342–350. Curran Associates, Inc., 2009. URL http://papers. nips.cc/paper/3628-kernel-methods-for-deep-learning.pdf.
219
+
220
+ Noel AC Cressie. Statistics for spatial data. John Willy and Sons. Inc., New York, 1993.
221
+
222
+ Xavier Glorot and Yoshua Bengio. Understanding the difficulty of training deep feedforward neural networks. AISTATS, page 8, 2010.
223
+
224
+ Soufiane Hayou, Arnaud Doucet, and Judith Rousseau. On the Impact of the Activation Function on Deep Neural Networks Training. ICML, May 2019. URL http://arxiv.org/abs/1902. 06853. arXiv: 1902.06853.
225
+
226
+ Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. Delving Deep into Rectifiers: Surpassing Human-Level Performance on ImageNet Classification. arXiv:1502.01852 [cs], February 2015. URL http://arxiv.org/abs/1502.01852. arXiv: 1502.01852.
227
+
228
+ Ashish Kapoor, Kristen Grauman, Raquel Urtasun, and Trevor Darrell. Gaussian Processes for Object Categorization. International Journal of Computer Vision, 88(2):169–188, June 2010. ISSN 1573-1405. doi: 10.1007/s11263-009-0268-3. URL https://doi.org/10.1007/ s11263-009-0268-3.
229
+
230
+ Yann LeCun. THE MNIST DATABASE of handwritten digits, 1998. URL http://yann. lecun.com/exdb/mnist/.
231
+
232
+ Jaehoon Lee, Yasaman Bahri, Roman Novak, Samuel S. Schoenholz, Jeffrey Pennington, and Jascha Sohl-Dickstein. Deep Neural Networks as Gaussian Processes. arXiv:1711.00165 [cs, stat], March 2018. URL http://arxiv.org/abs/1711.00165. arXiv: 1711.00165.
233
+
234
+ David MacKay. Introduction to Gaussian processes. Citeseer, 1998.
235
+
236
+ Dmytro Mishkin and Jiri Matas. All you need is a good init. ICLR, February 2016. URL http: //arxiv.org/abs/1511.06422. arXiv: 1511.06422.
237
+
238
+ Radford M. Neal. Bayesian Learning for Neural Networks, volume 118 of Lecture Notes in Statistics. Springer New York, New York, NY, 1996. ISBN 978-0-387-94724-2 978-1-4612-0745- 0. doi: 10.1007/978-1-4612-0745-0. URL http://link.springer.com/10.1007/ 978-1-4612-0745-0.
239
+
240
+ Radford M. Neal. Regression and classification using Gaussian process priors. Bayesian statistics, 6:475, 1998.
241
+
242
+ Samuel S. Schoenholz, Justin Gilmer, Surya Ganguli, and Jascha Sohl-Dickstein. Deep Information Propagation. ICLR, April 2017. URL http://arxiv.org/abs/1611.01232. arXiv: 1611.01232.
243
+
244
+ Raquel Urtasun and Trevor Darrell. Sparse probabilistic regression for activity-independent human pose inference. CVPR, 2008.
245
+
246
+ Mark van der Wilk, Carl Edward Rasmussen, and James Hensman. Convolutional Gaussian Processes. In I. Guyon, U. V. Luxburg, S. Bengio, H. Wallach, R. Fergus, S. Vishwanathan, and R. Garnett, editors, Advances in Neural Information Processing Systems 30, pages 2849–2858. Curran Associates, Inc., 2017. URL http://papers.nips.cc/paper/ 6877-convolutional-gaussian-processes.pdf.
247
+
248
+ Christopher KI Williams and Carl Edward Rasmussen. Gaussian processes for machine learning, 2006.
249
+
250
+ Andrew Gordon Wilson, Zhiting Hu, Ruslan Salakhutdinov, and Eric P. Xing. Deep kernel learning. In Artificial Intelligence and Statistics, pages 370–378, 2016.
251
+
252
+ # 5 APPENDIX
253
+
254
+ # Covariance Function at the Output of ReLU Neural Network
255
+
256
+ Our derivation follows the work on arc-cosine family of kernels developed in (Cho and Saul, 2009). However, instead of applying coplanar vector rotation in calculating the kernel integral, we recognize that the integrand can be written in terms of two jointly normal random variables. This helps to facilitate the computation which becomes more involved when both the weight and bias parameters are included.
257
+
258
+ The derivation is also made to conform to the arc-cosine kernel by utilizing the identities (Cho and Saul, 2009, equation (17), (18)) to give us
259
+
260
+ $$
261
+ \begin{array} { l } { { \displaystyle { \int _ { \eta = 0 } ^ { \frac { \pi } { 2 } } \frac { 1 } { 1 - \cos \phi \cos \eta } d \eta = \frac { \pi - \phi } { \sin \phi } } , } } \\ { { \displaystyle { \int _ { \theta = 0 } ^ { \frac { \pi } { 2 } } \frac { \sin 2 \theta } { \left( 1 - \cos \phi \sin 2 \theta \right) ^ { 2 } } d \theta } } } \\ { { = \displaystyle { \frac { 1 } { \sin ^ { 3 } \phi } \Big ( \sin ( \phi ) + ( \pi - \phi ) \cos ( \phi ) \Big ) } . } } \end{array}
262
+ $$
263
+
264
+ Equation (4) is derived, with the substitution $\eta = 2 ( \theta - \frac { \pi } { 4 } )$ ) , as follow:
265
+
266
+ $$
267
+ \begin{array} { r l } & { \displaystyle \int _ { \theta = 0 } ^ { \frac { \pi } { 2 } } \frac { \sin 2 \theta } { \left( 1 - \cos \phi \sin 2 \theta \right) ^ { 2 } } d \theta } \\ & { = \displaystyle \int _ { \eta = 0 } ^ { \frac { \pi } { 2 } } \frac { \cos \eta } { \left( 1 - \cos \phi \cos \eta \right) ^ { 2 } } d \eta } \\ & { = \displaystyle \frac { \partial } { \partial \cos \phi } \int _ { \eta = 0 } ^ { \frac { \pi } { 2 } } \frac { 1 } { 1 - \cos \phi \cos \eta } d \eta } \\ & { = \displaystyle \frac { \partial } { \partial \cos \phi } \left( \frac { \pi - \phi } { \sin \phi } \right) = \frac { - 1 } { \sin ( \phi ) } \frac { \partial } { \partial \phi } \left( \frac { \pi - \phi } { \sin \phi } \right) } \\ & { = \displaystyle \frac { 1 } { \sin ^ { 3 } \phi } \left( \sin ( \phi ) + ( \pi - \phi ) \cos ( \phi ) \right) . } \end{array}
268
+ $$
269
+
270
+ Denote the input layer (layer 0) weight and bias parameters as $b _ { j } ^ { 0 } \sim \mathcal { N } ( 0 , \sigma _ { b } ^ { 2 } )$ and $\begin{array} { r } { W _ { j k } ^ { 0 } \overset { \mathrm { i i d } } { \sim } \mathcal { N } ( 0 , \frac { \sigma _ { w } ^ { 2 } } { d _ { i n } } ) } \end{array}$ where $b _ { j } ^ { 0 } \underline { { 1 } } \perp W _ { j k } ^ { 0 }$ for all $k \in \{ 1 , \cdots , d _ { i n } \} , j \in \{ 1 , \cdots , N _ { 1 } \}$ .
271
+
272
+ The expected value of the product of post-activations at the output of the $j ^ { t h }$ hidden node is computed as
273
+
274
+ $$
275
+ \begin{array} { r l } & { E [ \mathbf { X } _ { j } ( { x } ^ { 0 } ) \mathbf { X } _ { j } ( { y } ^ { 0 } ) ] } \\ & { \ = \displaystyle \int \cdots \int _ { - \infty } ^ { \infty } \operatorname* { m a x } ( b _ { j } ^ { 0 } + w _ { j } ^ { 0 } \cdot { x } ^ { 0 } ) \operatorname* { m a x } ( b _ { j } ^ { 0 } + w _ { j } ^ { 0 } \cdot { y } ^ { 0 } ) f _ { b _ { j } ^ { 0 } , W _ { j } ^ { 0 } } ( b , w ) d w _ { j } ^ { 0 } d b _ { j } ^ { 0 } } \\ & { \ = \displaystyle \int \cdots \int _ { - \infty } ^ { \infty } ( b _ { j } ^ { 0 } + w _ { j } ^ { 0 } \cdot { x } ^ { 0 } ) _ { + } ( b _ { j } ^ { 0 } + w _ { j } ^ { 0 } \cdot { y } ^ { 0 } ) _ { + } f _ { b _ { j } ^ { 0 } , W _ { j } ^ { 0 } } ( b , w ) d w _ { j } ^ { 0 } d b } \end{array}
276
+ $$
277
+
278
+ Each pre-activation can be written in terms of a random variable:
279
+
280
+ $$
281
+ \begin{array} { l } { { U = b _ { j } ^ { 0 } + W _ { j } ^ { 0 } \cdot x ^ { 0 } = b _ { j } ^ { 0 } + \displaystyle \sum _ { k = 1 } ^ { d _ { i n } } W _ { j k } ^ { 0 } x _ { k } ^ { 0 } \sim \mathcal N ( 0 , \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \| x \| ^ { 2 } ) , } } \\ { { \displaystyle V = b _ { j } ^ { 0 } + W _ { j } ^ { 0 } \cdot y ^ { 0 } = b _ { j } ^ { 0 } + \displaystyle \sum _ { k ^ { \prime } = 1 } ^ { d _ { i n } } W _ { j k ^ { \prime } } ^ { 0 } y _ { k ^ { \prime } } ^ { 0 } \sim \mathcal N ( 0 , \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \| y \| ^ { 2 } ) . } } \end{array}
282
+ $$
283
+
284
+ Since $E [ U ] = E [ V ] = 0$ , their covariance can be expressed as
285
+
286
+ $$
287
+ \begin{array} { l } { { \displaystyle \mathrm { c o v } ( U , V ) = E \big [ ( b _ { j } ^ { 0 } + W _ { j } ^ { 0 } \cdot x ^ { 0 } ) ( b _ { j } ^ { 0 } + W _ { j } ^ { 0 } \cdot y ^ { 0 } ) \big ] } } \\ { { \displaystyle = E \big [ ( b _ { j } ^ { 0 } ) ^ { 2 } \big ] + E \bigg [ \displaystyle \sum _ { k = 1 } ^ { d _ { i n } } \sum _ { k ^ { \prime } = 1 } ^ { d _ { i n } } W _ { j k } ^ { 0 } W _ { j k ^ { \prime } } ^ { 0 } x _ { k } ^ { 0 } y _ { k ^ { \prime } } ^ { 0 } \bigg ] } } \\ { { \displaystyle = \sigma _ { b } ^ { 2 } + \displaystyle \sum _ { k = 1 } ^ { d _ { i n } } \sum _ { k ^ { \prime } = 1 } ^ { d _ { i n } } E \Big [ W _ { j k } ^ { 0 } W _ { j k ^ { \prime } } ^ { 0 } \Big ] x _ { k } ^ { 0 } y _ { k ^ { \prime } } ^ { 0 } } } \\ { { \displaystyle = \sigma _ { b } ^ { 2 } + \sigma _ { b } ^ { 2 } \sum _ { k = 1 } ^ { d _ { i n } } x _ { k } ^ { 0 } y _ { k } ^ { 0 } } } \\ { { \displaystyle = \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } ( x \cdot y ) ~ } } \\ { { \displaystyle = \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } ( x \cdot y ) ~ \mathrm { ( F o r ~ s i m p l i c i t y ~ w e ~ s e t ~ } x ^ { 0 } , y = y ^ { 0 } ) } } \end{array}
288
+ $$
289
+
290
+ This implies that the random variables $U , V$ have a joint Gaussian distribution:
291
+
292
+ $$
293
+ \begin{array}{c} \binom { U } { V } \sim { \mathcal N } ( 0 , \Sigma ) , \mathrm { w h e r e } \Sigma = \left( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \lVert x \rVert ^ { 2 } \right. \left. \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } ( x \cdot y ) \right) \\ { \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } ( x \cdot y ) \ \left. \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \lVert y \rVert ^ { 2 } . \right) } \end{array}
294
+ $$
295
+
296
+ We can, therefore, rewrite equation (5) as
297
+
298
+ $$
299
+ \iint _ { 0 } ^ { \infty } u v \frac { 1 } { 2 \pi | \Sigma | ^ { \frac { 1 } { 2 } } } \exp \big ( - \frac { 1 } { 2 } ( u , v ) \Sigma ^ { - 1 } ( u , v ) ^ { T } \big ) d u d v
300
+ $$
301
+
302
+ Denote $D : = | \Sigma | = \left( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \| x \| ^ { 2 } \right) \left( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \| y \| ^ { 2 } \right) - \left( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } ( x \cdot y ) \right) ^ { 2 }$ , and
303
+
304
+ $$
305
+ \Sigma ^ { - 1 } = { \binom { a _ { 1 1 } } { a _ { 2 1 } } } a _ { 2 2 } ) ,
306
+ $$
307
+
308
+ with $\begin{array} { l } { \displaystyle { a _ { 1 1 } = \frac { 1 } { D } \big ( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \| y \| ^ { 2 } \big ) , a _ { 2 2 } = \frac { 1 } { D } \big ( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \| x \| ^ { 2 } \big ) , } } \\ { \displaystyle { = a _ { 2 1 } = \frac { - 1 } { D } \big ( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } ( x \cdot y ) \big ) . } } \end{array}$ and
309
+
310
+ We therefore have:
311
+
312
+ $$
313
+ \begin{array} { l } { { \displaystyle { D \big ( a _ { 1 1 } a _ { 2 2 } - a _ { 1 2 } ^ { 2 } \big ) = D \Big ( \frac { 1 } { D } \big ( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \| y \| ^ { 2 } \big ) \frac { 1 } { D } \big ( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \| x \| ^ { 2 } \big ) - \big ( \frac { - 1 } { D } \big ( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \big ( x \cdot y \big ) \big ) ^ { 2 } \Big ) } } } \\ { { \displaystyle \qquad = \frac { 1 } { D } \Big ( \big ( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \| x \| ^ { 2 } \big ) \big ( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \| y \| ^ { 2 } \big ) - \big ( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \big ( x \cdot y \big ) \big ) ^ { 2 } \Big ) } } \\ { { \displaystyle \qquad = 1 . \quad \quad \mathrm { ( b y ~ d e f i n i t i o n ) } } } \end{array}
314
+ $$
315
+
316
+ The exponential term in equation (6) then becomes:
317
+
318
+ $$
319
+ - \frac { 1 } { 2 } ( u , v ) \Sigma ^ { - 1 } ( u , v ) ^ { T } = - \frac { 1 } { 2 } \big ( a _ { 1 1 } u ^ { 2 } + 2 a _ { 1 2 } u v + a _ { 2 2 } v ^ { 2 } \big ) .
320
+ $$
321
+
322
+ We now make use of the transformation from Cartesian to polar coordinates by setting
323
+
324
+ $$
325
+ { \begin{array} { r l } & { u = { \frac { r } { \sqrt { a _ { 1 1 } } } } \cos \alpha , v = { \frac { r } { \sqrt { a _ { 2 2 } } } } \sin \alpha } \\ & { \qquad \implies a _ { 1 1 } u ^ { 2 } = r ^ { 2 } { \cos ^ { 2 } } \alpha , a _ { 2 2 } v ^ { 2 } = r ^ { 2 } { \sin ^ { 2 } } \alpha . } \end{array} }
326
+ $$
327
+
328
+ The Jacobian $\mathcal { I }$ is calculated as
329
+
330
+ $$
331
+ \big | \frac { \partial ( u , v ) } { \partial ( r , \alpha ) } \big | = \frac { r } { \sqrt { a _ { 1 1 } a _ { 2 2 } } } .
332
+ $$
333
+
334
+ Equation (6) can in turn be expressed as
335
+
336
+ $$
337
+ \begin{array} { r l } & { \frac { 1 } { 2 \pi D ^ { 1 / 2 } } \int _ { \alpha = 0 } ^ { \frac { \pi } { 2 } } \int _ { r = 0 } ^ { \infty } \frac { r ^ { 2 } \sin 2 \alpha } { 2 \sqrt { a _ { 1 1 } a _ { 2 2 } } } \mathrm { e x p } \Big ( \frac { - 1 } { 2 } [ r ^ { 2 } \cos ^ { 2 } \alpha + \frac { 2 a _ { 1 2 } r ^ { 2 } \sin \alpha \cos \alpha } { \sqrt { a _ { 1 1 } a _ { 2 2 } } } + r ^ { 2 } \sin ^ { 2 } \alpha ] \Big ) \frac { r d r d \alpha } { \sqrt { a _ { 1 1 } a _ { 2 2 } } } } \\ & { = \frac { 1 } { 4 \pi D ^ { 1 / 2 } a _ { 1 1 } a _ { 2 2 } } \int _ { \alpha = 0 } ^ { \frac { \pi } { 2 } } \sin 2 \alpha d \alpha \int _ { r = 0 } ^ { \infty } r ^ { 3 } \mathrm { e x p } \Big ( \frac { - r ^ { 2 } } { 2 } [ 1 + \frac { a _ { 1 2 } \sin 2 \alpha } { \sqrt { a _ { 1 1 } a _ { 2 2 } } } ] \Big ) d r \qquad \quad ( \cot 2 ) } \end{array}
338
+ $$
339
+
340
+ Next, we need to show that $\mathcal { H } : = 1 + \frac { a _ { \mathrm { 1 2 } } \sin 2 \alpha } { \sqrt { a _ { \mathrm { 1 1 } } a _ { \mathrm { 2 2 } } } } \ge 0$ to ensure the expression in (8) is bounded.
341
+
342
+ First, since $\| x - y \| ^ { 2 } = \| x \| ^ { 2 } + \| y \| ^ { 2 } - 2 ( x \cdot y ) \geq 0 \implies \| x \| ^ { 2 } + \| y \| ^ { 2 } \geq 2 ( x \cdot y )$ , and let the angle between the vectors $x , y$ be $\theta = \cos ^ { - 1 } \Bigl ( \frac { x \cdot y } { \| x \| \| y \| } \Bigr )$ , we have
343
+
344
+ $$
345
+ \begin{array} { r l } & { \frac { \Big ( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } ( x \cdot y ) \Big ) ^ { 2 } } { \Big ( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \| x \| ^ { 2 } \Big ) \Big ( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \| y \| ^ { 2 } \Big ) } } \\ & { = \frac { \sigma _ { b } ^ { 4 } + ( \sigma _ { w } ^ { 2 } ) ^ { 2 } ( x \cdot y ) ^ { 2 } + 2 \sigma _ { b } ^ { 2 } ( \sigma _ { w } ^ { 2 } ) ( x \cdot y ) } { \sigma _ { b } ^ { 4 } + ( \sigma _ { w } ^ { 2 } ) ^ { 2 } \left( \| x \| ^ { 2 } \| y \| ^ { 2 } \right) + \sigma _ { b } ^ { 2 } ( \sigma _ { w } ^ { 2 } ) \left( \| x \| ^ { 2 } + \| y \| ^ { 2 } \right) } } \\ & { = \frac { \sigma _ { b } ^ { 4 } + ( \sigma _ { w } ^ { 2 } ) ^ { 2 } ( \| x \| \| y \| \cos \theta ) ^ { 2 } + \sigma _ { b } ^ { 2 } ( \sigma _ { w } ^ { 2 } ) 2 ( x \cdot y ) } { \sigma _ { b } ^ { 4 } + ( \sigma _ { w } ^ { 2 } ) ^ { 2 } \left( \| x \| ^ { 2 } \| y \| ^ { 2 } \right) + \sigma _ { b } ^ { 2 } ( \sigma _ { w } ^ { 2 } ) \left( \| x \| ^ { 2 } + \| y \| ^ { 2 } \right) } } \\ & { < 1 . } \end{array}
346
+ $$
347
+
348
+ This means that we can define a quantity $\phi$ as
349
+
350
+ $$
351
+ \begin{array} { l } { \displaystyle \phi = \cos ^ { - 1 } \frac { \left( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } ( x \cdot y ) \right) } { \left( \left( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \| x \| ^ { 2 } \right) \left( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \| y \| ^ { 2 } \right) \right) ^ { 1 / 2 } } } \\ { \displaystyle = \cos ^ { - 1 } \frac { \frac { 1 } { D } \left( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } ( x \cdot y ) \right) } { \frac { 1 } { D } \left( \left( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \| x \| ^ { 2 } \right) \left( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \| y \| ^ { 2 } \right) \right) } } \\ { = \cos ^ { - 1 } \Big ( \frac { - a _ { 1 2 } } { \sqrt { u _ { 1 } u _ { 2 2 } } } \Big ) } \\ { \displaystyle \implies \cos \phi = \left( \frac { - a _ { 1 2 } } { \sqrt { u _ { 1 } u _ { 2 2 } } } \right) } \end{array}
352
+ $$
353
+
354
+ This also leads to
355
+
356
+ $$
357
+ \begin{array} { l } { \mathcal { H } : = 1 + \frac { a _ { 1 2 } \sin 2 \alpha } { \sqrt { a _ { 1 } \sin 2 \alpha } } } \\ { \displaystyle = 1 + \frac { \frac { - 1 } { D } \left( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } ( x \cdot y ) \right) \sin 2 \alpha } { \frac { 1 } { D } \left( ( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } | x | ^ { 2 } ) \left( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } | y | | y | ^ { 2 } \right) \right) } } \\ { \displaystyle = 1 - \frac { ( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } ( x \cdot y ) ) \sin 2 \alpha } { \left( ( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } | x | ^ { 2 } ) ( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } | y | | y | ^ { 2 } ) \right) ^ { 1 / 2 } } } \\ { \geq 1 - \frac { \left( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } ( x \cdot y ) \right) } { \left( ( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } | x | ^ { 2 } ) ( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } | y | | y | ^ { 2 } ) \right) ^ { 1 / 2 } } } \\ { \displaystyle \geq 0 \ \frac { 1 } { 8 } \left( ( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } | x | ^ { 2 } ) ( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } | y | | y | ^ { 2 } ) \right) ^ { 1 / 2 } } \end{array}
358
+ $$
359
+
360
+ With a change of variables, we now evaluate the integral involving the parameter $r$ in expression (8) as follows.
361
+
362
+ Let $\eta = \frac { r ^ { 2 } } { 2 } \mathcal { H }$ . Then $r = \sqrt { \frac { 2 \eta } { \mathcal { H } } } \implies d r = \frac { 1 } { 2 } \sqrt { \frac { 2 } { \mathcal { H } } } \eta ^ { - 1 / 2 } d \eta .$ −1/2 d η. We have
363
+
364
+ $$
365
+ \begin{array} { r l } & { \int _ { n = 0 } ^ { \infty } \left( \frac { 2 } { \mathcal { H } } \right) ^ { \frac { 2 } { 3 } } \eta ^ { \frac { 2 } { 2 } } \hat { \mathbf { z } } ^ { - \nu } \frac { 1 } { 2 } \sqrt { \frac { 2 } { \mathcal { H } } \eta ^ { \frac { 2 } { 2 } } } \vec { \mathbf { z } } ^ { \frac { 1 } { 2 } } \ d \eta } \\ & { = \int _ { n = 0 } ^ { \infty } \frac { 2 2 } { \mathcal { H } ^ { 2 } } \frac { 1 } { 2 } \mathbf { z } ^ { \nu - \nu } \ d \eta } \\ & { = \frac { 2 } { \mathcal { H } ^ { 2 } } \int _ { n = 0 } ^ { \infty } \eta \ c ^ { - \nu } d \eta } \\ & { = \frac { 2 } { \mathcal { H } ^ { 2 } } \mathbf { z } ^ { \nu } [ ( 2 ) = \frac { 2 } { \mathcal { H } ^ { 2 } } } \\ & { = \frac { 2 } { \left( 1 + \frac { \operatorname { d r } _ { 1 } \sqrt { \operatorname { d r } _ { 1 } \log 2 } } { \sqrt { \operatorname { d r } _ { 1 } \log 2 } } \right) ^ { 2 } } } \\ & { = \frac { 2 } { \left( 1 - \frac { 2 } { \sqrt { \operatorname { d r } _ { 1 } \operatorname { d r } _ { 2 } \mathcal { H } } } \right) ^ { 2 } } . \quad \mathrm { ( f r o m ~ e q u a t i o n ~ \mathcal { O } ) } \big ) } \end{array}
366
+ $$
367
+
368
+ The complete expression (8) becomes
369
+
370
+ $$
371
+ \begin{array} { r l } & { \frac { 1 } { 4 \pi D ^ { 1 / 2 } a _ { 1 1 } a _ { 2 2 } } \displaystyle \int _ { \alpha = 0 } ^ { \frac { \pi } { 2 } } \frac { 2 \sin 2 \alpha } { \left( 1 - \cos \phi \sin 2 \alpha \right) ^ { 2 } } d \alpha } \\ & { = \frac { 1 } { 2 \pi D ^ { 1 / 2 } a _ { 1 1 } a _ { 2 2 } \sin ^ { 3 } \phi } \Big ( \sin ( \phi ) + ( \pi - \phi ) \cos ( \phi ) \Big ) . \quad \mathrm { ( f r o m ~ e q u a t i o n ~ ( 4 ) ) } } \end{array}
372
+ $$
373
+
374
+ where $\phi = \cos ^ { - 1 } \Big ( \frac { - a _ { 1 2 } } { \sqrt { a _ { 1 1 } a _ { 2 2 } } } \Big )$
375
+
376
+ Finally,
377
+
378
+ $$
379
+ \begin{array} { r l } & { 2 \pi \mathcal { D } ^ { 1 / 2 } a _ { 1 1 } a _ { 2 2 } \sin ^ { 3 } \phi } \\ & { = 2 \pi \mathcal { D } ^ { 1 / 2 } a _ { 1 1 } a _ { 2 2 } \left( 1 - \cos ^ { 2 } \phi \right) ^ { 3 / 2 } } \\ & { = 2 \pi \mathcal { D } ^ { 1 / 2 } a _ { 1 1 } a _ { 2 2 } \left( 1 - \frac { a _ { 1 2 } ^ { 2 } } { a _ { 1 1 } a _ { 2 2 } } \right) ^ { 3 / 2 } } \\ & { = 2 \pi \mathcal { D } ^ { 1 / 2 } \Big ( a _ { 1 1 } a _ { 2 2 } \Big ) ^ { - 1 / 2 } \Big ( a _ { 1 1 } a _ { 2 2 } - a _ { 1 2 } ^ { 2 } \Big ) ^ { 3 / 2 } } \\ & { = 2 \pi \Big ( \mathcal { D } ^ { 2 } a _ { 1 1 } a _ { 2 2 } \Big ) ^ { - 1 / 2 } \Big ( \mathcal { D } \big ( a _ { 1 1 } a _ { 2 2 } - a _ { 1 2 } ^ { 2 } \big ) \Big ) ^ { 3 / 2 } } \\ & { = 2 \pi \Big ( \big ( o _ { b } ^ { 2 } + o _ { w } ^ { 2 } \| x \| ^ { 2 } \big ) \big ( o _ { b } ^ { 2 } + o _ { w } ^ { 2 } \| y \| ^ { 2 } \big ) \Big ) ^ { - 1 / 2 } \Big ( 1 \Big ) ^ { 3 / 2 } \quad \mathrm { ( f r o m e q u a t i o n ~ ( 7 ) ) } } \end{array}
380
+ $$
381
+
382
+ The expected value of the product of post-activations at the output of the $j ^ { t h }$ hidden node in the first hidden layer is therefore determined to be
383
+
384
+ $$
385
+ \begin{array} { r l } & { E [ { \bf X } _ { j } ( x ) { \bf X } _ { j } ( y ) ] } \\ & { = \displaystyle \frac { 1 } { 2 \pi } \Big ( \big ( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \| x \| ^ { 2 } \big ) \big ( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \| y \| ^ { 2 } \big ) \Big ) ^ { 1 / 2 } \Big ( \sin ( \phi ) + \big ( \pi - \phi \big ) \cos ( \phi ) \Big ) , } \\ & { \mathrm { w h e r e \ } \phi = \cos ^ { - 1 } \Bigg \{ \frac { \big ( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } ( x \cdot y ) \big ) } { \Big ( \big ( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \| x \| ^ { 2 } \big ) \big ( \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \| y \| ^ { 2 } \big ) \Big ) ^ { 1 / 2 } } \Bigg \} . } \end{array}
386
+ $$
387
+
388
+ To compute the expected value, $\begin{array} { r } { E [ \mathbf { X } _ { j } ( x ) ] \ = \ \int \operatorname* { m a x } ( b + w \cdot x ) f _ { b _ { j } ^ { 0 } , W _ { j k } ^ { 0 } } ( b , w ) d w d b } \end{array}$ , we denote $U = b + w \cdot x \sim N ( 0 , \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \| x \| ^ { 2 } )$ , and apply the change in variables: ${ \frac { 1 } { 2 \sigma ^ { 2 } } } u ^ { 2 } = t$ , where $\sigma ^ { 2 } = $ $\sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \lVert x \rVert ^ { 2 }$ to obtain
389
+
390
+ $$
391
+ \begin{array} { l } { \displaystyle E [ \mathbf { X } _ { j } ( x ) ] = \int _ { - \infty } ^ { \infty } \left( u \right) + f _ { U } ( u ) d u } \\ { \displaystyle = \int _ { 0 } ^ { \infty } u \frac { 1 } { \sqrt { 2 \pi } \sigma } e ^ { - \frac { 1 } { 2 \sigma ^ { 2 } } u ^ { 2 } } d u } \\ { \displaystyle = \int _ { 0 } ^ { \infty } \sigma ^ { 2 } d t \frac { 1 } { \sqrt { 2 \pi } \sigma } e ^ { - t } } \\ { \displaystyle = \frac { \sigma } { \sqrt { 2 \pi } } } \\ { \displaystyle = \frac { \sqrt { \sigma _ { b } ^ { 2 } } + \sigma _ { w } ^ { 2 } \| x \| ^ { 2 } } { \sqrt { 2 \pi } } } \end{array}
392
+ $$
393
+
394
+ The covariance function at the network output is therefore determined to be
395
+
396
+ $$
397
+ \begin{array} { l } { { \displaystyle E \Big [ \big ( b _ { i } ^ { 1 } + \sum _ { j = 1 } ^ { N _ { 1 } } W _ { i j } ^ { 1 } \mathbf { X } _ { j } ( x ) \big ) \big ( b _ { i } ^ { 1 } + \sum _ { k = 1 } ^ { N _ { 1 } } W _ { i k } ^ { 1 } \mathbf { X } _ { k } ( y ) \big ) \Big ] - E \Big [ b _ { i } ^ { 1 } + \sum _ { j = 1 } ^ { N _ { 1 } } W _ { i j } ^ { 1 } \mathbf { X } _ { j } ( x ) \Big ] \Big [ b _ { i } ^ { 1 } + \sum _ { k = 1 } ^ { N _ { 1 } } W _ { i k } ^ { 1 } \mathbf { X } _ { k } ( y ) \Big ] } } \\ { { \displaystyle = E [ ( b _ { i } ^ { 1 } ) ^ { 2 } ] + \sum _ { j = 1 } ^ { N _ { 1 } } E [ ( W _ { i j } ^ { 1 } ) ^ { 2 } ] E [ \mathbf { X } _ { j } ( x ) \mathbf { X } _ { j } ( y ) ] - \frac { 1 } { 2 \pi } \sqrt { \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \| x \| ^ { 2 } } \sqrt { \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \| y \| ^ { 2 } } } } \\ { { \displaystyle = \sigma _ { b } ^ { 2 } + \frac { \sigma _ { w } ^ { 2 } } { N _ { 1 } } N _ { 1 } E [ \mathbf { X } _ { j } ( x ) \mathbf { X } _ { j } ( y ) ] - \frac { 1 } { 2 \pi } \sqrt { \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \| x \| ^ { 2 } } \sqrt { \sigma _ { b } ^ { 2 } + \sigma _ { w } ^ { 2 } \| y \| ^ { 2 } } } } \\ { { \displaystyle = \sigma _ { b } ^ { 2 } + \frac { \sigma _ { w } ^ { 2 } } { 2 \pi } \Big ( \sigma _ { b } ^ { 2 } + \| x \| ^ { 2 } \sigma _ { w } ^ { 2 } \Big ) ^ { \frac { 1 } { 2 } } \Big ( \sigma _ { b } ^ { 2 } + \| y \| ^ { 2 } \sigma _ { w } ^ { 2 } \Big ) ^ { \frac { 1 } { 2 } } \Big ( \sin \phi + ( \pi - \phi ) \cos \phi - 1 \Big ) . } } \end{array}
398
+ $$
parse/train/pbXQtKXwLS/pbXQtKXwLS_content_list.json ADDED
@@ -0,0 +1,1871 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [
2
+ {
3
+ "type": "text",
4
+ "text": "GUIDING NEURAL NETWORK INITIALIZATION VIA MARGINAL LIKELIHOOD MAXIMIZATION ",
5
+ "text_level": 1,
6
+ "bbox": [
7
+ 176,
8
+ 98,
9
+ 821,
10
+ 146
11
+ ],
12
+ "page_idx": 0
13
+ },
14
+ {
15
+ "type": "text",
16
+ "text": "Anonymous authors Paper under double-blind review ",
17
+ "bbox": [
18
+ 183,
19
+ 171,
20
+ 398,
21
+ 198
22
+ ],
23
+ "page_idx": 0
24
+ },
25
+ {
26
+ "type": "text",
27
+ "text": "ABSTRACT ",
28
+ "text_level": 1,
29
+ "bbox": [
30
+ 454,
31
+ 236,
32
+ 544,
33
+ 251
34
+ ],
35
+ "page_idx": 0
36
+ },
37
+ {
38
+ "type": "text",
39
+ "text": "We propose a simple approach to help guide hyperparameter selection for neural network initialization. We leverage the relationship between neural network and Gaussian process models having corresponding activation and covariance functions to infer the hyperparameter values desirable for model initialization. Our experiment shows that marginal likelihood maximization provides recommendations that yield near-optimal prediction performance on MNIST classification task under experiment constraints. Furthermore, our empirical results indicate consistency in the proposed technique, suggesting that computation cost for the procedure could be significantly reduced with smaller training sets. ",
40
+ "bbox": [
41
+ 233,
42
+ 268,
43
+ 764,
44
+ 393
45
+ ],
46
+ "page_idx": 0
47
+ },
48
+ {
49
+ "type": "text",
50
+ "text": "1 INTRODUCTION ",
51
+ "text_level": 1,
52
+ "bbox": [
53
+ 176,
54
+ 424,
55
+ 336,
56
+ 440
57
+ ],
58
+ "page_idx": 0
59
+ },
60
+ {
61
+ "type": "text",
62
+ "text": "Training deep neural networks successfully can be challenging. However, with proper initialization trained models could improve their prediction performance. Various initialization strategies in neural network have been discussed extensively in numerous research works. Glorot and Bengio (2010) focused on linear cases and proposed the normalized initialization scheme (also known as Xavier-initialization). Their derivation was obtained by considering activation variances in the forward path and the gradient variance in back-propagation. He-initialization (He et al., 2015) was developed for very deep networks with rectifier nonlinearities. Their approach imposed a condition on the weight variances to control the variation in the input magnitudes. Because of its success, He-initialization has become the de facto choice for deep ReLU networks. While Glorot- and Heinitialization schemes recognize the importance of and make use of the hidden layer widths in their formulation, other methods were also suggested to improve training in deep neural networks. ",
63
+ "bbox": [
64
+ 174,
65
+ 458,
66
+ 825,
67
+ 611
68
+ ],
69
+ "page_idx": 0
70
+ },
71
+ {
72
+ "type": "text",
73
+ "text": "Mishkin and Matas (2016) demonstrated that pre-initialization with orthonormal matrices followed by output variance normalization produces prediction performance comparable to, if not better than, standard techniques. Additionally, Schoenholz et al. (2017) developed the bound on the network depth based on the principle of ’Edge of Chaos’ given a particular set of initialization hyperparameters. Furthermore, Hayou et al. (2019) showed that theoretically and in practice proper initialization parameter tuning with appropriate activation function is important to model training for improved performance. ",
74
+ "bbox": [
75
+ 174,
76
+ 617,
77
+ 825,
78
+ 714
79
+ ],
80
+ "page_idx": 0
81
+ },
82
+ {
83
+ "type": "text",
84
+ "text": "Neal (1996) showed that as a fully-connected, single-hidden-layer feedforward untrained neural network becomes infinitely wide, Gaussian prior distributions over the network hidden-to-output weights and biases converge to a Gaussian process, under the assumption that the parameters are independent. In other words, the untrained infinite neural network and its induced Gaussian process counterpart are equivalent. Also, as a result of the central limit theorem, the covariance between network output evaluated at different inputs can be represented as a function of the hidden node activation function. Intuitively, we could therefore relate the prediction performance of an untrained, finite-width, single-hidden-layer, fully-connected feedforward neural network to a Gaussian process model with a covariance function corresponding to the network’s activation function. ",
85
+ "bbox": [
86
+ 174,
87
+ 722,
88
+ 825,
89
+ 847
90
+ ],
91
+ "page_idx": 0
92
+ },
93
+ {
94
+ "type": "text",
95
+ "text": "In this work we propose a simple and efficient method that learns from training data to guide the selection of initialization hyperparameters in neural networks. Marginal likelihood is a popular tool for choosing kernel hyperparameters in model selection. Its applications in convolutional Gaussian processes and deep kernel learning are discussed, respectively, in (van der Wilk et al., 2017; Wilson et al., 2016). Our method aims to synergize this powerful functionality of marginal likelihood and the relationship between untrained neural networks and Gaussian process models to make recommendations for neural network initialization. We first derive the covariance function corresponding to the activation function of the network whose prediction performance we wish to evaluate. We then employ marginal likelihood optimization for the Gaussian process model to learn hyperparameters from data. We hypothesize that the optimal set of hyperparameter values could improve initialization of the neural network. ",
96
+ "bbox": [
97
+ 174,
98
+ 854,
99
+ 823,
100
+ 924
101
+ ],
102
+ "page_idx": 0
103
+ },
104
+ {
105
+ "type": "text",
106
+ "text": "",
107
+ "bbox": [
108
+ 174,
109
+ 103,
110
+ 825,
111
+ 186
112
+ ],
113
+ "page_idx": 1
114
+ },
115
+ {
116
+ "type": "text",
117
+ "text": "2 APPROACH",
118
+ "text_level": 1,
119
+ "bbox": [
120
+ 174,
121
+ 213,
122
+ 299,
123
+ 229
124
+ ],
125
+ "page_idx": 1
126
+ },
127
+ {
128
+ "type": "text",
129
+ "text": "To assess our proposed method, we build a neural network and a Gaussian process model with corresponding activation and covariance functions. With the Gaussian process we estimate the covariance hyperparameters from training data. These hyperparameter values are then applied in the neural network to evaluate and compare its prediction accuracy among various hyperparameter sets. ",
130
+ "bbox": [
131
+ 174,
132
+ 247,
133
+ 825,
134
+ 304
135
+ ],
136
+ "page_idx": 1
137
+ },
138
+ {
139
+ "type": "text",
140
+ "text": "We first describe the structure of the neural network, followed by the Gaussian process model and the underlying reason for employing the marginal likelihood. Then, given the network activation function we proceed to derive a closed form representation of its counterpart covariance function. ",
141
+ "bbox": [
142
+ 174,
143
+ 310,
144
+ 825,
145
+ 353
146
+ ],
147
+ "page_idx": 1
148
+ },
149
+ {
150
+ "type": "text",
151
+ "text": "2.1 SINGLE-HIDDEN-LAYER NEURAL NETWORKS",
152
+ "text_level": 1,
153
+ "bbox": [
154
+ 174,
155
+ 376,
156
+ 531,
157
+ 390
158
+ ],
159
+ "page_idx": 1
160
+ },
161
+ {
162
+ "type": "text",
163
+ "text": "Our neural network model is a fully-connected, single-hidden-layer feedforward network with 2000 hidden nodes and rectified linear unit (ReLU) activation function. Following (Lee et al., 2018), we conduct our empirical study by considering classifying MNIST images as regression prediction. Inasmuch as the network is designed for regression, we choose the mean square error (MSE) loss as its objective function, along with Adam optimizer, and accuracy as the performance metric. In addition, one-hot encoding is utilized to generate class labels, where an incorrectly labeled class is designated -0.1, and a correctly labeled class 0.9 . For example, the one-hot representation of the integer 7 is given by [-0.1, -0.1, -0.1, -0.1, -0.1, -0.1, -0.1, 0.9, -0.1, -0.1]. ",
164
+ "bbox": [
165
+ 173,
166
+ 404,
167
+ 825,
168
+ 516
169
+ ],
170
+ "page_idx": 1
171
+ },
172
+ {
173
+ "type": "image",
174
+ "img_path": "images/54731f17b5c85d9323726dd1860cf907a524807ca14936340cb33c5c88ef53d2.jpg",
175
+ "image_caption": [
176
+ "Figure 1: A single-hidden-layer, fully-connected feedforward neural network for regression prediction. Left panel: Structural diagram of the neural network. Right panel: ReLU activation function: $\\phi ( a ) : = ( \\bar { a } ) _ { + } = \\operatorname* { m a x } ( 0 , a ) = \\bar { a }$ for $a \\geq 0 ; \\phi ( a ) = 0$ otherwise. "
177
+ ],
178
+ "image_footnote": [],
179
+ "bbox": [
180
+ 181,
181
+ 535,
182
+ 748,
183
+ 718
184
+ ],
185
+ "page_idx": 1
186
+ },
187
+ {
188
+ "type": "text",
189
+ "text": "As shown in the left panel of Figure (1), the single-hidden-layer neural network has a set of inputs denoted by $x = \\{ x _ { k } ^ { 0 } \\} , k \\in \\{ 1 , 2 , \\cdots , d _ { i n } \\}$ with input layer width $d _ { i n } = N _ { 0 } = 2 8 { \\mathrm { x } } 2 8 = 7 8 4 .$ . The model’s weight and bias parameters from $k ^ { t h }$ input node to $j ^ { t h }$ hidden node are $W _ { j k } ^ { 0 }$ iid∼ $\\begin{array} { r } { \\mathcal N ( 0 , \\frac { \\sigma _ { w } ^ { 2 } } { N _ { 0 } } ) , b _ { j } ^ { 0 } \\overset { \\mathrm { i i d } } { \\sim } \\mathcal N ( 0 , \\sigma _ { b } ^ { 2 } ) } \\end{array}$ , and $W _ { j k } ^ { 0 } \\perp \\perp b _ { j } ^ { 0 }$ . Similarly, the weight and bias parameters from $j ^ { t h }$ hid0den node to $i ^ { t h }$ output node with hidden layer width $N _ { 1 } = d _ { i n } = 2 0 0 0$ are $\\begin{array} { r } { W _ { i j } ^ { 1 } \\stackrel { \\mathrm { i i d } } { \\sim } \\mathcal N ( 0 , \\frac { \\sigma _ { w } ^ { 2 } } { N _ { 1 } } ) , b _ { i } ^ { 1 } } \\end{array}$ iid∼ $\\mathcal { N } ( 0 , \\sigma _ { b } ^ { 2 } )$ , and $W _ { i j } ^ { 1 } \\perp \\perp b _ { i } ^ { 1 }$ . For regression models the output layer has a single node, and therefore $i \\in \\{ 1 \\}$ . The ReLU nonlinearity is depicted in the right panel of Figure (1). ",
190
+ "bbox": [
191
+ 173,
192
+ 800,
193
+ 825,
194
+ 924
195
+ ],
196
+ "page_idx": 1
197
+ },
198
+ {
199
+ "type": "text",
200
+ "text": "The input to each hidden node nonlinearity (the pre-activation) is represented by $z _ { j } ^ { 0 } ( x ) = b _ { j } ^ { 0 } +$ $\\textstyle \\sum _ { k = 1 } ^ { d _ { i n } } W _ { j k } ^ { 0 } x _ { k } ^ { 0 }$ , while the hidden unit output after the nonlinearity (the post-activation) is denoted by $x _ { j } ^ { 1 } ( x ) = \\phi ( z _ { j } ^ { 0 } ( x ) )$ , $j \\in \\{ 1 , 2 , \\cdots , N _ { 1 } \\}$ . Since we typically apply linear activation function in the output stage of a regression model, the model output is simply $\\begin{array} { r } { z _ { i } ^ { 1 } ( x ) = b _ { i } ^ { 1 } + \\sum _ { j = 1 } ^ { N _ { 1 } } W _ { i j } ^ { 1 } x _ { j } ^ { 1 } ( x ) } \\end{array}$ . ",
201
+ "bbox": [
202
+ 173,
203
+ 102,
204
+ 825,
205
+ 174
206
+ ],
207
+ "page_idx": 2
208
+ },
209
+ {
210
+ "type": "text",
211
+ "text": "2.2 GAUSSIAN PROCESSES ",
212
+ "text_level": 1,
213
+ "bbox": [
214
+ 176,
215
+ 189,
216
+ 372,
217
+ 204
218
+ ],
219
+ "page_idx": 2
220
+ },
221
+ {
222
+ "type": "text",
223
+ "text": "A Gaussian process (MacKay, 1998; Neal, 1998; Williams and Rasmussen, 2006; Bishop, 2006) is a set of random variables any finite collection of which follows a multivariate normal distribution. A Guassian process prediction model exploits this unique property and offers a Bayesian approach to solving machine learning problems. The model is completely specified by its mean function and covariance function. ",
224
+ "bbox": [
225
+ 174,
226
+ 215,
227
+ 825,
228
+ 285
229
+ ],
230
+ "page_idx": 2
231
+ },
232
+ {
233
+ "type": "text",
234
+ "text": "By choosing a particular covariance function, a prior distribution over functions is induced which, together with observed inputs and targets, can be used to generate prediction distribution for making predictions and uncertainty measures on unknown test points. These capabilities allow Gaussian processes to be used effectively in many important machine learning applications such as human pose inference (Urtasun and Darrell, 2008) and object classification (Kapoor et al., 2010). Recent research works also apply Gaussian processes in deep structures for image classification (van der Wilk et al., 2017) and regression tasks (Wilson et al., 2016). ",
235
+ "bbox": [
236
+ 173,
237
+ 292,
238
+ 825,
239
+ 390
240
+ ],
241
+ "page_idx": 2
242
+ },
243
+ {
244
+ "type": "text",
245
+ "text": "To help achieve optimal performance for Guassian process prediction we select a suitable covariance function and tune the model by adjusting hyperparameters characterizing the covariance function. This can be accomplished by applying the marginal likelihood which is a crucial feature that enables Gaussian processes to learn proper hyperparameter values from training data. ",
246
+ "bbox": [
247
+ 174,
248
+ 396,
249
+ 825,
250
+ 454
251
+ ],
252
+ "page_idx": 2
253
+ },
254
+ {
255
+ "type": "text",
256
+ "text": "2.3 HYPERPARAMETERS AND MARGINAL LIKELIHOOD OPTIMIZATION ",
257
+ "text_level": 1,
258
+ "bbox": [
259
+ 176,
260
+ 468,
261
+ 676,
262
+ 483
263
+ ],
264
+ "page_idx": 2
265
+ },
266
+ {
267
+ "type": "text",
268
+ "text": "We briefly describe the procedure for estimating optimal hyperparamter values via maximizing the Gaussian process marginal likelihood function. ",
269
+ "bbox": [
270
+ 176,
271
+ 494,
272
+ 821,
273
+ 523
274
+ ],
275
+ "page_idx": 2
276
+ },
277
+ {
278
+ "type": "text",
279
+ "text": "Consider a set of $N$ multidimensional input data $X ~ = ~ \\{ x _ { i } \\} _ { i = 1 } ^ { N }$ , $x _ { i } \\in \\mathcal { R } ^ { D }$ , and target set $y =$ $\\{ y _ { i } \\} _ { i = 1 } ^ { N }$ , $y _ { i } \\in \\mathcal R$ . For each input $x _ { i }$ we have a corresponding input-output pair $( x _ { i } , y _ { i } )$ , where the observed output target is given by $y _ { i } = f ( x _ { i } ) + \\epsilon _ { i }$ , with data noise $\\epsilon _ { i } \\sim \\mathcal { N } ( 0 , \\sigma _ { n } ^ { 2 } )$ . We model the input-output latent function $f$ as a Gaussian process : ",
280
+ "bbox": [
281
+ 173,
282
+ 529,
283
+ 825,
284
+ 587
285
+ ],
286
+ "page_idx": 2
287
+ },
288
+ {
289
+ "type": "equation",
290
+ "img_path": "images/89fe7f72c77423be1f3058edc5889596a25f0bcba8438ba040341e4bdea59cf9.jpg",
291
+ "text": "$$\nf ( \\boldsymbol { x } _ { i } ) \\sim \\mathcal { G P } \\big ( \\mu ( \\boldsymbol { x } _ { i } ) , k ( \\boldsymbol { x } _ { i } , \\boldsymbol { x } _ { j } ) \\big ) ,\n$$",
292
+ "text_format": "latex",
293
+ "bbox": [
294
+ 393,
295
+ 588,
296
+ 601,
297
+ 608
298
+ ],
299
+ "page_idx": 2
300
+ },
301
+ {
302
+ "type": "text",
303
+ "text": "where we customarily set the mean function $\\mu ( x _ { i } ) : = E [ f ( x _ { i } ) ] = 0$ , and denote $k ( x _ { i } , x _ { j } )$ as the covariance function. ",
304
+ "bbox": [
305
+ 174,
306
+ 616,
307
+ 825,
308
+ 646
309
+ ],
310
+ "page_idx": 2
311
+ },
312
+ {
313
+ "type": "text",
314
+ "text": "The marginal likelihood (or evidence) (Williams and Rasmussen, 2006; Bishop, 2006) measures the probability of observed targets given input data and can be expressed as the integral of the product of likelihood and the prior, marginalized over the latent function $f$ : ",
315
+ "bbox": [
316
+ 173,
317
+ 651,
318
+ 823,
319
+ 695
320
+ ],
321
+ "page_idx": 2
322
+ },
323
+ {
324
+ "type": "equation",
325
+ "img_path": "images/be666b8138046a85dd5e3a81e83efc04b032f99577af5b10503e4c0f7d6324c6.jpg",
326
+ "text": "$$\np ( y | X ) = \\int p ( y , f | X ) d f = \\int p ( y | f , X ) p ( f | X ) d f .\n$$",
327
+ "text_format": "latex",
328
+ "bbox": [
329
+ 321,
330
+ 696,
331
+ 676,
332
+ 729
333
+ ],
334
+ "page_idx": 2
335
+ },
336
+ {
337
+ "type": "text",
338
+ "text": "$\\{ y _ { i } \\} _ { i = 1 } ^ { N } \\stackrel { \\smile } { = } \\{ f ( x _ { i } ) + \\epsilon _ { i } \\} _ { i = 1 } ^ { N }$ can be obtaine, which gives us $y | \\dot { X } \\sim \\mathcal { N } ( 0 , \\mathcal { K } + \\sigma _ { n } ^ { 2 } I )$ the iwhere $\\mathcal { K } \\breve { = } [ k ( x _ { i } , x _ { j } ) ] _ { i , j = 1 } ^ { \\tilde { N } }$ ticinand $I$ $_ \\mathrm { N }$ $\\mathbf { N }$ ",
339
+ "bbox": [
340
+ 174,
341
+ 737,
342
+ 825,
343
+ 780
344
+ ],
345
+ "page_idx": 2
346
+ },
347
+ {
348
+ "type": "equation",
349
+ "img_path": "images/6bbfc443b253723a94e8c0e35f50ee405dcb1ec517b1f9afc67e5be44a07a6d4.jpg",
350
+ "text": "$$\np ( y | X ) = \\frac { 1 } { ( 2 \\pi ) ^ { N / 2 } | K + \\sigma _ { n } ^ { 2 } I | ^ { 1 / 2 } } \\exp \\Big ( - \\frac { 1 } { 2 } y ^ { T } ( K + \\sigma _ { n } ^ { 2 } I ) ^ { - 1 } y \\Big ) .\n$$",
351
+ "text_format": "latex",
352
+ "bbox": [
353
+ 284,
354
+ 781,
355
+ 710,
356
+ 815
357
+ ],
358
+ "page_idx": 2
359
+ },
360
+ {
361
+ "type": "text",
362
+ "text": "To facilitate computation, we evaluate the log marginal likelihood which is given by ",
363
+ "bbox": [
364
+ 173,
365
+ 823,
366
+ 725,
367
+ 838
368
+ ],
369
+ "page_idx": 2
370
+ },
371
+ {
372
+ "type": "equation",
373
+ "img_path": "images/da816ff24c2accaac872e8cd9de96a58b35bb327b34442ef64e5decb7e8ba5ab.jpg",
374
+ "text": "$$\n\\log p ( y | X ) = - \\frac { 1 } { 2 } { y } ^ { T } \\bigl ( K + \\sigma _ { n } ^ { 2 } I \\bigr ) ^ { - 1 } y - \\frac { 1 } { 2 } \\mathrm { l o g } \\left| K + \\sigma _ { n } ^ { 2 } I \\right| - \\frac { N } { 2 } \\mathrm { l o g } 2 \\pi .\n$$",
375
+ "text_format": "latex",
376
+ "bbox": [
377
+ 271,
378
+ 839,
379
+ 725,
380
+ 869
381
+ ],
382
+ "page_idx": 2
383
+ },
384
+ {
385
+ "type": "text",
386
+ "text": "We are reminded here that the marginal likelihood is applied directly on the entire training dataset, rather than a validation subset. In addition, Cholesky decomposition (Neal, 1998) can be employed to calculate the term $\\left( \\boldsymbol { \\mathcal { K } } + \\sigma _ { n } ^ { 2 } \\boldsymbol { I } \\right) ^ { - 1 }$ in equation (2). ",
387
+ "bbox": [
388
+ 174,
389
+ 877,
390
+ 825,
391
+ 925
392
+ ],
393
+ "page_idx": 2
394
+ },
395
+ {
396
+ "type": "text",
397
+ "text": "2.4 RELU COVARIANCE FUNCTION ",
398
+ "text_level": 1,
399
+ "bbox": [
400
+ 176,
401
+ 103,
402
+ 434,
403
+ 118
404
+ ],
405
+ "page_idx": 3
406
+ },
407
+ {
408
+ "type": "text",
409
+ "text": "With the structure of the single-hidden-layer ReLU neural network defined, we proceed to study its corresponding ReLU Gaussian process. ",
410
+ "bbox": [
411
+ 173,
412
+ 128,
413
+ 823,
414
+ 159
415
+ ],
416
+ "page_idx": 3
417
+ },
418
+ {
419
+ "type": "text",
420
+ "text": "The ReLU covariance function is developed to estimate the covariance at the output of the ReLU neural network model. Our alternative derivation was inspired by the work on arc-cosine family of kernels developed in (Cho and Saul, 2009). In our work we first derive the expectation of the product of post-activations, instead of on the input to the nonlinearity (Lee et al., 2018). Then, we apply the output layer activation function on the post-activation expected value. It can be shown that the resulting representations are equivalent. The complete derivation of our expression is provided in the Appendix 5. ",
421
+ "bbox": [
422
+ 173,
423
+ 165,
424
+ 825,
425
+ 262
426
+ ],
427
+ "page_idx": 3
428
+ },
429
+ {
430
+ "type": "text",
431
+ "text": "Referring to Figure 1, we consider input vectors $x ^ { 0 } , y ^ { 0 } \\in \\mathcal { R } ^ { d _ { i n } }$ . The initial weight value is drawn randomly from the Gaussian distribution fW 0jk = N (0, σ2wdin ) and bias value from fb0j = N (0, σ2b ). The expected value of the product of post-activations at the output of the $j ^ { t h }$ hidden node is computed as ",
432
+ "bbox": [
433
+ 174,
434
+ 267,
435
+ 823,
436
+ 335
437
+ ],
438
+ "page_idx": 3
439
+ },
440
+ {
441
+ "type": "equation",
442
+ "img_path": "images/a51eb793e6ec254959602f4fcd0894d3a5564cd0a7f0f40761d489a4922befc8.jpg",
443
+ "text": "$$\n\\begin{array} { r l } & { E [ \\mathbf { X } _ { j } ( { x } ^ { 0 } ) \\mathbf { X } _ { j } ( { y } ^ { 0 } ) ] } \\\\ & { \\ = \\displaystyle \\int \\cdots \\int _ { - \\infty } ^ { \\infty } \\operatorname* { m a x } ( b _ { j } ^ { 0 } + w _ { j } ^ { 0 } \\cdot { x } ^ { 0 } ) \\operatorname* { m a x } ( b _ { j } ^ { 0 } + w _ { j } ^ { 0 } \\cdot { y } ^ { 0 } ) f _ { b _ { j } ^ { 0 } , W _ { j } ^ { 0 } } ( b , w ) d w _ { j } ^ { 0 } d b _ { j } ^ { 0 } } \\\\ & { \\ = \\displaystyle \\int \\cdots \\int _ { - \\infty } ^ { \\infty } ( b _ { j } ^ { 0 } + w _ { j } ^ { 0 } \\cdot { x } ^ { 0 } ) _ { + } ( b _ { j } ^ { 0 } + w _ { j } ^ { 0 } \\cdot { y } ^ { 0 } ) _ { + } f _ { b _ { j } ^ { 0 } , W _ { j } ^ { 0 } } ( b , w ) d w _ { j } ^ { 0 } d b } \\end{array}\n$$",
444
+ "text_format": "latex",
445
+ "bbox": [
446
+ 250,
447
+ 338,
448
+ 746,
449
+ 431
450
+ ],
451
+ "page_idx": 3
452
+ },
453
+ {
454
+ "type": "text",
455
+ "text": "Suppose we denote the pre-activations as ",
456
+ "bbox": [
457
+ 174,
458
+ 443,
459
+ 444,
460
+ 457
461
+ ],
462
+ "page_idx": 3
463
+ },
464
+ {
465
+ "type": "equation",
466
+ "img_path": "images/50e9d3d8adde6442bdc0879b0923d57f6590c8b6fa9586b0bcbb65b57e06eb21.jpg",
467
+ "text": "$$\n\\begin{array} { l } { { U = b _ { j } ^ { 0 } + W _ { j } ^ { 0 } \\cdot x ^ { 0 } = b _ { j } ^ { 0 } + \\displaystyle \\sum _ { k = 1 } ^ { d _ { i n } } W _ { j k } ^ { 0 } x _ { k } ^ { 0 } \\sim \\mathcal N ( 0 , \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\| x \\| ^ { 2 } ) , } } \\\\ { { \\displaystyle V = b _ { j } ^ { 0 } + W _ { j } ^ { 0 } \\cdot y ^ { 0 } = b _ { j } ^ { 0 } + \\displaystyle \\sum _ { k ^ { \\prime } = 1 } ^ { d _ { i n } } W _ { j k ^ { \\prime } } ^ { 0 } y _ { k ^ { \\prime } } ^ { 0 } \\sim \\mathcal N ( 0 , \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\| y \\| ^ { 2 } ) . } } \\end{array}\n$$",
468
+ "text_format": "latex",
469
+ "bbox": [
470
+ 284,
471
+ 463,
472
+ 712,
473
+ 553
474
+ ],
475
+ "page_idx": 3
476
+ },
477
+ {
478
+ "type": "text",
479
+ "text": "It can be shown that the random variables $U , V$ have a joint Gaussian distribution: ",
480
+ "bbox": [
481
+ 173,
482
+ 563,
483
+ 709,
484
+ 579
485
+ ],
486
+ "page_idx": 3
487
+ },
488
+ {
489
+ "type": "equation",
490
+ "img_path": "images/5d08163fe0a5a96de85b635a47d7f0d6d5aec49cad849df99a2c7f7bfed88c7e.jpg",
491
+ "text": "$$\n{ \\binom { U } { V } } \\sim { \\mathcal { N } } ( 0 , \\Sigma ) , { \\mathrm { ~ w h e r e ~ } } \\Sigma = { \\binom { \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\| x \\| ^ { 2 } } { \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } ( x \\cdot y ) } } \\quad \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } ( x \\cdot y ) \\quad ) ,\n$$",
492
+ "text_format": "latex",
493
+ "bbox": [
494
+ 274,
495
+ 583,
496
+ 722,
497
+ 619
498
+ ],
499
+ "page_idx": 3
500
+ },
501
+ {
502
+ "type": "text",
503
+ "text": "for simplicity we let $x = x ^ { 0 } , y = y ^ { 0 }$ . We can therefore write expression (3) as ",
504
+ "bbox": [
505
+ 173,
506
+ 631,
507
+ 686,
508
+ 647
509
+ ],
510
+ "page_idx": 3
511
+ },
512
+ {
513
+ "type": "equation",
514
+ "img_path": "images/917f0025fef5526b16ee451607dd27632a8c0f9ce0683c510daadecd2028c8f5.jpg",
515
+ "text": "$$\n\\iint _ { 0 } ^ { \\infty } u v \\frac { 1 } { 2 \\pi | \\Sigma | ^ { \\frac { 1 } { 2 } } } \\exp \\big ( - \\frac { 1 } { 2 } ( u , v ) \\Sigma ^ { - 1 } ( u , v ) ^ { T } \\big ) d u d v .\n$$",
516
+ "text_format": "latex",
517
+ "bbox": [
518
+ 318,
519
+ 652,
520
+ 676,
521
+ 689
522
+ ],
523
+ "page_idx": 3
524
+ },
525
+ {
526
+ "type": "equation",
527
+ "img_path": "images/7fcba1a822e3209c2c8f193c4baa8f264ca76eb8dd1e69471e32fabbb5790452.jpg",
528
+ "text": "$$\n\\begin{array} { l } { { \\displaystyle \\Sigma ^ { - 1 } = \\binom { a _ { 1 1 } } { a _ { 2 1 } } \\mathrm { , ~ w h e r e ~ } a _ { 1 1 } = \\frac { 1 } { D } ( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\| y \\| ^ { 2 } ) \\mathrm { , ~ } a _ { 2 2 } = \\frac { 1 } { D } ( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\| x \\| ^ { 2 } ) \\mathrm { , ~ } } } \\\\ { { \\displaystyle a _ { 1 2 } = a _ { 2 1 } = \\frac { - 1 } { D } ( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } ( x \\cdot y ) ) . } } \\end{array}\n$$",
529
+ "text_format": "latex",
530
+ "bbox": [
531
+ 227,
532
+ 728,
533
+ 771,
534
+ 795
535
+ ],
536
+ "page_idx": 3
537
+ },
538
+ {
539
+ "type": "text",
540
+ "text": "With polar coordinate transformation: $\\begin{array} { r } { u \\ = \\ \\frac { r } { \\sqrt { a _ { 1 1 } } } \\cos \\alpha , v \\ = \\ \\frac { r } { \\sqrt { a _ { 2 2 } } } \\sin \\alpha . } \\end{array}$ , expression (3) can be further reduced to ",
541
+ "bbox": [
542
+ 174,
543
+ 804,
544
+ 823,
545
+ 837
546
+ ],
547
+ "page_idx": 3
548
+ },
549
+ {
550
+ "type": "equation",
551
+ "img_path": "images/255c8654815a870af33859bc1f060e392cff95a0c5bc97533085e99ef9cace8f.jpg",
552
+ "text": "$$\n\\begin{array} { r l } & { \\frac { 1 } { 4 \\pi \\mathcal { D } ^ { 1 / 2 } a _ { 1 1 } a _ { 2 2 } } \\displaystyle \\int _ { \\alpha = 0 } ^ { \\frac { \\pi } { 2 } } \\frac { 2 \\sin 2 \\alpha } { \\left( 1 - \\cos \\phi \\sin 2 \\alpha \\right) ^ { 2 } } d \\alpha } \\\\ & { = \\frac { 1 } { 2 \\pi \\mathcal { D } ^ { 1 / 2 } a _ { 1 1 } a _ { 2 2 } \\sin ^ { 3 } \\phi } \\Big ( \\sin ( \\phi ) + ( \\pi - \\phi ) \\cos ( \\phi ) \\Big ) , \\mathrm { ~ w h e r e ~ } \\phi = \\cos ^ { - 1 } \\Big ( \\frac { - a _ { 1 2 } } { \\sqrt { a _ { 1 1 } a _ { 2 2 } } } \\Big ) . } \\end{array}\n$$",
553
+ "text_format": "latex",
554
+ "bbox": [
555
+ 215,
556
+ 838,
557
+ 784,
558
+ 924
559
+ ],
560
+ "page_idx": 3
561
+ },
562
+ {
563
+ "type": "text",
564
+ "text": "With some algebraic operations and after computing the entries in $\\Sigma ^ { - 1 }$ , we arrive at ",
565
+ "bbox": [
566
+ 173,
567
+ 102,
568
+ 725,
569
+ 119
570
+ ],
571
+ "page_idx": 4
572
+ },
573
+ {
574
+ "type": "equation",
575
+ "img_path": "images/5085e24be42b338806da57037c9c1ea51dbcab41cea166c21366139ac762371e.jpg",
576
+ "text": "$$\n\\begin{array} { l } { { \\displaystyle E [ { \\bf X } _ { j } ( x ) { \\bf X } _ { j } ( y ) ] } } \\\\ { { \\displaystyle = \\frac { 1 } { 2 \\pi } \\Big ( \\sigma _ { b } ^ { 2 } + \\| x \\| ^ { 2 } \\sigma _ { w } ^ { 2 } \\Big ) ^ { \\frac { 1 } { 2 } } \\Big ( \\sigma _ { b } ^ { 2 } + \\| y \\| ^ { 2 } \\sigma _ { w } ^ { 2 } \\Big ) ^ { \\frac { 1 } { 2 } } \\Big ( \\sin \\phi + ( \\pi - \\phi ) \\cos \\phi \\Big ) } } \\\\ { { \\displaystyle \\mathrm { w h e r e ~ } \\phi = \\cos ^ { - 1 } \\left\\{ \\frac { \\sigma _ { b } ^ { 2 } + ( x \\cdot y ) \\sigma _ { w } ^ { 2 } } { \\Big ( \\sigma _ { b } ^ { 2 } + \\| x \\| ^ { 2 } \\sigma _ { w } ^ { 2 } \\Big ) ^ { 1 / 2 } \\Big ( \\sigma _ { b } ^ { 2 } + \\| y \\| ^ { 2 } \\sigma _ { w } ^ { 2 } \\Big ) ^ { 1 / 2 } } \\right\\} . } } \\end{array}\n$$",
577
+ "text_format": "latex",
578
+ "bbox": [
579
+ 272,
580
+ 118,
581
+ 723,
582
+ 223
583
+ ],
584
+ "page_idx": 4
585
+ },
586
+ {
587
+ "type": "text",
588
+ "text": "To compute the expected value, $\\begin{array} { r } { E [ \\mathbf { X } _ { j } ( x ) ] \\ = \\ \\int \\operatorname* { m a x } ( b + w \\cdot x ) f _ { b _ { j } ^ { 0 } , W _ { j k } ^ { 0 } } ( b , w ) d w d b } \\end{array}$ , we denote $U = b + w \\cdot x \\sim N ( 0 , \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\| x \\| ^ { 2 } )$ , and apply the change in variable ${ \\frac { 1 } { 2 \\sigma ^ { 2 } } } u ^ { 2 } = t$ , where $\\sigma ^ { 2 } = $ $\\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\lVert x \\rVert ^ { 2 }$ to obtain ",
589
+ "bbox": [
590
+ 173,
591
+ 231,
592
+ 825,
593
+ 292
594
+ ],
595
+ "page_idx": 4
596
+ },
597
+ {
598
+ "type": "equation",
599
+ "img_path": "images/a8f8432f13f0ab8afbee6480fcd3fb795f8f57f1a11e4affc7500fddf1d67f95.jpg",
600
+ "text": "$$\n\\begin{array} { l } { { \\displaystyle E [ { \\bf X } _ { j } ( x ) ] = \\int _ { - \\infty } ^ { \\infty } \\left( u \\right) + f _ { U } \\left( u \\right) d u } } \\\\ { ~ } \\\\ { { \\displaystyle = \\int _ { 0 } ^ { \\infty } u \\frac { 1 } { \\sqrt { 2 \\pi } \\sigma } e ^ { - \\frac { 1 } { 2 \\sigma ^ { 2 } } u ^ { 2 } } d u } } \\\\ { { \\displaystyle = \\int _ { 0 } ^ { \\infty } \\sigma ^ { 2 } d u \\frac { 1 } { \\sqrt { 2 \\pi } \\sigma } e ^ { - t } } } \\\\ { { \\displaystyle = \\frac { \\sigma } { \\sqrt { 2 \\pi } } } } \\\\ { { \\displaystyle = \\frac { \\sqrt { \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } } \\left| x \\right| / 2 } { \\sqrt { 2 \\pi } } } } \\end{array}\n$$",
601
+ "text_format": "latex",
602
+ "bbox": [
603
+ 390,
604
+ 294,
605
+ 602,
606
+ 468
607
+ ],
608
+ "page_idx": 4
609
+ },
610
+ {
611
+ "type": "text",
612
+ "text": "The covariance function at the network output is therefore determined to be ",
613
+ "bbox": [
614
+ 173,
615
+ 473,
616
+ 669,
617
+ 489
618
+ ],
619
+ "page_idx": 4
620
+ },
621
+ {
622
+ "type": "equation",
623
+ "img_path": "images/ff2bc1e54ded8124639ecb745ead78a57f20aa902c85ffbc0f6ddf4106efccca.jpg",
624
+ "text": "$$\n\\begin{array} { l } { { \\displaystyle E \\Big [ \\big ( b _ { i } ^ { 1 } + \\sum _ { j = 1 } ^ { N _ { 1 } } W _ { i j } ^ { 1 } \\mathbf { X } _ { j } ( x ) \\big ) \\big ( b _ { i } ^ { 1 } + \\sum _ { k = 1 } ^ { N _ { 1 } } W _ { i k } ^ { 1 } \\mathbf { X } _ { k } ( y ) \\big ) \\Big ] - E \\Big [ b _ { i } ^ { 1 } + \\sum _ { j = 1 } ^ { N _ { 1 } } W _ { i j } ^ { 1 } \\mathbf { X } _ { j } ( x ) \\Big ] \\Big [ b _ { i } ^ { 1 } + \\sum _ { k = 1 } ^ { N _ { 1 } } W _ { i k } ^ { 1 } \\mathbf { X } _ { k } ( y ) \\Big ] } } \\\\ { { \\displaystyle = E [ ( b _ { i } ^ { 1 } ) ^ { 2 } ] + \\sum _ { j = 1 } ^ { N _ { 1 } } E [ ( W _ { i j } ^ { 1 } ) ^ { 2 } ] E [ \\mathbf { X } _ { j } ( x ) \\mathbf { X } _ { j } ( y ) ] - \\frac { 1 } { 2 \\pi } \\sqrt { \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\| x \\| ^ { 2 } } \\sqrt { \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\| y \\| ^ { 2 } } } } \\\\ { { \\displaystyle = \\sigma _ { b } ^ { 2 } + \\frac { \\sigma _ { w } ^ { 2 } } { N _ { 1 } } N _ { 1 } E [ \\mathbf { X } _ { j } ( x ) \\mathbf { X } _ { j } ( y ) ] - \\frac { 1 } { 2 \\pi } \\sqrt { \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\| x \\| ^ { 2 } } \\sqrt { \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\| y \\| ^ { 2 } } } } \\\\ { { \\displaystyle = \\sigma _ { b } ^ { 2 } + \\frac { \\sigma _ { w } ^ { 2 } } { 2 \\pi } \\Big ( \\sigma _ { b } ^ { 2 } + \\| x \\| ^ { 2 } \\sigma _ { w } ^ { 2 } \\Big ) ^ { \\frac { 1 } { 2 } } \\Big ( \\sigma _ { b } ^ { 2 } + \\| y \\| ^ { 2 } \\sigma _ { w } ^ { 2 } \\Big ) ^ { \\frac { 1 } { 2 } } \\Big ( \\sin \\phi + ( \\pi - \\phi ) \\cos \\phi - 1 \\Big ) . } } \\end{array}\n$$",
625
+ "text_format": "latex",
626
+ "bbox": [
627
+ 181,
628
+ 491,
629
+ 820,
630
+ 651
631
+ ],
632
+ "page_idx": 4
633
+ },
634
+ {
635
+ "type": "text",
636
+ "text": "2.5 GAUSSIAN PROCESS PREDICTION: A SIMULATION ",
637
+ "text_level": 1,
638
+ "bbox": [
639
+ 173,
640
+ 661,
641
+ 565,
642
+ 678
643
+ ],
644
+ "page_idx": 4
645
+ },
646
+ {
647
+ "type": "text",
648
+ "text": "Performing simulations allows us to explore and understand some properties of the models we wish to study. Simulation results also offer the opportunity for evaluating model precision and insight into observed events. ",
649
+ "bbox": [
650
+ 173,
651
+ 688,
652
+ 825,
653
+ 731
654
+ ],
655
+ "page_idx": 4
656
+ },
657
+ {
658
+ "type": "text",
659
+ "text": "To demonstrate making predictions with Gaussian process regression model, we borrow equations from (Williams and Rasmussen, 2006) where the formulation of Gaussian process predictive distribution is treated in great detail. ",
660
+ "bbox": [
661
+ 173,
662
+ 737,
663
+ 825,
664
+ 780
665
+ ],
666
+ "page_idx": 4
667
+ },
668
+ {
669
+ "type": "text",
670
+ "text": "Given the design matrix $X = \\{ x _ { i } \\} _ { i = 1 } ^ { N }$ , $\\boldsymbol { x } _ { i } \\in \\mathcal { R } ^ { D }$ , observed targets $y = \\{ y _ { i } \\} _ { i = 1 } ^ { N }$ , $y _ { i } \\in \\mathcal { R }$ , unknown test data $X _ { * }$ , and their function values $f _ { * } : = f ( X _ { * } )$ , the joint distribution of the target and function values is computed as ",
671
+ "bbox": [
672
+ 173,
673
+ 785,
674
+ 825,
675
+ 829
676
+ ],
677
+ "page_idx": 4
678
+ },
679
+ {
680
+ "type": "equation",
681
+ "img_path": "images/354284c9da6698eb636ed5e17f7e77dcd409fedb92551999dc345e577acf430d.jpg",
682
+ "text": "$$\n\\biggl [ \\mathop { y } _ { * } \\biggr ] \\sim N \\biggl ( 0 , \\left[ \\begin{array} { c c } { K ( X , X ) + \\sigma _ { n } ^ { 2 } I } & { K ( X , X _ { * } } \\\\ { K ( X _ { * } , X ) } & { K ( X _ { * } , X _ { * } ) } \\end{array} \\right] \\biggr ) ,\n$$",
683
+ "text_format": "latex",
684
+ "bbox": [
685
+ 326,
686
+ 830,
687
+ 669,
688
+ 872
689
+ ],
690
+ "page_idx": 4
691
+ },
692
+ {
693
+ "type": "text",
694
+ "text": "where $K ( X , X )$ represents the covariance matrix of all pairs of training points, $K ( X , X _ { * } )$ denotes that of pairs of training and test points, and $K ( X _ { * } , X _ { * } )$ gives the covariance matrix of pairs of test points. ",
695
+ "bbox": [
696
+ 173,
697
+ 881,
698
+ 823,
699
+ 924
700
+ ],
701
+ "page_idx": 4
702
+ },
703
+ {
704
+ "type": "text",
705
+ "text": "The prediction distribution is the conditional distribution ",
706
+ "bbox": [
707
+ 174,
708
+ 103,
709
+ 547,
710
+ 118
711
+ ],
712
+ "page_idx": 5
713
+ },
714
+ {
715
+ "type": "equation",
716
+ "img_path": "images/9b2cdee65cb420331e93138ec6c0ac271f0faa65e6c3e98a03d7a1e1a50c4882.jpg",
717
+ "text": "$$\nf _ { * } | X , y , X _ { * } \\sim N ( \\mu _ { * } , \\Sigma _ { * } )\n$$",
718
+ "text_format": "latex",
719
+ "bbox": [
720
+ 235,
721
+ 119,
722
+ 410,
723
+ 138
724
+ ],
725
+ "page_idx": 5
726
+ },
727
+ {
728
+ "type": "equation",
729
+ "img_path": "images/13c137867d7d9503fed98396c41414427ee59c5a0f72e54adeb5da5bd5cb78ad.jpg",
730
+ "text": "$$\n\\begin{array} { l } { \\operatorname { i o n } \\mu _ { \\ast } = K ( X _ { \\ast } , X ) \\big [ K ( X , X ) + \\sigma _ { n } ^ { 2 } I \\big ] ^ { - 1 } y } \\\\ { \\Sigma _ { \\ast } = K ( X _ { \\ast } , X _ { \\ast } ) - K ( X _ { \\ast } , X ) \\big [ K ( X , X ) + \\sigma _ { n } ^ { 2 } I \\big ] ^ { - 1 } K ( X , X _ { \\ast } ) . } \\end{array}\n$$",
731
+ "text_format": "latex",
732
+ "bbox": [
733
+ 341,
734
+ 138,
735
+ 764,
736
+ 185
737
+ ],
738
+ "page_idx": 5
739
+ },
740
+ {
741
+ "type": "text",
742
+ "text": "The simulation starts out with setting the hyperparameters of the ReLU covariance function to (3.6, 0.02), chosen from $\\sigma _ { w } ^ { 2 } \\in [ 0 . 4 , 1 . 2 , 2 . 0 , \\hat { 2 . } 8 , \\hat { 3 . } 6 ]$ , and $\\sigma _ { b } ^ { 2 } \\in [ 0 . 0 0 0 1 , 0 . 0 1 , 0 . 0 2 ]$ . We randomly select a set of 70 training and 30 test location points from 100 values evenly spaced in the interval [0.0, 1.0]. Ten sample paths, as shown in the top left panel of Figure (2), are generated from the design Gaussian process model. Their sample mean produces 70 training target and 30 test values. We then estimate the optimal hyperparameters from the training targets via evaluating the marginal likelihood, equation (2), over the design ranges of $\\sigma _ { w } ^ { 2 }$ and $\\sigma _ { b } ^ { 2 }$ . ",
743
+ "bbox": [
744
+ 173,
745
+ 191,
746
+ 825,
747
+ 291
748
+ ],
749
+ "page_idx": 5
750
+ },
751
+ {
752
+ "type": "text",
753
+ "text": "The maximum marginal likelihood is obtained at $\\{ \\tilde { \\sigma } _ { w } ^ { 2 } , \\tilde { \\sigma } _ { b } ^ { 2 } \\} = \\{ 3 . 6 , 0 . 0 2 \\}$ which is the design hyperparameter pair. The minimum marginal likelihood is obtained at $\\{ \\hat { \\sigma } _ { w } ^ { 2 } , \\hat { \\sigma } _ { b } ^ { 2 } \\} = \\{ 3 . 6 , 0 . 0 0 0 \\bar { 1 } \\}$ . A Gaussian process model is then built with the optimal hyperparameter pair to make predictions for the 30 test location points. The model accuracy is assessed with a RMSE of 0.00051. Additionally we overlay the predicted and true test target values, as shown in the top middle panel of Figure (2), to detect any prediction errors. We plot the line of equality to further validate the estimated hyperparameters, as depicted in the top right panel of the figure. ",
754
+ "bbox": [
755
+ 173,
756
+ 295,
757
+ 825,
758
+ 395
759
+ ],
760
+ "page_idx": 5
761
+ },
762
+ {
763
+ "type": "text",
764
+ "text": "The evaluation process is repeated applying the hyperparameter pair $\\big \\{ \\hat { \\sigma } _ { w } ^ { 2 } , \\hat { \\sigma } _ { b } ^ { 2 } \\big \\}$ which produces a prediction RMSE of 0.00188, over 3 times as large as the optimal case. The accuracy plots shown in the bottom panels of Figure (2) indicate some prediction errors. ",
765
+ "bbox": [
766
+ 173,
767
+ 400,
768
+ 825,
769
+ 443
770
+ ],
771
+ "page_idx": 5
772
+ },
773
+ {
774
+ "type": "image",
775
+ "img_path": "images/630c117a9a1155e2a76ef9d401390bae01718d2fe15527a6b199b7a27992f358.jpg",
776
+ "image_caption": [
777
+ "Figure 2: Gaussian process regression prediction on simulated data. Top left: 10 sample paths generated from a Gaussian process model with hyperparameters $( \\sigma _ { w } ^ { 2 } , \\sigma _ { b } ^ { 2 } ) \\overset { - } { = } ( 3 . 6 , 0 . 0 2 )$ . Top middle: Point-wise visual comparison between predicted and true target values for the optimal hyperparameter pair $\\{ 3 . 6 , 0 . 0 \\bar { 2 } \\}$ , showing good prediction results. Top right: The line of equality further confirming the prediction accuracy. Bottom left: Point-wise visual comparison for hyperparameter pair $\\lbrace 3 . 6 , 0 . 0 0 0 1 \\rbrace$ . Bottom right: Prediction errors revealed with the line of equality. "
778
+ ],
779
+ "image_footnote": [],
780
+ "bbox": [
781
+ 181,
782
+ 457,
783
+ 815,
784
+ 763
785
+ ],
786
+ "page_idx": 5
787
+ },
788
+ {
789
+ "type": "text",
790
+ "text": "Our simulation results agree with the principle that through optimizing the marginal likelihood of the Gaussian process model, we could estimate from training data the hyperparameter values most appropriate for its chosen covariance function. ",
791
+ "bbox": [
792
+ 174,
793
+ 881,
794
+ 825,
795
+ 924
796
+ ],
797
+ "page_idx": 5
798
+ },
799
+ {
800
+ "type": "text",
801
+ "text": "3 MNIST CLASSIFICATION EXPERIMENT ",
802
+ "text_level": 1,
803
+ "bbox": [
804
+ 174,
805
+ 102,
806
+ 532,
807
+ 118
808
+ ],
809
+ "page_idx": 6
810
+ },
811
+ {
812
+ "type": "text",
813
+ "text": "We conduct a classification experiment on the MNIST handwritten digit dataset (LeCun, 1998) making use of corresponding ReLU neural network and Gaussian process models. As in (Lee et al., 2018), the classification task on the class labels is treated as Gaussian process regression (also known as kriging in spatial statistics (Cressie, 1993)). ",
814
+ "bbox": [
815
+ 174,
816
+ 135,
817
+ 825,
818
+ 190
819
+ ],
820
+ "page_idx": 6
821
+ },
822
+ {
823
+ "type": "text",
824
+ "text": "It is necessary to point out that the goal of this work is to examine using the marginal likelihood to estimate the best available initial hyperparameter setting for neural networks, rather than determining the networks’ optimal structure. ",
825
+ "bbox": [
826
+ 174,
827
+ 196,
828
+ 825,
829
+ 239
830
+ ],
831
+ "page_idx": 6
832
+ },
833
+ {
834
+ "type": "text",
835
+ "text": "Our experiment consists of three main steps: (A) searching within a given grid of hyperparameter values for the pair $\\big \\{ \\tilde { \\sigma } _ { w } ^ { 2 } , \\tilde { \\sigma } _ { b } ^ { 2 } \\big \\}$ that maximizes the log marginal likelihood function of the Gaussian procepoint $\\{ \\sigma _ { w } ^ { 2 } , \\sigma _ { b } ^ { 2 } \\}$ (B) evaluaincluding $\\{ \\tilde { \\sigma _ { w } ^ { 2 } } , \\tilde { \\sigma } _ { b } ^ { 2 } \\}$ ction accuracy of the corresponding neural network at each grid, and (C) assessing neural network performance over all tested ",
836
+ "bbox": [
837
+ 174,
838
+ 247,
839
+ 825,
840
+ 316
841
+ ],
842
+ "page_idx": 6
843
+ },
844
+ {
845
+ "type": "text",
846
+ "text": "3.1 PROCEDURE ",
847
+ "text_level": 1,
848
+ "bbox": [
849
+ 174,
850
+ 335,
851
+ 302,
852
+ 349
853
+ ],
854
+ "page_idx": 6
855
+ },
856
+ {
857
+ "type": "text",
858
+ "text": "The workflow for the experiment is as follows: we set up a grid map of $\\sigma _ { w } ^ { 2 } \\in \\{ 0 . 4 , 1 . 2 , 2 . 0 , 2 . 8 , 3 . 6 \\}$ , $\\sigma _ { b } ^ { 2 } \\in \\{ 0 . 0 , 1 . 0 , 2 . 0 \\}$ . Then, $_ \\mathrm { N }$ samples are randomly selected from the MNIST training set to form a training subset, where $\\mathbf { N }$ is the training size. This is followed by computing the log marginal likelihood (equation 2) at each grid point. This allows us to identify the hyperparameter pair $\\big \\{ \\tilde { \\sigma } _ { w } ^ { 2 } , \\tilde { \\sigma } _ { b } ^ { 2 } \\big \\}$ that yields the maximum log marginal likelihood value. ",
859
+ "bbox": [
860
+ 174,
861
+ 362,
862
+ 825,
863
+ 433
864
+ ],
865
+ "page_idx": 6
866
+ },
867
+ {
868
+ "type": "text",
869
+ "text": "On the neural network side, we build a fully-connected feedforward neural network with a single hidden layer width, hidden width, of 2000 nodes, Adam optimizer, and mse loss function. Since the network model is fully connected, the size of the input layer $d _ { i n }$ is 28(pixels) $\\mathrm { ~ x ~ } 2 8 ( \\mathrm { p i x e l s } ) = 7 8 4$ . Prior to training, the initialization parameters $\\{ w , b \\}$ are set by sampling the distributions $\\mathcal { N } ( 0 , \\sigma _ { w } ^ { 2 } / d _ { i n } )$ and $\\bar { \\mathcal { N } } ( 0 , \\bar { \\sigma _ { b } ^ { 2 } } )$ for weights and biases from the input to the hidden layer, and $\\mathcal { N } ( 0 , \\sigma _ { w } ^ { 2 } / 2 0 0 0 )$ and $\\mathcal { N } ( 0 , \\sigma _ { b } ^ { 2 } )$ for weights and biases from the hidden to the output layer. The neural network is then trained with the training subset generated previously. We compute the model classification accuracy on the MNIST test set and repeat the procedure over the entire grid map of hyperparameter pairs. ",
870
+ "bbox": [
871
+ 173,
872
+ 439,
873
+ 825,
874
+ 551
875
+ ],
876
+ "page_idx": 6
877
+ },
878
+ {
879
+ "type": "text",
880
+ "text": "To investigate the usefulness of our proposed approach for assisting model initialization, we employ He-initialization approach as a benchmark to measure numerically and graphically our neural network performance over all tested hyperparameter pairs. Additionally, we check for recommendation consistency. ",
881
+ "bbox": [
882
+ 174,
883
+ 558,
884
+ 825,
885
+ 614
886
+ ],
887
+ "page_idx": 6
888
+ },
889
+ {
890
+ "type": "text",
891
+ "text": "3.2 RESULTS ",
892
+ "text_level": 1,
893
+ "bbox": [
894
+ 174,
895
+ 633,
896
+ 277,
897
+ 647
898
+ ],
899
+ "page_idx": 6
900
+ },
901
+ {
902
+ "type": "text",
903
+ "text": "Applying the method described in Section 2.3 for estimating model hyperparameter pair we obtain a consistent recommendation of $( \\sigma _ { w } ^ { 2 } , \\sigma _ { b } ^ { 2 } ) = ( 3 . 6 , 0 . 0 )$ . ",
904
+ "bbox": [
905
+ 176,
906
+ 660,
907
+ 823,
908
+ 690
909
+ ],
910
+ "page_idx": 6
911
+ },
912
+ {
913
+ "type": "image",
914
+ "img_path": "images/a02e934840c15c37ef77e64fe0bb249ef6869918100ae28d9a2a1ef50254b665.jpg",
915
+ "image_caption": [
916
+ "Figure 3: Comparing MNIST training accuracy over various training sizes. We observe that the convergence rate based on our method approaches that using He-initialization as the training size increases. This suggests that our technique may potentially be efficient for guiding deep neural network initialization. Left: train size $= 1 0 0 0$ . Middle: train size $\\scriptstyle = 3 0 0 0$ . Right: train size $\\mathord { = } 5 0 0 0$ . "
917
+ ],
918
+ "image_footnote": [],
919
+ "bbox": [
920
+ 192,
921
+ 705,
922
+ 807,
923
+ 853
924
+ ],
925
+ "page_idx": 6
926
+ },
927
+ {
928
+ "type": "text",
929
+ "text": "After running 250 training epochs, convergence of the neural network model and its prediction accuracy are studied for different training sizes. We observe that training based on our initialization approach converges to that based on He-initialization as the size of training samples increases, as shown in Figure 3. This seems to suggest that our approach may be used as an efficient tool for recommending initialization in deep learning. ",
930
+ "bbox": [
931
+ 174,
932
+ 103,
933
+ 825,
934
+ 174
935
+ ],
936
+ "page_idx": 7
937
+ },
938
+ {
939
+ "type": "text",
940
+ "text": "It is worth noting that the Gaussian process model marginal likelihood consistently suggests the hyperparameter pair $( \\sigma _ { w } ^ { 2 } , \\sigma _ { b } ^ { 2 } ) = ( 3 . \\dot { 6 } , 0 )$ . The fact that the bias variance $\\sigma _ { b } ^ { 2 }$ is estimated to be 0 coincides with the assumption that bias vector being 0 in (He et al., 2015). ",
941
+ "bbox": [
942
+ 176,
943
+ 180,
944
+ 821,
945
+ 223
946
+ ],
947
+ "page_idx": 7
948
+ },
949
+ {
950
+ "type": "text",
951
+ "text": "Table 1 lists neural network model prediction accuracy based on, respectively, our approach and He-initialization scheme, against the best and the worst performers. The results indicate that more frequently our approach achieves slightly better accuracy than based on He-initialization. However, neither approach reliably gives an estimate of weight variance close to that for the best case. ",
952
+ "bbox": [
953
+ 174,
954
+ 229,
955
+ 825,
956
+ 285
957
+ ],
958
+ "page_idx": 7
959
+ },
960
+ {
961
+ "type": "table",
962
+ "img_path": "images/943f8c87fdcf30bbae99d9741114d252e8957a647c434bcf08234edbb845a46a.jpg",
963
+ "table_caption": [
964
+ "Table 1: Single-hidden-layer fully-connected neural network model prediction accuracy on MNIST test set, and associated hyperparameter pair. "
965
+ ],
966
+ "table_footnote": [],
967
+ "table_body": "<table><tr><td rowspan=\"2\">Size</td><td colspan=\"2\">Best Case</td><td colspan=\"2\">Worst Case</td><td colspan=\"2\">He-Init</td><td colspan=\"2\">Ours</td></tr><tr><td>Acc.</td><td>(,)</td><td>Acc.</td><td>(,0)</td><td>Acc.</td><td>(²,0)</td><td>Acc.</td><td>(,0)</td></tr><tr><td>10000</td><td>96.85</td><td>(2,0)</td><td>96.04</td><td>(0.4,2)</td><td>96.85</td><td>(2,0)</td><td>96.60</td><td>(3.6, 0)</td></tr><tr><td>20000</td><td>97.25</td><td>(2.8,0)</td><td>96.70</td><td>(3.6, 1)</td><td>97.01</td><td>(2,0)</td><td>97.09</td><td>(3.6,0)</td></tr><tr><td>30000</td><td>97.50</td><td>(1.2, 0)</td><td>96.91</td><td>(2,2)</td><td>97.07</td><td>(2,0)</td><td>97.29</td><td>(3.6,0)</td></tr><tr><td>40000</td><td>97.43</td><td>(0.4,0)</td><td>97.16</td><td>(0.4,2)</td><td>97.35</td><td>(2,0)</td><td>97.42</td><td>(3.6,0)</td></tr><tr><td>50000</td><td>97.71</td><td>(3.6,0)</td><td>97.29</td><td>(0.4,2)</td><td>97.50</td><td>(2,0)</td><td>97.71</td><td>(3.6,0)</td></tr></table>",
968
+ "bbox": [
969
+ 196,
970
+ 349,
971
+ 797,
972
+ 470
973
+ ],
974
+ "page_idx": 7
975
+ },
976
+ {
977
+ "type": "text",
978
+ "text": "4 DISCUSSION AND FUTURE WORK ",
979
+ "text_level": 1,
980
+ "bbox": [
981
+ 174,
982
+ 508,
983
+ 486,
984
+ 525
985
+ ],
986
+ "page_idx": 7
987
+ },
988
+ {
989
+ "type": "text",
990
+ "text": "In this work we propose a simple, consistent, and time-efficient method to guide the selection of initial hyperparameters for neural networks. We show that through maximizing the log marginal likelihood we can learn from training data hyperparameter setting that leads to accurate and efficient initialization in neural networks. ",
991
+ "bbox": [
992
+ 174,
993
+ 546,
994
+ 825,
995
+ 603
996
+ ],
997
+ "page_idx": 7
998
+ },
999
+ {
1000
+ "type": "text",
1001
+ "text": "We develop an alternative representation of the ReLU covariance function to estimate the covariance at the output of the ReLU neural network model. We first derive the expectation of the product of post-activations. Then, we apply the output layer activation function on the post-activation expected value to generate the output covariance function. Utilizing marginal likelihood optimization with the derived ReLU covariance function we perform a simulation to demonstrate the effectiveness of Gaussian process regression. ",
1002
+ "bbox": [
1003
+ 174,
1004
+ 609,
1005
+ 825,
1006
+ 694
1007
+ ],
1008
+ "page_idx": 7
1009
+ },
1010
+ {
1011
+ "type": "text",
1012
+ "text": "We train a fully-connected single-hidden-layer neural network model to perform classification (treated as regression) on MNIST data set. The empirical results indicate that applying the recommended hyperparameter setting for initialization the neural network model performs well, with He-initialization scheme as the benchmark method. ",
1013
+ "bbox": [
1014
+ 174,
1015
+ 700,
1016
+ 825,
1017
+ 756
1018
+ ],
1019
+ "page_idx": 7
1020
+ },
1021
+ {
1022
+ "type": "text",
1023
+ "text": "A further examination of the results reveals consistency of the process. This implies that smaller training subsets could be used to provide reasonable recommendation for neural network initialization on sizable training data sets, reducing the computation time which is otherwise required for inverting considerably large covariance matrices. ",
1024
+ "bbox": [
1025
+ 174,
1026
+ 763,
1027
+ 825,
1028
+ 819
1029
+ ],
1030
+ "page_idx": 7
1031
+ },
1032
+ {
1033
+ "type": "text",
1034
+ "text": "The main goal of our future research is to investigate if our proposed method is adequate for deep neural networks with complicated data sets. We wish to ascertain if consistent recommendation could be attained by learning from larger data sets of color images via marginal likelihood maximization. We will attempt to derive or approximate multilayer covariance functions corresponding to various activation functions. Deep fully-connected neural network models will be built to perform classification on CIFAR-10 data set. Our hypothesis is that learning directly from training data helps to improve neural network initialization strategy. ",
1035
+ "bbox": [
1036
+ 174,
1037
+ 825,
1038
+ 825,
1039
+ 924
1040
+ ],
1041
+ "page_idx": 7
1042
+ },
1043
+ {
1044
+ "type": "text",
1045
+ "text": "REFERENCES ",
1046
+ "text_level": 1,
1047
+ "bbox": [
1048
+ 176,
1049
+ 102,
1050
+ 287,
1051
+ 118
1052
+ ],
1053
+ "page_idx": 8
1054
+ },
1055
+ {
1056
+ "type": "text",
1057
+ "text": "Christopher Bishop. Pattern recognition and machine learning. 2006. ",
1058
+ "bbox": [
1059
+ 174,
1060
+ 125,
1061
+ 632,
1062
+ 140
1063
+ ],
1064
+ "page_idx": 8
1065
+ },
1066
+ {
1067
+ "type": "text",
1068
+ "text": "Youngmin Cho and Lawrence K. Saul. Kernel Methods for Deep Learning. In Y. Bengio, D. Schuurmans, J. D. Lafferty, C. K. I. Williams, and A. Culotta, editors, Advances in Neural Information Processing Systems 22, pages 342–350. Curran Associates, Inc., 2009. URL http://papers. nips.cc/paper/3628-kernel-methods-for-deep-learning.pdf. ",
1069
+ "bbox": [
1070
+ 174,
1071
+ 147,
1072
+ 825,
1073
+ 205
1074
+ ],
1075
+ "page_idx": 8
1076
+ },
1077
+ {
1078
+ "type": "text",
1079
+ "text": "Noel AC Cressie. Statistics for spatial data. John Willy and Sons. Inc., New York, 1993. ",
1080
+ "bbox": [
1081
+ 173,
1082
+ 213,
1083
+ 746,
1084
+ 228
1085
+ ],
1086
+ "page_idx": 8
1087
+ },
1088
+ {
1089
+ "type": "text",
1090
+ "text": "Xavier Glorot and Yoshua Bengio. Understanding the difficulty of training deep feedforward neural networks. AISTATS, page 8, 2010. ",
1091
+ "bbox": [
1092
+ 171,
1093
+ 236,
1094
+ 826,
1095
+ 265
1096
+ ],
1097
+ "page_idx": 8
1098
+ },
1099
+ {
1100
+ "type": "text",
1101
+ "text": "Soufiane Hayou, Arnaud Doucet, and Judith Rousseau. On the Impact of the Activation Function on Deep Neural Networks Training. ICML, May 2019. URL http://arxiv.org/abs/1902. 06853. arXiv: 1902.06853. ",
1102
+ "bbox": [
1103
+ 174,
1104
+ 272,
1105
+ 825,
1106
+ 314
1107
+ ],
1108
+ "page_idx": 8
1109
+ },
1110
+ {
1111
+ "type": "text",
1112
+ "text": "Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. Delving Deep into Rectifiers: Surpassing Human-Level Performance on ImageNet Classification. arXiv:1502.01852 [cs], February 2015. URL http://arxiv.org/abs/1502.01852. arXiv: 1502.01852. ",
1113
+ "bbox": [
1114
+ 174,
1115
+ 323,
1116
+ 825,
1117
+ 366
1118
+ ],
1119
+ "page_idx": 8
1120
+ },
1121
+ {
1122
+ "type": "text",
1123
+ "text": "Ashish Kapoor, Kristen Grauman, Raquel Urtasun, and Trevor Darrell. Gaussian Processes for Object Categorization. International Journal of Computer Vision, 88(2):169–188, June 2010. ISSN 1573-1405. doi: 10.1007/s11263-009-0268-3. URL https://doi.org/10.1007/ s11263-009-0268-3. ",
1124
+ "bbox": [
1125
+ 173,
1126
+ 373,
1127
+ 825,
1128
+ 430
1129
+ ],
1130
+ "page_idx": 8
1131
+ },
1132
+ {
1133
+ "type": "text",
1134
+ "text": "Yann LeCun. THE MNIST DATABASE of handwritten digits, 1998. URL http://yann. lecun.com/exdb/mnist/. ",
1135
+ "bbox": [
1136
+ 174,
1137
+ 438,
1138
+ 821,
1139
+ 468
1140
+ ],
1141
+ "page_idx": 8
1142
+ },
1143
+ {
1144
+ "type": "text",
1145
+ "text": "Jaehoon Lee, Yasaman Bahri, Roman Novak, Samuel S. Schoenholz, Jeffrey Pennington, and Jascha Sohl-Dickstein. Deep Neural Networks as Gaussian Processes. arXiv:1711.00165 [cs, stat], March 2018. URL http://arxiv.org/abs/1711.00165. arXiv: 1711.00165. ",
1146
+ "bbox": [
1147
+ 173,
1148
+ 474,
1149
+ 825,
1150
+ 518
1151
+ ],
1152
+ "page_idx": 8
1153
+ },
1154
+ {
1155
+ "type": "text",
1156
+ "text": "David MacKay. Introduction to Gaussian processes. Citeseer, 1998. ",
1157
+ "bbox": [
1158
+ 173,
1159
+ 526,
1160
+ 622,
1161
+ 541
1162
+ ],
1163
+ "page_idx": 8
1164
+ },
1165
+ {
1166
+ "type": "text",
1167
+ "text": "Dmytro Mishkin and Jiri Matas. All you need is a good init. ICLR, February 2016. URL http: //arxiv.org/abs/1511.06422. arXiv: 1511.06422. ",
1168
+ "bbox": [
1169
+ 173,
1170
+ 549,
1171
+ 823,
1172
+ 578
1173
+ ],
1174
+ "page_idx": 8
1175
+ },
1176
+ {
1177
+ "type": "text",
1178
+ "text": "Radford M. Neal. Bayesian Learning for Neural Networks, volume 118 of Lecture Notes in Statistics. Springer New York, New York, NY, 1996. ISBN 978-0-387-94724-2 978-1-4612-0745- 0. doi: 10.1007/978-1-4612-0745-0. URL http://link.springer.com/10.1007/ 978-1-4612-0745-0. ",
1179
+ "bbox": [
1180
+ 174,
1181
+ 585,
1182
+ 825,
1183
+ 642
1184
+ ],
1185
+ "page_idx": 8
1186
+ },
1187
+ {
1188
+ "type": "text",
1189
+ "text": "Radford M. Neal. Regression and classification using Gaussian process priors. Bayesian statistics, 6:475, 1998. ",
1190
+ "bbox": [
1191
+ 171,
1192
+ 650,
1193
+ 823,
1194
+ 679
1195
+ ],
1196
+ "page_idx": 8
1197
+ },
1198
+ {
1199
+ "type": "text",
1200
+ "text": "Samuel S. Schoenholz, Justin Gilmer, Surya Ganguli, and Jascha Sohl-Dickstein. Deep Information Propagation. ICLR, April 2017. URL http://arxiv.org/abs/1611.01232. arXiv: 1611.01232. ",
1201
+ "bbox": [
1202
+ 173,
1203
+ 688,
1204
+ 825,
1205
+ 729
1206
+ ],
1207
+ "page_idx": 8
1208
+ },
1209
+ {
1210
+ "type": "text",
1211
+ "text": "Raquel Urtasun and Trevor Darrell. Sparse probabilistic regression for activity-independent human pose inference. CVPR, 2008. ",
1212
+ "bbox": [
1213
+ 171,
1214
+ 737,
1215
+ 823,
1216
+ 767
1217
+ ],
1218
+ "page_idx": 8
1219
+ },
1220
+ {
1221
+ "type": "text",
1222
+ "text": "Mark van der Wilk, Carl Edward Rasmussen, and James Hensman. Convolutional Gaussian Processes. In I. Guyon, U. V. Luxburg, S. Bengio, H. Wallach, R. Fergus, S. Vishwanathan, and R. Garnett, editors, Advances in Neural Information Processing Systems 30, pages 2849–2858. Curran Associates, Inc., 2017. URL http://papers.nips.cc/paper/ 6877-convolutional-gaussian-processes.pdf. ",
1223
+ "bbox": [
1224
+ 173,
1225
+ 775,
1226
+ 825,
1227
+ 845
1228
+ ],
1229
+ "page_idx": 8
1230
+ },
1231
+ {
1232
+ "type": "text",
1233
+ "text": "Christopher KI Williams and Carl Edward Rasmussen. Gaussian processes for machine learning, 2006. ",
1234
+ "bbox": [
1235
+ 171,
1236
+ 853,
1237
+ 823,
1238
+ 882
1239
+ ],
1240
+ "page_idx": 8
1241
+ },
1242
+ {
1243
+ "type": "text",
1244
+ "text": "Andrew Gordon Wilson, Zhiting Hu, Ruslan Salakhutdinov, and Eric P. Xing. Deep kernel learning. In Artificial Intelligence and Statistics, pages 370–378, 2016. ",
1245
+ "bbox": [
1246
+ 173,
1247
+ 890,
1248
+ 821,
1249
+ 920
1250
+ ],
1251
+ "page_idx": 8
1252
+ },
1253
+ {
1254
+ "type": "text",
1255
+ "text": "5 APPENDIX ",
1256
+ "text_level": 1,
1257
+ "bbox": [
1258
+ 174,
1259
+ 102,
1260
+ 294,
1261
+ 118
1262
+ ],
1263
+ "page_idx": 9
1264
+ },
1265
+ {
1266
+ "type": "text",
1267
+ "text": "Covariance Function at the Output of ReLU Neural Network ",
1268
+ "text_level": 1,
1269
+ "bbox": [
1270
+ 174,
1271
+ 132,
1272
+ 599,
1273
+ 148
1274
+ ],
1275
+ "page_idx": 9
1276
+ },
1277
+ {
1278
+ "type": "text",
1279
+ "text": "Our derivation follows the work on arc-cosine family of kernels developed in (Cho and Saul, 2009). However, instead of applying coplanar vector rotation in calculating the kernel integral, we recognize that the integrand can be written in terms of two jointly normal random variables. This helps to facilitate the computation which becomes more involved when both the weight and bias parameters are included. ",
1280
+ "bbox": [
1281
+ 173,
1282
+ 166,
1283
+ 825,
1284
+ 238
1285
+ ],
1286
+ "page_idx": 9
1287
+ },
1288
+ {
1289
+ "type": "text",
1290
+ "text": "The derivation is also made to conform to the arc-cosine kernel by utilizing the identities (Cho and Saul, 2009, equation (17), (18)) to give us ",
1291
+ "bbox": [
1292
+ 174,
1293
+ 257,
1294
+ 821,
1295
+ 286
1296
+ ],
1297
+ "page_idx": 9
1298
+ },
1299
+ {
1300
+ "type": "equation",
1301
+ "img_path": "images/8717ae93915195c4c0e66bce3da37576382b01851c823e233b6346e543dbf4f3.jpg",
1302
+ "text": "$$\n\\begin{array} { l } { { \\displaystyle { \\int _ { \\eta = 0 } ^ { \\frac { \\pi } { 2 } } \\frac { 1 } { 1 - \\cos \\phi \\cos \\eta } d \\eta = \\frac { \\pi - \\phi } { \\sin \\phi } } , } } \\\\ { { \\displaystyle { \\int _ { \\theta = 0 } ^ { \\frac { \\pi } { 2 } } \\frac { \\sin 2 \\theta } { \\left( 1 - \\cos \\phi \\sin 2 \\theta \\right) ^ { 2 } } d \\theta } } } \\\\ { { = \\displaystyle { \\frac { 1 } { \\sin ^ { 3 } \\phi } \\Big ( \\sin ( \\phi ) + ( \\pi - \\phi ) \\cos ( \\phi ) \\Big ) } . } } \\end{array}\n$$",
1303
+ "text_format": "latex",
1304
+ "bbox": [
1305
+ 372,
1306
+ 287,
1307
+ 625,
1308
+ 402
1309
+ ],
1310
+ "page_idx": 9
1311
+ },
1312
+ {
1313
+ "type": "text",
1314
+ "text": "Equation (4) is derived, with the substitution $\\eta = 2 ( \\theta - \\frac { \\pi } { 4 } )$ ) , as follow: ",
1315
+ "bbox": [
1316
+ 174,
1317
+ 410,
1318
+ 635,
1319
+ 434
1320
+ ],
1321
+ "page_idx": 9
1322
+ },
1323
+ {
1324
+ "type": "equation",
1325
+ "img_path": "images/c52d78d8e234ddc2b758599c368cb7ccac2a0bd8beaae29b118edf255ce23b01.jpg",
1326
+ "text": "$$\n\\begin{array} { r l } & { \\displaystyle \\int _ { \\theta = 0 } ^ { \\frac { \\pi } { 2 } } \\frac { \\sin 2 \\theta } { \\left( 1 - \\cos \\phi \\sin 2 \\theta \\right) ^ { 2 } } d \\theta } \\\\ & { = \\displaystyle \\int _ { \\eta = 0 } ^ { \\frac { \\pi } { 2 } } \\frac { \\cos \\eta } { \\left( 1 - \\cos \\phi \\cos \\eta \\right) ^ { 2 } } d \\eta } \\\\ & { = \\displaystyle \\frac { \\partial } { \\partial \\cos \\phi } \\int _ { \\eta = 0 } ^ { \\frac { \\pi } { 2 } } \\frac { 1 } { 1 - \\cos \\phi \\cos \\eta } d \\eta } \\\\ & { = \\displaystyle \\frac { \\partial } { \\partial \\cos \\phi } \\left( \\frac { \\pi - \\phi } { \\sin \\phi } \\right) = \\frac { - 1 } { \\sin ( \\phi ) } \\frac { \\partial } { \\partial \\phi } \\left( \\frac { \\pi - \\phi } { \\sin \\phi } \\right) } \\\\ & { = \\displaystyle \\frac { 1 } { \\sin ^ { 3 } \\phi } \\left( \\sin ( \\phi ) + ( \\pi - \\phi ) \\cos ( \\phi ) \\right) . } \\end{array}\n$$",
1327
+ "text_format": "latex",
1328
+ "bbox": [
1329
+ 339,
1330
+ 435,
1331
+ 656,
1332
+ 625
1333
+ ],
1334
+ "page_idx": 9
1335
+ },
1336
+ {
1337
+ "type": "text",
1338
+ "text": "Denote the input layer (layer 0) weight and bias parameters as $b _ { j } ^ { 0 } \\sim \\mathcal { N } ( 0 , \\sigma _ { b } ^ { 2 } )$ and $\\begin{array} { r } { W _ { j k } ^ { 0 } \\overset { \\mathrm { i i d } } { \\sim } \\mathcal { N } ( 0 , \\frac { \\sigma _ { w } ^ { 2 } } { d _ { i n } } ) } \\end{array}$ where $b _ { j } ^ { 0 } \\underline { { 1 } } \\perp W _ { j k } ^ { 0 }$ for all $k \\in \\{ 1 , \\cdots , d _ { i n } \\} , j \\in \\{ 1 , \\cdots , N _ { 1 } \\}$ . ",
1339
+ "bbox": [
1340
+ 173,
1341
+ 636,
1342
+ 821,
1343
+ 672
1344
+ ],
1345
+ "page_idx": 9
1346
+ },
1347
+ {
1348
+ "type": "text",
1349
+ "text": "The expected value of the product of post-activations at the output of the $j ^ { t h }$ hidden node is computed as ",
1350
+ "bbox": [
1351
+ 173,
1352
+ 689,
1353
+ 825,
1354
+ 719
1355
+ ],
1356
+ "page_idx": 9
1357
+ },
1358
+ {
1359
+ "type": "equation",
1360
+ "img_path": "images/4e24ed4b8b864e6a26952754e076b329028285d46d48d8fbfb7a5c347795b839.jpg",
1361
+ "text": "$$\n\\begin{array} { r l } & { E [ \\mathbf { X } _ { j } ( { x } ^ { 0 } ) \\mathbf { X } _ { j } ( { y } ^ { 0 } ) ] } \\\\ & { \\ = \\displaystyle \\int \\cdots \\int _ { - \\infty } ^ { \\infty } \\operatorname* { m a x } ( b _ { j } ^ { 0 } + w _ { j } ^ { 0 } \\cdot { x } ^ { 0 } ) \\operatorname* { m a x } ( b _ { j } ^ { 0 } + w _ { j } ^ { 0 } \\cdot { y } ^ { 0 } ) f _ { b _ { j } ^ { 0 } , W _ { j } ^ { 0 } } ( b , w ) d w _ { j } ^ { 0 } d b _ { j } ^ { 0 } } \\\\ & { \\ = \\displaystyle \\int \\cdots \\int _ { - \\infty } ^ { \\infty } ( b _ { j } ^ { 0 } + w _ { j } ^ { 0 } \\cdot { x } ^ { 0 } ) _ { + } ( b _ { j } ^ { 0 } + w _ { j } ^ { 0 } \\cdot { y } ^ { 0 } ) _ { + } f _ { b _ { j } ^ { 0 } , W _ { j } ^ { 0 } } ( b , w ) d w _ { j } ^ { 0 } d b } \\end{array}\n$$",
1362
+ "text_format": "latex",
1363
+ "bbox": [
1364
+ 250,
1365
+ 717,
1366
+ 746,
1367
+ 810
1368
+ ],
1369
+ "page_idx": 9
1370
+ },
1371
+ {
1372
+ "type": "text",
1373
+ "text": "Each pre-activation can be written in terms of a random variable: ",
1374
+ "bbox": [
1375
+ 171,
1376
+ 818,
1377
+ 599,
1378
+ 833
1379
+ ],
1380
+ "page_idx": 9
1381
+ },
1382
+ {
1383
+ "type": "equation",
1384
+ "img_path": "images/518a8cae508fb5de3d84f9debfea9299a9372242e4ecf26f2dc197729ff19367.jpg",
1385
+ "text": "$$\n\\begin{array} { l } { { U = b _ { j } ^ { 0 } + W _ { j } ^ { 0 } \\cdot x ^ { 0 } = b _ { j } ^ { 0 } + \\displaystyle \\sum _ { k = 1 } ^ { d _ { i n } } W _ { j k } ^ { 0 } x _ { k } ^ { 0 } \\sim \\mathcal N ( 0 , \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\| x \\| ^ { 2 } ) , } } \\\\ { { \\displaystyle V = b _ { j } ^ { 0 } + W _ { j } ^ { 0 } \\cdot y ^ { 0 } = b _ { j } ^ { 0 } + \\displaystyle \\sum _ { k ^ { \\prime } = 1 } ^ { d _ { i n } } W _ { j k ^ { \\prime } } ^ { 0 } y _ { k ^ { \\prime } } ^ { 0 } \\sim \\mathcal N ( 0 , \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\| y \\| ^ { 2 } ) . } } \\end{array}\n$$",
1386
+ "text_format": "latex",
1387
+ "bbox": [
1388
+ 284,
1389
+ 834,
1390
+ 710,
1391
+ 924
1392
+ ],
1393
+ "page_idx": 9
1394
+ },
1395
+ {
1396
+ "type": "text",
1397
+ "text": "Since $E [ U ] = E [ V ] = 0$ , their covariance can be expressed as ",
1398
+ "bbox": [
1399
+ 173,
1400
+ 102,
1401
+ 583,
1402
+ 119
1403
+ ],
1404
+ "page_idx": 10
1405
+ },
1406
+ {
1407
+ "type": "equation",
1408
+ "img_path": "images/257a66b82b5d18bb4eabdb5d8cf7ac93ab837548397b6f318b6df57105eb2da0.jpg",
1409
+ "text": "$$\n\\begin{array} { l } { { \\displaystyle \\mathrm { c o v } ( U , V ) = E \\big [ ( b _ { j } ^ { 0 } + W _ { j } ^ { 0 } \\cdot x ^ { 0 } ) ( b _ { j } ^ { 0 } + W _ { j } ^ { 0 } \\cdot y ^ { 0 } ) \\big ] } } \\\\ { { \\displaystyle = E \\big [ ( b _ { j } ^ { 0 } ) ^ { 2 } \\big ] + E \\bigg [ \\displaystyle \\sum _ { k = 1 } ^ { d _ { i n } } \\sum _ { k ^ { \\prime } = 1 } ^ { d _ { i n } } W _ { j k } ^ { 0 } W _ { j k ^ { \\prime } } ^ { 0 } x _ { k } ^ { 0 } y _ { k ^ { \\prime } } ^ { 0 } \\bigg ] } } \\\\ { { \\displaystyle = \\sigma _ { b } ^ { 2 } + \\displaystyle \\sum _ { k = 1 } ^ { d _ { i n } } \\sum _ { k ^ { \\prime } = 1 } ^ { d _ { i n } } E \\Big [ W _ { j k } ^ { 0 } W _ { j k ^ { \\prime } } ^ { 0 } \\Big ] x _ { k } ^ { 0 } y _ { k ^ { \\prime } } ^ { 0 } } } \\\\ { { \\displaystyle = \\sigma _ { b } ^ { 2 } + \\sigma _ { b } ^ { 2 } \\sum _ { k = 1 } ^ { d _ { i n } } x _ { k } ^ { 0 } y _ { k } ^ { 0 } } } \\\\ { { \\displaystyle = \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } ( x \\cdot y ) ~ } } \\\\ { { \\displaystyle = \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } ( x \\cdot y ) ~ \\mathrm { ( F o r ~ s i m p l i c i t y ~ w e ~ s e t ~ } x ^ { 0 } , y = y ^ { 0 } ) } } \\end{array}\n$$",
1410
+ "text_format": "latex",
1411
+ "bbox": [
1412
+ 295,
1413
+ 126,
1414
+ 699,
1415
+ 301
1416
+ ],
1417
+ "page_idx": 10
1418
+ },
1419
+ {
1420
+ "type": "text",
1421
+ "text": "This implies that the random variables $U , V$ have a joint Gaussian distribution: ",
1422
+ "bbox": [
1423
+ 174,
1424
+ 313,
1425
+ 689,
1426
+ 329
1427
+ ],
1428
+ "page_idx": 10
1429
+ },
1430
+ {
1431
+ "type": "equation",
1432
+ "img_path": "images/0bb0159e32817ed7a2d8140c0bb5bb548aa6fac8f247520a8abc6a6b328e22e7.jpg",
1433
+ "text": "$$\n\\begin{array}{c} \\binom { U } { V } \\sim { \\mathcal N } ( 0 , \\Sigma ) , \\mathrm { w h e r e } \\Sigma = \\left( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\lVert x \\rVert ^ { 2 } \\right. \\left. \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } ( x \\cdot y ) \\right) \\\\ { \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } ( x \\cdot y ) \\ \\left. \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\lVert y \\rVert ^ { 2 } . \\right) } \\end{array}\n$$",
1434
+ "text_format": "latex",
1435
+ "bbox": [
1436
+ 276,
1437
+ 335,
1438
+ 720,
1439
+ 371
1440
+ ],
1441
+ "page_idx": 10
1442
+ },
1443
+ {
1444
+ "type": "text",
1445
+ "text": "We can, therefore, rewrite equation (5) as ",
1446
+ "bbox": [
1447
+ 174,
1448
+ 383,
1449
+ 446,
1450
+ 398
1451
+ ],
1452
+ "page_idx": 10
1453
+ },
1454
+ {
1455
+ "type": "equation",
1456
+ "img_path": "images/11220e091857a38672dad44d4943ea666e3d4240be1b3605455b31f622ec8933.jpg",
1457
+ "text": "$$\n\\iint _ { 0 } ^ { \\infty } u v \\frac { 1 } { 2 \\pi | \\Sigma | ^ { \\frac { 1 } { 2 } } } \\exp \\big ( - \\frac { 1 } { 2 } ( u , v ) \\Sigma ^ { - 1 } ( u , v ) ^ { T } \\big ) d u d v\n$$",
1458
+ "text_format": "latex",
1459
+ "bbox": [
1460
+ 321,
1461
+ 406,
1462
+ 676,
1463
+ 441
1464
+ ],
1465
+ "page_idx": 10
1466
+ },
1467
+ {
1468
+ "type": "text",
1469
+ "text": "Denote $D : = | \\Sigma | = \\left( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\| x \\| ^ { 2 } \\right) \\left( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\| y \\| ^ { 2 } \\right) - \\left( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } ( x \\cdot y ) \\right) ^ { 2 }$ , and ",
1470
+ "bbox": [
1471
+ 173,
1472
+ 457,
1473
+ 692,
1474
+ 478
1475
+ ],
1476
+ "page_idx": 10
1477
+ },
1478
+ {
1479
+ "type": "equation",
1480
+ "img_path": "images/b393b8957d55798301151ddb289b1fbfded3d749354401ccdb4fac7639b19d0c.jpg",
1481
+ "text": "$$\n\\Sigma ^ { - 1 } = { \\binom { a _ { 1 1 } } { a _ { 2 1 } } } a _ { 2 2 } ) ,\n$$",
1482
+ "text_format": "latex",
1483
+ "bbox": [
1484
+ 424,
1485
+ 483,
1486
+ 570,
1487
+ 518
1488
+ ],
1489
+ "page_idx": 10
1490
+ },
1491
+ {
1492
+ "type": "text",
1493
+ "text": "with $\\begin{array} { l } { \\displaystyle { a _ { 1 1 } = \\frac { 1 } { D } \\big ( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\| y \\| ^ { 2 } \\big ) , a _ { 2 2 } = \\frac { 1 } { D } \\big ( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\| x \\| ^ { 2 } \\big ) , } } \\\\ { \\displaystyle { = a _ { 2 1 } = \\frac { - 1 } { D } \\big ( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } ( x \\cdot y ) \\big ) . } } \\end{array}$ and ",
1494
+ "bbox": [
1495
+ 171,
1496
+ 532,
1497
+ 584,
1498
+ 589
1499
+ ],
1500
+ "page_idx": 10
1501
+ },
1502
+ {
1503
+ "type": "text",
1504
+ "text": "We therefore have: ",
1505
+ "bbox": [
1506
+ 174,
1507
+ 602,
1508
+ 299,
1509
+ 617
1510
+ ],
1511
+ "page_idx": 10
1512
+ },
1513
+ {
1514
+ "type": "equation",
1515
+ "img_path": "images/08380f5a317715b5cbc167a9f43ab5f183296d5b639b8cf70741f2443aecaff0.jpg",
1516
+ "text": "$$\n\\begin{array} { l } { { \\displaystyle { D \\big ( a _ { 1 1 } a _ { 2 2 } - a _ { 1 2 } ^ { 2 } \\big ) = D \\Big ( \\frac { 1 } { D } \\big ( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\| y \\| ^ { 2 } \\big ) \\frac { 1 } { D } \\big ( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\| x \\| ^ { 2 } \\big ) - \\big ( \\frac { - 1 } { D } \\big ( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\big ( x \\cdot y \\big ) \\big ) ^ { 2 } \\Big ) } } } \\\\ { { \\displaystyle \\qquad = \\frac { 1 } { D } \\Big ( \\big ( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\| x \\| ^ { 2 } \\big ) \\big ( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\| y \\| ^ { 2 } \\big ) - \\big ( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\big ( x \\cdot y \\big ) \\big ) ^ { 2 } \\Big ) } } \\\\ { { \\displaystyle \\qquad = 1 . \\quad \\quad \\mathrm { ( b y ~ d e f i n i t i o n ) } } } \\end{array}\n$$",
1517
+ "text_format": "latex",
1518
+ "bbox": [
1519
+ 204,
1520
+ 621,
1521
+ 792,
1522
+ 702
1523
+ ],
1524
+ "page_idx": 10
1525
+ },
1526
+ {
1527
+ "type": "text",
1528
+ "text": "The exponential term in equation (6) then becomes: ",
1529
+ "bbox": [
1530
+ 173,
1531
+ 714,
1532
+ 514,
1533
+ 729
1534
+ ],
1535
+ "page_idx": 10
1536
+ },
1537
+ {
1538
+ "type": "equation",
1539
+ "img_path": "images/48405f9d0680ec756e79913a18b9dbb4b95945b3add480a982cf691c39a836b2.jpg",
1540
+ "text": "$$\n- \\frac { 1 } { 2 } ( u , v ) \\Sigma ^ { - 1 } ( u , v ) ^ { T } = - \\frac { 1 } { 2 } \\big ( a _ { 1 1 } u ^ { 2 } + 2 a _ { 1 2 } u v + a _ { 2 2 } v ^ { 2 } \\big ) .\n$$",
1541
+ "text_format": "latex",
1542
+ "bbox": [
1543
+ 308,
1544
+ 736,
1545
+ 689,
1546
+ 766
1547
+ ],
1548
+ "page_idx": 10
1549
+ },
1550
+ {
1551
+ "type": "text",
1552
+ "text": "We now make use of the transformation from Cartesian to polar coordinates by setting ",
1553
+ "bbox": [
1554
+ 174,
1555
+ 780,
1556
+ 738,
1557
+ 795
1558
+ ],
1559
+ "page_idx": 10
1560
+ },
1561
+ {
1562
+ "type": "equation",
1563
+ "img_path": "images/9048d266bffaf5d877e1930a6d85e80036aac61524dba93b1cdb9d87219498ff.jpg",
1564
+ "text": "$$\n{ \\begin{array} { r l } & { u = { \\frac { r } { \\sqrt { a _ { 1 1 } } } } \\cos \\alpha , v = { \\frac { r } { \\sqrt { a _ { 2 2 } } } } \\sin \\alpha } \\\\ & { \\qquad \\implies a _ { 1 1 } u ^ { 2 } = r ^ { 2 } { \\cos ^ { 2 } } \\alpha , a _ { 2 2 } v ^ { 2 } = r ^ { 2 } { \\sin ^ { 2 } } \\alpha . } \\end{array} }\n$$",
1565
+ "text_format": "latex",
1566
+ "bbox": [
1567
+ 352,
1568
+ 800,
1569
+ 643,
1570
+ 853
1571
+ ],
1572
+ "page_idx": 10
1573
+ },
1574
+ {
1575
+ "type": "text",
1576
+ "text": "The Jacobian $\\mathcal { I }$ is calculated as ",
1577
+ "bbox": [
1578
+ 174,
1579
+ 867,
1580
+ 385,
1581
+ 881
1582
+ ],
1583
+ "page_idx": 10
1584
+ },
1585
+ {
1586
+ "type": "equation",
1587
+ "img_path": "images/92145cf4d9bf1e4b43526a735a70c7f9dddb2fac3e0e2dc857e2985535c63734.jpg",
1588
+ "text": "$$\n\\big | \\frac { \\partial ( u , v ) } { \\partial ( r , \\alpha ) } \\big | = \\frac { r } { \\sqrt { a _ { 1 1 } a _ { 2 2 } } } .\n$$",
1589
+ "text_format": "latex",
1590
+ "bbox": [
1591
+ 421,
1592
+ 887,
1593
+ 576,
1594
+ 922
1595
+ ],
1596
+ "page_idx": 10
1597
+ },
1598
+ {
1599
+ "type": "text",
1600
+ "text": "Equation (6) can in turn be expressed as ",
1601
+ "bbox": [
1602
+ 173,
1603
+ 103,
1604
+ 437,
1605
+ 119
1606
+ ],
1607
+ "page_idx": 11
1608
+ },
1609
+ {
1610
+ "type": "equation",
1611
+ "img_path": "images/f36d6e562669729fab6fd7fcd8fd1c936f286f57364a254c72421aab1c6db38b.jpg",
1612
+ "text": "$$\n\\begin{array} { r l } & { \\frac { 1 } { 2 \\pi D ^ { 1 / 2 } } \\int _ { \\alpha = 0 } ^ { \\frac { \\pi } { 2 } } \\int _ { r = 0 } ^ { \\infty } \\frac { r ^ { 2 } \\sin 2 \\alpha } { 2 \\sqrt { a _ { 1 1 } a _ { 2 2 } } } \\mathrm { e x p } \\Big ( \\frac { - 1 } { 2 } [ r ^ { 2 } \\cos ^ { 2 } \\alpha + \\frac { 2 a _ { 1 2 } r ^ { 2 } \\sin \\alpha \\cos \\alpha } { \\sqrt { a _ { 1 1 } a _ { 2 2 } } } + r ^ { 2 } \\sin ^ { 2 } \\alpha ] \\Big ) \\frac { r d r d \\alpha } { \\sqrt { a _ { 1 1 } a _ { 2 2 } } } } \\\\ & { = \\frac { 1 } { 4 \\pi D ^ { 1 / 2 } a _ { 1 1 } a _ { 2 2 } } \\int _ { \\alpha = 0 } ^ { \\frac { \\pi } { 2 } } \\sin 2 \\alpha d \\alpha \\int _ { r = 0 } ^ { \\infty } r ^ { 3 } \\mathrm { e x p } \\Big ( \\frac { - r ^ { 2 } } { 2 } [ 1 + \\frac { a _ { 1 2 } \\sin 2 \\alpha } { \\sqrt { a _ { 1 1 } a _ { 2 2 } } } ] \\Big ) d r \\qquad \\quad ( \\cot 2 ) } \\end{array}\n$$",
1613
+ "text_format": "latex",
1614
+ "bbox": [
1615
+ 187,
1616
+ 126,
1617
+ 808,
1618
+ 204
1619
+ ],
1620
+ "page_idx": 11
1621
+ },
1622
+ {
1623
+ "type": "text",
1624
+ "text": "Next, we need to show that $\\mathcal { H } : = 1 + \\frac { a _ { \\mathrm { 1 2 } } \\sin 2 \\alpha } { \\sqrt { a _ { \\mathrm { 1 1 } } a _ { \\mathrm { 2 2 } } } } \\ge 0$ to ensure the expression in (8) is bounded. ",
1625
+ "bbox": [
1626
+ 174,
1627
+ 217,
1628
+ 803,
1629
+ 251
1630
+ ],
1631
+ "page_idx": 11
1632
+ },
1633
+ {
1634
+ "type": "text",
1635
+ "text": "First, since $\\| x - y \\| ^ { 2 } = \\| x \\| ^ { 2 } + \\| y \\| ^ { 2 } - 2 ( x \\cdot y ) \\geq 0 \\implies \\| x \\| ^ { 2 } + \\| y \\| ^ { 2 } \\geq 2 ( x \\cdot y )$ , and let the angle between the vectors $x , y$ be $\\theta = \\cos ^ { - 1 } \\Bigl ( \\frac { x \\cdot y } { \\| x \\| \\| y \\| } \\Bigr )$ , we have ",
1636
+ "bbox": [
1637
+ 173,
1638
+ 258,
1639
+ 823,
1640
+ 304
1641
+ ],
1642
+ "page_idx": 11
1643
+ },
1644
+ {
1645
+ "type": "equation",
1646
+ "img_path": "images/52390d6263d9b544260463db95fa41791cc3a568617952fb6d7be907033a44e6.jpg",
1647
+ "text": "$$\n\\begin{array} { r l } & { \\frac { \\Big ( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } ( x \\cdot y ) \\Big ) ^ { 2 } } { \\Big ( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\| x \\| ^ { 2 } \\Big ) \\Big ( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\| y \\| ^ { 2 } \\Big ) } } \\\\ & { = \\frac { \\sigma _ { b } ^ { 4 } + ( \\sigma _ { w } ^ { 2 } ) ^ { 2 } ( x \\cdot y ) ^ { 2 } + 2 \\sigma _ { b } ^ { 2 } ( \\sigma _ { w } ^ { 2 } ) ( x \\cdot y ) } { \\sigma _ { b } ^ { 4 } + ( \\sigma _ { w } ^ { 2 } ) ^ { 2 } \\left( \\| x \\| ^ { 2 } \\| y \\| ^ { 2 } \\right) + \\sigma _ { b } ^ { 2 } ( \\sigma _ { w } ^ { 2 } ) \\left( \\| x \\| ^ { 2 } + \\| y \\| ^ { 2 } \\right) } } \\\\ & { = \\frac { \\sigma _ { b } ^ { 4 } + ( \\sigma _ { w } ^ { 2 } ) ^ { 2 } ( \\| x \\| \\| y \\| \\cos \\theta ) ^ { 2 } + \\sigma _ { b } ^ { 2 } ( \\sigma _ { w } ^ { 2 } ) 2 ( x \\cdot y ) } { \\sigma _ { b } ^ { 4 } + ( \\sigma _ { w } ^ { 2 } ) ^ { 2 } \\left( \\| x \\| ^ { 2 } \\| y \\| ^ { 2 } \\right) + \\sigma _ { b } ^ { 2 } ( \\sigma _ { w } ^ { 2 } ) \\left( \\| x \\| ^ { 2 } + \\| y \\| ^ { 2 } \\right) } } \\\\ & { < 1 . } \\end{array}\n$$",
1648
+ "text_format": "latex",
1649
+ "bbox": [
1650
+ 320,
1651
+ 310,
1652
+ 676,
1653
+ 462
1654
+ ],
1655
+ "page_idx": 11
1656
+ },
1657
+ {
1658
+ "type": "text",
1659
+ "text": "This means that we can define a quantity $\\phi$ as ",
1660
+ "bbox": [
1661
+ 176,
1662
+ 476,
1663
+ 473,
1664
+ 491
1665
+ ],
1666
+ "page_idx": 11
1667
+ },
1668
+ {
1669
+ "type": "equation",
1670
+ "img_path": "images/02ea0eb22d123156d48ca8c67fd2884bf086031af126e9f7a6c268257eddaa96.jpg",
1671
+ "text": "$$\n\\begin{array} { l } { \\displaystyle \\phi = \\cos ^ { - 1 } \\frac { \\left( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } ( x \\cdot y ) \\right) } { \\left( \\left( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\| x \\| ^ { 2 } \\right) \\left( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\| y \\| ^ { 2 } \\right) \\right) ^ { 1 / 2 } } } \\\\ { \\displaystyle = \\cos ^ { - 1 } \\frac { \\frac { 1 } { D } \\left( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } ( x \\cdot y ) \\right) } { \\frac { 1 } { D } \\left( \\left( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\| x \\| ^ { 2 } \\right) \\left( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\| y \\| ^ { 2 } \\right) \\right) } } \\\\ { = \\cos ^ { - 1 } \\Big ( \\frac { - a _ { 1 2 } } { \\sqrt { u _ { 1 } u _ { 2 2 } } } \\Big ) } \\\\ { \\displaystyle \\implies \\cos \\phi = \\left( \\frac { - a _ { 1 2 } } { \\sqrt { u _ { 1 } u _ { 2 2 } } } \\right) } \\end{array}\n$$",
1672
+ "text_format": "latex",
1673
+ "bbox": [
1674
+ 336,
1675
+ 500,
1676
+ 658,
1677
+ 676
1678
+ ],
1679
+ "page_idx": 11
1680
+ },
1681
+ {
1682
+ "type": "text",
1683
+ "text": "This also leads to ",
1684
+ "bbox": [
1685
+ 173,
1686
+ 690,
1687
+ 290,
1688
+ 704
1689
+ ],
1690
+ "page_idx": 11
1691
+ },
1692
+ {
1693
+ "type": "equation",
1694
+ "img_path": "images/120363013df7875092c120d4bd70f056cb7e2712fddfd6f5b12712fc5f63e7dd.jpg",
1695
+ "text": "$$\n\\begin{array} { l } { \\mathcal { H } : = 1 + \\frac { a _ { 1 2 } \\sin 2 \\alpha } { \\sqrt { a _ { 1 } \\sin 2 \\alpha } } } \\\\ { \\displaystyle = 1 + \\frac { \\frac { - 1 } { D } \\left( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } ( x \\cdot y ) \\right) \\sin 2 \\alpha } { \\frac { 1 } { D } \\left( ( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } | x | ^ { 2 } ) \\left( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } | y | | y | ^ { 2 } \\right) \\right) } } \\\\ { \\displaystyle = 1 - \\frac { ( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } ( x \\cdot y ) ) \\sin 2 \\alpha } { \\left( ( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } | x | ^ { 2 } ) ( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } | y | | y | ^ { 2 } ) \\right) ^ { 1 / 2 } } } \\\\ { \\geq 1 - \\frac { \\left( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } ( x \\cdot y ) \\right) } { \\left( ( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } | x | ^ { 2 } ) ( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } | y | | y | ^ { 2 } ) \\right) ^ { 1 / 2 } } } \\\\ { \\displaystyle \\geq 0 \\ \\frac { 1 } { 8 } \\left( ( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } | x | ^ { 2 } ) ( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } | y | | y | ^ { 2 } ) \\right) ^ { 1 / 2 } } \\end{array}\n$$",
1696
+ "text_format": "latex",
1697
+ "bbox": [
1698
+ 339,
1699
+ 710,
1700
+ 656,
1701
+ 921
1702
+ ],
1703
+ "page_idx": 11
1704
+ },
1705
+ {
1706
+ "type": "text",
1707
+ "text": "With a change of variables, we now evaluate the integral involving the parameter $r$ in expression (8) as follows. ",
1708
+ "bbox": [
1709
+ 168,
1710
+ 103,
1711
+ 825,
1712
+ 133
1713
+ ],
1714
+ "page_idx": 12
1715
+ },
1716
+ {
1717
+ "type": "text",
1718
+ "text": "Let $\\eta = \\frac { r ^ { 2 } } { 2 } \\mathcal { H }$ . Then $r = \\sqrt { \\frac { 2 \\eta } { \\mathcal { H } } } \\implies d r = \\frac { 1 } { 2 } \\sqrt { \\frac { 2 } { \\mathcal { H } } } \\eta ^ { - 1 / 2 } d \\eta .$ −1/2 d η. We have ",
1719
+ "bbox": [
1720
+ 171,
1721
+ 147,
1722
+ 637,
1723
+ 184
1724
+ ],
1725
+ "page_idx": 12
1726
+ },
1727
+ {
1728
+ "type": "equation",
1729
+ "img_path": "images/47291e0704a1cf4f5e88e7d1f874338702a49b45f4813c3515d1f49fcc538975.jpg",
1730
+ "text": "$$\n\\begin{array} { r l } & { \\int _ { n = 0 } ^ { \\infty } \\left( \\frac { 2 } { \\mathcal { H } } \\right) ^ { \\frac { 2 } { 3 } } \\eta ^ { \\frac { 2 } { 2 } } \\hat { \\mathbf { z } } ^ { - \\nu } \\frac { 1 } { 2 } \\sqrt { \\frac { 2 } { \\mathcal { H } } \\eta ^ { \\frac { 2 } { 2 } } } \\vec { \\mathbf { z } } ^ { \\frac { 1 } { 2 } } \\ d \\eta } \\\\ & { = \\int _ { n = 0 } ^ { \\infty } \\frac { 2 2 } { \\mathcal { H } ^ { 2 } } \\frac { 1 } { 2 } \\mathbf { z } ^ { \\nu - \\nu } \\ d \\eta } \\\\ & { = \\frac { 2 } { \\mathcal { H } ^ { 2 } } \\int _ { n = 0 } ^ { \\infty } \\eta \\ c ^ { - \\nu } d \\eta } \\\\ & { = \\frac { 2 } { \\mathcal { H } ^ { 2 } } \\mathbf { z } ^ { \\nu } [ ( 2 ) = \\frac { 2 } { \\mathcal { H } ^ { 2 } } } \\\\ & { = \\frac { 2 } { \\left( 1 + \\frac { \\operatorname { d r } _ { 1 } \\sqrt { \\operatorname { d r } _ { 1 } \\log 2 } } { \\sqrt { \\operatorname { d r } _ { 1 } \\log 2 } } \\right) ^ { 2 } } } \\\\ & { = \\frac { 2 } { \\left( 1 - \\frac { 2 } { \\sqrt { \\operatorname { d r } _ { 1 } \\operatorname { d r } _ { 2 } \\mathcal { H } } } \\right) ^ { 2 } } . \\quad \\mathrm { ( f r o m ~ e q u a t i o n ~ \\mathcal { O } ) } \\big ) } \\end{array}\n$$",
1731
+ "text_format": "latex",
1732
+ "bbox": [
1733
+ 334,
1734
+ 190,
1735
+ 658,
1736
+ 426
1737
+ ],
1738
+ "page_idx": 12
1739
+ },
1740
+ {
1741
+ "type": "text",
1742
+ "text": "The complete expression (8) becomes ",
1743
+ "bbox": [
1744
+ 174,
1745
+ 435,
1746
+ 424,
1747
+ 450
1748
+ ],
1749
+ "page_idx": 12
1750
+ },
1751
+ {
1752
+ "type": "equation",
1753
+ "img_path": "images/a2892122fc6f9e22d7c370cc67c07b07046ae1c5fd38d41c9bb258fffa654171.jpg",
1754
+ "text": "$$\n\\begin{array} { r l } & { \\frac { 1 } { 4 \\pi D ^ { 1 / 2 } a _ { 1 1 } a _ { 2 2 } } \\displaystyle \\int _ { \\alpha = 0 } ^ { \\frac { \\pi } { 2 } } \\frac { 2 \\sin 2 \\alpha } { \\left( 1 - \\cos \\phi \\sin 2 \\alpha \\right) ^ { 2 } } d \\alpha } \\\\ & { = \\frac { 1 } { 2 \\pi D ^ { 1 / 2 } a _ { 1 1 } a _ { 2 2 } \\sin ^ { 3 } \\phi } \\Big ( \\sin ( \\phi ) + ( \\pi - \\phi ) \\cos ( \\phi ) \\Big ) . \\quad \\mathrm { ( f r o m ~ e q u a t i o n ~ ( 4 ) ) } } \\end{array}\n$$",
1755
+ "text_format": "latex",
1756
+ "bbox": [
1757
+ 243,
1758
+ 454,
1759
+ 754,
1760
+ 539
1761
+ ],
1762
+ "page_idx": 12
1763
+ },
1764
+ {
1765
+ "type": "text",
1766
+ "text": "where $\\phi = \\cos ^ { - 1 } \\Big ( \\frac { - a _ { 1 2 } } { \\sqrt { a _ { 1 1 } a _ { 2 2 } } } \\Big )$ ",
1767
+ "bbox": [
1768
+ 174,
1769
+ 550,
1770
+ 377,
1771
+ 580
1772
+ ],
1773
+ "page_idx": 12
1774
+ },
1775
+ {
1776
+ "type": "text",
1777
+ "text": "Finally, ",
1778
+ "bbox": [
1779
+ 173,
1780
+ 585,
1781
+ 225,
1782
+ 601
1783
+ ],
1784
+ "page_idx": 12
1785
+ },
1786
+ {
1787
+ "type": "equation",
1788
+ "img_path": "images/2cebcfcf980b16f64cbe77ac484019628382f6513004138da763eac3c94738cb.jpg",
1789
+ "text": "$$\n\\begin{array} { r l } & { 2 \\pi \\mathcal { D } ^ { 1 / 2 } a _ { 1 1 } a _ { 2 2 } \\sin ^ { 3 } \\phi } \\\\ & { = 2 \\pi \\mathcal { D } ^ { 1 / 2 } a _ { 1 1 } a _ { 2 2 } \\left( 1 - \\cos ^ { 2 } \\phi \\right) ^ { 3 / 2 } } \\\\ & { = 2 \\pi \\mathcal { D } ^ { 1 / 2 } a _ { 1 1 } a _ { 2 2 } \\left( 1 - \\frac { a _ { 1 2 } ^ { 2 } } { a _ { 1 1 } a _ { 2 2 } } \\right) ^ { 3 / 2 } } \\\\ & { = 2 \\pi \\mathcal { D } ^ { 1 / 2 } \\Big ( a _ { 1 1 } a _ { 2 2 } \\Big ) ^ { - 1 / 2 } \\Big ( a _ { 1 1 } a _ { 2 2 } - a _ { 1 2 } ^ { 2 } \\Big ) ^ { 3 / 2 } } \\\\ & { = 2 \\pi \\Big ( \\mathcal { D } ^ { 2 } a _ { 1 1 } a _ { 2 2 } \\Big ) ^ { - 1 / 2 } \\Big ( \\mathcal { D } \\big ( a _ { 1 1 } a _ { 2 2 } - a _ { 1 2 } ^ { 2 } \\big ) \\Big ) ^ { 3 / 2 } } \\\\ & { = 2 \\pi \\Big ( \\big ( o _ { b } ^ { 2 } + o _ { w } ^ { 2 } \\| x \\| ^ { 2 } \\big ) \\big ( o _ { b } ^ { 2 } + o _ { w } ^ { 2 } \\| y \\| ^ { 2 } \\big ) \\Big ) ^ { - 1 / 2 } \\Big ( 1 \\Big ) ^ { 3 / 2 } \\quad \\mathrm { ( f r o m e q u a t i o n ~ ( 7 ) ) } } \\end{array}\n$$",
1790
+ "text_format": "latex",
1791
+ "bbox": [
1792
+ 243,
1793
+ 604,
1794
+ 751,
1795
+ 776
1796
+ ],
1797
+ "page_idx": 12
1798
+ },
1799
+ {
1800
+ "type": "text",
1801
+ "text": "The expected value of the product of post-activations at the output of the $j ^ { t h }$ hidden node in the first hidden layer is therefore determined to be ",
1802
+ "bbox": [
1803
+ 173,
1804
+ 786,
1805
+ 823,
1806
+ 815
1807
+ ],
1808
+ "page_idx": 12
1809
+ },
1810
+ {
1811
+ "type": "equation",
1812
+ "img_path": "images/031826bbac0084d058bc9a188229683b04d8b425cba05fda108733cd8d8ce5fd.jpg",
1813
+ "text": "$$\n\\begin{array} { r l } & { E [ { \\bf X } _ { j } ( x ) { \\bf X } _ { j } ( y ) ] } \\\\ & { = \\displaystyle \\frac { 1 } { 2 \\pi } \\Big ( \\big ( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\| x \\| ^ { 2 } \\big ) \\big ( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\| y \\| ^ { 2 } \\big ) \\Big ) ^ { 1 / 2 } \\Big ( \\sin ( \\phi ) + \\big ( \\pi - \\phi \\big ) \\cos ( \\phi ) \\Big ) , } \\\\ & { \\mathrm { w h e r e \\ } \\phi = \\cos ^ { - 1 } \\Bigg \\{ \\frac { \\big ( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } ( x \\cdot y ) \\big ) } { \\Big ( \\big ( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\| x \\| ^ { 2 } \\big ) \\big ( \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\| y \\| ^ { 2 } \\big ) \\Big ) ^ { 1 / 2 } } \\Bigg \\} . } \\end{array}\n$$",
1814
+ "text_format": "latex",
1815
+ "bbox": [
1816
+ 253,
1817
+ 819,
1818
+ 741,
1819
+ 924
1820
+ ],
1821
+ "page_idx": 12
1822
+ },
1823
+ {
1824
+ "type": "text",
1825
+ "text": "To compute the expected value, $\\begin{array} { r } { E [ \\mathbf { X } _ { j } ( x ) ] \\ = \\ \\int \\operatorname* { m a x } ( b + w \\cdot x ) f _ { b _ { j } ^ { 0 } , W _ { j k } ^ { 0 } } ( b , w ) d w d b } \\end{array}$ , we denote $U = b + w \\cdot x \\sim N ( 0 , \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\| x \\| ^ { 2 } )$ , and apply the change in variables: ${ \\frac { 1 } { 2 \\sigma ^ { 2 } } } u ^ { 2 } = t$ , where $\\sigma ^ { 2 } = $ $\\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\lVert x \\rVert ^ { 2 }$ to obtain ",
1826
+ "bbox": [
1827
+ 171,
1828
+ 102,
1829
+ 826,
1830
+ 165
1831
+ ],
1832
+ "page_idx": 13
1833
+ },
1834
+ {
1835
+ "type": "equation",
1836
+ "img_path": "images/d5ba2c14dfdf0efed6f8b8e9b24931a0b8ecb62f7e0dc6d22247dc06c80ca746.jpg",
1837
+ "text": "$$\n\\begin{array} { l } { \\displaystyle E [ \\mathbf { X } _ { j } ( x ) ] = \\int _ { - \\infty } ^ { \\infty } \\left( u \\right) + f _ { U } ( u ) d u } \\\\ { \\displaystyle = \\int _ { 0 } ^ { \\infty } u \\frac { 1 } { \\sqrt { 2 \\pi } \\sigma } e ^ { - \\frac { 1 } { 2 \\sigma ^ { 2 } } u ^ { 2 } } d u } \\\\ { \\displaystyle = \\int _ { 0 } ^ { \\infty } \\sigma ^ { 2 } d t \\frac { 1 } { \\sqrt { 2 \\pi } \\sigma } e ^ { - t } } \\\\ { \\displaystyle = \\frac { \\sigma } { \\sqrt { 2 \\pi } } } \\\\ { \\displaystyle = \\frac { \\sqrt { \\sigma _ { b } ^ { 2 } } + \\sigma _ { w } ^ { 2 } \\| x \\| ^ { 2 } } { \\sqrt { 2 \\pi } } } \\end{array}\n$$",
1838
+ "text_format": "latex",
1839
+ "bbox": [
1840
+ 370,
1841
+ 170,
1842
+ 629,
1843
+ 344
1844
+ ],
1845
+ "page_idx": 13
1846
+ },
1847
+ {
1848
+ "type": "text",
1849
+ "text": "The covariance function at the network output is therefore determined to be ",
1850
+ "bbox": [
1851
+ 173,
1852
+ 356,
1853
+ 669,
1854
+ 371
1855
+ ],
1856
+ "page_idx": 13
1857
+ },
1858
+ {
1859
+ "type": "equation",
1860
+ "img_path": "images/76e113c366b2149fa540592fd4a63f4c3639ce68bfa7c9974db16404fd356b08.jpg",
1861
+ "text": "$$\n\\begin{array} { l } { { \\displaystyle E \\Big [ \\big ( b _ { i } ^ { 1 } + \\sum _ { j = 1 } ^ { N _ { 1 } } W _ { i j } ^ { 1 } \\mathbf { X } _ { j } ( x ) \\big ) \\big ( b _ { i } ^ { 1 } + \\sum _ { k = 1 } ^ { N _ { 1 } } W _ { i k } ^ { 1 } \\mathbf { X } _ { k } ( y ) \\big ) \\Big ] - E \\Big [ b _ { i } ^ { 1 } + \\sum _ { j = 1 } ^ { N _ { 1 } } W _ { i j } ^ { 1 } \\mathbf { X } _ { j } ( x ) \\Big ] \\Big [ b _ { i } ^ { 1 } + \\sum _ { k = 1 } ^ { N _ { 1 } } W _ { i k } ^ { 1 } \\mathbf { X } _ { k } ( y ) \\Big ] } } \\\\ { { \\displaystyle = E [ ( b _ { i } ^ { 1 } ) ^ { 2 } ] + \\sum _ { j = 1 } ^ { N _ { 1 } } E [ ( W _ { i j } ^ { 1 } ) ^ { 2 } ] E [ \\mathbf { X } _ { j } ( x ) \\mathbf { X } _ { j } ( y ) ] - \\frac { 1 } { 2 \\pi } \\sqrt { \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\| x \\| ^ { 2 } } \\sqrt { \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\| y \\| ^ { 2 } } } } \\\\ { { \\displaystyle = \\sigma _ { b } ^ { 2 } + \\frac { \\sigma _ { w } ^ { 2 } } { N _ { 1 } } N _ { 1 } E [ \\mathbf { X } _ { j } ( x ) \\mathbf { X } _ { j } ( y ) ] - \\frac { 1 } { 2 \\pi } \\sqrt { \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\| x \\| ^ { 2 } } \\sqrt { \\sigma _ { b } ^ { 2 } + \\sigma _ { w } ^ { 2 } \\| y \\| ^ { 2 } } } } \\\\ { { \\displaystyle = \\sigma _ { b } ^ { 2 } + \\frac { \\sigma _ { w } ^ { 2 } } { 2 \\pi } \\Big ( \\sigma _ { b } ^ { 2 } + \\| x \\| ^ { 2 } \\sigma _ { w } ^ { 2 } \\Big ) ^ { \\frac { 1 } { 2 } } \\Big ( \\sigma _ { b } ^ { 2 } + \\| y \\| ^ { 2 } \\sigma _ { w } ^ { 2 } \\Big ) ^ { \\frac { 1 } { 2 } } \\Big ( \\sin \\phi + ( \\pi - \\phi ) \\cos \\phi - 1 \\Big ) . } } \\end{array}\n$$",
1862
+ "text_format": "latex",
1863
+ "bbox": [
1864
+ 181,
1865
+ 377,
1866
+ 823,
1867
+ 537
1868
+ ],
1869
+ "page_idx": 13
1870
+ }
1871
+ ]
parse/train/pbXQtKXwLS/pbXQtKXwLS_middle.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/pbXQtKXwLS/pbXQtKXwLS_model.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/r1q7n9gAb/r1q7n9gAb_content_list.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/r1q7n9gAb/r1q7n9gAb_model.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/rkgOLb-0W/rkgOLb-0W.md ADDED
@@ -0,0 +1,474 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # NEURAL LANGUAGE MODELING BY JOINTLY LEARNING SYNTAX AND LEXICON
2
+
3
+ Yikang Shen, Zhouhan Lin, Chin-Wei Huang & Aaron Courville
4
+
5
+ Department of Computer Science and Operations Research
6
+ Universit de Montral
7
+ Montral, QC H3C3J7, Canada
8
+ {yi-kang.shen, zhouhan.lin, chin-wei.huang, aaron.courville}@umontreal.ca
9
+
10
+ # ABSTRACT
11
+
12
+ We propose a neural language model capable of unsupervised syntactic structure induction. The model leverages the structure information to form better semantic representations and better language modeling. Standard recurrent neural networks are limited by their structure and fail to efficiently use syntactic information. On the other hand, tree-structured recursive networks usually require additional structural supervision at the cost of human expert annotation. In this paper, We propose a novel neural language model, called the Parsing-Reading-Predict Networks (PRPN), that can simultaneously induce the syntactic structure from unannotated sentences and leverage the inferred structure to learn a better language model. In our model, the gradient can be directly back-propagated from the language model loss into the neural parsing network. Experiments show that the proposed model can discover the underlying syntactic structure and achieve state-of-the-art performance on word/character-level language model tasks.
13
+
14
+ # 1 INTRODUCTION
15
+
16
+ Linguistic theories generally regard natural language as consisting of two part: a lexicon, the complete set of all possible words in a language; and a syntax, the set of rules, principles, and processes that govern the structure of sentences (Sandra & Taft, 1994). To generate a proper sentence, tokens are put together with a specific syntactic structure. Understanding a sentence also requires lexical information to provide meanings, and syntactical knowledge to correctly combine meanings. Current neural language models can provide meaningful word represent (Bengio et al., 2003; Mikolov et al., 2013; Chen et al., 2013). However, standard recurrent neural networks only implicitly model syntax, thus fail to efficiently use structure information (Tai et al., 2015).
17
+
18
+ Developing a deep neural network that can leverage syntactic knowledge to form a better semantic representation has received a great deal of attention in recent years (Socher et al., 2013; Tai et al., 2015; Chung et al., 2016). Integrating syntactic structure into a language model is important for different reasons: 1) to obtain a hierarchical representation with increasing levels of abstraction, which is a key feature of deep neural networks and of the human brain (Bengio et al., 2009; LeCun et al., 2015; Schmidhuber, 2015); 2) to capture complex linguistic phenomena, like long-term dependency problem (Tai et al., 2015) and the compositional effects (Socher et al., 2013); 3) to provide shortcut for gradient back-propagation (Chung et al., 2016).
19
+
20
+ A syntactic parser is the most common source for structure information. Supervised parsers can achieve very high performance on well constructed sentences. Hence, parsers can provide accurate information about how to compose word semantics into sentence semantics (Socher et al., 2013), or how to generate the next word given previous words (Wu et al., 2017). However, only major languages have treebank data for training parsers, and it request expensive human expert annotation. People also tend to break language rules in many circumstances (such as writing a tweet). These defects limit the generalization capability of supervised parsers.
21
+
22
+ Unsupervised syntactic structure induction has been among the longstanding challenges of computational linguistic (Klein & Manning, 2002; 2004; Bod, 2006). Researchers are interested in this problem for a variety of reasons: to be able to parse languages for which no annotated treebanks exist (Marecek, 2016); to create a dependency structure to better suit a particular NLP application (Wu et al., 2017); to empirically argue for or against the poverty of the stimulus (Clark, 2001; Chomsky, 2014); and to examine cognitive issues in language learning (Solan et al., 2003).
23
+
24
+ In this paper, we propose a novel neural language model: Parsing-Reading-Predict Networks (PRPN), which can simultaneously induce the syntactic structure from unannotated sentences and leverage the inferred structure to form a better language model. With our model, we assume that language can be naturally represented as a tree-structured graph. The model is composed of three parts:
25
+
26
+ 1. A differentiable neural Parsing Network uses a convolutional neural network to compute the syntactic distance, which represents the syntactic relationships between all successive pairs of words in a sentence, and then makes soft constituent decisions based on the syntactic distance.
27
+ 2. A Reading Network that recurrently computes an adaptive memory representation to summarize information relevant to the current time step, based on all previous memories that are syntactically and directly related to the current token.
28
+ 3. A Predict Network that predicts the next token based on all memories that are syntactically and directly related to the next token.
29
+
30
+ We evaluate our model on three tasks: word-level language modeling, character-level language modeling, and unsupervised constituency parsing. The proposed model achieves (or is close to) the state-of-the-art on both word-level and character-level language modeling. The model’s unsupervised parsing outperforms some strong baseline models, demonstrating that the structure found by our model is similar to the intrinsic structure provided by human experts.
31
+
32
+ # 2 RELATED WORK
33
+
34
+ The idea of introducing some structures, especially trees, into language understanding to help a downstream task has been explored in various ways. For example, Socher et al. (2013); Tai et al. (2015) learn a bottom-up encoder, taking as an input a parse tree supplied from an external parser. There are models that are able to infer a tree during test time, while still need supervised signal on tree structure during training. For example, (Socher et al., 2010; Alvarez-Melis & Jaakkola, 2016; Zhou et al., 2017; Zhang et al., 2015), etc. Moreover, Williams et al. (2017) did an in-depth analysis of recursive models that are able to learn tree structure without being exposed to any grammar trees. Our model is also able to infer tree structure in an unsupervised setting, but different from theirs, it is a recurrent network that implicitly models tree structure through attention.
35
+
36
+ Apart from the approach of using recursive networks to capture structures, there is another line of research which try to learn recurrent features at multiple scales, which can be dated back to 1990s (e.g. El Hihi & Bengio (1996); Schmidhuber (1991); Lin et al. (1998)). The NARX RNN (Lin et al., 1998) is another example which used a feed forward net taking different inputs with predefined time delays to model long-term dependencies. More recently, Koutnik et al. (2014) also used multiple layers of recurrent networks with different pre-defined updating frequencies. Instead, our model tries to learn the structure from data, rather than predefining it. In that respect, Chung et al. (2016) relates to our model since it proposes a hierarchical multi-scale structure with binary gates controlling intralayer connections, and the gating mechanism is learned from data too. The difference is that their gating mechanism controls the updates of higher layers directly, while ours control it softly through an attention mechanism.
37
+
38
+ In terms of language modeling, syntactic language modeling can be dated back to Chelba (1997). Charniak (2001); Roark (2001) have also proposed language models with a top-down parsing mechanism. Recently Dyer et al. (2016); Kuncoro et al. (2016) have introduced neural networks into this space. It learns both a discriminative and a generative model with top-down parsing, trained with a supervision signal from parsed sentences in the corpus. There are also dependency-based approaches using neural networks, including Buys & Blunsom (2015); Emami & Jelinek (2005); Titov & Henderson (2010).
39
+
40
+ Parsers are also related to our work since they are all inferring grammatical tree structure given a sentence. For example, SPINN (Bowman et al., 2016) is a shift-reduce parser that uses an LSTM as its composition function. The transition classifier in SPINN is supervisedly trained on the Stanford PCFG Parser (Klein & Manning, 2003) output. Unsupervised parsers are more aligned with what our model is doing. Klein & Manning (2004) presented a generative model for the unsupervised learning of dependency structures. Klein & Manning (2002) is a generative distributional model for the unsupervised induction of natural language syntax which explicitly models constituent yields and contexts. We compare our parsing quality with the aforementioned two papers in Section 6.3.
41
+
42
+ # 3 MOTIVATION
43
+
44
+ ![](images/7e7d20cb5b89a653ca29ed3b4230b46b148e4e0f42b0b2d4c2aa3c05054edbdd.jpg)
45
+ Figure 1: Hard arrow represents syntactic tree structure and parent-to-child dependency relation, dash arrow represents dependency relation between siblings
46
+
47
+ Suppose we have a sequence of tokens $x _ { 0 } , . . . , x _ { 6 }$ governed by the tree structure showed in Figure 1. The leafs $x _ { i }$ are observed tokens. Node $y _ { i }$ represents the meaning of the constituent formed by its leaves $x _ { l ( y _ { i } ) } , . . . , x _ { r ( y _ { i } ) }$ , where $l ( \cdot )$ and $r ( \cdot )$ stands for the leftmost child and right most child. Root $r$ represents the meaning of the whole sequence. Arrows represent the dependency relations between nodes. The underlying assumption is that each node depends only on its parent and its left siblings.
48
+
49
+ Directly modeling the tree structure is a challenging task, usually requiring supervision to learn (Tai et al., 2015). In addition, relying on tree structures can result in a model that is not sufficiently robust to face ungrammatical sentences (Hashemi & Hwa, 2016). In contrast, recurrent models provide a convenient way to model sequential data, with the current hidden state only depends on the last hidden state. This makes models more robust when facing nonconforming sequential data, but it suffers from neglecting the real dependency relation that dominates the structure of natural language sentences.
50
+
51
+ ![](images/610156bef3a60a2af06644612bb9ca3b7d7f417faa79d8e79abfe9f10b9ff42f.jpg)
52
+ Figure 2: Proposed model architecture, hard line indicate valid connection in Reading Network, dash line indicate valid connection in Predict Network.
53
+
54
+ In this paper, we use skip-connection to integrate structured dependency relations with recurrent neural network. In other words, the current hidden state does not only depend on the last hidden state, but also on previous hidden states that have a direct syntactic relation to the current one.
55
+
56
+ Figure 2 shows the structure of our model. The non-leaf node $y _ { j }$ is represented by a set of hidden states $y _ { j } = \{ m _ { i } \} _ { l ( y _ { j } ) \leq i \leq r ( y _ { j } ) }$ , where $l ( y _ { j } )$ is the left most descendant leaf and $r ( y _ { j } )$ is the right most one. Arrows shows skip connections built by our model according to the latent structure. Skip connections are controlled by gates $g _ { i } ^ { t }$ . In order to define $g _ { i } ^ { t }$ , we introduce a latent variable $l _ { t }$ to represent local structural context of $x _ { t }$ :
57
+
58
+ • if $x _ { t }$ is not left most child of any subtree, then $l _ { t }$ is the position of $x _ { t }$ ’s left most sibling. • if $x _ { t }$ is the left most child of a subtree $y _ { i }$ , then $l _ { t }$ is the position of the left most child that belongs to the left most sibling of $y _ { i }$ .
59
+
60
+ and gates are defined as:
61
+
62
+ $$
63
+ g _ { i } ^ { t } = \left\{ { \begin{array} { l l } { 1 , } & { l _ { t } \leq i < t } \\ { 0 , } & { 0 < i < l _ { t } } \end{array} } \right.
64
+ $$
65
+
66
+ Given this architecture, the siblings dependency relation is modeled by at least one skip-connect. The skip connection will directly feed information forward, and pass gradient backward. The parentto-child relation will be implicitly modeled by skip-connect relation between nodes.
67
+
68
+ The model recurrently updates the hidden states according to:
69
+
70
+ $$
71
+ m _ { t } = h ( x _ { t } , m _ { 0 } , . . . , m _ { t - 1 } , g _ { 0 } ^ { t } , . . . , g _ { t - 1 } ^ { t } )
72
+ $$
73
+
74
+ and the probability distribution for next word is approximated by:
75
+
76
+ $$
77
+ p ( x _ { t + 1 } | x _ { 0 } , . . . , x _ { t } ) \approx p ( x _ { t + 1 } ; f ( m _ { 0 } , . . . , m _ { t } , g _ { 0 } ^ { t + 1 } , . . . , g _ { t } ^ { t + 1 } ) )
78
+ $$
79
+
80
+ where $g _ { i } ^ { t }$ are gates that control skip-connections. Both $f$ and $h$ have a structured attention mechanism that takes $g _ { i } ^ { t }$ as input and forces the model to focus on the most related information. Since $l _ { t }$ is an unobserved latent variable, We explain an approximation for $g _ { i } ^ { t }$ in the next section. The structured attention mechanism is explained in section 5.1.
81
+
82
+ # 4 MODELING SYNTACTIC STRUCTURE
83
+
84
+ # 4.1 MODELING LOCAL STRUCTURE
85
+
86
+ In this section we give a probabilistic view on how to model the local structure of language. A detailed elaboration for this section is given in Appendix B. At time step $t$ , $p ( l _ { t } | x _ { 0 } , . . . , x _ { t } )$ represents the probability of choosing one out of $t$ possible local structures. We propose to model the distribution by the Stick-Breaking Process:
87
+
88
+ $$
89
+ p ( l _ { t } = i | x _ { 0 } , . . . , x _ { t } ) = ( 1 - \alpha _ { i } ^ { t } ) \prod _ { j = i + 1 } ^ { t - 1 } \alpha _ { j } ^ { t }
90
+ $$
91
+
92
+ The formassigned, nderstood by noting that ais remaining probability, time step is the por $i + 1 , . . . , t - 1$ have their probabilitiesing probability that we $\textstyle \prod _ { j = i + 1 } ^ { t - 1 } \alpha _ { j } ^ { t }$ $1 - \alpha _ { i } ^ { t }$
93
+ assign to time step $i$ . Variable $\alpha _ { j } ^ { t }$ is parametrized in the next section.
94
+
95
+ As shown in Appendix B, the expectation of gate value $g _ { i } ^ { t }$ is the Cumulative Distribution Function (CDF) of $p ( l _ { t } = \bar { i } | x _ { 0 } , . . . , x _ { t } )$ . Thus, we can replace the discrete gate value by its expectation:
96
+
97
+ $$
98
+ g _ { i } ^ { t } = \mathbf { P } ( l _ { t } \leq i ) = \prod _ { j = i + 1 } ^ { t - 1 } \alpha _ { j } ^ { t }
99
+ $$
100
+
101
+ With these relaxations, Eq.2 and 3 can be approximated by using a soft gating vector to update the hidden state and predict the next token.
102
+
103
+ # 4.2 PARSING NETWORK
104
+
105
+ Inferring tree structure with Syntactic Distance In Eq.4, $1 - \alpha _ { j } ^ { t }$ is the portion of the remaining probability that we assign to position $j$ . Because the stick-breaking process should assign high probability to $l _ { t }$ , which is the closest constituent-beginning word. The model should assign large $\bar { 1 } - \alpha _ { j } ^ { t }$ to words beginning new constituents. While $x _ { t }$ itself is a constituent-beginning word, the model should assign large $1 - \alpha _ { j } ^ { t }$ to words beginning larger constituents. In other words, the model will consider longer dependency relations for the first word in constituent. Given the sentence in Figure 1, at time step $t = 6$ , both $1 - \alpha _ { 2 } ^ { 6 }$ and $1 - \alpha _ { 0 } ^ { 6 }$ should be close to 1, and all other $1 - \alpha _ { j } ^ { 6 }$ should be close to 0.
106
+
107
+ In order to parametrize $\alpha _ { j } ^ { t }$ , our basic hypothesis is that words in the same constituent should have a closer syntactic relation within themselves, and that this syntactical proximity can be represented by a scalar value. From the tree structure point of view, the shortest path between leafs in same subtree is shorter than the one between leafs in different subtree.
108
+
109
+ To model syntactical proximity, we introduce a new feature Syntactic Distance. For a sentence with length $K$ , we define a set of $K$ real valued scalar variables $d _ { 0 } , . . . , d _ { K - 1 }$ , with $d _ { i }$ representing a measure of the syntactic relation between the pair of adjacent words $( x _ { i - 1 } , x _ { i } )$ . $x _ { - 1 }$ could be the last word in previous sentence or a padding token. For time step $t$ , we want to find the closest words $x _ { j }$ , that have larger syntactic distance than $d _ { t }$ . Thus $\alpha _ { j } ^ { t }$ can be defined as:
110
+
111
+ $$
112
+ \alpha _ { j } ^ { t } = { \frac { \operatorname { h a r d t a n h } { ( ( d _ { t } - d _ { j } ) \cdot \tau ) } + 1 } { 2 } }
113
+ $$
114
+
115
+ where hardt $\mathrm { \ u n h } ( x ) = \operatorname* { m a x } ( - 1 , \operatorname* { m i n } ( 1 , x ) )$ . $\tau$ is the temperature parameter that controls the sensitivity of $\alpha _ { j } ^ { t }$ to the differences between distances.
116
+
117
+ The Syntactic Distance has some nice properties that both allow us to infer a tree structure from it and be robust to intermediate non-valid tree structures that the model may encounter during learning. In Appendix $\textrm { C }$ and D we list these properties and further explain the meanings of their values.
118
+
119
+ Parameterizing Syntactic Distance Roark & Hollingshead (2008) shows that it’s possible to identify the beginning and ending words of a constituent using local information. In our model, the syntactic distance between a given token (which is usually represented as a vector word embedding $e _ { i }$ ) and its previous token $e _ { i - 1 }$ , is provided by a convolutional kernel over a set of consecutive previous tokens $e _ { i - L } , e _ { i - L + 1 } , . . . , e _ { i }$ . This convolution is depicted as the gray triangles shown in Figure 3. Each triangle here represent 2 layers of convolution. Formally, the syntactic distance $d _ { i }$ between token $e _ { i - 1 }$ and $e _ { i }$ is computed by
120
+
121
+ $$
122
+ h _ { i } = \mathrm { R e L U } ( W _ { c } \left[ \begin{array} { c } { e _ { i - L } } \\ { e _ { i - L + 1 } } \\ { \cdots } \\ { e _ { i } } \end{array} \right] + b _ { c } )
123
+ $$
124
+
125
+ $$
126
+ d _ { i } = \mathrm { R e L U } \left( W _ { d } h _ { i } + b _ { d } \right)
127
+ $$
128
+
129
+ where $W _ { c }$ , $b _ { c }$ are the kernel parameters. $W _ { d }$ and $b _ { d }$ can be seen as another convolutional kernel with window size 1, convolved over $h _ { i }$ ’s. Here the kernel window size $L$ determines how far back into the history node $e _ { i }$ can reach while computing its syntactic distance $d _ { i }$ . Thus we call it the look-back range.
130
+
131
+ Convolving $^ { h }$ and $^ d$ on the whole sequence with length $K$ yields a set of distances. For the tokens in the beginning of the sequence, we simply pad $L - 1$ zero vectors to the front of the sequence in order to get $K - 1$ outputs.
132
+
133
+ # 5 MODELING LANGUAGE
134
+
135
+ # 5.1 READING NETWORK
136
+
137
+ The Reading Network generate new states $m _ { t }$ considering on input $x _ { t }$ , previous memory states $m _ { 0 } , . . . , m _ { t - 1 }$ , and gates $( g _ { 0 } ^ { t } , . . . , g _ { t - 1 } ^ { t }$ , as shown in Eq.2.
138
+
139
+ ![](images/5841529dde75dd85d916b388f393f203a304e8a6451605258566e479972d3292.jpg)
140
+ Figure 3: Convolutional network for computing syntactic distance. Gray triangles represent 2 layers of convolution, $d _ { 0 }$ to $d _ { 7 }$ are the syntactic distance output by each of the kernel position. The blue bars indicate the amplitude of $d _ { i }$ ’s, and $y _ { i }$ ’s are the inferred constituents.
141
+
142
+ Similar to Long Short-Term Memory-Network (LSTMN) (Cheng et al., 2016), the Reading Network maintains the memory states by maintaining two sets of vectors: a hidden tape $H _ { t - 1 } ~ =$ $\left( { { h } _ { t - { N } _ { m } } } , . . . , { { h } _ { t - 1 } } \right)$ , and a memory tape $C _ { t - 1 } = ( c _ { t - L } , . . . , c _ { t - 1 } )$ , where $N _ { m }$ is the upper bound for the memory span. Hidden states $m _ { i }$ is now represented by a tuple of two vectors $( \bar { h } _ { i } , c _ { i } )$ . The Reading Network captures the dependency relation by a modified attention mechanism: structured attention. At each step of recurrence, the model summarizes the previous recurrent states via the structured attention mechanism, then performs a normal LSTM update, with hidden and cell states output by the attention mechanism.
143
+
144
+ Structured Attention At each time step $t$ , the read operation attentively links the current token to previous memories with a structured attention layer:
145
+
146
+ $$
147
+ \begin{array} { r l } & { k _ { t } = W _ { h } h _ { t - 1 } + W _ { x } x _ { t } } \\ & { } \\ & { \tilde { s } _ { i } ^ { t } = \mathrm { s o f t m a x } ( \frac { h _ { i } k _ { t } ^ { \mathrm { T } } } { \sqrt { \delta _ { k } } } ) } \end{array}
148
+ $$
149
+
150
+ where, $\delta _ { k }$ is the dimension of the hidden state. Modulated by the gates in Eq.5, the structured intra-attention weight is defined as:
151
+
152
+ $$
153
+ s _ { i } ^ { t } = \frac { g _ { i } ^ { t } \tilde { s } _ { i } ^ { t } } { \sum _ { i } g _ { i } ^ { t } }
154
+ $$
155
+
156
+ This yields a probability distribution over the hidden state vectors of previous tokens. We can then compute an adaptive summary vector for the previous hidden tape and memory denoting by $\tilde { h } _ { t }$ and $\tilde { c } _ { t }$ :
157
+
158
+ $$
159
+ \left[ \tilde { h } _ { t } \right] = \sum _ { i = 1 } ^ { t - 1 } s _ { i } ^ { t } \cdot m _ { i } = \sum _ { i = 1 } ^ { t - 1 } s _ { i } ^ { t } \cdot \left[ h _ { i } \right]
160
+ $$
161
+
162
+ Structured attention provides a way to model the dependency relations shown in Figure 1.
163
+
164
+ Recurrent Update The Reading Network takes $x _ { t }$ , ${ \tilde { c } } _ { t }$ and $\tilde { h } _ { t }$ as input, computes the values of $c _ { t }$ and $h _ { t }$ by the LSTM recurrent update (Hochreiter & Schmidhuber, 1997). Then the write operation concatenates $h _ { t }$ and $c _ { t }$ to the end of hidden and memory tape.
165
+
166
+ # 5.2 PREDICT NETWORK
167
+
168
+ Predict Network models the probability distribution of next word $x _ { t + 1 }$ , considering on hidden states $m _ { 0 } , . . . , m _ { t }$ , and gates $g _ { 0 } ^ { t + 1 } , . . . , g _ { t } ^ { t + 1 }$ gt+1t . Note that, at time step t, the model cannot observe xt+1 , a temporary estimation of $d _ { t + 1 }$ is computed considering on $x _ { t - L } , . . . , x _ { t }$ :
169
+
170
+ $$
171
+ d _ { t + 1 } ^ { \prime } = \mathrm { R e L U } ( W _ { d } ^ { \prime } h _ { t } + b _ { d } ^ { \prime } )
172
+ $$
173
+
174
+ From there we compute its corresponding $\{ \alpha ^ { t + 1 } \}$ and $\{ g _ { i } ^ { t + 1 } \}$ for Eq.3. We parametrize $f ( \cdot )$ function as:
175
+
176
+ $$
177
+ f ( m _ { 0 } , . . . , m _ { t } , g _ { 0 } ^ { t + 1 } , . . . , g _ { t } ^ { t + 1 } ) = \hat { f } ( [ h _ { l : t - 1 } , h _ { t } ] )
178
+ $$
179
+
180
+ ![](images/6ae0fd4df59a2fbfb5e53d08ee8a23a85c79c6304d98c0d5e32785985bd5c315.jpg)
181
+ Figure 4: Syntactic distance estimated by Parsing Network. The model is trained on PTB dataset at the character level. Each blue bar is positioned between two characters, and represents the syntactic distance between them. From these distances we can infer a tree structure according to Section 4.2.
182
+
183
+ where $h _ { l : t - 1 }$ is an adaptive summary of $h _ { l _ { t + 1 } \leq i \leq t - 1 }$ , output by structured attention controlled by $g _ { 0 } ^ { t + 1 } , . . . , g _ { t - 1 } ^ { t + 1 }$ . ${ \hat { f } } ( \cdot )$ could be a simple feed-forward MLP, or more complex architecture, like ResNet, to add more depth to the model.
184
+
185
+ # 6 EXPERIMENTS
186
+
187
+ We evaluate the proposed model on three tasks, character-level language modeling, word-level language modeling, and unsupervised constituency parsing.
188
+
189
+ # 6.1 CHARACTER-LEVEL LANGUAGE MODEL
190
+
191
+ From a character-level view, natural language is a discrete sequence of data, where discrete symbols form a distinct and shallow tree structure: the sentence is the root, words are children of the root, and characters are leafs. However, compared to word-level language modeling, character-level language modeling requires the model to handle longer-term dependencies. We evaluate a character-level variant of our proposed language model over a preprocessed version of the Penn Treebank (PTB) and Text8 datasets.
192
+
193
+ When training, we use truncated back-propagation, and feed the final memory position from the previous batch as the initial memory of next one. At the beginning of training and test time, the model initial hidden states are filled with zero. Optimization is performed with Adam using learning rate $l r = 0 . 0 0 3$ , weight decay $w _ { d e c a y } = 1 0 ^ { - 6 }$ , $\beta _ { 1 } = 0 . 9$ , $\beta _ { 2 } = 0 . 9 9 9$ and $\sigma = 1 0 ^ { - 8 }$ . We carry out gradient clipping with maximum norm 1.0. The learning rate is multiplied by 0.1 whenever validation performance does not improve during 2 checkpoints. These checkpoints are performed at the end of each epoch. We also apply layer normalization (Ba et al., 2016) to the Reading Network and batch normalization to the Predict Network and parsing network. For all of the character-level language modeling experiments, we apply the same procedure, varying only the number of hidden units, mini-batch size and dropout rate.
194
+
195
+ Penn Treebank we process the Penn Treebank dataset (Marcus et al., 1993) by following the procedure introduced in (Mikolov et al., 2012). For character-level PTB, Reading Network has two recurrent layers, Predict Network has one residual block. Hidden state size is 1024 units. The input and output embedding size are 128, and not shared. Look-back range $L = 1 0$ , temperature parameter $\tau = 1 0$ , upper band of memory span $N _ { m } = 2 0$ . We use a batch size of 64, truncated backpropagation with 100 timesteps. The values used of dropout on input/output embeddings, between recurrent layers, and on recurrent states were $( 0 , 0 . 2 5 , 0 . 1 )$ respectively.
196
+
197
+ In Figure 4, we visualize the syntactic distance estimated by the Parsing Network, while reading three different sequences from the PTB test set. We observe that the syntactic distance tends to be higher between the last character of a word and a space, which is a reasonable breakpoint to separate between words. In other words, if the model sees a space, it will attend on all previous step. If the model sees a letter, it will attend no further then the last space step. The model autonomously discovered to avoid inter-word attention connection, and use the hidden states of space (separator) tokens to summarize previous information. This is strong proof that the model can understand the latent structure of data. As a result our model achieve state-of-the-art performance and significantly outperform baseline models. It is worth noting that HM-LSTM (Chung et al., 2016) also unsupervisedly induce similar structure from data. But discrete operations in HM-LSTM make their training procedure more complicated then ours.
198
+
199
+ Table 1: BPC on the Penn Treebank test set
200
+
201
+ <table><tr><td>Model</td><td>BPC</td></tr><tr><td>Norm-stabilized RNN(Krueger&amp; Memisevic,2015)</td><td>1.48</td></tr><tr><td>CW-RNN (Koutnik et al., 2014)</td><td>1.46</td></tr><tr><td>HF-MRNN (Mikolov et al., 2012)</td><td>1.41</td></tr><tr><td>MI-RNN (Wu et al., 2016)</td><td>1.39</td></tr><tr><td>ME n-gram (Mikolov et al., 2012)</td><td>1.37</td></tr><tr><td>BatchNorm LSTM (Cooijmans et al.,2016)</td><td>1.32</td></tr><tr><td>Zoneout RNN (Krueger et al., 2016)</td><td>1.27</td></tr><tr><td>HyperNetworks (Ha et al., 2016)</td><td>1.27</td></tr><tr><td>LayerNorm HM-LSTM (Chung et al., 2016)</td><td>1.24</td></tr><tr><td>LayerNorm HyperNetworks (Ha et al., 2016)</td><td>1.23</td></tr><tr><td>PRPN</td><td>1.202</td></tr></table>
202
+
203
+ # 6.2 WORD-LEVEL LANGUAGE MODEL
204
+
205
+ Comparing to character-level language modeling, word-level language modeling needs to deal with complex syntactic structure and various linguistic phenomena. But it has less long-term dependencies. We evaluate the word-level variant of our language model on a preprocessed version of the Penn Treebank (PTB) (Marcus et al., 1993) and Text8 (Mahoney, 2011) dataset.
206
+
207
+ We apply the same procedure and hyper-parameters as in character-level language model. Except optimization is performed with Adam with $\beta _ { 1 } = 0$ . This turns off the exponential moving average for estimates of the means of the gradients (Melis et al., 2017). We also adapt the number of hidden units, mini-batch size and the dropout rate according to the different tasks.
208
+
209
+ Penn Treebank we process the Penn Treebank dataset (Mikolov et al., 2012) by following the procedure introduced in (Mikolov et al., 2010). For word-level PTB, the Reading Network has two recurrent layers and the Predict Network do not have residual block. The hidden state size is 1200 units and the input and output embedding sizes are 800, and shared (Inan et al., 2016; Press & Wolf, 2017). Look-back range $L = 5$ , temperature parameter $\tau = 1 0$ and the upper band of memory span $N _ { m } = 1 5$ . We use a batch size of 64, truncated back-propagation with 35 time-steps. The values used of dropout on input/output embeddings, between recurrent layers, and on recurrent states were (0.7, 0.5, 0.5) respectively.
210
+
211
+ Table 2: PPL on the Penn Treebank test set
212
+
213
+ <table><tr><td>Model</td><td>PPL</td></tr><tr><td>RNN-LDA + KN-5 + cache (Mikolov &amp; Zweig, 2012)</td><td>92.0</td></tr><tr><td>LSTM (Zaremba et al., 2014)</td><td>78.4</td></tr><tr><td>Variational LSTM (Kim et al., 2016)</td><td>78.9</td></tr><tr><td>CharCNN (Kim et al., 2016)</td><td>78.9</td></tr><tr><td>Pointer Sentinel-LSTM (Merity et al.,2016)</td><td>70.9</td></tr><tr><td>LSTM + continuous cache pointer (Grave et al., 2016)</td><td>72.1</td></tr><tr><td>Variational LSTM (tied) + augmented loss (Inan et al.,2016)</td><td>68.5</td></tr><tr><td>Variational RHN (tied) (Zilly et al., 2016)</td><td>65.4</td></tr><tr><td>NAS Cell (tied) (Zoph &amp; Le, 2016)</td><td>62.4</td></tr><tr><td>4-layer skip connection LSTM (tied) (Melis et al., 2017)</td><td>58.3</td></tr><tr><td>PRPN</td><td>61.98</td></tr></table>
214
+
215
+ Table 3: Ablation test on the Penn Treebank. “- Parsing Net” means that we remove Parsing Network and replace Structured Attention with normal attention mechanism; “- Reading Net Attention” means that we remove Structured Attention from Reading Network, that is equivalent to replace Reading Network with a normal 2-layer LSTM; “- Predict Net Attention” means that we remove Structured Attention from Predict Network, that is equivalent to have a standard projection layer; “Our 2-layer LSTM” is equivalent to remove Parsing Network and remove Structured Attention from both Reading and Predict Network.
216
+
217
+ <table><tr><td>Model</td><td>PPL</td></tr><tr><td>PRPN</td><td>61.98</td></tr><tr><td>- Parsing Net</td><td>64.42</td></tr><tr><td>- Reading Net Attention</td><td>64.63</td></tr><tr><td>- Predict Net Attention</td><td>63.65</td></tr><tr><td>Our 2-layer LSTM</td><td>65.81</td></tr></table>
218
+
219
+ Text8 dataset contains 17M training tokens and has a vocabulary size of 44k words. The dataset is partitioned into a training set (first 99M characters) and a development set (last 1M characters) that is used to report performance. As this dataset contains various articles from Wikipedia, the longer term information (such as current topic) plays a bigger role than in the PTB experiments (Mikolov et al., 2014). We apply the same procedure and hyper-parameters as in character-level PTB, except we use a batch size of 128. The values used of dropout on input/output embeddings, between Recurrent Layers and on recurrent states were (0.4, 0.2, 0.2) respectively.
220
+
221
+ Table 4: PPL on the Text8 valid set
222
+
223
+ <table><tr><td>Model</td><td>PPL</td></tr><tr><td>LSTM-500 (Mikolov et al., 2014)</td><td>156</td></tr><tr><td>SCRNN (Mikolov et al., 2014)</td><td>161</td></tr><tr><td>MemNN (Sukhbaatar et al., 2015)</td><td>147</td></tr><tr><td>LSTM-1024 (Grave et al., 2016)</td><td>121</td></tr><tr><td>LSTM + continuous cache pointer (Grave et al., 2016)</td><td>99.9</td></tr><tr><td>PRPN</td><td>81.64</td></tr></table>
224
+
225
+ In Table 2, our results are comparable to the state-of-the-art methods. Since we do not have the same computational resource used in (Melis et al., 2017) to tune hyper-parameters at large scale, we expect that our model could achieve better performance after an aggressive hyperparameter tuning process. As shown in Table 4, our method outperform baseline methods. It is worth noticing that the continuous cache pointer can also be applied to output of our Predict Network without modification. Visualizations of tree structure generated from learned PTB language model are included in Appendix A. In Table 3, we show the value of test perplexity for different variants of PRPN, each variant remove part of the model. By removing Parsing Network, we observe a significant drop of performance. This stands as empirical evidence regarding the benefit of having structure information to control attention.
226
+
227
+ # 6.3 UNSUPERVISED CONSTITUENCY PARSING
228
+
229
+ The unsupervised constituency parsing task compares hte tree structure inferred by the model with those annotated by human experts. The experiment is performed on WSJ10 dataset. WSJ10 is the 7422 sentences in the Penn Treebank Wall Street Journal section which contained 10 words or less after the removal of punctuation and null elements. Evaluation was done by seeing whether proposed constituent spans are also in the Treebank parse, measuring unlabeled F1 $\mathrm { ( U F _ { 1 } ) }$ ) of unlabeled constituent precision and recall. Constituents which could not be gotten wrong (those of span one and those spanning entire sentences) were discarded. Given the mechanism discussed in Section 4.2, our model generates a binary tree. Although standard constituency parsing tree is not limited to binary tree. Previous unsupervised constituency parsing model also generate binary trees (Klein & Manning, 2002; Bod, 2006). Our model is compared with the several baseline methods, that are explained in Appendix E.
230
+
231
+ Different from the previous experiment setting, the model treat each sentence independently during train and test time. When training, we feed one batch of sentences at each iteration. In a batch, shorter sentences are padded with 0. At the beginning of the iteration, the model’s initial hidden states are filled with zero. When testing, we feed on sentence one by one to the model, then use the gate value output by the model to recursively combine tokens into constituents, as described in Appendix A.
232
+
233
+ Table 5: Parsing Performance on the WSJ10 dataset
234
+
235
+ <table><tr><td>Model</td><td>UF1</td></tr><tr><td>LBRANCH RANDOM</td><td>28.7</td></tr><tr><td>DEP-PCFG (Carroll &amp; Charniak,1992)</td><td>34.7</td></tr><tr><td>RBRANCH</td><td>48.2</td></tr><tr><td>CCM (Klein &amp; Manning,2002)</td><td>61.7</td></tr><tr><td>DMV+CCM (Klein &amp; Manning, 2005)</td><td>71.9</td></tr><tr><td>UML-DOP (Bod, 2006)</td><td>77.6</td></tr><tr><td>PRPN</td><td>82.9</td></tr><tr><td>UPPERBOUND</td><td>70.02 88.1</td></tr></table>
236
+
237
+ Table 5 summarizes the results. Our model significantly outperform the RANDOM baseline indicate a high consistency with human annotation. Our model also shows a comparable performance with CCM model. In fact our parsing network and CCM both focus on the relation between successive tokens. As described in Section 4.2, our model computes syntactic distance between all successive pair of tokens, then our parsing algorithm recursively assemble tokens into constituents according to the learned distance. CCM also recursively model the probability whether a contiguous subsequences of a sentence is a constituent. Thus, one can understand how our model is outperformed by $\mathrm { D M V + C C M }$ and UML-DOP models. The $\mathrm { D M V + C C M }$ model has extra information from a dependency parser. The UML-DOP approach captures both contiguous and non-contiguous lexical dependencies (Bod, 2006).
238
+
239
+ # 7 CONCLUSION
240
+
241
+ In this paper, we propose a novel neural language model that can simultaneously induce the syntactic structure from unannotated sentences and leverage the inferred structure to learn a better language model. We introduce a new neural parsing network: Parsing-Reading-Predict Network, that can make differentiable parsing decisions. We use a new structured attention mechanism to control skip connections in a recurrent neural network. Hence induced syntactic structure information can be used to improve the model’s performance. Via this mechanism, the gradient can be directly backpropagated from the language model loss function into the neural Parsing Network. The proposed model achieve (or is close to) the state-of-the-art on both word/character-level language modeling tasks. Experiment also shows that the inferred syntactic structure highly correlated to human expert annotation.
242
+
243
+ # ACKNOWLEDGEMENT
244
+
245
+ The authors would like to thank Timothy J. O’Donnell and Chris Dyer for the helpful discussions.
246
+
247
+ # REFERENCES
248
+
249
+ David Alvarez-Melis and Tommi S Jaakkola. Tree-structured decoding with doubly-recurrent neural networks. 2016.
250
+
251
+ Jimmy Lei Ba, Jamie Ryan Kiros, and Geoffrey E Hinton. Layer normalization. arXiv preprint arXiv:1607.06450, 2016.
252
+
253
+ Yoshua Bengio, Rejean Ducharme, Pascal Vincent, and Christian Jauvin. A neural probabilistic ´ language model. Journal of machine learning research, 3(Feb):1137–1155, 2003.
254
+
255
+ Yoshua Bengio et al. Learning deep architectures for ai. Foundations and trends $\textsuperscript { \textregistered }$ in Machine Learning, 2(1):1–127, 2009.
256
+
257
+ Rens Bod. An all-subtrees approach to unsupervised parsing. In Proceedings of the 21st International Conference on Computational Linguistics and the 44th annual meeting of the Association for Computational Linguistics, pp. 865–872. Association for Computational Linguistics, 2006.
258
+
259
+ Samuel R Bowman, Jon Gauthier, Abhinav Rastogi, Raghav Gupta, Christopher D Manning, and Christopher Potts. A fast unified model for parsing and sentence understanding. arXiv preprint arXiv:1603.06021, 2016.
260
+
261
+ Jan Buys and Phil Blunsom. Generative incremental dependency parsing with neural networks. In Proceedings of the 53rd Annual Meeting of the Association for Computational Linguistics and the 7th International Joint Conference on Natural Language Processing (Volume 2: Short Papers), volume 2, pp. 863–869, 2015.
262
+
263
+ Glenn Carroll and Eugene Charniak. Two experiments on learning probabilistic dependency grammars from corpora. Department of Computer Science, Univ., 1992.
264
+
265
+ Eugene Charniak. Immediate-head parsing for language models. In Proceedings of the 39th Annual Meeting on Association for Computational Linguistics, pp. 124–131. Association for Computational Linguistics, 2001.
266
+
267
+ Ciprian Chelba. A structured language model. In Proceedings of the eighth conference on European chapter of the Association for Computational Linguistics, pp. 498–500. Association for Computational Linguistics, 1997.
268
+
269
+ Yanqing Chen, Bryan Perozzi, Rami Al-Rfou, and Steven Skiena. The expressive power of word embeddings. arXiv preprint arXiv:1301.3226, 2013.
270
+
271
+ Jianpeng Cheng, Li Dong, and Mirella Lapata. Long short-term memory-networks for machine reading. arXiv preprint arXiv:1601.06733, 2016.
272
+
273
+ Noam Chomsky. Aspects of the Theory of Syntax, volume 11. MIT press, 2014.
274
+
275
+ Junyoung Chung, Sungjin Ahn, and Yoshua Bengio. Hierarchical multiscale recurrent neural net works. arXiv preprint arXiv:1609.01704, 2016.
276
+
277
+ Alexander Clark. Unsupervised induction of stochastic context-free grammars using distributional clustering. In Proceedings of the 2001 workshop on Computational Natural Language LearningVolume 7, pp. 13. Association for Computational Linguistics, 2001.
278
+
279
+ Tim Cooijmans, Nicolas Ballas, Cesar Laurent, C¸ a ´ glar G ˘ ulc¸ehre, and Aaron Courville. Recurrent ¨ batch normalization. arXiv preprint arXiv:1603.09025, 2016.
280
+
281
+ Chris Dyer, Adhiguna Kuncoro, Miguel Ballesteros, and Noah A Smith. Recurrent neural network grammars. arXiv preprint arXiv:1602.07776, 2016.
282
+
283
+ Salah El Hihi and Yoshua Bengio. Hierarchical recurrent neural networks for long-term dependencies. 1996. URL http://www.iro.umontreal.ca/˜lisa/pointeurs/elhihi_ bengio_96.pdf.
284
+
285
+ Ahmad Emami and Frederick Jelinek. A neural syntactic language model. Machine learning, 60 (1-3):195–227, 2005.
286
+
287
+ Edouard Grave, Armand Joulin, and Nicolas Usunier. Improving neural language models with a continuous cache. arXiv preprint arXiv:1612.04426, 2016.
288
+
289
+ David Ha, Andrew Dai, and Quoc V Le. Hypernetworks. arXiv preprint arXiv:1609.09106, 2016.
290
+
291
+ Homa B Hashemi and Rebecca Hwa. An evaluation of parser robustness for ungrammatical sentences. In EMNLP, pp. 1765–1774, 2016.
292
+
293
+ Sepp Hochreiter and Jurgen Schmidhuber. Long short-term memory. ¨ Neural computation, 9(8): 1735–1780, 1997.
294
+
295
+ Hakan Inan, Khashayar Khosravi, and Richard Socher. Tying word vectors and word classifiers: A loss framework for language modeling. arXiv preprint arXiv:1611.01462, 2016.
296
+
297
+ Yoon Kim, Yacine Jernite, David Sontag, and Alexander M Rush. Character-aware neural language models. In AAAI, pp. 2741–2749, 2016.
298
+
299
+ Dan Klein and Christopher D Manning. A generative constituent-context model for improved grammar induction. In Proceedings of the 40th Annual Meeting on Association for Computational Linguistics, pp. 128–135. Association for Computational Linguistics, 2002.
300
+
301
+ Dan Klein and Christopher D. Manning. Accurate unlexicalized parsing. In Proceedings of the 41st Annual Meeting on Association for Computational Linguistics - Volume 1, ACL ’03, pp. 423–430, Stroudsburg, PA, USA, 2003. Association for Computational Linguistics. doi: 10.3115/1075096. 1075150. URL https://doi.org/10.3115/1075096.1075150.
302
+
303
+ Dan Klein and Christopher D Manning. Corpus-based induction of syntactic structure: Models of dependency and constituency. In Proceedings of the 42nd Annual Meeting on Association for Computational Linguistics, pp. 478. Association for Computational Linguistics, 2004.
304
+
305
+ Dan Klein and Christopher D Manning. Natural language grammar induction with a generative constituent-context model. Pattern recognition, 38(9):1407–1419, 2005.
306
+
307
+ Jan Koutnik, Klaus Greff, Faustino Gomez, and Juergen Schmidhuber. A clockwork rnn. In International Conference on Machine Learning, pp. 1863–1871, 2014.
308
+
309
+ David Krueger and Roland Memisevic. Regularizing rnns by stabilizing activations. arXiv preprint arXiv:1511.08400, 2015.
310
+
311
+ David Krueger, Tegan Maharaj, Janos Kram ´ ar, Mohammad Pezeshki, Nicolas Ballas, Nan Rose- ´ mary Ke, Anirudh Goyal, Yoshua Bengio, Hugo Larochelle, Aaron Courville, et al. Zoneout: Regularizing rnns by randomly preserving hidden activations. arXiv preprint arXiv:1606.01305, 2016.
312
+
313
+ Adhiguna Kuncoro, Miguel Ballesteros, Lingpeng Kong, Chris Dyer, Graham Neubig, and Noah A Smith. What do recurrent neural network grammars learn about syntax? arXiv preprint arXiv:1611.05774, 2016.
314
+
315
+ Yann LeCun, Yoshua Bengio, and Geoffrey Hinton. Deep learning. Nature, 521(7553):436–444, 2015.
316
+
317
+ Tsungnan Lin, Bill G Horne, Peter Tino, and C Lee Giles. Learning long-term dependencies is not as difficult with narx recurrent neural networks. Technical report, 1998.
318
+
319
+ Matt Mahoney. Large text compression benchmark, 2011.
320
+
321
+ Mitchell P Marcus, Mary Ann Marcinkiewicz, and Beatrice Santorini. Building a large annotated corpus of english: The penn treebank. Computational linguistics, 19(2):313–330, 1993.
322
+
323
+ David Marecek. Twelve years of unsupervised dependency parsing. In ITAT, pp. 56–62, 2016.
324
+
325
+ Gabor Melis, Chris Dyer, and Phil Blunsom. On the state of the art of evaluation in neural language ´ models. arXiv preprint arXiv:1707.05589, 2017.
326
+
327
+ Stephen Merity, Caiming Xiong, James Bradbury, and Richard Socher. Pointer sentinel mixture models. arXiv preprint arXiv:1609.07843, 2016.
328
+
329
+ Tomas Mikolov and Geoffrey Zweig. Context dependent recurrent neural network language model. SLT, 12:234–239, 2012.
330
+
331
+ Tomas Mikolov, Martin Karafiat, Lukas Burget, Jan Cernock ´ y, and Sanjeev Khudanpur. Recurrent\` neural network based language model. In Interspeech, volume 2, pp. 3, 2010.
332
+
333
+ Toma´s Mikolov, Ilya Sutskever, Anoop Deoras, Hai-Son Le, Stefan Kombrink, and Jan Cer- ˇ nocky. Subword language modeling with neural networks. preprint (http://www. fit. vutbr. cz/imikolov/rnnlm/char. pdf), 2012.
334
+
335
+ Tomas Mikolov, Kai Chen, Greg Corrado, and Jeffrey Dean. Efficient estimation of word representations in vector space. arXiv preprint arXiv:1301.3781, 2013.
336
+
337
+ Tomas Mikolov, Armand Joulin, Sumit Chopra, Michael Mathieu, and Marc’Aurelio Ranzato. Learning longer memory in recurrent neural networks. arXiv preprint arXiv:1412.7753, 2014.
338
+
339
+ Ofir Press and Lior Wolf. Using the output embedding to improve language models. In Proceedings of the 15th Conference of the European Chapter of the Association for Computational Linguistics: Volume 2, Short Papers, pp. 157–163. Association for Computational Linguistics, 2017. URL http://www.aclweb.org/anthology/E17-2025.
340
+
341
+ Brian Roark. Probabilistic top-down parsing and language modeling. Computational linguistics, 27 (2):249–276, 2001.
342
+
343
+ Brian Roark and Kristy Hollingshead. Classifying chart cells for quadratic complexity context-free inference. In Proceedings of the 22nd International Conference on Computational LinguisticsVolume 1, pp. 745–751. Association for Computational Linguistics, 2008.
344
+
345
+ Dominiek Sandra and Marcus Taft. Morphological structure, lexical representation and lexical access. Taylor & Francis, 1994.
346
+
347
+ Jurgen Schmidhuber. Deep learning in neural networks: An overview. ¨ Neural networks, 61:85–117, 2015.
348
+
349
+ Jrgen Schmidhuber. Neural sequence chunkers. Technical report, 1991.
350
+
351
+ Richard Socher, Christopher D Manning, and Andrew Y Ng. Learning continuous phrase representations and syntactic parsing with recursive neural networks. In Proceedings of the NIPS-2010 Deep Learning and Unsupervised Feature Learning Workshop, pp. 1–9, 2010.
352
+
353
+ Richard Socher, Alex Perelygin, Jean Wu, Jason Chuang, Christopher D Manning, Andrew Ng, and Christopher Potts. Recursive deep models for semantic compositionality over a sentiment treebank. In Proceedings of the 2013 conference on empirical methods in natural language processing, pp. 1631–1642, 2013.
354
+
355
+ Zach Solan, Eytan Ruppin, David Horn, and Shimon Edelman. Automatic acquisition and efficient representation of syntactic structures. In Advances in Neural Information Processing Systems, pp. 107–114, 2003.
356
+
357
+ Sainbayar Sukhbaatar, Jason Weston, Rob Fergus, et al. End-to-end memory networks. In Advances in neural information processing systems, pp. 2440–2448, 2015.
358
+
359
+ Kai Sheng Tai, Richard Socher, and Christopher D Manning. Improved semantic representations from tree-structured long short-term memory networks. arXiv preprint arXiv:1503.00075, 2015.
360
+
361
+ Ivan Titov and James Henderson. A latent variable model for generative dependency parsing. In Trends in Parsing Technology, pp. 35–55. Springer, 2010.
362
+
363
+ Adina Williams, Andrew Drozdov, and Samuel R Bowman. Learning to parse from a semantic objective: It works. is it syntax? arXiv preprint arXiv:1709.01121, 2017.
364
+
365
+ Shuangzhi Wu, Dongdong Zhang, Nan Yang, Mu Li, and Ming Zhou. Sequence-to-dependency neural machine translation. In Proceedings of the 55th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), volume 1, pp. 698–707, 2017.
366
+
367
+ Yuhuai Wu, Saizheng Zhang, Ying Zhang, Yoshua Bengio, and Ruslan R Salakhutdinov. On multiplicative integration with recurrent neural networks. In Advances in Neural Information Processing Systems, pp. 2856–2864, 2016.
368
+
369
+ Wojciech Zaremba, Ilya Sutskever, and Oriol Vinyals. Recurrent neural network regularization. arXiv preprint arXiv:1409.2329, 2014.
370
+
371
+ Xingxing Zhang, Liang Lu, and Mirella Lapata. Top-down tree long short-term memory networks. arXiv preprint arXiv:1511.00060, 2015.
372
+
373
+ Ganbin Zhou, Ping Luo, Rongyu Cao, Yijun Xiao, Fen Lin, Bo Chen, and Qing He. Generative neural machine for tree structures. arXiv preprint arXiv:1705.00321, 2017.
374
+
375
+ Julian Georg Zilly, Rupesh Kumar Srivastava, Jan Koutn´ık, and Jurgen Schmidhuber. Recurrent ¨ highway networks. arXiv preprint arXiv:1607.03474, 2016.
376
+
377
+ Barret Zoph and Quoc V Le. Neural architecture search with reinforcement learning. arXiv preprint arXiv:1611.01578, 2016.
378
+
379
+ # APPENDIX
380
+
381
+ A INFERRED TREE STRUCTURE
382
+
383
+ ![](images/d1ea6509793a2bc9eab6f9c6f5510965841493c1a2bb6fe483e84a58a5e3c604.jpg)
384
+ Figure 5: Syntactic structures of two different sentences inferred from $\{ d _ { i } \}$ given by Parsing Network.
385
+
386
+ The tree structure is inferred from the syntactic distances yielded by the Parsing Network. We first sort the $d _ { i }$ ’s in decreasing order. For the first $d _ { i }$ in the sorted sequence, we separate sentence into constituents $( ( x _ { < i } ) , ( x _ { i } , \bar { ( } x _ { > i } ) ) )$ . Then we separately repeat this operation for constituents $( x _ { < i } )$ and $( x _ { > i } )$ . Until the constituent contains only one word.
387
+
388
+ # B MODELING LOCAL STRUCTURE
389
+
390
+ In this section we give a probabilistic view on how to model the local structure of language. Given the nature of language, sparse connectivity can be enforced as a prior on how to improve generalization and interpretability of the model.
391
+
392
+ At time step $t$ , $p ( l _ { t } | x _ { 0 } , . . . , x _ { t } )$ represents the probability of choosing one out of $t$ possible local structures that defines the conditional dependencies. If ${ { l } _ { t } } \mathrm { ~ = ~ } t ^ { \prime }$ , it means $x _ { t }$ depends on all the previous hidden state from $m _ { t ^ { \prime } }$ to $m _ { t }$ $\left( t ^ { \prime } \leq t \right)$ .
393
+
394
+ A particularly flexible option for modeling $p ( l _ { t } | x _ { 0 } , . . . , x _ { t } )$ is the Dirichlet Process, since being nonparametric allows us to attend on as many words as there are in a sentence; i.e. number of possible structures (mixture components) grows with the length of the sentence. As a result, we can write the probability of $l _ { t + 1 } = t ^ { \prime }$ as a consequence of the stick breaking process 1:
395
+
396
+ $$
397
+ p ( l _ { t } = t ^ { \prime } | x _ { 0 } , . . . , x _ { t } ) = ( 1 - \alpha _ { t ^ { \prime } } ^ { t } ) \prod _ { j = t ^ { \prime } + 1 } ^ { t - 1 } \alpha _ { j } ^ { t }
398
+ $$
399
+
400
+ for $1 \leq t ^ { \prime } < t - 1$ , and
401
+
402
+ $$
403
+ p ( l _ { t } = t - 1 | x _ { 0 } , . . . , x _ { t } ) = ( 1 - \alpha _ { t - 1 } ^ { t } ) ; \qquad p ( l _ { t } = 0 | x _ { 0 } , . . . , x _ { t } ) = \prod _ { j = 1 } ^ { t - 1 } \alpha _ { j } ^ { t }
404
+ $$
405
+
406
+ where $\alpha _ { j } \ = \ 1 - \beta _ { j }$ and $\beta _ { j }$ is a sample from a Beta distribution. Once we sample $l _ { t }$ from the process, the connectivity is realized by a element-wise multiplication of an attention weight vector with a masking vector $g _ { t }$ defined in Eq. 1. In this way, $x _ { t }$ becomes functionally independent of all $x _ { s }$ for all $s < l _ { t }$ . The expectation of this operation is the CDF of the probability of $l$ , since
407
+
408
+ $$
409
+ \begin{array} { l } { { \displaystyle { \bf E } _ { l _ { t } } [ g _ { t } ^ { \{ t ^ { \prime } \} } ] = \prod _ { j = 1 } \alpha _ { j } ^ { t } + ( 1 - \alpha _ { 1 } ^ { t } ) \prod _ { j = 2 } \alpha _ { j } ^ { t } + . . . + ( 1 - \alpha _ { t ^ { \prime } } ^ { t } ) \prod _ { j = t ^ { \prime } + 1 } \alpha _ { j } ^ { t } } } \\ { { \displaystyle \qquad = \sum _ { k = 0 } ^ { t ^ { \prime } } p ( l _ { t } = k | x _ { 0 } , . . . , x _ { t } ) = { \bf P } ( l _ { t } \le t ^ { \prime } ) } } \end{array}
410
+ $$
411
+
412
+ By telescopic cancellation, the CDF can be expressed in a succinct way:
413
+
414
+ $$
415
+ \mathbf { P } ( l _ { t } \leq t ^ { \prime } ) = \prod _ { j = t ^ { \prime } + 1 } ^ { t - 1 } \alpha _ { j } ^ { t }
416
+ $$
417
+
418
+ for $t ^ { \prime } < t$ , and $\mathbf { P } ( l _ { t } \ \leq \ t ) = 1$ . However, being Bayesian nonparametric and assuming a latent variable model require approximate inference. Hence, we have the following relaxations
419
+
420
+ 1. First, we relax the assumption and parameterize $\alpha _ { j } ^ { t }$ as a deterministic function depending on all the previous words, which we will describe in the next section. 2. We replace the discrete decision on the graph structure with a soft attention mechanism, by multiplying attention weight with the multiplicative gate:
421
+
422
+ $$
423
+ g _ { i } ^ { t } = \prod _ { j = i + 1 } ^ { t } \alpha _ { j } ^ { t }
424
+ $$
425
+
426
+ With these relaxations, Eq. (3) can be approximated by using a soft gating vector to update the hidden state $h$ and the predictive function $f$ . This approximation is reasonable since the gate is the expected value of the discrete masking operation described above.
427
+
428
+ # C NO PARTIAL OVERLAPPING IN DEPENDENCY RANGES
429
+
430
+ In this appendix, we show that having no partial overlapping in dependency ranges is an essential property for recovering a valid tree structure, and PRPN can provide a binary version of $g _ { i } ^ { t }$ , that have this property.
431
+
432
+ The masking vector $g _ { i } ^ { t }$ introduced in Section 4.1 determines the range of dependency, i.e., for the word $x _ { t }$ we have $g _ { i } ^ { t } = 1$ for all $l _ { t } \leq i < t$ . All the words fall into the range $l _ { t } \leq i < t$ is considered as $x _ { t }$ ’s sibling or offspring of its sibling. If the dependency ranges of two words are disjoint with each other, that means the two words belong to two different subtrees. If one range contains another, that means the one with smaller range is a sibling, or is an offspring of a sibling of the other word. However, if they partially overlaps, they can’t form a valid tree.
433
+
434
+ While Eq.5 and Eq.6 provide a soft version of dependency range, we can recover a binary version by setting $\tau$ in Eq.6 to $+ \infty$ . The binary version of $\alpha _ { j } ^ { t }$ corresponding to Eq. 6 becomes:
435
+
436
+ $$
437
+ \alpha _ { j } ^ { t } = \frac { \mathrm { s i g n } \left( d _ { t } - d _ { j + 1 } \right) + 1 } { 2 }
438
+ $$
439
+
440
+ which is basically the sign of comparing $d _ { t }$ and $d _ { j + 1 }$ , scaled to the range of 0 and 1. Then for each of its previous token the gate value $g _ { i } ^ { t }$ can be computed through Eq.5.
441
+
442
+ Now for a certain $x _ { t }$ , we have
443
+
444
+ $$
445
+ g _ { i } ^ { t } = { \left\{ \begin{array} { l l } { 1 , } & { t ^ { \prime } \leq i < t } \\ { 0 , } & { 0 \leq i < t ^ { \prime } } \end{array} \right. }
446
+ $$
447
+
448
+ where
449
+
450
+ $$
451
+ t ^ { \prime } = \operatorname* { m a x } i , \quad s . t . \quad d _ { i } > d _ { t }
452
+ $$
453
+
454
+ Now all the words that fall into the range $t ^ { \prime } \leq i < t$ are considered as either sibling of $x _ { t }$ , or offspring of a sibling of $x _ { t }$ (Figure 3). The essential point here is that, under this parameterization, the dependency range of any two tokens won’t partially overlap. Here we provide a terse proof:
455
+
456
+ Proof. Let’s assume that the dependency range of $x _ { v }$ and $x _ { n }$ partially overlaps. We should have $g _ { i } ^ { u } \ = \ 1$ for $u \leq i < v$ and $g _ { i } ^ { n } \ = \ 1$ for $m \leq i < n$ . Without losing generality, we assume $u < m < v < n$ so that the two dependency ranges overlap in the range $[ m , v ]$ .
457
+
458
+ 1. For $x _ { v }$ , we have $\alpha _ { i } ^ { v } = 1$ for all $u \leq i < v$ . According to Eq. 6 and 5, we have $d _ { i } < d _ { v }$ for all $u \leq i < v$ . Since $u < m$ , we have $d _ { m } < d _ { v }$ . 2. Similarly, for $x _ { n }$ , we have $d _ { i } < d _ { n }$ for all $m \leq i < n$ . Since $m < v$ , we have $d _ { v } < d _ { n }$ . On the other hand, since the range stops at $m$ , we should also have $d _ { m } > d _ { n }$ . Thus $d _ { m } > d _ { v }$ .
459
+
460
+ Items 1 and 2 are contradictory, so the dependency ranges of $x _ { v }$ and $x _ { n }$ won’t partially overlap.
461
+
462
+ # D PROPERTIES AND INTUITIONS OF $g _ { i } ^ { t }$ AND $d _ { i }$
463
+
464
+ First, for any fixed $t$ , $g _ { i } ^ { t }$ is monotonic in $i$ . This ensures that $g _ { i } ^ { t }$ still provides soft truncation to define a dependency range.
465
+
466
+ The second property comes from $\tau$ . The hyperparameter $\tau$ has an interesting effect on the tree structure: if it is set to 0, then for all $t$ , the gates $g _ { i } ^ { t }$ will be open to all of $e _ { t }$ ’s predecessors, which will result in a flat tree where all tokens are direct children of the root node; as $\tau$ becomes larger, the number of levels of hierarchy in the tree increases. As it approaches $+ \mathrm { i n f }$ , the hardtanh $( \cdot )$ becomes $\mathrm { s i g n } ( \cdot )$ and the dependency ranges form a valid tree. Note that, due to the linear part of the gating mechanism, which benefits training, when $\tau$ has a value in between the two extremes the truncation range for each token may overlap. That may sometimes result in vagueness in some part of the inferred tree. To eliminate this vagueness and ensure a valid tree, at test time we use $\tau = + \mathrm { i n f }$ .
467
+
468
+ Under this framework, the values of syntactic distance have more intuitive meanings. If two adjacent words are siblings of each other, the syntactic distance should approximate zero; otherwise, if they belong to different subtrees, they should have a larger syntactic distance. In the extreme case, the syntactic distance approaches 1 if the two words have no subtree in common. In Figure 3 we show the syntactic distances for each adjacent token pair which results in the tree shown in Figure 1.
469
+
470
+ # E BASELINE METHODS FOR UNSUPERVISED CONSTITUENCY PARSING
471
+
472
+ Our model is compared with the same baseline methods as in (Klein & Manning, 2005). RANDOM chooses a binary tree uniformly at random from the set of binary trees. This is the unsupervised baseline. LBRANCH and RBRANCH choose the completely left- and right-branching structures, respectively. RBRANCH is a frequently used baseline for supervised parsing, but it should be stressed that it encodes a significant fact about English structure, and an induction system need not beat it to claim a degree of success. UPPER BOUND is the upper bound on how well a binary system can do against the Treebank sentences. Because the Treebank sentences are generally more flat than binary, limiting the maximum precision which can be attained, since additional brackets added to provide a binary tree will be counted as wrong.
473
+
474
+ We also compared our model with other unsupervised constituency parsing methods. DEP-PCFG is dependency-structured PCFG (Carroll & Charniak, 1992). CCM is constituent-context model (Klein & Manning, 2002). DMV is an unsupervised dependency parsing model. $D M V { + } C C M$ is a combined model that jointly learn both constituency and dependency parser (Klein & Manning, 2004).
parse/train/rkgOLb-0W/rkgOLb-0W_content_list.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/rkgOLb-0W/rkgOLb-0W_middle.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/rkgOLb-0W/rkgOLb-0W_model.json ADDED
The diff for this file is too large to render. See raw diff