ZHANGYUXUAN-zR commited on
Commit
b977179
·
verified ·
1 Parent(s): 707461c

Add files using upload-large-folder tool

Browse files
parse/train/1ODSsnoMBav/1ODSsnoMBav.md ADDED
@@ -0,0 +1,273 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # CLDA: Contrastive Learning for Semi-Supervised Domain Adaptation
2
+
3
+ Ankit Singh
4
+
5
+ Department of Computer Science Indian Institute of Technology, Madras singh.ankit@cse.iitm.ac.in
6
+
7
+ # Abstract
8
+
9
+ Unsupervised Domain Adaptation (UDA) aims to align the labeled source distribution with the unlabeled target distribution to obtain domain invariant predictive models. However, the application of well-known UDA approaches does not generalize well in Semi-Supervised Domain Adaptation (SSDA) scenarios where few labeled samples from the target domain are available. This paper proposes a simple Contrastive Learning framework for semi-supervised Domain Adaptation (CLDA) that attempts to bridge the intra-domain gap between the labeled and unlabeled target distributions and the inter-domain gap between source and unlabeled target distribution in SSDA. We suggest employing class-wise contrastive learning to reduce the inter-domain gap and instance-level contrastive alignment between the original(input image) and strongly augmented unlabeled target images to minimize the intra-domain discrepancy. We have empirically shown that both of these modules complement each other to achieve superior performance. Experiments on three well-known domain adaptation benchmark datasets, namely DomainNet, Office-Home, and Office31, demonstrate the effectiveness of our approach. CLDA achieves state-of-the-art results on all the above datasets.
10
+
11
+ # 1 Introduction
12
+
13
+ Deep Convolutional networks [30, 52] have shown impressive performance in various computer vision tasks, e.g., image classification [19, 22] and action recognition [48, 23, 57, 32]. However, there is an inherent problem of generalizability with deep-learning models, i.e., models trained on one dataset(source domain) does not perform well on another domain. This loss of generalization is due to the presence of domain shift [11, 55] across the dataset. Recent works [46, 29] have shown that the presence of few labeled data from the target domain can significantly boost the performance of the convolutional neural network(CNN) based models. This observation led to the formulation of Semi-Supervised Domain Adaption (SSDA), which is a variant of Unsupervised Domain Adaptation where we have access to a few labeled samples from the target domain.
14
+
15
+ Unsupervised domain adaptation methods [42, 12, 36, 51, 35] try to transfer knowledge from the label rich source domain to the unlabeled target domain. Many such existing domain adaptation approaches [42, 12, 51] align the features of the source distribution with the target distribution without considering the category of the samples. These class-agnostic methods fail to generate discriminative features when aligning global distributions. Recently, owing to the success of contrastive approaches [6, 18, 39], in self-representation learning, some recent works [26, 28] have turned to instance-based contrastive approaches to reduce discrepancies across domains.
16
+
17
+ [46] reveals that the direct application of the well-known UDA approaches in Semi-Supervised Domain Adaptation yields sub-optimal performance. [29] has shown that supervision from labeled source and target samples can only ensure the partial cross-domain feature alignment. This creates aligned and unaligned sub-distributions of the target domain, causing intra-domain discrepancy apart from inter-domain discrepancy in SSDA.
18
+
19
+ ![](images/6b685103502be02c0b22dad148a39834efc5e2349ac431e7ecf24318a048e14e.jpg)
20
+ Figure 1: Conceptual description of CLDA approach. (a) Intial distribution of samples from both domain .(b) Instance Contrastive Alignment ensures unlabeled target samples move into the low entropy area forming robust clusters (c) Inter-Domain Contrastive Alignment minimizes the distance between the clusters of same class from both domain (d) The clusters of both domain are well aligned and samples are far away from decision boundary.
21
+
22
+ In this work, we propose CLDA, a simple single-stage novel contrastive learning framework to address the aforementioned problem. Our framework contains two significant components to learn domain agnostic representation. First, Inter-Domain Contrastive Alignment reduces the discrepancy between centroids of the same class from the source and the target domain while increasing the distance between the class centroids of different classes from both source and target domain. This ensures clusters of the same class from both domains are near each other in latent space than the clusters of the other classes from both domains.
23
+
24
+ Second, inspired by the success of self-representation learning in semi-supervised settings [17, 6, 49], we propose to use Instance Contrastive Alignment to reduce the intra-domain discrepancy. In this, we first generate the augmented views of the unlabeled target images using image augmentation methods. Alignment of the features of the original and augmented images of the unlabeled samples from the target domain ensures that they are closer to each other in latent space. The alignment between two variants of the same image ensures that the classifier boundary lies in the low-density regions assuring that the feature representations of two variants of the unlabeled target images are similar, which helps to generate better clusters for the target domain.
25
+
26
+ In summary, our key contributions are as follows. 1) We propose a novel, simple single-stage training framework for Semi-supervised Domain Adaptation. 2)We propose using alignment at class centroids and instance levels to reduce inter and intra domain discrepancies present in SSDA. 3)We evaluate the effectiveness of different augmentation approaches, for instance-based contrastive alignment in the SSDA setting. 4)We evaluate our approach over three well-known Domain Adaptation datasets (DomainNet, Office-Home, and Office31) to gain insights. Our approach achieves the state of the art results across multiple datasets showing its effectiveness. We perform extensive ablation experiments highlighting the role of different components of our framework.
27
+
28
+ # 2 Related Works
29
+
30
+ # 2.1 Unsupervised Domain Adaptation
31
+
32
+ Unsupervised Domain Adaptation (UDA) [14] is a well-studied problem, and most UDA algorithms reduce the domain gap by matching the features of the sources and target domain [16, 4, 24, 36, 51, 27]. Feature-based alignment methods reduce the global divergence [16, 51] between source and target distribution. Adversarial learning [12, 5, 34, 35, 42, 41] based approaches have shown impressive performance in reducing the divergence between source and target domains. It involves training the model to generate features to deceive the domain classifier, invariantly making the generated features domain agnostic. Recently, Image translation methods [20, 21, 38] have been explored in UDA where an image from the target domain is translated to the source domain to be treated as an image from the source domain to overcome the divergence present across domains.
33
+
34
+ Despite remarkable progress in UDA, [46] shows the UDA approaches do not perform well in the SSDA setting, which we consider in this work.
35
+
36
+ # 2.2 Semi-Supervised Learning
37
+
38
+ Semi-Supervised Learning(SSL) aims to leverage the vast amount of unlabeled data with limited labeled data to improve classifier performance. The main difference between SSL and SSDA is that SSL uses data sampled from the same distribution while SSDA deals with data sampled from two domains with inherent domain discrepancy. The current line of work in SSL [50, 3, 31, 10] follows consistency-based approaches to reduce the intra-domain gap. Mean teacher [53] uses two copies of the same model (student model and teacher model) to ensure consistency across augmented views of the images. Weights of the teacher model are updated as the exponential moving average of the weights of the student model. Mix-Match [3] and ReMixMatch [2] use interpolation between labeled and unlabeled data to generate perturbed features. Recently introduced FixMatch [50] achieves impressive performance using the confident pseudo labels of the unlabeled samples and treating them as labels for the strongly perturbed samples. However, direct application of SSL in the SSDA setting yields sub-optimal performance as the presumption in the SSL is that distributions of labeled and unlabeled data are identical, which is not the case in SSDA.
39
+
40
+ # 2.3 Contrastive Learning
41
+
42
+ Contrastive Learning(CL) has shown impressive performance in self-representation learning [6, 1, 18, 54, 39]. Most contrastive learning methods align the representations of the positive pair (similar images) to be close to each other while making negative pairs apart. In semantic segmentation, [33] uses patch-wise contrastive learning to reduce the domain divergence by aligning the similar patches across domains. In domain adaptation, contrastive learning [28, 26] has been applied for alignment at the instance level to learn domain agnostic representations. [26, 28] use samples from the same class as positive pairs, and samples from different classes are counted as negative pairs. [26] modifies Maximum Mean Discrepancy (MMD) [16] loss to be used as a contrastive loss. In contrast to [28, 26], our work proposes to use contrastive learning in SSDA setting both at the class and instance level (across perturbed samples of the same image) to learn the semantic structure of the data better.
43
+
44
+ # 2.4 Semi-Supervised Domain Adaptation
45
+
46
+ Semi-Supervised Domain Adaptation (SSDA) aims to reduce the discrepancy between the source and target distribution in the presence of limited labeled target samples. [46] first proposed to align the source and target distributions using adversarial training. [29] shows the presence of intra domain discrepancy in the target distribution and introduces a framework to mitigate it. [25] uses consistency alongside multiple adversarial strategies on top of MME [46]. [9] introduced the meta-learning framework for Semi-Supervised Domain Adaptation. [58] breaks down the SSDA problem into two subproblems, namely, SSL in the target domain and UDA problem across the source and target domains, and learn the optimal weights of the network using co-training. [37] proposed to use pretraining of the feature extractor and consistency across perturbed samples as a simple yet effective strategy for SSDA. [44] introduces a framework for SSDA consisting of a shared feature extractor and two classifiers with opposite purposes, which are trained in an alternative fashion; where one classifier tries to cluster the target samples while the other scatter the source samples, so that target features are well aligned with source domain features. Most of the above approaches are based on adversarial training, while our work proposes to use contrastive learning-based feature alignment at the class level and the instance level to reduce discrepancy across domains.
47
+
48
+ # 3 Methodology
49
+
50
+ In this section, we present our novel Semi-Supervised Domain Adaptation approach to learn domain agnostic representation. We will first introduce the background and notations used in our work and then describe our approach and its components in detail.
51
+
52
+ ![](images/e51ffd9d13deb32f523a10afdc3af7280418f9b75dd1bbf0946ee7f544d92b65.jpg)
53
+ Figure 2: Outline of our CLDA Framework Our approach consists of aligning the outputs of the neural network at two levels. At the instance level, we try to maximize the similarity between features of unlabeled target images and strongly augmented unlabeled target images using Instance Contrastive Alignment. At the class level, we pass the images from both domains through the network, where we assign the labels to features of unlabeled target images and compute the centroids of each class of the target domain. Similarly, we compute the centroids for source domain features using their class labels. Finally, we maximize the similarity between centroids of the same class across domains by employing Inter-Domain Contrastive Alignment. We also used cross-entropy loss on the labeled source and target images, apart from the above components in our framework.
54
+
55
+ # 3.1 Problem Formulation
56
+
57
+ In Semi-Supervised Domain Adaptation, we have datasets sampled from two domains. The source dataset contains labeled images $\mathcal { D } _ { s } = \{ ( x _ { i } ^ { s } , y _ { i } ^ { s } ) \} _ { i = 1 } ^ { N _ { s } } \subset \mathcal { R } ^ { d } \times \mathbf { \bar { \mathcal { V } } }$ sampled from some distribution $P _ { S } ( X , Y )$ . Besides that, we have two sets of data sampled from target domain distribution $P _ { T } ( X , Y )$ . We denote the labeled set of images sampled from the target domain as $\mathcal { D } _ { l t } = \{ ( x _ { i } ^ { l t } , y _ { i } ^ { l t } ) \} _ { i = 1 } ^ { N _ { l t } }$ . The unlabeled set sampled from target domain $\mathcal { D } _ { t } = \{ ( x _ { i } ^ { t } ) \} _ { i = 1 } ^ { N _ { t } }$ contains large number of images $( N _ { t } \gg N _ { l t } )$ without any corresponding labels associated with them. We also denote the labeled data from both domains as $\mathcal { D } _ { l } = \mathcal { D } _ { s } \cup \mathcal { D } _ { l t }$ . Labels $y _ { i } ^ { s }$ and $y _ { i } ^ { l t }$ of the samples from source and labeled target set correspond to one of the categories of the dataset having $K$ different classes/categories $i . e$ $\bar { Y = \{ 1 , 2 , . . . \bar { K } \} }$ . Our goal is to learn a task specific classifier using $D _ { s } , D _ { l t }$ and $D _ { t }$ to accurately predict labels on test data from target domain.
58
+
59
+ # 3.2 Supervised Training
60
+
61
+ Labeled source and target samples are passed through the CNN-based feature extractor $\mathcal { G } ( . )$ to obtain corresponding features, which are then passed through task-specific classifier $\mathcal F ( . )$ to minimize the well-known cross-entropy loss on the labeled images from both source and target domains.
62
+
63
+ $$
64
+ \mathcal { L } _ { s u p } = - \sum _ { k = 1 } ^ { K } ( y ^ { i } ) _ { k } \log ( \mathcal { F } ( \mathcal { G } ( ( x _ { l } ^ { i } ) ) _ { k }
65
+ $$
66
+
67
+ # 3.3 Inter-Domain Contrastive Alignment
68
+
69
+ Our method is based on the observation that the samples from the same category across domains must cluster in the latent space. However, this is observed only for the source domain due to the availability of the labels. Samples from the target domain do not align to form clusters due to the domain shift between the target and the source distributions. This discrepancy between the cluster of the same category across domains is reduced by aligning the centroids of each class of source and target domain. [6, 17] have shown that having a separate projection space is beneficial for contrastive training. Instead of using a separate projection, we have used the outputs from the task-specific classifier as features to align the clusters across the domain.
70
+
71
+ We represent the centroid of the images from the source domain belonging to class $k$ as the mean of their features, which can be written as
72
+
73
+ $$
74
+ C _ { k } ^ { s } = \frac { \displaystyle \sum _ { i = 1 } ^ { i = B } \mathbb { 1 } _ { \{ y _ { i } ^ { s } = k \} } \mathcal { F } ( \mathcal { G } ( x _ { i } ^ { s } ) ) } { \displaystyle \sum _ { i = 1 } ^ { i = B } \mathbb { 1 } _ { \{ y _ { i } ^ { s } = k \} } }
75
+ $$
76
+
77
+ where $B$ is the size of batch. We maintain a memory bank $\displaystyle C ^ { s } = [ C _ { 1 } ^ { s } , C _ { 2 } ^ { s } , . . . . C _ { K } ^ { s } ] )$ to store the centroids of each class from source domain. We use exponential moving average to update these centroid values during the training
78
+
79
+ $$
80
+ C _ { k } ^ { s } = \rho ( C _ { k } ^ { s } ) _ { s t e p } + ( 1 - \rho ) ( C _ { k } ^ { s } ) _ { s t e p - 1 }
81
+ $$
82
+
83
+ where $\rho$ is a momentum term, and $( C _ { k } ^ { s } ) _ { s t e p }$ and $( C _ { k } ^ { s } ) _ { s t e p - 1 }$ are the centroid values of class $k$ at the current and previous step, respectively.
84
+
85
+ We also need to cluster the unlabeled target samples for Inter-Domain Contrastive Alignment. The pseudo labels obtained from the task specific classifier as shown in Eq (3) is used as the class labels for the corresponding unlabeled target samples.
86
+
87
+ $$
88
+ \hat { y _ { i } ^ { t } } = a r g m a x ( ( \mathcal { F } ( \mathcal { G } ( x _ { i } ^ { t } ) ) )
89
+ $$
90
+
91
+ Similar to the source domain , we also calculate the separate cluster centroid $C _ { k } ^ { t }$ for each of the class $k$ of the target samples present in the minibatch as per the Eq (2) where unlabeled target images replace the images from the source domain with their corresponding pseudo label. The model is then trained to maximize the similarity between the cluster representation of each class $k$ from the source and the target domain. $C _ { k } ^ { s }$ and $C _ { k } ^ { t }$ form the positive pair while the remaining cluster centroids from both domains form the negative pairs. The remaining clusters from both domains are pushed apart in the latent space. This is achieved through employing a modified NT-Xent (normalized temperature-scaled cross-entropy) contrastive loss [6, 39, 49, 33] for domain adaptation given by
92
+
93
+ $$
94
+ \mathcal { L } _ { c l u } ( C _ { i } ^ { t } , C _ { i } ^ { s } ) = - \log \frac { h \bigl ( C _ { i } ^ { t } , C _ { i } ^ { s } \bigr ) } { h \bigl ( C _ { i } ^ { t } , C _ { i } ^ { s } \bigr ) + \underset { t \in \{ s , t \} } { \overset { K } { \sum } } \mathbb { 1 } _ { \{ r \neq i \} } h \bigl ( C _ { i } ^ { t } , C _ { r } ^ { q } \bigr ) }
95
+ $$
96
+
97
+ where $\begin{array} { r } { h ( \mathbf { u } , \mathbf { v } ) = \exp \big ( \frac { \mathbf { u } ^ { \top } \mathbf { v } } { \| \mathbf { u } \| _ { 2 } \| \mathbf { v } \| _ { 2 } } / \tau \big ) } \end{array}$ measures the exponential of cosine similarity , $\mathbb { 1 }$ is an indicator function and $\tau$ is the temperature hyperparameter.
98
+
99
+ # 3.4 Instance Contrastive Alignment
100
+
101
+ Recent works on contrastive learning [18, 39, 6] show encouraging results in single domain settings. [28] extends contrastive learning into multi-domain settings. Inspired by such success, we employ Instance Contrastive Learning to form stable and correct cluster cores in the target domain.
102
+
103
+ To perform contrastive alignment at the instance level, we first generate a strongly augmented version of the unlabeled target image i.e $\tilde { x _ { i } ^ { t } } = \psi ( x _ { i } ^ { t } )$ where $\psi ( . )$ is the strong augmentation function [8]. Next, we employ the NT-Xent loss [6, 39] as defined in Eq (5) to ensure that these two variants of the same image are closer to each other in the latent space while the rest of the images in minibatch of size $B$ are pushed apart. This idea stems from the cluster assumption in an ideal classifier, which states the decision boundary should lie in the low-density region, ensuring consistent prediction for different augmented variants of the same image.
104
+
105
+ $$
106
+ \mathcal { L } _ { i n s } ( \tilde { x } _ { i } ^ { t } , x _ { i } ^ { t } ) = - \log \frac { h \big ( \mathcal { F } ( \mathcal { G } ( \tilde { x } _ { i } ^ { t } ) , \mathcal { F } ( \mathcal { G } ( x _ { i } ^ { t } ) ) ) } { \displaystyle \sum _ { r = 1 } ^ { B } h \big ( \mathcal { F } ( \mathcal { G } ( \tilde { x } _ { i } ^ { t } ) ) , \mathcal { F } ( \mathcal { G } ( x _ { r } ^ { t } ) ) \big ) + \displaystyle \sum _ { r = 1 } ^ { B } \mathbb { 1 } _ { \{ r \neq i \} } h \big ( \mathcal { F } ( \mathcal { G } ( \tilde { x } _ { i } ^ { t } ) ) , \mathcal { F } ( \mathcal { G } ( \tilde { x } _ { r } ^ { t } ) ) \big ) }
107
+ $$
108
+
109
+ In SSDA, [29] has shown that target distribution gets divided into aligned and unaligned subdistribution in the presence of very few labeled target data. Thus, aligning the unaligned subdistribution can lead to improved performance, while perturbing the aligned sub-distribution can result in a negative transfer. Therefore, we only propagate the gradients for strongly augmented images to avoid perturbing the aligned sub-distribution in the target domain.
110
+
111
+ [6] shows stronger augmentation in contrastive learning leads to improved performance. Consistent prediction across the input and strongly augmented unlabeled images in Instance Contrastive Alignment forces the unaligned target sub-distribution to move away from the low-density region towards aligned distribution. This ensures better clustering in the unlabeled target distribution, which is validated by improved accuracy as shown in Table 5 after employing Instance Contrastive Alignment with Inter-Domain Contrastive Alignment.
112
+
113
+ Both of the components of the CLDA framework are necessary for the improved performance, as shown in Table 5 . Instance Contrastive Alignment ensures that unlabeled target samples are consistent and are in the high-density region. However, it does not assure alignment between source and unlabeled target samples. Inter-Domain Contrastive Alignment reduces the discrepancy between unlabeled target samples and source domain but unlabeled target samples closer to the decision boundary might get pushed towards the wrong classes resulting in negative transfer. Thus, combining both components results in a much better alignment of the unlabeled target samples towards the source domain, leading to improved performance of the framework.
114
+
115
+ # 3.5 Overall framework and training objective
116
+
117
+ The overall training objective employs supervised loss, Inter-Domain Contrastive Alignment and Instance Contrastive Alignment which can be formulated as follows:
118
+
119
+ $$
120
+ \mathcal { L } _ { t o t } = \mathcal { L } _ { s u p } + \alpha * \mathcal { L } _ { c l u } + \beta * \mathcal { L } _ { i n s }
121
+ $$
122
+
123
+ We train the model in our framework by employing overall training loss described as in (6).
124
+
125
+ # 4 Experiments
126
+
127
+ # 4.1 Experimental Setup
128
+
129
+ We evaluate the effectiveness of our approach on three different domain adaptation datasets: DomainNet [43], Office-Home [56] and Office31 [45]. DomainNet [43] is a large-scale domain adaptation dataset with 345 classes across 6 domains. Following MME [46], we use a subset of the dataset containing 126 categories across four domains: Real(R), Clipart(C), Sketch(S), and Painting(P). The performance on DomainNet is evaluated using 7 different combinations out of possible 12 combinations. Office-Home [56] is another widely used domain adaptation benchmark dataset with 65 classes across four domains: Art(Ar), Product $( \mathrm { P r } )$ , Clipart(Cl), and Real (Rl). We perform experiments on all possible combinations of 4 domains. Office31 [45] is a relatively smaller dataset containing just 31 categories of data across three domains- Amazon(A), Dslr(D), Webcam(W). Following prior work [46, 29], we evaluate our approach on two combinations for the office31 dataset.
130
+
131
+ For the fair comparison, we use the data-splits (train, validation, and test splits) released by [46] on Github 1. We use the same settings for the benchmark datasets as in the prior work [46, 29], including the number of labeled samples in the target domain, which are consistent across all experiments.
132
+
133
+ # 4.2 Implementation Details
134
+
135
+ Similar to the previous works on SSDA [46, 29, 9], we use Resnet34 and Alexnet as the backbone networks in our paper. We only used VGG for Office31 due to its higher memory requirements. The feature generator model is initialized with ImageNet weights, and the classifier is randomly initialized and has the same architecture as in [46, 29, 9]. All our experiments are performed using Pytorch [40].We use an identical set of hyperparameters $\langle \alpha = 4$ , $\beta = 1$ ) across all our experiments other than minibatch size. All the hyperparameters values are decided using validation performance on Product to Art experiments on the Office-Home dataset. We have set $\tau = 5$ in our experiments. Each minibatch of size $B$ contains an equal number of source and labeled target examples, while the number of unlabeled target samples is $\mu \times B$ . We study the effect of $\mu$ in section 4.5. Resnet34 experiments are performed with minibatch size, $B = 3 2$ and Alexnet models are trained with $B = 2 4$ We use $\mu = 4$ for all our experiments. We use SGD optimizer with a momentum of 0.9 and an initial learning rate of 0.01 with cosine learning rate decay for all our experiments. Weight decay is set to 0.0005 for all our models. Other details of the experiments are included in the supplementary.
136
+
137
+ Table 1: Performance Comparison in Office-Home. Numbers show top-1 accuracy values for different domain adaptation scenarios under 3-shot setting using Alexnet and Resnet34 as backbone networks. We have highlighted the best method for each transfer task. CLDA surpasses all the baseline methods in most adaptation scenarios. Our Proposed framework achieves the best average performance among all compared methods.
138
+
139
+ <table><tr><td>Net</td><td>Method</td><td>R1→C1</td><td>R1→Pr</td><td>Rl→Ar</td><td>Pr-→Rl</td><td>Pr→Cl</td><td>Pr→Ar</td><td>Ar→Pl</td><td>Ar-→C1</td><td>Ar-→Rl</td><td>CI-→Rl</td><td>Cl→Ar</td><td>C1-→Pr</td><td>Mean</td></tr><tr><td rowspan="10">Alexnet</td><td>S+T</td><td>44.6</td><td>66.7</td><td>47.7</td><td>57.8</td><td>44.4</td><td>36.1</td><td>57.6</td><td>38.8</td><td>57.0</td><td>54.3</td><td>37.5</td><td>57.9</td><td>50.0</td></tr><tr><td>DANN</td><td>47.2</td><td>66.7</td><td>46.6</td><td>58.1</td><td>44.4</td><td>36.1</td><td>57.2</td><td>39.8</td><td>56.6</td><td>54.3</td><td>38.6</td><td>57.9</td><td>50.3</td></tr><tr><td>ADR</td><td>37.8</td><td>63.5</td><td>45.4</td><td>53.5</td><td>32.5</td><td>32.2</td><td>49.5</td><td>31.8</td><td>53.4</td><td>49.7</td><td>34.2</td><td>50.4</td><td>44.5</td></tr><tr><td>CDAN</td><td>36.1</td><td>62.3</td><td>42.2</td><td>52.7</td><td>28.0</td><td>27.8</td><td>48.7</td><td>28.0</td><td>51.3</td><td>41.0</td><td>26.8</td><td>49.9</td><td>41.2</td></tr><tr><td>ENT</td><td>44.9</td><td>70.4</td><td>47.1</td><td>60.3</td><td>41.2</td><td>34.6</td><td>60.7</td><td>37.8</td><td>60.5</td><td>58.0</td><td>31.8</td><td>63.4</td><td>50.9</td></tr><tr><td>MME</td><td>51.2</td><td>73.0</td><td>50.3</td><td>61.6</td><td>47.2</td><td>40.7</td><td>63.9</td><td>43.8</td><td>61.4</td><td>59.9</td><td>44.7</td><td>64.7</td><td>55.2</td></tr><tr><td>Meta-MME</td><td>50.3</td><td>-</td><td>-</td><td>-</td><td>48.3</td><td>40.3</td><td>:</td><td>44.5</td><td>-</td><td>-</td><td>44.5</td><td>-</td><td>-</td></tr><tr><td>BiAT</td><td>-</td><td>-</td><td>-</td><td>-</td><td>-</td><td>-</td><td>-</td><td>-</td><td>-</td><td>-</td><td>-</td><td>-</td><td>56.4</td></tr><tr><td>APE CLDA(ours)</td><td>51.9</td><td>74.6</td><td>51.2</td><td>61.6</td><td>47.9</td><td>42.1</td><td>65.5</td><td>44.5</td><td>60.9</td><td>58.1</td><td>44.3</td><td>64.8</td><td>55.6</td></tr><tr><td></td><td>51.5</td><td>74.1</td><td>54.3</td><td>67.0</td><td>47.9</td><td>47.0</td><td>65.8</td><td>47.4</td><td>66.6</td><td>64.1</td><td>46.8</td><td>67.5</td><td>58.3</td></tr><tr><td rowspan="7">Resnet34</td><td>S+T</td><td>55.7</td><td>80.8</td><td>67.8</td><td>73.1</td><td>53.8</td><td>63.5</td><td>73.1</td><td>54.0</td><td>74.2</td><td>68.3</td><td>57.6</td><td>72.3</td><td>66.2</td></tr><tr><td>DANN</td><td>57.3</td><td>75.5</td><td>65.2</td><td>69.2</td><td>51.8</td><td>56.6</td><td>68.3</td><td>54.7</td><td>73.8</td><td>67.1</td><td>55.1</td><td>67.5</td><td>63.5</td></tr><tr><td>ENT</td><td>62.6</td><td>85.7</td><td>70.2</td><td>79.9</td><td>60.5</td><td>63.9</td><td>79.5</td><td>61.3</td><td>79.1</td><td>76.4</td><td>64.7</td><td>79.1</td><td>71.9</td></tr><tr><td>MME</td><td>64.6</td><td>85.5</td><td>71.3</td><td>80.1</td><td>64.6</td><td>65.5</td><td>79.0</td><td>63.6</td><td>79.7</td><td>76.6</td><td>67.2</td><td>79.3</td><td>73.1</td></tr><tr><td>Meta-MME</td><td>65.2</td><td>-</td><td>-</td><td>-</td><td>64.5</td><td>66.7</td><td>-</td><td>63.3</td><td>-</td><td>-</td><td>67.5</td><td>-</td><td>-</td></tr><tr><td>APE</td><td>66.4</td><td>86.2</td><td>73.4</td><td>82.0</td><td>65.2</td><td>66.1</td><td>81.1</td><td>63.9</td><td>80.2</td><td>76.8</td><td>66.6</td><td>79.9</td><td>74.0</td></tr><tr><td>CLDA (ours)</td><td>66.0</td><td>87.6</td><td>76.7</td><td>82.2</td><td>63.9</td><td>72.4</td><td>81.4</td><td>63.4</td><td>81.3</td><td>80.3</td><td>70.5</td><td>80.9</td><td>75.5</td></tr></table>
140
+
141
+ # 4.3 Baselines
142
+
143
+ We compare our CLDA framework with previous state-of-the-art SSDA approaches : MME [46], APE [29], BiAT [25] , UODA [44], Meta-MME [9] and ENT [15] using the performance reported by these papers. papers. We also included the results from adversarial based baseline methods: DANN [13], ADR [47] and CDAN [35] as reported in [46]. We also provide the $\mathbf { s } { + } \mathbf { T }$ results where the model is trained using all the labeled samples across domains.
144
+
145
+ # 4.4 Results
146
+
147
+ Table 1- 3 show top-1 accuracies and mean accuracies for different combination of domain adaptation scenarios for all three datasets in comparison with baseline SSDA methods.
148
+
149
+ Office-Home. Table 1 contains the results of the Office-Home dataset for 3-shot setting with Alexnet and Resnet34 as backbone networks. Results for the 1-shot adaptation scenarios are included in the supplementary. Our method consistently performs better than the baseline approaches and achieves $5 8 . 3 \%$ and $7 5 . 5 \%$ mean accuracy with Alexnet and Resnet34, respectively. Our approach surpasses the state-of-the-art SSDA approaches in most of the adaptation tasks. In some domain adaptation cases, such as $\mathrm { C l } \mathrm { R l }$ , $\mathbf { R } 1 \mathbf { A r }$ and $\mathrm { P r } \mathrm { A r }$ , we exceeded APE by more than $3 \%$ .
150
+
151
+ DomainNet: Our CLDA approach surpasses the performance of existing SSDA baselines as shown in Table 2. Using Alexnet backbone, our method improves over BiAT by $5 . 2 \%$ and $4 . 9 \%$ in 1-shot and 3-shot settings, respectively. We obtain similarly improved performance when we switch the neural backbone from Alexnet to Resnet34. With Resnet34 as the backbone, we gain $4 . 3 \%$ and $3 . 6 \%$ over APE in 1-shot and 3-shot settings, respectively. Similar to the Office-Home, our approach surpasses the well-known domain adaptation benchmarks methods in most domain adaptation tasks of the DomainNet dataset. Such consistent improved performance shows that our approach reduces both inter and intra domain discrepancy prevalent in SSDA.
152
+
153
+ Table 2: Performance Comparison in DomainNet. Numbers show Top-1 accuracy values for different domain adaptation scenarios under 1-shot and 3-shot settings using Alexnet and Resnet34 as backbone networks. CLDA achieves better performance than all the baseline methods in most of the domain adaptation tasks. We have highlighted the best approach for each domain adaptation task. Our Proposed framework achieves the best average performance among all compared methods.
154
+
155
+ <table><tr><td rowspan="2">Net</td><td rowspan="2">Method</td><td colspan="2">R→C</td><td colspan="2">R→P</td><td colspan="2">P→C</td><td colspan="2">C→S</td><td colspan="2">S→P</td><td colspan="2">R→S</td><td colspan="2">P→R</td><td colspan="2">Mean 1-shot3-shot</td></tr><tr><td>1-shot3-shot</td><td></td><td>1-shot</td><td>3-shot</td><td></td><td>1-shot3-shot</td><td>1-shot</td><td>3-shot</td><td>1-shot</td><td>3-shot</td><td>1-shot3-shot</td><td></td><td>1-shot3-shot</td><td></td><td></td><td></td></tr><tr><td rowspan="9">Alexnet</td><td>S+T</td><td>43.3</td><td>47.1</td><td>42.4</td><td>45.0 43.8</td><td>40.1 39.1</td><td>44.9</td><td>33.6</td><td>36.4</td><td>35.7</td><td>38.4</td><td>29.1</td><td>33.3</td><td>55.8</td><td>58.7</td><td>40.0 40.4</td><td>43.4</td></tr><tr><td>DANN</td><td>43.3</td><td>46.1</td><td>41.6</td><td></td><td></td><td>41.0</td><td>35.9</td><td>36.5</td><td>36.9</td><td>38.9</td><td>32.5</td><td>33.4</td><td>53.5</td><td>57.3</td><td></td><td>42.4</td></tr><tr><td>ADR</td><td>43.1</td><td>46.2</td><td>41.4</td><td>44.4</td><td>39.3</td><td>43.6</td><td>32.8</td><td>36.4</td><td>33.1</td><td>38.9</td><td>29.1</td><td>32.4</td><td>55.9</td><td>57.3</td><td>39.2</td><td>42.7</td></tr><tr><td>CDAN</td><td>46.3</td><td>46.8</td><td>45.7</td><td>45.0</td><td>38.3</td><td>42.3</td><td>27.5</td><td>29.5</td><td>30.2</td><td>33.7</td><td>28.8</td><td>31.3</td><td>56.7</td><td>58.7</td><td>39.1</td><td>41.0</td></tr><tr><td>ENT</td><td>37.0</td><td>45.5</td><td>35.6</td><td>42.6</td><td>26.8</td><td>40.4</td><td>18.9</td><td>31.1</td><td>15.1</td><td>29.6</td><td>18.0</td><td>29.6</td><td>52.2</td><td>60.0</td><td>29.1</td><td>39.8</td></tr><tr><td>MME</td><td>48.9</td><td>55.6</td><td>48.0</td><td>49.0</td><td>46.7</td><td>51.7</td><td>36.3</td><td>39.4</td><td>39.4</td><td>43.0</td><td>33.3</td><td>37.9</td><td>56.8</td><td>60.7</td><td>44.2</td><td>48.2</td></tr><tr><td>Meta-MME</td><td>1</td><td>56.4</td><td>-</td><td>50.2</td><td></td><td>51.9</td><td>,</td><td>39.6</td><td>,</td><td>43.7</td><td>-</td><td>38.7</td><td>1</td><td>60.7</td><td>-</td><td>48.8</td></tr><tr><td>BiAT</td><td>54.2</td><td>58.6</td><td>49.2</td><td>50.6</td><td>44.0</td><td>52.0</td><td>37.7</td><td>41.9</td><td>39.6</td><td>42.1</td><td>37.2</td><td>42.0</td><td>56.9</td><td>58.8</td><td>45.5</td><td>49.4</td></tr><tr><td>APE CLDA (ours)</td><td>47.7 56.3</td><td>54.6 59.9</td><td>49.0 56.0</td><td>50.5</td><td>46.9</td><td>52.1 54.6</td><td>38.5 42.5</td><td>42.6</td><td>38.5</td><td>42.2</td><td>33.8 38.0</td><td>38.7</td><td>57.5</td><td>61.4</td><td>44.6</td><td>48.9</td></tr><tr><td></td><td></td><td></td><td></td><td>57.2</td><td>50.8</td><td></td><td></td><td>47.3</td><td>46.8</td><td></td><td>51.4</td><td>42.7</td><td></td><td>64.4</td><td>67.0</td><td>50.7</td><td>54.3</td></tr><tr><td rowspan="10"></td><td>S+T</td><td>55.6</td><td>60.0</td><td>60.6</td><td>62.2</td><td>56.8</td><td>59.4</td><td>50.8</td><td>55.0</td><td>56.0</td><td>59.5</td><td>46.3</td><td>50.1</td><td>71.8</td><td>73.9</td><td>56.9</td><td>60.0</td></tr><tr><td>DANN</td><td>58.2</td><td>59.8</td><td>61.4</td><td>62.8</td><td>56.3</td><td>59.6</td><td>52.8</td><td>55.4</td><td>57.4</td><td>59.9</td><td>52.2</td><td>54.9</td><td>70.3</td><td>72.2</td><td>58.4</td><td>60.7</td></tr><tr><td>ADR</td><td>57.1</td><td>60.7</td><td>61.3</td><td>61.9</td><td>57.0</td><td>60.7</td><td>51.0</td><td>54.4</td><td>56.0</td><td>59.9</td><td>49.0</td><td>51.1</td><td>72.0</td><td>74.2</td><td>57.6</td><td>60.4</td></tr><tr><td>CDAN</td><td>65.0</td><td>69.0</td><td>64.9</td><td>67.3</td><td>63.7</td><td>68.4</td><td>53.1</td><td>57.8</td><td>63.4</td><td>65.3</td><td>54.5</td><td>59.0</td><td>73.2</td><td>78.5</td><td>62.5</td><td>66.5</td></tr><tr><td>ENT</td><td>65.2</td><td>71.0</td><td>65.9</td><td>69.2</td><td>65.4</td><td>71.1</td><td>54.6</td><td>60.0</td><td>59.7</td><td>62.1</td><td>52.1</td><td>61.1</td><td>75.0</td><td>78.6</td><td>62.6</td><td>67.6</td></tr><tr><td>MME</td><td>70.0</td><td>72.2</td><td>67.7</td><td>69.7</td><td>69.0</td><td>71.7</td><td>56.3</td><td>61.8</td><td>64.8</td><td>66.8</td><td>61.0</td><td>61.9</td><td>76.1</td><td>78.5</td><td>66.4</td><td>68.9</td></tr><tr><td>UODA</td><td>72.7</td><td>75.4</td><td>70.3</td><td>71.5</td><td>69.8</td><td>73.2</td><td>60.5</td><td>64.1</td><td>66.4</td><td>69.4</td><td>62.7</td><td>64.2</td><td>77.3</td><td>80.8</td><td>68.5</td><td>71.2</td></tr><tr><td>Meta-MME</td><td>1</td><td>73.5</td><td>1</td><td>70.3</td><td>1</td><td>72.8</td><td>-</td><td>62.8</td><td>1</td><td>68.0</td><td>-</td><td>63.8</td><td>-</td><td>79.2</td><td>-</td><td>70.1</td></tr><tr><td>BiAT</td><td>73.0</td><td>74.9</td><td>68.0</td><td>68.8</td><td>71.6</td><td>74.6</td><td>57.9</td><td>61.5</td><td>63.9</td><td>67.5</td><td>58.5</td><td>62.1</td><td>77.0</td><td>78.6</td><td>67.1</td><td>69.7</td></tr><tr><td>APE</td><td>70.4</td><td>76.6 77.7</td><td>70.8 75.1</td><td>72.1 75.7</td><td>72.9</td><td>76.7 76.4</td><td>56.7 63.7</td><td>63.1 69.7</td><td>64.5 70.2</td><td>66.1 73.7</td><td>63.0 67.1</td><td>67.8</td><td>76.6</td><td>79.4 82.9</td><td>67.6 71.9</td><td>71.7</td></tr><tr><td></td><td>CLDA (ours)</td><td>76.1</td><td></td><td></td><td></td><td>71.0</td><td></td><td></td><td></td><td></td><td></td><td>71.1</td><td>80.1</td><td></td><td></td><td>75.3</td></tr></table>
156
+
157
+ Table 3: Performance Comparison in Office31. Numbers show Top-1 accuracy values for different domain adaptation scenarios under 1-shot and 3-shot settings using Alexnet and VGG as backbone networks. CLDA outperforms all the baseline approaches in both scenarios. We have highlighted the superior method on each domain adaptation task. Our Proposed framework achieves the best mean accuracy among all baseline methods.
158
+
159
+ <table><tr><td></td><td colspan="5">Alexnet</td><td colspan="6">VGG</td></tr><tr><td></td><td colspan="2">W→A</td><td colspan="2">D→A</td><td colspan="2">Mean</td><td colspan="2">W→A</td><td colspan="2">D→A</td><td colspan="2">Mean</td></tr><tr><td>Method</td><td>1-shot</td><td>3-shot</td><td>1-shot</td><td>3-shot</td><td>1-shot</td><td>3-shot</td><td>1-shot</td><td>3-shot</td><td>1-shot</td><td>3-shot</td><td>1-shot</td><td>3-shot</td></tr><tr><td>S+T</td><td>50.4</td><td>61.2</td><td>50.0</td><td>62.4</td><td>50.2</td><td>61.8</td><td>169.2</td><td>73.2</td><td>68.2</td><td>73.3</td><td>68.7</td><td>73.25</td></tr><tr><td>DANN</td><td>57.0</td><td>64.4</td><td>54.5</td><td>65.2</td><td>55.8</td><td>64.8</td><td>69.3</td><td>75.4</td><td>70.4</td><td>74.6</td><td>69.85</td><td>75.0</td></tr><tr><td>ADR</td><td>50.2</td><td>61.2</td><td>50.9</td><td>61.4</td><td>50.6</td><td>61.3</td><td>69.7</td><td>73.3</td><td>69.2</td><td>74.1</td><td>69.45</td><td>73.7</td></tr><tr><td>CDAN</td><td>50.4</td><td>60.3</td><td>48.5</td><td>61.4</td><td>49.5</td><td>60.8</td><td>65.9</td><td>74.4</td><td>64.4</td><td>71.4</td><td>65.15</td><td>72.9</td></tr><tr><td>ENT</td><td>50.7</td><td>64.0</td><td>50.0</td><td>66.2</td><td>50.4</td><td>65.1</td><td>69.1</td><td>75.4</td><td>72.1</td><td>75.1</td><td>70.6</td><td>75.25</td></tr><tr><td>MME</td><td>57.2</td><td>67.3</td><td>55.8</td><td>67.8</td><td>56.5</td><td>67.6</td><td>73.1</td><td>76.3</td><td>73.6</td><td>77.6</td><td>73.35</td><td>76.95</td></tr><tr><td>BiAT</td><td>57.9</td><td>68.2</td><td>54.6</td><td>68.5</td><td>56.3</td><td>68.4</td><td>-</td><td>1</td><td>-</td><td>-</td><td>-</td><td>-</td></tr><tr><td>APE</td><td>1</td><td>67.6</td><td>-</td><td>69.0</td><td>-</td><td>68.3</td><td>-</td><td>-</td><td>-</td><td>-</td><td>-</td><td>-</td></tr><tr><td>CLDA</td><td>64.6</td><td>70.5</td><td>62.7</td><td>72.5</td><td>63.6</td><td>71.5</td><td>76.2</td><td>78.6</td><td>75.1</td><td>76.7</td><td>75.6</td><td>77.6</td></tr></table>
160
+
161
+ Office31: Similar to other datasets, our proposed method with Alexnet and VGG as neural backbone achieves the best performance in both domain adaption scenarios for office31 as shown in Table 3. Using Alexnet backbone, we beat the APE [29] by $3 . 2 \%$ in 3-shot and BiAT by $7 . 3 \%$ in 1-shot settings. We observe similar gains over all the baselines methods with VGG as the neural network backbone. This shows the efficacy of our proposed approach irrespective of the used backbone.
162
+
163
+ # 4.5 Ablation Studies
164
+
165
+ We perform extensive ablation experiments to analyze our CLDA framework and the effects of the different components and hyperparameters. We perform these experiments on the 3-shot $\mathrm { P r } \mathrm { A r }$ domain adaptation task of the Office-Home dataset using Resnet34 unless specified otherwise.
166
+
167
+ Effectiveness of Individual Modules: Our CLDA framework is composed of two modules: InterDomain Contrastive Alignment and Instance Contrastive Alignment. We investigate the significance of each component of our framework by dropping the other during training. We observe that the test accuracy drops from $7 2 . 4 \%$ to $6 8 . 3 \%$ when only Inter-Domain Contrastive Alignment is used, and it drops to $6 7 . 7 \%$ when Instance Contrastive Alignment is used alone as shown in Table 5(a). Though individual modules do not yield high performance on their own but once combined, they surpass their individual performance by a margin of around $4 \%$ .
168
+
169
+ <table><tr><td>Augmentation</td><td>Test Accuracy(Pr→Ar)</td><td>Test Accuracy(Rl→Ar)</td></tr><tr><td>Horizontal Flipping (Hflip)</td><td>68.1</td><td>73.4</td></tr><tr><td>Hflip + Color Jitter</td><td>67.6</td><td>74.9</td></tr><tr><td>Hflip+ Color Jitter+ Grayscale</td><td>70.2</td><td>76.2</td></tr><tr><td>Rand Augment (RA) [8]</td><td>71.1</td><td>74.6</td></tr><tr><td>RA + Grayscale</td><td>72.4</td><td>76.7</td></tr><tr><td>Auto Augment [7]</td><td>69.9</td><td>75.3</td></tr></table>
170
+
171
+ ![](images/c559af2063faac46d7120f29aecc53ce7e351334606d0acc8b6b5191dcde3732.jpg)
172
+ Table 4: Effect of Strong Augmentations Numbers show the test accuracy on 3-shot domain adaptation tasks of the Office-Home dataset with Resnet34 with different augmentation policies.
173
+ Accuracy vs Ratio of unlabeled to labeled data
174
+
175
+ ![](images/985e3697944763a1d34ecb7f6cdc7302257c7d45fd5a260543d6e9fc35ea2c15.jpg)
176
+ Accuracy vs Weight of Instance Contrastive Alignment
177
+
178
+ ![](images/ce7daee479da15ce20a942f1f3f10d535fc557418e4ecdea10f11f78515c6b41.jpg)
179
+ Accuracy vs Weight of Inter-Domain Contrastive Alignment
180
+ Figure 3: Effect of different hyperparameters on 3-shot $\mathbf { P r } \mathbf { A r }$ (Product to Art) data adaptation scenario on the Office-Home using Resnet34. (a) Effect of varying the weight of Instance Contrastive Alignment on validation and test Accuracy (b) Effect of varying weight of Inter-Domain Contrastive Alignment on validation and test Accuracy (c) Effect of $\mu$ , ratio of unlabeled target to labeled target data on validation and test accuracy.
181
+
182
+ Effect of Different Hyperparameters: We analyze the importance of different hyperparameters used in our approach. We observe that the weight of Instance Contrastive Alignment affects the performance of our approach as the test accuracy drops from $7 2 . 4 \%$ to $7 0 . 7 \%$ when we set $\alpha$ to 1 instead of its optimal value of 4 as shown in figure 3. We also notice that increasing $\beta$ led to a reduction of the validation and test performance. We also look into the effect of $\mu$ , which is the ratio of unlabeled to labeled data in a minibatch. We observe that an increasing value of $\mu$ increases the performance till $\mu = 4$ , after which it starts to drop, as shown in figure 3.
183
+
184
+ Importance of Instance Contrastive Alignment: Instance Contrastive Alignment ensures similar representation across different variants of the unlabeled target images. This consistency is also ensured by other well-known SSL approaches like FixMatch [50]. We perform an ablation experiment replacing Instance Contrastive Alignment with FixMatch. We also compare with L1 and L2 loss to have a fair analysis. As shown in Table 5 (b) Instance Contrastive Alignment helps to achieve superior performance in comparison with other consistency-based approaches.
185
+
186
+ <table><tr><td rowspan=1 colspan=1>Approach</td><td rowspan=1 colspan=1>Test Accuracy</td></tr><tr><td rowspan=1 colspan=1>CLDA w/o Instance ContrastiveCLDA w/o Inter-Domain Contrastive</td><td rowspan=1 colspan=1>68.367.7</td></tr><tr><td rowspan=1 colspan=1>CLDA (ours)</td><td rowspan=1 colspan=1>72.4</td></tr></table>
187
+
188
+ (a) Ablation Study on the effectiveness of Individual components of the CLDA framework on $\mathrm { P r } \mathrm { A r }$ adaptation task of the OfficeHome dataset using Resnet34.
189
+
190
+ <table><tr><td>Approach</td><td>Test Accuracy</td></tr><tr><td>Fix-Match</td><td>70.8</td></tr><tr><td>L1 loss</td><td>69.4</td></tr><tr><td>L2 loss</td><td>69.3</td></tr><tr><td>CLDA (ours)</td><td>72.4</td></tr></table>
191
+
192
+ (b) Ablation Study on other consistency based approaches on $\mathrm { P r } \mathrm { A r }$ domain adaptation task of the OfficeHome using Resnet34.
193
+
194
+ Table 5: Experiments to understand the significance of individual components of our framework.
195
+
196
+ Table 6: Ablation study to understand the effect of outliers in target domain. Numbers show the test accuracy of 1-shot domain adaptation tasks of the Office-Home dataset with Resnet34.
197
+
198
+ <table><tr><td>Experiments</td><td>O samples mislabeled</td><td>8 samples mislabeled (~ 12%)</td><td>16 samples mislabeled (~ 25%)</td></tr><tr><td>Pr→Ar</td><td>66.2</td><td>66.0</td><td>65.7</td></tr><tr><td>Rl→Ar</td><td>72.6</td><td>72.05</td><td>71.56</td></tr></table>
199
+
200
+ Effect of Other Clustering Techniques: Inter-Domain Contrastive Alignment requires pseudo labels for the unlabeled target data for clustering. In this ablation experiment, we replace our approach of using the model’s prediction as a pseudo label with K-means clustering, which we invoke after every 50 steps and use the generated centroids for the next 50 steps to obtain pseudo-class labels for unlabeled target data. We observe a drop in performance (from $7 2 . 4 \%$ to $\bar { 7 1 } . 2 \%$ ) when using K-means to obtain the pseudo label for unlabeled target images.
201
+
202
+ Effect of Augmentation Policy: We look into different augmentation policies for the Instance Contrastive Alignment. As suggested in [6], a stronger augmentation policy for contrastive learning increases the performance of the model. We find that RandAugment [8] with Grayscale augmentation policy gives better results over other augmentation policies. The influence of the strong augmentation can be observed from $\sim 4 \%$ improvement in the performance when the augmentation policy is switched from horizontal flipping to RandAugment with Grayscale. Table 4 contains the test accuracy of different augmentation policies on 3-shot $\mathrm { P r } \mathrm { A r }$ and $\mathrm { R l } \mathrm { P r }$ domain adaption tasks of the Office-Home dataset with Resnet34.
203
+
204
+ Effect of Noisy-Labeled Target Samples: In SSDA, we have few labeled samples from the target domain; however, the presence of noisy-labeled target samples can have an adverse effect on the performance. To understand the effect of noisy-labeled target samples on the framework, we conducted experiments on the 1-shot $\mathrm { P r } \mathrm { A r }$ and $\mathbf { R } 1 \mathbf { A r }$ domain adaptation scenarios of the Office-Home dataset with Resnet34, where we mislabeled some previously labeled target samples as shown in Table 6. We observe a small decrease in performance of our framework ( from $6 6 . \hat { 2 \% }$ to $6 5 . 7 \%$ for $\mathrm { P r } \mathrm { A r }$ and from $7 2 . 6 \%$ to $7 1 . 5 6 \%$ for $\mathbb { R } 1 \to \mathrm { A r }$ ) when mislabeled target samples increase from $0 \%$ to $\sim 2 5 \%$ in both domain adaptation scenarios showing the robustness of our framework.
205
+
206
+ # 5 Conclusion
207
+
208
+ In this work, we present a novel single-stage contrastive learning framework for semi-supervised domain adaptation. The framework consists of Inter-Domain Contrastive Alignment and InstanceContrastive Alignment, where the former maximizes the similarity between centroids of the same class from both domains and later maximizes the similarity between augmented views of the unlabeled target images. We show that both of the components of the framework are necessary for improved performance. We demonstrate the effectiveness of our approach on three standard domain adaptation benchmark datasets, outperforming the well-known SSDA methods.
209
+
210
+ # 6 Acknowledgments and Disclosure of Funding
211
+
212
+ The work is supported by Half-Time Research Assistantship (HTRA) grants from the Ministry of Education, India. We would also like to thank Saurav Chakraborty and Athira Nambiar for their valuable suggestions and feedback to improve the work.
213
+
214
+ # References
215
+
216
+ [1] Philip Bachman, R Devon Hjelm, and William Buchwalter. “Learning Representations by Maximizing Mutual Information Across Views”. In: Neural Information Processing Systems. 2019.
217
+ [2] David Berthelot, Nicholas Carlini, Ekin D. Cubuk, Alex Kurakin, Kihyuk Sohn, Han Zhang, and Colin Raffel. “ReMixMatch: Semi-Supervised Learning with Distribution Matching and Augmentation Anchoring”. In: International Conference on Learning Representations. 2020.
218
+ [3] David Berthelot, Nicholas Carlini, Ian Goodfellow, Nicolas Papernot, Avital Oliver, and Colin Raffel. “MixMatch: A Holistic Approach to Semi-Supervised Learning”. In: Neural Information Processing Systems. 2019.
219
+ [4] Konstantinos Bousmalis, George Trigeorgis, Nathan Silberman, Dilip Krishnan, and Dumitru Erhan. “Domain Separation Networks”. In: Neural Information Processing Systems. 2016.
220
+ [5] Chao Chen, Zhihong Chen, Boyuan Jiang, and Xinyu Jin. “Joint Domain Alignment and Discriminative Feature Learning for Unsupervised Deep Domain Adaptation”. In: AAAI Conference on Artificial Intelligence. Vol. 33. 01. 2019, pp. 3296–3303.
221
+ [6] Ting Chen, Simon Kornblith, Mohammad Norouzi, and Geoffrey E. Hinton. “A Simple Framework for Contrastive Learning of Visual Representations”. In: International Conference on Machine Learning. PMLR. 2020, pp. 1597–1607.
222
+ [7] Ekin Dogus Cubuk, Barret Zoph, Dandelion Mané, Vijay Vasudevan, and Quoc V. Le. “AutoAugment: Learning Augmentation Strategies From Data”. In: IEEE Conference on Computer Vision and Pattern Recognition (2019), pp. 113–123.
223
+ [8] Ekin Dogus Cubuk, Barret Zoph, Jonathon Shlens, and Quoc V. Le. “Randaugment: Practical automated data augmentation with a reduced search space”. In: IEEE Conference on Computer Vision and Pattern Recognition Workshops (2020), pp. 3008–3017.
224
+ [9] Timothy Hospedales Da Li. “Online Meta-Learning for Multi-Source and Semi-Supervised Domain Adaptation”. In: European Conference on Computer Vision. 2020.
225
+ [10] Zihang Dai, Zhilin Yang, Fan Yang, William W. Cohen, and Ruslan Salakhutdinov. “Good Semi-supervised Learning That Requires a Bad GAN”. In: Neural Information Processing Systems abs/1705.09783 (2017).
226
+ [11] Jeff Donahue, Yangqing Jia, Oriol Vinyals, Judy Hoffman, Ning Zhang, Eric Tzeng, and Trevor Darrell. “DeCAF: A Deep Convolutional Activation Feature for Generic Visual Recognition”. In: International Conference on Machine Learning. PMLR. 2014.
227
+ [12] Yaroslav Ganin and Victor Lempitsky. “Unsupervised Domain Adaptation by Backpropagation”. In: International Conference on Machine Learning. PMLR. 2015, pp. 1180–1189.
228
+ [13] Yaroslav Ganin, Evgeniya Ustinova, Hana Ajakan, Pascal Germain, Hugo Larochelle, François Laviolette, Mario Marchand, and Victor Lempitsky. “Domain-Adversarial Training of Neural Networks”. In: The Journal of Machine Learning Research 17.1 (2016), pp. 2096–2030.
229
+ [14] Raghuraman Gopalan, Ruonan Li, and Rama Chellappa. “Domain adaptation for object recognition: An unsupervised approach”. In: IEEE International Conference on Computer Vision (2011), pp. 999–1006.
230
+ [15] Yves Grandvalet and Yoshua Bengio. “Semi-supervised learning by entropy minimization���. In: Neural Information Processing Systems. 2004, pp. 529–536.
231
+ [16] Arthur Gretton, Karsten M Borgwardt, Malte J Rasch, Bernhard Schölkopf, and Alexander Smola. “A Kernel Two-Sample Test”. In: The Journal of Machine Learning Research 13.1 (2012), pp. 723–773.
232
+ [17] Jean-Bastien Grill, Florian Strub, Florent Altch’e, Corentin Tallec, Pierre H. Richemond, Elena Buchatskaya, Carl Doersch, Bernardo Avila Pires, Zhaohan Daniel Guo, Mohammad Gheshlaghi Azar, et al. “Bootstrap Your Own Latent: A New Approach to Self-Supervised Learning”. In: ArXiv abs/2006.07733 (2020).
233
+ [18] Kaiming He, Haoqi Fan, Yuxin Wu, Saining Xie, and Ross B. Girshick. “Momentum Contrast for Unsupervised Visual Representation Learning”. In: IEEE Conference on Computer Vision and Pattern Recognition (2020), pp. 9726–9735.
234
+ [19] Kaiming Heand, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. “Deep Residual Learning for Image Recognition”. In: IEEE Conference on Computer Vision and Pattern Recognition. 2016, pp. 770–778.
235
+ [20] Judy Hoffman, Eric Tzeng, Taesung Park, Jun-Yan Zhu, Phillip Isola, Kate Saenko, Alexei A. Efros, and Trevor Darrell. “CyCADA: Cycle-Consistent Adversarial Domain Adaptation”. In: International Conference on Machine Learning. PMLR. 2018.
236
+ [21] Lanqing Hu, Meina Kan, Shiguang Shan, and Xilin Chen. “Duplex Generative Adversarial Network for Unsupervised Domain Adaptation”. In: IEEE Conference on Computer Vision and Pattern Recognition (2018), pp. 1498–1507.
237
+ [22] Gao Huang, Zhuang Liu, Laurens Van Der Maaten, and Kilian Q. Weinberger. “Densely Connected Convolutional Networks”. In: IEEE Conference on Computer Vision and Pattern Recognition (2017), pp. 2261–2269.
238
+ [23] Shuiwang Ji, Wei Xu, Ming Yang, and Kai Yu. “3D Convolutional Neural Networks for Human Action Recognition”. In: IEEE Transactions on Pattern Analysis and Machine Intelligence 35 (2013), pp. 221–231.
239
+ [24] Jian Shen and Yanru Qu and Weinan Zhang and Yong Yu. “Wasserstein Distance Guided Representation Learning for Domain Adaptation”. In: AAAI Conference on Artificial Intelligence. 2018.
240
+ [25] Pin Jiang, Aming Wu, Yahong Han, Yunfeng Shao, Meiyu Qi, and Bingshuai Li. “Bidirectional Adversarial Training for Semi-Supervised Domain Adaptation”. In: International Joint Conferences on Artificial Intelligence. 2020.
241
+ [26] Guoliang Kang, Lu Jiang, Yi Yang, and Alexander G Hauptmann. “Contrastive Adaptation Network for Unsupervised Domain Adaptation”. In: IEEE Conference on Computer Vision and Pattern Recognition (2019), pp. 4888–4897.
242
+ [27] Guoliang Kang, Liang Zheng, Yan Yan, and Yi Yang. “Deep Adversarial Attention Alignment for Unsupervised Domain Adaptation: the Benefit of Target Expectation Maximization”. In: European Conference on Computer Vision. 2018.
243
+ [28] Donghyun Kim, Kuniaki Saito, Tae-Hyun Oh, Bryan A. Plummer, Stan Sclaroff, and Kate Saenko. “Cross-domain Self-supervised Learning for Domain Adaptation with Few Source Labels”. In: IEEE International Conference on Computer Vision abs/2003.08264 (2021).
244
+ [29] Tae-Kyung Kim and Changick Kim. “Attract, Perturb, and Explore: Learning a Feature Alignment Network for Semi-supervised Domain Adaptation”. In: European Conference on Computer Vision. 2020.
245
+ [30] Alex Krizhevsky, Ilya Sutskever, and Geoffrey E. Hinton. “ImageNet Classification with Deep Convolutional Neural Networks”. In: Neural Information Processing Systems 25 (2012), pp. 1097–1105.
246
+ [31] Chongxuan Li, Kun Xu, Zhu Jun, and Zhang Bo. “Triple Generative Adversarial Nets”. In: Neural Information Processing Systems abs/1703.02291 (2017).
247
+ [32] Ji Lin, Chuang Gan, and Song Han. “TSM: Temporal Shift Module for Efficient Video Understanding”. In: IEEE International Conference on Computer Vision (2019), pp. 7082– 7092.
248
+ [33] Weizhe Liu, David Ferstl, Samuel Schulter, Lukas Zebedin, Pascal Fua, and Christian Leistner. “Domain Adaptation for Semantic Segmentation via Patch-Wise Contrastive Learning”. In: arXiv preprint arXiv:2104.11056 (2021).
249
+ [34] Mingsheng Long, Yue Cao, Jianmin Wang, and Michael I. Jordan. “Learning Transferable Features with Deep Adaptation Networks”. In: International Conference on Machine Learning. PMLR. 2015, pp. 97–105.
250
+ [35] Mingsheng Long, Zhangjie Cao, Jianmin Wang, and Michael I. Jordan. “Conditional Adversarial Domain Adaptation”. In: Neural Information Processing Systems. 2018.
251
+ [36] Mingsheng Long, Han Zhu, Jianmin Wang, and Michael I. Jordan. “Unsupervised Domain Adaptation with Residual Transfer Networks”. In: Neural Information Processing Systems. 2016.
252
+ [37] Samarth Mishra, Kate Saenko, and Venkatesh Saligrama. “Surprisingly Simple SemiSupervised Domain Adaptation with Pretraining and Consistency”. In: ArXiv abs/2101.12727 (2021).
253
+ [38] Zak Murez, Soheil Kolouri, David Kriegman, Ravi Ramamoorthi, and Kyungnam Kim. “Image to Image Translation for Domain Adaptation”. In: IEEE Conference on Computer Vision and Pattern Recognition (2018), pp. 4500–4509.
254
+ [39] Aaron van den Oord, Yazhe Li, and Oriol Vinyals. “Representation Learning with Contrastive Predictive Coding”. In: ArXiv abs/1807.03748 (2018).
255
+ [40] Adam Paszke, Sam Gross, Francisco Massa, Adam Lerer, James Bradbury, Gregory Chanan, Trevor Killeen, Zeming Lin, Natalia Gimelshein, Luca Antiga, Alban Desmaison, Andreas Köpf, Edward Yang, Zach DeVito, Martin Raison, Alykhan Tejani, Sasank Chilamkurthy, Benoit Steiner, Lu Fang, Junjie Bai, and Soumith Chintala. “PyTorch: An Imperative Style, High-Performance Deep Learning Library”. In: Neural Information Processing Systems. 2019.
256
+ [41] Sujoy Paul, Yi-Hsuan Tsai, Samuel Schulter, Amit K Roy-Chowdhury, and Manmohan Chandraker. “Domain adaptive semantic segmentation using weak labels”. In: European Conference on Computer Vision. 2020, pp. 571–587.
257
+ [42] Zhongyi Pei, Zhangjie Cao, Mingsheng Long, and Jianmin Wang. “Multi-Adversarial Domain Adaptation”. In: AAAI Conference on Artificial Intelligence. 2018.
258
+ [43] Xingchao Peng, Qinxun Bai, Xide Xia, Zijun Huang, Kate Saenko, and Bo Wang. “Moment Matching for Multi-Source Domain Adaptation”. In: IEEE International Conference on Computer Vision. 2019, pp. 1406–1415.
259
+ [44] Can Qin, Lichen Wang, Qianqian Ma, Yu Yin, Huan Wang, and Yun Fu. “Contradictory Structure Learning for Semi-supervised Domain Adaptation”. In: Proceedings of the 2021 SIAM International Conference on Data Mining (SDM). SIAM. 2021, pp. 576–584.
260
+ [45] Kate Saenko, Brian Kulis, Mario Fritz, and Trevor Darrell. “Adapting Visual Category Models to New Domains”. In: European Conference on Computer Vision. 2010.
261
+ [46] Kuniaki Saito, Donghyun Kim, Stan Sclaroff, Trevor Darrell, and Kate Saenko. “SemiSupervised Domain Adaptation via Minimax Entropy”. In: IEEE International Conference on Computer Vision (2019), pp. 8049–8057.
262
+ [47] Kuniaki Saito, Yoshitaka Ushiku, Tatsuya Harada, and Kate Saenko. “Adversarial Dropout Regularization”. In: International Conference on Learning Representations. 2018.
263
+ [48] Karen Simonyan and Andrew Zisserman. “Two-Stream Convolutional Networks for Action Recognition in Videos”. In: Neural Information Processing Systems. 2014.
264
+ [49] Ankit Singh, Omprakash Chakraborty, Ashutosh Varshney, Rameswar panda, Rogerio Feris, Kate Saenko, and Abir Das. “Semi-Supervised Action Recognition With Temporal Contrastive Learning”. In: IEEE Conference on Computer Vision and Pattern Recognition. June 2021, pp. 10389–10399.
265
+ [50] Kihyuk Sohn, David Berthelot, Chun-Liang Li, Zizhao Zhang, Nicholas Carlini, Ekin D Cubuk, Alex Kurakin, Han Zhang, and Colin Raffel. “FixMatch: Simplifying Semi-Supervised Learning with Consistency and Confidence”. In: Neural Information Processing Systems (2020).
266
+ [51] Baochen Sun and Kate Saenko. “Deep CORAL: Correlation Alignment for Deep Domain Adaptation”. In: European Conference on Computer Vision Workshops. 2016.
267
+ [52] Christian Szegedy, Sergey Ioffe, Vincent Vanhoucke, and Alexander Amir Alemi. “Inceptionv4, Inception-ResNet and the Impact of Residual Connections on Learning”. In: AAAI Conference on Artificial Intelligence. 2017.
268
+ [53] Antti Tarvainen and Harri Valpola. “Mean teachers are better role models: Weight-averaged consistency targets improve semi-supervised deep learning results”. In: Neural Information Processing Systems. 2017.
269
+ [54] Yonglong Tian, Dilip Krishnan, and Phillip Isola. “Contrastive Multiview Coding”. In: European Conference on Computer Vision. 2020.
270
+ [55] Eric Tzeng, Judy Hoffman, Kate Saenko, and Trevor Darrell. “Adversarial Discriminative Domain Adaptation”. In: IEEE Conference on Computer Vision and Pattern Recognition (2017), pp. 2962–2971.
271
+ [56] Hemanth Venkateswara, Jose Eusebio, Shayok Chakraborty, and Sethuraman Panchanathan. “Deep Hashing Network for Unsupervised Domain Adaptation”. In: IEEE Conference on Computer Vision and Pattern Recognition (2017), pp. 5385–5394.
272
+ [57] Limin Wang, Yuanjun Xiong, Zhe Wang, Yu Qiao, Dahua Lin, Xiaoou Tang, and Luc Van Gool. “Temporal Segment Networks for Action Recognition in Videos”. In: IEEE Transactions on Pattern Analysis and Machine Intelligence 41 (2019), pp. 2740–2755.
273
+ [58] Luyu Yang, Yan Wang, Mingfei Gao, Abhinav Shrivastava, Kilian Q. Weinberger, Wei-Lun Chao, and Ser-Nam Lim. “Deep Co-Training with Task Decomposition for Semi-Supervised Domain Adaptation”. In: IEEE International Conference on Computer Vision. 2021.
parse/train/BtZhsSGNRNi/BtZhsSGNRNi_content_list.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/BtZhsSGNRNi/BtZhsSGNRNi_middle.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/BtZhsSGNRNi/BtZhsSGNRNi_model.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/BydLzGb0Z/BydLzGb0Z.md ADDED
@@ -0,0 +1,279 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # TWIN NETWORKS: MATCHING THE FUTURE FOR SEQUENCE GENERATION
2
+
3
+ Dmitriy Serdyuk,\* ♦ Nan Rosemary Ke,\* ♦ ‡ Alessandro Sordoni♥ Adam Trischler,♥ Chris $\mathbf { P a l } ^ { \bullet \bullet }$ & Yoshua Bengio¶ ♦
4
+
5
+ ♦ Montreal Institute for Learning Algorithms (MILA), Canada
6
+ ♥ Microsoft Research, Canada
7
+ ♣ Ecole Polytechnique, Canada
8
+ ¶ CIFAR Senior Fellow
9
+ ‡ Work done at Microsoft Research
10
+ \* Authors contributed equally
11
+ serdyuk@iro.umontreal.ca, rosemary.nan.ke@gmail.com
12
+
13
+ # ABSTRACT
14
+
15
+ We propose a simple technique for encouraging generative RNNs to plan ahead. We train a “backward” recurrent network to generate a given sequence in reverse order, and we encourage states of the forward model to predict cotemporal states of the backward model. The backward network is used only during training, and plays no role during sampling or inference. We hypothesize that our approach eases modeling of long-term dependencies by implicitly forcing the forward states to hold information about the longer-term future (as contained in the backward states). We show empirically that our approach achieves $9 \%$ relative improvement for a speech recognition task, and achieves significant improvement on a COCO caption generation task.
16
+
17
+ # 1 INTRODUCTION
18
+
19
+ Recurrent Neural Networks (RNNs) are the basis of state-of-art models for generating sequential data such as text and speech. RNNs are trained to generate sequences by predicting one output at a time given all previous ones, and excel at the task through their capacity to remember past information well beyond classical $n$ -gram models (Bengio et al., 1994; Hochreiter & Schmidhuber, 1997). More recently, RNNs have also found success when applied to conditional generation tasks such as speech-to-text (Chorowski et al., 2015; Chan et al., 2016), image captioning (Xu et al., 2015) and machine translation (Sutskever et al., 2014; Bahdanau et al., 2014).
20
+
21
+ RNNs are usually trained by teacher forcing: at each point in a given sequence, the RNN is optimized to predict the next token given all preceding tokens. This corresponds to optimizing one-stepahead prediction. As there is no explicit bias toward planning in the training objective, the model may prefer to focus on the most recent tokens instead of capturing subtle long-term dependencies that could contribute to global coherence. Local correlations are usually stronger than long-term dependencies and thus end up dominating the learning signal. The consequence is that samples from RNNs tend to exhibit local coherence but lack meaningful global structure. This difficulty in capturing long-term dependencies has been noted and discussed in several seminal works (Hochreiter, 1991; Bengio et al., 1994; Hochreiter & Schmidhuber, 1997; Pascanu et al., 2013).
22
+
23
+ Recent efforts to address this problem have involved augmenting RNNs with external memory (Dieng et al., 2016; Grave et al., 2016; Gulcehre et al., 2017a), with unitary or hierarchical architectures (Arjovsky et al., 2016; Serban et al., 2017), or with explicit planning mechanisms (Gulcehre et al., 2017b). Parallel efforts aim to prevent overfitting on strong local correlations by regularizing the states of the network, by applying dropout or penalizing various statistics (Moon et al., 2015; Zaremba et al., 2014; Gal & Ghahramani, 2016; Krueger et al., 2016; Merity et al., 2017).
24
+
25
+ ![](images/71380f8284009840161a47174fc671717566c045a27af572921be21466521547.jpg)
26
+ Figure 1: The forward and the backward networks predict the sequence $s = \{ x _ { 1 } , . . . , x _ { 4 } \}$ independently. The penalty matches the forward (or a parametric function of the forward) and the backward hidden states. The forward network receives the gradient signal from the log-likelihood objective as well as $L _ { t }$ between states that predict the same token. The backward network is trained only by maximizing the data log-likelihood. During the evaluation part of the network colored with orange is discarded. The cost $L _ { t }$ is either a Euclidean distance or a learned metric $| | g ( h _ { t } ^ { f } ) - h _ { t } ^ { b } | | _ { 2 }$ with an affine transformation $g$ . Best viewed in color.
27
+
28
+ In this paper, we propose TwinNet,1 a simple method for regularizing a recurrent neural network that encourages modeling those aspects of the past that are predictive of the long-term future. Succinctly, this is achieved as follows: in parallel to the standard forward RNN, we run a “twin” backward RNN (with no parameter sharing) that predicts the sequence in reverse, and we encourage the hidden state of the forward network to be close to that of the backward network used to predict the same token. Intuitively, this forces the forward network to focus on the past information that is useful to predicting a specific token and that is also present in and useful to the backward network, coming from the future (Fig. 1).
29
+
30
+ In practice, our model introduces a regularization term to the training loss. This is distinct from other regularization methods that act on the hidden states either by injecting noise (Krueger et al., 2016) or by penalizing their norm (Krueger & Memisevic, 2015; Merity et al., 2017), because we formulate explicit auxiliary targets for the forward hidden states: namely, the backward hidden states. The activation regularizer (AR) proposed by Merity et al. (2017), which penalizes the norm of the hidden states, is equivalent to the TwinNet approach with the backward states set to zero. Overall, our model is driven by the intuition (a) that the backward hidden states contain a summary of the future of the sequence, and (b) that in order to predict the future more accurately, the model will have to form a better representation of the past. We demonstrate the effectiveness of the TwinNet approach experimentally, through several conditional and unconditional generation tasks that include speech recognition, image captioning, language modelling, and sequential image generation. To summarize, the contributions of this work are as follows:
31
+
32
+ • We introduce a simple method for training generative recurrent networks that regularizes the hidden states of the network to anticipate future states (see Section 2); • The paper provides extensive evaluation of the proposed model on multiple tasks and concludes that it helps training and regularization for conditioned generation (speech recognition, image captioning) and for the unconditioned case (sequential MNIST, language modelling, see Section 4); • For deeper analysis we visualize the introduced cost and observe that it negatively correlates with the word frequency (more surprising words have higher cost).
33
+
34
+ # 2 MODEL
35
+
36
+ Given a dataset of sequences $\mathcal { S } = \{ s ^ { 1 } , \ldots , s ^ { n } \}$ , where each $s ^ { k } = \{ x _ { 1 } , \ldots , x _ { T _ { k } } \}$ is an observed sequence of inputs $x _ { i } \in { \mathcal { X } }$ , we wish to estimate a density $p ( s )$ by maximizing the log-likelihood of the observed data L = Pni=1 log p(si). Using the chain rule, the joint probability over a sequence $x _ { 1 } , \ldots , x _ { T }$ decomposes as:
37
+
38
+ $$
39
+ p ( x _ { 1 } , \dots , x _ { T } ) = p ( x _ { 1 } ) p ( x _ { 2 } | x _ { 1 } ) . . . = \prod _ { t = 1 } ^ { T } p ( x _ { t } | x _ { 1 } , \dots , x _ { t - 1 } ) .
40
+ $$
41
+
42
+ This particular decomposition of the joint probability has been widely used in language modeling (Bengio et al., 2003; Mikolov, 2010) and speech recognition (Bahl et al., 1983). A recurrent neural network is a powerful architecture for approximating this conditional probability. At each step, the RNN updates a hidden state $h _ { t } ^ { f }$ , which iteratively summarizes the inputs seen up to time $t$ :
43
+
44
+ $$
45
+ h _ { t } ^ { f } = \Phi _ { f } ( x _ { t - 1 } , h _ { t - 1 } ^ { f } ) ,
46
+ $$
47
+
48
+ where $f$ symbolizes that the network reads the sequence in the forward direction, and $\Phi _ { f }$ is typically a non-linear function, such as a LSTM cell (Hochreiter & Schmidhuber, 1997) or a GRU (Cho et al., 2014). Thus, $h _ { t } ^ { f }$ forms a representation summarizing information about the sequence’s past. The prediction of the next symbol $x _ { t }$ is performed using another non-linear transformation on top of $h _ { t } ^ { f }$ , i.e. $p _ { f } ( x _ { t } | \boldsymbol x _ { < t } ) = \Psi _ { f } ( h _ { t } ^ { f } )$ , which is typically a linear or affine transformation (followed by a softmax when $x _ { t }$ is a symbol). The basic idea of our approach is to encourage $h _ { t } ^ { f }$ to contain information that is useful to predict $x _ { t }$ and which is also compatible with the upcoming (future) inputs in the sequence. To achieve this, we run a twin recurrent network that predicts the sequence in reverse and further require the hidden states of the forward and the backward networks to be close. The backward network updates its hidden state according to:
49
+
50
+ $$
51
+ h _ { t } ^ { b } = \Phi _ { b } ( x _ { t + 1 } , h _ { t + 1 } ^ { b } ) ,
52
+ $$
53
+
54
+ and predicts $p _ { b } ( x _ { t } | x _ { > t } ) = \Psi _ { b } ( h _ { t } ^ { b } )$ using information only about the future of the sequence. Thus, $h _ { t } ^ { f }$ and $h _ { t } ^ { b }$ both contain useful information for predicting $x _ { t }$ , coming respectively from the past and future. Our idea consists in penalizing the distance between forward and backward hidden states leading to the same prediction. For this we use the Euclidean distance (see Fig. 1):
55
+
56
+ $$
57
+ L _ { t } ( s ) = \| g ( h _ { t } ^ { f } ) - h _ { t } ^ { b } \| _ { 2 } ,
58
+ $$
59
+
60
+ where the dependence on $x$ is implicit in the definition of $h _ { t } ^ { f }$ and $h _ { t } ^ { b }$ . The function $g$ adds further capacity to the model and comes from the class of parameterized affine transformations. Note that this class includes the identity tranformation. As we will show experimentally in Section 4, a learned affine transformation gives more flexibility to the model and leads to better results. This relaxes the strict match between forward and backward states, requiring just that the forward hidden states are predictive of the backward hidden states.2
61
+
62
+ The total objective maximized by our model for a sequence $s$ is a weighted sum of the forward and backward log-likelihoods minus the penalty term, computed at each time-step:
63
+
64
+ $$
65
+ \mathcal { F } ( s ) = \sum _ { t } \log p _ { f } ( x _ { t } | x _ { < t } ) + \log p _ { b } ( x _ { t } | x _ { > t } ) - \alpha L _ { t } ( s ) ,
66
+ $$
67
+
68
+ where $\alpha$ is an hyper-parameter controlling the importance of the penalty term. In order to provide a more stable learning signal to the forward network, we only propagate the gradient of the penalty term through the forward network. That is, we avoid co-adaptation of the backward and forward networks. During sampling and evaluation, we discard the backward network.
69
+
70
+ The proposed method can be easily extended to the conditional generation case. The forward hiddenstate transition is modified to
71
+
72
+ $$
73
+ h _ { t } ^ { f } = \Phi _ { f } \left( x _ { t - 1 } , \left[ h _ { t - 1 } ^ { f } , c \right] \right) ,
74
+ $$
75
+
76
+ # 3 RELATED WORK
77
+
78
+ Bidirectional neural networks (Schuster & Paliwal, 1997) have been used as powerful feature extractors for sequence tasks. The hidden state at each time step includes both information from the past and the future. For this reason, they usually act as better feature extractors than the unidirectional counterpart and have been successfully used in a myriad of tasks, e.g. in machine translation (Bahdanau et al., 2015), question answering (Chen et al., 2017) and sequence labeling (Ma & Hovy, 2016). However, it is not straightforward to apply these models to sequence generation (Zhang et al., 2018) due to the fact that the ancestral sampling process is not allowed to look into the future. In this paper, the backward model is used to regularize the hidden states of the forward model and thus is only used during training. Both inference and sampling are strictly equivalent to the unidirectional case.
79
+
80
+ Gated architectures such as LSTMs (Hochreiter & Schmidhuber, 1997) and GRUs (Chung et al., 2014) have been successful in easing the modeling of long term-dependencies: the gates indicate time-steps for which the network is allowed to keep new information in the memory or forget stored information. Graves et al. (2014); Dieng et al. (2016); Grave et al. (2016) effectively augment the memory of the network by means of an external memory. Another solution for capturing long-term dependencies and avoiding gradient vanishing problems is equipping existing architectures with a hierarchical structure (Serban et al., 2017). Other works tackled the vanishing gradient problem by making the recurrent dynamics unitary (Arjovsky et al., 2016). In parallel, inspired by recent advances in “learning to plan” for reinforcement learning (Silver et al., 2016; Tamar et al., 2016), recent efforts try to augment RNNs with an explicit planning mechanism (Gulcehre et al., 2017b) to force the network to commit to a plan while generating, or to make hidden states predictive of the far future (Li et al., 2017).
81
+
82
+ Regularization methods such as noise injection are also useful to shape the learning dynamics and overcome local correlations to take over the learning process. One of the most popular methods for neural network regularization is dropout (Srivastava et al., 2014). Dropout in RNNs has been proposed in (Moon et al., 2015), and was later extended in (Semeniuta et al., 2016; Gal & Ghahramani, 2016), where recurrent connections are dropped at random. Zoneout (Krueger et al., 2016) modifies the hidden state to regularize the network by effectively creating an ensemble of different length recurrent networks. Krueger & Memisevic (2015) introduce a “norm stabilization” regularization term that ensures that the consecutive hidden states of an RNN have similar Euclidean norm. Recently, Merity et al. (2017) proposed a set of regularization methods that achieve state-of-the-art on the Penn Treebank language modeling dataset. Other RNN regularization methods include the weight noise (Graves, 2011), gradient clipping (Pascanu et al., 2013) and gradient noise (Neelakantan et al., 2015).
83
+
84
+ # 4 EXPERIMENTAL SETUP AND RESULTS
85
+
86
+ We now present experiments on conditional and unconditional sequence generation, and analyze the results in an effort to understand the performance gains of TwinNet. First, we examine conditional generation tasks such as speech recognition and image captioning, where the results show clear improvements over the baseline and other regularization methods. Next, we explore unconditional language generation, where we find our model does not significantly improve on the baseline. Finally, to further determine what tasks the model is well-suited to, we analyze a sequential imputation task, where we can vary the task from unconditional to strongly conditional.
87
+
88
+ # 4.1 SPEECH RECOGNITION
89
+
90
+ We evaluated our approach on the conditional generation for character-level speech recognition, where the model is trained to convert the speech audio signal to the sequence of characters. The forward and backward RNNs are trained as conditional generative models with softattention (Chorowski et al., 2015). The context information $c$ is an encoding of the audio sequence and the output sequence $s$ is the corresponding character sequence. We evaluate our model on the Wall Street Journal (WSJ) dataset closely following the setting described in Bahdanau et al. (2016). We use 40 mel-filter bank features with delta and delta-deltas with their energies as the acoustic in
91
+
92
+ Table 1: Average character error rate (CER, $\%$ ) on WSJ dataset decoded with the beam size 10. We compare the attention model for speech recognition (“Baseline,” Bahdanau et al., 2016); the regularizer proposed by Krueger & Memisevic (2015) (“Stabilizing norm”); penalty on the L2 norm of the forward states (Merity et al., 2017) (“AR”), which is equivalent to TwinNet when all the hidden states of the backward network are set to zero. We report the results of our model (“TwinNet”) both with $g = I$ , the identity mapping, and with a learned $g$ .
93
+
94
+ <table><tr><td>Model</td><td>Test CER</td><td>Valid CER</td></tr><tr><td>Baseline</td><td>6.8</td><td>9.0</td></tr><tr><td>Baseline +Gaussian noise</td><td>6.9</td><td>9.1</td></tr><tr><td>Baseline + Stabilizing Norm</td><td>6.6</td><td>9.0</td></tr><tr><td>Baseline+AR</td><td>6.5</td><td>8.9</td></tr><tr><td>Baseline + TwinNet (g = I)</td><td>6.6</td><td>8.7</td></tr><tr><td>Baseline + TwinNet (learnt g)</td><td>6.2</td><td>8.4</td></tr></table>
95
+
96
+ puts to the model, these features are generated according to the Kaldi s5 recipe (Povey et al., 2011).
97
+ The resulting input feature dimension is 123.
98
+
99
+ We observe the Character Error Rate (CER) for our validation set, and we early stop on the best CER observed so far. We report CER for both our validation and test sets. For all our models and the baseline, we follow the setup in Bahdanau et al. (2016) and pretrain the model for 1 epoch, within this period, the context window is only allowed to move forward. We then perform 10 epochs of training, where the context window looks freely along the time axis of the encoded sequence, we also perform annealing on the models with 2 different learning rates and 3 epochs for each annealing stage. We use the AdaDelta optimizer for training. We perform a small hyper-parameter search on the weight $\alpha$ of our twin loss, $\alpha \in \{ 2 . 0 , 1 . 5 , 1 . 0 , 0 . 5 , 0 . 2 5 , 0 . 1 \} \nonumber$ , and select the best one according to the CER on the validation set.3
100
+
101
+ Results We summarize our findings in Table 1. Our best performing model shows relative improvement of $12 \%$ comparing to the baseline. We found that the TwinNet with a learned metric (learnt $g$ ) is more effective than strictly matching forward and hidden states. In order to gain insights on whether the empirical usefulness comes from using a backward recurrent network, we propose two ablation tests. For “Gaussian Noise,” the backward states are randomly sampled from a Gaussian distribution, therefore the forward states are trained to predict white noise. For “AR,” the backward states are set to zero, which is equivalent to penalizing the norm of the forward hidden states (Merity et al., 2017). Finally, we compare the model with the “Stabilizing Norm” regularizer (Krueger & Memisevic, 2015), that penalizes the difference of the norm of consecutive forward hidden states. Results shows that the information included in the backward states is indeed useful for obtaining a significant improvement.
102
+
103
+ Analysis The training/validation curve comparison for the baseline and our network is presented in Figure 2a.4 The TwinNet converges faster than the baseline and generalizes better. The L2 cost raises in the beginning as the forward and backward network start to learn independently. Later, due to the pressure of this cost, networks produce more aligned hidden representations. Figure 3 provides examples of utterances with L2 plotted along the time axis. We observe that the high entropy words produce spikes in the loss for such words as “uzi.” This is the case for rare words which are hard to predict from the acoustic information. To elaborate on this, we plot the L2 cost averaged over a word depending on the word frequency. The average distance decreases with the increasing frequency. The histogram comparison (Figure 2b) for the cost of rare and frequent words reveal that the not only the average cost is lower for frequent words, but the variance is higher for rare words. Additionally, we plot the dependency of the L2 cost cross-entropy cost of the forward network (Figure 2c) to show that the conditioning also plays the role in the entropy of the output, the losses are not absolutely correlated.
104
+
105
+ ![](images/65bf7a391596f728f9455b710810ba7fc977198a004e4810b4e82303658c9219.jpg)
106
+ Figure 2: Analysis for speech recognition experiments. (a): Training curves comparison for TwinNets and the baseline network. Dotted vertical lines denote stages of pre-training, training, and two stages of annealing. The L2 cost is plotted alongside. The TwinNet converges to a better solution as well as provides better generalization. (b): Comparison of histograms of the cost for rare words (first 1500) versus frequent words (all other). The cost is averaged over characters of a word. The distribution of rare words is wider and tends to produce higher L2 cost. (c): L2 loss vs. average cross-entropy loss.
107
+
108
+ ![](images/b4d567b88d393438a5fd29e3fcb65191022c1f07ab47f5bfab69fcbca281ad64.jpg)
109
+ Figure 3: Example of the L2 loss plotted along the time axis. Notice that spikes correspond to rare words given the acoustic information where the entropy of the prediction is high. Dotted vertical lines are plotted at word boundary positions.
110
+
111
+ # 4.2 IMAGE CAPTIONING
112
+
113
+ We evaluate our model on the conditional generation task of image captioning task on Microsoft COCO dataset (Lin et al., 2014). The MS COCO dataset covers 82,783 training images and 40,504 images for validation. Due to the lack of standardized split of training, validation and test data, we follow Karpathy’s split (Karpathy & Fei-Fei, 2015; Xu et al., 2015; Wang et al., 2016). These are 80,000 training images and 5,000 images for validation and test. We do early stopping based on the validation CIDEr scores and we report BLEU-1 to BLEU-4, CIDEr, and Meteor scores. To evaluate the consistency of our method, we tested TwinNet on both encoder-decoder (‘Show&Tell’, Vinyals et al., 2015) and soft attention (‘Show, Attend and Tell’, Xu et al., 2015) image captioning models.5
114
+
115
+ We use a Resnet (He et al., 2016) with 101 and 152 layers pre-trained on ImageNet for image classification. The last layer of the Resned is used to extract 2048 dimensional input features for the attention model (Xu et al., 2015). We use an LSTM with 512 hidden units for both “Show & Tell” and soft attention. Both models are trained with the Adam (Kingma & Ba, 2014) optimizer with a
116
+
117
+ Table 2: Results for image captioning on the MS COCO dataset, the higher the better for all metrics (BLEU 1 to 4, METEOR, and CIDEr). We reimplement both Show&Tell (Vinyals et al., 2015) and Soft Attention (Xu et al., 2015) in order to add the twin cost. We use two types of images features extracted either with Resnet-101 or Resnet-152.
118
+
119
+ <table><tr><td>Models</td><td>B-1</td><td>B-2</td><td>B-3</td><td>B-4</td><td>METEOR</td><td>CIDEr</td></tr><tr><td>DeepVS (Karpathy &amp; Fei-Fei,2015)</td><td>62.5</td><td>45.0</td><td>32.1</td><td>23.0</td><td>19.5</td><td>66.0</td></tr><tr><td>ATT-FCN (You et al., 2016)</td><td>70.9</td><td>53.7</td><td>40.2</td><td>30.4</td><td>24.3</td><td>1</td></tr><tr><td>Show &amp; Tell(Vinyals et al.,2015)</td><td>-</td><td></td><td>1</td><td>27.7</td><td>23.7</td><td>85.5</td></tr><tr><td>Soft Attention (Xu et al.,2015)</td><td>70.7</td><td>49.2</td><td>34.4</td><td>24.3</td><td>23.9</td><td>-</td></tr><tr><td>Hard Attention (Xu et al., 2015)</td><td>71.8</td><td>50.4</td><td>35.7</td><td>25.0</td><td>23.0</td><td>-</td></tr><tr><td>MSM (Yao et al., 2016)</td><td>73.0</td><td>56.5</td><td>42.9</td><td>32.5</td><td>25.1</td><td>98.6</td></tr><tr><td>Adaptive Attention (Lu et al., 2017)</td><td>74.2</td><td>58.0</td><td>43.9</td><td>33.2</td><td>26.6</td><td>108.5</td></tr><tr><td>No attention, Resnet101</td><td></td><td></td><td></td><td></td><td></td><td></td></tr><tr><td>Show&amp;Tell (Our impl.)</td><td>69.4</td><td>51.6</td><td>36.9</td><td>26.3</td><td>23.4</td><td>84.3</td></tr><tr><td>+ TwinNet</td><td>71.8</td><td>54.5</td><td>39.4</td><td>28.0</td><td>24.0</td><td>87.7</td></tr><tr><td>Attention, Resnet101</td><td></td><td></td><td></td><td></td><td></td><td></td></tr><tr><td>Soft Attention (Our impl.)</td><td>71.0</td><td>53.7</td><td>39.0</td><td>28.1</td><td>24.0</td><td>89.2</td></tr><tr><td>+ TwinNet</td><td>72.8</td><td>55.7</td><td>41.0</td><td>29.7</td><td>25.2</td><td>96.2</td></tr><tr><td>No attention, Resnet152</td><td></td><td></td><td></td><td></td><td></td><td></td></tr><tr><td>Show&amp;Tell (Our impl.)</td><td>71.7</td><td>54.4</td><td>39.7</td><td>28.8</td><td>24.8</td><td>93.0</td></tr><tr><td>+ TwinNet</td><td>72.3</td><td>55.2</td><td>40.4</td><td>29.3</td><td>25.1</td><td>94.7</td></tr><tr><td>Attention, Resnet152</td><td></td><td></td><td></td><td></td><td></td><td></td></tr><tr><td>Soft Attention (Our impl.)</td><td>73.2</td><td>56.3</td><td>41.4</td><td>30.1</td><td>25.3</td><td>96.6</td></tr><tr><td>+ TwinNet</td><td>73.8</td><td>56.9</td><td>42.0</td><td>30.6</td><td>25.2</td><td>97.3</td></tr></table>
120
+
121
+ Table 3: (left) Test set negative log-likelihood for binarized sequential MNIST, where H denotes lower performance of our model with respect to the baselines. (right) Perplexity results on WikiText-2 and Penn Treebank (Merity et al., 2017). AWD-LSTM refers to the model of (Merity et al., 2017) trained with the official implementation at http://github.com/salesforce/awd-lstm/.
122
+
123
+ <table><tr><td>Model</td><td>MNIST</td></tr><tr><td>DBN 2hl (Germain et al., 2015) NADE (Uria et al., 2016)</td><td>~84.55</td></tr><tr><td>EoNADE-5 2hl (Raiko et al.,2014)</td><td>88.33</td></tr><tr><td>DLGM 8 (Salimans et al.,2014)</td><td>84.68</td></tr><tr><td>DARN 1hl (Gregor et al., 2015)</td><td>~85.51 ~84.13</td></tr><tr><td>DRAW (Gregor et al.,2015)</td><td>≤80.97</td></tr><tr><td>P-Forcing(-layer) (Lamb et al.,2016)</td><td>79.58</td></tr><tr><td>PixelRNN(1-layer) (Oord et al.,2016b)</td><td></td></tr><tr><td>PixelRNN(7-layer) (Oord et al.,2016b)</td><td>80.75</td></tr><tr><td>PixelVAE (Gulrajani et al.,2016)</td><td>79.20</td></tr><tr><td>MatNets (Bachman,2016)</td><td>79.02 78.50</td></tr><tr><td>Baseline LSTM(3-layers)</td><td>79.87</td></tr><tr><td>+ TwinNet(3-layers)</td><td>79.35</td></tr><tr><td>Baseline LSTM(3-layers) + dropout + TwinNet(3-layers)</td><td>79.59 79.12</td></tr></table>
124
+
125
+ <table><tr><td>Penn Treebank</td><td>Valid</td><td>Test</td></tr><tr><td>LSTM (Zaremba et al., 2014) 4-layer LSTM (Melis et al., 2017) 5-layer RHN (Melis et al.,2017)</td><td>82.2 67.9</td><td>78.4 65.4</td></tr><tr><td>AWD-LSTM</td><td>64.8 61.2</td><td>62.2 58.8</td></tr><tr><td>+ TwinNet</td><td>61.0</td><td>58.3</td></tr><tr><td>WikiText-2 5-layer RHN (Melis et al.,2017)</td><td>Valid</td><td>Test</td></tr><tr><td>1-layer LSTM (Melis et al., 2017) 2-layer LSTM(Melis et al., 2017)</td><td>78.1 69.3 69.1</td><td>75.6 65.9</td></tr><tr><td>AWD-LSTM</td><td>68.7</td><td>65.9</td></tr><tr><td>+ TwinNet</td><td>68.0</td><td>65.8 64.9</td></tr></table>
126
+
127
+ learning rate of $1 0 ^ { - 4 }$ . TwinNet showed consistent improvements over “Show & Tell” (Table 2). For the soft attention model we observe small but consistent improvements for majority of scores.
128
+
129
+ # 4.3 UNCONDITIONAL GENERATION: SEQUENTIAL MNIST AND LANGUAGE MODELING
130
+
131
+ We investigate the performance of our model in pixel-by-pixel generation for sequential MNIST. We follow the setting described by Lamb et al. (2016): we use an LSTM with 3-layers of 512 hidden units for both forward and backward LSTMs, batch size 20, learning rate 0.001 and clip the gradient norms to 5. We use Adam (Kingma & Ba, 2014) as our optimization algorithm and we decay the learning rate by half after 5, 10, and 15 epochs. Our results are reported at the Table 3 (left). Our baseline LSTM implementation achieves 79.87 nats on the test set. We observe that by adding the TwinNet regularization cost consistently improves performance in this setting by about 0.52 nats. Adding dropout to the baseline LSTM is beneficial. Further gains were observed by adding both dropout and the TwinNet regularization cost. This last model achieves 79.12 nats on test set. Note that this result is competitive with deeper models such as PixelRNN (Oord et al., 2016b) (7-layers) and PixelVAE (Gulrajani et al., 2016) which uses an autoregressive decoder coupled with a deep stochastic auto-encoder.
132
+
133
+ As a last experiment, we report results obtained on a language modelling task using the PennTree Bank and WikiText-2 datasets (Merity et al., 2017). We augment the state-of-the-art AWD-LSTM model (Merity et al., 2017) with the proposed TwinNet regularization cost. The results are reported in Table 3 (right).
134
+
135
+ # 5 DISCUSSION
136
+
137
+ In this paper, we presented a simple recurrent neural network model that has two separate networks running in opposite directions during training. Our model is motivated by the fact that states of the forward model should be predictive of the entire future sequence. This may be hard to obtain by optimizing one-step ahead predictions. The backward path is discarded during the sampling and evaluation process, which makes the sampling process efficient. Empirical results show that the proposed method performs well on conditional generation for several tasks. The analysis reveals an interpretable behaviour of the proposed loss.
138
+
139
+ One of the shortcomings of the proposed approach is that the training process doubles the computation needed for the baseline (due to the backward network training). However, since the backward network is discarded during sampling, the sampling or inference process has the exact same computation steps as the baseline. This makes our approach applicable to models that requires expensive sampling steps, such as PixelRNNs (Oord et al., 2016b) and WaveNet (Oord et al., 2016a). One of future work directions is to test whether it could help in conditional speech synthesis using WaveNet.
140
+
141
+ We observed that the proposed approach yield minor improvements when applied to language modelling with PennTree bank. We hypothesize that this may be linked to the amount of entropy of the target distribution. In these high-entropy cases, at any time-step in the sequence, the distribution of backward states may be highly multi-modal (many possible futures may be equally likely for the same past). One way of overcoming this problem would be to replace the proposed L2 loss (which implicitly assumes a unimodal distribution of the backward states) by a more expressive loss obtained by either employing an inference network (Kingma & Welling, 2013) or distribution matching techniques (Goodfellow et al., 2014). We leave that for future investigation.
142
+
143
+ # ACKNOWLEDGMENTS
144
+
145
+ The authors would like to acknowledge the support of the following agencies for research funding and computing support: NSERC, Calcul Quebec, Compute Canada, the Canada Research Chairs, ´ CIFAR, and Samsung. We would also like to thank the developers of Theano Theano Development Team (2016), Blocks and Fuel van Merrienboer et al. (2015), and Pytorch for developments of great ¨ frameworks. We thank Aaron Courville, Sandeep Subramanian, Marc-Alexandre Cotˆ e, Anirudh ´ Goyal, Alex Lamb, Philemon Brakel, Devon Hjelm, Kyle Kastner, Olivier Breuleux, Phil Bachman, and Gaetan Marceau Caron for useful feedback and discussions. ´
146
+
147
+ # REFERENCES
148
+
149
+ Martin Arjovsky, Amar Shah, and Yoshua Bengio. Unitary evolution recurrent neural networks. In ICML, 2016.
150
+
151
+ Philip Bachman. An architecture for deep, hierarchical generative models. In NIPS, 2016.
152
+
153
+ Dzmitry Bahdanau, Kyunghyun Cho, and Yoshua Bengio. Neural machine translation by jointly learning to align and translate. arXiv preprint arXiv:1409.0473, 2014.
154
+
155
+ Dzmitry Bahdanau, Dmitriy Serdyuk, Philemon Brakel, Nan Rosemary Ke, Jan Chorowski, Aaron C. Courville, and Yoshua Bengio. Task loss estimation for sequence prediction. 2015.
156
+
157
+ Dzmitry Bahdanau, Jan Chorowski, Dmitriy Serdyuk, Philemon Brakel, and Yoshua Bengio. Endto-end attention-based large vocabulary speech recognition. ICASSP, 2016.
158
+
159
+ Lalit R Bahl, Frederick Jelinek, and Robert L Mercer. A maximum likelihood approach to continuous speech recognition. IEEE transactions on pattern analysis and machine intelligence, (2), 1983.
160
+
161
+ Yoshua Bengio, Patrice Simard, and Paolo Frasconi. Learning long-term dependencies with gradient descent is difficult. IEEE transactions on neural networks, 1994.
162
+
163
+ Yoshua Bengio, Rejean Ducharme, Pascal Vincent, and Christian Jauvin. A neural probabilistic ´ language model. JMLR, 2003.
164
+
165
+ Leon Bottou. Curiously fast convergence of some stochastic gradient descent algorithms. In ´ Proceedings of the symposium on learning and data science, Paris, 2009.
166
+
167
+ William Chan, Navdeep Jaitly, Quoc V Le, and Oriol Vinyals. Listen, attend and spell. ICASSP, 2016.
168
+
169
+ Danqi Chen, Adam Fisch, Jason Weston, and Antoine Bordes. Reading Wikipedia to answer opendomain questions. arXiv preprint arXiv:1704.00051, 2017.
170
+
171
+ Kyunghyun Cho, Bart Van Merrienboer, Caglar Gulcehre, Dzmitry Bahdanau, Fethi Bougares, Hol- ¨ ger Schwenk, and Yoshua Bengio. Learning phrase representations using RNN encoder-decoder for statistical machine translation. 2014.
172
+
173
+ Jan K Chorowski, Dzmitry Bahdanau, Dmitriy Serdyuk, Kyunghyun Cho, and Yoshua Bengio. Attention-based models for speech recognition. In NIPS. 2015.
174
+
175
+ Junyoung Chung, Caglar Gulcehre, KyungHyun Cho, and Yoshua Bengio. Empirical evaluation of gated recurrent neural networks on sequence modeling. arXiv:1412.3555, 2014.
176
+
177
+ Adji B Dieng, Chong Wang, Jianfeng Gao, and John Paisley. TopicRNN: A recurrent neural network with long-range semantic dependency. arXiv preprint arXiv:1611.01702, 2016.
178
+
179
+ Yarin Gal and Zoubin Ghahramani. A theoretically grounded application of dropout in recurrent neural networks. In NIPS, 2016.
180
+
181
+ Mathieu Germain, Karol Gregor, Iain Murray, and Hugo Larochelle. MADE: Masked autoencoder for distribution estimation. In ICML, 2015.
182
+
183
+ Ian Goodfellow, Jean Pouget-Abadie, Mehdi Mirza, Bing Xu, David Warde-Farley, Sherjil Ozair, Aaron Courville, and Yoshua Bengio. Generative adversarial nets. In NIPS, 2014.
184
+
185
+ Edouard Grave, Armand Joulin, and Nicolas Usunier. Improving neural language models with a continuous cache. arXiv preprint arXiv:1612.04426, 2016.
186
+
187
+ Alex Graves. Practical variational inference for neural networks. In NIPS, 2011.
188
+
189
+ Alex Graves, Greg Wayne, and Ivo Danihelka. Neural turing machines. arXiv preprint arXiv:1410.5401, 2014.
190
+
191
+ 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.
192
+
193
+ Caglar Gulcehre, Sarath Chandar, and Yoshua Bengio. Memory augmented neural networks with wormhole connections. arXiv preprint arXiv:1701.08718, 2017a.
194
+
195
+ Caglar Gulcehre, Francis Dutil, Adam Trischler, and Yoshua Bengio. Plan, attend, generate: Planning for sequence-to-sequence models. In Proc. of NIPS, 2017b.
196
+
197
+ Ishaan Gulrajani, Kundan Kumar, Faruk Ahmed, Adrien Ali Taiga, Francesco Visin, David Vazquez, and Aaron Courville. PixelVAE: A latent variable model for natural images. arXiv preprint arXiv:1611.05013, 2016.
198
+
199
+ Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. Deep residual learning for image recognition. In CVPR, 2016.
200
+
201
+ Sepp Hochreiter. Untersuchungen zu dynamischen neuronalen netzen. Diploma, Technische Universitat M¨ unchen ¨ , 91, 1991.
202
+
203
+ Sepp Hochreiter and Jurgen Schmidhuber. Long short-term memory. ¨ Neural computation, 1997.
204
+
205
+ Andrej Karpathy and Li Fei-Fei. Deep visual-semantic alignments for generating image descriptions. In CVPR, 2015.
206
+
207
+ Diederik Kingma and Jimmy Ba. Adam: A method for stochastic optimization. arXiv preprint arXiv:1412.6980, 2014.
208
+
209
+ Diederik P Kingma and Max Welling. Auto-encoding variational Bayes. arXiv preprint arXiv:1312.6114, 2013.
210
+
211
+ David Krueger and Roland Memisevic. Regularizing RNNs by stabilizing activations. arXiv:1511.08400, 2015.
212
+
213
+ David Krueger, Tegan Maharaj, Janos Kram ´ ar, Mohammad Pezeshki, Nicolas Ballas, Nan Rose- ´ mary Ke, Anirudh Goyal, Yoshua Bengio, Hugo Larochelle, Aaron Courville, and Chistopher Pal. Zoneout: Regularizing RNNs by randomly preserving hidden activations. 2016.
214
+
215
+ Alex M Lamb, Anirudh Goyal, Ying Zhang, Saizheng Zhang, Aaron C Courville, and Yoshua Bengio. Professor forcing: A new algorithm for training recurrent networks. In NIPS, 2016.
216
+
217
+ Jiwei Li, Will Monroe, and Dan Jurafsky. Learning to decode for future success. 2017.
218
+
219
+ Tsung-Yi Lin, Michael Maire, Serge Belongie, James Hays, Pietro Perona, Deva Ramanan, Piotr Dollar, and C Lawrence Zitnick. Microsoft COCO: Common objects in context. In ´ European conference on computer vision, 2014.
220
+
221
+ Jiasen Lu, Caiming Xiong, Devi Parikh, and Richard Socher. Knowing when to look: Adaptive attention via a visual sentinel for image captioning. In Proc. of CVPR 17, 2017.
222
+
223
+ Xuezhe Ma and Eduard Hovy. End-to-end sequence labeling via bi-directional LSTM-CNNs-CRF. arXiv preprint arXiv:1603.01354, 2016.
224
+
225
+ 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.
226
+
227
+ Stephen Merity, Nitish Shirish Keskar, and Richard Socher. Regularizing and optimizing LSTM language models. arXiv preprint arXiv:1708.02182, 2017.
228
+
229
+ Tomas Mikolov. Recurrent neural network based language model. 2010.
230
+
231
+ Taesup Moon, Heeyoul Choi, Hoshik Lee, and Inchul Song. RNNDROP: A novel dropout for RNNs in ASR. In ASRU, 2015.
232
+
233
+ Arvind Neelakantan, Luke Vilnis, Quoc V Le, Ilya Sutskever, Lukasz Kaiser, Karol Kurach, and James Martens. Adding gradient noise improves learning for very deep networks. 2015.
234
+
235
+ Aaron van den Oord, Sander Dieleman, Heiga Zen, Karen Simonyan, Oriol Vinyals, Alex Graves, Nal Kalchbrenner, Andrew Senior, and Koray Kavukcuoglu. Wavenet: A generative model for raw audio. arXiv:1609.03499, 2016a.
236
+
237
+ Aaron van den Oord, Nal Kalchbrenner, and Koray Kavukcuoglu. Pixel recurrent neural networks. arXiv preprint arXiv:1601.06759, 2016b.
238
+
239
+ Razvan Pascanu, Tomas Mikolov, and Yoshua Bengio. On the difficulty of training recurrent neural networks. In ICML, 2013.
240
+
241
+ Daniel Povey, Arnab Ghoshal, Gilles Boulianne, Lukas Burget, Ondrej Glembek, Nagendra Goel, Mirko Hannemann, Petr Motlicek, Yanmin Qian, Petr Schwarz, et al. The Kaldi speech recognition toolkit. In IEEE 2011 workshop on automatic speech recognition and understanding, 2011.
242
+
243
+ Tapani Raiko, Yao Li, Kyunghyun Cho, and Yoshua Bengio. Iterative neural autoregressive distribution estimator nade-k. In NIPS, 2014.
244
+
245
+ Tim Salimans, Diederik P Kingma, and Max Welling. Markov chain monte carlo and variational inference: Bridging the gap. arXiv preprint arXiv:1410.6460, 2014.
246
+
247
+ Mike Schuster and Kuldip K Paliwal. Bidirectional recurrent neural networks. IEEE Transactions on Signal Processing, 1997.
248
+
249
+ Stanislau Semeniuta, Aliaksei Severyn, and Erhardt Barth. Recurrent dropout without memory loss. 2016.
250
+
251
+ Iulian Vlad Serban, Alessandro Sordoni, Ryan Lowe, Laurent Charlin, Joelle Pineau, Aaron C Courville, and Yoshua Bengio. A hierarchical latent variable encoder-decoder model for generating dialogues. 2017.
252
+
253
+ David Silver, Hado van Hasselt, Matteo Hessel, Tom Schaul, Arthur Guez, Tim Harley, Gabriel Dulac-Arnold, David Reichert, Neil Rabinowitz, Andre Barreto, et al. The predictron: End-toend learning and planning. arXiv preprint arXiv:1612.08810, 2016.
254
+
255
+ Nitish Srivastava, Geoffrey E Hinton, Alex Krizhevsky, Ilya Sutskever, and Ruslan Salakhutdinov. Dropout: a simple way to prevent neural networks from overfitting. JMLR, 2014.
256
+
257
+ Ilya Sutskever, Oriol Vinyals, and Quoc V Le. Sequence to sequence learning with neural networks. In NIPS, 2014.
258
+
259
+ Aviv Tamar, Yi Wu, Garrett Thomas, Sergey Levine, and Pieter Abbeel. Value iteration networks. In NIPS, 2016.
260
+
261
+ Theano Development Team. Theano: A Python framework for fast computation of mathematical expressions. 2016.
262
+
263
+ Benigno Uria, Marc-Alexandre Cotˆ e, Karol Gregor, Iain Murray, and Hugo Larochelle. Neural ´ autoregressive distribution estimation. JMLR, 17(205), 2016.
264
+
265
+ Bart van Merrienboer, Dzmitry Bahdanau, Vincent Dumoulin, Dmitriy Serdyuk, David Warde-¨ Farley, Jan Chorowski, and Yoshua Bengio. Blocks and fuel: Frameworks for deep learning. 2015.
266
+
267
+ Oriol Vinyals, Alexander Toshev, Samy Bengio, and Dumitru Erhan. Show and tell: A neural image caption generator. In CVPR, 2015.
268
+
269
+ Cheng Wang, Haojin Yang, Christian Bartz, and Christoph Meinel. Image captioning with deep bidirectional LSTMs. In Proceedings of the 2016 ACM on Multimedia Conference. ACM, 2016.
270
+
271
+ Kelvin Xu, Jimmy Ba, Ryan Kiros, Kyunghyun Cho, Aaron Courville, Ruslan Salakhudinov, Rich Zemel, and Yoshua Bengio. Show, attend and tell: Neural image caption generation with visual attention. In ICML, 2015.
272
+
273
+ Ting Yao, Yingwei Pan, Yehao Li, Zhaofan Qiu, and Tao Mei. Boosting image captioning with attributes. arXiv preprint arXiv:1611.01646, 2016.
274
+
275
+ Quanzeng You, Hailin Jin, Zhaowen Wang, Chen Fang, and Jiebo Luo. Image captioning with semantic attention. In CVPR, 2016.
276
+
277
+ Wojciech Zaremba, Ilya Sutskever, and Oriol Vinyals. Recurrent neural network regularization. 2014.
278
+
279
+ Xiangwen Zhang, Jinsong Su, Yue Qin, Yang Liu, Rongrong Ji, and Hongji Wang. Asynchronous bidirectional decoding for neural machine translation. arXiv preprint arXiv:1801.05122, 2018.
parse/train/BydLzGb0Z/BydLzGb0Z_content_list.json ADDED
@@ -0,0 +1,1462 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [
2
+ {
3
+ "type": "text",
4
+ "text": "TWIN NETWORKS: MATCHING THE FUTURE FOR SEQUENCE GENERATION ",
5
+ "text_level": 1,
6
+ "bbox": [
7
+ 174,
8
+ 98,
9
+ 705,
10
+ 146
11
+ ],
12
+ "page_idx": 0
13
+ },
14
+ {
15
+ "type": "text",
16
+ "text": "Dmitriy Serdyuk,\\* ♦ Nan Rosemary Ke,\\* ♦ ‡ Alessandro Sordoni♥ Adam Trischler,♥ Chris $\\mathbf { P a l } ^ { \\bullet \\bullet }$ & Yoshua Bengio¶ ♦ ",
17
+ "bbox": [
18
+ 183,
19
+ 170,
20
+ 640,
21
+ 205
22
+ ],
23
+ "page_idx": 0
24
+ },
25
+ {
26
+ "type": "text",
27
+ "text": "♦ Montreal Institute for Learning Algorithms (MILA), Canada \n♥ Microsoft Research, Canada \n♣ Ecole Polytechnique, Canada \n¶ CIFAR Senior Fellow \n‡ Work done at Microsoft Research \n\\* Authors contributed equally \nserdyuk@iro.umontreal.ca, rosemary.nan.ke@gmail.com ",
28
+ "bbox": [
29
+ 184,
30
+ 223,
31
+ 676,
32
+ 327
33
+ ],
34
+ "page_idx": 0
35
+ },
36
+ {
37
+ "type": "text",
38
+ "text": "ABSTRACT ",
39
+ "text_level": 1,
40
+ "bbox": [
41
+ 454,
42
+ 361,
43
+ 544,
44
+ 376
45
+ ],
46
+ "page_idx": 0
47
+ },
48
+ {
49
+ "type": "text",
50
+ "text": "We propose a simple technique for encouraging generative RNNs to plan ahead. We train a “backward” recurrent network to generate a given sequence in reverse order, and we encourage states of the forward model to predict cotemporal states of the backward model. The backward network is used only during training, and plays no role during sampling or inference. We hypothesize that our approach eases modeling of long-term dependencies by implicitly forcing the forward states to hold information about the longer-term future (as contained in the backward states). We show empirically that our approach achieves $9 \\%$ relative improvement for a speech recognition task, and achieves significant improvement on a COCO caption generation task. ",
51
+ "bbox": [
52
+ 233,
53
+ 395,
54
+ 764,
55
+ 534
56
+ ],
57
+ "page_idx": 0
58
+ },
59
+ {
60
+ "type": "text",
61
+ "text": "1 INTRODUCTION ",
62
+ "text_level": 1,
63
+ "bbox": [
64
+ 176,
65
+ 569,
66
+ 336,
67
+ 585
68
+ ],
69
+ "page_idx": 0
70
+ },
71
+ {
72
+ "type": "text",
73
+ "text": "Recurrent Neural Networks (RNNs) are the basis of state-of-art models for generating sequential data such as text and speech. RNNs are trained to generate sequences by predicting one output at a time given all previous ones, and excel at the task through their capacity to remember past information well beyond classical $n$ -gram models (Bengio et al., 1994; Hochreiter & Schmidhuber, 1997). More recently, RNNs have also found success when applied to conditional generation tasks such as speech-to-text (Chorowski et al., 2015; Chan et al., 2016), image captioning (Xu et al., 2015) and machine translation (Sutskever et al., 2014; Bahdanau et al., 2014). ",
74
+ "bbox": [
75
+ 174,
76
+ 603,
77
+ 825,
78
+ 700
79
+ ],
80
+ "page_idx": 0
81
+ },
82
+ {
83
+ "type": "text",
84
+ "text": "RNNs are usually trained by teacher forcing: at each point in a given sequence, the RNN is optimized to predict the next token given all preceding tokens. This corresponds to optimizing one-stepahead prediction. As there is no explicit bias toward planning in the training objective, the model may prefer to focus on the most recent tokens instead of capturing subtle long-term dependencies that could contribute to global coherence. Local correlations are usually stronger than long-term dependencies and thus end up dominating the learning signal. The consequence is that samples from RNNs tend to exhibit local coherence but lack meaningful global structure. This difficulty in capturing long-term dependencies has been noted and discussed in several seminal works (Hochreiter, 1991; Bengio et al., 1994; Hochreiter & Schmidhuber, 1997; Pascanu et al., 2013). ",
85
+ "bbox": [
86
+ 174,
87
+ 708,
88
+ 823,
89
+ 833
90
+ ],
91
+ "page_idx": 0
92
+ },
93
+ {
94
+ "type": "text",
95
+ "text": "Recent efforts to address this problem have involved augmenting RNNs with external memory (Dieng et al., 2016; Grave et al., 2016; Gulcehre et al., 2017a), with unitary or hierarchical architectures (Arjovsky et al., 2016; Serban et al., 2017), or with explicit planning mechanisms (Gulcehre et al., 2017b). Parallel efforts aim to prevent overfitting on strong local correlations by regularizing the states of the network, by applying dropout or penalizing various statistics (Moon et al., 2015; Zaremba et al., 2014; Gal & Ghahramani, 2016; Krueger et al., 2016; Merity et al., 2017). ",
96
+ "bbox": [
97
+ 174,
98
+ 840,
99
+ 823,
100
+ 922
101
+ ],
102
+ "page_idx": 0
103
+ },
104
+ {
105
+ "type": "image",
106
+ "img_path": "images/71380f8284009840161a47174fc671717566c045a27af572921be21466521547.jpg",
107
+ "image_caption": [
108
+ "Figure 1: The forward and the backward networks predict the sequence $s = \\{ x _ { 1 } , . . . , x _ { 4 } \\}$ independently. The penalty matches the forward (or a parametric function of the forward) and the backward hidden states. The forward network receives the gradient signal from the log-likelihood objective as well as $L _ { t }$ between states that predict the same token. The backward network is trained only by maximizing the data log-likelihood. During the evaluation part of the network colored with orange is discarded. The cost $L _ { t }$ is either a Euclidean distance or a learned metric $| | g ( h _ { t } ^ { f } ) - h _ { t } ^ { b } | | _ { 2 }$ with an affine transformation $g$ . Best viewed in color. "
109
+ ],
110
+ "image_footnote": [],
111
+ "bbox": [
112
+ 356,
113
+ 97,
114
+ 637,
115
+ 255
116
+ ],
117
+ "page_idx": 1
118
+ },
119
+ {
120
+ "type": "text",
121
+ "text": "In this paper, we propose TwinNet,1 a simple method for regularizing a recurrent neural network that encourages modeling those aspects of the past that are predictive of the long-term future. Succinctly, this is achieved as follows: in parallel to the standard forward RNN, we run a “twin” backward RNN (with no parameter sharing) that predicts the sequence in reverse, and we encourage the hidden state of the forward network to be close to that of the backward network used to predict the same token. Intuitively, this forces the forward network to focus on the past information that is useful to predicting a specific token and that is also present in and useful to the backward network, coming from the future (Fig. 1). ",
122
+ "bbox": [
123
+ 173,
124
+ 405,
125
+ 825,
126
+ 517
127
+ ],
128
+ "page_idx": 1
129
+ },
130
+ {
131
+ "type": "text",
132
+ "text": "In practice, our model introduces a regularization term to the training loss. This is distinct from other regularization methods that act on the hidden states either by injecting noise (Krueger et al., 2016) or by penalizing their norm (Krueger & Memisevic, 2015; Merity et al., 2017), because we formulate explicit auxiliary targets for the forward hidden states: namely, the backward hidden states. The activation regularizer (AR) proposed by Merity et al. (2017), which penalizes the norm of the hidden states, is equivalent to the TwinNet approach with the backward states set to zero. Overall, our model is driven by the intuition (a) that the backward hidden states contain a summary of the future of the sequence, and (b) that in order to predict the future more accurately, the model will have to form a better representation of the past. We demonstrate the effectiveness of the TwinNet approach experimentally, through several conditional and unconditional generation tasks that include speech recognition, image captioning, language modelling, and sequential image generation. To summarize, the contributions of this work are as follows: ",
133
+ "bbox": [
134
+ 173,
135
+ 523,
136
+ 825,
137
+ 689
138
+ ],
139
+ "page_idx": 1
140
+ },
141
+ {
142
+ "type": "text",
143
+ "text": "• We introduce a simple method for training generative recurrent networks that regularizes the hidden states of the network to anticipate future states (see Section 2); • The paper provides extensive evaluation of the proposed model on multiple tasks and concludes that it helps training and regularization for conditioned generation (speech recognition, image captioning) and for the unconditioned case (sequential MNIST, language modelling, see Section 4); • For deeper analysis we visualize the introduced cost and observe that it negatively correlates with the word frequency (more surprising words have higher cost). ",
144
+ "bbox": [
145
+ 215,
146
+ 710,
147
+ 825,
148
+ 859
149
+ ],
150
+ "page_idx": 1
151
+ },
152
+ {
153
+ "type": "text",
154
+ "text": "2 MODEL ",
155
+ "text_level": 1,
156
+ "bbox": [
157
+ 174,
158
+ 102,
159
+ 269,
160
+ 117
161
+ ],
162
+ "page_idx": 2
163
+ },
164
+ {
165
+ "type": "text",
166
+ "text": "Given a dataset of sequences $\\mathcal { S } = \\{ s ^ { 1 } , \\ldots , s ^ { n } \\}$ , where each $s ^ { k } = \\{ x _ { 1 } , \\ldots , x _ { T _ { k } } \\}$ is an observed sequence of inputs $x _ { i } \\in { \\mathcal { X } }$ , we wish to estimate a density $p ( s )$ by maximizing the log-likelihood of the observed data L = Pni=1 log p(si). Using the chain rule, the joint probability over a sequence $x _ { 1 } , \\ldots , x _ { T }$ decomposes as: ",
167
+ "bbox": [
168
+ 174,
169
+ 131,
170
+ 825,
171
+ 189
172
+ ],
173
+ "page_idx": 2
174
+ },
175
+ {
176
+ "type": "equation",
177
+ "img_path": "images/03bdde0201af0a8692a4fd6f43db296c9508f400c7592f0afef184e09449eede.jpg",
178
+ "text": "$$\np ( x _ { 1 } , \\dots , x _ { T } ) = p ( x _ { 1 } ) p ( x _ { 2 } | x _ { 1 } ) . . . = \\prod _ { t = 1 } ^ { T } p ( x _ { t } | x _ { 1 } , \\dots , x _ { t - 1 } ) .\n$$",
179
+ "text_format": "latex",
180
+ "bbox": [
181
+ 295,
182
+ 190,
183
+ 700,
184
+ 233
185
+ ],
186
+ "page_idx": 2
187
+ },
188
+ {
189
+ "type": "text",
190
+ "text": "This particular decomposition of the joint probability has been widely used in language modeling (Bengio et al., 2003; Mikolov, 2010) and speech recognition (Bahl et al., 1983). A recurrent neural network is a powerful architecture for approximating this conditional probability. At each step, the RNN updates a hidden state $h _ { t } ^ { f }$ , which iteratively summarizes the inputs seen up to time $t$ : ",
191
+ "bbox": [
192
+ 173,
193
+ 234,
194
+ 825,
195
+ 292
196
+ ],
197
+ "page_idx": 2
198
+ },
199
+ {
200
+ "type": "equation",
201
+ "img_path": "images/2ade0569afee9a21e4169f56706613e346e6eb70835f9e1c6f2f0a3e0f2d8474.jpg",
202
+ "text": "$$\nh _ { t } ^ { f } = \\Phi _ { f } ( x _ { t - 1 } , h _ { t - 1 } ^ { f } ) ,\n$$",
203
+ "text_format": "latex",
204
+ "bbox": [
205
+ 423,
206
+ 294,
207
+ 573,
208
+ 315
209
+ ],
210
+ "page_idx": 2
211
+ },
212
+ {
213
+ "type": "text",
214
+ "text": "where $f$ symbolizes that the network reads the sequence in the forward direction, and $\\Phi _ { f }$ is typically a non-linear function, such as a LSTM cell (Hochreiter & Schmidhuber, 1997) or a GRU (Cho et al., 2014). Thus, $h _ { t } ^ { f }$ forms a representation summarizing information about the sequence’s past. The prediction of the next symbol $x _ { t }$ is performed using another non-linear transformation on top of $h _ { t } ^ { f }$ , i.e. $p _ { f } ( x _ { t } | \\boldsymbol x _ { < t } ) = \\Psi _ { f } ( h _ { t } ^ { f } )$ , which is typically a linear or affine transformation (followed by a softmax when $x _ { t }$ is a symbol). The basic idea of our approach is to encourage $h _ { t } ^ { f }$ to contain information that is useful to predict $x _ { t }$ and which is also compatible with the upcoming (future) inputs in the sequence. To achieve this, we run a twin recurrent network that predicts the sequence in reverse and further require the hidden states of the forward and the backward networks to be close. The backward network updates its hidden state according to: ",
215
+ "bbox": [
216
+ 173,
217
+ 315,
218
+ 825,
219
+ 462
220
+ ],
221
+ "page_idx": 2
222
+ },
223
+ {
224
+ "type": "equation",
225
+ "img_path": "images/61c14e3b90fbb076dc2a55221f1706367e8701e3e3098d1d5a107a6974d46480.jpg",
226
+ "text": "$$\nh _ { t } ^ { b } = \\Phi _ { b } ( x _ { t + 1 } , h _ { t + 1 } ^ { b } ) ,\n$$",
227
+ "text_format": "latex",
228
+ "bbox": [
229
+ 424,
230
+ 463,
231
+ 571,
232
+ 483
233
+ ],
234
+ "page_idx": 2
235
+ },
236
+ {
237
+ "type": "text",
238
+ "text": "and predicts $p _ { b } ( x _ { t } | x _ { > t } ) = \\Psi _ { b } ( h _ { t } ^ { b } )$ using information only about the future of the sequence. Thus, $h _ { t } ^ { f }$ and $h _ { t } ^ { b }$ both contain useful information for predicting $x _ { t }$ , coming respectively from the past and future. Our idea consists in penalizing the distance between forward and backward hidden states leading to the same prediction. For this we use the Euclidean distance (see Fig. 1): ",
239
+ "bbox": [
240
+ 173,
241
+ 484,
242
+ 825,
243
+ 545
244
+ ],
245
+ "page_idx": 2
246
+ },
247
+ {
248
+ "type": "equation",
249
+ "img_path": "images/78e31d9a0b8531e74b6409f5fca969dcb96a7b94fe004a272b58dc9811a7ece9.jpg",
250
+ "text": "$$\nL _ { t } ( s ) = \\| g ( h _ { t } ^ { f } ) - h _ { t } ^ { b } \\| _ { 2 } ,\n$$",
251
+ "text_format": "latex",
252
+ "bbox": [
253
+ 415,
254
+ 546,
255
+ 580,
256
+ 566
257
+ ],
258
+ "page_idx": 2
259
+ },
260
+ {
261
+ "type": "text",
262
+ "text": "where the dependence on $x$ is implicit in the definition of $h _ { t } ^ { f }$ and $h _ { t } ^ { b }$ . The function $g$ adds further capacity to the model and comes from the class of parameterized affine transformations. Note that this class includes the identity tranformation. As we will show experimentally in Section 4, a learned affine transformation gives more flexibility to the model and leads to better results. This relaxes the strict match between forward and backward states, requiring just that the forward hidden states are predictive of the backward hidden states.2 ",
263
+ "bbox": [
264
+ 173,
265
+ 569,
266
+ 825,
267
+ 654
268
+ ],
269
+ "page_idx": 2
270
+ },
271
+ {
272
+ "type": "text",
273
+ "text": "The total objective maximized by our model for a sequence $s$ is a weighted sum of the forward and backward log-likelihoods minus the penalty term, computed at each time-step: ",
274
+ "bbox": [
275
+ 173,
276
+ 660,
277
+ 823,
278
+ 689
279
+ ],
280
+ "page_idx": 2
281
+ },
282
+ {
283
+ "type": "equation",
284
+ "img_path": "images/6d83d5a27638354b30363c5257ec748c68abe764e745f031ada50515820a8f04.jpg",
285
+ "text": "$$\n\\mathcal { F } ( s ) = \\sum _ { t } \\log p _ { f } ( x _ { t } | x _ { < t } ) + \\log p _ { b } ( x _ { t } | x _ { > t } ) - \\alpha L _ { t } ( s ) ,\n$$",
286
+ "text_format": "latex",
287
+ "bbox": [
288
+ 312,
289
+ 690,
290
+ 684,
291
+ 723
292
+ ],
293
+ "page_idx": 2
294
+ },
295
+ {
296
+ "type": "text",
297
+ "text": "where $\\alpha$ is an hyper-parameter controlling the importance of the penalty term. In order to provide a more stable learning signal to the forward network, we only propagate the gradient of the penalty term through the forward network. That is, we avoid co-adaptation of the backward and forward networks. During sampling and evaluation, we discard the backward network. ",
298
+ "bbox": [
299
+ 173,
300
+ 724,
301
+ 825,
302
+ 781
303
+ ],
304
+ "page_idx": 2
305
+ },
306
+ {
307
+ "type": "text",
308
+ "text": "The proposed method can be easily extended to the conditional generation case. The forward hiddenstate transition is modified to ",
309
+ "bbox": [
310
+ 174,
311
+ 786,
312
+ 823,
313
+ 814
314
+ ],
315
+ "page_idx": 2
316
+ },
317
+ {
318
+ "type": "equation",
319
+ "img_path": "images/57d817fb73e5f27815fe695803ced79090918a95a4ebb3481b7fb59101a6dbda.jpg",
320
+ "text": "$$\nh _ { t } ^ { f } = \\Phi _ { f } \\left( x _ { t - 1 } , \\left[ h _ { t - 1 } ^ { f } , c \\right] \\right) ,\n$$",
321
+ "text_format": "latex",
322
+ "bbox": [
323
+ 401,
324
+ 810,
325
+ 594,
326
+ 838
327
+ ],
328
+ "page_idx": 2
329
+ },
330
+ {
331
+ "type": "text",
332
+ "text": "3 RELATED WORK ",
333
+ "text_level": 1,
334
+ "bbox": [
335
+ 176,
336
+ 102,
337
+ 343,
338
+ 117
339
+ ],
340
+ "page_idx": 3
341
+ },
342
+ {
343
+ "type": "text",
344
+ "text": "Bidirectional neural networks (Schuster & Paliwal, 1997) have been used as powerful feature extractors for sequence tasks. The hidden state at each time step includes both information from the past and the future. For this reason, they usually act as better feature extractors than the unidirectional counterpart and have been successfully used in a myriad of tasks, e.g. in machine translation (Bahdanau et al., 2015), question answering (Chen et al., 2017) and sequence labeling (Ma & Hovy, 2016). However, it is not straightforward to apply these models to sequence generation (Zhang et al., 2018) due to the fact that the ancestral sampling process is not allowed to look into the future. In this paper, the backward model is used to regularize the hidden states of the forward model and thus is only used during training. Both inference and sampling are strictly equivalent to the unidirectional case. ",
345
+ "bbox": [
346
+ 174,
347
+ 136,
348
+ 825,
349
+ 275
350
+ ],
351
+ "page_idx": 3
352
+ },
353
+ {
354
+ "type": "text",
355
+ "text": "Gated architectures such as LSTMs (Hochreiter & Schmidhuber, 1997) and GRUs (Chung et al., 2014) have been successful in easing the modeling of long term-dependencies: the gates indicate time-steps for which the network is allowed to keep new information in the memory or forget stored information. Graves et al. (2014); Dieng et al. (2016); Grave et al. (2016) effectively augment the memory of the network by means of an external memory. Another solution for capturing long-term dependencies and avoiding gradient vanishing problems is equipping existing architectures with a hierarchical structure (Serban et al., 2017). Other works tackled the vanishing gradient problem by making the recurrent dynamics unitary (Arjovsky et al., 2016). In parallel, inspired by recent advances in “learning to plan” for reinforcement learning (Silver et al., 2016; Tamar et al., 2016), recent efforts try to augment RNNs with an explicit planning mechanism (Gulcehre et al., 2017b) to force the network to commit to a plan while generating, or to make hidden states predictive of the far future (Li et al., 2017). ",
356
+ "bbox": [
357
+ 174,
358
+ 281,
359
+ 825,
360
+ 448
361
+ ],
362
+ "page_idx": 3
363
+ },
364
+ {
365
+ "type": "text",
366
+ "text": "Regularization methods such as noise injection are also useful to shape the learning dynamics and overcome local correlations to take over the learning process. One of the most popular methods for neural network regularization is dropout (Srivastava et al., 2014). Dropout in RNNs has been proposed in (Moon et al., 2015), and was later extended in (Semeniuta et al., 2016; Gal & Ghahramani, 2016), where recurrent connections are dropped at random. Zoneout (Krueger et al., 2016) modifies the hidden state to regularize the network by effectively creating an ensemble of different length recurrent networks. Krueger & Memisevic (2015) introduce a “norm stabilization” regularization term that ensures that the consecutive hidden states of an RNN have similar Euclidean norm. Recently, Merity et al. (2017) proposed a set of regularization methods that achieve state-of-the-art on the Penn Treebank language modeling dataset. Other RNN regularization methods include the weight noise (Graves, 2011), gradient clipping (Pascanu et al., 2013) and gradient noise (Neelakantan et al., 2015). ",
367
+ "bbox": [
368
+ 174,
369
+ 455,
370
+ 825,
371
+ 622
372
+ ],
373
+ "page_idx": 3
374
+ },
375
+ {
376
+ "type": "text",
377
+ "text": "4 EXPERIMENTAL SETUP AND RESULTS ",
378
+ "text_level": 1,
379
+ "bbox": [
380
+ 176,
381
+ 646,
382
+ 519,
383
+ 662
384
+ ],
385
+ "page_idx": 3
386
+ },
387
+ {
388
+ "type": "text",
389
+ "text": "We now present experiments on conditional and unconditional sequence generation, and analyze the results in an effort to understand the performance gains of TwinNet. First, we examine conditional generation tasks such as speech recognition and image captioning, where the results show clear improvements over the baseline and other regularization methods. Next, we explore unconditional language generation, where we find our model does not significantly improve on the baseline. Finally, to further determine what tasks the model is well-suited to, we analyze a sequential imputation task, where we can vary the task from unconditional to strongly conditional. ",
390
+ "bbox": [
391
+ 174,
392
+ 680,
393
+ 825,
394
+ 777
395
+ ],
396
+ "page_idx": 3
397
+ },
398
+ {
399
+ "type": "text",
400
+ "text": "4.1 SPEECH RECOGNITION ",
401
+ "text_level": 1,
402
+ "bbox": [
403
+ 176,
404
+ 799,
405
+ 374,
406
+ 813
407
+ ],
408
+ "page_idx": 3
409
+ },
410
+ {
411
+ "type": "text",
412
+ "text": "We evaluated our approach on the conditional generation for character-level speech recognition, where the model is trained to convert the speech audio signal to the sequence of characters. The forward and backward RNNs are trained as conditional generative models with softattention (Chorowski et al., 2015). The context information $c$ is an encoding of the audio sequence and the output sequence $s$ is the corresponding character sequence. We evaluate our model on the Wall Street Journal (WSJ) dataset closely following the setting described in Bahdanau et al. (2016). We use 40 mel-filter bank features with delta and delta-deltas with their energies as the acoustic in",
413
+ "bbox": [
414
+ 174,
415
+ 827,
416
+ 823,
417
+ 922
418
+ ],
419
+ "page_idx": 3
420
+ },
421
+ {
422
+ "type": "table",
423
+ "img_path": "images/218f7f84a197b4ca004580d1c605eedb70df7bea7471bc07b3242241eaa99113.jpg",
424
+ "table_caption": [
425
+ "Table 1: Average character error rate (CER, $\\%$ ) on WSJ dataset decoded with the beam size 10. We compare the attention model for speech recognition (“Baseline,” Bahdanau et al., 2016); the regularizer proposed by Krueger & Memisevic (2015) (“Stabilizing norm”); penalty on the L2 norm of the forward states (Merity et al., 2017) (“AR”), which is equivalent to TwinNet when all the hidden states of the backward network are set to zero. We report the results of our model (“TwinNet”) both with $g = I$ , the identity mapping, and with a learned $g$ . "
426
+ ],
427
+ "table_footnote": [],
428
+ "table_body": "<table><tr><td>Model</td><td>Test CER</td><td>Valid CER</td></tr><tr><td>Baseline</td><td>6.8</td><td>9.0</td></tr><tr><td>Baseline +Gaussian noise</td><td>6.9</td><td>9.1</td></tr><tr><td>Baseline + Stabilizing Norm</td><td>6.6</td><td>9.0</td></tr><tr><td>Baseline+AR</td><td>6.5</td><td>8.9</td></tr><tr><td>Baseline + TwinNet (g = I)</td><td>6.6</td><td>8.7</td></tr><tr><td>Baseline + TwinNet (learnt g)</td><td>6.2</td><td>8.4</td></tr></table>",
429
+ "bbox": [
430
+ 299,
431
+ 195,
432
+ 697,
433
+ 310
434
+ ],
435
+ "page_idx": 4
436
+ },
437
+ {
438
+ "type": "text",
439
+ "text": "puts to the model, these features are generated according to the Kaldi s5 recipe (Povey et al., 2011). \nThe resulting input feature dimension is 123. ",
440
+ "bbox": [
441
+ 176,
442
+ 338,
443
+ 820,
444
+ 366
445
+ ],
446
+ "page_idx": 4
447
+ },
448
+ {
449
+ "type": "text",
450
+ "text": "We observe the Character Error Rate (CER) for our validation set, and we early stop on the best CER observed so far. We report CER for both our validation and test sets. For all our models and the baseline, we follow the setup in Bahdanau et al. (2016) and pretrain the model for 1 epoch, within this period, the context window is only allowed to move forward. We then perform 10 epochs of training, where the context window looks freely along the time axis of the encoded sequence, we also perform annealing on the models with 2 different learning rates and 3 epochs for each annealing stage. We use the AdaDelta optimizer for training. We perform a small hyper-parameter search on the weight $\\alpha$ of our twin loss, $\\alpha \\in \\{ 2 . 0 , 1 . 5 , 1 . 0 , 0 . 5 , 0 . 2 5 , 0 . 1 \\} \\nonumber$ , and select the best one according to the CER on the validation set.3 ",
451
+ "bbox": [
452
+ 173,
453
+ 372,
454
+ 825,
455
+ 497
456
+ ],
457
+ "page_idx": 4
458
+ },
459
+ {
460
+ "type": "text",
461
+ "text": "Results We summarize our findings in Table 1. Our best performing model shows relative improvement of $12 \\%$ comparing to the baseline. We found that the TwinNet with a learned metric (learnt $g$ ) is more effective than strictly matching forward and hidden states. In order to gain insights on whether the empirical usefulness comes from using a backward recurrent network, we propose two ablation tests. For “Gaussian Noise,” the backward states are randomly sampled from a Gaussian distribution, therefore the forward states are trained to predict white noise. For “AR,” the backward states are set to zero, which is equivalent to penalizing the norm of the forward hidden states (Merity et al., 2017). Finally, we compare the model with the “Stabilizing Norm” regularizer (Krueger & Memisevic, 2015), that penalizes the difference of the norm of consecutive forward hidden states. Results shows that the information included in the backward states is indeed useful for obtaining a significant improvement. ",
462
+ "bbox": [
463
+ 173,
464
+ 516,
465
+ 825,
466
+ 669
467
+ ],
468
+ "page_idx": 4
469
+ },
470
+ {
471
+ "type": "text",
472
+ "text": "Analysis The training/validation curve comparison for the baseline and our network is presented in Figure 2a.4 The TwinNet converges faster than the baseline and generalizes better. The L2 cost raises in the beginning as the forward and backward network start to learn independently. Later, due to the pressure of this cost, networks produce more aligned hidden representations. Figure 3 provides examples of utterances with L2 plotted along the time axis. We observe that the high entropy words produce spikes in the loss for such words as “uzi.” This is the case for rare words which are hard to predict from the acoustic information. To elaborate on this, we plot the L2 cost averaged over a word depending on the word frequency. The average distance decreases with the increasing frequency. The histogram comparison (Figure 2b) for the cost of rare and frequent words reveal that the not only the average cost is lower for frequent words, but the variance is higher for rare words. Additionally, we plot the dependency of the L2 cost cross-entropy cost of the forward network (Figure 2c) to show that the conditioning also plays the role in the entropy of the output, the losses are not absolutely correlated. ",
473
+ "bbox": [
474
+ 173,
475
+ 688,
476
+ 825,
477
+ 867
478
+ ],
479
+ "page_idx": 4
480
+ },
481
+ {
482
+ "type": "image",
483
+ "img_path": "images/65bf7a391596f728f9455b710810ba7fc977198a004e4810b4e82303658c9219.jpg",
484
+ "image_caption": [
485
+ "Figure 2: Analysis for speech recognition experiments. (a): Training curves comparison for TwinNets and the baseline network. Dotted vertical lines denote stages of pre-training, training, and two stages of annealing. The L2 cost is plotted alongside. The TwinNet converges to a better solution as well as provides better generalization. (b): Comparison of histograms of the cost for rare words (first 1500) versus frequent words (all other). The cost is averaged over characters of a word. The distribution of rare words is wider and tends to produce higher L2 cost. (c): L2 loss vs. average cross-entropy loss. "
486
+ ],
487
+ "image_footnote": [],
488
+ "bbox": [
489
+ 184,
490
+ 102,
491
+ 813,
492
+ 252
493
+ ],
494
+ "page_idx": 5
495
+ },
496
+ {
497
+ "type": "image",
498
+ "img_path": "images/b4d567b88d393438a5fd29e3fcb65191022c1f07ab47f5bfab69fcbca281ad64.jpg",
499
+ "image_caption": [
500
+ "Figure 3: Example of the L2 loss plotted along the time axis. Notice that spikes correspond to rare words given the acoustic information where the entropy of the prediction is high. Dotted vertical lines are plotted at word boundary positions. "
501
+ ],
502
+ "image_footnote": [],
503
+ "bbox": [
504
+ 179,
505
+ 385,
506
+ 815,
507
+ 609
508
+ ],
509
+ "page_idx": 5
510
+ },
511
+ {
512
+ "type": "text",
513
+ "text": "4.2 IMAGE CAPTIONING ",
514
+ "text_level": 1,
515
+ "bbox": [
516
+ 176,
517
+ 695,
518
+ 356,
519
+ 709
520
+ ],
521
+ "page_idx": 5
522
+ },
523
+ {
524
+ "type": "text",
525
+ "text": "We evaluate our model on the conditional generation task of image captioning task on Microsoft COCO dataset (Lin et al., 2014). The MS COCO dataset covers 82,783 training images and 40,504 images for validation. Due to the lack of standardized split of training, validation and test data, we follow Karpathy’s split (Karpathy & Fei-Fei, 2015; Xu et al., 2015; Wang et al., 2016). These are 80,000 training images and 5,000 images for validation and test. We do early stopping based on the validation CIDEr scores and we report BLEU-1 to BLEU-4, CIDEr, and Meteor scores. To evaluate the consistency of our method, we tested TwinNet on both encoder-decoder (‘Show&Tell’, Vinyals et al., 2015) and soft attention (‘Show, Attend and Tell’, Xu et al., 2015) image captioning models.5 ",
526
+ "bbox": [
527
+ 174,
528
+ 722,
529
+ 825,
530
+ 833
531
+ ],
532
+ "page_idx": 5
533
+ },
534
+ {
535
+ "type": "text",
536
+ "text": "We use a Resnet (He et al., 2016) with 101 and 152 layers pre-trained on ImageNet for image classification. The last layer of the Resned is used to extract 2048 dimensional input features for the attention model (Xu et al., 2015). We use an LSTM with 512 hidden units for both “Show & Tell” and soft attention. Both models are trained with the Adam (Kingma & Ba, 2014) optimizer with a ",
537
+ "bbox": [
538
+ 176,
539
+ 840,
540
+ 825,
541
+ 896
542
+ ],
543
+ "page_idx": 5
544
+ },
545
+ {
546
+ "type": "table",
547
+ "img_path": "images/4995fc3314cc9bceedf081f5edc8d13ce588fa082a2e25c5f8e8b06569c13221.jpg",
548
+ "table_caption": [
549
+ "Table 2: Results for image captioning on the MS COCO dataset, the higher the better for all metrics (BLEU 1 to 4, METEOR, and CIDEr). We reimplement both Show&Tell (Vinyals et al., 2015) and Soft Attention (Xu et al., 2015) in order to add the twin cost. We use two types of images features extracted either with Resnet-101 or Resnet-152. "
550
+ ],
551
+ "table_footnote": [],
552
+ "table_body": "<table><tr><td>Models</td><td>B-1</td><td>B-2</td><td>B-3</td><td>B-4</td><td>METEOR</td><td>CIDEr</td></tr><tr><td>DeepVS (Karpathy &amp; Fei-Fei,2015)</td><td>62.5</td><td>45.0</td><td>32.1</td><td>23.0</td><td>19.5</td><td>66.0</td></tr><tr><td>ATT-FCN (You et al., 2016)</td><td>70.9</td><td>53.7</td><td>40.2</td><td>30.4</td><td>24.3</td><td>1</td></tr><tr><td>Show &amp; Tell(Vinyals et al.,2015)</td><td>-</td><td></td><td>1</td><td>27.7</td><td>23.7</td><td>85.5</td></tr><tr><td>Soft Attention (Xu et al.,2015)</td><td>70.7</td><td>49.2</td><td>34.4</td><td>24.3</td><td>23.9</td><td>-</td></tr><tr><td>Hard Attention (Xu et al., 2015)</td><td>71.8</td><td>50.4</td><td>35.7</td><td>25.0</td><td>23.0</td><td>-</td></tr><tr><td>MSM (Yao et al., 2016)</td><td>73.0</td><td>56.5</td><td>42.9</td><td>32.5</td><td>25.1</td><td>98.6</td></tr><tr><td>Adaptive Attention (Lu et al., 2017)</td><td>74.2</td><td>58.0</td><td>43.9</td><td>33.2</td><td>26.6</td><td>108.5</td></tr><tr><td>No attention, Resnet101</td><td></td><td></td><td></td><td></td><td></td><td></td></tr><tr><td>Show&amp;Tell (Our impl.)</td><td>69.4</td><td>51.6</td><td>36.9</td><td>26.3</td><td>23.4</td><td>84.3</td></tr><tr><td>+ TwinNet</td><td>71.8</td><td>54.5</td><td>39.4</td><td>28.0</td><td>24.0</td><td>87.7</td></tr><tr><td>Attention, Resnet101</td><td></td><td></td><td></td><td></td><td></td><td></td></tr><tr><td>Soft Attention (Our impl.)</td><td>71.0</td><td>53.7</td><td>39.0</td><td>28.1</td><td>24.0</td><td>89.2</td></tr><tr><td>+ TwinNet</td><td>72.8</td><td>55.7</td><td>41.0</td><td>29.7</td><td>25.2</td><td>96.2</td></tr><tr><td>No attention, Resnet152</td><td></td><td></td><td></td><td></td><td></td><td></td></tr><tr><td>Show&amp;Tell (Our impl.)</td><td>71.7</td><td>54.4</td><td>39.7</td><td>28.8</td><td>24.8</td><td>93.0</td></tr><tr><td>+ TwinNet</td><td>72.3</td><td>55.2</td><td>40.4</td><td>29.3</td><td>25.1</td><td>94.7</td></tr><tr><td>Attention, Resnet152</td><td></td><td></td><td></td><td></td><td></td><td></td></tr><tr><td>Soft Attention (Our impl.)</td><td>73.2</td><td>56.3</td><td>41.4</td><td>30.1</td><td>25.3</td><td>96.6</td></tr><tr><td>+ TwinNet</td><td>73.8</td><td>56.9</td><td>42.0</td><td>30.6</td><td>25.2</td><td>97.3</td></tr></table>",
553
+ "bbox": [
554
+ 214,
555
+ 167,
556
+ 784,
557
+ 462
558
+ ],
559
+ "page_idx": 6
560
+ },
561
+ {
562
+ "type": "text",
563
+ "text": "Table 3: (left) Test set negative log-likelihood for binarized sequential MNIST, where H denotes lower performance of our model with respect to the baselines. (right) Perplexity results on WikiText-2 and Penn Treebank (Merity et al., 2017). AWD-LSTM refers to the model of (Merity et al., 2017) trained with the official implementation at http://github.com/salesforce/awd-lstm/. ",
564
+ "bbox": [
565
+ 173,
566
+ 477,
567
+ 825,
568
+ 547
569
+ ],
570
+ "page_idx": 6
571
+ },
572
+ {
573
+ "type": "table",
574
+ "img_path": "images/fabad8e0d5e7902eb81636ea5c307791432222865f768711675609162125ed36.jpg",
575
+ "table_caption": [],
576
+ "table_footnote": [],
577
+ "table_body": "<table><tr><td>Model</td><td>MNIST</td></tr><tr><td>DBN 2hl (Germain et al., 2015) NADE (Uria et al., 2016)</td><td>~84.55</td></tr><tr><td>EoNADE-5 2hl (Raiko et al.,2014)</td><td>88.33</td></tr><tr><td>DLGM 8 (Salimans et al.,2014)</td><td>84.68</td></tr><tr><td>DARN 1hl (Gregor et al., 2015)</td><td>~85.51 ~84.13</td></tr><tr><td>DRAW (Gregor et al.,2015)</td><td>≤80.97</td></tr><tr><td>P-Forcing(-layer) (Lamb et al.,2016)</td><td>79.58</td></tr><tr><td>PixelRNN(1-layer) (Oord et al.,2016b)</td><td></td></tr><tr><td>PixelRNN(7-layer) (Oord et al.,2016b)</td><td>80.75</td></tr><tr><td>PixelVAE (Gulrajani et al.,2016)</td><td>79.20</td></tr><tr><td>MatNets (Bachman,2016)</td><td>79.02 78.50</td></tr><tr><td>Baseline LSTM(3-layers)</td><td>79.87</td></tr><tr><td>+ TwinNet(3-layers)</td><td>79.35</td></tr><tr><td>Baseline LSTM(3-layers) + dropout + TwinNet(3-layers)</td><td>79.59 79.12</td></tr></table>",
578
+ "bbox": [
579
+ 176,
580
+ 559,
581
+ 486,
582
+ 790
583
+ ],
584
+ "page_idx": 6
585
+ },
586
+ {
587
+ "type": "table",
588
+ "img_path": "images/7452b5e93ac09ffc18f0ef1d4e5ea77a7fea14821744728680fa75c985fcfb78.jpg",
589
+ "table_caption": [],
590
+ "table_footnote": [],
591
+ "table_body": "<table><tr><td>Penn Treebank</td><td>Valid</td><td>Test</td></tr><tr><td>LSTM (Zaremba et al., 2014) 4-layer LSTM (Melis et al., 2017) 5-layer RHN (Melis et al.,2017)</td><td>82.2 67.9</td><td>78.4 65.4</td></tr><tr><td>AWD-LSTM</td><td>64.8 61.2</td><td>62.2 58.8</td></tr><tr><td>+ TwinNet</td><td>61.0</td><td>58.3</td></tr><tr><td>WikiText-2 5-layer RHN (Melis et al.,2017)</td><td>Valid</td><td>Test</td></tr><tr><td>1-layer LSTM (Melis et al., 2017) 2-layer LSTM(Melis et al., 2017)</td><td>78.1 69.3 69.1</td><td>75.6 65.9</td></tr><tr><td>AWD-LSTM</td><td>68.7</td><td>65.9</td></tr><tr><td>+ TwinNet</td><td>68.0</td><td>65.8 64.9</td></tr></table>",
592
+ "bbox": [
593
+ 498,
594
+ 560,
595
+ 820,
596
+ 760
597
+ ],
598
+ "page_idx": 6
599
+ },
600
+ {
601
+ "type": "text",
602
+ "text": "learning rate of $1 0 ^ { - 4 }$ . TwinNet showed consistent improvements over “Show & Tell” (Table 2). For the soft attention model we observe small but consistent improvements for majority of scores. ",
603
+ "bbox": [
604
+ 174,
605
+ 819,
606
+ 825,
607
+ 848
608
+ ],
609
+ "page_idx": 6
610
+ },
611
+ {
612
+ "type": "text",
613
+ "text": "4.3 UNCONDITIONAL GENERATION: SEQUENTIAL MNIST AND LANGUAGE MODELING ",
614
+ "text_level": 1,
615
+ "bbox": [
616
+ 173,
617
+ 867,
618
+ 795,
619
+ 882
620
+ ],
621
+ "page_idx": 6
622
+ },
623
+ {
624
+ "type": "text",
625
+ "text": "We investigate the performance of our model in pixel-by-pixel generation for sequential MNIST. We follow the setting described by Lamb et al. (2016): we use an LSTM with 3-layers of 512 hidden units for both forward and backward LSTMs, batch size 20, learning rate 0.001 and clip the gradient norms to 5. We use Adam (Kingma & Ba, 2014) as our optimization algorithm and we decay the learning rate by half after 5, 10, and 15 epochs. Our results are reported at the Table 3 (left). Our baseline LSTM implementation achieves 79.87 nats on the test set. We observe that by adding the TwinNet regularization cost consistently improves performance in this setting by about 0.52 nats. Adding dropout to the baseline LSTM is beneficial. Further gains were observed by adding both dropout and the TwinNet regularization cost. This last model achieves 79.12 nats on test set. Note that this result is competitive with deeper models such as PixelRNN (Oord et al., 2016b) (7-layers) and PixelVAE (Gulrajani et al., 2016) which uses an autoregressive decoder coupled with a deep stochastic auto-encoder. ",
626
+ "bbox": [
627
+ 174,
628
+ 895,
629
+ 820,
630
+ 924
631
+ ],
632
+ "page_idx": 6
633
+ },
634
+ {
635
+ "type": "text",
636
+ "text": "",
637
+ "bbox": [
638
+ 174,
639
+ 103,
640
+ 825,
641
+ 242
642
+ ],
643
+ "page_idx": 7
644
+ },
645
+ {
646
+ "type": "text",
647
+ "text": "As a last experiment, we report results obtained on a language modelling task using the PennTree Bank and WikiText-2 datasets (Merity et al., 2017). We augment the state-of-the-art AWD-LSTM model (Merity et al., 2017) with the proposed TwinNet regularization cost. The results are reported in Table 3 (right). ",
648
+ "bbox": [
649
+ 174,
650
+ 250,
651
+ 825,
652
+ 306
653
+ ],
654
+ "page_idx": 7
655
+ },
656
+ {
657
+ "type": "text",
658
+ "text": "5 DISCUSSION ",
659
+ "text_level": 1,
660
+ "bbox": [
661
+ 176,
662
+ 325,
663
+ 310,
664
+ 342
665
+ ],
666
+ "page_idx": 7
667
+ },
668
+ {
669
+ "type": "text",
670
+ "text": "In this paper, we presented a simple recurrent neural network model that has two separate networks running in opposite directions during training. Our model is motivated by the fact that states of the forward model should be predictive of the entire future sequence. This may be hard to obtain by optimizing one-step ahead predictions. The backward path is discarded during the sampling and evaluation process, which makes the sampling process efficient. Empirical results show that the proposed method performs well on conditional generation for several tasks. The analysis reveals an interpretable behaviour of the proposed loss. ",
671
+ "bbox": [
672
+ 174,
673
+ 357,
674
+ 825,
675
+ 454
676
+ ],
677
+ "page_idx": 7
678
+ },
679
+ {
680
+ "type": "text",
681
+ "text": "One of the shortcomings of the proposed approach is that the training process doubles the computation needed for the baseline (due to the backward network training). However, since the backward network is discarded during sampling, the sampling or inference process has the exact same computation steps as the baseline. This makes our approach applicable to models that requires expensive sampling steps, such as PixelRNNs (Oord et al., 2016b) and WaveNet (Oord et al., 2016a). One of future work directions is to test whether it could help in conditional speech synthesis using WaveNet. ",
682
+ "bbox": [
683
+ 174,
684
+ 462,
685
+ 825,
686
+ 545
687
+ ],
688
+ "page_idx": 7
689
+ },
690
+ {
691
+ "type": "text",
692
+ "text": "We observed that the proposed approach yield minor improvements when applied to language modelling with PennTree bank. We hypothesize that this may be linked to the amount of entropy of the target distribution. In these high-entropy cases, at any time-step in the sequence, the distribution of backward states may be highly multi-modal (many possible futures may be equally likely for the same past). One way of overcoming this problem would be to replace the proposed L2 loss (which implicitly assumes a unimodal distribution of the backward states) by a more expressive loss obtained by either employing an inference network (Kingma & Welling, 2013) or distribution matching techniques (Goodfellow et al., 2014). We leave that for future investigation. ",
693
+ "bbox": [
694
+ 174,
695
+ 551,
696
+ 825,
697
+ 664
698
+ ],
699
+ "page_idx": 7
700
+ },
701
+ {
702
+ "type": "text",
703
+ "text": "ACKNOWLEDGMENTS ",
704
+ "text_level": 1,
705
+ "bbox": [
706
+ 176,
707
+ 685,
708
+ 356,
709
+ 700
710
+ ],
711
+ "page_idx": 7
712
+ },
713
+ {
714
+ "type": "text",
715
+ "text": "The authors would like to acknowledge the support of the following agencies for research funding and computing support: NSERC, Calcul Quebec, Compute Canada, the Canada Research Chairs, ´ CIFAR, and Samsung. We would also like to thank the developers of Theano Theano Development Team (2016), Blocks and Fuel van Merrienboer et al. (2015), and Pytorch for developments of great ¨ frameworks. We thank Aaron Courville, Sandeep Subramanian, Marc-Alexandre Cotˆ e, Anirudh ´ Goyal, Alex Lamb, Philemon Brakel, Devon Hjelm, Kyle Kastner, Olivier Breuleux, Phil Bachman, and Gaetan Marceau Caron for useful feedback and discussions. ´ ",
716
+ "bbox": [
717
+ 174,
718
+ 715,
719
+ 825,
720
+ 813
721
+ ],
722
+ "page_idx": 7
723
+ },
724
+ {
725
+ "type": "text",
726
+ "text": "REFERENCES ",
727
+ "text_level": 1,
728
+ "bbox": [
729
+ 176,
730
+ 102,
731
+ 287,
732
+ 118
733
+ ],
734
+ "page_idx": 8
735
+ },
736
+ {
737
+ "type": "text",
738
+ "text": "Martin Arjovsky, Amar Shah, and Yoshua Bengio. Unitary evolution recurrent neural networks. In ICML, 2016. ",
739
+ "bbox": [
740
+ 173,
741
+ 126,
742
+ 825,
743
+ 155
744
+ ],
745
+ "page_idx": 8
746
+ },
747
+ {
748
+ "type": "text",
749
+ "text": "Philip Bachman. An architecture for deep, hierarchical generative models. In NIPS, 2016. ",
750
+ "bbox": [
751
+ 171,
752
+ 164,
753
+ 763,
754
+ 180
755
+ ],
756
+ "page_idx": 8
757
+ },
758
+ {
759
+ "type": "text",
760
+ "text": "Dzmitry Bahdanau, Kyunghyun Cho, and Yoshua Bengio. Neural machine translation by jointly learning to align and translate. arXiv preprint arXiv:1409.0473, 2014. ",
761
+ "bbox": [
762
+ 171,
763
+ 189,
764
+ 823,
765
+ 218
766
+ ],
767
+ "page_idx": 8
768
+ },
769
+ {
770
+ "type": "text",
771
+ "text": "Dzmitry Bahdanau, Dmitriy Serdyuk, Philemon Brakel, Nan Rosemary Ke, Jan Chorowski, Aaron C. Courville, and Yoshua Bengio. Task loss estimation for sequence prediction. 2015. ",
772
+ "bbox": [
773
+ 173,
774
+ 227,
775
+ 823,
776
+ 257
777
+ ],
778
+ "page_idx": 8
779
+ },
780
+ {
781
+ "type": "text",
782
+ "text": "Dzmitry Bahdanau, Jan Chorowski, Dmitriy Serdyuk, Philemon Brakel, and Yoshua Bengio. Endto-end attention-based large vocabulary speech recognition. ICASSP, 2016. ",
783
+ "bbox": [
784
+ 173,
785
+ 265,
786
+ 823,
787
+ 295
788
+ ],
789
+ "page_idx": 8
790
+ },
791
+ {
792
+ "type": "text",
793
+ "text": "Lalit R Bahl, Frederick Jelinek, and Robert L Mercer. A maximum likelihood approach to continuous speech recognition. IEEE transactions on pattern analysis and machine intelligence, (2), 1983. ",
794
+ "bbox": [
795
+ 178,
796
+ 304,
797
+ 823,
798
+ 347
799
+ ],
800
+ "page_idx": 8
801
+ },
802
+ {
803
+ "type": "text",
804
+ "text": "Yoshua Bengio, Patrice Simard, and Paolo Frasconi. Learning long-term dependencies with gradient descent is difficult. IEEE transactions on neural networks, 1994. ",
805
+ "bbox": [
806
+ 173,
807
+ 356,
808
+ 821,
809
+ 386
810
+ ],
811
+ "page_idx": 8
812
+ },
813
+ {
814
+ "type": "text",
815
+ "text": "Yoshua Bengio, Rejean Ducharme, Pascal Vincent, and Christian Jauvin. A neural probabilistic ´ language model. JMLR, 2003. ",
816
+ "bbox": [
817
+ 176,
818
+ 395,
819
+ 821,
820
+ 424
821
+ ],
822
+ "page_idx": 8
823
+ },
824
+ {
825
+ "type": "text",
826
+ "text": "Leon Bottou. Curiously fast convergence of some stochastic gradient descent algorithms. In ´ Proceedings of the symposium on learning and data science, Paris, 2009. ",
827
+ "bbox": [
828
+ 174,
829
+ 434,
830
+ 821,
831
+ 463
832
+ ],
833
+ "page_idx": 8
834
+ },
835
+ {
836
+ "type": "text",
837
+ "text": "William Chan, Navdeep Jaitly, Quoc V Le, and Oriol Vinyals. Listen, attend and spell. ICASSP, 2016. ",
838
+ "bbox": [
839
+ 173,
840
+ 470,
841
+ 823,
842
+ 501
843
+ ],
844
+ "page_idx": 8
845
+ },
846
+ {
847
+ "type": "text",
848
+ "text": "Danqi Chen, Adam Fisch, Jason Weston, and Antoine Bordes. Reading Wikipedia to answer opendomain questions. arXiv preprint arXiv:1704.00051, 2017. ",
849
+ "bbox": [
850
+ 173,
851
+ 510,
852
+ 823,
853
+ 540
854
+ ],
855
+ "page_idx": 8
856
+ },
857
+ {
858
+ "type": "text",
859
+ "text": "Kyunghyun Cho, Bart Van Merrienboer, Caglar Gulcehre, Dzmitry Bahdanau, Fethi Bougares, Hol- ¨ ger Schwenk, and Yoshua Bengio. Learning phrase representations using RNN encoder-decoder for statistical machine translation. 2014. ",
860
+ "bbox": [
861
+ 173,
862
+ 547,
863
+ 823,
864
+ 592
865
+ ],
866
+ "page_idx": 8
867
+ },
868
+ {
869
+ "type": "text",
870
+ "text": "Jan K Chorowski, Dzmitry Bahdanau, Dmitriy Serdyuk, Kyunghyun Cho, and Yoshua Bengio. Attention-based models for speech recognition. In NIPS. 2015. ",
871
+ "bbox": [
872
+ 168,
873
+ 601,
874
+ 821,
875
+ 631
876
+ ],
877
+ "page_idx": 8
878
+ },
879
+ {
880
+ "type": "text",
881
+ "text": "Junyoung Chung, Caglar Gulcehre, KyungHyun Cho, and Yoshua Bengio. Empirical evaluation of gated recurrent neural networks on sequence modeling. arXiv:1412.3555, 2014. ",
882
+ "bbox": [
883
+ 171,
884
+ 638,
885
+ 823,
886
+ 670
887
+ ],
888
+ "page_idx": 8
889
+ },
890
+ {
891
+ "type": "text",
892
+ "text": "Adji B Dieng, Chong Wang, Jianfeng Gao, and John Paisley. TopicRNN: A recurrent neural network with long-range semantic dependency. arXiv preprint arXiv:1611.01702, 2016. ",
893
+ "bbox": [
894
+ 171,
895
+ 678,
896
+ 821,
897
+ 708
898
+ ],
899
+ "page_idx": 8
900
+ },
901
+ {
902
+ "type": "text",
903
+ "text": "Yarin Gal and Zoubin Ghahramani. A theoretically grounded application of dropout in recurrent neural networks. In NIPS, 2016. ",
904
+ "bbox": [
905
+ 171,
906
+ 715,
907
+ 823,
908
+ 746
909
+ ],
910
+ "page_idx": 8
911
+ },
912
+ {
913
+ "type": "text",
914
+ "text": "Mathieu Germain, Karol Gregor, Iain Murray, and Hugo Larochelle. MADE: Masked autoencoder for distribution estimation. In ICML, 2015. ",
915
+ "bbox": [
916
+ 169,
917
+ 755,
918
+ 825,
919
+ 784
920
+ ],
921
+ "page_idx": 8
922
+ },
923
+ {
924
+ "type": "text",
925
+ "text": "Ian Goodfellow, Jean Pouget-Abadie, Mehdi Mirza, Bing Xu, David Warde-Farley, Sherjil Ozair, Aaron Courville, and Yoshua Bengio. Generative adversarial nets. In NIPS, 2014. ",
926
+ "bbox": [
927
+ 169,
928
+ 792,
929
+ 823,
930
+ 823
931
+ ],
932
+ "page_idx": 8
933
+ },
934
+ {
935
+ "type": "text",
936
+ "text": "Edouard Grave, Armand Joulin, and Nicolas Usunier. Improving neural language models with a continuous cache. arXiv preprint arXiv:1612.04426, 2016. ",
937
+ "bbox": [
938
+ 173,
939
+ 832,
940
+ 821,
941
+ 861
942
+ ],
943
+ "page_idx": 8
944
+ },
945
+ {
946
+ "type": "text",
947
+ "text": "Alex Graves. Practical variational inference for neural networks. In NIPS, 2011. ",
948
+ "bbox": [
949
+ 171,
950
+ 871,
951
+ 700,
952
+ 886
953
+ ],
954
+ "page_idx": 8
955
+ },
956
+ {
957
+ "type": "text",
958
+ "text": "Alex Graves, Greg Wayne, and Ivo Danihelka. Neural turing machines. arXiv preprint arXiv:1410.5401, 2014. ",
959
+ "bbox": [
960
+ 173,
961
+ 895,
962
+ 821,
963
+ 924
964
+ ],
965
+ "page_idx": 8
966
+ },
967
+ {
968
+ "type": "text",
969
+ "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. ",
970
+ "bbox": [
971
+ 173,
972
+ 103,
973
+ 823,
974
+ 133
975
+ ],
976
+ "page_idx": 9
977
+ },
978
+ {
979
+ "type": "text",
980
+ "text": "Caglar Gulcehre, Sarath Chandar, and Yoshua Bengio. Memory augmented neural networks with wormhole connections. arXiv preprint arXiv:1701.08718, 2017a. ",
981
+ "bbox": [
982
+ 174,
983
+ 141,
984
+ 821,
985
+ 170
986
+ ],
987
+ "page_idx": 9
988
+ },
989
+ {
990
+ "type": "text",
991
+ "text": "Caglar Gulcehre, Francis Dutil, Adam Trischler, and Yoshua Bengio. Plan, attend, generate: Planning for sequence-to-sequence models. In Proc. of NIPS, 2017b. ",
992
+ "bbox": [
993
+ 174,
994
+ 178,
995
+ 821,
996
+ 208
997
+ ],
998
+ "page_idx": 9
999
+ },
1000
+ {
1001
+ "type": "text",
1002
+ "text": "Ishaan Gulrajani, Kundan Kumar, Faruk Ahmed, Adrien Ali Taiga, Francesco Visin, David Vazquez, and Aaron Courville. PixelVAE: A latent variable model for natural images. arXiv preprint arXiv:1611.05013, 2016. ",
1003
+ "bbox": [
1004
+ 174,
1005
+ 215,
1006
+ 823,
1007
+ 260
1008
+ ],
1009
+ "page_idx": 9
1010
+ },
1011
+ {
1012
+ "type": "text",
1013
+ "text": "Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. Deep residual learning for image recognition. In CVPR, 2016. ",
1014
+ "bbox": [
1015
+ 173,
1016
+ 267,
1017
+ 823,
1018
+ 297
1019
+ ],
1020
+ "page_idx": 9
1021
+ },
1022
+ {
1023
+ "type": "text",
1024
+ "text": "Sepp Hochreiter. Untersuchungen zu dynamischen neuronalen netzen. Diploma, Technische Universitat M¨ unchen ¨ , 91, 1991. ",
1025
+ "bbox": [
1026
+ 173,
1027
+ 305,
1028
+ 823,
1029
+ 335
1030
+ ],
1031
+ "page_idx": 9
1032
+ },
1033
+ {
1034
+ "type": "text",
1035
+ "text": "Sepp Hochreiter and Jurgen Schmidhuber. Long short-term memory. ¨ Neural computation, 1997. ",
1036
+ "bbox": [
1037
+ 173,
1038
+ 343,
1039
+ 807,
1040
+ 359
1041
+ ],
1042
+ "page_idx": 9
1043
+ },
1044
+ {
1045
+ "type": "text",
1046
+ "text": "Andrej Karpathy and Li Fei-Fei. Deep visual-semantic alignments for generating image descriptions. In CVPR, 2015. ",
1047
+ "bbox": [
1048
+ 173,
1049
+ 367,
1050
+ 823,
1051
+ 396
1052
+ ],
1053
+ "page_idx": 9
1054
+ },
1055
+ {
1056
+ "type": "text",
1057
+ "text": "Diederik Kingma and Jimmy Ba. Adam: A method for stochastic optimization. arXiv preprint arXiv:1412.6980, 2014. ",
1058
+ "bbox": [
1059
+ 174,
1060
+ 405,
1061
+ 823,
1062
+ 434
1063
+ ],
1064
+ "page_idx": 9
1065
+ },
1066
+ {
1067
+ "type": "text",
1068
+ "text": "Diederik P Kingma and Max Welling. Auto-encoding variational Bayes. arXiv preprint arXiv:1312.6114, 2013. ",
1069
+ "bbox": [
1070
+ 173,
1071
+ 443,
1072
+ 825,
1073
+ 472
1074
+ ],
1075
+ "page_idx": 9
1076
+ },
1077
+ {
1078
+ "type": "text",
1079
+ "text": "David Krueger and Roland Memisevic. Regularizing RNNs by stabilizing activations. arXiv:1511.08400, 2015. ",
1080
+ "bbox": [
1081
+ 171,
1082
+ 479,
1083
+ 821,
1084
+ 510
1085
+ ],
1086
+ "page_idx": 9
1087
+ },
1088
+ {
1089
+ "type": "text",
1090
+ "text": "David Krueger, Tegan Maharaj, Janos Kram ´ ar, Mohammad Pezeshki, Nicolas Ballas, Nan Rose- ´ mary Ke, Anirudh Goyal, Yoshua Bengio, Hugo Larochelle, Aaron Courville, and Chistopher Pal. Zoneout: Regularizing RNNs by randomly preserving hidden activations. 2016. ",
1091
+ "bbox": [
1092
+ 176,
1093
+ 517,
1094
+ 821,
1095
+ 561
1096
+ ],
1097
+ "page_idx": 9
1098
+ },
1099
+ {
1100
+ "type": "text",
1101
+ "text": "Alex M Lamb, Anirudh Goyal, Ying Zhang, Saizheng Zhang, Aaron C Courville, and Yoshua Bengio. Professor forcing: A new algorithm for training recurrent networks. In NIPS, 2016. ",
1102
+ "bbox": [
1103
+ 173,
1104
+ 569,
1105
+ 821,
1106
+ 599
1107
+ ],
1108
+ "page_idx": 9
1109
+ },
1110
+ {
1111
+ "type": "text",
1112
+ "text": "Jiwei Li, Will Monroe, and Dan Jurafsky. Learning to decode for future success. 2017. ",
1113
+ "bbox": [
1114
+ 171,
1115
+ 607,
1116
+ 745,
1117
+ 623
1118
+ ],
1119
+ "page_idx": 9
1120
+ },
1121
+ {
1122
+ "type": "text",
1123
+ "text": "Tsung-Yi Lin, Michael Maire, Serge Belongie, James Hays, Pietro Perona, Deva Ramanan, Piotr Dollar, and C Lawrence Zitnick. Microsoft COCO: Common objects in context. In ´ European conference on computer vision, 2014. ",
1124
+ "bbox": [
1125
+ 176,
1126
+ 631,
1127
+ 823,
1128
+ 674
1129
+ ],
1130
+ "page_idx": 9
1131
+ },
1132
+ {
1133
+ "type": "text",
1134
+ "text": "Jiasen Lu, Caiming Xiong, Devi Parikh, and Richard Socher. Knowing when to look: Adaptive attention via a visual sentinel for image captioning. In Proc. of CVPR 17, 2017. ",
1135
+ "bbox": [
1136
+ 171,
1137
+ 683,
1138
+ 821,
1139
+ 712
1140
+ ],
1141
+ "page_idx": 9
1142
+ },
1143
+ {
1144
+ "type": "text",
1145
+ "text": "Xuezhe Ma and Eduard Hovy. End-to-end sequence labeling via bi-directional LSTM-CNNs-CRF. arXiv preprint arXiv:1603.01354, 2016. ",
1146
+ "bbox": [
1147
+ 173,
1148
+ 719,
1149
+ 821,
1150
+ 750
1151
+ ],
1152
+ "page_idx": 9
1153
+ },
1154
+ {
1155
+ "type": "text",
1156
+ "text": "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. ",
1157
+ "bbox": [
1158
+ 174,
1159
+ 758,
1160
+ 821,
1161
+ 787
1162
+ ],
1163
+ "page_idx": 9
1164
+ },
1165
+ {
1166
+ "type": "text",
1167
+ "text": "Stephen Merity, Nitish Shirish Keskar, and Richard Socher. Regularizing and optimizing LSTM language models. arXiv preprint arXiv:1708.02182, 2017. ",
1168
+ "bbox": [
1169
+ 173,
1170
+ 796,
1171
+ 823,
1172
+ 825
1173
+ ],
1174
+ "page_idx": 9
1175
+ },
1176
+ {
1177
+ "type": "text",
1178
+ "text": "Tomas Mikolov. Recurrent neural network based language model. 2010. ",
1179
+ "bbox": [
1180
+ 173,
1181
+ 833,
1182
+ 651,
1183
+ 849
1184
+ ],
1185
+ "page_idx": 9
1186
+ },
1187
+ {
1188
+ "type": "text",
1189
+ "text": "Taesup Moon, Heeyoul Choi, Hoshik Lee, and Inchul Song. RNNDROP: A novel dropout for RNNs in ASR. In ASRU, 2015. ",
1190
+ "bbox": [
1191
+ 173,
1192
+ 857,
1193
+ 820,
1194
+ 887
1195
+ ],
1196
+ "page_idx": 9
1197
+ },
1198
+ {
1199
+ "type": "text",
1200
+ "text": "Arvind Neelakantan, Luke Vilnis, Quoc V Le, Ilya Sutskever, Lukasz Kaiser, Karol Kurach, and James Martens. Adding gradient noise improves learning for very deep networks. 2015. ",
1201
+ "bbox": [
1202
+ 173,
1203
+ 895,
1204
+ 821,
1205
+ 924
1206
+ ],
1207
+ "page_idx": 9
1208
+ },
1209
+ {
1210
+ "type": "text",
1211
+ "text": "Aaron van den Oord, Sander Dieleman, Heiga Zen, Karen Simonyan, Oriol Vinyals, Alex Graves, Nal Kalchbrenner, Andrew Senior, and Koray Kavukcuoglu. Wavenet: A generative model for raw audio. arXiv:1609.03499, 2016a. ",
1212
+ "bbox": [
1213
+ 176,
1214
+ 103,
1215
+ 821,
1216
+ 146
1217
+ ],
1218
+ "page_idx": 10
1219
+ },
1220
+ {
1221
+ "type": "text",
1222
+ "text": "Aaron van den Oord, Nal Kalchbrenner, and Koray Kavukcuoglu. Pixel recurrent neural networks. arXiv preprint arXiv:1601.06759, 2016b. ",
1223
+ "bbox": [
1224
+ 173,
1225
+ 154,
1226
+ 821,
1227
+ 183
1228
+ ],
1229
+ "page_idx": 10
1230
+ },
1231
+ {
1232
+ "type": "text",
1233
+ "text": "Razvan Pascanu, Tomas Mikolov, and Yoshua Bengio. On the difficulty of training recurrent neural networks. In ICML, 2013. ",
1234
+ "bbox": [
1235
+ 173,
1236
+ 191,
1237
+ 823,
1238
+ 220
1239
+ ],
1240
+ "page_idx": 10
1241
+ },
1242
+ {
1243
+ "type": "text",
1244
+ "text": "Daniel Povey, Arnab Ghoshal, Gilles Boulianne, Lukas Burget, Ondrej Glembek, Nagendra Goel, Mirko Hannemann, Petr Motlicek, Yanmin Qian, Petr Schwarz, et al. The Kaldi speech recognition toolkit. In IEEE 2011 workshop on automatic speech recognition and understanding, 2011. ",
1245
+ "bbox": [
1246
+ 176,
1247
+ 228,
1248
+ 823,
1249
+ 272
1250
+ ],
1251
+ "page_idx": 10
1252
+ },
1253
+ {
1254
+ "type": "text",
1255
+ "text": "Tapani Raiko, Yao Li, Kyunghyun Cho, and Yoshua Bengio. Iterative neural autoregressive distribution estimator nade-k. In NIPS, 2014. ",
1256
+ "bbox": [
1257
+ 173,
1258
+ 280,
1259
+ 823,
1260
+ 309
1261
+ ],
1262
+ "page_idx": 10
1263
+ },
1264
+ {
1265
+ "type": "text",
1266
+ "text": "Tim Salimans, Diederik P Kingma, and Max Welling. Markov chain monte carlo and variational inference: Bridging the gap. arXiv preprint arXiv:1410.6460, 2014. ",
1267
+ "bbox": [
1268
+ 171,
1269
+ 316,
1270
+ 823,
1271
+ 347
1272
+ ],
1273
+ "page_idx": 10
1274
+ },
1275
+ {
1276
+ "type": "text",
1277
+ "text": "Mike Schuster and Kuldip K Paliwal. Bidirectional recurrent neural networks. IEEE Transactions on Signal Processing, 1997. ",
1278
+ "bbox": [
1279
+ 171,
1280
+ 354,
1281
+ 825,
1282
+ 383
1283
+ ],
1284
+ "page_idx": 10
1285
+ },
1286
+ {
1287
+ "type": "text",
1288
+ "text": "Stanislau Semeniuta, Aliaksei Severyn, and Erhardt Barth. Recurrent dropout without memory loss. 2016. ",
1289
+ "bbox": [
1290
+ 171,
1291
+ 391,
1292
+ 823,
1293
+ 421
1294
+ ],
1295
+ "page_idx": 10
1296
+ },
1297
+ {
1298
+ "type": "text",
1299
+ "text": "Iulian Vlad Serban, Alessandro Sordoni, Ryan Lowe, Laurent Charlin, Joelle Pineau, Aaron C Courville, and Yoshua Bengio. A hierarchical latent variable encoder-decoder model for generating dialogues. 2017. ",
1300
+ "bbox": [
1301
+ 176,
1302
+ 429,
1303
+ 823,
1304
+ 472
1305
+ ],
1306
+ "page_idx": 10
1307
+ },
1308
+ {
1309
+ "type": "text",
1310
+ "text": "David Silver, Hado van Hasselt, Matteo Hessel, Tom Schaul, Arthur Guez, Tim Harley, Gabriel Dulac-Arnold, David Reichert, Neil Rabinowitz, Andre Barreto, et al. The predictron: End-toend learning and planning. arXiv preprint arXiv:1612.08810, 2016. ",
1311
+ "bbox": [
1312
+ 178,
1313
+ 479,
1314
+ 820,
1315
+ 523
1316
+ ],
1317
+ "page_idx": 10
1318
+ },
1319
+ {
1320
+ "type": "text",
1321
+ "text": "Nitish Srivastava, Geoffrey E Hinton, Alex Krizhevsky, Ilya Sutskever, and Ruslan Salakhutdinov. Dropout: a simple way to prevent neural networks from overfitting. JMLR, 2014. ",
1322
+ "bbox": [
1323
+ 178,
1324
+ 531,
1325
+ 820,
1326
+ 560
1327
+ ],
1328
+ "page_idx": 10
1329
+ },
1330
+ {
1331
+ "type": "text",
1332
+ "text": "Ilya Sutskever, Oriol Vinyals, and Quoc V Le. Sequence to sequence learning with neural networks. In NIPS, 2014. ",
1333
+ "bbox": [
1334
+ 174,
1335
+ 569,
1336
+ 820,
1337
+ 598
1338
+ ],
1339
+ "page_idx": 10
1340
+ },
1341
+ {
1342
+ "type": "text",
1343
+ "text": "Aviv Tamar, Yi Wu, Garrett Thomas, Sergey Levine, and Pieter Abbeel. Value iteration networks. In NIPS, 2016. ",
1344
+ "bbox": [
1345
+ 174,
1346
+ 606,
1347
+ 820,
1348
+ 636
1349
+ ],
1350
+ "page_idx": 10
1351
+ },
1352
+ {
1353
+ "type": "text",
1354
+ "text": "Theano Development Team. Theano: A Python framework for fast computation of mathematical expressions. 2016. ",
1355
+ "bbox": [
1356
+ 173,
1357
+ 643,
1358
+ 823,
1359
+ 672
1360
+ ],
1361
+ "page_idx": 10
1362
+ },
1363
+ {
1364
+ "type": "text",
1365
+ "text": "Benigno Uria, Marc-Alexandre Cotˆ e, Karol Gregor, Iain Murray, and Hugo Larochelle. Neural ´ autoregressive distribution estimation. JMLR, 17(205), 2016. ",
1366
+ "bbox": [
1367
+ 171,
1368
+ 681,
1369
+ 823,
1370
+ 710
1371
+ ],
1372
+ "page_idx": 10
1373
+ },
1374
+ {
1375
+ "type": "text",
1376
+ "text": "Bart van Merrienboer, Dzmitry Bahdanau, Vincent Dumoulin, Dmitriy Serdyuk, David Warde-¨ Farley, Jan Chorowski, and Yoshua Bengio. Blocks and fuel: Frameworks for deep learning. 2015. ",
1377
+ "bbox": [
1378
+ 174,
1379
+ 718,
1380
+ 823,
1381
+ 761
1382
+ ],
1383
+ "page_idx": 10
1384
+ },
1385
+ {
1386
+ "type": "text",
1387
+ "text": "Oriol Vinyals, Alexander Toshev, Samy Bengio, and Dumitru Erhan. Show and tell: A neural image caption generator. In CVPR, 2015. ",
1388
+ "bbox": [
1389
+ 173,
1390
+ 768,
1391
+ 823,
1392
+ 799
1393
+ ],
1394
+ "page_idx": 10
1395
+ },
1396
+ {
1397
+ "type": "text",
1398
+ "text": "Cheng Wang, Haojin Yang, Christian Bartz, and Christoph Meinel. Image captioning with deep bidirectional LSTMs. In Proceedings of the 2016 ACM on Multimedia Conference. ACM, 2016. ",
1399
+ "bbox": [
1400
+ 173,
1401
+ 806,
1402
+ 821,
1403
+ 837
1404
+ ],
1405
+ "page_idx": 10
1406
+ },
1407
+ {
1408
+ "type": "text",
1409
+ "text": "Kelvin Xu, Jimmy Ba, Ryan Kiros, Kyunghyun Cho, Aaron Courville, Ruslan Salakhudinov, Rich Zemel, and Yoshua Bengio. Show, attend and tell: Neural image caption generation with visual attention. In ICML, 2015. ",
1410
+ "bbox": [
1411
+ 174,
1412
+ 843,
1413
+ 823,
1414
+ 886
1415
+ ],
1416
+ "page_idx": 10
1417
+ },
1418
+ {
1419
+ "type": "text",
1420
+ "text": "Ting Yao, Yingwei Pan, Yehao Li, Zhaofan Qiu, and Tao Mei. Boosting image captioning with attributes. arXiv preprint arXiv:1611.01646, 2016. ",
1421
+ "bbox": [
1422
+ 173,
1423
+ 895,
1424
+ 821,
1425
+ 924
1426
+ ],
1427
+ "page_idx": 10
1428
+ },
1429
+ {
1430
+ "type": "text",
1431
+ "text": "Quanzeng You, Hailin Jin, Zhaowen Wang, Chen Fang, and Jiebo Luo. Image captioning with semantic attention. In CVPR, 2016. ",
1432
+ "bbox": [
1433
+ 174,
1434
+ 103,
1435
+ 825,
1436
+ 132
1437
+ ],
1438
+ "page_idx": 11
1439
+ },
1440
+ {
1441
+ "type": "text",
1442
+ "text": "Wojciech Zaremba, Ilya Sutskever, and Oriol Vinyals. Recurrent neural network regularization. 2014. ",
1443
+ "bbox": [
1444
+ 174,
1445
+ 140,
1446
+ 821,
1447
+ 170
1448
+ ],
1449
+ "page_idx": 11
1450
+ },
1451
+ {
1452
+ "type": "text",
1453
+ "text": "Xiangwen Zhang, Jinsong Su, Yue Qin, Yang Liu, Rongrong Ji, and Hongji Wang. Asynchronous bidirectional decoding for neural machine translation. arXiv preprint arXiv:1801.05122, 2018. ",
1454
+ "bbox": [
1455
+ 174,
1456
+ 179,
1457
+ 821,
1458
+ 208
1459
+ ],
1460
+ "page_idx": 11
1461
+ }
1462
+ ]
parse/train/BydLzGb0Z/BydLzGb0Z_middle.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/BydLzGb0Z/BydLzGb0Z_model.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/S1TgE7WR-/S1TgE7WR-.md ADDED
@@ -0,0 +1,588 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # COVARIANT COMPOSITIONAL NETWORKS FOR LEARNING GRAPHS
2
+
3
+ Risi Kondor, Truong Son Hy, Horace Pan & Brandon M. Anderson
4
+
5
+ Department of Computer Science
6
+ The University of Chicago
7
+ Chicago, IL - 60637
8
+ {risi,hytruongson,hopan,brandona}@cs.uchicago.edu
9
+
10
+ Shubhendu Trivedi Toyota Technological Institute Chicago, IL - 60637 shubhendu@ttic.edu
11
+
12
+ # ABSTRACT
13
+
14
+ Most existing neural networks for learning graphs address permutation invariance by conceiving of the network as a message passing scheme, where each node sums the feature vectors coming from its neighbors. We argue that this imposes a limitation on their representation power, and instead propose a new general architecture for representing objects consisting of a hierarchy of parts, which we call covariant compositional networks (CCNs). Here, covariance means that the activation of each neuron must transform in a specific way under permutations, similarly to steerability in CNNs. We achieve covariance by making each activation transform according to a tensor representation of the permutation group, and derive the corresponding tensor aggregation rules that each neuron must implement. Experiments show that CCNs can outperform competing methods on standard graph learning benchmarks.
15
+
16
+ # 1 INTRODUCTION
17
+
18
+ Learning on graphs has a long history in the kernels literature, including approaches based on random walks (Gartner, 2002; Borgwardt & Kriegel, 2005; Feragen et al., 2013), counting subgraphs ¨ (Shervashidze et al., 2009), spectral ideas (Vishwanathan et al., 2010), label propagation schemes with hashing (Shervashidze et al., 2011; Neumann et al., 2016), and even algebraic ideas (Kondor & Borgwardt, 2008). Many of these papers address moderate size problems in chemo- and bioinformatics, and the way they represent graphs is essentially fixed.
19
+
20
+ Recently, with the advent of deep learning and much larger datasets, a sequence of neural network based approaches have appeared to address the same problem, starting with (Scarselli et al., 2009). In contrast to the kernels framework, neural networks effectively integrate the classification or regression problem at hand with learning the graph representation itself, in a single, end-to-end system. In the last few years, there has been a veritable explosion in research activity in this area. Some of the proposed graph learning architectures (Duvenaud et al., 2015; Kearnes et al., 2016; Niepert et al., 2016) directly seek inspiration from the type of classical CNNs that are used for image recognition (LeCun et al., 1998; Krizhevsky et al., 2012). These methods involve first fixing a vertex ordering, then moving a filter across vertices while doing some computation as a function of the local neighborhood to generate a representation. This process is then repeated multiple times like in classical CNNs to build a deep graph representation. Other notable works on graph neural networks include (Li et al., 2016; Schutt et al., 2017; Battaglia et al., 2016; Kipf & Welling, 2017). ¨ Very recently, (Gilmer et al., 2017) showed that many of these approaches can be seen to be specific instances of a general message passing formalism, and coined the term message passing neural networks (MPNNs) to refer to them collectively.
21
+
22
+ While MPNNs have been very successful in applications and are an active field of research, they differ from classical CNNs in a fundamental way: the internal feature representations in CNNs are equivariant to such transformations of the inputs as translation and rotations (Cohen & Welling, 2016; 2017), the internal representations in MPNNs are fully invariant. This is a direct result of the fact that MPNNs deal with the permutation invariance issue in graphs simply by summing the messages coming from each neighbor. In this paper we argue that this is a serious limitation that restricts the representation power of MPNNs.
23
+
24
+ MPNNs are ultimately compositional (part-based) models, that build up the representation of the graph from the representations of a hierarchy of subgraphs. To address the covariance issue, we study the covariance behavior of such networks in general, introducing a new general class of neural network architectures, which we call compositional networks (comp-nets). One advantage of this generalization is that instead of focusing attention on the mechanics of how information propagates from node to node, it emphasizes the connection to convolutional networks, in particular, it shows that what is missing from MPNNs is essentially the analog of steerability.
25
+
26
+ Steerability implies that the activations (feature vectors) at a given neuron must transform according to a specific representation (in the algebraic sense) of the symmetry group of its receptive field, in our case, the group of permutations, $\mathbb { S } _ { m }$ . In this paper we only consider the defining representation and its tensor products, leading to first, second, third etc. order tensor activations. We derive the general form of covariant tensor propagation in comp-nets, and find that each “channel” in the network corresponds to a specific way of contracting a higher order tensor to a lower order one. Note that here by tensor activations we mean not just that each activation is expressed as a multidimensional array of numbers (as the word is usually used in the neural networks literature), but also that it transforms in a specific way under permutations, which is a more stringent criterion. The parameters of our covariant comp-nets are the entries of the mixing matrix that prescribe how these channels communicate with each other at each node. Our experiments show that this new architecture can beat scalar message passing neural networks on several standard datasets.
27
+
28
+ # 2 LEARNING GRAPHS
29
+
30
+ Graph learning encompasses a broad range of problems where the inputs are graphs and the outputs are class labels (classification), real valued quantities (regression) or more general, possibly combinatorial, objects. In the standard supervised learning setting this means that the training set consists of $m$ input/output pairs $\left\{ { ( G _ { 1 } , y _ { 1 } ) , ( G _ { 2 } , y _ { 2 } ) , \dots , ( G _ { m } , y _ { m } ) } \right\}$ , where each $G _ { i }$ is a graph and $y _ { i }$ is the corresponding label, and the goal is to learn a function $h \colon G \to y$ that will successfully predict the labels of further graphs that were not in the training set.
31
+
32
+ By way of fixing our notation, in the following we assume the each graph $G$ is a pair $( V , E )$ , where $V$ is the vertex set of $G$ and $E \subseteq V \times V$ is its edge set. For simplicity, we assume that $V = \{ 1 , 2 , \dots , n \}$ . We also assume that $G$ has no self-loops $( ( i , i ) \notin E$ for any $i \in V .$ ) and that $G$ is symmetric, i.e., $( i , j ) \in E \Rightarrow ( j , i ) \in E ^ { 1 }$ . We will, however, allow each edge $( i , j )$ to have a corresponding weight $w _ { i , j }$ , and each vertex $i$ to have a corresponding feature vector (vertex label) $l _ { i } \in \mathbb { R } ^ { d }$ . The latter, in particular, is important in many scientific applications, where $l _ { i }$ might encode, for example, what type of atom occupies a particular site in a molecule, or the identity of a protein in a biochemical interaction network. All the topological information about $G$ can be summarized in an adjacency matrix $A \in \mathbb { R } ^ { n \times n }$ , where $A _ { i , j } = w _ { i , j }$ if $i$ and $j$ are connected by an edge, and otherwise $A _ { i , j } = 0$ . When dealing with labeled graphs, we also have to provide $\left( l _ { 1 } , \ldots , l _ { n } \right)$ to fully specify $G$ .
33
+
34
+ One of the most fascinating aspects of graphs, but also what makes graph learning challenging, is that they involve structure at multiple different scales. In the case when $G$ is the graph of a protein, for example, an ideal graph learning algorithm would represent $G$ in a manner that simultaneously captures structure at the level of individual atoms, functional groups, interactions between functional groups, subunits of the protein, and the protein’s overall shape.
35
+
36
+ The other major requirement for graph learning algorithms relates to the fact that the usual ways to store and present graphs to learning algorithms have a critical spurious symmetry: If we were to permute the vertices of $G$ by any permutation $\sigma \colon \{ 1 , 2 , \ldots , n \} \to \{ 1 , 2 , \ldots , n \}$ (in other words, rename vertex 1 as $\sigma ( 1 )$ , vertex 2 as $\sigma ( 2 )$ , etc.), then the adjacency matrix would change to
37
+
38
+ ![](images/b079f02a32e4e9a1eb95fdd65106bcb063f8214b5aa9215a677ac5d9f5e43e96.jpg)
39
+ Figure 1: (a) A small graph $G$ with 6 vertices and its adjacency matrix. (b) An alternative form $G ^ { \prime }$ of the same graph, derived from $G$ by renumbering the vertices by a permutation $\sigma \colon \{ 1 , 2 , \ldots , 6 \} \mapsto$ $\{ 1 , 2 , \ldots , 6 \}$ . The adjacency matrices of $G$ and $G ^ { \prime }$ are different, but topologically they represent the same graph. Therefore, we expect the feature map $\phi$ to satisfy $\phi ( G ) \bar { = } \phi ( \bar { G } ^ { \prime } )$ .
40
+
41
+ $$
42
+ A _ { i , j } ^ { \prime } = A _ { \sigma ^ { - 1 } ( i ) , \sigma ^ { - 1 } ( j ) } ,
43
+ $$
44
+
45
+ and simultaneously the vertex labels would change to $\left( l _ { 1 } ^ { \prime } , \ldots , l _ { n } ^ { \prime } \right)$ , where ${ l ^ { \prime } } _ { i } = l _ { \sigma ^ { - 1 } ( i ) }$ . However, $G ^ { \prime } = ( A ^ { \prime } , l _ { 1 } ^ { \prime } , \ldots , l _ { n } ^ { \prime } )$ would still represent exactly the same graph as $G = ( A , l _ { 1 } , \ldots , l _ { n } )$ . In particular, (a) in training, whether $G$ or $G ^ { \prime }$ is presented to the algorithm must not make a difference to the final hypothesis $h$ that it returns, (b) $h$ itself must satisfy $\bar { h } ( G ) = h ( G ^ { \prime } )$ for any labeled graph and its permuted variant.
46
+
47
+ Most learning algorithms for combinatorial objects hinge on some sort of fixed or learned internal representation of data, called the feature map, which, in our case we denote $\phi ( G )$ . The set of all $n !$ possible permutations of $\{ 1 , 2 , \ldots , n \}$ forms a group called the symmetric group of order $n$ , denoted $\mathbb { S } _ { n }$ . The permutation invariance criterion can then be formulated as follows (Figure 1).
48
+
49
+ Definition 1. Let $\mathcal { A }$ be a graph learning algorithm that uses a feature map $G \mapsto \phi ( G )$ . We say that the feature map $\phi$ (and consequently the algorithm $\mathcal { A }$ ) is permutation invariant $i f ,$ given any $n \in \mathbb N$ , any $n$ vertex labeled graph $G = ( A , l _ { 1 } , \dots , l _ { n } ) $ , and any permutation $\sigma \in \mathbb { S } _ { n }$ , letting $G ^ { \prime } = ( A ^ { \prime } , l _ { 1 } ^ { \prime } , \ldots , l _ { n } ^ { \prime } )$ , where $A _ { i , j } ^ { \prime } = { A _ { \sigma } } - 1 ( i ) , \sigma ^ { - 1 } ( j )$ and $l _ { i } ^ { \prime } = l _ { \sigma ^ { - 1 } ( i ) }$ , we have that $\phi ( G ) = \phi ( G ^ { \prime } )$ .
50
+
51
+ Capturing multiscale structure and respecting permutation invariance are the two the key constraints around which most of the graph learning literature revolves. In kernel based learning, for example, invariant kernels have been constructed by counting random walks (Gartner, 2002), matching ¨ eigenvalues of the graph Laplacian (Vishwanathan et al., 2010) and using algebraic ideas (Kondor & Borgwardt, 2008).
52
+
53
+ # 3 COMPOSITIONAL NETWORKS
54
+
55
+ Many recent graph learning papers, whether or not they make this explicit, employ a compositional approach to modeling graphs, building up the representation of $G$ from representations of subgraphs. At a conceptual level, this is similar to part-based modeling, which has a long history in machine learning (Fischler & Elschlager, 1973; Ohta et al., 1978; Tu et al., 2005; Felzenszwalb & Huttenlocher, 2005; Zhu & Mumford, 2006; Felzenszwalb et al., 2010). In this section we introduce a general, abstract architecture called compositional networks (comp-nets) for representing complex objects as a combination of their parts, and show that several exisiting graph neural networks can be seen as special cases of this framework.
56
+
57
+ Definition 2. Let $\mathcal { G }$ be a compound object with n elementary parts (atoms) $\mathcal { E } = \{ e _ { 1 } , \ldots , e _ { n } \}$ . A composition scheme for $\mathcal { G }$ is a directed acyclic graph (DAG) $\mathcal { M }$ in which each node ${ \mathfrak { n } } _ { i }$ is associated with some subset $\mathcal { P } _ { i }$ of $\mathcal { E }$ (these subsets are called the parts of $\mathcal { G }$ ) in such a way that
58
+
59
+ 1. If ${ \mathfrak { n } } _ { i }$ is a leaf node, then $\mathcal { P } _ { i }$ contains a single atom ${ e _ { \xi ( i ) } } ^ { 2 }$ .
60
+ 2. $\mathcal { M }$ has a unique root node ${ \mathfrak { n } } _ { r }$ , which corresponds to the entire set $\{ e _ { 1 } , \ldots , e _ { n } \}$ .
61
+ 3. For any two nodes ${ \mathfrak { n } } _ { i }$ and ${ \mathfrak { n } } _ { j }$ , $i f { \mathfrak { n } } _ { i }$ is a descendant of ${ \mathfrak { n } } _ { j }$ , then $\mathcal { P } _ { i } \subset \mathcal { P } _ { j }$ .
62
+
63
+ We define a compositional network as a composition scheme in which each node ${ \mathfrak { n } } _ { i }$ also carries a feature vector $f _ { i }$ that provides a representation of the corresponding part (Figure 2). When we want to emphasize the connection to more classical neural architectures, we will refer to ${ \mathfrak { n } } _ { i }$ as the $i ^ { \because }$ ’th neuron, $\mathcal { P } _ { i }$ as its receptive field3, and $f _ { i }$ as its activation.
64
+
65
+ ![](images/d5a99f82a0d8332cec0992d2ec5b746ec2e02c9612f36eb9e4be87cd3bc7392c.jpg)
66
+ Figure 2: (a) A composition scheme for an object $\mathcal { G }$ is a DAG in which the leaves correspond to atoms, the internal nodes correspond to sets of atoms, and the root corresponds to the entire object. (b) A compositional network is a composition scheme in which each node ${ \mathfrak { n } } _ { i }$ also carries a feature vector $f _ { i }$ . The feature vector at ${ \mathfrak { n } } _ { i }$ is computed from the feature vectors of the children of ${ \mathfrak { n } } _ { i }$ .
67
+
68
+ ![](images/5eb2ddf7a5ac4bb48bfcbaa0d27baa486f0ad9c00099b449f5edd57c0f1427c9.jpg)
69
+ Figure 3: A minimal requirement for composition schemes is that they be invariant to permutation, i.e. that if the numbering of the atoms is changed by a permutation $\sigma$ , then we must get an isomorphic DAG. Any node in the new DAG that corresponds to $\{ e _ { i _ { 1 } } ^ { \prime } , \ldots , e _ { i _ { k } } ^ { \prime } \}$ must have a corrresponding node in the old DAG corresponding to $\{ e _ { \sigma ^ { - 1 } \left( i _ { 1 } \right) } , \ldots , e _ { \sigma ^ { - 1 } \left( i _ { k } \right) } \}$ .
70
+
71
+ Definition 3. Let $\mathcal { G }$ be a compound object in which each atom $e _ { i }$ carries a label $l _ { i }$ , and $\textit { \textbf { M } a }$ composition scheme for $\mathcal { G }$ . The corresponding compositional network $\mathcal { N }$ is a $D A G$ with the same structure as $\mathcal { M }$ in which each node ${ \mathfrak { n } } _ { i }$ also has an associated feature vector $f _ { i }$ such that
72
+
73
+ 1. If ${ \mathfrak { n } } _ { i }$ is a leaf node, then $f _ { i } = l _ { \xi ( i ) }$
74
+
75
+ 2. If $\mathsf { \Pi } _ { \mathfrak { n } _ { i } }$ is a non-leaf node, and its children are $\mathfrak { n } _ { c _ { 1 } } , \ldots , \mathfrak { n } _ { c _ { k } }$ , then $f _ { i } = \Phi ( f _ { c _ { 1 } } , f _ { c _ { 2 } } , \dots , f _ { c _ { k } } )$ for some aggregation function $\Phi$ . (Note: in general, $\Phi$ can also depend on the relationships between the subparts, but for now, to keep the discussion as simple as possible, we ignore this possibility.)
76
+
77
+ The representation $\phi ( \mathcal G )$ afforded by the comp-net is given by the feature vector $f _ { r }$ of the root.
78
+
79
+ Note that while, for the sake of concreteness, we call the $f _ { i }$ ’s “feature vectors”, there is no reason a priori why they need to be vectors rather than some other type of mathematical object. In fact, in the second half of the paper we make a point of treating the $f _ { i }$ ’s as tensors, because that is what will make it the easiest to describe the specific way that they transform with respect to permutations.
80
+
81
+ In compositional networks for graphs, the atoms will usually be the vertices, and the $\mathcal { P } _ { i }$ parts will correspond to clusters of nodes or neighborhoods of given radii. Comp-nets are particularly attractive in this domain because they can combine information from the graph at different scales. The comp-net formalism also suggests a natural way to satisfy the permutation invariance criterion of Definition 1.
82
+
83
+ Definition 4. Let $\mathcal { M }$ be the composition scheme of an object $\mathcal { G }$ with n atoms and $\mathcal { M } ^ { \prime }$ the composition scheme of another object that is equivalent in structure to $\mathcal { G }$ , except that its atoms have been permuted by some permutation $\sigma \in \mathbb { S } _ { n }$ $( e _ { i } ^ { \prime } = e _ { \sigma ^ { - 1 } ( i ) }$ and $\ell _ { i } ^ { \prime } = \ell _ { \sigma ^ { - 1 } ( i ) } )$ . We say that $\mathcal { M }$ (more precisely, the algorithm generating $\mathcal { M }$ ) is permutation invariant if there is a bijection $\psi \colon { \mathcal { M } } \to { \mathcal { M } } ^ { \prime }$ taking each ${ \mathfrak { n } } _ { a } \in { \mathcal { M } }$ to some $\mathfrak { n } _ { b } ^ { \prime } \in \mathcal { M } ^ { \prime }$ such that if $\mathcal { P } _ { a } = \{ e _ { i _ { 1 } } , . . . , e _ { i _ { k } } \}$ , then $\mathcal { P } _ { b } ^ { \prime } = \{ e _ { \sigma ( i _ { 1 } ) } ^ { \prime } , \cdot \cdot \cdot , e _ { \sigma ( i _ { k } ) } ^ { \prime } \}$ .
84
+
85
+ Proposition 1. Let $\phi ( \mathcal G )$ be the output of a comp-net based on a composition scheme $\mathcal { M }$ . Assume 1. $\mathcal { M }$ is permutation invariant in the sense of Definition 4.
86
+
87
+ 2. The aggregation function $\Phi ( f _ { c _ { 1 } } , f _ { c _ { 2 } } , \dots , { \bar { f } } _ { c _ { k } } )$ used to compute the feature vector of each node from the feature vectors of its children is invariant to the permutations of its arguments.
88
+
89
+ Then the overall representation $\phi ( \mathcal G )$ is invariant to permutations of the atoms. In particular, if $\mathcal { G }$ is a graph and the atoms are its vertices, then $\phi$ is a permutation invariant graph representation.
90
+
91
+ # 3.1 MESSAGE PASSING NEURAL NETWORKS AS A SPECIAL CASE OF COMP-NETS
92
+
93
+ Graph learning is not the only domain where invariance and multiscale structure are important: the most commonly cited reasons for the success of convolutional neural networks (CNNs) in image tasks is their ability to address exactly these two criteria in the vision context. Furthermore, each neuron ${ \mathfrak { n } } _ { i }$ in a CNN aggregates information from a small set of neurons from the previous layer, therefore its receptive field, corresponding to $\mathcal { P } _ { i }$ , is the union of the receptive fields of its “children”, so we have a hierarchical structure very similar to that described in the previous section. In this sense, CNNs are a specific kind of compositional network, where the atoms are pixels. This connection has inspired several authors to frame graph learning as a generalization of convolutional nets to the graph domain (Bruna et al., 2014; Henaff et al., 2015; Duvenaud et al., 2015; Defferrard et al., 2016; Kipf & Welling, 2017). While in mathematics convolution has a fairly specific meaning that is side-stepped by this analogy, the CNN analogy does suggest that a natural way to define the $\Phi$ aggregation functions is to let $\mathbf { \bar { \Phi } } ( f _ { c _ { 1 } } , f _ { c _ { 2 } } , \ldots , f _ { c _ { k } } )$ be a linear function of $f _ { c _ { 1 } } , f _ { c _ { 2 } } , \ldots , f _ { c _ { k } }$ followed by a pointwise nonlinearity, such as a ReLU operation.
94
+
95
+ To define a comp-net for graphs we also need to specify the composition scheme $\mathcal { M }$ . Many algorithms define $\mathcal { M }$ in layers, where each layer (except the last) has one node for each vertex of $G$ :
96
+
97
+ $\mathcal { M } 1$ . In layer $\ell = 0$ each node ${ \mathfrak { n } } _ { i } ^ { 0 }$ represents the single vertex $\mathcal { P } _ { i } ^ { 0 } = \{ i \}$ .
98
+
99
+ $\mathcal { M } 2$ . In layers $\ell = 1 , 2 , \ldots , L$ , node ${ \mathfrak { n } } _ { i } ^ { \ell }$ is connected to all nodes from the previous level that are neighbors of $i$ in $G$ , i.e., the children of ${ \mathfrak { n } } _ { i } ^ { \ell }$ are
100
+
101
+ $$
102
+ \mathrm { c h } ( \mathfrak { n } _ { i } ^ { \ell } ) = \\\\mathfrak { n } _ { j } ^ { \ell - 1 } \ | \ j \in \mathcal { N } ( i ) \} ,
103
+ $$
104
+
105
+ where $\mathcal { N } ( i )$ denotes the set of neighbors of $i$ in $G$ . Therefore, $\begin{array} { r } { \mathcal { P } _ { i } ^ { \ell } = \bigcup _ { j \in \mathcal { N } ( i ) } \mathcal { P } _ { j } ^ { \ell - 1 } } \end{array}$ .
106
+
107
+ $\mathcal { M } 3$ . In layer $L { + 1 }$ we have a single node ${ \mathfrak { n } } _ { r }$ that represents the entire graph and collects information from all nodes at level $L$ .
108
+
109
+ Since this construction only depends on topological information about $G$ , the resulting composition scheme is guaranteed to be permutation invariant in the sense of Definition 4.
110
+
111
+ A further important consequence of this way of defining $\mathcal { M }$ is that the resulting comp-net can be equivalently interpreted as label propagation algorithm, where in each round $\ell = 1 , 2 , \dots , L$ , each vertex aggregates information from its neighbors and then updates its own label.
112
+
113
+ <table><tr><td>Algorithm1 The label propagation algorithm corresponding to M1-M3</td></tr><tr><td>foreachvertex i</td></tr><tr><td>f←l</td></tr><tr><td>forl=1 to L</td></tr><tr><td>for each vertexi f←Φ(fe-1 fl-1) where N(i)={𝑖1,...,i}</td></tr></table>
114
+
115
+ Many authors choose to describe graph neural networks exclusively in terms of label propagation, without mentioning the compositional aspect of the model. Gilmer et al. (2017) call this general approach message passing neural networks, and point out that a range of different graph learning architectures are special cases of it. More broadly, the classic Weisfeiler–Lehman test of isomorphism also follows the same logic (Weisfeiler & Lehman, 1968; Read & Corneil, 1977; Cai et al., 1992), and so does the related Weisfeiler–Lehman kernel, arguably the most successful kernel-based approach to graph learning (Shervashidze et al., 2011). Note also that in label propagation or message passing algorithms there is a clear notion of the source domain of vertex $i$ at round $\ell$ , as the set of vertices that can influence $f _ { i } ^ { \ell }$ , and this corresponds exactly to the receptive field $\mathcal { P } _ { i } ^ { \ell }$ of “neuron” ${ \mathfrak { n } } _ { i } ^ { \ell }$ in the comp-net picture.
116
+
117
+ The following proposition is immediate from the form of Algorithm 1 and reassures us that message passing neural networks, as special cases of comp-nets, do indeed produce permutation invariant representations of graphs.
118
+
119
+ Proposition 2. Any label propagation scheme in which the aggregation function $\Phi$ is invariant to the permutations of its arguments is invariant to permutations in the sense of Definition $^ { l }$ .
120
+
121
+ In the next section we argue that invariant message passing networks are limited in their representation power, however, and describe a generalization via comp-nets that overcomes some of these limitations.
122
+
123
+ # 4 COVARIANT COMPOSITIONAL NETWORKS
124
+
125
+ One of the messages of the present paper is that invariant message passing algorithms, of the form described in the previous section, are not the most general possible compositional models for producing permutation invariant representations of graphs (or of compound objects, in general).
126
+
127
+ Once again, an analogy with image recognition is helpful. Classical CNNs face two types of basic image transformations: translations and rotations. With respect to translations (barring pooling, edge effects and other complications), CNNs behave in a quasi-invariant way, in the sense that if the input image is translated by any integer amount $( t _ { x } , t _ { y } )$ , the activations in each layer $\ell = 1 , 2 , \ldots L$ translate the same way: the activation of any neuron n\`i,j is simply transferred to neuron n\`i+t1,j+t2 , i.e., $f ^ { \prime } { } _ { i + t _ { 1 } , j + t _ { 2 } } ^ { \ell } { = } f _ { i , j } ^ { \ell }$ . This is the simplest manifestation of a well studied property of CNNs called equivariance (Cohen & Welling, 2016; Worrall et al., 2017).
128
+
129
+ With respect to rotations, however, the situation is more complicated: if we rotate the input image by, e.g., 90 degrees, not only will the part of the image that fell in the receptive field of a particular neuron $\mathfrak { n } _ { i , j } ^ { \ell }$ move to the receptive field of a different neuron $\mathfrak { n } _ { j , - i } ^ { \ell }$ , but the orientation of the receptive field will also change (Figure 4). Consequently, features which were, for example, prevup by horizontal filters will now be picked up by vertical filters. Therefore, in general, $f ^ { \prime } { } _ { j , - i } ^ { \ell } \neq f _ { i , j } ^ { \ell }$ d. It can be shown that one cannot construct a CNN for images that behaves in a quasi-invariant way with respect to both translations and rotations unless every filter is directionless.
130
+
131
+ It is, however, possible to construct a CNN in which the activations transform in a predictable and reversible way, in particular, $f _ { \ j , - i } ^ { \prime \ell } = R ( f _ { i , j } ^ { \ell } )$ for some fixed invertible function $R$ . This phenomenon is called steerability, and has a significant literature in both classical signal processing (Freeman & Adelson, 1991; Simoncelli et al., 1992; Perona, 1995; Teo & Hel-Or, 1998; Manduchi et al., 1998) and the neural networks field (Cohen & Welling, 2017).
132
+
133
+ ![](images/9f571f8517fddf7beece745085bf7d286713d9e1f1954fcc58dfb54fe8ad2ba8.jpg)
134
+ Figure 4: In convolutional neural networks if thewhat used to fall in the receptive field of neuron t image is translated by some amois moved to the receptive field of $( t _ { 1 } , t _ { 2 } )$ i,j Therefore, the activations transform in the very simple way tions not only move the receptive fields around, but also perm $f _ { i + t _ { 1 } , j + t _ { 2 } } ^ { \prime \ell } = f _ { i , j } ^ { \ell }$ i+t1,j+t2 . In contrast, rota- the receptive field internally, therefore, in general, horizontal filter (blue) and a vert $f _ { j , - i } ^ { \prime \ell } \neq f _ { i , j } ^ { \ell }$ . The right hand figure shows that if the CNN has ad) then their activations are exchanged by a 90 degree rotation. In steerable CNNs, if $( i , j ) \mapsto ( i ^ { \prime } , j ^ { \prime } )$ , then $f _ { \ i ^ { \prime } , j ^ { \prime } } ^ { \prime \ell } = R ( f _ { i , j } ^ { \ell } )$ for some fixed linear function
135
+
136
+ The situation in compositional networks is similar. The comp-net and message passing architectures that we have examined so far, by virtue of the aggregation function being symmetric in its arguments, are all quasi-invariant (with respect to permutations) in the following sense.
137
+
138
+ Definition 5. Let $\mathcal { G }$ be a compound object of $n$ parts and $\mathcal { G } ^ { \prime }$ an equivalent object in which the atoms have been permuted by some permutation $\sigma$ . Let $\mathcal { N }$ be a comp-net for $\mathcal { G }$ based on an invariant composition scheme, and $\mathcal { N } ^ { \prime }$ be the corresponding network for $\mathcal { G } ^ { \prime }$ . We say that $\mathcal { N }$ is quasi-invariant if for any $\mathfrak { n } _ { i } \in \mathcal { N }$ , letting ${ \mathfrak { n } } _ { j } ^ { \prime }$ be the corresponding node in $\mathcal { N } ^ { \prime }$ , $f _ { i } = f _ { j } ^ { \prime }$ for any $\sigma \in \mathbb { S } _ { n }$
139
+
140
+ Quasi-invariance in comp-nets is equivalent to the assertion that the activation $f _ { i }$ at any given node must only depend on $\mathcal { P } _ { i } = \{ e _ { j _ { 1 } } , . . . , e _ { j _ { k } } \}$ as a set, and not on the internal ordering of the atoms $e _ { j _ { 1 } } , \dotsc , e _ { j _ { k } }$ making up the receptive field. At first sight this seems desirable, since it is exactly what we expect from the overall representation $\phi ( G )$ . On closer examination, however, we realize that this property is potentially problematic, since it means that ${ \mathfrak { n } } _ { i }$ has lost all information about which vertex in its receptive field has contributed what to the aggregate information $f _ { i }$ . In the CNN analogy, we can say that we have lost information about the orientation of the receptive field. In particular, if, further upstream, $f _ { i }$ is combined with some other feature vector $f _ { j }$ from a node with an overlapping receptive field, the aggregation process has no way of taking into account which parts of the information in $f _ { i }$ and $f _ { j }$ come from shared vertices and which parts do not (Figure 5).
141
+
142
+ The solution is to upgrade the $\mathcal { P } _ { i }$ receptive fields to be ordered sets, and explicitly establish how $f _ { i }$ co-varies with the internal ordering of the receptive fields. To emphasize that henceforth the $\mathcal { P } _ { i }$ sets are ordered, we will use parentheses rather than braces to denote their content.
143
+
144
+ Definition 6. Let $\mathcal { G } , \mathcal { G } ^ { \prime }$ , $\mathcal { N }$ and $\mathcal { N } ^ { \prime }$ be as in Definition 5. Let ${ \mathfrak { n } } _ { i }$ be any node of $\mathcal { N }$ and ${ \mathfrak { n } } _ { j }$ the corresponding node of $\mathcal { N } ^ { \prime }$ . Assume that $\mathcal { P } _ { i } = ( e _ { p _ { 1 } } , . . . , e _ { p _ { m } } )$ while $\mathcal { P } _ { j } ^ { \prime } = ( e _ { q _ { 1 } } , \dots , e _ { q _ { m } } )$ , and let $\pi \in \mathbb { S } _ { m }$ be the permutation that aligns the orderings of the two receptive fields, i.e., for which $e _ { q _ { \pi ( a ) } } = e _ { p _ { a } }$ . We say that $\mathcal { N }$ is covariant to permutations if for any $\pi$ , there is a corresponding function $R _ { \pi }$ such that $f _ { j } ^ { \prime } = R _ { \pi } ( f _ { i } )$ .
145
+
146
+ # 4.1 FIRST ORDER COVARIANT COMP-NETS
147
+
148
+ The form of covariance prescribed by Definition 6 is very general. To make it more specific, in line with the classical literature on steerable representations, we make the assumption that the $\{ f \mapsto R _ { \pi } ( f ) \} _ { \pi \in \mathbb { S } _ { m } }$ maps are linear, and by abuse of notation, from now on simply treat them as matrices (with $\stackrel { \triangledown } { R _ { \pi } } ( f ) \stackrel { - } { = } R _ { \pi } f ;$ ). The linearity assumption automatically implies that $\{ R _ { \pi } \} _ { \pi \in \mathbb { S } _ { m } }$ is a representation of $\mathbb { S } _ { m }$ in the group theoretic sense of the word (for the definition of group representations, see the Appendix)4.
149
+
150
+ Proposition 3. If for any $\pi \in \mathbb { S } _ { m } ,$ , the $f \mapsto R _ { \pi } ( f )$ map appearing in Definition $6$ is linear, then the corresponding $\{ R _ { \pi } \} _ { \pi \in \mathbb { S } _ { m } }$ matrices form a representation of $\mathbb { S } _ { m }$ .
151
+
152
+ ![](images/43063f92f2da83a2f4849e94038eb4a3b1dcf539320d5b4ea45ff4dd16bd3e03.jpg)
153
+ Figure 5: Top left: At level $\ell = 1 \ \mathfrak { n } _ { 3 }$ aggregates information from $\{ \mathfrak { n } _ { 4 } , \mathfrak { n } _ { 5 } \}$ and ${ \mathfrak { n } } _ { 2 }$ aggregates information $\{ \mathfrak { n } _ { 5 } , \mathfrak { n } _ { 6 } \}$ . At $\ell = 2$ , ${ \mathfrak { n } } _ { 1 }$ collects this summary information from ${ \mathfrak { n } } _ { 3 }$ and ${ \mathfrak { n } } _ { 2 }$ . Bottom left: This graph is not isomorphic to the top one, but the activations of $\mathfrak { n } _ { 3 }$ and ${ \mathfrak { n } } _ { 2 }$ at $\ell = 1$ will be identical. Therefore, at $\ell = 2$ , ${ \mathfrak { n } } _ { 1 }$ will get the same inputs from its neighbors, irrespective of whether or not ${ \mathfrak { n } } _ { 5 }$ and ${ \mathfrak { n } } _ { 7 }$ are the same node or not. Right: Aggregation at different levels. For keeping the figure legible only the neighborhood around one node in higher levels is marked.
154
+
155
+ The representation theory of symmetric groups is a rich subject that goes beyond the scope of the present paper (Sagan, 2001). However, there is one particular representation of $\mathbb { S } _ { m }$ that is likely familiar even to non-algebraists, the so-called defining representation, given by the $P _ { \pi } \in \mathbb { R } ^ { n \times \bar { n } }$ permutation matrices
156
+
157
+ $$
158
+ [ P _ { \pi } ] _ { i , j } = { \left\{ \begin{array} { l l } { 1 } & { { \mathrm { i f } } \ \pi ( j ) = i } \\ { 0 } & { { \mathrm { o t h e r w i s e . } } } \end{array} \right. }
159
+ $$
160
+
161
+ It is easy to verify that $P _ { \pi _ { 2 } \pi _ { 1 } } = P _ { \pi _ { 2 } } P _ { \pi _ { 1 } }$ for any $\pi _ { 1 } , \pi _ { 2 } \in \mathbb { S } _ { m }$ , so $\{ P _ { \pi } \} _ { \pi \in \mathbb { S } _ { m } }$ is indeed a representation of $\mathbb { S } _ { m }$ . If the transformation rules of the $f _ { i }$ activations in a given comp-net are dictated by this representation, then each $f _ { i }$ must necessarily be a $| \mathcal { P } _ { i } |$ dimensional vector, and intuitively each component of $f _ { i }$ carries information related to one specific atom in the receptive field, or the interaction of that specific atom with all the others. We call this case first order permutation covariance.
162
+
163
+ Definition 7. We say that ${ \mathfrak { n } } _ { i }$ is a first order covariant node in a comp-net if under the permutation of its receptive field $\mathcal { P } _ { i }$ by any $\pi \in \mathbb { S } _ { | P _ { i } | }$ , its activation trasforms as $f _ { i } \mapsto P _ { \pi } f _ { i }$ .
164
+
165
+ # 4.2 SECOND ORDER COVARIANT COMP-NETS
166
+
167
+ It is easy to verify that given any representation $( R _ { g } ) _ { g \in \mathfrak { G } }$ of a group $\mathfrak { G }$ , the matrices $( R _ { g } \otimes R _ { g } ) _ { g \in \mathfrak { G } }$ also furnish a representation of $\mathfrak { G }$ . Thus, one step up in the hierarchy from $P _ { \pi }$ –covariant comp-nets are $P _ { \pi } \otimes P _ { \pi }$ –covariant comp-nets, where the $f _ { i }$ feature vectors are now $\left| \mathcal { P } _ { i } \right| ^ { 2 }$ dimensional vectors that transform under permutations of the internal ordering by $\pi$ as $f _ { i } \mapsto ( { \stackrel { . } { P } } _ { \pi } \otimes P _ { \pi } ) f _ { i }$ .
168
+
169
+ If we reshape $f _ { i }$ into a matrix $F _ { i } \in \mathbb { R } ^ { | \mathcal { P } _ { i } | \times | \mathcal { P } _ { i } | }$ , then the action
170
+
171
+ $$
172
+ F _ { i } \mapsto P _ { \pi } F _ { i } P _ { \pi } ^ { \top }
173
+ $$
174
+
175
+ is equivalent to $P _ { \pi } \otimes P _ { \pi }$ acting on $f _ { i }$ . In the following, we will prefer this more intuitive matrix view, since it clearly expresses that feature vectors that transform this way express relationships between the different constituents of the receptive field. Note, in particular, that if we define $A \downarrow _ { \mathcal { P } _ { i } }$ as the restriction of the adjacency matrix to $\mathcal { P } _ { i }$ (i.e., if $\mathcal { P } _ { i } = ( e _ { p _ { 1 } } , \ldots , e _ { p _ { m } } )$ then $[ A \downarrow _ { \mathcal { P } _ { i } } ] _ { a , b } = A _ { p _ { a } , p _ { b } } )$ , then $A \downarrow _ { \mathcal { P } _ { i } }$ transforms exactly as $F _ { i }$ does in the equation above.
176
+
177
+ Definition 8. We say that ${ \mathfrak { n } } _ { i }$ is a second order covariant node in a comp-net if under the permutation of its receptive field $\mathcal { P } _ { i }$ by any $\pi \in \mathbb { S } _ { | \mathcal { P } _ { i } | }$ , its activation transforms as $\bar { F _ { i } } \mapsto \bar { P _ { \pi } } F _ { i } P _ { \pi } ^ { \top }$ .
178
+
179
+ # 4.3 THIRD AND HIGHER ORDER COVARIANT COMP-NETS
180
+
181
+ Taking the pattern further lets us consider third, fourth, and general, $k$ ’th order nodes in our compnet, in which the activations are $k$ ’th order tensors, transforming under permutations as
182
+
183
+ $$
184
+ F _ { i } \mapsto F _ { i } ^ { \prime } \qquad \mathrm { w h e r e } \qquad [ F _ { i } ^ { \prime } ] _ { j _ { 1 } , \dots , j _ { k } } = \sum _ { j _ { 1 } ^ { \prime } } \sum _ { j _ { 2 } ^ { \prime } } \dots \sum _ { j _ { k } ^ { \prime } } [ P _ { \pi } ] _ { j _ { 1 } , j _ { 1 } ^ { \prime } } [ P _ { \pi } ] _ { j _ { 2 } , j _ { 2 } ^ { \prime } } \dots [ P _ { \pi } ] _ { j _ { k } , j _ { k } ^ { \prime } } [ F _ { i } ] _ { j _ { 1 } ^ { \prime } , \dots , j _ { k } ^ { \prime } } ,
185
+ $$
186
+
187
+ In the more compact, so called Einstein notation5,
188
+
189
+ $$
190
+ [ F _ { i } ^ { \prime } ] _ { j _ { 1 } , \dots , j _ { k } } = [ P _ { \pi } ] _ { j _ { 1 } } { } ^ { j _ { 1 } ^ { \prime } } [ P _ { \pi } ] _ { j _ { 2 } } { } ^ { j _ { 2 } ^ { \prime } } \dots [ P _ { \pi } ] _ { j _ { k } } { } ^ { j _ { k } ^ { \prime } } [ F _ { i } ] _ { j _ { 1 } ^ { \prime } , \dots , j _ { k } ^ { \prime } } .
191
+ $$
192
+
193
+ In general, we will call any quantity which transforms according to this equation a $\mathbf { k }$ ’th order Ptensor. Note that this notion of tensors is distinct from the common usage of the term in neural networks, and more similar to how the word is used in Physics, because it not only implies that $F _ { i }$ is a quanity representable by an $m \times m \times \ldots \times m$ array of numbers, but also that $F _ { i }$ transforms in a specific way.
194
+
195
+ Since scalars, vectors and matrices can be considered as $0 ^ { \mathrm { t h } }$ , $1 ^ { \mathrm { s t } }$ and $2 ^ { \mathrm { n d } }$ order tensors, respectively, the following definition covers Definitions 5, 7 and 8 as special cases (with quasi-invariance being equivalent to zeroth order equivariance). To unify notation and terminology, regardless of the dimensionality, in the following we will always talk about feature tensors rather than feature vectors, and denote the activations with $F _ { i }$ rather than $f _ { i }$ , as we did in the first half of the paper.
196
+
197
+ Definition 9. We say that ${ \mathfrak { n } } _ { i }$ is a k’th order covariant node in a comp-net if the corresponding activation $F _ { i }$ is a $k$ ’th order $P$ –tensor, i.e., it transforms under permutations of $\mathcal { P } _ { i }$ according to $( I )$ , or the activation is a sequence of c separate $P$ –tensors $F _ { i } ^ { ( 1 ) } , \ldots , F _ { i } ^ { ( c ) }$ corresponding to c distinct channels.
198
+
199
+ # 5 TENSOR AGGREGATION RULES
200
+
201
+ The previous sections prescribed how activations must transform in comp-nets of different orders, but did not explain how this can be assured, and what it entails for the $\Phi$ aggregation functions. Fortunately, tensor arithmetic provides a compact framework for deriving the general form of these operations. Recall the four basic operations that can be applied to tensors6:
202
+
203
+ 1. The tensor product of $A \in { \mathcal { T } } ^ { k }$ with $B \in \tau ^ { p }$ yields a tensor $C = A \otimes B \in { \mathcal { T } } ^ { p + k }$ where
204
+
205
+ $$
206
+ C _ { i _ { 1 } , i _ { 2 } , . . . , i _ { k + p } } = A _ { i _ { 1 } , i _ { 2 } , . . . , i _ { k } } B _ { i _ { k + 1 } , i _ { k + 2 } , . . . , i _ { k + p } } .
207
+ $$
208
+
209
+ 2. The elementwise product of $A \in { \mathcal { T } } ^ { k }$ with $B \in \tau ^ { p }$ along dimensions $( a _ { 1 } , a _ { 2 } , \ldots , a _ { p } )$ yields a tensor $C = A \odot _ { ( a _ { 1 } , \ldots , a _ { p } ) } B \in \mathcal { T } ^ { k }$ where
210
+
211
+ $$
212
+ C _ { i _ { 1 } , i _ { 2 } , . . . , i _ { k } } = A _ { i _ { 1 } , i _ { 2 } , . . . , i _ { k } } B _ { i _ { a _ { 1 } } , i _ { a _ { 2 } } , . . . , i _ { a _ { p } } } .
213
+ $$
214
+
215
+ 3. The projection (summation) of $A \in \tau ^ { k }$ along dimensions $\{ a _ { 1 } , a _ { 2 } , \ldots , a _ { p } \}$ yields a tensor $C = A \ J _ { \psi _ { a _ { 1 } , \ldots , a _ { p } } } \in \mathcal { T } ^ { k - p }$ with
216
+
217
+ $$
218
+ C _ { i _ { 1 } , i _ { 2 } , \ldots , i _ { k } } = \sum _ { i _ { a _ { 1 } } } \sum _ { i _ { a _ { 2 } } } \ldots \sum _ { i _ { a _ { p } } } A _ { i _ { 1 } , i _ { 2 } , \ldots , i _ { k } } ,
219
+ $$
220
+
221
+ where we assume that $i _ { a _ { 1 } } , \ldots , i _ { a _ { p } }$ have been removed from amongst the indices of $C$
222
+
223
+ 4. The contraction of $A \in { \mathcal { T } } ^ { k }$ along the pair of dimensions $\{ a , b \}$ (assuming $a < b$ ) yields a $k - 2$ order tensor
224
+
225
+ $$
226
+ C _ { i _ { 1 } , i _ { 2 } , \dots , i _ { k } } = \sum _ { j } A _ { i _ { 1 } , \dots , i _ { a - 1 } , j , i _ { a + i } , \dots , i _ { b - 1 } , j , i _ { b + 1 } , \dots , k } ,
227
+ $$
228
+
229
+ where again we assume that $i _ { a }$ and $i _ { b }$ have been removed from amongst the indices of $C$ . Using Einstein notation this can be written much more compactly as
230
+
231
+ $$
232
+ C _ { i _ { 1 } , i _ { 2 } , . . . , i _ { k } } = A _ { i _ { 1 } , i _ { 2 } , . . . , i _ { k } } \delta ^ { i _ { a } , i _ { b } } ,
233
+ $$
234
+
235
+ where $\delta ^ { i _ { a } , i _ { b } }$ is the diagonal tensor with $\delta ^ { i , j } = 1$ if $i = j$ and 0 otherwise. In a somewhat unorthodox fashion, we also generalize contractions to (combinations of) larger sets of indices $\{ \{ a _ { 1 } ^ { 1 } , \dotsc , a _ { p _ { 1 } } ^ { 1 } \} , \{ a _ { 1 } ^ { 2 } , \dotsc , a _ { p _ { 2 } } ^ { 2 } \} , \dotsc , \{ a _ { 1 } ^ { q } , \dotsc , a _ { p _ { q } } ^ { q } \} \}$ as the $( k - \textstyle \sum _ { j } p _ { j } )$ order tensor
236
+
237
+ $$
238
+ C _ { \ldots } = A _ { i _ { 1 } , i _ { 2 } , \ldots , i _ { k } } \delta ^ { a _ { 1 } ^ { 1 } , \ldots , a _ { p _ { 1 } } ^ { 1 } } \delta ^ { a _ { 1 } ^ { 2 } , \ldots , a _ { p _ { 2 } } ^ { 2 } } \ldots \delta ^ { a _ { 1 } ^ { q } , \ldots , a _ { p _ { q } } ^ { q } } .
239
+ $$
240
+
241
+ Note that this subsumes projections, since it allows us to write $A \downarrow _ { { a _ { 1 } } , \ldots , { a _ { p } } }$ in the slightly unusual looking form
242
+
243
+ $$
244
+ A \downarrow _ { a _ { 1 } , \dots , a _ { p } } = A _ { i _ { 1 } , i _ { 2 } , \dots , i _ { k } } \delta ^ { i _ { a _ { 1 } } } \delta ^ { i _ { a _ { 2 } } } \dots \delta ^ { i _ { a _ { k } } } .
245
+ $$
246
+
247
+ The following proposition shows that, remarkably, all of the above operations (as well as taking linear conbinations) preserve the way that $P -$ –tensors behave under permutations and thus they can be freely “mixed and matched” within $\Phi$ .
248
+
249
+ Proposition 4. Assume that $A$ and $B$ are $k$ ’th and $p$ ’th order $P$ –tensors, respectively. Then
250
+
251
+ 1. $A \otimes B$ is a $k + p$ ’th order $P$ –tensor.
252
+ 2. $A \odot _ { ( a _ { 1 } , \ldots , a _ { p } ) } B$ k’th orde $P -$ –tensor.
253
+ 3. A↓a1,...,ap $k - p$ $P$
254
+ 4. $A _ { i _ { 1 } , i _ { 2 } , \dots , i _ { k } } \delta ^ { a _ { 1 } ^ { 1 } , \dots , a _ { p _ { 1 } } ^ { 1 } } \dots \delta ^ { a _ { 1 } ^ { q } , \dots , a _ { p _ { q } } ^ { q } }$ is a $k - \textstyle \sum _ { j } p _ { j }$ ’th order $P -$ –tensor.
255
+
256
+ In addition, if $A _ { 1 } , \ldots , A _ { u }$ are $k$ ’th order $P$ –tensors and $\alpha _ { 1 } , \ldots , \alpha _ { u }$ are scalars, then $\textstyle \sum _ { j } { \alpha _ { j } A _ { j } }$ is a $k$ ’th order $P$ –tensor.
257
+
258
+ The more challenging part of constructing the aggregation scheme for comp-nets is establishing how to relate $P -$ –tensors at different nodes. The following two propositions answer this question.
259
+
260
+ Proposition 5. Assume that node ${ \mathfrak { n } } _ { a }$ is a descendant of node ${ \mathfrak { n } } _ { b }$ in a comp-net $\mathcal { N }$ , $\begin{array} { r l } { \mathcal { P } _ { a } } & { { } = } \end{array}$ $( e _ { p _ { 1 } } , \ldots , e _ { p _ { m } } )$ and $\mathcal { P } _ { b } = ( e _ { q _ { 1 } } , . . . , e _ { q _ { m ^ { \prime } } } )$ are the corresponding ordered receptive fields (note that this implies that, as sets, $\mathcal { P } _ { a } \subseteq \mathcal { P } _ { b } ,$ ), and $\chi ^ { a b } \in \mathbb { R } ^ { m \times m ^ { \prime } }$ is an indicator matrix defined
261
+
262
+ $$
263
+ \chi _ { i , j } ^ { a b } = \{ { \begin{array} { l l } { 1 } & { i f \ q _ { j } = p _ { i } } \\ { 0 } & { o t h e r w i s e . } \end{array} }
264
+ $$
265
+
266
+ Assume that $F$ is a $k$ ’th order $P$ –tensor with respect to permutations of $( e _ { p _ { 1 } } , \ldots , e _ { p _ { m } } )$ . Then, dropping the $a { } b$ superscript for clarity,
267
+
268
+ $$
269
+ \widetilde { F } _ { i _ { 1 } , \dots , i _ { k } } = \chi _ { i _ { 1 } } { } ^ { j _ { 1 } } \chi _ { i _ { 2 } } { } ^ { j _ { 2 } } \dots \chi _ { i _ { k } } { } ^ { j _ { k } } F _ { j _ { 1 } , \dots , j _ { k } }
270
+ $$
271
+
272
+ is a k’th order $P$ –tensor with respect to permutations of $( e _ { q _ { 1 } } , \dots , e _ { q _ { m ^ { \prime } } } )$
273
+
274
+ Equation 2 tells us that when node ${ \mathfrak { n } } _ { b }$ aggregates $P -$ –tensors from its children, it first has to “promote” them to being $P$ –tensors with respect to the contents of its own receptive field by contracting along each of their dimensions with the appropriate $\chi ^ { a b }$ matrix. This is a critical element in comp-nets to guarantee covariance.
275
+
276
+ Proposition 6. Let $\mathfrak { n } _ { c _ { 1 } } , \ldots , \mathfrak { n } _ { c _ { s } }$ be the children of ${ \mathfrak { n } } _ { t }$ in a message passing type comp-net with corresponding $k$ ’th order tensor activations $F _ { c _ { 1 } } , \ldots , F _ { c _ { s } }$ . Let
277
+
278
+ $$
279
+ [ \widetilde { F } _ { c _ { u } } ] _ { i _ { 1 } , \dots , i _ { k } } = [ \chi ^ { c _ { u } t } ] _ { i _ { 1 } } ^ { ~ j _ { 1 } } [ \chi ^ { c _ { u } t } ] _ { i _ { 2 } } ^ { ~ j _ { 2 } } \dots [ \chi ^ { c _ { u } t } ] _ { i _ { k } } ^ { ~ j _ { k } } [ F _ { c _ { u } } ] _ { j _ { 1 } , \dots , j _ { k } }
280
+ $$
281
+
282
+ be the promotions of these activations to $P -$ –tensors of ${ \mathfrak { n } } _ { t : }$ Assume that $\mathcal { P } _ { t } = ( e _ { p _ { 1 } } , \ldots , e _ { p _ { m } } )$ . Now let $\overline { F }$ be a $k + 1$ ’th order object in which the $j$ ’th slice is $F _ { p _ { j } } \ i f \mathfrak { n } _ { p _ { j } }$ is one of the children of ${ \mathfrak { n } } _ { t }$ , i.e.,
283
+
284
+ $$
285
+ \overline { { F } } _ { i _ { 1 } , \dots , i _ { k } , j } = [ \widetilde { F } _ { p _ { j } } ] _ { i _ { 1 } , \dots , i _ { k } } ,
286
+ $$
287
+
288
+ and zero otherwise. Then $\overline { F }$ is a $k + 1$ ’th order $P -$ –tensor of ${ \mathfrak { n } } _ { t }$
289
+
290
+ Finally, as already mentioned, the restriction of the adjacency matrix to $\mathcal { P } _ { i }$ is a second order $P -$ tensor, which gives an easy way of explicitly adding topological information to the activation.
291
+
292
+ Proposition 7. If $F _ { i }$ is a $k$ ’th order $P$ –tensor at node ${ \mathfrak { n } } _ { i }$ , and $A \downarrow _ { \mathcal { P } _ { i } }$ is the restriction of the adjacency matrix to $\mathcal { P } _ { i }$ as defined in Section 4.2, then $F \otimes A \downarrow _ { \mathcal { P } _ { i } }$ is a $k + 2$ ’th order $P$ –tensor.
293
+
294
+ Combining all the above results, assuming that node ${ \mathfrak { n } } _ { t }$ has children $\mathfrak { n } _ { c _ { 1 } } , \ldots , \mathfrak { n } _ { c _ { s } }$ , we arrive at the following general algorithm for the aggregation rule $\Phi _ { t }$ :
295
+
296
+ 1. Collect all the $k$ ’th order activations $F _ { c _ { 1 } } , \ldots , F _ { c _ { s } }$ of the children.
297
+ 2. Promote each activation to $\widetilde { F } _ { c _ { 1 } } , \ldots , \widetilde { F } _ { c _ { s } }$ (Proposition 5).
298
+ 3. Stack $\widetilde { F } _ { c _ { 1 } } , \ldots , \widetilde { F } _ { c _ { s } }$ together into a $k + 1$ order tensor $T$ (Proposition 6).
299
+ 4. Optionally form the tensor product of $T$ with $A \downarrow _ { \mathcal { P } _ { t } }$ to get a $k { + 3 }$ order tensor $H$ (otherwise just set $H = T$ ) (Proposition 7).
300
+ 5. Contract $H$ along some number of combinations of dimensions to get $s$ separate lower order tensors $Q _ { 1 } , \ldots , Q _ { s }$ (Proposition 4).
301
+ 6. Mix $Q _ { 1 } , \ldots , Q _ { s }$ with a matrix $W \in \mathbb { R } ^ { s ^ { \prime } \times s }$ and apply a nonlinearity $\Upsilon$ to get the final activation of the neuron, which consists of the $s ^ { \prime }$ output tensors
302
+
303
+ $$
304
+ F ^ { ( i ) } = \Upsilon \bigg [ \sum _ { j = 1 } ^ { s } W _ { i , j } Q _ { j } + b _ { i } \mathbb { 1 } \bigg ] \quad \qquad i = 1 , 2 , \ldots s ^ { \prime } ,
305
+ $$
306
+
307
+ where the $b _ { i }$ scalars are bias terms, and $\mathbb { 1 }$ is the $\left| \mathcal { P } _ { t } \right| \times \ldots \times \left| \mathcal { P } _ { t } \right|$ dimensional all ones tensor.
308
+
309
+ A few remarks are in order about this general scheme:
310
+
311
+ 1. Since $\widetilde { F } _ { c _ { 1 } } , \ldots , \widetilde { F } _ { c _ { s } }$ are stacked into a larger tensor and then possibly also multiplied by $A \downarrow _ { \mathcal { P } _ { t } }$ , the general tendency would be for the tensor order to increase at every node, and the corresponding storage requirements to increase exponentially. The purpose of the contractions in Step 5 is to counteract this tendency, and pull the order of the tensors back to some small number, typically 1, 2 or 3.
312
+ 2. However, since contractions can be done in many different ways, the number of channels will increase. When the number of input channels is small, this is reasonable, since otherwise the number of learnable weights in the algorithm would be too small. However, if unchecked, this can also become problematic. Fortunately, mixing the channels by $W$ on Step 6 gives an opportunity to stabilize the number of channels at some value $s ^ { \prime }$ .
313
+ 3. In the pseudocode above, for simplicity, the number of input channels is one and the number of output channels is $s ^ { \prime }$ . More realistically, the inputs would also have multiple channels (say, $s _ { 0 . }$ ) which would be propagated through the algorithm independently up to the mixing stage, making $W$ an $s ^ { \prime } \times s \times s _ { 0 }$ dimension tensor (not in the $P -$ –tensor sense!).
314
+ 4. The conventional part of the entire algorithm is Step 6, and the only learnable parameters are the entries of the $W$ matrix (tensor) and the $b _ { i }$ bias terms. These parameters are shared by all nodes in the network and learned in the usual way, by stochastic gradient descent.
315
+ 5. Our scheme could be elaborated further while maintaining permutation covariance by, for example taking the tensor product of $T$ with itself, or by introducing $A \downarrow _ { \mathcal { P } _ { t } }$ in a different way. However, the way that $\widetilde { F } _ { c _ { 1 } } , \ldots , \widetilde { F } _ { c _ { s } }$ and $A \downarrow _ { \mathcal { P } _ { t } }$ are combined by tensor products is already much more general and expressive than conventional message passing networks.
316
+ 6. Our framework admits many design choices, including the choice of the order odf the activations, the choice of contractions, and $c ^ { \prime }$ . However, the overall structure of Steps 1–5 is fully dictated by the covariance constraint on the network.
317
+ 7. The final output of the network $\phi ( G ) = F _ { r }$ must be permutation invariant. That means that the root node ${ \mathfrak { n } } _ { r }$ must produce a tuple of zeroth order tensors (scalars) $( F _ { r } ^ { ( 1 ) } , \dots , F _ { r } ^ { ( c ) } )$ . This is similar to how many other graph representation algorithms compute $\phi ( G )$ by summing the activations at level $L$ or creating histogram features.
318
+
319
+ We consider a few special cases to explain how tensor aggregation relates to more conventional message passing rules.
320
+
321
+ # 5.1.1 ZEROTH ORDER TENSOR AGGREGATION
322
+
323
+ Constraining both the input tensors $F _ { c _ { 1 } } , \ldots , F _ { c _ { s } }$ and the outputs to be zeroth order tensors, i.e., no need for promotions, and scalars, and foregoing multiplication by $T$ Ptis just the vector $A \downarrow _ { \mathcal { P } _ { t } }$ greatly simplifies the form of $( F _ { c _ { 1 } } ^ { \ell } , \ldots , F _ { c _ { s } } ^ { \ell } )$ . There is only one way to contract $\Phi$ . In this case there is a vector into a scalar, and that is to sum its elements. Therefore, in this case, the entire aggregation algorithm reduces to the simple formula
324
+
325
+ $$
326
+ F _ { i } = \Upsilon \Big ( w \sum _ { u = 1 } ^ { c } F _ { c _ { u } } + b \Big ) .
327
+ $$
328
+
329
+ For a neural network this is too simplistic. However, it’s interesting to note that the Weisfeiler– Lehmann isomorphism test essentially builds on just this formula, with a specific choice of $\Upsilon$ (Read & Corneil, 1977). If we allow more channels in the inputs and the outputs, $W$ becomes a matrix, and we recover the simplest form of neural message passing algorithms (Duvenaud et al., 2015).
330
+
331
+ # 5.1.2 FIRST ORDER TENSOR AGGREGATION
332
+
333
+ In first order tensor aggregation, assuming that $| { \mathcal { P } } _ { i } | = m$ , $\widetilde { F } _ { c _ { 1 } \ldots } , \ldots , \widetilde { F } _ { c _ { s } }$ are $m$ dimensional column vectors, and $T$ is an $m \times m$ matrix consisting of $F _ { c _ { 1 } } , \ldots , F _ { c _ { s } }$ stacked columnwise. There are two ways of contracting (in our generalized sense) a matrix into a vector: by summing over its rows, or summing over its columns. The second of these choices leads us back to summing over all contributions from the children, while the first is more interesting because it corresponds to summing $\widetilde { F } _ { c _ { 1 } } , \ldots , \widetilde { F } _ { c _ { s } }$ as vectors individually. In summary, we get an aggregation function that transforms a single input channel to two output channels of the form
334
+
335
+ $$
336
+ F _ { i } ^ { ( 1 ) } = \Upsilon \Big [ w _ { 1 , 1 } ( T ^ { \top } \mathbf { 1 } ) + w _ { 1 , 2 } ( T \mathbf { 1 } ) + b _ { 1 } \mathbf { 1 } \Big ] , \qquad F _ { i } ^ { ( 2 ) } = \Upsilon \Big [ w _ { 2 , 1 } ( T ^ { \top } \mathbf { 1 } ) + w _ { 2 , 2 } ( T \mathbf { 1 } ) + b _ { 2 } \mathbf { 1 } \Big ] ,
337
+ $$
338
+
339
+ where 1 denotes the $m$ dimensional all ones vector. Thus, in this layer $W \in \mathbb { R } ^ { 2 \times 2 }$ . Unless constrained by $c ^ { \prime }$ , in each subsequent layer the number of channels doubles further and these channels can all mix with each other, so $W ^ { ( 2 ) } { \in } \mathbb { R } ^ { 4 \times 4 }$ , $W ^ { ( 3 ) } \in \mathbb { R } ^ { 8 \times 8 }$ , and so on.
340
+
341
+ # 5.1.3 SECOND ORDER TENSOR AGGREGATION WITHOUT THE ADJACENCY MATRIX
342
+
343
+ In second order tensor aggregation, $T$ is a third order $P$ –tensor, which can be contracted back to second order in three different ways, by projecting it along each of its dimensions. Therefore the outputs will be the three matrices
344
+
345
+ $$
346
+ F ^ { ( i ) } = \Upsilon \big ( w _ { i , 1 } T \downarrow _ { 1 } + w _ { i , 2 } T \downarrow _ { 2 } + w _ { i , 3 } T \downarrow _ { 3 } + b _ { i } { \bf 1 } _ { m \times m } \big ) \qquad i \in \{ 1 , 2 , 3 \} ,
347
+ $$
348
+
349
+ and the weight matrix is $W \in \mathbb { R } ^ { 3 \times 3 }$ .
350
+
351
+ # 5.1.4 SECOND ORDER TENSOR AGGREGATION WITH THE ADJACENCY MATRIX
352
+
353
+ The first nontrivial tensor contraction case occurs when $\widetilde { F } _ { c _ { 1 } } , \ldots , \widetilde { F } _ { c _ { s } }$ are second order tensors, and we multiply with $A \downarrow _ { \mathcal { P } _ { t } }$ , since in that case $T$ is 5th order, and can be contracted down to second order in a total of 50 different ways:
354
+
355
+ 1. The “ $1 + 1 + 1 ^ { , }$ case contracts $T$ in the form $T _ { i _ { 1 } , i _ { 2 } , i _ { 3 } , i _ { 4 } , i _ { 5 } } \delta ^ { i _ { a _ { 1 } } } \delta ^ { i _ { a _ { 2 } } } \delta ^ { i _ { a _ { 3 } } }$ , i.e., it projects $T$ down along 3 of its 5 dimensions. This alone can be done in ${ \binom { 5 } { 3 } } = 1 0 .$ different ways7 2. The $^ { 6 6 } 1 { + } 2 ^ { 5 }$ case contracts $T$ in the form $T _ { i _ { 1 } , i _ { 2 } , i _ { 3 } , i _ { 4 } , i _ { 5 } } \delta ^ { i _ { a _ { 1 } } } \delta ^ { i _ { a _ { 2 } } , i _ { a _ { 3 } } }$ , i.e., it projects $T$ along one dimension, and contracts it along two others. This can be done in $3 { \binom { 5 } { 3 } } = 3 0$ ways. 3. The $\mathbf { \bar { \Psi } } ^ { 6 6 } 3 ^ { \mathfrak { s } }$ case is a single 3-fold contraction $T _ { i _ { 1 } , i _ { 2 } , i _ { 3 } , i _ { 4 } , i _ { 5 } } \delta ^ { i _ { a _ { 1 } } , i _ { a _ { 2 } } , i _ { a _ { 3 } } }$ , which again can be done in ${ \binom { 5 } { 3 } } = 1 0$ different ways.
356
+
357
+ The tensor $\mathcal { T } _ { i _ { 1 } , i _ { 2 } , i _ { 3 } , i _ { 4 } , i _ { 5 } }$ will be symmetric with respect to two sets of indices, following the structure of the promotion tensors and the adjacency matrix. Including these symmetries, the number of contractions is 18 including: five $^ { \ 6 } 1 + 1 + 1 \ '$ , ten $^ { } 1 { + } 2 ^ { \circ }$ , and three $\mathbf { \bar { \Psi } } ^ { 6 6 } 3 ^ { \mathfrak { s } }$ .
358
+
359
+ ![](images/69128a399e98e7c84471301683172e6a6a2ef3306b9b8a14871cecf443ca354f.jpg)
360
+ Figure 6: The activations of vertices in the receptive field $\mathcal { P } _ { \ell } ^ { v } = \{ w _ { 1 } , w _ { 2 } , w _ { 3 } \}$ of vertex $v$ at level $\ell \cdot$ -th are stacked into a 3rd order tensor and undergo a tensor product operation with the restricted adjacency matrix, and then contracted in different ways. In this figure, we only consider single channel, each channel is represented by a 5th order tensor. In the general case of multi channels, the resulting tensor would have 6th order, but we contract on each channel separately.
361
+
362
+ # 6 EXPERIMENTS
363
+
364
+ We compared the second order variant (CCN 2D) of our CCNs framework (Section 4.2) to several standard graph learning algorithms on three types of datasets that involve learning the properties of molecules from their structure:
365
+
366
+ 1. The Harvard Clean Energy Project (Hachmann et al., 2011), consisting of 2.3 million organic compounds that are candidates for use in solar cells. The regression target in this case is Power Conversion Efficiency (PCE). Due to time constraints, instead of using the entire dataset, the experiments were ran on a random subset of 50,000 molecules.
367
+ 2. QM9, which is a dataset of all 133k organic molecules with up to nine heavy atoms (C,O,N and F) out of the GDB-17 universe of molecules. Each molecule has 13 target properties to predict. The dataset does contain spatial information relating to the atomic configurations, but we only used the chemical graph and atom node labels. For our experiments we normalized each target variable to have mean 0 and standard deviation 1. We report both MAE and RMSE for all normalized learning targets.
368
+ 3. Graph kernels datasets, specifically (a) MUTAG, which is a dataset of 188 mutagenic aromatic and heteroaromatic compounds (Debnat et al., 1991); (b) PTC, which consists of 344 chemical compounds that have been tested for positive or negative toxicity in lab rats (Toivonen et al., 2003); (c) NCI1 and NCI109, which have 4110 and 4127 compounds respectively, each screened for activity against small cell lung cancer and ovarian cancer lines (Wale et al., 2008).
369
+
370
+ In the case of HCEP, we compared CCN to lasso, ridge regression, random forests, gradient boosted trees, optimal assignment Wesifeiler–Lehman graph kernel (Kriege et al., 2016) (WL), neural graph fingerprints (Duvenaud et al., 2015), and the “patchy-SAN” convolutional type algorithm from (Niepert et al., 2016) (referred to as PSCN). For the first four of these baseline methods, we created simple feature vectors from each molecule: the number of bonds of each type (i.e. number of $_ \mathrm { H - H }$ bonds, number of ${ \mathrm { C } } { \mathrm { - } } 0$ bonds, etc) and the number of atoms of each type. Molecular graph fingerprints uses atom labels of each vertex as base features. For ridge regression and lasso, we cross validated over $\lambda$ . For random forests and gradient boosted trees, we used 400 trees, and cross validated over max depth, minimum samples for a leaf, minimum samples to split a node, and learning rate (for GBT). For neural graph fingerprints, we used 2 layers and a hidden layer size of 10. In PSCN, we used a patch size of 10 with two convolutional layers and a dense layer on top as described in their paper.
371
+
372
+ For the graph kernels datasets, we compare against graph kernel results as reported in (Kondor & Pan, 2016) (which computed kernel matrices using the Weisfeiler–Lehman, Weisfeiler–edge, shortest paths, graphlets and multiscale Laplacian graph kernels and used a C-SVM on top), Neural graph fingerprints (with 2 levels and a hidden size of 10) and PSCN. For QM9, we compared against the Weisfeiler–Lehman graph kernel (with C-SVM on top), neural graph fingerprints, and PSCN. The settings for NGF and PSCN are as described for HCEP.
373
+
374
+ For our own method, second order CCN, we initialized the base features of each vertex with computed histogram alignment features, inspired by (Kriege et al., 2016), of depth up to 10. Each vertex receives a base label $l _ { i } = \mathrm { c o n c a t } _ { j = 1 } ^ { 1 0 } \bar { H _ { j } } ( i )$ where $\bar { H _ { j } } ( i ) \in \mathbb { R } ^ { d }$ (with $d$ being the total number of distinct discrete node labels) is the vector of relative frequencies of each label for the set of vertices at distance equal to $j$ from vertex $i$ . We use exactly 18 unique contractions defined in 5.1.4 that result in additional channels. We used up to three levels and the intermediate number of channels increases 18 time at each level. To avoid exponentially growing channels, we applied learnable weight matrices to compress the channels into a fixed number of channels.
375
+
376
+ In each experiment we used $80 \%$ of the dataset for training, $10 \%$ for validation, and evaluated on the remaining $10 \%$ test set. For the kernel datasets we performed the experiments on 10 separate training/validation/test stratified splits and averaged the resulting classification accuracies. We used Adam optimization method (Kingma & Ba, 2015). Our initial learning rate was set to 0.001 after experimenting on a held out set. The learning rate decayed linearly after each step towards a minimum of $1 0 ^ { - 6 }$ .
377
+
378
+ # 6.1 GRAPHFLOW DEEP LEARNING FRAMEWORK
379
+
380
+ We developed our custom Deep Learning framework in $\mathrm { C + + / C U D A }$ named GraphFlow that supports symbolic/automatic differentiation, dynamic computation graphs, specialized tensor operations, and computational acceleration with GPU. Our method, Covariant Compositional Networks, and other graph neural networks such as Neural Graph Fingerprints (Duvenaud et al., 2015), PSCN (Niepert et al., 2016) and Gated Graph Neural Networks (Li et al., 2016) are implemented based on the GraphFlow framework. Our source code can be found at https://github.com/HyTruongSon/ GraphFlow.
381
+
382
+ One challenge of the implementation of Covariant Compositional Networks is that the high-order tensors (for example, in figure 6, we have a 5th order tensor after the tensor product operation) cannot be stored explicitly in the memory. Our solution is to propose a virtual indexing system in such a way that we never compute the whole sparse high-order tensor at once, but only compute its elements when given the indices. Basically, we always work with a virtual tensor, and that allows us to implement our tensor reduction/contraction operations efficiently with GPU.
383
+
384
+ # 6.2 DISCUSSION
385
+
386
+ On the subsampled HCEP dataset, CCN outperforms all other methods by a very large margin. For the graph kernels datasets, SVM with the Weisfeiler–Lehman kernels achieve the highest accuracy on NCI1 and NCI109, while CCN wins on MUTAG and PTC. Perhaps this poor performance is to be expected, since the datasets are small and neural network approaches usually require tens of thousands of training examples at minimum to be effective. Indeed, neural graph fingerprints and PSCN also perform poorly compared to the Weisfeiler–Lehman kernels.
387
+
388
+ In the QM9 experiments, CCN beats the three other algorithms in both mean absolute error and root mean squared error. It should be noted that (Gilmer et al., 2017) obtained stronger results on QM9, but we cannot properly compare our results with theirs because our experiments only use the adjacency matrices and atom labels of each node, while theirs includes comprehensive chemical features that better inform the target quantum properties.
389
+
390
+ Table 1: HCEP regression results
391
+
392
+ <table><tr><td rowspan=1 colspan=1></td><td rowspan=1 colspan=1>Test MAE</td><td rowspan=1 colspan=1>Test RMSE</td></tr><tr><td rowspan=1 colspan=1>Lasso</td><td rowspan=1 colspan=1>0.867</td><td rowspan=1 colspan=1>1.437</td></tr><tr><td rowspan=1 colspan=1>Ridge regression</td><td rowspan=1 colspan=1>0.854</td><td rowspan=1 colspan=1>1.376</td></tr><tr><td rowspan=1 colspan=1>Random forest</td><td rowspan=1 colspan=1>1.004</td><td rowspan=1 colspan=1>1.799</td></tr><tr><td rowspan=1 colspan=1>Gradient boosted trees</td><td rowspan=1 colspan=1>0.704</td><td rowspan=1 colspan=1>1.005</td></tr><tr><td rowspan=1 colspan=1>WL graph kernel</td><td rowspan=1 colspan=1>0.805</td><td rowspan=1 colspan=1>1.096</td></tr><tr><td rowspan=1 colspan=1>Neural graph fingerprints</td><td rowspan=1 colspan=1>0.851</td><td rowspan=1 colspan=1>1.177</td></tr><tr><td rowspan=1 colspan=1>PSCN (k = 10)</td><td rowspan=1 colspan=1>0.718</td><td rowspan=1 colspan=1>0.973</td></tr><tr><td rowspan=1 colspan=1>CCN 2D</td><td rowspan=1 colspan=1>0.340</td><td rowspan=1 colspan=1>0.449</td></tr></table>
393
+
394
+ Table 2: Kernel Datasets Classification results (accuracy $+ / -$ standard deviation)
395
+
396
+ <table><tr><td rowspan=1 colspan=1></td><td rowspan=1 colspan=1>MUTAG</td><td rowspan=1 colspan=1>PTC</td><td rowspan=1 colspan=1>NCI1</td><td rowspan=1 colspan=1>NCI109</td></tr><tr><td rowspan=1 colspan=1>WL</td><td rowspan=1 colspan=1>84.50 ± 2.16</td><td rowspan=1 colspan=1>59.97 ± 1.60</td><td rowspan=1 colspan=1>84.76 ± 0.32</td><td rowspan=1 colspan=1>85.12 ± 0.29</td></tr><tr><td rowspan=1 colspan=1>WL-edge</td><td rowspan=1 colspan=1>82.94 ± 2.33</td><td rowspan=1 colspan=1>60.18 ± 2.19</td><td rowspan=1 colspan=1>84.65 ± 0.25</td><td rowspan=1 colspan=1>85.32 ± 0.34</td></tr><tr><td rowspan=1 colspan=1>SP</td><td rowspan=1 colspan=1>85.50 ± 2.50</td><td rowspan=1 colspan=1>59.53 ± 1.71</td><td rowspan=1 colspan=1>73.61 ± 0.36</td><td rowspan=1 colspan=1>73.23 ± 0.26</td></tr><tr><td rowspan=1 colspan=1>Graphlet</td><td rowspan=1 colspan=1>82.44 ± 1.29</td><td rowspan=1 colspan=1>55.88 ± 0.31</td><td rowspan=1 colspan=1>62.40 ± 0.27</td><td rowspan=1 colspan=1>62.35 ± 0.28</td></tr><tr><td rowspan=1 colspan=1>p-RW</td><td rowspan=1 colspan=1>80.33 ± 1.35</td><td rowspan=1 colspan=1>59.85 ± 0.95</td><td rowspan=1 colspan=1>TIMED OUT</td><td rowspan=1 colspan=1>TIMED OUT</td></tr><tr><td rowspan=1 colspan=1>MLG</td><td rowspan=1 colspan=1>87.94 ± 1.61</td><td rowspan=1 colspan=1>63.26 ± 1.48</td><td rowspan=1 colspan=1>81.75 ± 0.24</td><td rowspan=1 colspan=1>81.31 ± 0.22</td></tr><tr><td rowspan=1 colspan=1>PSCN k = 10 (Niepert et al.)</td><td rowspan=1 colspan=1>88.95 ± 4.37</td><td rowspan=1 colspan=1>62.29 ± 5.68</td><td rowspan=1 colspan=1>76.34 ± 1.68</td><td rowspan=1 colspan=1>N/A</td></tr><tr><td rowspan=1 colspan=1>Neural graph fingerprints</td><td rowspan=1 colspan=1>89.00± 7.00</td><td rowspan=1 colspan=1>57.85 ± 3.36</td><td rowspan=1 colspan=1>62.21 ± 4.72</td><td rowspan=1 colspan=1>56.11 ± 4.31</td></tr><tr><td rowspan=1 colspan=1>CCN 2D</td><td rowspan=1 colspan=1>91.64 ± 7.24</td><td rowspan=1 colspan=1>70.62 ± 7.04</td><td rowspan=1 colspan=1>76.27 ± 4.13</td><td rowspan=1 colspan=1>75.54 ± 3.36</td></tr></table>
397
+
398
+ # 7 CONCLUSIONS
399
+
400
+ We have presented a general framework called covariant compositional networks (CCNs) for constructing covariant graph neural networks, which encompasses other message passing approaches as special cases, but takes a more general and principled approach to ensuring covariance with respect to permutations. Experimental results on several benchmark datasets show that CCNs can outperform other state-of-the-art algorithms.
401
+
402
+ Table 3: QM9 regression results (MAE)
403
+
404
+ <table><tr><td rowspan=1 colspan=1></td><td rowspan=1 colspan=1>WLGK</td><td rowspan=1 colspan=1>NGF</td><td rowspan=1 colspan=1>PSCN (k =10)</td><td rowspan=1 colspan=1>CCN 2D</td></tr><tr><td rowspan=1 colspan=1>alpha</td><td rowspan=1 colspan=1>0.46</td><td rowspan=1 colspan=1>0.43</td><td rowspan=1 colspan=1>0.20</td><td rowspan=1 colspan=1>0.16</td></tr><tr><td rowspan=1 colspan=1>Cv</td><td rowspan=1 colspan=1>0.59</td><td rowspan=1 colspan=1>0.47</td><td rowspan=1 colspan=1>0.27</td><td rowspan=1 colspan=1>0.23</td></tr><tr><td rowspan=1 colspan=1>G</td><td rowspan=1 colspan=1>0.51</td><td rowspan=1 colspan=1>0.46</td><td rowspan=1 colspan=1>0.33</td><td rowspan=1 colspan=1>0.29</td></tr><tr><td rowspan=1 colspan=1>gap</td><td rowspan=1 colspan=1>0.72</td><td rowspan=1 colspan=1>0.67</td><td rowspan=1 colspan=1>0.60</td><td rowspan=1 colspan=1>0.54</td></tr><tr><td rowspan=1 colspan=1>H</td><td rowspan=1 colspan=1>0.52</td><td rowspan=1 colspan=1>0.47</td><td rowspan=1 colspan=1>0.34</td><td rowspan=1 colspan=1>0.30</td></tr><tr><td rowspan=1 colspan=1>HOMO</td><td rowspan=1 colspan=1>0.64</td><td rowspan=1 colspan=1>0.58</td><td rowspan=1 colspan=1>0.51</td><td rowspan=1 colspan=1>0.39</td></tr><tr><td rowspan=1 colspan=1>LUMO</td><td rowspan=1 colspan=1>0.70</td><td rowspan=1 colspan=1>0.65</td><td rowspan=1 colspan=1>0.59</td><td rowspan=1 colspan=1>0.53</td></tr><tr><td rowspan=1 colspan=1>mu</td><td rowspan=1 colspan=1>0.69</td><td rowspan=1 colspan=1>0.63</td><td rowspan=1 colspan=1>0.54</td><td rowspan=1 colspan=1>0.48</td></tr><tr><td rowspan=1 colspan=1>omega1</td><td rowspan=1 colspan=1>0.72</td><td rowspan=1 colspan=1>0.63</td><td rowspan=1 colspan=1>0.57</td><td rowspan=1 colspan=1>0.45</td></tr><tr><td rowspan=1 colspan=1>R2</td><td rowspan=1 colspan=1>0.55</td><td rowspan=1 colspan=1>0.49</td><td rowspan=1 colspan=1>0.22</td><td rowspan=1 colspan=1>0.19</td></tr><tr><td rowspan=1 colspan=1>U</td><td rowspan=1 colspan=1>0.52</td><td rowspan=1 colspan=1>0.47</td><td rowspan=1 colspan=1>0.34</td><td rowspan=1 colspan=1>0.29</td></tr><tr><td rowspan=1 colspan=1>U0</td><td rowspan=1 colspan=1>0.52</td><td rowspan=1 colspan=1>0.47</td><td rowspan=1 colspan=1>0.34</td><td rowspan=1 colspan=1>0.29</td></tr><tr><td rowspan=1 colspan=1>ZPVE</td><td rowspan=1 colspan=1>0.57</td><td rowspan=1 colspan=1>0.51</td><td rowspan=1 colspan=1>0.43</td><td rowspan=1 colspan=1>0.39</td></tr></table>
405
+
406
+ Table 4: QM9 regression results (RMSE)
407
+
408
+ <table><tr><td rowspan=1 colspan=1></td><td rowspan=1 colspan=1>WLGK</td><td rowspan=1 colspan=1>NGF</td><td rowspan=1 colspan=1>PSCN (k =10)</td><td rowspan=1 colspan=1>CCN 2D</td></tr><tr><td rowspan=1 colspan=1>alpha</td><td rowspan=1 colspan=1>0.68</td><td rowspan=1 colspan=1>0.65</td><td rowspan=1 colspan=1>0.31</td><td rowspan=1 colspan=1>0.26</td></tr><tr><td rowspan=1 colspan=1>Cv</td><td rowspan=1 colspan=1>0.78</td><td rowspan=1 colspan=1>0.65</td><td rowspan=1 colspan=1>0.34</td><td rowspan=1 colspan=1>0.30</td></tr><tr><td rowspan=1 colspan=1>G</td><td rowspan=1 colspan=1>0.67</td><td rowspan=1 colspan=1>0.62</td><td rowspan=1 colspan=1>0.43</td><td rowspan=1 colspan=1>0.38</td></tr><tr><td rowspan=1 colspan=1>gap</td><td rowspan=1 colspan=1>0.86</td><td rowspan=1 colspan=1>0.82</td><td rowspan=1 colspan=1>0.75</td><td rowspan=1 colspan=1>0.69</td></tr><tr><td rowspan=1 colspan=1>H</td><td rowspan=1 colspan=1>0.68</td><td rowspan=1 colspan=1>0.62</td><td rowspan=1 colspan=1>0.44</td><td rowspan=1 colspan=1>0.40</td></tr><tr><td rowspan=1 colspan=1>HOMO</td><td rowspan=1 colspan=1>0.91</td><td rowspan=1 colspan=1>0.81</td><td rowspan=1 colspan=1>0.70</td><td rowspan=1 colspan=1>0.55</td></tr><tr><td rowspan=1 colspan=1>LUMO</td><td rowspan=1 colspan=1>0.84</td><td rowspan=1 colspan=1>0.79</td><td rowspan=1 colspan=1>0.73</td><td rowspan=1 colspan=1>0.68</td></tr><tr><td rowspan=1 colspan=1>mu</td><td rowspan=1 colspan=1>0.92</td><td rowspan=1 colspan=1>0.87</td><td rowspan=1 colspan=1>0.75</td><td rowspan=1 colspan=1>0.67</td></tr><tr><td rowspan=1 colspan=1>omega1</td><td rowspan=1 colspan=1>0.84</td><td rowspan=1 colspan=1>0.77</td><td rowspan=1 colspan=1>0.73</td><td rowspan=1 colspan=1>0.65</td></tr><tr><td rowspan=1 colspan=1>R2</td><td rowspan=1 colspan=1>0.81</td><td rowspan=1 colspan=1>0.71</td><td rowspan=1 colspan=1>0.31</td><td rowspan=1 colspan=1>0.27</td></tr><tr><td rowspan=1 colspan=1>U</td><td rowspan=1 colspan=1>0.67</td><td rowspan=1 colspan=1>0.62</td><td rowspan=1 colspan=1>0.44</td><td rowspan=1 colspan=1>0.40</td></tr><tr><td rowspan=1 colspan=1>U0</td><td rowspan=1 colspan=1>0.67</td><td rowspan=1 colspan=1>0.62</td><td rowspan=1 colspan=1>0.44</td><td rowspan=1 colspan=1>0.39</td></tr><tr><td rowspan=1 colspan=1>ZPVE</td><td rowspan=1 colspan=1>0.72</td><td rowspan=1 colspan=1>0.66</td><td rowspan=1 colspan=1>0.55</td><td rowspan=1 colspan=1>0.51</td></tr></table>
409
+
410
+ # REFERENCES
411
+
412
+ P. Battaglia, R. Pascanu, M. Lai, D. J. Rezende, and K. Kavukcuoglu. Interaction networks for learning about objects, relations and physics. 29:4502–4510, 2016.
413
+
414
+ K. M. Borgwardt and H. P. Kriegel. Shortest-path kernels on graphs. 5:74–81, 2005.
415
+
416
+ J. Bruna, W. Zaremba, A. Szlam, and Y. LeCun. Spectral networks and locally connected networks on graphs. 3, 2014.
417
+
418
+ J. Y. Cai, M. Furer, and N. Immerman. An optimal lower bound on the number of variables for graph identification. Combinatorica, 12:389–410, 12 1992.
419
+
420
+ T. Cohen and M. Welling. Group equivariant convolutional networks. 33:2990–2999, 2016.
421
+
422
+ T. Cohen and M. Welling. Steerable cnns. Proc. ICLR, 5, 2017.
423
+
424
+ A. K. Debnat, R. L. Lopez de Compadre, G. Debnath, A. J. Shusterman, and C. Hansch. Structureactivity relationship of mutagenic aromatic and heteroaromatic nitro compounds. correlation with molecular orbital energies and hydrophobicity. J. Med. Chem., 34:786–97, 1991.
425
+
426
+ M. Defferrard, X. Bresson, and P. Vandergheynst. Convolutional neural networks on graphs with fast localized spectral filtering. 29, 2016.
427
+
428
+ D. K. Duvenaud, D. Maclaurin, J. Iparraguirre, R. Bombarell, T. Hirzel, A. Aspuru-Guzik, and R. P. Adams. Convolutional networks on graphs for learning molecular fingerprints. 28:2224–2232, 2015.
429
+
430
+ P. F. Felzenszwalb and D. P. Huttenlocher. Pictorial structures for object recognition. Int. J. Comput. Vis., 61:55–71, 2005.
431
+
432
+ P. F. Felzenszwalb, R. B. Girshick, D. McAllester, and D. Ramanan. Object detection with discriminatively trained part-based models. IEEE Trans. Pattern Anal. Mach. Intell., 32:541–551, 2010.
433
+
434
+ A. Feragen, N. Kasenburg, J. Peterson, M. de Bruijne, and K. M. Borgwardt. Scalable kernels for graphs with continuous attributes. 26, 2013.
435
+
436
+ M. Fischler and R. Elschlager. The representation and matching of pictorial structures. IEEE Trans. Comput., C-22:67–92, 1973.
437
+
438
+ W. T. Freeman and E. H. Adelson. The design and use of steerable filters. IEEE Trans. Pattern Anal. Mach. Intell., 13:891–906, 09 1991.
439
+
440
+ T. Gartner. Exponential and geometric kernels for graphs. Principles of modeling nonvectorial data, ¨ 2002.
441
+
442
+ J. Gilmer, S. S. Schoenholz, P. F. Riley, O. Vinyals, and G. E. Dahl. Neural message passing for quantum chemistry. In Doina Precup and Yee Whye Teh (eds.), Proc. ICML, volume 70 of Proceedings of Machine Learning Research, pp. 1263–1272, International Convention Centre, Sydney, Australia, 08 2017. PMLR. URL http://proceedings.mlr.press/v70/ gilmer17a.html.
443
+ J. Hachmann, R. Olivares-Amaya, S. Atahan-Evrenk, C. Amador-Bedolla, R. S. Sanchez-Carrera, A. Gold-Parker, L. Vogt, A. M. Brockway, and A. Aspuru-Guzik. The harvard clean energy project: Large-scale computational screening and design of organic photovoltaics on the world community grid. J. Phys. Chem. Lett., 2:2241–2251, 2011.
444
+ M. Henaff, J. Bruna, and Y. LeCun. Deep convolutional networks on graph-structured data. arXiv preprint arXiv:1506.05163, 06 2015.
445
+ S. Kearnes, K. McCloskey, M. Brendl, V. Pande, and P. Riley. Molecular graph convolutions: moving beyond fingerprints. J. Comput. Aided Mol. Des., 30:595–608, 2016.
446
+ D. P. Kingma and J. Ba. Adam: A method for stochastic optimization. In Proc. ICLR, San Diego, 2015.
447
+ T. N. Kipf and M. Welling. Semi-supervised classification with graph convolutional networks. 5, 2017.
448
+ R. Kondor and K. M. Borgwardt. The skew spectrum of graphs. 25:496–503, 2008.
449
+ R. Kondor and H. Pan. The multiscale laplacian graph kernel. 29:2982–2990, 2016.
450
+ N. M. Kriege, P. Giscard, and R. Wilson. On valid optimal assignment kernels and applications to graph classification. Adv. NIPS, 20:1623–1631, 2016.
451
+ A. Krizhevsky, I. Sutskever, and G. E. Hinton. Imagenet classification with deep convolutional neural networks. 25:1097–1105, 01 2012.
452
+ Y. LeCun, Y. Bengio, and P. Haffner. Gradient-based learning applied to document recognition. Proc. IEEE, pp. 2278–2324, 1998.
453
+ Y. Li, D. Tarlow, M. Brockschmidt, and R. Zemel. Gated graph sequence neural networks. Proc. ICLR, 4, 2016.
454
+ R. Manduchi, P. Perona, and D. Shy. Efficient deformable filter banks. IEEE Trans. on Signal Process., 46:1168–1173, 04 1998.
455
+ M. Neumann, R. Garnett, C. Baukhage, and K. Kersting. Propagation kernels: efficient graph kernels from propagated information. 102, 02 2016.
456
+ M. Niepert, M. Ahmed, and K. Kutzkov. Learning convolutional neural networks for graphs. 33: 2014–2023, 2016.
457
+ Y. Ohta, T. Kanade, and T. Sakai. An analysis system for scenes containing objects with substructures. 4:752–754, 1978.
458
+ P. Perona. Deformable kernels for early vision. IEEE Trans. Pattern Anal. Mach. Intell., 17:488– 499, 05 1995.
459
+ R. C. Read and D. G. Corneil. The graph isomorphism disease. J. Graph Theory, 1:339–363, 1977.
460
+ B. E. Sagan. The Symmetric Group. Grad. Texts in Math. Springer, 2001.
461
+ F. Scarselli, M. Gori, A. C. Tsoi, M. Hagenbuchner, and G. Monfardini. The graph neural network model. IEEE Trans. on Neural Netw., 20:61–80, 2009.
462
+ K. T. Schutt, Kristof T., F. Arbabzadah, S. Chmiela, K. R. M ¨ uller, and A. Tkatchenko. Quantum- ¨ chemical insights from deep tensor neural networks. Nat. Commun., 8:13890, 01 2017.
463
+ N. Shervashidze, S. V. N. Vishwanathan, T. Petri, K. M., and K. M. Borgwardt. Efficient graphlet kernels for large graph comparison. 12:488–495, 2009.
464
+ N. Shervashidze, P. Schweitzer, E. J. van Leeuwan, K. Mehlhorn, and K. M. Borgwardt. Weisfeilerlehman graph kernels. J. Mach. Learn. Res., 12:2539–2561, 2011.
465
+ E. P. Simoncelli, W. T. Freeman, E. H. Adelson, and D. J. Heeger. Shiftable multiscale transforms. IEEE Trans. Inf. Theory., 38:587–607, 03 1992.
466
+ P. C. Teo and Y. Hel-Or. Lie generators for computing steerable functions. Pattern Recognit. Lett., 16:7–17, 10 1998.
467
+ H. Toivonen, A. Srinivasan, R. D. King, S. Kramer, and C. Helma. Statistical evaluation of the predictive toxicology challenge. Bioinformatics, 19:1183–1193, 2003.
468
+ Z. W. Tu, X. R. Chen, A. L. Yuille, and S. C. Zhu. Image parsing: Unifying segmentation, detection, and recognition. Int. J. Comput. Vis., 63:113–140, 2005.
469
+ S. V. N. Vishwanathan, N. N. Schraudolf, R. Kondor, and K. M. Bogwardt. Graph kernels. J. Mach. Learn. Res., 11:1201–1242, 2010.
470
+ N. Wale, I. A. Watson, and G. Karypis. Comparison of descriptor spaces for chemical compound retrieval and classification. Knowl. Info. Sys., 14:347–375, 2008.
471
+ B. Weisfeiler and A. A. Lehman. A reduction of a graph to a canonical form and an algebra arising during this reduction. Nauchno-Technicheskaya Informatsia, 9, 1968.
472
+ D. E. Worrall, S. Garbin, D. Turmukhambetov, and G. J. Brostow. Harmonic networks: Deep translation and rotation equivariance. Proc. IEEE CVPR, 07 2017.
473
+ S. Zhu and D. Mumford. A stochastic grammar of images. Found. Trends Comput. Graphics Vis., 2:259–362, 2006.
474
+
475
+ # A MATHEMATICAL BACKGROUND
476
+
477
+ Groups. A group is a set $G$ endowed with an operation $G \times G \to G$ (usually denoted multiplicatively) obeying the following axioms:
478
+
479
+ G1. for any $u , v \in G , \ u v \in G$ (closure);
480
+ G2. for any $u , v , w \in G$ , $u ( v w ) = ( u v ) w$ (associativity);
481
+ G3. there is a unique $e \in G$ , called the identity of $G$ , such that $e u = u e = u$ for any $u \in G$ ;
482
+ G4. for any $u \in G$ , there is a corresponding element $u ^ { - 1 } \in G$ called the inverse of $u$ , such that $u u ^ { - 1 } \bar { } = u ^ { - 1 } u = e .$ .
483
+
484
+ We do not require that the group operation be commutative, i.e., in general, $u v \ne v u$ . Groups can be finite or infinite, countable or uncountable, compact or non-compact. While most of the results in this paper would generalize to any compact group, the keep the exposition as simple as possible, throughout we assume that $G$ is finite or countably infinite. As usual, $| G |$ will denote the size (cardinality) of $G$ , sometimes also called the order of the group.
485
+
486
+ Representations. A (finite dimensional) representation of a group $G$ over a field $\mathbb { F }$ is a matrixvalued function $R \colon G \to \mathbb { F } ^ { d _ { \rho } \times d _ { \rho } }$ such that $R ( x ) R ( y ) = R ( x y )$ for any $x , y \in G$ . We generally assume that $\mathbb { F } = \mathbb { C }$ , however in the special case when $G$ is the symmetric group $\mathbb { S } _ { n }$ we can restrict ourselves to only considering real-valued representations, i.e., $\mathbb { F } = \mathbb { R }$ .
487
+
488
+ # B PROOFS
489
+
490
+ Proof of Proposition 1. Let $\mathcal { G }$ and $\mathcal { G } ^ { \prime }$ be two compound objects, where $\mathcal { G } ^ { \prime }$ is equivalent to $\mathcal { G }$ up to a permutation $\sigma \in \mathbb { S } _ { n }$ of the atoms. For any node ${ \mathfrak { n } } _ { a }$ of $\mathcal { G }$ we let ${ \mathfrak { n } } _ { a } ^ { \prime }$ be the corresponding node of $\mathcal { G } ^ { \prime }$ , and let $f _ { a }$ and $f _ { a } ^ { \prime }$ be their activations.
491
+
492
+ We prove that $f _ { a } = f _ { a } ^ { \prime }$ for every node in $\mathcal { G }$ by using induction on the distance of ${ \mathfrak { n } } _ { a }$ from its farthest descendant that is a leaf, which we call its height and denote $h ( a )$ . For $h ( a ) = 0$ , the statment is
493
+
494
+ clearly true, since $f _ { a } = f _ { a } ^ { \prime } = \ell _ { \xi ( a ) }$ . Now assume that it is true for all nodes with height up to $h ^ { * }$ . For any node ${ \mathfrak { n } } _ { a }$ with $h ( a ) = h ^ { * } + 1$ , $f _ { a } = \Phi ( f _ { c _ { 1 } } , f _ { c _ { 2 } } , . . . , f _ { c _ { k } } )$ , where each of the children $c _ { 1 } , \ldots , c _ { k }$ are of height at most $h ^ { * }$ , therefore
495
+
496
+ $$
497
+ f _ { a } = \Phi ( f _ { c _ { 1 } } , f _ { c _ { 2 } } , \dots , f _ { c _ { k } } ) = \Phi ( f _ { c _ { 1 } } ^ { \prime } , f _ { c _ { 2 } } ^ { \prime } , \dots , f _ { c _ { k } } ^ { \prime } ) = f _ { a } ^ { \prime } .
498
+ $$
499
+
500
+ Thus, $f _ { a } = f _ { a } ^ { \prime }$ for every node in $\mathcal { G }$ . The proposition follows by $\phi ( \mathcal { G } ) = f _ { r } = f _ { r } ^ { \prime } = \phi ( \mathcal { G } ^ { \prime } )$
501
+
502
+ Proof of Proposition 3. Let ${ \mathcal { G } } , { \mathcal { G } } ^ { \prime }$ , $\mathcal { N }$ and $\mathcal { N } ^ { \prime }$ be as in Definition 5. As in Definition 6, for each node (neuron) ${ \mathfrak { n } } _ { i }$ in $\mathcal { N }$ there is a node ${ \mathfrak { n } } _ { j } ^ { \prime }$ in $\mathcal { N } ^ { \prime }$ such that their receptive fields are equivalent up to permutation. That is, if $| { \mathcal { P } } _ { i } | = m$ , then $\left. \mathcal { P } _ { j } ^ { \prime } \right. = m$ , and there is a permutation $\pi \in \mathbb { S } _ { m }$ , such that if $\mathcal { P } _ { i } = ( e _ { p _ { 1 } } , \dots , e _ { p _ { m } } )$ and $\mathcal { P } _ { j } ^ { \prime } = ( e _ { q _ { 1 } } , \ldots , e _ { q _ { m } } )$ , then $e _ { q _ { \pi ( a ) } } = e _ { p _ { a } }$ . By covariance, then $f _ { j } ^ { \prime } = R _ { \pi } ( f _ { i } )$ .
503
+
504
+ Now let $\mathcal { G } ^ { \prime \prime }$ be a third equivalent object, and $\mathcal { N } ^ { \prime \prime }$ the corresponding comp-net. $\mathcal { N } ^ { \prime \prime }$ must also have a node, $\mathfrak { n } _ { k } ^ { \prime \prime }$ , that corresponds to ${ \mathfrak { n } } _ { i }$ and ${ \mathfrak { n } } _ { j } ^ { \prime }$ . In particular, letting its receptive field be $\mathcal { P } _ { k } ^ { \prime \prime } = ( e _ { r _ { 1 } } , \ldots , e _ { r _ { m } } )$ , there is a permutation $\sigma \in \mathbb { S } _ { m }$ for which $e _ { r _ { \sigma ( b ) } } = e _ { q _ { b } }$ . Therefore, $f _ { k } ^ { \prime \prime } = R _ { \sigma } ( f _ { j } ^ { \prime } )$ .
505
+
506
+ At the same time, ${ \mathfrak { n } } _ { k } ^ { \prime \prime }$ is also in correspondence with ${ \mathfrak { n } } _ { i }$ . In particular, letting $\tau = \sigma \pi$ (which corresponds to first applying the permutation $\pi$ , then applying $\sigma$ ), $e _ { r _ { \tau ( a ) } } = e _ { p _ { a } }$ , and therefore $f _ { k } ^ { \prime \prime } { = } R _ { \tau } ( f _ { i } )$ . Hence, the $\{ R _ { \pi } \}$ maps must satisfy
507
+
508
+ $$
509
+ R _ { \sigma \pi } ( f _ { i } ) = R _ { \sigma } ( f _ { j } ^ { \prime } ) = R _ { \sigma } ( R _ { \pi } ( f _ { i } ) ) ,
510
+ $$
511
+
512
+ for any $f _ { i }$ . More succinctly, $R _ { \sigma \pi } = R _ { \sigma } \circ R _ { \pi }$ for any $\pi , \sigma \in \mathbb { S } _ { m }$ . In the case that the $\{ R _ { \pi } \}$ maps are linear and represented by matrices, this reduces to $R _ { \sigma \pi } = R _ { \sigma } R _ { \pi }$ , which is equivalent to saying that they form a group representation of $\mathbb { S } _ { m }$ . 
513
+
514
+ Proof of Proposition 4. Under the action of a permutation $\pi \in \mathbb { S } _ { m }$ , $A$ and $B$ transform as
515
+
516
+ $$
517
+ \begin{array} { l l l l l l } { { A \mapsto A ^ { \prime } } } & { { \qquad } } & { { [ A ^ { \prime } ] _ { j _ { 1 } , \dots , j _ { k } } } } & { { = } } & { { [ P _ { \pi } ] _ { j _ { 1 } } j _ { 1 } ^ { \prime } [ P _ { \pi } ] _ { j _ { 2 } } ^ { \prime } \dots [ P _ { \pi } ] _ { j _ { k } } j _ { k } ^ { \prime } [ A ] _ { j _ { 1 } ^ { \prime } , \dots , j _ { k } ^ { \prime } } , } } \\ { { B \mapsto B ^ { \prime } } } & { { \qquad } } & { { [ B ^ { \prime } ] _ { j _ { 1 } , \dots , j _ { p } } } } & { { = } } & { { [ P _ { \pi } ] _ { j _ { 1 } } j _ { 1 } ^ { \prime } [ P _ { \pi } ] _ { j _ { 2 } } ^ { \prime } \dots [ { P _ { \pi } } ] _ { j _ { p } } j _ { p } ^ { \prime } [ B ] _ { j _ { 1 } ^ { \prime } , \dots , j _ { p } ^ { \prime } } . } } \end{array}
518
+ $$
519
+
520
+ Case 1. Let $C = A \otimes B$ . Under (3) and (4), $C$ transforms into
521
+
522
+ $$
523
+ \begin{array} { r l } & { [ C ^ { \prime } ] _ { i _ { 1 } , \dots , i _ { k + p } } = \left( [ P _ { \pi } ] _ { i _ { 1 } } \dotsi _ { 1 } [ P _ { \pi } ] _ { i _ { k } } ^ { i } [ A ] _ { i _ { 1 } ^ { \prime } , \dots , i _ { k } ^ { \prime } } \right) \left( [ P _ { \pi } ] _ { i _ { k + 1 } } \underset { \dots } { \overset { i _ { k } ^ { \prime } } { _ { k + 1 } } } \dotsi [ P _ { \pi } ] _ { i _ { k + p } } \ [ B ] _ { i _ { k + 1 } ^ { \prime } , \dots , i _ { k + p } ^ { \prime } } \right) } \\ & { \qquad = [ P _ { \pi } ] _ { i _ { 1 } ^ { \prime } } \dots [ P _ { \pi } ] _ { i _ { k + p } } \ C _ { i _ { 1 } ^ { \prime } , \dots , i _ { k + p } ^ { \prime } } , } \end{array}
524
+ $$
525
+
526
+ therefore, $C$ is a $k + p ^ { \mathrm { : } }$ ’th order $P -$ –tensor.
527
+
528
+ Case 2. Let $\begin{array} { r } { C = A \odot _ { ( a _ { 1 } , . . . , a _ { p } ) } B } \end{array}$ . Under (3) and (4), $C$ transforms as
529
+
530
+ $$
531
+ \begin{array} { r l } { [ C ^ { \prime } ] _ { i _ { 1 } , \dots , i _ { k } } = \left( [ P _ { \pi } ] _ { i _ { 1 } } i _ { 1 } ^ { \prime } \dots [ P _ { \pi } ] _ { i _ { k } } i _ { k } ^ { \prime } [ A ] _ { i _ { 1 } ^ { \prime } , \dots , i _ { k } ^ { \prime } } \right) \left( [ P _ { \pi } ] _ { i _ { a _ { 1 } } } i _ { 2 1 } ^ { \prime } \dots [ P _ { \pi } ] _ { i _ { a _ { p } } } ^ { \phantom { \dagger } } [ B ] _ { i _ { a _ { 1 } } ^ { \prime } , \dots , i _ { a _ { p } } ^ { \prime } } \right) = } & { } \\ { = [ P _ { \pi } ] _ { i _ { 1 } ^ { \prime } } \dots [ P _ { \pi } ] _ { i _ { k } ^ { \prime } } \dots [ P _ { \pi } ] _ { i _ { a _ { 1 } } ^ { \prime } } \dots [ P _ { \pi } ] _ { i _ { a _ { 1 } } } i _ { 2 1 } ^ { \prime } \dots [ P _ { \pi } ] _ { i _ { a _ { p } } ^ { \prime } } \dots [ C ] _ { i _ { 1 } ^ { \prime } \dots , i _ { k } ^ { \prime } } . } & { } \end{array}
532
+ $$
533
+
534
+ Note that each of the [Pπ ]iaji0aj factors in this expression repeats one of the earlier appearing $[ P _ { \pi } ] _ { i _ { 1 } } { } ^ { i _ { 1 } ^ { \prime } } , ~ . ~ . ~ . ~ , [ P _ { \pi } ] _ { i _ { k } } { } ^ { i _ { k } ^ { \prime } }$ factors, but since $P _ { \pi }$ only has zero and one entries $[ { \cal P } _ { \pi } ] _ { a , b } ^ { 2 } \ = \ [ { \cal P } _ { \pi } ] _ { a , b }$ , so these factors can be dropped. Thus, $C$ is a $k$ ’th order $P -$ –tensor.
535
+
536
+ Case 3. Let $C = A { \downarrow } _ { a _ { 1 } , \dots , a _ { p } }$ and $b _ { 1 } , \dotsc , b _ { k - p }$ be the indices (in increasing order) that are not amongst $\{ a _ { 1 } , \ldots , a _ { p } \}$ . Under (3), $C$ becomes
537
+
538
+ $$
539
+ \begin{array} { l } { { [ { \cal C } ^ { \prime } ] _ { i _ { b _ { 1 } } , \dots , i _ { b _ { k - p } } } = \displaystyle \sum _ { i _ { a _ { 1 } } } \dots \sum _ { i _ { a _ { p } } } [ P _ { \pi } ] _ { i _ { 1 } } i _ { 1 } ^ { \prime } ~ \dots ~ [ P _ { \pi } ] _ { i _ { k } } ^ { i _ { k } ^ { \prime } } ~ [ A ] _ { i _ { 1 } ^ { \prime } , \dots , i _ { k } ^ { \prime } } } } \\ { { { } } } \\ { { { } = [ P _ { \pi } ] _ { i _ { b _ { 1 } } } i _ { b _ { 1 } } ^ { \prime } ~ \dots ~ [ P _ { \pi } ] _ { i _ { b _ { k - p } } } \sum _ { i _ { a _ { 1 } } ^ { \prime } } \dots \sum _ { i _ { a _ { p } } ^ { \prime } } [ A ] _ { i _ { 1 } ^ { \prime } , \dots , i _ { k } ^ { \prime } } } } \end{array}
540
+ $$
541
+
542
+ Thus, $C$ is a $k - p$ ’th order $P -$ –tensor.
543
+
544
+ Case 4. Follows directly from 3.
545
+
546
+ Case 5. Finally, if $A _ { 1 } , . . . , A _ { u }$ are $k ^ { \mathrm { : } }$ ’th order $P -$ –tensors and $\begin{array} { r } { C = \sum _ { j } \alpha _ { j } A _ { j } } \end{array}$ then
547
+
548
+ $$
549
+ [ C ^ { \prime } ] _ { i _ { 1 } , \ldots , i _ { k } } = \sum _ { j } \alpha _ { j } [ P _ { \pi } ] _ { i _ { 1 } ^ { \prime } } \ldots [ P _ { \pi } ] _ { i _ { k } ^ { \prime } } [ A _ { j } ^ { \prime } ] _ { i _ { 1 } ^ { \prime } , \ldots , i _ { k } ^ { \prime } } = [ P _ { \pi } ] _ { i _ { 1 } ^ { \prime } } \ldots [ P _ { \pi } ] _ { i _ { k } ^ { \prime } } \sum _ { j } \alpha _ { k } [ A _ { j } ^ { \prime } ] _ { i _ { 1 } ^ { \prime } , \ldots , i _ { k } ^ { \prime } } ,
550
+ $$
551
+
552
+ so $C$ is a $k$ ’th order $P$ –tensor.
553
+
554
+ Proof of Proposition 5. Under the action of a permutation $\pi \in \mathbb { S } _ { m ^ { \prime } }$ on $\mathcal { P } _ { b } , \chi$ (dropping the $a { } b$ superscipt) transforms to $\chi ^ { \prime }$ , where $\chi _ { i , j } ^ { \prime } = \chi _ { \pi ^ { - 1 } ( i ) , j }$ . However, this can also be written as
555
+
556
+ $$
557
+ \chi _ { i , j } ^ { \prime } = [ P _ { \pi } \chi ] _ { i , j } = \sum _ { i ^ { \prime } } [ P _ { \pi } ] _ { i , i ^ { \prime } } \chi _ { i ^ { \prime } , j } .
558
+ $$
559
+
560
+ Therefore, $\widetilde { F } _ { i _ { 1 } , \dots , i _ { k } }$ transforms to
561
+
562
+ $$
563
+ \widetilde { F } _ { i _ { 1 } , \ldots , i _ { k } } ^ { \prime } = \chi _ { i _ { 1 } } ^ { \prime ~ j _ { 1 } } \chi _ { i _ { 2 } } ^ { \prime ~ j _ { 2 } } \ldots \chi _ { i _ { k } } ^ { \prime ~ j _ { k } } F _ { j _ { 1 } , \ldots , j _ { k } } = [ P _ { \pi } ] _ { i _ { 1 } } i _ { 1 } ^ { i _ { 1 } ^ { \prime } } \ldots [ P _ { \pi } ] _ { i _ { k } } i _ { k } ^ { i _ { k } ^ { \prime } } \chi _ { i _ { 1 } ^ { \prime } } ^ { \prime ~ j _ { 1 } } \chi _ { i _ { 2 } ^ { \prime } } ^ { \prime ~ j _ { 2 } } \ldots \chi _ { i _ { k } ^ { \prime } } ^ { \prime ~ j _ { k } } F _ { j _ { 1 } , \ldots , j _ { k } } ,
564
+ $$
565
+
566
+ so $\widetilde { F }$ is a $P$ –tensor.
567
+
568
+ Proof of Proposition 6. By Proposition 5, under the action of any permutation $\pi$ , each of the $\widetilde { F } _ { p _ { j } }$ slices of $\overline { F }$ transforms as
569
+
570
+ $$
571
+ [ \widetilde { F } _ { p _ { j } } ^ { \prime } ] _ { i _ { 1 } , \dots , i _ { k } } = [ P _ { \pi } ] _ { i _ { 1 } } \widetilde { \phantom { - } } _ { \dots } ^ { i _ { 1 } ^ { \prime } } \dots [ P _ { \pi } ] _ { i _ { k } } \widetilde { \phantom { - } } [ \widetilde { F } _ { p _ { j } } ^ { \prime } ] _ { i _ { 1 } , \dots , i _ { k } } .
572
+ $$
573
+
574
+ At the same time, $\pi$ also permutes the slices amongst each other according to
575
+
576
+ $$
577
+ \overline { { { F } } } _ { i _ { 1 } , \dots , i _ { k } , j } ^ { \prime } = [ \widetilde { F } _ { p _ { \pi ^ { - 1 } ( j ) } } ] _ { i _ { 1 } , \dots , i _ { k } } = \overline { { { F } } } _ { i _ { 1 } , \dots , i _ { k } , \pi ^ { - 1 } ( j ) } ^ { \prime } .
578
+ $$
579
+
580
+ Therefore
581
+
582
+ $$
583
+ \overline { { F } } _ { i _ { 1 } , \dots , i _ { k } , j } ^ { \prime } = [ P _ { \pi } ] _ { i _ { 1 } } { } ^ { i _ { 1 } ^ { \prime } } \dots [ P _ { \pi } ] _ { i _ { k } } { } ^ { i _ { k } ^ { \prime } } [ P _ { \pi } ] _ { j } ^ { j ^ { \prime } } \overline { { F } } _ { i _ { 1 } , \dots , i _ { k } , j } ,
584
+ $$
585
+
586
+ so $\overline { F }$ is a $k + 1$ ’th order $P -$ –tensor.
587
+
588
+ Proof of Proposition 7. Under any permutation $\pi \in \mathbb { S } _ { m }$ of $\mathcal { P } _ { i }$ , $A \downarrow _ { \mathcal { P } _ { i } ^ { \prime } }$ transforms to $A \downarrow _ { \mathcal { P } _ { i } ^ { \prime } }$ , where $[ A \downarrow _ { \mathcal { P } _ { i } ^ { \prime } } ] _ { \pi ( a ) , \pi ( b ) } = [ A \downarrow _ { \mathcal { P } _ { i } } ] _ { a , b }$ . Therefore, $A \downarrow _ { \mathcal { P } _ { i } }$ is a second order $P$ –tensor. By the first case of Proposition 4, $F \otimes A \downarrow _ { \mathcal { P } _ { i } }$ is then a $k + 2$ ’th order $P .$ –tensor. 
parse/train/S1TgE7WR-/S1TgE7WR-_content_list.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/S1TgE7WR-/S1TgE7WR-_middle.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/S1TgE7WR-/S1TgE7WR-_model.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/S1xxx64YwH/S1xxx64YwH.md ADDED
@@ -0,0 +1,285 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # ECOLOGICAL REINFORCEMENT LEARNING
2
+
3
+ Anonymous authors Paper under double-blind review
4
+
5
+ # ABSTRACT
6
+
7
+ Reinforcement learning algorithms have been shown to effectively learn tasks in a variety of static, deterministic, and simplistic environments, but their application to environments which are characteristic of dynamic lifelong settings encountered in the real world has been limited. Understanding the impact of specific environmental properties on the learning dynamics of reinforcement learning algorithms is important as we want to align the environments in which we develop our algorithms with the real world, and this is strongly coupled with the type of intelligence which can be learned. In this work, we study what we refer to as ecological reinforcement learning: the interaction between properties of the environment and the reinforcement learning agent. To this end, we introduce environments with characteristics that we argue better reflect natural environments: non-episodic learning, uninformative “fundamental drive” reward signals, and natural dynamics that cause the environment to change even when the agent fails to take intelligent actions. We show these factors can have a profound effect on the learning progress of reinforcement learning algorithms. Surprisingly, we find that these seemingly more challenging learning conditions can often make reinforcement learning agents learn more effectively. Through this study, we hope to shift the focus of the community towards learning in realistic, natural environments with dynamic elements.
8
+
9
+ # 1 INTRODUCTION
10
+
11
+ A central goal in current AI research, especially in reinforcement learning (RL), is to develop algorithms that are general, in the sense that the same method can be used to train an effective model for a wide variety of tasks, problems, and domains. In RL, this means designing algorithms that can solve any Markov decision process (MDP). However, natural intelligence – e.g., humans and animals – exists in the context of a natural environment. People and animals cannot be understood separately from the environments that they inhabit any more than brains can be understood separately from the bodies they control. In the same way, perhaps a complete understanding of artificial intelligence can also only be obtained in the context of an environment, or at least a set of assumptions on that environment.
12
+
13
+ There has been comparatively little study in the field of reinforcement learning to understand how properties of the environment impact the learning process for complex RL agents. Many of the environments used in modern reinforcement learning research differ in fundamental ways from the real world. First, standard RL benchmarks, such as the arcade learning environment (ALE) (Bellemare et al., 2013) and Gym (Brockman et al., 2016) are episodic, while natural environments are continual and lack a “reset” mechanism, requiring an agent to learn through continual interaction. Second, most of these environments include detailed reward functions that not only correspond to overall task success, but also provide intermediate learning signal, thus shaping the learning process. These signals can aid in learning, but they can also bias the learning process. Third, the environments are typically static, in the sense that only the agent’s own actions substantively impact the world. In contrast, natural environments are stochastic and dynamic: an agent that does nothing will still experience many different states, due to the behavior of natural processes and other creatures.
14
+
15
+ In this paper, we aim to study how these properties affect the learning process. At the core of our work is the concept of ecological reinforcement learning: the idea that the behavior and learning dynamics of an agent, like that of an animal, must be understood in the context of the environment in which it is situated. We therefore study how particular properties of the environment can facilitate or harm the emergence of complex behaviors. We focus our attention on the three properties outlined above: (1) continual, non-episodic environments where the agent must learn over the course of one “lifetime,” (2) environments that lack detailed reward shaping, but instead provides a reward signal based on a simple “fundamental drive,” (3) environments that are inherently dynamic, evolving on their own around the agent even if the agent does not take meaningful or useful actions. We study how each of these properties affects the learning process. Although on the surface these properties would seem to make the learning process harder, we observe that in some cases, they can actually make reinforcement learning easier.
16
+
17
+ ![](images/03b0179dec31be1505bc07b040d399247bfbc699801aeb21bcdd26643d86d28b.jpg)
18
+ Figure 1: We study three properties of realistic environments that can have a large effect on the difficulty of reinforcement learning: (left) non-episodic learning, where the agent is not reset automatically to the same initial state distribution, but must handle whatever situation it puts itself in; (middle) environment shaping as an alternative to reward shaping, where the agent has a single, sparse reward, but the environment is varied so as to provide a curriculum (e.g., due to its natural dynamics, or by a cooperative teacher agent); (right) dynamic environments, where the environment changes due to the actions of other agents and natural phenomena, even if the agent does not take a coordinated course of action – such dynamic phenomena can, as we will show, alleviate some of the difficulties in non-episodic learning.
19
+
20
+ The degree to which these properties make learning easier is highly dependent on the degree of scaffolding that is provided by an environment. For example, an agent tasked with collecting and making food pellets might struggle to learn if it must first complete a complex sequence of actions. However, if food pellets are initially plentiful, the agent can first learn that food pellets are rewarding, and then gradually learn to make them out of raw ingredients as the initial supply becomes scarce. This provides a natural scaffolding and curriculum without requiring manual reward engineering. More generally, “environment shaping” can be used as a way to craft the agent’s curriculum without modifying its reward function. This benefit is counter-balanced by the fact that non-episodic learning is inherently harder – the resets in episodic tasks provide a more stationary learning problem, preventing the agent from getting “stuck” due to a bad initial policy. However, natural environments can also counteract this difficulty: a dynamic environment that gradually changes on its own can provide a sort of “soft” reset that can mitigate the difficulties of reset-free learning, and we observe this empirically in our experiments. We illustrate some of these ideas in Figure 1.
21
+
22
+ The contribution of this work is an empirical study of how the properties of environments – particularly properties that we believe reflect realistic environments – impact reinforcement learning. We study the effect of (1) continual, non-episodic learning, (2) learning with and without reward shaping, and (3) learning in dynamic environments that evolve on their own. We find that, though each of these properties can make learning harder, they can also be combined in realistic ways to actually make learning easier. We also provide an open-source environment for future experiments studying “ecological” reinforcement learning, and we hope that our experimental conclusions will encourage future research that studies how the nature of the environment in which the RL agent is situated can facilitate learning and the emergence of complex skills. This exercise helps us determine which types of algorithmic challenges we should focus our development efforts towards in order to solve natural environments that agents might encounter.
23
+
24
+ # 2 RELATED WORK
25
+
26
+ Solving general RL problems can be extremely hard in general (Kakade & Langford, 2002). Reward shaping is a common technique to guide learning $\mathrm { N g }$ et al., 1999; Devlin & Kudenko, 2012; Brys et al., 2015) but is usually hand crafted and must be carefully designed by human experts (Griffith et al., 2013). Shaping the reward may also lead to suboptimal solutions, as it alters the objective of the learning problem. Curriculum learning can be used to first provide the agent with easier tasks, followed by more challenging tasks (Bengio et al., 2009; Graves et al., 2017; Randløv & Alstrøm, 1998; Wang et al., $2 0 1 9 \mathrm { a }$ ; Yu et al., 2018; Heess et al., 2017). Curriculum learning can also be viewed in the context of multiple learning agents in an adversarial or cooperative setting (Silver et al., 2016; Al-Shedivat et al., 2017; Sukhbaatar et al., 2017; Omidshafiei et al., 2018) or where the curriculum is automatically generated (Florensa et al., 2017b;a; Riedmiller et al., 2018; Wang et al., 2019b). The “environment shaping” that we study in our experiments can be viewed as a kind of curriculum learning, and we argue – and show empirically – that this environment shaping approach can in some cases be more effective than more commonly used reward shaping.
27
+
28
+ Improved exploration methods are a possible solution to solving sparse reward tasks. Prior work has used approximate state-visitation counts (Tang et al., 2016; Bellemare et al., 2013), information gain, or prediction error (Houthooft et al., 2016; Pathak et al., 2017), or model ensemble uncertainty (Osband et al., 2016). A recent work (Ecoffet et al., 2019) maintains a set of novel states and first returns to the novel states before exploring from this frontier. Our work could be combined with an exploration method, however, this work indicates that sparse reward tasks can be solved with an appropriately shaped environment.
29
+
30
+ Prior work on RL without resets has focused on safe exploration (Moldovan & Abbeel, 2012; Chatzilygeroudis et al., 2018) or learning a policy to reset the environment (Eysenbach et al., 2017; Han et al., 2015). Even-Dar et al. (2005) studies reset free RL in POMDPs and implements a homing strategy which approximately resets the agent. Rather than trying to convert the reset-free problem to one that looks more like a scenario with resets, our experiments study under which conditions reset-free learning can actually be easier, and show that dynamic environments – which we argue better reflect the real world – actually make learning without resets easier.
31
+
32
+ Learning in non-episodic settings has been studied from the perspective of continual learning Ring (1997), where a number of tasks are learned in sequence. These algorithms typically consider the problem of “catastrophic forgetting” (Mccloskey, 1989; French, 1999), where previously learned tasks are forgotten while learning new tasks. To solve this problem, algorithms use methods such as explicit memorization (Rusu et al., 2016; Schwarz et al., 2018), generative replay (Shin et al., 2017) and explicit weight regularization (Kirkpatrick et al., 2016; Kaplanis et al., 2018). These works assume that resets and task boundaries are available whereas we assume that the agent is unable to reset. There has also been work on building more complex tasks in large diverse worlds with Mujoco (Todorov et al., 2012; Singh et al., 2019; Yu et al., 2019), Malmo (Johnson et al., 2016; Guss et al., 2019), DeepMind Lab (Beattie et al., 2016), and many others, however, again, these environments are studied in the context of episodic-learning.
33
+
34
+ # 3 PROPERTIES OF NATURAL ENVIRONMENTS
35
+
36
+ In contrast to most simulated environments that are used for reinforcement learning experiments (Brockman et al., 2016), agents learning in natural environments experience a continual stream of experience, without episode boundaries. The typical reward function engineering that is often employed in reinforcement learning experiments is also generally unavailable in the real world, where agents must rely on their own low-level perception to understand the world. Finally, natural environments change on their own, even when the agent does not follow a coordinated or intelligent course of action. This dynamism can create additional challenges, but can also facilitate learning, mitigating some of the issues due to non-episodic and non-resettable learning settings. In this paper, our aim is to study how these aspects of the environment impact the performance of reinforcement learning agents. We term this approach ecological reinforcement learning, in that it deals specifically with the relationship between properties of the environment and the reinforcement learning agent, rather than studying reinforcement learning algorithms in the general case, regardless of the particular properties of the learning environment. We believe that the properties outlined above are broadly reflected in real-world settings, and are often absent in simulated reinforcement learning benchmarks. In this section, we discuss each of these properties, and formulate our hypotheses about how these properties might influence learning.
37
+
38
+ Continual non-episodic learning. In the real world, all learning must at some level be nonepisodic: though we may instrument environments to make them appear episodic, there is always a single underlying temporal process. In general, this makes the learning problem harder: when the agent is not reset to randomly chosen initial states, mistakes early on in training can put it into undesirable situations, from which it might be harder to recover and – more importantly – harder to learn. A non-episodic learning process is non-stationary, and the agent can become trapped in difficult regions of the state space.
39
+
40
+ Hypothesis 1: Non-episodic learning is more difficult than episodic learning because the agent must handle a non-stationary learning problem, and can become trapped in difficult states. We will study this hypothesis in our experiments, and show how some of the other properties of natural environments can help alleviate this difficulty.
41
+
42
+ Sparse rewards and environment shaping. While in principle RL algorithms can handle relatively uninformative rewards, in practice reward shaping is often an essential tool for getting RL methods to acquire effective policies. For example, an agent that must learn a policy to collect resources to make an axe (see Figure 2) might make use of a reward function that specifies the distance to the nearest resource, or at least provides a small reward for each resource obtained, as opposed to a reward given only for obtaining the final goal. However, well-shaped rewards are generally not available and difficult to provide in the real world, since they require knowledge of privileged state variables (e.g., positions of objects) or the process by which the task must be completed (e.g., required resources), both of which should in principle be learned automatically by the agent. Furthermore, reward shaping might introduce bias, since the optimal policy for a shaped reward may not in fact be optimal for the original task reward. On the other hand, agents in the real world do not learn in a vacuum: even for humans and animals, it is reasonable to assume a reasonably cooperative environment that has been set up so as to facilitate learning. For humans, this kind of “scaffolding” is often provided by other agents (e.g., parents and teachers). But even without other agents, natural environments might provide automatic scaffolding – e.g., an animal might find apples that fell from a tree, and thereby learn that apples are a source of food. Once the fallen apples are exhausted, the animal might use its knowledge of the value of apples to learn to climb the tree to obtain the apples on its own. This kind of “environment shaping” could serve as a tool for guiding the learning process, without the bias or manual engineering inherent in reward shaping.
43
+
44
+ Hypothesis 2: Environment shaping can enable agents to learn even with simple sparse rewards, and can in fact result in more proficient policies if applied correctly, as opposed to reward shaping.
45
+
46
+ Dynamic environments. Standard reinforcement learning benchmark tasks are typically situated in static environments (Brockman et al., 2016; Bellemare et al., 2013), in the sense that the environment does not change substantially unless the agent takes a coordinated course of action. On the other hand, real-world settings are typically dynamic, in the sense that the environment changes even if the agent does not follow any coordinated course of action: animals will move around, times of day will change, seasons will change, etc. Dynamic environments present their own challenges, but they can also facilitate learning, by automatically exposing the agent to a wide variety of situations.
47
+
48
+ Hypothesis 3: While dynamic environments could make learning more difficult, in fact they can alleviate some of the challenges associated with non-episodic learning, by providing the agent with a variety of learning conditions even in the absence of coordinated and intelligent behavior (as is the case, e.g., early on in training).
49
+
50
+ # 4 EXPERIMENTAL SETUP
51
+
52
+ To carry out our ecological RL study, we construct three simulated tasks. The simulator for two of them is built on top of the grid-like environment proposed by Chevalier-Boisvert et al. (2018). We chose a grid-based discrete-action environment over a more complex, high-dimensional one to study the aforementioned properties in isolation, without other confounding factors involving highdimensional observations and representation learning. The goal is not to simulate a completely visually realistic and life-like system, but to study those properties of the MDP that will be particularly important in natural environments, and have not been addressed in detail in prior work.
53
+
54
+ The environment is an $N \times N$ grid of tiles, where each tile contains at most one object, but the agent is free to move over any tile and can pick up and carry one object at a time. The agent can use objects in its environment to construct new ones by dropping a carried object onto an existing object. Objects include wood, metal, deer, axe, and food. The agent can combine wood with metal to construct an axe and apply the axe to a deer to produce food. The agent consumes resources such as food by picking them up. There are movement actions associated with each of the cardinal directions, as well as to pick up or drop an object. The environment is partially observed, and the agent receives a local egocentric view around it, represented by the shaded region in Figure 2, which is a $5 \times 5 \times C$ grid, where $C$ is the number of object types, and each grid position contains a one-hot vector representation of the object type. We use the following two tasks in our evaluation, which are illustrated in Figure 2:
55
+
56
+ ![](images/851f30e059be396a7c250cb4546b2faf89727a9fa36f95820145a7594a566770.jpg)
57
+ Figure 2: Tasks in our partially observed stochastic environment for crafting an axe (left) and hunting a deer (middle). The agent (purple triangle) receives a local observation (shaded gray square) and must interact with objects in the correct sequences to complete the task. In the food collection task in Unity (right), the agent’s goal is to collect green food and avoid red poison.
58
+
59
+ Tool-making: The agent must combine wood and metal to craft an axe, and then pick up the axe. Wood and metal appear at random locations initially, and continue to spawn with some probability as time progresses in the dynamic setting.
60
+
61
+ Hunting: The agent uses an axe to hunt a deer, which produces food that it can pick up to eat. Axes and deer appear at random locations. The deer can move around in the environment in the dynamic setting, and can appear at different distances from the agent.
62
+
63
+ In order to study our hypotheses in varied settings, we additionally investigate these environmental properties, enumerated at the end of this section, in the context of the Food Collector environment available as part of the Unity ML-Agents toolkit provided by Juliani et al. (2018). The environment features a continuous state space with raycast partial observations representing the directional view of the agent. The action space is 27-dimensional, with separate action streams corresponding to forward, lateral, and rotational movement. The task is taken as-is, wherein the agent must maximize the number of healthy food items eaten (represented by green spheres) while avoiding consuming poisonous food (red sphere). We modify the environment dynamics and initial conditions within this task setting to investigate our hypotheses.
64
+
65
+ To study the hypotheses discussed in the previous section, we vary a number of properties of these environments, and examine their effect on the learning process:
66
+
67
+ Non-episodic learning. The non-episodic version of each task does not allow the agent to reset to the initial state, and instead requires it to learn the task effectively over one very long episode, as illustrated in the figure on the right. For example, in the Unity Food Collector task, the agent must learn to continually collect as many healthy food items as possible while avoiding the poisonous food across its lifetime. We will compare this against the episodic case, where the agent is reset to an initial state distribution after completing the task or after a fixed time horizon. This will allow us to study hypothesis $H l$ .
68
+
69
+ ![](images/66d6015d129a90f30b572326f81d0d85664dda57c68e5a10b91ccf41eea1d2f6.jpg)
70
+
71
+ Reward shaping. Reward shaping is often used to assist the agent in finding a good policy by providing more signal to the agent. The environment allows us to experiment with different reward functions, such as a shaped distance-based reward function that rewards the agent for how close it is to the nearest resource it needs, and a larger bonus for interacting with the right object. A sparse reward function will b based on a simple “fundamental drive:” whether or not the agent has just acquired the axe (in th tool-making task), deer (hunting), or food (food collector).
72
+
73
+ ![](images/e8be49462fb9af660e8f7942b2e28f64b948ed3c1ad8532352adf8296771af09.jpg)
74
+
75
+ Environment shaping. Instead of shaping rewards, which can be unrealistic and can bias the learning process, we can instead change the types and distribution of states the agent observes while learning. In our tasks, we can scaffold the learning process by controlling the maximum distance from the agent at which the resources (wood, metal, deer, and food) can appear. We can gradually increase this distance as the learning progresses, as illustrated the figure on the right, which shows the deer appearing progressively further away during training, thus inducing a curriculum. This type of environment shaping can remove the need for reward shaping, and potentially alleviates its shortcomings. We will use this setting to study hypothesis $H 2$ .
76
+
77
+ Dynamic vs. static environments. We can construct dynamic versions of both of our tasks by varying the probability that the environment changes at any given time, regardless of the agent’s actions. This captures the fact that natural environments will change on their own, regardless of what the agent does: other animals will move around, weather will change, etc. In both grid domains, we define a continuous spectrum of dynamic effects, in terms of a dynamic event probability. In the tool-making task, the dynamic effect probability $p$ controls the resource generation, determining the probability that a resource will spawn in empty squares no less than two squares away from the agent at each time step. To keep the expected quantity of resources constant throughout the trajectory we allow resources to decay (disappear) after a lifespan of $\frac { I } { p }$ timesteps, where $I$ is the number of instances of this resource that appear in the initial environment. In the hunting task, the dynamic effect probability $p$ is the probability that a deer will move to a random adjacent square on each time step, as illustrated in the figure above. The static version of these environments will have $p = 0$ , such that resources are in fixed positions and only respawn as needed when the agent completes the task, and deer do not move. In the Unity Food Collector environment, the dynamic property is given by the speed at which both healthy and poisonous food move, which was tested across the range of $v = 0$ to $v = 1 6$ , corresponding to the velocities set for the food objects in the Unity engine. The static setting here corresponds to stationary food. By studying dynamic and static environments in episodic and non-episodic settings, we can analyze hypothesis $H 3$ .
78
+
79
+ ![](images/5e33e9c6293a07bee59285c53718ccffc8cb1bfc8c2d25b61290025efc3d3ccd.jpg)
80
+
81
+ In order to compare agents trained under the different environment conditions, we must construct a single consistent evaluation protocol. We use the same agent network architecture and RL algorithm for all experiments, with details provided in Appendix A. We evaluate all agents on a set of validation tasks that are chosen to be as close as possible to the “standard” RL setting, which is episodic and static. We generate 100 validation tasks by randomly generating environments with varying initial resource and agent locations. Performance is measured by the proportion of validation tasks solved. We first study non-episodic learning and dynamic vs. static environments by varying these training settings with sparse reward and no environment shaping. We will then study reward shaping and environment shaping in the dynamic non-episodic setting. The training settings are:
82
+
83
+ Static episodic: In this setting, $p$ is set to 0 so positions of the resources will be static unless the agent moves them. When the agent finishes the task, the environment is reset to a random initial configuration. The environment is also reset when the episode length reaches 200.
84
+
85
+ Static non-episodic: Here, $p = 0$ and there are no resets. When the agent has used up the available resources, more resources are generated randomly.
86
+
87
+ Dynamic non-episodic: This setting explores the lifelong case with a changing environment, where the dynamic property $p$ is varied between 0 and 1. For tool-making, $p$ is the probability of resources spawning at each timestep in a random location. There is initially two of each type of resource. This environment is lifelong and does not reset when the agent completes the task.
88
+
89
+ Dynamic episodic: This is the same as the dynamic non-episodic version except that the environment is reset to a random initial configuration when the agent completes the task.
90
+
91
+ # 5 EXPERIMENTAL RESULTS
92
+
93
+ To study the hypotheses in Section 3, we perform experiments where we train RL agents on the tasks described above and vary different properties of the environment during training.
94
+
95
+ # 5.1 NON-EPISODIC LEARNING IN DYNAMIC AND STATIC ENVIRONMENTS
96
+
97
+ In the real world, environments are generally dynamic and non-episodic, meaning that the agent is never reset to an initial state distribution, and many parts of the environment are changing without the agent’s intervention. In this section we study the effects of both a dynamic, changing environment and the ability to reset on the learning agent, corresponding to hypotheses $H l$ and $H 3$ . These settings will use sparse reward and no environment shaping.
98
+
99
+ ![](images/9e64ce211a9f989420a7c3b3d8508323116658264d9d1bfe128fb4b42af85412.jpg)
100
+ Figure 3: Proportion of validation tasks solved in each setting. Agents learning in static non-episodic environments struggle to learn useful behaviors, while agents learning in dynamic non-episodic environments are substantially more successful. Episodic learning is easier than non-episodic learning on the first task, but non-episodic learning in dynamic environments is almost as effective as episodic learning on the hunting task.
101
+
102
+ Effect of resets on learning. In regard to $H l$ , we find that learning tasks in static, reset-free, nonepisodic environments is difficult. In Figure 3, we compare the performance of the agent trained in each of the four conditions. Recall that all evaluations are conducted in the same setting, with resets and static environments, regardless of how the agent is actually trained. For the tool-making task, we observe that removing resets makes learning more difficult in the typical static case. The agent trained in a static environment without resets obtains the lowest performance $0 \%$ evaluation tasks solved). Adding in resets to the static case helps with performance $( 1 2 \% )$ . In the static environment, we observe that the agent frequently becomes stuck in corners of the map or in areas with no resources.
103
+
104
+ The results indicate that disabling resets makes the standard static learning condition substantially harder. Indeed, the static no reset agent is unable to learn effectively for either task, even though the static episodic agent does learn the task to a moderate proficiency. However, making the environment dynamic substantially improves performance, in both the episodic and non-episodic setting, as shown in Figure 3. These results suggest that dynamic environments to a large extent alleviate the challenges associated with non-episodic learning, confirming hypothesis $H 3$ . The lesson that we might draw from this is that, although individual properties of natural environments (such as non-episodic learning) can make the learning process harder, combining these properties (i.e., as in the non-episodic dynamic setting) can actually alleviate these challenges, since the dynamics of the environment naturally cause the agent to experience a variety of different situations, even before it has learned to take meaningful and coordinated actions.
105
+
106
+ Dynamic environments and non-episodic learning. We conclude that, when resets are not available, dynamic environments can also help with non-episodic RL. In this section, we study how the frequency of dynamic effects impacts learning. In Figure 3, we can see that making the environment more dynamic increases performance to $7 0 \%$ , compared to the static non-episodic case $( 0 \% )$ . Having both a dynamic environment and resets achieves the highest performance $( 9 5 \% )$ , indicating that both are helpful on their own. However, an environment that is too dynamic hinders performance, as we observe in Figure 4, where a dynamic effect probability of 0.5 performs worse than 0.1. This implies that environment dynamics represent a tradeoff: the environment should be stable enough for the agent to learn meaningful behavior, but dynamic enough to present interesting situations. This in some sense resembles the tradeoff typically encountered with exploration constants, e.g. in $\epsilon$ -greedy exploration. From this experiment, we can conclude that, although $H 3$ is generally true, the particular choice of environment settings can greatly impact learning performance. To understand this better, we analyze and compare the effect of “environment shaping,” as defined in Section 4, in the following subsection.
107
+
108
+ ![](images/ce2d75d532b6a31167f4909ade1a8830c40e4f93eb9ceafc27133e08559ea894.jpg)
109
+ Figure 4: Proportion of validation tasks solved as the dynamic effect probability (i.e., resource probability and deer movement probability) is varied in the non-episodic setting. For all tasks, the standard static environment does not allow for effective learning, but a number of dynamic environment variants allow the agent to learn the task successfully. Evaluation is still carried out in a static environment.
110
+
111
+ # 5.2 REWARD SHAPING AND ENVIRONMENT SHAPING
112
+
113
+ Next, we study how reward shaping and environment shaping compare in terms of their capacity to assist learning in reset-free environments, to study hypothesis $H 2$ . We perform experiments where we train RL agents on the same tool-making task, in the non-episodic case. We compare shaping the environment during training to shaping the reward function during training. The training environments have one of each resource, spawning at locations sampled uniformly over the world every 20 timesteps which is a much more difficult setting than the ones used in the previous section. We evaluate a range of reward and environment shaping conditions. For all methods the agent is given a reward of 100 each time it completes the task. Resource interaction means picked up a required resource resource. The methods are:
114
+
115
+ No shaping with sparse reward: Resources spawn uniformly and the agent receives task completion reward.
116
+
117
+ Distance reward shaping: The agent is provided with a dense distance-based reward which grants $( - 0 . 0 1 *$ distance to nearest required resource) and (1) for resource interaction.
118
+
119
+ One-time reward shaping: This is less dense than the distance based reward. The agent is given reward (1) for resource interaction and $- 1 0 0$ for dropping the resource. This resource reward is only granted the first time and resets every time the task is completed.
120
+
121
+ Environment shaping with subgoal reward: We design a simple shaping method that gradually increases the distance away from the agent at which resources spawn. This distances increases linearly until the resources are placed uniformly over the grid world, as in the shaped reward version. We tried various schedules and found a schedule that starts at a distance of 2 and increases by 1 every 1e5 environment steps to work well. The subgoal reward is simpler than the one-time reward. The agent is given reward (1) for resource interaction. This reward does not keep track of previous object interactions and grants the bonus multiple times.
122
+
123
+ Environment shaping with sparse reward: We shape the environment as in the previous method but only use the task reward.
124
+
125
+ Environment shaping can replace reward shaping. We compare performance of these methods in Figure 5 for both the episodic and non-episodic case. We find that, even in the episodic case, environment shaping works well and outperforms reward shaping in the long run. Improper reward shaping can alter the optimal policy, thereby biasing learning and resulting in a solution that is worse
126
+
127
+ ![](images/0efdf540d052076509be282730b717372725807a3f1a3c313bfe633e86530f6a.jpg)
128
+ Figure 5: Proportion of validation tasks solved for environment shaping with sparse reward, subgoal reward, and different forms of reward shaping. We see that environment shaping can obtain better final performance than reward shaping.
129
+
130
+ with respect to the desired performance measure, which typically corresponds to the sparse reward.
131
+ These behaviors are shown in Appendix D.
132
+
133
+ Interestingly, we find that environment shaping works better for the more difficult task of Hunting. As task complexity grows, so does the difficulty of constructing an unbiased shaped reward for the tasks. In this case, environment shaping benefits from its ease of use and general applicability to various tasks. Further experiments on a harder environment are detailed in Appendix C.
134
+
135
+ Human guided environment shaping. In the real world, environment shaping can be done by doing what we already do for other human learners (e.g., children and pupils in school): arranging the environment to be conducive to learning. We also conducted a study of this setting, by having an actual human user interactively specify how the environment should be altered to facilitate the agent’s learning process. In this case, the human user was able to provide an environment shaping schedule that outperformed the one we specified manually. Full results for this experiment are provided in Appendix B. These results suggest that environment shaping is not only effective, but is also readily intuitive for a human user to specify interactively, suggesting that it can be a viable way to provide guidance to reinforcement learning agents and may be intuitive to specify, in comparison with reward shaping, which can at times be difficult and counter-intuitive.
136
+
137
+ # 5.3 EXPERIMENTAL CONCLUSIONS
138
+
139
+ Our experiments confirm hypothesis $H l$ by showing that non-episodic is indeed substantially harder than episodic learning in standard static environments. However, our experiments also show that, for all considered tasks, introducing dynamic effects can allow non-episodic learning to succeed, in some cases to a degree that is comparable to the episodic setting, confirming hypothesis $H 3$ . However, this result is sensitive to the degree of stochasticity, suggesting that the specific dynamics and design of the environment has a large impact on learning. Based on this conclusion, we study how shaping the environment influences the learning process, and conclude that appropriate environment shaping can, in our tasks, supplant the need for more traditional reward shaping, confirming hypothesis $H 2$ . We further show the human users can effectively select environment shaping schedules manually, suggesting that this is an intuitive way to guide the learning of reinforcement learning agents. Our conclusions support the notion that ecological reinforcement learning – the study of the interaction between an RL agent and its environment – is an important topic for further study.
140
+
141
+ # 6 DISCUSSION
142
+
143
+ We study how certain properties of natural environments – namely, non-episodic learning without resets, simple “fundamental drive” reward functions, and dynamic environments that evolve on their own even when the agent does not actively intervene – affect the reinforcement learning process. We use the term ecological reinforcement learning to refer to this sort of study, which aims to analyze interactions between RL agents and the environment in which learning occurs. Although these properties by themselves tend to make learning harder, we find that environments that exhibit several of these traits can actually be easier to learn in, and agents trained in such settings can actually outperform agents trained in more conventional episodic settings on the same evaluation tasks. We conclude that in dynamic environments, the variability of situations created by the environment’s dynamics and simple rewards that are difficult for the agent to exploit can create a kind of natural curriculum that guides an agent through the emergence of increasingly complex behaviors.
144
+
145
+ Aside from these potentially surprising observations, the framework of ecological reinforcement learning also points to a new way to approach the design of RL agents. While reward function design is typically considered the primary modality for specifying tasks to RL agents, ecological reinforcement learning suggests that the form and structure of the environment can help to guide the emergence and specification of skills. Combined with the guidance and curricula afforded by natural environments, this suggests that studying and systematizing the interaction between RL agents and various environment properties is an important and interesting direction for future research.
146
+
147
+ # REFERENCES
148
+
149
+ Maruan Al-Shedivat, Trapit Bansal, Yura Burda, Ilya Sutskever, Igor Mordatch, and Pieter Abbeel. Continuous adaptation via meta-learning in nonstationary and competitive environments. ArXiv, abs/1710.03641, 2017.
150
+
151
+ Charles Beattie, Joel Z. Leibo, Denis Teplyashin, Tom Ward, Marcus Wainwright, Heinrich Kuttler, ¨ Andrew Lefrancq, Simon Green, V´ıctor Valdes, Amir Sadik, Julian Schrittwieser, Keith Ander- ´ son, Sarah York, Max Cant, Adam Cain, Adrian Bolton, Stephen Gaffney, Helen King, Demis Hassabis, Shane Legg, and Stig Petersen. Deepmind lab. CoRR, abs/1612.03801, 2016. URL http://arxiv.org/abs/1612.03801.
152
+
153
+ Marc G. Bellemare, Yavar Naddaf, Joel Veness, and Michael H. Bowling. The arcade learning environment: An evaluation platform for general agents. In J. Artif. Intell. Res., 2013.
154
+
155
+ Yoshua Bengio, Jer´ ome Louradour, Ronan Collobert, and Jason Weston. Curriculum learning. In ˆ ICML, 2009.
156
+
157
+ Greg Brockman, Vicki Cheung, Ludwig Pettersson, Jonas Schneider, John Schulman, Jie Tang, and Wojciech Zaremba. Openai gym. ArXiv, abs/1606.01540, 2016.
158
+
159
+ Tim Brys, Anna Harutyunyan, Halit Bener Suay, Sonia Chernova, Matthew E. Taylor, and Ann Nowe. Reinforcement learning from demonstration through shaping. In ´ IJCAI, 2015.
160
+
161
+ Konstantinos Chatzilygeroudis, Vassilis Vassiliades, and Jean-Baptiste Mouret. Reset-free trialand-error learning for robot damage recovery. Robotics and Autonomous Systems, 100:236–250, 2018.
162
+
163
+ Maxime Chevalier-Boisvert, Lucas Willems, and Suman Pal. Minimalistic gridworld environment for openai gym. https://github.com/maximecb/gym-minigrid, 2018.
164
+
165
+ Sam Devlin and Daniel Kudenko. Dynamic potential-based reward shaping. In AAMAS, 2012.
166
+
167
+ Adrien Ecoffet, Joost Huizinga, Joel Lehman, Kenneth O. Stanley, and Jeff Clune. Go-explore: a new approach for hard-exploration problems. ArXiv, abs/1901.10995, 2019.
168
+
169
+ Eyal Even-Dar, Sham M. Kakade, and Yishay Mansour. Reinforcement learning in pomdps without resets. In IJCAI, 2005.
170
+
171
+ Benjamin Eysenbach, Shixiang Gu, Julian Ibarz, and Sergey Levine. Leave no trace: Learning to reset for safe and autonomous reinforcement learning. ArXiv, abs/1711.06782, 2017.
172
+
173
+ Carlos Florensa, David Held, Xinyang Geng, and Pieter Abbeel. Automatic goal generation for reinforcement learning agents. ArXiv, abs/1705.06366, 2017a.
174
+
175
+ Carlos Florensa, David Held, Markus Wulfmeier, Michael Zhang, and Pieter Abbeel. Reverse curriculum generation for reinforcement learning. In CoRL, 2017b.
176
+
177
+ Robert M French. Catastrophic forgetting in connectionist networks. Trends in cognitive sciences, 3(4):128–135, 1999.
178
+
179
+ Alex Graves, Marc G. Bellemare, Jacob Menick, Remi Munos, and Koray Kavukcuoglu. Automated ´ curriculum learning for neural networks. In ICML, 2017.
180
+
181
+ Shane Griffith, Kaushik Subramanian, Jonathan Scholz, Charles Lee Isbell, and Andrea Lockerd Thomaz. Policy shaping: Integrating human feedback with reinforcement learning. In NIPS, 2013.
182
+
183
+ William H. Guss, Cayden Codel, Katja Hofmann, Brandon Houghton, Noboru Kuno, Stephanie Milani, Sharada Mohanty, Diego Perez Liebana, Ruslan Salakhutdinov, Nicholay Topin, et al. The MineRL competition on sample efficient reinforcement learning using human priors. NeurIPS Competition Track, 2019.
184
+
185
+ Weiqiao Han, Sergey Levine, and Pieter Abbeel. Learning compound multi-step controllers under unknown dynamics. 2015 IEEE/RSJ International Conference on Intelligent Robots and Systems (IROS), pp. 6435–6442, 2015.
186
+
187
+ Nicolas Manfred Otto Heess, TB Dhruva, Srinivasan Sriram, Jay Lemmon, Josh Merel, Greg Wayne, Yuval Tassa, Tom Erez, Ziyu Wang, S. M. Ali Eslami, Martin A. Riedmiller, and David Silver. Emergence of locomotion behaviours in rich environments. ArXiv, abs/1707.02286, 2017.
188
+
189
+ Rein Houthooft, Xi Chen, Yan Duan, John Schulman, Filip De Turck, and Pieter Abbeel. Vime: Variational information maximizing exploration. In NIPS, 2016.
190
+
191
+ Matthew Johnson, Katja Hofmann, Tim Hutton, and David Bignell. The malmo platform for artificial intelligence experimentation. In Proceedings of the Twenty-Fifth International Joint Conference on Artificial Intelligence, IJCAI, 2016.
192
+
193
+ Arthur Juliani, Vincent-Pierre Berges, Esh Vckay, Yuan Gao, Hunter Henry, Marwan Mattar, and Danny Lange. Unity: A general platform for intelligent agents, 2018.
194
+
195
+ Sham M. Kakade and John Langford. Approximately optimal approximate reinforcement learning. In ICML, 2002.
196
+
197
+ Christos Kaplanis, Murray Shanahan, and Claudia Clopath. Continual reinforcement learning with complex synapses. ICML, abs/1802.07239, 2018.
198
+
199
+ Diederik P. Kingma and Jimmy Ba. Adam: A method for stochastic optimization. CoRR, abs/1412.6980, 2014.
200
+
201
+ James Kirkpatrick, Razvan Pascanu, Neil C. Rabinowitz, Joel Veness, Guillaume Desjardins, Andrei A. Rusu, Kieran Milan, John Quan, Tiago Ramalho, Agnieszka Grabska-Barwinska, Demis Hassabis, Claudia Clopath, Dharshan Kumaran, and Raia Hadsell. Overcoming catastrophic forgetting in neural networks. CoRR, abs/1612.00796, 2016.
202
+
203
+ M. Mccloskey. Catastrophic interference in connectionist networks: The sequential learning problem” the psychology. 1989.
204
+
205
+ Teodor Mihai Moldovan and Pieter Abbeel. Safe exploration in markov decision processes. ArXiv, abs/1205.4810, 2012.
206
+
207
+ Andrew Y. $\mathrm { N g }$ , Daishi Harada, and Stuart J. Russell. Policy invariance under reward transformations: Theory and application to reward shaping. In ICML, 1999.
208
+
209
+ Shayegan Omidshafiei, Dong-Ki Kim, Miao Liu, Gerald Tesauro, Matthew Riemer, Christopher Amato, Murray Campbell, and Jonathan P. How. Learning to teach in cooperative multiagent reinforcement learning. In AAAI, 2018.
210
+
211
+ Ian Osband, Charles Blundell, Alexander Pritzel, and Benjamin Van Roy. Deep exploration via bootstrapped dqn. In NIPS, 2016.
212
+
213
+ Deepak Pathak, Pulkit Agrawal, Alexei A. Efros, and Trevor Darrell. Curiosity-driven exploration by self-supervised prediction. 2017 IEEE Conference on Computer Vision and Pattern Recognition Workshops (CVPRW), pp. 488–489, 2017.
214
+
215
+ Jette Randløv and Preben Alstrøm. Learning to drive a bicycle using reinforcement learning and shaping. In ICML, 1998.
216
+
217
+ Martin A. Riedmiller, Roland Hafner, Thomas Lampe, Michael Neunert, Jonas Degrave, Tom Van de Wiele, Volodymyr Mnih, Nicolas Manfred Otto Heess, and Jost Tobias Springenberg. Learning by playing solving sparse reward tasks from scratch. In ICML, 2018.
218
+
219
+ Mark B. Ring. Child: A first step towards continual learning. In Machine Learning, pp. 77–104, 1997.
220
+
221
+ Andrei A. Rusu, Neil C. Rabinowitz, Guillaume Desjardins, Hubert Soyer, James Kirkpatrick, Koray Kavukcuoglu, Razvan Pascanu, and Raia Hadsell. Progressive neural networks. ArXiv, abs/1606.04671, 2016.
222
+
223
+ Jonathan Schwarz, Jelena Luketina, Wojciech Marian Czarnecki, Agnieszka Grabska-Barwiska, Yee Whye Teh, Razvan Pascanu, and Raia Hadsell. Progress & compress: A scalable framework for continual learning. ArXiv, abs/1805.06370, 2018.
224
+
225
+ Hanul Shin, Jung Kwon Lee, Jaehong Kim, and Jiwon Kim. Continual learning with deep generative replay. In NeurNIPS, 2017.
226
+
227
+ David Silver, Aja Huang, Chris J. Maddison, Arthur Guez, Laurent Sifre, George van den Driessche, Julian Schrittwieser, Ioannis Antonoglou, Vedavyas Panneershelvam, Marc Lanctot, Sander Dieleman, Dominik Grewe, John Nham, Nal Kalchbrenner, Ilya Sutskever, Timothy P. Lillicrap, Madeleine Leach, Koray Kavukcuoglu, Thore Graepel, and Demis Hassabis. Mastering the game of go with deep neural networks and tree search. Nature, 529:484–489, 2016.
228
+
229
+ Avi Singh, Larry Yang, Kristian Hartikainen, Chelsea Finn, and Sergey Levine. End-to-end robotic reinforcement learning without reward engineering. ArXiv, abs/1904.07854, 2019.
230
+
231
+ Sainbayar Sukhbaatar, Ilya Kostrikov, Arthur Szlam, and Rob Fergus. Intrinsic motivation and automatic curricula via asymmetric self-play. ArXiv, abs/1703.05407, 2017.
232
+
233
+ Haoran Tang, Rein Houthooft, Davis Foote, Adam Stooke, Xi Chen, Yan Duan, John Schulman, Filip De Turck, and Pieter Abbeel. #exploration: A study of count-based exploration for deep reinforcement learning. In NIPS, 2016.
234
+
235
+ Emanuel Todorov, Tom Erez, and Yuval Tassa. Mujoco: A physics engine for model-based control. 2012 IEEE/RSJ International Conference on Intelligent Robots and Systems, pp. 5026–5033, 2012.
236
+
237
+ Hado van Hasselt, Arthur Guez, and David Silver. Deep reinforcement learning with double qlearning. In AAAI, 2015.
238
+
239
+ Rui Wang, Joel Lehman, Jeff Clune, and Kenneth O. Stanley. Paired open-ended trailblazer (POET): endlessly generating increasingly complex and diverse learning environments and their solutions. CoRR, abs/1901.01753, 2019a.
240
+
241
+ Rui Wang, Joel Lehman, Jeff Clune, and Kenneth O. Stanley. Paired open-ended trailblazer (poet): Endlessly generating increasingly complex and diverse learning environments and their solutions. ArXiv, abs/1901.01753, 2019b.
242
+
243
+ Tianhe Yu, Deirdre Quillen, Zhanpeng He, Ryan Julian, Karol Hausman, Chelsea Finn, and Sergey Levine. Meta-world: A benchmark and evaluation for multi-task and meta reinforcement learning. CoRL, 2019.
244
+
245
+ Wenhao Yu, Greg Turk, and Chuanjian Liu. Learning symmetric and low-energy locomotion. ACM Trans. Graph., 37:144:1–144:12, 2018.
246
+
247
+ # A AGENT ARCHITECTURE AND TRAINING
248
+
249
+ We use the same agent network architecture and RL algorithm for all our experiments with minor modification to account for the properties we vary such as reset free RL. Agents are parametrized by an MLP. The environment grid size is $8 \times 8$ . The partial grid observation is flattened and processed by a 2 layer MLP of size (64, 64, 32). The inventory observation is processed by a 2 layer MLP of size (16, 16, 16). These outputs are concatenated and then processed by a final MLP of size (16, action dim). All layers are followed by ReLU nonlinearities except the final layer which uses a softmax to output the action distribution.
250
+
251
+ We train the agents using double DQN (van Hasselt et al., 2015) and the Adam optimizer (Kingma & Ba, 2014) with a learning rate of 0.0001, selected by sweeping across a range of learning rates, with results shown in Figure 6. Training is done in batch mode such that we alternate between collecting 500 environment steps and taking 500 gradient steps (with batch size 256) over the replay buffer of size 5e5. For environments with resets, the horizon length is set to 200. We swept over various horizon lengths and found 200 to work the best. We also tried setting the horizon length very short (20 and 50) to help with the episodic methods but found no effect. We use epsilon greedy exploration for the policy where epsilon starts at 1 and decays linearly by 0.0001 each timestep to 0.1. For each training method we run 10 random seeds.
252
+
253
+ ![](images/442b293f21b72a483c6e1df5c8ca44c583cb634441a9a3cf3a648878ac9172fd.jpg)
254
+ Figure 6: Proportion of validation tasks solved in each setting. Agents learning in static non-episodic environments struggle to learn useful behaviors, while agents learning in dynamic non-episodic environments are substantially more successful. Episodic learning is easier than non-episodic learning on the first task, but non-episodic learning in dynamic environments is almost as effective as episodic learning on the hunting task.
255
+
256
+ # B HUMAN GUIDED ENVIRONMENT SHAPING
257
+
258
+ ![](images/dbd4f5c771bffa7ecaa38ce25688e4b83d38c26686609d1ec4af82b7bdecd8fc.jpg)
259
+ Figure 7: Performance of human guided environment shaping. We ask a human user to interactively shape the environment and observe the human can effectively guide the shaping compared to a predefined environment shaping schedule.
260
+
261
+ In the real world, environment shaping can be done by humans. In this section, we study if a human user can effectively guide the environment shaping during training, instead of using our predefined curriculum. We use the tool-making task in the non-episodic setting with sparse reward. The form of environment shaping is setting the distance from the agent within which resources can spawn, which can be increased over time to “teach” the agent to reach further-away resources. The human is tasked with providing this distance schedule interactively based on the performance of the agent. At each interaction, the human is given a video demonstrating the agent’s current behavior on the training environment and a graph with the agent’s validation performance to date. The human user produces two numbers: the resource spawn distance and for how many training epochs to continue training before requesting another input. This allows the human to adaptively adjust the environment shaping depending on the agent’s performance and minimize the amount of human supervision. Interestingly, the human controlled environment shaping does better than our linearly annealed environment shaping, as shown in Figure 7. The human user specifies a slower resource schedule than our programmed environment shaping.
262
+
263
+ ![](images/33971ce3a2b21989ef9c693e12eed00ff85c9dc0493cdcebcbd8707cf6b4ce63.jpg)
264
+ C ROBUSTNESS OF ENVIRONMENT SHAPING VS. REWARD SHAPING
265
+ Figure 8: Performance of environment shaping and reward shaping on the axe-making task in an environment with wall obstacles. The distance-based reward suffers while environment shaping, despite operating off of a sparse reward, obtains peak validation performance. We find that this advantage in robustness of environment shaping is present in both the episodic and non-episodic settings, but is enhanced in the former.
266
+
267
+ We examine the robustness of the different methods of shaping the learning of the agent by studying the performance of the agent in a more challenging environment which contain walls and are more maze-like. This makes the environment less easily navigable and provides more chances for the agent to become trapped in a particular region of the state space. We find in Figure 8 that environment shaping is the best-performing method under this structural challenge under both episodic and non-episodic settings. However, the episodic setting demonstrates a larger gap between the performance of environment shaping and that of reward shaping. We visualize the state visitation counts of the agent under the different shaping methods in Figures 9 (non-episodic) and 10 (episodic) to understand the differences in performance. In the non-episodic setting, the distance-based reward shaping results in the agent getting trapped in corners and therefore spending a high proportion of time there. This demonstrates that reward shaping can be easier to exploit as it alters the true objective. In contrast environment shaping methods results in greater coverage of the grid. This is consistent with their superior performance in Figure 8.
268
+
269
+ # D LEARNED BEHAVIOR
270
+
271
+ In Figure 11, we demonstrate the learned behavior under environment shaping with a sparse reward and reward shaping with the one-time reward. With environment shaping, the agent accomplishes the desired task in 15 timesteps. On the other hand, despite the fact that the one-time reward provides a reward only for the first interaction with the metal, the reward-shaped agent obtains the metal and repeatedly drops and picks it up afterwards, eventually failing to solve it within the allotted 100 timesteps, demonstrating the biasing effect of reward shaping.
272
+
273
+ In Figure 12, we visualize trajectories from the hunting environment and analyze the learned behavior of two environment-shaped agents, a distance-based reward shaped agent, and a one-time reward shaped agent. The first environment-shaped agent is able to use resources that start out on opposite sides of the world, such that they are never both in view of the agent at the same time. This is notable because the form of environment shaping used is one wherein the agent is provided with resources near it and gradually weaned off over time. The second environment-shaped agent, while presented with a task in which the resources start out on adjacent squares, faces the challenge of the deer moving right before the agent approaches it. We observe that the trained policy is able to make a second attempt at catching the deer, and is successful. The agent trained with distance-based reward shaping displays suboptimal behavior of approaching the axe and then the deer while failing to interact with either, which can be seen as a bias resulting from a reward that incentivizes proximity to resources. Finally, the agent trained with one-time reward shaping also shows suboptimal behavior that is explained by the biases of the reward. The agent picks up the axe and then remains stationary throughout the remainder of the trajectory, failing to hunt the deer due to a reward that provides it a small reward bonus for accomplishing the first portion of the task.
274
+
275
+ ![](images/a96d248b8c8ce80a18a381840894e7c0f1e801edee7ac45c210e47bc5edb7c12.jpg)
276
+ Figure 9: State visitation counts for the non-episodic setting visualized at 4 stages during training under the different methods of shaping. Yellow corresponds to high visitation, dark purple corresponds to low visitation. The darkest purple around the borders and in the map correspond to walls, which cannot be traversed by the agent. We find that the distance-based reward shaping results in the agent getting stuck in the corners of the grid, while the one-time reward and both environment shaping methods result in the most uniform state visitation distribution over the grid during training, indicating that they were able to traverse the grid and explaining their superior performance shown in Figure 8.
277
+
278
+ ![](images/1333f5e91dd24befb57d79137f3aea567ff20cc9a04a50615a5bb458b1cab812.jpg)
279
+ Figure 10: State visitation counts for the episodic setting visualized at 4 stages during training under the different methods of shaping. Yellow corresponds to high visitation, dark purple corresponds to low visitation. The darkest purple around the borders and in the map correspond to walls, which cannot be traversed by the agent. All shaping methods result in a more uniform state visitation distribution than in the non-episodic setting in Figure 9, which aligns with intuition since the resets in the episodic setting help the agent get “unstuck.”
280
+
281
+ ![](images/59e3c911bca86d9277dc5c3fd787b86ebf393f308c24c0b7e6efbe41ad8cb55d.jpg)
282
+ Figure 11: Sample trajectories on validation environments demonstrating learned behavior trained under environment shaping with sparse reward (left) as well as under shaping with the one-time reward (right), both in the non-episodic setting. The shaded region represents the agent’s ego-centric partial view of the environment.
283
+
284
+ ![](images/2595169463c02b01ea535e5d6c22dee3a2bb551b6a0e10ea27a21b53ea470fa9.jpg)
285
+ Figure 12: Sample trajectories on validation environments demonstrating learned behavior trained under environment shaping with sparse reward (top two), distance-based reward shaping (third), and one-time reward shaping (bottom), all in the non-episodic setting. While the environment shaped agents accomplish the desired task within 15 timesteps, biased task specification in the last two result in interpretable but suboptimal behavior. The distance-based reward shaped agent goes to the correct resources in order, but without interacting with either. The one-time reward shaped agent picks up the axe, but fails to do anything afterwards. Both reward shaped agents here fail to solve the task within the allotted 100 timesteps.
parse/train/S1xxx64YwH/S1xxx64YwH_content_list.json ADDED
@@ -0,0 +1,1700 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [
2
+ {
3
+ "type": "text",
4
+ "text": "ECOLOGICAL REINFORCEMENT LEARNING ",
5
+ "text_level": 1,
6
+ "bbox": [
7
+ 174,
8
+ 98,
9
+ 691,
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
+ 400,
21
+ 172
22
+ ],
23
+ "page_idx": 0
24
+ },
25
+ {
26
+ "type": "text",
27
+ "text": "ABSTRACT ",
28
+ "text_level": 1,
29
+ "bbox": [
30
+ 454,
31
+ 210,
32
+ 544,
33
+ 224
34
+ ],
35
+ "page_idx": 0
36
+ },
37
+ {
38
+ "type": "text",
39
+ "text": "Reinforcement learning algorithms have been shown to effectively learn tasks in a variety of static, deterministic, and simplistic environments, but their application to environments which are characteristic of dynamic lifelong settings encountered in the real world has been limited. Understanding the impact of specific environmental properties on the learning dynamics of reinforcement learning algorithms is important as we want to align the environments in which we develop our algorithms with the real world, and this is strongly coupled with the type of intelligence which can be learned. In this work, we study what we refer to as ecological reinforcement learning: the interaction between properties of the environment and the reinforcement learning agent. To this end, we introduce environments with characteristics that we argue better reflect natural environments: non-episodic learning, uninformative “fundamental drive” reward signals, and natural dynamics that cause the environment to change even when the agent fails to take intelligent actions. We show these factors can have a profound effect on the learning progress of reinforcement learning algorithms. Surprisingly, we find that these seemingly more challenging learning conditions can often make reinforcement learning agents learn more effectively. Through this study, we hope to shift the focus of the community towards learning in realistic, natural environments with dynamic elements. ",
40
+ "bbox": [
41
+ 233,
42
+ 239,
43
+ 764,
44
+ 503
45
+ ],
46
+ "page_idx": 0
47
+ },
48
+ {
49
+ "type": "text",
50
+ "text": "1 INTRODUCTION ",
51
+ "text_level": 1,
52
+ "bbox": [
53
+ 176,
54
+ 530,
55
+ 334,
56
+ 546
57
+ ],
58
+ "page_idx": 0
59
+ },
60
+ {
61
+ "type": "text",
62
+ "text": "A central goal in current AI research, especially in reinforcement learning (RL), is to develop algorithms that are general, in the sense that the same method can be used to train an effective model for a wide variety of tasks, problems, and domains. In RL, this means designing algorithms that can solve any Markov decision process (MDP). However, natural intelligence – e.g., humans and animals – exists in the context of a natural environment. People and animals cannot be understood separately from the environments that they inhabit any more than brains can be understood separately from the bodies they control. In the same way, perhaps a complete understanding of artificial intelligence can also only be obtained in the context of an environment, or at least a set of assumptions on that environment. ",
63
+ "bbox": [
64
+ 174,
65
+ 561,
66
+ 825,
67
+ 686
68
+ ],
69
+ "page_idx": 0
70
+ },
71
+ {
72
+ "type": "text",
73
+ "text": "There has been comparatively little study in the field of reinforcement learning to understand how properties of the environment impact the learning process for complex RL agents. Many of the environments used in modern reinforcement learning research differ in fundamental ways from the real world. First, standard RL benchmarks, such as the arcade learning environment (ALE) (Bellemare et al., 2013) and Gym (Brockman et al., 2016) are episodic, while natural environments are continual and lack a “reset” mechanism, requiring an agent to learn through continual interaction. Second, most of these environments include detailed reward functions that not only correspond to overall task success, but also provide intermediate learning signal, thus shaping the learning process. These signals can aid in learning, but they can also bias the learning process. Third, the environments are typically static, in the sense that only the agent’s own actions substantively impact the world. In contrast, natural environments are stochastic and dynamic: an agent that does nothing will still experience many different states, due to the behavior of natural processes and other creatures. ",
74
+ "bbox": [
75
+ 174,
76
+ 694,
77
+ 825,
78
+ 861
79
+ ],
80
+ "page_idx": 0
81
+ },
82
+ {
83
+ "type": "text",
84
+ "text": "In this paper, we aim to study how these properties affect the learning process. At the core of our work is the concept of ecological reinforcement learning: the idea that the behavior and learning dynamics of an agent, like that of an animal, must be understood in the context of the environment in which it is situated. We therefore study how particular properties of the environment can facilitate or harm the emergence of complex behaviors. We focus our attention on the three properties outlined above: (1) continual, non-episodic environments where the agent must learn over the course of one “lifetime,” (2) environments that lack detailed reward shaping, but instead provides a reward signal based on a simple “fundamental drive,” (3) environments that are inherently dynamic, evolving on their own around the agent even if the agent does not take meaningful or useful actions. We study how each of these properties affects the learning process. Although on the surface these properties would seem to make the learning process harder, we observe that in some cases, they can actually make reinforcement learning easier. ",
85
+ "bbox": [
86
+ 174,
87
+ 868,
88
+ 823,
89
+ 924
90
+ ],
91
+ "page_idx": 0
92
+ },
93
+ {
94
+ "type": "image",
95
+ "img_path": "images/03b0179dec31be1505bc07b040d399247bfbc699801aeb21bcdd26643d86d28b.jpg",
96
+ "image_caption": [
97
+ "Figure 1: We study three properties of realistic environments that can have a large effect on the difficulty of reinforcement learning: (left) non-episodic learning, where the agent is not reset automatically to the same initial state distribution, but must handle whatever situation it puts itself in; (middle) environment shaping as an alternative to reward shaping, where the agent has a single, sparse reward, but the environment is varied so as to provide a curriculum (e.g., due to its natural dynamics, or by a cooperative teacher agent); (right) dynamic environments, where the environment changes due to the actions of other agents and natural phenomena, even if the agent does not take a coordinated course of action – such dynamic phenomena can, as we will show, alleviate some of the difficulties in non-episodic learning. "
98
+ ],
99
+ "image_footnote": [],
100
+ "bbox": [
101
+ 174,
102
+ 102,
103
+ 823,
104
+ 167
105
+ ],
106
+ "page_idx": 1
107
+ },
108
+ {
109
+ "type": "text",
110
+ "text": "",
111
+ "bbox": [
112
+ 174,
113
+ 296,
114
+ 825,
115
+ 407
116
+ ],
117
+ "page_idx": 1
118
+ },
119
+ {
120
+ "type": "text",
121
+ "text": "The degree to which these properties make learning easier is highly dependent on the degree of scaffolding that is provided by an environment. For example, an agent tasked with collecting and making food pellets might struggle to learn if it must first complete a complex sequence of actions. However, if food pellets are initially plentiful, the agent can first learn that food pellets are rewarding, and then gradually learn to make them out of raw ingredients as the initial supply becomes scarce. This provides a natural scaffolding and curriculum without requiring manual reward engineering. More generally, “environment shaping” can be used as a way to craft the agent’s curriculum without modifying its reward function. This benefit is counter-balanced by the fact that non-episodic learning is inherently harder – the resets in episodic tasks provide a more stationary learning problem, preventing the agent from getting “stuck” due to a bad initial policy. However, natural environments can also counteract this difficulty: a dynamic environment that gradually changes on its own can provide a sort of “soft” reset that can mitigate the difficulties of reset-free learning, and we observe this empirically in our experiments. We illustrate some of these ideas in Figure 1. ",
122
+ "bbox": [
123
+ 173,
124
+ 415,
125
+ 825,
126
+ 594
127
+ ],
128
+ "page_idx": 1
129
+ },
130
+ {
131
+ "type": "text",
132
+ "text": "The contribution of this work is an empirical study of how the properties of environments – particularly properties that we believe reflect realistic environments – impact reinforcement learning. We study the effect of (1) continual, non-episodic learning, (2) learning with and without reward shaping, and (3) learning in dynamic environments that evolve on their own. We find that, though each of these properties can make learning harder, they can also be combined in realistic ways to actually make learning easier. We also provide an open-source environment for future experiments studying “ecological” reinforcement learning, and we hope that our experimental conclusions will encourage future research that studies how the nature of the environment in which the RL agent is situated can facilitate learning and the emergence of complex skills. This exercise helps us determine which types of algorithmic challenges we should focus our development efforts towards in order to solve natural environments that agents might encounter. ",
133
+ "bbox": [
134
+ 173,
135
+ 602,
136
+ 825,
137
+ 755
138
+ ],
139
+ "page_idx": 1
140
+ },
141
+ {
142
+ "type": "text",
143
+ "text": "2 RELATED WORK ",
144
+ "text_level": 1,
145
+ "bbox": [
146
+ 176,
147
+ 779,
148
+ 344,
149
+ 795
150
+ ],
151
+ "page_idx": 1
152
+ },
153
+ {
154
+ "type": "text",
155
+ "text": "Solving general RL problems can be extremely hard in general (Kakade & Langford, 2002). Reward shaping is a common technique to guide learning $\\mathrm { N g }$ et al., 1999; Devlin & Kudenko, 2012; Brys et al., 2015) but is usually hand crafted and must be carefully designed by human experts (Griffith et al., 2013). Shaping the reward may also lead to suboptimal solutions, as it alters the objective of the learning problem. Curriculum learning can be used to first provide the agent with easier tasks, followed by more challenging tasks (Bengio et al., 2009; Graves et al., 2017; Randløv & Alstrøm, 1998; Wang et al., $2 0 1 9 \\mathrm { a }$ ; Yu et al., 2018; Heess et al., 2017). Curriculum learning can also be viewed in the context of multiple learning agents in an adversarial or cooperative setting (Silver et al., 2016; Al-Shedivat et al., 2017; Sukhbaatar et al., 2017; Omidshafiei et al., 2018) or where the curriculum is automatically generated (Florensa et al., 2017b;a; Riedmiller et al., 2018; Wang et al., 2019b). The “environment shaping” that we study in our experiments can be viewed as a kind of curriculum learning, and we argue – and show empirically – that this environment shaping approach can in some cases be more effective than more commonly used reward shaping. ",
156
+ "bbox": [
157
+ 174,
158
+ 811,
159
+ 825,
160
+ 924
161
+ ],
162
+ "page_idx": 1
163
+ },
164
+ {
165
+ "type": "text",
166
+ "text": "",
167
+ "bbox": [
168
+ 174,
169
+ 103,
170
+ 823,
171
+ 172
172
+ ],
173
+ "page_idx": 2
174
+ },
175
+ {
176
+ "type": "text",
177
+ "text": "Improved exploration methods are a possible solution to solving sparse reward tasks. Prior work has used approximate state-visitation counts (Tang et al., 2016; Bellemare et al., 2013), information gain, or prediction error (Houthooft et al., 2016; Pathak et al., 2017), or model ensemble uncertainty (Osband et al., 2016). A recent work (Ecoffet et al., 2019) maintains a set of novel states and first returns to the novel states before exploring from this frontier. Our work could be combined with an exploration method, however, this work indicates that sparse reward tasks can be solved with an appropriately shaped environment. ",
178
+ "bbox": [
179
+ 174,
180
+ 181,
181
+ 823,
182
+ 277
183
+ ],
184
+ "page_idx": 2
185
+ },
186
+ {
187
+ "type": "text",
188
+ "text": "Prior work on RL without resets has focused on safe exploration (Moldovan & Abbeel, 2012; Chatzilygeroudis et al., 2018) or learning a policy to reset the environment (Eysenbach et al., 2017; Han et al., 2015). Even-Dar et al. (2005) studies reset free RL in POMDPs and implements a homing strategy which approximately resets the agent. Rather than trying to convert the reset-free problem to one that looks more like a scenario with resets, our experiments study under which conditions reset-free learning can actually be easier, and show that dynamic environments – which we argue better reflect the real world – actually make learning without resets easier. ",
189
+ "bbox": [
190
+ 174,
191
+ 285,
192
+ 825,
193
+ 382
194
+ ],
195
+ "page_idx": 2
196
+ },
197
+ {
198
+ "type": "text",
199
+ "text": "Learning in non-episodic settings has been studied from the perspective of continual learning Ring (1997), where a number of tasks are learned in sequence. These algorithms typically consider the problem of “catastrophic forgetting” (Mccloskey, 1989; French, 1999), where previously learned tasks are forgotten while learning new tasks. To solve this problem, algorithms use methods such as explicit memorization (Rusu et al., 2016; Schwarz et al., 2018), generative replay (Shin et al., 2017) and explicit weight regularization (Kirkpatrick et al., 2016; Kaplanis et al., 2018). These works assume that resets and task boundaries are available whereas we assume that the agent is unable to reset. There has also been work on building more complex tasks in large diverse worlds with Mujoco (Todorov et al., 2012; Singh et al., 2019; Yu et al., 2019), Malmo (Johnson et al., 2016; Guss et al., 2019), DeepMind Lab (Beattie et al., 2016), and many others, however, again, these environments are studied in the context of episodic-learning. ",
200
+ "bbox": [
201
+ 174,
202
+ 388,
203
+ 825,
204
+ 542
205
+ ],
206
+ "page_idx": 2
207
+ },
208
+ {
209
+ "type": "text",
210
+ "text": "3 PROPERTIES OF NATURAL ENVIRONMENTS",
211
+ "text_level": 1,
212
+ "bbox": [
213
+ 174,
214
+ 571,
215
+ 563,
216
+ 587
217
+ ],
218
+ "page_idx": 2
219
+ },
220
+ {
221
+ "type": "text",
222
+ "text": "In contrast to most simulated environments that are used for reinforcement learning experiments (Brockman et al., 2016), agents learning in natural environments experience a continual stream of experience, without episode boundaries. The typical reward function engineering that is often employed in reinforcement learning experiments is also generally unavailable in the real world, where agents must rely on their own low-level perception to understand the world. Finally, natural environments change on their own, even when the agent does not follow a coordinated or intelligent course of action. This dynamism can create additional challenges, but can also facilitate learning, mitigating some of the issues due to non-episodic and non-resettable learning settings. In this paper, our aim is to study how these aspects of the environment impact the performance of reinforcement learning agents. We term this approach ecological reinforcement learning, in that it deals specifically with the relationship between properties of the environment and the reinforcement learning agent, rather than studying reinforcement learning algorithms in the general case, regardless of the particular properties of the learning environment. We believe that the properties outlined above are broadly reflected in real-world settings, and are often absent in simulated reinforcement learning benchmarks. In this section, we discuss each of these properties, and formulate our hypotheses about how these properties might influence learning. ",
223
+ "bbox": [
224
+ 174,
225
+ 608,
226
+ 825,
227
+ 829
228
+ ],
229
+ "page_idx": 2
230
+ },
231
+ {
232
+ "type": "text",
233
+ "text": "Continual non-episodic learning. In the real world, all learning must at some level be nonepisodic: though we may instrument environments to make them appear episodic, there is always a single underlying temporal process. In general, this makes the learning problem harder: when the agent is not reset to randomly chosen initial states, mistakes early on in training can put it into undesirable situations, from which it might be harder to recover and – more importantly – harder to learn. A non-episodic learning process is non-stationary, and the agent can become trapped in difficult regions of the state space. ",
234
+ "bbox": [
235
+ 174,
236
+ 854,
237
+ 823,
238
+ 922
239
+ ],
240
+ "page_idx": 2
241
+ },
242
+ {
243
+ "type": "text",
244
+ "text": "",
245
+ "bbox": [
246
+ 171,
247
+ 103,
248
+ 823,
249
+ 132
250
+ ],
251
+ "page_idx": 3
252
+ },
253
+ {
254
+ "type": "text",
255
+ "text": "Hypothesis 1: Non-episodic learning is more difficult than episodic learning because the agent must handle a non-stationary learning problem, and can become trapped in difficult states. We will study this hypothesis in our experiments, and show how some of the other properties of natural environments can help alleviate this difficulty. ",
256
+ "bbox": [
257
+ 174,
258
+ 138,
259
+ 823,
260
+ 194
261
+ ],
262
+ "page_idx": 3
263
+ },
264
+ {
265
+ "type": "text",
266
+ "text": "Sparse rewards and environment shaping. While in principle RL algorithms can handle relatively uninformative rewards, in practice reward shaping is often an essential tool for getting RL methods to acquire effective policies. For example, an agent that must learn a policy to collect resources to make an axe (see Figure 2) might make use of a reward function that specifies the distance to the nearest resource, or at least provides a small reward for each resource obtained, as opposed to a reward given only for obtaining the final goal. However, well-shaped rewards are generally not available and difficult to provide in the real world, since they require knowledge of privileged state variables (e.g., positions of objects) or the process by which the task must be completed (e.g., required resources), both of which should in principle be learned automatically by the agent. Furthermore, reward shaping might introduce bias, since the optimal policy for a shaped reward may not in fact be optimal for the original task reward. On the other hand, agents in the real world do not learn in a vacuum: even for humans and animals, it is reasonable to assume a reasonably cooperative environment that has been set up so as to facilitate learning. For humans, this kind of “scaffolding” is often provided by other agents (e.g., parents and teachers). But even without other agents, natural environments might provide automatic scaffolding – e.g., an animal might find apples that fell from a tree, and thereby learn that apples are a source of food. Once the fallen apples are exhausted, the animal might use its knowledge of the value of apples to learn to climb the tree to obtain the apples on its own. This kind of “environment shaping” could serve as a tool for guiding the learning process, without the bias or manual engineering inherent in reward shaping. ",
267
+ "bbox": [
268
+ 174,
269
+ 209,
270
+ 825,
271
+ 474
272
+ ],
273
+ "page_idx": 3
274
+ },
275
+ {
276
+ "type": "text",
277
+ "text": "Hypothesis 2: Environment shaping can enable agents to learn even with simple sparse rewards, and can in fact result in more proficient policies if applied correctly, as opposed to reward shaping. ",
278
+ "bbox": [
279
+ 174,
280
+ 481,
281
+ 823,
282
+ 508
283
+ ],
284
+ "page_idx": 3
285
+ },
286
+ {
287
+ "type": "text",
288
+ "text": "Dynamic environments. Standard reinforcement learning benchmark tasks are typically situated in static environments (Brockman et al., 2016; Bellemare et al., 2013), in the sense that the environment does not change substantially unless the agent takes a coordinated course of action. On the other hand, real-world settings are typically dynamic, in the sense that the environment changes even if the agent does not follow any coordinated course of action: animals will move around, times of day will change, seasons will change, etc. Dynamic environments present their own challenges, but they can also facilitate learning, by automatically exposing the agent to a wide variety of situations. ",
289
+ "bbox": [
290
+ 173,
291
+ 523,
292
+ 825,
293
+ 621
294
+ ],
295
+ "page_idx": 3
296
+ },
297
+ {
298
+ "type": "text",
299
+ "text": "Hypothesis 3: While dynamic environments could make learning more difficult, in fact they can alleviate some of the challenges associated with non-episodic learning, by providing the agent with a variety of learning conditions even in the absence of coordinated and intelligent behavior (as is the case, e.g., early on in training). ",
300
+ "bbox": [
301
+ 174,
302
+ 628,
303
+ 823,
304
+ 684
305
+ ],
306
+ "page_idx": 3
307
+ },
308
+ {
309
+ "type": "text",
310
+ "text": "4 EXPERIMENTAL SETUP ",
311
+ "text_level": 1,
312
+ "bbox": [
313
+ 176,
314
+ 704,
315
+ 398,
316
+ 719
317
+ ],
318
+ "page_idx": 3
319
+ },
320
+ {
321
+ "type": "text",
322
+ "text": "To carry out our ecological RL study, we construct three simulated tasks. The simulator for two of them is built on top of the grid-like environment proposed by Chevalier-Boisvert et al. (2018). We chose a grid-based discrete-action environment over a more complex, high-dimensional one to study the aforementioned properties in isolation, without other confounding factors involving highdimensional observations and representation learning. The goal is not to simulate a completely visually realistic and life-like system, but to study those properties of the MDP that will be particularly important in natural environments, and have not been addressed in detail in prior work. ",
323
+ "bbox": [
324
+ 174,
325
+ 736,
326
+ 823,
327
+ 833
328
+ ],
329
+ "page_idx": 3
330
+ },
331
+ {
332
+ "type": "text",
333
+ "text": "The environment is an $N \\times N$ grid of tiles, where each tile contains at most one object, but the agent is free to move over any tile and can pick up and carry one object at a time. The agent can use objects in its environment to construct new ones by dropping a carried object onto an existing object. Objects include wood, metal, deer, axe, and food. The agent can combine wood with metal to construct an axe and apply the axe to a deer to produce food. The agent consumes resources such as food by picking them up. There are movement actions associated with each of the cardinal directions, as well as to pick up or drop an object. The environment is partially observed, and the agent receives a local egocentric view around it, represented by the shaded region in Figure 2, which is a $5 \\times 5 \\times C$ grid, where $C$ is the number of object types, and each grid position contains a one-hot vector representation of the object type. We use the following two tasks in our evaluation, which are illustrated in Figure 2: ",
334
+ "bbox": [
335
+ 174,
336
+ 840,
337
+ 823,
338
+ 922
339
+ ],
340
+ "page_idx": 3
341
+ },
342
+ {
343
+ "type": "text",
344
+ "text": "",
345
+ "bbox": [
346
+ 174,
347
+ 103,
348
+ 825,
349
+ 174
350
+ ],
351
+ "page_idx": 4
352
+ },
353
+ {
354
+ "type": "image",
355
+ "img_path": "images/851f30e059be396a7c250cb4546b2faf89727a9fa36f95820145a7594a566770.jpg",
356
+ "image_caption": [
357
+ "Figure 2: Tasks in our partially observed stochastic environment for crafting an axe (left) and hunting a deer (middle). The agent (purple triangle) receives a local observation (shaded gray square) and must interact with objects in the correct sequences to complete the task. In the food collection task in Unity (right), the agent’s goal is to collect green food and avoid red poison. "
358
+ ],
359
+ "image_footnote": [],
360
+ "bbox": [
361
+ 204,
362
+ 178,
363
+ 789,
364
+ 267
365
+ ],
366
+ "page_idx": 4
367
+ },
368
+ {
369
+ "type": "text",
370
+ "text": "Tool-making: The agent must combine wood and metal to craft an axe, and then pick up the axe. Wood and metal appear at random locations initially, and continue to spawn with some probability as time progresses in the dynamic setting. ",
371
+ "bbox": [
372
+ 174,
373
+ 338,
374
+ 825,
375
+ 381
376
+ ],
377
+ "page_idx": 4
378
+ },
379
+ {
380
+ "type": "text",
381
+ "text": "Hunting: The agent uses an axe to hunt a deer, which produces food that it can pick up to eat. Axes and deer appear at random locations. The deer can move around in the environment in the dynamic setting, and can appear at different distances from the agent. ",
382
+ "bbox": [
383
+ 174,
384
+ 387,
385
+ 825,
386
+ 429
387
+ ],
388
+ "page_idx": 4
389
+ },
390
+ {
391
+ "type": "text",
392
+ "text": "In order to study our hypotheses in varied settings, we additionally investigate these environmental properties, enumerated at the end of this section, in the context of the Food Collector environment available as part of the Unity ML-Agents toolkit provided by Juliani et al. (2018). The environment features a continuous state space with raycast partial observations representing the directional view of the agent. The action space is 27-dimensional, with separate action streams corresponding to forward, lateral, and rotational movement. The task is taken as-is, wherein the agent must maximize the number of healthy food items eaten (represented by green spheres) while avoiding consuming poisonous food (red sphere). We modify the environment dynamics and initial conditions within this task setting to investigate our hypotheses. ",
393
+ "bbox": [
394
+ 174,
395
+ 436,
396
+ 825,
397
+ 561
398
+ ],
399
+ "page_idx": 4
400
+ },
401
+ {
402
+ "type": "text",
403
+ "text": "To study the hypotheses discussed in the previous section, we vary a number of properties of these environments, and examine their effect on the learning process: ",
404
+ "bbox": [
405
+ 173,
406
+ 568,
407
+ 823,
408
+ 597
409
+ ],
410
+ "page_idx": 4
411
+ },
412
+ {
413
+ "type": "text",
414
+ "text": "Non-episodic learning. The non-episodic version of each task does not allow the agent to reset to the initial state, and instead requires it to learn the task effectively over one very long episode, as illustrated in the figure on the right. For example, in the Unity Food Collector task, the agent must learn to continually collect as many healthy food items as possible while avoiding the poisonous food across its lifetime. We will compare this against the episodic case, where the agent is reset to an initial state distribution after completing the task or after a fixed time horizon. This will allow us to study hypothesis $H l$ . ",
415
+ "bbox": [
416
+ 174,
417
+ 604,
418
+ 549,
419
+ 728
420
+ ],
421
+ "page_idx": 4
422
+ },
423
+ {
424
+ "type": "text",
425
+ "text": "",
426
+ "bbox": [
427
+ 178,
428
+ 728,
429
+ 823,
430
+ 756
431
+ ],
432
+ "page_idx": 4
433
+ },
434
+ {
435
+ "type": "image",
436
+ "img_path": "images/66d6015d129a90f30b572326f81d0d85664dda57c68e5a10b91ccf41eea1d2f6.jpg",
437
+ "image_caption": [],
438
+ "image_footnote": [],
439
+ "bbox": [
440
+ 576,
441
+ 609,
442
+ 805,
443
+ 717
444
+ ],
445
+ "page_idx": 4
446
+ },
447
+ {
448
+ "type": "text",
449
+ "text": "Reward shaping. Reward shaping is often used to assist the agent in finding a good policy by providing more signal to the agent. The environment allows us to experiment with different reward functions, such as a shaped distance-based reward function that rewards the agent for how close it is to the nearest resource it needs, and a larger bonus for interacting with the right object. A sparse reward function will b based on a simple “fundamental drive:” whether or not the agent has just acquired the axe (in th tool-making task), deer (hunting), or food (food collector). ",
450
+ "bbox": [
451
+ 174,
452
+ 763,
453
+ 531,
454
+ 847
455
+ ],
456
+ "page_idx": 4
457
+ },
458
+ {
459
+ "type": "image",
460
+ "img_path": "images/e8be49462fb9af660e8f7942b2e28f64b948ed3c1ad8532352adf8296771af09.jpg",
461
+ "image_caption": [],
462
+ "image_footnote": [],
463
+ "bbox": [
464
+ 550,
465
+ 770,
466
+ 812,
467
+ 835
468
+ ],
469
+ "page_idx": 4
470
+ },
471
+ {
472
+ "type": "text",
473
+ "text": "",
474
+ "bbox": [
475
+ 174,
476
+ 847,
477
+ 813,
478
+ 888
479
+ ],
480
+ "page_idx": 4
481
+ },
482
+ {
483
+ "type": "text",
484
+ "text": "Environment shaping. Instead of shaping rewards, which can be unrealistic and can bias the learning process, we can instead change the types and distribution of states the agent observes while learning. In our tasks, we can scaffold the learning process by controlling the maximum distance from the agent at which the resources (wood, metal, deer, and food) can appear. We can gradually increase this distance as the learning progresses, as illustrated the figure on the right, which shows the deer appearing progressively further away during training, thus inducing a curriculum. This type of environment shaping can remove the need for reward shaping, and potentially alleviates its shortcomings. We will use this setting to study hypothesis $H 2$ . ",
485
+ "bbox": [
486
+ 173,
487
+ 895,
488
+ 823,
489
+ 924
490
+ ],
491
+ "page_idx": 4
492
+ },
493
+ {
494
+ "type": "text",
495
+ "text": "",
496
+ "bbox": [
497
+ 173,
498
+ 103,
499
+ 823,
500
+ 188
501
+ ],
502
+ "page_idx": 5
503
+ },
504
+ {
505
+ "type": "text",
506
+ "text": "Dynamic vs. static environments. We can construct dynamic versions of both of our tasks by varying the probability that the environment changes at any given time, regardless of the agent’s actions. This captures the fact that natural environments will change on their own, regardless of what the agent does: other animals will move around, weather will change, etc. In both grid domains, we define a continuous spectrum of dynamic effects, in terms of a dynamic event probability. In the tool-making task, the dynamic effect probability $p$ controls the resource generation, determining the probability that a resource will spawn in empty squares no less than two squares away from the agent at each time step. To keep the expected quantity of resources constant throughout the trajectory we allow resources to decay (disappear) after a lifespan of $\\frac { I } { p }$ timesteps, where $I$ is the number of instances of this resource that appear in the initial environment. In the hunting task, the dynamic effect probability $p$ is the probability that a deer will move to a random adjacent square on each time step, as illustrated in the figure above. The static version of these environments will have $p = 0$ , such that resources are in fixed positions and only respawn as needed when the agent completes the task, and deer do not move. In the Unity Food Collector environment, the dynamic property is given by the speed at which both healthy and poisonous food move, which was tested across the range of $v = 0$ to $v = 1 6$ , corresponding to the velocities set for the food objects in the Unity engine. The static setting here corresponds to stationary food. By studying dynamic and static environments in episodic and non-episodic settings, we can analyze hypothesis $H 3$ . ",
507
+ "bbox": [
508
+ 173,
509
+ 194,
510
+ 517,
511
+ 291
512
+ ],
513
+ "page_idx": 5
514
+ },
515
+ {
516
+ "type": "image",
517
+ "img_path": "images/5e33e9c6293a07bee59285c53718ccffc8cb1bfc8c2d25b61290025efc3d3ccd.jpg",
518
+ "image_caption": [],
519
+ "image_footnote": [],
520
+ "bbox": [
521
+ 544,
522
+ 202,
523
+ 805,
524
+ 285
525
+ ],
526
+ "page_idx": 5
527
+ },
528
+ {
529
+ "type": "text",
530
+ "text": "",
531
+ "bbox": [
532
+ 173,
533
+ 291,
534
+ 825,
535
+ 501
536
+ ],
537
+ "page_idx": 5
538
+ },
539
+ {
540
+ "type": "text",
541
+ "text": "In order to compare agents trained under the different environment conditions, we must construct a single consistent evaluation protocol. We use the same agent network architecture and RL algorithm for all experiments, with details provided in Appendix A. We evaluate all agents on a set of validation tasks that are chosen to be as close as possible to the “standard” RL setting, which is episodic and static. We generate 100 validation tasks by randomly generating environments with varying initial resource and agent locations. Performance is measured by the proportion of validation tasks solved. We first study non-episodic learning and dynamic vs. static environments by varying these training settings with sparse reward and no environment shaping. We will then study reward shaping and environment shaping in the dynamic non-episodic setting. The training settings are: ",
542
+ "bbox": [
543
+ 174,
544
+ 627,
545
+ 825,
546
+ 753
547
+ ],
548
+ "page_idx": 5
549
+ },
550
+ {
551
+ "type": "text",
552
+ "text": "Static episodic: In this setting, $p$ is set to 0 so positions of the resources will be static unless the agent moves them. When the agent finishes the task, the environment is reset to a random initial configuration. The environment is also reset when the episode length reaches 200. ",
553
+ "bbox": [
554
+ 174,
555
+ 760,
556
+ 825,
557
+ 801
558
+ ],
559
+ "page_idx": 5
560
+ },
561
+ {
562
+ "type": "text",
563
+ "text": "Static non-episodic: Here, $p = 0$ and there are no resets. When the agent has used up the available resources, more resources are generated randomly. ",
564
+ "bbox": [
565
+ 173,
566
+ 805,
567
+ 823,
568
+ 833
569
+ ],
570
+ "page_idx": 5
571
+ },
572
+ {
573
+ "type": "text",
574
+ "text": "Dynamic non-episodic: This setting explores the lifelong case with a changing environment, where the dynamic property $p$ is varied between 0 and 1. For tool-making, $p$ is the probability of resources spawning at each timestep in a random location. There is initially two of each type of resource. This environment is lifelong and does not reset when the agent completes the task. ",
575
+ "bbox": [
576
+ 174,
577
+ 837,
578
+ 825,
579
+ 892
580
+ ],
581
+ "page_idx": 5
582
+ },
583
+ {
584
+ "type": "text",
585
+ "text": "Dynamic episodic: This is the same as the dynamic non-episodic version except that the environment is reset to a random initial configuration when the agent completes the task. ",
586
+ "bbox": [
587
+ 173,
588
+ 895,
589
+ 820,
590
+ 924
591
+ ],
592
+ "page_idx": 5
593
+ },
594
+ {
595
+ "type": "text",
596
+ "text": "5 EXPERIMENTAL RESULTS ",
597
+ "text_level": 1,
598
+ "bbox": [
599
+ 176,
600
+ 102,
601
+ 419,
602
+ 118
603
+ ],
604
+ "page_idx": 6
605
+ },
606
+ {
607
+ "type": "text",
608
+ "text": "To study the hypotheses in Section 3, we perform experiments where we train RL agents on the tasks described above and vary different properties of the environment during training. ",
609
+ "bbox": [
610
+ 174,
611
+ 133,
612
+ 823,
613
+ 161
614
+ ],
615
+ "page_idx": 6
616
+ },
617
+ {
618
+ "type": "text",
619
+ "text": "5.1 NON-EPISODIC LEARNING IN DYNAMIC AND STATIC ENVIRONMENTS ",
620
+ "text_level": 1,
621
+ "bbox": [
622
+ 174,
623
+ 178,
624
+ 699,
625
+ 193
626
+ ],
627
+ "page_idx": 6
628
+ },
629
+ {
630
+ "type": "text",
631
+ "text": "In the real world, environments are generally dynamic and non-episodic, meaning that the agent is never reset to an initial state distribution, and many parts of the environment are changing without the agent’s intervention. In this section we study the effects of both a dynamic, changing environment and the ability to reset on the learning agent, corresponding to hypotheses $H l$ and $H 3$ . These settings will use sparse reward and no environment shaping. ",
632
+ "bbox": [
633
+ 174,
634
+ 204,
635
+ 825,
636
+ 273
637
+ ],
638
+ "page_idx": 6
639
+ },
640
+ {
641
+ "type": "image",
642
+ "img_path": "images/9e64ce211a9f989420a7c3b3d8508323116658264d9d1bfe128fb4b42af85412.jpg",
643
+ "image_caption": [
644
+ "Figure 3: Proportion of validation tasks solved in each setting. Agents learning in static non-episodic environments struggle to learn useful behaviors, while agents learning in dynamic non-episodic environments are substantially more successful. Episodic learning is easier than non-episodic learning on the first task, but non-episodic learning in dynamic environments is almost as effective as episodic learning on the hunting task. "
645
+ ],
646
+ "image_footnote": [],
647
+ "bbox": [
648
+ 238,
649
+ 287,
650
+ 732,
651
+ 479
652
+ ],
653
+ "page_idx": 6
654
+ },
655
+ {
656
+ "type": "text",
657
+ "text": "Effect of resets on learning. In regard to $H l$ , we find that learning tasks in static, reset-free, nonepisodic environments is difficult. In Figure 3, we compare the performance of the agent trained in each of the four conditions. Recall that all evaluations are conducted in the same setting, with resets and static environments, regardless of how the agent is actually trained. For the tool-making task, we observe that removing resets makes learning more difficult in the typical static case. The agent trained in a static environment without resets obtains the lowest performance $0 \\%$ evaluation tasks solved). Adding in resets to the static case helps with performance $( 1 2 \\% )$ . In the static environment, we observe that the agent frequently becomes stuck in corners of the map or in areas with no resources. ",
658
+ "bbox": [
659
+ 173,
660
+ 568,
661
+ 825,
662
+ 693
663
+ ],
664
+ "page_idx": 6
665
+ },
666
+ {
667
+ "type": "text",
668
+ "text": "The results indicate that disabling resets makes the standard static learning condition substantially harder. Indeed, the static no reset agent is unable to learn effectively for either task, even though the static episodic agent does learn the task to a moderate proficiency. However, making the environment dynamic substantially improves performance, in both the episodic and non-episodic setting, as shown in Figure 3. These results suggest that dynamic environments to a large extent alleviate the challenges associated with non-episodic learning, confirming hypothesis $H 3$ . The lesson that we might draw from this is that, although individual properties of natural environments (such as non-episodic learning) can make the learning process harder, combining these properties (i.e., as in the non-episodic dynamic setting) can actually alleviate these challenges, since the dynamics of the environment naturally cause the agent to experience a variety of different situations, even before it has learned to take meaningful and coordinated actions. ",
669
+ "bbox": [
670
+ 173,
671
+ 699,
672
+ 825,
673
+ 853
674
+ ],
675
+ "page_idx": 6
676
+ },
677
+ {
678
+ "type": "text",
679
+ "text": "Dynamic environments and non-episodic learning. We conclude that, when resets are not available, dynamic environments can also help with non-episodic RL. In this section, we study how the frequency of dynamic effects impacts learning. In Figure 3, we can see that making the environment more dynamic increases performance to $7 0 \\%$ , compared to the static non-episodic case $( 0 \\% )$ . Having both a dynamic environment and resets achieves the highest performance $( 9 5 \\% )$ , indicating that both are helpful on their own. However, an environment that is too dynamic hinders performance, as we observe in Figure 4, where a dynamic effect probability of 0.5 performs worse than 0.1. This implies that environment dynamics represent a tradeoff: the environment should be stable enough for the agent to learn meaningful behavior, but dynamic enough to present interesting situations. This in some sense resembles the tradeoff typically encountered with exploration constants, e.g. in $\\epsilon$ -greedy exploration. From this experiment, we can conclude that, although $H 3$ is generally true, the particular choice of environment settings can greatly impact learning performance. To understand this better, we analyze and compare the effect of “environment shaping,” as defined in Section 4, in the following subsection. ",
680
+ "bbox": [
681
+ 174,
682
+ 859,
683
+ 825,
684
+ 902
685
+ ],
686
+ "page_idx": 6
687
+ },
688
+ {
689
+ "type": "image",
690
+ "img_path": "images/ce2d75d532b6a31167f4909ade1a8830c40e4f93eb9ceafc27133e08559ea894.jpg",
691
+ "image_caption": [
692
+ "Figure 4: Proportion of validation tasks solved as the dynamic effect probability (i.e., resource probability and deer movement probability) is varied in the non-episodic setting. For all tasks, the standard static environment does not allow for effective learning, but a number of dynamic environment variants allow the agent to learn the task successfully. Evaluation is still carried out in a static environment. "
693
+ ],
694
+ "image_footnote": [],
695
+ "bbox": [
696
+ 240,
697
+ 99,
698
+ 732,
699
+ 183
700
+ ],
701
+ "page_idx": 7
702
+ },
703
+ {
704
+ "type": "text",
705
+ "text": "",
706
+ "bbox": [
707
+ 174,
708
+ 281,
709
+ 825,
710
+ 434
711
+ ],
712
+ "page_idx": 7
713
+ },
714
+ {
715
+ "type": "text",
716
+ "text": "5.2 REWARD SHAPING AND ENVIRONMENT SHAPING ",
717
+ "text_level": 1,
718
+ "bbox": [
719
+ 174,
720
+ 460,
721
+ 558,
722
+ 476
723
+ ],
724
+ "page_idx": 7
725
+ },
726
+ {
727
+ "type": "text",
728
+ "text": "Next, we study how reward shaping and environment shaping compare in terms of their capacity to assist learning in reset-free environments, to study hypothesis $H 2$ . We perform experiments where we train RL agents on the same tool-making task, in the non-episodic case. We compare shaping the environment during training to shaping the reward function during training. The training environments have one of each resource, spawning at locations sampled uniformly over the world every 20 timesteps which is a much more difficult setting than the ones used in the previous section. We evaluate a range of reward and environment shaping conditions. For all methods the agent is given a reward of 100 each time it completes the task. Resource interaction means picked up a required resource resource. The methods are: ",
729
+ "bbox": [
730
+ 174,
731
+ 491,
732
+ 825,
733
+ 616
734
+ ],
735
+ "page_idx": 7
736
+ },
737
+ {
738
+ "type": "text",
739
+ "text": "No shaping with sparse reward: Resources spawn uniformly and the agent receives task completion reward. ",
740
+ "bbox": [
741
+ 176,
742
+ 623,
743
+ 821,
744
+ 651
745
+ ],
746
+ "page_idx": 7
747
+ },
748
+ {
749
+ "type": "text",
750
+ "text": "Distance reward shaping: The agent is provided with a dense distance-based reward which grants $( - 0 . 0 1 *$ distance to nearest required resource) and (1) for resource interaction. ",
751
+ "bbox": [
752
+ 174,
753
+ 655,
754
+ 821,
755
+ 684
756
+ ],
757
+ "page_idx": 7
758
+ },
759
+ {
760
+ "type": "text",
761
+ "text": "One-time reward shaping: This is less dense than the distance based reward. The agent is given reward (1) for resource interaction and $- 1 0 0$ for dropping the resource. This resource reward is only granted the first time and resets every time the task is completed. ",
762
+ "bbox": [
763
+ 174,
764
+ 686,
765
+ 825,
766
+ 728
767
+ ],
768
+ "page_idx": 7
769
+ },
770
+ {
771
+ "type": "text",
772
+ "text": "Environment shaping with subgoal reward: We design a simple shaping method that gradually increases the distance away from the agent at which resources spawn. This distances increases linearly until the resources are placed uniformly over the grid world, as in the shaped reward version. We tried various schedules and found a schedule that starts at a distance of 2 and increases by 1 every 1e5 environment steps to work well. The subgoal reward is simpler than the one-time reward. The agent is given reward (1) for resource interaction. This reward does not keep track of previous object interactions and grants the bonus multiple times. ",
773
+ "bbox": [
774
+ 174,
775
+ 732,
776
+ 825,
777
+ 829
778
+ ],
779
+ "page_idx": 7
780
+ },
781
+ {
782
+ "type": "text",
783
+ "text": "Environment shaping with sparse reward: We shape the environment as in the previous method but only use the task reward. ",
784
+ "bbox": [
785
+ 173,
786
+ 833,
787
+ 821,
788
+ 861
789
+ ],
790
+ "page_idx": 7
791
+ },
792
+ {
793
+ "type": "text",
794
+ "text": "Environment shaping can replace reward shaping. We compare performance of these methods in Figure 5 for both the episodic and non-episodic case. We find that, even in the episodic case, environment shaping works well and outperforms reward shaping in the long run. Improper reward shaping can alter the optimal policy, thereby biasing learning and resulting in a solution that is worse ",
795
+ "bbox": [
796
+ 174,
797
+ 868,
798
+ 823,
799
+ 924
800
+ ],
801
+ "page_idx": 7
802
+ },
803
+ {
804
+ "type": "image",
805
+ "img_path": "images/0efdf540d052076509be282730b717372725807a3f1a3c313bfe633e86530f6a.jpg",
806
+ "image_caption": [
807
+ "Figure 5: Proportion of validation tasks solved for environment shaping with sparse reward, subgoal reward, and different forms of reward shaping. We see that environment shaping can obtain better final performance than reward shaping. "
808
+ ],
809
+ "image_footnote": [],
810
+ "bbox": [
811
+ 173,
812
+ 103,
813
+ 792,
814
+ 460
815
+ ],
816
+ "page_idx": 8
817
+ },
818
+ {
819
+ "type": "text",
820
+ "text": "with respect to the desired performance measure, which typically corresponds to the sparse reward. \nThese behaviors are shown in Appendix D. ",
821
+ "bbox": [
822
+ 173,
823
+ 542,
824
+ 821,
825
+ 570
826
+ ],
827
+ "page_idx": 8
828
+ },
829
+ {
830
+ "type": "text",
831
+ "text": "Interestingly, we find that environment shaping works better for the more difficult task of Hunting. As task complexity grows, so does the difficulty of constructing an unbiased shaped reward for the tasks. In this case, environment shaping benefits from its ease of use and general applicability to various tasks. Further experiments on a harder environment are detailed in Appendix C. ",
832
+ "bbox": [
833
+ 174,
834
+ 578,
835
+ 825,
836
+ 633
837
+ ],
838
+ "page_idx": 8
839
+ },
840
+ {
841
+ "type": "text",
842
+ "text": "Human guided environment shaping. In the real world, environment shaping can be done by doing what we already do for other human learners (e.g., children and pupils in school): arranging the environment to be conducive to learning. We also conducted a study of this setting, by having an actual human user interactively specify how the environment should be altered to facilitate the agent’s learning process. In this case, the human user was able to provide an environment shaping schedule that outperformed the one we specified manually. Full results for this experiment are provided in Appendix B. These results suggest that environment shaping is not only effective, but is also readily intuitive for a human user to specify interactively, suggesting that it can be a viable way to provide guidance to reinforcement learning agents and may be intuitive to specify, in comparison with reward shaping, which can at times be difficult and counter-intuitive. ",
843
+ "bbox": [
844
+ 174,
845
+ 641,
846
+ 825,
847
+ 780
848
+ ],
849
+ "page_idx": 8
850
+ },
851
+ {
852
+ "type": "text",
853
+ "text": "5.3 EXPERIMENTAL CONCLUSIONS ",
854
+ "text_level": 1,
855
+ "bbox": [
856
+ 176,
857
+ 799,
858
+ 431,
859
+ 813
860
+ ],
861
+ "page_idx": 8
862
+ },
863
+ {
864
+ "type": "text",
865
+ "text": "Our experiments confirm hypothesis $H l$ by showing that non-episodic is indeed substantially harder than episodic learning in standard static environments. However, our experiments also show that, for all considered tasks, introducing dynamic effects can allow non-episodic learning to succeed, in some cases to a degree that is comparable to the episodic setting, confirming hypothesis $H 3$ . However, this result is sensitive to the degree of stochasticity, suggesting that the specific dynamics and design of the environment has a large impact on learning. Based on this conclusion, we study how shaping the environment influences the learning process, and conclude that appropriate environment shaping can, in our tasks, supplant the need for more traditional reward shaping, confirming hypothesis $H 2$ . We further show the human users can effectively select environment shaping schedules manually, suggesting that this is an intuitive way to guide the learning of reinforcement learning agents. Our conclusions support the notion that ecological reinforcement learning – the study of the interaction between an RL agent and its environment – is an important topic for further study. ",
866
+ "bbox": [
867
+ 174,
868
+ 825,
869
+ 825,
870
+ 924
871
+ ],
872
+ "page_idx": 8
873
+ },
874
+ {
875
+ "type": "text",
876
+ "text": "",
877
+ "bbox": [
878
+ 174,
879
+ 103,
880
+ 823,
881
+ 174
882
+ ],
883
+ "page_idx": 9
884
+ },
885
+ {
886
+ "type": "text",
887
+ "text": "6 DISCUSSION ",
888
+ "text_level": 1,
889
+ "bbox": [
890
+ 174,
891
+ 194,
892
+ 310,
893
+ 210
894
+ ],
895
+ "page_idx": 9
896
+ },
897
+ {
898
+ "type": "text",
899
+ "text": "We study how certain properties of natural environments – namely, non-episodic learning without resets, simple “fundamental drive” reward functions, and dynamic environments that evolve on their own even when the agent does not actively intervene – affect the reinforcement learning process. We use the term ecological reinforcement learning to refer to this sort of study, which aims to analyze interactions between RL agents and the environment in which learning occurs. Although these properties by themselves tend to make learning harder, we find that environments that exhibit several of these traits can actually be easier to learn in, and agents trained in such settings can actually outperform agents trained in more conventional episodic settings on the same evaluation tasks. We conclude that in dynamic environments, the variability of situations created by the environment’s dynamics and simple rewards that are difficult for the agent to exploit can create a kind of natural curriculum that guides an agent through the emergence of increasingly complex behaviors. ",
900
+ "bbox": [
901
+ 174,
902
+ 227,
903
+ 825,
904
+ 378
905
+ ],
906
+ "page_idx": 9
907
+ },
908
+ {
909
+ "type": "text",
910
+ "text": "Aside from these potentially surprising observations, the framework of ecological reinforcement learning also points to a new way to approach the design of RL agents. While reward function design is typically considered the primary modality for specifying tasks to RL agents, ecological reinforcement learning suggests that the form and structure of the environment can help to guide the emergence and specification of skills. Combined with the guidance and curricula afforded by natural environments, this suggests that studying and systematizing the interaction between RL agents and various environment properties is an important and interesting direction for future research. ",
911
+ "bbox": [
912
+ 174,
913
+ 386,
914
+ 825,
915
+ 483
916
+ ],
917
+ "page_idx": 9
918
+ },
919
+ {
920
+ "type": "text",
921
+ "text": "REFERENCES ",
922
+ "text_level": 1,
923
+ "bbox": [
924
+ 174,
925
+ 506,
926
+ 285,
927
+ 520
928
+ ],
929
+ "page_idx": 9
930
+ },
931
+ {
932
+ "type": "text",
933
+ "text": "Maruan Al-Shedivat, Trapit Bansal, Yura Burda, Ilya Sutskever, Igor Mordatch, and Pieter Abbeel. Continuous adaptation via meta-learning in nonstationary and competitive environments. ArXiv, abs/1710.03641, 2017. ",
934
+ "bbox": [
935
+ 174,
936
+ 529,
937
+ 823,
938
+ 570
939
+ ],
940
+ "page_idx": 9
941
+ },
942
+ {
943
+ "type": "text",
944
+ "text": "Charles Beattie, Joel Z. Leibo, Denis Teplyashin, Tom Ward, Marcus Wainwright, Heinrich Kuttler, ¨ Andrew Lefrancq, Simon Green, V´ıctor Valdes, Amir Sadik, Julian Schrittwieser, Keith Ander- ´ son, Sarah York, Max Cant, Adam Cain, Adrian Bolton, Stephen Gaffney, Helen King, Demis Hassabis, Shane Legg, and Stig Petersen. Deepmind lab. CoRR, abs/1612.03801, 2016. URL http://arxiv.org/abs/1612.03801. ",
945
+ "bbox": [
946
+ 173,
947
+ 582,
948
+ 823,
949
+ 651
950
+ ],
951
+ "page_idx": 9
952
+ },
953
+ {
954
+ "type": "text",
955
+ "text": "Marc G. Bellemare, Yavar Naddaf, Joel Veness, and Michael H. Bowling. The arcade learning environment: An evaluation platform for general agents. In J. Artif. Intell. Res., 2013. ",
956
+ "bbox": [
957
+ 174,
958
+ 661,
959
+ 823,
960
+ 690
961
+ ],
962
+ "page_idx": 9
963
+ },
964
+ {
965
+ "type": "text",
966
+ "text": "Yoshua Bengio, Jer´ ome Louradour, Ronan Collobert, and Jason Weston. Curriculum learning. In ˆ ICML, 2009. ",
967
+ "bbox": [
968
+ 173,
969
+ 700,
970
+ 825,
971
+ 729
972
+ ],
973
+ "page_idx": 9
974
+ },
975
+ {
976
+ "type": "text",
977
+ "text": "Greg Brockman, Vicki Cheung, Ludwig Pettersson, Jonas Schneider, John Schulman, Jie Tang, and Wojciech Zaremba. Openai gym. ArXiv, abs/1606.01540, 2016. ",
978
+ "bbox": [
979
+ 173,
980
+ 739,
981
+ 823,
982
+ 768
983
+ ],
984
+ "page_idx": 9
985
+ },
986
+ {
987
+ "type": "text",
988
+ "text": "Tim Brys, Anna Harutyunyan, Halit Bener Suay, Sonia Chernova, Matthew E. Taylor, and Ann Nowe. Reinforcement learning from demonstration through shaping. In ´ IJCAI, 2015. ",
989
+ "bbox": [
990
+ 173,
991
+ 779,
992
+ 823,
993
+ 808
994
+ ],
995
+ "page_idx": 9
996
+ },
997
+ {
998
+ "type": "text",
999
+ "text": "Konstantinos Chatzilygeroudis, Vassilis Vassiliades, and Jean-Baptiste Mouret. Reset-free trialand-error learning for robot damage recovery. Robotics and Autonomous Systems, 100:236–250, 2018. ",
1000
+ "bbox": [
1001
+ 176,
1002
+ 818,
1003
+ 823,
1004
+ 859
1005
+ ],
1006
+ "page_idx": 9
1007
+ },
1008
+ {
1009
+ "type": "text",
1010
+ "text": "Maxime Chevalier-Boisvert, Lucas Willems, and Suman Pal. Minimalistic gridworld environment for openai gym. https://github.com/maximecb/gym-minigrid, 2018. ",
1011
+ "bbox": [
1012
+ 173,
1013
+ 871,
1014
+ 823,
1015
+ 898
1016
+ ],
1017
+ "page_idx": 9
1018
+ },
1019
+ {
1020
+ "type": "text",
1021
+ "text": "Sam Devlin and Daniel Kudenko. Dynamic potential-based reward shaping. In AAMAS, 2012. ",
1022
+ "bbox": [
1023
+ 173,
1024
+ 909,
1025
+ 790,
1026
+ 924
1027
+ ],
1028
+ "page_idx": 9
1029
+ },
1030
+ {
1031
+ "type": "text",
1032
+ "text": "Adrien Ecoffet, Joost Huizinga, Joel Lehman, Kenneth O. Stanley, and Jeff Clune. Go-explore: a new approach for hard-exploration problems. ArXiv, abs/1901.10995, 2019. ",
1033
+ "bbox": [
1034
+ 171,
1035
+ 103,
1036
+ 823,
1037
+ 132
1038
+ ],
1039
+ "page_idx": 10
1040
+ },
1041
+ {
1042
+ "type": "text",
1043
+ "text": "Eyal Even-Dar, Sham M. Kakade, and Yishay Mansour. Reinforcement learning in pomdps without resets. In IJCAI, 2005. ",
1044
+ "bbox": [
1045
+ 174,
1046
+ 140,
1047
+ 823,
1048
+ 170
1049
+ ],
1050
+ "page_idx": 10
1051
+ },
1052
+ {
1053
+ "type": "text",
1054
+ "text": "Benjamin Eysenbach, Shixiang Gu, Julian Ibarz, and Sergey Levine. Leave no trace: Learning to reset for safe and autonomous reinforcement learning. ArXiv, abs/1711.06782, 2017. ",
1055
+ "bbox": [
1056
+ 174,
1057
+ 179,
1058
+ 823,
1059
+ 208
1060
+ ],
1061
+ "page_idx": 10
1062
+ },
1063
+ {
1064
+ "type": "text",
1065
+ "text": "Carlos Florensa, David Held, Xinyang Geng, and Pieter Abbeel. Automatic goal generation for reinforcement learning agents. ArXiv, abs/1705.06366, 2017a. ",
1066
+ "bbox": [
1067
+ 173,
1068
+ 217,
1069
+ 823,
1070
+ 246
1071
+ ],
1072
+ "page_idx": 10
1073
+ },
1074
+ {
1075
+ "type": "text",
1076
+ "text": "Carlos Florensa, David Held, Markus Wulfmeier, Michael Zhang, and Pieter Abbeel. Reverse curriculum generation for reinforcement learning. In CoRL, 2017b. ",
1077
+ "bbox": [
1078
+ 174,
1079
+ 253,
1080
+ 823,
1081
+ 284
1082
+ ],
1083
+ "page_idx": 10
1084
+ },
1085
+ {
1086
+ "type": "text",
1087
+ "text": "Robert M French. Catastrophic forgetting in connectionist networks. Trends in cognitive sciences, 3(4):128–135, 1999. ",
1088
+ "bbox": [
1089
+ 173,
1090
+ 291,
1091
+ 823,
1092
+ 321
1093
+ ],
1094
+ "page_idx": 10
1095
+ },
1096
+ {
1097
+ "type": "text",
1098
+ "text": "Alex Graves, Marc G. Bellemare, Jacob Menick, Remi Munos, and Koray Kavukcuoglu. Automated ´ curriculum learning for neural networks. In ICML, 2017. ",
1099
+ "bbox": [
1100
+ 173,
1101
+ 330,
1102
+ 823,
1103
+ 359
1104
+ ],
1105
+ "page_idx": 10
1106
+ },
1107
+ {
1108
+ "type": "text",
1109
+ "text": "Shane Griffith, Kaushik Subramanian, Jonathan Scholz, Charles Lee Isbell, and Andrea Lockerd Thomaz. Policy shaping: Integrating human feedback with reinforcement learning. In NIPS, 2013. ",
1110
+ "bbox": [
1111
+ 176,
1112
+ 367,
1113
+ 823,
1114
+ 410
1115
+ ],
1116
+ "page_idx": 10
1117
+ },
1118
+ {
1119
+ "type": "text",
1120
+ "text": "William H. Guss, Cayden Codel, Katja Hofmann, Brandon Houghton, Noboru Kuno, Stephanie Milani, Sharada Mohanty, Diego Perez Liebana, Ruslan Salakhutdinov, Nicholay Topin, et al. The MineRL competition on sample efficient reinforcement learning using human priors. NeurIPS Competition Track, 2019. ",
1121
+ "bbox": [
1122
+ 173,
1123
+ 419,
1124
+ 825,
1125
+ 477
1126
+ ],
1127
+ "page_idx": 10
1128
+ },
1129
+ {
1130
+ "type": "text",
1131
+ "text": "Weiqiao Han, Sergey Levine, and Pieter Abbeel. Learning compound multi-step controllers under unknown dynamics. 2015 IEEE/RSJ International Conference on Intelligent Robots and Systems (IROS), pp. 6435–6442, 2015. ",
1132
+ "bbox": [
1133
+ 174,
1134
+ 484,
1135
+ 823,
1136
+ 529
1137
+ ],
1138
+ "page_idx": 10
1139
+ },
1140
+ {
1141
+ "type": "text",
1142
+ "text": "Nicolas Manfred Otto Heess, TB Dhruva, Srinivasan Sriram, Jay Lemmon, Josh Merel, Greg Wayne, Yuval Tassa, Tom Erez, Ziyu Wang, S. M. Ali Eslami, Martin A. Riedmiller, and David Silver. Emergence of locomotion behaviours in rich environments. ArXiv, abs/1707.02286, 2017. ",
1143
+ "bbox": [
1144
+ 176,
1145
+ 536,
1146
+ 823,
1147
+ 580
1148
+ ],
1149
+ "page_idx": 10
1150
+ },
1151
+ {
1152
+ "type": "text",
1153
+ "text": "Rein Houthooft, Xi Chen, Yan Duan, John Schulman, Filip De Turck, and Pieter Abbeel. Vime: Variational information maximizing exploration. In NIPS, 2016. ",
1154
+ "bbox": [
1155
+ 171,
1156
+ 588,
1157
+ 821,
1158
+ 617
1159
+ ],
1160
+ "page_idx": 10
1161
+ },
1162
+ {
1163
+ "type": "text",
1164
+ "text": "Matthew Johnson, Katja Hofmann, Tim Hutton, and David Bignell. The malmo platform for artificial intelligence experimentation. In Proceedings of the Twenty-Fifth International Joint Conference on Artificial Intelligence, IJCAI, 2016. ",
1165
+ "bbox": [
1166
+ 174,
1167
+ 626,
1168
+ 821,
1169
+ 670
1170
+ ],
1171
+ "page_idx": 10
1172
+ },
1173
+ {
1174
+ "type": "text",
1175
+ "text": "Arthur Juliani, Vincent-Pierre Berges, Esh Vckay, Yuan Gao, Hunter Henry, Marwan Mattar, and Danny Lange. Unity: A general platform for intelligent agents, 2018. ",
1176
+ "bbox": [
1177
+ 171,
1178
+ 678,
1179
+ 823,
1180
+ 708
1181
+ ],
1182
+ "page_idx": 10
1183
+ },
1184
+ {
1185
+ "type": "text",
1186
+ "text": "Sham M. Kakade and John Langford. Approximately optimal approximate reinforcement learning. In ICML, 2002. ",
1187
+ "bbox": [
1188
+ 173,
1189
+ 715,
1190
+ 823,
1191
+ 746
1192
+ ],
1193
+ "page_idx": 10
1194
+ },
1195
+ {
1196
+ "type": "text",
1197
+ "text": "Christos Kaplanis, Murray Shanahan, and Claudia Clopath. Continual reinforcement learning with complex synapses. ICML, abs/1802.07239, 2018. ",
1198
+ "bbox": [
1199
+ 171,
1200
+ 753,
1201
+ 823,
1202
+ 784
1203
+ ],
1204
+ "page_idx": 10
1205
+ },
1206
+ {
1207
+ "type": "text",
1208
+ "text": "Diederik P. Kingma and Jimmy Ba. Adam: A method for stochastic optimization. CoRR, abs/1412.6980, 2014. ",
1209
+ "bbox": [
1210
+ 171,
1211
+ 791,
1212
+ 823,
1213
+ 820
1214
+ ],
1215
+ "page_idx": 10
1216
+ },
1217
+ {
1218
+ "type": "text",
1219
+ "text": "James Kirkpatrick, Razvan Pascanu, Neil C. Rabinowitz, Joel Veness, Guillaume Desjardins, Andrei A. Rusu, Kieran Milan, John Quan, Tiago Ramalho, Agnieszka Grabska-Barwinska, Demis Hassabis, Claudia Clopath, Dharshan Kumaran, and Raia Hadsell. Overcoming catastrophic forgetting in neural networks. CoRR, abs/1612.00796, 2016. ",
1220
+ "bbox": [
1221
+ 173,
1222
+ 829,
1223
+ 825,
1224
+ 886
1225
+ ],
1226
+ "page_idx": 10
1227
+ },
1228
+ {
1229
+ "type": "text",
1230
+ "text": "M. Mccloskey. Catastrophic interference in connectionist networks: The sequential learning problem” the psychology. 1989. ",
1231
+ "bbox": [
1232
+ 171,
1233
+ 895,
1234
+ 820,
1235
+ 924
1236
+ ],
1237
+ "page_idx": 10
1238
+ },
1239
+ {
1240
+ "type": "text",
1241
+ "text": "Teodor Mihai Moldovan and Pieter Abbeel. Safe exploration in markov decision processes. ArXiv, abs/1205.4810, 2012. ",
1242
+ "bbox": [
1243
+ 173,
1244
+ 103,
1245
+ 823,
1246
+ 132
1247
+ ],
1248
+ "page_idx": 11
1249
+ },
1250
+ {
1251
+ "type": "text",
1252
+ "text": "Andrew Y. $\\mathrm { N g }$ , Daishi Harada, and Stuart J. Russell. Policy invariance under reward transformations: Theory and application to reward shaping. In ICML, 1999. ",
1253
+ "bbox": [
1254
+ 173,
1255
+ 140,
1256
+ 823,
1257
+ 170
1258
+ ],
1259
+ "page_idx": 11
1260
+ },
1261
+ {
1262
+ "type": "text",
1263
+ "text": "Shayegan Omidshafiei, Dong-Ki Kim, Miao Liu, Gerald Tesauro, Matthew Riemer, Christopher Amato, Murray Campbell, and Jonathan P. How. Learning to teach in cooperative multiagent reinforcement learning. In AAAI, 2018. ",
1264
+ "bbox": [
1265
+ 176,
1266
+ 178,
1267
+ 823,
1268
+ 222
1269
+ ],
1270
+ "page_idx": 11
1271
+ },
1272
+ {
1273
+ "type": "text",
1274
+ "text": "Ian Osband, Charles Blundell, Alexander Pritzel, and Benjamin Van Roy. Deep exploration via bootstrapped dqn. In NIPS, 2016. ",
1275
+ "bbox": [
1276
+ 169,
1277
+ 229,
1278
+ 825,
1279
+ 258
1280
+ ],
1281
+ "page_idx": 11
1282
+ },
1283
+ {
1284
+ "type": "text",
1285
+ "text": "Deepak Pathak, Pulkit Agrawal, Alexei A. Efros, and Trevor Darrell. Curiosity-driven exploration by self-supervised prediction. 2017 IEEE Conference on Computer Vision and Pattern Recognition Workshops (CVPRW), pp. 488–489, 2017. ",
1286
+ "bbox": [
1287
+ 173,
1288
+ 267,
1289
+ 825,
1290
+ 310
1291
+ ],
1292
+ "page_idx": 11
1293
+ },
1294
+ {
1295
+ "type": "text",
1296
+ "text": "Jette Randløv and Preben Alstrøm. Learning to drive a bicycle using reinforcement learning and shaping. In ICML, 1998. ",
1297
+ "bbox": [
1298
+ 171,
1299
+ 319,
1300
+ 823,
1301
+ 348
1302
+ ],
1303
+ "page_idx": 11
1304
+ },
1305
+ {
1306
+ "type": "text",
1307
+ "text": "Martin A. Riedmiller, Roland Hafner, Thomas Lampe, Michael Neunert, Jonas Degrave, Tom Van de Wiele, Volodymyr Mnih, Nicolas Manfred Otto Heess, and Jost Tobias Springenberg. Learning by playing solving sparse reward tasks from scratch. In ICML, 2018. ",
1308
+ "bbox": [
1309
+ 173,
1310
+ 356,
1311
+ 825,
1312
+ 400
1313
+ ],
1314
+ "page_idx": 11
1315
+ },
1316
+ {
1317
+ "type": "text",
1318
+ "text": "Mark B. Ring. Child: A first step towards continual learning. In Machine Learning, pp. 77–104, 1997. ",
1319
+ "bbox": [
1320
+ 173,
1321
+ 409,
1322
+ 823,
1323
+ 438
1324
+ ],
1325
+ "page_idx": 11
1326
+ },
1327
+ {
1328
+ "type": "text",
1329
+ "text": "Andrei A. Rusu, Neil C. Rabinowitz, Guillaume Desjardins, Hubert Soyer, James Kirkpatrick, Koray Kavukcuoglu, Razvan Pascanu, and Raia Hadsell. Progressive neural networks. ArXiv, abs/1606.04671, 2016. ",
1330
+ "bbox": [
1331
+ 174,
1332
+ 445,
1333
+ 826,
1334
+ 488
1335
+ ],
1336
+ "page_idx": 11
1337
+ },
1338
+ {
1339
+ "type": "text",
1340
+ "text": "Jonathan Schwarz, Jelena Luketina, Wojciech Marian Czarnecki, Agnieszka Grabska-Barwiska, Yee Whye Teh, Razvan Pascanu, and Raia Hadsell. Progress & compress: A scalable framework for continual learning. ArXiv, abs/1805.06370, 2018. ",
1341
+ "bbox": [
1342
+ 174,
1343
+ 497,
1344
+ 825,
1345
+ 540
1346
+ ],
1347
+ "page_idx": 11
1348
+ },
1349
+ {
1350
+ "type": "text",
1351
+ "text": "Hanul Shin, Jung Kwon Lee, Jaehong Kim, and Jiwon Kim. Continual learning with deep generative replay. In NeurNIPS, 2017. ",
1352
+ "bbox": [
1353
+ 173,
1354
+ 547,
1355
+ 823,
1356
+ 577
1357
+ ],
1358
+ "page_idx": 11
1359
+ },
1360
+ {
1361
+ "type": "text",
1362
+ "text": "David Silver, Aja Huang, Chris J. Maddison, Arthur Guez, Laurent Sifre, George van den Driessche, Julian Schrittwieser, Ioannis Antonoglou, Vedavyas Panneershelvam, Marc Lanctot, Sander Dieleman, Dominik Grewe, John Nham, Nal Kalchbrenner, Ilya Sutskever, Timothy P. Lillicrap, Madeleine Leach, Koray Kavukcuoglu, Thore Graepel, and Demis Hassabis. Mastering the game of go with deep neural networks and tree search. Nature, 529:484–489, 2016. ",
1363
+ "bbox": [
1364
+ 173,
1365
+ 585,
1366
+ 825,
1367
+ 656
1368
+ ],
1369
+ "page_idx": 11
1370
+ },
1371
+ {
1372
+ "type": "text",
1373
+ "text": "Avi Singh, Larry Yang, Kristian Hartikainen, Chelsea Finn, and Sergey Levine. End-to-end robotic reinforcement learning without reward engineering. ArXiv, abs/1904.07854, 2019. ",
1374
+ "bbox": [
1375
+ 169,
1376
+ 665,
1377
+ 823,
1378
+ 695
1379
+ ],
1380
+ "page_idx": 11
1381
+ },
1382
+ {
1383
+ "type": "text",
1384
+ "text": "Sainbayar Sukhbaatar, Ilya Kostrikov, Arthur Szlam, and Rob Fergus. Intrinsic motivation and automatic curricula via asymmetric self-play. ArXiv, abs/1703.05407, 2017. ",
1385
+ "bbox": [
1386
+ 171,
1387
+ 703,
1388
+ 823,
1389
+ 733
1390
+ ],
1391
+ "page_idx": 11
1392
+ },
1393
+ {
1394
+ "type": "text",
1395
+ "text": "Haoran Tang, Rein Houthooft, Davis Foote, Adam Stooke, Xi Chen, Yan Duan, John Schulman, Filip De Turck, and Pieter Abbeel. #exploration: A study of count-based exploration for deep reinforcement learning. In NIPS, 2016. ",
1396
+ "bbox": [
1397
+ 176,
1398
+ 739,
1399
+ 823,
1400
+ 784
1401
+ ],
1402
+ "page_idx": 11
1403
+ },
1404
+ {
1405
+ "type": "text",
1406
+ "text": "Emanuel Todorov, Tom Erez, and Yuval Tassa. Mujoco: A physics engine for model-based control. 2012 IEEE/RSJ International Conference on Intelligent Robots and Systems, pp. 5026–5033, 2012. ",
1407
+ "bbox": [
1408
+ 176,
1409
+ 792,
1410
+ 823,
1411
+ 834
1412
+ ],
1413
+ "page_idx": 11
1414
+ },
1415
+ {
1416
+ "type": "text",
1417
+ "text": "Hado van Hasselt, Arthur Guez, and David Silver. Deep reinforcement learning with double qlearning. In AAAI, 2015. ",
1418
+ "bbox": [
1419
+ 171,
1420
+ 843,
1421
+ 821,
1422
+ 872
1423
+ ],
1424
+ "page_idx": 11
1425
+ },
1426
+ {
1427
+ "type": "text",
1428
+ "text": "Rui Wang, Joel Lehman, Jeff Clune, and Kenneth O. Stanley. Paired open-ended trailblazer (POET): endlessly generating increasingly complex and diverse learning environments and their solutions. CoRR, abs/1901.01753, 2019a. ",
1429
+ "bbox": [
1430
+ 174,
1431
+ 881,
1432
+ 823,
1433
+ 924
1434
+ ],
1435
+ "page_idx": 11
1436
+ },
1437
+ {
1438
+ "type": "text",
1439
+ "text": "Rui Wang, Joel Lehman, Jeff Clune, and Kenneth O. Stanley. Paired open-ended trailblazer (poet): Endlessly generating increasingly complex and diverse learning environments and their solutions. ArXiv, abs/1901.01753, 2019b. ",
1440
+ "bbox": [
1441
+ 174,
1442
+ 103,
1443
+ 823,
1444
+ 146
1445
+ ],
1446
+ "page_idx": 12
1447
+ },
1448
+ {
1449
+ "type": "text",
1450
+ "text": "Tianhe Yu, Deirdre Quillen, Zhanpeng He, Ryan Julian, Karol Hausman, Chelsea Finn, and Sergey Levine. Meta-world: A benchmark and evaluation for multi-task and meta reinforcement learning. CoRL, 2019. ",
1451
+ "bbox": [
1452
+ 174,
1453
+ 155,
1454
+ 823,
1455
+ 196
1456
+ ],
1457
+ "page_idx": 12
1458
+ },
1459
+ {
1460
+ "type": "text",
1461
+ "text": "Wenhao Yu, Greg Turk, and Chuanjian Liu. Learning symmetric and low-energy locomotion. ACM Trans. Graph., 37:144:1–144:12, 2018. ",
1462
+ "bbox": [
1463
+ 171,
1464
+ 207,
1465
+ 823,
1466
+ 234
1467
+ ],
1468
+ "page_idx": 12
1469
+ },
1470
+ {
1471
+ "type": "text",
1472
+ "text": "A AGENT ARCHITECTURE AND TRAINING ",
1473
+ "text_level": 1,
1474
+ "bbox": [
1475
+ 176,
1476
+ 102,
1477
+ 540,
1478
+ 118
1479
+ ],
1480
+ "page_idx": 13
1481
+ },
1482
+ {
1483
+ "type": "text",
1484
+ "text": "We use the same agent network architecture and RL algorithm for all our experiments with minor modification to account for the properties we vary such as reset free RL. Agents are parametrized by an MLP. The environment grid size is $8 \\times 8$ . The partial grid observation is flattened and processed by a 2 layer MLP of size (64, 64, 32). The inventory observation is processed by a 2 layer MLP of size (16, 16, 16). These outputs are concatenated and then processed by a final MLP of size (16, action dim). All layers are followed by ReLU nonlinearities except the final layer which uses a softmax to output the action distribution. ",
1485
+ "bbox": [
1486
+ 173,
1487
+ 133,
1488
+ 825,
1489
+ 231
1490
+ ],
1491
+ "page_idx": 13
1492
+ },
1493
+ {
1494
+ "type": "text",
1495
+ "text": "We train the agents using double DQN (van Hasselt et al., 2015) and the Adam optimizer (Kingma & Ba, 2014) with a learning rate of 0.0001, selected by sweeping across a range of learning rates, with results shown in Figure 6. Training is done in batch mode such that we alternate between collecting 500 environment steps and taking 500 gradient steps (with batch size 256) over the replay buffer of size 5e5. For environments with resets, the horizon length is set to 200. We swept over various horizon lengths and found 200 to work the best. We also tried setting the horizon length very short (20 and 50) to help with the episodic methods but found no effect. We use epsilon greedy exploration for the policy where epsilon starts at 1 and decays linearly by 0.0001 each timestep to 0.1. For each training method we run 10 random seeds. ",
1496
+ "bbox": [
1497
+ 173,
1498
+ 237,
1499
+ 825,
1500
+ 363
1501
+ ],
1502
+ "page_idx": 13
1503
+ },
1504
+ {
1505
+ "type": "image",
1506
+ "img_path": "images/442b293f21b72a483c6e1df5c8ca44c583cb634441a9a3cf3a648878ac9172fd.jpg",
1507
+ "image_caption": [
1508
+ "Figure 6: Proportion of validation tasks solved in each setting. Agents learning in static non-episodic environments struggle to learn useful behaviors, while agents learning in dynamic non-episodic environments are substantially more successful. Episodic learning is easier than non-episodic learning on the first task, but non-episodic learning in dynamic environments is almost as effective as episodic learning on the hunting task. "
1509
+ ],
1510
+ "image_footnote": [],
1511
+ "bbox": [
1512
+ 174,
1513
+ 377,
1514
+ 792,
1515
+ 497
1516
+ ],
1517
+ "page_idx": 13
1518
+ },
1519
+ {
1520
+ "type": "text",
1521
+ "text": "B HUMAN GUIDED ENVIRONMENT SHAPING ",
1522
+ "text_level": 1,
1523
+ "bbox": [
1524
+ 174,
1525
+ 592,
1526
+ 563,
1527
+ 608
1528
+ ],
1529
+ "page_idx": 13
1530
+ },
1531
+ {
1532
+ "type": "image",
1533
+ "img_path": "images/dbd4f5c771bffa7ecaa38ce25688e4b83d38c26686609d1ec4af82b7bdecd8fc.jpg",
1534
+ "image_caption": [
1535
+ "Figure 7: Performance of human guided environment shaping. We ask a human user to interactively shape the environment and observe the human can effectively guide the shaping compared to a predefined environment shaping schedule. "
1536
+ ],
1537
+ "image_footnote": [],
1538
+ "bbox": [
1539
+ 238,
1540
+ 625,
1541
+ 743,
1542
+ 718
1543
+ ],
1544
+ "page_idx": 13
1545
+ },
1546
+ {
1547
+ "type": "text",
1548
+ "text": "In the real world, environment shaping can be done by humans. In this section, we study if a human user can effectively guide the environment shaping during training, instead of using our predefined curriculum. We use the tool-making task in the non-episodic setting with sparse reward. The form of environment shaping is setting the distance from the agent within which resources can spawn, which can be increased over time to “teach” the agent to reach further-away resources. The human is tasked with providing this distance schedule interactively based on the performance of the agent. At each interaction, the human is given a video demonstrating the agent’s current behavior on the training environment and a graph with the agent’s validation performance to date. The human user produces two numbers: the resource spawn distance and for how many training epochs to continue training before requesting another input. This allows the human to adaptively adjust the environment shaping depending on the agent’s performance and minimize the amount of human supervision. Interestingly, the human controlled environment shaping does better than our linearly annealed environment shaping, as shown in Figure 7. The human user specifies a slower resource schedule than our programmed environment shaping. ",
1549
+ "bbox": [
1550
+ 173,
1551
+ 799,
1552
+ 825,
1553
+ 924
1554
+ ],
1555
+ "page_idx": 13
1556
+ },
1557
+ {
1558
+ "type": "text",
1559
+ "text": "",
1560
+ "bbox": [
1561
+ 173,
1562
+ 103,
1563
+ 825,
1564
+ 174
1565
+ ],
1566
+ "page_idx": 14
1567
+ },
1568
+ {
1569
+ "type": "image",
1570
+ "img_path": "images/33971ce3a2b21989ef9c693e12eed00ff85c9dc0493cdcebcbd8707cf6b4ce63.jpg",
1571
+ "image_caption": [
1572
+ "C ROBUSTNESS OF ENVIRONMENT SHAPING VS. REWARD SHAPING ",
1573
+ "Figure 8: Performance of environment shaping and reward shaping on the axe-making task in an environment with wall obstacles. The distance-based reward suffers while environment shaping, despite operating off of a sparse reward, obtains peak validation performance. We find that this advantage in robustness of environment shaping is present in both the episodic and non-episodic settings, but is enhanced in the former. "
1574
+ ],
1575
+ "image_footnote": [],
1576
+ "bbox": [
1577
+ 173,
1578
+ 233,
1579
+ 825,
1580
+ 363
1581
+ ],
1582
+ "page_idx": 14
1583
+ },
1584
+ {
1585
+ "type": "text",
1586
+ "text": "We examine the robustness of the different methods of shaping the learning of the agent by studying the performance of the agent in a more challenging environment which contain walls and are more maze-like. This makes the environment less easily navigable and provides more chances for the agent to become trapped in a particular region of the state space. We find in Figure 8 that environment shaping is the best-performing method under this structural challenge under both episodic and non-episodic settings. However, the episodic setting demonstrates a larger gap between the performance of environment shaping and that of reward shaping. We visualize the state visitation counts of the agent under the different shaping methods in Figures 9 (non-episodic) and 10 (episodic) to understand the differences in performance. In the non-episodic setting, the distance-based reward shaping results in the agent getting trapped in corners and therefore spending a high proportion of time there. This demonstrates that reward shaping can be easier to exploit as it alters the true objective. In contrast environment shaping methods results in greater coverage of the grid. This is consistent with their superior performance in Figure 8. ",
1587
+ "bbox": [
1588
+ 174,
1589
+ 458,
1590
+ 825,
1591
+ 638
1592
+ ],
1593
+ "page_idx": 14
1594
+ },
1595
+ {
1596
+ "type": "text",
1597
+ "text": "D LEARNED BEHAVIOR ",
1598
+ "text_level": 1,
1599
+ "bbox": [
1600
+ 174,
1601
+ 661,
1602
+ 385,
1603
+ 676
1604
+ ],
1605
+ "page_idx": 14
1606
+ },
1607
+ {
1608
+ "type": "text",
1609
+ "text": "In Figure 11, we demonstrate the learned behavior under environment shaping with a sparse reward and reward shaping with the one-time reward. With environment shaping, the agent accomplishes the desired task in 15 timesteps. On the other hand, despite the fact that the one-time reward provides a reward only for the first interaction with the metal, the reward-shaped agent obtains the metal and repeatedly drops and picks it up afterwards, eventually failing to solve it within the allotted 100 timesteps, demonstrating the biasing effect of reward shaping. ",
1610
+ "bbox": [
1611
+ 174,
1612
+ 694,
1613
+ 825,
1614
+ 777
1615
+ ],
1616
+ "page_idx": 14
1617
+ },
1618
+ {
1619
+ "type": "text",
1620
+ "text": "In Figure 12, we visualize trajectories from the hunting environment and analyze the learned behavior of two environment-shaped agents, a distance-based reward shaped agent, and a one-time reward shaped agent. The first environment-shaped agent is able to use resources that start out on opposite sides of the world, such that they are never both in view of the agent at the same time. This is notable because the form of environment shaping used is one wherein the agent is provided with resources near it and gradually weaned off over time. The second environment-shaped agent, while presented with a task in which the resources start out on adjacent squares, faces the challenge of the deer moving right before the agent approaches it. We observe that the trained policy is able to make a second attempt at catching the deer, and is successful. The agent trained with distance-based reward shaping displays suboptimal behavior of approaching the axe and then the deer while failing to interact with either, which can be seen as a bias resulting from a reward that incentivizes proximity to resources. Finally, the agent trained with one-time reward shaping also shows suboptimal behavior that is explained by the biases of the reward. The agent picks up the axe and then remains stationary throughout the remainder of the trajectory, failing to hunt the deer due to a reward that provides it a small reward bonus for accomplishing the first portion of the task. ",
1621
+ "bbox": [
1622
+ 174,
1623
+ 785,
1624
+ 825,
1625
+ 924
1626
+ ],
1627
+ "page_idx": 14
1628
+ },
1629
+ {
1630
+ "type": "image",
1631
+ "img_path": "images/a96d248b8c8ce80a18a381840894e7c0f1e801edee7ac45c210e47bc5edb7c12.jpg",
1632
+ "image_caption": [
1633
+ "Figure 9: State visitation counts for the non-episodic setting visualized at 4 stages during training under the different methods of shaping. Yellow corresponds to high visitation, dark purple corresponds to low visitation. The darkest purple around the borders and in the map correspond to walls, which cannot be traversed by the agent. We find that the distance-based reward shaping results in the agent getting stuck in the corners of the grid, while the one-time reward and both environment shaping methods result in the most uniform state visitation distribution over the grid during training, indicating that they were able to traverse the grid and explaining their superior performance shown in Figure 8. "
1634
+ ],
1635
+ "image_footnote": [],
1636
+ "bbox": [
1637
+ 302,
1638
+ 97,
1639
+ 709,
1640
+ 613
1641
+ ],
1642
+ "page_idx": 15
1643
+ },
1644
+ {
1645
+ "type": "text",
1646
+ "text": "",
1647
+ "bbox": [
1648
+ 173,
1649
+ 766,
1650
+ 825,
1651
+ 837
1652
+ ],
1653
+ "page_idx": 15
1654
+ },
1655
+ {
1656
+ "type": "image",
1657
+ "img_path": "images/1333f5e91dd24befb57d79137f3aea567ff20cc9a04a50615a5bb458b1cab812.jpg",
1658
+ "image_caption": [
1659
+ "Figure 10: State visitation counts for the episodic setting visualized at 4 stages during training under the different methods of shaping. Yellow corresponds to high visitation, dark purple corresponds to low visitation. The darkest purple around the borders and in the map correspond to walls, which cannot be traversed by the agent. All shaping methods result in a more uniform state visitation distribution than in the non-episodic setting in Figure 9, which aligns with intuition since the resets in the episodic setting help the agent get “unstuck.” "
1660
+ ],
1661
+ "image_footnote": [],
1662
+ "bbox": [
1663
+ 302,
1664
+ 103,
1665
+ 709,
1666
+ 616
1667
+ ],
1668
+ "page_idx": 16
1669
+ },
1670
+ {
1671
+ "type": "image",
1672
+ "img_path": "images/59e3c911bca86d9277dc5c3fd787b86ebf393f308c24c0b7e6efbe41ad8cb55d.jpg",
1673
+ "image_caption": [
1674
+ "Figure 11: Sample trajectories on validation environments demonstrating learned behavior trained under environment shaping with sparse reward (left) as well as under shaping with the one-time reward (right), both in the non-episodic setting. The shaded region represents the agent’s ego-centric partial view of the environment. "
1675
+ ],
1676
+ "image_footnote": [],
1677
+ "bbox": [
1678
+ 200,
1679
+ 741,
1680
+ 732,
1681
+ 863
1682
+ ],
1683
+ "page_idx": 16
1684
+ },
1685
+ {
1686
+ "type": "image",
1687
+ "img_path": "images/2595169463c02b01ea535e5d6c22dee3a2bb551b6a0e10ea27a21b53ea470fa9.jpg",
1688
+ "image_caption": [
1689
+ "Figure 12: Sample trajectories on validation environments demonstrating learned behavior trained under environment shaping with sparse reward (top two), distance-based reward shaping (third), and one-time reward shaping (bottom), all in the non-episodic setting. While the environment shaped agents accomplish the desired task within 15 timesteps, biased task specification in the last two result in interpretable but suboptimal behavior. The distance-based reward shaped agent goes to the correct resources in order, but without interacting with either. The one-time reward shaped agent picks up the axe, but fails to do anything afterwards. Both reward shaped agents here fail to solve the task within the allotted 100 timesteps. "
1690
+ ],
1691
+ "image_footnote": [],
1692
+ "bbox": [
1693
+ 217,
1694
+ 45,
1695
+ 1000,
1696
+ 794
1697
+ ],
1698
+ "page_idx": 17
1699
+ }
1700
+ ]
parse/train/S1xxx64YwH/S1xxx64YwH_middle.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/S1xxx64YwH/S1xxx64YwH_model.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/SyyGPP0TZ/SyyGPP0TZ.md ADDED
@@ -0,0 +1,257 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # REGULARIZING AND OPTIMIZING LSTM LANGUAGE MODELS
2
+
3
+ Stephen Merity, Nitish Shirish Keskar & Richard Socher Salesforce Research
4
+ Palo Alto, CA 94301, USA
5
+ {smerity,nkeskar,rsocher}@salesforce.com
6
+
7
+ # ABSTRACT
8
+
9
+ In this paper, we consider the specific problem of word-level language modeling and investigate strategies for regularizing and optimizing LSTM-based models. We propose the weight-dropped LSTM, which uses DropConnect on hidden-tohidden weights, as a form of recurrent regularization. Further, we introduce NTAvSGD, a non-monotonically triggered (NT) variant of the averaged stochastic gradient method (AvSGD), wherein the averaging trigger is determined using a NT condition as opposed to being tuned by the user. Using these and other regularization strategies, our AvSGD Weight-Dropped LSTM (AWD-LSTM) achieves state-of-the-art word level perplexities on two data sets: 57.3 on Penn Treebank and 65.8 on WikiText-2. In exploring the effectiveness of a neural cache in conjunction with our proposed model, we achieve an even lower state-of-the-art perplexity of 52.8 on Penn Treebank and 52.0 on WikiText-2. We also explore the viability of the proposed regularization and optimization strategies in the context of the quasi-recurrent neural network (QRNN) and demonstrate comparable performance to the AWD-LSTM counterpart. The code for reproducing the results is open sourced and is available at https://github.com/salesforce/ awd-lstm-lm.
10
+
11
+ # 1 INTRODUCTION
12
+
13
+ Effective regularization techniques for deep learning have been the subject of much research in recent years. Given the over-parameterization of neural networks, generalization performance crucially relies on the ability to regularize the models sufficiently. Strategies such as dropout (Srivastava et al., 2014) and batch normalization (Ioffe & Szegedy, 2015) have found great success and are now ubiquitous in feed-forward and convolutional neural networks. Na¨ıvely applying these approaches to the case of recurrent neural networks (RNNs) has not been highly successful however. Many recent works have hence been focused on the extension of these regularization strategies to RNNs; we briefly discuss some of them below.
14
+
15
+ A na¨ıve application of dropout (Srivastava et al., 2014) to an RNN’s hidden state is ineffective as it disrupts the RNN’s ability to retain long term dependencies (Zaremba et al., 2014). Gal & Ghahramani (2016) propose overcoming this problem by retaining the same dropout mask across multiple time steps as opposed to sampling a new binary mask at each timestep. Another approach is to regularize the network through limiting updates to the RNN’s hidden state. One such approach is taken by Semeniuta et al. (2016) wherein the authors drop updates to network units, specifically the input gates of the LSTM, in lieu of the units themselves. This is reminiscent of zoneout (Krueger et al., 2016) where updates to the hidden state may fail to occur for randomly selected neurons.
16
+
17
+ Instead of operating on the RNN’s hidden states, one can regularize the network through restrictions on the recurrent matrices as well. This can be done either through restricting the capacity of the matrix (Arjovsky et al., 2016; Wisdom et al., 2016; Jing et al., 2016) or through element-wise interactions (Balduzzi & Ghifary, 2016; Bradbury et al., 2016; Seo et al., 2016).
18
+
19
+ Other forms of regularization explicitly act upon activations such as batch normalization (Ioffe & Szegedy, 2015), recurrent batch normalization (Cooijmans et al., 2016), and layer normalization (Ba et al., 2016). These all introduce additional training parameters and can complicate the training process while increasing the sensitivity of the model.
20
+
21
+ In this work, we investigate a set of regularization strategies that are not only highly effective but which can also be used with no modification to existing LSTM implementations. The weightdropped LSTM applies recurrent regularization through a DropConnect mask on the hidden-tohidden recurrent weights. Other strategies include the use of randomized-length backpropagation through time (BPTT), embedding dropout, activation regularization (AR), and temporal activation regularization (TAR).
22
+
23
+ As no modifications are required of the LSTM implementation these regularization strategies are compatible with black box libraries, such as NVIDIA cuDNN, which can be many times faster than na¨ıve LSTM implementations.
24
+
25
+ Effective methods for training deep recurrent networks have also been a topic of renewed interest. Once a model has been defined, the training algorithm used is required to not only find a good minimizer of the loss function but also converge to such a minimizer rapidly. The choice of the optimizer is even more important in the context of regularized models since such strategies, especially the use of dropout, can impede the training process. Stochastic gradient descent (SGD), and its variants such as Adam (Kingma & Ba, 2014) and RMSprop (Tieleman & Hinton, 2012) are amongst the most popular training methods. These methods iteratively reduce the training loss through scaled (stochastic) gradient steps. In particular, Adam has been found to be widely applicable despite requiring less tuning of its hyperparameters. In the context of word-level language modeling, past work has empirically found that SGD outperforms other methods in not only the final loss but also in the rate of convergence. This is in agreement with recent evidence pointing to the insufficiency of adaptive gradient methods (Wilson et al., 2017).
26
+
27
+ Given the success of SGD, especially within the language modeling domain, we investigate the use of averaged SGD (AvSGD) (Polyak & Juditsky, 1992) which is known to have superior theoretical guarantees. AvSGD carries out iterations similar to SGD, but instead of returning the last iterate as the solution, returns an average of the iterates past a certain, tuned, threshold $T$ . This threshold $T$ is typically tuned and has a direct impact on the performance of the method. We propose a variant of AvSGD where $T$ is determined on the fly through a non-monotonic criterion and show that it achieves better training outcomes compared to SGD.
28
+
29
+ # 2 WEIGHT-DROPPED LSTM
30
+
31
+ We refer to the mathematical formulation of the LSTM,
32
+
33
+ $$
34
+ \begin{array} { r l } & { { i _ { t } } = \sigma ( { W ^ { i } } { x _ { t } } + { U ^ { i } } { h _ { t - 1 } } ) } \\ & { { f _ { t } } = \sigma ( { W ^ { f } } { x _ { t } } + { U ^ { f } } { h _ { t - 1 } } ) } \\ & { { o _ { t } } = \sigma ( { W ^ { o } } { x _ { t } } + { U ^ { o } } { h _ { t - 1 } } ) } \\ & { { { \tilde { c } } _ { t } } = \operatorname { t a n h } ( { W ^ { c } } { x _ { t } } + { U ^ { c } } { h _ { t - 1 } } ) } \\ & { { c _ { t } } = i _ { t } \odot { { \tilde { c } } _ { t } } + { f _ { t } } \odot + { { \tilde { c } } _ { t - 1 } } } \\ & { { h _ { t } } = o _ { t } \odot \operatorname { t a n h } ( { c _ { t } } ) } \end{array}
35
+ $$
36
+
37
+ where $[ W ^ { i } , W ^ { f } , W ^ { o } , U ^ { i } , U ^ { f } , U ^ { o } ]$ are weight matrices, $x _ { t }$ is the vector input to the timestep $t$ , $h _ { t }$ is the current exposed hidden state, $c _ { t }$ is the memory cell state, and $\odot$ is element-wise multiplication.
38
+
39
+ Preventing overfitting within the recurrent connections of an RNN has been an area of extensive research in language modeling. The majority of previous recurrent regularization techniques have acted on the hidden state vector $h _ { t - 1 }$ , most frequently introducing a dropout operation between timesteps, or performing dropout on the update to the memory state $c _ { t }$ . These modifications to a standard LSTM prevent the use of black box RNN implementations that may be many times faster due to low-level hardware-specific optimizations.
40
+
41
+ We propose the use of DropConnect (Wan et al., 2013) on the recurrent hidden to hidden weight matrices which does not require any modifications to an RNN’s formulation. As the dropout operation is applied once to the weight matrices, before the forward and backward pass, the impact on training speed is minimal and any standard RNN implementation can be used, including inflexible but highly optimized black box LSTM implementations such as NVIDIA’s cuDNN LSTM.
42
+
43
+ By performing DropConnect on the hidden-to-hidden weight matrices $[ U ^ { i } , U ^ { f } , U ^ { o } , U ^ { c } ]$ within the LSTM, we can prevent overfitting from occurring on the recurrent connections of the LSTM. This regularization technique would also be applicable to preventing overfitting on the recurrent weight matrices of other RNN cells.
44
+
45
+ As the same weights are reused over multiple timesteps, the same individual dropped weights remain dropped for the entirety of the forward and backward pass. The result is similar to variational dropout, which applies the same dropout mask to recurrent connections within the LSTM by performing dropout on $h _ { t - 1 }$ , except that the dropout is applied to the recurrent weights. DropConnect could also be used on the non-recurrent weights of the LSTM $[ W ^ { i } , W ^ { f } , W ^ { o } ]$ though our focus was on preventing overfitting on the recurrent connection.
46
+
47
+ # 3 OPTIMIZATION
48
+
49
+ SGD is among the most popular methods for training deep learning models across various modalities including computer vision, natural language processing, and reinforcement learning. The training of deep networks can be posed as a non-convex empirical risk minimization problem
50
+
51
+ $$
52
+ \operatorname* { m i n } _ { w } \quad \frac { 1 } { N } \sum _ { i = 1 } ^ { N } f _ { i } ( w ) ,
53
+ $$
54
+
55
+ where $f _ { i }$ is the loss function for the $i ^ { t h }$ data point, $w$ are the weights of the network, and the expectation is taken over the data. In this context, given a sequence of learning rates, $\gamma _ { k }$ , SGD iteratively takes steps of the form
56
+
57
+ $$
58
+ w _ { k + 1 } = w _ { k } - \gamma _ { k } \hat { \nabla } f ( w _ { k } ) ,
59
+ $$
60
+
61
+ where the subscript denotes the iteration number and the $\hat { \nabla }$ denotes a stochastic gradient that may be computed on a minibatch of data points. SGD demonstrably performs well in practice and also possesses several attractive theoretical properties such as linear convergence (Bottou et al., 2016), saddle point avoidance (Panageas & Piliouras, 2016) and better generalization performance (Hardt et al., 2015). For the specific task of neural language modeling, traditionally SGD without momentum has been found to outperform other algorithms such as momentum SGD (Sutskever et al., 2013), Adam (Kingma & Ba, 2014), Adagrad (Duchi et al., 2011) and RMSProp (Tieleman & Hinton, 2012) by a statistically significant margin.
62
+
63
+ Motivated by this observation, we investigate averaged SGD (AvSGD) to further improve the training process. AvSGD has been analyzed in depth theoretically and many surprising results have been shown including its asymptotic second-order convergence (Polyak & Juditsky, 1992; Mandt et al., 2017). AvSGD tsolution, returns $\textstyle { \frac { 1 } { ( K - T + 1 ) } } \sum _ { i = T } ^ { K } w _ { i }$ to equa, where $K$ n (1) but instead of returning the lastis the total number of iterations and $T < K$ s theis a user-specified averaging trigger.
64
+
65
+ Despite its theoretical appeal, AvSGD has found limited practical use in training of deep networks. This may be in part due to unclear tuning guidelines for the learning-rate schedule $\gamma _ { k }$ and averaging trigger $T$ . If the averaging is triggered too soon, the efficacy of the method is impacted, and if it is triggered too late, many additional iterations may be needed to converge to the solution. In this section, we describe a non-monotonically triggered variant of AvSGD (NT-AvSGD), which obviates the need for tuning $T$ . Further, the algorithm uses a constant learning rate throughout the experiment and hence no further tuning is necessary for the decay scheduling.
66
+
67
+ Ideally, averaging needs to be triggered when the SGD iterates converge to a steady-state distribution (Mandt et al., 2017). This is roughly equivalent to the convergence of SGD to a neighborhood around a solution. In the case of SGD, certain learning-rate reduction strategies such as the stepwise strategy analogously reduce the learning rate by a fixed quantity at such a point. A common strategy employed in language modeling is to reduce the learning rates by a fixed proportion when the performance of the model’s primary metric (such as perplexity) worsens or stagnates. Along the same lines, one could make a triggering decision based on the performance of the model on the
68
+
69
+ # Algorithm 1 Non-monotonically Triggered AvSGD (NT-AvSGD)
70
+
71
+ Inputs: Initial point $w _ { 0 }$ , learning rate $\gamma$ , logging interval L, non-monotone interval n.
72
+ 1: Initialize $k 0$ , $t \gets 0$ , $T \gets 0$ , $\mathrm { 1 0 9 5 [ ] }$
73
+ 2: while stopping criterion not met do
74
+ 3: Compute stochastic gradient $\hat { \nabla } f ( \boldsymbol { w } _ { k } )$ and take SGD step (1).
75
+ 4: if $\mod ( k , L ) = 0$ and $T = 0$ then
76
+ 5: Compute validation perplexity $v$ .
77
+ 6: if $t > n$ and $v > \qquad \mathrm { m i n } \qquad \mathrm { l o q s [ 1 ] ~ } \mathbf { t h e l }$ n
78
+ l∈{0,··· ,t−n−1}
79
+ 7: Set $T \gets k$
80
+ 8: end if
81
+ 9: Append $v$ to logs
82
+ 10: $t \gets t + 1$
83
+ 11: end if
84
+ 12: k ← k + 1
85
+ 13: end while
86
+ return Pki=T wi
87
+
88
+ validation set. However, instead of averaging immediately after the validation metric worsens, we propose a non-monotonic criterion that conservatively triggers the averaging when the validation metric fails to improve for multiple cycles; see Algorithm 1. Given that the choice of triggering is irreversible, this conservatism ensures that the randomness of training does not play a major role in the decision. Analogous strategies have also been proposed for learning-rate reduction in SGD (Keskar & Saon, 2015).
89
+
90
+ While the algorithm introduces two additional hyperparameters, the logging interval $L$ and nonmonotone interval $n$ , we found that setting $L$ to be the number of iterations in an epoch and $n = 5$ worked well across various models and data sets. As such, we use this setting in all of our NTAvSGD experiments in the following section and demonstrate that it achieves better training outcomes as compared to SGD.
91
+
92
+ # 4 EXTENDED REGULARIZATION TECHNIQUES
93
+
94
+ In addition to the regularization and optimization techniques above, we explored additional regularization techniques that aimed to improve data efficiency during training and to prevent overfitting of the RNN model.
95
+
96
+ # 4.1 VARIABLE LENGTH BACKPROPAGATION SEQUENCES
97
+
98
+ Given a fixed sequence length that is used to break a data set into fixed length batches, the data set is not efficiently used. To illustrate this, imagine being given 100 elements to perform backpropagation through with a fixed backpropagation through time (BPTT) window of 10. Any element divisible by 10 will never have any elements to backprop into, no matter how many times you may traverse the data set. Indeed, the backpropagation window that each element receives is equal to $i$ mod 10 where $i$ is the element’s index. This is data inefficient, preventing $\frac { 1 } { 1 0 }$ of the data set from ever being able to improve itself in a recurrent fashion, and resulting in $\frac { 8 } { 1 0 }$ of the remaining elements receiving only a partial backpropagation window compared to the full possible backpropagation window of length 10.
99
+
100
+ To prevent such inefficient data usage, we randomly select the sequence length for the forward and backward pass in two steps. First, we select the base sequence length to be seq with probability $p$ and $\frac { \mathrm { s e q } } { 2 }$ with probability $1 - p$ , where $p$ is a high value approaching 1. This spreads the starting point for the BPTT window beyond the base sequence length. We then select the sequence length according to $\mathcal { N } ( \mathrm { s e q } , s )$ , where seq is the base sequence length and $s$ is the standard deviation. This jitters the starting point such that it doesn’t always fall on a specific word divisible by seq or $\frac { \mathrm { s e q } } { 2 }$ . From these, the sequence length more efficiently uses the data set, ensuring that when given enough epochs all the elements in the data set experience a full BPTT window, while ensuring the average sequence length remains around the base sequence length for computational efficiency.
101
+
102
+ During training, we rescale the learning rate depending on the length of the resulting sequence compared to the original specified sequence length. The rescaling step is necessary as sampling arbitrary sequence lengths with a fixed learning rate favors short sequences over longer ones. This linear scaling rule has been noted as important for training large scale minibatch SGD without loss of accuracy (Goyal et al., 2017) and is a component of unbiased truncated backpropagation through time (Tallec & Ollivier, 2017).
103
+
104
+ # 4.2 VARIATIONAL DROPOUT
105
+
106
+ In standard dropout, a new binary dropout mask is sampled each and every time the dropout function is called. New dropout masks are sampled even if the given connection is repeated, such as the input $x _ { 0 }$ to an LSTM at timestep $t = 0$ receiving a different dropout mask than the input $x _ { 1 }$ fed to the same LSTM at $t = 1$ . A variant of this, variational dropout (Gal & Ghahramani, 2016), samples a binary dropout mask only once upon the first call and then to repeatedly use that locked dropout mask for all repeated connections within the forward and backward pass.
107
+
108
+ While we propose using DropConnect rather than variational dropout to regularize the hidden-tohidden transition within an RNN, we use variational dropout for all other dropout operations, specifically using the same dropout mask for all inputs and outputs of the LSTM within a given forward and backward pass. Each example within the minibatch uses a unique dropout mask, rather than a single dropout mask being used over all examples, ensuring diversity in the elements dropped out.
109
+
110
+ # 4.3 EMBEDDING DROPOUT
111
+
112
+ Following Gal & Ghahramani (2016), we employ embedding dropout. This is equivalent to performing dropout on the embedding matrix at a word level, where the dropout is broadcast across all the word vector’s embedding. The remaining non-dropped-out word embeddings are scaled by $\frac { 1 } { 1 - p _ { e } }$ where $p _ { e }$ is the probability of embedding dropout. As the dropout occurs on the embedding matrix that is used for a full forward and backward pass, this means that all occurrences of a specific word will disappear within that pass, equivalent to performing variational dropout on the connection between the one-hot embedding and the embedding lookup.
113
+
114
+ # 4.4 WEIGHT TYING
115
+
116
+ Weight tying (Inan et al., 2016; Press & Wolf, 2016) shares the weights between the embedding and softmax layer, substantially reducing the total parameter count in the model. The technique has theoretical motivation (Inan et al., 2016) and prevents the model from having to learn a one-to-one correspondence between the input and output, resulting in substantial improvements to the standard LSTM language model.
117
+
118
+ # 4.5 INDEPENDENT EMBEDDING SIZE AND HIDDEN SIZE
119
+
120
+ In most natural language processing tasks, both pre-trained and trained word vectors are of relatively low dimensionality—frequently between 100 and 400 dimensions in size. Most previous LSTM language models tie the dimensionality of the word vectors to the dimensionality of the LSTM’s hidden state. Even if reducing the word embedding size was not beneficial in preventing overfitting, the easiest reduction in total parameters for a language model is reducing the word vector size. To achieve this, the first and last LSTM layers are modified such that their input and output dimensionality respectively are equal to the reduced embedding size.
121
+
122
+ 4.6 ACTIVATION REGULARIZATION (AR) AND TEMPORAL ACTIVATION REGULARIZATION (TAR)
123
+
124
+ $L _ { 2 }$ -regularization is often used on the weights of the network to control the norm of the resulting model and reduce overfitting. In addition, $L _ { 2 }$ decay can be used on the individual unit activations and on the difference in outputs of an RNN at different time steps; these strategies labeled as activation regularization (AR) and temporal activation regularization (TAR) respectively (Merity et al., 2017). AR penalizes activations that are significantly larger than 0 as a means of regularizing the network. Concretely, AR is defined as
125
+
126
+ $$
127
+ \alpha L _ { 2 } ( m \odot h _ { t } )
128
+ $$
129
+
130
+ where $m$ is the dropout mask, $L _ { 2 } ( \cdot ) = \| \cdot \| _ { 2 } , h _ { t }$ is the output of the RNN at timestep $t$ , and $\alpha$ is a scaling coefficient. TAR falls under the broad category of slowness regularizers (Hinton, 1989; Foldi ¨ ak, 1991; Luciw´ $\&$ Schmidhuber, 2012; Jonschkowski & Brock, 2015) which penalize the model from producing large changes in the hidden state. Using the notation from AR, TAR is defined as
131
+
132
+ $$
133
+ \beta L _ { 2 } ( h _ { t } - h _ { t + 1 } )
134
+ $$
135
+
136
+ where $\beta$ is a scaling coefficient. As in Merity et al. (2017), the AR and TAR loss are only applied to the output of the final RNN layer as opposed to being applied to all layers.
137
+
138
+ # 5 EXPERIMENT DETAILS
139
+
140
+ For evaluating the impact of these approaches, we perform language modeling over a preprocessed version of the Penn Treebank (PTB) (Mikolov et al., 2010) and the WikiText-2 (WT2) data set (Merity et al., 2016).
141
+
142
+ PTB: The Penn Treebank data set has long been a central data set for experimenting with language modeling. The data set is heavily preprocessed and does not contain capital letters, numbers, or punctuation. The vocabulary is also capped at 10,000 unique words, quite small in comparison to most modern datasets, which results in a large number of out of vocabulary (OoV) tokens.
143
+
144
+ WT2: WikiText-2 is sourced from curated Wikipedia articles and is approximately twice the size of the PTB data set. The text is tokenized and processed using the Moses tokenizer (Koehn et al., 2007), frequently used for machine translation, and features a vocabulary of over 30,000 words. Capitalization, punctuation, and numbers are retained in this data set.
145
+
146
+ All experiments use a three-layer LSTM model with 1150 units in the hidden layer and an embedding of size 400. The loss was averaged over all examples and timesteps. All embedding weights were uniformly initialized in the interval $[ - 0 . 1 , 0 . 1 ]$ and all other weights were initialized between $[ - \frac { 1 } { \sqrt { H } } , \frac { 1 } { \sqrt { H } } ]$ , where $H$ is the hidden size.
147
+
148
+ For training the models, we use the NT-AvSGD algorithm discussed in the previous section for 750 epochs with $L$ equivalent to one epoch and $n = 5$ . We use a batch size of 80 for WT2 and 40 for PTB. Empirically, we found relatively large batch sizes (e.g., 40-80) performed better than smaller sizes (e.g., 10-20) for NT-AvSGD. After completion, we run AvSGD with $T = 0$ and hot-started $w _ { 0 }$ as a fine-tuning step to further improve the solution. For this fine-tuning step, we terminate the run using the same non-monotonic criterion detailed in Algorithm 1.
149
+
150
+ We carry out gradient clipping with maximum norm 0.25 and use an initial learning rate of 30 for all experiments. We use a random BPTT length which is $\mathcal { N } ( 7 0 , 5 )$ with probability 0.95 and $\mathcal { N } ( 3 5 , 5 )$ with probability 0.05. The values used for dropout on the word vectors, the output between LSTM layers, the output of the final LSTM layer, and embedding dropout where (0.4, 0.3, 0.4, 0.1) respectively. For the weight-dropped LSTM, a dropout of 0.5 was applied to the recurrent weight matrices. For WT2, we increase the input dropout to 0.65 to account for the increased vocabulary size. For all experiments, we use AR and TAR values of 2 and 1 respectively, and tie the embedding and softmax weights. These hyperparameters were chosen through trial and error and we expect further improvements may be possible if a fine-grained hyperparameter search were to be conducted. In the results, we abbreviate our approach as AWD-LSTM for AvSGD Weight-Dropped LSTM. The code for reproducing our results is open sourced and available at https://github.com/ salesforce/awd-lstm-lm.
151
+
152
+ Table 1: Single model perplexity on validation and test sets for the Penn Treebank language modeling task. Parameter numbers with $^ \ddag$ are estimates based upon our understanding of the model and with reference to (Merity et al., 2016). Models noting tied use weight tying on the embedding and softmax weights. Our model, AWD-LSTM, stands for AvSGD Weight-Dropped LSTM.
153
+
154
+ <table><tr><td>Model</td><td>Parameters</td><td>Validation</td><td>Test</td></tr><tr><td>Mikolov&amp; Zweig (2012) - KN-5</td><td>2M</td><td></td><td>141.2</td></tr><tr><td>Mikolov &amp; Zweig (2012) - KN5 + cache</td><td>2M</td><td></td><td>125.7</td></tr><tr><td>Mikolov&amp; Zweig (2012) - RNN</td><td>6Mt</td><td></td><td>124.7</td></tr><tr><td>Mikolov &amp; Zweig (2012) - RNN-LDA</td><td>7M</td><td></td><td>113.7</td></tr><tr><td>Mikolov &amp; Zweig (2012) - RNN-LDA + KN-5 + cache</td><td>9M</td><td></td><td>92.0</td></tr><tr><td>Zaremba et al. (2014) -LSTM (medium)</td><td>20M</td><td>86.2</td><td>82.7</td></tr><tr><td>Zaremba et al. (2014) - LSTM (large)</td><td>66M</td><td>82.2</td><td>78.4</td></tr><tr><td>Gal &amp; Ghahramani (2O16)- Variational LSTM</td><td>20M</td><td>1</td><td>78.6</td></tr><tr><td>Gal &amp; Ghahramani (2O16)- Variational LSTM</td><td>66M</td><td>1</td><td>73.4</td></tr><tr><td>Kim et al. (2016) - CharCNN</td><td>19M</td><td>1</td><td>78.9</td></tr><tr><td>Merity et al. (2016) - Pointer Sentinel-LSTM</td><td>21M</td><td>72.4</td><td>70.9</td></tr><tr><td>Grave et al. (2016) - LSTM Grave et al. (2016) - LSTM + continuous cache pointer</td><td>1</td><td>1</td><td>82.3</td></tr><tr><td>Inan et al.(2O16) -Variational LSTM(tied) +augmented loss</td><td>一</td><td>1</td><td>72.1</td></tr><tr><td>Inan et al. (2016) - Variational LSTM (tied) + augmented loss</td><td>24M</td><td>75.7</td><td>73.2</td></tr><tr><td>Zilly et al. (2016) - Variational RHN (tied)</td><td>51M</td><td>71.1</td><td>68.5</td></tr><tr><td>Zoph &amp; Le (2016) - NAS Cell (tied)</td><td>23M</td><td>67.9</td><td>65.4</td></tr><tr><td></td><td>25M</td><td>1</td><td>64.0</td></tr><tr><td>Zoph &amp; Le (2016) - NAS Cell (tied)</td><td>54M</td><td>一</td><td>62.4</td></tr><tr><td>Melis et al. (2017) - 4-layer skip connection LSTM (tied)</td><td>24M</td><td>60.9</td><td>58.3</td></tr><tr><td>AWD-LSTM - 3-layer LSTM (tied)</td><td>24M</td><td>60.0</td><td>57.3</td></tr><tr><td>AWD-LSTM - 3-layer LSTM (tied) + continuous cache pointer</td><td>24M</td><td>53.9</td><td>52.8</td></tr></table>
155
+
156
+ Table 2: Single model perplexity over WikiText-2. Models noting tied use weight tying on the embedding and softmax weights. Our model, AWD-LSTM, stands for AvSGD Weight-Dropped LSTM.
157
+
158
+ <table><tr><td>Model</td><td>Parameters</td><td>Validation</td><td>Test</td></tr><tr><td>Inan et al. (2016) - Variational LSTM (tied)</td><td>28M</td><td>92.3</td><td>87.7</td></tr><tr><td>Inan et al. (2016) - Variational LSTM (tied) + augmented loss</td><td>28M</td><td>91.5</td><td>87.0</td></tr><tr><td>Grave et al. (2016) - LSTM</td><td>1</td><td>1</td><td>99.3</td></tr><tr><td>Grave et al. (2016) - LSTM + continuous cache pointer</td><td>1</td><td>1</td><td>68.9</td></tr><tr><td>Melis et al. (2017)- 1-layer LSTM (tied)</td><td>24M</td><td>69.3</td><td>65.9</td></tr><tr><td>Melis et al. (2017) - 2-layer skip connection LSTM (tied)</td><td>24M</td><td>69.1</td><td>65.9</td></tr><tr><td>AWD-LSTM- 3-layer LSTM (tied)</td><td>33M</td><td>68.6</td><td>65.8</td></tr><tr><td>AWD-LSTM - 3-layer LSTM (tied) + continuous cache pointer</td><td>33M</td><td>53.8</td><td>52.0</td></tr></table>
159
+
160
+ # 6 EXPERIMENTAL ANALYSIS
161
+
162
+ We present the single-model perplexity results for both our models (AWD-LSTM) and other competitive models in Table 1 and 2 for PTB and WT2 respectively 1. On both data sets we improve the state-of-the-art, with our vanilla LSTM model beating the state of the art by approximately 1 unit on PTB and 0.1 units on WT2.
163
+
164
+ In comparison to other recent state-of-the-art models, our model uses a vanilla LSTM. Zilly et al. (2016) propose the recurrent highway network, which extends the LSTM to allow multiple hidden state updates per timestep. Zoph & Le (2016) use a reinforcement learning agent to generate an RNN cell tailored to the specific task of language modeling, with the cell far more complex than the LSTM.
165
+
166
+ Independently of our work, Melis et al. (2017) apply extensive hyperparameter search to an LSTM based language modeling implementation, analyzing the sensitivity of RNN based language models to hyperparameters. Unlike our work, they use a modified LSTM, which caps the input gate $i _ { t }$ to be $\operatorname* { m i n } ( 1 - f _ { t } , i _ { t } )$ , use Adam with $\beta _ { 1 } = 0$ rather than SGD or AvSGD, use skip connections between LSTM layers, and use a black box hyperparameter tuner for exploring models and settings. Of particular interest is that their hyperparameters were tuned individually for each data set compared to our work which shared almost all hyperparameters between PTB and WT2, including the embedding and hidden size for both data sets. Due to this, they used less model parameters than our model and found shallow LSTMs of one or two layers worked best for WT2.
167
+
168
+ Like our work, Melis et al. (2017) find that the underlying LSTM architecture can be highly effective compared to complex custom architectures when well tuned hyperparameters are used. The approaches used in our work and (Melis et al., 2017) may be complementary and would be worth exploration.
169
+
170
+ # 6.1 POINTER MODELS
171
+
172
+ In past work, pointer based attention models have been shown to be highly effective in improving language modeling (Merity et al., 2016; Grave et al., 2016). Given such substantial improvements to the underlying neural language model, it remained an open question as to how effective pointer augmentation may be, especially when improvements such as weight tying may act in mutually exclusive ways.
173
+
174
+ The neural cache model (Grave et al., 2016) can be added on top of a pre-trained language model at negligible cost. The neural cache stores the previous hidden states in memory cells and then uses a simple convex combination of the probability distributions suggested by the cache and the language model for prediction. The cache model has three hyperparameters: the memory size (window) for the cache, the coefficient of the combination (which determines how the two distributions are mixed), and the flatness of the cache distribution. All of these are tuned on the validation set once a trained language model has been obtained and require no training by themselves, making it quite inexpensive to use. The tuned values for these hyperparameters were (2000, 0.1, 1.0) for PTB and (3785, 0.1279, 0.662) for WT2 respectively.
175
+
176
+ In Tables 1 and 2, we show that the model further improves the perplexity of the language model by as much as 6 perplexity points for PTB and 11 points for WT2. While this is smaller than the gains reported in Grave et al. (2016), which used an LSTM without weight tying, this is still a substantial drop. Given the simplicity of the neural cache model, and the lack of any trained components, these results suggest that existing neural language models remain fundamentally lacking, failing to capture long term dependencies or remember recently seen words effectively.
177
+
178
+ To understand the impact the pointer had on the model, specifically the validation set perplexity, we detail the contribution that each word has on the cache model’s overall perplexity in Table 3. We compute the sum of the total difference in the loss function value (i.e., log perplexity) between the LSTM-only and LSTM-with-cache models for the target words in the validation portion of the WikiText-2 data set. We present results for the sum of the difference as opposed to the mean since the latter undesirably overemphasizes infrequently occurring words for which the cache helps significantly and ignores frequently occurring words for which the cache provides modest improvements that cumulatively make a strong contribution.
179
+
180
+ The largest cumulative gain is in improving the handling of ${ \tt { < u n k > } }$ tokens, though this is over 11540 instances. The second best improvement, approximately one fifth the gain given by the ${ \mathrm { \ c u n k { \mathrm { > } } } }$ tokens, is for Meridian, yet this word only occurs 161 times. This indicates the cache still helps significantly even for relatively rare words, further demonstrated by Churchill, Blythe, or Sonic. The cache is not beneficial when handling frequent word categories, such as punctuation or stop words, for which the language model is likely well suited. These observations motivate the design of a cache framework that is more aware of the relative strengths of the two models.
181
+
182
+ # 6.2 AWD-QRNN
183
+
184
+ Several architectures for learning sequential data based on convolutions, instead of recurrences, have been proposed recently. We briefly mention experiments on the same language modeling using quasi-recurrent neural networks (QRNNs) (Bradbury et al., 2016) instead of LSTMs; we label this setup the AWD-QRNN. As in the case of AWD-LSTM, we regularize the network through weight, embedding and variational dropouts along with variable sequence lengths, weight tying, AR and TAR. The networks were designed such that they had the same number of parameters as their LSTM counterparts and were trained using NT-AvSGD. Despite the same size of the network, QRNNs were $2 - 4 \times$ faster per epoch as compared to their LSTM counterparts and required fewer epochs to converge. We report the results in Table 4. As is evident from the table, the QRNN model achieves comparable results to the LSTM suggesting the generality of the proposed regularization techniques. Interestingly, the hyperparameter values for the various regularization components, including the optimization procedure, needed minimal changes from the LSTM to the QRNN models for competitive performance. For full details and hyperparameters, refer to the released code.
185
+
186
+ Table 3: The sum total difference in loss (log perplexity) that a given word results in over all instances in the validation data set of WikiText-2 when the continuous cache pointer is introduced. The right column contains the words with the twenty best improvements (i.e., where the cache was advantageous), and the left column the twenty most deteriorated (i.e., where the cache was disadvantageous).
187
+
188
+ <table><tr><td>Word</td><td>Count</td><td>△loss</td><td>Word</td><td>Count</td><td>△loss</td></tr><tr><td>·</td><td>7632</td><td>-696.45</td><td>&lt;unk&gt;</td><td>11540</td><td>5047.34</td></tr><tr><td>,</td><td>9857</td><td>-687.49</td><td>Meridian</td><td>161</td><td>1057.78</td></tr><tr><td>of</td><td>5816</td><td>-365.21</td><td>Churchill</td><td>137</td><td>849.43</td></tr><tr><td>=</td><td>2884</td><td>-342.01</td><td>-</td><td>67</td><td>682.15</td></tr><tr><td>to</td><td>4048</td><td>-283.10</td><td>Blythe</td><td>97</td><td>554.95</td></tr><tr><td>in</td><td>4178</td><td>-222.94</td><td>Sonic</td><td>75</td><td>543.85</td></tr><tr><td>&lt;eos&gt;</td><td>3690</td><td>-216.42</td><td>Richmond</td><td>101</td><td>429.18</td></tr><tr><td>and</td><td>5251</td><td>-215.38</td><td>Starr</td><td>74</td><td>416.52</td></tr><tr><td>the</td><td>12481</td><td>-209.97</td><td>Australian</td><td>234</td><td>366.36</td></tr><tr><td>a</td><td>3381</td><td>-149.78</td><td>Pagan</td><td>54</td><td>365.19</td></tr><tr><td>”</td><td>2540</td><td>-127.99</td><td>Asahi</td><td>39</td><td>316.24</td></tr><tr><td>that</td><td>1365</td><td>-118.09</td><td>Japanese</td><td>181</td><td>295.97</td></tr><tr><td>by</td><td>1252</td><td>-113.05</td><td>Hu</td><td>43</td><td>285.58</td></tr><tr><td>was</td><td>2279</td><td>-107.95</td><td>Hedgehog</td><td>29</td><td>266.48</td></tr><tr><td>)</td><td>1101</td><td>-94.74</td><td>Burma</td><td>35</td><td>263.65</td></tr><tr><td>with</td><td>1176</td><td>-93.01</td><td>29</td><td>92</td><td>260.88</td></tr><tr><td>for</td><td>1215</td><td>-87.68</td><td>Mississippi</td><td>72</td><td>241.59</td></tr><tr><td>on</td><td>1485</td><td>-81.55</td><td>German</td><td>108</td><td>241.23</td></tr><tr><td>as</td><td>1338</td><td>-77.05</td><td>mill</td><td>67</td><td>237.76</td></tr><tr><td>at</td><td>879</td><td>-59.86</td><td>Cooke</td><td>33</td><td>231.11</td></tr></table>
189
+
190
+ Table 4: Comparison of AWD-LSTM and AWD-QRNN for the same model size on the PTB and WikiText-2 data sets.
191
+
192
+ <table><tr><td rowspan="2">Model</td><td colspan="2">PTB</td><td colspan="2">WT2</td></tr><tr><td>Validation</td><td>Test</td><td>Validation</td><td>Test</td></tr><tr><td>AWD-LSTM only training</td><td>60.7</td><td>58.3</td><td>69.1</td><td>66.0</td></tr><tr><td>+ fine tune</td><td>60.0</td><td>57.3</td><td>68.6</td><td>65.8</td></tr><tr><td>+ fine tune + continuous cache pointer</td><td>53.9</td><td>52.8</td><td>53.8</td><td>52.0</td></tr><tr><td>QRNN-LSTM only training</td><td>60.6</td><td>58.3</td><td>69.3</td><td>66.8</td></tr><tr><td>+ fine tune</td><td>59.1</td><td>56.7</td><td>68.5</td><td>65.9</td></tr><tr><td>+ fine tune + continuous cache pointer</td><td>53.4</td><td>52.6</td><td>53.6</td><td>52.1</td></tr></table>
193
+
194
+ # 6.3 MODEL ABLATION ANALYSIS
195
+
196
+ In Table 5, we present the values of validation and testing perplexity for different variants of our best-performing LSTM model. Each variant removes a form of optimization or regularization.
197
+
198
+ Table 5: Model ablations for our best LSTM models reporting results over the validation and test set on Penn Treebank and WikiText-2. Ablations are split into optimization and regularization variants, sorted according to the achieved validation perplexity on WikiText-2.
199
+
200
+ <table><tr><td rowspan="2">Model</td><td colspan="2">PTB</td><td colspan="2">WT2</td></tr><tr><td>Validation</td><td>Test</td><td>Validation</td><td>Test</td></tr><tr><td>AWD-LSTM (tied)</td><td>60.0</td><td>57.3</td><td>68.6</td><td>65.8</td></tr><tr><td>- fine-tuning</td><td>60.7</td><td>58.8</td><td>69.1</td><td>66.0</td></tr><tr><td>- NT-AvSGD</td><td>66.3</td><td>63.7</td><td>73.3</td><td>69.7</td></tr><tr><td>- variable sequence lengths</td><td>61.3</td><td>58.9</td><td>69.3</td><td>66.2</td></tr><tr><td>- embedding dropout</td><td>65.1</td><td>62.7</td><td>71.1</td><td>68.1</td></tr><tr><td>- weight decay</td><td>63.7</td><td>61.0</td><td>71.9</td><td>68.7</td></tr><tr><td>- AR/TAR</td><td>62.7</td><td>60.3</td><td>73.2</td><td>70.1</td></tr><tr><td>- full sized embedding</td><td>68.0</td><td>65.6</td><td>73.7</td><td>70.7</td></tr><tr><td>- weight-dropping</td><td>71.1</td><td>68.9</td><td>78.4</td><td>74.9</td></tr></table>
201
+
202
+ The first two variants deal with the optimization of the language models while the rest deal with the regularization. For the model using SGD with learning rate reduced by 2 using the same nonmonotonic fashion, there is a significant degradation in performance. This stands as empirical evidence regarding the benefit of averaging of the iterates. Using a monotonic criterion instead also hampered performance. Similarly, the removal of the fine-tuning step expectedly also degrades the performance. This step helps improve the estimate of the minimizer by resetting the memory of the previous experiment. While this process of fine-tuning can be repeated multiple times, we found little benefit in repeating it more than once.
203
+
204
+ The removal of regularization strategies paints a similar picture; the inclusion of all of the proposed strategies was pivotal in ensuring state-of-the-art performance. The most extreme perplexity jump was in removing the hidden-to-hidden LSTM regularization provided by the weight-dropped LSTM. Without such hidden-to-hidden regularization, perplexity rises substantially, up to 11 points. This is in line with previous work showing the necessity of recurrent regularization in state-of-the-art models (Gal & Ghahramani, 2016; Inan et al., 2016).
205
+
206
+ We also experiment with static sequence lengths which we had hypothesized would lead to inefficient data usage. This also worsens the performance by approximately one perplexity unit. Next, we experiment with reverting to matching the sizes of the embedding vectors and the hidden states. This significantly increases the number of parameters in the network (to 43M in the case of PTB and 70M for WT2) and leads to degradation by almost 8 perplexity points, which we attribute to overfitting in the word embeddings. While this could potentially be improved with more aggressive regularization, the computational overhead involved with substantially larger embeddings likely outweighs any advantages. Finally, we experiment with the removal of embedding dropout, AR/TAR and weight decay. In all of the cases, the model suffers a perplexity increase of 2–6 points which we hypothesize is due to insufficient regularization in the network.
207
+
208
+ # 7 CONCLUSION
209
+
210
+ In this work, we discuss regularization and optimization strategies for neural language models. We propose the weight-dropped LSTM, a strategy that uses a DropConnect mask on the hidden-tohidden weight matrices, as a means to prevent overfitting across the recurrent connections. Further, we investigate the use of averaged SGD with a non-monontonic trigger for training language models and show that it outperforms SGD by a significant margin. We investigate other regularization strategies including the use of variable BPTT length and achieve a new state-of-the-art perplexity on the PTB and WikiText-2 data sets. Our models outperform custom-built RNN cells and complex regularization strategies that preclude the possibility of using optimized libraries such as the NVIDIA cuDNN LSTM. We explore the use of a neural cache in conjunction with our proposed model and show that this further improves the performance, thus attaining an even lower state-of-the-art perplexity. We also explore the viability of using the proposed regularization and optimization strategies in the context of a quasi-recurrent neural network (QRNN) and demonstrate comparable performance to the LSTM counterpart. While the regularization and optimization strategies proposed are demonstrated on the task of language modeling, we anticipate that they would be generally applicable across other sequence learning tasks.
211
+
212
+ # REFERENCES
213
+
214
+ M. Arjovsky, A. Shah, and Y. Bengio. Unitary evolution recurrent neural networks. In International Conference on Machine Learning, pp. 1120–1128, 2016.
215
+ J. Ba, J. Kiros, and G. E. Hinton. Layer normalization. CoRR, abs/1607.06450, 2016.
216
+ D. Balduzzi and M. Ghifary. Strongly-typed recurrent neural networks. arXiv preprint arXiv:1602.02218, 2016.
217
+ L. Bottou, F. E. Curtis, and J. Nocedal. Optimization methods for large-scale machine learning. arXiv preprint arXiv:1606.04838, 2016.
218
+ J. Bradbury, S. Merity, C. Xiong, and R. Socher. Quasi-Recurrent Neural Networks. arXiv preprint arXiv:1611.01576, 2016.
219
+ T. Cooijmans, N. Ballas, C. Laurent, and A. C. Courville. Recurrent batch normalization. CoRR, abs/1603.09025, 2016.
220
+ J. Duchi, E. Hazan, and Y. Singer. Adaptive subgradient methods for online learning and stochastic optimization. Journal of Machine Learning Research, 12(Jul):2121–2159, 2011.
221
+ P. Foldi ¨ ak. Learning invariance from transformation sequences. ´ Neural Computation, 3(2):194–200, 1991.
222
+ Y. Gal and Z. Ghahramani. A theoretically grounded application of dropout in recurrent neural networks. In NIPS, 2016.
223
+ P. Goyal, P. Dollar, R. Girshick, P. Noordhuis, L. Wesolowski, A. Kyrola, A. Tulloch, Y. Jia, ´ and K. He. Accurate, large minibatch sgd: Training imagenet in 1 hour. arXiv preprint arXiv:1706.02677, 2017.
224
+ E. Grave, A. Joulin, and N. Usunier. Improving neural language models with a continuous cache. arXiv preprint arXiv:1612.04426, 2016.
225
+ M. Hardt, B. Recht, and Y. Singer. Train faster, generalize better: Stability of stochastic gradient descent. arXiv preprint arXiv:1509.01240, 2015.
226
+ G. E. Hinton. Connectionist learning procedures. Artificial intelligence, 40(1-3):185–234, 1989.
227
+ H. Inan, K. Khosravi, and R. Socher. Tying Word Vectors and Word Classifiers: A Loss Framework for Language Modeling. arXiv preprint arXiv:1611.01462, 2016.
228
+ S. Ioffe and C. Szegedy. Batch normalization: Accelerating deep network training by reducing internal covariate shift. In ICML, 2015.
229
+ L. Jing, Y. Shen, T. Dubcek, J. Peurifoy, S. Skirlo, M. Tegmark, and M. Solja ˇ ciˇ c. Tunable ´ Efficient Unitary Neural Networks (EUNN) and their application to RNN. arXiv preprint arXiv:1612.05231, 2016.
230
+ R. Jonschkowski and O. Brock. Learning state representations with robotic priors. Auton. Robots, 39:407–428, 2015.
231
+ N. Keskar and G. Saon. A nonmonotone learning rate strategy for sgd training of deep neural networks. In Acoustics, Speech and Signal Processing (ICASSP), 2015 IEEE International Conference on, pp. 4974–4978. IEEE, 2015.
232
+ Y. Kim, Y. Jernite, D. Sontag, and A. M. Rush. Character-aware neural language models. In Thirtieth AAAI Conference on Artificial Intelligence, 2016.
233
+ D. Kingma and J. Ba. Adam: A method for stochastic optimization. arXiv preprint arXiv:1412.6980, 2014.
234
+ P. Koehn, H. Hoang, A. Birch, C. Callison-Burch, M. Federico, N. Bertoldi, B. Cowan, W. Shen, C. Moran, R. Zens, C. Dyer, O. Bojar, A. Constantin, and E. Herbst. Moses: Open source toolkit for statistical machine translation. In ACL, 2007.
235
+ D. Krueger, T. Maharaj, J. Kramar, M. Pezeshki, N. Ballas, N. Ke, A. Goyal, Y. Bengio, ´ H. Larochelle, A. Courville, et al. Zoneout: Regularizing RNNss by randomly preserving hidden activations. arXiv preprint arXiv:1606.01305, 2016.
236
+ M. Luciw and J. Schmidhuber. Low complexity proto-value function learning from sensory observations with incremental slow feature analysis. Artificial Neural Networks and Machine Learning– ICANN 2012, pp. 279–287, 2012.
237
+ S. Mandt, M. D. Hoffman, and D. M. Blei. Stochastic gradient descent as approximate bayesian inference. arXiv preprint arXiv:1704.04289, 2017.
238
+ G. Melis, C. Dyer, and P. Blunsom. On the State of the Art of Evaluation in Neural Language Models. arXiv preprint arXiv:1707.05589, 2017.
239
+ S. Merity, C. Xiong, J. Bradbury, and R. Socher. Pointer Sentinel Mixture Models. arXiv preprint arXiv:1609.07843, 2016.
240
+ S. Merity, B. McCann, and R. Socher. Revisiting activation regularization for language rnns. arXiv preprint arXiv:1708.01009, 2017.
241
+ T. Mikolov and G. Zweig. Context dependent recurrent neural network language model. SLT, 12: 234–239, 2012.
242
+ T. Mikolov, M. Karafiat, L. Burget, J. Cernock ´ y, and S. Khudanpur. Recurrent neural network based ´ language model. In INTERSPEECH, 2010.
243
+ I. Panageas and G. Piliouras. Gradient descent converges to minimizers: The case of non-isolated critical points. CoRR, abs/1605.00405, 2016.
244
+ B. Polyak and A. Juditsky. Acceleration of stochastic approximation by averaging. SIAM Journal on Control and Optimization, 30(4):838–855, 1992.
245
+ O. Press and L. Wolf. Using the output embedding to improve language models. arXiv preprint arXiv:1608.05859, 2016.
246
+ S. Semeniuta, A. Severyn, and E. Barth. Recurrent dropout without memory loss. In COLING, 2016.
247
+ M. Seo, S. Min, A. Farhadi, and H. Hajishirzi. Query-Reduction Networks for Question Answering. arXiv preprint arXiv:1606.04582, 2016.
248
+ N. Srivastava, G. Hinton, A. Krizhevsky, I. Sutskever, and R. Salakhutdinov. Dropout: a simple way to prevent neural networks from overfitting. Journal of Machine Learning Research, 15: 1929–1958, 2014.
249
+ I. Sutskever, J. Martens, G. Dahl, and G. Hinton. On the importance of initialization and momentum in deep learning. In International conference on machine learning, pp. 1139–1147, 2013.
250
+ C. Tallec and Y. Ollivier. Unbiasing truncated backpropagation through time. arXiv preprint arXiv:1705.08209, 2017.
251
+ T. Tieleman and G. Hinton. Lecture 6.5-rmsprop: Divide the gradient by a running average of its recent magnitude. COURSERA: Neural networks for machine learning, 4(2):26–31, 2012.
252
+ L. Wan, M. Zeiler, S. Zhang, Y LeCun, and R. Fergus. Regularization of neural networks using dropconnect. In Proceedings of the 30th international conference on machine learning (ICML13), pp. 1058–1066, 2013.
253
+ A. C Wilson, R. Roelofs, M. Stern, N. Srebro, and B. Recht. The marginal value of adaptive gradient methods in machine learning. arXiv preprint arXiv:1705.08292, 2017.
254
+ S. Wisdom, T. Powers, J. Hershey, J. Le Roux, and L. Atlas. Full-capacity unitary recurrent neural networks. In Advances in Neural Information Processing Systems, pp. 4880–4888, 2016.
255
+ W. Zaremba, I. Sutskever, and O. Vinyals. Recurrent neural network regularization. arXiv preprint arXiv:1409.2329, 2014.
256
+ J. G. Zilly, R. K. Srivastava, J. Koutn´ık, and J. Schmidhuber. Recurrent highway networks. arXiv preprint arXiv:1607.03474, 2016.
257
+ B. Zoph and Q. V. Le. Neural architecture search with reinforcement learning. arXiv preprint arXiv:1611.01578, 2016.
parse/train/SyyGPP0TZ/SyyGPP0TZ_content_list.json ADDED
@@ -0,0 +1,1123 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [
2
+ {
3
+ "type": "text",
4
+ "text": "REGULARIZING AND OPTIMIZING LSTM LANGUAGE MODELS ",
5
+ "text_level": 1,
6
+ "bbox": [
7
+ 174,
8
+ 98,
9
+ 821,
10
+ 145
11
+ ],
12
+ "page_idx": 0
13
+ },
14
+ {
15
+ "type": "text",
16
+ "text": "Stephen Merity, Nitish Shirish Keskar & Richard Socher Salesforce Research \nPalo Alto, CA 94301, USA \n{smerity,nkeskar,rsocher}@salesforce.com ",
17
+ "bbox": [
18
+ 183,
19
+ 170,
20
+ 581,
21
+ 227
22
+ ],
23
+ "page_idx": 0
24
+ },
25
+ {
26
+ "type": "text",
27
+ "text": "ABSTRACT ",
28
+ "text_level": 1,
29
+ "bbox": [
30
+ 454,
31
+ 262,
32
+ 544,
33
+ 277
34
+ ],
35
+ "page_idx": 0
36
+ },
37
+ {
38
+ "type": "text",
39
+ "text": "In this paper, we consider the specific problem of word-level language modeling and investigate strategies for regularizing and optimizing LSTM-based models. We propose the weight-dropped LSTM, which uses DropConnect on hidden-tohidden weights, as a form of recurrent regularization. Further, we introduce NTAvSGD, a non-monotonically triggered (NT) variant of the averaged stochastic gradient method (AvSGD), wherein the averaging trigger is determined using a NT condition as opposed to being tuned by the user. Using these and other regularization strategies, our AvSGD Weight-Dropped LSTM (AWD-LSTM) achieves state-of-the-art word level perplexities on two data sets: 57.3 on Penn Treebank and 65.8 on WikiText-2. In exploring the effectiveness of a neural cache in conjunction with our proposed model, we achieve an even lower state-of-the-art perplexity of 52.8 on Penn Treebank and 52.0 on WikiText-2. We also explore the viability of the proposed regularization and optimization strategies in the context of the quasi-recurrent neural network (QRNN) and demonstrate comparable performance to the AWD-LSTM counterpart. The code for reproducing the results is open sourced and is available at https://github.com/salesforce/ awd-lstm-lm. ",
40
+ "bbox": [
41
+ 233,
42
+ 295,
43
+ 764,
44
+ 531
45
+ ],
46
+ "page_idx": 0
47
+ },
48
+ {
49
+ "type": "text",
50
+ "text": "1 INTRODUCTION ",
51
+ "text_level": 1,
52
+ "bbox": [
53
+ 176,
54
+ 563,
55
+ 336,
56
+ 579
57
+ ],
58
+ "page_idx": 0
59
+ },
60
+ {
61
+ "type": "text",
62
+ "text": "Effective regularization techniques for deep learning have been the subject of much research in recent years. Given the over-parameterization of neural networks, generalization performance crucially relies on the ability to regularize the models sufficiently. Strategies such as dropout (Srivastava et al., 2014) and batch normalization (Ioffe & Szegedy, 2015) have found great success and are now ubiquitous in feed-forward and convolutional neural networks. Na¨ıvely applying these approaches to the case of recurrent neural networks (RNNs) has not been highly successful however. Many recent works have hence been focused on the extension of these regularization strategies to RNNs; we briefly discuss some of them below. ",
63
+ "bbox": [
64
+ 174,
65
+ 595,
66
+ 825,
67
+ 707
68
+ ],
69
+ "page_idx": 0
70
+ },
71
+ {
72
+ "type": "text",
73
+ "text": "A na¨ıve application of dropout (Srivastava et al., 2014) to an RNN’s hidden state is ineffective as it disrupts the RNN’s ability to retain long term dependencies (Zaremba et al., 2014). Gal & Ghahramani (2016) propose overcoming this problem by retaining the same dropout mask across multiple time steps as opposed to sampling a new binary mask at each timestep. Another approach is to regularize the network through limiting updates to the RNN’s hidden state. One such approach is taken by Semeniuta et al. (2016) wherein the authors drop updates to network units, specifically the input gates of the LSTM, in lieu of the units themselves. This is reminiscent of zoneout (Krueger et al., 2016) where updates to the hidden state may fail to occur for randomly selected neurons. ",
74
+ "bbox": [
75
+ 174,
76
+ 713,
77
+ 825,
78
+ 825
79
+ ],
80
+ "page_idx": 0
81
+ },
82
+ {
83
+ "type": "text",
84
+ "text": "Instead of operating on the RNN’s hidden states, one can regularize the network through restrictions on the recurrent matrices as well. This can be done either through restricting the capacity of the matrix (Arjovsky et al., 2016; Wisdom et al., 2016; Jing et al., 2016) or through element-wise interactions (Balduzzi & Ghifary, 2016; Bradbury et al., 2016; Seo et al., 2016). ",
85
+ "bbox": [
86
+ 176,
87
+ 833,
88
+ 823,
89
+ 888
90
+ ],
91
+ "page_idx": 0
92
+ },
93
+ {
94
+ "type": "text",
95
+ "text": "Other forms of regularization explicitly act upon activations such as batch normalization (Ioffe & Szegedy, 2015), recurrent batch normalization (Cooijmans et al., 2016), and layer normalization (Ba et al., 2016). These all introduce additional training parameters and can complicate the training process while increasing the sensitivity of the model. ",
96
+ "bbox": [
97
+ 176,
98
+ 895,
99
+ 821,
100
+ 924
101
+ ],
102
+ "page_idx": 0
103
+ },
104
+ {
105
+ "type": "text",
106
+ "text": "",
107
+ "bbox": [
108
+ 173,
109
+ 103,
110
+ 823,
111
+ 132
112
+ ],
113
+ "page_idx": 1
114
+ },
115
+ {
116
+ "type": "text",
117
+ "text": "In this work, we investigate a set of regularization strategies that are not only highly effective but which can also be used with no modification to existing LSTM implementations. The weightdropped LSTM applies recurrent regularization through a DropConnect mask on the hidden-tohidden recurrent weights. Other strategies include the use of randomized-length backpropagation through time (BPTT), embedding dropout, activation regularization (AR), and temporal activation regularization (TAR). ",
118
+ "bbox": [
119
+ 174,
120
+ 138,
121
+ 823,
122
+ 222
123
+ ],
124
+ "page_idx": 1
125
+ },
126
+ {
127
+ "type": "text",
128
+ "text": "As no modifications are required of the LSTM implementation these regularization strategies are compatible with black box libraries, such as NVIDIA cuDNN, which can be many times faster than na¨ıve LSTM implementations. ",
129
+ "bbox": [
130
+ 178,
131
+ 229,
132
+ 821,
133
+ 271
134
+ ],
135
+ "page_idx": 1
136
+ },
137
+ {
138
+ "type": "text",
139
+ "text": "Effective methods for training deep recurrent networks have also been a topic of renewed interest. Once a model has been defined, the training algorithm used is required to not only find a good minimizer of the loss function but also converge to such a minimizer rapidly. The choice of the optimizer is even more important in the context of regularized models since such strategies, especially the use of dropout, can impede the training process. Stochastic gradient descent (SGD), and its variants such as Adam (Kingma & Ba, 2014) and RMSprop (Tieleman & Hinton, 2012) are amongst the most popular training methods. These methods iteratively reduce the training loss through scaled (stochastic) gradient steps. In particular, Adam has been found to be widely applicable despite requiring less tuning of its hyperparameters. In the context of word-level language modeling, past work has empirically found that SGD outperforms other methods in not only the final loss but also in the rate of convergence. This is in agreement with recent evidence pointing to the insufficiency of adaptive gradient methods (Wilson et al., 2017). ",
140
+ "bbox": [
141
+ 173,
142
+ 279,
143
+ 825,
144
+ 445
145
+ ],
146
+ "page_idx": 1
147
+ },
148
+ {
149
+ "type": "text",
150
+ "text": "Given the success of SGD, especially within the language modeling domain, we investigate the use of averaged SGD (AvSGD) (Polyak & Juditsky, 1992) which is known to have superior theoretical guarantees. AvSGD carries out iterations similar to SGD, but instead of returning the last iterate as the solution, returns an average of the iterates past a certain, tuned, threshold $T$ . This threshold $T$ is typically tuned and has a direct impact on the performance of the method. We propose a variant of AvSGD where $T$ is determined on the fly through a non-monotonic criterion and show that it achieves better training outcomes compared to SGD. ",
151
+ "bbox": [
152
+ 174,
153
+ 452,
154
+ 825,
155
+ 549
156
+ ],
157
+ "page_idx": 1
158
+ },
159
+ {
160
+ "type": "text",
161
+ "text": "2 WEIGHT-DROPPED LSTM ",
162
+ "text_level": 1,
163
+ "bbox": [
164
+ 176,
165
+ 571,
166
+ 421,
167
+ 588
168
+ ],
169
+ "page_idx": 1
170
+ },
171
+ {
172
+ "type": "text",
173
+ "text": "We refer to the mathematical formulation of the LSTM, ",
174
+ "bbox": [
175
+ 174,
176
+ 604,
177
+ 540,
178
+ 621
179
+ ],
180
+ "page_idx": 1
181
+ },
182
+ {
183
+ "type": "equation",
184
+ "img_path": "images/2af87554fcd185970b807e6853c03f62e54788e618db5e45a0c4a087eb754394.jpg",
185
+ "text": "$$\n\\begin{array} { r l } & { { i _ { t } } = \\sigma ( { W ^ { i } } { x _ { t } } + { U ^ { i } } { h _ { t - 1 } } ) } \\\\ & { { f _ { t } } = \\sigma ( { W ^ { f } } { x _ { t } } + { U ^ { f } } { h _ { t - 1 } } ) } \\\\ & { { o _ { t } } = \\sigma ( { W ^ { o } } { x _ { t } } + { U ^ { o } } { h _ { t - 1 } } ) } \\\\ & { { { \\tilde { c } } _ { t } } = \\operatorname { t a n h } ( { W ^ { c } } { x _ { t } } + { U ^ { c } } { h _ { t - 1 } } ) } \\\\ & { { c _ { t } } = i _ { t } \\odot { { \\tilde { c } } _ { t } } + { f _ { t } } \\odot + { { \\tilde { c } } _ { t - 1 } } } \\\\ & { { h _ { t } } = o _ { t } \\odot \\operatorname { t a n h } ( { c _ { t } } ) } \\end{array}\n$$",
186
+ "text_format": "latex",
187
+ "bbox": [
188
+ 405,
189
+ 627,
190
+ 596,
191
+ 738
192
+ ],
193
+ "page_idx": 1
194
+ },
195
+ {
196
+ "type": "text",
197
+ "text": "where $[ W ^ { i } , W ^ { f } , W ^ { o } , U ^ { i } , U ^ { f } , U ^ { o } ]$ are weight matrices, $x _ { t }$ is the vector input to the timestep $t$ , $h _ { t }$ is the current exposed hidden state, $c _ { t }$ is the memory cell state, and $\\odot$ is element-wise multiplication. ",
198
+ "bbox": [
199
+ 171,
200
+ 756,
201
+ 823,
202
+ 784
203
+ ],
204
+ "page_idx": 1
205
+ },
206
+ {
207
+ "type": "text",
208
+ "text": "Preventing overfitting within the recurrent connections of an RNN has been an area of extensive research in language modeling. The majority of previous recurrent regularization techniques have acted on the hidden state vector $h _ { t - 1 }$ , most frequently introducing a dropout operation between timesteps, or performing dropout on the update to the memory state $c _ { t }$ . These modifications to a standard LSTM prevent the use of black box RNN implementations that may be many times faster due to low-level hardware-specific optimizations. ",
209
+ "bbox": [
210
+ 174,
211
+ 790,
212
+ 825,
213
+ 875
214
+ ],
215
+ "page_idx": 1
216
+ },
217
+ {
218
+ "type": "text",
219
+ "text": "We propose the use of DropConnect (Wan et al., 2013) on the recurrent hidden to hidden weight matrices which does not require any modifications to an RNN’s formulation. As the dropout operation is applied once to the weight matrices, before the forward and backward pass, the impact on training speed is minimal and any standard RNN implementation can be used, including inflexible but highly optimized black box LSTM implementations such as NVIDIA’s cuDNN LSTM. ",
220
+ "bbox": [
221
+ 176,
222
+ 881,
223
+ 823,
224
+ 924
225
+ ],
226
+ "page_idx": 1
227
+ },
228
+ {
229
+ "type": "text",
230
+ "text": "",
231
+ "bbox": [
232
+ 171,
233
+ 103,
234
+ 823,
235
+ 132
236
+ ],
237
+ "page_idx": 2
238
+ },
239
+ {
240
+ "type": "text",
241
+ "text": "By performing DropConnect on the hidden-to-hidden weight matrices $[ U ^ { i } , U ^ { f } , U ^ { o } , U ^ { c } ]$ within the LSTM, we can prevent overfitting from occurring on the recurrent connections of the LSTM. This regularization technique would also be applicable to preventing overfitting on the recurrent weight matrices of other RNN cells. ",
242
+ "bbox": [
243
+ 174,
244
+ 138,
245
+ 825,
246
+ 194
247
+ ],
248
+ "page_idx": 2
249
+ },
250
+ {
251
+ "type": "text",
252
+ "text": "As the same weights are reused over multiple timesteps, the same individual dropped weights remain dropped for the entirety of the forward and backward pass. The result is similar to variational dropout, which applies the same dropout mask to recurrent connections within the LSTM by performing dropout on $h _ { t - 1 }$ , except that the dropout is applied to the recurrent weights. DropConnect could also be used on the non-recurrent weights of the LSTM $[ W ^ { i } , W ^ { f } , W ^ { o } ]$ though our focus was on preventing overfitting on the recurrent connection. ",
253
+ "bbox": [
254
+ 174,
255
+ 202,
256
+ 825,
257
+ 286
258
+ ],
259
+ "page_idx": 2
260
+ },
261
+ {
262
+ "type": "text",
263
+ "text": "3 OPTIMIZATION ",
264
+ "text_level": 1,
265
+ "bbox": [
266
+ 176,
267
+ 305,
268
+ 331,
269
+ 321
270
+ ],
271
+ "page_idx": 2
272
+ },
273
+ {
274
+ "type": "text",
275
+ "text": "SGD is among the most popular methods for training deep learning models across various modalities including computer vision, natural language processing, and reinforcement learning. The training of deep networks can be posed as a non-convex empirical risk minimization problem ",
276
+ "bbox": [
277
+ 174,
278
+ 337,
279
+ 825,
280
+ 378
281
+ ],
282
+ "page_idx": 2
283
+ },
284
+ {
285
+ "type": "equation",
286
+ "img_path": "images/a895f86273c8ba33bdeed97919528b8cb948cfbf0a51aa34138d3a299bb2f2d1.jpg",
287
+ "text": "$$\n\\operatorname* { m i n } _ { w } \\quad \\frac { 1 } { N } \\sum _ { i = 1 } ^ { N } f _ { i } ( w ) ,\n$$",
288
+ "text_format": "latex",
289
+ "bbox": [
290
+ 428,
291
+ 383,
292
+ 568,
293
+ 428
294
+ ],
295
+ "page_idx": 2
296
+ },
297
+ {
298
+ "type": "text",
299
+ "text": "where $f _ { i }$ is the loss function for the $i ^ { t h }$ data point, $w$ are the weights of the network, and the expectation is taken over the data. In this context, given a sequence of learning rates, $\\gamma _ { k }$ , SGD iteratively takes steps of the form ",
300
+ "bbox": [
301
+ 174,
302
+ 433,
303
+ 825,
304
+ 476
305
+ ],
306
+ "page_idx": 2
307
+ },
308
+ {
309
+ "type": "equation",
310
+ "img_path": "images/3a7df61589eba9f20d5068919985e49e53a56d3417111b3462b44244da5db308.jpg",
311
+ "text": "$$\nw _ { k + 1 } = w _ { k } - \\gamma _ { k } \\hat { \\nabla } f ( w _ { k } ) ,\n$$",
312
+ "text_format": "latex",
313
+ "bbox": [
314
+ 410,
315
+ 479,
316
+ 588,
317
+ 500
318
+ ],
319
+ "page_idx": 2
320
+ },
321
+ {
322
+ "type": "text",
323
+ "text": "where the subscript denotes the iteration number and the $\\hat { \\nabla }$ denotes a stochastic gradient that may be computed on a minibatch of data points. SGD demonstrably performs well in practice and also possesses several attractive theoretical properties such as linear convergence (Bottou et al., 2016), saddle point avoidance (Panageas & Piliouras, 2016) and better generalization performance (Hardt et al., 2015). For the specific task of neural language modeling, traditionally SGD without momentum has been found to outperform other algorithms such as momentum SGD (Sutskever et al., 2013), Adam (Kingma & Ba, 2014), Adagrad (Duchi et al., 2011) and RMSProp (Tieleman & Hinton, 2012) by a statistically significant margin. ",
324
+ "bbox": [
325
+ 174,
326
+ 506,
327
+ 825,
328
+ 619
329
+ ],
330
+ "page_idx": 2
331
+ },
332
+ {
333
+ "type": "text",
334
+ "text": "Motivated by this observation, we investigate averaged SGD (AvSGD) to further improve the training process. AvSGD has been analyzed in depth theoretically and many surprising results have been shown including its asymptotic second-order convergence (Polyak & Juditsky, 1992; Mandt et al., 2017). AvSGD tsolution, returns $\\textstyle { \\frac { 1 } { ( K - T + 1 ) } } \\sum _ { i = T } ^ { K } w _ { i }$ to equa, where $K$ n (1) but instead of returning the lastis the total number of iterations and $T < K$ s theis a user-specified averaging trigger. ",
335
+ "bbox": [
336
+ 174,
337
+ 626,
338
+ 825,
339
+ 715
340
+ ],
341
+ "page_idx": 2
342
+ },
343
+ {
344
+ "type": "text",
345
+ "text": "Despite its theoretical appeal, AvSGD has found limited practical use in training of deep networks. This may be in part due to unclear tuning guidelines for the learning-rate schedule $\\gamma _ { k }$ and averaging trigger $T$ . If the averaging is triggered too soon, the efficacy of the method is impacted, and if it is triggered too late, many additional iterations may be needed to converge to the solution. In this section, we describe a non-monotonically triggered variant of AvSGD (NT-AvSGD), which obviates the need for tuning $T$ . Further, the algorithm uses a constant learning rate throughout the experiment and hence no further tuning is necessary for the decay scheduling. ",
346
+ "bbox": [
347
+ 174,
348
+ 720,
349
+ 825,
350
+ 820
351
+ ],
352
+ "page_idx": 2
353
+ },
354
+ {
355
+ "type": "text",
356
+ "text": "Ideally, averaging needs to be triggered when the SGD iterates converge to a steady-state distribution (Mandt et al., 2017). This is roughly equivalent to the convergence of SGD to a neighborhood around a solution. In the case of SGD, certain learning-rate reduction strategies such as the stepwise strategy analogously reduce the learning rate by a fixed quantity at such a point. A common strategy employed in language modeling is to reduce the learning rates by a fixed proportion when the performance of the model’s primary metric (such as perplexity) worsens or stagnates. Along the same lines, one could make a triggering decision based on the performance of the model on the ",
357
+ "bbox": [
358
+ 173,
359
+ 825,
360
+ 825,
361
+ 924
362
+ ],
363
+ "page_idx": 2
364
+ },
365
+ {
366
+ "type": "text",
367
+ "text": "Algorithm 1 Non-monotonically Triggered AvSGD (NT-AvSGD) ",
368
+ "text_level": 1,
369
+ "bbox": [
370
+ 173,
371
+ 103,
372
+ 609,
373
+ 118
374
+ ],
375
+ "page_idx": 3
376
+ },
377
+ {
378
+ "type": "text",
379
+ "text": "Inputs: Initial point $w _ { 0 }$ , learning rate $\\gamma$ , logging interval L, non-monotone interval n. \n1: Initialize $k 0$ , $t \\gets 0$ , $T \\gets 0$ , $\\mathrm { 1 0 9 5 [ ] }$ \n2: while stopping criterion not met do \n3: Compute stochastic gradient $\\hat { \\nabla } f ( \\boldsymbol { w } _ { k } )$ and take SGD step (1). \n4: if $\\mod ( k , L ) = 0$ and $T = 0$ then \n5: Compute validation perplexity $v$ . \n6: if $t > n$ and $v > \\qquad \\mathrm { m i n } \\qquad \\mathrm { l o q s [ 1 ] ~ } \\mathbf { t h e l }$ n \nl∈{0,··· ,t−n−1} \n7: Set $T \\gets k$ \n8: end if \n9: Append $v$ to logs \n10: $t \\gets t + 1$ \n11: end if \n12: k ← k + 1 \n13: end while \nreturn Pki=T wi ",
380
+ "bbox": [
381
+ 174,
382
+ 119,
383
+ 825,
384
+ 366
385
+ ],
386
+ "page_idx": 3
387
+ },
388
+ {
389
+ "type": "text",
390
+ "text": "validation set. However, instead of averaging immediately after the validation metric worsens, we propose a non-monotonic criterion that conservatively triggers the averaging when the validation metric fails to improve for multiple cycles; see Algorithm 1. Given that the choice of triggering is irreversible, this conservatism ensures that the randomness of training does not play a major role in the decision. Analogous strategies have also been proposed for learning-rate reduction in SGD (Keskar & Saon, 2015). ",
391
+ "bbox": [
392
+ 173,
393
+ 393,
394
+ 825,
395
+ 477
396
+ ],
397
+ "page_idx": 3
398
+ },
399
+ {
400
+ "type": "text",
401
+ "text": "While the algorithm introduces two additional hyperparameters, the logging interval $L$ and nonmonotone interval $n$ , we found that setting $L$ to be the number of iterations in an epoch and $n = 5$ worked well across various models and data sets. As such, we use this setting in all of our NTAvSGD experiments in the following section and demonstrate that it achieves better training outcomes as compared to SGD. ",
402
+ "bbox": [
403
+ 174,
404
+ 483,
405
+ 823,
406
+ 554
407
+ ],
408
+ "page_idx": 3
409
+ },
410
+ {
411
+ "type": "text",
412
+ "text": "4 EXTENDED REGULARIZATION TECHNIQUES ",
413
+ "text_level": 1,
414
+ "bbox": [
415
+ 174,
416
+ 575,
417
+ 566,
418
+ 590
419
+ ],
420
+ "page_idx": 3
421
+ },
422
+ {
423
+ "type": "text",
424
+ "text": "In addition to the regularization and optimization techniques above, we explored additional regularization techniques that aimed to improve data efficiency during training and to prevent overfitting of the RNN model. ",
425
+ "bbox": [
426
+ 174,
427
+ 606,
428
+ 825,
429
+ 647
430
+ ],
431
+ "page_idx": 3
432
+ },
433
+ {
434
+ "type": "text",
435
+ "text": "4.1 VARIABLE LENGTH BACKPROPAGATION SEQUENCES ",
436
+ "text_level": 1,
437
+ "bbox": [
438
+ 173,
439
+ 666,
440
+ 571,
441
+ 680
442
+ ],
443
+ "page_idx": 3
444
+ },
445
+ {
446
+ "type": "text",
447
+ "text": "Given a fixed sequence length that is used to break a data set into fixed length batches, the data set is not efficiently used. To illustrate this, imagine being given 100 elements to perform backpropagation through with a fixed backpropagation through time (BPTT) window of 10. Any element divisible by 10 will never have any elements to backprop into, no matter how many times you may traverse the data set. Indeed, the backpropagation window that each element receives is equal to $i$ mod 10 where $i$ is the element’s index. This is data inefficient, preventing $\\frac { 1 } { 1 0 }$ of the data set from ever being able to improve itself in a recurrent fashion, and resulting in $\\frac { 8 } { 1 0 }$ of the remaining elements receiving only a partial backpropagation window compared to the full possible backpropagation window of length 10. ",
448
+ "bbox": [
449
+ 174,
450
+ 691,
451
+ 825,
452
+ 819
453
+ ],
454
+ "page_idx": 3
455
+ },
456
+ {
457
+ "type": "text",
458
+ "text": "To prevent such inefficient data usage, we randomly select the sequence length for the forward and backward pass in two steps. First, we select the base sequence length to be seq with probability $p$ and $\\frac { \\mathrm { s e q } } { 2 }$ with probability $1 - p$ , where $p$ is a high value approaching 1. This spreads the starting point for the BPTT window beyond the base sequence length. We then select the sequence length according to $\\mathcal { N } ( \\mathrm { s e q } , s )$ , where seq is the base sequence length and $s$ is the standard deviation. This jitters the starting point such that it doesn’t always fall on a specific word divisible by seq or $\\frac { \\mathrm { s e q } } { 2 }$ . From these, the sequence length more efficiently uses the data set, ensuring that when given enough epochs all the elements in the data set experience a full BPTT window, while ensuring the average sequence length remains around the base sequence length for computational efficiency. ",
459
+ "bbox": [
460
+ 174,
461
+ 827,
462
+ 825,
463
+ 924
464
+ ],
465
+ "page_idx": 3
466
+ },
467
+ {
468
+ "type": "text",
469
+ "text": "",
470
+ "bbox": [
471
+ 173,
472
+ 103,
473
+ 821,
474
+ 132
475
+ ],
476
+ "page_idx": 4
477
+ },
478
+ {
479
+ "type": "text",
480
+ "text": "During training, we rescale the learning rate depending on the length of the resulting sequence compared to the original specified sequence length. The rescaling step is necessary as sampling arbitrary sequence lengths with a fixed learning rate favors short sequences over longer ones. This linear scaling rule has been noted as important for training large scale minibatch SGD without loss of accuracy (Goyal et al., 2017) and is a component of unbiased truncated backpropagation through time (Tallec & Ollivier, 2017). ",
481
+ "bbox": [
482
+ 174,
483
+ 138,
484
+ 825,
485
+ 222
486
+ ],
487
+ "page_idx": 4
488
+ },
489
+ {
490
+ "type": "text",
491
+ "text": "4.2 VARIATIONAL DROPOUT ",
492
+ "text_level": 1,
493
+ "bbox": [
494
+ 176,
495
+ 241,
496
+ 382,
497
+ 253
498
+ ],
499
+ "page_idx": 4
500
+ },
501
+ {
502
+ "type": "text",
503
+ "text": "In standard dropout, a new binary dropout mask is sampled each and every time the dropout function is called. New dropout masks are sampled even if the given connection is repeated, such as the input $x _ { 0 }$ to an LSTM at timestep $t = 0$ receiving a different dropout mask than the input $x _ { 1 }$ fed to the same LSTM at $t = 1$ . A variant of this, variational dropout (Gal & Ghahramani, 2016), samples a binary dropout mask only once upon the first call and then to repeatedly use that locked dropout mask for all repeated connections within the forward and backward pass. ",
504
+ "bbox": [
505
+ 174,
506
+ 266,
507
+ 825,
508
+ 349
509
+ ],
510
+ "page_idx": 4
511
+ },
512
+ {
513
+ "type": "text",
514
+ "text": "While we propose using DropConnect rather than variational dropout to regularize the hidden-tohidden transition within an RNN, we use variational dropout for all other dropout operations, specifically using the same dropout mask for all inputs and outputs of the LSTM within a given forward and backward pass. Each example within the minibatch uses a unique dropout mask, rather than a single dropout mask being used over all examples, ensuring diversity in the elements dropped out. ",
515
+ "bbox": [
516
+ 174,
517
+ 357,
518
+ 825,
519
+ 426
520
+ ],
521
+ "page_idx": 4
522
+ },
523
+ {
524
+ "type": "text",
525
+ "text": "4.3 EMBEDDING DROPOUT ",
526
+ "text_level": 1,
527
+ "bbox": [
528
+ 176,
529
+ 444,
530
+ 372,
531
+ 458
532
+ ],
533
+ "page_idx": 4
534
+ },
535
+ {
536
+ "type": "text",
537
+ "text": "Following Gal & Ghahramani (2016), we employ embedding dropout. This is equivalent to performing dropout on the embedding matrix at a word level, where the dropout is broadcast across all the word vector’s embedding. The remaining non-dropped-out word embeddings are scaled by $\\frac { 1 } { 1 - p _ { e } }$ where $p _ { e }$ is the probability of embedding dropout. As the dropout occurs on the embedding matrix that is used for a full forward and backward pass, this means that all occurrences of a specific word will disappear within that pass, equivalent to performing variational dropout on the connection between the one-hot embedding and the embedding lookup. ",
538
+ "bbox": [
539
+ 174,
540
+ 469,
541
+ 825,
542
+ 569
543
+ ],
544
+ "page_idx": 4
545
+ },
546
+ {
547
+ "type": "text",
548
+ "text": "4.4 WEIGHT TYING",
549
+ "text_level": 1,
550
+ "bbox": [
551
+ 174,
552
+ 587,
553
+ 323,
554
+ 601
555
+ ],
556
+ "page_idx": 4
557
+ },
558
+ {
559
+ "type": "text",
560
+ "text": "Weight tying (Inan et al., 2016; Press & Wolf, 2016) shares the weights between the embedding and softmax layer, substantially reducing the total parameter count in the model. The technique has theoretical motivation (Inan et al., 2016) and prevents the model from having to learn a one-to-one correspondence between the input and output, resulting in substantial improvements to the standard LSTM language model. ",
561
+ "bbox": [
562
+ 174,
563
+ 613,
564
+ 825,
565
+ 683
566
+ ],
567
+ "page_idx": 4
568
+ },
569
+ {
570
+ "type": "text",
571
+ "text": "4.5 INDEPENDENT EMBEDDING SIZE AND HIDDEN SIZE ",
572
+ "text_level": 1,
573
+ "bbox": [
574
+ 174,
575
+ 702,
576
+ 568,
577
+ 714
578
+ ],
579
+ "page_idx": 4
580
+ },
581
+ {
582
+ "type": "text",
583
+ "text": "In most natural language processing tasks, both pre-trained and trained word vectors are of relatively low dimensionality—frequently between 100 and 400 dimensions in size. Most previous LSTM language models tie the dimensionality of the word vectors to the dimensionality of the LSTM’s hidden state. Even if reducing the word embedding size was not beneficial in preventing overfitting, the easiest reduction in total parameters for a language model is reducing the word vector size. To achieve this, the first and last LSTM layers are modified such that their input and output dimensionality respectively are equal to the reduced embedding size. ",
584
+ "bbox": [
585
+ 174,
586
+ 727,
587
+ 823,
588
+ 824
589
+ ],
590
+ "page_idx": 4
591
+ },
592
+ {
593
+ "type": "text",
594
+ "text": "4.6 ACTIVATION REGULARIZATION (AR) AND TEMPORAL ACTIVATION REGULARIZATION (TAR) ",
595
+ "bbox": [
596
+ 171,
597
+ 842,
598
+ 810,
599
+ 869
600
+ ],
601
+ "page_idx": 4
602
+ },
603
+ {
604
+ "type": "text",
605
+ "text": "$L _ { 2 }$ -regularization is often used on the weights of the network to control the norm of the resulting model and reduce overfitting. In addition, $L _ { 2 }$ decay can be used on the individual unit activations and on the difference in outputs of an RNN at different time steps; these strategies labeled as activation regularization (AR) and temporal activation regularization (TAR) respectively (Merity et al., 2017). AR penalizes activations that are significantly larger than 0 as a means of regularizing the network. Concretely, AR is defined as ",
606
+ "bbox": [
607
+ 176,
608
+ 882,
609
+ 823,
610
+ 922
611
+ ],
612
+ "page_idx": 4
613
+ },
614
+ {
615
+ "type": "text",
616
+ "text": "",
617
+ "bbox": [
618
+ 173,
619
+ 103,
620
+ 825,
621
+ 146
622
+ ],
623
+ "page_idx": 5
624
+ },
625
+ {
626
+ "type": "equation",
627
+ "img_path": "images/ce4e638ed38937a1b2b408ecfc46f0ab544c630791cf1699835693b157c08543.jpg",
628
+ "text": "$$\n\\alpha L _ { 2 } ( m \\odot h _ { t } )\n$$",
629
+ "text_format": "latex",
630
+ "bbox": [
631
+ 449,
632
+ 161,
633
+ 547,
634
+ 179
635
+ ],
636
+ "page_idx": 5
637
+ },
638
+ {
639
+ "type": "text",
640
+ "text": "where $m$ is the dropout mask, $L _ { 2 } ( \\cdot ) = \\| \\cdot \\| _ { 2 } , h _ { t }$ is the output of the RNN at timestep $t$ , and $\\alpha$ is a scaling coefficient. TAR falls under the broad category of slowness regularizers (Hinton, 1989; Foldi ¨ ak, 1991; Luciw´ $\\&$ Schmidhuber, 2012; Jonschkowski & Brock, 2015) which penalize the model from producing large changes in the hidden state. Using the notation from AR, TAR is defined as ",
641
+ "bbox": [
642
+ 173,
643
+ 199,
644
+ 825,
645
+ 270
646
+ ],
647
+ "page_idx": 5
648
+ },
649
+ {
650
+ "type": "equation",
651
+ "img_path": "images/06edcc281b00c43782c6b8e0c681eff3481e1694c3e4eedc9275608312890940.jpg",
652
+ "text": "$$\n\\beta L _ { 2 } ( h _ { t } - h _ { t + 1 } )\n$$",
653
+ "text_format": "latex",
654
+ "bbox": [
655
+ 441,
656
+ 285,
657
+ 557,
658
+ 304
659
+ ],
660
+ "page_idx": 5
661
+ },
662
+ {
663
+ "type": "text",
664
+ "text": "where $\\beta$ is a scaling coefficient. As in Merity et al. (2017), the AR and TAR loss are only applied to the output of the final RNN layer as opposed to being applied to all layers. ",
665
+ "bbox": [
666
+ 173,
667
+ 323,
668
+ 825,
669
+ 353
670
+ ],
671
+ "page_idx": 5
672
+ },
673
+ {
674
+ "type": "text",
675
+ "text": "5 EXPERIMENT DETAILS ",
676
+ "text_level": 1,
677
+ "bbox": [
678
+ 176,
679
+ 386,
680
+ 395,
681
+ 401
682
+ ],
683
+ "page_idx": 5
684
+ },
685
+ {
686
+ "type": "text",
687
+ "text": "For evaluating the impact of these approaches, we perform language modeling over a preprocessed version of the Penn Treebank (PTB) (Mikolov et al., 2010) and the WikiText-2 (WT2) data set (Merity et al., 2016). ",
688
+ "bbox": [
689
+ 174,
690
+ 425,
691
+ 825,
692
+ 468
693
+ ],
694
+ "page_idx": 5
695
+ },
696
+ {
697
+ "type": "text",
698
+ "text": "PTB: The Penn Treebank data set has long been a central data set for experimenting with language modeling. The data set is heavily preprocessed and does not contain capital letters, numbers, or punctuation. The vocabulary is also capped at 10,000 unique words, quite small in comparison to most modern datasets, which results in a large number of out of vocabulary (OoV) tokens. ",
699
+ "bbox": [
700
+ 173,
701
+ 474,
702
+ 825,
703
+ 531
704
+ ],
705
+ "page_idx": 5
706
+ },
707
+ {
708
+ "type": "text",
709
+ "text": "WT2: WikiText-2 is sourced from curated Wikipedia articles and is approximately twice the size of the PTB data set. The text is tokenized and processed using the Moses tokenizer (Koehn et al., 2007), frequently used for machine translation, and features a vocabulary of over 30,000 words. Capitalization, punctuation, and numbers are retained in this data set. ",
710
+ "bbox": [
711
+ 174,
712
+ 537,
713
+ 825,
714
+ 594
715
+ ],
716
+ "page_idx": 5
717
+ },
718
+ {
719
+ "type": "text",
720
+ "text": "All experiments use a three-layer LSTM model with 1150 units in the hidden layer and an embedding of size 400. The loss was averaged over all examples and timesteps. All embedding weights were uniformly initialized in the interval $[ - 0 . 1 , 0 . 1 ]$ and all other weights were initialized between $[ - \\frac { 1 } { \\sqrt { H } } , \\frac { 1 } { \\sqrt { H } } ]$ , where $H$ is the hidden size. ",
721
+ "bbox": [
722
+ 174,
723
+ 601,
724
+ 823,
725
+ 659
726
+ ],
727
+ "page_idx": 5
728
+ },
729
+ {
730
+ "type": "text",
731
+ "text": "For training the models, we use the NT-AvSGD algorithm discussed in the previous section for 750 epochs with $L$ equivalent to one epoch and $n = 5$ . We use a batch size of 80 for WT2 and 40 for PTB. Empirically, we found relatively large batch sizes (e.g., 40-80) performed better than smaller sizes (e.g., 10-20) for NT-AvSGD. After completion, we run AvSGD with $T = 0$ and hot-started $w _ { 0 }$ as a fine-tuning step to further improve the solution. For this fine-tuning step, we terminate the run using the same non-monotonic criterion detailed in Algorithm 1. ",
732
+ "bbox": [
733
+ 173,
734
+ 666,
735
+ 825,
736
+ 750
737
+ ],
738
+ "page_idx": 5
739
+ },
740
+ {
741
+ "type": "text",
742
+ "text": "We carry out gradient clipping with maximum norm 0.25 and use an initial learning rate of 30 for all experiments. We use a random BPTT length which is $\\mathcal { N } ( 7 0 , 5 )$ with probability 0.95 and $\\mathcal { N } ( 3 5 , 5 )$ with probability 0.05. The values used for dropout on the word vectors, the output between LSTM layers, the output of the final LSTM layer, and embedding dropout where (0.4, 0.3, 0.4, 0.1) respectively. For the weight-dropped LSTM, a dropout of 0.5 was applied to the recurrent weight matrices. For WT2, we increase the input dropout to 0.65 to account for the increased vocabulary size. For all experiments, we use AR and TAR values of 2 and 1 respectively, and tie the embedding and softmax weights. These hyperparameters were chosen through trial and error and we expect further improvements may be possible if a fine-grained hyperparameter search were to be conducted. In the results, we abbreviate our approach as AWD-LSTM for AvSGD Weight-Dropped LSTM. The code for reproducing our results is open sourced and available at https://github.com/ salesforce/awd-lstm-lm. ",
743
+ "bbox": [
744
+ 173,
745
+ 757,
746
+ 825,
747
+ 922
748
+ ],
749
+ "page_idx": 5
750
+ },
751
+ {
752
+ "type": "table",
753
+ "img_path": "images/a2a2fe6f16010b9688bcee87fc223905e13edf7c075be6367273c5ddf191050b.jpg",
754
+ "table_caption": [
755
+ "Table 1: Single model perplexity on validation and test sets for the Penn Treebank language modeling task. Parameter numbers with $^ \\ddag$ are estimates based upon our understanding of the model and with reference to (Merity et al., 2016). Models noting tied use weight tying on the embedding and softmax weights. Our model, AWD-LSTM, stands for AvSGD Weight-Dropped LSTM. "
756
+ ],
757
+ "table_footnote": [],
758
+ "table_body": "<table><tr><td>Model</td><td>Parameters</td><td>Validation</td><td>Test</td></tr><tr><td>Mikolov&amp; Zweig (2012) - KN-5</td><td>2M</td><td></td><td>141.2</td></tr><tr><td>Mikolov &amp; Zweig (2012) - KN5 + cache</td><td>2M</td><td></td><td>125.7</td></tr><tr><td>Mikolov&amp; Zweig (2012) - RNN</td><td>6Mt</td><td></td><td>124.7</td></tr><tr><td>Mikolov &amp; Zweig (2012) - RNN-LDA</td><td>7M</td><td></td><td>113.7</td></tr><tr><td>Mikolov &amp; Zweig (2012) - RNN-LDA + KN-5 + cache</td><td>9M</td><td></td><td>92.0</td></tr><tr><td>Zaremba et al. (2014) -LSTM (medium)</td><td>20M</td><td>86.2</td><td>82.7</td></tr><tr><td>Zaremba et al. (2014) - LSTM (large)</td><td>66M</td><td>82.2</td><td>78.4</td></tr><tr><td>Gal &amp; Ghahramani (2O16)- Variational LSTM</td><td>20M</td><td>1</td><td>78.6</td></tr><tr><td>Gal &amp; Ghahramani (2O16)- Variational LSTM</td><td>66M</td><td>1</td><td>73.4</td></tr><tr><td>Kim et al. (2016) - CharCNN</td><td>19M</td><td>1</td><td>78.9</td></tr><tr><td>Merity et al. (2016) - Pointer Sentinel-LSTM</td><td>21M</td><td>72.4</td><td>70.9</td></tr><tr><td>Grave et al. (2016) - LSTM Grave et al. (2016) - LSTM + continuous cache pointer</td><td>1</td><td>1</td><td>82.3</td></tr><tr><td>Inan et al.(2O16) -Variational LSTM(tied) +augmented loss</td><td>一</td><td>1</td><td>72.1</td></tr><tr><td>Inan et al. (2016) - Variational LSTM (tied) + augmented loss</td><td>24M</td><td>75.7</td><td>73.2</td></tr><tr><td>Zilly et al. (2016) - Variational RHN (tied)</td><td>51M</td><td>71.1</td><td>68.5</td></tr><tr><td>Zoph &amp; Le (2016) - NAS Cell (tied)</td><td>23M</td><td>67.9</td><td>65.4</td></tr><tr><td></td><td>25M</td><td>1</td><td>64.0</td></tr><tr><td>Zoph &amp; Le (2016) - NAS Cell (tied)</td><td>54M</td><td>一</td><td>62.4</td></tr><tr><td>Melis et al. (2017) - 4-layer skip connection LSTM (tied)</td><td>24M</td><td>60.9</td><td>58.3</td></tr><tr><td>AWD-LSTM - 3-layer LSTM (tied)</td><td>24M</td><td>60.0</td><td>57.3</td></tr><tr><td>AWD-LSTM - 3-layer LSTM (tied) + continuous cache pointer</td><td>24M</td><td>53.9</td><td>52.8</td></tr></table>",
759
+ "bbox": [
760
+ 179,
761
+ 101,
762
+ 812,
763
+ 412
764
+ ],
765
+ "page_idx": 6
766
+ },
767
+ {
768
+ "type": "table",
769
+ "img_path": "images/17ad5e97948bf488a798297b9de44909c1ff22ed4409f6d9a83d82f50cb24e39.jpg",
770
+ "table_caption": [
771
+ "Table 2: Single model perplexity over WikiText-2. Models noting tied use weight tying on the embedding and softmax weights. Our model, AWD-LSTM, stands for AvSGD Weight-Dropped LSTM. "
772
+ ],
773
+ "table_footnote": [],
774
+ "table_body": "<table><tr><td>Model</td><td>Parameters</td><td>Validation</td><td>Test</td></tr><tr><td>Inan et al. (2016) - Variational LSTM (tied)</td><td>28M</td><td>92.3</td><td>87.7</td></tr><tr><td>Inan et al. (2016) - Variational LSTM (tied) + augmented loss</td><td>28M</td><td>91.5</td><td>87.0</td></tr><tr><td>Grave et al. (2016) - LSTM</td><td>1</td><td>1</td><td>99.3</td></tr><tr><td>Grave et al. (2016) - LSTM + continuous cache pointer</td><td>1</td><td>1</td><td>68.9</td></tr><tr><td>Melis et al. (2017)- 1-layer LSTM (tied)</td><td>24M</td><td>69.3</td><td>65.9</td></tr><tr><td>Melis et al. (2017) - 2-layer skip connection LSTM (tied)</td><td>24M</td><td>69.1</td><td>65.9</td></tr><tr><td>AWD-LSTM- 3-layer LSTM (tied)</td><td>33M</td><td>68.6</td><td>65.8</td></tr><tr><td>AWD-LSTM - 3-layer LSTM (tied) + continuous cache pointer</td><td>33M</td><td>53.8</td><td>52.0</td></tr></table>",
775
+ "bbox": [
776
+ 186,
777
+ 492,
778
+ 807,
779
+ 636
780
+ ],
781
+ "page_idx": 6
782
+ },
783
+ {
784
+ "type": "text",
785
+ "text": "6 EXPERIMENTAL ANALYSIS ",
786
+ "text_level": 1,
787
+ "bbox": [
788
+ 176,
789
+ 710,
790
+ 428,
791
+ 727
792
+ ],
793
+ "page_idx": 6
794
+ },
795
+ {
796
+ "type": "text",
797
+ "text": "We present the single-model perplexity results for both our models (AWD-LSTM) and other competitive models in Table 1 and 2 for PTB and WT2 respectively 1. On both data sets we improve the state-of-the-art, with our vanilla LSTM model beating the state of the art by approximately 1 unit on PTB and 0.1 units on WT2. ",
798
+ "bbox": [
799
+ 174,
800
+ 742,
801
+ 825,
802
+ 797
803
+ ],
804
+ "page_idx": 6
805
+ },
806
+ {
807
+ "type": "text",
808
+ "text": "In comparison to other recent state-of-the-art models, our model uses a vanilla LSTM. Zilly et al. (2016) propose the recurrent highway network, which extends the LSTM to allow multiple hidden state updates per timestep. Zoph & Le (2016) use a reinforcement learning agent to generate an RNN cell tailored to the specific task of language modeling, with the cell far more complex than the LSTM. ",
809
+ "bbox": [
810
+ 174,
811
+ 805,
812
+ 825,
813
+ 875
814
+ ],
815
+ "page_idx": 6
816
+ },
817
+ {
818
+ "type": "text",
819
+ "text": "Independently of our work, Melis et al. (2017) apply extensive hyperparameter search to an LSTM based language modeling implementation, analyzing the sensitivity of RNN based language models to hyperparameters. Unlike our work, they use a modified LSTM, which caps the input gate $i _ { t }$ to be $\\operatorname* { m i n } ( 1 - f _ { t } , i _ { t } )$ , use Adam with $\\beta _ { 1 } = 0$ rather than SGD or AvSGD, use skip connections between LSTM layers, and use a black box hyperparameter tuner for exploring models and settings. Of particular interest is that their hyperparameters were tuned individually for each data set compared to our work which shared almost all hyperparameters between PTB and WT2, including the embedding and hidden size for both data sets. Due to this, they used less model parameters than our model and found shallow LSTMs of one or two layers worked best for WT2. ",
820
+ "bbox": [
821
+ 174,
822
+ 103,
823
+ 825,
824
+ 228
825
+ ],
826
+ "page_idx": 7
827
+ },
828
+ {
829
+ "type": "text",
830
+ "text": "Like our work, Melis et al. (2017) find that the underlying LSTM architecture can be highly effective compared to complex custom architectures when well tuned hyperparameters are used. The approaches used in our work and (Melis et al., 2017) may be complementary and would be worth exploration. ",
831
+ "bbox": [
832
+ 176,
833
+ 236,
834
+ 825,
835
+ 291
836
+ ],
837
+ "page_idx": 7
838
+ },
839
+ {
840
+ "type": "text",
841
+ "text": "6.1 POINTER MODELS ",
842
+ "text_level": 1,
843
+ "bbox": [
844
+ 176,
845
+ 309,
846
+ 339,
847
+ 323
848
+ ],
849
+ "page_idx": 7
850
+ },
851
+ {
852
+ "type": "text",
853
+ "text": "In past work, pointer based attention models have been shown to be highly effective in improving language modeling (Merity et al., 2016; Grave et al., 2016). Given such substantial improvements to the underlying neural language model, it remained an open question as to how effective pointer augmentation may be, especially when improvements such as weight tying may act in mutually exclusive ways. ",
854
+ "bbox": [
855
+ 174,
856
+ 335,
857
+ 823,
858
+ 406
859
+ ],
860
+ "page_idx": 7
861
+ },
862
+ {
863
+ "type": "text",
864
+ "text": "The neural cache model (Grave et al., 2016) can be added on top of a pre-trained language model at negligible cost. The neural cache stores the previous hidden states in memory cells and then uses a simple convex combination of the probability distributions suggested by the cache and the language model for prediction. The cache model has three hyperparameters: the memory size (window) for the cache, the coefficient of the combination (which determines how the two distributions are mixed), and the flatness of the cache distribution. All of these are tuned on the validation set once a trained language model has been obtained and require no training by themselves, making it quite inexpensive to use. The tuned values for these hyperparameters were (2000, 0.1, 1.0) for PTB and (3785, 0.1279, 0.662) for WT2 respectively. ",
865
+ "bbox": [
866
+ 174,
867
+ 412,
868
+ 825,
869
+ 537
870
+ ],
871
+ "page_idx": 7
872
+ },
873
+ {
874
+ "type": "text",
875
+ "text": "In Tables 1 and 2, we show that the model further improves the perplexity of the language model by as much as 6 perplexity points for PTB and 11 points for WT2. While this is smaller than the gains reported in Grave et al. (2016), which used an LSTM without weight tying, this is still a substantial drop. Given the simplicity of the neural cache model, and the lack of any trained components, these results suggest that existing neural language models remain fundamentally lacking, failing to capture long term dependencies or remember recently seen words effectively. ",
876
+ "bbox": [
877
+ 174,
878
+ 545,
879
+ 825,
880
+ 628
881
+ ],
882
+ "page_idx": 7
883
+ },
884
+ {
885
+ "type": "text",
886
+ "text": "To understand the impact the pointer had on the model, specifically the validation set perplexity, we detail the contribution that each word has on the cache model’s overall perplexity in Table 3. We compute the sum of the total difference in the loss function value (i.e., log perplexity) between the LSTM-only and LSTM-with-cache models for the target words in the validation portion of the WikiText-2 data set. We present results for the sum of the difference as opposed to the mean since the latter undesirably overemphasizes infrequently occurring words for which the cache helps significantly and ignores frequently occurring words for which the cache provides modest improvements that cumulatively make a strong contribution. ",
887
+ "bbox": [
888
+ 174,
889
+ 636,
890
+ 825,
891
+ 747
892
+ ],
893
+ "page_idx": 7
894
+ },
895
+ {
896
+ "type": "text",
897
+ "text": "The largest cumulative gain is in improving the handling of ${ \\tt { < u n k > } }$ tokens, though this is over 11540 instances. The second best improvement, approximately one fifth the gain given by the ${ \\mathrm { \\ c u n k { \\mathrm { > } } } }$ tokens, is for Meridian, yet this word only occurs 161 times. This indicates the cache still helps significantly even for relatively rare words, further demonstrated by Churchill, Blythe, or Sonic. The cache is not beneficial when handling frequent word categories, such as punctuation or stop words, for which the language model is likely well suited. These observations motivate the design of a cache framework that is more aware of the relative strengths of the two models. ",
898
+ "bbox": [
899
+ 174,
900
+ 753,
901
+ 825,
902
+ 851
903
+ ],
904
+ "page_idx": 7
905
+ },
906
+ {
907
+ "type": "text",
908
+ "text": "6.2 AWD-QRNN ",
909
+ "text_level": 1,
910
+ "bbox": [
911
+ 174,
912
+ 868,
913
+ 310,
914
+ 883
915
+ ],
916
+ "page_idx": 7
917
+ },
918
+ {
919
+ "type": "text",
920
+ "text": "Several architectures for learning sequential data based on convolutions, instead of recurrences, have been proposed recently. We briefly mention experiments on the same language modeling using quasi-recurrent neural networks (QRNNs) (Bradbury et al., 2016) instead of LSTMs; we label this setup the AWD-QRNN. As in the case of AWD-LSTM, we regularize the network through weight, embedding and variational dropouts along with variable sequence lengths, weight tying, AR and TAR. The networks were designed such that they had the same number of parameters as their LSTM counterparts and were trained using NT-AvSGD. Despite the same size of the network, QRNNs were $2 - 4 \\times$ faster per epoch as compared to their LSTM counterparts and required fewer epochs to converge. We report the results in Table 4. As is evident from the table, the QRNN model achieves comparable results to the LSTM suggesting the generality of the proposed regularization techniques. Interestingly, the hyperparameter values for the various regularization components, including the optimization procedure, needed minimal changes from the LSTM to the QRNN models for competitive performance. For full details and hyperparameters, refer to the released code. ",
921
+ "bbox": [
922
+ 176,
923
+ 895,
924
+ 823,
925
+ 924
926
+ ],
927
+ "page_idx": 7
928
+ },
929
+ {
930
+ "type": "table",
931
+ "img_path": "images/72a032772c8081ba2793196342163d9396f03bdec9eb9240fe386f4dfdf9e7ed.jpg",
932
+ "table_caption": [
933
+ "Table 3: The sum total difference in loss (log perplexity) that a given word results in over all instances in the validation data set of WikiText-2 when the continuous cache pointer is introduced. The right column contains the words with the twenty best improvements (i.e., where the cache was advantageous), and the left column the twenty most deteriorated (i.e., where the cache was disadvantageous). "
934
+ ],
935
+ "table_footnote": [],
936
+ "table_body": "<table><tr><td>Word</td><td>Count</td><td>△loss</td><td>Word</td><td>Count</td><td>△loss</td></tr><tr><td>·</td><td>7632</td><td>-696.45</td><td>&lt;unk&gt;</td><td>11540</td><td>5047.34</td></tr><tr><td>,</td><td>9857</td><td>-687.49</td><td>Meridian</td><td>161</td><td>1057.78</td></tr><tr><td>of</td><td>5816</td><td>-365.21</td><td>Churchill</td><td>137</td><td>849.43</td></tr><tr><td>=</td><td>2884</td><td>-342.01</td><td>-</td><td>67</td><td>682.15</td></tr><tr><td>to</td><td>4048</td><td>-283.10</td><td>Blythe</td><td>97</td><td>554.95</td></tr><tr><td>in</td><td>4178</td><td>-222.94</td><td>Sonic</td><td>75</td><td>543.85</td></tr><tr><td>&lt;eos&gt;</td><td>3690</td><td>-216.42</td><td>Richmond</td><td>101</td><td>429.18</td></tr><tr><td>and</td><td>5251</td><td>-215.38</td><td>Starr</td><td>74</td><td>416.52</td></tr><tr><td>the</td><td>12481</td><td>-209.97</td><td>Australian</td><td>234</td><td>366.36</td></tr><tr><td>a</td><td>3381</td><td>-149.78</td><td>Pagan</td><td>54</td><td>365.19</td></tr><tr><td>”</td><td>2540</td><td>-127.99</td><td>Asahi</td><td>39</td><td>316.24</td></tr><tr><td>that</td><td>1365</td><td>-118.09</td><td>Japanese</td><td>181</td><td>295.97</td></tr><tr><td>by</td><td>1252</td><td>-113.05</td><td>Hu</td><td>43</td><td>285.58</td></tr><tr><td>was</td><td>2279</td><td>-107.95</td><td>Hedgehog</td><td>29</td><td>266.48</td></tr><tr><td>)</td><td>1101</td><td>-94.74</td><td>Burma</td><td>35</td><td>263.65</td></tr><tr><td>with</td><td>1176</td><td>-93.01</td><td>29</td><td>92</td><td>260.88</td></tr><tr><td>for</td><td>1215</td><td>-87.68</td><td>Mississippi</td><td>72</td><td>241.59</td></tr><tr><td>on</td><td>1485</td><td>-81.55</td><td>German</td><td>108</td><td>241.23</td></tr><tr><td>as</td><td>1338</td><td>-77.05</td><td>mill</td><td>67</td><td>237.76</td></tr><tr><td>at</td><td>879</td><td>-59.86</td><td>Cooke</td><td>33</td><td>231.11</td></tr></table>",
937
+ "bbox": [
938
+ 299,
939
+ 101,
940
+ 697,
941
+ 382
942
+ ],
943
+ "page_idx": 8
944
+ },
945
+ {
946
+ "type": "table",
947
+ "img_path": "images/ff9c249c0724979903f20a243ffffdfe8e3220aafd7146ec8cb7af5dca6ec16c.jpg",
948
+ "table_caption": [
949
+ "Table 4: Comparison of AWD-LSTM and AWD-QRNN for the same model size on the PTB and WikiText-2 data sets. "
950
+ ],
951
+ "table_footnote": [],
952
+ "table_body": "<table><tr><td rowspan=\"2\">Model</td><td colspan=\"2\">PTB</td><td colspan=\"2\">WT2</td></tr><tr><td>Validation</td><td>Test</td><td>Validation</td><td>Test</td></tr><tr><td>AWD-LSTM only training</td><td>60.7</td><td>58.3</td><td>69.1</td><td>66.0</td></tr><tr><td>+ fine tune</td><td>60.0</td><td>57.3</td><td>68.6</td><td>65.8</td></tr><tr><td>+ fine tune + continuous cache pointer</td><td>53.9</td><td>52.8</td><td>53.8</td><td>52.0</td></tr><tr><td>QRNN-LSTM only training</td><td>60.6</td><td>58.3</td><td>69.3</td><td>66.8</td></tr><tr><td>+ fine tune</td><td>59.1</td><td>56.7</td><td>68.5</td><td>65.9</td></tr><tr><td>+ fine tune + continuous cache pointer</td><td>53.4</td><td>52.6</td><td>53.6</td><td>52.1</td></tr></table>",
953
+ "bbox": [
954
+ 220,
955
+ 488,
956
+ 774,
957
+ 622
958
+ ],
959
+ "page_idx": 8
960
+ },
961
+ {
962
+ "type": "text",
963
+ "text": "",
964
+ "bbox": [
965
+ 174,
966
+ 689,
967
+ 825,
968
+ 843
969
+ ],
970
+ "page_idx": 8
971
+ },
972
+ {
973
+ "type": "text",
974
+ "text": "6.3 MODEL ABLATION ANALYSIS ",
975
+ "text_level": 1,
976
+ "bbox": [
977
+ 176,
978
+ 867,
979
+ 421,
980
+ 881
981
+ ],
982
+ "page_idx": 8
983
+ },
984
+ {
985
+ "type": "text",
986
+ "text": "In Table 5, we present the values of validation and testing perplexity for different variants of our best-performing LSTM model. Each variant removes a form of optimization or regularization. ",
987
+ "bbox": [
988
+ 173,
989
+ 895,
990
+ 823,
991
+ 924
992
+ ],
993
+ "page_idx": 8
994
+ },
995
+ {
996
+ "type": "table",
997
+ "img_path": "images/6c44d5888c7d379aebb7c7dd619cf921e55f3f66d0ec6836043aa7faa4909f7d.jpg",
998
+ "table_caption": [
999
+ "Table 5: Model ablations for our best LSTM models reporting results over the validation and test set on Penn Treebank and WikiText-2. Ablations are split into optimization and regularization variants, sorted according to the achieved validation perplexity on WikiText-2. "
1000
+ ],
1001
+ "table_footnote": [],
1002
+ "table_body": "<table><tr><td rowspan=\"2\">Model</td><td colspan=\"2\">PTB</td><td colspan=\"2\">WT2</td></tr><tr><td>Validation</td><td>Test</td><td>Validation</td><td>Test</td></tr><tr><td>AWD-LSTM (tied)</td><td>60.0</td><td>57.3</td><td>68.6</td><td>65.8</td></tr><tr><td>- fine-tuning</td><td>60.7</td><td>58.8</td><td>69.1</td><td>66.0</td></tr><tr><td>- NT-AvSGD</td><td>66.3</td><td>63.7</td><td>73.3</td><td>69.7</td></tr><tr><td>- variable sequence lengths</td><td>61.3</td><td>58.9</td><td>69.3</td><td>66.2</td></tr><tr><td>- embedding dropout</td><td>65.1</td><td>62.7</td><td>71.1</td><td>68.1</td></tr><tr><td>- weight decay</td><td>63.7</td><td>61.0</td><td>71.9</td><td>68.7</td></tr><tr><td>- AR/TAR</td><td>62.7</td><td>60.3</td><td>73.2</td><td>70.1</td></tr><tr><td>- full sized embedding</td><td>68.0</td><td>65.6</td><td>73.7</td><td>70.7</td></tr><tr><td>- weight-dropping</td><td>71.1</td><td>68.9</td><td>78.4</td><td>74.9</td></tr></table>",
1003
+ "bbox": [
1004
+ 254,
1005
+ 102,
1006
+ 740,
1007
+ 281
1008
+ ],
1009
+ "page_idx": 9
1010
+ },
1011
+ {
1012
+ "type": "text",
1013
+ "text": "The first two variants deal with the optimization of the language models while the rest deal with the regularization. For the model using SGD with learning rate reduced by 2 using the same nonmonotonic fashion, there is a significant degradation in performance. This stands as empirical evidence regarding the benefit of averaging of the iterates. Using a monotonic criterion instead also hampered performance. Similarly, the removal of the fine-tuning step expectedly also degrades the performance. This step helps improve the estimate of the minimizer by resetting the memory of the previous experiment. While this process of fine-tuning can be repeated multiple times, we found little benefit in repeating it more than once. ",
1014
+ "bbox": [
1015
+ 174,
1016
+ 363,
1017
+ 825,
1018
+ 476
1019
+ ],
1020
+ "page_idx": 9
1021
+ },
1022
+ {
1023
+ "type": "text",
1024
+ "text": "The removal of regularization strategies paints a similar picture; the inclusion of all of the proposed strategies was pivotal in ensuring state-of-the-art performance. The most extreme perplexity jump was in removing the hidden-to-hidden LSTM regularization provided by the weight-dropped LSTM. Without such hidden-to-hidden regularization, perplexity rises substantially, up to 11 points. This is in line with previous work showing the necessity of recurrent regularization in state-of-the-art models (Gal & Ghahramani, 2016; Inan et al., 2016). ",
1025
+ "bbox": [
1026
+ 174,
1027
+ 483,
1028
+ 825,
1029
+ 565
1030
+ ],
1031
+ "page_idx": 9
1032
+ },
1033
+ {
1034
+ "type": "text",
1035
+ "text": "We also experiment with static sequence lengths which we had hypothesized would lead to inefficient data usage. This also worsens the performance by approximately one perplexity unit. Next, we experiment with reverting to matching the sizes of the embedding vectors and the hidden states. This significantly increases the number of parameters in the network (to 43M in the case of PTB and 70M for WT2) and leads to degradation by almost 8 perplexity points, which we attribute to overfitting in the word embeddings. While this could potentially be improved with more aggressive regularization, the computational overhead involved with substantially larger embeddings likely outweighs any advantages. Finally, we experiment with the removal of embedding dropout, AR/TAR and weight decay. In all of the cases, the model suffers a perplexity increase of 2–6 points which we hypothesize is due to insufficient regularization in the network. ",
1036
+ "bbox": [
1037
+ 174,
1038
+ 573,
1039
+ 825,
1040
+ 712
1041
+ ],
1042
+ "page_idx": 9
1043
+ },
1044
+ {
1045
+ "type": "text",
1046
+ "text": "7 CONCLUSION ",
1047
+ "text_level": 1,
1048
+ "bbox": [
1049
+ 176,
1050
+ 737,
1051
+ 318,
1052
+ 752
1053
+ ],
1054
+ "page_idx": 9
1055
+ },
1056
+ {
1057
+ "type": "text",
1058
+ "text": "In this work, we discuss regularization and optimization strategies for neural language models. We propose the weight-dropped LSTM, a strategy that uses a DropConnect mask on the hidden-tohidden weight matrices, as a means to prevent overfitting across the recurrent connections. Further, we investigate the use of averaged SGD with a non-monontonic trigger for training language models and show that it outperforms SGD by a significant margin. We investigate other regularization strategies including the use of variable BPTT length and achieve a new state-of-the-art perplexity on the PTB and WikiText-2 data sets. Our models outperform custom-built RNN cells and complex regularization strategies that preclude the possibility of using optimized libraries such as the NVIDIA cuDNN LSTM. We explore the use of a neural cache in conjunction with our proposed model and show that this further improves the performance, thus attaining an even lower state-of-the-art perplexity. We also explore the viability of using the proposed regularization and optimization strategies in the context of a quasi-recurrent neural network (QRNN) and demonstrate comparable performance to the LSTM counterpart. While the regularization and optimization strategies proposed are demonstrated on the task of language modeling, we anticipate that they would be generally applicable across other sequence learning tasks. ",
1059
+ "bbox": [
1060
+ 174,
1061
+ 770,
1062
+ 825,
1063
+ 924
1064
+ ],
1065
+ "page_idx": 9
1066
+ },
1067
+ {
1068
+ "type": "text",
1069
+ "text": "",
1070
+ "bbox": [
1071
+ 174,
1072
+ 103,
1073
+ 825,
1074
+ 160
1075
+ ],
1076
+ "page_idx": 10
1077
+ },
1078
+ {
1079
+ "type": "text",
1080
+ "text": "REFERENCES ",
1081
+ "text_level": 1,
1082
+ "bbox": [
1083
+ 174,
1084
+ 181,
1085
+ 285,
1086
+ 195
1087
+ ],
1088
+ "page_idx": 10
1089
+ },
1090
+ {
1091
+ "type": "text",
1092
+ "text": "M. Arjovsky, A. Shah, and Y. Bengio. Unitary evolution recurrent neural networks. In International Conference on Machine Learning, pp. 1120–1128, 2016. \nJ. Ba, J. Kiros, and G. E. Hinton. Layer normalization. CoRR, abs/1607.06450, 2016. \nD. Balduzzi and M. Ghifary. Strongly-typed recurrent neural networks. arXiv preprint arXiv:1602.02218, 2016. \nL. Bottou, F. E. Curtis, and J. Nocedal. Optimization methods for large-scale machine learning. arXiv preprint arXiv:1606.04838, 2016. \nJ. Bradbury, S. Merity, C. Xiong, and R. Socher. Quasi-Recurrent Neural Networks. arXiv preprint arXiv:1611.01576, 2016. \nT. Cooijmans, N. Ballas, C. Laurent, and A. C. Courville. Recurrent batch normalization. CoRR, abs/1603.09025, 2016. \nJ. Duchi, E. Hazan, and Y. Singer. Adaptive subgradient methods for online learning and stochastic optimization. Journal of Machine Learning Research, 12(Jul):2121–2159, 2011. \nP. Foldi ¨ ak. Learning invariance from transformation sequences. ´ Neural Computation, 3(2):194–200, 1991. \nY. Gal and Z. Ghahramani. A theoretically grounded application of dropout in recurrent neural networks. In NIPS, 2016. \nP. Goyal, P. Dollar, R. Girshick, P. Noordhuis, L. Wesolowski, A. Kyrola, A. Tulloch, Y. Jia, ´ and K. He. Accurate, large minibatch sgd: Training imagenet in 1 hour. arXiv preprint arXiv:1706.02677, 2017. \nE. Grave, A. Joulin, and N. Usunier. Improving neural language models with a continuous cache. arXiv preprint arXiv:1612.04426, 2016. \nM. Hardt, B. Recht, and Y. Singer. Train faster, generalize better: Stability of stochastic gradient descent. arXiv preprint arXiv:1509.01240, 2015. \nG. E. Hinton. Connectionist learning procedures. Artificial intelligence, 40(1-3):185–234, 1989. \nH. Inan, K. Khosravi, and R. Socher. Tying Word Vectors and Word Classifiers: A Loss Framework for Language Modeling. arXiv preprint arXiv:1611.01462, 2016. \nS. Ioffe and C. Szegedy. Batch normalization: Accelerating deep network training by reducing internal covariate shift. In ICML, 2015. \nL. Jing, Y. Shen, T. Dubcek, J. Peurifoy, S. Skirlo, M. Tegmark, and M. Solja ˇ ciˇ c. Tunable ´ Efficient Unitary Neural Networks (EUNN) and their application to RNN. arXiv preprint arXiv:1612.05231, 2016. \nR. Jonschkowski and O. Brock. Learning state representations with robotic priors. Auton. Robots, 39:407–428, 2015. \nN. Keskar and G. Saon. A nonmonotone learning rate strategy for sgd training of deep neural networks. In Acoustics, Speech and Signal Processing (ICASSP), 2015 IEEE International Conference on, pp. 4974–4978. IEEE, 2015. \nY. Kim, Y. Jernite, D. Sontag, and A. M. Rush. Character-aware neural language models. In Thirtieth AAAI Conference on Artificial Intelligence, 2016. \nD. Kingma and J. Ba. Adam: A method for stochastic optimization. arXiv preprint arXiv:1412.6980, 2014. \nP. Koehn, H. Hoang, A. Birch, C. Callison-Burch, M. Federico, N. Bertoldi, B. Cowan, W. Shen, C. Moran, R. Zens, C. Dyer, O. Bojar, A. Constantin, and E. Herbst. Moses: Open source toolkit for statistical machine translation. In ACL, 2007. \nD. Krueger, T. Maharaj, J. Kramar, M. Pezeshki, N. Ballas, N. Ke, A. Goyal, Y. Bengio, ´ H. Larochelle, A. Courville, et al. Zoneout: Regularizing RNNss by randomly preserving hidden activations. arXiv preprint arXiv:1606.01305, 2016. \nM. Luciw and J. Schmidhuber. Low complexity proto-value function learning from sensory observations with incremental slow feature analysis. Artificial Neural Networks and Machine Learning– ICANN 2012, pp. 279–287, 2012. \nS. Mandt, M. D. Hoffman, and D. M. Blei. Stochastic gradient descent as approximate bayesian inference. arXiv preprint arXiv:1704.04289, 2017. \nG. Melis, C. Dyer, and P. Blunsom. On the State of the Art of Evaluation in Neural Language Models. arXiv preprint arXiv:1707.05589, 2017. \nS. Merity, C. Xiong, J. Bradbury, and R. Socher. Pointer Sentinel Mixture Models. arXiv preprint arXiv:1609.07843, 2016. \nS. Merity, B. McCann, and R. Socher. Revisiting activation regularization for language rnns. arXiv preprint arXiv:1708.01009, 2017. \nT. Mikolov and G. Zweig. Context dependent recurrent neural network language model. SLT, 12: 234–239, 2012. \nT. Mikolov, M. Karafiat, L. Burget, J. Cernock ´ y, and S. Khudanpur. Recurrent neural network based ´ language model. In INTERSPEECH, 2010. \nI. Panageas and G. Piliouras. Gradient descent converges to minimizers: The case of non-isolated critical points. CoRR, abs/1605.00405, 2016. \nB. Polyak and A. Juditsky. Acceleration of stochastic approximation by averaging. SIAM Journal on Control and Optimization, 30(4):838–855, 1992. \nO. Press and L. Wolf. Using the output embedding to improve language models. arXiv preprint arXiv:1608.05859, 2016. \nS. Semeniuta, A. Severyn, and E. Barth. Recurrent dropout without memory loss. In COLING, 2016. \nM. Seo, S. Min, A. Farhadi, and H. Hajishirzi. Query-Reduction Networks for Question Answering. arXiv preprint arXiv:1606.04582, 2016. \nN. Srivastava, G. Hinton, A. Krizhevsky, I. Sutskever, and R. Salakhutdinov. Dropout: a simple way to prevent neural networks from overfitting. Journal of Machine Learning Research, 15: 1929–1958, 2014. \nI. Sutskever, J. Martens, G. Dahl, and G. Hinton. On the importance of initialization and momentum in deep learning. In International conference on machine learning, pp. 1139–1147, 2013. \nC. Tallec and Y. Ollivier. Unbiasing truncated backpropagation through time. arXiv preprint arXiv:1705.08209, 2017. \nT. Tieleman and G. Hinton. Lecture 6.5-rmsprop: Divide the gradient by a running average of its recent magnitude. COURSERA: Neural networks for machine learning, 4(2):26–31, 2012. \nL. Wan, M. Zeiler, S. Zhang, Y LeCun, and R. Fergus. Regularization of neural networks using dropconnect. In Proceedings of the 30th international conference on machine learning (ICML13), pp. 1058–1066, 2013. \nA. C Wilson, R. Roelofs, M. Stern, N. Srebro, and B. Recht. The marginal value of adaptive gradient methods in machine learning. arXiv preprint arXiv:1705.08292, 2017. \nS. Wisdom, T. Powers, J. Hershey, J. Le Roux, and L. Atlas. Full-capacity unitary recurrent neural networks. In Advances in Neural Information Processing Systems, pp. 4880–4888, 2016. \nW. Zaremba, I. Sutskever, and O. Vinyals. Recurrent neural network regularization. arXiv preprint arXiv:1409.2329, 2014. \nJ. G. Zilly, R. K. Srivastava, J. Koutn´ık, and J. Schmidhuber. Recurrent highway networks. arXiv preprint arXiv:1607.03474, 2016. \nB. Zoph and Q. V. Le. Neural architecture search with reinforcement learning. arXiv preprint arXiv:1611.01578, 2016. ",
1093
+ "bbox": [
1094
+ 171,
1095
+ 194,
1096
+ 828,
1097
+ 928
1098
+ ],
1099
+ "page_idx": 10
1100
+ },
1101
+ {
1102
+ "type": "text",
1103
+ "text": "",
1104
+ "bbox": [
1105
+ 168,
1106
+ 64,
1107
+ 828,
1108
+ 929
1109
+ ],
1110
+ "page_idx": 11
1111
+ },
1112
+ {
1113
+ "type": "text",
1114
+ "text": "",
1115
+ "bbox": [
1116
+ 168,
1117
+ 103,
1118
+ 828,
1119
+ 284
1120
+ ],
1121
+ "page_idx": 12
1122
+ }
1123
+ ]
parse/train/SyyGPP0TZ/SyyGPP0TZ_middle.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/SyyGPP0TZ/SyyGPP0TZ_model.json ADDED
The diff for this file is too large to render. See raw diff