ZHANGYUXUAN-zR commited on
Commit
a6ea37c
·
verified ·
1 Parent(s): 3f01fc2

Add files using upload-large-folder tool

Browse files
parse/train/HJV1zP5xg/HJV1zP5xg.md ADDED
@@ -0,0 +1,385 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # DIVERSE BEAM SEARCH: DECODING DIVERSE SOLUTIONS FROM NEURAL SEQUENCE MODELS
2
+
3
+ Ashwin K Vijayakumar1, Michael Cogswell1, Ramprasaath R. Selvaraju1, Qing Sun1
4
+ Stefan Lee1, David Crandall2 & Dhruv Batra1
5
+
6
+ {ashwinkv,cogswell,ram21,sunqing,steflee}@vt.edu djcran@indiana.edu, dbatra@vt.edu
7
+
8
+ 1 Department of Electrical and Computer Engineering, Virginia Tech, Blacksburg, VA, USA
9
+
10
+ 2 School of Informatics and Computing Indiana University, Bloomington, IN, USA
11
+
12
+ # ABSTRACT
13
+
14
+ Neural sequence models are widely used to model time-series data. Equally ubiquitous is the usage of beam search (BS) as an approximate inference algorithm to decode output sequences from these models. BS explores the search space in a greedy left-right fashion retaining only the top $B$ candidates. This tends to result in sequences that differ only slightly from each other. Producing lists of nearly identical sequences is not only computationally wasteful but also typically fails to capture the inherent ambiguity of complex AI tasks. To overcome this problem, we propose Diverse Beam Search (DBS), an alternative to BS that decodes a list of diverse outputs by optimizing a diversity-augmented objective. We observe that our method not only improved diversity but also finds better top 1 solutions by controlling for the exploration and exploitation of the search space. Moreover, these gains are achieved with minimal computational or memory overhead compared to beam search. To demonstrate the broad applicability of our method, we present results on image captioning, machine translation, conversation and visual question generation using both standard quantitative metrics and qualitative human studies. We find that our method consistently outperforms BS and previously proposed techniques for diverse decoding from neural sequence models.
15
+
16
+ # 1 INTRODUCTION
17
+
18
+ In the last few years, Recurrent Neural Networks (RNNs), Long Short-Term Memory networks (LSTMs) or more generally, neural sequence models have become the standard choice for modeling time-series data for a wide range of applications including speech recognition (Graves et al., 2013), machine translation (Bahdanau et al., 2014), conversation modeling (Vinyals & Le, 2015), image and video captioning (Vinyals et al., 2015; Venugopalan et al., 2015), and visual question answering (Antol et al., 2015). RNN based sequence generation architectures model the conditional probability, $\operatorname* { P r } ( \mathbf { y } | \mathbf { x } )$ of an output sequence $\mathbf { y } = ( y _ { 1 } , \dots , y _ { T } )$ given an input $\mathbf { x }$ (possibly also a sequence); where the output tokens $y _ { t }$ are from a finite vocabulary, $\nu$ .
19
+
20
+ Inference in RNNs. Maximum a Posteriori (MAP) inference for RNNs is the task of finding the most likely output sequence given the input. Since the number of possible sequences grows as $| \mathcal { V } | ^ { T }$ , exact inference is NP-hard – so, approximate inference algorithms like beam search (BS) are commonly employed. BS is a heuristic graph-search algorithm that maintains the $B$ top-scoring partial sequences expanded in a greedy left-to-right fashion. Fig. 1 shows a sample BS search tree.
21
+
22
+ Lack of Diversity in BS. Despite the widespread usage of BS, it has long been understood that solutions decoded by BS are generic and lacking in diversity (Finkel et al., 2006; Gimpel et al.,
23
+
24
+ ![](images/9d5741424271b2b680ca96a29deae3b58d1f3f59e3921635d32795b4ae741c13.jpg)
25
+ Single engine train rolling down the tracks. A locomotive drives along the tracks amongst trees and bushes. An engine is coming down the train track. A steam locomotive is blowing steam. An old fashion train with steam coming out of its pipe. A black and red train moving down a train track.
26
+ Figure 1: Comparing image captioning outputs decoded by BS (top) and our method, Diverse Beam Search (middle) – we notice that BS captions are near-duplicates with similar shared paths in the search tree and minor variations in the end. In contrast, DBS captions are significantly diverse and similar to the variability in human-generated ground truth captions (bottom).
27
+
28
+ 2013; Li et al., 2015; Li & Jurafsky, 2016). Comparing the human (bottom) and BS (top) generated captions shown in Fig. 1 demonstrates this deficiency. While this behavior of BS is disadvantageous for many reasons, we highlight the three most crucial ones here:
29
+
30
+ i) The production of near-identical beams make BS a computationally wasteful algorithm, with essentially the same computation being repeated for no significant gain in performance.
31
+ ii) Due to loss-evaluation mismatch (i.e. improvements in posterior-probabilities not necessarily corresponding to improvements in task-specific metrics), it is common practice to deliberately throttle BS to become a poorer optimization algorithm by using reduced beam widths (Vinyals et al., 2015; Karpathy & Fei-Fei, 2015; Ferraro et al., 2016). This treatment of an optimization algorithm as a hyperparameter is not only intellectually dissatisfying but also has a significant practical side-effect – it leads to the decoding of largely bland, generic, and “safe” outputs, e.g. always saying “I don’t know” in conversation models (Kannan et al., 2016).
32
+ iii) Most importantly, lack of diversity in the decoded solutions is fundamentally crippling in AI problems with significant ambiguity – e.g. there are multiple ways of describing an image or responding in a conversation that are “correct” and it is important to capture this ambiguity by finding several diverse plausible hypotheses.
33
+
34
+ Overview and Contributions. To address these shortcomings, we propose Diverse Beam Search $( D B S ) - \mathbf { a }$ general framework to decode a set of diverse sequences that can be used as an alternative to BS. At a high level, DBS decodes diverse lists by dividing the given beam budget into groups and enforcing diversity between groups of beams. Drawing from recent work in the probabilistic graphical models literature on Diverse M-Best (DivMBest) MAP inference (Batra et al., 2012; Prasad et al., 2014; Kirillov et al., 2015), we optimize an objective that consists of two terms – the sequence likelihood under the model and a dissimilarity term that encourages beams across groups to differ. This diversity-augmented model score is optimized in a doubly greedy manner – greedily optimizing along both time (like BS) and groups (like DivMBest).
35
+
36
+ Our primary technical contribution is Diverse Beam Search, a doubly greedy approximate inference algorithm to decode diverse sequences from neural sequence models. We report results on image captioning, machine translation, conversations and visual question generation to demonstrate the broad applicability of DBS. Results show that DBS produces consistent improvements on both task-specific oracle and other diversity-related metrics while maintaining run-time and memory requirements similar to BS. We also evaluate human preferences between image captions generated by BS or DBS. Further experiments show that DBS is robust over a wide range of its parameter values and is capable of encoding various notions of diversity through different forms of the diversty term.
37
+
38
+ Overall, our algorithm is simple to implement and consistently outperforms BS in a wide range of domains without sacrificing efficiency. Our implementation is publicly available at https: //github.com/ashwinkalyan/dbs. Additionally, we provide an interactive demonstration of DBS for image captioning at http://dbs.cloudcv.org.
39
+
40
+ # 2 PRELIMINARIES: DECODING RNNS WITH BEAM SEARCH
41
+
42
+ We begin with a refresher on BS, before describing our generalization, Diverse Beam Search. For notational convenience, let $[ n ]$ denote the set of natural numbers from 1 to $n$ and let $\mathbf { v } _ { [ n ] } =$ $[ v _ { 1 } , \ldots , v _ { n } ] ^ { \intercal }$ index the first $n$ elements of a vector $\mathbf { v } \in \mathbb { R } ^ { m }$ .
43
+
44
+ The Decoding Problem. RNNs are trained to estimate the likelihood of sequences of tokens from a finite dictionary $\nu$ given an input $\mathbf { x }$ . The RNN updates its internal state and estimates the conditional probability distribution over the next output given the input and all previous output tokens. We denote the logarithm of this conditional probability distribution over all tokens at time $t$ as $\theta ( y _ { t } ) =$ $\log \operatorname* { P r } ( y _ { t } | y _ { t - 1 } , \dots , y _ { 1 } , \mathbf { x } )$ . To avoid notational clutter, we index $\theta ( \cdot )$ with a single variable $y _ { t }$ , but it should be clear that it depends on all previous outputs, $\mathbf { y } _ { [ t - 1 ] }$ . We write the log probability of a partial solution (i.e. the sum of log probabilities of all tokens decoded so far) as $\Theta ( \mathbf { y } _ { [ t ] } ) =$ $\textstyle \sum _ { \tau \in [ t ] } \theta ( y _ { \tau } )$ . The decoding problem is then the task of finding a sequence y that maximizes $\Theta ( \mathbf { y } )$ .
45
+
46
+ As each output is conditioned on all the previous outputs, decoding the optimal length- $\mathcal { T }$ sequence in this setting can be viewed as MAP inference on a $T$ -order Markov chain with nodes corresponding to output tokens at each time step. Not only does the size of the largest factor in such a graph grow as $| \nu | ^ { \star }$ , but computing these factors also requires repetitively evaluating the sequence model. Thus, approximate algorithms are employed and the most prevalent method is beam search (BS).
47
+
48
+ Beam search is a heuristic search algorithm which stores the top $B$ highest scoring partial candidates at each time step; where $B$ is known as the beam width. Let us denote the set of $B$ solutions held by BS at the start of time $t$ as $Y _ { [ t - 1 ] } = \{ \mathbf { y } _ { 1 , [ t - 1 ] } , \dotsc , \mathbf { y } _ { B , [ t - 1 ] } \}$ . At each time step, BS considers all possible single token extensions of these beams given by the set $\mathscr { V } _ { t } = Y _ { [ t - 1 ] } \times \mathscr { V }$ and retains the $B$ highest scoring extensions. More formally, at each step the beams are updated as
49
+
50
+ $$
51
+ Y _ { [ t ] } = \operatorname * { a r g m a x } _ { \substack { \mathbf { y } _ { 1 , [ t ] } , \ldots , \mathbf { y } _ { B , [ t ] } \in \mathcal { V } _ { t } } } \sum _ { b \in [ B ] } \Theta ( \mathbf { y } _ { b , [ t ] } ) \ \ldots t . \ \mathbf { y } _ { i , [ t ] } \neq \mathbf { y } _ { j , [ t ] } \ \forall i \neq j .
52
+ $$
53
+
54
+ The above objective can be trivially maximized by sorting all $B \times | \mathcal { V } |$ members of $\mathcal { V } _ { t }$ by their log probabilities and selecting the top $B$ . This process is repeated until time $T$ and the most likely sequence is selected by ranking the $B$ complete beams according to their log probabilities.
55
+
56
+ While this method allows for multiple sequences to be explored in parallel, most completions tend to stem from a single highly valued beam – resulting in outputs that are often only minor perturbations of a single sequence (and typically only towards the end of the sequences).
57
+
58
+ # 3 DIVERSE BEAM SEARCH: FORMULATION AND ALGORITHM
59
+
60
+ To overcome this, we augment the objective in Eq. 1 with a dissimilarity term $\Delta ( Y _ { [ t ] } )$ that measures the diversity between candidate sequences, assigning a penalty $\Delta ( Y _ { [ t ] } ) [ c ]$ to each possible sequence completion $c \in \mathcal V$ . Jointly optimizing this augmented objective for all $B$ candidates at each time step is intractable as the number of possible solutions grows with $| \gamma | ^ { B }$ (easily $1 0 ^ { 6 0 }$ for typical language modeling settings). To avoid this, we opt for a greedy procedure that divides the beam budget $B$ into $G$ groups and promotes diversity between these groups. The approximation is doubly greedy – across both time and groups – so $\Delta ( Y _ { [ t ] } )$ is constant with respect to other groups and we can sequentially optimize each group using regular BS. We now explain the specifics of our approach.
61
+
62
+ Diverse Beam Search. As joint optimization is intractable, we form $G$ smaller groups of beams and optimize them sequentially. Consider a partition of the set of beams $Y _ { [ t ] }$ into $G$ smaller sets $Y _ { [ t ] } ^ { g } , g { \in } [ G ]$ of $B ^ { \prime } = B / G$ beams each (we pick $G$ to divide $B$ ). In the example shown in Fig. 2, $B = 6$ beams are divided into $G = 3$ differently colored groups containing $B ^ { \prime } = 2$ beams each.
63
+
64
+ Considering diversity only between groups, reduces the search space at each time step; however, inference remains intractable. To enforce diversity efficiently, we consider a greedy strategy that steps each group forward in time sequentially while considering the others fixed. Each group can then evaluate the diversity term with respect to the fixed extensions of previous groups, returning the search space to $B ^ { \prime } \times | \mathcal { V } |$ . In the snapshot shown in Fig. 2, the third group is being stepped forward at time step $t = 4$ and the previous groups have already been completed. With this staggered beamfront, the diversity term of the third group can be computed using these completions. Here we use hamming diversity, which adds diversity penalty -1 for each appearance of a possible extension word at the same time step in a previous group – ‘birds’, ‘the’, and ‘an’ in the example – and 0 to all other possible completions. We discuss other forms for the diversity function in Section 5.1.
65
+
66
+ ![](images/5956b1f134b4b09453be0d3d8e6cbba937e5b3fe2aba0ca90f414b51d98be929.jpg)
67
+ Figure 2: Diverse beam search operates left-to-right through time and top to bottom through groups. Diversity between groups is combined with joint log probabilities, allowing continuations to be found efficiently. The resulting outputs are more diverse than for standard approaches.
68
+
69
+ As we optimize each group with the previous groups fixed, extending group $g$ at time $t$ amounts to a standard BS using dissimilarity augmented log probabilities and can be written as:
70
+
71
+ $$
72
+ \begin{array} { r l } { Y _ { [ t ] } ^ { g } } & { = \underset { \mathbf { y } _ { 1 , [ t ] } ^ { g } \dots \mathbf { y } _ { B ^ { \prime } , [ t ] } ^ { g } \in \mathcal { Y } _ { t } ^ { g } } { \mathrm { a r g m a x } } \quad \quad \displaystyle \sum _ { b \in [ B ^ { \prime } ] } \Theta \left( \mathbf { y } _ { b , [ t ] } ^ { g } \right) + \lambda \Delta \left( \underset { h = 1 } { \bigcup ^ { g - 1 } } Y _ { [ t ] } ^ { h } \right) [ y _ { b , t } ^ { g } ] , } \\ & { \quad \quad s . t . \lambda \geq 0 , \mathbf { y } _ { i , [ t ] } ^ { g } \neq \mathbf { y } _ { j , [ t ] } ^ { g } \forall i \neq j } \end{array}
73
+ $$
74
+
75
+ where $\lambda$ is scalar controlling the strength of the diversity term. The full procedure to obtain diverse sequences using our method, Diverse Beam Search (DBS), is presented in Algorithm 1. It consists of two main steps for each group at each time step –
76
+
77
+ 1) augmenting the log probabilities of each possible extension with the diversity term computed from previously advanced groups (Algorithm 1, Line 5) and,
78
+ 2) running one step of a smaller BS with $B ^ { \prime }$ beams using the augmented log probabilities to extend the current group (Algorithm 1, Line 6).
79
+
80
+ Note that the first group $( g = 1 )$ ) is not ‘conditioned’ on other groups during optimization, so our method is guaranteed to perform at least as well as a beam search of size $B ^ { \prime }$ .
81
+
82
+ # Algorithm 1: Diverse Beam Search
83
+
84
+ 1 Perform a diverse beam search with $G$ groups using a beam width of $B$
85
+ 2 for $t = 1$ , . . . $T$ do
86
+ // perform one step of beam search for first group without diversity
87
+ 3 $\begin{array} { r } { Y _ { [ t ] } ^ { 1 } \operatorname { a r g m a x } _ { ( \mathbf { y } _ { 1 , [ t ] } ^ { 1 } , \dots , \mathbf { y } _ { B ^ { \prime } , [ t ] } ^ { 1 } ) } \sum _ { b \in [ B ^ { \prime } ] } \Theta ( \mathbf { y } _ { b , [ t ] } ^ { 1 } ) } \end{array}$
88
+ 4 for $g = 2$ , . . . $G$ do
89
+ 5 $\begin{array} { r } { \Theta ( \mathbf { y } _ { b , [ t ] } ^ { g } ) \Theta ( \mathbf { y } _ { b , [ t ] } ^ { g } ) + \lambda \Delta ( \bigcup _ { h = 1 } ^ { g - 1 } Y _ { [ t ] } ^ { h } ) [ y _ { b , t } ^ { g } ] \quad \ b \in [ B ^ { \prime } ] , \mathbf { y } _ { b , [ t ] } ^ { g } \in \mathcal { Y } _ { t } ^ { g } : } \end{array}$ and $\lambda > 0$
90
+ 6 $Y _ { [ t ] } ^ { g } \overset { \cdot } { } \operatorname { a r g m a x } _ { ( \mathbf { y } _ { 1 , [ t ] } ^ { g } , \ldots , \mathbf { y } _ { B ^ { \prime } , [ t ] } ^ { g } ) } \sum _ { b \in [ B ^ { \prime } ] } \Theta ( \mathbf { y } _ { b , [ t ] } ^ { g } )$ r thes.t. $\mathbf { y } _ { i , [ t ] } \neq \mathbf { y } _ { j , [ t ] } \forall i \neq j$
91
+
92
+ 7 Return set of B solutions, $\begin{array} { r } { Y _ { [ T ] } = \bigcup _ { g = 1 } ^ { G } Y _ { [ T ] } ^ { g } } \end{array}$
93
+
94
+ # 4 RELATED WORK
95
+
96
+ Diverse M-Best Lists. The task of generating diverse structured outputs from probabilistic models has been studied extensively (Park & Ramanan, 2011; Batra et al., 2012; Kirillov et al., 2015; Prasad et al., 2014). Batra et al. (2012) formalized this task for Markov Random Fields as the DivMBest problem and presented a greedy approach which solves for outputs iteratively, conditioning on previous solutions to induce diversity. Kirillov et al. (2015) show how these solutions can be found jointly (non-greedily) for certain kinds of energy functions. The techniques developed by Kirillov are not directly applicable to decoding from RNNs, which do not satisfy the assumptions made.
97
+
98
+ Most related to our proposed approach is the work of Gimpel et al. (2013), who applied DivMBest to machine translation using beam search as a black-box inference algorithm. Specifically, in this approach, DivMBest knows nothing about the inner-workings of BS and simply makes $B$ sequential calls to BS to generate $B$ diverse solutions. This approach is extremely wasteful because BS is called $B$ times, run from scratch every time, and even though each call to BS produces $B$ solutions, only one solution is kept by DivMBest. In contrast, DBS avoids these shortcomings by integrating diversity within BS such that no beams are discarded. By running multiple beam searches in parallel and at staggered time offsets, we obtain large time savings making our method comparable to $a$ single run of classical BS. One potential disadvantage of our method w.r.t. Gimpel et al. (2013) is that sentence-level diversity metrics cannot be incorporated in DBS since no group is complete when diversity is encouraged. However, as observed empirically by us and Li et al. (2015), initial words tend to disproportionally impact the diversity of the resultant sequences – suggesting that later words may not be important for diverse inference.
99
+
100
+ Diverse Decoding for RNNs. Efforts have been made by Li et al. (2015) and Li & Jurafsky (2016) to produce diverse decodings from recurrent models for conversation modeling and machine translation. Both of these works propose new heuristics for creating diverse M-Best lists and employ mutual information to re-rank lists of sequences. The latter achieves a goal separate from ours, which is simply to re-rank diverse lists.
101
+
102
+ Li & Jurafsky (2016) proposes a BS diversification heuristic that discourages beams from sharing common roots, implicitly resulting in diverse lists. Introducing diversity through a modified objective (as in DBS) rather than via a procedural heuristic provides easier generalization to incorporate different notions of diversity and control the exploration-exploitation trade-off as detailed in Section 5.1. Furthermore, we find that DBS outperforms the method of Li & Jurafsky (2016).
103
+
104
+ Li et al. (2015) introduced a novel decoding objective that maximizes mutual information between inputs and predicted outputs to penalize generic sequences. This operates on a principle orthogonal and complementary to DBS and Li & Jurafsky (2016). It works by penalizing utterances that are generally more frequent (diversity independent of input) rather than penalizing utterances that are similar to other utterances produced for the same input (diversity conditioned on input). Furthermore, the input-independent approach requires training a new language model for the target language while DBS just requires a diversity function $\Delta$ . Combination of these complementary techniques is left as interesting future work.
105
+
106
+ In other recent work, Wu et al. (2016) modify the beam search objective by introducing lengthnormalization to favor longer sequences and a coverage penalty that favors sequences that account for the complete input sequence. While the coverage term does not generalize to all neural sequence models, the length-normalization term can be implemented by modifying the joint-log-probability of each sequence. Although the goal of this method is not to produce diverse lists and hence not directly comparable, it is a complementary technique that can be used in conjunction with our diverse decoding method.
107
+
108
+ # 5 EXPERIMENTS
109
+
110
+ In this section, we evaluate our approach on image captioning, machine translation, conversation and visual question generation tasks to demonstrate both its effectiveness against baselines and its general applicability to any inference currently supported by beam search. We also analyze the effects of DBS parameters, explore human preferences for diversity, and discuss diversity’s importance in explaining complex images. We first explain the baselines and evaluations used in this paper.
111
+
112
+ Baselines & Metrics. Apart from classical beam search, we compare DBS with the diverse decoding method proposed in Li & Jurafsky (2016). We also compare against two other complementary decoding techniques proposed in Li et al. (2015) and Wu et al. (2016). Note that these two techniques are not directly comparable with DBS since the goal is not to produce diverse lists. We now provide a brief description of the comparisons mentioned:
113
+
114
+ - Li & Jurafsky (2016): modify BS by introducing an intra-sibling rank. For each partial solution, the set of $| \nu |$ beam extensions are sorted and assigned intra-sibling ranks $k \in \ [ | \nu | ]$ in order of decreasing log probabilities, $\theta _ { t } ( y _ { t } )$ . The log probability of an extension is then reduced in proportion to its rank, and continuations are re-sorted under these modified log probabilities to select the top $B$ ‘diverse’ beam extensions.
115
+
116
+ - Li et al. (2015): train an additional unconditioned target sequence model $U ( \mathbf { y } )$ and perform BS decoding on an augmented objective $P ( \mathbf { y } | x ) - \lambda U ( \mathbf { y } )$ , penalizing input-independent decodings.
117
+
118
+ - $\mathrm { { W u } }$ et al. (2016) modify the beam-search objective by introducing length-normalization that favors longer sequences. The joint log-probability of completed sequences is divided by a factor, $( 5 + | \mathbf { y } | ) ^ { \alpha } / ( 5 + 1 ) ^ { \alpha }$ , where $\alpha \in [ 0 , 1 ]$ .
119
+
120
+ We compare to our own implementations of these methods as none are publicly available. Both Li & Jurafsky (2016) and Li et al. (2015) develop and use re-rankers to pick a single solution from the generated lists. Since we are interested in evaluating the quality of the generated lists and in isolating the gains due to diverse decoding, we do not implement any re-rankers, simply sorting by log-probability.
121
+
122
+ We evaluate the performance of the generated lists using the following two metrics:
123
+
124
+ - Oracle Accuracy: Oracle or top $k$ accuracy w.r.t. some task-specific metric, such as BLEU (Papineni et al., 2002) or SPICE (Anderson et al., 2016), is the maximum value of the metric achieved over a list of $k$ potential solutions. Oracle accuracy is an upper bound on the performance of any re-ranking strategy and thus measures the maximum potential of a set of outputs. - Diversity Statistics: We count the number of distinct n-grams present in the list of generated outputs. Similar to Li et al. (2015), we divide these counts by the total number of words generated to bias against long sentences.
125
+
126
+ Simultaneous improvements in both metrics indicate that output sequences have increased diversity without sacrificing fluency and correctness with respect to target tasks.
127
+
128
+ 5.1 SENSITIVITY ANALYSIS AND EFFECT OF DIVERSITY FUNCTIONS
129
+
130
+ Here we discuss the impact of the number of groups, strength of diversity , and various forms of diversity for language models. Note that the parameters of DBS (and other baselines) were tuned on a held-out validation set for each experiment. The supplement provides further discussion and experimental details.
131
+
132
+ Number of Groups $\mathbf { \Pi } ( \mathbf { G } )$ . Setting $G { = } B$ allows for the maximum exploration of the search space, while setting $G { = } 1$ reduces DBS to BS, resulting in increased exploitation of the search-space around the 1-best decoding. Empirically, we find that maximum exploration correlates with improved oracle accuracy and hence use $G { = } B$ to report results unless mentioned otherwise. See the supplement for a comparison and more details.
133
+
134
+ Diversity Strength $( \lambda )$ . The diversity strength $\lambda$ specifies the trade-off between the model score and diversity terms. As expected, we find that a higher value of $\lambda$ produces a more diverse list; however, very large values of $\lambda$ can overpower model score and result in grammatically incorrect outputs. We set $\lambda$ via grid search over a range of values to maximize oracle accuracies achieved on the validation set. We find a wide range of $\lambda$ values (0.2 to 0.8) work well for most tasks and datasets.
135
+
136
+ Choice of Diversity Function $( \Delta )$ . In Section 3, we defined $\Delta ( \cdot )$ as a function over a set of partial solutions that outputs a vector of dissimilarity scores for all possible beam completions. Assuming that each of the previous groups influences the completion of the current group independently, we can simplify $\Delta ( \bar { \bigcup } _ { h = 1 } ^ { g - 1 } Y _ { [ t ] } ^ { h } )$ as the sum of each group’s contributions as $\bar { \sum _ { h = 1 } ^ { g - 1 } \Delta ( Y _ { [ t ] } ^ { h } ) }$ . In Section 3, we illustrated a simple hamming diversity of this form that penalizes selection of tokens proportionally to the number of time it was used in previous groups. However, this factorized diversity term can take various forms in our model – with hamming diversity being the simplest. For language models, we study the effect of using cumulative (i.e. considering all past time steps), n-gram and neural embedding based diversity functions. Each of these forms encode differing notions of diversity and result in DBS outperforming BS. We find simple hamming distance to be effective and report results based on this diversity measure unless otherwise specified. More details about these forms of the diversity term are provided in the supplementary.
137
+
138
+ # 5.2 IMAGE CAPTIONING
139
+
140
+ Dataset and Models. We evaluate on two datasets – COCO (Lin et al., 2014) and PASCAL-50S (Vedantam et al., 2015). We use the public splits as in Karpathy & Fei-Fei (2015) for COCO. PASCAL-50S is used only for testing (with 200 held out images used to tune hyperparameters). We train a captioning model (Vinyals et al., 2015) using the neuraltalk21 code repository.
141
+
142
+ Results. Table 1 shows Oracle (top $k$ ) SPICE for different values of $k$ . DBS consistently outperforms BS and Li & Jurafsky (2016) on both datasets. We observe that gains on PASCAL-50S are more pronounced $7 . 1 4 \%$ and $4 . 6 5 \%$ SPICE $\textcircled{ a} 2 0$ improvements over BS and Li & Jurafsky (2016)) than COCO. This suggests diverse predictions are especially advantageous when there is a mismatch between training and testing sets, implying DBS may be better suited for real-world applications.
143
+
144
+ Table 1 also shows the number of distinct n-grams produced by different techniques. Our method produces significantly more distinct n-grams (almost $300 \%$ increase in the number of 4-grams produced) as compared to BS. We also note that our method tends to produce slightly longer captions compared on average. Moreover, on the PASCAL-50S test split we observe that DBS finds more likely top-1 solutions on average – DBS obtains an average maximum log probability of -6.53 opposed to -6.91 found by BS of the same beam width. This empirical evidence suggests that using DBS as a replacement to BS may lead to lower inference approximation error.
145
+
146
+ Table 1: Oracle accuracy and distinct n-grams on COCO and PASCAL-50S datasets for image captioning at $B = 2 0$ . While we report SPICE, we observe similar trends in other metrics (reported in supplement).
147
+
148
+ <table><tr><td rowspan="2">Dataset</td><td rowspan="2">Method</td><td colspan="4">Oracle Accuracy (SPICE)</td><td colspan="4">Diversity Statistics</td></tr><tr><td>@1</td><td>@5</td><td>@10</td><td>@20</td><td>distinct-1</td><td>distinct-2</td><td>distinct-3</td><td>distinct-4</td></tr><tr><td rowspan="5">PASCAL-50S</td><td>Beam Search</td><td>4.933</td><td>7.046</td><td>7.949</td><td>8.747</td><td>0.12</td><td>0.57</td><td>1.35</td><td>2.50</td></tr><tr><td>Li &amp; Jurafsky (2016)</td><td>5.083</td><td>7.248</td><td>8.096</td><td>8.917</td><td>0.15</td><td>0.97</td><td>2.43</td><td>5.31</td></tr><tr><td>DBS</td><td>5.357</td><td>7.357</td><td>8.269</td><td>9.293</td><td>0.18</td><td>1.26</td><td>3.67</td><td>7.33</td></tr><tr><td>Wu et al. (2016)</td><td>5.301</td><td>7.322</td><td>8.236</td><td>8.832</td><td>0.16</td><td>1.10</td><td>3.16</td><td>6.45</td></tr><tr><td>Li et al. (2015)</td><td>5.129</td><td>7.175</td><td>8.168</td><td>8.560</td><td>0.13</td><td>1.15</td><td>3.58</td><td>8.42</td></tr><tr><td rowspan="5">COCO</td><td>Beam Search</td><td>16.278</td><td>22.962</td><td>25.145</td><td>27.343</td><td>0.40</td><td>1.51</td><td>3.25</td><td>5.67</td></tr><tr><td>Li &amp; Jurafsky (2016)</td><td>16.351</td><td>22.715</td><td>25.234</td><td>27.591</td><td>0.54</td><td>2.40</td><td>5.69</td><td>8.94</td></tr><tr><td>DBS</td><td>16.783</td><td>23.081</td><td>26.088</td><td>28.096</td><td>0.56</td><td>2.96</td><td>7.38</td><td>13.44</td></tr><tr><td>Wu et al. (2016)</td><td>16.642</td><td>22.643</td><td>25.437</td><td>27.783</td><td>0.54</td><td>2.42</td><td>6.01</td><td>7.08</td></tr><tr><td>Li et al. (2015)</td><td>16.749</td><td>23.271</td><td>26.104</td><td>27.946</td><td>0.42</td><td>1.37</td><td>3.46</td><td>6.10</td></tr></table>
149
+
150
+ Human Studies. To evaluate human preference between captions generated by DBS and BS, we perform a human study via Amazon Mechanical Turk using all 1000 images of PASCAL-50S. For each image, both DBS and standard BS captions are shown to 5 different users. They are then asked – “Which of the two robots understands the image better?” In this forced-choice test, DBS captions were preferred over BS $60 \%$ of the time by human annotators.
151
+
152
+ Is diversity always needed? While these results show that diverse outputs are important for systems that interact with users, is diversity always beneficial? While images with many objects (e.g., a park or a living room) can be described in multiple ways, the same is not true when there are few objects (e.g., a close up of a cat or a selfie). This notion is studied by Ionescu et al. (2016), which defines a “difficulty score”: the human response time for solving a visual search task. On the PASCAL50S dataset, we observe a positive correlation $\zeta \rho = 0 . 7 3 )$ between difficulty scores and humans preferring DBS to BS. Moreover, while DBS is generally preferred by humans for ‘difficult’ images, both are about equally preferred on ‘easier’ images. Details are provided in the supplement.
153
+
154
+ # 5.3 MACHINE TRANSLATION
155
+
156
+ We use the WMT’14 dataset containing $4 . 5 { \mathrm { M } }$ sentences to train our machine translation models. We train stacking LSTM models as detailed in Luong et al. (2015), consisting of 4 layers and 1024- dimensional hidden states. While decoding sentences, we employ the same strategy to replace UNK tokens. We train our models using the publicly available seq2seq-attn2 code repository. We report results on news-test-2013 and news-test-2014 and use the news-test-2012 to tune the parameters of DBS. We use sentence level BLEU scores to compute oracle metrics and report distinct $\mathbf { n }$ -grams similar to image captioning. Results are shown in Table 2 and we again find that DBS consistently outperforms all baselines.
157
+
158
+ Table 2: Quantitative results on English-German translation on the newstest-2013 and newstest-2014 datasets combined (at $B = 2 0$ ).
159
+
160
+ <table><tr><td rowspan="2">Method</td><td colspan="4">Oracle Accuracy (BLEU-4)</td><td colspan="4">Diversity Statistics</td></tr><tr><td>@1</td><td>@5</td><td>@10</td><td>@20</td><td>distinct-1</td><td>distinct-2</td><td>distinct-3</td><td>distinct-4</td></tr><tr><td>Beam Search</td><td>20.5</td><td>22.4</td><td>23.8</td><td>24.2</td><td>0.04</td><td>0.75</td><td>2.10</td><td>3.23</td></tr><tr><td>Li &amp; Jurafsky (2016)</td><td>20.7</td><td>22.6</td><td>24.0</td><td>24.3</td><td>0.04</td><td>0.81</td><td>2.92</td><td>4.61</td></tr><tr><td>DBS</td><td>20.8</td><td>22.9</td><td>24.4</td><td>24.8</td><td>0.06</td><td>0.95</td><td>3.67</td><td>5.54</td></tr><tr><td>Wu et al. (2016)</td><td>20.6</td><td>22.6</td><td>24.3</td><td>24.6</td><td>0.05</td><td>0.88</td><td>2.83</td><td>4.50</td></tr><tr><td>Li et al. (2015)</td><td>20.7</td><td>23.1</td><td>24.4</td><td>24.6</td><td>0.04</td><td>0.86</td><td>2.76</td><td>4.31</td></tr></table>
161
+
162
+ # 5.4 DIALOG GENERATION
163
+
164
+ Dialog generation is a task that is inherently diverse as there are multiple valid ways to respond to a statement. We train a seq2seq model consisting of LSTMs as in Vinyals & Le (2015) on the Cornell Movie Dialogs Corpus (Danescu-Niculescu-Mizil & Lee, 2011) using the neuralconvo3 repository. The training dataset consists of 222,182 conversational exchanges between movie characters. Since automatic evaluation of dialog generation responses is an open research problem with existing metrics being poorly correlated with human judgement (Liu et al., 2016), we show qualitative results to demonstrate the effectiveness of DBS. Table 3 compares BS and DBS at $\scriptstyle \mathrm { B } = 3$ .
165
+
166
+ Table 3: Qualitative examples of dialog generation comparing best-first search, BS and DBS
167
+
168
+ <table><tr><td>Prompt</td><td>Beam Search</td><td>Diverse Beam Search</td></tr><tr><td rowspan="2">Why do you want to be the president?</td><td>I don&#x27;t know. I don&#x27;t know...</td><td>I don&#x27;t know.</td></tr><tr><td>I don&#x27;t know,but Iam the best</td><td>Because you know! Because,I have another life.</td></tr><tr><td rowspan="2">It&#x27;s such a beautiful day!</td><td>I know!</td><td>I know.</td></tr><tr><td>It&#x27;s true.</td><td>Well...</td></tr><tr><td rowspan="2">What&#x27;s your name?</td><td>Yeah. Jacob.</td><td>That&#x27;s not true,honey.</td></tr><tr><td>Berger, my man. Berger, Thomas.</td><td>Jacob. Berger,darling</td></tr></table>
169
+
170
+ # 5.5 VISUAL QUESTION GENERATION
171
+
172
+ We also report results on Visual Question Generation (VQG) (Mostafazadeh et al., 2016), where a model is trained to produce questions about an image. Generating visually focused questions is interesting because it requires reasoning about multiple problems that are central to vision – e.g., object attributes, relationships between objects, and natural language. Furthermore, many questions could make sense for one image, so it is important that lists of generated questions be diverse.
173
+
174
+ We use the VQA dataset (Antol et al., 2015) to train a model similar to image captioning architectures. Instead of captions, the training set now consists of 3 questions per image. Similar to previous results, using beam search to sample outputs results in similarly worded questions (see Fig. 3) and DBS brings out new details captured by the model. Counting the number of types of questions generated (as defined by Antol et al. (2015)) allows us to measure this diversity. We observe that the number of question types generated per image increases from 2.3 for BS to 3.7 for DBS (at $B = 6$ ).
175
+
176
+ # 6 CONCLUSION
177
+
178
+ Beam search is widely a used approximate inference algorithm for decoding sequences from neural sequence models; however, it suffers from a lack of diversity. Producing multiple highly similar and generic outputs is not only wasteful in terms of computation but also detrimental for tasks with
179
+
180
+ ![](images/a0a6e647a739605ab7556bbb6177817a288cd3a8aeb6a5f579e90b1d1debca11.jpg)
181
+
182
+ Figure 3: Qualitative results on Visual Question Generation. DBS generates questions that are non-generic and belong to different question types.
183
+
184
+ inherent ambiguity like many involving language. In this work, we modify Beam Search with a diversity-augmented sequence decoding objective to produce Diverse Beam Search. We develop a ‘doubly greedy’ approximate algorithm to minimize this objective and produce diverse sequence decodings. Our method consistently outperforms beam search and other baselines across all our experiments without extra computation or task-specific overhead. DBS is task-agnostic and can be applied to any case where BS is used, which we demonstrate in multiple domains. Our implementation available at https://github.com/ashwinkalyan/dbs.
185
+
186
+ # REFERENCES
187
+
188
+ Peter Anderson, Basura Fernando, Mark Johnson, and Stephen Gould. Spice: Semantic propositional image caption evaluation. In Proceedings of European Conference on Computer Vision (ECCV), 2016. 6
189
+ Stanislaw Antol, Aishwarya Agrawal, Jiasen Lu, Margaret Mitchell, Dhruv Batra, C Lawrence Zitnick, and Devi Parikh. VQA: Visual question answering. In Proceedings of IEEE Conference on Computer Vision and Pattern Recognition (CVPR), pp. 2425–2433, 2015. 1, 8
190
+ Dzmitry Bahdanau, Kyunghyun Cho, and Yoshua Bengio. Neural machine translation by jointly learning to align and translate. Proceedings of the International Conference on Learning Representations (ICLR), 2014. 1
191
+ Dhruv Batra, Payman Yadollahpour, Abner Guzman-Rivera, and Gregory Shakhnarovich. Diverse M-Best Solutions in Markov Random Fields. In Proceedings of European Conference on Computer Vision (ECCV), 2012. 2, 4
192
+ Cristian Danescu-Niculescu-Mizil and Lillian Lee. Chameleons in imagined conversations: A new approach to understanding coordination of linguistic style in dialogs. In Proceedings of the Workshop on Cognitive Modeling and Computational Linguistics, ACL 2011, 2011. 8
193
+ Francis Ferraro, Ishan Mostafazadeh, Nasrinand Misra, Aishwarya Agrawal, Jacob Devlin, Ross Girshick, Xiadong He, Pushmeet Kohli, Dhruv Batra, and C Lawrence Zitnick. Visual storytelling. Proceedings of the Conference of the North American Chapter of the Association for Computational Linguistics – Human Language Technologies (NAACL HLT), 2016. 2
194
+ Jenny Rose Finkel, Christopher D Manning, and Andrew Y Ng. Solving the problem of cascading errors: Approximate bayesian inference for linguistic annotation pipelines. In Proceedings of the Conference on Empirical Methods in Natural Language Processing (EMNLP), pp. 618–626, 2006. 1
195
+ K. Gimpel, D. Batra, C. Dyer, and G. Shakhnarovich. A systematic exploration of diversity in machine translation. In Proceedings of the Conference on Empirical Methods in Natural Language Processing (EMNLP), 2013. 1, 5, 12
196
+ Alex Graves, Abdel-rahman Mohamed, and Geoffrey E. Hinton. Speech recognition with deep recurrent neural networks. abs/1303.5778, 2013. 1
197
+
198
+ Radu Tudor Ionescu, Bogdan Alexe, Marius Leordeanu, Marius Popescu, Dim Papadopoulos, and Vittorio Ferrari. How hard can it be? Estimating the difficulty of visual search in an image. In Proceedings of IEEE Conference on Computer Vision and Pattern Recognition (CVPR), 2016. 7
199
+
200
+ Anjuli Kannan, Karol Kurach, Sujith Ravi, Tobias Kaufmann, Andrew Tomkins, Balint Miklos, Greg Corrado, László Lukács, Marina Ganea, Peter Young, et al. Smart reply: Automated reeponse suggestion for email. In Proceedings of the ACM SIGKDD Conference on Knowledge Discovery and Data Mining (KDD), 2016. 2
201
+
202
+ Andrej Karpathy and Li Fei-Fei. Deep visual-semantic alignments for generating image descriptions. In Proceedings of IEEE Conference on Computer Vision and Pattern Recognition (CVPR), 2015. 2, 7
203
+
204
+ Alexander Kirillov, Bogdan Savchynskyy, Dmitrij Schlesinger, Dmitry Vetrov, and Carsten Rother. Inferring m-best diverse labelings in a single one. In Proceedings of IEEE Conference on Computer Vision and Pattern Recognition (CVPR), 2015. 2, 4
205
+
206
+ Jiwei Li and Dan Jurafsky. Mutual information and diverse decoding improve neural machine translation. arXiv preprint arXiv:1601.00372, 2016. 2, 5, 6, 7, 8, 13, 14
207
+
208
+ Jiwei Li, Michel Galley, Chris Brockett, Jianfeng Gao, and Bill Dolan. A diversity-promoting objective function for neural conversation models. Proceedings of the Conference of the North American Chapter of the Association for Computational Linguistics – Human Language Technologies (NAACL HLT), 2015. 2, 5, 6, 7, 8, 13, 14
209
+
210
+ 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, 2014. 7
211
+
212
+ Chia-Wei Liu, Ryan Lowe, Iulian Vlad Serban, Michael Noseworthy, Laurent Charlin, and Joelle Pineau. How NOT to evaluate your dialogue system: An empirical study of unsupervised evaluation metrics for dialogue response generation. 2016. URL http://arxiv.org/abs/1603. 08023. 8
213
+
214
+ Minh-Thang Luong, Hieu Pham, and Christopher D Manning. Effective approaches to attentionbased neural machine translation. arXiv preprint arXiv:1508.04025, 2015. 7
215
+
216
+ Tomas Mikolov, Ilya Sutskever, Kai Chen, Greg S. Corrado, and Jeff Dean. Distributed representations of words and phrases and their compositionality. In Advances in Neural Information Processing Systems (NIPS), 2013. 12
217
+
218
+ Nasrin Mostafazadeh, Ishan Misra, Jacob Devlin, Margaret Mitchell, Xiaodong He, and Lucy Vanderwende. Generating natural questions about an image. Proceedings of the Annual Meeting on Association for Computational Linguistics (ACL), 2016. 8
219
+
220
+ Kishore Papineni, Salim Roukos, Todd Ward, and Wei-Jing Zhu. Bleu: a method for automatic evaluation of machine translation. In Proceedings of the Annual Meeting on Association for Computational Linguistics (ACL), 2002. 6
221
+
222
+ Dennis Park and Deva Ramanan. N-best maximal decoders for part models. In Proceedings of IEEE International Conference on Computer Vision (ICCV), 2011. 4
223
+
224
+ Adarsh Prasad, Stefanie Jegelka, and Dhruv Batra. Submodular meets structured: Finding diverse subsets in exponentially-large structured item sets. In Advances in Neural Information Processing Systems (NIPS), 2014. 2, 4
225
+
226
+ Ramakrishna Vedantam, C Lawrence Zitnick, and Devi Parikh. Cider: Consensus-based image description evaluation. In Proceedings of IEEE Conference on Computer Vision and Pattern Recognition (CVPR), 2015. 7
227
+
228
+ Subhashini Venugopalan, Marcus Rohrbach, Jeffrey Donahue, Raymond Mooney, Trevor Darrell, and Kate Saenko. Sequence to sequence-video to text. In Proceedings of IEEE Conference on Computer Vision and Pattern Recognition (CVPR), pp. 4534–4542, 2015. 1
229
+
230
+ Oriol Vinyals and Quoc Le. A neural conversational model. arXiv preprint arXiv:1506.05869, 2015. 1, 8
231
+
232
+ Oriol Vinyals, Alexander Toshev, Samy Bengio, and Dumitru Erhan. Show and tell: A neural image caption generator. In Proceedings of IEEE Conference on Computer Vision and Pattern Recognition (CVPR), 2015. 1, 2, 7
233
+
234
+ Yonghui Wu, Mike Schuster, Zhifeng Chen, Quoc V Le, Mohammad Norouzi, Wolfgang Macherey, Maxim Krikun, Yuan Cao, Qin Gao, Klaus Macherey, et al. Google’s neural machine translation system: Bridging the gap between human and machine translation. arXiv preprint arXiv:1609.08144, 2016. 5, 6, 7, 8, 13, 14
235
+
236
+ # APPENDIX
237
+
238
+ SENSIVITY STUDIES
239
+
240
+ Number of Groups. Fig. 4 presents snapshots of the transition from BS to DBS at $B = 6$ and $G = \{ 1 , 3 , 6 \}$ . As beam width moves from 1 to $G$ , the exploration of the method increases resulting in more diverse lists.
241
+
242
+ ![](images/556736eb871c5bae6f8e4101360fb2a4fb9a43d36b74e6a03d44b1d63a05f8f0.jpg)
243
+
244
+ Figure 4: Effect of increasing the number of groups $G$ . The beams that belong to the same group are colored similarly. Recall that diversity is only enforced across groups such that $G = 1$ corresponds to classical BS.
245
+
246
+ Diversity Strength. As noted in Section 5.1, our method is robust to a wide range of values of the diversity strength $( \lambda )$ . Fig. 5a shows a grid search of $\lambda$ for image-captioning on the PASCAL-50S dataset.
247
+
248
+ Choice of Diversity Function. The diversity function can take various forms ranging from simple hamming diversity to neural embedding based diversity. We discuss some forms for language modelling below:
249
+
250
+ - Hamming Diversity. This form penalizes the selection of tokens used in previous groups proportional to the number of times it was selected before.
251
+ - Cumulative Diversity. Once two sequences have diverged sufficiently, it seems unnecessary and perhaps harmful to restrict that they cannot use the same words at the same time. To encode this ‘backing-off’ of the diversity penalty we introduce cumulative diversity which keeps a count of identical words used at every time step, indicative of overall dissimilarity. Specifically, $\begin{array} { r } { \Delta ( Y _ { [ t ] } ^ { h } ) [ y _ { [ t ] } ^ { g } ] = \exp \{ - \big ( \sum _ { \tau \in t } \sum _ { b \in B ^ { \prime } } I \big [ y _ { b , \tau } ^ { h } \neq y _ { b , \tau } ^ { g } ] \big ) / \Gamma \} } \end{array}$ where $\Gamma$ is a temperature parameter controlling the strength of the cumulative diversity term and $I [ \cdot ]$ is the indicator function.
252
+ - $n$ -gram Diversity. The current group is penalized for producing the same n-grams as previous groups, regardless of alignment in time – similar to Gimpel et al. (2013). This is proportional to the number of times each $\mathbf { n }$ -gram in a candidate occurred in previous groups. Unlike hamming diversity, n-grams capture higher order structures in the sequences.
253
+ - Neural-embedding Diversity. While all the previous diversity functions discussed above perform exact matches, neural embeddings such as word2vec (Mikolov et al., 2013) can penalize semantically similar words like synonyms. This is incorporated in each of the previous diversity functions by replacing the hamming similarity with a soft version obtained by computing the cosine similarity between word2vec representations. When using with n-gram diversity, the representation of the n-gram is obtained by summing the vectors of the constituent words.
254
+
255
+ Each of these various forms encode different notions of diversity. Hamming diversity ensures different words are used at different times, but can be circumvented by small changes in sequence alignment. While n-gram diversity captures higher order statistics, it ignores sentence alignment. Neural-embedding based encodings can be seen as a semantic blurring of either the hamming or n-gram metrics, with word2vec representation similarity propagating diversity penalties not only to exact matches but also to close synonyms. Fig. 5b shows the oracle performace of various forms of the diversity function described in Section 5.1. We find that using any of the above functions help outperform BS in the tasks we examine; hamming diversity achieves the best oracle performance despite its simplicity.
256
+
257
+ # IMAGE CAPTIONING EVALUATION
258
+
259
+ While we report oracle SPICE values in the paper, our method consistently outperforms baselines and classical BS on other standard metrics such as CIDEr (Table 4), METEOR (Table 5) and ROUGE (Table 6). We provide these additional results in this section.
260
+
261
+ ![](images/ea97b6acbd398b4c75fa8a982a70103fc8074070dad4bb764dd796b23c52143e.jpg)
262
+ Figure 5: Fig. 5a shows the results of a grid search of the diversity strength $( \lambda )$ parameter of DBS on the validation split of PASCAL 50S dataset. We observe that it is robust for a wide range of values. Fig. 5b compares the performance of multiple forms for the diversity function $( \Delta )$ . While naïve diversity performs the best, other forms are comparable while being better than BS.
263
+
264
+ Table 4: CIDEr Oracle accuracy on COCO and PASCAL-50S datasets for image captioning at $B = 2 0$ .
265
+
266
+ <table><tr><td>Dataset</td><td>Method</td><td colspan="4">Oracle Accuracy (CIDEr)</td></tr><tr><td></td><td></td><td>@1</td><td>@5</td><td>@10</td><td>@20</td></tr><tr><td rowspan="5">PASCAL-50S</td><td>Beam Search</td><td>53.79</td><td>83.94</td><td>96.70</td><td>107.63</td></tr><tr><td>Li &amp; Jurafsky (2016)</td><td>54.61</td><td>85.21</td><td>99.80</td><td>110.64</td></tr><tr><td>DBS</td><td>57.82</td><td>89.38</td><td>103.75</td><td>113.43</td></tr><tr><td>Wu et al. (2016)</td><td>47.77</td><td>72.12</td><td>84.64</td><td>105.66</td></tr><tr><td>Li et al. (2015)</td><td>49.80</td><td>81.35</td><td>96.87</td><td>107.37</td></tr><tr><td rowspan="5">COCO</td><td>Beam Search</td><td>87.27</td><td>121.74</td><td>133.46</td><td>140.98</td></tr><tr><td>Li &amp; Jurafsky (2016)</td><td>91.42</td><td>111.33</td><td>116.94</td><td>119.14</td></tr><tr><td>DBS</td><td>86.88</td><td>123.38</td><td>135.68</td><td>142.88</td></tr><tr><td>Wu et al. (2016)</td><td>87.54</td><td>122.06</td><td>133.21</td><td>139.43</td></tr><tr><td>Li et al. (2015)</td><td>88.18</td><td>124.20</td><td>138.65</td><td>150.06</td></tr></table>
267
+
268
+ Table 5: METEOR Oracle accuracy on COCO and PASCAL-50S datasets for image captioning at $B = 2 0$
269
+
270
+ <table><tr><td>Dataset</td><td>Method</td><td colspan="4">Oracle Accuracy (METEOR)</td></tr><tr><td></td><td></td><td>@1</td><td>@5</td><td>@10</td><td>@20</td></tr><tr><td rowspan="4">PASCAL-50S</td><td>Beam Search</td><td>12.24</td><td>16.74</td><td>19.14</td><td>21.22</td></tr><tr><td>Li &amp; Jurafsky (2016)</td><td>13.52</td><td>17.65</td><td>19.91</td><td>21.76</td></tr><tr><td>DBS</td><td>13.71</td><td>18.45</td><td>20.67</td><td>22.83</td></tr><tr><td>Wu et al. (2016)</td><td>13.34</td><td>17.20</td><td>18.98</td><td>21.13</td></tr><tr><td rowspan="5">COCO</td><td>Li et al. (2015)</td><td>13.04</td><td>17.92</td><td>19.73</td><td>22.32</td></tr><tr><td>Beam Search</td><td>24.81</td><td>28.56</td><td>30.59</td><td>31.87</td></tr><tr><td>Li &amp; Jurafsky (2016)</td><td>24.88</td><td>29.10</td><td>31.44</td><td>33.56</td></tr><tr><td>DBS</td><td>25.04</td><td>29.67</td><td>33.25</td><td>35.42</td></tr><tr><td>Wu et al. (2016)</td><td>24.82</td><td>28.92</td><td>31.53</td><td>34.14</td></tr><tr><td></td><td>Li et al. (2015)</td><td>24.93</td><td>30.11</td><td>32.34</td><td>34.88</td></tr></table>
271
+
272
+ Modified SPICE evaluation. To measure both the quality and the diversity of the generated captions, we compute SPICE-score by comparing the graph union of all the generated hypotheses with the ground truth scene graph. This measure rewards all the relevant relations decoded as against oracle accuracy that compares to relevant relations present only in the top-scoring caption. We observe that DBS outperforms both baselines under this measure with a score of 18.345 as against a score of 16.988 (beam search) and 17.452 (Li & Jurafsky, 2016).
273
+
274
+ Table 6: ROUGE Oracle accuracy on COCO and PASCAL-50S datasets for image captioning at $B = 2 0$
275
+
276
+ <table><tr><td>Dataset</td><td>Method</td><td colspan="4">Oracle Accuracy (ROUGE-L)</td></tr><tr><td></td><td></td><td>@1</td><td>@5</td><td>@10</td><td>@20</td></tr><tr><td rowspan="4">PASCAL-50S</td><td>Beam Search</td><td>45.23</td><td>56.12</td><td>59.61</td><td>62.04</td></tr><tr><td>Li &amp; Jurafsky (2016)</td><td>46.21</td><td>56.17</td><td>60.15</td><td>62.95</td></tr><tr><td>DBS</td><td>46.24</td><td>56.90</td><td>60.35</td><td>63.02</td></tr><tr><td>Wu et al. (2016)</td><td>43.73</td><td>52.29</td><td>56.49</td><td>61.65</td></tr><tr><td rowspan="5">COCO</td><td>Li et al. (2015)</td><td>44.12</td><td>54.67</td><td>57.34</td><td>60.11</td></tr><tr><td>Beam Search</td><td>52.46</td><td>58.43</td><td>62.56</td><td>65.14</td></tr><tr><td>Li &amp; Jurafsky (2016)</td><td>52.87</td><td>59.89 60.89</td><td>63.45</td><td>65.42</td></tr><tr><td>DBS</td><td>53.04</td><td></td><td>64.24</td><td>67.72</td></tr><tr><td>Wu et al. (2016) Li et al. (2015)</td><td>52.13 53.10</td><td>58.26 59.32</td><td>62.89 63.04</td><td>65.77 66.19</td></tr></table>
277
+
278
+ # HUMAN STUDIES
279
+
280
+ For image-captioning, we conduct a human preference study between BS and DBS captions as explained in Section 5. A screen shot of the interface used to collect human preferences for captions generated using DBS and BS is presented in Fig. 6. The lists were shuffled to guard the task from being gamed by a turker.
281
+
282
+ Table 7: Frequency table for image difficulty and human preference for DBS captions on PASCAL50S dataset
283
+
284
+ <table><tr><td>difficulty score bin range</td><td>#images</td><td>% images DBS was preffered</td></tr><tr><td>≤μ-σ</td><td>481</td><td>50.51%</td></tr><tr><td>[μ-σ,μ+σ]</td><td>409</td><td>69.92%</td></tr><tr><td>≥μ+σ</td><td>110</td><td>83.63%</td></tr></table>
285
+
286
+ As mentioned in Section 5, we observe that difficulty score of an image and human preference for DBS captions are positively correlated. The dataset contains more images that are less difficulty and so, we analyze the correlation by dividing the data into three bins. For each bin, we report the $\%$ of images for which DBS captions were preferred after a majority vote (i.e. at least 3/5 turkers voted in favor of DBS) in Table 7. At low difficulty scores consisting mostly of iconic images – one might expect that BS would be preferred more often than chance. However, mismatch between the statistics of the training and testing data results in a better performance of DBS. Some examples for this case are provided in Fig. 7. More general qualitative examples are provided in Fig. 8.
287
+
288
+ # DISCUSSION
289
+
290
+ Are longer sentences better? Many recent works propose a scoring or a ranking objective that depends on the sequence length. These favor longer sequences, reasoning that they tend to have more details and resulting in improved accuracies. We measure the correlation between length of a sequence and its accuracy (here, SPICE) and observe insignificant correlation between SPICE and sequence length. On the PASCAL-50S dataset, we find that BS and DBS have are negatively correlated ${ \mathrm { \Delta } } \rho = - 0 . 0 0 3$ and $\rho = - 0 . 0 1 5$ respectively), while (Li & Jurafsky, 2016) is correlated positively $\zeta = 0 . 0 0 2 )$ . Length is not correlated with performance in this case.
291
+
292
+ Efficient utilization of beam budget. In this experiment, we emperically show that DBS makes efficient use of the beam budget in exploring the search space for better solutions. Fig. 9 shows the variation of oracle SPICE $( \ @ \mathbf { B } )$ with the beam size. At really high beam widths, all decoding techniques achieve similar oracle accuracies. However, diverse decoding techniques like DBS achieve the same oracle at much lower beam widths. Hence, DBS not only produces sequence lists that are significantly different but also efficiently utilizes the beam budget to decode better solutions.
293
+
294
+ # Instructions
295
+
296
+ # Which of the two robots understands the image better?
297
+
298
+ Two robots are shown an image.They both make 5 guesses each for describing the image with a single sentence.
299
+
300
+ Which robot do you think is more intellgent or uman-like displaying a better understanding of the image?
301
+
302
+ ![](images/662dc603494fb0f0a451658ae4e0c273db83b292b1f52a884fc7756064dc03cb.jpg)
303
+ Note: Select the radio button above the set of captions that you pick.
304
+ Figure 6: Screen-shot of the interface used to perform human studies
305
+
306
+ ![](images/62aa5f9e25d94974a1969061c1a3754f7e38d4142f17f0d79c955450596c86d6.jpg)
307
+
308
+ # Beam Search
309
+
310
+ A man riding a motorcycle on a dirt road A man riding a motorcycle on a beach A man riding a motorcycle on the side of a road A man riding a bike on a dirt road A man riding a motorcycle on the side of the road A man riding a motorcycle on the side of a beach
311
+
312
+ # Diverse Beam Search
313
+
314
+ A man riding a motorcycle on a beach
315
+ A man riding abike on a dirt road
316
+ A man riding a bike on a dirt road
317
+ A man on a motorcycle is flying a kite
318
+ A person on a skateboard riding on the side of a road
319
+ A person on a bicycle with a helmet on on the ground
320
+
321
+ Difficulty Score : 2.8308
322
+
323
+ ![](images/77403f71019e18c04f4f1a6720d4a5cc1c89577890e2881d56f41bc788761f27.jpg)
324
+ Difficulty Score :2.9287
325
+
326
+ # Beam Search
327
+
328
+ A black bear standing in a grassy field A black bear standing in a field of grass A black bear is standing in the grass A black bear is standing in a field A black bear standing in the grass next to a tree A black bear standing in the grass near a fence
329
+
330
+ # Diverse Beam Search
331
+
332
+ # A black dog is standing in the grass A black dog is standing in the grass
333
+
334
+ A black bear walking through a grassy field A black bear walking ina field of grass A black and white dog is standing in the grass A black bear standing in the grass near a fence
335
+
336
+ Difficulty Score :2.8999
337
+
338
+ # Beam Search
339
+
340
+ A close up of a bowl of broccoli A close up of a plate of broccoli A close up of a broccoli plant on a table Aclose up of a bowl of broccoli on a table A close up of a broccoli plant in a garden A close up of a plate of broccoli and cauliflower
341
+
342
+ ![](images/b066fe5f4248b97c1b655d251233ccf7a81c79004631b695b39d783bfb1cbbe8.jpg)
343
+ Figure 7: For images with low difficulty score, BS captions are preferred to DBS – as show in the first figure. However, we observe that DBS captions perform better when there is a mismatch between the statistics of the testing and training sets. Interesting captions are colored in blue for readability.
344
+
345
+ # Diverse Beam Search
346
+
347
+ Aclose up of a bowl of broccoli Aclose up of a plate of broccoli and broccoli A green plant with a green plant in it A green plant with a bunch of green leaves A white plate topped with broccoli and a plant A small green plant with a green plant in it
348
+
349
+ ![](images/4b1f21718dfbe05f9421ad7e3a2d6c2c85f0d31c7f6d33e3643ef377219dcbb5.jpg)
350
+ Difficulty Score : 5.4382
351
+
352
+ # Beam Search
353
+
354
+ A group of people sitting at a table with laptops A group of people sitting at a table A couple of people that are sitting at a table A group of people sitting around a table with laptops A group of people sitting at a table in front of laptops A group of people sitting at a table with a laptop
355
+
356
+ # Diverse Beam Search
357
+
358
+ A group of people sitting at a table with laptops A group of people sitting at a table with laptops A group of people sitting around a table with laptops A group of people are sitting at a table Two people sitting at a table with laptops Three people are siting at a table with laptops
359
+
360
+ ![](images/30135864d55d2af3015cf71afa6f0c1390585b3ec4aae52f68046d295327111e.jpg)
361
+ Difficulty Score : 4.1815
362
+
363
+ # Beam Search
364
+
365
+ A woman sitting in front of a laptop computer A woman sitting at a table with a laptop A woman sitting at a table with a laptop computer A woman is working on a laptop computer A woman siting at a desk with a laptop computer A woman is sitting at a table with a laptop
366
+
367
+ # Diverse Beam Search
368
+
369
+ A woman sitting at a table with a laptop computer A woman is working on a laptop computer A woman is sitting at a table with a laptop A man sitting at a desk with a laptop computer A woman in a kitchen with a laptop computer A man is sitting at a table with a laptop and a computer
370
+
371
+ ![](images/2e49b474bdeec252ee0c8fd4ca955890a4b6e467353d29d34401fb1dd843d6f0.jpg)
372
+ Difficulty Score : 3.8146
373
+
374
+ # Beam Search
375
+
376
+ A wooden table topped with plates of food A table with plates of food on it A wooden table topped with plates and bowls of food A table that hasa bunch of plates on it A wooden table topped with plates of food and glasses A wooden table topped with plates of food and cups
377
+
378
+ # Diverse Beam Search
379
+
380
+ A table with a plate of food and a glass of wine A table with a plate of food and a glass A table with plates of food and a glass of wine A dining table with a plate of food and a glass of wine A table with a bowl of food and a bowl of soup on it A dining room table with a plate of food and a glass of wine on it
381
+
382
+ Figure 8: For images with a high difficulty score, captions produced by DBS are preferred to BS. Interesting captions are colored in blue for readability.
383
+
384
+ ![](images/65ed921c683ee3a93446aacd14516bad30606979e9db87e3bf875653961e6660.jpg)
385
+ Figure 9: As the number of beams increases, all decoding methods tend to achieve about the same oracle accuracy. However, diverse decoding techniques like DBS utilize the beam budget efficiently achieving higher oracle accuracies at much lower beam budgets.
parse/train/HJV1zP5xg/HJV1zP5xg_content_list.json ADDED
@@ -0,0 +1,1992 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [
2
+ {
3
+ "type": "text",
4
+ "text": "DIVERSE BEAM SEARCH: DECODING DIVERSE SOLUTIONS FROM NEURAL SEQUENCE MODELS ",
5
+ "text_level": 1,
6
+ "bbox": [
7
+ 174,
8
+ 98,
9
+ 647,
10
+ 171
11
+ ],
12
+ "page_idx": 0
13
+ },
14
+ {
15
+ "type": "text",
16
+ "text": "Ashwin K Vijayakumar1, Michael Cogswell1, Ramprasaath R. Selvaraju1, Qing Sun1 \nStefan Lee1, David Crandall2 & Dhruv Batra1 ",
17
+ "bbox": [
18
+ 184,
19
+ 196,
20
+ 777,
21
+ 227
22
+ ],
23
+ "page_idx": 0
24
+ },
25
+ {
26
+ "type": "text",
27
+ "text": "{ashwinkv,cogswell,ram21,sunqing,steflee}@vt.edu djcran@indiana.edu, dbatra@vt.edu ",
28
+ "bbox": [
29
+ 186,
30
+ 228,
31
+ 655,
32
+ 253
33
+ ],
34
+ "page_idx": 0
35
+ },
36
+ {
37
+ "type": "text",
38
+ "text": "1 Department of Electrical and Computer Engineering, Virginia Tech, Blacksburg, VA, USA ",
39
+ "bbox": [
40
+ 184,
41
+ 268,
42
+ 542,
43
+ 296
44
+ ],
45
+ "page_idx": 0
46
+ },
47
+ {
48
+ "type": "text",
49
+ "text": "2 School of Informatics and Computing Indiana University, Bloomington, IN, USA ",
50
+ "bbox": [
51
+ 184,
52
+ 310,
53
+ 465,
54
+ 338
55
+ ],
56
+ "page_idx": 0
57
+ },
58
+ {
59
+ "type": "text",
60
+ "text": "ABSTRACT ",
61
+ "text_level": 1,
62
+ "bbox": [
63
+ 454,
64
+ 376,
65
+ 544,
66
+ 390
67
+ ],
68
+ "page_idx": 0
69
+ },
70
+ {
71
+ "type": "text",
72
+ "text": "Neural sequence models are widely used to model time-series data. Equally ubiquitous is the usage of beam search (BS) as an approximate inference algorithm to decode output sequences from these models. BS explores the search space in a greedy left-right fashion retaining only the top $B$ candidates. This tends to result in sequences that differ only slightly from each other. Producing lists of nearly identical sequences is not only computationally wasteful but also typically fails to capture the inherent ambiguity of complex AI tasks. To overcome this problem, we propose Diverse Beam Search (DBS), an alternative to BS that decodes a list of diverse outputs by optimizing a diversity-augmented objective. We observe that our method not only improved diversity but also finds better top 1 solutions by controlling for the exploration and exploitation of the search space. Moreover, these gains are achieved with minimal computational or memory overhead compared to beam search. To demonstrate the broad applicability of our method, we present results on image captioning, machine translation, conversation and visual question generation using both standard quantitative metrics and qualitative human studies. We find that our method consistently outperforms BS and previously proposed techniques for diverse decoding from neural sequence models. ",
73
+ "bbox": [
74
+ 233,
75
+ 407,
76
+ 764,
77
+ 642
78
+ ],
79
+ "page_idx": 0
80
+ },
81
+ {
82
+ "type": "text",
83
+ "text": "1 INTRODUCTION ",
84
+ "text_level": 1,
85
+ "bbox": [
86
+ 176,
87
+ 669,
88
+ 336,
89
+ 684
90
+ ],
91
+ "page_idx": 0
92
+ },
93
+ {
94
+ "type": "text",
95
+ "text": "In the last few years, Recurrent Neural Networks (RNNs), Long Short-Term Memory networks (LSTMs) or more generally, neural sequence models have become the standard choice for modeling time-series data for a wide range of applications including speech recognition (Graves et al., 2013), machine translation (Bahdanau et al., 2014), conversation modeling (Vinyals & Le, 2015), image and video captioning (Vinyals et al., 2015; Venugopalan et al., 2015), and visual question answering (Antol et al., 2015). RNN based sequence generation architectures model the conditional probability, $\\operatorname* { P r } ( \\mathbf { y } | \\mathbf { x } )$ of an output sequence $\\mathbf { y } = ( y _ { 1 } , \\dots , y _ { T } )$ given an input $\\mathbf { x }$ (possibly also a sequence); where the output tokens $y _ { t }$ are from a finite vocabulary, $\\nu$ . ",
96
+ "bbox": [
97
+ 174,
98
+ 700,
99
+ 825,
100
+ 811
101
+ ],
102
+ "page_idx": 0
103
+ },
104
+ {
105
+ "type": "text",
106
+ "text": "Inference in RNNs. Maximum a Posteriori (MAP) inference for RNNs is the task of finding the most likely output sequence given the input. Since the number of possible sequences grows as $| \\mathcal { V } | ^ { T }$ , exact inference is NP-hard – so, approximate inference algorithms like beam search (BS) are commonly employed. BS is a heuristic graph-search algorithm that maintains the $B$ top-scoring partial sequences expanded in a greedy left-to-right fashion. Fig. 1 shows a sample BS search tree. ",
107
+ "bbox": [
108
+ 174,
109
+ 819,
110
+ 823,
111
+ 888
112
+ ],
113
+ "page_idx": 0
114
+ },
115
+ {
116
+ "type": "text",
117
+ "text": "Lack of Diversity in BS. Despite the widespread usage of BS, it has long been understood that solutions decoded by BS are generic and lacking in diversity (Finkel et al., 2006; Gimpel et al., ",
118
+ "bbox": [
119
+ 174,
120
+ 895,
121
+ 823,
122
+ 924
123
+ ],
124
+ "page_idx": 0
125
+ },
126
+ {
127
+ "type": "image",
128
+ "img_path": "images/9d5741424271b2b680ca96a29deae3b58d1f3f59e3921635d32795b4ae741c13.jpg",
129
+ "image_caption": [
130
+ "Single engine train rolling down the tracks. A locomotive drives along the tracks amongst trees and bushes. An engine is coming down the train track. A steam locomotive is blowing steam. An old fashion train with steam coming out of its pipe. A black and red train moving down a train track. ",
131
+ "Figure 1: Comparing image captioning outputs decoded by BS (top) and our method, Diverse Beam Search (middle) – we notice that BS captions are near-duplicates with similar shared paths in the search tree and minor variations in the end. In contrast, DBS captions are significantly diverse and similar to the variability in human-generated ground truth captions (bottom). "
132
+ ],
133
+ "image_footnote": [],
134
+ "bbox": [
135
+ 178,
136
+ 103,
137
+ 823,
138
+ 243
139
+ ],
140
+ "page_idx": 1
141
+ },
142
+ {
143
+ "type": "text",
144
+ "text": "2013; Li et al., 2015; Li & Jurafsky, 2016). Comparing the human (bottom) and BS (top) generated captions shown in Fig. 1 demonstrates this deficiency. While this behavior of BS is disadvantageous for many reasons, we highlight the three most crucial ones here: ",
145
+ "bbox": [
146
+ 174,
147
+ 371,
148
+ 825,
149
+ 412
150
+ ],
151
+ "page_idx": 1
152
+ },
153
+ {
154
+ "type": "text",
155
+ "text": "i) The production of near-identical beams make BS a computationally wasteful algorithm, with essentially the same computation being repeated for no significant gain in performance. \nii) Due to loss-evaluation mismatch (i.e. improvements in posterior-probabilities not necessarily corresponding to improvements in task-specific metrics), it is common practice to deliberately throttle BS to become a poorer optimization algorithm by using reduced beam widths (Vinyals et al., 2015; Karpathy & Fei-Fei, 2015; Ferraro et al., 2016). This treatment of an optimization algorithm as a hyperparameter is not only intellectually dissatisfying but also has a significant practical side-effect – it leads to the decoding of largely bland, generic, and “safe” outputs, e.g. always saying “I don’t know” in conversation models (Kannan et al., 2016). \niii) Most importantly, lack of diversity in the decoded solutions is fundamentally crippling in AI problems with significant ambiguity – e.g. there are multiple ways of describing an image or responding in a conversation that are “correct” and it is important to capture this ambiguity by finding several diverse plausible hypotheses. ",
156
+ "bbox": [
157
+ 178,
158
+ 419,
159
+ 826,
160
+ 611
161
+ ],
162
+ "page_idx": 1
163
+ },
164
+ {
165
+ "type": "text",
166
+ "text": "Overview and Contributions. To address these shortcomings, we propose Diverse Beam Search $( D B S ) - \\mathbf { a }$ general framework to decode a set of diverse sequences that can be used as an alternative to BS. At a high level, DBS decodes diverse lists by dividing the given beam budget into groups and enforcing diversity between groups of beams. Drawing from recent work in the probabilistic graphical models literature on Diverse M-Best (DivMBest) MAP inference (Batra et al., 2012; Prasad et al., 2014; Kirillov et al., 2015), we optimize an objective that consists of two terms – the sequence likelihood under the model and a dissimilarity term that encourages beams across groups to differ. This diversity-augmented model score is optimized in a doubly greedy manner – greedily optimizing along both time (like BS) and groups (like DivMBest). ",
167
+ "bbox": [
168
+ 173,
169
+ 617,
170
+ 825,
171
+ 742
172
+ ],
173
+ "page_idx": 1
174
+ },
175
+ {
176
+ "type": "text",
177
+ "text": "Our primary technical contribution is Diverse Beam Search, a doubly greedy approximate inference algorithm to decode diverse sequences from neural sequence models. We report results on image captioning, machine translation, conversations and visual question generation to demonstrate the broad applicability of DBS. Results show that DBS produces consistent improvements on both task-specific oracle and other diversity-related metrics while maintaining run-time and memory requirements similar to BS. We also evaluate human preferences between image captions generated by BS or DBS. Further experiments show that DBS is robust over a wide range of its parameter values and is capable of encoding various notions of diversity through different forms of the diversty term. ",
178
+ "bbox": [
179
+ 173,
180
+ 750,
181
+ 825,
182
+ 861
183
+ ],
184
+ "page_idx": 1
185
+ },
186
+ {
187
+ "type": "text",
188
+ "text": "Overall, our algorithm is simple to implement and consistently outperforms BS in a wide range of domains without sacrificing efficiency. Our implementation is publicly available at https: //github.com/ashwinkalyan/dbs. Additionally, we provide an interactive demonstration of DBS for image captioning at http://dbs.cloudcv.org. ",
189
+ "bbox": [
190
+ 174,
191
+ 867,
192
+ 823,
193
+ 924
194
+ ],
195
+ "page_idx": 1
196
+ },
197
+ {
198
+ "type": "text",
199
+ "text": "2 PRELIMINARIES: DECODING RNNS WITH BEAM SEARCH ",
200
+ "text_level": 1,
201
+ "bbox": [
202
+ 174,
203
+ 102,
204
+ 683,
205
+ 118
206
+ ],
207
+ "page_idx": 2
208
+ },
209
+ {
210
+ "type": "text",
211
+ "text": "We begin with a refresher on BS, before describing our generalization, Diverse Beam Search. For notational convenience, let $[ n ]$ denote the set of natural numbers from 1 to $n$ and let $\\mathbf { v } _ { [ n ] } =$ $[ v _ { 1 } , \\ldots , v _ { n } ] ^ { \\intercal }$ index the first $n$ elements of a vector $\\mathbf { v } \\in \\mathbb { R } ^ { m }$ . ",
212
+ "bbox": [
213
+ 174,
214
+ 132,
215
+ 823,
216
+ 176
217
+ ],
218
+ "page_idx": 2
219
+ },
220
+ {
221
+ "type": "text",
222
+ "text": "The Decoding Problem. RNNs are trained to estimate the likelihood of sequences of tokens from a finite dictionary $\\nu$ given an input $\\mathbf { x }$ . The RNN updates its internal state and estimates the conditional probability distribution over the next output given the input and all previous output tokens. We denote the logarithm of this conditional probability distribution over all tokens at time $t$ as $\\theta ( y _ { t } ) =$ $\\log \\operatorname* { P r } ( y _ { t } | y _ { t - 1 } , \\dots , y _ { 1 } , \\mathbf { x } )$ . To avoid notational clutter, we index $\\theta ( \\cdot )$ with a single variable $y _ { t }$ , but it should be clear that it depends on all previous outputs, $\\mathbf { y } _ { [ t - 1 ] }$ . We write the log probability of a partial solution (i.e. the sum of log probabilities of all tokens decoded so far) as $\\Theta ( \\mathbf { y } _ { [ t ] } ) =$ $\\textstyle \\sum _ { \\tau \\in [ t ] } \\theta ( y _ { \\tau } )$ . The decoding problem is then the task of finding a sequence y that maximizes $\\Theta ( \\mathbf { y } )$ . ",
223
+ "bbox": [
224
+ 174,
225
+ 183,
226
+ 825,
227
+ 299
228
+ ],
229
+ "page_idx": 2
230
+ },
231
+ {
232
+ "type": "text",
233
+ "text": "As each output is conditioned on all the previous outputs, decoding the optimal length- $\\mathcal { T }$ sequence in this setting can be viewed as MAP inference on a $T$ -order Markov chain with nodes corresponding to output tokens at each time step. Not only does the size of the largest factor in such a graph grow as $| \\nu | ^ { \\star }$ , but computing these factors also requires repetitively evaluating the sequence model. Thus, approximate algorithms are employed and the most prevalent method is beam search (BS). ",
234
+ "bbox": [
235
+ 174,
236
+ 306,
237
+ 825,
238
+ 376
239
+ ],
240
+ "page_idx": 2
241
+ },
242
+ {
243
+ "type": "text",
244
+ "text": "Beam search is a heuristic search algorithm which stores the top $B$ highest scoring partial candidates at each time step; where $B$ is known as the beam width. Let us denote the set of $B$ solutions held by BS at the start of time $t$ as $Y _ { [ t - 1 ] } = \\{ \\mathbf { y } _ { 1 , [ t - 1 ] } , \\dotsc , \\mathbf { y } _ { B , [ t - 1 ] } \\}$ . At each time step, BS considers all possible single token extensions of these beams given by the set $\\mathscr { V } _ { t } = Y _ { [ t - 1 ] } \\times \\mathscr { V }$ and retains the $B$ highest scoring extensions. More formally, at each step the beams are updated as ",
245
+ "bbox": [
246
+ 174,
247
+ 382,
248
+ 825,
249
+ 453
250
+ ],
251
+ "page_idx": 2
252
+ },
253
+ {
254
+ "type": "equation",
255
+ "img_path": "images/18ad878b46ff546a5379d34863f51b4cd7c081103b560336961163dca81325fe.jpg",
256
+ "text": "$$\nY _ { [ t ] } = \\operatorname * { a r g m a x } _ { \\substack { \\mathbf { y } _ { 1 , [ t ] } , \\ldots , \\mathbf { y } _ { B , [ t ] } \\in \\mathcal { V } _ { t } } } \\sum _ { b \\in [ B ] } \\Theta ( \\mathbf { y } _ { b , [ t ] } ) \\ \\ldots t . \\ \\mathbf { y } _ { i , [ t ] } \\neq \\mathbf { y } _ { j , [ t ] } \\ \\forall i \\neq j .\n$$",
257
+ "text_format": "latex",
258
+ "bbox": [
259
+ 272,
260
+ 455,
261
+ 725,
262
+ 492
263
+ ],
264
+ "page_idx": 2
265
+ },
266
+ {
267
+ "type": "text",
268
+ "text": "The above objective can be trivially maximized by sorting all $B \\times | \\mathcal { V } |$ members of $\\mathcal { V } _ { t }$ by their log probabilities and selecting the top $B$ . This process is repeated until time $T$ and the most likely sequence is selected by ranking the $B$ complete beams according to their log probabilities. ",
269
+ "bbox": [
270
+ 174,
271
+ 496,
272
+ 825,
273
+ 540
274
+ ],
275
+ "page_idx": 2
276
+ },
277
+ {
278
+ "type": "text",
279
+ "text": "While this method allows for multiple sequences to be explored in parallel, most completions tend to stem from a single highly valued beam – resulting in outputs that are often only minor perturbations of a single sequence (and typically only towards the end of the sequences). ",
280
+ "bbox": [
281
+ 174,
282
+ 545,
283
+ 825,
284
+ 588
285
+ ],
286
+ "page_idx": 2
287
+ },
288
+ {
289
+ "type": "text",
290
+ "text": "3 DIVERSE BEAM SEARCH: FORMULATION AND ALGORITHM ",
291
+ "text_level": 1,
292
+ "bbox": [
293
+ 174,
294
+ 608,
295
+ 702,
296
+ 625
297
+ ],
298
+ "page_idx": 2
299
+ },
300
+ {
301
+ "type": "text",
302
+ "text": "To overcome this, we augment the objective in Eq. 1 with a dissimilarity term $\\Delta ( Y _ { [ t ] } )$ that measures the diversity between candidate sequences, assigning a penalty $\\Delta ( Y _ { [ t ] } ) [ c ]$ to each possible sequence completion $c \\in \\mathcal V$ . Jointly optimizing this augmented objective for all $B$ candidates at each time step is intractable as the number of possible solutions grows with $| \\gamma | ^ { B }$ (easily $1 0 ^ { 6 0 }$ for typical language modeling settings). To avoid this, we opt for a greedy procedure that divides the beam budget $B$ into $G$ groups and promotes diversity between these groups. The approximation is doubly greedy – across both time and groups – so $\\Delta ( Y _ { [ t ] } )$ is constant with respect to other groups and we can sequentially optimize each group using regular BS. We now explain the specifics of our approach. ",
303
+ "bbox": [
304
+ 173,
305
+ 637,
306
+ 825,
307
+ 752
308
+ ],
309
+ "page_idx": 2
310
+ },
311
+ {
312
+ "type": "text",
313
+ "text": "Diverse Beam Search. As joint optimization is intractable, we form $G$ smaller groups of beams and optimize them sequentially. Consider a partition of the set of beams $Y _ { [ t ] }$ into $G$ smaller sets $Y _ { [ t ] } ^ { g } , g { \\in } [ G ]$ of $B ^ { \\prime } = B / G$ beams each (we pick $G$ to divide $B$ ). In the example shown in Fig. 2, $B = 6$ beams are divided into $G = 3$ differently colored groups containing $B ^ { \\prime } = 2$ beams each. ",
314
+ "bbox": [
315
+ 174,
316
+ 757,
317
+ 825,
318
+ 819
319
+ ],
320
+ "page_idx": 2
321
+ },
322
+ {
323
+ "type": "text",
324
+ "text": "Considering diversity only between groups, reduces the search space at each time step; however, inference remains intractable. To enforce diversity efficiently, we consider a greedy strategy that steps each group forward in time sequentially while considering the others fixed. Each group can then evaluate the diversity term with respect to the fixed extensions of previous groups, returning the search space to $B ^ { \\prime } \\times | \\mathcal { V } |$ . In the snapshot shown in Fig. 2, the third group is being stepped forward at time step $t = 4$ and the previous groups have already been completed. With this staggered beamfront, the diversity term of the third group can be computed using these completions. Here we use hamming diversity, which adds diversity penalty -1 for each appearance of a possible extension word at the same time step in a previous group – ‘birds’, ‘the’, and ‘an’ in the example – and 0 to all other possible completions. We discuss other forms for the diversity function in Section 5.1. ",
325
+ "bbox": [
326
+ 174,
327
+ 825,
328
+ 825,
329
+ 924
330
+ ],
331
+ "page_idx": 2
332
+ },
333
+ {
334
+ "type": "image",
335
+ "img_path": "images/5956b1f134b4b09453be0d3d8e6cbba937e5b3fe2aba0ca90f414b51d98be929.jpg",
336
+ "image_caption": [
337
+ "Figure 2: Diverse beam search operates left-to-right through time and top to bottom through groups. Diversity between groups is combined with joint log probabilities, allowing continuations to be found efficiently. The resulting outputs are more diverse than for standard approaches. "
338
+ ],
339
+ "image_footnote": [],
340
+ "bbox": [
341
+ 187,
342
+ 101,
343
+ 803,
344
+ 218
345
+ ],
346
+ "page_idx": 3
347
+ },
348
+ {
349
+ "type": "text",
350
+ "text": "",
351
+ "bbox": [
352
+ 173,
353
+ 276,
354
+ 825,
355
+ 319
356
+ ],
357
+ "page_idx": 3
358
+ },
359
+ {
360
+ "type": "text",
361
+ "text": "As we optimize each group with the previous groups fixed, extending group $g$ at time $t$ amounts to a standard BS using dissimilarity augmented log probabilities and can be written as: ",
362
+ "bbox": [
363
+ 173,
364
+ 325,
365
+ 826,
366
+ 354
367
+ ],
368
+ "page_idx": 3
369
+ },
370
+ {
371
+ "type": "equation",
372
+ "img_path": "images/082d5426338cc98f0eca7df9726929c08cd48d1e818d4c25caf8d265baf80ea5.jpg",
373
+ "text": "$$\n\\begin{array} { r l } { Y _ { [ t ] } ^ { g } } & { = \\underset { \\mathbf { y } _ { 1 , [ t ] } ^ { g } \\dots \\mathbf { y } _ { B ^ { \\prime } , [ t ] } ^ { g } \\in \\mathcal { Y } _ { t } ^ { g } } { \\mathrm { a r g m a x } } \\quad \\quad \\displaystyle \\sum _ { b \\in [ B ^ { \\prime } ] } \\Theta \\left( \\mathbf { y } _ { b , [ t ] } ^ { g } \\right) + \\lambda \\Delta \\left( \\underset { h = 1 } { \\bigcup ^ { g - 1 } } Y _ { [ t ] } ^ { h } \\right) [ y _ { b , t } ^ { g } ] , } \\\\ & { \\quad \\quad s . t . \\lambda \\geq 0 , \\mathbf { y } _ { i , [ t ] } ^ { g } \\neq \\mathbf { y } _ { j , [ t ] } ^ { g } \\forall i \\neq j } \\end{array}\n$$",
374
+ "text_format": "latex",
375
+ "bbox": [
376
+ 263,
377
+ 362,
378
+ 730,
379
+ 431
380
+ ],
381
+ "page_idx": 3
382
+ },
383
+ {
384
+ "type": "text",
385
+ "text": "where $\\lambda$ is scalar controlling the strength of the diversity term. The full procedure to obtain diverse sequences using our method, Diverse Beam Search (DBS), is presented in Algorithm 1. It consists of two main steps for each group at each time step – ",
386
+ "bbox": [
387
+ 176,
388
+ 438,
389
+ 821,
390
+ 479
391
+ ],
392
+ "page_idx": 3
393
+ },
394
+ {
395
+ "type": "text",
396
+ "text": "1) augmenting the log probabilities of each possible extension with the diversity term computed from previously advanced groups (Algorithm 1, Line 5) and, \n2) running one step of a smaller BS with $B ^ { \\prime }$ beams using the augmented log probabilities to extend the current group (Algorithm 1, Line 6). ",
397
+ "bbox": [
398
+ 174,
399
+ 486,
400
+ 825,
401
+ 549
402
+ ],
403
+ "page_idx": 3
404
+ },
405
+ {
406
+ "type": "text",
407
+ "text": "Note that the first group $( g = 1 )$ ) is not ‘conditioned’ on other groups during optimization, so our method is guaranteed to perform at least as well as a beam search of size $B ^ { \\prime }$ . ",
408
+ "bbox": [
409
+ 171,
410
+ 555,
411
+ 821,
412
+ 584
413
+ ],
414
+ "page_idx": 3
415
+ },
416
+ {
417
+ "type": "text",
418
+ "text": "Algorithm 1: Diverse Beam Search ",
419
+ "text_level": 1,
420
+ "bbox": [
421
+ 174,
422
+ 597,
423
+ 411,
424
+ 611
425
+ ],
426
+ "page_idx": 3
427
+ },
428
+ {
429
+ "type": "text",
430
+ "text": "1 Perform a diverse beam search with $G$ groups using a beam width of $B$ \n2 for $t = 1$ , . . . $T$ do \n// perform one step of beam search for first group without diversity \n3 $\\begin{array} { r } { Y _ { [ t ] } ^ { 1 } \\operatorname { a r g m a x } _ { ( \\mathbf { y } _ { 1 , [ t ] } ^ { 1 } , \\dots , \\mathbf { y } _ { B ^ { \\prime } , [ t ] } ^ { 1 } ) } \\sum _ { b \\in [ B ^ { \\prime } ] } \\Theta ( \\mathbf { y } _ { b , [ t ] } ^ { 1 } ) } \\end{array}$ \n4 for $g = 2$ , . . . $G$ do \n5 $\\begin{array} { r } { \\Theta ( \\mathbf { y } _ { b , [ t ] } ^ { g } ) \\Theta ( \\mathbf { y } _ { b , [ t ] } ^ { g } ) + \\lambda \\Delta ( \\bigcup _ { h = 1 } ^ { g - 1 } Y _ { [ t ] } ^ { h } ) [ y _ { b , t } ^ { g } ] \\quad \\ b \\in [ B ^ { \\prime } ] , \\mathbf { y } _ { b , [ t ] } ^ { g } \\in \\mathcal { Y } _ { t } ^ { g } : } \\end{array}$ and $\\lambda > 0$ \n6 $Y _ { [ t ] } ^ { g } \\overset { \\cdot } { } \\operatorname { a r g m a x } _ { ( \\mathbf { y } _ { 1 , [ t ] } ^ { g } , \\ldots , \\mathbf { y } _ { B ^ { \\prime } , [ t ] } ^ { g } ) } \\sum _ { b \\in [ B ^ { \\prime } ] } \\Theta ( \\mathbf { y } _ { b , [ t ] } ^ { g } )$ r thes.t. $\\mathbf { y } _ { i , [ t ] } \\neq \\mathbf { y } _ { j , [ t ] } \\forall i \\neq j$ ",
431
+ "bbox": [
432
+ 165,
433
+ 614,
434
+ 642,
435
+ 642
436
+ ],
437
+ "page_idx": 3
438
+ },
439
+ {
440
+ "type": "text",
441
+ "text": "",
442
+ "bbox": [
443
+ 160,
444
+ 642,
445
+ 803,
446
+ 763
447
+ ],
448
+ "page_idx": 3
449
+ },
450
+ {
451
+ "type": "text",
452
+ "text": "7 Return set of B solutions, $\\begin{array} { r } { Y _ { [ T ] } = \\bigcup _ { g = 1 } ^ { G } Y _ { [ T ] } ^ { g } } \\end{array}$ ",
453
+ "bbox": [
454
+ 160,
455
+ 768,
456
+ 462,
457
+ 790
458
+ ],
459
+ "page_idx": 3
460
+ },
461
+ {
462
+ "type": "text",
463
+ "text": "4 RELATED WORK ",
464
+ "text_level": 1,
465
+ "bbox": [
466
+ 176,
467
+ 818,
468
+ 346,
469
+ 835
470
+ ],
471
+ "page_idx": 3
472
+ },
473
+ {
474
+ "type": "text",
475
+ "text": "Diverse M-Best Lists. The task of generating diverse structured outputs from probabilistic models has been studied extensively (Park & Ramanan, 2011; Batra et al., 2012; Kirillov et al., 2015; Prasad et al., 2014). Batra et al. (2012) formalized this task for Markov Random Fields as the DivMBest problem and presented a greedy approach which solves for outputs iteratively, conditioning on previous solutions to induce diversity. Kirillov et al. (2015) show how these solutions can be found jointly (non-greedily) for certain kinds of energy functions. The techniques developed by Kirillov are not directly applicable to decoding from RNNs, which do not satisfy the assumptions made. ",
476
+ "bbox": [
477
+ 173,
478
+ 853,
479
+ 825,
480
+ 924
481
+ ],
482
+ "page_idx": 3
483
+ },
484
+ {
485
+ "type": "text",
486
+ "text": "",
487
+ "bbox": [
488
+ 171,
489
+ 103,
490
+ 821,
491
+ 132
492
+ ],
493
+ "page_idx": 4
494
+ },
495
+ {
496
+ "type": "text",
497
+ "text": "Most related to our proposed approach is the work of Gimpel et al. (2013), who applied DivMBest to machine translation using beam search as a black-box inference algorithm. Specifically, in this approach, DivMBest knows nothing about the inner-workings of BS and simply makes $B$ sequential calls to BS to generate $B$ diverse solutions. This approach is extremely wasteful because BS is called $B$ times, run from scratch every time, and even though each call to BS produces $B$ solutions, only one solution is kept by DivMBest. In contrast, DBS avoids these shortcomings by integrating diversity within BS such that no beams are discarded. By running multiple beam searches in parallel and at staggered time offsets, we obtain large time savings making our method comparable to $a$ single run of classical BS. One potential disadvantage of our method w.r.t. Gimpel et al. (2013) is that sentence-level diversity metrics cannot be incorporated in DBS since no group is complete when diversity is encouraged. However, as observed empirically by us and Li et al. (2015), initial words tend to disproportionally impact the diversity of the resultant sequences – suggesting that later words may not be important for diverse inference. ",
498
+ "bbox": [
499
+ 173,
500
+ 138,
501
+ 825,
502
+ 319
503
+ ],
504
+ "page_idx": 4
505
+ },
506
+ {
507
+ "type": "text",
508
+ "text": "Diverse Decoding for RNNs. Efforts have been made by Li et al. (2015) and Li & Jurafsky (2016) to produce diverse decodings from recurrent models for conversation modeling and machine translation. Both of these works propose new heuristics for creating diverse M-Best lists and employ mutual information to re-rank lists of sequences. The latter achieves a goal separate from ours, which is simply to re-rank diverse lists. ",
509
+ "bbox": [
510
+ 174,
511
+ 328,
512
+ 823,
513
+ 398
514
+ ],
515
+ "page_idx": 4
516
+ },
517
+ {
518
+ "type": "text",
519
+ "text": "Li & Jurafsky (2016) proposes a BS diversification heuristic that discourages beams from sharing common roots, implicitly resulting in diverse lists. Introducing diversity through a modified objective (as in DBS) rather than via a procedural heuristic provides easier generalization to incorporate different notions of diversity and control the exploration-exploitation trade-off as detailed in Section 5.1. Furthermore, we find that DBS outperforms the method of Li & Jurafsky (2016). ",
520
+ "bbox": [
521
+ 174,
522
+ 405,
523
+ 823,
524
+ 474
525
+ ],
526
+ "page_idx": 4
527
+ },
528
+ {
529
+ "type": "text",
530
+ "text": "Li et al. (2015) introduced a novel decoding objective that maximizes mutual information between inputs and predicted outputs to penalize generic sequences. This operates on a principle orthogonal and complementary to DBS and Li & Jurafsky (2016). It works by penalizing utterances that are generally more frequent (diversity independent of input) rather than penalizing utterances that are similar to other utterances produced for the same input (diversity conditioned on input). Furthermore, the input-independent approach requires training a new language model for the target language while DBS just requires a diversity function $\\Delta$ . Combination of these complementary techniques is left as interesting future work. ",
531
+ "bbox": [
532
+ 174,
533
+ 482,
534
+ 825,
535
+ 593
536
+ ],
537
+ "page_idx": 4
538
+ },
539
+ {
540
+ "type": "text",
541
+ "text": "In other recent work, Wu et al. (2016) modify the beam search objective by introducing lengthnormalization to favor longer sequences and a coverage penalty that favors sequences that account for the complete input sequence. While the coverage term does not generalize to all neural sequence models, the length-normalization term can be implemented by modifying the joint-log-probability of each sequence. Although the goal of this method is not to produce diverse lists and hence not directly comparable, it is a complementary technique that can be used in conjunction with our diverse decoding method. ",
542
+ "bbox": [
543
+ 174,
544
+ 599,
545
+ 825,
546
+ 698
547
+ ],
548
+ "page_idx": 4
549
+ },
550
+ {
551
+ "type": "text",
552
+ "text": "5 EXPERIMENTS ",
553
+ "text_level": 1,
554
+ "bbox": [
555
+ 176,
556
+ 710,
557
+ 326,
558
+ 727
559
+ ],
560
+ "page_idx": 4
561
+ },
562
+ {
563
+ "type": "text",
564
+ "text": "In this section, we evaluate our approach on image captioning, machine translation, conversation and visual question generation tasks to demonstrate both its effectiveness against baselines and its general applicability to any inference currently supported by beam search. We also analyze the effects of DBS parameters, explore human preferences for diversity, and discuss diversity’s importance in explaining complex images. We first explain the baselines and evaluations used in this paper. ",
565
+ "bbox": [
566
+ 174,
567
+ 739,
568
+ 823,
569
+ 809
570
+ ],
571
+ "page_idx": 4
572
+ },
573
+ {
574
+ "type": "text",
575
+ "text": "Baselines & Metrics. Apart from classical beam search, we compare DBS with the diverse decoding method proposed in Li & Jurafsky (2016). We also compare against two other complementary decoding techniques proposed in Li et al. (2015) and Wu et al. (2016). Note that these two techniques are not directly comparable with DBS since the goal is not to produce diverse lists. We now provide a brief description of the comparisons mentioned: ",
576
+ "bbox": [
577
+ 174,
578
+ 819,
579
+ 823,
580
+ 888
581
+ ],
582
+ "page_idx": 4
583
+ },
584
+ {
585
+ "type": "text",
586
+ "text": "- Li & Jurafsky (2016): modify BS by introducing an intra-sibling rank. For each partial solution, the set of $| \\nu |$ beam extensions are sorted and assigned intra-sibling ranks $k \\in \\ [ | \\nu | ]$ in order of decreasing log probabilities, $\\theta _ { t } ( y _ { t } )$ . The log probability of an extension is then reduced in proportion to its rank, and continuations are re-sorted under these modified log probabilities to select the top $B$ ‘diverse’ beam extensions. ",
587
+ "bbox": [
588
+ 179,
589
+ 895,
590
+ 823,
591
+ 924
592
+ ],
593
+ "page_idx": 4
594
+ },
595
+ {
596
+ "type": "text",
597
+ "text": "",
598
+ "bbox": [
599
+ 187,
600
+ 103,
601
+ 821,
602
+ 145
603
+ ],
604
+ "page_idx": 5
605
+ },
606
+ {
607
+ "type": "text",
608
+ "text": "- Li et al. (2015): train an additional unconditioned target sequence model $U ( \\mathbf { y } )$ and perform BS decoding on an augmented objective $P ( \\mathbf { y } | x ) - \\lambda U ( \\mathbf { y } )$ , penalizing input-independent decodings. ",
609
+ "bbox": [
610
+ 176,
611
+ 151,
612
+ 823,
613
+ 180
614
+ ],
615
+ "page_idx": 5
616
+ },
617
+ {
618
+ "type": "text",
619
+ "text": "- $\\mathrm { { W u } }$ et al. (2016) modify the beam-search objective by introducing length-normalization that favors longer sequences. The joint log-probability of completed sequences is divided by a factor, $( 5 + | \\mathbf { y } | ) ^ { \\alpha } / ( 5 + 1 ) ^ { \\alpha }$ , where $\\alpha \\in [ 0 , 1 ]$ . ",
620
+ "bbox": [
621
+ 181,
622
+ 184,
623
+ 821,
624
+ 227
625
+ ],
626
+ "page_idx": 5
627
+ },
628
+ {
629
+ "type": "text",
630
+ "text": "We compare to our own implementations of these methods as none are publicly available. Both Li & Jurafsky (2016) and Li et al. (2015) develop and use re-rankers to pick a single solution from the generated lists. Since we are interested in evaluating the quality of the generated lists and in isolating the gains due to diverse decoding, we do not implement any re-rankers, simply sorting by log-probability. ",
631
+ "bbox": [
632
+ 174,
633
+ 233,
634
+ 825,
635
+ 304
636
+ ],
637
+ "page_idx": 5
638
+ },
639
+ {
640
+ "type": "text",
641
+ "text": "We evaluate the performance of the generated lists using the following two metrics: ",
642
+ "bbox": [
643
+ 176,
644
+ 309,
645
+ 720,
646
+ 324
647
+ ],
648
+ "page_idx": 5
649
+ },
650
+ {
651
+ "type": "text",
652
+ "text": "- Oracle Accuracy: Oracle or top $k$ accuracy w.r.t. some task-specific metric, such as BLEU (Papineni et al., 2002) or SPICE (Anderson et al., 2016), is the maximum value of the metric achieved over a list of $k$ potential solutions. Oracle accuracy is an upper bound on the performance of any re-ranking strategy and thus measures the maximum potential of a set of outputs. - Diversity Statistics: We count the number of distinct n-grams present in the list of generated outputs. Similar to Li et al. (2015), we divide these counts by the total number of words generated to bias against long sentences. ",
653
+ "bbox": [
654
+ 176,
655
+ 332,
656
+ 825,
657
+ 434
658
+ ],
659
+ "page_idx": 5
660
+ },
661
+ {
662
+ "type": "text",
663
+ "text": "Simultaneous improvements in both metrics indicate that output sequences have increased diversity without sacrificing fluency and correctness with respect to target tasks. ",
664
+ "bbox": [
665
+ 169,
666
+ 441,
667
+ 823,
668
+ 469
669
+ ],
670
+ "page_idx": 5
671
+ },
672
+ {
673
+ "type": "text",
674
+ "text": "5.1 SENSITIVITY ANALYSIS AND EFFECT OF DIVERSITY FUNCTIONS ",
675
+ "bbox": [
676
+ 176,
677
+ 507,
678
+ 663,
679
+ 522
680
+ ],
681
+ "page_idx": 5
682
+ },
683
+ {
684
+ "type": "text",
685
+ "text": "Here we discuss the impact of the number of groups, strength of diversity , and various forms of diversity for language models. Note that the parameters of DBS (and other baselines) were tuned on a held-out validation set for each experiment. The supplement provides further discussion and experimental details. ",
686
+ "bbox": [
687
+ 174,
688
+ 536,
689
+ 825,
690
+ 592
691
+ ],
692
+ "page_idx": 5
693
+ },
694
+ {
695
+ "type": "text",
696
+ "text": "Number of Groups $\\mathbf { \\Pi } ( \\mathbf { G } )$ . Setting $G { = } B$ allows for the maximum exploration of the search space, while setting $G { = } 1$ reduces DBS to BS, resulting in increased exploitation of the search-space around the 1-best decoding. Empirically, we find that maximum exploration correlates with improved oracle accuracy and hence use $G { = } B$ to report results unless mentioned otherwise. See the supplement for a comparison and more details. ",
697
+ "bbox": [
698
+ 174,
699
+ 598,
700
+ 825,
701
+ 669
702
+ ],
703
+ "page_idx": 5
704
+ },
705
+ {
706
+ "type": "text",
707
+ "text": "Diversity Strength $( \\lambda )$ . The diversity strength $\\lambda$ specifies the trade-off between the model score and diversity terms. As expected, we find that a higher value of $\\lambda$ produces a more diverse list; however, very large values of $\\lambda$ can overpower model score and result in grammatically incorrect outputs. We set $\\lambda$ via grid search over a range of values to maximize oracle accuracies achieved on the validation set. We find a wide range of $\\lambda$ values (0.2 to 0.8) work well for most tasks and datasets. ",
708
+ "bbox": [
709
+ 173,
710
+ 675,
711
+ 825,
712
+ 746
713
+ ],
714
+ "page_idx": 5
715
+ },
716
+ {
717
+ "type": "text",
718
+ "text": "Choice of Diversity Function $( \\Delta )$ . In Section 3, we defined $\\Delta ( \\cdot )$ as a function over a set of partial solutions that outputs a vector of dissimilarity scores for all possible beam completions. Assuming that each of the previous groups influences the completion of the current group independently, we can simplify $\\Delta ( \\bar { \\bigcup } _ { h = 1 } ^ { g - 1 } Y _ { [ t ] } ^ { h } )$ as the sum of each group’s contributions as $\\bar { \\sum _ { h = 1 } ^ { g - 1 } \\Delta ( Y _ { [ t ] } ^ { h } ) }$ . In Section 3, we illustrated a simple hamming diversity of this form that penalizes selection of tokens proportionally to the number of time it was used in previous groups. However, this factorized diversity term can take various forms in our model – with hamming diversity being the simplest. For language models, we study the effect of using cumulative (i.e. considering all past time steps), n-gram and neural embedding based diversity functions. Each of these forms encode differing notions of diversity and result in DBS outperforming BS. We find simple hamming distance to be effective and report results based on this diversity measure unless otherwise specified. More details about these forms of the diversity term are provided in the supplementary. ",
719
+ "bbox": [
720
+ 173,
721
+ 752,
722
+ 825,
723
+ 924
724
+ ],
725
+ "page_idx": 5
726
+ },
727
+ {
728
+ "type": "text",
729
+ "text": "5.2 IMAGE CAPTIONING ",
730
+ "text_level": 1,
731
+ "bbox": [
732
+ 176,
733
+ 103,
734
+ 356,
735
+ 117
736
+ ],
737
+ "page_idx": 6
738
+ },
739
+ {
740
+ "type": "text",
741
+ "text": "Dataset and Models. We evaluate on two datasets – COCO (Lin et al., 2014) and PASCAL-50S (Vedantam et al., 2015). We use the public splits as in Karpathy & Fei-Fei (2015) for COCO. PASCAL-50S is used only for testing (with 200 held out images used to tune hyperparameters). We train a captioning model (Vinyals et al., 2015) using the neuraltalk21 code repository. ",
742
+ "bbox": [
743
+ 174,
744
+ 126,
745
+ 825,
746
+ 183
747
+ ],
748
+ "page_idx": 6
749
+ },
750
+ {
751
+ "type": "text",
752
+ "text": "Results. Table 1 shows Oracle (top $k$ ) SPICE for different values of $k$ . DBS consistently outperforms BS and Li & Jurafsky (2016) on both datasets. We observe that gains on PASCAL-50S are more pronounced $7 . 1 4 \\%$ and $4 . 6 5 \\%$ SPICE $\\textcircled{ a} 2 0$ improvements over BS and Li & Jurafsky (2016)) than COCO. This suggests diverse predictions are especially advantageous when there is a mismatch between training and testing sets, implying DBS may be better suited for real-world applications. ",
753
+ "bbox": [
754
+ 174,
755
+ 190,
756
+ 825,
757
+ 261
758
+ ],
759
+ "page_idx": 6
760
+ },
761
+ {
762
+ "type": "text",
763
+ "text": "Table 1 also shows the number of distinct n-grams produced by different techniques. Our method produces significantly more distinct n-grams (almost $300 \\%$ increase in the number of 4-grams produced) as compared to BS. We also note that our method tends to produce slightly longer captions compared on average. Moreover, on the PASCAL-50S test split we observe that DBS finds more likely top-1 solutions on average – DBS obtains an average maximum log probability of -6.53 opposed to -6.91 found by BS of the same beam width. This empirical evidence suggests that using DBS as a replacement to BS may lead to lower inference approximation error. ",
764
+ "bbox": [
765
+ 174,
766
+ 268,
767
+ 825,
768
+ 366
769
+ ],
770
+ "page_idx": 6
771
+ },
772
+ {
773
+ "type": "table",
774
+ "img_path": "images/21bf901592a31fb8f69ce03975ddc319d57f9d10d26040f7e9a067bd6606d482.jpg",
775
+ "table_caption": [
776
+ "Table 1: Oracle accuracy and distinct n-grams on COCO and PASCAL-50S datasets for image captioning at $B = 2 0$ . While we report SPICE, we observe similar trends in other metrics (reported in supplement). "
777
+ ],
778
+ "table_footnote": [],
779
+ "table_body": "<table><tr><td rowspan=\"2\">Dataset</td><td rowspan=\"2\">Method</td><td colspan=\"4\">Oracle Accuracy (SPICE)</td><td colspan=\"4\">Diversity Statistics</td></tr><tr><td>@1</td><td>@5</td><td>@10</td><td>@20</td><td>distinct-1</td><td>distinct-2</td><td>distinct-3</td><td>distinct-4</td></tr><tr><td rowspan=\"5\">PASCAL-50S</td><td>Beam Search</td><td>4.933</td><td>7.046</td><td>7.949</td><td>8.747</td><td>0.12</td><td>0.57</td><td>1.35</td><td>2.50</td></tr><tr><td>Li &amp; Jurafsky (2016)</td><td>5.083</td><td>7.248</td><td>8.096</td><td>8.917</td><td>0.15</td><td>0.97</td><td>2.43</td><td>5.31</td></tr><tr><td>DBS</td><td>5.357</td><td>7.357</td><td>8.269</td><td>9.293</td><td>0.18</td><td>1.26</td><td>3.67</td><td>7.33</td></tr><tr><td>Wu et al. (2016)</td><td>5.301</td><td>7.322</td><td>8.236</td><td>8.832</td><td>0.16</td><td>1.10</td><td>3.16</td><td>6.45</td></tr><tr><td>Li et al. (2015)</td><td>5.129</td><td>7.175</td><td>8.168</td><td>8.560</td><td>0.13</td><td>1.15</td><td>3.58</td><td>8.42</td></tr><tr><td rowspan=\"5\">COCO</td><td>Beam Search</td><td>16.278</td><td>22.962</td><td>25.145</td><td>27.343</td><td>0.40</td><td>1.51</td><td>3.25</td><td>5.67</td></tr><tr><td>Li &amp; Jurafsky (2016)</td><td>16.351</td><td>22.715</td><td>25.234</td><td>27.591</td><td>0.54</td><td>2.40</td><td>5.69</td><td>8.94</td></tr><tr><td>DBS</td><td>16.783</td><td>23.081</td><td>26.088</td><td>28.096</td><td>0.56</td><td>2.96</td><td>7.38</td><td>13.44</td></tr><tr><td>Wu et al. (2016)</td><td>16.642</td><td>22.643</td><td>25.437</td><td>27.783</td><td>0.54</td><td>2.42</td><td>6.01</td><td>7.08</td></tr><tr><td>Li et al. (2015)</td><td>16.749</td><td>23.271</td><td>26.104</td><td>27.946</td><td>0.42</td><td>1.37</td><td>3.46</td><td>6.10</td></tr></table>",
780
+ "bbox": [
781
+ 176,
782
+ 398,
783
+ 825,
784
+ 558
785
+ ],
786
+ "page_idx": 6
787
+ },
788
+ {
789
+ "type": "text",
790
+ "text": "Human Studies. To evaluate human preference between captions generated by DBS and BS, we perform a human study via Amazon Mechanical Turk using all 1000 images of PASCAL-50S. For each image, both DBS and standard BS captions are shown to 5 different users. They are then asked – “Which of the two robots understands the image better?” In this forced-choice test, DBS captions were preferred over BS $60 \\%$ of the time by human annotators. ",
791
+ "bbox": [
792
+ 174,
793
+ 569,
794
+ 825,
795
+ 640
796
+ ],
797
+ "page_idx": 6
798
+ },
799
+ {
800
+ "type": "text",
801
+ "text": "Is diversity always needed? While these results show that diverse outputs are important for systems that interact with users, is diversity always beneficial? While images with many objects (e.g., a park or a living room) can be described in multiple ways, the same is not true when there are few objects (e.g., a close up of a cat or a selfie). This notion is studied by Ionescu et al. (2016), which defines a “difficulty score”: the human response time for solving a visual search task. On the PASCAL50S dataset, we observe a positive correlation $\\zeta \\rho = 0 . 7 3 )$ between difficulty scores and humans preferring DBS to BS. Moreover, while DBS is generally preferred by humans for ‘difficult’ images, both are about equally preferred on ‘easier’ images. Details are provided in the supplement. ",
802
+ "bbox": [
803
+ 173,
804
+ 646,
805
+ 825,
806
+ 757
807
+ ],
808
+ "page_idx": 6
809
+ },
810
+ {
811
+ "type": "text",
812
+ "text": "5.3 MACHINE TRANSLATION ",
813
+ "text_level": 1,
814
+ "bbox": [
815
+ 176,
816
+ 775,
817
+ 388,
818
+ 790
819
+ ],
820
+ "page_idx": 6
821
+ },
822
+ {
823
+ "type": "text",
824
+ "text": "We use the WMT’14 dataset containing $4 . 5 { \\mathrm { M } }$ sentences to train our machine translation models. We train stacking LSTM models as detailed in Luong et al. (2015), consisting of 4 layers and 1024- dimensional hidden states. While decoding sentences, we employ the same strategy to replace UNK tokens. We train our models using the publicly available seq2seq-attn2 code repository. We report results on news-test-2013 and news-test-2014 and use the news-test-2012 to tune the parameters of DBS. We use sentence level BLEU scores to compute oracle metrics and report distinct $\\mathbf { n }$ -grams similar to image captioning. Results are shown in Table 2 and we again find that DBS consistently outperforms all baselines. ",
825
+ "bbox": [
826
+ 174,
827
+ 801,
828
+ 825,
829
+ 885
830
+ ],
831
+ "page_idx": 6
832
+ },
833
+ {
834
+ "type": "text",
835
+ "text": "",
836
+ "bbox": [
837
+ 176,
838
+ 103,
839
+ 823,
840
+ 132
841
+ ],
842
+ "page_idx": 7
843
+ },
844
+ {
845
+ "type": "table",
846
+ "img_path": "images/8e1c45e8834c3ec162d74ba97fbcff31dfbe2a3931565930a33231d154cae737.jpg",
847
+ "table_caption": [
848
+ "Table 2: Quantitative results on English-German translation on the newstest-2013 and newstest-2014 datasets combined (at $B = 2 0$ ). "
849
+ ],
850
+ "table_footnote": [],
851
+ "table_body": "<table><tr><td rowspan=\"2\">Method</td><td colspan=\"4\">Oracle Accuracy (BLEU-4)</td><td colspan=\"4\">Diversity Statistics</td></tr><tr><td>@1</td><td>@5</td><td>@10</td><td>@20</td><td>distinct-1</td><td>distinct-2</td><td>distinct-3</td><td>distinct-4</td></tr><tr><td>Beam Search</td><td>20.5</td><td>22.4</td><td>23.8</td><td>24.2</td><td>0.04</td><td>0.75</td><td>2.10</td><td>3.23</td></tr><tr><td>Li &amp; Jurafsky (2016)</td><td>20.7</td><td>22.6</td><td>24.0</td><td>24.3</td><td>0.04</td><td>0.81</td><td>2.92</td><td>4.61</td></tr><tr><td>DBS</td><td>20.8</td><td>22.9</td><td>24.4</td><td>24.8</td><td>0.06</td><td>0.95</td><td>3.67</td><td>5.54</td></tr><tr><td>Wu et al. (2016)</td><td>20.6</td><td>22.6</td><td>24.3</td><td>24.6</td><td>0.05</td><td>0.88</td><td>2.83</td><td>4.50</td></tr><tr><td>Li et al. (2015)</td><td>20.7</td><td>23.1</td><td>24.4</td><td>24.6</td><td>0.04</td><td>0.86</td><td>2.76</td><td>4.31</td></tr></table>",
852
+ "bbox": [
853
+ 176,
854
+ 164,
855
+ 825,
856
+ 284
857
+ ],
858
+ "page_idx": 7
859
+ },
860
+ {
861
+ "type": "text",
862
+ "text": "5.4 DIALOG GENERATION ",
863
+ "text_level": 1,
864
+ "bbox": [
865
+ 176,
866
+ 304,
867
+ 369,
868
+ 318
869
+ ],
870
+ "page_idx": 7
871
+ },
872
+ {
873
+ "type": "text",
874
+ "text": "Dialog generation is a task that is inherently diverse as there are multiple valid ways to respond to a statement. We train a seq2seq model consisting of LSTMs as in Vinyals & Le (2015) on the Cornell Movie Dialogs Corpus (Danescu-Niculescu-Mizil & Lee, 2011) using the neuralconvo3 repository. The training dataset consists of 222,182 conversational exchanges between movie characters. Since automatic evaluation of dialog generation responses is an open research problem with existing metrics being poorly correlated with human judgement (Liu et al., 2016), we show qualitative results to demonstrate the effectiveness of DBS. Table 3 compares BS and DBS at $\\scriptstyle \\mathrm { B } = 3$ . ",
875
+ "bbox": [
876
+ 173,
877
+ 329,
878
+ 825,
879
+ 428
880
+ ],
881
+ "page_idx": 7
882
+ },
883
+ {
884
+ "type": "table",
885
+ "img_path": "images/76089f7e972b3fa9750d3a3a3440d126cd10ac862253296fbe928fef8d35a5a3.jpg",
886
+ "table_caption": [
887
+ "Table 3: Qualitative examples of dialog generation comparing best-first search, BS and DBS "
888
+ ],
889
+ "table_footnote": [],
890
+ "table_body": "<table><tr><td>Prompt</td><td>Beam Search</td><td>Diverse Beam Search</td></tr><tr><td rowspan=\"2\">Why do you want to be the president?</td><td>I don&#x27;t know. I don&#x27;t know...</td><td>I don&#x27;t know.</td></tr><tr><td>I don&#x27;t know,but Iam the best</td><td>Because you know! Because,I have another life.</td></tr><tr><td rowspan=\"2\">It&#x27;s such a beautiful day!</td><td>I know!</td><td>I know.</td></tr><tr><td>It&#x27;s true.</td><td>Well...</td></tr><tr><td rowspan=\"2\">What&#x27;s your name?</td><td>Yeah. Jacob.</td><td>That&#x27;s not true,honey.</td></tr><tr><td>Berger, my man. Berger, Thomas.</td><td>Jacob. Berger,darling</td></tr></table>",
891
+ "bbox": [
892
+ 176,
893
+ 448,
894
+ 826,
895
+ 597
896
+ ],
897
+ "page_idx": 7
898
+ },
899
+ {
900
+ "type": "text",
901
+ "text": "5.5 VISUAL QUESTION GENERATION ",
902
+ "text_level": 1,
903
+ "bbox": [
904
+ 176,
905
+ 616,
906
+ 444,
907
+ 631
908
+ ],
909
+ "page_idx": 7
910
+ },
911
+ {
912
+ "type": "text",
913
+ "text": "We also report results on Visual Question Generation (VQG) (Mostafazadeh et al., 2016), where a model is trained to produce questions about an image. Generating visually focused questions is interesting because it requires reasoning about multiple problems that are central to vision – e.g., object attributes, relationships between objects, and natural language. Furthermore, many questions could make sense for one image, so it is important that lists of generated questions be diverse. ",
914
+ "bbox": [
915
+ 174,
916
+ 642,
917
+ 825,
918
+ 712
919
+ ],
920
+ "page_idx": 7
921
+ },
922
+ {
923
+ "type": "text",
924
+ "text": "We use the VQA dataset (Antol et al., 2015) to train a model similar to image captioning architectures. Instead of captions, the training set now consists of 3 questions per image. Similar to previous results, using beam search to sample outputs results in similarly worded questions (see Fig. 3) and DBS brings out new details captured by the model. Counting the number of types of questions generated (as defined by Antol et al. (2015)) allows us to measure this diversity. We observe that the number of question types generated per image increases from 2.3 for BS to 3.7 for DBS (at $B = 6$ ). ",
925
+ "bbox": [
926
+ 174,
927
+ 718,
928
+ 825,
929
+ 803
930
+ ],
931
+ "page_idx": 7
932
+ },
933
+ {
934
+ "type": "text",
935
+ "text": "6 CONCLUSION ",
936
+ "text_level": 1,
937
+ "bbox": [
938
+ 174,
939
+ 824,
940
+ 318,
941
+ 839
942
+ ],
943
+ "page_idx": 7
944
+ },
945
+ {
946
+ "type": "text",
947
+ "text": "Beam search is widely a used approximate inference algorithm for decoding sequences from neural sequence models; however, it suffers from a lack of diversity. Producing multiple highly similar and generic outputs is not only wasteful in terms of computation but also detrimental for tasks with ",
948
+ "bbox": [
949
+ 176,
950
+ 856,
951
+ 825,
952
+ 898
953
+ ],
954
+ "page_idx": 7
955
+ },
956
+ {
957
+ "type": "image",
958
+ "img_path": "images/a0a6e647a739605ab7556bbb6177817a288cd3a8aeb6a5f579e90b1d1debca11.jpg",
959
+ "image_caption": [],
960
+ "image_footnote": [],
961
+ "bbox": [
962
+ 186,
963
+ 98,
964
+ 818,
965
+ 275
966
+ ],
967
+ "page_idx": 8
968
+ },
969
+ {
970
+ "type": "text",
971
+ "text": "Figure 3: Qualitative results on Visual Question Generation. DBS generates questions that are non-generic and belong to different question types. ",
972
+ "bbox": [
973
+ 171,
974
+ 280,
975
+ 825,
976
+ 305
977
+ ],
978
+ "page_idx": 8
979
+ },
980
+ {
981
+ "type": "text",
982
+ "text": "inherent ambiguity like many involving language. In this work, we modify Beam Search with a diversity-augmented sequence decoding objective to produce Diverse Beam Search. We develop a ‘doubly greedy’ approximate algorithm to minimize this objective and produce diverse sequence decodings. Our method consistently outperforms beam search and other baselines across all our experiments without extra computation or task-specific overhead. DBS is task-agnostic and can be applied to any case where BS is used, which we demonstrate in multiple domains. Our implementation available at https://github.com/ashwinkalyan/dbs. ",
983
+ "bbox": [
984
+ 174,
985
+ 319,
986
+ 825,
987
+ 416
988
+ ],
989
+ "page_idx": 8
990
+ },
991
+ {
992
+ "type": "text",
993
+ "text": "REFERENCES ",
994
+ "text_level": 1,
995
+ "bbox": [
996
+ 174,
997
+ 438,
998
+ 285,
999
+ 452
1000
+ ],
1001
+ "page_idx": 8
1002
+ },
1003
+ {
1004
+ "type": "text",
1005
+ "text": "Peter Anderson, Basura Fernando, Mark Johnson, and Stephen Gould. Spice: Semantic propositional image caption evaluation. In Proceedings of European Conference on Computer Vision (ECCV), 2016. 6 \nStanislaw Antol, Aishwarya Agrawal, Jiasen Lu, Margaret Mitchell, Dhruv Batra, C Lawrence Zitnick, and Devi Parikh. VQA: Visual question answering. In Proceedings of IEEE Conference on Computer Vision and Pattern Recognition (CVPR), pp. 2425–2433, 2015. 1, 8 \nDzmitry Bahdanau, Kyunghyun Cho, and Yoshua Bengio. Neural machine translation by jointly learning to align and translate. Proceedings of the International Conference on Learning Representations (ICLR), 2014. 1 \nDhruv Batra, Payman Yadollahpour, Abner Guzman-Rivera, and Gregory Shakhnarovich. Diverse M-Best Solutions in Markov Random Fields. In Proceedings of European Conference on Computer Vision (ECCV), 2012. 2, 4 \nCristian Danescu-Niculescu-Mizil and Lillian Lee. Chameleons in imagined conversations: A new approach to understanding coordination of linguistic style in dialogs. In Proceedings of the Workshop on Cognitive Modeling and Computational Linguistics, ACL 2011, 2011. 8 \nFrancis Ferraro, Ishan Mostafazadeh, Nasrinand Misra, Aishwarya Agrawal, Jacob Devlin, Ross Girshick, Xiadong He, Pushmeet Kohli, Dhruv Batra, and C Lawrence Zitnick. Visual storytelling. Proceedings of the Conference of the North American Chapter of the Association for Computational Linguistics – Human Language Technologies (NAACL HLT), 2016. 2 \nJenny Rose Finkel, Christopher D Manning, and Andrew Y Ng. Solving the problem of cascading errors: Approximate bayesian inference for linguistic annotation pipelines. In Proceedings of the Conference on Empirical Methods in Natural Language Processing (EMNLP), pp. 618–626, 2006. 1 \nK. Gimpel, D. Batra, C. Dyer, and G. Shakhnarovich. A systematic exploration of diversity in machine translation. In Proceedings of the Conference on Empirical Methods in Natural Language Processing (EMNLP), 2013. 1, 5, 12 \nAlex Graves, Abdel-rahman Mohamed, and Geoffrey E. Hinton. Speech recognition with deep recurrent neural networks. abs/1303.5778, 2013. 1 ",
1006
+ "bbox": [
1007
+ 171,
1008
+ 458,
1009
+ 826,
1010
+ 926
1011
+ ],
1012
+ "page_idx": 8
1013
+ },
1014
+ {
1015
+ "type": "text",
1016
+ "text": "Radu Tudor Ionescu, Bogdan Alexe, Marius Leordeanu, Marius Popescu, Dim Papadopoulos, and Vittorio Ferrari. How hard can it be? Estimating the difficulty of visual search in an image. In Proceedings of IEEE Conference on Computer Vision and Pattern Recognition (CVPR), 2016. 7 ",
1017
+ "bbox": [
1018
+ 178,
1019
+ 103,
1020
+ 823,
1021
+ 146
1022
+ ],
1023
+ "page_idx": 9
1024
+ },
1025
+ {
1026
+ "type": "text",
1027
+ "text": "Anjuli Kannan, Karol Kurach, Sujith Ravi, Tobias Kaufmann, Andrew Tomkins, Balint Miklos, Greg Corrado, László Lukács, Marina Ganea, Peter Young, et al. Smart reply: Automated reeponse suggestion for email. In Proceedings of the ACM SIGKDD Conference on Knowledge Discovery and Data Mining (KDD), 2016. 2 ",
1028
+ "bbox": [
1029
+ 174,
1030
+ 155,
1031
+ 825,
1032
+ 213
1033
+ ],
1034
+ "page_idx": 9
1035
+ },
1036
+ {
1037
+ "type": "text",
1038
+ "text": "Andrej Karpathy and Li Fei-Fei. Deep visual-semantic alignments for generating image descriptions. In Proceedings of IEEE Conference on Computer Vision and Pattern Recognition (CVPR), 2015. 2, 7 ",
1039
+ "bbox": [
1040
+ 174,
1041
+ 222,
1042
+ 825,
1043
+ 265
1044
+ ],
1045
+ "page_idx": 9
1046
+ },
1047
+ {
1048
+ "type": "text",
1049
+ "text": "Alexander Kirillov, Bogdan Savchynskyy, Dmitrij Schlesinger, Dmitry Vetrov, and Carsten Rother. Inferring m-best diverse labelings in a single one. In Proceedings of IEEE Conference on Computer Vision and Pattern Recognition (CVPR), 2015. 2, 4 ",
1050
+ "bbox": [
1051
+ 174,
1052
+ 275,
1053
+ 823,
1054
+ 319
1055
+ ],
1056
+ "page_idx": 9
1057
+ },
1058
+ {
1059
+ "type": "text",
1060
+ "text": "Jiwei Li and Dan Jurafsky. Mutual information and diverse decoding improve neural machine translation. arXiv preprint arXiv:1601.00372, 2016. 2, 5, 6, 7, 8, 13, 14 ",
1061
+ "bbox": [
1062
+ 171,
1063
+ 328,
1064
+ 823,
1065
+ 358
1066
+ ],
1067
+ "page_idx": 9
1068
+ },
1069
+ {
1070
+ "type": "text",
1071
+ "text": "Jiwei Li, Michel Galley, Chris Brockett, Jianfeng Gao, and Bill Dolan. A diversity-promoting objective function for neural conversation models. Proceedings of the Conference of the North American Chapter of the Association for Computational Linguistics – Human Language Technologies (NAACL HLT), 2015. 2, 5, 6, 7, 8, 13, 14 ",
1072
+ "bbox": [
1073
+ 173,
1074
+ 367,
1075
+ 825,
1076
+ 424
1077
+ ],
1078
+ "page_idx": 9
1079
+ },
1080
+ {
1081
+ "type": "text",
1082
+ "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, 2014. 7 ",
1083
+ "bbox": [
1084
+ 174,
1085
+ 433,
1086
+ 823,
1087
+ 463
1088
+ ],
1089
+ "page_idx": 9
1090
+ },
1091
+ {
1092
+ "type": "text",
1093
+ "text": "Chia-Wei Liu, Ryan Lowe, Iulian Vlad Serban, Michael Noseworthy, Laurent Charlin, and Joelle Pineau. How NOT to evaluate your dialogue system: An empirical study of unsupervised evaluation metrics for dialogue response generation. 2016. URL http://arxiv.org/abs/1603. 08023. 8 ",
1094
+ "bbox": [
1095
+ 173,
1096
+ 472,
1097
+ 825,
1098
+ 529
1099
+ ],
1100
+ "page_idx": 9
1101
+ },
1102
+ {
1103
+ "type": "text",
1104
+ "text": "Minh-Thang Luong, Hieu Pham, and Christopher D Manning. Effective approaches to attentionbased neural machine translation. arXiv preprint arXiv:1508.04025, 2015. 7 ",
1105
+ "bbox": [
1106
+ 171,
1107
+ 540,
1108
+ 821,
1109
+ 569
1110
+ ],
1111
+ "page_idx": 9
1112
+ },
1113
+ {
1114
+ "type": "text",
1115
+ "text": "Tomas Mikolov, Ilya Sutskever, Kai Chen, Greg S. Corrado, and Jeff Dean. Distributed representations of words and phrases and their compositionality. In Advances in Neural Information Processing Systems (NIPS), 2013. 12 ",
1116
+ "bbox": [
1117
+ 176,
1118
+ 578,
1119
+ 821,
1120
+ 621
1121
+ ],
1122
+ "page_idx": 9
1123
+ },
1124
+ {
1125
+ "type": "text",
1126
+ "text": "Nasrin Mostafazadeh, Ishan Misra, Jacob Devlin, Margaret Mitchell, Xiaodong He, and Lucy Vanderwende. Generating natural questions about an image. Proceedings of the Annual Meeting on Association for Computational Linguistics (ACL), 2016. 8 ",
1127
+ "bbox": [
1128
+ 174,
1129
+ 631,
1130
+ 825,
1131
+ 674
1132
+ ],
1133
+ "page_idx": 9
1134
+ },
1135
+ {
1136
+ "type": "text",
1137
+ "text": "Kishore Papineni, Salim Roukos, Todd Ward, and Wei-Jing Zhu. Bleu: a method for automatic evaluation of machine translation. In Proceedings of the Annual Meeting on Association for Computational Linguistics (ACL), 2002. 6 ",
1138
+ "bbox": [
1139
+ 174,
1140
+ 683,
1141
+ 825,
1142
+ 727
1143
+ ],
1144
+ "page_idx": 9
1145
+ },
1146
+ {
1147
+ "type": "text",
1148
+ "text": "Dennis Park and Deva Ramanan. N-best maximal decoders for part models. In Proceedings of IEEE International Conference on Computer Vision (ICCV), 2011. 4 ",
1149
+ "bbox": [
1150
+ 173,
1151
+ 737,
1152
+ 823,
1153
+ 766
1154
+ ],
1155
+ "page_idx": 9
1156
+ },
1157
+ {
1158
+ "type": "text",
1159
+ "text": "Adarsh Prasad, Stefanie Jegelka, and Dhruv Batra. Submodular meets structured: Finding diverse subsets in exponentially-large structured item sets. In Advances in Neural Information Processing Systems (NIPS), 2014. 2, 4 ",
1160
+ "bbox": [
1161
+ 173,
1162
+ 775,
1163
+ 823,
1164
+ 818
1165
+ ],
1166
+ "page_idx": 9
1167
+ },
1168
+ {
1169
+ "type": "text",
1170
+ "text": "Ramakrishna Vedantam, C Lawrence Zitnick, and Devi Parikh. Cider: Consensus-based image description evaluation. In Proceedings of IEEE Conference on Computer Vision and Pattern Recognition (CVPR), 2015. 7 ",
1171
+ "bbox": [
1172
+ 174,
1173
+ 828,
1174
+ 825,
1175
+ 871
1176
+ ],
1177
+ "page_idx": 9
1178
+ },
1179
+ {
1180
+ "type": "text",
1181
+ "text": "Subhashini Venugopalan, Marcus Rohrbach, Jeffrey Donahue, Raymond Mooney, Trevor Darrell, and Kate Saenko. Sequence to sequence-video to text. In Proceedings of IEEE Conference on Computer Vision and Pattern Recognition (CVPR), pp. 4534–4542, 2015. 1 ",
1182
+ "bbox": [
1183
+ 174,
1184
+ 881,
1185
+ 825,
1186
+ 924
1187
+ ],
1188
+ "page_idx": 9
1189
+ },
1190
+ {
1191
+ "type": "text",
1192
+ "text": "Oriol Vinyals and Quoc Le. A neural conversational model. arXiv preprint arXiv:1506.05869, 2015. 1, 8 ",
1193
+ "bbox": [
1194
+ 174,
1195
+ 103,
1196
+ 821,
1197
+ 132
1198
+ ],
1199
+ "page_idx": 10
1200
+ },
1201
+ {
1202
+ "type": "text",
1203
+ "text": "Oriol Vinyals, Alexander Toshev, Samy Bengio, and Dumitru Erhan. Show and tell: A neural image caption generator. In Proceedings of IEEE Conference on Computer Vision and Pattern Recognition (CVPR), 2015. 1, 2, 7 ",
1204
+ "bbox": [
1205
+ 174,
1206
+ 140,
1207
+ 823,
1208
+ 184
1209
+ ],
1210
+ "page_idx": 10
1211
+ },
1212
+ {
1213
+ "type": "text",
1214
+ "text": "Yonghui Wu, Mike Schuster, Zhifeng Chen, Quoc V Le, Mohammad Norouzi, Wolfgang Macherey, Maxim Krikun, Yuan Cao, Qin Gao, Klaus Macherey, et al. Google’s neural machine translation system: Bridging the gap between human and machine translation. arXiv preprint arXiv:1609.08144, 2016. 5, 6, 7, 8, 13, 14 ",
1215
+ "bbox": [
1216
+ 174,
1217
+ 193,
1218
+ 825,
1219
+ 248
1220
+ ],
1221
+ "page_idx": 10
1222
+ },
1223
+ {
1224
+ "type": "text",
1225
+ "text": "APPENDIX ",
1226
+ "text_level": 1,
1227
+ "bbox": [
1228
+ 176,
1229
+ 103,
1230
+ 263,
1231
+ 117
1232
+ ],
1233
+ "page_idx": 11
1234
+ },
1235
+ {
1236
+ "type": "text",
1237
+ "text": "SENSIVITY STUDIES ",
1238
+ "bbox": [
1239
+ 176,
1240
+ 136,
1241
+ 316,
1242
+ 150
1243
+ ],
1244
+ "page_idx": 11
1245
+ },
1246
+ {
1247
+ "type": "text",
1248
+ "text": "Number of Groups. Fig. 4 presents snapshots of the transition from BS to DBS at $B = 6$ and $G = \\{ 1 , 3 , 6 \\}$ . As beam width moves from 1 to $G$ , the exploration of the method increases resulting in more diverse lists. ",
1249
+ "bbox": [
1250
+ 176,
1251
+ 164,
1252
+ 825,
1253
+ 205
1254
+ ],
1255
+ "page_idx": 11
1256
+ },
1257
+ {
1258
+ "type": "image",
1259
+ "img_path": "images/556736eb871c5bae6f8e4101360fb2a4fb9a43d36b74e6a03d44b1d63a05f8f0.jpg",
1260
+ "image_caption": [],
1261
+ "image_footnote": [],
1262
+ "bbox": [
1263
+ 186,
1264
+ 218,
1265
+ 818,
1266
+ 280
1267
+ ],
1268
+ "page_idx": 11
1269
+ },
1270
+ {
1271
+ "type": "text",
1272
+ "text": "Figure 4: Effect of increasing the number of groups $G$ . The beams that belong to the same group are colored similarly. Recall that diversity is only enforced across groups such that $G = 1$ corresponds to classical BS. ",
1273
+ "bbox": [
1274
+ 173,
1275
+ 295,
1276
+ 823,
1277
+ 321
1278
+ ],
1279
+ "page_idx": 11
1280
+ },
1281
+ {
1282
+ "type": "text",
1283
+ "text": "Diversity Strength. As noted in Section 5.1, our method is robust to a wide range of values of the diversity strength $( \\lambda )$ . Fig. 5a shows a grid search of $\\lambda$ for image-captioning on the PASCAL-50S dataset. ",
1284
+ "bbox": [
1285
+ 174,
1286
+ 333,
1287
+ 825,
1288
+ 375
1289
+ ],
1290
+ "page_idx": 11
1291
+ },
1292
+ {
1293
+ "type": "text",
1294
+ "text": "Choice of Diversity Function. The diversity function can take various forms ranging from simple hamming diversity to neural embedding based diversity. We discuss some forms for language modelling below: ",
1295
+ "bbox": [
1296
+ 173,
1297
+ 382,
1298
+ 825,
1299
+ 424
1300
+ ],
1301
+ "page_idx": 11
1302
+ },
1303
+ {
1304
+ "type": "text",
1305
+ "text": "- Hamming Diversity. This form penalizes the selection of tokens used in previous groups proportional to the number of times it was selected before. \n- Cumulative Diversity. Once two sequences have diverged sufficiently, it seems unnecessary and perhaps harmful to restrict that they cannot use the same words at the same time. To encode this ‘backing-off’ of the diversity penalty we introduce cumulative diversity which keeps a count of identical words used at every time step, indicative of overall dissimilarity. Specifically, $\\begin{array} { r } { \\Delta ( Y _ { [ t ] } ^ { h } ) [ y _ { [ t ] } ^ { g } ] = \\exp \\{ - \\big ( \\sum _ { \\tau \\in t } \\sum _ { b \\in B ^ { \\prime } } I \\big [ y _ { b , \\tau } ^ { h } \\neq y _ { b , \\tau } ^ { g } ] \\big ) / \\Gamma \\} } \\end{array}$ where $\\Gamma$ is a temperature parameter controlling the strength of the cumulative diversity term and $I [ \\cdot ]$ is the indicator function. \n- $n$ -gram Diversity. The current group is penalized for producing the same n-grams as previous groups, regardless of alignment in time – similar to Gimpel et al. (2013). This is proportional to the number of times each $\\mathbf { n }$ -gram in a candidate occurred in previous groups. Unlike hamming diversity, n-grams capture higher order structures in the sequences. \n- Neural-embedding Diversity. While all the previous diversity functions discussed above perform exact matches, neural embeddings such as word2vec (Mikolov et al., 2013) can penalize semantically similar words like synonyms. This is incorporated in each of the previous diversity functions by replacing the hamming similarity with a soft version obtained by computing the cosine similarity between word2vec representations. When using with n-gram diversity, the representation of the n-gram is obtained by summing the vectors of the constituent words. ",
1306
+ "bbox": [
1307
+ 173,
1308
+ 431,
1309
+ 826,
1310
+ 700
1311
+ ],
1312
+ "page_idx": 11
1313
+ },
1314
+ {
1315
+ "type": "text",
1316
+ "text": "Each of these various forms encode different notions of diversity. Hamming diversity ensures different words are used at different times, but can be circumvented by small changes in sequence alignment. While n-gram diversity captures higher order statistics, it ignores sentence alignment. Neural-embedding based encodings can be seen as a semantic blurring of either the hamming or n-gram metrics, with word2vec representation similarity propagating diversity penalties not only to exact matches but also to close synonyms. Fig. 5b shows the oracle performace of various forms of the diversity function described in Section 5.1. We find that using any of the above functions help outperform BS in the tasks we examine; hamming diversity achieves the best oracle performance despite its simplicity. ",
1317
+ "bbox": [
1318
+ 173,
1319
+ 707,
1320
+ 825,
1321
+ 833
1322
+ ],
1323
+ "page_idx": 11
1324
+ },
1325
+ {
1326
+ "type": "text",
1327
+ "text": "IMAGE CAPTIONING EVALUATION ",
1328
+ "text_level": 1,
1329
+ "bbox": [
1330
+ 176,
1331
+ 854,
1332
+ 411,
1333
+ 867
1334
+ ],
1335
+ "page_idx": 11
1336
+ },
1337
+ {
1338
+ "type": "text",
1339
+ "text": "While we report oracle SPICE values in the paper, our method consistently outperforms baselines and classical BS on other standard metrics such as CIDEr (Table 4), METEOR (Table 5) and ROUGE (Table 6). We provide these additional results in this section. ",
1340
+ "bbox": [
1341
+ 176,
1342
+ 882,
1343
+ 823,
1344
+ 922
1345
+ ],
1346
+ "page_idx": 11
1347
+ },
1348
+ {
1349
+ "type": "image",
1350
+ "img_path": "images/ea97b6acbd398b4c75fa8a982a70103fc8074070dad4bb764dd796b23c52143e.jpg",
1351
+ "image_caption": [
1352
+ "Figure 5: Fig. 5a shows the results of a grid search of the diversity strength $( \\lambda )$ parameter of DBS on the validation split of PASCAL 50S dataset. We observe that it is robust for a wide range of values. Fig. 5b compares the performance of multiple forms for the diversity function $( \\Delta )$ . While naïve diversity performs the best, other forms are comparable while being better than BS. "
1353
+ ],
1354
+ "image_footnote": [],
1355
+ "bbox": [
1356
+ 176,
1357
+ 103,
1358
+ 821,
1359
+ 296
1360
+ ],
1361
+ "page_idx": 12
1362
+ },
1363
+ {
1364
+ "type": "table",
1365
+ "img_path": "images/be7f67816d975e39f0dc364faffa01a756908d596adf4539a9599fc2774a34d9.jpg",
1366
+ "table_caption": [
1367
+ "Table 4: CIDEr Oracle accuracy on COCO and PASCAL-50S datasets for image captioning at $B = 2 0$ . "
1368
+ ],
1369
+ "table_footnote": [],
1370
+ "table_body": "<table><tr><td>Dataset</td><td>Method</td><td colspan=\"4\">Oracle Accuracy (CIDEr)</td></tr><tr><td></td><td></td><td>@1</td><td>@5</td><td>@10</td><td>@20</td></tr><tr><td rowspan=\"5\">PASCAL-50S</td><td>Beam Search</td><td>53.79</td><td>83.94</td><td>96.70</td><td>107.63</td></tr><tr><td>Li &amp; Jurafsky (2016)</td><td>54.61</td><td>85.21</td><td>99.80</td><td>110.64</td></tr><tr><td>DBS</td><td>57.82</td><td>89.38</td><td>103.75</td><td>113.43</td></tr><tr><td>Wu et al. (2016)</td><td>47.77</td><td>72.12</td><td>84.64</td><td>105.66</td></tr><tr><td>Li et al. (2015)</td><td>49.80</td><td>81.35</td><td>96.87</td><td>107.37</td></tr><tr><td rowspan=\"5\">COCO</td><td>Beam Search</td><td>87.27</td><td>121.74</td><td>133.46</td><td>140.98</td></tr><tr><td>Li &amp; Jurafsky (2016)</td><td>91.42</td><td>111.33</td><td>116.94</td><td>119.14</td></tr><tr><td>DBS</td><td>86.88</td><td>123.38</td><td>135.68</td><td>142.88</td></tr><tr><td>Wu et al. (2016)</td><td>87.54</td><td>122.06</td><td>133.21</td><td>139.43</td></tr><tr><td>Li et al. (2015)</td><td>88.18</td><td>124.20</td><td>138.65</td><td>150.06</td></tr></table>",
1371
+ "bbox": [
1372
+ 272,
1373
+ 397,
1374
+ 725,
1375
+ 580
1376
+ ],
1377
+ "page_idx": 12
1378
+ },
1379
+ {
1380
+ "type": "table",
1381
+ "img_path": "images/537ff905a96efe3eda5765277c2dc5a068f0a75f12d1c5d4fdc90117c65a1b20.jpg",
1382
+ "table_caption": [
1383
+ "Table 5: METEOR Oracle accuracy on COCO and PASCAL-50S datasets for image captioning at $B = 2 0$ "
1384
+ ],
1385
+ "table_footnote": [],
1386
+ "table_body": "<table><tr><td>Dataset</td><td>Method</td><td colspan=\"4\">Oracle Accuracy (METEOR)</td></tr><tr><td></td><td></td><td>@1</td><td>@5</td><td>@10</td><td>@20</td></tr><tr><td rowspan=\"4\">PASCAL-50S</td><td>Beam Search</td><td>12.24</td><td>16.74</td><td>19.14</td><td>21.22</td></tr><tr><td>Li &amp; Jurafsky (2016)</td><td>13.52</td><td>17.65</td><td>19.91</td><td>21.76</td></tr><tr><td>DBS</td><td>13.71</td><td>18.45</td><td>20.67</td><td>22.83</td></tr><tr><td>Wu et al. (2016)</td><td>13.34</td><td>17.20</td><td>18.98</td><td>21.13</td></tr><tr><td rowspan=\"5\">COCO</td><td>Li et al. (2015)</td><td>13.04</td><td>17.92</td><td>19.73</td><td>22.32</td></tr><tr><td>Beam Search</td><td>24.81</td><td>28.56</td><td>30.59</td><td>31.87</td></tr><tr><td>Li &amp; Jurafsky (2016)</td><td>24.88</td><td>29.10</td><td>31.44</td><td>33.56</td></tr><tr><td>DBS</td><td>25.04</td><td>29.67</td><td>33.25</td><td>35.42</td></tr><tr><td>Wu et al. (2016)</td><td>24.82</td><td>28.92</td><td>31.53</td><td>34.14</td></tr><tr><td></td><td>Li et al. (2015)</td><td>24.93</td><td>30.11</td><td>32.34</td><td>34.88</td></tr></table>",
1387
+ "bbox": [
1388
+ 272,
1389
+ 616,
1390
+ 725,
1391
+ 806
1392
+ ],
1393
+ "page_idx": 12
1394
+ },
1395
+ {
1396
+ "type": "text",
1397
+ "text": "Modified SPICE evaluation. To measure both the quality and the diversity of the generated captions, we compute SPICE-score by comparing the graph union of all the generated hypotheses with the ground truth scene graph. This measure rewards all the relevant relations decoded as against oracle accuracy that compares to relevant relations present only in the top-scoring caption. We observe that DBS outperforms both baselines under this measure with a score of 18.345 as against a score of 16.988 (beam search) and 17.452 (Li & Jurafsky, 2016). ",
1398
+ "bbox": [
1399
+ 173,
1400
+ 839,
1401
+ 825,
1402
+ 924
1403
+ ],
1404
+ "page_idx": 12
1405
+ },
1406
+ {
1407
+ "type": "table",
1408
+ "img_path": "images/8b266065959c87bb9a2ec469c6f2a0b859f027f277c9aded4ef9cee9a5a7ea7c.jpg",
1409
+ "table_caption": [
1410
+ "Table 6: ROUGE Oracle accuracy on COCO and PASCAL-50S datasets for image captioning at $B = 2 0$ "
1411
+ ],
1412
+ "table_footnote": [],
1413
+ "table_body": "<table><tr><td>Dataset</td><td>Method</td><td colspan=\"4\">Oracle Accuracy (ROUGE-L)</td></tr><tr><td></td><td></td><td>@1</td><td>@5</td><td>@10</td><td>@20</td></tr><tr><td rowspan=\"4\">PASCAL-50S</td><td>Beam Search</td><td>45.23</td><td>56.12</td><td>59.61</td><td>62.04</td></tr><tr><td>Li &amp; Jurafsky (2016)</td><td>46.21</td><td>56.17</td><td>60.15</td><td>62.95</td></tr><tr><td>DBS</td><td>46.24</td><td>56.90</td><td>60.35</td><td>63.02</td></tr><tr><td>Wu et al. (2016)</td><td>43.73</td><td>52.29</td><td>56.49</td><td>61.65</td></tr><tr><td rowspan=\"5\">COCO</td><td>Li et al. (2015)</td><td>44.12</td><td>54.67</td><td>57.34</td><td>60.11</td></tr><tr><td>Beam Search</td><td>52.46</td><td>58.43</td><td>62.56</td><td>65.14</td></tr><tr><td>Li &amp; Jurafsky (2016)</td><td>52.87</td><td>59.89 60.89</td><td>63.45</td><td>65.42</td></tr><tr><td>DBS</td><td>53.04</td><td></td><td>64.24</td><td>67.72</td></tr><tr><td>Wu et al. (2016) Li et al. (2015)</td><td>52.13 53.10</td><td>58.26 59.32</td><td>62.89 63.04</td><td>65.77 66.19</td></tr></table>",
1414
+ "bbox": [
1415
+ 272,
1416
+ 114,
1417
+ 725,
1418
+ 303
1419
+ ],
1420
+ "page_idx": 13
1421
+ },
1422
+ {
1423
+ "type": "text",
1424
+ "text": "HUMAN STUDIES ",
1425
+ "text_level": 1,
1426
+ "bbox": [
1427
+ 174,
1428
+ 329,
1429
+ 297,
1430
+ 343
1431
+ ],
1432
+ "page_idx": 13
1433
+ },
1434
+ {
1435
+ "type": "text",
1436
+ "text": "For image-captioning, we conduct a human preference study between BS and DBS captions as explained in Section 5. A screen shot of the interface used to collect human preferences for captions generated using DBS and BS is presented in Fig. 6. The lists were shuffled to guard the task from being gamed by a turker. ",
1437
+ "bbox": [
1438
+ 174,
1439
+ 354,
1440
+ 825,
1441
+ 410
1442
+ ],
1443
+ "page_idx": 13
1444
+ },
1445
+ {
1446
+ "type": "table",
1447
+ "img_path": "images/8c3887fc74e016d096e0e58f12bd9593b6a17416b34bbe80109df5814695d1e0.jpg",
1448
+ "table_caption": [
1449
+ "Table 7: Frequency table for image difficulty and human preference for DBS captions on PASCAL50S dataset "
1450
+ ],
1451
+ "table_footnote": [],
1452
+ "table_body": "<table><tr><td>difficulty score bin range</td><td>#images</td><td>% images DBS was preffered</td></tr><tr><td>≤μ-σ</td><td>481</td><td>50.51%</td></tr><tr><td>[μ-σ,μ+σ]</td><td>409</td><td>69.92%</td></tr><tr><td>≥μ+σ</td><td>110</td><td>83.63%</td></tr></table>",
1453
+ "bbox": [
1454
+ 338,
1455
+ 431,
1456
+ 655,
1457
+ 515
1458
+ ],
1459
+ "page_idx": 13
1460
+ },
1461
+ {
1462
+ "type": "text",
1463
+ "text": "As mentioned in Section 5, we observe that difficulty score of an image and human preference for DBS captions are positively correlated. The dataset contains more images that are less difficulty and so, we analyze the correlation by dividing the data into three bins. For each bin, we report the $\\%$ of images for which DBS captions were preferred after a majority vote (i.e. at least 3/5 turkers voted in favor of DBS) in Table 7. At low difficulty scores consisting mostly of iconic images – one might expect that BS would be preferred more often than chance. However, mismatch between the statistics of the training and testing data results in a better performance of DBS. Some examples for this case are provided in Fig. 7. More general qualitative examples are provided in Fig. 8. ",
1464
+ "bbox": [
1465
+ 174,
1466
+ 535,
1467
+ 825,
1468
+ 647
1469
+ ],
1470
+ "page_idx": 13
1471
+ },
1472
+ {
1473
+ "type": "text",
1474
+ "text": "DISCUSSION ",
1475
+ "text_level": 1,
1476
+ "bbox": [
1477
+ 174,
1478
+ 665,
1479
+ 263,
1480
+ 678
1481
+ ],
1482
+ "page_idx": 13
1483
+ },
1484
+ {
1485
+ "type": "text",
1486
+ "text": "Are longer sentences better? Many recent works propose a scoring or a ranking objective that depends on the sequence length. These favor longer sequences, reasoning that they tend to have more details and resulting in improved accuracies. We measure the correlation between length of a sequence and its accuracy (here, SPICE) and observe insignificant correlation between SPICE and sequence length. On the PASCAL-50S dataset, we find that BS and DBS have are negatively correlated ${ \\mathrm { \\Delta } } \\rho = - 0 . 0 0 3$ and $\\rho = - 0 . 0 1 5$ respectively), while (Li & Jurafsky, 2016) is correlated positively $\\zeta = 0 . 0 0 2 )$ . Length is not correlated with performance in this case. ",
1487
+ "bbox": [
1488
+ 174,
1489
+ 690,
1490
+ 825,
1491
+ 787
1492
+ ],
1493
+ "page_idx": 13
1494
+ },
1495
+ {
1496
+ "type": "text",
1497
+ "text": "Efficient utilization of beam budget. In this experiment, we emperically show that DBS makes efficient use of the beam budget in exploring the search space for better solutions. Fig. 9 shows the variation of oracle SPICE $( \\ @ \\mathbf { B } )$ with the beam size. At really high beam widths, all decoding techniques achieve similar oracle accuracies. However, diverse decoding techniques like DBS achieve the same oracle at much lower beam widths. Hence, DBS not only produces sequence lists that are significantly different but also efficiently utilizes the beam budget to decode better solutions. ",
1498
+ "bbox": [
1499
+ 174,
1500
+ 795,
1501
+ 825,
1502
+ 878
1503
+ ],
1504
+ "page_idx": 13
1505
+ },
1506
+ {
1507
+ "type": "text",
1508
+ "text": "Instructions ",
1509
+ "text_level": 1,
1510
+ "bbox": [
1511
+ 274,
1512
+ 378,
1513
+ 313,
1514
+ 386
1515
+ ],
1516
+ "page_idx": 14
1517
+ },
1518
+ {
1519
+ "type": "text",
1520
+ "text": "Which of the two robots understands the image better? ",
1521
+ "text_level": 1,
1522
+ "bbox": [
1523
+ 334,
1524
+ 398,
1525
+ 656,
1526
+ 411
1527
+ ],
1528
+ "page_idx": 14
1529
+ },
1530
+ {
1531
+ "type": "text",
1532
+ "text": "Two robots are shown an image.They both make 5 guesses each for describing the image with a single sentence. ",
1533
+ "bbox": [
1534
+ 274,
1535
+ 420,
1536
+ 696,
1537
+ 439
1538
+ ],
1539
+ "page_idx": 14
1540
+ },
1541
+ {
1542
+ "type": "text",
1543
+ "text": "Which robot do you think is more intellgent or uman-like displaying a better understanding of the image? ",
1544
+ "bbox": [
1545
+ 276,
1546
+ 448,
1547
+ 697,
1548
+ 467
1549
+ ],
1550
+ "page_idx": 14
1551
+ },
1552
+ {
1553
+ "type": "image",
1554
+ "img_path": "images/662dc603494fb0f0a451658ae4e0c273db83b292b1f52a884fc7756064dc03cb.jpg",
1555
+ "image_caption": [
1556
+ "Note: Select the radio button above the set of captions that you pick. ",
1557
+ "Figure 6: Screen-shot of the interface used to perform human studies "
1558
+ ],
1559
+ "image_footnote": [],
1560
+ "bbox": [
1561
+ 325,
1562
+ 503,
1563
+ 683,
1564
+ 619
1565
+ ],
1566
+ "page_idx": 14
1567
+ },
1568
+ {
1569
+ "type": "image",
1570
+ "img_path": "images/62aa5f9e25d94974a1969061c1a3754f7e38d4142f17f0d79c955450596c86d6.jpg",
1571
+ "image_caption": [],
1572
+ "image_footnote": [],
1573
+ "bbox": [
1574
+ 277,
1575
+ 227,
1576
+ 408,
1577
+ 377
1578
+ ],
1579
+ "page_idx": 15
1580
+ },
1581
+ {
1582
+ "type": "text",
1583
+ "text": "Beam Search ",
1584
+ "text_level": 1,
1585
+ "bbox": [
1586
+ 619,
1587
+ 219,
1588
+ 694,
1589
+ 229
1590
+ ],
1591
+ "page_idx": 15
1592
+ },
1593
+ {
1594
+ "type": "text",
1595
+ "text": "A man riding a motorcycle on a dirt road A man riding a motorcycle on a beach A man riding a motorcycle on the side of a road A man riding a bike on a dirt road A man riding a motorcycle on the side of the road A man riding a motorcycle on the side of a beach ",
1596
+ "bbox": [
1597
+ 501,
1598
+ 231,
1599
+ 759,
1600
+ 295
1601
+ ],
1602
+ "page_idx": 15
1603
+ },
1604
+ {
1605
+ "type": "text",
1606
+ "text": "Diverse Beam Search ",
1607
+ "text_level": 1,
1608
+ "bbox": [
1609
+ 596,
1610
+ 305,
1611
+ 717,
1612
+ 315
1613
+ ],
1614
+ "page_idx": 15
1615
+ },
1616
+ {
1617
+ "type": "text",
1618
+ "text": "A man riding a motorcycle on a beach \nA man riding abike on a dirt road \nA man riding a bike on a dirt road \nA man on a motorcycle is flying a kite \nA person on a skateboard riding on the side of a road \nA person on a bicycle with a helmet on on the ground ",
1619
+ "bbox": [
1620
+ 503,
1621
+ 316,
1622
+ 781,
1623
+ 380
1624
+ ],
1625
+ "page_idx": 15
1626
+ },
1627
+ {
1628
+ "type": "text",
1629
+ "text": "Difficulty Score : 2.8308 ",
1630
+ "bbox": [
1631
+ 279,
1632
+ 383,
1633
+ 406,
1634
+ 393
1635
+ ],
1636
+ "page_idx": 15
1637
+ },
1638
+ {
1639
+ "type": "image",
1640
+ "img_path": "images/77403f71019e18c04f4f1a6720d4a5cc1c89577890e2881d56f41bc788761f27.jpg",
1641
+ "image_caption": [
1642
+ "Difficulty Score :2.9287 "
1643
+ ],
1644
+ "image_footnote": [],
1645
+ "bbox": [
1646
+ 196,
1647
+ 411,
1648
+ 482,
1649
+ 558
1650
+ ],
1651
+ "page_idx": 15
1652
+ },
1653
+ {
1654
+ "type": "text",
1655
+ "text": "Beam Search ",
1656
+ "text_level": 1,
1657
+ "bbox": [
1658
+ 607,
1659
+ 410,
1660
+ 683,
1661
+ 420
1662
+ ],
1663
+ "page_idx": 15
1664
+ },
1665
+ {
1666
+ "type": "text",
1667
+ "text": "A black bear standing in a grassy field A black bear standing in a field of grass A black bear is standing in the grass A black bear is standing in a field A black bear standing in the grass next to a tree A black bear standing in the grass near a fence ",
1668
+ "bbox": [
1669
+ 501,
1670
+ 421,
1671
+ 751,
1672
+ 484
1673
+ ],
1674
+ "page_idx": 15
1675
+ },
1676
+ {
1677
+ "type": "text",
1678
+ "text": "Diverse Beam Search ",
1679
+ "text_level": 1,
1680
+ "bbox": [
1681
+ 586,
1682
+ 494,
1683
+ 707,
1684
+ 505
1685
+ ],
1686
+ "page_idx": 15
1687
+ },
1688
+ {
1689
+ "type": "text",
1690
+ "text": "A black dog is standing in the grass A black dog is standing in the grass ",
1691
+ "text_level": 1,
1692
+ "bbox": [
1693
+ 501,
1694
+ 506,
1695
+ 689,
1696
+ 526
1697
+ ],
1698
+ "page_idx": 15
1699
+ },
1700
+ {
1701
+ "type": "text",
1702
+ "text": "A black bear walking through a grassy field A black bear walking ina field of grass A black and white dog is standing in the grass A black bear standing in the grass near a fence ",
1703
+ "bbox": [
1704
+ 501,
1705
+ 526,
1706
+ 748,
1707
+ 569
1708
+ ],
1709
+ "page_idx": 15
1710
+ },
1711
+ {
1712
+ "type": "text",
1713
+ "text": "Difficulty Score :2.8999 ",
1714
+ "bbox": [
1715
+ 277,
1716
+ 744,
1717
+ 403,
1718
+ 756
1719
+ ],
1720
+ "page_idx": 15
1721
+ },
1722
+ {
1723
+ "type": "text",
1724
+ "text": "Beam Search ",
1725
+ "text_level": 1,
1726
+ "bbox": [
1727
+ 612,
1728
+ 589,
1729
+ 687,
1730
+ 598
1731
+ ],
1732
+ "page_idx": 15
1733
+ },
1734
+ {
1735
+ "type": "text",
1736
+ "text": "A close up of a bowl of broccoli A close up of a plate of broccoli A close up of a broccoli plant on a table Aclose up of a bowl of broccoli on a table A close up of a broccoli plant in a garden A close up of a plate of broccoli and cauliflower ",
1737
+ "bbox": [
1738
+ 504,
1739
+ 599,
1740
+ 750,
1741
+ 664
1742
+ ],
1743
+ "page_idx": 15
1744
+ },
1745
+ {
1746
+ "type": "image",
1747
+ "img_path": "images/b066fe5f4248b97c1b655d251233ccf7a81c79004631b695b39d783bfb1cbbe8.jpg",
1748
+ "image_caption": [
1749
+ "Figure 7: For images with low difficulty score, BS captions are preferred to DBS – as show in the first figure. However, we observe that DBS captions perform better when there is a mismatch between the statistics of the testing and training sets. Interesting captions are colored in blue for readability. "
1750
+ ],
1751
+ "image_footnote": [],
1752
+ "bbox": [
1753
+ 196,
1754
+ 590,
1755
+ 485,
1756
+ 738
1757
+ ],
1758
+ "page_idx": 15
1759
+ },
1760
+ {
1761
+ "type": "text",
1762
+ "text": "Diverse Beam Search ",
1763
+ "text_level": 1,
1764
+ "bbox": [
1765
+ 589,
1766
+ 674,
1767
+ 710,
1768
+ 684
1769
+ ],
1770
+ "page_idx": 15
1771
+ },
1772
+ {
1773
+ "type": "text",
1774
+ "text": "Aclose up of a bowl of broccoli Aclose up of a plate of broccoli and broccoli A green plant with a green plant in it A green plant with a bunch of green leaves A white plate topped with broccoli and a plant A small green plant with a green plant in it ",
1775
+ "bbox": [
1776
+ 503,
1777
+ 684,
1778
+ 740,
1779
+ 750
1780
+ ],
1781
+ "page_idx": 15
1782
+ },
1783
+ {
1784
+ "type": "image",
1785
+ "img_path": "images/4b1f21718dfbe05f9421ad7e3a2d6c2c85f0d31c7f6d33e3643ef377219dcbb5.jpg",
1786
+ "image_caption": [
1787
+ "Difficulty Score : 5.4382 "
1788
+ ],
1789
+ "image_footnote": [],
1790
+ "bbox": [
1791
+ 207,
1792
+ 210,
1793
+ 491,
1794
+ 358
1795
+ ],
1796
+ "page_idx": 16
1797
+ },
1798
+ {
1799
+ "type": "text",
1800
+ "text": "Beam Search ",
1801
+ "text_level": 1,
1802
+ "bbox": [
1803
+ 616,
1804
+ 214,
1805
+ 692,
1806
+ 224
1807
+ ],
1808
+ "page_idx": 16
1809
+ },
1810
+ {
1811
+ "type": "text",
1812
+ "text": "A group of people sitting at a table with laptops A group of people sitting at a table A couple of people that are sitting at a table A group of people sitting around a table with laptops A group of people sitting at a table in front of laptops A group of people sitting at a table with a laptop ",
1813
+ "bbox": [
1814
+ 508,
1815
+ 224,
1816
+ 781,
1817
+ 289
1818
+ ],
1819
+ "page_idx": 16
1820
+ },
1821
+ {
1822
+ "type": "text",
1823
+ "text": "Diverse Beam Search ",
1824
+ "text_level": 1,
1825
+ "bbox": [
1826
+ 593,
1827
+ 299,
1828
+ 714,
1829
+ 309
1830
+ ],
1831
+ "page_idx": 16
1832
+ },
1833
+ {
1834
+ "type": "text",
1835
+ "text": "A group of people sitting at a table with laptops A group of people sitting at a table with laptops A group of people sitting around a table with laptops A group of people are sitting at a table Two people sitting at a table with laptops Three people are siting at a table with laptops ",
1836
+ "bbox": [
1837
+ 509,
1838
+ 310,
1839
+ 779,
1840
+ 375
1841
+ ],
1842
+ "page_idx": 16
1843
+ },
1844
+ {
1845
+ "type": "image",
1846
+ "img_path": "images/30135864d55d2af3015cf71afa6f0c1390585b3ec4aae52f68046d295327111e.jpg",
1847
+ "image_caption": [
1848
+ "Difficulty Score : 4.1815 "
1849
+ ],
1850
+ "image_footnote": [],
1851
+ "bbox": [
1852
+ 205,
1853
+ 393,
1854
+ 491,
1855
+ 541
1856
+ ],
1857
+ "page_idx": 16
1858
+ },
1859
+ {
1860
+ "type": "text",
1861
+ "text": "Beam Search ",
1862
+ "text_level": 1,
1863
+ "bbox": [
1864
+ 617,
1865
+ 393,
1866
+ 692,
1867
+ 404
1868
+ ],
1869
+ "page_idx": 16
1870
+ },
1871
+ {
1872
+ "type": "text",
1873
+ "text": "A woman sitting in front of a laptop computer A woman sitting at a table with a laptop A woman sitting at a table with a laptop computer A woman is working on a laptop computer A woman siting at a desk with a laptop computer A woman is sitting at a table with a laptop ",
1874
+ "bbox": [
1875
+ 509,
1876
+ 404,
1877
+ 767,
1878
+ 468
1879
+ ],
1880
+ "page_idx": 16
1881
+ },
1882
+ {
1883
+ "type": "text",
1884
+ "text": "Diverse Beam Search ",
1885
+ "text_level": 1,
1886
+ "bbox": [
1887
+ 594,
1888
+ 478,
1889
+ 717,
1890
+ 488
1891
+ ],
1892
+ "page_idx": 16
1893
+ },
1894
+ {
1895
+ "type": "text",
1896
+ "text": "A woman sitting at a table with a laptop computer A woman is working on a laptop computer A woman is sitting at a table with a laptop A man sitting at a desk with a laptop computer A woman in a kitchen with a laptop computer A man is sitting at a table with a laptop and a computer ",
1897
+ "bbox": [
1898
+ 509,
1899
+ 489,
1900
+ 795,
1901
+ 553
1902
+ ],
1903
+ "page_idx": 16
1904
+ },
1905
+ {
1906
+ "type": "image",
1907
+ "img_path": "images/2e49b474bdeec252ee0c8fd4ca955890a4b6e467353d29d34401fb1dd843d6f0.jpg",
1908
+ "image_caption": [
1909
+ "Difficulty Score : 3.8146 "
1910
+ ],
1911
+ "image_footnote": [],
1912
+ "bbox": [
1913
+ 205,
1914
+ 574,
1915
+ 493,
1916
+ 722
1917
+ ],
1918
+ "page_idx": 16
1919
+ },
1920
+ {
1921
+ "type": "text",
1922
+ "text": "Beam Search ",
1923
+ "text_level": 1,
1924
+ "bbox": [
1925
+ 622,
1926
+ 573,
1927
+ 696,
1928
+ 582
1929
+ ],
1930
+ "page_idx": 16
1931
+ },
1932
+ {
1933
+ "type": "text",
1934
+ "text": "A wooden table topped with plates of food A table with plates of food on it A wooden table topped with plates and bowls of food A table that hasa bunch of plates on it A wooden table topped with plates of food and glasses A wooden table topped with plates of food and cups ",
1935
+ "bbox": [
1936
+ 513,
1937
+ 583,
1938
+ 797,
1939
+ 647
1940
+ ],
1941
+ "page_idx": 16
1942
+ },
1943
+ {
1944
+ "type": "text",
1945
+ "text": "Diverse Beam Search ",
1946
+ "text_level": 1,
1947
+ "bbox": [
1948
+ 598,
1949
+ 657,
1950
+ 718,
1951
+ 667
1952
+ ],
1953
+ "page_idx": 16
1954
+ },
1955
+ {
1956
+ "type": "text",
1957
+ "text": "A table with a plate of food and a glass of wine A table with a plate of food and a glass A table with plates of food and a glass of wine A dining table with a plate of food and a glass of wine A table with a bowl of food and a bowl of soup on it A dining room table with a plate of food and a glass of wine on it ",
1958
+ "bbox": [
1959
+ 513,
1960
+ 667,
1961
+ 794,
1962
+ 742
1963
+ ],
1964
+ "page_idx": 16
1965
+ },
1966
+ {
1967
+ "type": "text",
1968
+ "text": "Figure 8: For images with a high difficulty score, captions produced by DBS are preferred to BS. Interesting captions are colored in blue for readability. ",
1969
+ "bbox": [
1970
+ 174,
1971
+ 820,
1972
+ 823,
1973
+ 848
1974
+ ],
1975
+ "page_idx": 16
1976
+ },
1977
+ {
1978
+ "type": "image",
1979
+ "img_path": "images/65ed921c683ee3a93446aacd14516bad30606979e9db87e3bf875653961e6660.jpg",
1980
+ "image_caption": [
1981
+ "Figure 9: As the number of beams increases, all decoding methods tend to achieve about the same oracle accuracy. However, diverse decoding techniques like DBS utilize the beam budget efficiently achieving higher oracle accuracies at much lower beam budgets. "
1982
+ ],
1983
+ "image_footnote": [],
1984
+ "bbox": [
1985
+ 179,
1986
+ 397,
1987
+ 800,
1988
+ 584
1989
+ ],
1990
+ "page_idx": 17
1991
+ }
1992
+ ]
parse/train/HJV1zP5xg/HJV1zP5xg_middle.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/HJV1zP5xg/HJV1zP5xg_model.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/HJewiCVFPB/HJewiCVFPB.md ADDED
@@ -0,0 +1,408 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # GRADIENT SURGERY FOR MULTI-TASK LEARNING
2
+
3
+ Anonymous authors Paper under double-blind review
4
+
5
+ # ABSTRACT
6
+
7
+ While deep learning and deep reinforcement learning systems have demonstrated impressive results in domains such as image classification, game playing, and robotic control, data efficiency remains a major challenge, particularly as these algorithms learn individual tasks from scratch. Multi-task learning has emerged as a promising approach for sharing structure across multiple tasks to enable more efficient learning. However, the multi-task setting presents a number of optimization challenges, making it difficult to realize large efficiency gains compared to learning tasks independently. The reasons why multi-task learning is so challenging compared to single task learning are not fully understood. Motivated by the insight that gradient interference causes optimization challenges, we develop a simple and general approach for avoiding interference between gradients from different tasks, by altering the gradients through a technique we refer to as “gradient surgery”. We propose a form of gradient surgery that projects the gradient of a task onto the normal plane of the gradient of any other task that has a conflicting gradient. On a series of challenging multi-task supervised and multi-task reinforcement learning problems, we find that this approach leads to substantial gains in efficiency and performance. Further, it can be effectively combined with previously-proposed multi-task architectures for enhanced performance in a model-agnostic way.
8
+
9
+ # 1 INTRODUCTION
10
+
11
+ While deep learning and deep reinforcement learning (RL) have shown considerable promise in enabling systems to perform complex tasks, the data requirements of current methods make it difficult to learn a breadth of capabilities particularly when all tasks are learned individually from scratch. A natural approach to such multi-task learning problems is to train a single network on all tasks jointly, with the aim of discovering shared structure across the tasks in a way that achieves greater efficiency and performance than solving the tasks individually. However, learning multiple tasks all at once results in a difficult optimization problem, sometimes leading to worse overall performance and data efficiency compared to learning tasks individually (Parisotto et al., 2015; Rusu et al., 2016a). These optimization challenges are so prevalent that multiple multi-task RL algorithms have considered using independent training as a subroutine of the algorithm before distilling the independent models into a multi-tasking model (Levine et al., 2016; Parisotto et al., 2015; Rusu et al., 2016a; Ghosh et al., 2017; Teh et al., 2017), producing a multi-task model but losing out on the efficiency gains over independent training. If we could tackle the optimization challenges of multi-task learning effectively, we may be able to actually realize the hypothesized benefits of multi-task learning without the cost in final performance.
12
+
13
+ While there has been a significant amount of research in multi-task learning (Caruana, 1997; Ruder, 2017), the optimization challenges are not well understood. Prior work has described varying learning speeds of different tasks (Chen et al., 2017) and plateaus in the optimization landscape (Schaul et al., 2019) as potential causes, while a range of other works have focused on the model architecture (Misra et al., 2016b; Liu et al., 2018). In this work, we instead hypothesize that the central optimization issue in multi-task learning arises from gradients from different tasks conflicting with one another. In particular, we define two gradients to be conflicting if they point away from one another (i.e., have a negative cosine similarity). As a concrete example, consider the 2D optimization landscapes of two task objectives shown in Figure 1. The optimization landscape of each task consists of a deep valley, as has been characterized of neural network optimization landscapes in the past (Goodfellow et al., 2014). When considering the combined optimization landscape for multiple tasks, SGD produces gradients that struggle to efficiently find the optimum. This occurs due to a gradient thrashing phenomenon, where the gradient of one task destabilizes optimization in the valley. We can observe this in Figure 1(d) when the optimization reaches the deep valley of task 1, but is prevented from traversing the valley to an optimum. In Section 6.2, we find experimentally that this thrashing phenomenon also occurs in a neural network multi-task learning problem.
14
+
15
+ ![](images/61de57b0fe5017235f4ce4df8cb4be8d30719ff3e91a41a59f711ae8cb6ecd69.jpg)
16
+ Figure 1: Visualization of PCGrad’s effect on a 2D multi-task optimization problem. (a) A multi-task objective landscape. (b) & (c) Contour plots of the individual task objectives that comprise the multi-task objective. (d) Trajectory of gradient updates on the multi-task objective using the Adam optimizer. The gradient vectors of the two tasks at the end of the trajectory are indicated by blue and red arrows, where the relative lengths are on a log scale.(e) Trajectory of gradient updates on the multi-task objective using Adam with PCGrad. For (d) and (e), the optimization trajectory goes from black to yellow.
17
+
18
+ The core contribution of this work is a method for mitigating gradient interference by altering the gradients directly, i.e. by performing “gradient surgery”. If two gradients are conflicting, we alter the gradients by projecting each onto the normal plane of the other, preventing the interfering components of the gradient from being applied to the network. We refer to this particular form of gradient surgery as projecting conflicting gradients (PCGrad). PCGrad is model-agnostic, requiring only a single modification to the application of gradients. Hence, it is easy to apply to a range of problem settings, including multi-task supervised learning and multi-task reinforcement learning, and can also be readily combined with other multi-task learning approaches, such as those that modify the architecture. We evaluate PCGrad on multi-task CIFAR classification, multi-objective scene understanding, a challenging multi-task RL domain, and goal-conditioned RL. Across the board, we find PCGrad leads to significant improvements in terms of data efficiency, optimization speed, and final performance compared to prior approaches. Further, on multi-task supervised learning tasks, PCGrad can be successfully combined with prior state-of-the-art methods for multi-task learning for even greater performance.
19
+
20
+ # 2 PRELIMINARIES
21
+
22
+ The goal of multi-task learning is to find parameters $\theta$ of a model $f _ { \theta }$ that achieve high average performance across all the training tasks drawn from a distribution of tasks $p ( \tau )$ . More formally, we aim to solve the problem: $\operatorname* { m i n } _ { \theta } \mathbb { E } _ { \mathcal { T } _ { i } \sim p ( \mathcal { T } ) } \left[ \mathcal { L } _ { i } ( f _ { \theta } ) \right]$ , where $\mathcal { L } _ { i }$ is a loss function for the $i$ -th task $\mathcal { T } _ { i }$ that we want to minimize. To obtain a model that solves a specific task from the task distribution $p ( \mathcal { T } )$ , we define a task-conditioned model $f _ { \boldsymbol { \theta } } ( \boldsymbol { y } | \boldsymbol { x } , z _ { i } )$ , with input $x$ , output $y$ , and encoding $z _ { i }$ for task $\mathcal { T } _ { i }$ , which could be provided as a one-hot vector or in any other form.
23
+
24
+ # 3 MULTI-TASK LEARNING VIA GRADIENT SURGERY
25
+
26
+ While the multi-task problem can in principle be solved by simply applying a standard single-task algorithm with a suitable task identifier provided to the model or a simple multi-head or multi-output model, a number of prior works (Parisotto et al., 2015; Rusu et al., 2016a; Sener & Koltun, 2018) have found this learning problem to be difficult, especially in the reinforcement learning setting. We hypothesize that one of the main challenges of multi-task learning can be characterized by conflicting and thrashing gradients, and find that this can significantly impede learning progress, especially when combined with iterative data collection. We identify possible causes for this problem and propose a simple and general approach to mitigate it.
27
+
28
+ # 3.1 THRASHING GRADIENTS IN MULTI-TASK OPTIMIZATION LANDSCAPES
29
+
30
+ We hypothesize that a key optimization issue in multi-task learning arises when gradients from multiple tasks are in conflict with one another, i.e. when gradients point away from one another. More specifically, we hypothesize that such conflict may lead to gradient thrashing. Concretely, gradient thrashing refers to the phenomenon where a large gradient for one task changes the parameter vectors in a way that substantially decreases performance on another task. Since worse performance typically leads to larger gradients, this results in alternating gradient directions, where, at the next iteration, the second task will have large gradients that dominate and reduce performance on the former task. This issue can be particularly pronounced for neural network optimization, since neural network loss landscapes are known to resemble long narrow valleys (Goodfellow et al., 2014), where the gradient perpendicular to the direction of the valley will be small.
31
+
32
+ ![](images/28c8389133d913290b204c119be99e66cf5a7eed386a660afd2ba9a69abc4cfd.jpg)
33
+ Figure 2: Visual depiction of conflicting gradients and PCGrad. In (a), we see that tasks A and B have conflicting gradient directions, which can lead to destructive interference and unstable learning. In (b), we illustrate the PCGrad algorithm in cases where gradients are conflicting. PCGrad projects the gradient of task A onto the normal vector of task B’s gradient. In (c), we show that tasks with non-conflicting gradients are not altered under PCGrad, thereby keeping tasks with constructive interference.
34
+
35
+ We aim to study this hypothesis through two toy examples. First, consider the two-dimensional optimization landscape illustrated in Fig. 1a, where the landscape for each task objective corresponds to a deep and curved valley (Fig. 1b and 1c). The optima of this multi-task objective correspond to where the two valleys meet. More details on the optimization landscape are in Appendix B. We observe that the gradient thrashing hypothesis is consistent with what we observe when running Adam (Kingma & Ba, 2014) on this landscape in Fig. 1d, where we observe that Adam does not traverse one valley towards the other, preventing it from reaching an optimum.
36
+
37
+ We also aim to detect if a similar phenomenon occurs in multi-task learning with a neural network with thousands of parameters on a toy regression problem. To measure the extent of gradient thrashing, we plot the cosine similarity between the gradients of two tasks throughout the beginning of learning in Fig. 4 (left). We indeed observe a significant level of gradient thrashing at every iteration, where the cosine similarity varies between $- 0 . 7 5$ and 0.75 at a very high frequency.
38
+
39
+ Motivated by these observations, we develop an algorithm that aims to alleviate the optimization challenges caused by gradient thrashing by preventing such gradient conflict between tasks.
40
+
41
+ # 3.2 PCGRAD: PROJECTING CONFLICTING GRADIENTS
42
+
43
+ We aim to prevent gradient thrashing by directly altering the gradients themselves, i.e. through “gradient surgery.” To be maximally effective and maximally applicable, we must perform surgery in a way that still allows for positive interactions between the task gradients and does not introduce any assumptions on the form of the model.
44
+
45
+ We start by first detecting whether two gradients are in conflict, by measuring whether they point away from one another. More concretely, we characterize two tasks as conflicting for the current parameter setting if they yield a negative cosine similarity between their respective gradients. The goal of PCGrad is to modify the gradients for each task so as to minimize negative conflict with other task gradients, which will in turn mitigate gradient thrashing.
46
+
47
+ To deconflict gradients during optimization, PCGrad adopts a simple procedure: if the gradients between two tasks are in conflict, i.e. their cosine similarity is negative, we project the gradient from one task onto the normal plane of the gradient of the other task. This amounts to removing the conflicting component of the gradient for the task, thereby reducing the amount of destructive gradient interference between tasks. A pictorial description of this idea is shown in Fig. 2. Suppose the gradient for task $\mathcal { T } _ { i }$ is $\mathbf { g } _ { i }$ , and the gradient for task $\tau _ { j }$ is $\mathbf { g } _ { j }$ . PCGrad proceeds as follows: (1) First, it determines whether $\mathbf { g } _ { i }$ conflicts with ${ \bf { g } } _ { j }$ by computing the cosine similarity between vectors $\mathbf { g } _ { i }$ and $\mathbf { g } _ { j }$ , where negative values indicate conflicting gradients. (2) If the cosine similarity is negative, we replace $\mathbf { g } _ { i }$ by its projection onto the normal plane of $\mathbf { g } _ { j }$ : $\begin{array} { r } { \mathbf { g } _ { i } = \mathbf { g } _ { i } - \frac { \mathbf { g } _ { i } \cdot \mathbf { g } _ { j } } { \| \mathbf { g } _ { j } \| ^ { 2 } } \mathbf { g } _ { j } } \end{array}$ gi·gjkgjk2 gj . If the gradients are not in conflict, i.e. cosine similarity is non-negative, the original gradient $\mathbf { g } _ { i }$ remains unaltered. (3) PCGrad repeats this process across all of the other tasks sampled in random order from the current
48
+
49
+ # Algorithm 1 PCGrad Update Rule
50
+
51
+ Require: Current model parameters $\theta$
52
+ 1: Sample mini-batch of tasks $B = \{ \mathcal { T } _ { k } \} \sim p ( \mathcal { T } )$
53
+ 2: for $\bar { \mathcal { T } } _ { i } \sim \mathcal { B }$ in sequence do
54
+ 3: Compute gradient ${ \bf g } _ { i }$ of $\mathcal { T } _ { i }$ as $\mathbf { g } _ { i } = \nabla _ { \theta } \mathcal { L } _ { i } ( f _ { \theta } )$
55
+ 4: for ${ \tau _ { j } } \stackrel { \mathrm { u n i f o r m l y } } { \sim } { B }$ in random order do
56
+ 5: Compute gradient $\mathbf { g } _ { j }$ of task $\mathcal { T } _ { j }$ as $\mathbf { g } _ { j } = \nabla _ { \theta } \mathcal { L } _ { j } ( f _ { \theta } )$
57
+ 6: Compute cosine similarity between $\mathbf { g } _ { i }$ as $\mathbf { g } _ { j }$ as $\begin{array} { r } { \cos ( \phi _ { i j } ) = \frac { \mathbf { g } _ { i } \cdot \mathbf { g } _ { j } } { \| \mathbf { g } _ { i } \| \| \mathbf { g } _ { j } \| } } \end{array}$ .
58
+ 7: 8: if $\begin{array} { r l } & { \cos ( \phi _ { i j } ) < 0 \mathrm { t h e n } } \\ & { \mathrm { S e t } \mathbf { g } _ { i } = \mathbf { g } _ { i } - \frac { \mathbf { g } _ { i } \cdot \mathbf { g } _ { j } } { \| \mathbf { g } _ { j } \| ^ { 2 } } \mathbf { g } _ { j } } \end{array}$ // Subtract the projection of ${ \bf g } _ { i }$ onto $\mathbf { g } _ { j }$
59
+ 9: end if
60
+ 10: end for
61
+ 11: Store $\mathbf { g } _ { i } ^ { \mathrm { p r o j } } = \mathbf { g } _ { i }$
62
+ 12: end for
63
+ 13: return update $\begin{array} { r } { \Delta \theta = \sum _ { i } \mathbf { g } _ { i } ^ { \mathrm { p r o j } } } \end{array}$
64
+
65
+ batch $\mathcal { T } _ { j } \ \forall \ j \ \neq i$ , resulting in the gradient ${ \bf g } _ { i } ^ { \mathrm { p r o j } }$ that is applied for task $\mathcal { T } _ { i }$ . We perform the same procedure for all tasks in the batch to obtain their respective gradients. The full update procedure is described in Algorithm 1 and a discussion on using a random task order is included in Appendix D.
66
+
67
+ This procedure, while simple to implement, ensures that the gradients that we apply for each task per batch interfere minimally with the other tasks in the batch, mitigating the thrashing gradient problem, producing a variant on standard first-order gradient descent in the multi-objective setting. In practice, the PCGrad gradient surgery method can be combined with any gradient-based optimizer, including commonly used methods such as SGD with momentum and Adam (Kingma & Ba, 2014), by simply passing the computed update to the respective optimizer instead of the original gradient. Our experimental results verify the hypothesis that this procedure reduces the problem of thrashing gradients, and find that, as a result, learning progress is substantially improved.
68
+
69
+ Finally, we analyze the convergence of this procedure in Theorem 1 in the two-task setting, to ensure that the procedure is sensible under the standard assumptions in optimization.
70
+
71
+ Theorem 1. Consider two task loss functions $\mathcal { L } _ { 1 } : \mathbb { R } ^ { n } \mathbb { R }$ and $\mathcal { L } _ { 2 } : \mathbb { R } ^ { n } \mathbb { R }$ which are convex and differentiable. For all $\theta \in \mathbb { R } ^ { n }$ , let $\begin{array} { r } { \mathcal { L } ( \boldsymbol { \theta } ) = \mathcal { L } _ { 1 } ( \boldsymbol { \theta } ) + \mathcal { L } _ { 2 } ( \boldsymbol { \theta } ) , } \end{array}$ , i.e. $\mathcal { L }$ is a multi-task objective. Let $\phi$ be the angle between $\nabla { \mathcal { L } } _ { 1 } ( \theta )$ and $\nabla { \mathcal { L } } _ { 2 } ( \theta )$ . Suppose $\mathcal { L }$ is differentiable and that its gradient is Lipschitz continuous with constant $L > 0$ , i.e. we have $| | \nabla \mathcal { L } ( \bar { \theta _ { 1 } } ) - \nabla \mathcal { L } ( \theta _ { 2 } ) | | _ { 2 } \leq L | | \theta _ { 1 } - \theta _ { 2 } | | _ { 2 } f o r$ any $\theta _ { 1 } , \theta _ { 2 }$ . Then, the PCGrad update rule with step size $\begin{array} { r } { t \le \frac { 1 } { L } } \end{array}$ will converge to either $( l )$ a location in the optimization landscape where $\cos ( \phi ) = - 1$ or (2) the optimal value $\mathcal { L } ( \theta ^ { \ast } )$ .
72
+
73
+ Proof. See Appendix A.
74
+
75
+ Theorem 1 states that application of the PCGrad update in the two-task setting with a convex and Lipschitz multi-task loss function $\mathcal { L }$ leads to convergence to either the minimizer of $\mathcal { L }$ or a potentially sub-optimal objective value. A sub-optimal solution occurs when the cosine similarity between the gradients of the two tasks is $- 1$ , i.e. the gradients directly conflict, leading to zero gradient after applying PCGrad. However, in practice, since we are using SGD, which is a noisy estimate of the true batch gradients, the cosine similarity between the gradients of two tasks in a minibatch is unlikely to be $- 1$ , thus avoiding this scenario.
76
+
77
+ # 4 THE PRACTICAL OPERATIONS OF PCGRAD
78
+
79
+ We apply PCGrad to both supervised learning and reinforcement learning problem settings with multiple tasks or goals. In this section, we discuss the practical instantiations of PCGrad in those settings. Further implementation details are included in Section 6.
80
+
81
+ # 4.1 MULTI-TASK SUPERVISED LEARNING
82
+
83
+ In multi-task supervised learning, each task $\mathcal { T } _ { i } \sim p ( \mathcal { T } )$ has a corresponding training dataset $\mathcal { D } _ { i }$ consisting of $N _ { i }$ labeled training examples, i.e. $\mathcal { D } _ { i } = \{ ( x , y ) _ { n } \} _ { n = 1 } ^ { N _ { i } }$ . The objective for each task in this supervised setting is then defined as $\mathcal { L } _ { i } ( f _ { \theta } ) = \mathbb { E } _ { ( x , y ) \sim \mathcal { D } _ { i } } \left[ - \log f _ { \theta } ( y \vert x , z _ { i } ) \right]$ , where $z _ { i }$ is a one-hot encoding of task $\mathcal { T } _ { i }$ .
84
+
85
+ At each training step, we randomly sample a batch of data points $\boldsymbol { B }$ from the whole dataset $\textstyle \bigcup _ { i } { \mathcal { D } } _ { i }$ and then group the sampled data with the same task encoding into small batches denoted as $B _ { i }$ for each $\mathcal { T } _ { i }$ represented in $\boldsymbol { B }$ . We denote the set of tasks appearing in $\boldsymbol { B }$ as $B _ { T }$ . After sampling, we precompute the gradient of each task in $B _ { T }$ as
86
+
87
+ $$
88
+ \begin{array} { r } { \nabla _ { \theta } \mathcal { L } _ { i } ( f _ { \theta } ) = \mathbb { E } _ { ( { x } , { y } ) \sim \mathcal { B } _ { i } } \left[ - \nabla _ { \theta } \log f _ { \theta } ( { y } | { x } , { z } _ { i } ) \right] . } \end{array}
89
+ $$
90
+
91
+ Given the set of precomputed gradients $\nabla _ { \theta } \mathcal { L } _ { i } ( f _ { \theta } )$ , we also precompute the cosine similarity between all pairs of the gradients in the set. Using the pre-computed gradients and their similarities, we can obtain the PCGrad update by following Algorithm 1, without re-computing task gradients nor backpropagating into the network.
92
+
93
+ Since the PCGrad procedure is only modifying the gradients of shared parameters in the optimization step, it is model-agnostic and can be readily applied to any architecture designed for supervised multi-task learning. In Section 6, we combine PCGrad with two state-of-the-art architectures for multi-task learning, which leads to noticeable improvement over their original performance.
94
+
95
+ # 4.2 MULTI-TASK AND GOAL-CONDITIONED REINFORCEMENT LEARNING
96
+
97
+ For multi-task reinforcement learning, PCGrad can be readily applied to policy gradient methods by directly updating the computed policy gradient of each task, following Algorithm 1, analogous to the supervised learning setting. For actor-critic algorithms, it is also straightforward to apply PCGrad: we simply replace the task gradients for both the actor and the critic by their gradients computed via PCGrad. Hence, PCGrad can be readily incorporated into a variety of model-free RL algorithms. When applying PCGrad to goal-conditioned RL, we represent $p ( \mathcal T )$ as a distribution of goals and let $z _ { i }$ be the encoding of a goal. Similar to the multi-task supervised learning setting discussed above, PCGrad may be combined with various architectures designed for multi-task and goal-conditioned RL (Fernando et al., 2017; Devin et al., 2016), where PCGrad operates on the gradients of shared parameters, leaving task-specific parameters untouched.
98
+
99
+ In our experiments, we apply PCGrad to the soft actor-critic (SAC) algorithm (Haarnoja et al., 2018), a recently proposed off-policy actor-critic algorithm that has shown significant gains in sample efficiency and asymptotic performance across many different domains. In SAC, we employ a $\mathrm { Q } \mathrm { - }$ learning style gradient to compute the gradient of the Q-function network, $Q _ { \phi } ( s , a , z _ { i } )$ , often known as the critic, and a reparameterization-style gradient to compute the gradient of the policy network $\pi _ { \boldsymbol { \theta } } ( a | s , z _ { i } )$ , often known as the actor. For sampling, we instantiate a set of replay buffers $\{ \mathcal { D } _ { i } \} _ { \mathcal { T } _ { i } \sim p ( \mathcal { T } ) }$ . Training and data collection are alternated throughout training. During a data collection step, we run the policy $\pi _ { \theta }$ on all the tasks $\mathcal { T } _ { i } \sim p ( \mathcal { T } )$ to collect an equal number of paths for each task and store the paths of each task $\mathcal { T } _ { i }$ into the corresponding replay buffer $\mathcal { D } _ { i }$ . At each training step, we sample an equal amount of data from each replay buffer $\mathcal { D } _ { i }$ to form a stratified batch. For each task $\mathcal { T } _ { i } \sim p ( \mathcal { T } )$ , the parameters of the critic $\theta$ are optimized to minimize the soft Bellman residual:
100
+
101
+ $$
102
+ \begin{array} { r l } & { J _ { Q } ^ { ( i ) } ( \phi ) = \mathbb { E } _ { ( s _ { t } , a _ { t } , z _ { i } ) \sim \mathcal { D } _ { i } } \left[ Q _ { \phi } ( s _ { t } , a _ { t } , z _ { i } ) - ( r ( s _ { t } , a _ { t } , z _ { i } ) + \gamma V _ { \bar { \phi } } ( s _ { t + 1 } , z _ { i } ) ) \right] , } \\ & { V _ { \bar { \phi } } ( s _ { t + 1 } , z _ { i } ) = \mathbb { E } _ { a _ { t + 1 } \sim \pi _ { \theta } } \left[ Q _ { \bar { \phi } } ( s _ { t + 1 } , a _ { t + 1 } , z _ { i } ) - \alpha \log \pi _ { \theta } ( a _ { t + 1 } | s _ { t + 1 } , z _ { i } ) \right] , } \end{array}
103
+ $$
104
+
105
+ where $\gamma$ is the discount factor, $\bar { \phi }$ are the delayed parameters, and $\alpha$ is a learnable temperature that automatically adjusts the weight of the entropy term. For each task $\mathcal { T } _ { i } \sim p ( \mathcal { T } )$ , the parameters of the policy $\pi _ { \theta }$ are trained to minimize the following objective
106
+
107
+ $$
108
+ J _ { \pi } ^ { ( i ) } ( \theta ) = \mathbb { E } _ { s _ { t } \sim \mathcal { D } _ { i } } \left[ \mathbb { E } _ { a _ { t } \sim \pi _ { \theta } ( a _ { t } \mid s _ { t } , z _ { i } ) ) } \left[ \alpha \log \pi _ { \theta } ( a _ { t } \mid s _ { t } , z _ { i } ) - Q _ { \phi } ( { s _ { t } , a _ { t } , z _ { i } } ) \right] \right] .
109
+ $$
110
+
111
+ We compute $\nabla _ { \phi } J _ { Q } ^ { ( i ) } ( \phi )$ and $\nabla _ { \theta } J _ { \pi } ^ { ( i ) } ( \theta )$ for all $\begin{array} { r } { \mathcal { T } _ { i } \sim p ( \mathcal { T } ) } \end{array}$ and apply PCGrad to both following Algorithm 1.
112
+
113
+ In the context of SAC specifically, we further study how the temperature $\alpha$ should be adjusted. If we use a single learnable temperature for adjusting entropy of the multi-task policy $\pi _ { \boldsymbol { \theta } } ( a | s , z _ { i } )$ , SAC may stop exploring once all easier tasks are solved, leading to poor performance on tasks that are harder or require more exploration. To address this issue, we propose to learn the temperature on a per-task basis, i.e. using a parametrized model to represent $\alpha _ { \psi } ( z _ { i } )$ (which we abbreviate as PA for per-task alpha). This allows the method to control the entropy of $\dot { \pi } _ { \boldsymbol { \theta } } ( a | s , z _ { i } )$ per-task. We optimize the parameters of $\alpha _ { \psi } ( z _ { i } )$ using the same constrained optimization framework as in Haarnoja et al. (2018).
114
+
115
+ # 5 RELATED WORK
116
+
117
+ Algorithms for multi-task learning typically consider how to train a single model that can solve a variety of different tasks (Caruana, 1997; Bakker & Heskes, 2003; Ruder, 2017). The multi-task formulation has been applied to many different settings, including supervised learning (Zhang et al., 2014; Long & Wang, 2015; Yang & Hospedales, 2016; Sener & Koltun, 2018; Zamir et al., 2018) and reinforcement-learning (Espeholt et al., 2018; Wilson et al., 2007), as well as many different domains, such as vision (Bilen & Vedaldi, 2016; Misra et al., 2016a; Kokkinos, 2017; Liu et al., 2018; Zamir et al., 2018), language (Collobert & Weston, 2008; Dong et al., 2015; McCann et al., 2018; Radford et al., 2019) and robotics (Riedmiller et al., 2018; Wulfmeier et al., 2019; Hausman et al., 2018). While multi-task learning has the promise of accelerating acquisition of large task repertoires, in practice it presents a challenging optimization problem, which has been tackled in several ways in prior work.
118
+
119
+ A number of architectural solutions have been proposed to the multi-task learning problem based on multiple modules or paths (Fernando et al., 2017; Devin et al., 2016; Misra et al., 2016b; Rusu et al., 2016b; Rosenbaum et al., 2018; Vandenhende et al., 2019; Rosenbaum et al., 2018), or using attention-based architectures (Liu et al., 2018; Maninis et al., 2019). Our work is agnostic to the model architecture and can be combined with prior architectural approaches in a complementary fashion. A different set of multi-task learning approaches aim to decompose the problem into multiple local problems, often corresponding to each task, that are significantly easier to learn, akin to divide and conquer algorithms (Levine et al., 2016; Rusu et al., 2016a; Parisotto et al., 2015; Teh et al., 2017; Ghosh et al., 2017; Czarnecki et al., 2019). Eventually, the local models are combined into a single, multi-task policy using different distillation techniques (outlined in (Hinton et al., 2015; Czarnecki et al., 2019)). In contrast to these methods, we propose a simple and cogent scheme for multi-task learning that allows us to learn the tasks simultaneously using a single, shared model without the need for network distillation.
120
+
121
+ Similarly to our work, a number of prior approaches have observed the difficulty of optimization in the multi-task learning setting (Hessel et al., 2019; Chen et al., 2018; Kendall et al., 2018b; Schaul et al., 2019). Our work, in contrast to many of these optimization schemes, suggests that the challenge in multi-task learning may be attributed to the problem of gradient thrashing, which we address directly by introducing a simple and practical algorithm that de-conflicts gradients from different tasks. Prior work (Sener & Koltun, 2018) alternatively proposes a gradient-based multi-objective optimization problem for multi-task learning to address the problem of optimizing possibly conflicting objectives. As noted in Alg 2 in (Sener & Koltun, 2018), it learns a constant scaling factor for per-task gradient to avoid conflicting, while our method corrects both the scaling factor and the direction of per-task gradient, which can more effectively deconflict gradients. Prior work has also used the cosine similarity between gradients to define when an auxiliary task might be useful for single-task learning (Du et al., 2018). We similarly use cosine similarity between gradients to determine if the gradients between a pair of tasks are in conflict. Unlike Du et al. (2018), we use this measure of gradient conflict as a part of gradient surgery in the context of multi-task learning applications.
122
+
123
+ A number of works in continual learning have studied how to make gradient updates that do not adversely affect other tasks by projecting the gradients into a space that do not conflict with previous tasks (Lopez-Paz & Ranzato, 2017; Chaudhry et al., 2018). Those methods focus on the continual learning setting, and either need to solve for the gradient projections using quadratic programming (Lopez-Paz & Ranzato, 2017), or only projecting the gradient onto the normal plane of the average of the gradients of past tasks (Chaudhry et al., 2018). In contrast, our work focuses on multi-task learning, does not require solving any QP, and iteratively projects the gradients of each task onto the normal plane of the gradients of each of the other tasks instead of averaging. Finally, our method is distinct from and solves a different problem than the projected gradient method (Calamai & More, 1987), which is an approach for constrained optimization that projects gradients onto the ´ constraint manifold.
124
+
125
+ ![](images/fd487e1226e8625528f23a719200a0346be4dbf560626ca0509476293a46fb8b.jpg)
126
+ Figure 3: We show visualization of 50 tasks used in MT50 from Meta-World (Yu et al., 2019), which we use for our multi-task RL experiments. MT10 is a subset of the total 50 tasks, which includes reach, push, pick & place, open drawer, close drawer, open door, press button top, open window, close window, and insert peg inside.
127
+
128
+ # 6 EXPERIMENTS
129
+
130
+ The goal of our experiments is to study the following questions: (1) Are conflicting gradients a major factor in making optimization for multi-task learning challenging? (2) Does PCGrad make the optimization problems easier for various multi-task learning problems including supervised, reinforcement, and goal-conditioned reinforcement learning settings across different task families? (3) Can PCGrad be combined with other multi-task learning approaches to further improve performance?
131
+
132
+ # 6.1 EXPERIMENTAL SETUP
133
+
134
+ To evaluate our method experimentally, we consider both a multi-task supervised learning and a multi-task reinforcement learning problem setup. For supervised learning, we first consider the MultiMNIST dataset (Sener & Koltun, 2018), which contains two tasks: classifying the digit on the top left and on the bottom right in an overlaid image. Beyond digit classification, we also use the CIFAR-100 dataset (Krizhevsky et al., 2009) where each of the 20 label superclasses are treated as distinct tasks, following Rosenbaum et al. (2018). We also conduct experiments on the NYUv2 dataset (Silberman et al., 2012), which consists of RGB-D indoor scene images. Following Liu et al. (2018), we evaluate our method on 3 tasks: 13-class semantic segmentation, depth estimation, and surface normal prediction. In the case of multi-task reinforcement learning, we evaluate our algorithm on the recently proposed Meta-World benchmark (Yu et al., 2019). This benchmark includes a variety of simulated robotic manipulation tasks contained in a shared, table-top environment with a simulated Sawyer arm (visualized as the ”Push” environment in Fig. 3). In particular, we use the multi-task benchmarks MT10 and MT50, which consists of the 10 tasks and 50 tasks respectively depicted in Fig. 3 that require diverse strategies to solve them, which makes them difficult to optimize jointly with a single policy. Note that MT10 is a subset of MT50. To evaluate goal-conditioned RL scenarios, we consider goal-conditioned robotic pushing with a Sawyer robot. This domain is representative of challenges in learning goal-conditioned policies over a wide distribution of goals. For details on the experimental set-up and model architectures see Appendix E.
135
+
136
+ # 6.2 ANALYSIS OF CONFLICTING GRADIENTS
137
+
138
+ To answer question (1), we consider a simple regression problem, where each task is regressing the input to the output of a sine function. The amplitude and the phase of each task are varied. We construct 10 tasks with the amplitude uniformly sampled from the range [0, 5] and the phase uniformly sampled from the range $[ 0 , \pi ]$ . The input is also uniformly sampled from the range $[ 0 , 5 ]$ and is concatenated with the one-hot task encoding. For training, we use a 3-layer fully-connected neural network with 100 hidden units.
139
+
140
+ ![](images/6be492001dd85363da9fcd707c39223ebe8895c02351127cc23ecc0ee1a381e0.jpg)
141
+ Figure 4: An analysis of the gradients during the first 1000 updates of training, on a toy 10-task sinusoid regression problem. Left: The cosine similarity between the gradients of 2 of the 10 tasks (selected arbitrarily, and fixed throughout this plot). We observe a substantial amount of thrashing with standard Adam training, while Adam with PCGrad reduces the thrashing and leads to more closely aligned updates. Right: Adam with PCGrad improves performance compared to standard Adam.
142
+
143
+ We compare the performance of the network trained with Adam and the network trained with Adam with PCGrad-modified gradients while plotting the cosine similarity between a pair of tasks during training as shown in Figure 4. The plot on the left in Figure 4 demonstrates that the cosine similarity of Adam gradients between a pair of tasks has high variance, which leads to the gradient thrashing problem, while the cosine similarity of the gradient projected by PCGrad yields positive values diminishing the conflicting-gradients problem. As shown in the plot on the right in Figure 4, Adam with PCGrad leads to faster learning over Adam, which implies that gradient thrashing is indeed a problem in multi-task optimization and reducing it can result in considerable performance boost.
144
+
145
+ # 6.3 MULTI-TASK AND MULTI-OBJECTIVE SUPERVISED LEARNING WITH PCGRAD
146
+
147
+ To answer question (3), we perform experiments on three standard multi-task supervised learning datasets: MultiMNIST, multi-task CIFAR-100 and NYUv2. We include the results on MultiMNIST in Appendix C.
148
+
149
+ For CIFAR-100, we follow (Rosenbaum et al., 2018) to treat 20 coarse labels in the dataset as distinct tasks and create a dataset with 20 tasks and 2500 training instances as well as 500 test instances per task. We combine PCGrad with a powerful multi-task learning architecture, routing networks (Rosenbaum et al., 2018; 2019), by simply projecting gradients of the shared parameters in routing networks. As shown in Table 1, applying PCGrad to a single network achieves $71 \%$ classification accuracy, which outperforms most of the prior methods such as independent training and cross-stitch (Misra et al., 2016b). Though routing networks achieve better performance than PCGrad on its own, PCGrad is complementary to routing networks and combining PCGrad with routing networks leads to a $2 . 8 \%$ absolute improvement in test accuracy averaged over 3 runs.
150
+
151
+ We also combine PCGrad with another state-of-art multi-task learning algorithm, MTAN (Liu et al., 2018), and evaluate the performance on a more challenging indoor scene dataset, NYUv2, which contains 3 tasks as described in Section 6.1. We compare MTAN with PCGrad to a list of methods mentioned in Section 6.1, where each method is trained with three different weighting schemes as in (Liu et al., 2018), equal weighting, weight uncertainty (Kendall et al., 2018a), and DWA (Liu et al., 2018). We only run MTAN with PCGrad with weight uncertainty as we find weight uncertainty as the most effective scheme for training MTAN. The results comparing Cross-Stitch, MTAN and MTAN $^ +$ PCGrad are presented in Table 2 while the full comparison can be found in Table 4 in the Appendix E.3. MTAN with PCGrad is able to achieve the best scores in 8 out of the 9 categories where there are 3 categories per task.
152
+
153
+ Our multi-task supervised learning results demonstrate that PCGrad can be seamlessly combined with state-of-art multi-task learning architectures and further improve their results on established supervised multi-task learning benchmarks.
154
+
155
+ # 6.4 MULTI-TASK REINFORCEMENT LEARNING
156
+
157
+ To answer question (2), we test all methods on 10 and 50 manipulation tasks respectively shown in Figure 3. At each data collection step, we collect 600 samples for each task, and at each training step,
158
+
159
+ <table><tr><td></td><td>% accuracy</td></tr><tr><td>task specific-1-fc (Rosenbaum et al., 2018)</td><td>42</td></tr><tr><td>task specific-all-fc (Rosenbaum et al., 2018)</td><td>49</td></tr><tr><td>cross stitch-all-fc (Misra et al.,2016b) routing-all-fc + WPL (Rosenbaum et al.,2019)</td><td>53</td></tr><tr><td>independent</td><td>74.7</td></tr><tr><td>PCGrad (ours)</td><td>67.7</td></tr><tr><td></td><td>71</td></tr><tr><td>routing-all-fc + WPL + PCGrad (ours)</td><td>[77.5</td></tr></table>
160
+
161
+ Table 1: CIFAR-100 multi-task results. We apply PCGrad to the routing networks and achieve a significant improvement in classfication accuracy.
162
+
163
+ <table><tr><td rowspan="2">#P.</td><td rowspan="2">Architecture</td><td rowspan="2">Weighting</td><td colspan="2">Segmentation</td><td colspan="2">Depth</td><td colspan="5">Surface Normal</td></tr><tr><td>(Higher Better) mIoU</td><td>Pix Acc</td><td>(Lower Better) Abs Err</td><td>Rel Err</td><td>Angle Distance (Lower Better) Mean1</td><td>Median</td><td>11.25</td><td>Within t° (Higher Better) 22.5</td><td>30</td></tr><tr><td rowspan="4">~3</td><td rowspan="2">Cros-Stitch+</td><td>Equal Weights</td><td>14.71</td><td>50.23</td><td>0.6481</td><td>0.2871</td><td>33.56</td><td>28.58</td><td>20.08</td><td>40.54</td><td>51.97</td></tr><tr><td>Uncert.Weights*</td><td>15.69</td><td>52.60</td><td>0.6277</td><td>0.2702</td><td>32.69</td><td>27.26</td><td>21.63</td><td>42.84</td><td>54.45</td></tr><tr><td rowspan="2"></td><td>DWA†,T=2</td><td>16.11</td><td>53.19</td><td>0.5922</td><td>0.2611</td><td>32.34</td><td>26.91</td><td>21.81</td><td>43.14</td><td>54.92</td></tr><tr><td>Equal Weights</td><td>17.72</td><td>55.32</td><td>0.5906</td><td>0.2577</td><td>31.44</td><td>25.37</td><td>23.17</td><td>45.65</td><td>57.48</td></tr><tr><td rowspan="2">1.77</td><td rowspan="2">MTANt</td><td>Uncert.Weights*</td><td>17.67</td><td>55.61</td><td>0.5927</td><td>0.2592</td><td>31.25</td><td>25.57</td><td>22.99</td><td>45.83</td><td>57.67</td></tr><tr><td>DWA+,T=2</td><td>17.15</td><td>54.97</td><td>0.5956</td><td>0.2569</td><td>31.60</td><td>25.46</td><td>22.48</td><td>44.86</td><td>57.24</td></tr><tr><td></td><td></td><td>1.77MTAN++ PCGrad (ours)Uncert.Weights*</td><td>20.17</td><td>56.65</td><td>0.5904</td><td>0.2467</td><td>30.01</td><td>24.83</td><td>22.28</td><td>46.12</td><td>58.77</td></tr></table>
164
+
165
+ Table 2: We present the results on three tasks on the NYUv2 dataset: 13-class semantic segmentation, depth estimation, and surface normal prediction results. #P shows the total number of network parameters. We highlight the best performing combination of multi-task architecture and weighting in bold. The top validation scores for each task are annotated with boxes. The symbols indicate prior methods: ∗: (Kendall et al., 2018a), †: (Liu et al., 2018), ‡: (Misra et al., 2016b). Performance of other methods as reported in (Liu et al., 2018).
166
+
167
+ ![](images/377976d48312e8cb7dfcb0de421a3d07cf0558c92f93eb0fe433c37dc3e4830e.jpg)
168
+ Figure 5: Learning curve on MT10, MT50 and goal-conditioned pushing. PCGrad outperforms the other methods in the three settings in terms of both success rates / average distance to the goal and data efficiency.
169
+
170
+ we sample 128 datapoints per task from corresponding replay buffers. The results are shown in the two plots on the left in Figure 5. We measure success according to the metrics used in the Meta-World benchmark where the reported the success rates are averaged across tasks. For all methods, we apply PA as discussed in Section 4 to learn a separate alpha term per task as the task encoding in MT10 and MT50 is just a one-hot encoding. PCGrad combined with SAC learns all tasks with the best data efficiency and successfully solves all of the 10 tasks in MT10 and about $70 \%$ of the 50 tasks in MT50. Training a single SAC policy and a multi-head policy turns out to be unable to acquire half of the skills in both MT10 and MT50, suggesting that eliminating gradient interference across tasks can significantly boost performance of multi-task RL. Training independent SAC agents is able to eventually solve all tasks in MT10 and $70 \%$ of the tasks in MT50, but requires about 2 millions and 15 millions more samples than PCGrad with SAC in MT10 and MT50 respectively, implying that applying PCGrad can result in leveraging shared structure among tasks that expedites multi-task learning.
171
+
172
+ As noted by $\mathrm { Y u }$ et al. (2019), these tasks involve fairly distinct behavior motions, which makes learning all of them with a single policy challenging as demonstrated by poor baseline performance. The ability to learn these tasks together opens the door for a number of interesting extensions to meta-learning, goal conditioned RL and generalization to novel task families. We present the results of PCGrad on goal-conditioned RL in the following subsection.
173
+
174
+ We also provide an ablation study on the importance of correcting the gradient direction and scaling the gradient magnitudes in PCGrad. We construct two variants of PCGrad: (1) only applying the gradient direction corrected with PCGrad while keeping the gradient magnitude unchanged and (2) only applying the gradient magnitude computed by PCGrad while keeping the gradient direction unchanged. As shown in the plot on the left in Figure 6, both variants perform worse than PCGrad and the variant where we only vary the gradient magnitudes is much worse than PCGrad. We also compare PCGrad to a prior method GradNorm (Chen et al., 2018), which scales the magnitude of gradients of all the tasks. As shown in the plot on the right in Figure 6, PCGrad significantly outperforms GradNorm. We also notice that the variant of PCGrad where only the gradient magnitudes change gets comparable results to GradNorm, which suggests that its important to modify both the gradient directions and magnitudes to eliminate interference and achieve good multi-task learning results.
175
+
176
+ ![](images/412941b5dca2cd83f58b0c272e922c1522ccbaa8b55a58fb2ffb379383c3a3c8.jpg)
177
+ Figure 6: Ablation study on only using the magnitude and the direction of the gradients modified by PCGrad (left) and comparison between PCGrad and GradNorm (Chen et al., 2018) (right). PCGrad outperforms both ablations and GradNorm with a large margin, indicating the importance of modifying both the gradient directions and magnitudes in multi-task learning.
178
+
179
+ # 6.5 GOAL-CONDITIONED REINFORCEMENT LEARNING
180
+
181
+ For our goal-conditioned RL evaluation, we use the robot-pushing environment described in Sec. 6.1 where the goals are represented as the concatenations of the initial positions of the puck to be pushed and the its goal location, both of which are uniformly sampled (details in Appendix E.2). We also apply PA as discussed in Section 4 to predict the temperature for entropy term given the goal. We summarize the results in the plot on the right in Figure 5. PCGrad with SAC and PA achieves the best performance in terms of average distance to the goal position, while PCGrad with SAC improves over the baseline and a vanilla SAC agent is struggling to successfully accomplish the task. This suggests that PCGrad is able to ease the RL optimization problem also when the task distribution is continuous.
182
+
183
+ # 7 CONCLUSION
184
+
185
+ In this work, we identified one of the major challenges in multi-task optimization: conflicting gradients across tasks. We proposed a simple algorithm (PCGrad) to mitigate the challenge of conflicting gradients via “gradient surgery”. PCGrad provides a simple way to project gradients to be orthogonal in a multi-task setting, which substantially improves optimization performance, since the task gradients are prevented from negating each other. We provide some simple didactic examples and analysis of how this procedure works in simple settings, and subsequently show significant improvement in optimization for a variety of multi-task supervised learning and reinforcement learning problems. We show that, once some of the optimization challenges of multi-task learning are alleviated by PCGrad, we can obtain the hypothesized benefits in efficiency and asymptotic performance that are believed to be possible in multi-task settings.
186
+
187
+ While we studied multi-task supervised learning and multi-task reinforcement learning in this work, we suspect the problem of conflicting gradients to be prevalent in a range of other settings and applications, such as meta-learning, continual learning, multi-goal imitation learning (Codevilla et al., 2018), and multi-task problems in natural language processing applications (McCann et al., 2018). Due to its simplicity and model-agnostic nature, we expect that applying PCGrad in these domains to be a promising avenue for future investigation. Further, the general idea of gradient surgery may be an important ingredient for alleviating a broader class of optimization challenges in deep learning, such as the challenges in the stability challenges in two-player games (Roth et al., 2017) and multi-agent optimizations (Nedic & Ozdaglar, 2009). We believe this work to be a step towards simple yet general techniques for addressing some of these challenges.
188
+
189
+ # REFERENCES
190
+
191
+ Vijay Badrinarayanan, Alex Kendall, and Roberto Cipolla. Segnet: A deep convolutional encoderdecoder architecture for image segmentation. IEEE transactions on pattern analysis and machine intelligence, 39(12):2481–2495, 2017.
192
+
193
+ Bart Bakker and Tom Heskes. Task clustering and gating for bayesian multitask learning. J. Mach. Learn. Res., 2003.
194
+
195
+ Hakan Bilen and Andrea Vedaldi. Integrated perception with recurrent multi-task neural networks. In Advances in neural information processing systems, pp. 235–243, 2016.
196
+
197
+ Stephen Boyd and Lieven Vandenberghe. Convex optimization. Cambridge university press, 2004.
198
+
199
+ Paul H Calamai and Jorge J More. Projected gradient methods for linearly constrained problems. ´ Mathematical programming, 39(1):93–116, 1987.
200
+
201
+ Rich Caruana. Multitask learning. Machine Learning, 1997.
202
+
203
+ Arslan Chaudhry, Marc’Aurelio Ranzato, Marcus Rohrbach, and Mohamed Elhoseiny. Efficient lifelong learning with a-gem. arXiv preprint arXiv:1812.00420, 2018.
204
+
205
+ Zhao Chen, Vijay Badrinarayanan, Chen-Yu Lee, and Andrew Rabinovich. Gradnorm: Gradient normalization for adaptive loss balancing in deep multitask networks. arXiv preprint arXiv:1711.02257, 2017.
206
+
207
+ Zhao Chen, Vijay Badrinarayanan, Chen-Yu Lee, and Andrew Rabinovich. Gradnorm: Gradient normalization for adaptive loss balancing in deep multitask networks. In Proceedings of the International Conference on Machine Learning, 2018.
208
+
209
+ Felipe Codevilla, Matthias Miiller, Antonio Lopez, Vladlen Koltun, and Alexey Dosovitskiy. End-to- ´ end driving via conditional imitation learning. In 2018 IEEE International Conference on Robotics and Automation (ICRA), pp. 1–9. IEEE, 2018.
210
+
211
+ Ronan Collobert and Jason Weston. A unified architecture for natural language processing: Deep neural networks with multitask learning. In Proceedings of the 25th international conference on Machine learning, pp. 160–167. ACM, 2008.
212
+
213
+ Wojciech M. Czarnecki, Razvan Pascanu, Simon Osindero, Siddhant M. Jayakumar, Grzegorz Swirszcz, and Max Jaderberg. Distilling policy distillation. In The 22nd International Conference on Artificial Intelligence and Statistics, AISTATS, 2019.
214
+
215
+ Coline Devin, Abhishek Gupta, Trevor Darrell, Pieter Abbeel, and Sergey Levine. Learning modular neural network policies for multi-task and multi-robot transfer. CoRR, abs/1609.07088, 2016.
216
+
217
+ Daxiang Dong, Hua Wu, Wei He, Dianhai Yu, and Haifeng Wang. Multi-task learning for multiple language translation. In Proceedings of the 53rd Annual Meeting of the Association for Computational Linguistics and the 7th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pp. 1723–1732, 2015.
218
+
219
+ Yunshu Du, Wojciech M. Czarnecki, Siddhant M. Jayakumar, Razvan Pascanu, and Balaji Lakshminarayanan. Adapting auxiliary losses using gradient similarity. CoRR, abs/1812.02224, 2018.
220
+
221
+ Lasse Espeholt, Hubert Soyer, Remi Munos, Karen Simonyan, Volodymyr Mnih, Tom Ward, Yotam ´ Doron, Vlad Firoiu, Tim Harley, Iain Dunning, Shane Legg, and Koray Kavukcuoglu. IMPALA: scalable distributed deep-rl with importance weighted actor-learner architectures. In Proceedings of the 35th International Conference on Machine Learning, 2018.
222
+
223
+ Chrisantha Fernando, Dylan Banarse, Charles Blundell, Yori Zwols, David Ha, Andrei A. Rusu, Alexander Pritzel, and Daan Wierstra. Pathnet: Evolution channels gradient descent in super neural networks. CoRR, abs/1701.08734, 2017. URL http://arxiv.org/abs/1701.08734.
224
+
225
+ Dibya Ghosh, Avi Singh, Aravind Rajeswaran, Vikash Kumar, and Sergey Levine. Divide-andconquer reinforcement learning. CoRR, abs/1711.09874, 2017.
226
+
227
+ Ian J Goodfellow, Oriol Vinyals, and Andrew M Saxe. Qualitatively characterizing neural network optimization problems. arXiv preprint arXiv:1412.6544, 2014.
228
+
229
+ Tuomas Haarnoja, Aurick Zhou, Pieter Abbeel, and Sergey Levine. Soft actor-critic: Off-policy maximum entropy deep reinforcement learning with a stochastic actor. International Conference on Machine Learning, 2018.
230
+
231
+ Karol Hausman, Jost Tobias Springenberg, Ziyu Wang, Nicolas Heess, and Martin Riedmiller. Learning an embedding space for transferable robot skills. 2018.
232
+
233
+ Matteo Hessel, Hubert Soyer, Lasse Espeholt, Wojciech Czarnecki, Simon Schmitt, and Hado van Hasselt. Multi-task deep reinforcement learning with popart. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 33, pp. 3796–3803, 2019.
234
+
235
+ Geoffrey Hinton, Oriol Vinyals, and Jeff Dean. Distilling the knowledge in a neural network. arXiv preprint arXiv:1503.02531, 2015.
236
+
237
+ Alex Kendall, Yarin Gal, and Roberto Cipolla. Multi-task learning using uncertainty to weigh losses for scene geometry and semantics. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pp. 7482–7491, 2018a.
238
+
239
+ Alex Kendall, Yarin Gal, and Roberto Cipolla. Multi-task learning using uncertainty to weigh losses for scene geometry and semantics. In CVPR, 2018b.
240
+
241
+ Diederik P Kingma and Jimmy Ba. Adam: A method for stochastic optimization. arXiv preprint arXiv:1412.6980, 2014.
242
+
243
+ Iasonas Kokkinos. Ubernet: Training a universal convolutional neural network for low-, mid-, and high-level vision using diverse datasets and limited memory. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pp. 6129–6138, 2017.
244
+
245
+ Alex Krizhevsky, Geoffrey Hinton, et al. Learning multiple layers of features from tiny images. Technical report, Citeseer, 2009.
246
+
247
+ Sergey Levine, Chelsea Finn, Trevor Darrell, and Pieter Abbeel. End-to-end training of deep visuomotor policies. The Journal of Machine Learning Research, 17(1):1334–1373, 2016.
248
+
249
+ Shikun Liu, Edward Johns, and Andrew J. Davison. End-to-end multi-task learning with attention. CoRR, abs/1803.10704, 2018.
250
+
251
+ Mingsheng Long and Jianmin Wang. Learning multiple tasks with deep relationship networks. arXiv preprint arXiv:1506.02117, 2, 2015.
252
+
253
+ David Lopez-Paz and Marc’Aurelio Ranzato. Gradient episodic memory for continual learning. In Advances in Neural Information Processing Systems, pp. 6467–6476, 2017.
254
+
255
+ Kevis-Kokitsi Maninis, Ilija Radosavovic, and Iasonas Kokkinos. Attentive single-tasking of multiple tasks. CoRR, abs/1904.08918, 2019.
256
+
257
+ Bryan McCann, Nitish Shirish Keskar, Caiming Xiong, and Richard Socher. The natural language decathlon: Multitask learning as question answering. arXiv preprint arXiv:1806.08730, 2018.
258
+
259
+ Ishan Misra, Abhinav Shrivastava, Abhinav Gupta, and Martial Hebert. Cross-stitch networks for multi-task learning. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pp. 3994–4003, 2016a.
260
+
261
+ Ishan Misra, Abhinav Shrivastava, Abhinav Gupta, and Martial Hebert. Cross-stitch networks for multi-task learning. In Conference on Computer Vision and Pattern Recognition, CVPR, 2016b.
262
+
263
+ Angelia Nedic and Asuman Ozdaglar. Distributed subgradient methods for multi-agent optimization. IEEE Transactions on Automatic Control, 54(1):48, 2009.
264
+
265
+ Emilio Parisotto, Jimmy Lei Ba, and Ruslan Salakhutdinov. Actor-mimic: Deep multitask and transfer reinforcement learning. arXiv preprint arXiv:1511.06342, 2015.
266
+
267
+ Alec Radford, Jeffrey Wu, Rewon Child, David Luan, Dario Amodei, and Ilya Sutskever. Language models are unsupervised multitask learners. OpenAI Blog, 1(8), 2019.
268
+
269
+ Martin Riedmiller, Roland Hafner, Thomas Lampe, Michael Neunert, Jonas Degrave, Tom Van de Wiele, Volodymyr Mnih, Nicolas Heess, and Jost Tobias Springenberg. Learning by playingsolving sparse reward tasks from scratch. arXiv preprint arXiv:1802.10567, 2018.
270
+
271
+ Clemens Rosenbaum, Tim Klinger, and Matthew Riemer. Routing networks: Adaptive selection of non-linear functions for multi-task learning. International Conference on Learning Representations (ICLR), 2018.
272
+
273
+ Clemens Rosenbaum, Ignacio Cases, Matthew Riemer, and Tim Klinger. Routing networks and the challenges of modular and compositional computation. arXiv preprint arXiv:1904.12774, 2019.
274
+
275
+ Kevin Roth, Aurelien Lucchi, Sebastian Nowozin, and Thomas Hofmann. Stabilizing training of generative adversarial networks through regularization. In Advances in neural information processing systems, pp. 2018–2028, 2017.
276
+
277
+ Sebastian Ruder. An overview of multi-task learning in deep neural networks. arXiv preprint arXiv:1706.05098, 2017.
278
+
279
+ Andrei A. Rusu, Sergio Gomez Colmenarejo, C¸ aglar Gul¨ c¸ehre, Guillaume Desjardins, James Kirkpatrick, Razvan Pascanu, Volodymyr Mnih, Koray Kavukcuoglu, and Raia Hadsell. Policy distillation. In 4th International Conference on Learning Representations, ICLR, 2016a.
280
+
281
+ Andrei A Rusu, Neil C Rabinowitz, Guillaume Desjardins, Hubert Soyer, James Kirkpatrick, Koray Kavukcuoglu, Razvan Pascanu, and Raia Hadsell. Progressive neural networks. arXiv preprint arXiv:1606.04671, 2016b.
282
+
283
+ Tom Schaul, Diana Borsa, Joseph Modayil, and Razvan Pascanu. Ray interference: a source of plateaus in deep reinforcement learning. arXiv preprint arXiv:1904.11455, 2019.
284
+
285
+ Ozan Sener and Vladlen Koltun. Multi-task learning as multi-objective optimization. In Advances in Neural Information Processing Systems, 2018.
286
+
287
+ Nathan Silberman, Derek Hoiem, Pushmeet Kohli, and Rob Fergus. Indoor segmentation and support inference from rgbd images. In European Conference on Computer Vision, pp. 746–760. Springer, 2012.
288
+
289
+ Yee Teh, Victor Bapst, Wojciech M Czarnecki, John Quan, James Kirkpatrick, Raia Hadsell, Nicolas Heess, and Razvan Pascanu. Distral: Robust multitask reinforcement learning. In Advances in Neural Information Processing Systems, pp. 4496–4506, 2017.
290
+
291
+ Simon Vandenhende, Bert De Brabandere, and Luc Van Gool. Branched multi-task networks: Deciding what layers to share. CoRR, abs/1904.02920, 2019.
292
+
293
+ Aaron Wilson, Alan Fern, Soumya Ray, and Prasad Tadepalli. Multi-task reinforcement learning: a hierarchical bayesian approach. In Proceedings of the 24th international conference on Machine learning, pp. 1015–1022. ACM, 2007.
294
+
295
+ Markus Wulfmeier, Abbas Abdolmaleki, Roland Hafner, Jost Tobias Springenberg, Michael Neunert, Tim Hertweck, Thomas Lampe, Noah Siegel, Nicolas Heess, and Martin Riedmiller. Regularized hierarchical policies for compositional transfer in robotics. arXiv preprint arXiv:1906.11228, 2019.
296
+
297
+ Yongxin Yang and Timothy M Hospedales. Trace norm regularised deep multi-task learning. arXiv preprint arXiv:1606.04038, 2016.
298
+
299
+ 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. arXiv preprint arXiv:1910.10897, 2019.
300
+
301
+ Amir R Zamir, Alexander Sax, William Shen, Leonidas J Guibas, Jitendra Malik, and Silvio Savarese. Taskonomy: Disentangling task transfer learning. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pp. 3712–3722, 2018.
302
+
303
+ Zhanpeng Zhang, Ping Luo, Chen Change Loy, and Xiaoou Tang. Facial landmark detection by deep multi-task learning. In European conference on computer vision, pp. 94–108. Springer, 2014.
304
+
305
+ # A PROOF OF THEOREM 1
306
+
307
+ Proof. We will use the shorthand $| | \cdot | |$ to denote the $L _ { 2 }$ -norm and $\nabla { \mathcal { L } } = \nabla _ { \theta } { \mathcal { L } }$ , where $\theta$ is the parameter vector. Let $\mathbf { g _ { 1 } } = \nabla \mathcal { L } _ { 1 }$ , $\mathbf { g _ { 2 } } = \nabla \mathcal { L } _ { 2 }$ , and $\phi$ be the angle between $\bf { g _ { 1 } }$ and $\mathbf { g _ { 2 } }$ .
308
+
309
+ At each PCGrad update, we have two cases: $c o s ( \phi ) \geq 0$ or $\cos ( \phi < 0 )$ .
310
+
311
+ If $\cos ( \phi ) \geq 0$ , then we apply the standard gradient descent update using $\begin{array} { r } { t \leq \frac { 1 } { L } } \end{array}$ , which leads to a strict decrease in the objective function value ${ \mathcal { L } } ( \phi )$ unless $\nabla \mathcal { L } ( \phi ) = 0$ , which occurs only when $\theta = \theta ^ { * }$ (Boyd & Vandenberghe, 2004).
312
+
313
+ In the case that $\cos ( \phi ) < 0$ , we proceed as follows:
314
+
315
+ Our assumption that $\nabla \mathcal { L }$ is Lipschitz continuous with constant $L$ implies that $\nabla ^ { 2 } { \mathcal { L } } ( \theta ) - L I$ is a negative semidefinite matrix. Using this fact, we can perform a quadratic expansion of $\mathcal { L }$ around $\mathcal { L } ( \boldsymbol { \theta } )$ and obtain the following inequality:
316
+
317
+ $$
318
+ \begin{array} { l } { \displaystyle \mathcal { L } ( { \boldsymbol { \theta } } ^ { + } ) \leq \mathcal { L } ( { \boldsymbol { \theta } } ) + \nabla \mathcal { L } ( { \boldsymbol { \theta } } ) ^ { T } ( { \boldsymbol { \theta } } ^ { + } - { \boldsymbol { \theta } } ) + \frac { 1 } { 2 } \nabla ^ { 2 } \mathcal { L } ( { \boldsymbol { \theta } } ) \vert \vert { \boldsymbol { \theta } } ^ { + } - { \boldsymbol { \theta } } \vert \vert ^ { 2 } } \\ { \leq \mathcal { L } ( { \boldsymbol { \theta } } ) + \nabla \mathcal { L } ( { \boldsymbol { \theta } } ) ^ { T } ( { \boldsymbol { \theta } } ^ { + } - { \boldsymbol { \theta } } ) + \frac { 1 } { 2 } L \vert \vert { \boldsymbol { \theta } } ^ { + } - { \boldsymbol { \theta } } \vert \vert ^ { 2 } } \end{array}
319
+ $$
320
+
321
+ Now, we can plug in the PCGrad update by letting θ+ = θ − t(∇L(θ) − g1·g2||g1||2 g1 − | g1·g2|g2||2 g2). We then get:
322
+
323
+ $$
324
+ \begin{array} { r l } & { \mathcal { L } ( \boldsymbol { \theta } ^ { + } ) \leq \mathcal { L } ( \boldsymbol { \theta } ) + t ( \nabla \mathcal { L } ( \boldsymbol { \theta } ) ) ^ { T } ( - \nabla \mathcal { L } ( \boldsymbol { \theta } ) + \frac { \mathbf { g _ { 1 } } \cdot \mathbf { g _ { 2 } } } { | | \mathbf { g _ { 1 } } | | ^ { 2 } } \mathbf { g _ { 1 } } + \frac { \mathbf { g _ { 1 } } \cdot \mathbf { g _ { 2 } } } { | | \mathbf { g _ { 2 } } | | ^ { 2 } } \mathbf { g _ { 2 } } ) } \\ & { \qquad + \frac { 1 } { 2 } L t ^ { 2 } | | \nabla \mathcal { L } ( \boldsymbol { \theta } ) - \frac { \mathbf { g _ { 1 } } \cdot \mathbf { g _ { 2 } } } { | | \mathbf { g _ { 1 } } | | ^ { 2 } } \mathbf { g _ { 1 } } - \frac { \mathbf { g _ { 1 } } \cdot \mathbf { g _ { 2 } } } { | | \mathbf { g _ { 2 } } | | ^ { 2 } } \mathbf { g _ { 2 } } | | ^ { 2 } } \end{array}
325
+ $$
326
+
327
+ $$
328
+ \begin{array} { l } { = \displaystyle \mathcal { L } ( \boldsymbol { \theta } ) + t ( - | | \mathbf { g _ { 1 } } | | ^ { 2 } - | | \mathbf { g _ { 2 } } | | ^ { 2 } + 2 \mathbf { g _ { 1 } } \cdot \mathbf { g _ { 2 } } + \frac { ( \mathbf { g _ { 1 } } \cdot \mathbf { g _ { 2 } } ) ^ { 2 } } { | | \mathbf { g _ { 1 } } | | ^ { 2 } } + \frac { ( \mathbf { g _ { 1 } } \cdot \mathbf { g _ { 2 } } ) ^ { 2 } } { | | \mathbf { g _ { 2 } } | | ^ { 2 } } ) } \\ { + \displaystyle \frac { 1 } { 2 } L t ^ { 2 } | | \mathbf { g _ { 1 } } + \mathbf { g _ { 2 } } - \frac { \mathbf { g _ { 1 } } \cdot \mathbf { g _ { 2 } } } { | | \mathbf { g _ { 1 } } | | ^ { 2 } } \mathbf { g _ { 1 } } - \frac { \mathbf { g _ { 1 } } \cdot \mathbf { g _ { 2 } } } { | | \mathbf { g _ { 2 } } | | ^ { 2 } } \mathbf { g _ { 2 } } | | ^ { 2 } } \end{array}
329
+ $$
330
+
331
+ (Expanding further and re-arranging terms)
332
+
333
+ $$
334
+ { \begin{array} { l } { = { \mathcal { L } } ( \theta ) - ( t - { \frac { 1 } { 2 } } L t ^ { 2 } ) ( | | \mathbf { g _ { 1 } } | | ^ { 2 } + | | \mathbf { g _ { 2 } } | | ^ { 2 } - { \frac { \left( \mathbf { g _ { 1 } } \cdot \mathbf { g _ { 2 } } \right) } { | | \mathbf { g _ { 1 } } | | ^ { 2 } } } - { \frac { \left( \mathbf { g _ { 1 } } \cdot \mathbf { g _ { 2 } } \right) } { | | \mathbf { g _ { 2 } } | | ^ { 2 } } } ) } \\ { = { \mathcal { L } } t ^ { 2 } ( \mathbf { g _ { 1 } } \cdot \mathbf { g _ { 2 } } - { \frac { \left( \mathbf { g _ { 1 } } \cdot \mathbf { g _ { 2 } } \right) ^ { 2 } } { | | \mathbf { g _ { 1 } } | | ^ { 2 } | | \mathbf { g _ { 2 } } | | ^ { 2 } } } \mathbf { g _ { 1 } } \cdot \mathbf { g _ { 2 } } ) } \end{array} }
335
+ $$
336
+
337
+ (Using the identity $\cos ( \phi ) = { \frac { \mathbf { g _ { 1 } } \cdot \mathbf { g _ { 2 } } } { | | \mathbf { g _ { 1 } } | | | | \mathbf { g _ { 2 } } | | } } )$
338
+
339
+ $$
340
+ \begin{array} { l } { { \displaystyle = \mathcal { L } ( \theta ) - ( t - \frac { 1 } { 2 } L t ^ { 2 } ) [ ( 1 - \cos ^ { 2 } ( \phi ) ) | | { \bf g _ { 1 } } | ] ^ { 2 } + ( 1 - \cos ^ { 2 } ( \phi ) ) | | { \bf g _ { 2 } } | | ^ { 2 } } \} } \\ { { \displaystyle - \left. L t ^ { 2 } ( 1 - \cos ^ { 2 } ( \phi ) ) | | { \bf g _ { 1 } } | | | { \bf g _ { 2 } } | | \cos ( \phi ) \right. } } \end{array}
341
+ $$
342
+
343
+ (Note that $\cos ( \phi ) < 0$ so the final term is non-negative)
344
+
345
+ Using $\begin{array} { r } { t \le \frac { 1 } { L } } \end{array}$ , we know that $\begin{array} { r } { - ( 1 - \frac 1 2 L t ) = \frac 1 2 L t - 1 \le \frac 1 2 L ( 1 / L ) - 1 = \frac { - 1 } { 2 } } \end{array}$ and $L t ^ { 2 } \leq t$
346
+
347
+ Plugging this into the last expression above, we can conclude the following:
348
+
349
+ $$
350
+ \begin{array} { l } { \displaystyle \mathcal { L } ( \boldsymbol { \theta } ^ { + } ) \leq \mathcal { L } ( \boldsymbol { \theta } ) - \frac { 1 } { 2 } t [ ( 1 - \cos ^ { 2 } ( \boldsymbol { \phi } ) ) | | \mathbf { g } _ { 1 } | ] ^ { 2 } + ( 1 - \cos ^ { 2 } ( \boldsymbol { \phi } ) ) | | \mathbf { g } _ { 2 } | ] ^ { 2 } ] } \\ { \displaystyle - t ( 1 - \cos ^ { 2 } ( \boldsymbol { \phi } ) ) | | \mathbf { g } _ { 1 } | | | | \mathbf { g } _ { 2 } | | \cos ( \boldsymbol { \phi } ) } \\ { \displaystyle = \mathcal { L } ( \boldsymbol { \theta } ) - \frac { 1 } { 2 } t ( 1 - \cos ^ { 2 } ( \boldsymbol { \phi } ) ) | | | \mathbf { g } _ { 1 } | | ^ { 2 } + 2 | | \mathbf { g } _ { 1 } | | | | \mathbf { g } _ { 2 } | | \cos ( \boldsymbol { \phi } ) + | | \mathbf { g } _ { 2 } | | ^ { 2 } ] } \\ { \displaystyle = \mathcal { L } ( \boldsymbol { \theta } ) - \frac { 1 } { 2 } t ( 1 - \cos ^ { 2 } ( \boldsymbol { \phi } ) ) [ | | \mathbf { g } _ { 1 } | | ^ { 2 } + 2 \mathbf { g } _ { 1 } \cdot \mathbf { g } _ { 2 } + | | \mathbf { g } _ { 2 } | | ^ { 2 } ] } \\ { \displaystyle = \mathcal { L } ( \boldsymbol { \theta } ) - \frac { 1 } { 2 } t ( 1 - \cos ^ { 2 } ( \boldsymbol { \phi } ) ) | | \mathbf { g } _ { 1 } + \mathbf { g } _ { 2 } | | ^ { 2 } } \\ { \displaystyle = \mathcal { L } ( \boldsymbol { \theta } ) - \frac { 1 } { 2 } t ( 1 - \cos ^ { 2 } ( \boldsymbol { \phi } ) ) | | \nabla \mathcal { L } ( \boldsymbol { \theta } ) | | ^ { 2 } } \end{array}
351
+ $$
352
+
353
+ If $\cos ( \phi ) > - 1$ , then $\begin{array} { r l } { { \frac { 1 } { 2 } t ( 1 - \cos ^ { 2 } ( \phi ) ) \| \nabla \mathcal { L } ( \theta ) \| ^ { 2 } } } \end{array}$ will always be positive unless $\nabla { \mathcal { L } } ( \theta ) = 0$ . This inequality implies that the objective function value strictly decreases with each iteration where $\cos ( \phi ) > - 1$ .
354
+
355
+ Hence repeatedly applying PCGrad process can either reach the optimal value ${ \mathcal { L } } ( \theta ) = { \mathcal { L } } ( \theta ^ { * } )$ or $\cos ( \phi ) = - 1$ , in which case $\begin{array} { r } { \frac { 1 } { 2 } t ( 1 - \bar { \cos ^ { 2 } ( \phi ) } ) \| \nabla \mathcal { L } ( \theta ) \| ^ { 2 } = 0 , } \end{array}$ . Note that this result only holds when we choose $t$ to be small enough, i.e. $\begin{array} { r } { t \le \frac { 1 } { L } } \end{array}$ .
356
+
357
+ # B 2D OPTIMIZATION LANDSCAPE DETAILS
358
+
359
+ To produce the 2D optimization visualizations in Figure 1, we used a parameter vector $\theta = \left[ \theta _ { 1 } , \theta _ { 2 } \right] \in$ $\mathbb { R } ^ { 2 }$ and the following task loss functions:
360
+
361
+ $$
362
+ \begin{array} { r l } & { \mathcal { L } _ { 1 } ( \theta ) = 2 0 \log ( \operatorname* { m a x } ( | . 5 \theta _ { 1 } + \operatorname { t a n h } ( \theta _ { 2 } ) | , 0 . 0 0 0 0 0 5 ) ) } \\ & { \mathcal { L } _ { 2 } ( \theta ) = 2 5 \log ( \operatorname* { m a x } ( | . 5 \theta _ { 1 } - \operatorname { t a n h } ( \theta _ { 2 } ) + 2 | , 0 . 0 0 0 0 0 5 ) ) } \end{array}
363
+ $$
364
+
365
+ The multi-task objective is $\mathcal { L } ( \theta ) = \mathcal { L } _ { 1 } ( \theta ) + \mathcal { L } _ { 2 } ( \theta )$ . We initialized $\theta = [ 0 . 5 , - 3 ]$ and performed 500,000 gradient updates to minimize $\mathcal { L }$ using the Adam optimizer with learning rate 0.001. We compared using Adam for each update to using Adam in conjunction with the PCGrad method presented in Section 3.2.
366
+
367
+ # C EXPERIMENTAL RESULTS ON MULTIMNIST
368
+
369
+ Following the same set-up in Sener & Koltun (2018), for each image, we sample a different one uniformly at random. Then we put one of the image on the top left and the other one on the bottom right. The two tasks in the multi-task learning problem are to classify the digits on the top left (task-L) and bottom right (task-R) respectively. We construct such $6 0 \mathrm { K }$ examples. We combine PCGrad with the same backbone architecture used in (Sener & Koltun, 2018) and compare its performance to Sener & Koltun (2018) by running the open-sourced code provided in (Sener & Koltun, 2018). As shown in Table 3, our method results $0 . 1 3 \%$ and $0 . 5 5 \%$ improvement over Sener & Koltun (2018) in left and right digit accuracy respectively.
370
+
371
+ <table><tr><td></td><td>left digit</td><td>right digit</td></tr><tr><td>Sener &amp; Koltun (2018)</td><td>96.45</td><td>94.95</td></tr><tr><td>PCGrad (ours)</td><td>96.58</td><td>95.50</td></tr></table>
372
+
373
+ Table 3: MultiMNIST results. PCGrad achieves improvements over Sener & Koltun (2018) in both left and right digit classfication accuracy.
374
+
375
+ # D ABLATION STUDY ON THE TASK ORDER
376
+
377
+ As stated on line 4 in Algorithm 1, we sample the tasks from the batch and randomly shuffle the order of the tasks before performing the update steps in PCGrad. With random shuffling, we make
378
+
379
+ PCGrad symmetric w.r.t. the task order in expectation. In Figure 7, we observe that PCGrad with a random task order achieves better performance between PCGrad with a fixed task order in the setting of MT50 where the number of tasks is large and the conflicting gradient phenomenon is much more likely to happen.
380
+
381
+ ![](images/807b5fd27120d7c92f596dd5dff23d51259e68ce83646668c231b41e2475cb34.jpg)
382
+ Figure 7: Ablation study on using a fixed task order during PCGrad. PCGrad with a random task order does significantly better PCGrad with a fixed task order in MT50 benchmark.
383
+
384
+ # E EXPERIMENT DETAILS
385
+
386
+ E.1 DETAILED EXPERIMENT SET-UP
387
+
388
+ For our CIFAR-100 multi-task experiment, we adopt the architecture used in Rosenbaum et al. (2019), which is a convolutional neural network that consists of 3 convolutional layers with $1 6 0 3 \times 3$ filters each layer and 2 fully connected layers with 320 hidden units. As for experiments on the NYUv2 dataset, we follow Liu et al. (2018) to use SegNet (Badrinarayanan et al., 2017) as the backbone architecture.
389
+
390
+ Our reinforcement learning experiments all use the SAC (Haarnoja et al., 2018) algorithm as the base algorithm, where the actor and the critic are represented as 6-layer fully-connected feedforward neural networks for all methods. The numbers of hidden units of each layer of the neural networks are 160, 300 and 200 for MT10, MT50 and goal-conditioned RL respectively.
391
+
392
+ We use five algorithms as baselines in the CIFAR-100 multi-task experiment: task specific-1-fc (Rosenbaum et al., 2018): a convolutional neural network shared across tasks except that each task has a separate last fully-connected layer, task specific-1-fc (Rosenbaum et al., 2018) : all the convolutional layers shared across tasks with separate fully-connected layers for each task, cross stitch-all-fc (Misra et al., 2016b): one convolutional neural network per task along with cross-stitch units to share features across tasks, routing-all-fc ${ \bf \Pi } _ { \bf { \Pi } } + { \bf W } { \bf P } { \bf L }$ (Rosenbaum et al., 2019): a network that employs a trainable router trained with multi-agent RL algorithm (WPL) to select trainable functions for each task, independent: training separate neural networks for each task.
393
+
394
+ For comparisons on the NYUv2 dataset, we consider 5 baselines: Single Task, One Task: the vanilla SegNet used for single-task training, Single Task, STAN (Liu et al., 2018): the single-task version of MTAN as mentioned below, Multi-Task, Split, Wide / Deep (Liu et al., 2018): the standard SegNet shared for all three tasks except that each task has a separate last layer for final task-specific prediction with two variants Wide and Deep specified in Liu et al. (2018), Multi-Task Dense: a shared network followed by separate task-specific networks, Multi-Task Cross-Stitch (Misra et al., 2016b): similar to the baseline used in CIFAR-100 experiment but with SegNet as the backbone, MTAN (Liu et al., 2018): a shared network with a soft-attention module for each task.
395
+
396
+ On the multi-task and goal-conditioned RL domain, we apply PCGrad to the vanilla SAC algorithm with task encoding as part of the input to the actor and the critic as described in Section 4 and compare our method to the vanilla SAC without PCGrad and training actors and critics for each task individually (Independent).
397
+
398
+ # E.2 GOAL-CONDITIONED EXPERIMENT DETAILS
399
+
400
+ We use the pushing environment from the Meta-World benchmark (Yu et al., 2019) as shown in Figure 3. In this environment, the table spans from $[ - 0 . 4 , 0 . 2 ]$ to [0.4, 1.0] in the 2D space. To construct the goals, we sample the intial positions of the puck from the range $[ - 0 . 2 , 0 . 6 ]$ to [0.2, 0.7] on the table and the goal positions from the range $[ - 0 . 2 , 0 . 8 5 ]$ to $[ 0 . 2 , 0 . 9 5 ]$ on the table. The goal is represented as a concatenation of the initial puck position and the goal position. Since in the goal-conditioned setting, the task distribution is continuous, we sample a minibatch of 9 goals and 128 samples per goal at each training iteration and also sample 600 samples per goal in the minibatch at each data collection step.
401
+
402
+ # E.3 FULL NYUV2 RESULTS
403
+
404
+ We provide the full comparison on the NYUv2 dataset in Table 4.
405
+
406
+ <table><tr><td rowspan="2">Type</td><td rowspan="2">#P.</td><td rowspan="2">Architecture Weighting</td><td colspan="2">Segmentation</td><td colspan="2">Depth</td><td colspan="5">Surface Normal</td></tr><tr><td colspan="2">mIoU Pix Acc Abs Err Rel Err</td><td colspan="2">(Higher Better) (Lower Better)</td><td colspan="2">Angle Distance (Lower Better) Mean Median</td><td colspan="2">Within t (Higher Better) 11.2522.5</td></tr><tr><td rowspan="2">Single Task</td><td>3 One Task</td><td></td><td></td><td>15.10 51.54</td><td></td><td>0.7508 0.3266</td><td>531.76</td><td>25.51</td><td></td><td>22.12 45.33</td><td>30 57.13</td></tr><tr><td>4.56 STANt</td><td>n.a. n.a.</td><td>15.73</td><td>52.89</td><td>0.6935</td><td>0.2891</td><td>32.09</td><td>26.32</td><td>21.49</td><td>44.38</td><td>56.51</td></tr><tr><td rowspan="9">Multi Task</td><td rowspan="3">1.75 Split, Wide</td><td>Equal Weights</td><td>15.89</td><td>51.19</td><td>0.6494</td><td>0.2804</td><td>33.69</td><td>28.91</td><td>18.54</td><td>39.91</td><td>52.02</td></tr><tr><td>Uncert.Weights*</td><td>15.86</td><td>51.12</td><td>0.6040</td><td>0.2570</td><td>32.33</td><td>26.62</td><td>21.68</td><td>43.59</td><td>55.36</td></tr><tr><td>DWA+,T=2</td><td>16.92</td><td>53.72</td><td>0.6125</td><td>0.2546</td><td>32.34</td><td>27.10</td><td>20.69</td><td>42.73</td><td>54.74</td></tr><tr><td rowspan="3">2Split, Deep</td><td>Equal Weights</td><td>13.03</td><td>41.47</td><td>0.7836</td><td>0.3326</td><td>38.28</td><td>36.55</td><td>9.50</td><td>27.11</td><td>39.63</td></tr><tr><td>Uncert.Weights*</td><td>14.53</td><td>43.69</td><td>0.7705</td><td>0.3340</td><td>35.14</td><td>32.13</td><td>14.69</td><td>34.52</td><td>46.94</td></tr><tr><td>DWA+,T= 2</td><td>13.63</td><td>44.41</td><td>0.7581</td><td>0.3227</td><td>36.41</td><td>34.12</td><td>12.82</td><td>31.12</td><td>43.48</td></tr><tr><td rowspan="3">4.95 Dense</td><td>Equal Weights</td><td>16.06</td><td>52.73</td><td>0.6488</td><td>0.2871</td><td>33.58</td><td>28.01</td><td>20.07</td><td>41.50</td><td>53.35</td></tr><tr><td>Uncert.Weights*</td><td>16.48</td><td>54.40</td><td>0.6282</td><td>0.2761</td><td>31.68</td><td>25.68</td><td>21.73</td><td>44.58</td><td>56.65</td></tr><tr><td>DWAt,T = 2</td><td>16.15</td><td>54.35</td><td>0.6059</td><td>0.2593</td><td>32.44</td><td>27.40</td><td>20.53</td><td>42.76</td><td>54.27</td></tr><tr><td rowspan="3">≈3 Cross-Stitcht</td><td>Equal Weights</td><td>14.71 15.69</td><td>50.23</td><td>0.6481</td><td>0.2871</td><td>33.56</td><td>28.58</td><td></td><td>20.08 40.54</td><td></td><td>51.97</td></tr><tr><td></td><td>Uncert. Weights*</td><td>52.60</td><td>0.6277</td><td>0.2702</td><td>32.69</td><td></td><td>27.26</td><td>21.63 21.81</td><td>42.84</td><td>54.45 54.92</td></tr><tr><td>DWA+,T= 2</td><td>16.11</td><td>53.19</td><td>0.5922</td><td>0.2611</td><td>32.34</td><td>26.91</td><td></td><td>43.14</td><td></td></tr><tr><td rowspan="3">1.77 MTANt</td><td></td><td>Equal Weights 17.72</td><td>55.32</td><td>0.5906</td><td>0.2577</td><td></td><td>31.44</td><td>25.37</td><td>23.17</td><td>45.65</td><td>57.48</td></tr><tr><td>Uncert.Weights*</td><td>17.67</td><td>55.61</td><td>0.5927</td><td>0.2592</td><td>31.25</td><td></td><td>25.57</td><td>22.99</td><td>45.83</td><td>57.67</td></tr><tr><td>DWAt,T=2</td><td>17.15</td><td>54.97</td><td>0.5956</td><td>0.2569</td><td>31.60</td><td>25.46</td><td></td><td>22.48 44.86</td><td></td><td>57.24</td></tr></table>
407
+
408
+ Table 4: We present the full results on three tasks on the NYUv2 dataset: 13-class semantic segmentation, depth estimation, and surface normal prediction results. #P shows the total number of network parameters. We highlight the best performing combination of multi-task architecture and weighting in bold. The top validation scores for each task are annotated with boxes. The symbols indicate prior methods: ∗: (Kendall et al., 2018a), †: (Liu et al., 2018), $^ \ddag$ : (Misra et al., 2016b). Performance of other methods taken from (Liu et al., 2018).
parse/train/HJewiCVFPB/HJewiCVFPB_middle.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/Hkl1iRNFwS/Hkl1iRNFwS.md ADDED
@@ -0,0 +1,257 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # THE EARLY PHASE OF NEURAL NETWORK TRAINING
2
+
3
+ Jonathan Frankle† MIT CSAIL
4
+
5
+ David J. Schwab CUNY ITS Facebook AI Research
6
+
7
+ Ari S. Morcos Facebook AI Research
8
+
9
+ # ABSTRACT
10
+
11
+ Recent studies have shown that many important aspects of neural network learning take place within the very earliest iterations or epochs of training. For example, sparse, trainable sub-networks emerge (Frankle et al., 2019), gradient descent moves into a small subspace (Gur-Ari et al., 2018), and the network undergoes a critical period (Achille et al., 2019). Here we examine the changes that deep neural networks undergo during this early phase of training. We perform extensive measurements of the network state during these early iterations of training and leverage the framework of Frankle et al. (2019) to quantitatively probe the weight distribution and its reliance on various aspects of the dataset. We find that, within this framework, deep networks are not robust to reinitializing with random weights while maintaining signs, and that weight distributions are highly non-independent even after only a few hundred iterations. Despite this behavior, pre-training with blurred inputs or an auxiliary self-supervised task can approximate the changes in supervised networks, suggesting that these changes are not inherently label-dependent, though labels significantly accelerate this process. Together, these results help to elucidate the network changes occurring during this pivotal initial period of learning.
12
+
13
+ # 1 INTRODUCTION
14
+
15
+ Over the past decade, methods for successfully training big, deep neural networks have revolutionized machine learning. Yet surprisingly, the underlying reasons for the success of these approaches remain poorly understood, despite remarkable empirical performance (Santurkar et al., 2018; Zhang et al., 2017). A large body of work has focused on understanding what happens during the later stages of training (Neyshabur et al., 2019; Yaida, 2019; Chaudhuri & Soatto, 2017; Wei & Schwab, 2019), while the initial phase has been less explored. However, a number of distinct observations indicate that significant and consequential changes are occurring during the most early stage of training. These include the presence of critical periods during training (Achille et al., 2019), the dramatic reshaping of the local loss landscape (Sagun et al., 2017; Gur-Ari et al., 2018), and the necessity of rewinding in the context of the lottery ticket hypothesis (Frankle et al., 2019). Here we perform a thorough investigation of the state of the network in this early stage.
16
+
17
+ To provide a unified framework for understanding the changes the network undergoes during the early phase, we employ the methodology of iterative magnitude pruning with rewinding (IMP), as detailed below, throughout the bulk of this work (Frankle & Carbin, 2019; Frankle et al., 2019). The initial lottery ticket hypothesis, which was validated on comparatively small networks, proposed that small, sparse sub-networks found via pruning of converged larger models could be trained to high performance provided they were initialized with the same values used in the training of the unpruned model (Frankle & Carbin, 2019). However, follow-up work found that rewinding the weights to their values at some iteration early in the training of the unpruned model, rather than to their initial values, was necessary to achieve good performance on deeper networks such as ResNets (Frankle et al., 2019). This observation suggests that the changes in the network during this initial phase are vital for the success of the training of small, sparse sub-networks. As a result, this paradigm provides a simple and quantitative scheme for measuring the importance of the weights at various points early in training within an actionable and causal framework.
18
+
19
+ We make the following contributions, all evaluated across three different network architectures:
20
+
21
+ 1. We provide an in-depth overview of various statistics summarizing learning over the early part of training.
22
+ 2. We evaluate the impact of perturbing the state of the network in various ways during the early phase of training, finding that: (i) counter to observations in smaller networks (Zhou et al., 2019), deeper networks are not robust to reinitializion with random weights, but maintained signs (ii) the distribution of weights after the early phase of training is already highly non-i.i.d., as permuting them dramatically harms performance, even when signs are maintained (iii) both of the above perturbations can roughly be approximated by simply adding noise to the network weights, though this effect is stronger for (ii) than (i)
23
+
24
+ 3. We measure the data-dependence of the early phase of training, finding that pre-training using only $p ( x )$ can approximate the changes that occur in the early phase of training, though pre-training must last for far longer ${ \sim } 3 2 \times$ longer) and not be fed misleading labels.
25
+
26
+ # 2 KNOWN PHENOMENA IN THE EARLY PHASE OF TRAINING
27
+
28
+ Lottery ticket rewinding: The original lottery ticket paper (Frankle & Carbin, 2019) rewound weights to initialization, i.e., $k ~ = ~ 0$ , during IMP. Follow up work on larger models demonstrated that it is necessary to rewind to a later point during training for IMP to succeed, i.e., $k \ < < \ T$ , where $T$ is total training iterations (Frankle et al., 2019). Notably, the benefit of rewinding to a later point in training saturates quickly, roughly between 500 and 2000 iterations for ResNet-20 on CIFAR-10 (Figure 1). This timescale is strikingly similar to the changes in the Hessian described below.
29
+
30
+ Hessian eigenspectrum: The shape of the loss landscape around the network state also appears
31
+
32
+ ![](images/8c4ca4d2642f445b29e873fc950bbc21f6cd35aa36fbbe51f69c185df46c53ba.jpg)
33
+ Figure 1: Accuracy of IMP when rewinding to various iterations of the early phase for ResNet20 sub-networks as a function of sparsity level.
34
+
35
+ to change rapidly during the early phase of training (Sagun et al., 2017; Gur-Ari et al., 2018). At initialization, the Hessian of the loss contains a number of large positive and negative eigenvalues. However, very rapidly the curvature is reshaped in a few marked ways: a few large eigenvalues emerge, the bulk eigenvalues are close to zero, and the negative eigenvalues become very small. Moreover, once the Hessian spectrum has reshaped, gradient descent appears to occur largely within the top subspace of the Hessian (Gur-Ari et al., 2018). These results have been largely confirmed in large scale studies (Ghorbani et al., 2019), but note they depend to some extent on architecture and (absence of) batch normalization (Ioffe & Szegedy, 2015). A notable exception to this consistency is the presence of substantial $L _ { 1 }$ energy of negative eigenvalues for models trained on ImageNet.
36
+
37
+ Critical periods in deep learning: Achille et al. (2019) found that perturbing the training process by providing corrupted data early on in training can result in irrevocable damage to the final performance of the network. Note that the timescales over which the authors find a critical period extend well beyond those we study here. However, architecture, learning rate schedule, and regularization all modify the timing of the critical period, and follow-up work found that critical periods were also present for regularization, in particular weight decay and data augmentation (Golatkar et al., 2019).
38
+
39
+ # 3 PRELIMINARIES AND METHODOLOGY
40
+
41
+ Networks: Throughout this paper, we study five standard convolutional neural networks for CIFAR-10. These include the ResNet-20 and ResNet-56 architectures designed for CIFAR-10 (He et al., 2015), the ResNet-18 architecture designed for ImageNet but commonly used on CIFAR-10 (He et al., 2015), the WRN-16-8 wide residual network (Zagoruyko & Komodakis, 2016), and the
42
+
43
+ ![](images/bbc021b67f4758bf1ffddd590865638abb4a0901c8374f61644c3639d1985c0a.jpg)
44
+ Figure 2: Rough timeline of the early phase of training for ResNet-20 on CIFAR-10.
45
+
46
+ VGG-13 network (Simonyan & Zisserman (2015) as adapted by Liu et al. (2019)). Throughout the main body of the paper, we show ResNet-20; in Appendix B, we present the same experiments for the other networks. Unless otherwise stated, results were qualitatively similar across all three networks. All experiments in this paper display the mean and standard deviation across five replicates with different random seeds. See Appendix A for further model details.
47
+
48
+ Iterative magnitude pruning with rewinding: In order to test the effect of various hypotheses about the state of sparse networks early in training, we use the Iterative Magnitude Pruning with rewinding (IMP) procedure of Frankle et al. (2019) to extract sub-networks from various points in training that could have learned on their own. The procedure involves training a network to completion, pruning the $20 \%$ of weights with the lowest magnitudes globally throughout the network, and rewinding the remaining weights to their values from an earlier iteration $k$ during the initial, pre-pruning training run. This process is iterated to produce networks with high sparsity levels. As demonstrated in Frankle et al. (2019), IMP with rewinding leads to sparse sub-networks which can train to high performance even at high sparsity levels $> 9 0 \%$ .
49
+
50
+ Figure 1 shows the results of the IMP with rewinding procedure, showing the accuracy of ResNet20 at increasing sparsity when performing this procedure for several rewinding values of $k$ . For $k \geq 5 0 0$ , sub-networks can match the performance of the original network with $1 6 . 8 \%$ of weights remaining. For $k > 2 0 0 0$ , essentially no further improvement is observed (not shown).
51
+
52
+ # 4 THE STATE OF THE NETWORK EARLY IN TRAINING
53
+
54
+ Many of the aforementioned papers refer to various points in the “early” part of training. In this section, we descriptively chart the state of ResNet-20 during the earliest phase of training to provide context for this related work and our subsequent experiments. We specifically focus on the first 4,000 iterations (10 epochs). See Figure A3 for the characterization of additional networks. We include a summary of these results for ResNet-20 as a timeline in Figure 2, and include a broader timeline including results from several previous papers for ResNet-18 in Figure A1.
55
+
56
+ As shown in Figure 3, during the earliest ten iterations, the network undergoes substantial change. It experiences large gradients that correspond to a rapid increase in distance from the initialization and a large number of sign changes of the weights. After these initial iterations, gradient magnitudes drop and the rate of change in each of the aforementioned quantities gradually slows through the remainder of the period we observe. Interestingly, gradient magnitudes reach a minimum after the first 200 iterations and subsequently increase to a stable level by iteration 500. Evaluation accuracy, improves rapidly, reaching $55 \%$ by the end of the first epoch (400 iterations), more than halfway to the final $9 1 . 5 \%$ . By 2000 iterations, accuracy approaches $80 \%$ .
57
+
58
+ During the first 4000 iterations of training, we observe three sub-phases. In the first phase, lasting only the initial few iterations, gradient magnitudes are very large and, consequently, the network changes rapidly. In the second phase, lasting about 500 iterations, performance quickly improves, weight magnitudes quickly increase, sign differences from initialization quickly increase, and gradient magnitudes reach a minimum before settling at a stable level. Finally, in the third phase, all of these quantities continue to change in the same direction, but begin to decelerate.
59
+
60
+ ![](images/536f691a12fa237fb72a5290ddf148134e074daf7b9eb9951f39a422f822647b.jpg)
61
+ Figure 3: Basic telemetry about the state of ResNet-20 during the first 4000 iterations (10 epochs). Top row: evaluation accuracy/loss; average weight magnitude; percentage of weights that change sign from initialization; the values of ten randomly-selected weights. Bottom row: gradient magnitude; L2 distance of weights from their initial values and final values at the end of training; cosine similarity of weights from their initial values and final values at the end of training.
62
+
63
+ ![](images/9b938cd5121d512198fefd1d83a99771476d10b7fe225ff94604b45fa851893d.jpg)
64
+ Figure 4: Performance of an IMP-derived sub-network of ResNet-20 on CIFAR-10 initialized to the signs at iteration 0 or $k$ and the magnitudes at iteration 0 or $k$ . Left: $k = 5 0 0$ . Right: $k = 2 0 0 0$ .
65
+
66
+ # 5 PERTURBING NEURAL NETWORKS EARLY IN TRAINING
67
+
68
+ Figure 1 shows that the changes in the network weights over the first 500 iterations of training are essential to enable high performance at high sparsity levels. What features of this weight transformation are necessary to recover increased performance? Can they be summarized by maintaining the weight signs, but discarding their magnitudes as implied by Zhou et al. (2019)? Can they be represented distributionally? In this section, we evaluate these questions by perturbing the early state of the network in various ways. Concretely, we either add noise or shuffle the weights of IMP sub-networks of ResNet-20 across different network sub-compenents and examine the effect on the network’s ability to learn thereafter. The sub-networks derived by IMP with rewinding make it possible to understand the causal impact of perturbations on sub-networks that are as capable as the full networks but more visibly decline in performance when improperly configured. To enable comparisons between the experiments in Section 5 and provide a common frame of reference, we measure the effective standard deviation of each perturbation, i.e. stddev $( w _ { p e r t u r b } - w _ { o r i g } )$ .
69
+
70
+ # 5.1 ARE SIGNS ALL YOU NEED?
71
+
72
+ Zhou et al. (2019) show that, for a set of small convolutional networks, signs alone are sufficient to capture the state of lottery ticket sub-networks. However, it is unclear whether signs are still sufficient for larger networks early in training. In Figure 4, we investigate the impact of combining the magnitudes of the weights from one time-point with the signs from another. We found that the signs at iteration 500 paired with the magnitudes from initialization (red line) or from a separate random initialization (green line) were insufficient to maintain the performance reached by using both signs and magnitudes from iteration 500 (orange line), and performance drops to that of using both magnitudes and signs from initialization (blue line). However, while using the magnitudes from iteration 500 and the signs from initialization, performance is still substantially better than initialization signs and magnitudes. In addition, the overall perturbation to the network by using the magnitudes at iteration 500 and signs from initialization (mean: 0.0, stddev: 0.033) is smaller than by using the signs at iteration 500 and the magnitudes from initialization $( 0 . 0 \pm 0 . 0 4 2$ , mean $\pm$ std). These results suggest that the change in weight magnitudes over the first 500 iterations of training are substantially more important than the change in the signs for enabling subsequent training.
73
+
74
+ ![](images/8047cf2a48a2e5be51317667d22db2c6655703fd386a19e3004bc37d3bf38ab8.jpg)
75
+ Figure 5: Performance of an IMP-derived ResNet-20 sub-network on CIFAR-10 initialized with the weights at iteration $k$ permuted within various structural elements. Left: $k = 5 0 0$ . Right: $k = 2 0 0 0$ .
76
+
77
+ ![](images/8df733a2ecf858a504a521a4c2ece79ef9ff72c54a282b564ce7001e5b6fa5fd.jpg)
78
+ Figure 6: The effect of training an IMP-derived sub-network of ResNet-20 on CIFAR-10 initialized with the weights at iteration $k$ as shuffled within various structural elements where shuffling only occurs between weights with the same sign. Left: $k = 5 0 0$ . Right: $k = 2 0 0 0$ .
79
+
80
+ By iteration 2000, however, pairing the iteration 2000 signs with magnitudes from initialization (red line) reaches similar performance to using the signs from initialization and the magnitudes from iteration 2000 (purple line) though not as high performance as using both from iteration 2000. This result suggests that network signs undergo important changes between iterations 500 and 2000, as only $9 \%$ of signs change during this period. Our results also suggest that counter to the observations of Zhou et al. (2019) in shallow networks, signs are not sufficient in deeper networks.
81
+
82
+ # 5.2 ARE WEIGHT DISTRIBUTIONS I.I.D.?
83
+
84
+ Can the changes in weights over the first $k$ iterations be approximated distributionally? To measure this, we permuted the weights at iteration $k$ within various structural sub-components of the network (globally, within layers, and within convolutional filters). If networks are robust to these permutations, it would suggest that the weights in such sub-compenents might be approximated and sampled from. As Figure 5 shows, however, we found that performance was not robust to shuffling weights globally (green line) or within layers (red line), and drops substantially to no better than that of the original initialization (blue line) at both 500 and 2000 iterations.1 Shuffling within filters (purple line) performs slightly better, but results in a smaller overall perturbation $( 0 . 0 \pm 0 . 0 9 2$ for $k = 5 0 0$ ) than shuffling layerwise $( 0 . 0 { \pm } 0 . 1 4 3 )$ or globally $( 0 . 0 { \pm } 0 . 1 4 4 )$ , suggesting that this change in perturbation strength may simply account for the difference.
85
+
86
+ ![](images/d765cebe2c186de4c5b3ee8cc5eadc7096326e5470eaf14de37b6bd970c9d02d.jpg)
87
+ Figure 7: The effect of training an IMP-derived sub-network of ResNet-20 on CIFAR-10 initialized with the weights at iteration $k$ and Gaussian noise of $n \sigma$ , where $\sigma$ is the standard deviation of the initialization distribution for each layer. Left: $k = 5 0 0$ . Right: $k = 2 0 0 0$ .
88
+
89
+ Are the signs from the rewinding iteration, $k$ , sufficient to recover the damage caused by permutation? In Figure 6, we also consider shuffling only amongst weights that have the same sign. Doing so substantially improves the performance of the filter-wise shuffle; however, it also reduces the extent of the overall perturbation $( 0 . 0 \pm 0 . 0 4 9$ for $k = 5 0 0$ ). It also improves the performance of shuffling within layers slightly for $k = 5 0 0$ and substantially for $k = 2 0 0 0$ . We attribute the behavior for $k = 2 0 0 0$ to the signs just as in Figure 4: when the magnitudes are similar in value (Figure 4 red line) or distribution (Figure 6 red and green lines), using the signs improves performance. Reverting back to the initial signs while shuffling magnitudes within layers (brown line), however, damages the network too severely $( 0 . 0 \pm 0 . 0 8 7$ for $k = 5 0 0 \mathrm { \AA }$ ) to yield any performance improvement over random noise. These results suggest that, while the signs from initialization are not sufficient for high performance at high sparsity as shown in Section 5.1, the signs from the rewinding iteration are sufficient to recover the damage caused by permutation, at least to some extent.
90
+
91
+ # 5.3 IS IT ALL JUST NOISE?
92
+
93
+ Some of our previous results suggested that the impact of signs and permutations may simply reduce to adding noise to the weights. To evaluate this hypothesis, we next study the effect of simply adding Gaussian noise to the network weights at iteration $k$ . To add noise appropriately for layers with different scales, the standard deviation of the noise added for each layer was normalized to a multiple of the standard deviation $\sigma$ of the initialization distribution for that layer. In Figure 7, we see that for iteration $k = 5 0 0$ , sub-networks can tolerate $0 . 5 \sigma$ to $1 \sigma$ of noise before performance degrades back to that of the original initialization at higher levels of noise. For iteration $k = 2 0 0 0$ , networks are surprisingly robust to noise up to $1 \sigma$ , and even $2 \sigma$ exhibits nontrivial performance.
94
+
95
+ In Figure 8, we plot the performance of each network at a fixed sparsity level as a function of the effective standard deviation of the noise imposed by each of the aforementioned perturbations. We find that the standard deviation of the effective noise explained fairly well the resultant performance $k = 5 0 0$ : $r = - 0 . 6 7 2$ , $p = 0 . 0 0 8$ ; $k = 2 0 0 0$ : $r = - 0 . 7 2 6$ , $p = 0 . 0 0 3 )$ . As expected, perturbations that preserved the performance of the network generally resulted in smaller changes to the state of the network at iteration $k$ . Interestingly, experiments that mixed signs and magnitudes from different points in training (green points) aligned least well with this pattern: the standard deviation of the perturbation is roughly similar among all of these experiments, but the accuracy of the resulting networks changes substantially. This result suggests that although the standard deviation of the noise is certainly indicative of lower accuracy, there are still specific perturbations that, while small in overall magnitude, can have a large effect on the network’s ability to learn, suggesting that the observed perturbation effects are not, in fact, just a consequence of noise.
96
+
97
+ # 6 THE DATA-DEPENDENCE OF NEURAL NETWORKS EARLY IN TRAINING
98
+
99
+ Section 5 suggests that the change in network behavior by iteration $k$ is not due to easilyascertainable, distributional properties of the network weights and signs. Rather, it appears that training is required to reach these network states. It is unclear, however, the extent to which various aspects of the data distribution are necessary. Mainly, is the change in weights during the early phase of training dependent on $p ( x )$ or $p ( y | \dot { x } ) \dot { }$ ? Here, we attempt to answer this question by measuring the extent to which we can re-create a favorable network state for sub-network training using restricted information from the training data and labels. In particular, we consider pre-training the network with techniques that ignore labels entirely (self-supervised rotation prediction, Section 6.2), provide misleading labels (training with random labels, Section 6.1), or eliminate information from examples (blurring training examples Section 6.3).
100
+
101
+ ![](images/f475c2671eb155c5f5bfa3ab2df77732fada8935c1ae32dfdf549d2039aa9131.jpg)
102
+ Figure 8: The effective standard deviation of various perturbations as a function of mean evaluation accuracy (across 5 seeds) at sparsity $2 6 . 2 \%$ . The mean of each perturbation was approximately 0. Left: $k = 5 0 0$ , $r = - 0 . 6 7 2$ , $p = 0 . 0 0 8$ ; Right: $k = 2 0 0 0$ , $r = - 0 . 7 2 6$ , $p = 0 . 0 0 3$ .
103
+
104
+ ![](images/8715684b756ced9cf2ac21b60d181576c6c05b8ece9df66ac1df49bf882960a3.jpg)
105
+ Figure 9: The effect of pre-training ResNet-20 on CIFAR-10 with random labels, self-supervised rotation, $4 \mathbf { x }$ blurring, and $4 \mathbf { x }$ blurring and self-supervised rotation.
106
+
107
+ We first train a randomly-initialized, unpruned network on CIFAR-10 on the pre-training task for a set number of epochs. After pre-training, we train the network normally as if the pre-trained state were the original initialization. We then use the state of the network at the end of the pre-training phase as the “initialization” to find masks for IMP. Finally, we examine the performance of the IMPpruned sub-networks as initialized using the state after pre-training. This experiment determines the extent to which pre-training places the network in a state suitable for sub-network training as compared to using the state of the network at iteration $k$ of training on the original task.
108
+
109
+ # 6.1 RANDOM LABELS
110
+
111
+ To evaluate whether this phase of training is dependent on underlying structure in the data, we drew inspiration from Zhang et al. (2017) and pre-trained networks on data with randomized labels. This experiment tests whether the input distribution of the training data is sufficient to put the network in a position from which IMP with rewinding can find a sparse, trainable sub-network despite the presence of incorrect (not just missing) labels. Figure 9 (upper left) shows that pre-training on random labels for up to 10 epochs provides no improvement above rewinding to iteration 0 and that pre-training for longer begins to hurt accuracy. This result suggests that, though it is still possible that labels may not be required for learning, the presence incorrect labels is sufficient to prevent learning which approximates the early phase of training.
112
+
113
+ # 6.2 SELF-SUPERVISED ROTATION PREDICTION
114
+
115
+ What if we remove labels entirely? Is $p ( x )$ sufficient to approximate the early phase of training? Historically, neural network training often involved two steps: a self-supervised pre-training phase followed by a supervised phase on the target task (Erhan et al., 2010). Here, we consider one such self-supervised technique: rotation prediction (Gidaris et al., 2018). During the pre-training phase, the network is presented with a training image that has randomly been rotated $9 0 n$ degrees (where $n \in \{ 0 , 1 , 2 , 3 \bar \} )$ . The network must classify examples by the value of $n$ . If self-supervised pretraining can approximate the early phase of training, it would suggest that $p ( x )$ is sufficient on its own. Indeed, as shown in Figure 9 (upper right), this pre-training regime leads to well-trainable subnetworks, though networks must be trained for many more epochs compared to supervised training (40 compared to 1.25, or a factor of $3 2 \times 1$ ). This result suggests that the labels for the ultimate task themselves are not necessary to put the network in such a state (although explicitly misleading labels are detrimental). We emphasize that the duration of the pre-training phase required is an order of magnitude larger than the original rewinding iteration, however, suggesting that labels add important information which accelerates the learning process.
116
+
117
+ # 6.3 BLURRING TRAINING EXAMPLES
118
+
119
+ To probe the importance of $p ( x )$ for the early phase of training, we study the extent to which the training input distribution is necessary. Namely, we pretrain using blurred training inputs with the correct labels. Following Achille et al. (2019), we blur training inputs by downsampling by $4 \mathbf { x }$ and then upsampling back to the full size. Figure 9 (bottom left) shows that this pre-training method succeeds: after 40 epochs of pre-training, IMP with rewinding can find sub-networks that are similar in performance to those found after training on the original task for 500 iterations (1.25 epochs).
120
+
121
+ Due to the success of the the rotation and blurring pre-training tasks, we explored the effect of combining these pre-training techniques. Doing so tests the extent to which we can discard both the training labels and some information from the training inputs. Figure 9 (bottom right) shows that doing so provides the network too little information: no amount of pre-training we considered makes it possible for IMP with rewinding to find sub-networks that perform tangibly better than rewinding to iteration 0. Interestingly however, as shown in Appendix B, trainable sub-networks are found for VGG-13 with this pre-training regime, suggesting that different network architectures have different sensitivities to the deprivation of labels and input content.
122
+
123
+ # 6.4 SPARSE PRETRAINING
124
+
125
+ Since sparse sub-networks are often challenging to train from scratch without the proper initialization (Han et al., 2015; Liu et al., 2019; Frankle & Carbin, 2019), does pre-training make it easier for sparse neural networks to learn? Doing so would serve as a rough form of curriculum learning (Bengio et al., 2009) for sparse neural networks. We experimented with training sparse sub-networks of ResNet-20 (IMP sub-networks, randomly reinitialized sub-networks, and randomly pruned subnetworks) first on self-supervised rotation and then on the main task, but found no benefit beyond rewinding to iteration 0 (Figure 10). Moreover, doing so when starting from a sub-network rewound to iteration 500 actually hurts final accuracy. This result suggests that while pre-training is sufficient to approximate the early phase of supervised training with an appropriately structured mask, it is not sufficient to do so with an inappropriate mask.
126
+
127
+ ![](images/72f8803cfddf40a06eaf44ba7dce17941a23f860928741782f1d1815af395e7b.jpg)
128
+ Figure 10: The effect of pretraining sparse sub-networks of Resnet-20 (rewound to iteration 500) with 40 epochs of self-supervised rotation before training on CIFAR-10.
129
+
130
+ # 7 DISCUSSION
131
+
132
+ In this paper, we first performed extensive measurements of various statistics summarizing learning over the early part of training. Notably, we uncovered 3 sub-phases: in the very first iterations, gradient magnitudes are anomalously large and motion is rapid. Subsequently, gradients overshoot to smaller magnitudes before leveling off while performance increases rapidly. Then, learning slowly begins to decelerate. We then studied a suite of perturbations to the network state in the early phase finding that, counter to observations in smaller networks (Zhou et al., 2019), deeper networks are not robust to reinitializing with random weights with maintained signs. We also found that the weight distribution after the early phase of training is highly non-independent. Finally, we measured the data-dependence of the early phase with the surprising result that pre-training on a self-supervised task yields equivalent performance to late rewinding with IMP.
133
+
134
+ These results have significant implications for the lottery ticket hypothesis. The seeming necessity of late rewinding calls into question certain interpretations of lottery tickets as well as the ability to identify sub-networks at initialization. Our observation that weights are highly non-independent at the rewinding point suggests that the weights at this point cannot be easily approximated, making approaches which attempt to “jump” directly to the rewinding point unlikely to succeed. However, our result that labels are not necessary to approximate the rewinding point suggests that the learning during this phase does not require task-specific information, suggesting that rewinding may not be necessary if networks are pre-trained appropriately.
135
+
136
+ # REFERENCES
137
+
138
+ Alessandro Achille, Matteo Rovere, and Stefano Soatto. Critical learning periods in deep neural networks. 2019.
139
+
140
+ Yoshua Bengio, Jer´ ome Louradour, Ronan Collobert, and Jason Weston. Curriculum learning. In ˆ Proceedings of the 26th annual international conference on machine learning, pp. 41–48. ACM, 2009.
141
+
142
+ Pratik Chaudhuri and Stefano Soatto. Stochastic gradient descent performs variational inference, converges to limit cycles for deep networks. 2017. URL https://arxiv.org/abs/1710. 11029.
143
+
144
+ Dumitru Erhan, Yoshua Bengio, Aaron Courville, Pierre-Antoine Manzagol, Pascal Vincent, and Samy Bengio. Why does unsupervised pre-training help deep learning? Journal of Machine Learning Research, 11(Feb):625–660, 2010.
145
+
146
+ Jonathan Frankle and Michael Carbin. The lottery ticket hypothesis: Finding sparse, trainable neural networks. In International Conference on Learning Representations, 2019. URL https:// openreview.net/forum?id $\underline { { \underline { { \mathbf { \Pi } } } } } =$ rJl-b3RcF7.
147
+
148
+ Jonathan Frankle, Gintare Karolina Dziugaite, Daniel M Roy, and Michael Carbin. Stabilizing the lottery ticket hypothesis. arXiv preprint arXiv:1903.01611, 2019.
149
+
150
+ Behrooz Ghorbani, Shankar Krishnan, and Ying Xiao. An investigation into neural net optimization via hessian eigenvalue density. In Proceedings of the 36th International Conference on Machine Learning, volume 97, pp. 2232–2241, 2019. URL http://proceedings.mlr.press/ v97/ghorbani19b.html.
151
+
152
+ Spyros Gidaris, Praveer Singh, and Nikos Komodakis. Unsupervised representation learning by predicting image rotations. In International Conference on Learning Representations, 2018. URL https://openreview.net/forum?id $\underline { { \underline { { \mathbf { \Pi } } } } } =$ S1v4N2l0-.
153
+
154
+ Aditya Golatkar, Alessandro Achille, and Stefano Soatto. Time matters in regularizing deep networks: Weight decay and data augmentation affect early learning dynamics, matter little near convergence. 2019.
155
+
156
+ Guy Gur-Ari, Daniel A Roberts, and Ethan Dyer. Gradient descent happens in a tiny subspace. arXiv preprint arXiv:1812.04754, 2018.
157
+
158
+ Song Han, Jeff Pool, John Tran, and William Dally. Learning both weights and connections for efficient neural network. In Advances in neural information processing systems, pp. 1135–1143, 2015.
159
+
160
+ K He, X Zhang, S Ren, and J Sun. Deep residual learning for image recognition. In Computer Vision and Pattern Recogntion (CVPR), volume 5, pp. 6, 2015.
161
+
162
+ Sergey Ioffe and Christian Szegedy. Batch normalization: Accelerating deep network training by reducing internal covariate shift. In Proceedings of the 32Nd International Conference on International Conference on Machine Learning - Volume 37, ICML’15, pp. 448–456. JMLR.org, 2015. URL http://dl.acm.org/citation.cfm?id=3045118.3045167.
163
+
164
+ Zhuang Liu, Mingjie Sun, Tinghui Zhou, Gao Huang, and Trevor Darrell. Rethinking the value of network pruning. In International Conference on Learning Representations, 2019. URL https: //openreview.net/forum?id $=$ rJlnB3C5Ym.
165
+
166
+ Behnam Neyshabur, Zhiyuan Li, Srinadh Bhojanapalli, Yann LeCun, and Nathan Srebro. Towards understanding the role of over-parametrization in generalization of neural networks. 2019.
167
+
168
+ Levent Sagun, Utku Evci, Ugur Guney, Yann Dauphin, and Leon Bottou. Empirical analysis of the hessian of over-parametrized neural networks. 2017. URL https://arxiv.org/abs/ 1706.04454.
169
+
170
+ Shibani Santurkar, Dimitris Tsipras, Andrew Ilyas, and Aleksander Madry. How does batch normalization help optimization? In Advances in neural information processing systems, 2018.
171
+
172
+ Karen Simonyan and Andrew Zisserman. Very deep convolutional networks for large-scale image recognition. 2015.
173
+
174
+ Mingwei Wei and David Schwab. How noise during training affects the hessian spectrum in overparameterized neural networks. 2019.
175
+
176
+ Sho Yaida. Fluctuation-dissipation relations for stochastic gradient descent. 2019.
177
+
178
+ Sergey Zagoruyko and Nikos Komodakis. Wide residual networks. arXiv preprint arXiv:1605.07146, 2016.
179
+
180
+ Chiyuan Zhang, Samy Bengio, Moritz Hardt, Benjamin Recht, and Oriol Vinyals. Understanding deep learning requires rethinking generalization. 2017.
181
+
182
+ Hattie Zhou, Janice Lan, Rosanne Liu, and Jason Yosinski. Deconstructing lottery tickets: Zeros, signs, and the supermask. 2019.
183
+
184
+ A MODEL DETAILS
185
+
186
+ <table><tr><td>Network</td><td>Epochs</td><td>Batch Size</td><td>Learning Rate</td><td>Parameters</td><td>Eval Accuracy</td></tr><tr><td>ResNet-20</td><td>160</td><td>128</td><td>0.1 (Mom 0.9)</td><td>272K</td><td>91.5 ± 0.2%</td></tr><tr><td>ResNet-56</td><td>160</td><td>128</td><td>0.1 (Mom 0.9)</td><td>856K</td><td>93.0 ± 0.1%</td></tr><tr><td>ResNet-18</td><td>160</td><td>128</td><td>0.1 (Mom 0.9)</td><td>11.2M</td><td>86.8 ± 0.3%</td></tr><tr><td>VGG-13</td><td>160</td><td>64</td><td>0.1 (Mom 0.9)</td><td>9.42M</td><td>93.5 ± 0.1%</td></tr><tr><td>WRN-16-8</td><td>160</td><td>128</td><td>0.1 (Mom 0.9)</td><td>11.1M</td><td>94.8 ± 0.1%</td></tr></table>
187
+
188
+ Table A1: Summary of the networks we study in this paper. We present ResNet-20 in the main body of the paper and the remaining networks in Appendix B.
189
+
190
+ Table A1 summarizes the networks. All networks follow the same training regime: we train with SGD for 160 epochs starting at learning rate 0.1 (momentum 0.9) and drop the learning rate by a factor of ten at epoch 80 and again at epoch 120. Training includes weight decay with weight 1e4. Data is augmented with normalization, random flips, and random crops up to four pixels in any direction.
191
+
192
+ # B EXPERIMENTS FOR OTHER NETWORKS
193
+
194
+ ![](images/872ddc7d0ad8582b233591a1e40741fe4f95c600a08270edc101a7423e02545a.jpg)
195
+ Figure A1: Rough timeline of the early phase of training for ResNet-18 on CIFAR-10, including results from previous papers.
196
+
197
+ ![](images/63f2f9a9f6e585e38e603d9a40fa15b8af8a6995ed2ca2c196aee9d7fbf2deb8.jpg)
198
+ Figure A2: The effect of IMP rewinding iteration on the accuracy of sub-networks at various levels of sparsity. Accompanies Figure 1.
199
+
200
+ ![](images/d8488c8ab8d7f0308f3b1974a7b9a84dca85c021322de3896d8b904f932747f4.jpg)
201
+ Figure A3: Basic telemetry about the state of all networks in Table A1 during the first 4000 iterations of training. Accompanies Figure 3.
202
+
203
+ ![](images/a34ceb4ae0c81987ecdc7f5ddfa2e60ff037795ef8cf8955eccec47d906fca5e.jpg)
204
+ Figure A4: The effect of training an IMP-derived sub-network initialized to the signs at iteration 0 or $k$ and the magnitudes at iteration 0 or $k$ . Accompanies Figure A4.
205
+
206
+ ![](images/5c33032f73bacd97dba4aac435754655fdd79b3b50ca5595eb22c73c864aca92.jpg)
207
+
208
+ ![](images/0f3e0b165de498927e7248762a6b658ac2efbd505279c8b086ad1b4808cc7041.jpg)
209
+ Resnet-56 (CIFAR-10) - Rewinding Iteration 500
210
+
211
+ ![](images/b3d85495d764c63e5b9793c943d132939f9fb8c23934c35e70bf5a2abaaf631b.jpg)
212
+
213
+ ![](images/dbb505d3de1c365cdfb743d4eade9f62de4ba15c2fa9ed7f280990be575bdcdd.jpg)
214
+ Resnet-56 (CIFAR-10) - Rewinding Iteration 2000
215
+
216
+ ![](images/b2ccf52edf1b0b59acfd5e765e85299de16f99b871641d074efe1cd7ee7be4f1.jpg)
217
+ Resnet-18 (CIFAR-10) - Rewinding Iteration 500
218
+
219
+ ![](images/fb413d3205393040787190042574869ec1120adff3ee9b8638e8bf905c8c50d6.jpg)
220
+ Resnet-18 (CIFAR-10) - Rewinding Iteration 2000
221
+
222
+ ![](images/67363ef8fb1130a5957e75416ca688f6769e3620ac64cbc18953cfe4bd3ae060.jpg)
223
+ WRN-16-8 (CIFAR-10) - Rewinding Iteration 50
224
+
225
+ ![](images/5cdf2d289db2a8d2df68fcf74b52f0a7e0936cdc876aaadb775053cac7397f21.jpg)
226
+ WRN-16-8 (CIFAR-10) - Rewinding Iteration 250
227
+ Figure A5: The effect of training an IMP-derived sub-network initialized with the weights at iteration $k$ as shuffled within various structural elements. Accompanies Figure 5.
228
+
229
+ ![](images/2bd0fbe5e838abb5ac1e1e4022ccb7706c047b174850e2a1882f0a3c6d0501dc.jpg)
230
+ Figure A6: The effect of training an IMP-derived sub-network initialized with the weights at iteration $k$ as shuffled within various structural elements where shuffling only occurs between weights with the same sign. Accompanies Figure 6.
231
+
232
+ ![](images/d7e58a8ae01b34aebcb964fc88e4a58f41aa2ab9218ed70fd5d4343139da08a6.jpg)
233
+ Figure A7: The effect of training an IMP-derived sub-network initialized with the weights at iteration $k$ and Gaussian noise of $n \sigma$ , where $\sigma$ is the standard deviation of the initialization distribution for each layer. Accompanies Figure 7.
234
+
235
+ ![](images/b52dfa34b65e90016f1295f7e726d50c1dfff13edbf013fa698a5e01479a5380.jpg)
236
+ Figure A8: The effective standard deviation of each of the perturbations studied in Section 5 as a function of mean evaluation accuracy (across five seeds). Accompanies Figure 8.
237
+
238
+ ![](images/8cf6dc60b9976983ad6d59be2cc9ad9e266bb88950bb4572c5653558c98a1ec5.jpg)
239
+ Figure A9: The effect of pre-training CIFAR-10 with random labels. Accompanies Figure 9.
240
+
241
+ ![](images/06aff5a9a34d2535adc00efc1e7ba5f1559550836e2f886fb09a8a1971d49a38.jpg)
242
+ Figure A10: The effect of pre-training CIFAR-10 with self-supervised rotation. Accompanies Figure 9.
243
+
244
+ ![](images/75b300fc6a420d980deba5c945bc99ec31f9b87ff18ecf8ff04f650c76cf3135.jpg)
245
+ Figure A11: The effect of pre-training CIFAR-10 with $4 \mathbf { x }$ blurring. Accompanies Figure 9.
246
+
247
+ ![](images/6c798e68075d87eb505781c2e6300a3e943b845fe448ebf79e2ed47aea5ed65a.jpg)
248
+ VGG-13 (CIFAR-10) - 4x Blurring $^ +$ Self-Superivsed Rotation
249
+
250
+ ![](images/7e4a1e55454f29fd7af5984c32bd2fdf38629d509dc5a36e2877375b43bd8a8e.jpg)
251
+
252
+ ![](images/79d334233a97559da6578ed0b4bf0d59b42735df0cefe987851334d4ea8e655e.jpg)
253
+ Resnet-18 (CIFAR-10) - 4x Blurring $^ +$ Self-Superivsed Rotation
254
+
255
+ ![](images/54cd29c3f583c670ce6e12169f0a37b36cdf9113cd9c041dd99964a54af20bf0.jpg)
256
+ WRN-16-8 (CIFAR-10) - 4x Blurring $^ +$ Self-Superivsed Rotation
257
+ Figure A12: The effect of pre-training CIFAR-10 with $4 \mathbf { x }$ blurring and self-supervised rotation. Accompanies Figure 9.
parse/train/Hkl1iRNFwS/Hkl1iRNFwS_model.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/HkxaFoC9KQ/HkxaFoC9KQ.md ADDED
@@ -0,0 +1,314 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # DEEP REINFORCEMENT LEARNING WITH RELATIONAL INDUCTIVE BIASES
2
+
3
+ Vinicius Zambaldi∗, David Raposo∗, Adam Santoro∗, Victor Bapst, Yujia Li, Igor Babuschkin, Karl Tuyls, David Reichert, Timothy Lillicrap, Edward Lockhart, Murray Shanahan, Victoria Langston, Razvan Pascanu, Matthew Botvinick, Oriol Vinyals, Peter Battaglia
4
+
5
+ DeepMind, London, UK {vzambaldi,draposo,adamsantoro}@google.com
6
+
7
+ # ABSTRACT
8
+
9
+ We introduce an approach for augmenting model-free deep reinforcement learning agents with a mechanism for relational reasoning over structured representations, which improves performance, learning efficiency, generalization, and interpretability. Our architecture encodes an image as a set of vectors, and applies an iterative message-passing procedure to discover and reason about relevant entities and relations in a scene. In six of seven StarCraft II Learning Environment mini-games, our agent achieved state-of-the-art performance, and surpassed human grandmasterlevel on four. In a novel navigation and planning task, our agent’s performance and learning efficiency far exceeded non-relational baselines, it was able to generalize to more complex scenes than it had experienced during training. Moreover, when we examined its learned internal representations, they reflected important structure about the problem and the agent’s intentions. The main contribution of this work is to introduce techniques for representing and reasoning about states in model-free deep reinforcement learning agents via relational inductive biases. Our experiments show this approach can offer advantages in efficiency, generalization, and interpretability, and can scale up to meet some of the most challenging test environments in modern artificial intelligence.
10
+
11
+ # 1 INTRODUCTION
12
+
13
+ Recent deep reinforcement learning (RL) systems have achieved remarkable performance in very challenging problem domains (Mnih et al., 2015; Silver et al., 2016), in large part because of their flexibility in how they learn and exploit the statistical structure underlying observations and reward signals. But the downsides to such flexibility often include low sample efficiency and poor transfer beyond the specifics of the training environment (Zhang et al., 2018; Lake et al., 2017; Kansky et al., 2017). Various structured approaches to RL (e.g. Dzeroski et al. (2001); Driessens & Dzeroski (2004); Diuk et al. (2008); Garnelo et al. (2016)) have attempted to overcome these limitations by explicitly incorporating entity-based and symbolic representations, and specialized building blocks for solving the task at hand. Although these approaches are often highly efficient, they constrain the representations and admissible learning algorithms, they struggle to learn rich representations, and they are therefore confined to relatively simple tasks and data conditions.
14
+
15
+ To strike favorable tradeoffs between flexibility and efficiency, a number of recent approaches have explored using relational inductive biases in deep learning, to reap the benefits of flexible statistical learning and more structured approaches. Methods such as “graph networks” (Scarselli et al., 2009; Li et al., 2015; Battaglia et al., 2018) explicitly represent entities and their relations using using sets and graphs, and perform relational reasoning using learned message-passing (Gilmer et al., 2017) and attention (Vaswani et al., 2017; Hoshen, 2017; Velickovic et al., 2017; Wang et al., 2017) schemes. Because they are implemented using deep neural networks, they can learn transformations from input observations into task-relevant entities, as well as functions for computing rich interaction among these entities. This provides a powerful capacity for combinatorial generalization, where their learned building blocks can be composed to represent and reason about novel scenarios (Battaglia et al., 2016; Raposo et al., 2017; Dai et al., 2017; Wang et al., 2018; Selsam et al., 2018; Hamrick et al., 2018; Kipf et al., 2018; Sanchez-Gonzalez et al., 2018).
16
+
17
+ ![](images/5c822588dfeea2de0a334b5cd697ba4399066fb4f496cf8c18238a9bfe656daf.jpg)
18
+ Figure 1: Box-World and StarCraft II tasks demand reasoning about entities and their relations.
19
+
20
+ Drawing on several lines of work, we introduce an approach for incorporating relational inductive biases for entity- and relation-centric state representations, and iterated relational reasoning, into a deep RL agent. In contrast with prior work exploring relational inductive biases in deep RL (e.g., Wang et al., 2018), our approach does not rely on a priori knowledge of the structure of the problem and is agnostic to the particular relations that need to be considered. To handle raw visual input data, our architecture used a convolutional front-end to compute embeddings of sets of entities, similar to previous work in visual question answering, physical prediction, and video understanding (Santoro et al., 2017; Watters et al., 2017; Wang et al., 2017). To perform relational reasoning, we used a self-attention mechanism (Vaswani et al., 2017; Hoshen, 2017; Velickovic et al., 2017) applied iteratively within each timestep, which can be viewed as learned message-passing (Li et al., 2015; Gilmer et al., 2017). Our deep RL agent is based on an off-policy advantage actor-critic (A2C) method which is very effective across a range of standard RL environments (Espeholt et al., 2018).
21
+
22
+ Our results show that this relational deep RL agent scale to very challenging tasks, achieving state-ofthe-art performance on six out of seven StarCraft II mini-games (Vinyals et al., 2017), surpassing grandmaster level on four mini-games. Additionally, we introduce a novel navigation and planning task, called “Box-World”, which stresses the planning and reasoning components of the policy, factoring out other challenges like complex vision or large action spaces. Our agent reaches higher ceiling performance, more efficiently, than non-relational baseline, and is able to generalize to solve problems with more complex solutions than it had been trained on within this task. We also found that the intermediate representations involved in the relational computations were interpretable, and suggest that the agent has rich understanding of the underlying structure of the problem.
23
+
24
+ # 2 RELATIONAL DEEP RL AGENT ARCHITECTURE
25
+
26
+ # RL ALGORITHM
27
+
28
+ We started with a deep RL algorithm based on a distributed advantage actor-critic (A2C) method (Espeholt et al., 2018), which the schematic on the left of Figure 2 summarizes. The agent creates an embedded state representation, $S$ from its input observation, which is then used to compute as output a policy, $\pi$ (the “actor”), and a baseline value, $B$ (the “critic”). The $\pi$ consists of logits over the set of possible actions, from which an action to perform is sampled, and the $B$ is an estimate of the statevalue function at the current state. During learning, the $B$ is used to compute the temporal-difference error, which is used both to optimize $\pi$ to generate actions with greater returns than $B$ predicts, and to optimize $B$ to more accurately estimate state values. For further algorithmic details, including the distributed actor/learner framework and off-policy correction methods, please see Espeholt et al. (2018).
29
+
30
+ ![](images/8bfc778b0d4448fb937ffa5bf0924c16cd775e8a977b685163c8c39e78217311.jpg)
31
+ Figure 2: Box-World agent architecture and multi-head dot-product attention. $E$ is a matrix that compiles the entities produced by the visual front-end; $g _ { \theta }$ is a multilayer perceptron applied in parallel to each row of the output of an MHDPA step, $A$ , and producing updated entities, $\widetilde { E }$ .
32
+
33
+ # INPUT MODULE
34
+
35
+ Our agent takes as input an image of a scene, transforms it into an embedded state representation, $S$ , which is a spatial feature map returned by a convolutional neural network (CNN). The relational module (Figure 2) operated on a set of entities, so our architecture transformed the $m \times n \times f$ feature map into an $N \times f$ (where $N = m \cdot n$ ) set of “entity vectors”, $E$ , by reshaping $S$ so that each of $E$ ’s row, $\mathbf { e } _ { i }$ , corresponded to a feature vector, $\mathbf { s } _ { x , y }$ , at a particular $x , y$ location in the embedded scene. Crucially, this allowed for non-local computation between entities (Wang et al., 2017), unconstrained by their coordinates in the spatial feature map. Because removing the spatial map’s coordinate structure could prevent spatial information from being available for downstream computation, we concatenated the spatial $x , y$ coordinates of each $\mathbf { s } _ { x , y }$ onto the corresponding $\mathbf { e } _ { i }$ to ensure it was preserved. This feature-to-entity transformation procedure is analogous to how relation networks, visual interaction networks, and the general class of non-local neural networks (Santoro et al., 2017; Watters et al., 2017; Wang et al., 2017) process input images.
36
+
37
+ # RELATIONAL MODULE
38
+
39
+ To perform one step of relational reasoning, our architecture computed pairwise interactions between each entity and all others (including itself), denoted $\mathbf { p } _ { i , j }$ , and updated each entity by accumulating information about all of its interactions, $\tilde { \mathbf { e } } _ { i } \gets \{ \mathbf { p } _ { i , j } \} _ { j = 1 : N }$ . This is analogous to how the general class of graph neural networks and their relatives perform entity-wise relational updates (Scarselli et al., 2009; Gilmer et al., 2017). To perform these one-step relational computations, we used self-attention (Vaswani et al., 2017; Hoshen, 2017; Velickovic et al., 2017; Wang et al., 2017), though various other implementations (e.g., those reviewed in Battaglia et al. (2018)) should also be viable.
40
+
41
+ Our specific self-attention implementation was based on Vaswani et al. (2017)’s multi-head dotproduct attention (MHDPA), which we explain in detail to make clear its role as a mechanism of relational reasoning. MHDPA (see Figure 2’s expanded box) projects the entities, $E$ , into matrices of query, key, and value vectors, $Q , K$ , and $V$ , respectively (which are normalized via “layer normalization” (Ba et al., 2016)). The similarities between query $\mathbf { q } _ { i }$ and all keys, $\mathbf { k } _ { j = 1 : N }$ are computed by a dot-product, which are normalized into attention weights, $\mathbf { w } _ { i }$ , via a softmax function, and then used to compute the pairwise interaction terms, $\mathbf { p } _ { i , j } = w _ { i , j } \mathbf { v } _ { j }$ . The accumulation of the interactions for each entity is the sum of these pairwise interactions, $\begin{array} { r } { \mathbf { a } _ { i } = \sum _ { j = 1 : N } \mathbf { p } _ { i , j } } \end{array}$ . This can be efficiently computed using matrix multiplications, $A = \mathrm { s o f t m a x } ( d ^ { - { \frac { 1 } { 2 } } } Q K ^ { T } ) V$ , where $d$ is the dimensionality of the query and key vectors (i.e. $Q$ and $K$ have shape $N \times d )$ . Like Vaswani et al. (2017), we also use multiple, independent attention “heads”, applied in parallel (which our attention analyses in Results 3.1 suggests the heads may assume distinct relational semantics through training). The updated entities are computed as a function of the accumulated interactions, $\tilde { \mathbf { e } } _ { i } = \breve { g _ { \theta } } \left( \mathbf { a } _ { i } ^ { h = 1 : \breve { H } } \right)$
42
+
43
+ ![](images/6118afe1c717ba4bed79c7d07ad7ffdb8f5e73e37d7fb84f0a56124d3a26e4a8.jpg)
44
+ Figure 3: Box-World task: example observations (left), underlying graph structure that determines the proper path to the goal and the distractor branches (middle), and training curves (right).
45
+
46
+ (where $h$ indexes the head) by concatenating all $\mathbf { a } _ { i } ^ { h = 1 : H }$ together, passing them to a multilayer perceptron (MLP), summing the output with $\mathbf { e } _ { i }$ (i.e. a residual connection), and applying a final stage of layer normalization (Ba et al., 2016). We included this non-linear transformation $\left( g _ { \boldsymbol { \theta } } \right)$ to facilitate the computation of more complex relationships between the entities. This is analogous to what is done in Santoro et al. (2017).
47
+
48
+ This one-step relational update process, which we term a “block”, can be applied iteratively using shared (recurrent) or unshared (deep) parameters, to compute higher order interactions among entities, analogous to message-passing on graphs (Li et al., 2015; Gilmer et al., 2017). Here we refer to the stack of multiple relational blocks as the relational module.
49
+
50
+ # OUTPUT MODULE
51
+
52
+ The relational module’s final output, $\tilde { E }$ , is then used to compute $\pi$ and $B$ as follows. The $\tilde { E }$ matrix, with shape $N \times f$ , is reduced to an $f$ -dimensional vector by max-pooling over the entity dimension. This pooled vector is then passed to a small MLP, which returns an $( c + 1 )$ -dimensional vector. This vector is split into a $c$ -dimensional vector of $\pi$ ’s logits (where $c$ is the number of discrete actions), and a scalar baseline value estimate, $B$ . The $\pi$ logits are normalized using a softmax function, and used as probability parameters for a multinomial distribution, from which an action is randomly sampled.
53
+
54
+ # 3 EXPERIMENTS AND RESULTS
55
+
56
+ # 3.1 BOX-WORLD
57
+
58
+ TASK DESCRIPTION
59
+
60
+ We first introduce a controlled navigation environment, called Box-World1, which we designed to be perceptually simple, but combinatorially complex, and require abstract relational reasoning and planning. It consists of a $1 2 \times 1 2$ pixel room with keys and boxes scattered randomly. The room also contains an agent, represented by a single dark gray pixel, which can move in four directions: $u p$ down, left, right (see Figure 1).
61
+
62
+ Keys are represented by a single colored pixel. The agent can pick up a loose key (i.e., one not adjacent to any other colored pixel) by walking the avatar (i.e. the visual depiction of the agent’s location) over it. Boxes are represented by two adjacent colored pixels – the pixel on the right represents the box’s lock and its color indicates which key can be used to open that lock; the pixel on the left indicates the content of the box which is inaccessible while the box is locked.
63
+
64
+ To collect the content of a box the agent must first collect the key that opens the box (the one that matches the lock’s color), and then walk over the lock, which makes the lock disappear. At this point the content of the box becomes accessible and can be picked up by the agent. Most boxes contain keys that, if made accessible, can be used to open other boxes. One of the boxes contains a gem, represented by a single white pixel. The agent’s goal is to acquire the gem by unlocking the box that contains it and picking it up by walking over it. Keys that an agent has in its possession are depicted in the input observation as a pixel in the top-left corner.
65
+
66
+ In each level there is a unique sequence of boxes that need to be opened in order to reach the gem. Opening one wrong box (a distractor box) consumes the held key and leads to a dead-end, where the gem cannot be reached and the level becomes unsolvable. There are three user-controlled parameters that contribute to the difficulty of the level: 1) the number of boxes in the path to the goal (solution length); 2) the number of distractor branches; 3) the length of the distractor branches. In general, the task is computationally difficult for a few reasons. First, a key can only be used once, so the agent must be able to reason about whether a particular box is along a distractor branch or along the solution path. Second, keys and boxes appear in random locations in the room, demanding a capacity to reason about keys and boxes based on their abstract relations, rather than based on their spatial proximity.
67
+
68
+ # RL AGENTS FOR BOX-WORLD
69
+
70
+ Our agent follows the reinforcement learning setup and architecture described in section (Sec. 2). For a non-relational baseline, we replaced the agent’s relational module with a variable number of residual convolution blocks. See the Appendix for further details of the input, relational, and output modules, including hyperparameters and training procedures.
71
+
72
+ # RESULTS
73
+
74
+ The training set-up consisted of Box-World levels with solution lengths of at least 1 and up to 4. This ensured that an untrained agent would have a small probability of reaching the goal by chance, at least on some levels.2 The number of distractor branches was randomly sampled from 0 to 4. Training was split into two variants of the task: one with distractor branches of length 1; another one with distractor branches of length 3 (see Figure 3).
75
+
76
+ Agents augmented with our relational module achieved close to optimal performance in the two variants of this task, solving more than $98 \%$ of the levels. In the task variant with short distractor branches, an agent with a single relational block was able to achieve top performance. In the variant with long distractor branches, a greater number of relational blocks was required, consistent with the conjecture that more blocks allow higher-order relational computations. In contrast, our baseline agents, which can only rely on convolutional and fully-connected layers, performed significantly worse, solving less than $7 5 \%$ of the levels across the two task variants. We observed similar results when we repeated the experiments using two alternative RL algorithms: asynchronous advantage actor-critic (A3C, Mnih et al., 2016) and distributed Q-learning with prioritized experience replay (Horgan et al., 2018). We note that with Q-learning training took significantly longer (see Figure 7 in Appendix).
77
+
78
+ We also repeated these experiments, but with backward branching in the underlying graph used to generate the level. With backward branching the agent does not need to plan far into the future; when it is in possession of a key, a successful strategy is always to open the matching lock. In contrast, with forward branching scenes, the agent can use a key on the wrong lock (i.e. on a lock along a distractor branch). Thus, forward branching demands more complicated forward planning to determine the correct locks to open, which contrasts with backward branching scenarios where an agent can adopt a more reactive policy, always opting to open the lock that matches the key in possession. Indeed, the baseline agents performed much better in backward (versus forward) branching scenes, which suggests that its weak relational reasoning capacity is to blame for its poor performance in the forward branching condition (see Figure 8 in Appendix).
79
+
80
+ ![](images/beb04b6ec5b9b8cc5e50650e51e3e5c6fff6aadf5786f1a3d827447fd82403ac.jpg)
81
+ Figure 4: Visualization of attention weights. (a) The underlying graph of one example level; (b) the result of the analysis for that level, using each of the entities along the solution path (1–5) as the source of attention. Arrows point to the entities that the source is attending to. An arrow’s transparency is determined by the corresponding attention weight.
82
+
83
+ # VISUALIZATION OF ATTENTION WEIGHTS
84
+
85
+ We next looked at specific rows of the attention weight matrix, $\mathbf { w } _ { i }$ , which corresponded to relevant objects in the scene. Figure 4 shows the result of this analysis when the attending entities (source of the attention) are objects along the solution path. For one of the attention heads, each key attends mostly to the locks that can be unlocked with that key. In other words, the attention weights reflect the options available to the agent once a key is collected. For another attention head, each key attends mostly to the avatar’s entity vector. This suggests that object-avatar relations are important, which may help measure of relative position and support navigation.
86
+
87
+ In the case of RGB pixel inputs, the relationship between keys and locks that can be opened with that key is confounded with the fact that keys and the corresponding locks have the same RGB representation. We therefore repeated the analysis, this time using one-hot representation of the input, where the mapping between keys and the corresponding locks is arbitrary. We found evidence that: 1) keys attend to the locks they can unlock; 2) locks attend to the keys that can be used to unlock them; 3) all the objects attend to the avatar’s location; 4) the avatar and gem attend to each other and themselves.
88
+
89
+ # GENERALIZATION CAPABILITY: TESTING ON WITHHELD ENVIRONMENTS
90
+
91
+ As we observed, the attention weights captured a link between a key and its corresponding lock, using a shared computation across entities. If the function used to compute the weights (and hence, used to determine that certain keys and locks are related) has learned to represent some general, abstract notion of what it means to “unlock” – e.g., unlocks(key, lock) – then this function should be able to generalize to key-lock combinations that it has never observed during training. Similarly, a capacity to understand “unlocking” shouldn’t necessarily be affected by the number of locks that need to be unlocked to reach a solution.
92
+
93
+ We thus tested the model under two conditions, without further training: 1) on levels that required opening a longer sequence of boxes than it had ever observed (6, 8 and 10), and 2) on levels that required using a key-lock combination that was never required for reaching the gem during training, instead only being placed on distractor paths. As shown in Figure 5, in the first condition, the agent with the relational module solved more than $8 8 \%$ of the levels, across all three solution length conditions. In contrast, the performance of the agent trained without the relational module collapsed to $5 \%$ when tested on sequences of 6 boxes, and to $0 \%$ on sequences of 8 and 10. On levels with new key-lock combinations, the agent augmented with a relational module solved $9 7 \%$ of the new levels. The agent without the relational module performed poorly, reaching only $13 \%$ . Together, these results show that the relational module offers a greater capacity for zero-shot transfer to more complex and previously unseen problems. This is likely a consequence of our approach’s object- and relation-centric learning, which is less sensitive to the specific conjunctions of objects and relations it has experienced during training.
94
+
95
+ ![](images/a02836fc44696892da9ab8b0409a3d108982124448e2cce0f32f471ecb3f9e38.jpg)
96
+ Figure 5: Generalization in Box-World. Zero-shot transfer to levels that required: (a) opening a longer sequence of boxes; (b) using a key-lock combination that was never required during training.
97
+
98
+ # 3.2 STARCRAFT II MINI-GAMES
99
+
100
+ # TASK DESCRIPTION
101
+
102
+ StarCraft II is a popular video game that presents a difficult challenge for RL agents. It is a multiagent game where each player controls a large number (hundreds) of units that need to interact and collaborate (see Figure 1). It is partially observable and has a large state and action space, with more than 100 possible actions. The consequences of any single action – in particular, early decisions in the game – are typically only observed many frames later, posing difficulties in temporal credit assignment and exploration.
103
+
104
+ We trained our agents on the suite of 7 mini-games developed for the StarCraft II Learning Environment (SC2LE, Vinyals et al., 2017). These mini-games were proposed as a set of specific scenarios that are representative of the mechanics of the full game and can be used to test agents in a simpler set up with a better defined reward structure, compared to the full game. The 7 mini-games demand different strategies and skills. Notably, Collect Mineral Shards (CMS), Defeat Roaches (DR) and Defeat Zerglings and Banelings (DZB), require controlling multiple units with precision and in a coordinated manner. To achieve a high score in CMS, the player (or agent) needs to command the two marines independently, defining navigation paths that do not overlap too much in order to efficiently cover most of the ground. In DR, the player must focus-fire to succeed, which requires selecting the same attack target, one at a time, for all the marines. In DZB, the enemy units have different abilities, so a good strategy may involve splitting the army into groups with different roles.
105
+
106
+ # RL AGENTS FOR STARCRAFT II
107
+
108
+ For StarCraft II (SC2), we start by first constructing a strong control baseline to test against our relational agent. The architecture is similar to that of the Box-World agent, with changes to accommodate specific features of the SC2 environment. We increased the model capacity by using 2 residual convolutional blocks in the input module, each consisting of 3 convolutional layers. We added a 2D-ConvLSTM immediately downstream of the residual blocks, so the subsequent computations were sensitive to the recent history of observations, rather than only the current observation, thus accounting for partial observability. Including this memory mechanism was important because the actions a StarCraft agent issues to units are carried out over multiple timesteps (e.g., MOVE UNIT 3 TO COORDINATE (1, 5)), and the agent needs a way of not “forgetting” what actions it has issued previously. Otherwise it might keep reissuing the same action to a unit, rather than choosing another action for another unit. Finally, the relational module depicted in section (Sec. 2) was replaced by a stack of residual convolutional blocks in the control agent.
109
+
110
+ For the agent’s output, alongside action $a$ and value $V$ , the network produces two sets of action-related arguments: non-spatial arguments (Args) and spatial arguments $( A r g s _ { x , y } )$ . These arguments are used as modifiers of particular actions (see (Vinyals et al., 2017)). Args are produced from the output of the aggregation function, whereas $A r g s _ { x , y }$ result from upsampling the output of the relational module. See the Appendix for further details.
111
+
112
+ ![](images/710f8f8bda37ef92da4ce3ab129888d9cc58bcd4cab04bc160ab0c9f71c6f33a.jpg)
113
+ Figure 6: Final performance across StarCraft II mini-games. The relational-agent achieved above grandmaster scores in 4 out of 7 levels. The main difference between our new control agent and the relational agent is most relevant in the Defeat Zerglings and Banelings task. Here, the underlying strategy requires agents to split their army and kite enemy units in order to alleviate the incoming impact (as Banelings incur area damage); a strategy requiring reasoning and fine control over many units. A relational agent with iterative blocks of attention was required for this strategy to emerge. For more details, see Table 1 in the Appendix.
114
+
115
+ # RESULTS
116
+
117
+ For these results we used the full action set provided by SC2LE and performance was measured as the mean score over 30 episodes of the best run for each mini-game. Our agent implementations achieved high scores across all the mini-games (Figure 6), consistently outperforming the previous best models. In particular, the agent augmented with a relational module achieved state-of-the-art results in six mini-games and its performance surpassed that of the human grandmaster in four of them3.
118
+
119
+ Head-to-head comparisons between our two implementations show that the agent with the relational component (relational) achieves similar or better results than the one without (control). Concretely, for Collect Mineral Shards, Defeat Roaches and Defeat Zerglings and Banelings, the relational agent improved relative to the control agent by 9, 8 and 134 points, with a standard error of 1.5, 6.4 and 18.2, respectively.
120
+
121
+ We note that both models improved substantially over the previous best (Vinyals et al., 2017), and in some mini-games, they approach an empirical ceiling performance. This can be attributed to a combination of factors: improved RL algorithm (Espeholt et al., 2018), more robust architecture, better hyperparameter tuning to address issues of credit assignment and exploration, better action selection procedure, and longer training. Next, we focus on differences afforded by relational inductive biases and turn to particular generalization tests to determine the behavioural traits of the control and relational agents.
122
+
123
+ # GENERALIZATION CAPABILITY
124
+
125
+ As observed in Box-World, a capacity to better understand underlying relational structure – rather than latch onto superficial statistics – may manifest in better generalization to never-before-seen situations. To test generalization in SC2 we took agents trained on Collect Mineral Shards, which involved using two marines to collect randomly scattered minerals and tested them, without further training, on modified levels that allowed the agents to instead control up to ten marines. It’s worth highlighting the agents have never been exposed to a single observation present in these generalization experiments. Intuitively, if an agent understands that marines are independent units that can be coordinated, yet controlled independently to collect resources, then increasing the number of marines available should only affect the underlying strategy of unit deployment, and should not catastrophically break model performance.
126
+
127
+ We observed that—at least for medium sized networks—some interesting generalization capabilities emerge, with the best seeds of the relational agent achieving better generalization scores in the test scenario. However, we noticed high variability in these quantitative results, with the effect diminishing when using larger models (which may be more prone to overfitting on the training set). Qualitative analysis of the policies revealed distinct behaviours for the best performing control and relational agents: while the former adopted a "land sweep strategy", controlling many units as a group to cover the space, the latter managed to independently control several units simultaneously, suggesting a finer grained understanding of the game dynamics. Further work is required to draw firm conclusions about the generalization capabilities of a relational agent in more complex domains such as StarCraft II (see Figure 9 in Appendix).
128
+
129
+ Given the combinatoric richness and multi-agent aspects of the full StarCraft II game, an agent is frequently exposed to situations in which it might not have been trained on. Thus, an improved capability to generalize to new, unseen situations aided by a better understanding of underlying abstract entities and their relations is fundamental.
130
+
131
+ # 4 CONCLUSION
132
+
133
+ By introducing structured perception and relational reasoning into deep RL architectures, our agents can learn interpretable representations, and exceed baseline agents in terms of sample complexity, ability to generalize, and overall performance. Behavioral analyses showed that the learned representations allowed for better generalization, which is characteristic of relational representations. Analysis of attention weights showed that the model’s internal computations were interpretable, and congruent with the computations we would expect from a model computing task-relevant relations.
134
+
135
+ One important future direction is to explore ways to scale our approach to larger inputs spaces, without suffering, as this and other approaches do (e.g., Wang et al., 2017; Santoro et al., 2017), from the quadratic complexity that results from considering all input pairs. Possible avenues involve using a distinct attentional mechanisms that scales linearly with the number of inputs (Hoshen, 2017) or filtering out unimportant relations (Malinowski et al., 2018). Other future directions include exploring perceiving complex scenes via more structured formats, such as scene graphs (Xu et al., 2017; Chen et al., 2018), which could be powerful additions to our approach’s input module. More complex relational modules could be explored, such as richer graph network implementations (Battaglia et al., 2018), learned approaches for inducing compositional programs (Reed & De Freitas, 2015; Parisotto et al., 2017; Allamanis et al., 2017; Devlin et al., 2017) and reasoning about structured data (Neelakantan et al., 2015; Liang et al., 2016), or even explicit logical reasoning over structured internal representations (Evans et al., 2018), drawing inspiration from more symbolic approaches in classic AI. Our approach may also interface well with approaches for hierarchical RL (Vezhnevets et al., 2017), planning (Guez et al., 2018), and structured behavior representation (Huang et al., 2018), so that the structured internal representations and patterns of reasoning can translate into more structured behaviors.
136
+
137
+ More speculatively, this work blurs the line between model-free agents, and those with a capacity for more abstract planning. An important feature of model-based approaches is making general knowledge of the environment available for decision-making. Here our inductive biases for entityand relation-centric representations and iterated reasoning reflect key knowledge about the structure of the world. While not a model in the technical sense, it is possible that the agent learns to exploit this relational architectural prior similarly to how an imagination-based agent’s forward model operates (Hamrick et al., 2017; Pascanu et al., 2017; Weber et al., 2017). More generally, our work opens new directions for RL via a principled hybrid of flexible statistical learning and more structured approaches.
138
+
139
+ # REFERENCES
140
+
141
+ Miltiadis Allamanis, Pankajan Chanthirasegaran, Pushmeet Kohli, and Charles Sutton. Learning continuous semantic representations of symbolic expressions. In Proceedings of the International Conference on Machine Learning (ICML), 2017.
142
+
143
+ Jimmy Lei Ba, Jamie Ryan Kiros, and Geoffrey E Hinton. Layer normalization. arXiv preprint arXiv:1607.06450, 2016.
144
+
145
+ Peter Battaglia, Razvan Pascanu, Matthew Lai, Danilo Jimenez Rezende, et al. Interaction networks for learning about objects, relations and physics. In Advances in neural information processing systems, pp. 4502–4510, 2016.
146
+
147
+ Peter W Battaglia, Jessica B Hamrick, Victor Bapst, Alvaro Sanchez-Gonzalez, Vinicius Zambaldi, Mateusz Malinowski, Andrea Tacchetti, David Raposo, Adam Santoro, Ryan Faulkner, et al. Relational inductive biases, deep learning, and graph networks. arXiv preprint arXiv:1806.01261, 2018.
148
+
149
+ Xinlei Chen, Li-Jia Li, Li Fei-Fei, and Abhinav Gupta. Iterative visual reasoning beyond convolutions. arXiv preprint arXiv:1803.11189, 2018.
150
+
151
+ Hanjun Dai, Elias Khalil, Yuyu Zhang, Bistra Dilkina, and Le Song. Learning combinatorial optimization algorithms over graphs. In Advances in Neural Information Processing Systems, pp. 6351–6361, 2017.
152
+
153
+ Jacob Devlin, Jonathan Uesato, Rishabh Singh, and Pushmeet Kohli. Semantic code repair using neuro-symbolic transformation networks. arXiv preprint arXiv:1710.11054, 2017.
154
+
155
+ Carlos Diuk, Andre Cohen, and Michael L Littman. An object-oriented representation for efficient reinforcement learning. In Proceedings of the 25th international conference on Machine learning, pp. 240–247. ACM, 2008.
156
+
157
+ Kurt Driessens and Saso Dzeroski. Integrating guidance into relational reinforcement learning. Machine Learning, 57(3):271–304, 2004.
158
+
159
+ Saso Dzeroski, Luc De Raedt, and Kurt Driessens. Relational reinforcement learning. Machine Learning, 43(1/2):7–52, 2001.
160
+
161
+ Lasse Espeholt, Hubert Soyer, Remi Munos, Karen Simonyan, Volodymir Mnih, Tom Ward, Yotam Doron, Vlad Firoiu, Tim Harley, Iain Dunning, et al. Impala: Scalable distributed deep-rl with importance weighted actor-learner architectures. arXiv preprint arXiv:1802.01561, 2018.
162
+
163
+ Richard Evans, David Saxton, David Amos, Pushmeet Kohli, and Edward Grefenstette. Can neural networks understand logical entailment? In Proceedings of the International Conference on Learning Representations (ICLR), 2018.
164
+
165
+ Marta Garnelo, Kai Arulkumaran, and Murray Shanahan. Towards deep symbolic reinforcement learning. arXiv preprint arXiv:1609.05518, 2016.
166
+
167
+ Justin Gilmer, Samuel S Schoenholz, Patrick F Riley, Oriol Vinyals, and George E Dahl. Neural message passing for quantum chemistry. arXiv preprint arXiv:1704.01212, 2017.
168
+
169
+ Arthur Guez, Théophane Weber, Ioannis Antonoglou, Karen Simonyan, Oriol Vinyals, Daan Wierstra, Rémi Munos, and David Silver. Learning to search with mctsnets. arXiv preprint arXiv:1802.04697, 2018.
170
+
171
+ Jessica B Hamrick, Andrew J Ballard, Razvan Pascanu, Oriol Vinyals, Nicolas Heess, and Peter W Battaglia. Metacontrol for adaptive imagination-based optimization. arXiv preprint arXiv:1705.02670, 2017.
172
+
173
+ Jessica B Hamrick, Kelsey R Allen, Victor Bapst, Tina Zhu, Kevin R McKee, Joshua B Tenenbaum, and Peter W Battaglia. Relational inductive bias for physical construction in humans and machines. arXiv preprint arXiv:1806.01203, 2018.
174
+
175
+ Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. Identity mappings in deep residual networks. In European Conference on Computer Vision, pp. 630–645. Springer, 2016.
176
+
177
+ Dan Horgan, John Quan, David Budden, Gabriel Barth-Maron, Matteo Hessel, Hado Van Hasselt, and David Silver. Distributed prioritized experience replay. arXiv preprint arXiv:1803.00933, 2018.
178
+
179
+ Yedid Hoshen. Vain: Attentional multi-agent predictive modeling. In Advances in Neural Information Processing Systems, pp. 2701–2711, 2017.
180
+
181
+ De-An Huang, Suraj Nair, Danfei Xu, Yuke Zhu, Animesh Garg, Li Fei-Fei, Silvio Savarese, and Juan Carlos Niebles. Neural task graphs: Generalizing to unseen tasks from a single video demonstration. arXiv preprint arXiv:1807.03480, 2018.
182
+
183
+ Max Jaderberg, Valentin Dalibard, Simon Osindero, Wojciech M Czarnecki, Jeff Donahue, Ali Razavi, Oriol Vinyals, Tim Green, Iain Dunning, Karen Simonyan, et al. Population based training of neural networks. arXiv preprint arXiv:1711.09846, 2017.
184
+
185
+ Ken Kansky, Tom Silver, David A Mély, Mohamed Eldawy, Miguel Lázaro-Gredilla, Xinghua Lou, Nimrod Dorfman, Szymon Sidor, Scott Phoenix, and Dileep George. Schema networks: Zero-shot transfer with a generative causal model of intuitive physics. arXiv preprint arXiv:1706.04317, 2017.
186
+
187
+ Thomas Kipf, Ethan Fetaya, Kuan-Chieh Wang, Max Welling, and Richard Zemel. Neural relational inference for interacting systems. arXiv preprint arXiv:1802.04687, 2018.
188
+
189
+ Brenden M Lake, Tomer D Ullman, Joshua B Tenenbaum, and Samuel J Gershman. Building machines that learn and think like people. Behavioral and Brain Sciences, 40, 2017.
190
+
191
+ Yujia Li, Daniel Tarlow, Marc Brockschmidt, and Richard Zemel. Gated graph sequence neural networks. arXiv preprint arXiv:1511.05493, 2015.
192
+
193
+ Chen Liang, Jonathan Berant, Quoc Le, Kenneth D Forbus, and Ni Lao. Neural symbolic machines: Learning semantic parsers on freebase with weak supervision. arXiv preprint arXiv:1611.00020, 2016.
194
+
195
+ Mateusz Malinowski, Carl Doersch, Adam Santoro, and Peter Battaglia. Learning visual question answering by bootstrapping hard attention. In Proceedings of the European Conference on Computer Vision (ECCV), pp. 3–20, 2018.
196
+
197
+ Volodymyr Mnih, Koray Kavukcuoglu, David Silver, Andrei A Rusu, Joel Veness, Marc G Bellemare, Alex Graves, Martin Riedmiller, Andreas K Fidjeland, Georg Ostrovski, et al. Human-level control through deep reinforcement learning. Nature, 518(7540):529, 2015.
198
+
199
+ Volodymyr Mnih, Adria Puigdomenech Badia, Mehdi Mirza, Alex Graves, Timothy Lillicrap, Tim Harley, David Silver, and Koray Kavukcuoglu. Asynchronous methods for deep reinforcement learning. In International conference on machine learning, pp. 1928–1937, 2016.
200
+
201
+ Arvind Neelakantan, Quoc V Le, and Ilya Sutskever. Neural programmer: Inducing latent programs with gradient descent. arXiv preprint arXiv:1511.04834, 2015.
202
+
203
+ Emilio Parisotto, Abdel-rahman Mohamed, Rishabh Singh, Lihong Li, Dengyong Zhou, and Pushmeet Kohli. Neuro-symbolic program synthesis. In Proceedings of the International Conference on Learning Representations (ICLR), 2017.
204
+
205
+ Razvan Pascanu, Yujia Li, Oriol Vinyals, Nicolas Heess, Lars Buesing, Sebastien Racanière, David Reichert, Théophane Weber, Daan Wierstra, and Peter Battaglia. Learning model-based planning from scratch. arXiv preprint arXiv:1707.06170, 2017.
206
+
207
+ David Raposo, Adam Santoro, David Barrett, Razvan Pascanu, Timothy Lillicrap, and Peter Battaglia. Discovering objects and their relations from entangled scene representations. arXiv preprint arXiv:1702.05068, 2017.
208
+
209
+ Scott Reed and Nando De Freitas. Neural programmer-interpreters. arXiv preprint arXiv:1511.06279, 2015.
210
+
211
+ Alvaro Sanchez-Gonzalez, Nicolas Heess, Jost Tobias Springenberg, Josh Merel, Martin Riedmiller, Raia Hadsell, and Peter Battaglia. Graph networks as learnable physics engines for inference and control. arXiv preprint arXiv:1806.01242, 2018.
212
+
213
+ Adam Santoro, David Raposo, David G Barrett, Mateusz Malinowski, Razvan Pascanu, Peter Battaglia, and Tim Lillicrap. A simple neural network module for relational reasoning. In Advances in neural information processing systems, pp. 4974–4983, 2017.
214
+
215
+ Franco Scarselli, Marco Gori, Ah Chung Tsoi, Markus Hagenbuchner, and Gabriele Monfardini. The graph neural network model. IEEE Transactions on Neural Networks, 20(1):61–80, 2009.
216
+
217
+ Daniel Selsam, Matthew Lamm, Benedikt Bunz, Percy Liang, Leonardo de Moura, and David L Dill. Learning a sat solver from single-bit supervision. arXiv preprint arXiv:1802.03685, 2018.
218
+
219
+ David Silver, Aja Huang, Chris J Maddison, Arthur Guez, Laurent Sifre, George Van Den Driessche, Julian Schrittwieser, Ioannis Antonoglou, Veda Panneershelvam, Marc Lanctot, et al. Mastering the game of go with deep neural networks and tree search. nature, 529(7587):484–489, 2016.
220
+
221
+ Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Łukasz Kaiser, and Illia Polosukhin. Attention is all you need. In Advances in Neural Information Processing Systems, pp. 6000–6010, 2017.
222
+
223
+ Petar Velickovic, Guillem Cucurull, Arantxa Casanova, Adriana Romero, Pietro Lio, and Yoshua Bengio. Graph attention networks. arXiv preprint arXiv:1710.10903, 2017.
224
+
225
+ Alexander Sasha Vezhnevets, Simon Osindero, Tom Schaul, Nicolas Heess, Max Jaderberg, David Silver, and Koray Kavukcuoglu. Feudal networks for hierarchical reinforcement learning. arXiv preprint arXiv:1703.01161, 2017.
226
+
227
+ Oriol Vinyals, Timo Ewalds, Sergey Bartunov, Petko Georgiev, Alexander Sasha Vezhnevets, Michelle Yeo, Alireza Makhzani, Heinrich Küttler, John Agapiou, Julian Schrittwieser, et al. Starcraft ii: a new challenge for reinforcement learning. arXiv preprint arXiv:1708.04782, 2017.
228
+
229
+ Tingwu Wang, Renjie Liao, Jimmy Ba, and Sanja Fidler. Nervenet: Learning structured policy with graph neural networks. Proceedings of the International Conference on Learning Representations (ICLR), 2018.
230
+
231
+ Xiaolong Wang, Ross Girshick, Abhinav Gupta, and Kaiming He. Non-local neural networks. arXiv preprint arXiv:1711.07971, 2017.
232
+
233
+ Nicholas Watters, Andrea Tacchetti, Theophane Weber, Razvan Pascanu, Peter Battaglia, and Daniel Zoran. Visual interaction networks. arXiv preprint arXiv:1706.01433, 2017.
234
+
235
+ Théophane Weber, Sébastien Racanière, David P Reichert, Lars Buesing, Arthur Guez, Danilo Jimenez Rezende, Adria Puigdomènech Badia, Oriol Vinyals, Nicolas Heess, Yujia Li, et al. Imagination-augmented agents for deep reinforcement learning. arXiv preprint arXiv:1707.06203, 2017.
236
+
237
+ Danfei Xu, Yuke Zhu, Christopher B Choy, and Li Fei-Fei. Scene graph generation by iterative message passing. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, volume 2, 2017.
238
+
239
+ Chiyuan Zhang, Oriol Vinyals, Remi Munos, and Samy Bengio. A study on overfitting in deep reinforcement learning. arXiv preprint arXiv:1804.06893, 2018.
240
+
241
+ # APPENDIX
242
+
243
+ A BOX-WORLD
244
+
245
+ TASK
246
+
247
+ Each level in Box-world is procedurally generated. We start by generating a random graph (a tree) that defines the correct path to the goal – i.e., the sequence of boxes that need to be opened to reach the gem. This graph also defines multiple distractor branches – boxes that lead to dead-ends. The agent, keys and boxes, including the one containing the gem, are positioned randomly in the room, assuring that there is enough space for the agent to navigate between boxes. There is a total of 20 keys and 20 locks that are randomly sampled to produce the level. An agent receives a reward of $+ 1 0$ for collecting the gem, $+ 1$ for opening a box in the solution path and $- 1$ for opening a distractor box. A level terminates immediately after the gem is collected or a distractor box is opened.
248
+
249
+ The generation process produces a very large number of possible trees, making it extremely unlikely that the agent will face the same level twice. The procedural generation of levels also allows us to create different training-test splits by withholding levels that conform to a particular case during training and presenting them to the agent at test time.
250
+
251
+ ![](images/f17b742e4204133c699243326f366d268887d65d6c2d6d663d4922248c21fd54.jpg)
252
+ Figure 7: Alternative RL algorithms produced similar results on Box-World. The difference in performance that we observed between relational and baseline agents using the RL algorithm proposed by Espeholt et al. (2018) was still present when using A3C or distributed DQN. These experiments were done using $1 0 \times 1 0$ pixel maps, solution sequences of up to 3 boxes and up to 3 distractor branches.
253
+
254
+ ![](images/9014be2b4481bb22f1c5ceeb81002b1c9ecb910d24d762e5a77f620ca0472ef9.jpg)
255
+ Figure 8: Box-World: forward branching versus backward branching. With backward branching, any given key can only open one box; however, each key type (i.e. color), can appear in multiple boxes. This means that an agent can adopt a more reactive policy without planning beyond which box to open next.
256
+
257
+ Mini-game
258
+ Table 1: Mean scores achieved in the StarCraft II mini-games using full action set. $\uparrow$ denotes a score that is higher than a StarCraft Grandmaster. Mini-games: 1–Move To Beacon, 2–Collect Mineral Shards, 3–Find And Defeat Zerglings, 4–Defeat Roaches, 5–Defeat Zerglings And Banelings, 6–Collect Minerals And Gas, 7–Build Marines.
259
+
260
+ <table><tr><td>Agent</td><td>1</td><td>2</td><td>3</td><td>4</td><td>5</td><td>6</td><td>7</td></tr><tr><td>DeepMind Human Player (Vinyals et al., 2017)</td><td>26</td><td>133</td><td>46</td><td>41</td><td>729</td><td>6880</td><td>138</td></tr><tr><td>StarCraft Grandmaster (Vinyals et al.,2017)</td><td>28</td><td>177</td><td>61</td><td>215</td><td>727</td><td>7566</td><td>133</td></tr><tr><td>Random Policy (Vinyals et al., 2017)</td><td>1</td><td>17</td><td>4</td><td>1</td><td>23</td><td>12</td><td>&lt;1</td></tr><tr><td>FullyConv LSTM (Vinyals et al., 2017)</td><td>26</td><td>104</td><td>44</td><td>98</td><td>96</td><td>3351</td><td>6</td></tr><tr><td>PBT-A3C (Jaderberg et al., 2017)</td><td>1</td><td>101</td><td>50</td><td>132</td><td>125</td><td>3345</td><td>0</td></tr><tr><td>Relational agent</td><td>27</td><td>196个</td><td>62个</td><td>303 个</td><td>736个</td><td>4906</td><td>123</td></tr><tr><td>Control agent</td><td>27</td><td>187↑</td><td>61</td><td>295个</td><td>602</td><td>5055</td><td>120</td></tr></table>
261
+
262
+ # B RL TRAINING PROCEDURE
263
+
264
+ We used distributed A2C agents with off-policy corrections (Espeholt et al., 2018). Each agents consisted of 100 actors generating trajectories of experience, and a single learner, which learns $\pi$ and $B$ using the actors’ experiences. The model updates were performed on GPU using mini-batches of 32 trajectories provided by the actors via a queue. The agents used an entropy cost of 0.005, discount $( \gamma )$ of 0.99 and unroll length of 40 steps.
265
+
266
+ Training was done using RMSprop optimiser with momentum of 0, $\epsilon$ of 0.1 and a decay term of 0.99.
267
+ The learning rate was tuned, taking values between 1e−5 and $2 \mathrm { e } { - 4 }$ .
268
+
269
+ # AGENT ARCHITECTURE
270
+
271
+ The input module contained two convolutional layers with 12 and 24 kernels, $2 \times 2$ kernel sizes and a stride of 1, followed by a rectified linear unit (ReLU) activation function. The output was tagged with two extra channels indicating the spatial position ( $\mathbf { \chi } _ { x }$ and $y$ ) of each cell in the feature map using evenly spaced values between $- 1$ and 1. This was passed to the relational module, consisting of relational blocks, with shared parameters. Queries, keys and values were produced by 2 to 4 attention heads and had an embedding size $( d )$ of 64. The output of this module was aggregated using a feature-wise max pooling function and passed to 4 fully connected layers, each followed by a ReLU. Policy logits $\pi$ , size 4) and baseline function $B$ , size 1) were produced by a linear projection. The policy logits were normalized and used as multinomial distribution from which the action $( a )$ was sampled.
272
+
273
+ # BASELINE AGENT ARCHITECTURE
274
+
275
+ As a baseline agent we used the same architecture as the relational agent but replaced the relational module with a variable number (3 to 6) of residual-convolutional blocks. Each residual block comprised two convolutional layers, with $3 \times 3$ kernels, stride of 1 and 26 output channels.
276
+
277
+ # C STARCRAFT II MINI-GAMES
278
+
279
+ StarCraft II agents were trained with Adam optimiser for a total of 10 billion steps using batches of 32 trajectories, each unrolled for 80 steps. A linear decay was applied to the optimiser learning rate and entropy loss scaling throughout training (see Table 2 for details). We ran approximately 100 experiments for each mini-game, using the hyperparameter settings indicated in Table 4 combined with 3 seeds.
280
+
281
+ ![](images/ce7160880769779dda4c01b71bb80c0c73a296b82bd706f75e2d9ec213edd709.jpg)
282
+ Figure 9: Generalization results on the StarCraft II mini-game Collect Mineral Shards. Agents were trained on levels with 2 marines and tested on levels with 1, 2, 3, 4, 5 or 10 marines. Colored bars indicate mean score over the ten best runs; error bars indicate standard error.
283
+
284
+ RELATIONAL AGENT ARCHITECTURE
285
+
286
+ The StarCraft II (SC2) agent architecture follows closely the one we adopted in Box-World. Here we highlight the changes needed to satisfy SC2 constraints.
287
+
288
+ Input-preprocessing. At each time step agents are presented with 4 sources of information: minimap, screen, player, and previous-action. These tensors share the same pre-processing: numerical features are re-scaled with a logarithmic transformation and categorical features are embedded into a continuous 10-dimensional space.
289
+
290
+ State encoding. Spatially encoded inputs (minimap and screen) are tiled with binary masks denoting whether the previous action constituted a screen- or minimap-related action. These tensors are then fed to independent residual convolutional blocks, each consisting of one convolutional layer $( 4 \times 4$ kernels and stride 2) followed by a residual block with 2 convolutional layers ( $3 \times 3$ kernels and stride 1), which process and downsample the inputs to $[ 8 \times 8 \times \# c h a n n e l s _ { 1 } ]$ outputs. These tensors are concatenated along the depth dimension to form a singular spatial input $( i n p u t s _ { 3 D }$ , with shape $[ 8 \times 8 \times \# c h a n n e l s _ { 1 } + \# c h a n n e l s _ { 1 } ] )$ . The remaining inputs (player and previous-action) are concatenated and passed to a 2-layer MLP (128 units, ReLU, 64 units) to form a singular non-spatial input $( i n p u t s _ { 2 D } )$ .
291
+
292
+ Memory processing. Next, inputs $_ { 3 D }$ is passed to the Conv2DLSTM along with its previous state to produce a new state and outputs $_ { 3 D }$ (shape $[ 8 \times 8 \times \# c h a n n e l s _ { 2 } ] )$ , which represents an aggregated history of input observations.
293
+
294
+ Relational processing. outputs $3 D$ is flattened along the first two dimensions (forming a 2D tensor of shape $[ 6 4 \times$ #channels2] and passed to the stacked MHDPA blocks (see Table 3 for details). Its output tensors (of shape $6 4 \times$ attention embedding size $^ *$ number of attention heads]) follow two separate pathways – relational-spatial: reshapes the tensors to their original spatial shape $[ 8 \times 8 ]$ ; relational-nonspatial: aggregates through a feature-wise max-pooling operation (combining the 64 embeddings into a flat tensor) and further processes using a 2-layer MLP (512 units per layer, ReLU activations).
295
+
296
+ Output processing. $i n p u t s _ { 2 D }$ and relational-nonspatial are concatenated to form a set of shared features. Policy logits are produced by feeding shared features to a 2-layer MLP (256 units, ReLU, $| a c t i o n s |$ units) and masking unavailable actions (following Vinyals et al. (2017)). Similarly, baselines values $V$ are generated by feeding shared features to a separate 2-layer MLP (256 units, ReLU, 1 unit).
297
+
298
+ Actions are sampled using computed policy logits and embedded into a 16 dimensional vector. This embedding is used to condition shared features and generate logits for non-spatial arguments (Args) through independent linear combinations (one for each argument). Finally, spatial arguments $( A r g s _ { x , y } )$ are obtained by first deconvolving relational-spatial to $[ 3 2 \times 3 2 \times \# c h a n n e l s _ { 3 } ]$ tensors using Conv2DTranspose layers, conditioned by tiling the action embedding along the depth dimension and passed by $1 \times 1 \times 1$ convolution layers (one for each spatial argument). Spatial arguments $( x , y )$ are produced by sampling resulting tensors and selecting the corresponding row and column indexes.
299
+
300
+ Table 2: Shared fixed hyperparameters across mini-games.
301
+
302
+ <table><tr><td>Hyperparameter</td><td>Value</td></tr><tr><td>Conv2DLSTM</td><td></td></tr><tr><td>Output channels(#channels2)</td><td>96</td></tr><tr><td>Kernel shape</td><td>(3,3)</td></tr><tr><td>Stride</td><td>(1,1)</td></tr><tr><td>Conv2DTranspose</td><td></td></tr><tr><td>Output channels (#channels3)</td><td>16</td></tr><tr><td>Kernel shape</td><td>(4, 4)</td></tr><tr><td>Stride</td><td>(2,2)</td></tr><tr><td>Discount (γ)</td><td>0.99</td></tr><tr><td>Batch size</td><td>32</td></tr><tr><td>Unroll Length</td><td>80</td></tr><tr><td>Baseline loss scaling</td><td>0.1</td></tr><tr><td>Clip global gradient norm</td><td>100.0</td></tr><tr><td>Adam β1</td><td>0.9</td></tr><tr><td>Adam β2</td><td>0.999</td></tr><tr><td>Adam e</td><td>1e-8</td></tr></table>
303
+
304
+ Table 3: Fixed MHDPA settings for StarCraft II mini-games.
305
+
306
+ <table><tr><td>Setting Value</td></tr><tr><td>MLP layers 2</td></tr><tr><td>Units per MLP layer 384</td></tr><tr><td>MLP activations ReLU</td></tr><tr><td>Attention embedding size 32</td></tr><tr><td>Weight sharing shared MLP across blocks</td></tr><tr><td>shared embedding across blocks</td></tr></table>
307
+
308
+ # CONTROL AGENT ARCHITECTURE
309
+
310
+ The control agent architecture only differs on the relational processing part of the pipeline. Analogous to the relational agent, output $\beta _ { 2 D }$ are obtained from Conv2DLSTM layers. These tensors are first passed to a 12-layer deep residual model – comprising 4 blocks of 3 convolutions layers (32 output channels, $4 \times 4$ kernel for the first convolution and $3 \times 3$ for the second and third, and stride 1) interleaved with ReLU activations and skip-connections – as proposed by He et al. (2016), to form the relational-spatial outputs. These tensors also follow a separate pathway where they are flattened and passed to a 2-layer MLP (512 units per layer, ReLU activations) to produce what we refer to above as relational-nonspatial. The remaining architecture is identical to the relational agent.
311
+
312
+ Table 4: Swept hyperparameters across mini-games.
313
+
314
+ <table><tr><td>Hyperparameter</td><td>Value</td></tr><tr><td>Relational module</td><td></td></tr><tr><td>Number of heads</td><td>[1,3]</td></tr><tr><td>Number of blocks</td><td>[1, 3, 5]</td></tr><tr><td>Entropy loss scaling</td><td>[le-1,le-2,le-3]</td></tr><tr><td>Adam learning rate</td><td>[le-4,le-5]</td></tr></table>
parse/train/HkxaFoC9KQ/HkxaFoC9KQ_content_list.json ADDED
@@ -0,0 +1,1802 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [
2
+ {
3
+ "type": "text",
4
+ "text": "DEEP REINFORCEMENT LEARNING WITH RELATIONAL INDUCTIVE BIASES ",
5
+ "text_level": 1,
6
+ "bbox": [
7
+ 176,
8
+ 101,
9
+ 823,
10
+ 145
11
+ ],
12
+ "page_idx": 0
13
+ },
14
+ {
15
+ "type": "text",
16
+ "text": "Vinicius Zambaldi∗, David Raposo∗, Adam Santoro∗, Victor Bapst, Yujia Li, Igor Babuschkin, Karl Tuyls, David Reichert, Timothy Lillicrap, Edward Lockhart, Murray Shanahan, Victoria Langston, Razvan Pascanu, Matthew Botvinick, Oriol Vinyals, Peter Battaglia ",
17
+ "bbox": [
18
+ 184,
19
+ 169,
20
+ 802,
21
+ 234
22
+ ],
23
+ "page_idx": 0
24
+ },
25
+ {
26
+ "type": "text",
27
+ "text": "DeepMind, London, UK {vzambaldi,draposo,adamsantoro}@google.com ",
28
+ "bbox": [
29
+ 184,
30
+ 252,
31
+ 596,
32
+ 284
33
+ ],
34
+ "page_idx": 0
35
+ },
36
+ {
37
+ "type": "text",
38
+ "text": "ABSTRACT ",
39
+ "text_level": 1,
40
+ "bbox": [
41
+ 454,
42
+ 321,
43
+ 544,
44
+ 337
45
+ ],
46
+ "page_idx": 0
47
+ },
48
+ {
49
+ "type": "text",
50
+ "text": "We introduce an approach for augmenting model-free deep reinforcement learning agents with a mechanism for relational reasoning over structured representations, which improves performance, learning efficiency, generalization, and interpretability. Our architecture encodes an image as a set of vectors, and applies an iterative message-passing procedure to discover and reason about relevant entities and relations in a scene. In six of seven StarCraft II Learning Environment mini-games, our agent achieved state-of-the-art performance, and surpassed human grandmasterlevel on four. In a novel navigation and planning task, our agent’s performance and learning efficiency far exceeded non-relational baselines, it was able to generalize to more complex scenes than it had experienced during training. Moreover, when we examined its learned internal representations, they reflected important structure about the problem and the agent’s intentions. The main contribution of this work is to introduce techniques for representing and reasoning about states in model-free deep reinforcement learning agents via relational inductive biases. Our experiments show this approach can offer advantages in efficiency, generalization, and interpretability, and can scale up to meet some of the most challenging test environments in modern artificial intelligence. ",
51
+ "bbox": [
52
+ 233,
53
+ 353,
54
+ 766,
55
+ 588
56
+ ],
57
+ "page_idx": 0
58
+ },
59
+ {
60
+ "type": "text",
61
+ "text": "1 INTRODUCTION ",
62
+ "text_level": 1,
63
+ "bbox": [
64
+ 176,
65
+ 613,
66
+ 336,
67
+ 628
68
+ ],
69
+ "page_idx": 0
70
+ },
71
+ {
72
+ "type": "text",
73
+ "text": "Recent deep reinforcement learning (RL) systems have achieved remarkable performance in very challenging problem domains (Mnih et al., 2015; Silver et al., 2016), in large part because of their flexibility in how they learn and exploit the statistical structure underlying observations and reward signals. But the downsides to such flexibility often include low sample efficiency and poor transfer beyond the specifics of the training environment (Zhang et al., 2018; Lake et al., 2017; Kansky et al., 2017). Various structured approaches to RL (e.g. Dzeroski et al. (2001); Driessens & Dzeroski (2004); Diuk et al. (2008); Garnelo et al. (2016)) have attempted to overcome these limitations by explicitly incorporating entity-based and symbolic representations, and specialized building blocks for solving the task at hand. Although these approaches are often highly efficient, they constrain the representations and admissible learning algorithms, they struggle to learn rich representations, and they are therefore confined to relatively simple tasks and data conditions. ",
74
+ "bbox": [
75
+ 174,
76
+ 645,
77
+ 825,
78
+ 797
79
+ ],
80
+ "page_idx": 0
81
+ },
82
+ {
83
+ "type": "text",
84
+ "text": "To strike favorable tradeoffs between flexibility and efficiency, a number of recent approaches have explored using relational inductive biases in deep learning, to reap the benefits of flexible statistical learning and more structured approaches. Methods such as “graph networks” (Scarselli et al., 2009; Li et al., 2015; Battaglia et al., 2018) explicitly represent entities and their relations using using sets and graphs, and perform relational reasoning using learned message-passing (Gilmer et al., 2017) and attention (Vaswani et al., 2017; Hoshen, 2017; Velickovic et al., 2017; Wang et al., 2017) schemes. Because they are implemented using deep neural networks, they can learn transformations from input observations into task-relevant entities, as well as functions for computing rich interaction among these entities. This provides a powerful capacity for combinatorial generalization, where their learned building blocks can be composed to represent and reason about novel scenarios (Battaglia et al., 2016; Raposo et al., 2017; Dai et al., 2017; Wang et al., 2018; Selsam et al., 2018; Hamrick et al., 2018; Kipf et al., 2018; Sanchez-Gonzalez et al., 2018). ",
85
+ "bbox": [
86
+ 174,
87
+ 804,
88
+ 825,
89
+ 902
90
+ ],
91
+ "page_idx": 0
92
+ },
93
+ {
94
+ "type": "image",
95
+ "img_path": "images/5c822588dfeea2de0a334b5cd697ba4399066fb4f496cf8c18238a9bfe656daf.jpg",
96
+ "image_caption": [
97
+ "Figure 1: Box-World and StarCraft II tasks demand reasoning about entities and their relations. "
98
+ ],
99
+ "image_footnote": [],
100
+ "bbox": [
101
+ 204,
102
+ 98,
103
+ 789,
104
+ 232
105
+ ],
106
+ "page_idx": 1
107
+ },
108
+ {
109
+ "type": "text",
110
+ "text": "",
111
+ "bbox": [
112
+ 174,
113
+ 299,
114
+ 825,
115
+ 369
116
+ ],
117
+ "page_idx": 1
118
+ },
119
+ {
120
+ "type": "text",
121
+ "text": "Drawing on several lines of work, we introduce an approach for incorporating relational inductive biases for entity- and relation-centric state representations, and iterated relational reasoning, into a deep RL agent. In contrast with prior work exploring relational inductive biases in deep RL (e.g., Wang et al., 2018), our approach does not rely on a priori knowledge of the structure of the problem and is agnostic to the particular relations that need to be considered. To handle raw visual input data, our architecture used a convolutional front-end to compute embeddings of sets of entities, similar to previous work in visual question answering, physical prediction, and video understanding (Santoro et al., 2017; Watters et al., 2017; Wang et al., 2017). To perform relational reasoning, we used a self-attention mechanism (Vaswani et al., 2017; Hoshen, 2017; Velickovic et al., 2017) applied iteratively within each timestep, which can be viewed as learned message-passing (Li et al., 2015; Gilmer et al., 2017). Our deep RL agent is based on an off-policy advantage actor-critic (A2C) method which is very effective across a range of standard RL environments (Espeholt et al., 2018). ",
122
+ "bbox": [
123
+ 174,
124
+ 376,
125
+ 825,
126
+ 542
127
+ ],
128
+ "page_idx": 1
129
+ },
130
+ {
131
+ "type": "text",
132
+ "text": "Our results show that this relational deep RL agent scale to very challenging tasks, achieving state-ofthe-art performance on six out of seven StarCraft II mini-games (Vinyals et al., 2017), surpassing grandmaster level on four mini-games. Additionally, we introduce a novel navigation and planning task, called “Box-World”, which stresses the planning and reasoning components of the policy, factoring out other challenges like complex vision or large action spaces. Our agent reaches higher ceiling performance, more efficiently, than non-relational baseline, and is able to generalize to solve problems with more complex solutions than it had been trained on within this task. We also found that the intermediate representations involved in the relational computations were interpretable, and suggest that the agent has rich understanding of the underlying structure of the problem. ",
133
+ "bbox": [
134
+ 174,
135
+ 549,
136
+ 825,
137
+ 675
138
+ ],
139
+ "page_idx": 1
140
+ },
141
+ {
142
+ "type": "text",
143
+ "text": "2 RELATIONAL DEEP RL AGENT ARCHITECTURE ",
144
+ "text_level": 1,
145
+ "bbox": [
146
+ 174,
147
+ 712,
148
+ 593,
149
+ 728
150
+ ],
151
+ "page_idx": 1
152
+ },
153
+ {
154
+ "type": "text",
155
+ "text": "RL ALGORITHM ",
156
+ "text_level": 1,
157
+ "bbox": [
158
+ 176,
159
+ 753,
160
+ 287,
161
+ 767
162
+ ],
163
+ "page_idx": 1
164
+ },
165
+ {
166
+ "type": "text",
167
+ "text": "We started with a deep RL algorithm based on a distributed advantage actor-critic (A2C) method (Espeholt et al., 2018), which the schematic on the left of Figure 2 summarizes. The agent creates an embedded state representation, $S$ from its input observation, which is then used to compute as output a policy, $\\pi$ (the “actor”), and a baseline value, $B$ (the “critic”). The $\\pi$ consists of logits over the set of possible actions, from which an action to perform is sampled, and the $B$ is an estimate of the statevalue function at the current state. During learning, the $B$ is used to compute the temporal-difference error, which is used both to optimize $\\pi$ to generate actions with greater returns than $B$ predicts, and to optimize $B$ to more accurately estimate state values. For further algorithmic details, including the distributed actor/learner framework and off-policy correction methods, please see Espeholt et al. (2018). ",
168
+ "bbox": [
169
+ 173,
170
+ 785,
171
+ 825,
172
+ 924
173
+ ],
174
+ "page_idx": 1
175
+ },
176
+ {
177
+ "type": "image",
178
+ "img_path": "images/8bfc778b0d4448fb937ffa5bf0924c16cd775e8a977b685163c8c39e78217311.jpg",
179
+ "image_caption": [
180
+ "Figure 2: Box-World agent architecture and multi-head dot-product attention. $E$ is a matrix that compiles the entities produced by the visual front-end; $g _ { \\theta }$ is a multilayer perceptron applied in parallel to each row of the output of an MHDPA step, $A$ , and producing updated entities, $\\widetilde { E }$ . "
181
+ ],
182
+ "image_footnote": [],
183
+ "bbox": [
184
+ 181,
185
+ 106,
186
+ 818,
187
+ 314
188
+ ],
189
+ "page_idx": 2
190
+ },
191
+ {
192
+ "type": "text",
193
+ "text": "INPUT MODULE ",
194
+ "text_level": 1,
195
+ "bbox": [
196
+ 174,
197
+ 400,
198
+ 284,
199
+ 414
200
+ ],
201
+ "page_idx": 2
202
+ },
203
+ {
204
+ "type": "text",
205
+ "text": "Our agent takes as input an image of a scene, transforms it into an embedded state representation, $S$ , which is a spatial feature map returned by a convolutional neural network (CNN). The relational module (Figure 2) operated on a set of entities, so our architecture transformed the $m \\times n \\times f$ feature map into an $N \\times f$ (where $N = m \\cdot n$ ) set of “entity vectors”, $E$ , by reshaping $S$ so that each of $E$ ’s row, $\\mathbf { e } _ { i }$ , corresponded to a feature vector, $\\mathbf { s } _ { x , y }$ , at a particular $x , y$ location in the embedded scene. Crucially, this allowed for non-local computation between entities (Wang et al., 2017), unconstrained by their coordinates in the spatial feature map. Because removing the spatial map’s coordinate structure could prevent spatial information from being available for downstream computation, we concatenated the spatial $x , y$ coordinates of each $\\mathbf { s } _ { x , y }$ onto the corresponding $\\mathbf { e } _ { i }$ to ensure it was preserved. This feature-to-entity transformation procedure is analogous to how relation networks, visual interaction networks, and the general class of non-local neural networks (Santoro et al., 2017; Watters et al., 2017; Wang et al., 2017) process input images. ",
206
+ "bbox": [
207
+ 174,
208
+ 424,
209
+ 826,
210
+ 592
211
+ ],
212
+ "page_idx": 2
213
+ },
214
+ {
215
+ "type": "text",
216
+ "text": "RELATIONAL MODULE ",
217
+ "text_level": 1,
218
+ "bbox": [
219
+ 176,
220
+ 609,
221
+ 331,
222
+ 622
223
+ ],
224
+ "page_idx": 2
225
+ },
226
+ {
227
+ "type": "text",
228
+ "text": "To perform one step of relational reasoning, our architecture computed pairwise interactions between each entity and all others (including itself), denoted $\\mathbf { p } _ { i , j }$ , and updated each entity by accumulating information about all of its interactions, $\\tilde { \\mathbf { e } } _ { i } \\gets \\{ \\mathbf { p } _ { i , j } \\} _ { j = 1 : N }$ . This is analogous to how the general class of graph neural networks and their relatives perform entity-wise relational updates (Scarselli et al., 2009; Gilmer et al., 2017). To perform these one-step relational computations, we used self-attention (Vaswani et al., 2017; Hoshen, 2017; Velickovic et al., 2017; Wang et al., 2017), though various other implementations (e.g., those reviewed in Battaglia et al. (2018)) should also be viable. ",
229
+ "bbox": [
230
+ 174,
231
+ 633,
232
+ 825,
233
+ 731
234
+ ],
235
+ "page_idx": 2
236
+ },
237
+ {
238
+ "type": "text",
239
+ "text": "Our specific self-attention implementation was based on Vaswani et al. (2017)’s multi-head dotproduct attention (MHDPA), which we explain in detail to make clear its role as a mechanism of relational reasoning. MHDPA (see Figure 2’s expanded box) projects the entities, $E$ , into matrices of query, key, and value vectors, $Q , K$ , and $V$ , respectively (which are normalized via “layer normalization” (Ba et al., 2016)). The similarities between query $\\mathbf { q } _ { i }$ and all keys, $\\mathbf { k } _ { j = 1 : N }$ are computed by a dot-product, which are normalized into attention weights, $\\mathbf { w } _ { i }$ , via a softmax function, and then used to compute the pairwise interaction terms, $\\mathbf { p } _ { i , j } = w _ { i , j } \\mathbf { v } _ { j }$ . The accumulation of the interactions for each entity is the sum of these pairwise interactions, $\\begin{array} { r } { \\mathbf { a } _ { i } = \\sum _ { j = 1 : N } \\mathbf { p } _ { i , j } } \\end{array}$ . This can be efficiently computed using matrix multiplications, $A = \\mathrm { s o f t m a x } ( d ^ { - { \\frac { 1 } { 2 } } } Q K ^ { T } ) V$ , where $d$ is the dimensionality of the query and key vectors (i.e. $Q$ and $K$ have shape $N \\times d )$ . Like Vaswani et al. (2017), we also use multiple, independent attention “heads”, applied in parallel (which our attention analyses in Results 3.1 suggests the heads may assume distinct relational semantics through training). The updated entities are computed as a function of the accumulated interactions, $\\tilde { \\mathbf { e } } _ { i } = \\breve { g _ { \\theta } } \\left( \\mathbf { a } _ { i } ^ { h = 1 : \\breve { H } } \\right)$ ",
240
+ "bbox": [
241
+ 173,
242
+ 738,
243
+ 826,
244
+ 924
245
+ ],
246
+ "page_idx": 2
247
+ },
248
+ {
249
+ "type": "image",
250
+ "img_path": "images/6118afe1c717ba4bed79c7d07ad7ffdb8f5e73e37d7fb84f0a56124d3a26e4a8.jpg",
251
+ "image_caption": [
252
+ "Figure 3: Box-World task: example observations (left), underlying graph structure that determines the proper path to the goal and the distractor branches (middle), and training curves (right). "
253
+ ],
254
+ "image_footnote": [],
255
+ "bbox": [
256
+ 207,
257
+ 98,
258
+ 787,
259
+ 337
260
+ ],
261
+ "page_idx": 3
262
+ },
263
+ {
264
+ "type": "text",
265
+ "text": "(where $h$ indexes the head) by concatenating all $\\mathbf { a } _ { i } ^ { h = 1 : H }$ together, passing them to a multilayer perceptron (MLP), summing the output with $\\mathbf { e } _ { i }$ (i.e. a residual connection), and applying a final stage of layer normalization (Ba et al., 2016). We included this non-linear transformation $\\left( g _ { \\boldsymbol { \\theta } } \\right)$ to facilitate the computation of more complex relationships between the entities. This is analogous to what is done in Santoro et al. (2017). ",
266
+ "bbox": [
267
+ 174,
268
+ 405,
269
+ 825,
270
+ 476
271
+ ],
272
+ "page_idx": 3
273
+ },
274
+ {
275
+ "type": "text",
276
+ "text": "This one-step relational update process, which we term a “block”, can be applied iteratively using shared (recurrent) or unshared (deep) parameters, to compute higher order interactions among entities, analogous to message-passing on graphs (Li et al., 2015; Gilmer et al., 2017). Here we refer to the stack of multiple relational blocks as the relational module. ",
277
+ "bbox": [
278
+ 176,
279
+ 482,
280
+ 825,
281
+ 537
282
+ ],
283
+ "page_idx": 3
284
+ },
285
+ {
286
+ "type": "text",
287
+ "text": "OUTPUT MODULE ",
288
+ "text_level": 1,
289
+ "bbox": [
290
+ 176,
291
+ 558,
292
+ 299,
293
+ 570
294
+ ],
295
+ "page_idx": 3
296
+ },
297
+ {
298
+ "type": "text",
299
+ "text": "The relational module’s final output, $\\tilde { E }$ , is then used to compute $\\pi$ and $B$ as follows. The $\\tilde { E }$ matrix, with shape $N \\times f$ , is reduced to an $f$ -dimensional vector by max-pooling over the entity dimension. This pooled vector is then passed to a small MLP, which returns an $( c + 1 )$ -dimensional vector. This vector is split into a $c$ -dimensional vector of $\\pi$ ’s logits (where $c$ is the number of discrete actions), and a scalar baseline value estimate, $B$ . The $\\pi$ logits are normalized using a softmax function, and used as probability parameters for a multinomial distribution, from which an action is randomly sampled. ",
300
+ "bbox": [
301
+ 174,
302
+ 582,
303
+ 826,
304
+ 666
305
+ ],
306
+ "page_idx": 3
307
+ },
308
+ {
309
+ "type": "text",
310
+ "text": "3 EXPERIMENTS AND RESULTS ",
311
+ "text_level": 1,
312
+ "bbox": [
313
+ 178,
314
+ 690,
315
+ 444,
316
+ 705
317
+ ],
318
+ "page_idx": 3
319
+ },
320
+ {
321
+ "type": "text",
322
+ "text": "3.1 BOX-WORLD ",
323
+ "text_level": 1,
324
+ "bbox": [
325
+ 174,
326
+ 722,
327
+ 308,
328
+ 737
329
+ ],
330
+ "page_idx": 3
331
+ },
332
+ {
333
+ "type": "text",
334
+ "text": "TASK DESCRIPTION ",
335
+ "bbox": [
336
+ 176,
337
+ 750,
338
+ 310,
339
+ 763
340
+ ],
341
+ "page_idx": 3
342
+ },
343
+ {
344
+ "type": "text",
345
+ "text": "We first introduce a controlled navigation environment, called Box-World1, which we designed to be perceptually simple, but combinatorially complex, and require abstract relational reasoning and planning. It consists of a $1 2 \\times 1 2$ pixel room with keys and boxes scattered randomly. The room also contains an agent, represented by a single dark gray pixel, which can move in four directions: $u p$ down, left, right (see Figure 1). ",
346
+ "bbox": [
347
+ 174,
348
+ 775,
349
+ 825,
350
+ 844
351
+ ],
352
+ "page_idx": 3
353
+ },
354
+ {
355
+ "type": "text",
356
+ "text": "Keys are represented by a single colored pixel. The agent can pick up a loose key (i.e., one not adjacent to any other colored pixel) by walking the avatar (i.e. the visual depiction of the agent’s location) over it. Boxes are represented by two adjacent colored pixels – the pixel on the right represents the box’s lock and its color indicates which key can be used to open that lock; the pixel on the left indicates the content of the box which is inaccessible while the box is locked. ",
357
+ "bbox": [
358
+ 178,
359
+ 852,
360
+ 821,
361
+ 895
362
+ ],
363
+ "page_idx": 3
364
+ },
365
+ {
366
+ "type": "text",
367
+ "text": "",
368
+ "bbox": [
369
+ 171,
370
+ 103,
371
+ 821,
372
+ 131
373
+ ],
374
+ "page_idx": 4
375
+ },
376
+ {
377
+ "type": "text",
378
+ "text": "To collect the content of a box the agent must first collect the key that opens the box (the one that matches the lock’s color), and then walk over the lock, which makes the lock disappear. At this point the content of the box becomes accessible and can be picked up by the agent. Most boxes contain keys that, if made accessible, can be used to open other boxes. One of the boxes contains a gem, represented by a single white pixel. The agent’s goal is to acquire the gem by unlocking the box that contains it and picking it up by walking over it. Keys that an agent has in its possession are depicted in the input observation as a pixel in the top-left corner. ",
379
+ "bbox": [
380
+ 174,
381
+ 140,
382
+ 825,
383
+ 236
384
+ ],
385
+ "page_idx": 4
386
+ },
387
+ {
388
+ "type": "text",
389
+ "text": "In each level there is a unique sequence of boxes that need to be opened in order to reach the gem. Opening one wrong box (a distractor box) consumes the held key and leads to a dead-end, where the gem cannot be reached and the level becomes unsolvable. There are three user-controlled parameters that contribute to the difficulty of the level: 1) the number of boxes in the path to the goal (solution length); 2) the number of distractor branches; 3) the length of the distractor branches. In general, the task is computationally difficult for a few reasons. First, a key can only be used once, so the agent must be able to reason about whether a particular box is along a distractor branch or along the solution path. Second, keys and boxes appear in random locations in the room, demanding a capacity to reason about keys and boxes based on their abstract relations, rather than based on their spatial proximity. ",
390
+ "bbox": [
391
+ 174,
392
+ 243,
393
+ 825,
394
+ 382
395
+ ],
396
+ "page_idx": 4
397
+ },
398
+ {
399
+ "type": "text",
400
+ "text": "RL AGENTS FOR BOX-WORLD ",
401
+ "text_level": 1,
402
+ "bbox": [
403
+ 176,
404
+ 402,
405
+ 388,
406
+ 416
407
+ ],
408
+ "page_idx": 4
409
+ },
410
+ {
411
+ "type": "text",
412
+ "text": "Our agent follows the reinforcement learning setup and architecture described in section (Sec. 2). For a non-relational baseline, we replaced the agent’s relational module with a variable number of residual convolution blocks. See the Appendix for further details of the input, relational, and output modules, including hyperparameters and training procedures. ",
413
+ "bbox": [
414
+ 174,
415
+ 429,
416
+ 825,
417
+ 484
418
+ ],
419
+ "page_idx": 4
420
+ },
421
+ {
422
+ "type": "text",
423
+ "text": "RESULTS ",
424
+ "text_level": 1,
425
+ "bbox": [
426
+ 176,
427
+ 505,
428
+ 238,
429
+ 518
430
+ ],
431
+ "page_idx": 4
432
+ },
433
+ {
434
+ "type": "text",
435
+ "text": "The training set-up consisted of Box-World levels with solution lengths of at least 1 and up to 4. This ensured that an untrained agent would have a small probability of reaching the goal by chance, at least on some levels.2 The number of distractor branches was randomly sampled from 0 to 4. Training was split into two variants of the task: one with distractor branches of length 1; another one with distractor branches of length 3 (see Figure 3). ",
436
+ "bbox": [
437
+ 174,
438
+ 531,
439
+ 823,
440
+ 601
441
+ ],
442
+ "page_idx": 4
443
+ },
444
+ {
445
+ "type": "text",
446
+ "text": "Agents augmented with our relational module achieved close to optimal performance in the two variants of this task, solving more than $98 \\%$ of the levels. In the task variant with short distractor branches, an agent with a single relational block was able to achieve top performance. In the variant with long distractor branches, a greater number of relational blocks was required, consistent with the conjecture that more blocks allow higher-order relational computations. In contrast, our baseline agents, which can only rely on convolutional and fully-connected layers, performed significantly worse, solving less than $7 5 \\%$ of the levels across the two task variants. We observed similar results when we repeated the experiments using two alternative RL algorithms: asynchronous advantage actor-critic (A3C, Mnih et al., 2016) and distributed Q-learning with prioritized experience replay (Horgan et al., 2018). We note that with Q-learning training took significantly longer (see Figure 7 in Appendix). ",
447
+ "bbox": [
448
+ 174,
449
+ 608,
450
+ 825,
451
+ 760
452
+ ],
453
+ "page_idx": 4
454
+ },
455
+ {
456
+ "type": "text",
457
+ "text": "We also repeated these experiments, but with backward branching in the underlying graph used to generate the level. With backward branching the agent does not need to plan far into the future; when it is in possession of a key, a successful strategy is always to open the matching lock. In contrast, with forward branching scenes, the agent can use a key on the wrong lock (i.e. on a lock along a distractor branch). Thus, forward branching demands more complicated forward planning to determine the correct locks to open, which contrasts with backward branching scenarios where an agent can adopt a more reactive policy, always opting to open the lock that matches the key in possession. Indeed, the baseline agents performed much better in backward (versus forward) branching scenes, which suggests that its weak relational reasoning capacity is to blame for its poor performance in the forward branching condition (see Figure 8 in Appendix). ",
458
+ "bbox": [
459
+ 174,
460
+ 767,
461
+ 825,
462
+ 878
463
+ ],
464
+ "page_idx": 4
465
+ },
466
+ {
467
+ "type": "image",
468
+ "img_path": "images/beb04b6ec5b9b8cc5e50650e51e3e5c6fff6aadf5786f1a3d827447fd82403ac.jpg",
469
+ "image_caption": [
470
+ "Figure 4: Visualization of attention weights. (a) The underlying graph of one example level; (b) the result of the analysis for that level, using each of the entities along the solution path (1–5) as the source of attention. Arrows point to the entities that the source is attending to. An arrow’s transparency is determined by the corresponding attention weight. "
471
+ ],
472
+ "image_footnote": [],
473
+ "bbox": [
474
+ 225,
475
+ 99,
476
+ 771,
477
+ 348
478
+ ],
479
+ "page_idx": 5
480
+ },
481
+ {
482
+ "type": "text",
483
+ "text": "",
484
+ "bbox": [
485
+ 174,
486
+ 446,
487
+ 821,
488
+ 474
489
+ ],
490
+ "page_idx": 5
491
+ },
492
+ {
493
+ "type": "text",
494
+ "text": "VISUALIZATION OF ATTENTION WEIGHTS ",
495
+ "text_level": 1,
496
+ "bbox": [
497
+ 178,
498
+ 493,
499
+ 460,
500
+ 506
501
+ ],
502
+ "page_idx": 5
503
+ },
504
+ {
505
+ "type": "text",
506
+ "text": "We next looked at specific rows of the attention weight matrix, $\\mathbf { w } _ { i }$ , which corresponded to relevant objects in the scene. Figure 4 shows the result of this analysis when the attending entities (source of the attention) are objects along the solution path. For one of the attention heads, each key attends mostly to the locks that can be unlocked with that key. In other words, the attention weights reflect the options available to the agent once a key is collected. For another attention head, each key attends mostly to the avatar’s entity vector. This suggests that object-avatar relations are important, which may help measure of relative position and support navigation. ",
507
+ "bbox": [
508
+ 174,
509
+ 518,
510
+ 825,
511
+ 616
512
+ ],
513
+ "page_idx": 5
514
+ },
515
+ {
516
+ "type": "text",
517
+ "text": "In the case of RGB pixel inputs, the relationship between keys and locks that can be opened with that key is confounded with the fact that keys and the corresponding locks have the same RGB representation. We therefore repeated the analysis, this time using one-hot representation of the input, where the mapping between keys and the corresponding locks is arbitrary. We found evidence that: 1) keys attend to the locks they can unlock; 2) locks attend to the keys that can be used to unlock them; 3) all the objects attend to the avatar’s location; 4) the avatar and gem attend to each other and themselves. ",
518
+ "bbox": [
519
+ 174,
520
+ 622,
521
+ 825,
522
+ 719
523
+ ],
524
+ "page_idx": 5
525
+ },
526
+ {
527
+ "type": "text",
528
+ "text": "GENERALIZATION CAPABILITY: TESTING ON WITHHELD ENVIRONMENTS ",
529
+ "text_level": 1,
530
+ "bbox": [
531
+ 176,
532
+ 739,
533
+ 678,
534
+ 752
535
+ ],
536
+ "page_idx": 5
537
+ },
538
+ {
539
+ "type": "text",
540
+ "text": "As we observed, the attention weights captured a link between a key and its corresponding lock, using a shared computation across entities. If the function used to compute the weights (and hence, used to determine that certain keys and locks are related) has learned to represent some general, abstract notion of what it means to “unlock” – e.g., unlocks(key, lock) – then this function should be able to generalize to key-lock combinations that it has never observed during training. Similarly, a capacity to understand “unlocking” shouldn’t necessarily be affected by the number of locks that need to be unlocked to reach a solution. ",
541
+ "bbox": [
542
+ 174,
543
+ 763,
544
+ 825,
545
+ 861
546
+ ],
547
+ "page_idx": 5
548
+ },
549
+ {
550
+ "type": "text",
551
+ "text": "We thus tested the model under two conditions, without further training: 1) on levels that required opening a longer sequence of boxes than it had ever observed (6, 8 and 10), and 2) on levels that required using a key-lock combination that was never required for reaching the gem during training, instead only being placed on distractor paths. As shown in Figure 5, in the first condition, the agent with the relational module solved more than $8 8 \\%$ of the levels, across all three solution length conditions. In contrast, the performance of the agent trained without the relational module collapsed to $5 \\%$ when tested on sequences of 6 boxes, and to $0 \\%$ on sequences of 8 and 10. On levels with new key-lock combinations, the agent augmented with a relational module solved $9 7 \\%$ of the new levels. The agent without the relational module performed poorly, reaching only $13 \\%$ . Together, these results show that the relational module offers a greater capacity for zero-shot transfer to more complex and previously unseen problems. This is likely a consequence of our approach’s object- and relation-centric learning, which is less sensitive to the specific conjunctions of objects and relations it has experienced during training. ",
552
+ "bbox": [
553
+ 174,
554
+ 867,
555
+ 825,
556
+ 924
557
+ ],
558
+ "page_idx": 5
559
+ },
560
+ {
561
+ "type": "image",
562
+ "img_path": "images/a02836fc44696892da9ab8b0409a3d108982124448e2cce0f32f471ecb3f9e38.jpg",
563
+ "image_caption": [
564
+ "Figure 5: Generalization in Box-World. Zero-shot transfer to levels that required: (a) opening a longer sequence of boxes; (b) using a key-lock combination that was never required during training. "
565
+ ],
566
+ "image_footnote": [],
567
+ "bbox": [
568
+ 223,
569
+ 103,
570
+ 776,
571
+ 297
572
+ ],
573
+ "page_idx": 6
574
+ },
575
+ {
576
+ "type": "text",
577
+ "text": "",
578
+ "bbox": [
579
+ 174,
580
+ 363,
581
+ 825,
582
+ 489
583
+ ],
584
+ "page_idx": 6
585
+ },
586
+ {
587
+ "type": "text",
588
+ "text": "3.2 STARCRAFT II MINI-GAMES ",
589
+ "text_level": 1,
590
+ "bbox": [
591
+ 176,
592
+ 506,
593
+ 408,
594
+ 520
595
+ ],
596
+ "page_idx": 6
597
+ },
598
+ {
599
+ "type": "text",
600
+ "text": "TASK DESCRIPTION ",
601
+ "text_level": 1,
602
+ "bbox": [
603
+ 176,
604
+ 532,
605
+ 312,
606
+ 546
607
+ ],
608
+ "page_idx": 6
609
+ },
610
+ {
611
+ "type": "text",
612
+ "text": "StarCraft II is a popular video game that presents a difficult challenge for RL agents. It is a multiagent game where each player controls a large number (hundreds) of units that need to interact and collaborate (see Figure 1). It is partially observable and has a large state and action space, with more than 100 possible actions. The consequences of any single action – in particular, early decisions in the game – are typically only observed many frames later, posing difficulties in temporal credit assignment and exploration. ",
613
+ "bbox": [
614
+ 174,
615
+ 556,
616
+ 825,
617
+ 640
618
+ ],
619
+ "page_idx": 6
620
+ },
621
+ {
622
+ "type": "text",
623
+ "text": "We trained our agents on the suite of 7 mini-games developed for the StarCraft II Learning Environment (SC2LE, Vinyals et al., 2017). These mini-games were proposed as a set of specific scenarios that are representative of the mechanics of the full game and can be used to test agents in a simpler set up with a better defined reward structure, compared to the full game. The 7 mini-games demand different strategies and skills. Notably, Collect Mineral Shards (CMS), Defeat Roaches (DR) and Defeat Zerglings and Banelings (DZB), require controlling multiple units with precision and in a coordinated manner. To achieve a high score in CMS, the player (or agent) needs to command the two marines independently, defining navigation paths that do not overlap too much in order to efficiently cover most of the ground. In DR, the player must focus-fire to succeed, which requires selecting the same attack target, one at a time, for all the marines. In DZB, the enemy units have different abilities, so a good strategy may involve splitting the army into groups with different roles. ",
624
+ "bbox": [
625
+ 174,
626
+ 647,
627
+ 825,
628
+ 800
629
+ ],
630
+ "page_idx": 6
631
+ },
632
+ {
633
+ "type": "text",
634
+ "text": "RL AGENTS FOR STARCRAFT II ",
635
+ "text_level": 1,
636
+ "bbox": [
637
+ 176,
638
+ 815,
639
+ 398,
640
+ 829
641
+ ],
642
+ "page_idx": 6
643
+ },
644
+ {
645
+ "type": "text",
646
+ "text": "For StarCraft II (SC2), we start by first constructing a strong control baseline to test against our relational agent. The architecture is similar to that of the Box-World agent, with changes to accommodate specific features of the SC2 environment. We increased the model capacity by using 2 residual convolutional blocks in the input module, each consisting of 3 convolutional layers. We added a 2D-ConvLSTM immediately downstream of the residual blocks, so the subsequent computations were sensitive to the recent history of observations, rather than only the current observation, thus accounting for partial observability. Including this memory mechanism was important because the actions a StarCraft agent issues to units are carried out over multiple timesteps (e.g., MOVE UNIT 3 TO COORDINATE (1, 5)), and the agent needs a way of not “forgetting” what actions it has issued previously. Otherwise it might keep reissuing the same action to a unit, rather than choosing another action for another unit. Finally, the relational module depicted in section (Sec. 2) was replaced by a stack of residual convolutional blocks in the control agent. ",
647
+ "bbox": [
648
+ 174,
649
+ 840,
650
+ 825,
651
+ 922
652
+ ],
653
+ "page_idx": 6
654
+ },
655
+ {
656
+ "type": "text",
657
+ "text": "",
658
+ "bbox": [
659
+ 174,
660
+ 103,
661
+ 825,
662
+ 188
663
+ ],
664
+ "page_idx": 7
665
+ },
666
+ {
667
+ "type": "text",
668
+ "text": "For the agent’s output, alongside action $a$ and value $V$ , the network produces two sets of action-related arguments: non-spatial arguments (Args) and spatial arguments $( A r g s _ { x , y } )$ . These arguments are used as modifiers of particular actions (see (Vinyals et al., 2017)). Args are produced from the output of the aggregation function, whereas $A r g s _ { x , y }$ result from upsampling the output of the relational module. See the Appendix for further details. ",
669
+ "bbox": [
670
+ 173,
671
+ 194,
672
+ 825,
673
+ 263
674
+ ],
675
+ "page_idx": 7
676
+ },
677
+ {
678
+ "type": "image",
679
+ "img_path": "images/710f8f8bda37ef92da4ce3ab129888d9cc58bcd4cab04bc160ab0c9f71c6f33a.jpg",
680
+ "image_caption": [
681
+ "Figure 6: Final performance across StarCraft II mini-games. The relational-agent achieved above grandmaster scores in 4 out of 7 levels. The main difference between our new control agent and the relational agent is most relevant in the Defeat Zerglings and Banelings task. Here, the underlying strategy requires agents to split their army and kite enemy units in order to alleviate the incoming impact (as Banelings incur area damage); a strategy requiring reasoning and fine control over many units. A relational agent with iterative blocks of attention was required for this strategy to emerge. For more details, see Table 1 in the Appendix. "
682
+ ],
683
+ "image_footnote": [],
684
+ "bbox": [
685
+ 189,
686
+ 290,
687
+ 808,
688
+ 675
689
+ ],
690
+ "page_idx": 7
691
+ },
692
+ {
693
+ "type": "text",
694
+ "text": "RESULTS ",
695
+ "text_level": 1,
696
+ "bbox": [
697
+ 174,
698
+ 838,
699
+ 238,
700
+ 852
701
+ ],
702
+ "page_idx": 7
703
+ },
704
+ {
705
+ "type": "text",
706
+ "text": "For these results we used the full action set provided by SC2LE and performance was measured as the mean score over 30 episodes of the best run for each mini-game. Our agent implementations achieved high scores across all the mini-games (Figure 6), consistently outperforming the previous best models. In particular, the agent augmented with a relational module achieved state-of-the-art results in six mini-games and its performance surpassed that of the human grandmaster in four of them3. ",
707
+ "bbox": [
708
+ 174,
709
+ 867,
710
+ 825,
711
+ 924
712
+ ],
713
+ "page_idx": 7
714
+ },
715
+ {
716
+ "type": "text",
717
+ "text": "",
718
+ "bbox": [
719
+ 174,
720
+ 103,
721
+ 823,
722
+ 132
723
+ ],
724
+ "page_idx": 8
725
+ },
726
+ {
727
+ "type": "text",
728
+ "text": "Head-to-head comparisons between our two implementations show that the agent with the relational component (relational) achieves similar or better results than the one without (control). Concretely, for Collect Mineral Shards, Defeat Roaches and Defeat Zerglings and Banelings, the relational agent improved relative to the control agent by 9, 8 and 134 points, with a standard error of 1.5, 6.4 and 18.2, respectively. ",
729
+ "bbox": [
730
+ 174,
731
+ 138,
732
+ 825,
733
+ 208
734
+ ],
735
+ "page_idx": 8
736
+ },
737
+ {
738
+ "type": "text",
739
+ "text": "We note that both models improved substantially over the previous best (Vinyals et al., 2017), and in some mini-games, they approach an empirical ceiling performance. This can be attributed to a combination of factors: improved RL algorithm (Espeholt et al., 2018), more robust architecture, better hyperparameter tuning to address issues of credit assignment and exploration, better action selection procedure, and longer training. Next, we focus on differences afforded by relational inductive biases and turn to particular generalization tests to determine the behavioural traits of the control and relational agents. ",
740
+ "bbox": [
741
+ 174,
742
+ 215,
743
+ 825,
744
+ 313
745
+ ],
746
+ "page_idx": 8
747
+ },
748
+ {
749
+ "type": "text",
750
+ "text": "GENERALIZATION CAPABILITY ",
751
+ "text_level": 1,
752
+ "bbox": [
753
+ 176,
754
+ 329,
755
+ 390,
756
+ 342
757
+ ],
758
+ "page_idx": 8
759
+ },
760
+ {
761
+ "type": "text",
762
+ "text": "As observed in Box-World, a capacity to better understand underlying relational structure – rather than latch onto superficial statistics – may manifest in better generalization to never-before-seen situations. To test generalization in SC2 we took agents trained on Collect Mineral Shards, which involved using two marines to collect randomly scattered minerals and tested them, without further training, on modified levels that allowed the agents to instead control up to ten marines. It’s worth highlighting the agents have never been exposed to a single observation present in these generalization experiments. Intuitively, if an agent understands that marines are independent units that can be coordinated, yet controlled independently to collect resources, then increasing the number of marines available should only affect the underlying strategy of unit deployment, and should not catastrophically break model performance. ",
763
+ "bbox": [
764
+ 174,
765
+ 353,
766
+ 825,
767
+ 491
768
+ ],
769
+ "page_idx": 8
770
+ },
771
+ {
772
+ "type": "text",
773
+ "text": "We observed that—at least for medium sized networks—some interesting generalization capabilities emerge, with the best seeds of the relational agent achieving better generalization scores in the test scenario. However, we noticed high variability in these quantitative results, with the effect diminishing when using larger models (which may be more prone to overfitting on the training set). Qualitative analysis of the policies revealed distinct behaviours for the best performing control and relational agents: while the former adopted a \"land sweep strategy\", controlling many units as a group to cover the space, the latter managed to independently control several units simultaneously, suggesting a finer grained understanding of the game dynamics. Further work is required to draw firm conclusions about the generalization capabilities of a relational agent in more complex domains such as StarCraft II (see Figure 9 in Appendix). ",
774
+ "bbox": [
775
+ 174,
776
+ 498,
777
+ 825,
778
+ 638
779
+ ],
780
+ "page_idx": 8
781
+ },
782
+ {
783
+ "type": "text",
784
+ "text": "Given the combinatoric richness and multi-agent aspects of the full StarCraft II game, an agent is frequently exposed to situations in which it might not have been trained on. Thus, an improved capability to generalize to new, unseen situations aided by a better understanding of underlying abstract entities and their relations is fundamental. ",
785
+ "bbox": [
786
+ 174,
787
+ 645,
788
+ 825,
789
+ 700
790
+ ],
791
+ "page_idx": 8
792
+ },
793
+ {
794
+ "type": "text",
795
+ "text": "4 CONCLUSION ",
796
+ "text_level": 1,
797
+ "bbox": [
798
+ 176,
799
+ 720,
800
+ 318,
801
+ 737
802
+ ],
803
+ "page_idx": 8
804
+ },
805
+ {
806
+ "type": "text",
807
+ "text": "By introducing structured perception and relational reasoning into deep RL architectures, our agents can learn interpretable representations, and exceed baseline agents in terms of sample complexity, ability to generalize, and overall performance. Behavioral analyses showed that the learned representations allowed for better generalization, which is characteristic of relational representations. Analysis of attention weights showed that the model’s internal computations were interpretable, and congruent with the computations we would expect from a model computing task-relevant relations. ",
808
+ "bbox": [
809
+ 174,
810
+ 752,
811
+ 825,
812
+ 837
813
+ ],
814
+ "page_idx": 8
815
+ },
816
+ {
817
+ "type": "text",
818
+ "text": "One important future direction is to explore ways to scale our approach to larger inputs spaces, without suffering, as this and other approaches do (e.g., Wang et al., 2017; Santoro et al., 2017), from the quadratic complexity that results from considering all input pairs. Possible avenues involve using a distinct attentional mechanisms that scales linearly with the number of inputs (Hoshen, 2017) or filtering out unimportant relations (Malinowski et al., 2018). Other future directions include exploring perceiving complex scenes via more structured formats, such as scene graphs (Xu et al., 2017; Chen et al., 2018), which could be powerful additions to our approach’s input module. More complex relational modules could be explored, such as richer graph network implementations (Battaglia et al., 2018), learned approaches for inducing compositional programs (Reed & De Freitas, 2015; Parisotto et al., 2017; Allamanis et al., 2017; Devlin et al., 2017) and reasoning about structured data (Neelakantan et al., 2015; Liang et al., 2016), or even explicit logical reasoning over structured internal representations (Evans et al., 2018), drawing inspiration from more symbolic approaches in classic AI. Our approach may also interface well with approaches for hierarchical RL (Vezhnevets et al., 2017), planning (Guez et al., 2018), and structured behavior representation (Huang et al., 2018), so that the structured internal representations and patterns of reasoning can translate into more structured behaviors. ",
819
+ "bbox": [
820
+ 174,
821
+ 844,
822
+ 825,
823
+ 900
824
+ ],
825
+ "page_idx": 8
826
+ },
827
+ {
828
+ "type": "text",
829
+ "text": "",
830
+ "bbox": [
831
+ 174,
832
+ 103,
833
+ 825,
834
+ 270
835
+ ],
836
+ "page_idx": 9
837
+ },
838
+ {
839
+ "type": "text",
840
+ "text": "More speculatively, this work blurs the line between model-free agents, and those with a capacity for more abstract planning. An important feature of model-based approaches is making general knowledge of the environment available for decision-making. Here our inductive biases for entityand relation-centric representations and iterated reasoning reflect key knowledge about the structure of the world. While not a model in the technical sense, it is possible that the agent learns to exploit this relational architectural prior similarly to how an imagination-based agent’s forward model operates (Hamrick et al., 2017; Pascanu et al., 2017; Weber et al., 2017). More generally, our work opens new directions for RL via a principled hybrid of flexible statistical learning and more structured approaches. ",
841
+ "bbox": [
842
+ 174,
843
+ 276,
844
+ 825,
845
+ 402
846
+ ],
847
+ "page_idx": 9
848
+ },
849
+ {
850
+ "type": "text",
851
+ "text": "REFERENCES ",
852
+ "text_level": 1,
853
+ "bbox": [
854
+ 176,
855
+ 102,
856
+ 287,
857
+ 118
858
+ ],
859
+ "page_idx": 10
860
+ },
861
+ {
862
+ "type": "text",
863
+ "text": "Miltiadis Allamanis, Pankajan Chanthirasegaran, Pushmeet Kohli, and Charles Sutton. Learning continuous semantic representations of symbolic expressions. In Proceedings of the International Conference on Machine Learning (ICML), 2017. ",
864
+ "bbox": [
865
+ 174,
866
+ 126,
867
+ 821,
868
+ 169
869
+ ],
870
+ "page_idx": 10
871
+ },
872
+ {
873
+ "type": "text",
874
+ "text": "Jimmy Lei Ba, Jamie Ryan Kiros, and Geoffrey E Hinton. Layer normalization. arXiv preprint arXiv:1607.06450, 2016. ",
875
+ "bbox": [
876
+ 168,
877
+ 178,
878
+ 823,
879
+ 207
880
+ ],
881
+ "page_idx": 10
882
+ },
883
+ {
884
+ "type": "text",
885
+ "text": "Peter Battaglia, Razvan Pascanu, Matthew Lai, Danilo Jimenez Rezende, et al. Interaction networks for learning about objects, relations and physics. In Advances in neural information processing systems, pp. 4502–4510, 2016. ",
886
+ "bbox": [
887
+ 174,
888
+ 217,
889
+ 823,
890
+ 260
891
+ ],
892
+ "page_idx": 10
893
+ },
894
+ {
895
+ "type": "text",
896
+ "text": "Peter W Battaglia, Jessica B Hamrick, Victor Bapst, Alvaro Sanchez-Gonzalez, Vinicius Zambaldi, Mateusz Malinowski, Andrea Tacchetti, David Raposo, Adam Santoro, Ryan Faulkner, et al. Relational inductive biases, deep learning, and graph networks. arXiv preprint arXiv:1806.01261, 2018. ",
897
+ "bbox": [
898
+ 173,
899
+ 268,
900
+ 826,
901
+ 325
902
+ ],
903
+ "page_idx": 10
904
+ },
905
+ {
906
+ "type": "text",
907
+ "text": "Xinlei Chen, Li-Jia Li, Li Fei-Fei, and Abhinav Gupta. Iterative visual reasoning beyond convolutions. arXiv preprint arXiv:1803.11189, 2018. ",
908
+ "bbox": [
909
+ 173,
910
+ 335,
911
+ 825,
912
+ 364
913
+ ],
914
+ "page_idx": 10
915
+ },
916
+ {
917
+ "type": "text",
918
+ "text": "Hanjun Dai, Elias Khalil, Yuyu Zhang, Bistra Dilkina, and Le Song. Learning combinatorial optimization algorithms over graphs. In Advances in Neural Information Processing Systems, pp. 6351–6361, 2017. ",
919
+ "bbox": [
920
+ 173,
921
+ 373,
922
+ 826,
923
+ 416
924
+ ],
925
+ "page_idx": 10
926
+ },
927
+ {
928
+ "type": "text",
929
+ "text": "Jacob Devlin, Jonathan Uesato, Rishabh Singh, and Pushmeet Kohli. Semantic code repair using neuro-symbolic transformation networks. arXiv preprint arXiv:1710.11054, 2017. ",
930
+ "bbox": [
931
+ 169,
932
+ 426,
933
+ 823,
934
+ 455
935
+ ],
936
+ "page_idx": 10
937
+ },
938
+ {
939
+ "type": "text",
940
+ "text": "Carlos Diuk, Andre Cohen, and Michael L Littman. An object-oriented representation for efficient reinforcement learning. In Proceedings of the 25th international conference on Machine learning, pp. 240–247. ACM, 2008. ",
941
+ "bbox": [
942
+ 173,
943
+ 464,
944
+ 825,
945
+ 507
946
+ ],
947
+ "page_idx": 10
948
+ },
949
+ {
950
+ "type": "text",
951
+ "text": "Kurt Driessens and Saso Dzeroski. Integrating guidance into relational reinforcement learning. Machine Learning, 57(3):271–304, 2004. ",
952
+ "bbox": [
953
+ 169,
954
+ 517,
955
+ 825,
956
+ 546
957
+ ],
958
+ "page_idx": 10
959
+ },
960
+ {
961
+ "type": "text",
962
+ "text": "Saso Dzeroski, Luc De Raedt, and Kurt Driessens. Relational reinforcement learning. Machine Learning, 43(1/2):7–52, 2001. ",
963
+ "bbox": [
964
+ 171,
965
+ 555,
966
+ 823,
967
+ 585
968
+ ],
969
+ "page_idx": 10
970
+ },
971
+ {
972
+ "type": "text",
973
+ "text": "Lasse Espeholt, Hubert Soyer, Remi Munos, Karen Simonyan, Volodymir Mnih, Tom Ward, Yotam Doron, Vlad Firoiu, Tim Harley, Iain Dunning, et al. Impala: Scalable distributed deep-rl with importance weighted actor-learner architectures. arXiv preprint arXiv:1802.01561, 2018. ",
974
+ "bbox": [
975
+ 174,
976
+ 594,
977
+ 825,
978
+ 637
979
+ ],
980
+ "page_idx": 10
981
+ },
982
+ {
983
+ "type": "text",
984
+ "text": "Richard Evans, David Saxton, David Amos, Pushmeet Kohli, and Edward Grefenstette. Can neural networks understand logical entailment? In Proceedings of the International Conference on Learning Representations (ICLR), 2018. ",
985
+ "bbox": [
986
+ 174,
987
+ 646,
988
+ 825,
989
+ 690
990
+ ],
991
+ "page_idx": 10
992
+ },
993
+ {
994
+ "type": "text",
995
+ "text": "Marta Garnelo, Kai Arulkumaran, and Murray Shanahan. Towards deep symbolic reinforcement learning. arXiv preprint arXiv:1609.05518, 2016. ",
996
+ "bbox": [
997
+ 173,
998
+ 699,
999
+ 823,
1000
+ 728
1001
+ ],
1002
+ "page_idx": 10
1003
+ },
1004
+ {
1005
+ "type": "text",
1006
+ "text": "Justin Gilmer, Samuel S Schoenholz, Patrick F Riley, Oriol Vinyals, and George E Dahl. Neural message passing for quantum chemistry. arXiv preprint arXiv:1704.01212, 2017. ",
1007
+ "bbox": [
1008
+ 171,
1009
+ 737,
1010
+ 823,
1011
+ 767
1012
+ ],
1013
+ "page_idx": 10
1014
+ },
1015
+ {
1016
+ "type": "text",
1017
+ "text": "Arthur Guez, Théophane Weber, Ioannis Antonoglou, Karen Simonyan, Oriol Vinyals, Daan Wierstra, Rémi Munos, and David Silver. Learning to search with mctsnets. arXiv preprint arXiv:1802.04697, 2018. ",
1018
+ "bbox": [
1019
+ 174,
1020
+ 776,
1021
+ 825,
1022
+ 819
1023
+ ],
1024
+ "page_idx": 10
1025
+ },
1026
+ {
1027
+ "type": "text",
1028
+ "text": "Jessica B Hamrick, Andrew J Ballard, Razvan Pascanu, Oriol Vinyals, Nicolas Heess, and Peter W Battaglia. Metacontrol for adaptive imagination-based optimization. arXiv preprint arXiv:1705.02670, 2017. ",
1029
+ "bbox": [
1030
+ 171,
1031
+ 829,
1032
+ 825,
1033
+ 871
1034
+ ],
1035
+ "page_idx": 10
1036
+ },
1037
+ {
1038
+ "type": "text",
1039
+ "text": "Jessica B Hamrick, Kelsey R Allen, Victor Bapst, Tina Zhu, Kevin R McKee, Joshua B Tenenbaum, and Peter W Battaglia. Relational inductive bias for physical construction in humans and machines. arXiv preprint arXiv:1806.01203, 2018. ",
1040
+ "bbox": [
1041
+ 174,
1042
+ 881,
1043
+ 826,
1044
+ 924
1045
+ ],
1046
+ "page_idx": 10
1047
+ },
1048
+ {
1049
+ "type": "text",
1050
+ "text": "Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. Identity mappings in deep residual networks. In European Conference on Computer Vision, pp. 630–645. Springer, 2016. ",
1051
+ "bbox": [
1052
+ 171,
1053
+ 103,
1054
+ 825,
1055
+ 133
1056
+ ],
1057
+ "page_idx": 11
1058
+ },
1059
+ {
1060
+ "type": "text",
1061
+ "text": "Dan Horgan, John Quan, David Budden, Gabriel Barth-Maron, Matteo Hessel, Hado Van Hasselt, and David Silver. Distributed prioritized experience replay. arXiv preprint arXiv:1803.00933, 2018. ",
1062
+ "bbox": [
1063
+ 176,
1064
+ 142,
1065
+ 823,
1066
+ 185
1067
+ ],
1068
+ "page_idx": 11
1069
+ },
1070
+ {
1071
+ "type": "text",
1072
+ "text": "Yedid Hoshen. Vain: Attentional multi-agent predictive modeling. In Advances in Neural Information Processing Systems, pp. 2701–2711, 2017. ",
1073
+ "bbox": [
1074
+ 176,
1075
+ 195,
1076
+ 821,
1077
+ 224
1078
+ ],
1079
+ "page_idx": 11
1080
+ },
1081
+ {
1082
+ "type": "text",
1083
+ "text": "De-An Huang, Suraj Nair, Danfei Xu, Yuke Zhu, Animesh Garg, Li Fei-Fei, Silvio Savarese, and Juan Carlos Niebles. Neural task graphs: Generalizing to unseen tasks from a single video demonstration. arXiv preprint arXiv:1807.03480, 2018. ",
1084
+ "bbox": [
1085
+ 173,
1086
+ 234,
1087
+ 826,
1088
+ 277
1089
+ ],
1090
+ "page_idx": 11
1091
+ },
1092
+ {
1093
+ "type": "text",
1094
+ "text": "Max Jaderberg, Valentin Dalibard, Simon Osindero, Wojciech M Czarnecki, Jeff Donahue, Ali Razavi, Oriol Vinyals, Tim Green, Iain Dunning, Karen Simonyan, et al. Population based training of neural networks. arXiv preprint arXiv:1711.09846, 2017. ",
1095
+ "bbox": [
1096
+ 176,
1097
+ 286,
1098
+ 825,
1099
+ 330
1100
+ ],
1101
+ "page_idx": 11
1102
+ },
1103
+ {
1104
+ "type": "text",
1105
+ "text": "Ken Kansky, Tom Silver, David A Mély, Mohamed Eldawy, Miguel Lázaro-Gredilla, Xinghua Lou, Nimrod Dorfman, Szymon Sidor, Scott Phoenix, and Dileep George. Schema networks: Zero-shot transfer with a generative causal model of intuitive physics. arXiv preprint arXiv:1706.04317, 2017. ",
1106
+ "bbox": [
1107
+ 173,
1108
+ 340,
1109
+ 826,
1110
+ 396
1111
+ ],
1112
+ "page_idx": 11
1113
+ },
1114
+ {
1115
+ "type": "text",
1116
+ "text": "Thomas Kipf, Ethan Fetaya, Kuan-Chieh Wang, Max Welling, and Richard Zemel. Neural relational inference for interacting systems. arXiv preprint arXiv:1802.04687, 2018. ",
1117
+ "bbox": [
1118
+ 173,
1119
+ 406,
1120
+ 821,
1121
+ 436
1122
+ ],
1123
+ "page_idx": 11
1124
+ },
1125
+ {
1126
+ "type": "text",
1127
+ "text": "Brenden M Lake, Tomer D Ullman, Joshua B Tenenbaum, and Samuel J Gershman. Building machines that learn and think like people. Behavioral and Brain Sciences, 40, 2017. ",
1128
+ "bbox": [
1129
+ 173,
1130
+ 445,
1131
+ 823,
1132
+ 476
1133
+ ],
1134
+ "page_idx": 11
1135
+ },
1136
+ {
1137
+ "type": "text",
1138
+ "text": "Yujia Li, Daniel Tarlow, Marc Brockschmidt, and Richard Zemel. Gated graph sequence neural networks. arXiv preprint arXiv:1511.05493, 2015. ",
1139
+ "bbox": [
1140
+ 173,
1141
+ 484,
1142
+ 823,
1143
+ 515
1144
+ ],
1145
+ "page_idx": 11
1146
+ },
1147
+ {
1148
+ "type": "text",
1149
+ "text": "Chen Liang, Jonathan Berant, Quoc Le, Kenneth D Forbus, and Ni Lao. Neural symbolic machines: Learning semantic parsers on freebase with weak supervision. arXiv preprint arXiv:1611.00020, 2016. ",
1150
+ "bbox": [
1151
+ 173,
1152
+ 523,
1153
+ 826,
1154
+ 566
1155
+ ],
1156
+ "page_idx": 11
1157
+ },
1158
+ {
1159
+ "type": "text",
1160
+ "text": "Mateusz Malinowski, Carl Doersch, Adam Santoro, and Peter Battaglia. Learning visual question answering by bootstrapping hard attention. In Proceedings of the European Conference on Computer Vision (ECCV), pp. 3–20, 2018. ",
1161
+ "bbox": [
1162
+ 176,
1163
+ 577,
1164
+ 823,
1165
+ 621
1166
+ ],
1167
+ "page_idx": 11
1168
+ },
1169
+ {
1170
+ "type": "text",
1171
+ "text": "Volodymyr Mnih, Koray Kavukcuoglu, David Silver, Andrei A Rusu, Joel Veness, Marc G Bellemare, Alex Graves, Martin Riedmiller, Andreas K Fidjeland, Georg Ostrovski, et al. Human-level control through deep reinforcement learning. Nature, 518(7540):529, 2015. ",
1172
+ "bbox": [
1173
+ 176,
1174
+ 630,
1175
+ 823,
1176
+ 672
1177
+ ],
1178
+ "page_idx": 11
1179
+ },
1180
+ {
1181
+ "type": "text",
1182
+ "text": "Volodymyr Mnih, Adria Puigdomenech Badia, Mehdi Mirza, Alex Graves, Timothy Lillicrap, Tim Harley, David Silver, and Koray Kavukcuoglu. Asynchronous methods for deep reinforcement learning. In International conference on machine learning, pp. 1928–1937, 2016. ",
1183
+ "bbox": [
1184
+ 173,
1185
+ 683,
1186
+ 825,
1187
+ 727
1188
+ ],
1189
+ "page_idx": 11
1190
+ },
1191
+ {
1192
+ "type": "text",
1193
+ "text": "Arvind Neelakantan, Quoc V Le, and Ilya Sutskever. Neural programmer: Inducing latent programs with gradient descent. arXiv preprint arXiv:1511.04834, 2015. ",
1194
+ "bbox": [
1195
+ 171,
1196
+ 736,
1197
+ 823,
1198
+ 765
1199
+ ],
1200
+ "page_idx": 11
1201
+ },
1202
+ {
1203
+ "type": "text",
1204
+ "text": "Emilio Parisotto, Abdel-rahman Mohamed, Rishabh Singh, Lihong Li, Dengyong Zhou, and Pushmeet Kohli. Neuro-symbolic program synthesis. In Proceedings of the International Conference on Learning Representations (ICLR), 2017. ",
1205
+ "bbox": [
1206
+ 174,
1207
+ 775,
1208
+ 823,
1209
+ 818
1210
+ ],
1211
+ "page_idx": 11
1212
+ },
1213
+ {
1214
+ "type": "text",
1215
+ "text": "Razvan Pascanu, Yujia Li, Oriol Vinyals, Nicolas Heess, Lars Buesing, Sebastien Racanière, David Reichert, Théophane Weber, Daan Wierstra, and Peter Battaglia. Learning model-based planning from scratch. arXiv preprint arXiv:1707.06170, 2017. ",
1216
+ "bbox": [
1217
+ 176,
1218
+ 828,
1219
+ 823,
1220
+ 871
1221
+ ],
1222
+ "page_idx": 11
1223
+ },
1224
+ {
1225
+ "type": "text",
1226
+ "text": "David Raposo, Adam Santoro, David Barrett, Razvan Pascanu, Timothy Lillicrap, and Peter Battaglia. Discovering objects and their relations from entangled scene representations. arXiv preprint arXiv:1702.05068, 2017. ",
1227
+ "bbox": [
1228
+ 174,
1229
+ 882,
1230
+ 825,
1231
+ 922
1232
+ ],
1233
+ "page_idx": 11
1234
+ },
1235
+ {
1236
+ "type": "text",
1237
+ "text": "Scott Reed and Nando De Freitas. Neural programmer-interpreters. arXiv preprint arXiv:1511.06279, 2015. ",
1238
+ "bbox": [
1239
+ 173,
1240
+ 103,
1241
+ 825,
1242
+ 132
1243
+ ],
1244
+ "page_idx": 12
1245
+ },
1246
+ {
1247
+ "type": "text",
1248
+ "text": "Alvaro Sanchez-Gonzalez, Nicolas Heess, Jost Tobias Springenberg, Josh Merel, Martin Riedmiller, Raia Hadsell, and Peter Battaglia. Graph networks as learnable physics engines for inference and control. arXiv preprint arXiv:1806.01242, 2018. ",
1249
+ "bbox": [
1250
+ 176,
1251
+ 140,
1252
+ 823,
1253
+ 184
1254
+ ],
1255
+ "page_idx": 12
1256
+ },
1257
+ {
1258
+ "type": "text",
1259
+ "text": "Adam Santoro, David Raposo, David G Barrett, Mateusz Malinowski, Razvan Pascanu, Peter Battaglia, and Tim Lillicrap. A simple neural network module for relational reasoning. In Advances in neural information processing systems, pp. 4974–4983, 2017. ",
1260
+ "bbox": [
1261
+ 174,
1262
+ 193,
1263
+ 823,
1264
+ 236
1265
+ ],
1266
+ "page_idx": 12
1267
+ },
1268
+ {
1269
+ "type": "text",
1270
+ "text": "Franco Scarselli, Marco Gori, Ah Chung Tsoi, Markus Hagenbuchner, and Gabriele Monfardini. The graph neural network model. IEEE Transactions on Neural Networks, 20(1):61–80, 2009. ",
1271
+ "bbox": [
1272
+ 173,
1273
+ 243,
1274
+ 823,
1275
+ 273
1276
+ ],
1277
+ "page_idx": 12
1278
+ },
1279
+ {
1280
+ "type": "text",
1281
+ "text": "Daniel Selsam, Matthew Lamm, Benedikt Bunz, Percy Liang, Leonardo de Moura, and David L Dill. Learning a sat solver from single-bit supervision. arXiv preprint arXiv:1802.03685, 2018. ",
1282
+ "bbox": [
1283
+ 174,
1284
+ 281,
1285
+ 823,
1286
+ 310
1287
+ ],
1288
+ "page_idx": 12
1289
+ },
1290
+ {
1291
+ "type": "text",
1292
+ "text": "David Silver, Aja Huang, Chris J Maddison, Arthur Guez, Laurent Sifre, George Van Den Driessche, Julian Schrittwieser, Ioannis Antonoglou, Veda Panneershelvam, Marc Lanctot, et al. Mastering the game of go with deep neural networks and tree search. nature, 529(7587):484–489, 2016. ",
1293
+ "bbox": [
1294
+ 173,
1295
+ 319,
1296
+ 826,
1297
+ 363
1298
+ ],
1299
+ "page_idx": 12
1300
+ },
1301
+ {
1302
+ "type": "text",
1303
+ "text": "Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Łukasz Kaiser, and Illia Polosukhin. Attention is all you need. In Advances in Neural Information Processing Systems, pp. 6000–6010, 2017. ",
1304
+ "bbox": [
1305
+ 173,
1306
+ 371,
1307
+ 825,
1308
+ 414
1309
+ ],
1310
+ "page_idx": 12
1311
+ },
1312
+ {
1313
+ "type": "text",
1314
+ "text": "Petar Velickovic, Guillem Cucurull, Arantxa Casanova, Adriana Romero, Pietro Lio, and Yoshua Bengio. Graph attention networks. arXiv preprint arXiv:1710.10903, 2017. ",
1315
+ "bbox": [
1316
+ 171,
1317
+ 422,
1318
+ 825,
1319
+ 452
1320
+ ],
1321
+ "page_idx": 12
1322
+ },
1323
+ {
1324
+ "type": "text",
1325
+ "text": "Alexander Sasha Vezhnevets, Simon Osindero, Tom Schaul, Nicolas Heess, Max Jaderberg, David Silver, and Koray Kavukcuoglu. Feudal networks for hierarchical reinforcement learning. arXiv preprint arXiv:1703.01161, 2017. ",
1326
+ "bbox": [
1327
+ 174,
1328
+ 460,
1329
+ 823,
1330
+ 503
1331
+ ],
1332
+ "page_idx": 12
1333
+ },
1334
+ {
1335
+ "type": "text",
1336
+ "text": "Oriol Vinyals, Timo Ewalds, Sergey Bartunov, Petko Georgiev, Alexander Sasha Vezhnevets, Michelle Yeo, Alireza Makhzani, Heinrich Küttler, John Agapiou, Julian Schrittwieser, et al. Starcraft ii: a new challenge for reinforcement learning. arXiv preprint arXiv:1708.04782, 2017. ",
1337
+ "bbox": [
1338
+ 176,
1339
+ 511,
1340
+ 823,
1341
+ 555
1342
+ ],
1343
+ "page_idx": 12
1344
+ },
1345
+ {
1346
+ "type": "text",
1347
+ "text": "Tingwu Wang, Renjie Liao, Jimmy Ba, and Sanja Fidler. Nervenet: Learning structured policy with graph neural networks. Proceedings of the International Conference on Learning Representations (ICLR), 2018. ",
1348
+ "bbox": [
1349
+ 173,
1350
+ 563,
1351
+ 825,
1352
+ 606
1353
+ ],
1354
+ "page_idx": 12
1355
+ },
1356
+ {
1357
+ "type": "text",
1358
+ "text": "Xiaolong Wang, Ross Girshick, Abhinav Gupta, and Kaiming He. Non-local neural networks. arXiv preprint arXiv:1711.07971, 2017. ",
1359
+ "bbox": [
1360
+ 171,
1361
+ 614,
1362
+ 823,
1363
+ 645
1364
+ ],
1365
+ "page_idx": 12
1366
+ },
1367
+ {
1368
+ "type": "text",
1369
+ "text": "Nicholas Watters, Andrea Tacchetti, Theophane Weber, Razvan Pascanu, Peter Battaglia, and Daniel Zoran. Visual interaction networks. arXiv preprint arXiv:1706.01433, 2017. ",
1370
+ "bbox": [
1371
+ 169,
1372
+ 652,
1373
+ 823,
1374
+ 683
1375
+ ],
1376
+ "page_idx": 12
1377
+ },
1378
+ {
1379
+ "type": "text",
1380
+ "text": "Théophane Weber, Sébastien Racanière, David P Reichert, Lars Buesing, Arthur Guez, Danilo Jimenez Rezende, Adria Puigdomènech Badia, Oriol Vinyals, Nicolas Heess, Yujia Li, et al. Imagination-augmented agents for deep reinforcement learning. arXiv preprint arXiv:1707.06203, 2017. ",
1381
+ "bbox": [
1382
+ 174,
1383
+ 690,
1384
+ 825,
1385
+ 746
1386
+ ],
1387
+ "page_idx": 12
1388
+ },
1389
+ {
1390
+ "type": "text",
1391
+ "text": "Danfei Xu, Yuke Zhu, Christopher B Choy, and Li Fei-Fei. Scene graph generation by iterative message passing. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, volume 2, 2017. ",
1392
+ "bbox": [
1393
+ 174,
1394
+ 756,
1395
+ 823,
1396
+ 799
1397
+ ],
1398
+ "page_idx": 12
1399
+ },
1400
+ {
1401
+ "type": "text",
1402
+ "text": "Chiyuan Zhang, Oriol Vinyals, Remi Munos, and Samy Bengio. A study on overfitting in deep reinforcement learning. arXiv preprint arXiv:1804.06893, 2018. ",
1403
+ "bbox": [
1404
+ 174,
1405
+ 808,
1406
+ 821,
1407
+ 837
1408
+ ],
1409
+ "page_idx": 12
1410
+ },
1411
+ {
1412
+ "type": "text",
1413
+ "text": "APPENDIX ",
1414
+ "text_level": 1,
1415
+ "bbox": [
1416
+ 176,
1417
+ 103,
1418
+ 263,
1419
+ 117
1420
+ ],
1421
+ "page_idx": 13
1422
+ },
1423
+ {
1424
+ "type": "text",
1425
+ "text": "A BOX-WORLD ",
1426
+ "bbox": [
1427
+ 176,
1428
+ 140,
1429
+ 294,
1430
+ 154
1431
+ ],
1432
+ "page_idx": 13
1433
+ },
1434
+ {
1435
+ "type": "text",
1436
+ "text": "TASK ",
1437
+ "bbox": [
1438
+ 176,
1439
+ 170,
1440
+ 214,
1441
+ 184
1442
+ ],
1443
+ "page_idx": 13
1444
+ },
1445
+ {
1446
+ "type": "text",
1447
+ "text": "Each level in Box-world is procedurally generated. We start by generating a random graph (a tree) that defines the correct path to the goal – i.e., the sequence of boxes that need to be opened to reach the gem. This graph also defines multiple distractor branches – boxes that lead to dead-ends. The agent, keys and boxes, including the one containing the gem, are positioned randomly in the room, assuring that there is enough space for the agent to navigate between boxes. There is a total of 20 keys and 20 locks that are randomly sampled to produce the level. An agent receives a reward of $+ 1 0$ for collecting the gem, $+ 1$ for opening a box in the solution path and $- 1$ for opening a distractor box. A level terminates immediately after the gem is collected or a distractor box is opened. ",
1448
+ "bbox": [
1449
+ 174,
1450
+ 198,
1451
+ 826,
1452
+ 310
1453
+ ],
1454
+ "page_idx": 13
1455
+ },
1456
+ {
1457
+ "type": "text",
1458
+ "text": "The generation process produces a very large number of possible trees, making it extremely unlikely that the agent will face the same level twice. The procedural generation of levels also allows us to create different training-test splits by withholding levels that conform to a particular case during training and presenting them to the agent at test time. ",
1459
+ "bbox": [
1460
+ 174,
1461
+ 318,
1462
+ 825,
1463
+ 373
1464
+ ],
1465
+ "page_idx": 13
1466
+ },
1467
+ {
1468
+ "type": "image",
1469
+ "img_path": "images/f17b742e4204133c699243326f366d268887d65d6c2d6d663d4922248c21fd54.jpg",
1470
+ "image_caption": [
1471
+ "Figure 7: Alternative RL algorithms produced similar results on Box-World. The difference in performance that we observed between relational and baseline agents using the RL algorithm proposed by Espeholt et al. (2018) was still present when using A3C or distributed DQN. These experiments were done using $1 0 \\times 1 0$ pixel maps, solution sequences of up to 3 boxes and up to 3 distractor branches. "
1472
+ ],
1473
+ "image_footnote": [],
1474
+ "bbox": [
1475
+ 318,
1476
+ 410,
1477
+ 684,
1478
+ 559
1479
+ ],
1480
+ "page_idx": 13
1481
+ },
1482
+ {
1483
+ "type": "image",
1484
+ "img_path": "images/9014be2b4481bb22f1c5ceeb81002b1c9ecb910d24d762e5a77f620ca0472ef9.jpg",
1485
+ "image_caption": [
1486
+ "Figure 8: Box-World: forward branching versus backward branching. With backward branching, any given key can only open one box; however, each key type (i.e. color), can appear in multiple boxes. This means that an agent can adopt a more reactive policy without planning beyond which box to open next. "
1487
+ ],
1488
+ "image_footnote": [],
1489
+ "bbox": [
1490
+ 243,
1491
+ 705,
1492
+ 756,
1493
+ 849
1494
+ ],
1495
+ "page_idx": 13
1496
+ },
1497
+ {
1498
+ "type": "table",
1499
+ "img_path": "images/277e5c2cb2c4198468e00b5d2661ccb97d560b73354c04b76dc8c2186c9fba14.jpg",
1500
+ "table_caption": [
1501
+ "Mini-game ",
1502
+ "Table 1: Mean scores achieved in the StarCraft II mini-games using full action set. $\\uparrow$ denotes a score that is higher than a StarCraft Grandmaster. Mini-games: 1–Move To Beacon, 2–Collect Mineral Shards, 3–Find And Defeat Zerglings, 4–Defeat Roaches, 5–Defeat Zerglings And Banelings, 6–Collect Minerals And Gas, 7–Build Marines. "
1503
+ ],
1504
+ "table_footnote": [],
1505
+ "table_body": "<table><tr><td>Agent</td><td>1</td><td>2</td><td>3</td><td>4</td><td>5</td><td>6</td><td>7</td></tr><tr><td>DeepMind Human Player (Vinyals et al., 2017)</td><td>26</td><td>133</td><td>46</td><td>41</td><td>729</td><td>6880</td><td>138</td></tr><tr><td>StarCraft Grandmaster (Vinyals et al.,2017)</td><td>28</td><td>177</td><td>61</td><td>215</td><td>727</td><td>7566</td><td>133</td></tr><tr><td>Random Policy (Vinyals et al., 2017)</td><td>1</td><td>17</td><td>4</td><td>1</td><td>23</td><td>12</td><td>&lt;1</td></tr><tr><td>FullyConv LSTM (Vinyals et al., 2017)</td><td>26</td><td>104</td><td>44</td><td>98</td><td>96</td><td>3351</td><td>6</td></tr><tr><td>PBT-A3C (Jaderberg et al., 2017)</td><td>1</td><td>101</td><td>50</td><td>132</td><td>125</td><td>3345</td><td>0</td></tr><tr><td>Relational agent</td><td>27</td><td>196个</td><td>62个</td><td>303 个</td><td>736个</td><td>4906</td><td>123</td></tr><tr><td>Control agent</td><td>27</td><td>187↑</td><td>61</td><td>295个</td><td>602</td><td>5055</td><td>120</td></tr></table>",
1506
+ "bbox": [
1507
+ 183,
1508
+ 121,
1509
+ 815,
1510
+ 284
1511
+ ],
1512
+ "page_idx": 14
1513
+ },
1514
+ {
1515
+ "type": "text",
1516
+ "text": "B RL TRAINING PROCEDURE ",
1517
+ "text_level": 1,
1518
+ "bbox": [
1519
+ 176,
1520
+ 390,
1521
+ 387,
1522
+ 405
1523
+ ],
1524
+ "page_idx": 14
1525
+ },
1526
+ {
1527
+ "type": "text",
1528
+ "text": "We used distributed A2C agents with off-policy corrections (Espeholt et al., 2018). Each agents consisted of 100 actors generating trajectories of experience, and a single learner, which learns $\\pi$ and $B$ using the actors’ experiences. The model updates were performed on GPU using mini-batches of 32 trajectories provided by the actors via a queue. The agents used an entropy cost of 0.005, discount $( \\gamma )$ of 0.99 and unroll length of 40 steps. ",
1529
+ "bbox": [
1530
+ 174,
1531
+ 419,
1532
+ 825,
1533
+ 489
1534
+ ],
1535
+ "page_idx": 14
1536
+ },
1537
+ {
1538
+ "type": "text",
1539
+ "text": "Training was done using RMSprop optimiser with momentum of 0, $\\epsilon$ of 0.1 and a decay term of 0.99. \nThe learning rate was tuned, taking values between 1e−5 and $2 \\mathrm { e } { - 4 }$ . ",
1540
+ "bbox": [
1541
+ 174,
1542
+ 496,
1543
+ 823,
1544
+ 523
1545
+ ],
1546
+ "page_idx": 14
1547
+ },
1548
+ {
1549
+ "type": "text",
1550
+ "text": "AGENT ARCHITECTURE ",
1551
+ "text_level": 1,
1552
+ "bbox": [
1553
+ 176,
1554
+ 547,
1555
+ 338,
1556
+ 560
1557
+ ],
1558
+ "page_idx": 14
1559
+ },
1560
+ {
1561
+ "type": "text",
1562
+ "text": "The input module contained two convolutional layers with 12 and 24 kernels, $2 \\times 2$ kernel sizes and a stride of 1, followed by a rectified linear unit (ReLU) activation function. The output was tagged with two extra channels indicating the spatial position ( $\\mathbf { \\chi } _ { x }$ and $y$ ) of each cell in the feature map using evenly spaced values between $- 1$ and 1. This was passed to the relational module, consisting of relational blocks, with shared parameters. Queries, keys and values were produced by 2 to 4 attention heads and had an embedding size $( d )$ of 64. The output of this module was aggregated using a feature-wise max pooling function and passed to 4 fully connected layers, each followed by a ReLU. Policy logits $\\pi$ , size 4) and baseline function $B$ , size 1) were produced by a linear projection. The policy logits were normalized and used as multinomial distribution from which the action $( a )$ was sampled. ",
1563
+ "bbox": [
1564
+ 174,
1565
+ 571,
1566
+ 825,
1567
+ 712
1568
+ ],
1569
+ "page_idx": 14
1570
+ },
1571
+ {
1572
+ "type": "text",
1573
+ "text": "BASELINE AGENT ARCHITECTURE",
1574
+ "text_level": 1,
1575
+ "bbox": [
1576
+ 176,
1577
+ 734,
1578
+ 411,
1579
+ 747
1580
+ ],
1581
+ "page_idx": 14
1582
+ },
1583
+ {
1584
+ "type": "text",
1585
+ "text": "As a baseline agent we used the same architecture as the relational agent but replaced the relational module with a variable number (3 to 6) of residual-convolutional blocks. Each residual block comprised two convolutional layers, with $3 \\times 3$ kernels, stride of 1 and 26 output channels. ",
1586
+ "bbox": [
1587
+ 176,
1588
+ 760,
1589
+ 823,
1590
+ 801
1591
+ ],
1592
+ "page_idx": 14
1593
+ },
1594
+ {
1595
+ "type": "text",
1596
+ "text": "C STARCRAFT II MINI-GAMES ",
1597
+ "text_level": 1,
1598
+ "bbox": [
1599
+ 176,
1600
+ 825,
1601
+ 398,
1602
+ 839
1603
+ ],
1604
+ "page_idx": 14
1605
+ },
1606
+ {
1607
+ "type": "text",
1608
+ "text": "StarCraft II agents were trained with Adam optimiser for a total of 10 billion steps using batches of 32 trajectories, each unrolled for 80 steps. A linear decay was applied to the optimiser learning rate and entropy loss scaling throughout training (see Table 2 for details). We ran approximately 100 experiments for each mini-game, using the hyperparameter settings indicated in Table 4 combined with 3 seeds. ",
1609
+ "bbox": [
1610
+ 176,
1611
+ 853,
1612
+ 823,
1613
+ 922
1614
+ ],
1615
+ "page_idx": 14
1616
+ },
1617
+ {
1618
+ "type": "image",
1619
+ "img_path": "images/ce7160880769779dda4c01b71bb80c0c73a296b82bd706f75e2d9ec213edd709.jpg",
1620
+ "image_caption": [
1621
+ "Figure 9: Generalization results on the StarCraft II mini-game Collect Mineral Shards. Agents were trained on levels with 2 marines and tested on levels with 1, 2, 3, 4, 5 or 10 marines. Colored bars indicate mean score over the ten best runs; error bars indicate standard error. "
1622
+ ],
1623
+ "image_footnote": [],
1624
+ "bbox": [
1625
+ 272,
1626
+ 102,
1627
+ 722,
1628
+ 262
1629
+ ],
1630
+ "page_idx": 15
1631
+ },
1632
+ {
1633
+ "type": "text",
1634
+ "text": "RELATIONAL AGENT ARCHITECTURE ",
1635
+ "bbox": [
1636
+ 176,
1637
+ 362,
1638
+ 434,
1639
+ 376
1640
+ ],
1641
+ "page_idx": 15
1642
+ },
1643
+ {
1644
+ "type": "text",
1645
+ "text": "The StarCraft II (SC2) agent architecture follows closely the one we adopted in Box-World. Here we highlight the changes needed to satisfy SC2 constraints. ",
1646
+ "bbox": [
1647
+ 173,
1648
+ 393,
1649
+ 823,
1650
+ 421
1651
+ ],
1652
+ "page_idx": 15
1653
+ },
1654
+ {
1655
+ "type": "text",
1656
+ "text": "Input-preprocessing. At each time step agents are presented with 4 sources of information: minimap, screen, player, and previous-action. These tensors share the same pre-processing: numerical features are re-scaled with a logarithmic transformation and categorical features are embedded into a continuous 10-dimensional space. ",
1657
+ "bbox": [
1658
+ 174,
1659
+ 429,
1660
+ 825,
1661
+ 484
1662
+ ],
1663
+ "page_idx": 15
1664
+ },
1665
+ {
1666
+ "type": "text",
1667
+ "text": "State encoding. Spatially encoded inputs (minimap and screen) are tiled with binary masks denoting whether the previous action constituted a screen- or minimap-related action. These tensors are then fed to independent residual convolutional blocks, each consisting of one convolutional layer $( 4 \\times 4$ kernels and stride 2) followed by a residual block with 2 convolutional layers ( $3 \\times 3$ kernels and stride 1), which process and downsample the inputs to $[ 8 \\times 8 \\times \\# c h a n n e l s _ { 1 } ]$ outputs. These tensors are concatenated along the depth dimension to form a singular spatial input $( i n p u t s _ { 3 D }$ , with shape $[ 8 \\times 8 \\times \\# c h a n n e l s _ { 1 } + \\# c h a n n e l s _ { 1 } ] )$ . The remaining inputs (player and previous-action) are concatenated and passed to a 2-layer MLP (128 units, ReLU, 64 units) to form a singular non-spatial input $( i n p u t s _ { 2 D } )$ . ",
1668
+ "bbox": [
1669
+ 173,
1670
+ 491,
1671
+ 825,
1672
+ 617
1673
+ ],
1674
+ "page_idx": 15
1675
+ },
1676
+ {
1677
+ "type": "text",
1678
+ "text": "Memory processing. Next, inputs $_ { 3 D }$ is passed to the Conv2DLSTM along with its previous state to produce a new state and outputs $_ { 3 D }$ (shape $[ 8 \\times 8 \\times \\# c h a n n e l s _ { 2 } ] )$ , which represents an aggregated history of input observations. ",
1679
+ "bbox": [
1680
+ 174,
1681
+ 623,
1682
+ 825,
1683
+ 665
1684
+ ],
1685
+ "page_idx": 15
1686
+ },
1687
+ {
1688
+ "type": "text",
1689
+ "text": "Relational processing. outputs $3 D$ is flattened along the first two dimensions (forming a 2D tensor of shape $[ 6 4 \\times$ #channels2] and passed to the stacked MHDPA blocks (see Table 3 for details). Its output tensors (of shape $6 4 \\times$ attention embedding size $^ *$ number of attention heads]) follow two separate pathways – relational-spatial: reshapes the tensors to their original spatial shape $[ 8 \\times 8 ]$ ; relational-nonspatial: aggregates through a feature-wise max-pooling operation (combining the 64 embeddings into a flat tensor) and further processes using a 2-layer MLP (512 units per layer, ReLU activations). ",
1690
+ "bbox": [
1691
+ 173,
1692
+ 672,
1693
+ 825,
1694
+ 770
1695
+ ],
1696
+ "page_idx": 15
1697
+ },
1698
+ {
1699
+ "type": "text",
1700
+ "text": "Output processing. $i n p u t s _ { 2 D }$ and relational-nonspatial are concatenated to form a set of shared features. Policy logits are produced by feeding shared features to a 2-layer MLP (256 units, ReLU, $| a c t i o n s |$ units) and masking unavailable actions (following Vinyals et al. (2017)). Similarly, baselines values $V$ are generated by feeding shared features to a separate 2-layer MLP (256 units, ReLU, 1 unit). ",
1701
+ "bbox": [
1702
+ 173,
1703
+ 777,
1704
+ 825,
1705
+ 847
1706
+ ],
1707
+ "page_idx": 15
1708
+ },
1709
+ {
1710
+ "type": "text",
1711
+ "text": "Actions are sampled using computed policy logits and embedded into a 16 dimensional vector. This embedding is used to condition shared features and generate logits for non-spatial arguments (Args) through independent linear combinations (one for each argument). Finally, spatial arguments $( A r g s _ { x , y } )$ are obtained by first deconvolving relational-spatial to $[ 3 2 \\times 3 2 \\times \\# c h a n n e l s _ { 3 } ]$ tensors using Conv2DTranspose layers, conditioned by tiling the action embedding along the depth dimension and passed by $1 \\times 1 \\times 1$ convolution layers (one for each spatial argument). Spatial arguments $( x , y )$ are produced by sampling resulting tensors and selecting the corresponding row and column indexes. ",
1712
+ "bbox": [
1713
+ 174,
1714
+ 854,
1715
+ 825,
1716
+ 924
1717
+ ],
1718
+ "page_idx": 15
1719
+ },
1720
+ {
1721
+ "type": "table",
1722
+ "img_path": "images/81bb77c80db23a121b8f8f082247720b9caef3f69d0d680d420915b0397a2e60.jpg",
1723
+ "table_caption": [
1724
+ "Table 2: Shared fixed hyperparameters across mini-games. "
1725
+ ],
1726
+ "table_footnote": [],
1727
+ "table_body": "<table><tr><td>Hyperparameter</td><td>Value</td></tr><tr><td>Conv2DLSTM</td><td></td></tr><tr><td>Output channels(#channels2)</td><td>96</td></tr><tr><td>Kernel shape</td><td>(3,3)</td></tr><tr><td>Stride</td><td>(1,1)</td></tr><tr><td>Conv2DTranspose</td><td></td></tr><tr><td>Output channels (#channels3)</td><td>16</td></tr><tr><td>Kernel shape</td><td>(4, 4)</td></tr><tr><td>Stride</td><td>(2,2)</td></tr><tr><td>Discount (γ)</td><td>0.99</td></tr><tr><td>Batch size</td><td>32</td></tr><tr><td>Unroll Length</td><td>80</td></tr><tr><td>Baseline loss scaling</td><td>0.1</td></tr><tr><td>Clip global gradient norm</td><td>100.0</td></tr><tr><td>Adam β1</td><td>0.9</td></tr><tr><td>Adam β2</td><td>0.999</td></tr><tr><td>Adam e</td><td>1e-8</td></tr></table>",
1728
+ "bbox": [
1729
+ 346,
1730
+ 101,
1731
+ 661,
1732
+ 429
1733
+ ],
1734
+ "page_idx": 16
1735
+ },
1736
+ {
1737
+ "type": "table",
1738
+ "img_path": "images/825ca0c1e337a3c152b7411c3297147b44565625f507cfc102da1df84efe9eb5.jpg",
1739
+ "table_caption": [
1740
+ "Table 3: Fixed MHDPA settings for StarCraft II mini-games. "
1741
+ ],
1742
+ "table_footnote": [],
1743
+ "table_body": "<table><tr><td>Setting Value</td></tr><tr><td>MLP layers 2</td></tr><tr><td>Units per MLP layer 384</td></tr><tr><td>MLP activations ReLU</td></tr><tr><td>Attention embedding size 32</td></tr><tr><td>Weight sharing shared MLP across blocks</td></tr><tr><td>shared embedding across blocks</td></tr></table>",
1744
+ "bbox": [
1745
+ 297,
1746
+ 474,
1747
+ 699,
1748
+ 614
1749
+ ],
1750
+ "page_idx": 16
1751
+ },
1752
+ {
1753
+ "type": "text",
1754
+ "text": "",
1755
+ "bbox": [
1756
+ 176,
1757
+ 672,
1758
+ 826,
1759
+ 702
1760
+ ],
1761
+ "page_idx": 16
1762
+ },
1763
+ {
1764
+ "type": "text",
1765
+ "text": "CONTROL AGENT ARCHITECTURE ",
1766
+ "text_level": 1,
1767
+ "bbox": [
1768
+ 176,
1769
+ 718,
1770
+ 410,
1771
+ 731
1772
+ ],
1773
+ "page_idx": 16
1774
+ },
1775
+ {
1776
+ "type": "text",
1777
+ "text": "The control agent architecture only differs on the relational processing part of the pipeline. Analogous to the relational agent, output $\\beta _ { 2 D }$ are obtained from Conv2DLSTM layers. These tensors are first passed to a 12-layer deep residual model – comprising 4 blocks of 3 convolutions layers (32 output channels, $4 \\times 4$ kernel for the first convolution and $3 \\times 3$ for the second and third, and stride 1) interleaved with ReLU activations and skip-connections – as proposed by He et al. (2016), to form the relational-spatial outputs. These tensors also follow a separate pathway where they are flattened and passed to a 2-layer MLP (512 units per layer, ReLU activations) to produce what we refer to above as relational-nonspatial. The remaining architecture is identical to the relational agent. ",
1778
+ "bbox": [
1779
+ 174,
1780
+ 741,
1781
+ 825,
1782
+ 853
1783
+ ],
1784
+ "page_idx": 16
1785
+ },
1786
+ {
1787
+ "type": "table",
1788
+ "img_path": "images/d84d12d9c82871efb78796042545cb5b22a6aab30aacfc38d01c3c0f9d635845.jpg",
1789
+ "table_caption": [
1790
+ "Table 4: Swept hyperparameters across mini-games. "
1791
+ ],
1792
+ "table_footnote": [],
1793
+ "table_body": "<table><tr><td>Hyperparameter</td><td>Value</td></tr><tr><td>Relational module</td><td></td></tr><tr><td>Number of heads</td><td>[1,3]</td></tr><tr><td>Number of blocks</td><td>[1, 3, 5]</td></tr><tr><td>Entropy loss scaling</td><td>[le-1,le-2,le-3]</td></tr><tr><td>Adam learning rate</td><td>[le-4,le-5]</td></tr></table>",
1794
+ "bbox": [
1795
+ 338,
1796
+ 434,
1797
+ 658,
1798
+ 555
1799
+ ],
1800
+ "page_idx": 17
1801
+ }
1802
+ ]
parse/train/HkxaFoC9KQ/HkxaFoC9KQ_middle.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/HkxaFoC9KQ/HkxaFoC9KQ_model.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/NTEz-6wysdb/NTEz-6wysdb.md ADDED
@@ -0,0 +1,304 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # DISTILLING KNOWLEDGE FROM READER T O RETRIEVER FOR QUESTION ANSWERING
2
+
3
+ Gautier Izacard1,2,3, Edouard Grave1
4
+ 1Facebook AI Research, 2Ecole normale sup ´ erieure, PSL University, ´ 3Inria
5
+ {gizacard|egrave}@fb.com
6
+
7
+ # ABSTRACT
8
+
9
+ The task of information retrieval is an important component of many natural language processing systems, such as open domain question answering. While traditional methods were based on hand-crafted features, continuous representations based on neural networks recently obtained competitive results. A challenge of using such methods is to obtain supervised data to train the retriever model, corresponding to pairs of query and support documents. In this paper, we propose a technique to learn retriever models for downstream tasks, inspired by knowledge distillation, and which does not require annotated pairs of query and documents. Our approach leverages attention scores of a reader model, used to solve the task based on retrieved documents, to obtain synthetic labels for the retriever. We evaluate our method on question answering, obtaining state-of-the-art results.
10
+
11
+ # 1 INTRODUCTION
12
+
13
+ Information retrieval is an important component for many natural language processing tasks, such as question answering (Voorhees et al., 1999) or fact checking (Thorne et al., 2018). For example, many real world question answering systems start by retrieving a set of support documents from a large source of knowledge such as Wikipedia. Then, a finer-grained model processes these documents to extract the answer. Traditionally, information retrieval systems were based on hand-crafted sparse representations of text documents, such as TF-IDF or BM25 (Jones, 1972; Robertson et al., 1995). Recently, methods based on dense vectors and machine learning have shown promising results (Karpukhin et al., 2020; Khattab et al., 2020). Deep neural networks based on pre-training, such as BERT (Devlin et al., 2019), have been used to encode documents into fixed-size representations. These representations are then queried using approximate nearest neighbors (Johnson et al., 2019). These techniques have lead to improved performance on various question answering tasks.
14
+
15
+ A challenge of applying machine learning to information retrieval is to obtain training data for the retriever. To train such models, one needs pairs of queries and the corresponding list of documents that contains the information corresponding to the queries. Unfortunately, hand-labeling data to that end is time consuming, and many datasets and applications lack such annotations. An alternative approach is to resort to heuristics, or weakly supervised learning, for example by considering that all documents containing the answer are positive examples. However, these approaches suffer from the following limitations. First, frequent answers or entities might lead to false positive examples. As an example, consider the question “where was Ada Lovelace born?”. The sentence “Ada Lovelace died in 1852 in London” would be considered as a positive example, because it contains the answer “London”. A second limitation is that for some tasks, such as fact checking or long form question answering, such heuristics might not be applicable directly.
16
+
17
+ In this paper, we propose a procedure to learn retriever systems without strong supervision in the form of pairs of queries and documents. Following previous work (Chen et al., 2017), our approach uses two models: the first one retrieves documents from a large source of knowledge (the retriever), the second one processes the support documents to solve the task (the reader). Our method is inspired by knowledge distillation (Hinton et al., 2015), and uses the reader model to obtain synthetic labels to train the retriever model. More precisely, we use a sequence-to-sequence model as the reader, and use the attention activations over the input documents as synthetic labels to train the retriever. Said otherwise, we assume that attention activations are a good proxy for the relevance of documents. We then train the retriever to reproduce the ranking of documents corresponding to that metric.
18
+
19
+ We make the following contributions:
20
+
21
+ • First, we show that attention scores from a sequence-to-sequence reader model are a good measure of document relevance (Sec. 3.2) ;
22
+ Second, inspired by knowledge distillation, we propose to iteratively train the retriever from these activations, and compare different loss functions (Sec. 3.4) ;
23
+ • Finally, we evaluate our method on three question-answering benchmarks, obtaining stateof-the-art results (Sec. 4).
24
+
25
+ Our code is available at: github.com/facebookresearch/FiD.
26
+
27
+ # 2 RELATED WORK
28
+
29
+ We briefly review information retrieval based on machine learning. We refer the reader to Manning et al. (2008) and Mitra et al. (2018) for a more exhaustive introduction to the subject.
30
+
31
+ Vector space models. In traditional information retrieval systems, documents and queries are represented as sparse vectors, each dimension corresponding to a different term. Different schemes have been considered to weigh the different term, the most well known being based on inverse document frequency, or term specificity (Jones, 1972). This technique was later extended, leading to the BM25 weighting scheme which is still widely used today (Robertson et al., 1995). A limitation of sparse representations is that the terms of the query need to match the terms of the returned documents. To overcome this, Deerwester et al. (1990) proposed to use latent semantic analysis for indexing, leading to low-dimension dense representations of documents.
32
+
33
+ Neural information retrieval. Following the success of deep learning for other natural processing tasks, neural networks were applied to the task of information retrieval. Huang et al. (2013) proposed a deep bag-of-words model, where queries and documents were embedded independently, a technique known as bi-encoder. Documents were then ranked by using the cosine similarity with the query, and the model was trained on clickthrough data from a search engine. This technique was later extended by using convolutional neural networks (Shen et al., 2014) and recurrent neural networks (Palangi et al., 2016). A limitation of independently embedding documents and query is that it does not capture fine-grained interactions between the query and documents. This lead Nogueira & Cho (2019) and Yang et al. (2019) to use a BERT model to jointly embed documents and query, a technique known as cross-encoder.
34
+
35
+ End-to-end retrieval. Most of the methods described in the previous paragraph were used to rerank a small number of documents, usually returned by a traditional IR systems. In the context of ad-hoc document retrieval, Gillick et al. (2018) showed that bi-encoder models could be competitive with traditional IR systems. For open domain question-answering, Karpukhin et al. (2020) introduced dense passage retrieval (DPR), which uses dense embeddings and nearest neighbors search. More precisely, question and passage embeddings are obtained using a BERT-based biencoder model, which is trained on a small dataset of question and passage pairs. Then, the full knowledge source (Wikipedia) is encoded using this model, and passages are queried by computing the $\mathbf { k }$ -nearest neighbors of the embedding of the question. Jointly embedding the query and documents makes the application of cross-encoder models intractable to large database. To address this limitation, Humeau et al. (2019) introduced the poly-encoder architecture, in which each documents is represented by multiple vectors instead of one. Similarly, Khattab et al. (2020) proposed a scoring function where each term of the query and documents is represented by a single vector. To make the method tractable, their system retrieves documents with an approximate score, which are then re-ranked with the exact one. Finally, Luan et al. (2020) conducts a theoretical and empirical study of sparse, dense and cross-attention information retrieval systems.
36
+
37
+ Unsupervised learning. Closest to our work, there is growing body of work trying to learn information retrieval systems from unsupervised data. Lee et al. (2019) introduced the inverse cloze task for pre-training retrievers, which can then be fine-tuned end-to-end on question-answering tasks. This pre-training scheme was later evaluated for ad-hoc document retrieval by Chang et al. (2020). Guu et al. (2020) proposed to augment language model pre-training with a retriever module, which is trained using the masked language modeling objective. Similarly, Lewis et al. (2020a) introduced a sequence-to-sequence model that is pre-trained by generating a target text, after retrieving a set of related texts. Lewis et al. (2020b) further train the retriever obtained in Karpukhin et al. (2020) by backpropagating to the retriever the error between the generated output and the gold answer.
38
+
39
+ Simultaneously to our work, Yang & Seo (2020) proposes to train a retriever with knowledge distillation. The main difference with our method is the nature of the synthetic labels that are used to train the retriever. Yang & Seo (2020) uses the DPR reader, which includes a classifier that predicts which passage contains the answer, and can be seen as a cross-encoder reranker. This technique thus performs the distillation of a cross-encoder retriever to a bi-encoder retriever. In contrast, our method uses the internal attention scores of the reader, which does not require additional supervision besides pairs of question and answer.
40
+
41
+ # 3 METHODOLOGY
42
+
43
+ Our system is composed of two modules, the retriever and the reader, following the standard pipeline for open-domain question answering. Given an input question these modules are used in a two-step process to generate an answer. First the retriever selects support passages in a large knowledge source. Then these passages are processed by the reader, along with the question, to generate an answer. For the reader module we use the Fusion-in-Decoder model (Izacard & Grave, 2020), which achieves state-of-the-art performance when combined with BM25 or DPR (Karpukhin et al., 2020). It is based on a sequence-to-sequence architecture, and is initialized from pre-trained models such as T5 or BART (Raffel et al., 2019; Lewis et al., 2019).
44
+
45
+ The focus of this work is to train the retriever without strong supervision or weakly supervised learning based on heuristics. For this we propose to train the retriever by learning to approximate the attention score of the reader. The training scheme outlined here can be seen as a student-teacher pipeline, where the teacher, the reader module, produces targets which are used to train a student network, the reader. By doing so, we hope to leverage the signal extracted from the question-answer pairs by the reader. Since the goal of the retriever is to retrieve the most relevant passages, by training the retriever to estimate the reader attention scores, we implicitly make the assumption that these scores are a good proxy for the usefulness of a passage to answer the question.
46
+
47
+ In this section we will first describe the Fusion-in-Decoder architecture, before elaborating on the signal which is used to train the retriever, the design of the retriever, and how this module is trained.
48
+
49
+ # 3.1 CROSS-ATTENTION MECHANISM
50
+
51
+ First, let us briefly review the Fusion-in-Decoder model (FiD, Izacard & Grave, 2020). The underlying architecture is a sequence-to-sequence model, composed of an encoder and a decoder. The encoder independently processes $n _ { p }$ different text inputs $\left( s _ { k } \right) _ { 1 \leq k \leq n _ { p } }$ . In the case of open-domain question answering based on Wikipedia, each input $s _ { k }$ is the concatenation of the question $q$ and a support passage, with special tokens question:, title: and context: added before the question, the title of the Wikipedia article and the text of each passage. The output representations of the encoder are then concatenated to form a global representation $\mathbf { X }$ of dimension $\bar { ( \sum _ { k } \ell _ { k } ) } \times d .$ , where $\ell _ { k }$ is the length of the $k$ -th segment and $d$ is the dimension of the embeddings and hidden representations of the model. Then, the decoder processes this representation as a regular autoregressive model, alternating self-attention, cross-attention and feed-forward modules.
52
+
53
+ Only the cross-attention module explicitly takes as input the global output representation $\mathbf { X }$ of the encoder. If $\mathbf { H } \in \mathbb { R } ^ { d }$ denotes the output of the previous self-attention layer of the decoder, the crossattention operation consists in the following operations. First, queries $\mathbf { Q }$ , keys $\mathbf { K }$ and values $\mathbf { V }$ are computed by applying linear transformations:
54
+
55
+ $$
56
+ \mathbf { Q } = \mathbf { W } _ { Q } \mathbf { H } , \quad \mathbf { K } = \mathbf { W } _ { K } \mathbf { X } , \quad \mathbf { V } = \mathbf { W } _ { V } \mathbf { X } .
57
+ $$
58
+
59
+ Then a similarity score between the query at position $i$ , $\mathbf { Q } _ { i }$ , and the key at position $j , \mathbf { K } _ { j }$ , is obtained by computing the dot-product between these two elements, and normalized over the dimension:
60
+
61
+ $$
62
+ \alpha _ { i , j } = { \bf Q } _ { i } ^ { T } { \bf K } _ { j } , \qquad \tilde { \alpha } _ { i , j } = \frac { \exp ( \alpha _ { i , j } ) } { \sum _ { m } \exp ( \alpha _ { i , m } ) } .
63
+ $$
64
+
65
+ A new representation is obtained as a sum of the values, weighted by the attention probabilities, before going through a final linear transformation $\mathbf { W } _ { o }$ :
66
+
67
+ $$
68
+ \mathbf { O } _ { i } = \mathbf { W } _ { O } \sum _ { j } \tilde { \alpha } _ { i , j } \mathbf { V } _ { i , j }
69
+ $$
70
+
71
+ The operations described above are performed in parallel with different linear transformations in the case of multi-head attention. Finally a normalization layer is applied, and this pipeline is wrapped by a skip connection. See Vaswani et al. (2017) for more details on the structure of Transformers.
72
+
73
+ # 3.2 CROSS-ATTENTION SCORE AS A RELEVANCE MEASURE FOR PASSAGE RETRIEVAL
74
+
75
+ In some sense, the attention scores $\alpha _ { : , j }$ involving the $j$ -th key measures the importance of this key, and corresponding value, to compute the next representation. We hypothesize that it is good proxy to estimate the relevance of a passage — the more the tokens in a text segment are attended to, the more relevant the text segment is to answer the question.
76
+
77
+ Given the reader model, an input question $q$ and a corresponding set of support passages $\begin{array} { l l l } { { \mathcal D } _ { q } } & { = } & { ( p _ { k } ) _ { 1 \leq k \leq n } } \end{array}$ , we obtain relevance scores $( G _ { q , p _ { k } } ) _ { 1 \leq k \leq n }$ for each passage by aggregating attention scores. In particular, the score $G _ { q , p _ { k } }$ k is obtained by averaging the pre-attention scores $\alpha _ { 0 , }$ : over all the tokens in the input $s _ { k }$ corresponding to the passage $p _ { k }$ , all the layers and all the heads of the decoder. Note that the FiD decoder jointly processes the passages, and thus the score $G _ { q , p _ { k } }$ depends on the other support passages. We consider other pooling operators, such as max, to aggregate attention scores over layers, heads and tokens and empirically compare them in Sec. 5.2.
78
+
79
+ Before we proceed, let us consider the following simple experiment, which is a first indication that reader attention scores are indeed a strong relevance signal. Given a question and 100 passages retrieved with DPR, our goal is to select the 10 best passages. When using the top 10 passages from DPR instead of the top 100, the performance of our reader drops from $4 8 . 2 \ \mathrm { E M }$ to 42.9 EM. On the other hand, if we select the top 10 documents according to the attention scores, the performance only drops to $4 6 . 8 \ : \mathrm { E M }$ .
80
+
81
+ # 3.3 DENSE BI-ENCODER FOR PASSAGE RETRIEVAL
82
+
83
+ Ideally, we would like to rank passages according to the reader cross-attention scores. In practice however, since the passages and the question need to be processed simultaneously by the reader module it is impractical to query a large knowledge source this way. Thus, we use a retriever model composed of an embedder function $E$ that maps any text passage to a $d$ -dimensional vector, such that the similarity score between a question $q$ and a passage $p$ is defined as $S _ { \theta } ( q , p ) = E ( q ) ^ { T } E ( p )$ . This similarity metric enables us to index all passages in the knowledge source as a preprocessing step. Then at runtime, passages with the highest similarity score with the input question are retrieved, by using an efficient similarity search library such as FAISS (Johnson et al., 2019).
84
+
85
+ For the embedder we use BERT and follow DPR by considering that the encodings $E ( q )$ and $E ( p )$ are obtained by extracting the representation of the initial [CLS] token. This leads to a representation of dimension $d = 7 6 8$ in the case of a base model. Differently from DPR, we use the same encoding function $E$ for the questions and passages by sharing parameters.
86
+
87
+ # 3.4 DISTILLING THE CROSS-ATTENTION SCORE TO A BI-ENCODER
88
+
89
+ In this section, we describe how to train the retriever model, based on the relevance scores obtained in Sec. 3.2. For the training objective of the retriever, we propose to minimize the KL-divergence between the output $S _ { \theta } ( q , p )$ and the score $G _ { q , p }$ after normalization:
90
+
91
+ $$
92
+ \mathcal { L } _ { \mathrm { K L } } ( \boldsymbol { \theta } , \boldsymbol { \mathcal { Q } } ) = \sum _ { \boldsymbol { q } \in \mathcal { Q } , \boldsymbol { p } \in \mathcal { D } _ { \boldsymbol { q } } } \tilde { G } _ { \boldsymbol { q } , \boldsymbol { p } } ( \log \tilde { G } _ { \boldsymbol { q } , \boldsymbol { p } } - \log \tilde { S } _ { \boldsymbol { \theta } } ( \boldsymbol { q } , \boldsymbol { p } ) ) ,
93
+ $$
94
+
95
+ where
96
+
97
+ $$
98
+ \tilde { G } _ { q , p } = \frac { \exp ( G _ { q , p } ) } { \sum _ { p ^ { \prime } \in \mathcal { D } _ { q } } \exp ( G _ { q , p ^ { \prime } } ) } , \qquad \tilde { S } _ { \theta } ( q , p ) = \frac { \exp ( S _ { \theta } ( q , p ) ) } { \sum _ { p ^ { \prime } \in \mathcal { D } _ { q } } \exp ( S _ { \theta } ( q , p ^ { \prime } ) ) } .
99
+ $$
100
+
101
+ In Sec. 5.1 we present results obtained when using alternatives to this training objective. We consider two other objectives which have been used in Dehghani et al. (2017), where BM25 is used as a teacher model to train a neural ranker. A first option consists in training the retriever with a regression approach by minimizing the mean squared error:
102
+
103
+ $$
104
+ \mathcal { L } _ { \mathrm { M S E } } ( \theta , \mathcal { Q } ) = \sum _ { q \in \mathcal { Q } , p \in \mathcal { D } _ { q } } ( S _ { \theta } ( q , p ) - G _ { q , p } ) ^ { 2 } .
105
+ $$
106
+
107
+ The second option we consider is to use a max-margin loss that explicitly penalizes inversions in the ranking estimated by the retriever:
108
+
109
+ $$
110
+ \mathcal { L } _ { \mathrm { r a n k i n g } } ( \theta , \mathcal { Q } ) = \sum _ { \scriptstyle q \in \mathcal { Q } , p _ { 1 } , p _ { 2 } \in \mathcal { D } _ { q } } \operatorname* { m a x } \left( 0 , \gamma - \mathrm { s i g n } ( G _ { q , p _ { 1 } } - G _ { q , p _ { 2 } } ) ( S _ { \theta } ( q , p _ { 1 } ) - S _ { \theta } ( q , p _ { 2 } ) ) \right) .
111
+ $$
112
+
113
+ In words, if $p _ { 1 }$ is more relevant to answer the question $q$ than $p _ { 2 }$ , i.e. $G _ { q , p _ { 1 } } > G _ { q , p _ { 2 } }$ , the loss pushes the retriever score of $p _ { 1 }$ to be larger than the score of $p _ { 2 }$ by at least a margin of $\gamma$ .
114
+
115
+ # 3.5 ITERATIVE TRAINING
116
+
117
+ In this section, we explain how iterative training can be used with the student-teacher scheme described in the previous section, similarly to Khattab et al. (2020). This iterative procedure can be interpreted as using the current retriever to sample negative examples, in order to train a new retriever. When learning a retriever with discriminative training, negative samples play an important role, and various strategies have been considered in previous work. Karpukhin et al. (2020) compared random sampling with using the top- $\mathbf { \nabla } \cdot \mathbf { k }$ passages from BM25 which do not contain the answer and with using the positive passages from other queries. Consider that for each question, we have an initial set of support documents $\mathcal { D } _ { q } ^ { 0 }$ . We propose to use an iterative pipeline where each iteration can be described as the following 4-step process:
118
+
119
+ 1. Train the reader $R$ using the set of support documents for each question $\mathcal { D } _ { q } ^ { 0 }$ .
120
+ 2. Compute aggregated attention scores $( G _ { q , p } ) _ { q \in \mathcal { Q } , p \in \mathcal { D } _ { q } ^ { 0 } }$ with the reader $R$ .
121
+ 3. Train the retriever E using the scores (Gq,p)q∈Q,p∈D0 .
122
+ 4. Retrieve top-passages with the new trained retriever $E$ .
123
+
124
+ This multi-step procedure can be repeated multiple times. A critical point of the training procedure is the initial set of documents corresponding to each question. In Sec. 4, we compare retrievers obtained by starting from documents obtained using BM25 or cosine similarity from a BERT model. In particular, we show that while the initial performance with BERT is low, the iterative procedure allows to greatly improve the performance of the model.
125
+
126
+ # 4 EXPERIMENTS
127
+
128
+ In this section we evaluate the student-teacher training procedure from the previous section. We show that we obtain competitive performance without strong supervision for support documents.
129
+
130
+ # 4.1 EXPERIMENTAL SETTING
131
+
132
+ Datasets. We perform experiments on TriviaQA (Joshi et al., 2017) and NaturalQuestions (Kwiatkowski et al., 2019), two standard benchmarks for open-domain question answering. TriviaQA is made of questions from trivia and quiz league websites, and does not contain gold support documents. NaturalQuestions contains questions corresponding to web search queries, and gold support documents from Wikipedia. Following the setting from Lee et al. (2019); Karpukhin et al. (2020), we use the original evaluation set as test set, and keep $10 \%$ of the training data for validation. We use the Wikipedia dump from Dec. 20, 2018 for support documents, splitting articles into non-overlapping passages of 100 tokens, and applying the same preprocessing as Chen et al. (2017).
133
+
134
+ Table 1: Iterative training starting with documents retrieved with BERT and BM25. Iteration 0 corresponds to the performance of the reader trained on the set of initial support documents. We report all metrics on the validation set.
135
+
136
+ <table><tr><td></td><td colspan="5">BERT</td><td colspan="2">BM25</td></tr><tr><td></td><td>Iter.</td><td>P@20</td><td>P@100</td><td>Dev EM</td><td>P@20</td><td>P@100</td><td>Dev EM</td></tr><tr><td rowspan="4">NaturalQuestions</td><td>0</td><td>4.8</td><td>12.0</td><td>9.8</td><td>59.3</td><td>74.0</td><td>41.2</td></tr><tr><td>1</td><td>32.2</td><td>45.8</td><td>16.9</td><td>76.4</td><td>84.3</td><td>46.8</td></tr><tr><td>2</td><td>51.1</td><td>62.6</td><td>28.6</td><td>80.4</td><td>86.7</td><td>47.9</td></tr><tr><td>3</td><td>67.8</td><td>76.8</td><td>39.3</td><td>80.0</td><td>86.3</td><td>46.2</td></tr><tr><td rowspan="5">TriviaQA</td><td>0</td><td>4.6</td><td>12.0</td><td>9.7</td><td>75.0</td><td>82.3</td><td>65.3</td></tr><tr><td>1</td><td>37.1</td><td>59.4</td><td>19.6</td><td>79.0</td><td>85.5</td><td>66.7</td></tr><tr><td>2</td><td>60.8</td><td>73.4</td><td>43.3</td><td>82.1</td><td>86.5</td><td>67.5</td></tr><tr><td>3</td><td>72.0</td><td>83.2</td><td>52.0</td><td>81.6</td><td>86.6</td><td>67.7</td></tr><tr><td>4</td><td>76.4</td><td>84.6</td><td>62.3</td><td>1</td><td>1</td><td>1</td></tr></table>
137
+
138
+ We also evaluate on NarrativeQuestions (Kocisk ˇ y et al., 2018), using a publicly available prepro-\` cessed version.1 This is a reading comprehension dataset built on a corpus of books and movie scripts. For each story, questions are generated by human annotators based on a summary of the given document. We consider the full story setting, where the task is to answer questions given the entire story and not the summary used to generate question-answer pairs. Here the knowledge source is not the same for all questions: given a question the retrieval operation is performed on all passages of the associated story. These passages are obtained by dividing the story in chunks of 100 words. These stories are long documents, with an average of 60k words. While part of the documents could be processed entirely by the Fusion-in-Decoder module, it is interesting to limit the number of support passages to reduce the computational cost of the reading step.
139
+
140
+ While answers in TriviaQA and NaturalQuestions are short, NarrativeQA answers are about five words long on average, with medium length answers such as ”He dismantles it and attaches it to his mother’s jeep” which answers the question ”What does Mark do with his radio station?”. Notably a significant number of answers do not correspond to spans in the story. It is thus not straightforward to train the retriever with heuristics using question-answer pairs. In our case we use the same pipeline as for TriviaQA and NaturalQuestions, demonstrating the flexibility of our approach.
141
+
142
+ Evaluation. The model performance is assessed in two ways. First, following previous work such as DPR and ColbertQA, we report the top- $k$ retrieval accuracy $( \mathrm { P } @ \mathrm { k } )$ , which is the percentage of questions for which at least one passage of the top- $k$ retrieved passages contains the gold answer. It is unclear how well this metric evaluates the retriever performance, since the answer can be contained in a passage without being related to the question. This is notably true for common words or entities.
143
+
144
+ We also report the final end-to-end performance of the question answering system composed of the retriever and reader modules. This is the metric we are fundamentally interested in. For TriviaQA and NaturalQuestions, predicted answers are evaluated with the standard exact match metric (EM), as introduced by Rajpurkar et al. (2016). For NarrativeQA we report the metrics proposed in the original paper: ROUGE-L, BLEU-1, BLEU-4 and METEOR.
145
+
146
+ # 4.2 TECHNICAL DETAILS
147
+
148
+ Initialization. Similarly to DPR, we initialize the retriever with the BERT base model, pretrained with uncased text. The Fusion-in-Decoder reader is initialized with the T5 base model. A critical component of the iterative training procedure is the initialization of the support passages $\mathcal { D } _ { q } ^ { 0 }$ associated with each question $q$ . For this we consider different options. The first one is to use passages retrieved using BM25. We use the implementation from Apache Lucene2 with default parameters, and tokenize questions and passages with $\operatorname { S p a C y } ^ { 3 }$ . We also use passages obtained with BERT as a retriever without fine-tuning, this leads to poor initial performance. Finally in Table 2 we show that initializing $\mathcal { D } _ { q } ^ { 0 }$ with passages obtained with DPR (Karpukhin et al., 2020) outperforms the two previous initializations. We train all retrievers using 100 passages. For the reader, we use 100 passages for NaturalQuestions and TriviaQA and 20 passages for NarrativeQA.
149
+
150
+ Table 2: Comparison to state-of-the-art models on NaturalQuestions and TriviaQA.
151
+
152
+ <table><tr><td>Model</td><td colspan="2">NQ</td><td colspan="2">TriviaQA</td></tr><tr><td></td><td>dev.</td><td>test</td><td>dev.</td><td>test</td></tr><tr><td>DPR (Karpukhin et al., 2020)</td><td>1</td><td>41.5</td><td>1</td><td>57.9</td></tr><tr><td>RAG (Lewis et al., 2020b)</td><td>=</td><td>44.5</td><td>1</td><td>56.1</td></tr><tr><td>ColBERT-QA (Khattab et al., 2020)</td><td>1</td><td>48.2</td><td>1</td><td>63.2</td></tr><tr><td>Fusion-in-Decoder (T5 base) (Izacard &amp; Grave,2020)</td><td></td><td>48.2</td><td>=</td><td>65.0</td></tr><tr><td>Fusion-in-Decoder (T5 large) (Izacard &amp; Grave,2020)</td><td>1</td><td>51.4</td><td>1</td><td>67.6</td></tr><tr><td>Ours (starting from BERT,T5 base)</td><td>39.3</td><td>40.0</td><td>62.5</td><td>62.7</td></tr><tr><td>Ours (starting from BM25, T5 base)</td><td>47.9</td><td>48.9</td><td>67.7</td><td>67.7</td></tr><tr><td>Ours (starting from DPR, T5 base)</td><td>48.0</td><td>49.6</td><td>68.6</td><td>68.8</td></tr><tr><td>Ours (starting from DPR, T5 large)</td><td>51.9</td><td>53.7</td><td>71.9</td><td>72.1</td></tr></table>
153
+
154
+ Iterative training. We apply the iterative training procedure on each dataset independently. Both the reader and the retriever are fine-tuned using the ADAM algorithm (Kingma & Ba, 2014), with a batch of size 64. The reader is trained for $1 0 \mathrm { k }$ gradient steps with a constant learning rate of $1 0 ^ { - 4 }$ , and the best model is selected based on the validation performance. The retriever is trained with a constant learning rate of $5 \cdot 1 0 ^ { - 5 }$ until the performance saturates. To monitor the performance of the retriever during training, we measure the similarity between the reader and the retriever rankings. At each new training iteration the reader is reinitialized from T5 base, while we pursue the training of the retriever. We found that restarting from T5 base is important for the first iterations when starting with BERT documents. We have not tried to reinitialize the retriever between each iteration. More details on the hyperparameters and the training procedure are reported in Appendix A.2.
155
+
156
+ # 4.3 RESULTS
157
+
158
+ In Table 1, we report the performance of our approach for different number of self-training iterations. Generally, we observe that the accuracy of our system increases with the number of iterations, obtaining strong performance after a few iterations. Interestingly, while the initial performance with documents retrieved with BERT is very poor, our method still reach competitive scores on TriviaQA, and to a lesser extent, NaturalQuestions. However, a second observation is that the quality of the initial document sets plays an important role on the performance of the end system. Indeed, we observe that starting the procedure from BM25 documents, which are higher quality as indicated by the performance of the system at iteration 0, leads to stronger results than using BERT documents. An interesting research question would be to explore pre-training of the initial BERT model for retrieval, for example by using the inverse cloze task.
159
+
160
+ In Table 2, we report the performance of our approach, as well as existing state-of-the-art systems on TriviaQA and NaturalQuestions. In addition to initializing our method with documents retrieved with BM25 and BERT, we also train a system by starting from DPR documents. First, we observe that our method improve the performance over the state-of-the-art, even when starting from BM25 documents. This validates our assumption that it is possible to obtain strong retrievers without the need of supervision for the documents. Second, when starting from DPR passages, our method leads to a $+ 4 . 5$ EM improvement on TriviaQA and $+ 2 . 3$ EM improvement on NaturalQuestions when the final evaluation is carried out with a large reader.
161
+
162
+ Table 3: Performance on NarrativeQA.
163
+
164
+ <table><tr><td>Method</td><td>Iter.</td><td colspan="2">Rouge-L</td><td colspan="2">Bleu-1</td><td colspan="2">Bleu-4</td><td colspan="2">Meteor</td></tr><tr><td></td><td></td><td>dev.</td><td>test</td><td>dev.</td><td>test</td><td>dev.</td><td>test</td><td>dev.</td><td>test</td></tr><tr><td>Best from Kocisky et al. (2018)</td><td>1</td><td>14.5</td><td>14.0</td><td>20.0</td><td>19.1</td><td>2.23</td><td>2.1</td><td>4.6</td><td>4.4</td></tr><tr><td>DPR + FiD</td><td>-</td><td>29.7</td><td>30.8</td><td>33.0</td><td>34.0</td><td>6.7</td><td>6.9</td><td>10.3</td><td>10.8</td></tr><tr><td>Ours starting from BM25</td><td>0</td><td>29.9</td><td>30.3</td><td>34.6</td><td>33.7</td><td>7.1</td><td>6.5</td><td>10.5</td><td>10.4</td></tr><tr><td>Ours starting from BM25</td><td>1</td><td>31.6</td><td>32.0</td><td>34.9</td><td>35.3</td><td>7.6</td><td>7.5</td><td>11.0</td><td>11.1</td></tr></table>
165
+
166
+ In Table 3, we report the performance of our method on the NarrativeQA dataset. We use the setting where the knowledge source corresponds to the whole document, and in particular, we do not use the summary. We compare our results to the best ones reported in the original paper for this setting. Similar to results obtained on NaturalQuestions and TriviaQA, we observe that training the retriever by using the attention scores of the reader leads to improvements, compared to the BM25 baseline.
167
+
168
+ # 5 ABLATIONS
169
+
170
+ In this section, we investigate design choices regarding two key elements of our approach: the training objective and the aggregation of cross-attention scores. For all experiments, we consider a simplified experimental setting: a single training iteration is performed on NaturalQuestions, starting from BM25 passages.
171
+
172
+ # 5.1 TRAINING OBJECTIVES
173
+
174
+ In Table 4 we report the performance of our model trained with the different training objectives described in Sec. 3.3. We observe that using the KL-divergence between the aggregated scores of the reader and the scores of the retriever outperforms the other objective functions.
175
+
176
+ <table><tr><td>Method</td><td>P@5</td><td>P@20</td><td>P@100</td><td>Dev EM</td></tr><tr><td>Mean Squared Error</td><td>46.5</td><td>61.2</td><td>73.9</td><td>40.6</td></tr><tr><td>Max-margin loss,γ = 1</td><td>60.3</td><td>73.6</td><td>82.7</td><td>45.4</td></tr><tr><td>Max-margin loss, = 0.2</td><td>60.3</td><td>73.5</td><td>82.6</td><td>45.8</td></tr><tr><td>Max-margin loss, γ = 0.1</td><td>60.2</td><td>73.5</td><td>82.6</td><td>45.1</td></tr><tr><td>KL-divergence</td><td>64.7</td><td>76.4</td><td>84.3</td><td>46.8</td></tr></table>
177
+
178
+ Table 4: Comparison of training objectives on NaturalQuestions after one iteration. We report all the metrics on the validation set.
179
+
180
+ # 5.2 HOW TO AGGREGATE CROSS-ATTENTION SCORES?
181
+
182
+ In Section 4 the cross-attention scores $\alpha$ are aggregated in a specific way, in order to obtain a single scalar used to train the retriever. Formally let us denote by $\alpha _ { i , j , k , h }$ the cross-attention scores between token $i$ of the output and token $j$ of the input, for the $k$ -th layer and $h$ -th head. Then, the scores $G _ { q , p }$ for $p \in \mathcal { D } _ { q }$ used in Section 4 are computed as follows:
183
+
184
+ $$
185
+ G _ { q , p } = \operatorname* { m e a n } _ { j , k , h } \alpha _ { 0 , j , k , h } ,
186
+ $$
187
+
188
+ where $j$ describes the input tokens corresponding to $p$ . In Table 5 we explore alternatives to this choice by considering different aggregation schemes. In particular, we consider (1) taking the max over the input tokens corresponding to passage $p$ instead of the average, (2) taking the average over the output tokens instead of taking the score of the first token, (3) taking the mean over the last six layers instead of all the layers, (4) taking the max over the layers instead of the average, (5) taking the max over the heads instead of the average. We observe that the performance of our approach is relatively stable to the choice of aggregation, and that the best result is obtained by averaging, except over the output tokens where it is best to only consider the first token.
189
+
190
+ Table 5: Comparison of attention aggregation schemes on NaturalQuestions after one iteration. The index $i$ corresponds to output tokens, $j$ corresponds to input tokens of a given passage, $h$ to heads and $k$ to layers of the decoder. We report all metrics on the validation set.
191
+
192
+ <table><tr><td>Method</td><td>P@5</td><td>P@20</td><td>P@100</td><td>Dev EM</td></tr><tr><td>(0) )meanj,k,h αo,j,k,h</td><td>64.7</td><td>76.4</td><td>84.3</td><td>46.8</td></tr><tr><td>(1) meank,h maxj Qo,j,k,h</td><td>61.2</td><td>72.5</td><td>81.0</td><td>46.0</td></tr><tr><td>(2) meani,j,k,h αi,j,k,h</td><td>63.5</td><td>75.3</td><td>83.1</td><td>45.8</td></tr><tr><td>(3)1 )mean7≤k≤12,j,h α0,j,k,h</td><td>64.1</td><td>75.7</td><td>83.8</td><td>46.4</td></tr><tr><td>(4) meanj,h maxk αo,j,k,h</td><td>63.9</td><td>75.5</td><td>83.7</td><td>46.5</td></tr><tr><td>(5) meanj,k maxh Qo,j,k,h</td><td>64.2</td><td>76.1</td><td>83.9</td><td>46.8</td></tr></table>
193
+
194
+ # 6 CONCLUSION
195
+
196
+ In this paper, we introduce a method to train an information retrieval module for downstream tasks, without using pairs of queries and documents as annotations. Our approach is inspired by knowledge distillation, where the retriever module corresponds to the student model and the reader module corresponds to the teacher model. In particular, we use the cross-attention scores, from a sequenceto-sequence reader, to obtain synthetic targets for the retriever. We compare different ways to aggregate the scores, as well as different training objectives to learn the retriever. We show that iteratively training the reader and the retriever leads to better performance, and obtain state-of-the-art performance on competitive question answering benchmarks. In the future, we would like to explore better pre-training strategies for the retriever module, as well as better scoring functions for the retriever.
197
+
198
+ # REFERENCES
199
+
200
+ Wei-Cheng Chang, Felix X Yu, Yin-Wen Chang, Yiming Yang, and Sanjiv Kumar. Pre-training tasks for embedding-based large-scale retrieval. arXiv preprint arXiv:2002.03932, 2020.
201
+
202
+ Danqi Chen, Adam Fisch, Jason Weston, and Antoine Bordes. Reading Wikipedia to answer opendomain questions. In Proc. ACL, 2017.
203
+
204
+ Scott Deerwester, Susan T Dumais, George W Furnas, Thomas K Landauer, and Richard Harshman. Indexing by latent semantic analysis. Journal of the American society for information science, 41 (6):391–407, 1990.
205
+
206
+ Mostafa Dehghani, Hamed Zamani, Aliaksei Severyn, Jaap Kamps, and W. Bruce Croft. Neural ranking models with weak supervision. In Proceedings of the 40th International ACM SIGIR Conference on Research and Development in Information Retrieval, SIGIR ’17, pp. 65–74, New York, NY, USA, 2017. Association for Computing Machinery. doi: 10.1145/3077136.3080832. URL https://doi.org/10.1145/3077136.3080832.
207
+
208
+ Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. BERT: Pre-training of deep bidirectional transformers for language understanding. In Proc. NAACL, 2019.
209
+
210
+ Daniel Gillick, Alessandro Presta, and Gaurav Singh Tomar. End-to-end retrieval in continuous space. arXiv preprint arXiv:1811.08008, 2018.
211
+
212
+ Kelvin Guu, Kenton Lee, Zora Tung, Panupong Pasupat, and Ming-Wei Chang. Realm: Retrievalaugmented language model pre-training. arXiv preprint arXiv:2002.08909, 2020.
213
+
214
+ Geoffrey Hinton, Oriol Vinyals, and Jeff Dean. Distilling the knowledge in a neural network, 2015.
215
+
216
+ Po-Sen Huang, Xiaodong He, Jianfeng Gao, Li Deng, Alex Acero, and Larry Heck. Learning deep structured semantic models for web search using clickthrough data. In Proceedings of the 22nd ACM international conference on Information & Knowledge Management, pp. 2333–2338, 2013.
217
+
218
+ Samuel Humeau, Kurt Shuster, Marie-Anne Lachaux, and Jason Weston. Poly-encoders: Transformer architectures and pre-training strategies for fast and accurate multi-sentence scoring. arXiv preprint arXiv:1905.01969, 2019.
219
+
220
+ Gautier Izacard and Edouard Grave. Leveraging passage retrieval with generative models for open domain question answering. arXiv preprint arXiv:2007.01282, 2020.
221
+
222
+ Jeff Johnson, Matthijs Douze, and Herve J ´ egou. Billion-scale similarity search with gpus. ´ IEEE Transactions on Big Data, 2019.
223
+
224
+ Karen Sparck Jones. A statistical interpretation of term specificity and its application in retrieval. Journal of documentation, 1972.
225
+
226
+ Mandar Joshi, Eunsol Choi, Daniel S. Weld, and Luke Zettlemoyer. Triviaqa: A large scale distantly supervised challenge dataset for reading comprehension. In Proc. ACL, 2017.
227
+
228
+ Vladimir Karpukhin, Barlas Oguz, Sewon Min, Ledell Wu, Sergey Edunov, Danqi Chen, and ˘ Wen-tau Yih. Dense passage retrieval for open-domain question answering. arXiv preprint arXiv:2004.04906, 2020.
229
+
230
+ Omar Khattab, Christopher Potts, and Matei Zaharia. Relevance-guided supervision for openqa with colbert, 2020.
231
+
232
+ Diederik P Kingma and Jimmy Ba. Adam: A method for stochastic optimization. arXiv preprint arXiv:1412.6980, 2014.
233
+
234
+ Toma´s Ko ˇ cisk ˇ y, Jonathan Schwarz, Phil Blunsom, Chris Dyer, Karl Moritz Hermann, G \` abor Melis, ´ and Edward Grefenstette. The NarrativeQA reading comprehension challenge. TACL, 2018.
235
+
236
+ Tom Kwiatkowski, Jennimaria Palomaki, Olivia Redfield, Michael Collins, Ankur Parikh, Chris Alberti, Danielle Epstein, Illia Polosukhin, Matthew Kelcey, Jacob Devlin, Kenton Lee, Kristina N. Toutanova, Llion Jones, Ming-Wei Chang, Andrew Dai, Jakob Uszkoreit, Quoc Le, and Slav Petrov. Natural Questions: a benchmark for question answering research. TACL, 2019.
237
+
238
+ Kenton Lee, Ming-Wei Chang, and Kristina Toutanova. Latent retrieval for weakly supervised open domain question answering. In Proc. ACL, 2019.
239
+
240
+ Mike Lewis, Yinhan Liu, Naman Goyal, Marjan Ghazvininejad, Abdelrahman Mohamed, Omer Levy, Ves Stoyanov, and Luke Zettlemoyer. BART: Denoising sequence-to-sequence pretraining for natural language generation, translation, and comprehension. arXiv preprint arXiv:1910.13461, 2019.
241
+
242
+ Mike Lewis, Marjan Ghazvininejad, Gargi Ghosh, Armen Aghajanyan, Sida Wang, and Luke Zettlemoyer. Pre-training via paraphrasing. arXiv preprint arXiv:2006.15020, 2020a.
243
+
244
+ Patrick Lewis, Ethan Perez, Aleksandara Piktus, Fabio Petroni, Vladimir Karpukhin, Naman Goyal, Heinrich Kuttler, Mike Lewis, Wen-tau Yih, Tim Rockt ¨ aschel, et al. Retrieval-augmented gener- ¨ ation for knowledge-intensive nlp tasks. arXiv preprint arXiv:2005.11401, 2020b.
245
+
246
+ Ilya Loshchilov and Frank Hutter. Decoupled weight decay regularization. In International Conference on Learning Representations, 2019.
247
+
248
+ Yi Luan, Jacob Eisenstein, Kristina Toutanova, and Michael Collins. Sparse, dense, and attentional representations for text retrieval. arXiv preprint arXiv:2005.00181, 2020.
249
+
250
+ Christopher D Manning, Hinrich Schutze, and Prabhakar Raghavan. ¨ Introduction to information retrieval. Cambridge university press, 2008.
251
+
252
+ Bhaskar Mitra, Nick Craswell, et al. An introduction to neural information retrieval. Foundations and Trends $\textsuperscript { \textregistered }$ in Information Retrieval, 13(1):1–126, 2018.
253
+
254
+ Rodrigo Nogueira and Kyunghyun Cho. Passage re-ranking with bert. arXiv preprint arXiv:1901.04085, 2019.
255
+
256
+ Hamid Palangi, Li Deng, Yelong Shen, Jianfeng Gao, Xiaodong He, Jianshu Chen, Xinying Song, and Rabab Ward. Deep sentence embedding using long short-term memory networks: Analysis and application to information retrieval. IEEE/ACM Transactions on Audio, Speech, and Language Processing, 24(4):694–707, 2016.
257
+
258
+ Colin Raffel, Noam Shazeer, Adam Roberts, Katherine Lee, Sharan Narang, Michael Matena, Yanqi Zhou, Wei Li, and Peter J Liu. Exploring the limits of transfer learning with a unified text-to-text transformer. arXiv preprint arXiv:1910.10683, 2019.
259
+
260
+ Pranav Rajpurkar, Jian Zhang, Konstantin Lopyrev, and Percy Liang. SQuAD: $1 0 0 { , } 0 0 0 { + }$ questions for machine comprehension of text. In Proc. EMNLP, 2016.
261
+
262
+ Stephen E Robertson, Steve Walker, Susan Jones, Micheline M Hancock-Beaulieu, Mike Gatford, et al. Okapi at TREC-3. NIST Special Publication Sp, 1995.
263
+
264
+ Yelong Shen, Xiaodong He, Jianfeng Gao, Li Deng, and Gregoire Mesnil. Learning semantic rep- ´ resentations using convolutional neural networks for web search. In Proceedings of the $2 3 r d$ international conference on world wide web, pp. 373–374, 2014.
265
+
266
+ James Thorne, Andreas Vlachos, Christos Christodoulopoulos, and Arpit Mittal. Fever: a large-scale dataset for fact extraction and verification. arXiv preprint arXiv:1803.05355, 2018.
267
+
268
+ Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Ł ukasz Kaiser, and Illia Polosukhin. Attention is all you need. In Advances in Neural Information Processing Systems 30, pp. 5998–6008. 2017.
269
+
270
+ Ellen M Voorhees et al. The TREC-8 question answering track report. In TREC, 1999.
271
+
272
+ Sohee Yang and Minjoon Seo. Is retriever merely an approximator of reader? arXiv preprint arXiv:2010.10999, 2020.
273
+
274
+ Wei Yang, Yuqing Xie, Aileen Lin, Xingyu Li, Luchen Tan, Kun Xiong, Ming Li, and Jimmy Lin. End-to-end open-domain question answering with BERTserini. In Proc. NAACL (Demonstrations), 2019.
275
+
276
+ Table 6: Hyperparameters for retriever and reader training.
277
+
278
+ <table><tr><td>Hyperparameter</td><td>Reader-base</td><td>Reader-large</td><td>Retriever</td></tr><tr><td>Number of parameters</td><td>220M</td><td>770M</td><td>110M</td></tr><tr><td>Number of heads</td><td>12</td><td>16</td><td>12</td></tr><tr><td>Number of layers</td><td>24</td><td>48</td><td>12</td></tr><tr><td>Hidden size</td><td>768</td><td>1024</td><td>768</td></tr><tr><td>Batch size</td><td>64</td><td>64</td><td>64</td></tr><tr><td>Dropout</td><td>0.1</td><td>0.1</td><td>0.1</td></tr><tr><td>Learning rate schedule</td><td>constant</td><td>linear</td><td>constant</td></tr><tr><td>Peak learning rate</td><td>0.0001</td><td>0.00005</td><td>0.00005</td></tr><tr><td>Gradient clipping</td><td>1.</td><td>1.</td><td>1.</td></tr></table>
279
+
280
+ # A EXPERIMENTAL DETAILS
281
+
282
+ # A.1 SETTING
283
+
284
+ For NaturalQuestions and TriviaQA we follow the standard open-domain question answering setting used in Lee et al. (2019); Karpukhin et al. (2020). In this setting the original development set is used as test set, and $10 \%$ of the training set is used for development purpose. Moreover, for NaturalQuestions, all questions with answers longer than five tokens are discarded.
285
+
286
+ For TriviaQA we use the unique human-generated answer to train the reader. In this dataset part of the answers are in uppercase. We normalize uppercase answers by converting the first letter in each word to uppercase and remaining characters to lowercase using the title Python string method.
287
+
288
+ For NarrativeQA, questions and answers in uppercase are converted to lowercase.
289
+
290
+ # A.2 TRAINING
291
+
292
+ For every datasets, both the reader and the retriever are fine-tuned with a dropout rate of $10 \%$ . All models at the exception of the large reader are trained using the ADAM algorithm (Kingma & Ba, 2014) with a constant learning rate of $1 0 ^ { - 4 }$ for the base reader and $5 \cdot 1 0 ^ { - 5 } $ for the retriever. The base reader is trained for 10k gradient steps with a batch size of 64. We train the large reader with the ADAMW algorithm (Loshchilov & Hutter, 2019) with a peak learning rate of $5 \cdot 1 0 ^ { - 5 }$ and a linear warmup for 600 gradient steps followed by a linear decrease of the learning rate for $1 4 . 4 \mathrm { k }$ gradient steps.
293
+
294
+ We perform model selection on the validation performance. The retriever is trained until its performance saturates with a batch size of 64. To monitor the performance of the retriever during training, we measure the similarity between the ranking obtained with the reader score, and the ranking of the retriever. We use different metrics for this: the number of inversions between the two rankings, the proportion of passages in the retriever top- $k$ that are also in the reader top- $k$ and the number of passages to obtain all top- $k$ passage of the reader.
295
+
296
+ During training and at test time, each text input of the encoder is restricted to be at most 250 token long. For NaturalQuestions and TriviaQA, we use wikipedia as a knowledge source, thus for each passage there is an associated article title. Each input is composed of the concatenation of a question, title and support passage with special tokens question:, title: and context: added before the question, the title and the text of each passage. In the case of NarrativeQA, the question and each passage are concatenated to form the different inputs.
297
+
298
+ # A.3 INFERENCE
299
+
300
+ At test time, for TriviaQA and NaturalQuestions we use greedy decoding, and Beam Search with 3 beams for NarrativeQA.
301
+
302
+ <table><tr><td></td><td colspan="3">NaturalQuestions</td><td colspan="3">TriviaQA</td></tr><tr><td>Iter.</td><td>P@20</td><td>P@100</td><td>Dev EM</td><td>P@20</td><td>P@100</td><td>Dev EM</td></tr><tr><td>0</td><td>77.1</td><td>84.3</td><td>46.4</td><td>78.2</td><td>84.7</td><td>65.0</td></tr><tr><td>1</td><td>80.3</td><td>86.7</td><td>47.8</td><td>81.4</td><td>86.4</td><td>67.1</td></tr><tr><td>2</td><td>82.4</td><td>87.9</td><td>48.2</td><td>83.5</td><td>87.4</td><td>68.1</td></tr></table>
303
+
304
+ Table 7: Iterative training starting with documents retrieved with DPR. Iteration 0 corresponds to the performance of the reader trained on the set of initial support documents. We report all metrics on the validation set. Contrary to results reported in Table 1, the reader model was not re-initialized between each iteration.
parse/train/NTEz-6wysdb/NTEz-6wysdb_content_list.json ADDED
@@ -0,0 +1,1603 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [
2
+ {
3
+ "type": "text",
4
+ "text": "DISTILLING KNOWLEDGE FROM READER T O RETRIEVER FOR QUESTION ANSWERING ",
5
+ "text_level": 1,
6
+ "bbox": [
7
+ 174,
8
+ 98,
9
+ 821,
10
+ 147
11
+ ],
12
+ "page_idx": 0
13
+ },
14
+ {
15
+ "type": "text",
16
+ "text": "Gautier Izacard1,2,3, Edouard Grave1 \n1Facebook AI Research, 2Ecole normale sup ´ erieure, PSL University, ´ 3Inria \n{gizacard|egrave}@fb.com ",
17
+ "bbox": [
18
+ 181,
19
+ 171,
20
+ 674,
21
+ 217
22
+ ],
23
+ "page_idx": 0
24
+ },
25
+ {
26
+ "type": "text",
27
+ "text": "ABSTRACT ",
28
+ "text_level": 1,
29
+ "bbox": [
30
+ 454,
31
+ 253,
32
+ 544,
33
+ 268
34
+ ],
35
+ "page_idx": 0
36
+ },
37
+ {
38
+ "type": "text",
39
+ "text": "The task of information retrieval is an important component of many natural language processing systems, such as open domain question answering. While traditional methods were based on hand-crafted features, continuous representations based on neural networks recently obtained competitive results. A challenge of using such methods is to obtain supervised data to train the retriever model, corresponding to pairs of query and support documents. In this paper, we propose a technique to learn retriever models for downstream tasks, inspired by knowledge distillation, and which does not require annotated pairs of query and documents. Our approach leverages attention scores of a reader model, used to solve the task based on retrieved documents, to obtain synthetic labels for the retriever. We evaluate our method on question answering, obtaining state-of-the-art results. ",
40
+ "bbox": [
41
+ 233,
42
+ 284,
43
+ 764,
44
+ 436
45
+ ],
46
+ "page_idx": 0
47
+ },
48
+ {
49
+ "type": "text",
50
+ "text": "1 INTRODUCTION ",
51
+ "text_level": 1,
52
+ "bbox": [
53
+ 176,
54
+ 462,
55
+ 336,
56
+ 478
57
+ ],
58
+ "page_idx": 0
59
+ },
60
+ {
61
+ "type": "text",
62
+ "text": "Information retrieval is an important component for many natural language processing tasks, such as question answering (Voorhees et al., 1999) or fact checking (Thorne et al., 2018). For example, many real world question answering systems start by retrieving a set of support documents from a large source of knowledge such as Wikipedia. Then, a finer-grained model processes these documents to extract the answer. Traditionally, information retrieval systems were based on hand-crafted sparse representations of text documents, such as TF-IDF or BM25 (Jones, 1972; Robertson et al., 1995). Recently, methods based on dense vectors and machine learning have shown promising results (Karpukhin et al., 2020; Khattab et al., 2020). Deep neural networks based on pre-training, such as BERT (Devlin et al., 2019), have been used to encode documents into fixed-size representations. These representations are then queried using approximate nearest neighbors (Johnson et al., 2019). These techniques have lead to improved performance on various question answering tasks. ",
63
+ "bbox": [
64
+ 174,
65
+ 492,
66
+ 825,
67
+ 646
68
+ ],
69
+ "page_idx": 0
70
+ },
71
+ {
72
+ "type": "text",
73
+ "text": "A challenge of applying machine learning to information retrieval is to obtain training data for the retriever. To train such models, one needs pairs of queries and the corresponding list of documents that contains the information corresponding to the queries. Unfortunately, hand-labeling data to that end is time consuming, and many datasets and applications lack such annotations. An alternative approach is to resort to heuristics, or weakly supervised learning, for example by considering that all documents containing the answer are positive examples. However, these approaches suffer from the following limitations. First, frequent answers or entities might lead to false positive examples. As an example, consider the question “where was Ada Lovelace born?”. The sentence “Ada Lovelace died in 1852 in London” would be considered as a positive example, because it contains the answer “London”. A second limitation is that for some tasks, such as fact checking or long form question answering, such heuristics might not be applicable directly. ",
74
+ "bbox": [
75
+ 174,
76
+ 652,
77
+ 825,
78
+ 805
79
+ ],
80
+ "page_idx": 0
81
+ },
82
+ {
83
+ "type": "text",
84
+ "text": "In this paper, we propose a procedure to learn retriever systems without strong supervision in the form of pairs of queries and documents. Following previous work (Chen et al., 2017), our approach uses two models: the first one retrieves documents from a large source of knowledge (the retriever), the second one processes the support documents to solve the task (the reader). Our method is inspired by knowledge distillation (Hinton et al., 2015), and uses the reader model to obtain synthetic labels to train the retriever model. More precisely, we use a sequence-to-sequence model as the reader, and use the attention activations over the input documents as synthetic labels to train the retriever. Said otherwise, we assume that attention activations are a good proxy for the relevance of documents. We then train the retriever to reproduce the ranking of documents corresponding to that metric. ",
85
+ "bbox": [
86
+ 174,
87
+ 813,
88
+ 823,
89
+ 924
90
+ ],
91
+ "page_idx": 0
92
+ },
93
+ {
94
+ "type": "text",
95
+ "text": "",
96
+ "bbox": [
97
+ 174,
98
+ 103,
99
+ 825,
100
+ 132
101
+ ],
102
+ "page_idx": 1
103
+ },
104
+ {
105
+ "type": "text",
106
+ "text": "We make the following contributions: ",
107
+ "bbox": [
108
+ 176,
109
+ 138,
110
+ 421,
111
+ 154
112
+ ],
113
+ "page_idx": 1
114
+ },
115
+ {
116
+ "type": "text",
117
+ "text": "• First, we show that attention scores from a sequence-to-sequence reader model are a good measure of document relevance (Sec. 3.2) ; \nSecond, inspired by knowledge distillation, we propose to iteratively train the retriever from these activations, and compare different loss functions (Sec. 3.4) ; \n• Finally, we evaluate our method on three question-answering benchmarks, obtaining stateof-the-art results (Sec. 4). ",
118
+ "bbox": [
119
+ 215,
120
+ 165,
121
+ 825,
122
+ 257
123
+ ],
124
+ "page_idx": 1
125
+ },
126
+ {
127
+ "type": "text",
128
+ "text": "Our code is available at: github.com/facebookresearch/FiD. ",
129
+ "bbox": [
130
+ 174,
131
+ 268,
132
+ 645,
133
+ 284
134
+ ],
135
+ "page_idx": 1
136
+ },
137
+ {
138
+ "type": "text",
139
+ "text": "2 RELATED WORK ",
140
+ "text_level": 1,
141
+ "bbox": [
142
+ 176,
143
+ 303,
144
+ 341,
145
+ 319
146
+ ],
147
+ "page_idx": 1
148
+ },
149
+ {
150
+ "type": "text",
151
+ "text": "We briefly review information retrieval based on machine learning. We refer the reader to Manning et al. (2008) and Mitra et al. (2018) for a more exhaustive introduction to the subject. ",
152
+ "bbox": [
153
+ 174,
154
+ 334,
155
+ 823,
156
+ 362
157
+ ],
158
+ "page_idx": 1
159
+ },
160
+ {
161
+ "type": "text",
162
+ "text": "Vector space models. In traditional information retrieval systems, documents and queries are represented as sparse vectors, each dimension corresponding to a different term. Different schemes have been considered to weigh the different term, the most well known being based on inverse document frequency, or term specificity (Jones, 1972). This technique was later extended, leading to the BM25 weighting scheme which is still widely used today (Robertson et al., 1995). A limitation of sparse representations is that the terms of the query need to match the terms of the returned documents. To overcome this, Deerwester et al. (1990) proposed to use latent semantic analysis for indexing, leading to low-dimension dense representations of documents. ",
163
+ "bbox": [
164
+ 174,
165
+ 377,
166
+ 825,
167
+ 488
168
+ ],
169
+ "page_idx": 1
170
+ },
171
+ {
172
+ "type": "text",
173
+ "text": "Neural information retrieval. Following the success of deep learning for other natural processing tasks, neural networks were applied to the task of information retrieval. Huang et al. (2013) proposed a deep bag-of-words model, where queries and documents were embedded independently, a technique known as bi-encoder. Documents were then ranked by using the cosine similarity with the query, and the model was trained on clickthrough data from a search engine. This technique was later extended by using convolutional neural networks (Shen et al., 2014) and recurrent neural networks (Palangi et al., 2016). A limitation of independently embedding documents and query is that it does not capture fine-grained interactions between the query and documents. This lead Nogueira & Cho (2019) and Yang et al. (2019) to use a BERT model to jointly embed documents and query, a technique known as cross-encoder. ",
174
+ "bbox": [
175
+ 174,
176
+ 503,
177
+ 825,
178
+ 642
179
+ ],
180
+ "page_idx": 1
181
+ },
182
+ {
183
+ "type": "text",
184
+ "text": "End-to-end retrieval. Most of the methods described in the previous paragraph were used to rerank a small number of documents, usually returned by a traditional IR systems. In the context of ad-hoc document retrieval, Gillick et al. (2018) showed that bi-encoder models could be competitive with traditional IR systems. For open domain question-answering, Karpukhin et al. (2020) introduced dense passage retrieval (DPR), which uses dense embeddings and nearest neighbors search. More precisely, question and passage embeddings are obtained using a BERT-based biencoder model, which is trained on a small dataset of question and passage pairs. Then, the full knowledge source (Wikipedia) is encoded using this model, and passages are queried by computing the $\\mathbf { k }$ -nearest neighbors of the embedding of the question. Jointly embedding the query and documents makes the application of cross-encoder models intractable to large database. To address this limitation, Humeau et al. (2019) introduced the poly-encoder architecture, in which each documents is represented by multiple vectors instead of one. Similarly, Khattab et al. (2020) proposed a scoring function where each term of the query and documents is represented by a single vector. To make the method tractable, their system retrieves documents with an approximate score, which are then re-ranked with the exact one. Finally, Luan et al. (2020) conducts a theoretical and empirical study of sparse, dense and cross-attention information retrieval systems. ",
185
+ "bbox": [
186
+ 174,
187
+ 659,
188
+ 825,
189
+ 878
190
+ ],
191
+ "page_idx": 1
192
+ },
193
+ {
194
+ "type": "text",
195
+ "text": "Unsupervised learning. Closest to our work, there is growing body of work trying to learn information retrieval systems from unsupervised data. Lee et al. (2019) introduced the inverse cloze task for pre-training retrievers, which can then be fine-tuned end-to-end on question-answering tasks. This pre-training scheme was later evaluated for ad-hoc document retrieval by Chang et al. (2020). Guu et al. (2020) proposed to augment language model pre-training with a retriever module, which is trained using the masked language modeling objective. Similarly, Lewis et al. (2020a) introduced a sequence-to-sequence model that is pre-trained by generating a target text, after retrieving a set of related texts. Lewis et al. (2020b) further train the retriever obtained in Karpukhin et al. (2020) by backpropagating to the retriever the error between the generated output and the gold answer. ",
196
+ "bbox": [
197
+ 174,
198
+ 895,
199
+ 821,
200
+ 922
201
+ ],
202
+ "page_idx": 1
203
+ },
204
+ {
205
+ "type": "text",
206
+ "text": "",
207
+ "bbox": [
208
+ 174,
209
+ 103,
210
+ 825,
211
+ 202
212
+ ],
213
+ "page_idx": 2
214
+ },
215
+ {
216
+ "type": "text",
217
+ "text": "Simultaneously to our work, Yang & Seo (2020) proposes to train a retriever with knowledge distillation. The main difference with our method is the nature of the synthetic labels that are used to train the retriever. Yang & Seo (2020) uses the DPR reader, which includes a classifier that predicts which passage contains the answer, and can be seen as a cross-encoder reranker. This technique thus performs the distillation of a cross-encoder retriever to a bi-encoder retriever. In contrast, our method uses the internal attention scores of the reader, which does not require additional supervision besides pairs of question and answer. ",
218
+ "bbox": [
219
+ 174,
220
+ 208,
221
+ 825,
222
+ 305
223
+ ],
224
+ "page_idx": 2
225
+ },
226
+ {
227
+ "type": "text",
228
+ "text": "3 METHODOLOGY ",
229
+ "text_level": 1,
230
+ "bbox": [
231
+ 176,
232
+ 333,
233
+ 339,
234
+ 349
235
+ ],
236
+ "page_idx": 2
237
+ },
238
+ {
239
+ "type": "text",
240
+ "text": "Our system is composed of two modules, the retriever and the reader, following the standard pipeline for open-domain question answering. Given an input question these modules are used in a two-step process to generate an answer. First the retriever selects support passages in a large knowledge source. Then these passages are processed by the reader, along with the question, to generate an answer. For the reader module we use the Fusion-in-Decoder model (Izacard & Grave, 2020), which achieves state-of-the-art performance when combined with BM25 or DPR (Karpukhin et al., 2020). It is based on a sequence-to-sequence architecture, and is initialized from pre-trained models such as T5 or BART (Raffel et al., 2019; Lewis et al., 2019). ",
241
+ "bbox": [
242
+ 174,
243
+ 369,
244
+ 825,
245
+ 481
246
+ ],
247
+ "page_idx": 2
248
+ },
249
+ {
250
+ "type": "text",
251
+ "text": "The focus of this work is to train the retriever without strong supervision or weakly supervised learning based on heuristics. For this we propose to train the retriever by learning to approximate the attention score of the reader. The training scheme outlined here can be seen as a student-teacher pipeline, where the teacher, the reader module, produces targets which are used to train a student network, the reader. By doing so, we hope to leverage the signal extracted from the question-answer pairs by the reader. Since the goal of the retriever is to retrieve the most relevant passages, by training the retriever to estimate the reader attention scores, we implicitly make the assumption that these scores are a good proxy for the usefulness of a passage to answer the question. ",
252
+ "bbox": [
253
+ 174,
254
+ 488,
255
+ 825,
256
+ 599
257
+ ],
258
+ "page_idx": 2
259
+ },
260
+ {
261
+ "type": "text",
262
+ "text": "In this section we will first describe the Fusion-in-Decoder architecture, before elaborating on the signal which is used to train the retriever, the design of the retriever, and how this module is trained. ",
263
+ "bbox": [
264
+ 174,
265
+ 606,
266
+ 821,
267
+ 635
268
+ ],
269
+ "page_idx": 2
270
+ },
271
+ {
272
+ "type": "text",
273
+ "text": "3.1 CROSS-ATTENTION MECHANISM ",
274
+ "text_level": 1,
275
+ "bbox": [
276
+ 176,
277
+ 659,
278
+ 442,
279
+ 672
280
+ ],
281
+ "page_idx": 2
282
+ },
283
+ {
284
+ "type": "text",
285
+ "text": "First, let us briefly review the Fusion-in-Decoder model (FiD, Izacard & Grave, 2020). The underlying architecture is a sequence-to-sequence model, composed of an encoder and a decoder. The encoder independently processes $n _ { p }$ different text inputs $\\left( s _ { k } \\right) _ { 1 \\leq k \\leq n _ { p } }$ . In the case of open-domain question answering based on Wikipedia, each input $s _ { k }$ is the concatenation of the question $q$ and a support passage, with special tokens question:, title: and context: added before the question, the title of the Wikipedia article and the text of each passage. The output representations of the encoder are then concatenated to form a global representation $\\mathbf { X }$ of dimension $\\bar { ( \\sum _ { k } \\ell _ { k } ) } \\times d .$ , where $\\ell _ { k }$ is the length of the $k$ -th segment and $d$ is the dimension of the embeddings and hidden representations of the model. Then, the decoder processes this representation as a regular autoregressive model, alternating self-attention, cross-attention and feed-forward modules. ",
286
+ "bbox": [
287
+ 174,
288
+ 688,
289
+ 825,
290
+ 827
291
+ ],
292
+ "page_idx": 2
293
+ },
294
+ {
295
+ "type": "text",
296
+ "text": "Only the cross-attention module explicitly takes as input the global output representation $\\mathbf { X }$ of the encoder. If $\\mathbf { H } \\in \\mathbb { R } ^ { d }$ denotes the output of the previous self-attention layer of the decoder, the crossattention operation consists in the following operations. First, queries $\\mathbf { Q }$ , keys $\\mathbf { K }$ and values $\\mathbf { V }$ are computed by applying linear transformations: ",
297
+ "bbox": [
298
+ 174,
299
+ 834,
300
+ 825,
301
+ 890
302
+ ],
303
+ "page_idx": 2
304
+ },
305
+ {
306
+ "type": "equation",
307
+ "img_path": "images/a2964445aec6ea0075aba56e8e1a5f99da193977fa1d04be9d3dd1e51f27499e.jpg",
308
+ "text": "$$\n\\mathbf { Q } = \\mathbf { W } _ { Q } \\mathbf { H } , \\quad \\mathbf { K } = \\mathbf { W } _ { K } \\mathbf { X } , \\quad \\mathbf { V } = \\mathbf { W } _ { V } \\mathbf { X } .\n$$",
309
+ "text_format": "latex",
310
+ "bbox": [
311
+ 348,
312
+ 904,
313
+ 648,
314
+ 921
315
+ ],
316
+ "page_idx": 2
317
+ },
318
+ {
319
+ "type": "text",
320
+ "text": "Then a similarity score between the query at position $i$ , $\\mathbf { Q } _ { i }$ , and the key at position $j , \\mathbf { K } _ { j }$ , is obtained by computing the dot-product between these two elements, and normalized over the dimension: ",
321
+ "bbox": [
322
+ 173,
323
+ 103,
324
+ 823,
325
+ 132
326
+ ],
327
+ "page_idx": 3
328
+ },
329
+ {
330
+ "type": "equation",
331
+ "img_path": "images/775e441b2259949dd579a4d9595c24e13bf3c4a43164f2419433a62a26131e05.jpg",
332
+ "text": "$$\n\\alpha _ { i , j } = { \\bf Q } _ { i } ^ { T } { \\bf K } _ { j } , \\qquad \\tilde { \\alpha } _ { i , j } = \\frac { \\exp ( \\alpha _ { i , j } ) } { \\sum _ { m } \\exp ( \\alpha _ { i , m } ) } .\n$$",
333
+ "text_format": "latex",
334
+ "bbox": [
335
+ 351,
336
+ 133,
337
+ 645,
338
+ 167
339
+ ],
340
+ "page_idx": 3
341
+ },
342
+ {
343
+ "type": "text",
344
+ "text": "A new representation is obtained as a sum of the values, weighted by the attention probabilities, before going through a final linear transformation $\\mathbf { W } _ { o }$ : ",
345
+ "bbox": [
346
+ 173,
347
+ 175,
348
+ 826,
349
+ 204
350
+ ],
351
+ "page_idx": 3
352
+ },
353
+ {
354
+ "type": "equation",
355
+ "img_path": "images/7b363808395c0cf34675d5e8406dcb29819b30c9f38314bdfeabe57259adbf23.jpg",
356
+ "text": "$$\n\\mathbf { O } _ { i } = \\mathbf { W } _ { O } \\sum _ { j } \\tilde { \\alpha } _ { i , j } \\mathbf { V } _ { i , j }\n$$",
357
+ "text_format": "latex",
358
+ "bbox": [
359
+ 418,
360
+ 205,
361
+ 578,
362
+ 239
363
+ ],
364
+ "page_idx": 3
365
+ },
366
+ {
367
+ "type": "text",
368
+ "text": "The operations described above are performed in parallel with different linear transformations in the case of multi-head attention. Finally a normalization layer is applied, and this pipeline is wrapped by a skip connection. See Vaswani et al. (2017) for more details on the structure of Transformers. ",
369
+ "bbox": [
370
+ 174,
371
+ 247,
372
+ 826,
373
+ 290
374
+ ],
375
+ "page_idx": 3
376
+ },
377
+ {
378
+ "type": "text",
379
+ "text": "3.2 CROSS-ATTENTION SCORE AS A RELEVANCE MEASURE FOR PASSAGE RETRIEVAL ",
380
+ "text_level": 1,
381
+ "bbox": [
382
+ 173,
383
+ 306,
384
+ 787,
385
+ 320
386
+ ],
387
+ "page_idx": 3
388
+ },
389
+ {
390
+ "type": "text",
391
+ "text": "In some sense, the attention scores $\\alpha _ { : , j }$ involving the $j$ -th key measures the importance of this key, and corresponding value, to compute the next representation. We hypothesize that it is good proxy to estimate the relevance of a passage — the more the tokens in a text segment are attended to, the more relevant the text segment is to answer the question. ",
392
+ "bbox": [
393
+ 174,
394
+ 332,
395
+ 825,
396
+ 388
397
+ ],
398
+ "page_idx": 3
399
+ },
400
+ {
401
+ "type": "text",
402
+ "text": "Given the reader model, an input question $q$ and a corresponding set of support passages $\\begin{array} { l l l } { { \\mathcal D } _ { q } } & { = } & { ( p _ { k } ) _ { 1 \\leq k \\leq n } } \\end{array}$ , we obtain relevance scores $( G _ { q , p _ { k } } ) _ { 1 \\leq k \\leq n }$ for each passage by aggregating attention scores. In particular, the score $G _ { q , p _ { k } }$ k is obtained by averaging the pre-attention scores $\\alpha _ { 0 , }$ : over all the tokens in the input $s _ { k }$ corresponding to the passage $p _ { k }$ , all the layers and all the heads of the decoder. Note that the FiD decoder jointly processes the passages, and thus the score $G _ { q , p _ { k } }$ depends on the other support passages. We consider other pooling operators, such as max, to aggregate attention scores over layers, heads and tokens and empirically compare them in Sec. 5.2. ",
403
+ "bbox": [
404
+ 173,
405
+ 395,
406
+ 825,
407
+ 493
408
+ ],
409
+ "page_idx": 3
410
+ },
411
+ {
412
+ "type": "text",
413
+ "text": "Before we proceed, let us consider the following simple experiment, which is a first indication that reader attention scores are indeed a strong relevance signal. Given a question and 100 passages retrieved with DPR, our goal is to select the 10 best passages. When using the top 10 passages from DPR instead of the top 100, the performance of our reader drops from $4 8 . 2 \\ \\mathrm { E M }$ to 42.9 EM. On the other hand, if we select the top 10 documents according to the attention scores, the performance only drops to $4 6 . 8 \\ : \\mathrm { E M }$ . ",
414
+ "bbox": [
415
+ 173,
416
+ 500,
417
+ 825,
418
+ 583
419
+ ],
420
+ "page_idx": 3
421
+ },
422
+ {
423
+ "type": "text",
424
+ "text": "3.3 DENSE BI-ENCODER FOR PASSAGE RETRIEVAL ",
425
+ "text_level": 1,
426
+ "bbox": [
427
+ 174,
428
+ 599,
429
+ 534,
430
+ 613
431
+ ],
432
+ "page_idx": 3
433
+ },
434
+ {
435
+ "type": "text",
436
+ "text": "Ideally, we would like to rank passages according to the reader cross-attention scores. In practice however, since the passages and the question need to be processed simultaneously by the reader module it is impractical to query a large knowledge source this way. Thus, we use a retriever model composed of an embedder function $E$ that maps any text passage to a $d$ -dimensional vector, such that the similarity score between a question $q$ and a passage $p$ is defined as $S _ { \\theta } ( q , p ) = E ( q ) ^ { T } E ( p )$ . This similarity metric enables us to index all passages in the knowledge source as a preprocessing step. Then at runtime, passages with the highest similarity score with the input question are retrieved, by using an efficient similarity search library such as FAISS (Johnson et al., 2019). ",
437
+ "bbox": [
438
+ 173,
439
+ 625,
440
+ 825,
441
+ 737
442
+ ],
443
+ "page_idx": 3
444
+ },
445
+ {
446
+ "type": "text",
447
+ "text": "For the embedder we use BERT and follow DPR by considering that the encodings $E ( q )$ and $E ( p )$ are obtained by extracting the representation of the initial [CLS] token. This leads to a representation of dimension $d = 7 6 8$ in the case of a base model. Differently from DPR, we use the same encoding function $E$ for the questions and passages by sharing parameters. ",
448
+ "bbox": [
449
+ 173,
450
+ 743,
451
+ 825,
452
+ 800
453
+ ],
454
+ "page_idx": 3
455
+ },
456
+ {
457
+ "type": "text",
458
+ "text": "3.4 DISTILLING THE CROSS-ATTENTION SCORE TO A BI-ENCODER",
459
+ "text_level": 1,
460
+ "bbox": [
461
+ 173,
462
+ 815,
463
+ 643,
464
+ 830
465
+ ],
466
+ "page_idx": 3
467
+ },
468
+ {
469
+ "type": "text",
470
+ "text": "In this section, we describe how to train the retriever model, based on the relevance scores obtained in Sec. 3.2. For the training objective of the retriever, we propose to minimize the KL-divergence between the output $S _ { \\theta } ( q , p )$ and the score $G _ { q , p }$ after normalization: ",
471
+ "bbox": [
472
+ 174,
473
+ 840,
474
+ 825,
475
+ 883
476
+ ],
477
+ "page_idx": 3
478
+ },
479
+ {
480
+ "type": "equation",
481
+ "img_path": "images/1da16106237baa8282942192b5a7951126b1347bbf2834e81b82609b204e3333.jpg",
482
+ "text": "$$\n\\mathcal { L } _ { \\mathrm { K L } } ( \\boldsymbol { \\theta } , \\boldsymbol { \\mathcal { Q } } ) = \\sum _ { \\boldsymbol { q } \\in \\mathcal { Q } , \\boldsymbol { p } \\in \\mathcal { D } _ { \\boldsymbol { q } } } \\tilde { G } _ { \\boldsymbol { q } , \\boldsymbol { p } } ( \\log \\tilde { G } _ { \\boldsymbol { q } , \\boldsymbol { p } } - \\log \\tilde { S } _ { \\boldsymbol { \\theta } } ( \\boldsymbol { q } , \\boldsymbol { p } ) ) ,\n$$",
483
+ "text_format": "latex",
484
+ "bbox": [
485
+ 320,
486
+ 886,
487
+ 676,
488
+ 921
489
+ ],
490
+ "page_idx": 3
491
+ },
492
+ {
493
+ "type": "text",
494
+ "text": "where ",
495
+ "bbox": [
496
+ 174,
497
+ 104,
498
+ 217,
499
+ 117
500
+ ],
501
+ "page_idx": 4
502
+ },
503
+ {
504
+ "type": "equation",
505
+ "img_path": "images/df3c9e24a4acad83d7335b31ad0331c1209e4a287440a606d41c34c11c8512f7.jpg",
506
+ "text": "$$\n\\tilde { G } _ { q , p } = \\frac { \\exp ( G _ { q , p } ) } { \\sum _ { p ^ { \\prime } \\in \\mathcal { D } _ { q } } \\exp ( G _ { q , p ^ { \\prime } } ) } , \\qquad \\tilde { S } _ { \\theta } ( q , p ) = \\frac { \\exp ( S _ { \\theta } ( q , p ) ) } { \\sum _ { p ^ { \\prime } \\in \\mathcal { D } _ { q } } \\exp ( S _ { \\theta } ( q , p ^ { \\prime } ) ) } .\n$$",
507
+ "text_format": "latex",
508
+ "bbox": [
509
+ 264,
510
+ 121,
511
+ 732,
512
+ 159
513
+ ],
514
+ "page_idx": 4
515
+ },
516
+ {
517
+ "type": "text",
518
+ "text": "In Sec. 5.1 we present results obtained when using alternatives to this training objective. We consider two other objectives which have been used in Dehghani et al. (2017), where BM25 is used as a teacher model to train a neural ranker. A first option consists in training the retriever with a regression approach by minimizing the mean squared error: ",
519
+ "bbox": [
520
+ 173,
521
+ 170,
522
+ 826,
523
+ 228
524
+ ],
525
+ "page_idx": 4
526
+ },
527
+ {
528
+ "type": "equation",
529
+ "img_path": "images/9ea5ae3937bb127ced1de3319528cba8f6432a043c7adf43f90ffa5b8b6f6c23.jpg",
530
+ "text": "$$\n\\mathcal { L } _ { \\mathrm { M S E } } ( \\theta , \\mathcal { Q } ) = \\sum _ { q \\in \\mathcal { Q } , p \\in \\mathcal { D } _ { q } } ( S _ { \\theta } ( q , p ) - G _ { q , p } ) ^ { 2 } .\n$$",
531
+ "text_format": "latex",
532
+ "bbox": [
533
+ 352,
534
+ 232,
535
+ 645,
536
+ 268
537
+ ],
538
+ "page_idx": 4
539
+ },
540
+ {
541
+ "type": "text",
542
+ "text": "The second option we consider is to use a max-margin loss that explicitly penalizes inversions in the ranking estimated by the retriever: ",
543
+ "bbox": [
544
+ 171,
545
+ 281,
546
+ 823,
547
+ 310
548
+ ],
549
+ "page_idx": 4
550
+ },
551
+ {
552
+ "type": "equation",
553
+ "img_path": "images/9c511332d3a289d1f7df588d655f6a6d849395e84e92f287d59586fa3a3dc13c.jpg",
554
+ "text": "$$\n\\mathcal { L } _ { \\mathrm { r a n k i n g } } ( \\theta , \\mathcal { Q } ) = \\sum _ { \\scriptstyle q \\in \\mathcal { Q } , p _ { 1 } , p _ { 2 } \\in \\mathcal { D } _ { q } } \\operatorname* { m a x } \\left( 0 , \\gamma - \\mathrm { s i g n } ( G _ { q , p _ { 1 } } - G _ { q , p _ { 2 } } ) ( S _ { \\theta } ( q , p _ { 1 } ) - S _ { \\theta } ( q , p _ { 2 } ) ) \\right) .\n$$",
555
+ "text_format": "latex",
556
+ "bbox": [
557
+ 204,
558
+ 315,
559
+ 792,
560
+ 352
561
+ ],
562
+ "page_idx": 4
563
+ },
564
+ {
565
+ "type": "text",
566
+ "text": "In words, if $p _ { 1 }$ is more relevant to answer the question $q$ than $p _ { 2 }$ , i.e. $G _ { q , p _ { 1 } } > G _ { q , p _ { 2 } }$ , the loss pushes the retriever score of $p _ { 1 }$ to be larger than the score of $p _ { 2 }$ by at least a margin of $\\gamma$ . ",
567
+ "bbox": [
568
+ 171,
569
+ 364,
570
+ 823,
571
+ 393
572
+ ],
573
+ "page_idx": 4
574
+ },
575
+ {
576
+ "type": "text",
577
+ "text": "3.5 ITERATIVE TRAINING ",
578
+ "text_level": 1,
579
+ "bbox": [
580
+ 176,
581
+ 410,
582
+ 362,
583
+ 424
584
+ ],
585
+ "page_idx": 4
586
+ },
587
+ {
588
+ "type": "text",
589
+ "text": "In this section, we explain how iterative training can be used with the student-teacher scheme described in the previous section, similarly to Khattab et al. (2020). This iterative procedure can be interpreted as using the current retriever to sample negative examples, in order to train a new retriever. When learning a retriever with discriminative training, negative samples play an important role, and various strategies have been considered in previous work. Karpukhin et al. (2020) compared random sampling with using the top- $\\mathbf { \\nabla } \\cdot \\mathbf { k }$ passages from BM25 which do not contain the answer and with using the positive passages from other queries. Consider that for each question, we have an initial set of support documents $\\mathcal { D } _ { q } ^ { 0 }$ . We propose to use an iterative pipeline where each iteration can be described as the following 4-step process: ",
590
+ "bbox": [
591
+ 173,
592
+ 435,
593
+ 826,
594
+ 561
595
+ ],
596
+ "page_idx": 4
597
+ },
598
+ {
599
+ "type": "text",
600
+ "text": "1. Train the reader $R$ using the set of support documents for each question $\\mathcal { D } _ { q } ^ { 0 }$ . \n2. Compute aggregated attention scores $( G _ { q , p } ) _ { q \\in \\mathcal { Q } , p \\in \\mathcal { D } _ { q } ^ { 0 } }$ with the reader $R$ . \n3. Train the retriever E using the scores (Gq,p)q∈Q,p∈D0 . \n4. Retrieve top-passages with the new trained retriever $E$ . ",
601
+ "bbox": [
602
+ 210,
603
+ 571,
604
+ 728,
605
+ 650
606
+ ],
607
+ "page_idx": 4
608
+ },
609
+ {
610
+ "type": "text",
611
+ "text": "This multi-step procedure can be repeated multiple times. A critical point of the training procedure is the initial set of documents corresponding to each question. In Sec. 4, we compare retrievers obtained by starting from documents obtained using BM25 or cosine similarity from a BERT model. In particular, we show that while the initial performance with BERT is low, the iterative procedure allows to greatly improve the performance of the model. ",
612
+ "bbox": [
613
+ 174,
614
+ 661,
615
+ 825,
616
+ 732
617
+ ],
618
+ "page_idx": 4
619
+ },
620
+ {
621
+ "type": "text",
622
+ "text": "4 EXPERIMENTS ",
623
+ "text_level": 1,
624
+ "bbox": [
625
+ 176,
626
+ 752,
627
+ 326,
628
+ 767
629
+ ],
630
+ "page_idx": 4
631
+ },
632
+ {
633
+ "type": "text",
634
+ "text": "In this section we evaluate the student-teacher training procedure from the previous section. We show that we obtain competitive performance without strong supervision for support documents. ",
635
+ "bbox": [
636
+ 174,
637
+ 782,
638
+ 823,
639
+ 811
640
+ ],
641
+ "page_idx": 4
642
+ },
643
+ {
644
+ "type": "text",
645
+ "text": "4.1 EXPERIMENTAL SETTING ",
646
+ "text_level": 1,
647
+ "bbox": [
648
+ 174,
649
+ 828,
650
+ 392,
651
+ 843
652
+ ],
653
+ "page_idx": 4
654
+ },
655
+ {
656
+ "type": "text",
657
+ "text": "Datasets. We perform experiments on TriviaQA (Joshi et al., 2017) and NaturalQuestions (Kwiatkowski et al., 2019), two standard benchmarks for open-domain question answering. TriviaQA is made of questions from trivia and quiz league websites, and does not contain gold support documents. NaturalQuestions contains questions corresponding to web search queries, and gold support documents from Wikipedia. Following the setting from Lee et al. (2019); Karpukhin et al. (2020), we use the original evaluation set as test set, and keep $10 \\%$ of the training data for validation. We use the Wikipedia dump from Dec. 20, 2018 for support documents, splitting articles into non-overlapping passages of 100 tokens, and applying the same preprocessing as Chen et al. (2017). ",
658
+ "bbox": [
659
+ 174,
660
+ 853,
661
+ 823,
662
+ 924
663
+ ],
664
+ "page_idx": 4
665
+ },
666
+ {
667
+ "type": "table",
668
+ "img_path": "images/c317dae74315108e6dde590bb3e6a6544c1558f89c217213ab0af940e6d2c0f7.jpg",
669
+ "table_caption": [
670
+ "Table 1: Iterative training starting with documents retrieved with BERT and BM25. Iteration 0 corresponds to the performance of the reader trained on the set of initial support documents. We report all metrics on the validation set. "
671
+ ],
672
+ "table_footnote": [],
673
+ "table_body": "<table><tr><td></td><td colspan=\"5\">BERT</td><td colspan=\"2\">BM25</td></tr><tr><td></td><td>Iter.</td><td>P@20</td><td>P@100</td><td>Dev EM</td><td>P@20</td><td>P@100</td><td>Dev EM</td></tr><tr><td rowspan=\"4\">NaturalQuestions</td><td>0</td><td>4.8</td><td>12.0</td><td>9.8</td><td>59.3</td><td>74.0</td><td>41.2</td></tr><tr><td>1</td><td>32.2</td><td>45.8</td><td>16.9</td><td>76.4</td><td>84.3</td><td>46.8</td></tr><tr><td>2</td><td>51.1</td><td>62.6</td><td>28.6</td><td>80.4</td><td>86.7</td><td>47.9</td></tr><tr><td>3</td><td>67.8</td><td>76.8</td><td>39.3</td><td>80.0</td><td>86.3</td><td>46.2</td></tr><tr><td rowspan=\"5\">TriviaQA</td><td>0</td><td>4.6</td><td>12.0</td><td>9.7</td><td>75.0</td><td>82.3</td><td>65.3</td></tr><tr><td>1</td><td>37.1</td><td>59.4</td><td>19.6</td><td>79.0</td><td>85.5</td><td>66.7</td></tr><tr><td>2</td><td>60.8</td><td>73.4</td><td>43.3</td><td>82.1</td><td>86.5</td><td>67.5</td></tr><tr><td>3</td><td>72.0</td><td>83.2</td><td>52.0</td><td>81.6</td><td>86.6</td><td>67.7</td></tr><tr><td>4</td><td>76.4</td><td>84.6</td><td>62.3</td><td>1</td><td>1</td><td>1</td></tr></table>",
674
+ "bbox": [
675
+ 184,
676
+ 101,
677
+ 813,
678
+ 275
679
+ ],
680
+ "page_idx": 5
681
+ },
682
+ {
683
+ "type": "text",
684
+ "text": "",
685
+ "bbox": [
686
+ 174,
687
+ 354,
688
+ 825,
689
+ 410
690
+ ],
691
+ "page_idx": 5
692
+ },
693
+ {
694
+ "type": "text",
695
+ "text": "We also evaluate on NarrativeQuestions (Kocisk ˇ y et al., 2018), using a publicly available prepro-\\` cessed version.1 This is a reading comprehension dataset built on a corpus of books and movie scripts. For each story, questions are generated by human annotators based on a summary of the given document. We consider the full story setting, where the task is to answer questions given the entire story and not the summary used to generate question-answer pairs. Here the knowledge source is not the same for all questions: given a question the retrieval operation is performed on all passages of the associated story. These passages are obtained by dividing the story in chunks of 100 words. These stories are long documents, with an average of 60k words. While part of the documents could be processed entirely by the Fusion-in-Decoder module, it is interesting to limit the number of support passages to reduce the computational cost of the reading step. ",
696
+ "bbox": [
697
+ 174,
698
+ 417,
699
+ 825,
700
+ 556
701
+ ],
702
+ "page_idx": 5
703
+ },
704
+ {
705
+ "type": "text",
706
+ "text": "While answers in TriviaQA and NaturalQuestions are short, NarrativeQA answers are about five words long on average, with medium length answers such as ”He dismantles it and attaches it to his mother’s jeep” which answers the question ”What does Mark do with his radio station?”. Notably a significant number of answers do not correspond to spans in the story. It is thus not straightforward to train the retriever with heuristics using question-answer pairs. In our case we use the same pipeline as for TriviaQA and NaturalQuestions, demonstrating the flexibility of our approach. ",
707
+ "bbox": [
708
+ 174,
709
+ 564,
710
+ 825,
711
+ 647
712
+ ],
713
+ "page_idx": 5
714
+ },
715
+ {
716
+ "type": "text",
717
+ "text": "Evaluation. The model performance is assessed in two ways. First, following previous work such as DPR and ColbertQA, we report the top- $k$ retrieval accuracy $( \\mathrm { P } @ \\mathrm { k } )$ , which is the percentage of questions for which at least one passage of the top- $k$ retrieved passages contains the gold answer. It is unclear how well this metric evaluates the retriever performance, since the answer can be contained in a passage without being related to the question. This is notably true for common words or entities. ",
718
+ "bbox": [
719
+ 174,
720
+ 664,
721
+ 825,
722
+ 733
723
+ ],
724
+ "page_idx": 5
725
+ },
726
+ {
727
+ "type": "text",
728
+ "text": "We also report the final end-to-end performance of the question answering system composed of the retriever and reader modules. This is the metric we are fundamentally interested in. For TriviaQA and NaturalQuestions, predicted answers are evaluated with the standard exact match metric (EM), as introduced by Rajpurkar et al. (2016). For NarrativeQA we report the metrics proposed in the original paper: ROUGE-L, BLEU-1, BLEU-4 and METEOR. ",
729
+ "bbox": [
730
+ 174,
731
+ 741,
732
+ 825,
733
+ 809
734
+ ],
735
+ "page_idx": 5
736
+ },
737
+ {
738
+ "type": "text",
739
+ "text": "4.2 TECHNICAL DETAILS ",
740
+ "text_level": 1,
741
+ "bbox": [
742
+ 174,
743
+ 828,
744
+ 361,
745
+ 842
746
+ ],
747
+ "page_idx": 5
748
+ },
749
+ {
750
+ "type": "text",
751
+ "text": "Initialization. Similarly to DPR, we initialize the retriever with the BERT base model, pretrained with uncased text. The Fusion-in-Decoder reader is initialized with the T5 base model. A critical component of the iterative training procedure is the initialization of the support passages $\\mathcal { D } _ { q } ^ { 0 }$ associated with each question $q$ . For this we consider different options. The first one is to use passages retrieved using BM25. We use the implementation from Apache Lucene2 with default parameters, and tokenize questions and passages with $\\operatorname { S p a C y } ^ { 3 }$ . We also use passages obtained with BERT as a retriever without fine-tuning, this leads to poor initial performance. Finally in Table 2 we show that initializing $\\mathcal { D } _ { q } ^ { 0 }$ with passages obtained with DPR (Karpukhin et al., 2020) outperforms the two previous initializations. We train all retrievers using 100 passages. For the reader, we use 100 passages for NaturalQuestions and TriviaQA and 20 passages for NarrativeQA. ",
752
+ "bbox": [
753
+ 176,
754
+ 854,
755
+ 823,
756
+ 897
757
+ ],
758
+ "page_idx": 5
759
+ },
760
+ {
761
+ "type": "table",
762
+ "img_path": "images/cc46aa76024041aed4cd0b6bd9f7b2752f88dabc2dee90a7f69c13874c6c1e17.jpg",
763
+ "table_caption": [
764
+ "Table 2: Comparison to state-of-the-art models on NaturalQuestions and TriviaQA. "
765
+ ],
766
+ "table_footnote": [],
767
+ "table_body": "<table><tr><td>Model</td><td colspan=\"2\">NQ</td><td colspan=\"2\">TriviaQA</td></tr><tr><td></td><td>dev.</td><td>test</td><td>dev.</td><td>test</td></tr><tr><td>DPR (Karpukhin et al., 2020)</td><td>1</td><td>41.5</td><td>1</td><td>57.9</td></tr><tr><td>RAG (Lewis et al., 2020b)</td><td>=</td><td>44.5</td><td>1</td><td>56.1</td></tr><tr><td>ColBERT-QA (Khattab et al., 2020)</td><td>1</td><td>48.2</td><td>1</td><td>63.2</td></tr><tr><td>Fusion-in-Decoder (T5 base) (Izacard &amp; Grave,2020)</td><td></td><td>48.2</td><td>=</td><td>65.0</td></tr><tr><td>Fusion-in-Decoder (T5 large) (Izacard &amp; Grave,2020)</td><td>1</td><td>51.4</td><td>1</td><td>67.6</td></tr><tr><td>Ours (starting from BERT,T5 base)</td><td>39.3</td><td>40.0</td><td>62.5</td><td>62.7</td></tr><tr><td>Ours (starting from BM25, T5 base)</td><td>47.9</td><td>48.9</td><td>67.7</td><td>67.7</td></tr><tr><td>Ours (starting from DPR, T5 base)</td><td>48.0</td><td>49.6</td><td>68.6</td><td>68.8</td></tr><tr><td>Ours (starting from DPR, T5 large)</td><td>51.9</td><td>53.7</td><td>71.9</td><td>72.1</td></tr></table>",
768
+ "bbox": [
769
+ 214,
770
+ 101,
771
+ 785,
772
+ 276
773
+ ],
774
+ "page_idx": 6
775
+ },
776
+ {
777
+ "type": "text",
778
+ "text": "",
779
+ "bbox": [
780
+ 174,
781
+ 327,
782
+ 825,
783
+ 425
784
+ ],
785
+ "page_idx": 6
786
+ },
787
+ {
788
+ "type": "text",
789
+ "text": "Iterative training. We apply the iterative training procedure on each dataset independently. Both the reader and the retriever are fine-tuned using the ADAM algorithm (Kingma & Ba, 2014), with a batch of size 64. The reader is trained for $1 0 \\mathrm { k }$ gradient steps with a constant learning rate of $1 0 ^ { - 4 }$ , and the best model is selected based on the validation performance. The retriever is trained with a constant learning rate of $5 \\cdot 1 0 ^ { - 5 }$ until the performance saturates. To monitor the performance of the retriever during training, we measure the similarity between the reader and the retriever rankings. At each new training iteration the reader is reinitialized from T5 base, while we pursue the training of the retriever. We found that restarting from T5 base is important for the first iterations when starting with BERT documents. We have not tried to reinitialize the retriever between each iteration. More details on the hyperparameters and the training procedure are reported in Appendix A.2. ",
790
+ "bbox": [
791
+ 174,
792
+ 443,
793
+ 825,
794
+ 582
795
+ ],
796
+ "page_idx": 6
797
+ },
798
+ {
799
+ "type": "text",
800
+ "text": "4.3 RESULTS ",
801
+ "text_level": 1,
802
+ "bbox": [
803
+ 174,
804
+ 599,
805
+ 277,
806
+ 613
807
+ ],
808
+ "page_idx": 6
809
+ },
810
+ {
811
+ "type": "text",
812
+ "text": "In Table 1, we report the performance of our approach for different number of self-training iterations. Generally, we observe that the accuracy of our system increases with the number of iterations, obtaining strong performance after a few iterations. Interestingly, while the initial performance with documents retrieved with BERT is very poor, our method still reach competitive scores on TriviaQA, and to a lesser extent, NaturalQuestions. However, a second observation is that the quality of the initial document sets plays an important role on the performance of the end system. Indeed, we observe that starting the procedure from BM25 documents, which are higher quality as indicated by the performance of the system at iteration 0, leads to stronger results than using BERT documents. An interesting research question would be to explore pre-training of the initial BERT model for retrieval, for example by using the inverse cloze task. ",
813
+ "bbox": [
814
+ 174,
815
+ 626,
816
+ 825,
817
+ 765
818
+ ],
819
+ "page_idx": 6
820
+ },
821
+ {
822
+ "type": "text",
823
+ "text": "In Table 2, we report the performance of our approach, as well as existing state-of-the-art systems on TriviaQA and NaturalQuestions. In addition to initializing our method with documents retrieved with BM25 and BERT, we also train a system by starting from DPR documents. First, we observe that our method improve the performance over the state-of-the-art, even when starting from BM25 documents. This validates our assumption that it is possible to obtain strong retrievers without the need of supervision for the documents. Second, when starting from DPR passages, our method leads to a $+ 4 . 5$ EM improvement on TriviaQA and $+ 2 . 3$ EM improvement on NaturalQuestions when the final evaluation is carried out with a large reader. ",
824
+ "bbox": [
825
+ 174,
826
+ 772,
827
+ 825,
828
+ 883
829
+ ],
830
+ "page_idx": 6
831
+ },
832
+ {
833
+ "type": "table",
834
+ "img_path": "images/3b0f82f16f91d00f55bcb6c7ef09377df742bdd062c3d3c6d69a0c7b151a8c01.jpg",
835
+ "table_caption": [
836
+ "Table 3: Performance on NarrativeQA. "
837
+ ],
838
+ "table_footnote": [],
839
+ "table_body": "<table><tr><td>Method</td><td>Iter.</td><td colspan=\"2\">Rouge-L</td><td colspan=\"2\">Bleu-1</td><td colspan=\"2\">Bleu-4</td><td colspan=\"2\">Meteor</td></tr><tr><td></td><td></td><td>dev.</td><td>test</td><td>dev.</td><td>test</td><td>dev.</td><td>test</td><td>dev.</td><td>test</td></tr><tr><td>Best from Kocisky et al. (2018)</td><td>1</td><td>14.5</td><td>14.0</td><td>20.0</td><td>19.1</td><td>2.23</td><td>2.1</td><td>4.6</td><td>4.4</td></tr><tr><td>DPR + FiD</td><td>-</td><td>29.7</td><td>30.8</td><td>33.0</td><td>34.0</td><td>6.7</td><td>6.9</td><td>10.3</td><td>10.8</td></tr><tr><td>Ours starting from BM25</td><td>0</td><td>29.9</td><td>30.3</td><td>34.6</td><td>33.7</td><td>7.1</td><td>6.5</td><td>10.5</td><td>10.4</td></tr><tr><td>Ours starting from BM25</td><td>1</td><td>31.6</td><td>32.0</td><td>34.9</td><td>35.3</td><td>7.6</td><td>7.5</td><td>11.0</td><td>11.1</td></tr></table>",
840
+ "bbox": [
841
+ 173,
842
+ 101,
843
+ 825,
844
+ 207
845
+ ],
846
+ "page_idx": 7
847
+ },
848
+ {
849
+ "type": "text",
850
+ "text": "In Table 3, we report the performance of our method on the NarrativeQA dataset. We use the setting where the knowledge source corresponds to the whole document, and in particular, we do not use the summary. We compare our results to the best ones reported in the original paper for this setting. Similar to results obtained on NaturalQuestions and TriviaQA, we observe that training the retriever by using the attention scores of the reader leads to improvements, compared to the BM25 baseline. ",
851
+ "bbox": [
852
+ 174,
853
+ 256,
854
+ 825,
855
+ 327
856
+ ],
857
+ "page_idx": 7
858
+ },
859
+ {
860
+ "type": "text",
861
+ "text": "5 ABLATIONS ",
862
+ "text_level": 1,
863
+ "bbox": [
864
+ 174,
865
+ 347,
866
+ 303,
867
+ 363
868
+ ],
869
+ "page_idx": 7
870
+ },
871
+ {
872
+ "type": "text",
873
+ "text": "In this section, we investigate design choices regarding two key elements of our approach: the training objective and the aggregation of cross-attention scores. For all experiments, we consider a simplified experimental setting: a single training iteration is performed on NaturalQuestions, starting from BM25 passages. ",
874
+ "bbox": [
875
+ 174,
876
+ 378,
877
+ 825,
878
+ 434
879
+ ],
880
+ "page_idx": 7
881
+ },
882
+ {
883
+ "type": "text",
884
+ "text": "5.1 TRAINING OBJECTIVES ",
885
+ "text_level": 1,
886
+ "bbox": [
887
+ 174,
888
+ 452,
889
+ 375,
890
+ 465
891
+ ],
892
+ "page_idx": 7
893
+ },
894
+ {
895
+ "type": "text",
896
+ "text": "In Table 4 we report the performance of our model trained with the different training objectives described in Sec. 3.3. We observe that using the KL-divergence between the aggregated scores of the reader and the scores of the retriever outperforms the other objective functions. ",
897
+ "bbox": [
898
+ 174,
899
+ 477,
900
+ 823,
901
+ 520
902
+ ],
903
+ "page_idx": 7
904
+ },
905
+ {
906
+ "type": "table",
907
+ "img_path": "images/1c6e70afa7c364d90a052ec0b6fbc410a08f44ed58a7ec89ac695076353af938.jpg",
908
+ "table_caption": [],
909
+ "table_footnote": [
910
+ "Table 4: Comparison of training objectives on NaturalQuestions after one iteration. We report all the metrics on the validation set. "
911
+ ],
912
+ "table_body": "<table><tr><td>Method</td><td>P@5</td><td>P@20</td><td>P@100</td><td>Dev EM</td></tr><tr><td>Mean Squared Error</td><td>46.5</td><td>61.2</td><td>73.9</td><td>40.6</td></tr><tr><td>Max-margin loss,γ = 1</td><td>60.3</td><td>73.6</td><td>82.7</td><td>45.4</td></tr><tr><td>Max-margin loss, = 0.2</td><td>60.3</td><td>73.5</td><td>82.6</td><td>45.8</td></tr><tr><td>Max-margin loss, γ = 0.1</td><td>60.2</td><td>73.5</td><td>82.6</td><td>45.1</td></tr><tr><td>KL-divergence</td><td>64.7</td><td>76.4</td><td>84.3</td><td>46.8</td></tr></table>",
913
+ "bbox": [
914
+ 272,
915
+ 532,
916
+ 723,
917
+ 632
918
+ ],
919
+ "page_idx": 7
920
+ },
921
+ {
922
+ "type": "text",
923
+ "text": "5.2 HOW TO AGGREGATE CROSS-ATTENTION SCORES? ",
924
+ "text_level": 1,
925
+ "bbox": [
926
+ 173,
927
+ 693,
928
+ 563,
929
+ 707
930
+ ],
931
+ "page_idx": 7
932
+ },
933
+ {
934
+ "type": "text",
935
+ "text": "In Section 4 the cross-attention scores $\\alpha$ are aggregated in a specific way, in order to obtain a single scalar used to train the retriever. Formally let us denote by $\\alpha _ { i , j , k , h }$ the cross-attention scores between token $i$ of the output and token $j$ of the input, for the $k$ -th layer and $h$ -th head. Then, the scores $G _ { q , p }$ for $p \\in \\mathcal { D } _ { q }$ used in Section 4 are computed as follows: ",
936
+ "bbox": [
937
+ 173,
938
+ 718,
939
+ 825,
940
+ 773
941
+ ],
942
+ "page_idx": 7
943
+ },
944
+ {
945
+ "type": "equation",
946
+ "img_path": "images/9150c03b5253bb206b947309a57930336922b8da945dca2473f8c88aae8f4774.jpg",
947
+ "text": "$$\nG _ { q , p } = \\operatorname* { m e a n } _ { j , k , h } \\alpha _ { 0 , j , k , h } ,\n$$",
948
+ "text_format": "latex",
949
+ "bbox": [
950
+ 423,
951
+ 781,
952
+ 573,
953
+ 806
954
+ ],
955
+ "page_idx": 7
956
+ },
957
+ {
958
+ "type": "text",
959
+ "text": "where $j$ describes the input tokens corresponding to $p$ . In Table 5 we explore alternatives to this choice by considering different aggregation schemes. In particular, we consider (1) taking the max over the input tokens corresponding to passage $p$ instead of the average, (2) taking the average over the output tokens instead of taking the score of the first token, (3) taking the mean over the last six layers instead of all the layers, (4) taking the max over the layers instead of the average, (5) taking the max over the heads instead of the average. We observe that the performance of our approach is relatively stable to the choice of aggregation, and that the best result is obtained by averaging, except over the output tokens where it is best to only consider the first token. ",
960
+ "bbox": [
961
+ 173,
962
+ 811,
963
+ 825,
964
+ 924
965
+ ],
966
+ "page_idx": 7
967
+ },
968
+ {
969
+ "type": "table",
970
+ "img_path": "images/a8bfcd0537fd2aa084a7d4a47754cc70bbb5e4f3e35cd84cec06ca2a5b8f4cc2.jpg",
971
+ "table_caption": [
972
+ "Table 5: Comparison of attention aggregation schemes on NaturalQuestions after one iteration. The index $i$ corresponds to output tokens, $j$ corresponds to input tokens of a given passage, $h$ to heads and $k$ to layers of the decoder. We report all metrics on the validation set. "
973
+ ],
974
+ "table_footnote": [],
975
+ "table_body": "<table><tr><td>Method</td><td>P@5</td><td>P@20</td><td>P@100</td><td>Dev EM</td></tr><tr><td>(0) )meanj,k,h αo,j,k,h</td><td>64.7</td><td>76.4</td><td>84.3</td><td>46.8</td></tr><tr><td>(1) meank,h maxj Qo,j,k,h</td><td>61.2</td><td>72.5</td><td>81.0</td><td>46.0</td></tr><tr><td>(2) meani,j,k,h αi,j,k,h</td><td>63.5</td><td>75.3</td><td>83.1</td><td>45.8</td></tr><tr><td>(3)1 )mean7≤k≤12,j,h α0,j,k,h</td><td>64.1</td><td>75.7</td><td>83.8</td><td>46.4</td></tr><tr><td>(4) meanj,h maxk αo,j,k,h</td><td>63.9</td><td>75.5</td><td>83.7</td><td>46.5</td></tr><tr><td>(5) meanj,k maxh Qo,j,k,h</td><td>64.2</td><td>76.1</td><td>83.9</td><td>46.8</td></tr></table>",
976
+ "bbox": [
977
+ 267,
978
+ 101,
979
+ 728,
980
+ 214
981
+ ],
982
+ "page_idx": 8
983
+ },
984
+ {
985
+ "type": "text",
986
+ "text": "6 CONCLUSION ",
987
+ "text_level": 1,
988
+ "bbox": [
989
+ 174,
990
+ 290,
991
+ 318,
992
+ 306
993
+ ],
994
+ "page_idx": 8
995
+ },
996
+ {
997
+ "type": "text",
998
+ "text": "In this paper, we introduce a method to train an information retrieval module for downstream tasks, without using pairs of queries and documents as annotations. Our approach is inspired by knowledge distillation, where the retriever module corresponds to the student model and the reader module corresponds to the teacher model. In particular, we use the cross-attention scores, from a sequenceto-sequence reader, to obtain synthetic targets for the retriever. We compare different ways to aggregate the scores, as well as different training objectives to learn the retriever. We show that iteratively training the reader and the retriever leads to better performance, and obtain state-of-the-art performance on competitive question answering benchmarks. In the future, we would like to explore better pre-training strategies for the retriever module, as well as better scoring functions for the retriever. ",
999
+ "bbox": [
1000
+ 173,
1001
+ 320,
1002
+ 825,
1003
+ 446
1004
+ ],
1005
+ "page_idx": 8
1006
+ },
1007
+ {
1008
+ "type": "text",
1009
+ "text": "REFERENCES ",
1010
+ "text_level": 1,
1011
+ "bbox": [
1012
+ 174,
1013
+ 467,
1014
+ 285,
1015
+ 482
1016
+ ],
1017
+ "page_idx": 8
1018
+ },
1019
+ {
1020
+ "type": "text",
1021
+ "text": "Wei-Cheng Chang, Felix X Yu, Yin-Wen Chang, Yiming Yang, and Sanjiv Kumar. Pre-training tasks for embedding-based large-scale retrieval. arXiv preprint arXiv:2002.03932, 2020. ",
1022
+ "bbox": [
1023
+ 173,
1024
+ 491,
1025
+ 823,
1026
+ 518
1027
+ ],
1028
+ "page_idx": 8
1029
+ },
1030
+ {
1031
+ "type": "text",
1032
+ "text": "Danqi Chen, Adam Fisch, Jason Weston, and Antoine Bordes. Reading Wikipedia to answer opendomain questions. In Proc. ACL, 2017. ",
1033
+ "bbox": [
1034
+ 173,
1035
+ 527,
1036
+ 821,
1037
+ 556
1038
+ ],
1039
+ "page_idx": 8
1040
+ },
1041
+ {
1042
+ "type": "text",
1043
+ "text": "Scott Deerwester, Susan T Dumais, George W Furnas, Thomas K Landauer, and Richard Harshman. Indexing by latent semantic analysis. Journal of the American society for information science, 41 (6):391–407, 1990. ",
1044
+ "bbox": [
1045
+ 176,
1046
+ 564,
1047
+ 821,
1048
+ 607
1049
+ ],
1050
+ "page_idx": 8
1051
+ },
1052
+ {
1053
+ "type": "text",
1054
+ "text": "Mostafa Dehghani, Hamed Zamani, Aliaksei Severyn, Jaap Kamps, and W. Bruce Croft. Neural ranking models with weak supervision. In Proceedings of the 40th International ACM SIGIR Conference on Research and Development in Information Retrieval, SIGIR ’17, pp. 65–74, New York, NY, USA, 2017. Association for Computing Machinery. doi: 10.1145/3077136.3080832. URL https://doi.org/10.1145/3077136.3080832. ",
1055
+ "bbox": [
1056
+ 173,
1057
+ 616,
1058
+ 825,
1059
+ 686
1060
+ ],
1061
+ "page_idx": 8
1062
+ },
1063
+ {
1064
+ "type": "text",
1065
+ "text": "Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. BERT: Pre-training of deep bidirectional transformers for language understanding. In Proc. NAACL, 2019. ",
1066
+ "bbox": [
1067
+ 173,
1068
+ 694,
1069
+ 820,
1070
+ 724
1071
+ ],
1072
+ "page_idx": 8
1073
+ },
1074
+ {
1075
+ "type": "text",
1076
+ "text": "Daniel Gillick, Alessandro Presta, and Gaurav Singh Tomar. End-to-end retrieval in continuous space. arXiv preprint arXiv:1811.08008, 2018. ",
1077
+ "bbox": [
1078
+ 174,
1079
+ 732,
1080
+ 820,
1081
+ 761
1082
+ ],
1083
+ "page_idx": 8
1084
+ },
1085
+ {
1086
+ "type": "text",
1087
+ "text": "Kelvin Guu, Kenton Lee, Zora Tung, Panupong Pasupat, and Ming-Wei Chang. Realm: Retrievalaugmented language model pre-training. arXiv preprint arXiv:2002.08909, 2020. ",
1088
+ "bbox": [
1089
+ 174,
1090
+ 768,
1091
+ 818,
1092
+ 799
1093
+ ],
1094
+ "page_idx": 8
1095
+ },
1096
+ {
1097
+ "type": "text",
1098
+ "text": "Geoffrey Hinton, Oriol Vinyals, and Jeff Dean. Distilling the knowledge in a neural network, 2015. ",
1099
+ "bbox": [
1100
+ 173,
1101
+ 806,
1102
+ 821,
1103
+ 821
1104
+ ],
1105
+ "page_idx": 8
1106
+ },
1107
+ {
1108
+ "type": "text",
1109
+ "text": "Po-Sen Huang, Xiaodong He, Jianfeng Gao, Li Deng, Alex Acero, and Larry Heck. Learning deep structured semantic models for web search using clickthrough data. In Proceedings of the 22nd ACM international conference on Information & Knowledge Management, pp. 2333–2338, 2013. ",
1110
+ "bbox": [
1111
+ 176,
1112
+ 830,
1113
+ 821,
1114
+ 873
1115
+ ],
1116
+ "page_idx": 8
1117
+ },
1118
+ {
1119
+ "type": "text",
1120
+ "text": "Samuel Humeau, Kurt Shuster, Marie-Anne Lachaux, and Jason Weston. Poly-encoders: Transformer architectures and pre-training strategies for fast and accurate multi-sentence scoring. arXiv preprint arXiv:1905.01969, 2019. ",
1121
+ "bbox": [
1122
+ 174,
1123
+ 882,
1124
+ 823,
1125
+ 922
1126
+ ],
1127
+ "page_idx": 8
1128
+ },
1129
+ {
1130
+ "type": "text",
1131
+ "text": "Gautier Izacard and Edouard Grave. Leveraging passage retrieval with generative models for open domain question answering. arXiv preprint arXiv:2007.01282, 2020. ",
1132
+ "bbox": [
1133
+ 171,
1134
+ 103,
1135
+ 823,
1136
+ 132
1137
+ ],
1138
+ "page_idx": 9
1139
+ },
1140
+ {
1141
+ "type": "text",
1142
+ "text": "Jeff Johnson, Matthijs Douze, and Herve J ´ egou. Billion-scale similarity search with gpus. ´ IEEE Transactions on Big Data, 2019. ",
1143
+ "bbox": [
1144
+ 173,
1145
+ 140,
1146
+ 823,
1147
+ 170
1148
+ ],
1149
+ "page_idx": 9
1150
+ },
1151
+ {
1152
+ "type": "text",
1153
+ "text": "Karen Sparck Jones. A statistical interpretation of term specificity and its application in retrieval. Journal of documentation, 1972. ",
1154
+ "bbox": [
1155
+ 173,
1156
+ 179,
1157
+ 821,
1158
+ 208
1159
+ ],
1160
+ "page_idx": 9
1161
+ },
1162
+ {
1163
+ "type": "text",
1164
+ "text": "Mandar Joshi, Eunsol Choi, Daniel S. Weld, and Luke Zettlemoyer. Triviaqa: A large scale distantly supervised challenge dataset for reading comprehension. In Proc. ACL, 2017. ",
1165
+ "bbox": [
1166
+ 173,
1167
+ 217,
1168
+ 823,
1169
+ 246
1170
+ ],
1171
+ "page_idx": 9
1172
+ },
1173
+ {
1174
+ "type": "text",
1175
+ "text": "Vladimir Karpukhin, Barlas Oguz, Sewon Min, Ledell Wu, Sergey Edunov, Danqi Chen, and ˘ Wen-tau Yih. Dense passage retrieval for open-domain question answering. arXiv preprint arXiv:2004.04906, 2020. ",
1176
+ "bbox": [
1177
+ 176,
1178
+ 253,
1179
+ 823,
1180
+ 297
1181
+ ],
1182
+ "page_idx": 9
1183
+ },
1184
+ {
1185
+ "type": "text",
1186
+ "text": "Omar Khattab, Christopher Potts, and Matei Zaharia. Relevance-guided supervision for openqa with colbert, 2020. ",
1187
+ "bbox": [
1188
+ 174,
1189
+ 306,
1190
+ 823,
1191
+ 335
1192
+ ],
1193
+ "page_idx": 9
1194
+ },
1195
+ {
1196
+ "type": "text",
1197
+ "text": "Diederik P Kingma and Jimmy Ba. Adam: A method for stochastic optimization. arXiv preprint arXiv:1412.6980, 2014. ",
1198
+ "bbox": [
1199
+ 174,
1200
+ 343,
1201
+ 821,
1202
+ 372
1203
+ ],
1204
+ "page_idx": 9
1205
+ },
1206
+ {
1207
+ "type": "text",
1208
+ "text": "Toma´s Ko ˇ cisk ˇ y, Jonathan Schwarz, Phil Blunsom, Chris Dyer, Karl Moritz Hermann, G \\` abor Melis, ´ and Edward Grefenstette. The NarrativeQA reading comprehension challenge. TACL, 2018. ",
1209
+ "bbox": [
1210
+ 174,
1211
+ 381,
1212
+ 821,
1213
+ 411
1214
+ ],
1215
+ "page_idx": 9
1216
+ },
1217
+ {
1218
+ "type": "text",
1219
+ "text": "Tom Kwiatkowski, Jennimaria Palomaki, Olivia Redfield, Michael Collins, Ankur Parikh, Chris Alberti, Danielle Epstein, Illia Polosukhin, Matthew Kelcey, Jacob Devlin, Kenton Lee, Kristina N. Toutanova, Llion Jones, Ming-Wei Chang, Andrew Dai, Jakob Uszkoreit, Quoc Le, and Slav Petrov. Natural Questions: a benchmark for question answering research. TACL, 2019. ",
1220
+ "bbox": [
1221
+ 174,
1222
+ 419,
1223
+ 825,
1224
+ 477
1225
+ ],
1226
+ "page_idx": 9
1227
+ },
1228
+ {
1229
+ "type": "text",
1230
+ "text": "Kenton Lee, Ming-Wei Chang, and Kristina Toutanova. Latent retrieval for weakly supervised open domain question answering. In Proc. ACL, 2019. ",
1231
+ "bbox": [
1232
+ 173,
1233
+ 486,
1234
+ 823,
1235
+ 515
1236
+ ],
1237
+ "page_idx": 9
1238
+ },
1239
+ {
1240
+ "type": "text",
1241
+ "text": "Mike Lewis, Yinhan Liu, Naman Goyal, Marjan Ghazvininejad, Abdelrahman Mohamed, Omer Levy, Ves Stoyanov, and Luke Zettlemoyer. BART: Denoising sequence-to-sequence pretraining for natural language generation, translation, and comprehension. arXiv preprint arXiv:1910.13461, 2019. ",
1242
+ "bbox": [
1243
+ 173,
1244
+ 522,
1245
+ 825,
1246
+ 580
1247
+ ],
1248
+ "page_idx": 9
1249
+ },
1250
+ {
1251
+ "type": "text",
1252
+ "text": "Mike Lewis, Marjan Ghazvininejad, Gargi Ghosh, Armen Aghajanyan, Sida Wang, and Luke Zettlemoyer. Pre-training via paraphrasing. arXiv preprint arXiv:2006.15020, 2020a. ",
1253
+ "bbox": [
1254
+ 169,
1255
+ 588,
1256
+ 823,
1257
+ 618
1258
+ ],
1259
+ "page_idx": 9
1260
+ },
1261
+ {
1262
+ "type": "text",
1263
+ "text": "Patrick Lewis, Ethan Perez, Aleksandara Piktus, Fabio Petroni, Vladimir Karpukhin, Naman Goyal, Heinrich Kuttler, Mike Lewis, Wen-tau Yih, Tim Rockt ¨ aschel, et al. Retrieval-augmented gener- ¨ ation for knowledge-intensive nlp tasks. arXiv preprint arXiv:2005.11401, 2020b. ",
1264
+ "bbox": [
1265
+ 174,
1266
+ 626,
1267
+ 820,
1268
+ 670
1269
+ ],
1270
+ "page_idx": 9
1271
+ },
1272
+ {
1273
+ "type": "text",
1274
+ "text": "Ilya Loshchilov and Frank Hutter. Decoupled weight decay regularization. In International Conference on Learning Representations, 2019. ",
1275
+ "bbox": [
1276
+ 168,
1277
+ 678,
1278
+ 823,
1279
+ 707
1280
+ ],
1281
+ "page_idx": 9
1282
+ },
1283
+ {
1284
+ "type": "text",
1285
+ "text": "Yi Luan, Jacob Eisenstein, Kristina Toutanova, and Michael Collins. Sparse, dense, and attentional representations for text retrieval. arXiv preprint arXiv:2005.00181, 2020. ",
1286
+ "bbox": [
1287
+ 171,
1288
+ 715,
1289
+ 823,
1290
+ 746
1291
+ ],
1292
+ "page_idx": 9
1293
+ },
1294
+ {
1295
+ "type": "text",
1296
+ "text": "Christopher D Manning, Hinrich Schutze, and Prabhakar Raghavan. ¨ Introduction to information retrieval. Cambridge university press, 2008. ",
1297
+ "bbox": [
1298
+ 173,
1299
+ 753,
1300
+ 823,
1301
+ 784
1302
+ ],
1303
+ "page_idx": 9
1304
+ },
1305
+ {
1306
+ "type": "text",
1307
+ "text": "Bhaskar Mitra, Nick Craswell, et al. An introduction to neural information retrieval. Foundations and Trends $\\textsuperscript { \\textregistered }$ in Information Retrieval, 13(1):1–126, 2018. ",
1308
+ "bbox": [
1309
+ 169,
1310
+ 791,
1311
+ 823,
1312
+ 820
1313
+ ],
1314
+ "page_idx": 9
1315
+ },
1316
+ {
1317
+ "type": "text",
1318
+ "text": "Rodrigo Nogueira and Kyunghyun Cho. Passage re-ranking with bert. arXiv preprint arXiv:1901.04085, 2019. ",
1319
+ "bbox": [
1320
+ 169,
1321
+ 829,
1322
+ 825,
1323
+ 858
1324
+ ],
1325
+ "page_idx": 9
1326
+ },
1327
+ {
1328
+ "type": "text",
1329
+ "text": "Hamid Palangi, Li Deng, Yelong Shen, Jianfeng Gao, Xiaodong He, Jianshu Chen, Xinying Song, and Rabab Ward. Deep sentence embedding using long short-term memory networks: Analysis and application to information retrieval. IEEE/ACM Transactions on Audio, Speech, and Language Processing, 24(4):694–707, 2016. ",
1330
+ "bbox": [
1331
+ 174,
1332
+ 867,
1333
+ 825,
1334
+ 924
1335
+ ],
1336
+ "page_idx": 9
1337
+ },
1338
+ {
1339
+ "type": "text",
1340
+ "text": "Colin Raffel, Noam Shazeer, Adam Roberts, Katherine Lee, Sharan Narang, Michael Matena, Yanqi Zhou, Wei Li, and Peter J Liu. Exploring the limits of transfer learning with a unified text-to-text transformer. arXiv preprint arXiv:1910.10683, 2019. ",
1341
+ "bbox": [
1342
+ 178,
1343
+ 103,
1344
+ 823,
1345
+ 146
1346
+ ],
1347
+ "page_idx": 10
1348
+ },
1349
+ {
1350
+ "type": "text",
1351
+ "text": "Pranav Rajpurkar, Jian Zhang, Konstantin Lopyrev, and Percy Liang. SQuAD: $1 0 0 { , } 0 0 0 { + }$ questions for machine comprehension of text. In Proc. EMNLP, 2016. ",
1352
+ "bbox": [
1353
+ 171,
1354
+ 155,
1355
+ 823,
1356
+ 184
1357
+ ],
1358
+ "page_idx": 10
1359
+ },
1360
+ {
1361
+ "type": "text",
1362
+ "text": "Stephen E Robertson, Steve Walker, Susan Jones, Micheline M Hancock-Beaulieu, Mike Gatford, et al. Okapi at TREC-3. NIST Special Publication Sp, 1995. ",
1363
+ "bbox": [
1364
+ 173,
1365
+ 193,
1366
+ 823,
1367
+ 222
1368
+ ],
1369
+ "page_idx": 10
1370
+ },
1371
+ {
1372
+ "type": "text",
1373
+ "text": "Yelong Shen, Xiaodong He, Jianfeng Gao, Li Deng, and Gregoire Mesnil. Learning semantic rep- ´ resentations using convolutional neural networks for web search. In Proceedings of the $2 3 r d$ international conference on world wide web, pp. 373–374, 2014. ",
1374
+ "bbox": [
1375
+ 176,
1376
+ 229,
1377
+ 823,
1378
+ 273
1379
+ ],
1380
+ "page_idx": 10
1381
+ },
1382
+ {
1383
+ "type": "text",
1384
+ "text": "James Thorne, Andreas Vlachos, Christos Christodoulopoulos, and Arpit Mittal. Fever: a large-scale dataset for fact extraction and verification. arXiv preprint arXiv:1803.05355, 2018. ",
1385
+ "bbox": [
1386
+ 173,
1387
+ 281,
1388
+ 823,
1389
+ 310
1390
+ ],
1391
+ "page_idx": 10
1392
+ },
1393
+ {
1394
+ "type": "text",
1395
+ "text": "Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Ł ukasz Kaiser, and Illia Polosukhin. Attention is all you need. In Advances in Neural Information Processing Systems 30, pp. 5998–6008. 2017. ",
1396
+ "bbox": [
1397
+ 173,
1398
+ 319,
1399
+ 823,
1400
+ 363
1401
+ ],
1402
+ "page_idx": 10
1403
+ },
1404
+ {
1405
+ "type": "text",
1406
+ "text": "Ellen M Voorhees et al. The TREC-8 question answering track report. In TREC, 1999. ",
1407
+ "bbox": [
1408
+ 173,
1409
+ 371,
1410
+ 741,
1411
+ 387
1412
+ ],
1413
+ "page_idx": 10
1414
+ },
1415
+ {
1416
+ "type": "text",
1417
+ "text": "Sohee Yang and Minjoon Seo. Is retriever merely an approximator of reader? arXiv preprint arXiv:2010.10999, 2020. ",
1418
+ "bbox": [
1419
+ 173,
1420
+ 395,
1421
+ 821,
1422
+ 424
1423
+ ],
1424
+ "page_idx": 10
1425
+ },
1426
+ {
1427
+ "type": "text",
1428
+ "text": "Wei Yang, Yuqing Xie, Aileen Lin, Xingyu Li, Luchen Tan, Kun Xiong, Ming Li, and Jimmy Lin. End-to-end open-domain question answering with BERTserini. In Proc. NAACL (Demonstrations), 2019. ",
1429
+ "bbox": [
1430
+ 174,
1431
+ 433,
1432
+ 825,
1433
+ 476
1434
+ ],
1435
+ "page_idx": 10
1436
+ },
1437
+ {
1438
+ "type": "table",
1439
+ "img_path": "images/b9c62d58545360da4589e7c0a92cfce16e4357df617d4997c9c1cc88f810c3c0.jpg",
1440
+ "table_caption": [
1441
+ "Table 6: Hyperparameters for retriever and reader training. "
1442
+ ],
1443
+ "table_footnote": [],
1444
+ "table_body": "<table><tr><td>Hyperparameter</td><td>Reader-base</td><td>Reader-large</td><td>Retriever</td></tr><tr><td>Number of parameters</td><td>220M</td><td>770M</td><td>110M</td></tr><tr><td>Number of heads</td><td>12</td><td>16</td><td>12</td></tr><tr><td>Number of layers</td><td>24</td><td>48</td><td>12</td></tr><tr><td>Hidden size</td><td>768</td><td>1024</td><td>768</td></tr><tr><td>Batch size</td><td>64</td><td>64</td><td>64</td></tr><tr><td>Dropout</td><td>0.1</td><td>0.1</td><td>0.1</td></tr><tr><td>Learning rate schedule</td><td>constant</td><td>linear</td><td>constant</td></tr><tr><td>Peak learning rate</td><td>0.0001</td><td>0.00005</td><td>0.00005</td></tr><tr><td>Gradient clipping</td><td>1.</td><td>1.</td><td>1.</td></tr></table>",
1445
+ "bbox": [
1446
+ 272,
1447
+ 99,
1448
+ 725,
1449
+ 256
1450
+ ],
1451
+ "page_idx": 11
1452
+ },
1453
+ {
1454
+ "type": "text",
1455
+ "text": "A EXPERIMENTAL DETAILS ",
1456
+ "text_level": 1,
1457
+ "bbox": [
1458
+ 176,
1459
+ 304,
1460
+ 421,
1461
+ 320
1462
+ ],
1463
+ "page_idx": 11
1464
+ },
1465
+ {
1466
+ "type": "text",
1467
+ "text": "A.1 SETTING ",
1468
+ "text_level": 1,
1469
+ "bbox": [
1470
+ 176,
1471
+ 335,
1472
+ 281,
1473
+ 351
1474
+ ],
1475
+ "page_idx": 11
1476
+ },
1477
+ {
1478
+ "type": "text",
1479
+ "text": "For NaturalQuestions and TriviaQA we follow the standard open-domain question answering setting used in Lee et al. (2019); Karpukhin et al. (2020). In this setting the original development set is used as test set, and $10 \\%$ of the training set is used for development purpose. Moreover, for NaturalQuestions, all questions with answers longer than five tokens are discarded. ",
1480
+ "bbox": [
1481
+ 174,
1482
+ 362,
1483
+ 825,
1484
+ 417
1485
+ ],
1486
+ "page_idx": 11
1487
+ },
1488
+ {
1489
+ "type": "text",
1490
+ "text": "For TriviaQA we use the unique human-generated answer to train the reader. In this dataset part of the answers are in uppercase. We normalize uppercase answers by converting the first letter in each word to uppercase and remaining characters to lowercase using the title Python string method. ",
1491
+ "bbox": [
1492
+ 176,
1493
+ 425,
1494
+ 825,
1495
+ 467
1496
+ ],
1497
+ "page_idx": 11
1498
+ },
1499
+ {
1500
+ "type": "text",
1501
+ "text": "For NarrativeQA, questions and answers in uppercase are converted to lowercase. ",
1502
+ "bbox": [
1503
+ 174,
1504
+ 474,
1505
+ 707,
1506
+ 488
1507
+ ],
1508
+ "page_idx": 11
1509
+ },
1510
+ {
1511
+ "type": "text",
1512
+ "text": "A.2 TRAINING ",
1513
+ "text_level": 1,
1514
+ "bbox": [
1515
+ 176,
1516
+ 505,
1517
+ 289,
1518
+ 520
1519
+ ],
1520
+ "page_idx": 11
1521
+ },
1522
+ {
1523
+ "type": "text",
1524
+ "text": "For every datasets, both the reader and the retriever are fine-tuned with a dropout rate of $10 \\%$ . All models at the exception of the large reader are trained using the ADAM algorithm (Kingma & Ba, 2014) with a constant learning rate of $1 0 ^ { - 4 }$ for the base reader and $5 \\cdot 1 0 ^ { - 5 } $ for the retriever. The base reader is trained for 10k gradient steps with a batch size of 64. We train the large reader with the ADAMW algorithm (Loshchilov & Hutter, 2019) with a peak learning rate of $5 \\cdot 1 0 ^ { - 5 }$ and a linear warmup for 600 gradient steps followed by a linear decrease of the learning rate for $1 4 . 4 \\mathrm { k }$ gradient steps. ",
1525
+ "bbox": [
1526
+ 174,
1527
+ 531,
1528
+ 825,
1529
+ 630
1530
+ ],
1531
+ "page_idx": 11
1532
+ },
1533
+ {
1534
+ "type": "text",
1535
+ "text": "We perform model selection on the validation performance. The retriever is trained until its performance saturates with a batch size of 64. To monitor the performance of the retriever during training, we measure the similarity between the ranking obtained with the reader score, and the ranking of the retriever. We use different metrics for this: the number of inversions between the two rankings, the proportion of passages in the retriever top- $k$ that are also in the reader top- $k$ and the number of passages to obtain all top- $k$ passage of the reader. ",
1536
+ "bbox": [
1537
+ 174,
1538
+ 636,
1539
+ 825,
1540
+ 719
1541
+ ],
1542
+ "page_idx": 11
1543
+ },
1544
+ {
1545
+ "type": "text",
1546
+ "text": "During training and at test time, each text input of the encoder is restricted to be at most 250 token long. For NaturalQuestions and TriviaQA, we use wikipedia as a knowledge source, thus for each passage there is an associated article title. Each input is composed of the concatenation of a question, title and support passage with special tokens question:, title: and context: added before the question, the title and the text of each passage. In the case of NarrativeQA, the question and each passage are concatenated to form the different inputs. ",
1547
+ "bbox": [
1548
+ 174,
1549
+ 727,
1550
+ 825,
1551
+ 810
1552
+ ],
1553
+ "page_idx": 11
1554
+ },
1555
+ {
1556
+ "type": "text",
1557
+ "text": "A.3 INFERENCE ",
1558
+ "text_level": 1,
1559
+ "bbox": [
1560
+ 176,
1561
+ 827,
1562
+ 299,
1563
+ 842
1564
+ ],
1565
+ "page_idx": 11
1566
+ },
1567
+ {
1568
+ "type": "text",
1569
+ "text": "At test time, for TriviaQA and NaturalQuestions we use greedy decoding, and Beam Search with 3 beams for NarrativeQA. ",
1570
+ "bbox": [
1571
+ 176,
1572
+ 853,
1573
+ 823,
1574
+ 882
1575
+ ],
1576
+ "page_idx": 11
1577
+ },
1578
+ {
1579
+ "type": "table",
1580
+ "img_path": "images/4ef8044a25f7572921aa2f04a3620f1881b7d8b5090ee05bff741f6e9b8c2a21.jpg",
1581
+ "table_caption": [],
1582
+ "table_footnote": [],
1583
+ "table_body": "<table><tr><td></td><td colspan=\"3\">NaturalQuestions</td><td colspan=\"3\">TriviaQA</td></tr><tr><td>Iter.</td><td>P@20</td><td>P@100</td><td>Dev EM</td><td>P@20</td><td>P@100</td><td>Dev EM</td></tr><tr><td>0</td><td>77.1</td><td>84.3</td><td>46.4</td><td>78.2</td><td>84.7</td><td>65.0</td></tr><tr><td>1</td><td>80.3</td><td>86.7</td><td>47.8</td><td>81.4</td><td>86.4</td><td>67.1</td></tr><tr><td>2</td><td>82.4</td><td>87.9</td><td>48.2</td><td>83.5</td><td>87.4</td><td>68.1</td></tr></table>",
1584
+ "bbox": [
1585
+ 251,
1586
+ 436,
1587
+ 746,
1588
+ 522
1589
+ ],
1590
+ "page_idx": 12
1591
+ },
1592
+ {
1593
+ "type": "text",
1594
+ "text": "Table 7: Iterative training starting with documents retrieved with DPR. Iteration 0 corresponds to the performance of the reader trained on the set of initial support documents. We report all metrics on the validation set. Contrary to results reported in Table 1, the reader model was not re-initialized between each iteration. ",
1595
+ "bbox": [
1596
+ 176,
1597
+ 532,
1598
+ 823,
1599
+ 588
1600
+ ],
1601
+ "page_idx": 12
1602
+ }
1603
+ ]
parse/train/NTEz-6wysdb/NTEz-6wysdb_middle.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/NTEz-6wysdb/NTEz-6wysdb_model.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/qbH974jKUVy/qbH974jKUVy.md ADDED
@@ -0,0 +1,254 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # THE ROLE OF DISENTANGLEMENT IN GENERALISATION
2
+
3
+ Milton L. Montero1,2, Casimir J.H. Ludwig 1, Rui Ponte Costa2, Gaurav Malhotra1 & Jeffrey S. Bowers 1
4
+
5
+ 1. School of Psychological Science
6
+ 2. Computational Neuroscience Unit, Department of Computer Science
7
+ University of Bristol
8
+ Bristol, United Kingdom
9
+ {m.lleramontero,c.ludwig,rui.costa,gaurav.malhotra,j.bowers}@bristol.ac.uk
10
+
11
+ # ABSTRACT
12
+
13
+ Combinatorial generalisation — the ability to understand and produce novel combinations of familiar elements — is a core capacity of human intelligence that current AI systems struggle with. Recently, it has been suggested that learning disentangled representations may help address this problem. It is claimed that such representations should be able to capture the compositional structure of the world which can then be combined to support combinatorial generalisation. In this study, we systematically tested how the degree of disentanglement affects various forms of generalisation, including two forms of combinatorial generalisation that varied in difficulty. We trained three classes of variational autoencoders (VAEs) on two datasets on an unsupervised task by excluding combinations of generative factors during training. At test time we ask the models to reconstruct the missing combinations in order to measure generalisation performance. Irrespective of the degree of disentanglement, we found that the models supported only weak combinatorial generalisation. We obtained the same outcome when we directly input perfectly disentangled representations as the latents, and when we tested a model on a more complex task that explicitly required independent generative factors to be controlled. While learning disentangled representations does improve interpretability and sample efficiency in some downstream tasks, our results suggest that they are not sufficient for supporting more difficult forms of generalisation.
14
+
15
+ # 1 INTRODUCTION
16
+
17
+ Generalisation to unseen data has been a key challenge for neural networks since the early days of connectionism, with considerable debate about whether these models can emulate the kinds of behaviours that are present in humans (McClelland et al., 1986; Fodor & Pylyshyn, 1988; Smolensky, 1987; 1988; Fodor & McLaughlin, 1990). While the modern successes of Deep Learning do indeed point to impressive gains in this regard, human level generalisation still remains elusive (Lake & Baroni, 2018; Marcus, 2018). One explanation for this is that humans encode stimuli in a compositional manner, with a small set of independent and more primitive features (e.g., separate representations of size, position, line orientation, etc.) being used to build more complex representation (e.g., a square of a given size and position). The meaning of the more complex representation comes from the meaning of it’s parts. Critically, compositional representations afford the ability to recombine primitives in novel ways: if a person has learnt to recognize squares and circles in context where all squares are blue and all circles are red, they can nevertheless also recognise red squares, even though they have never seen these in the training data. This ability to perform combinatorial generalisation based on compositional representations is thought to be a hallmark of human level intelligence (Fodor & Pylyshyn, 1988) (See McClelland et al. (1986) for a diverging opinion).
18
+
19
+ Recently it has been proposed that generalisation in neural networks can be improved by extracting disentangled representations (Higgins et al., 2017) from data using (variational) generative models (Kingma & Welling, 2013; Rezende et al., 2014). In this view, disentangled representations capture the compositional structure of the world (Higgins et al., 2018a; Duan et al., 2020), separating the generative factors present in the stimuli into separate components of the internal representation (Higgins et al., 2017; Burgess et al., 2018). It has been argued that these representations allow downstream models to perform better due to the structured nature of the representations (Higgins et al., 2017; 2018b) and to share information across related tasks (Bengio et al., 2014). Here we are interested in the question of whether networks can support combinatorial generalisation and extrapolation by exploiting these disentangled representations.
20
+
21
+ In this study we systematically tested whether and how disentangled representations support three forms of generalisation: two forms of combinatorial generalisation that varied in difficulty as well as extrapolation, as detailed below. We explored this issue by assessing how well models could render images when we varied (1) the image datasets (dSprites and 3DShape), (2) the models used to reconstruct these images ( $\beta$ -VAEs and FactorVAEs with different disentanglement pressures, and decoder models in which we dropped the encoders and directly input perfectly disentangled latents), and (3) the tasks that varied in their combinatorial requirements (image reconstruction vs. image transformation). Across all conditions we found that models only supported the simplest versions of combinatorial generalisation and the degree of disentanglement had no impact on the degree of generalisation. These findings suggest that models with entangled and disentangled representations are both generalising on the basis of overall similarity of the trained and test images (interpolation), and that combinatorial generalisation requires more than learning disentangled representations.
22
+
23
+ # 1.1 PREVIOUS WORK
24
+
25
+ Recent work on learning disentangled representations in unsupervised generative models has indeed shown some promise in improving the performance of downstream tasks (Higgins et al., 2018b; van Steenkiste et al., 2019) but this benefit is mainly related to sample efficiency rather than generalisation. Indeed, we are only aware of two studies that have considered the importance of learned disentanglement for combinatorial generalisation and they have used different network architectures and have reached opposite conclusions. Bowers et al. (2016) showed that a recurrent model of shortterm memory tested on lists of words that required some degree of combinatorial generalisation (recalling a sequence of words when one or more of words at test were novel) only succeeded when it had learned highly selective (disentangled) representations ("grandmother cell" units for letters). By contrast, Chaabouni et al. (2020) found that models with disentangled representations do not confer significant improvements in generalisation over entangled ones in a language modeling setting, with both entangled and disentangled representations supporting combinatorial generalisation as long as the training set was rich enough. At the same time, they found that languages generated through compositional representations were easier to learn, suggesting this as a pressure to learn disentangled representations.
26
+
27
+ A number of recent papers have reported that VAEs can support some degree of combinatorial generalisation, but there is no clear understanding of whether and how disentangled representations played any role in supporting this performance. Esmaeili et al. (2019) showed that a model trained on the MNIST dataset could reconstruct images even when some particular combination of factors were removed during training, such as a thick number 7 or a narrow 0. The authors also showed that the model had learned disentangled representations and concluded that the disentangled representations played a role in the successful performance. However, the authors did not vary the degree of disentanglement in their models and, accordingly, it is possible that a VAE that learned entangled representations would do just as well. Similarly, Higgins et al. (2018c) have highlighted how VAEs that learn disentangled representations can support some forms of combinatorial generalisation when generating images from text. For example, their model could render a room with white walls, pink floor and blue ceiling even though it was never shown that combination in the training set. This is an impressive form of combinatorial generalisation but, as we show below, truly compositional representations should be able to support several other forms of combinatorial generalisations that were not tested in this study. Moreover, it is not clear what role disentanglement played in this successful instance of generalisation. Finally, Zhao et al. (2018) assessed VAE performance on a range of combinatorial generalisation tasks that varied in difficulty, and found that the model performed well in the simplest settings but struggled in more difficult ones. But again, they did not consider whether learning disentangled representations was relevant to generalisation performance.
28
+
29
+ Another work that has significant relation to ours is Locatello et al. (2019), who examine how hard it is to learn disentangled representations and their relation to sampling efficiency for downstream tasks. We are interested in a related, but different question: even if a model learns a disentangled representation in an intermediate layer, does this enable models to achieve combinatorial generalisation? So while Locatello et al. (2019) train their models on complete datasets to investigate the degree of disentanglement and sampling efficiency, we systematically exclude generative factors from training in order to test for combinatorial generalisation (see Methods and Results).
30
+
31
+ ![](images/ca12adc3248df5e251d862bb3d9849c826f1d614a761c14d95ac7b90aa86f9d1.jpg)
32
+ Figure 1: Testing generalisation in image reconstruction. (a) An illustration of different tests of combinatorial generalisation for the three-dimensional case (i.e., three generative factors). The blank cells represent combinations that the model is trained on. Coloured cells represent novel test combinations that probe different forms of generalisation: Recombination-to-Element (red), Recombination-to-Range (green) and Extrapolation (blue) – see main text for details. (b) Each row shows an example of training and test stimuli for testing a form of generalisation. In the top row, training set excludes ellipses in the bottom-right corner at less than $1 2 0 ^ { \circ }$ though they are present at the bottom-right corner at other rotations. In the middle row, training set excludes squares in the right side of the image though other shapes and rotations are present at this location and squares are seen at all other combinations of rotations and translations. In the bottom row, training set excludes all shapes on the right side of the image.
33
+
34
+ # 2 METHODS AND RESULTS
35
+
36
+ We assessed combinatorial generalisation on two different datasets. The dSprites image dataset (Matthey et al., 2017) contains 2D images in black and white that vary along five generative factors: shape, scale, orientation, position- $\times$ and position-y and focuses on manipulations of single objects. The 3D Shapes dataset (Burgess & Kim, 2018) contains 3D images in colour that vary along six generative factors: floor-hue, wall-hue, object-hue, object-shape, object-scale, object-orientation. In contrast to dSprites, the images are more realistic, which has been shown to aid reconstruction performance (Locatello et al., 2019). To test combinatorial generalisation, we systematically excluded some combinations of these generative factors from the training data and tested reconstruction on these unseen values. Test cases can be divided into three broad categories based on the number of combinations excluded from training.
37
+
38
+ • Recombination-to-Element (red squares in Figure 1): The model has never been trained on one combination of all of the generative factors. In dSprites, an example of this case would be excluding the combination: [shape=ellipse, scale=1, orientation $< ~ 1 2 0 ^ { \circ }$ , position- $\mathsf { x } { > } \Theta . 5$ , position$y > 0 . 5 ]$ from the training set – i.e. the model has never seen a large ellipse at $< ~ 1 2 0 ^ { \circ }$ in the bottom-right corner, though it has seen all other combinations.
39
+
40
+ • Recombination-to-Range (green squares in Figure 1): The model has never been trained on all combinations of some of the factors (i.e. a subset of generative factors). For example, in the 3D Shapes dataset, all combinations with [object-hue $^ { = 1 }$ , shap $: = \mathfrak { s }$ sphere] have been left out of the training set – i.e. none of the training images contain a blue sphere. This condition is more complex than Recombination-to-Element as an entire range of combinations [floor-hue=0. . . 1, wall-hue=0. . . 1, ob ject-hue=1, shape=sphere, scale=0. . . 1, orientation=0. . . 1] have been left out (here bold text indicates the range of values excluded). When the number of generative factors is larger than three, “Recombination-to-Range” is, in fact, a set of conditions that vary in difficulty, depending upon how many generative factors have been excluded. Another example would be excluding all combinations where [floor-hue=1, wall-hue=1, object-hue=1, shape=1, scale=1]. Here a smaller range of combinations [floor-hue=1, wall-hue=1, object-hue $^ { = 1 }$ , shape $^ { = 1 }$ , scale=1, orientation=0. . . 1] have been excluded.
41
+
42
+ • Extrapolation (blue squares in Figure 1): This is the most challenging form of generalisation where models are tested on values of generative factors that are beyond the range of values observed in the training dataset. For example, in the dSprites dataset, all combinations where [posi tion- $\times > 0 . 5 ]$ have never been seen.
43
+
44
+ Each of these conditions is interesting for different reasons. A model that learns compositional representations should be able to combine observed values of shape (ellipses), translation (bottom-right) and rotation $0 ^ { \circ }$ to $1 2 0 ^ { \circ }$ ) to generalise to all unseen combination of factors. The simplest case is the recombination-to-element condition in which all combinations but one have been trained, but a model that learns entangled representations might also succeed based on its training on highly similar patterns (generalisation by interpolation). A more challenging case is recombination-to-range condition given that more combinations have been excluded, making generalisation by similarity (interpolation) more difficult. The final condition is not a form of combinatorial generalisation as the model cannot combine observed values of generative factors to render images. Indeed compositional representations may be inadequate for this form of generalisation.
45
+
46
+ # 2.1 IMAGE RECONSTRUCTION WITH DSPRITES DATASET
47
+
48
+ In the dSprites dataset, for testing the Recombination-to-element case, we split each range of values of a generative factor into three bins, so that we had $3 \times 3 \times 3 \times 3 \times 3$ such combinations of bins for all five generative factors. We then remove one of these 243 combinations during training, namely those that satisfied [shap ${ \tt : e }$ llipsis, position- $\ X \ > = \ 0 . 6$ , , position- $y ~ > = ~ 0 . 6$ , $1 2 0 ^ { \circ } < =$ rotation $\angle = 2 4 0 ^ { \circ }$ , scale $< ~ 0 . 6 1$ . In other words ellipses in the bottom right corner with those given rotations, which is a relatively small number of combinations that are all very similar to each other.
49
+
50
+ For the Recombination-to-range case, we tested three different variants. First, we excluded all combinations where [shape $! = !$ square, position- $\mathsf { x } { \mathsf { > } } \Theta . 5 ]$ . The model sees other shapes at those positions during training and it sees squares on the left-hand side of the screen. Thus the models experiences both generative factor values independently and has to recombine them to produce a novel image at test time. In the second case, we excluded all combinations where [shape=square, $\mathsf { s c a l e } { \mathsf { > } } \Theta . 5 ]$ . In the third case, we excluded all combinations where [shape=square, rotation $> 9 0 ^ { \circ } ]$ ]. We observed very similar results for all three cases and below we report the results for the first variant.
51
+
52
+ Finally, for the Extrapolation case, we excluded all combinations of generative factors where [po sition- $\times \ > x ]$ . We chose a set of different values for $x$ : $x ~ \in ~ 0 . 1 6 , 0 . 2 5 , 0 . 5 0 , 0 . 7 5$ , where $x$ is normalised in the range $[ 0 , 1 ]$ (results shown in Figure 2 for $x = 0 . 5 0 $ ). At test time the model needed to reconstruct images where translation along the $\mathbf { X }$ -axis, $x$ , was greater than the cutoff value.
53
+
54
+ We tested three classes of models on all three types of generalisation: standard Variational Autoencoder (VAEs, Kingma & Welling (2013); Rezende et al. (2014)), $\beta$ -VAE (Higgins et al., 2017; Burgess et al., 2018) with $\beta = 8$ and $\beta = 1 2$ , FactorVAE (Kim & Mnih, 2019) with $\gamma = 2 0$ , $\gamma = 5 0$ and $\gamma = 1 0 0$ . The architectures are the ones found in Higgins et al. (2017), Burgess et al. (2018) and Kim & Mnih (2019) (Details in the Appendix). We used a batch size of 64 and a learning rate of $5 e - 4$ for the Adam optimizer (Kingma & Ba, 2017). In each case, we simulated three seeds and we report results for runs where we obtained largest disentanglement.
55
+
56
+ As shown by Locatello et al. (2019), none of the models trained end-to-end in an unsupervised manner produce perfectly disentangled representations. Since we were interested in studying the effect of disentanglement on generalisation, we compared our results with a model where we removed the encoder and directly gave disentangled latents as inputs to the decoder. We call this model the ground-truth decoder (GT Decoder from here on). This decoder uses the same MLP architecture as the one used in Higgins et al. (2017). We tested deeper decoders with convolutions and batch norm as well, but found no benefit or a decrease in performance.
57
+
58
+ We measured the level of disentanglement using the framework introduced in Eastwood & Williams (2018). The procedure consists of using the latent representations generated for each image to predict the true generative factors using a regression model (in our case, Lasso regression; see Appendix A). The level of disentanglement is quantified by their ‘Overall disentanglement metric’, which we call D-score here.
59
+
60
+ ![](images/5f366e82e8ceb5c74b34978ae9c4c111df55825f734284f6b060c86c3a740588.jpg)
61
+ Figure 2: Image reconstruction and disentanglement for the dSprites dataset (a) Top row shows examples of input images and the four rows below show reconstructions by four different models. Three pairs of columns show reconstructions in training and test conditions. Left) Recombinationto-Element condition where the models did not see [shape $=$ ellipse, scale $= 1$ , orientation $< 1 2 0 ^ { \circ }$ , po sition- $\times \ > 0 . 5$ , position- $\mathsf { y } > 0 . 5 \mathsf { l }$ , Middle) Recombination-to-Range condition where models did not see [shape $=$ square, position- $\times ~ > 0 . 5 ]$ , Right) Extrapolation condition where models did not see [posi tion- $\times > \Theta . 5 ]$ (b) Visualisation of disentanglement. In each panel, columns show latent variables and rows show the generative factors. The size of the square represents the relative importance of the latent variable for predicting the generative factor. Sparse matrices indicate higher disentanglement (Eastwood & Williams, 2018). Each disentanglement matrix corresponds to the model on that row in (a) in the Reconstruction-to-Range condition. The visualisation of the entire set of models and all conditions is shown in Appendix B
62
+
63
+ Figure 2 shows examples of model reconstructions for each of the conditions which help assess the reconstruction success qualitatively (more examples are shown in Appendix C). A more quantitative assessment of the models can be made by examining the negative-log-likelihood of reconstructions for different conditions, plotted in Figure 3. The amount of disentanglement achieved by the models trained end-to-end varied over a broad range and was a function of model architecture and the hyperparameter ( $\beta$ and $\gamma$ ) values. In general, reconstruction accuracy was better for smaller values of $\beta$ both during training and testing. This has been observed before and is a known issue encountered when increasing the value of $\beta$ parameter (Hoffman & Johnson, 2016). We found that models were able to perform the Recombination-to-Element generalisation but failed in the Recombination-toRange and Extrapolation cases. In these cases, models either showed really poor reconstruction of the critical element or substituted one of the excluded combination with a combination that had been observed during training (see reconstructions for test cases in Figure 2(a)). Moreover, the amount of generalisation did not depend on the degree of disentanglement. Indeed, the GT Decoder using perfectly disentangled representations was no better than the end-to-end models. Even though this model achieved a lower NLL score, examining the image reconstructions showed that it failed to reconstruct the essential combination excluded from the training data (see Appendix B).
64
+
65
+ The Recombination-to-Range condition shows another interesting qualitative difference between the entangled and disentangled models. All models failed to generalise, but in different ways. Entangled models tended to put a blob in the correct location, which allows them to minimise loss in pixel space over a large set of test examples. In contrast, the models with higher level of disentanglement fell back to the most similar shape (in pixel space) that they had seen at that location.
66
+
67
+ ![](images/f3627aebf672b8c0b003ae2ccd960ee5dddcb4d01b4ad62c89c85e862b770c3c.jpg)
68
+ Figure 3: Disentanglement vs reconstruction NLL. The relation between the level of disentanglement and the performance of the model. Performance of the training data is plotted along with performance in the test (generalisation) data. Disentanglement does not provide any help in performance for the end-to-end models. The ground truth decoder (GTD) is less affected, yet it is still the case that it fails to generalize (see Figure 2 and Figure 4).
69
+
70
+ Finally, the Recombination-to-Element condition was solved by all the models, regardless of disentanglement score. In fact, the entangled models tended to achieve better reconstructions as evidenced by the disentangled models with $\beta { = } 1 2$ which had a hard time reconstructing ellipses at small scales and tended to just produce a circle instead.
71
+
72
+ The second panel in Figure 2 shows the coefficients computed by the disentanglement metric for the Reconstruction-to-Range condition. The size of each square denotes the relative importance of a latent (column) in predicting the corresponding generative factor (row). The higher the disentanglement, the sparser the matrices. An examination of these matrices revealed that different models achieved a large range of disentanglement though none of the end-to-end models achieved perfect disentanglement.
73
+
74
+ # 2.2 IMAGE RECONSTRUCTION WITH 3D SHAPES DATASET
75
+
76
+ The procedure for testing on the 3D Shapes dataset parallels the dSprites dataset above. The 3D Shapes dataset has six generative factors: floor-hue, wall-hue, object-hue, object-shape, object-scale, object-orientation. For the Recombination-to-Element condition, we excluded one combination from training: [floor-hue $> 0 . 5$ , wall-hue $> 0 . 5$ , object-hue $> 0 . 5$ , object-shape=cylinder, object-scale=1, object-orientation $\scriptstyle 1 = 0$ ]. For the Recombination-to-Range condition, we excluded all combinations where [object-hue $> = 0 . 5$ (cyan), object-shape $=$ oblong] and trained all other combinations. This means that the models saw several combinations where object-hue was $> = 0 . 5$ and where object-shape was oblong but never the combination together. For the Extrapolation condition, we excluded all combinations where [floor-hue $> = 0 . 5 ]$ ].
77
+
78
+ We trained the same set of six end-to-end models as above as well as the GT Decoder. All endto-end models were trained for 65 epochs (around 500000 iterations as in the original articles), while the GT Decoder was trained for 1000 epochs. Reconstructions for the training set are shown in Appendix C and clearly show that the models were able to learn the task. The results for the test conditions are shown in Figure 3 (bottom row) and some examples of typical reconstructions are shown in Figure 4. As it was the case with the dSprites dataset, we observed that the level of disentanglement varied across models, with VAE showing a low D-score and Factor-VAE showing a high Dscore. We also tested the perfectly disentangled model where a decoder learns to construct images from disentangled latents.
79
+
80
+ All models managed to reconstruct the held-out combination in the Recombination-to-element condition. However, none of the models succeeded in correctly reconstructing the held-out combinations in the Recombination-to-range or Extrapolation conditions. In both cases, we observed a large reconstruction error either due to poor overall reconstruction (Extrapolation case) or because the critical combination, [object-hue, object-shape] was replaced with a combination observed during training. And again, we did not see any correlation between disentanglement and the extent of combinatorial generalisation. Even though the perfectly disentangled model had a lower NLL score (see
81
+
82
+ ![](images/dfa5bb4b1ad4ffd9d9306d7676c88d973d00c5bf03232efcf3e97c1d7cf65e5d.jpg)
83
+ Figure 4: Image reconstructions and disentanglement for the Shapes3D dataset. We use the same layout as in Figure 2. a) Reconstruction examples for each of the three generalisation conditions. For the first condition, the model has not seen magenta floors with purple cylinders, yet it is able to reconstruct them properly. For the second condition, it has not seen magenta oblong shapes, yet it has seen it in other colors and it has seen magenta on other shapes. Finally, the in the third condition magenta floors have never been seen during training. b) Example Hinton diagrams of the coefficients used to compute disentanglement. Diagram in each row corresponds to the model in the same row in (a). Sparse matrices are better and the perfect one (up to permutation) is shown at the bottom.
84
+
85
+ Figure 3, bottom row), like other models it failed to reconstruct the critical [object-hue, object-shape] combination that was left out in the training data (see example images of reconstruction in Figure 4 and Appendix C).
86
+
87
+ # 2.3 IMAGE COMPOSITION EXPERIMENTS
88
+
89
+ The limited combinatorial generalisation in the experiments above could be because of the limitations of the task rather than the models or their internal representations. Even though the models learned disentangled representations to some extent, or were provided perfectly disentangled representations, it could be that the simple reconstruction task does not provide enough impetus for the decoder to learn how to combine these disentangled representations to enable generalisation. Therefore, in the final set of experiments we designed a variation of the standard unsupervised task that requires combining generative factors in order to solve the task using the dSprites dataset.
90
+
91
+ This new task is illustrated in Figure 5(a). The input consists of two images and an action. The goal of the task is to take the first (reference) image and modify it so that it matches the second (transform) image along the dimension specified by the action. This action is coded using a onehot vector. This design is based on the question answering task in Santoro et al. (2017) and the compositional one in Higgins et al. (2018c). We produced training and test sets for each condition by sampling reference-transform pairs along with an action uniformly from the generative factors. We ensured that this sampling respected the experiment restriction, so that the transformed image is not outside the current set.
92
+
93
+ The standard VAE is inadequate to solve this task. Therefore, we constructed a model with the architecture shown in Figure 5(b). This model first applies an encoder to both images, obtaining low-dimensional latent representations of each image. It then combines these latent representations with the action to obtain a transformed internal representation. There are several ways in which the input representations of the two images could be combined with the action. We tried three different methods: (i) using a standard MLP, (ii) element-wise interpolation between the two representations, with the interpolation coefficients determined by the action, and (iii) concatenating each input representations with the actions and linearly combining the resultant vectors. We obtained qualitatively similar results with all three methods, but found that the method (iii) gave the best results, providing greatest accuracy of reconstruction as well as highest levels of disentanglement. Therefore, in the rest of the manuscript we describe the results obtained using this method. Once this transformed internal representation has been generated, it is decoded to obtain an output image. We use the same encoding and decoding modules as the ones used by Burgess et al. (2018). The results for this model are shown in Table 1. The model managed to solve the task. In doing so, it also comes to rely on representations with a high level of disentanglement (see Figure 6(b)) even though the $\beta$ parameter is set to 1. Models with higher values could not solve the task altogether, presumably because the constraint is too strong. However, as was the case in the previous experiment, models failed to solve the more challenging generalisation tasks.
94
+
95
+ ![](images/a1323e14005938be7f7f6e6940d30904c7c95bdde979646137727d4b2ae57382.jpg)
96
+ Figure 5: Image composition task. (a) An example of the composition task. In this case, the shape of the output must match the transform and the rest of the values must match the reference. (b) The general architecture used, based on the standard VAE. The model uses the same encoder on both images. Then a transform takes latent representation samples and combines them to produce a transformed representation. This is used to produce the transformed image.
97
+
98
+ Table 1: Model performance in the second set of experiments.
99
+
100
+ <table><tr><td></td><td>Experiment</td><td>D-score</td><td>NLL (training)</td><td>NLL (testing)</td></tr><tr><td>1</td><td>Extrapolation</td><td>0.82</td><td>31.73</td><td>19138.82</td></tr><tr><td>2</td><td>Recomb to range</td><td>0.71</td><td>50.10</td><td>346.10</td></tr><tr><td>3</td><td>Recomb to element</td><td>0.96</td><td>36.57</td><td>13.74</td></tr></table>
101
+
102
+ In Figure 5 we show some examples of the model’s behaviour and its internal representations. The model failed in similar ways as the disentangled models in the previous experiment, confusing shapes when presented with unseen combinations. Even the Recombination to element case showed some failures (like in the example shown in Figure 5(a)) though the models were, in general, successful in this condition, as can be inferred by comparing the negative log-likelihoods for the training and test trials for this condition in Table 1.
103
+
104
+ # 3 DISCUSSION
105
+
106
+ It is frequently assumed that disentangled representations are implicitly compositional (Higgins et al., 2018a;c). This raises the question as to whether disentangled representations support combinatorial generalisation, a key feature of compositional representations (Fodor & Pylyshyn, 1988). However, we found no evidence for this. Indeed representations that varied from highly entangled to perfectly disentangled were equally successful at recombination-to-element generalisation, and both failed on recombination-to-range and extrapolation. This was the case even when we trained a VAE on an explicitly combinatorial task that led models to learn highly disentangled representations that were no better at generalisation.
107
+
108
+ Our findings might seem to contradict previous reports showing success in combinatorial generalisation tasks. In Eslami et al. (2018), some success was reported when rendering novel 3D shapes with colours that had been previously seen on other shapes. And in Higgins et al. (2018c) it was reported that using a disentangled representation allowed the model to recombine observed shapes and colours in novel ways. However, it is not clear what sorts of combinatorial generalisation was tested. For example, consider the SCAN model (Higgins et al., 2018c) that could render a room with [white suitcase, blue walls, magenta floor], even though it was never shown this combination during training (see Figure 4 in Higgins et al. (2018c)). But, unlike our training set, it is not clear what exactly was excluded while training this model, and they may have been testing generalisation in a condition similar to our Recombination-to-element condition. Our finding that generalisation was limited to the Recombination-to-element condition suggests that models are simply generalising on the basis of overall similarity (interpolation) rather than exploiting disentangled representations in order to support a more powerful form of compositional generalisation described by Fodor & Pylyshyn (1988).
109
+
110
+ ![](images/c5043f985aa95f7c6eaa69fa927a64f8cec2f2b7720bcd3d2b6fa296e55ea07a.jpg)
111
+ Figure 6: Image composition generalisation results (a) Each column shows an example trial which consists of a reference image, an action, a transform image and the transformed (output) image. We show examples of both training and test trials. Each of the training trials results in the correct (expected) transformed image, while each of the test trials shows a failure. (b) Visualisation of the degree of disentanglement for three conditions by the model. The sparse representation reflects the high level of disentanglement achieved by these models in this task.
112
+
113
+ This raises the question as to why disentangled representations are not more effective in supporting combinatorial generalisation. One possibility is that disentangled representations are necessary but not sufficient to support the principle of compositionality. On this view, a model must also include a mechanism for binding these representations in a way that maintains their independence. This point has previously been made in the context of connectionist representations by Hummel in Hummel (2000). Another possibility is that a model may be able to perform combinatorial generalisation without needing disentangled or indeed compositional representations if the training environment is rich enough (Chaabouni et al., 2020; Hill et al., 2020; Lampinen & McClelland, 2020).
114
+
115
+ An important goal for future research is to develop networks that support the more difficult forms of combinatorial generalisation and extrapolation. In fact there is already an active range of research in this direction that include networks with specialized modules (Santoro et al., 2017), mechanisms (Mitchell & Bowers, 2020; Hummel & Biederman, 1992), structured representations (Higgins et al., 2018c; Watters et al., 2019), or learning objectives (Vankov & Bowers, 2020) that may show greater success. It will be interesting to see how these and other approaches fare in the more difficult generalisation settings we have identified here, and the role of disentanglement in any solutions.
116
+
117
+ # ACKNOWLEDGEMENTS
118
+
119
+ We would like to thank Chris Summerfield, Irina Higgins, Ben Evans and Jeff Mitchell for useful discussions and feedback during the development of this research.
120
+
121
+ This research was supported by a ERC Advanced Grant (Generalization in Mind and Machine, #741134).
122
+
123
+ # REFERENCES
124
+
125
+ Yoshua Bengio, Aaron Courville, and Pascal Vincent. Representation Learning: A Review and New Perspectives. arXiv:1206.5538 [cs], April 2014. URL http://arxiv.org/abs/1206.5538. arXiv: 1206.5538.
126
+
127
+ Jeffrey S. Bowers, Ivan I. Vankov, Markus F. Damian, and Colin J. Davis. Why do some neurons in cortex respond to information in a selective manner? Insights from artificial neural networks. Cognition, 148:47–63, March 2016. ISSN 0010-0277. doi: 10.1016/j.cognition.2015.12.009. URL http://www.sciencedirect.com/science/article/pii/S0010027715301232.
128
+
129
+ Chris Burgess and Hyunjik Kim. 3d shapes dataset. https://github.com/deepmind/3dshapes-dataset/, 2018.
130
+
131
+ Christopher P. Burgess, Irina Higgins, Arka Pal, Loic Matthey, Nick Watters, Guillaume Desjardins, and Alexander Lerchner. Understanding disentangling in $\$ 1$ \beta\$-VAE. arXiv:1804.03599 [cs, stat], April 2018. URL http://arxiv.org/abs/1804.03599. arXiv: 1804.03599.
132
+
133
+ Rahma Chaabouni, Eugene Kharitonov, Diane Bouchacourt, Emmanuel Dupoux, and Marco Baroni. Compositionality and generalization in emergent languages. arXiv preprint arXiv:2004.09124, 2020.
134
+
135
+ Sunny Duan, Loic Matthey, Andre Saraiva, Nicholas Watters, Christopher P. Burgess, Alexander Lerchner, and Irina Higgins. Unsupervised Model Selection for Variational Disentangled Representation Learning. arXiv:1905.12614 [cs, stat], February 2020. URL http://arxiv.org/ abs/1905.12614. arXiv: 1905.12614.
136
+
137
+ Cian Eastwood and Christopher KI Williams. A framework for the quantitative evaluation of disentangled representations. In International Conference on Learning Representations, pp. 15, 2018.
138
+
139
+ S. M. Ali Eslami, Danilo Jimenez Rezende, Frederic Besse, Fabio Viola, Ari S. Morcos, Marta Garnelo, Avraham Ruderman, Andrei A. Rusu, Ivo Danihelka, Karol Gregor, David P. Reichert, Lars Buesing, Theophane Weber, Oriol Vinyals, Dan Rosenbaum, Neil Rabinowitz, Helen King, Chloe Hillier, Matt Botvinick, Daan Wierstra, Koray Kavukcuoglu, and Demis Hassabis. Neural scene representation and rendering. Science, 360(6394):1204–1210, June 2018. ISSN 0036- 8075, 1095-9203. doi: 10.1126/science.aar6170. URL https://science.sciencemag.org/ content/360/6394/1204. Publisher: American Association for the Advancement of Science Section: Research Article.
140
+
141
+ Babak Esmaeili, Hao Wu, Sarthak Jain, Alican Bozkurt, N. Siddharth, Brooks Paige, Dana H. Brooks, Jennifer Dy, and Jan-Willem Meent. Structured Disentangled Representations. In The 22nd International Conference on Artificial Intelligence and Statistics, pp. 2525–2534. PMLR, April 2019. URL http://proceedings.mlr.press/v89/esmaeili19a.html. ISSN: 2640-3498.
142
+
143
+ Jerry Fodor and Brian P. McLaughlin. Connectionism and the problem of systematicity: Why Smolensky’s solution doesn’t work. Cognition, 35(2):183–204, May 1990. ISSN 0010-0277. doi: 10.1016/0010-0277(90)90014-B. URL http://www.sciencedirect.com/science/ article/pii/001002779090014B.
144
+
145
+ Jerry A. Fodor and Zenon W. Pylyshyn. Connectionism and cognitive architecture: A critical analysis. Cognition, 28(1):3–71, March 1988. ISSN 0010-0277. doi: 10.1016/0010-0277(88)90031-5. URL http://www.sciencedirect.com/science/article/pii/0010027788900315.
146
+
147
+ Irina Higgins, Loic Matthey, Arka Pal, Christopher Burgess, Xavier Glorot, Matthew Botvinick, Shakir Mohamed, and Alexander Lerchner. $\beta$ -VAE: Learning basic visual concepts with a constrained variational framework. pp. 13, 2017.
148
+
149
+ Irina Higgins, David Amos, David Pfau, Sebastien Racaniere, Loic Matthey, Danilo Rezende, and Alexander Lerchner. Towards a Definition of Disentangled Representations. arXiv:1812.02230 [cs, stat], December 2018a. URL http://arxiv.org/abs/1812.02230. arXiv: 1812.02230.
150
+
151
+ Irina Higgins, Arka Pal, Andrei A. Rusu, Loic Matthey, Christopher P. Burgess, Alexander Pritzel, Matthew Botvinick, Charles Blundell, and Alexander Lerchner. DARLA: Improving Zero-Shot Transfer in Reinforcement Learning. arXiv:1707.08475 [cs, stat], June 2018b. URL http: //arxiv.org/abs/1707.08475. arXiv: 1707.08475.
152
+
153
+ Irina Higgins, Nicolas Sonnerat, Loic Matthey, Arka Pal, Christopher P. Burgess, Matko Bosnjak, Murray Shanahan, Matthew Botvinick, Demis Hassabis, and Alexander Lerchner. SCAN: Learning Hierarchical Compositional Visual Concepts. arXiv:1707.03389 [cs, stat], June 2018c. URL http://arxiv.org/abs/1707.03389. arXiv: 1707.03389.
154
+
155
+ Felix Hill, Andrew Lampinen, Rosalia Schneider, Stephen Clark, Matthew Botvinick, James L. McClelland, and Adam Santoro. Environmental drivers of systematicity and generalization in a situated agent. arXiv:1910.00571 [cs], February 2020. URL http://arxiv.org/abs/1910. 00571. arXiv: 1910.00571.
156
+
157
+ Matthew D Hoffman and Matthew J Johnson. Elbo surgery: yet another way to carve up the variational evidence lower bound. In Workshop in Advances in Approximate Bayesian Inference, NIPS, volume 1, pp. 2, 2016.
158
+
159
+ J. E. Hummel. Localism as a first step toward symbolic representation. Behavioral and Brain Sciences, 23(4):480–481, December 2000. ISSN 0140-525X. doi: 10.1017/S0140525X0036335X.
160
+
161
+ John E Hummel and Irving Biederman. Dynamic binding in a neural network for shape recognition. Psychological review, 99(3):480, 1992.
162
+
163
+ Hyunjik Kim and Andriy Mnih. Disentangling by Factorising. arXiv:1802.05983 [cs, stat], July 2019. URL http://arxiv.org/abs/1802.05983. arXiv: 1802.05983.
164
+
165
+ Diederik P. Kingma and Jimmy Ba. Adam: A Method for Stochastic Optimization. arXiv:1412.6980 [cs], January 2017. URL http://arxiv.org/abs/1412.6980. arXiv: 1412.6980.
166
+
167
+ Diederik P. Kingma and Max Welling. Auto-Encoding Variational Bayes. arXiv:1312.6114 [cs, stat], December 2013. URL http://arxiv.org/abs/1312.6114. arXiv: 1312.6114.
168
+
169
+ Klaus Greff, Aaron Klein, Martin Chovanec, Frank Hutter, and Jürgen Schmidhuber. The Sacred Infrastructure for Computational Research. In Katy Huff, David Lippa, Dillon Niederhut, and M Pacer (eds.), Proceedings of the 16th Python in Science Conference, pp. 49 – 56, 2017. doi: 10.25080/shinma-7f4c6e7-008.
170
+
171
+ Brenden Lake and Marco Baroni. Generalization without Systematicity: On the Compositional Skills of Sequence-to-Sequence Recurrent Networks. In International Conference on Machine Learning, pp. 2873–2882. PMLR, July 2018. URL http://proceedings.mlr.press/v80/ lake18a.html. ISSN: 2640-3498.
172
+
173
+ Andrew K Lampinen and James L McClelland. Transforming task representations to allow deep learning models to perform novel tasks. arXiv preprint arXiv:2005.04318, 2020.
174
+
175
+ Francesco Locatello, Stefan Bauer, Mario Lucic, Gunnar Rätsch, Sylvain Gelly, Bernhard Schölkopf, and Olivier Bachem. Challenging Common Assumptions in the Unsupervised Learning of Disentangled Representations. pp. 11, 2019.
176
+
177
+ Gary Marcus. Deep learning: A critical appraisal. arXiv preprint arXiv:1801.00631, 2018.
178
+
179
+ Emile Mathieu, Tom Rainforth, N. Siddharth, and Yee Whye Teh. Disentangling Disentanglement in Variational Autoencoders. arXiv:1812.02833 [cs, stat], June 2019. URL http://arxiv. org/abs/1812.02833. arXiv: 1812.02833.
180
+
181
+ Loic Matthey, Irina Higgins, Demis Hassabis, and Alexander Lerchner. dSprites: Disentanglement testing Sprites dataset. 2017. URL https://github.com/deepmind/dsprites-dataset/.
182
+
183
+ James L McClelland, David E Rumelhart, PDP Research Group, and others. Parallel distributed processing. Explorations in the Microstructure of Cognition, 2:216–271, 1986. Publisher: MIT Press Cambridge, Ma.
184
+
185
+ Jeff Mitchell and Jeffrey S. Bowers. Harnessing the Symmetry of Convolutions for Systematic Generalisation. In 2020 International Joint Conference on Neural Networks (IJCNN), pp. 1–8, Glasgow, United Kingdom, July 2020. IEEE. ISBN 978-1-72816-926-2. doi: 10.1109/IJCNN48605. 2020.9207183. URL https://ieeexplore.ieee.org/document/9207183/.
186
+
187
+ Adam Paszke, Sam Gross, Francisco Massa, Adam Lerer, James Bradbury, Gregory Chanan, Trevor Killeen, Zeming Lin, Natalia Gimelshein, Luca Antiga, Alban Desmaison, Andreas Kopf, Edward Yang, Zachary DeVito, Martin Raison, Alykhan Tejani, Sasank Chilamkurthy, Benoit Steiner, Lu Fang, Junjie Bai, and Soumith Chintala. Pytorch: An imperative style, highperformance deep learning library. In H. Wallach, H. Larochelle, A. Beygelzimer, F. dAlché-Buc, E. Fox, and R. Garnett (eds.), Advances in Neural Information Processing Systems 32, pp. 8024–8035. Curran Associates, Inc., 2019. URL http://papers.neurips.cc/paper/ 9015-pytorch-an-imperative-style-high-performance-deep-learning-library. pdf.
188
+
189
+ F. Pedregosa, G. Varoquaux, A. Gramfort, V. Michel, B. Thirion, O. Grisel, M. Blondel, P. Prettenhofer, R. Weiss, V. Dubourg, J. Vanderplas, A. Passos, D. Cournapeau, M. Brucher, M. Perrot, and E. Duchesnay. Scikit-learn: Machine learning in Python. Journal of Machine Learning Research, 12:2825–2830, 2011.
190
+
191
+ Danilo Jimenez Rezende, Shakir Mohamed, and Daan Wierstra. Stochastic Backpropagation and Approximate Inference in Deep Generative Models. arXiv:1401.4082 [cs, stat], January 2014. URL http://arxiv.org/abs/1401.4082. arXiv: 1401.4082.
192
+
193
+ Adam Santoro, David Raposo, David G Barrett, Mateusz Malinowski, Razvan Pascanu, Peter Battaglia, and Timothy Lillicrap. A simple neural network module for relational reasoning. In I. Guyon, U. V. Luxburg, S. Bengio, H. Wallach, R. Fergus, S. Vishwanathan, and R. Garnett (eds.), Advances in Neural Information Processing Systems 30, pp. 4967–4976. Curran Associates, Inc., 2017. URL http://papers.nips.cc/paper/ 7082-a-simple-neural-network-module-for-relational-reasoning.pdf.
194
+
195
+ Paul Smolensky. The constituent structure of connectionist mental states: A reply to Fodor and Pylyshyn. Southern Journal of Philosophy, 26(Supplement):137–163, 1987. Publisher: Citeseer.
196
+
197
+ Paul Smolensky. Connectionism, constituency, and the language of thought. University of Colorado at Boulder, 1988.
198
+
199
+ S. Desroziers J. Kriss V. Fomin, J. Anmol and A. Tejani. High-level library to help with training neural networks in pytorch. https://github.com/pytorch/ignite, 2020.
200
+
201
+ Sjoerd van Steenkiste, Jürgen Schmidhuber, Francesco Locatello, and Olivier Bachem. Are Disentangled Representations Helpful for Abstract Visual Reasoning? pp. 14, 2019.
202
+
203
+ Ivan I. Vankov and Jeffrey S. Bowers. Training neural networks to encode symbols enables combinatorial generalization. Philosophical Transactions of the Royal Society B: Biological Sciences, 375(1791):20190309, February 2020. doi: 10.1098/rstb.2019.0309. URL https: //royalsocietypublishing.org/doi/10.1098/rstb.2019.0309. Publisher: Royal Society.
204
+
205
+ Nicholas Watters, Loic Matthey, Christopher P. Burgess, and Alexander Lerchner. Spatial Broadcast Decoder: A Simple Architecture for Learning Disentangled Representations in VAEs. arXiv:1901.07017 [cs, stat], August 2019. URL http://arxiv.org/abs/1901.07017. arXiv: 1901.07017.
206
+
207
+ Shengjia Zhao, Hongyu Ren, Arianna Yuan, Jiaming Song, Noah Goodman, and Stefano Ermon. Bias and Generalization in Deep Generative Models: An Empirical Study. arXiv:1811.03259 [cs, stat], November 2018. URL http://arxiv.org/abs/1811.03259. arXiv: 1811.03259.
208
+
209
+ # A MODELS AND TRAINING
210
+
211
+ For our experiments on the standard unsupervised task we used two different VAE architectures. The first one is the same found in Higgins et al. (2017) and uses a 2-layer MLP as an encoder with 1200 units and ReLU non-linearity. The decoder is a 3-layer with the same number of units and the Tanh non-linearity. The second architecture is the one found in Burgess et al. (2018) and consists of a 3-layer CNN with $3 2 \times 4 \times 2 \times 1$ convolutions and max pooling, followed by a 2-layer MLP with 256 units in each layer. The decoder is defined to be the transpose of this architecture. ReLU non-linearity where applied after each layer of the CNN and the MLP for both the encoder and the decoder. Both models used a Gaussian stochastic layer with 10 units as in the original papers.
212
+
213
+ We also tested two variants of this last architecture, one found in Mathieu et al. (2019) which changes the shape of the convolution and another with batch normalisation. Neither variant exhibited any improvements to disentanglement or reconstruction on the full dSprite data and so were not included in the rest of the experiments.
214
+
215
+ For the image composition task we used same as in Burgess et al. (2018) that we described above. The latent transformation layer was parameterized as:
216
+
217
+ $$
218
+ h _ { t r a n s f o r m e d } = W _ { r } c a t [ z _ { r } ; a c t i o n ] + W _ { t } c a t [ z _ { t } ; a c t i o n ]
219
+ $$
220
+
221
+ where $z _ { r }$ and $z _ { t }$ are the samples from the stochastic layer for reference and transform image, cat is the concatenation operation performed along the column dimension. The output is another 10- dimensional vector with the transformed latent code.
222
+
223
+ Alternatively we also tried a 3 layer MLP with 100 hidden units, but saw no benefit in performance and decreased disentanglement when trainined on the full dataset.
224
+
225
+ Training on the unsupervised tasks ran for 100 epochs for dSprites and 65 epochs for Shapes3D, even though models converged before the end. The learning rate was fixed at $1 e - 4$ and the batch size at 64. $\beta$ values used were 1, 4, 8, 12, 16 on the full dSprite dataset. $\beta = 4$ and $\beta = 1 6$ where not included in the rest of the experiments since the former offered very little disentanglement and the latter very large reconstruction error. For the FactorVAE we used $\gamma = 2 0 , 5 0 , 1 0 ( $ 0 throughout. In the composition task the models where trained for 100 epochs with $\beta = 1$ . Using $\beta$ higher than 1 interfered with the model’s ability to solve the task so they where not used.
226
+
227
+ For the ground-truth decoders (GT Decoder) we used the same MLP decoder of Higgins et al. (2017) mentioned above. Using deeper decoders with convolutions with/without batch norm after each layer was also tested, but did not provide significan benefits and also decreased the performance on some of the conditions.
228
+
229
+ All the models where implemented in PyTorch (Paszke et al., 2019) and the experiments where performed using the Ignite and Sacred frameworks (V. Fomin & Tejani, 2020; Klaus Greff et al., 2017).
230
+
231
+ To measure disentanglement we used the framework proposed by Eastwood & Williams (2018) with a slight modification. The approach consists of predicting each generative factor value, given the latent representations of the training images using a non-linear model. In our case we used the LassoCV regression found in the Sklearn library (Pedregosa et al., 2011) with an $\alpha$ coefficient of 0.01 and 5 cross-validation partitions. Deviating from the original proposal, we do not normalize the inputs to the regression model since we found that this tends to give a lot of weight to dead units (when measured by their KL divergence). This is likely due to the model “killing” these units during training after they start with a high KL value, which might not completely erase the information they carry about a given generative factor.
232
+
233
+ Working code for running these experiments and analyses can be downloaded at https://github.
234
+ com/mmrl/disent-and-gen.
235
+
236
+ ![](images/98899b7b56cb657c7ea909545bac26e823d256b0ca358c413d51c219a88916e9.jpg)
237
+ Figure 7: Disentanglement scores for dSprites. The disentanglement analysis results for the dSprites dataset. The scores for each of the metrics evaluated by the DCI framework: disentanglement (left), overall disentanglement (middle) and completeness (right) for each of the conditions.
238
+
239
+ ![](images/35fd2b6c5a8196f41ce6b7417a0dfc6586e49c368fdd2291b206667bdd875379.jpg)
240
+ Figure 8: Hinton diagrams for dSprites dataset. The matrices of coefficients computed by the framework plotted as Hinton diagrams. These are used to obtain the quantitative scores in the panel above. They offer a qualitative view of how the model is disentangling. On the left is how perfect disentanglement looks in this framework.
241
+
242
+ ![](images/7292bb6dbe356dc3bede6b5ef0f2d3a2c9022db7e698af6e18364a37af9bc305.jpg)
243
+ Figure 9: Reconstructions for the dSprites dataset. For each condition and model, these are some reconstruction examples for both training and testing. There is general success and failure in the Recombination to Element (top) and Extrapolation (bottom) conditions, respectively. For this last condition, the models seem to reproduce the closest instance they have seen, which tranlated to the middle of the image. For the Recombination to range (middle), the models tend to resort to generating a blob at the right location, minimising their pixel-level error.
244
+
245
+ C EXTRA PLOTS FOR THE 3D SHAPES DATASET
246
+
247
+ ![](images/baaa266eeaa0212d321df4cadff20b070c0163db5049381f75728082bf6b5995.jpg)
248
+ Figure 10: Disentanglement analysis for Shapes3D. The disentanglement analysis results for the 3D Shapes dataset. The scores for each of the metrics evaluated by the DCI framework (Eastwood & Williams, 2018): disentanglement (left), overall disentanglement (middle) and completeness (right) for each of the conditions.
249
+
250
+ ![](images/c29401e333f93fbd80986c93ebbb886d5d94d1bb411ee79c5a12c4389b344470.jpg)
251
+ Figure 11: Hinton diagrams for 3DShapes dataset. The matrices of coefficients computed by the framework plotted as Hinton Diagrams. As discussed in the main text, these matrices offer a qualitative view of how the model is disentangling. In general, sparse matrices indicate higher disentanglement. It is clear from these diagrams that the degree of disentanglement varies over a broad range for the tested models.
252
+
253
+ ![](images/7c01a7e17a903b7d9fb9bcda6bc84f0a1ec45a4f77a02f5a1600deaf86a14114.jpg)
254
+ Figure 12: Reconstructions for the Shapes3D dataset. For each condition and model, these are some reconstruction examples for both training (left) and testing (right). In each case, the input image is shown in the left-most column and each subsequent column shows reconstruction by a different model. The test images always show a combination that was left out during training. All training images are successfully reproduced. However, reconstruction for test images only succeeds consistently for the Recombination-to-Element condition (top). All reconstructions fail in the Extrapolation condition (bottom) while most of them fail for the Recombination-to-Range condition (middle). There are occasional instances in Recombination-to-Range condition that seem to correctly reconstruct the input image. This seems to happen when the novel combination for color and shape is closest to the ones the model has experienced during training. For example, models are better when the oblong shape is paired with cyan (which is close to green, which it has seen) and worse on magenta.
parse/train/qbH974jKUVy/qbH974jKUVy_content_list.json ADDED
@@ -0,0 +1,1422 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [
2
+ {
3
+ "type": "text",
4
+ "text": "THE ROLE OF DISENTANGLEMENT IN GENERALISATION ",
5
+ "text_level": 1,
6
+ "bbox": [
7
+ 174,
8
+ 99,
9
+ 839,
10
+ 121
11
+ ],
12
+ "page_idx": 0
13
+ },
14
+ {
15
+ "type": "text",
16
+ "text": "Milton L. Montero1,2, Casimir J.H. Ludwig 1, Rui Ponte Costa2, Gaurav Malhotra1 & Jeffrey S. Bowers 1 ",
17
+ "bbox": [
18
+ 181,
19
+ 143,
20
+ 915,
21
+ 160
22
+ ],
23
+ "page_idx": 0
24
+ },
25
+ {
26
+ "type": "text",
27
+ "text": "1. School of Psychological Science \n2. Computational Neuroscience Unit, Department of Computer Science \nUniversity of Bristol \nBristol, United Kingdom \n{m.lleramontero,c.ludwig,rui.costa,gaurav.malhotra,j.bowers}@bristol.ac.uk ",
28
+ "bbox": [
29
+ 184,
30
+ 160,
31
+ 844,
32
+ 228
33
+ ],
34
+ "page_idx": 0
35
+ },
36
+ {
37
+ "type": "text",
38
+ "text": "ABSTRACT ",
39
+ "text_level": 1,
40
+ "bbox": [
41
+ 454,
42
+ 265,
43
+ 544,
44
+ 281
45
+ ],
46
+ "page_idx": 0
47
+ },
48
+ {
49
+ "type": "text",
50
+ "text": "Combinatorial generalisation — the ability to understand and produce novel combinations of familiar elements — is a core capacity of human intelligence that current AI systems struggle with. Recently, it has been suggested that learning disentangled representations may help address this problem. It is claimed that such representations should be able to capture the compositional structure of the world which can then be combined to support combinatorial generalisation. In this study, we systematically tested how the degree of disentanglement affects various forms of generalisation, including two forms of combinatorial generalisation that varied in difficulty. We trained three classes of variational autoencoders (VAEs) on two datasets on an unsupervised task by excluding combinations of generative factors during training. At test time we ask the models to reconstruct the missing combinations in order to measure generalisation performance. Irrespective of the degree of disentanglement, we found that the models supported only weak combinatorial generalisation. We obtained the same outcome when we directly input perfectly disentangled representations as the latents, and when we tested a model on a more complex task that explicitly required independent generative factors to be controlled. While learning disentangled representations does improve interpretability and sample efficiency in some downstream tasks, our results suggest that they are not sufficient for supporting more difficult forms of generalisation. ",
51
+ "bbox": [
52
+ 233,
53
+ 296,
54
+ 764,
55
+ 560
56
+ ],
57
+ "page_idx": 0
58
+ },
59
+ {
60
+ "type": "text",
61
+ "text": "1 INTRODUCTION ",
62
+ "text_level": 1,
63
+ "bbox": [
64
+ 176,
65
+ 587,
66
+ 334,
67
+ 603
68
+ ],
69
+ "page_idx": 0
70
+ },
71
+ {
72
+ "type": "text",
73
+ "text": "Generalisation to unseen data has been a key challenge for neural networks since the early days of connectionism, with considerable debate about whether these models can emulate the kinds of behaviours that are present in humans (McClelland et al., 1986; Fodor & Pylyshyn, 1988; Smolensky, 1987; 1988; Fodor & McLaughlin, 1990). While the modern successes of Deep Learning do indeed point to impressive gains in this regard, human level generalisation still remains elusive (Lake & Baroni, 2018; Marcus, 2018). One explanation for this is that humans encode stimuli in a compositional manner, with a small set of independent and more primitive features (e.g., separate representations of size, position, line orientation, etc.) being used to build more complex representation (e.g., a square of a given size and position). The meaning of the more complex representation comes from the meaning of it’s parts. Critically, compositional representations afford the ability to recombine primitives in novel ways: if a person has learnt to recognize squares and circles in context where all squares are blue and all circles are red, they can nevertheless also recognise red squares, even though they have never seen these in the training data. This ability to perform combinatorial generalisation based on compositional representations is thought to be a hallmark of human level intelligence (Fodor & Pylyshyn, 1988) (See McClelland et al. (1986) for a diverging opinion). ",
74
+ "bbox": [
75
+ 174,
76
+ 618,
77
+ 825,
78
+ 827
79
+ ],
80
+ "page_idx": 0
81
+ },
82
+ {
83
+ "type": "text",
84
+ "text": "Recently it has been proposed that generalisation in neural networks can be improved by extracting disentangled representations (Higgins et al., 2017) from data using (variational) generative models (Kingma & Welling, 2013; Rezende et al., 2014). In this view, disentangled representations capture the compositional structure of the world (Higgins et al., 2018a; Duan et al., 2020), separating the generative factors present in the stimuli into separate components of the internal representation (Higgins et al., 2017; Burgess et al., 2018). It has been argued that these representations allow downstream models to perform better due to the structured nature of the representations (Higgins et al., 2017; 2018b) and to share information across related tasks (Bengio et al., 2014). Here we are interested in the question of whether networks can support combinatorial generalisation and extrapolation by exploiting these disentangled representations. ",
85
+ "bbox": [
86
+ 174,
87
+ 834,
88
+ 823,
89
+ 917
90
+ ],
91
+ "page_idx": 0
92
+ },
93
+ {
94
+ "type": "text",
95
+ "text": "",
96
+ "bbox": [
97
+ 174,
98
+ 103,
99
+ 823,
100
+ 159
101
+ ],
102
+ "page_idx": 1
103
+ },
104
+ {
105
+ "type": "text",
106
+ "text": "In this study we systematically tested whether and how disentangled representations support three forms of generalisation: two forms of combinatorial generalisation that varied in difficulty as well as extrapolation, as detailed below. We explored this issue by assessing how well models could render images when we varied (1) the image datasets (dSprites and 3DShape), (2) the models used to reconstruct these images ( $\\beta$ -VAEs and FactorVAEs with different disentanglement pressures, and decoder models in which we dropped the encoders and directly input perfectly disentangled latents), and (3) the tasks that varied in their combinatorial requirements (image reconstruction vs. image transformation). Across all conditions we found that models only supported the simplest versions of combinatorial generalisation and the degree of disentanglement had no impact on the degree of generalisation. These findings suggest that models with entangled and disentangled representations are both generalising on the basis of overall similarity of the trained and test images (interpolation), and that combinatorial generalisation requires more than learning disentangled representations. ",
107
+ "bbox": [
108
+ 174,
109
+ 166,
110
+ 825,
111
+ 333
112
+ ],
113
+ "page_idx": 1
114
+ },
115
+ {
116
+ "type": "text",
117
+ "text": "1.1 PREVIOUS WORK ",
118
+ "text_level": 1,
119
+ "bbox": [
120
+ 176,
121
+ 349,
122
+ 336,
123
+ 364
124
+ ],
125
+ "page_idx": 1
126
+ },
127
+ {
128
+ "type": "text",
129
+ "text": "Recent work on learning disentangled representations in unsupervised generative models has indeed shown some promise in improving the performance of downstream tasks (Higgins et al., 2018b; van Steenkiste et al., 2019) but this benefit is mainly related to sample efficiency rather than generalisation. Indeed, we are only aware of two studies that have considered the importance of learned disentanglement for combinatorial generalisation and they have used different network architectures and have reached opposite conclusions. Bowers et al. (2016) showed that a recurrent model of shortterm memory tested on lists of words that required some degree of combinatorial generalisation (recalling a sequence of words when one or more of words at test were novel) only succeeded when it had learned highly selective (disentangled) representations (\"grandmother cell\" units for letters). By contrast, Chaabouni et al. (2020) found that models with disentangled representations do not confer significant improvements in generalisation over entangled ones in a language modeling setting, with both entangled and disentangled representations supporting combinatorial generalisation as long as the training set was rich enough. At the same time, they found that languages generated through compositional representations were easier to learn, suggesting this as a pressure to learn disentangled representations. ",
130
+ "bbox": [
131
+ 174,
132
+ 376,
133
+ 825,
134
+ 584
135
+ ],
136
+ "page_idx": 1
137
+ },
138
+ {
139
+ "type": "text",
140
+ "text": "A number of recent papers have reported that VAEs can support some degree of combinatorial generalisation, but there is no clear understanding of whether and how disentangled representations played any role in supporting this performance. Esmaeili et al. (2019) showed that a model trained on the MNIST dataset could reconstruct images even when some particular combination of factors were removed during training, such as a thick number 7 or a narrow 0. The authors also showed that the model had learned disentangled representations and concluded that the disentangled representations played a role in the successful performance. However, the authors did not vary the degree of disentanglement in their models and, accordingly, it is possible that a VAE that learned entangled representations would do just as well. Similarly, Higgins et al. (2018c) have highlighted how VAEs that learn disentangled representations can support some forms of combinatorial generalisation when generating images from text. For example, their model could render a room with white walls, pink floor and blue ceiling even though it was never shown that combination in the training set. This is an impressive form of combinatorial generalisation but, as we show below, truly compositional representations should be able to support several other forms of combinatorial generalisations that were not tested in this study. Moreover, it is not clear what role disentanglement played in this successful instance of generalisation. Finally, Zhao et al. (2018) assessed VAE performance on a range of combinatorial generalisation tasks that varied in difficulty, and found that the model performed well in the simplest settings but struggled in more difficult ones. But again, they did not consider whether learning disentangled representations was relevant to generalisation performance. ",
141
+ "bbox": [
142
+ 174,
143
+ 590,
144
+ 825,
145
+ 854
146
+ ],
147
+ "page_idx": 1
148
+ },
149
+ {
150
+ "type": "text",
151
+ "text": "Another work that has significant relation to ours is Locatello et al. (2019), who examine how hard it is to learn disentangled representations and their relation to sampling efficiency for downstream tasks. We are interested in a related, but different question: even if a model learns a disentangled representation in an intermediate layer, does this enable models to achieve combinatorial generalisation? So while Locatello et al. (2019) train their models on complete datasets to investigate the degree of disentanglement and sampling efficiency, we systematically exclude generative factors from training in order to test for combinatorial generalisation (see Methods and Results). ",
152
+ "bbox": [
153
+ 176,
154
+ 862,
155
+ 823,
156
+ 917
157
+ ],
158
+ "page_idx": 1
159
+ },
160
+ {
161
+ "type": "image",
162
+ "img_path": "images/ca12adc3248df5e251d862bb3d9849c826f1d614a761c14d95ac7b90aa86f9d1.jpg",
163
+ "image_caption": [
164
+ "Figure 1: Testing generalisation in image reconstruction. (a) An illustration of different tests of combinatorial generalisation for the three-dimensional case (i.e., three generative factors). The blank cells represent combinations that the model is trained on. Coloured cells represent novel test combinations that probe different forms of generalisation: Recombination-to-Element (red), Recombination-to-Range (green) and Extrapolation (blue) – see main text for details. (b) Each row shows an example of training and test stimuli for testing a form of generalisation. In the top row, training set excludes ellipses in the bottom-right corner at less than $1 2 0 ^ { \\circ }$ though they are present at the bottom-right corner at other rotations. In the middle row, training set excludes squares in the right side of the image though other shapes and rotations are present at this location and squares are seen at all other combinations of rotations and translations. In the bottom row, training set excludes all shapes on the right side of the image. "
165
+ ],
166
+ "image_footnote": [],
167
+ "bbox": [
168
+ 173,
169
+ 99,
170
+ 826,
171
+ 279
172
+ ],
173
+ "page_idx": 2
174
+ },
175
+ {
176
+ "type": "text",
177
+ "text": "",
178
+ "bbox": [
179
+ 173,
180
+ 465,
181
+ 823,
182
+ 508
183
+ ],
184
+ "page_idx": 2
185
+ },
186
+ {
187
+ "type": "text",
188
+ "text": "2 METHODS AND RESULTS ",
189
+ "text_level": 1,
190
+ "bbox": [
191
+ 176,
192
+ 527,
193
+ 413,
194
+ 544
195
+ ],
196
+ "page_idx": 2
197
+ },
198
+ {
199
+ "type": "text",
200
+ "text": "We assessed combinatorial generalisation on two different datasets. The dSprites image dataset (Matthey et al., 2017) contains 2D images in black and white that vary along five generative factors: shape, scale, orientation, position- $\\times$ and position-y and focuses on manipulations of single objects. The 3D Shapes dataset (Burgess & Kim, 2018) contains 3D images in colour that vary along six generative factors: floor-hue, wall-hue, object-hue, object-shape, object-scale, object-orientation. In contrast to dSprites, the images are more realistic, which has been shown to aid reconstruction performance (Locatello et al., 2019). To test combinatorial generalisation, we systematically excluded some combinations of these generative factors from the training data and tested reconstruction on these unseen values. Test cases can be divided into three broad categories based on the number of combinations excluded from training. ",
201
+ "bbox": [
202
+ 173,
203
+ 559,
204
+ 825,
205
+ 699
206
+ ],
207
+ "page_idx": 2
208
+ },
209
+ {
210
+ "type": "text",
211
+ "text": "• Recombination-to-Element (red squares in Figure 1): The model has never been trained on one combination of all of the generative factors. In dSprites, an example of this case would be excluding the combination: [shape=ellipse, scale=1, orientation $< ~ 1 2 0 ^ { \\circ }$ , position- $\\mathsf { x } { > } \\Theta . 5$ , position$y > 0 . 5 ]$ from the training set – i.e. the model has never seen a large ellipse at $< ~ 1 2 0 ^ { \\circ }$ in the bottom-right corner, though it has seen all other combinations. ",
212
+ "bbox": [
213
+ 174,
214
+ 710,
215
+ 825,
216
+ 781
217
+ ],
218
+ "page_idx": 2
219
+ },
220
+ {
221
+ "type": "text",
222
+ "text": "• Recombination-to-Range (green squares in Figure 1): The model has never been trained on all combinations of some of the factors (i.e. a subset of generative factors). For example, in the 3D Shapes dataset, all combinations with [object-hue $^ { = 1 }$ , shap $: = \\mathfrak { s }$ sphere] have been left out of the training set – i.e. none of the training images contain a blue sphere. This condition is more complex than Recombination-to-Element as an entire range of combinations [floor-hue=0. . . 1, wall-hue=0. . . 1, ob ject-hue=1, shape=sphere, scale=0. . . 1, orientation=0. . . 1] have been left out (here bold text indicates the range of values excluded). When the number of generative factors is larger than three, “Recombination-to-Range” is, in fact, a set of conditions that vary in difficulty, depending upon how many generative factors have been excluded. Another example would be excluding all combinations where [floor-hue=1, wall-hue=1, object-hue=1, shape=1, scale=1]. Here a smaller range of combinations [floor-hue=1, wall-hue=1, object-hue $^ { = 1 }$ , shape $^ { = 1 }$ , scale=1, orientation=0. . . 1] have been excluded. ",
223
+ "bbox": [
224
+ 178,
225
+ 785,
226
+ 825,
227
+ 924
228
+ ],
229
+ "page_idx": 2
230
+ },
231
+ {
232
+ "type": "text",
233
+ "text": "",
234
+ "bbox": [
235
+ 183,
236
+ 106,
237
+ 823,
238
+ 131
239
+ ],
240
+ "page_idx": 3
241
+ },
242
+ {
243
+ "type": "text",
244
+ "text": "• Extrapolation (blue squares in Figure 1): This is the most challenging form of generalisation where models are tested on values of generative factors that are beyond the range of values observed in the training dataset. For example, in the dSprites dataset, all combinations where [posi tion- $\\times > 0 . 5 ]$ have never been seen. ",
245
+ "bbox": [
246
+ 176,
247
+ 136,
248
+ 823,
249
+ 191
250
+ ],
251
+ "page_idx": 3
252
+ },
253
+ {
254
+ "type": "text",
255
+ "text": "Each of these conditions is interesting for different reasons. A model that learns compositional representations should be able to combine observed values of shape (ellipses), translation (bottom-right) and rotation $0 ^ { \\circ }$ to $1 2 0 ^ { \\circ }$ ) to generalise to all unseen combination of factors. The simplest case is the recombination-to-element condition in which all combinations but one have been trained, but a model that learns entangled representations might also succeed based on its training on highly similar patterns (generalisation by interpolation). A more challenging case is recombination-to-range condition given that more combinations have been excluded, making generalisation by similarity (interpolation) more difficult. The final condition is not a form of combinatorial generalisation as the model cannot combine observed values of generative factors to render images. Indeed compositional representations may be inadequate for this form of generalisation. ",
256
+ "bbox": [
257
+ 174,
258
+ 205,
259
+ 825,
260
+ 344
261
+ ],
262
+ "page_idx": 3
263
+ },
264
+ {
265
+ "type": "text",
266
+ "text": "2.1 IMAGE RECONSTRUCTION WITH DSPRITES DATASET",
267
+ "text_level": 1,
268
+ "bbox": [
269
+ 174,
270
+ 362,
271
+ 573,
272
+ 376
273
+ ],
274
+ "page_idx": 3
275
+ },
276
+ {
277
+ "type": "text",
278
+ "text": "In the dSprites dataset, for testing the Recombination-to-element case, we split each range of values of a generative factor into three bins, so that we had $3 \\times 3 \\times 3 \\times 3 \\times 3$ such combinations of bins for all five generative factors. We then remove one of these 243 combinations during training, namely those that satisfied [shap ${ \\tt : e }$ llipsis, position- $\\ X \\ > = \\ 0 . 6$ , , position- $y ~ > = ~ 0 . 6$ , $1 2 0 ^ { \\circ } < =$ rotation $\\angle = 2 4 0 ^ { \\circ }$ , scale $< ~ 0 . 6 1$ . In other words ellipses in the bottom right corner with those given rotations, which is a relatively small number of combinations that are all very similar to each other. ",
279
+ "bbox": [
280
+ 174,
281
+ 387,
282
+ 825,
283
+ 470
284
+ ],
285
+ "page_idx": 3
286
+ },
287
+ {
288
+ "type": "text",
289
+ "text": "For the Recombination-to-range case, we tested three different variants. First, we excluded all combinations where [shape $! = !$ square, position- $\\mathsf { x } { \\mathsf { > } } \\Theta . 5 ]$ . The model sees other shapes at those positions during training and it sees squares on the left-hand side of the screen. Thus the models experiences both generative factor values independently and has to recombine them to produce a novel image at test time. In the second case, we excluded all combinations where [shape=square, $\\mathsf { s c a l e } { \\mathsf { > } } \\Theta . 5 ]$ . In the third case, we excluded all combinations where [shape=square, rotation $> 9 0 ^ { \\circ } ]$ ]. We observed very similar results for all three cases and below we report the results for the first variant. ",
290
+ "bbox": [
291
+ 174,
292
+ 478,
293
+ 825,
294
+ 575
295
+ ],
296
+ "page_idx": 3
297
+ },
298
+ {
299
+ "type": "text",
300
+ "text": "Finally, for the Extrapolation case, we excluded all combinations of generative factors where [po sition- $\\times \\ > x ]$ . We chose a set of different values for $x$ : $x ~ \\in ~ 0 . 1 6 , 0 . 2 5 , 0 . 5 0 , 0 . 7 5$ , where $x$ is normalised in the range $[ 0 , 1 ]$ (results shown in Figure 2 for $x = 0 . 5 0 $ ). At test time the model needed to reconstruct images where translation along the $\\mathbf { X }$ -axis, $x$ , was greater than the cutoff value. ",
301
+ "bbox": [
302
+ 174,
303
+ 583,
304
+ 825,
305
+ 651
306
+ ],
307
+ "page_idx": 3
308
+ },
309
+ {
310
+ "type": "text",
311
+ "text": "We tested three classes of models on all three types of generalisation: standard Variational Autoencoder (VAEs, Kingma & Welling (2013); Rezende et al. (2014)), $\\beta$ -VAE (Higgins et al., 2017; Burgess et al., 2018) with $\\beta = 8$ and $\\beta = 1 2$ , FactorVAE (Kim & Mnih, 2019) with $\\gamma = 2 0$ , $\\gamma = 5 0$ and $\\gamma = 1 0 0$ . The architectures are the ones found in Higgins et al. (2017), Burgess et al. (2018) and Kim & Mnih (2019) (Details in the Appendix). We used a batch size of 64 and a learning rate of $5 e - 4$ for the Adam optimizer (Kingma & Ba, 2017). In each case, we simulated three seeds and we report results for runs where we obtained largest disentanglement. ",
312
+ "bbox": [
313
+ 174,
314
+ 659,
315
+ 825,
316
+ 757
317
+ ],
318
+ "page_idx": 3
319
+ },
320
+ {
321
+ "type": "text",
322
+ "text": "As shown by Locatello et al. (2019), none of the models trained end-to-end in an unsupervised manner produce perfectly disentangled representations. Since we were interested in studying the effect of disentanglement on generalisation, we compared our results with a model where we removed the encoder and directly gave disentangled latents as inputs to the decoder. We call this model the ground-truth decoder (GT Decoder from here on). This decoder uses the same MLP architecture as the one used in Higgins et al. (2017). We tested deeper decoders with convolutions and batch norm as well, but found no benefit or a decrease in performance. ",
323
+ "bbox": [
324
+ 174,
325
+ 763,
326
+ 823,
327
+ 861
328
+ ],
329
+ "page_idx": 3
330
+ },
331
+ {
332
+ "type": "text",
333
+ "text": "We measured the level of disentanglement using the framework introduced in Eastwood & Williams (2018). The procedure consists of using the latent representations generated for each image to predict the true generative factors using a regression model (in our case, Lasso regression; see Appendix A). The level of disentanglement is quantified by their ‘Overall disentanglement metric’, which we call D-score here. ",
334
+ "bbox": [
335
+ 176,
336
+ 868,
337
+ 823,
338
+ 910
339
+ ],
340
+ "page_idx": 3
341
+ },
342
+ {
343
+ "type": "image",
344
+ "img_path": "images/5f366e82e8ceb5c74b34978ae9c4c111df55825f734284f6b060c86c3a740588.jpg",
345
+ "image_caption": [
346
+ "Figure 2: Image reconstruction and disentanglement for the dSprites dataset (a) Top row shows examples of input images and the four rows below show reconstructions by four different models. Three pairs of columns show reconstructions in training and test conditions. Left) Recombinationto-Element condition where the models did not see [shape $=$ ellipse, scale $= 1$ , orientation $< 1 2 0 ^ { \\circ }$ , po sition- $\\times \\ > 0 . 5$ , position- $\\mathsf { y } > 0 . 5 \\mathsf { l }$ , Middle) Recombination-to-Range condition where models did not see [shape $=$ square, position- $\\times ~ > 0 . 5 ]$ , Right) Extrapolation condition where models did not see [posi tion- $\\times > \\Theta . 5 ]$ (b) Visualisation of disentanglement. In each panel, columns show latent variables and rows show the generative factors. The size of the square represents the relative importance of the latent variable for predicting the generative factor. Sparse matrices indicate higher disentanglement (Eastwood & Williams, 2018). Each disentanglement matrix corresponds to the model on that row in (a) in the Reconstruction-to-Range condition. The visualisation of the entire set of models and all conditions is shown in Appendix B "
347
+ ],
348
+ "image_footnote": [],
349
+ "bbox": [
350
+ 174,
351
+ 98,
352
+ 826,
353
+ 381
354
+ ],
355
+ "page_idx": 4
356
+ },
357
+ {
358
+ "type": "text",
359
+ "text": "",
360
+ "bbox": [
361
+ 176,
362
+ 587,
363
+ 821,
364
+ 614
365
+ ],
366
+ "page_idx": 4
367
+ },
368
+ {
369
+ "type": "text",
370
+ "text": "Figure 2 shows examples of model reconstructions for each of the conditions which help assess the reconstruction success qualitatively (more examples are shown in Appendix C). A more quantitative assessment of the models can be made by examining the negative-log-likelihood of reconstructions for different conditions, plotted in Figure 3. The amount of disentanglement achieved by the models trained end-to-end varied over a broad range and was a function of model architecture and the hyperparameter ( $\\beta$ and $\\gamma$ ) values. In general, reconstruction accuracy was better for smaller values of $\\beta$ both during training and testing. This has been observed before and is a known issue encountered when increasing the value of $\\beta$ parameter (Hoffman & Johnson, 2016). We found that models were able to perform the Recombination-to-Element generalisation but failed in the Recombination-toRange and Extrapolation cases. In these cases, models either showed really poor reconstruction of the critical element or substituted one of the excluded combination with a combination that had been observed during training (see reconstructions for test cases in Figure 2(a)). Moreover, the amount of generalisation did not depend on the degree of disentanglement. Indeed, the GT Decoder using perfectly disentangled representations was no better than the end-to-end models. Even though this model achieved a lower NLL score, examining the image reconstructions showed that it failed to reconstruct the essential combination excluded from the training data (see Appendix B). ",
371
+ "bbox": [
372
+ 173,
373
+ 622,
374
+ 825,
375
+ 843
376
+ ],
377
+ "page_idx": 4
378
+ },
379
+ {
380
+ "type": "text",
381
+ "text": "The Recombination-to-Range condition shows another interesting qualitative difference between the entangled and disentangled models. All models failed to generalise, but in different ways. Entangled models tended to put a blob in the correct location, which allows them to minimise loss in pixel space over a large set of test examples. In contrast, the models with higher level of disentanglement fell back to the most similar shape (in pixel space) that they had seen at that location. ",
382
+ "bbox": [
383
+ 174,
384
+ 851,
385
+ 823,
386
+ 921
387
+ ],
388
+ "page_idx": 4
389
+ },
390
+ {
391
+ "type": "image",
392
+ "img_path": "images/f3627aebf672b8c0b003ae2ccd960ee5dddcb4d01b4ad62c89c85e862b770c3c.jpg",
393
+ "image_caption": [
394
+ "Figure 3: Disentanglement vs reconstruction NLL. The relation between the level of disentanglement and the performance of the model. Performance of the training data is plotted along with performance in the test (generalisation) data. Disentanglement does not provide any help in performance for the end-to-end models. The ground truth decoder (GTD) is less affected, yet it is still the case that it fails to generalize (see Figure 2 and Figure 4). "
395
+ ],
396
+ "image_footnote": [],
397
+ "bbox": [
398
+ 171,
399
+ 95,
400
+ 825,
401
+ 268
402
+ ],
403
+ "page_idx": 5
404
+ },
405
+ {
406
+ "type": "text",
407
+ "text": "Finally, the Recombination-to-Element condition was solved by all the models, regardless of disentanglement score. In fact, the entangled models tended to achieve better reconstructions as evidenced by the disentangled models with $\\beta { = } 1 2$ which had a hard time reconstructing ellipses at small scales and tended to just produce a circle instead. ",
408
+ "bbox": [
409
+ 174,
410
+ 368,
411
+ 825,
412
+ 424
413
+ ],
414
+ "page_idx": 5
415
+ },
416
+ {
417
+ "type": "text",
418
+ "text": "The second panel in Figure 2 shows the coefficients computed by the disentanglement metric for the Reconstruction-to-Range condition. The size of each square denotes the relative importance of a latent (column) in predicting the corresponding generative factor (row). The higher the disentanglement, the sparser the matrices. An examination of these matrices revealed that different models achieved a large range of disentanglement though none of the end-to-end models achieved perfect disentanglement. ",
419
+ "bbox": [
420
+ 174,
421
+ 431,
422
+ 825,
423
+ 515
424
+ ],
425
+ "page_idx": 5
426
+ },
427
+ {
428
+ "type": "text",
429
+ "text": "2.2 IMAGE RECONSTRUCTION WITH 3D SHAPES DATASET ",
430
+ "text_level": 1,
431
+ "bbox": [
432
+ 174,
433
+ 531,
434
+ 588,
435
+ 546
436
+ ],
437
+ "page_idx": 5
438
+ },
439
+ {
440
+ "type": "text",
441
+ "text": "The procedure for testing on the 3D Shapes dataset parallels the dSprites dataset above. The 3D Shapes dataset has six generative factors: floor-hue, wall-hue, object-hue, object-shape, object-scale, object-orientation. For the Recombination-to-Element condition, we excluded one combination from training: [floor-hue $> 0 . 5$ , wall-hue $> 0 . 5$ , object-hue $> 0 . 5$ , object-shape=cylinder, object-scale=1, object-orientation $\\scriptstyle 1 = 0$ ]. For the Recombination-to-Range condition, we excluded all combinations where [object-hue $> = 0 . 5$ (cyan), object-shape $=$ oblong] and trained all other combinations. This means that the models saw several combinations where object-hue was $> = 0 . 5$ and where object-shape was oblong but never the combination together. For the Extrapolation condition, we excluded all combinations where [floor-hue $> = 0 . 5 ]$ ]. ",
442
+ "bbox": [
443
+ 174,
444
+ 558,
445
+ 825,
446
+ 683
447
+ ],
448
+ "page_idx": 5
449
+ },
450
+ {
451
+ "type": "text",
452
+ "text": "We trained the same set of six end-to-end models as above as well as the GT Decoder. All endto-end models were trained for 65 epochs (around 500000 iterations as in the original articles), while the GT Decoder was trained for 1000 epochs. Reconstructions for the training set are shown in Appendix C and clearly show that the models were able to learn the task. The results for the test conditions are shown in Figure 3 (bottom row) and some examples of typical reconstructions are shown in Figure 4. As it was the case with the dSprites dataset, we observed that the level of disentanglement varied across models, with VAE showing a low D-score and Factor-VAE showing a high Dscore. We also tested the perfectly disentangled model where a decoder learns to construct images from disentangled latents. ",
453
+ "bbox": [
454
+ 174,
455
+ 690,
456
+ 825,
457
+ 815
458
+ ],
459
+ "page_idx": 5
460
+ },
461
+ {
462
+ "type": "text",
463
+ "text": "All models managed to reconstruct the held-out combination in the Recombination-to-element condition. However, none of the models succeeded in correctly reconstructing the held-out combinations in the Recombination-to-range or Extrapolation conditions. In both cases, we observed a large reconstruction error either due to poor overall reconstruction (Extrapolation case) or because the critical combination, [object-hue, object-shape] was replaced with a combination observed during training. And again, we did not see any correlation between disentanglement and the extent of combinatorial generalisation. Even though the perfectly disentangled model had a lower NLL score (see ",
464
+ "bbox": [
465
+ 174,
466
+ 821,
467
+ 823,
468
+ 920
469
+ ],
470
+ "page_idx": 5
471
+ },
472
+ {
473
+ "type": "image",
474
+ "img_path": "images/dfa5bb4b1ad4ffd9d9306d7676c88d973d00c5bf03232efcf3e97c1d7cf65e5d.jpg",
475
+ "image_caption": [
476
+ "Figure 4: Image reconstructions and disentanglement for the Shapes3D dataset. We use the same layout as in Figure 2. a) Reconstruction examples for each of the three generalisation conditions. For the first condition, the model has not seen magenta floors with purple cylinders, yet it is able to reconstruct them properly. For the second condition, it has not seen magenta oblong shapes, yet it has seen it in other colors and it has seen magenta on other shapes. Finally, the in the third condition magenta floors have never been seen during training. b) Example Hinton diagrams of the coefficients used to compute disentanglement. Diagram in each row corresponds to the model in the same row in (a). Sparse matrices are better and the perfect one (up to permutation) is shown at the bottom. "
477
+ ],
478
+ "image_footnote": [],
479
+ "bbox": [
480
+ 173,
481
+ 99,
482
+ 826,
483
+ 392
484
+ ],
485
+ "page_idx": 6
486
+ },
487
+ {
488
+ "type": "text",
489
+ "text": "Figure 3, bottom row), like other models it failed to reconstruct the critical [object-hue, object-shape] combination that was left out in the training data (see example images of reconstruction in Figure 4 and Appendix C). ",
490
+ "bbox": [
491
+ 174,
492
+ 542,
493
+ 825,
494
+ 584
495
+ ],
496
+ "page_idx": 6
497
+ },
498
+ {
499
+ "type": "text",
500
+ "text": "2.3 IMAGE COMPOSITION EXPERIMENTS ",
501
+ "text_level": 1,
502
+ "bbox": [
503
+ 178,
504
+ 602,
505
+ 465,
506
+ 616
507
+ ],
508
+ "page_idx": 6
509
+ },
510
+ {
511
+ "type": "text",
512
+ "text": "The limited combinatorial generalisation in the experiments above could be because of the limitations of the task rather than the models or their internal representations. Even though the models learned disentangled representations to some extent, or were provided perfectly disentangled representations, it could be that the simple reconstruction task does not provide enough impetus for the decoder to learn how to combine these disentangled representations to enable generalisation. Therefore, in the final set of experiments we designed a variation of the standard unsupervised task that requires combining generative factors in order to solve the task using the dSprites dataset. ",
513
+ "bbox": [
514
+ 174,
515
+ 627,
516
+ 823,
517
+ 724
518
+ ],
519
+ "page_idx": 6
520
+ },
521
+ {
522
+ "type": "text",
523
+ "text": "This new task is illustrated in Figure 5(a). The input consists of two images and an action. The goal of the task is to take the first (reference) image and modify it so that it matches the second (transform) image along the dimension specified by the action. This action is coded using a onehot vector. This design is based on the question answering task in Santoro et al. (2017) and the compositional one in Higgins et al. (2018c). We produced training and test sets for each condition by sampling reference-transform pairs along with an action uniformly from the generative factors. We ensured that this sampling respected the experiment restriction, so that the transformed image is not outside the current set. ",
524
+ "bbox": [
525
+ 174,
526
+ 731,
527
+ 825,
528
+ 843
529
+ ],
530
+ "page_idx": 6
531
+ },
532
+ {
533
+ "type": "text",
534
+ "text": "The standard VAE is inadequate to solve this task. Therefore, we constructed a model with the architecture shown in Figure 5(b). This model first applies an encoder to both images, obtaining low-dimensional latent representations of each image. It then combines these latent representations with the action to obtain a transformed internal representation. There are several ways in which the input representations of the two images could be combined with the action. We tried three different methods: (i) using a standard MLP, (ii) element-wise interpolation between the two representations, with the interpolation coefficients determined by the action, and (iii) concatenating each input representations with the actions and linearly combining the resultant vectors. We obtained qualitatively similar results with all three methods, but found that the method (iii) gave the best results, providing greatest accuracy of reconstruction as well as highest levels of disentanglement. Therefore, in the rest of the manuscript we describe the results obtained using this method. Once this transformed internal representation has been generated, it is decoded to obtain an output image. We use the same encoding and decoding modules as the ones used by Burgess et al. (2018). The results for this model are shown in Table 1. The model managed to solve the task. In doing so, it also comes to rely on representations with a high level of disentanglement (see Figure 6(b)) even though the $\\beta$ parameter is set to 1. Models with higher values could not solve the task altogether, presumably because the constraint is too strong. However, as was the case in the previous experiment, models failed to solve the more challenging generalisation tasks. ",
535
+ "bbox": [
536
+ 174,
537
+ 849,
538
+ 823,
539
+ 920
540
+ ],
541
+ "page_idx": 6
542
+ },
543
+ {
544
+ "type": "image",
545
+ "img_path": "images/a1323e14005938be7f7f6e6940d30904c7c95bdde979646137727d4b2ae57382.jpg",
546
+ "image_caption": [
547
+ "Figure 5: Image composition task. (a) An example of the composition task. In this case, the shape of the output must match the transform and the rest of the values must match the reference. (b) The general architecture used, based on the standard VAE. The model uses the same encoder on both images. Then a transform takes latent representation samples and combines them to produce a transformed representation. This is used to produce the transformed image. "
548
+ ],
549
+ "image_footnote": [],
550
+ "bbox": [
551
+ 171,
552
+ 99,
553
+ 826,
554
+ 237
555
+ ],
556
+ "page_idx": 7
557
+ },
558
+ {
559
+ "type": "table",
560
+ "img_path": "images/90feef6ef8656100793ed925470e79f19fa36f6f2e50ce84fd12a30127ee4579.jpg",
561
+ "table_caption": [
562
+ "Table 1: Model performance in the second set of experiments. "
563
+ ],
564
+ "table_footnote": [],
565
+ "table_body": "<table><tr><td></td><td>Experiment</td><td>D-score</td><td>NLL (training)</td><td>NLL (testing)</td></tr><tr><td>1</td><td>Extrapolation</td><td>0.82</td><td>31.73</td><td>19138.82</td></tr><tr><td>2</td><td>Recomb to range</td><td>0.71</td><td>50.10</td><td>346.10</td></tr><tr><td>3</td><td>Recomb to element</td><td>0.96</td><td>36.57</td><td>13.74</td></tr></table>",
566
+ "bbox": [
567
+ 235,
568
+ 358,
569
+ 758,
570
+ 429
571
+ ],
572
+ "page_idx": 7
573
+ },
574
+ {
575
+ "type": "text",
576
+ "text": "",
577
+ "bbox": [
578
+ 174,
579
+ 454,
580
+ 825,
581
+ 635
582
+ ],
583
+ "page_idx": 7
584
+ },
585
+ {
586
+ "type": "text",
587
+ "text": "In Figure 5 we show some examples of the model’s behaviour and its internal representations. The model failed in similar ways as the disentangled models in the previous experiment, confusing shapes when presented with unseen combinations. Even the Recombination to element case showed some failures (like in the example shown in Figure 5(a)) though the models were, in general, successful in this condition, as can be inferred by comparing the negative log-likelihoods for the training and test trials for this condition in Table 1. ",
588
+ "bbox": [
589
+ 174,
590
+ 642,
591
+ 825,
592
+ 724
593
+ ],
594
+ "page_idx": 7
595
+ },
596
+ {
597
+ "type": "text",
598
+ "text": "3 DISCUSSION ",
599
+ "text_level": 1,
600
+ "bbox": [
601
+ 176,
602
+ 746,
603
+ 310,
604
+ 761
605
+ ],
606
+ "page_idx": 7
607
+ },
608
+ {
609
+ "type": "text",
610
+ "text": "It is frequently assumed that disentangled representations are implicitly compositional (Higgins et al., 2018a;c). This raises the question as to whether disentangled representations support combinatorial generalisation, a key feature of compositional representations (Fodor & Pylyshyn, 1988). However, we found no evidence for this. Indeed representations that varied from highly entangled to perfectly disentangled were equally successful at recombination-to-element generalisation, and both failed on recombination-to-range and extrapolation. This was the case even when we trained a VAE on an explicitly combinatorial task that led models to learn highly disentangled representations that were no better at generalisation. ",
611
+ "bbox": [
612
+ 174,
613
+ 776,
614
+ 825,
615
+ 888
616
+ ],
617
+ "page_idx": 7
618
+ },
619
+ {
620
+ "type": "text",
621
+ "text": "Our findings might seem to contradict previous reports showing success in combinatorial generalisation tasks. In Eslami et al. (2018), some success was reported when rendering novel 3D shapes with colours that had been previously seen on other shapes. And in Higgins et al. (2018c) it was reported that using a disentangled representation allowed the model to recombine observed shapes and colours in novel ways. However, it is not clear what sorts of combinatorial generalisation was tested. For example, consider the SCAN model (Higgins et al., 2018c) that could render a room with [white suitcase, blue walls, magenta floor], even though it was never shown this combination during training (see Figure 4 in Higgins et al. (2018c)). But, unlike our training set, it is not clear what exactly was excluded while training this model, and they may have been testing generalisation in a condition similar to our Recombination-to-element condition. Our finding that generalisation was limited to the Recombination-to-element condition suggests that models are simply generalising on the basis of overall similarity (interpolation) rather than exploiting disentangled representations in order to support a more powerful form of compositional generalisation described by Fodor & Pylyshyn (1988). ",
622
+ "bbox": [
623
+ 174,
624
+ 895,
625
+ 821,
626
+ 924
627
+ ],
628
+ "page_idx": 7
629
+ },
630
+ {
631
+ "type": "image",
632
+ "img_path": "images/c5043f985aa95f7c6eaa69fa927a64f8cec2f2b7720bcd3d2b6fa296e55ea07a.jpg",
633
+ "image_caption": [
634
+ "Figure 6: Image composition generalisation results (a) Each column shows an example trial which consists of a reference image, an action, a transform image and the transformed (output) image. We show examples of both training and test trials. Each of the training trials results in the correct (expected) transformed image, while each of the test trials shows a failure. (b) Visualisation of the degree of disentanglement for three conditions by the model. The sparse representation reflects the high level of disentanglement achieved by these models in this task. "
635
+ ],
636
+ "image_footnote": [],
637
+ "bbox": [
638
+ 174,
639
+ 99,
640
+ 826,
641
+ 303
642
+ ],
643
+ "page_idx": 8
644
+ },
645
+ {
646
+ "type": "text",
647
+ "text": "",
648
+ "bbox": [
649
+ 174,
650
+ 415,
651
+ 825,
652
+ 582
653
+ ],
654
+ "page_idx": 8
655
+ },
656
+ {
657
+ "type": "text",
658
+ "text": "This raises the question as to why disentangled representations are not more effective in supporting combinatorial generalisation. One possibility is that disentangled representations are necessary but not sufficient to support the principle of compositionality. On this view, a model must also include a mechanism for binding these representations in a way that maintains their independence. This point has previously been made in the context of connectionist representations by Hummel in Hummel (2000). Another possibility is that a model may be able to perform combinatorial generalisation without needing disentangled or indeed compositional representations if the training environment is rich enough (Chaabouni et al., 2020; Hill et al., 2020; Lampinen & McClelland, 2020). ",
659
+ "bbox": [
660
+ 174,
661
+ 588,
662
+ 825,
663
+ 700
664
+ ],
665
+ "page_idx": 8
666
+ },
667
+ {
668
+ "type": "text",
669
+ "text": "An important goal for future research is to develop networks that support the more difficult forms of combinatorial generalisation and extrapolation. In fact there is already an active range of research in this direction that include networks with specialized modules (Santoro et al., 2017), mechanisms (Mitchell & Bowers, 2020; Hummel & Biederman, 1992), structured representations (Higgins et al., 2018c; Watters et al., 2019), or learning objectives (Vankov & Bowers, 2020) that may show greater success. It will be interesting to see how these and other approaches fare in the more difficult generalisation settings we have identified here, and the role of disentanglement in any solutions. ",
670
+ "bbox": [
671
+ 174,
672
+ 707,
673
+ 825,
674
+ 804
675
+ ],
676
+ "page_idx": 8
677
+ },
678
+ {
679
+ "type": "text",
680
+ "text": "ACKNOWLEDGEMENTS ",
681
+ "text_level": 1,
682
+ "bbox": [
683
+ 176,
684
+ 825,
685
+ 366,
686
+ 839
687
+ ],
688
+ "page_idx": 8
689
+ },
690
+ {
691
+ "type": "text",
692
+ "text": "We would like to thank Chris Summerfield, Irina Higgins, Ben Evans and Jeff Mitchell for useful discussions and feedback during the development of this research. ",
693
+ "bbox": [
694
+ 171,
695
+ 854,
696
+ 823,
697
+ 880
698
+ ],
699
+ "page_idx": 8
700
+ },
701
+ {
702
+ "type": "text",
703
+ "text": "This research was supported by a ERC Advanced Grant (Generalization in Mind and Machine, #741134). ",
704
+ "bbox": [
705
+ 173,
706
+ 888,
707
+ 794,
708
+ 901
709
+ ],
710
+ "page_idx": 8
711
+ },
712
+ {
713
+ "type": "text",
714
+ "text": "REFERENCES ",
715
+ "text_level": 1,
716
+ "bbox": [
717
+ 176,
718
+ 103,
719
+ 285,
720
+ 117
721
+ ],
722
+ "page_idx": 9
723
+ },
724
+ {
725
+ "type": "text",
726
+ "text": "Yoshua Bengio, Aaron Courville, and Pascal Vincent. Representation Learning: A Review and New Perspectives. arXiv:1206.5538 [cs], April 2014. URL http://arxiv.org/abs/1206.5538. arXiv: 1206.5538. ",
727
+ "bbox": [
728
+ 174,
729
+ 126,
730
+ 825,
731
+ 167
732
+ ],
733
+ "page_idx": 9
734
+ },
735
+ {
736
+ "type": "text",
737
+ "text": "Jeffrey S. Bowers, Ivan I. Vankov, Markus F. Damian, and Colin J. Davis. Why do some neurons in cortex respond to information in a selective manner? Insights from artificial neural networks. Cognition, 148:47–63, March 2016. ISSN 0010-0277. doi: 10.1016/j.cognition.2015.12.009. URL http://www.sciencedirect.com/science/article/pii/S0010027715301232. ",
738
+ "bbox": [
739
+ 173,
740
+ 178,
741
+ 825,
742
+ 233
743
+ ],
744
+ "page_idx": 9
745
+ },
746
+ {
747
+ "type": "text",
748
+ "text": "Chris Burgess and Hyunjik Kim. 3d shapes dataset. https://github.com/deepmind/3dshapes-dataset/, 2018. ",
749
+ "bbox": [
750
+ 171,
751
+ 242,
752
+ 823,
753
+ 271
754
+ ],
755
+ "page_idx": 9
756
+ },
757
+ {
758
+ "type": "text",
759
+ "text": "Christopher P. Burgess, Irina Higgins, Arka Pal, Loic Matthey, Nick Watters, Guillaume Desjardins, and Alexander Lerchner. Understanding disentangling in $\\$ 1$ \\beta\\$-VAE. arXiv:1804.03599 [cs, stat], April 2018. URL http://arxiv.org/abs/1804.03599. arXiv: 1804.03599. ",
760
+ "bbox": [
761
+ 176,
762
+ 280,
763
+ 823,
764
+ 323
765
+ ],
766
+ "page_idx": 9
767
+ },
768
+ {
769
+ "type": "text",
770
+ "text": "Rahma Chaabouni, Eugene Kharitonov, Diane Bouchacourt, Emmanuel Dupoux, and Marco Baroni. Compositionality and generalization in emergent languages. arXiv preprint arXiv:2004.09124, 2020. ",
771
+ "bbox": [
772
+ 174,
773
+ 332,
774
+ 826,
775
+ 375
776
+ ],
777
+ "page_idx": 9
778
+ },
779
+ {
780
+ "type": "text",
781
+ "text": "Sunny Duan, Loic Matthey, Andre Saraiva, Nicholas Watters, Christopher P. Burgess, Alexander Lerchner, and Irina Higgins. Unsupervised Model Selection for Variational Disentangled Representation Learning. arXiv:1905.12614 [cs, stat], February 2020. URL http://arxiv.org/ abs/1905.12614. arXiv: 1905.12614. ",
782
+ "bbox": [
783
+ 174,
784
+ 383,
785
+ 825,
786
+ 439
787
+ ],
788
+ "page_idx": 9
789
+ },
790
+ {
791
+ "type": "text",
792
+ "text": "Cian Eastwood and Christopher KI Williams. A framework for the quantitative evaluation of disentangled representations. In International Conference on Learning Representations, pp. 15, 2018. ",
793
+ "bbox": [
794
+ 173,
795
+ 449,
796
+ 825,
797
+ 491
798
+ ],
799
+ "page_idx": 9
800
+ },
801
+ {
802
+ "type": "text",
803
+ "text": "S. M. Ali Eslami, Danilo Jimenez Rezende, Frederic Besse, Fabio Viola, Ari S. Morcos, Marta Garnelo, Avraham Ruderman, Andrei A. Rusu, Ivo Danihelka, Karol Gregor, David P. Reichert, Lars Buesing, Theophane Weber, Oriol Vinyals, Dan Rosenbaum, Neil Rabinowitz, Helen King, Chloe Hillier, Matt Botvinick, Daan Wierstra, Koray Kavukcuoglu, and Demis Hassabis. Neural scene representation and rendering. Science, 360(6394):1204–1210, June 2018. ISSN 0036- 8075, 1095-9203. doi: 10.1126/science.aar6170. URL https://science.sciencemag.org/ content/360/6394/1204. Publisher: American Association for the Advancement of Science Section: Research Article. ",
804
+ "bbox": [
805
+ 174,
806
+ 500,
807
+ 825,
808
+ 612
809
+ ],
810
+ "page_idx": 9
811
+ },
812
+ {
813
+ "type": "text",
814
+ "text": "Babak Esmaeili, Hao Wu, Sarthak Jain, Alican Bozkurt, N. Siddharth, Brooks Paige, Dana H. Brooks, Jennifer Dy, and Jan-Willem Meent. Structured Disentangled Representations. In The 22nd International Conference on Artificial Intelligence and Statistics, pp. 2525–2534. PMLR, April 2019. URL http://proceedings.mlr.press/v89/esmaeili19a.html. ISSN: 2640-3498. ",
815
+ "bbox": [
816
+ 173,
817
+ 621,
818
+ 825,
819
+ 690
820
+ ],
821
+ "page_idx": 9
822
+ },
823
+ {
824
+ "type": "text",
825
+ "text": "Jerry Fodor and Brian P. McLaughlin. Connectionism and the problem of systematicity: Why Smolensky’s solution doesn’t work. Cognition, 35(2):183–204, May 1990. ISSN 0010-0277. doi: 10.1016/0010-0277(90)90014-B. URL http://www.sciencedirect.com/science/ article/pii/001002779090014B. ",
826
+ "bbox": [
827
+ 173,
828
+ 700,
829
+ 825,
830
+ 757
831
+ ],
832
+ "page_idx": 9
833
+ },
834
+ {
835
+ "type": "text",
836
+ "text": "Jerry A. Fodor and Zenon W. Pylyshyn. Connectionism and cognitive architecture: A critical analysis. Cognition, 28(1):3–71, March 1988. ISSN 0010-0277. doi: 10.1016/0010-0277(88)90031-5. URL http://www.sciencedirect.com/science/article/pii/0010027788900315. ",
837
+ "bbox": [
838
+ 173,
839
+ 766,
840
+ 823,
841
+ 809
842
+ ],
843
+ "page_idx": 9
844
+ },
845
+ {
846
+ "type": "text",
847
+ "text": "Irina Higgins, Loic Matthey, Arka Pal, Christopher Burgess, Xavier Glorot, Matthew Botvinick, Shakir Mohamed, and Alexander Lerchner. $\\beta$ -VAE: Learning basic visual concepts with a constrained variational framework. pp. 13, 2017. ",
848
+ "bbox": [
849
+ 171,
850
+ 818,
851
+ 825,
852
+ 861
853
+ ],
854
+ "page_idx": 9
855
+ },
856
+ {
857
+ "type": "text",
858
+ "text": "Irina Higgins, David Amos, David Pfau, Sebastien Racaniere, Loic Matthey, Danilo Rezende, and Alexander Lerchner. Towards a Definition of Disentangled Representations. arXiv:1812.02230 [cs, stat], December 2018a. URL http://arxiv.org/abs/1812.02230. arXiv: 1812.02230. ",
859
+ "bbox": [
860
+ 173,
861
+ 869,
862
+ 825,
863
+ 912
864
+ ],
865
+ "page_idx": 9
866
+ },
867
+ {
868
+ "type": "text",
869
+ "text": "Irina Higgins, Arka Pal, Andrei A. Rusu, Loic Matthey, Christopher P. Burgess, Alexander Pritzel, Matthew Botvinick, Charles Blundell, and Alexander Lerchner. DARLA: Improving Zero-Shot Transfer in Reinforcement Learning. arXiv:1707.08475 [cs, stat], June 2018b. URL http: //arxiv.org/abs/1707.08475. arXiv: 1707.08475. ",
870
+ "bbox": [
871
+ 174,
872
+ 103,
873
+ 825,
874
+ 160
875
+ ],
876
+ "page_idx": 10
877
+ },
878
+ {
879
+ "type": "text",
880
+ "text": "Irina Higgins, Nicolas Sonnerat, Loic Matthey, Arka Pal, Christopher P. Burgess, Matko Bosnjak, Murray Shanahan, Matthew Botvinick, Demis Hassabis, and Alexander Lerchner. SCAN: Learning Hierarchical Compositional Visual Concepts. arXiv:1707.03389 [cs, stat], June 2018c. URL http://arxiv.org/abs/1707.03389. arXiv: 1707.03389. ",
881
+ "bbox": [
882
+ 173,
883
+ 169,
884
+ 825,
885
+ 224
886
+ ],
887
+ "page_idx": 10
888
+ },
889
+ {
890
+ "type": "text",
891
+ "text": "Felix Hill, Andrew Lampinen, Rosalia Schneider, Stephen Clark, Matthew Botvinick, James L. McClelland, and Adam Santoro. Environmental drivers of systematicity and generalization in a situated agent. arXiv:1910.00571 [cs], February 2020. URL http://arxiv.org/abs/1910. 00571. arXiv: 1910.00571. ",
892
+ "bbox": [
893
+ 173,
894
+ 234,
895
+ 825,
896
+ 290
897
+ ],
898
+ "page_idx": 10
899
+ },
900
+ {
901
+ "type": "text",
902
+ "text": "Matthew D Hoffman and Matthew J Johnson. Elbo surgery: yet another way to carve up the variational evidence lower bound. In Workshop in Advances in Approximate Bayesian Inference, NIPS, volume 1, pp. 2, 2016. ",
903
+ "bbox": [
904
+ 173,
905
+ 299,
906
+ 825,
907
+ 343
908
+ ],
909
+ "page_idx": 10
910
+ },
911
+ {
912
+ "type": "text",
913
+ "text": "J. E. Hummel. Localism as a first step toward symbolic representation. Behavioral and Brain Sciences, 23(4):480–481, December 2000. ISSN 0140-525X. doi: 10.1017/S0140525X0036335X. ",
914
+ "bbox": [
915
+ 169,
916
+ 351,
917
+ 823,
918
+ 381
919
+ ],
920
+ "page_idx": 10
921
+ },
922
+ {
923
+ "type": "text",
924
+ "text": "John E Hummel and Irving Biederman. Dynamic binding in a neural network for shape recognition. Psychological review, 99(3):480, 1992. ",
925
+ "bbox": [
926
+ 171,
927
+ 388,
928
+ 823,
929
+ 417
930
+ ],
931
+ "page_idx": 10
932
+ },
933
+ {
934
+ "type": "text",
935
+ "text": "Hyunjik Kim and Andriy Mnih. Disentangling by Factorising. arXiv:1802.05983 [cs, stat], July 2019. URL http://arxiv.org/abs/1802.05983. arXiv: 1802.05983. ",
936
+ "bbox": [
937
+ 169,
938
+ 426,
939
+ 823,
940
+ 455
941
+ ],
942
+ "page_idx": 10
943
+ },
944
+ {
945
+ "type": "text",
946
+ "text": "Diederik P. Kingma and Jimmy Ba. Adam: A Method for Stochastic Optimization. arXiv:1412.6980 [cs], January 2017. URL http://arxiv.org/abs/1412.6980. arXiv: 1412.6980. ",
947
+ "bbox": [
948
+ 171,
949
+ 464,
950
+ 825,
951
+ 493
952
+ ],
953
+ "page_idx": 10
954
+ },
955
+ {
956
+ "type": "text",
957
+ "text": "Diederik P. Kingma and Max Welling. Auto-Encoding Variational Bayes. arXiv:1312.6114 [cs, stat], December 2013. URL http://arxiv.org/abs/1312.6114. arXiv: 1312.6114. ",
958
+ "bbox": [
959
+ 171,
960
+ 501,
961
+ 823,
962
+ 531
963
+ ],
964
+ "page_idx": 10
965
+ },
966
+ {
967
+ "type": "text",
968
+ "text": "Klaus Greff, Aaron Klein, Martin Chovanec, Frank Hutter, and Jürgen Schmidhuber. The Sacred Infrastructure for Computational Research. In Katy Huff, David Lippa, Dillon Niederhut, and M Pacer (eds.), Proceedings of the 16th Python in Science Conference, pp. 49 – 56, 2017. doi: 10.25080/shinma-7f4c6e7-008. ",
969
+ "bbox": [
970
+ 174,
971
+ 540,
972
+ 825,
973
+ 595
974
+ ],
975
+ "page_idx": 10
976
+ },
977
+ {
978
+ "type": "text",
979
+ "text": "Brenden Lake and Marco Baroni. Generalization without Systematicity: On the Compositional Skills of Sequence-to-Sequence Recurrent Networks. In International Conference on Machine Learning, pp. 2873–2882. PMLR, July 2018. URL http://proceedings.mlr.press/v80/ lake18a.html. ISSN: 2640-3498. ",
980
+ "bbox": [
981
+ 174,
982
+ 604,
983
+ 825,
984
+ 661
985
+ ],
986
+ "page_idx": 10
987
+ },
988
+ {
989
+ "type": "text",
990
+ "text": "Andrew K Lampinen and James L McClelland. Transforming task representations to allow deep learning models to perform novel tasks. arXiv preprint arXiv:2005.04318, 2020. ",
991
+ "bbox": [
992
+ 171,
993
+ 670,
994
+ 820,
995
+ 700
996
+ ],
997
+ "page_idx": 10
998
+ },
999
+ {
1000
+ "type": "text",
1001
+ "text": "Francesco Locatello, Stefan Bauer, Mario Lucic, Gunnar Rätsch, Sylvain Gelly, Bernhard Schölkopf, and Olivier Bachem. Challenging Common Assumptions in the Unsupervised Learning of Disentangled Representations. pp. 11, 2019. ",
1002
+ "bbox": [
1003
+ 173,
1004
+ 708,
1005
+ 825,
1006
+ 751
1007
+ ],
1008
+ "page_idx": 10
1009
+ },
1010
+ {
1011
+ "type": "text",
1012
+ "text": "Gary Marcus. Deep learning: A critical appraisal. arXiv preprint arXiv:1801.00631, 2018. ",
1013
+ "bbox": [
1014
+ 169,
1015
+ 760,
1016
+ 767,
1017
+ 776
1018
+ ],
1019
+ "page_idx": 10
1020
+ },
1021
+ {
1022
+ "type": "text",
1023
+ "text": "Emile Mathieu, Tom Rainforth, N. Siddharth, and Yee Whye Teh. Disentangling Disentanglement in Variational Autoencoders. arXiv:1812.02833 [cs, stat], June 2019. URL http://arxiv. org/abs/1812.02833. arXiv: 1812.02833. ",
1024
+ "bbox": [
1025
+ 173,
1026
+ 784,
1027
+ 825,
1028
+ 827
1029
+ ],
1030
+ "page_idx": 10
1031
+ },
1032
+ {
1033
+ "type": "text",
1034
+ "text": "Loic Matthey, Irina Higgins, Demis Hassabis, and Alexander Lerchner. dSprites: Disentanglement testing Sprites dataset. 2017. URL https://github.com/deepmind/dsprites-dataset/. ",
1035
+ "bbox": [
1036
+ 171,
1037
+ 835,
1038
+ 825,
1039
+ 864
1040
+ ],
1041
+ "page_idx": 10
1042
+ },
1043
+ {
1044
+ "type": "text",
1045
+ "text": "James L McClelland, David E Rumelhart, PDP Research Group, and others. Parallel distributed processing. Explorations in the Microstructure of Cognition, 2:216–271, 1986. Publisher: MIT Press Cambridge, Ma. ",
1046
+ "bbox": [
1047
+ 173,
1048
+ 873,
1049
+ 825,
1050
+ 916
1051
+ ],
1052
+ "page_idx": 10
1053
+ },
1054
+ {
1055
+ "type": "text",
1056
+ "text": "Jeff Mitchell and Jeffrey S. Bowers. Harnessing the Symmetry of Convolutions for Systematic Generalisation. In 2020 International Joint Conference on Neural Networks (IJCNN), pp. 1–8, Glasgow, United Kingdom, July 2020. IEEE. ISBN 978-1-72816-926-2. doi: 10.1109/IJCNN48605. 2020.9207183. URL https://ieeexplore.ieee.org/document/9207183/. ",
1057
+ "bbox": [
1058
+ 174,
1059
+ 103,
1060
+ 825,
1061
+ 159
1062
+ ],
1063
+ "page_idx": 11
1064
+ },
1065
+ {
1066
+ "type": "text",
1067
+ "text": "Adam Paszke, Sam Gross, Francisco Massa, Adam Lerer, James Bradbury, Gregory Chanan, Trevor Killeen, Zeming Lin, Natalia Gimelshein, Luca Antiga, Alban Desmaison, Andreas Kopf, Edward Yang, Zachary DeVito, Martin Raison, Alykhan Tejani, Sasank Chilamkurthy, Benoit Steiner, Lu Fang, Junjie Bai, and Soumith Chintala. Pytorch: An imperative style, highperformance deep learning library. In H. Wallach, H. Larochelle, A. Beygelzimer, F. dAlché-Buc, E. Fox, and R. Garnett (eds.), Advances in Neural Information Processing Systems 32, pp. 8024–8035. Curran Associates, Inc., 2019. URL http://papers.neurips.cc/paper/ 9015-pytorch-an-imperative-style-high-performance-deep-learning-library. pdf. ",
1068
+ "bbox": [
1069
+ 174,
1070
+ 169,
1071
+ 828,
1072
+ 294
1073
+ ],
1074
+ "page_idx": 11
1075
+ },
1076
+ {
1077
+ "type": "text",
1078
+ "text": "F. Pedregosa, G. Varoquaux, A. Gramfort, V. Michel, B. Thirion, O. Grisel, M. Blondel, P. Prettenhofer, R. Weiss, V. Dubourg, J. Vanderplas, A. Passos, D. Cournapeau, M. Brucher, M. Perrot, and E. Duchesnay. Scikit-learn: Machine learning in Python. Journal of Machine Learning Research, 12:2825–2830, 2011. ",
1079
+ "bbox": [
1080
+ 174,
1081
+ 303,
1082
+ 826,
1083
+ 359
1084
+ ],
1085
+ "page_idx": 11
1086
+ },
1087
+ {
1088
+ "type": "text",
1089
+ "text": "Danilo Jimenez Rezende, Shakir Mohamed, and Daan Wierstra. Stochastic Backpropagation and Approximate Inference in Deep Generative Models. arXiv:1401.4082 [cs, stat], January 2014. URL http://arxiv.org/abs/1401.4082. arXiv: 1401.4082. ",
1090
+ "bbox": [
1091
+ 173,
1092
+ 368,
1093
+ 825,
1094
+ 411
1095
+ ],
1096
+ "page_idx": 11
1097
+ },
1098
+ {
1099
+ "type": "text",
1100
+ "text": "Adam Santoro, David Raposo, David G Barrett, Mateusz Malinowski, Razvan Pascanu, Peter Battaglia, and Timothy Lillicrap. A simple neural network module for relational reasoning. In I. Guyon, U. V. Luxburg, S. Bengio, H. Wallach, R. Fergus, S. Vishwanathan, and R. Garnett (eds.), Advances in Neural Information Processing Systems 30, pp. 4967–4976. Curran Associates, Inc., 2017. URL http://papers.nips.cc/paper/ 7082-a-simple-neural-network-module-for-relational-reasoning.pdf. ",
1101
+ "bbox": [
1102
+ 173,
1103
+ 420,
1104
+ 825,
1105
+ 505
1106
+ ],
1107
+ "page_idx": 11
1108
+ },
1109
+ {
1110
+ "type": "text",
1111
+ "text": "Paul Smolensky. The constituent structure of connectionist mental states: A reply to Fodor and Pylyshyn. Southern Journal of Philosophy, 26(Supplement):137–163, 1987. Publisher: Citeseer. ",
1112
+ "bbox": [
1113
+ 173,
1114
+ 513,
1115
+ 823,
1116
+ 542
1117
+ ],
1118
+ "page_idx": 11
1119
+ },
1120
+ {
1121
+ "type": "text",
1122
+ "text": "Paul Smolensky. Connectionism, constituency, and the language of thought. University of Colorado at Boulder, 1988. ",
1123
+ "bbox": [
1124
+ 173,
1125
+ 551,
1126
+ 825,
1127
+ 580
1128
+ ],
1129
+ "page_idx": 11
1130
+ },
1131
+ {
1132
+ "type": "text",
1133
+ "text": "S. Desroziers J. Kriss V. Fomin, J. Anmol and A. Tejani. High-level library to help with training neural networks in pytorch. https://github.com/pytorch/ignite, 2020. ",
1134
+ "bbox": [
1135
+ 173,
1136
+ 588,
1137
+ 823,
1138
+ 618
1139
+ ],
1140
+ "page_idx": 11
1141
+ },
1142
+ {
1143
+ "type": "text",
1144
+ "text": "Sjoerd van Steenkiste, Jürgen Schmidhuber, Francesco Locatello, and Olivier Bachem. Are Disentangled Representations Helpful for Abstract Visual Reasoning? pp. 14, 2019. ",
1145
+ "bbox": [
1146
+ 171,
1147
+ 626,
1148
+ 821,
1149
+ 656
1150
+ ],
1151
+ "page_idx": 11
1152
+ },
1153
+ {
1154
+ "type": "text",
1155
+ "text": "Ivan I. Vankov and Jeffrey S. Bowers. Training neural networks to encode symbols enables combinatorial generalization. Philosophical Transactions of the Royal Society B: Biological Sciences, 375(1791):20190309, February 2020. doi: 10.1098/rstb.2019.0309. URL https: //royalsocietypublishing.org/doi/10.1098/rstb.2019.0309. Publisher: Royal Society. ",
1156
+ "bbox": [
1157
+ 173,
1158
+ 664,
1159
+ 825,
1160
+ 734
1161
+ ],
1162
+ "page_idx": 11
1163
+ },
1164
+ {
1165
+ "type": "text",
1166
+ "text": "Nicholas Watters, Loic Matthey, Christopher P. Burgess, and Alexander Lerchner. Spatial Broadcast Decoder: A Simple Architecture for Learning Disentangled Representations in VAEs. arXiv:1901.07017 [cs, stat], August 2019. URL http://arxiv.org/abs/1901.07017. arXiv: 1901.07017. ",
1167
+ "bbox": [
1168
+ 173,
1169
+ 743,
1170
+ 825,
1171
+ 800
1172
+ ],
1173
+ "page_idx": 11
1174
+ },
1175
+ {
1176
+ "type": "text",
1177
+ "text": "Shengjia Zhao, Hongyu Ren, Arianna Yuan, Jiaming Song, Noah Goodman, and Stefano Ermon. Bias and Generalization in Deep Generative Models: An Empirical Study. arXiv:1811.03259 [cs, stat], November 2018. URL http://arxiv.org/abs/1811.03259. arXiv: 1811.03259. ",
1178
+ "bbox": [
1179
+ 174,
1180
+ 809,
1181
+ 823,
1182
+ 852
1183
+ ],
1184
+ "page_idx": 11
1185
+ },
1186
+ {
1187
+ "type": "text",
1188
+ "text": "A MODELS AND TRAINING ",
1189
+ "text_level": 1,
1190
+ "bbox": [
1191
+ 176,
1192
+ 102,
1193
+ 413,
1194
+ 117
1195
+ ],
1196
+ "page_idx": 12
1197
+ },
1198
+ {
1199
+ "type": "text",
1200
+ "text": "For our experiments on the standard unsupervised task we used two different VAE architectures. The first one is the same found in Higgins et al. (2017) and uses a 2-layer MLP as an encoder with 1200 units and ReLU non-linearity. The decoder is a 3-layer with the same number of units and the Tanh non-linearity. The second architecture is the one found in Burgess et al. (2018) and consists of a 3-layer CNN with $3 2 \\times 4 \\times 2 \\times 1$ convolutions and max pooling, followed by a 2-layer MLP with 256 units in each layer. The decoder is defined to be the transpose of this architecture. ReLU non-linearity where applied after each layer of the CNN and the MLP for both the encoder and the decoder. Both models used a Gaussian stochastic layer with 10 units as in the original papers. ",
1201
+ "bbox": [
1202
+ 174,
1203
+ 133,
1204
+ 825,
1205
+ 244
1206
+ ],
1207
+ "page_idx": 12
1208
+ },
1209
+ {
1210
+ "type": "text",
1211
+ "text": "We also tested two variants of this last architecture, one found in Mathieu et al. (2019) which changes the shape of the convolution and another with batch normalisation. Neither variant exhibited any improvements to disentanglement or reconstruction on the full dSprite data and so were not included in the rest of the experiments. ",
1212
+ "bbox": [
1213
+ 174,
1214
+ 252,
1215
+ 825,
1216
+ 308
1217
+ ],
1218
+ "page_idx": 12
1219
+ },
1220
+ {
1221
+ "type": "text",
1222
+ "text": "For the image composition task we used same as in Burgess et al. (2018) that we described above. The latent transformation layer was parameterized as: ",
1223
+ "bbox": [
1224
+ 171,
1225
+ 314,
1226
+ 821,
1227
+ 343
1228
+ ],
1229
+ "page_idx": 12
1230
+ },
1231
+ {
1232
+ "type": "equation",
1233
+ "img_path": "images/60c313fa3e59cd8c16a57156c7e38ce59d1c662e03c28f7349ac5950d413a3ba.jpg",
1234
+ "text": "$$\nh _ { t r a n s f o r m e d } = W _ { r } c a t [ z _ { r } ; a c t i o n ] + W _ { t } c a t [ z _ { t } ; a c t i o n ]\n$$",
1235
+ "text_format": "latex",
1236
+ "bbox": [
1237
+ 312,
1238
+ 362,
1239
+ 684,
1240
+ 380
1241
+ ],
1242
+ "page_idx": 12
1243
+ },
1244
+ {
1245
+ "type": "text",
1246
+ "text": "where $z _ { r }$ and $z _ { t }$ are the samples from the stochastic layer for reference and transform image, cat is the concatenation operation performed along the column dimension. The output is another 10- dimensional vector with the transformed latent code. ",
1247
+ "bbox": [
1248
+ 176,
1249
+ 390,
1250
+ 821,
1251
+ 431
1252
+ ],
1253
+ "page_idx": 12
1254
+ },
1255
+ {
1256
+ "type": "text",
1257
+ "text": "Alternatively we also tried a 3 layer MLP with 100 hidden units, but saw no benefit in performance and decreased disentanglement when trainined on the full dataset. ",
1258
+ "bbox": [
1259
+ 173,
1260
+ 439,
1261
+ 823,
1262
+ 467
1263
+ ],
1264
+ "page_idx": 12
1265
+ },
1266
+ {
1267
+ "type": "text",
1268
+ "text": "Training on the unsupervised tasks ran for 100 epochs for dSprites and 65 epochs for Shapes3D, even though models converged before the end. The learning rate was fixed at $1 e - 4$ and the batch size at 64. $\\beta$ values used were 1, 4, 8, 12, 16 on the full dSprite dataset. $\\beta = 4$ and $\\beta = 1 6$ where not included in the rest of the experiments since the former offered very little disentanglement and the latter very large reconstruction error. For the FactorVAE we used $\\gamma = 2 0 , 5 0 , 1 0 ( $ 0 throughout. In the composition task the models where trained for 100 epochs with $\\beta = 1$ . Using $\\beta$ higher than 1 interfered with the model’s ability to solve the task so they where not used. ",
1269
+ "bbox": [
1270
+ 173,
1271
+ 474,
1272
+ 825,
1273
+ 571
1274
+ ],
1275
+ "page_idx": 12
1276
+ },
1277
+ {
1278
+ "type": "text",
1279
+ "text": "For the ground-truth decoders (GT Decoder) we used the same MLP decoder of Higgins et al. (2017) mentioned above. Using deeper decoders with convolutions with/without batch norm after each layer was also tested, but did not provide significan benefits and also decreased the performance on some of the conditions. ",
1280
+ "bbox": [
1281
+ 174,
1282
+ 578,
1283
+ 825,
1284
+ 635
1285
+ ],
1286
+ "page_idx": 12
1287
+ },
1288
+ {
1289
+ "type": "text",
1290
+ "text": "All the models where implemented in PyTorch (Paszke et al., 2019) and the experiments where performed using the Ignite and Sacred frameworks (V. Fomin & Tejani, 2020; Klaus Greff et al., 2017). ",
1291
+ "bbox": [
1292
+ 176,
1293
+ 641,
1294
+ 823,
1295
+ 684
1296
+ ],
1297
+ "page_idx": 12
1298
+ },
1299
+ {
1300
+ "type": "text",
1301
+ "text": "To measure disentanglement we used the framework proposed by Eastwood & Williams (2018) with a slight modification. The approach consists of predicting each generative factor value, given the latent representations of the training images using a non-linear model. In our case we used the LassoCV regression found in the Sklearn library (Pedregosa et al., 2011) with an $\\alpha$ coefficient of 0.01 and 5 cross-validation partitions. Deviating from the original proposal, we do not normalize the inputs to the regression model since we found that this tends to give a lot of weight to dead units (when measured by their KL divergence). This is likely due to the model “killing” these units during training after they start with a high KL value, which might not completely erase the information they carry about a given generative factor. ",
1302
+ "bbox": [
1303
+ 173,
1304
+ 690,
1305
+ 825,
1306
+ 815
1307
+ ],
1308
+ "page_idx": 12
1309
+ },
1310
+ {
1311
+ "type": "text",
1312
+ "text": "Working code for running these experiments and analyses can be downloaded at https://github. \ncom/mmrl/disent-and-gen. ",
1313
+ "bbox": [
1314
+ 174,
1315
+ 823,
1316
+ 820,
1317
+ 852
1318
+ ],
1319
+ "page_idx": 12
1320
+ },
1321
+ {
1322
+ "type": "image",
1323
+ "img_path": "images/98899b7b56cb657c7ea909545bac26e823d256b0ca358c413d51c219a88916e9.jpg",
1324
+ "image_caption": [
1325
+ "Figure 7: Disentanglement scores for dSprites. The disentanglement analysis results for the dSprites dataset. The scores for each of the metrics evaluated by the DCI framework: disentanglement (left), overall disentanglement (middle) and completeness (right) for each of the conditions. "
1326
+ ],
1327
+ "image_footnote": [],
1328
+ "bbox": [
1329
+ 235,
1330
+ 133,
1331
+ 761,
1332
+ 416
1333
+ ],
1334
+ "page_idx": 13
1335
+ },
1336
+ {
1337
+ "type": "image",
1338
+ "img_path": "images/35fd2b6c5a8196f41ce6b7417a0dfc6586e49c368fdd2291b206667bdd875379.jpg",
1339
+ "image_caption": [
1340
+ "Figure 8: Hinton diagrams for dSprites dataset. The matrices of coefficients computed by the framework plotted as Hinton diagrams. These are used to obtain the quantitative scores in the panel above. They offer a qualitative view of how the model is disentangling. On the left is how perfect disentanglement looks in this framework. "
1341
+ ],
1342
+ "image_footnote": [],
1343
+ "bbox": [
1344
+ 235,
1345
+ 491,
1346
+ 753,
1347
+ 833
1348
+ ],
1349
+ "page_idx": 13
1350
+ },
1351
+ {
1352
+ "type": "image",
1353
+ "img_path": "images/7292bb6dbe356dc3bede6b5ef0f2d3a2c9022db7e698af6e18364a37af9bc305.jpg",
1354
+ "image_caption": [
1355
+ "Figure 9: Reconstructions for the dSprites dataset. For each condition and model, these are some reconstruction examples for both training and testing. There is general success and failure in the Recombination to Element (top) and Extrapolation (bottom) conditions, respectively. For this last condition, the models seem to reproduce the closest instance they have seen, which tranlated to the middle of the image. For the Recombination to range (middle), the models tend to resort to generating a blob at the right location, minimising their pixel-level error. "
1356
+ ],
1357
+ "image_footnote": [],
1358
+ "bbox": [
1359
+ 171,
1360
+ 101,
1361
+ 826,
1362
+ 465
1363
+ ],
1364
+ "page_idx": 14
1365
+ },
1366
+ {
1367
+ "type": "text",
1368
+ "text": "C EXTRA PLOTS FOR THE 3D SHAPES DATASET ",
1369
+ "bbox": [
1370
+ 173,
1371
+ 587,
1372
+ 583,
1373
+ 604
1374
+ ],
1375
+ "page_idx": 14
1376
+ },
1377
+ {
1378
+ "type": "image",
1379
+ "img_path": "images/baaa266eeaa0212d321df4cadff20b070c0163db5049381f75728082bf6b5995.jpg",
1380
+ "image_caption": [
1381
+ "Figure 10: Disentanglement analysis for Shapes3D. The disentanglement analysis results for the 3D Shapes dataset. The scores for each of the metrics evaluated by the DCI framework (Eastwood & Williams, 2018): disentanglement (left), overall disentanglement (middle) and completeness (right) for each of the conditions. "
1382
+ ],
1383
+ "image_footnote": [],
1384
+ "bbox": [
1385
+ 235,
1386
+ 97,
1387
+ 761,
1388
+ 383
1389
+ ],
1390
+ "page_idx": 15
1391
+ },
1392
+ {
1393
+ "type": "image",
1394
+ "img_path": "images/c29401e333f93fbd80986c93ebbb886d5d94d1bb411ee79c5a12c4389b344470.jpg",
1395
+ "image_caption": [
1396
+ "Figure 11: Hinton diagrams for 3DShapes dataset. The matrices of coefficients computed by the framework plotted as Hinton Diagrams. As discussed in the main text, these matrices offer a qualitative view of how the model is disentangling. In general, sparse matrices indicate higher disentanglement. It is clear from these diagrams that the degree of disentanglement varies over a broad range for the tested models. "
1397
+ ],
1398
+ "image_footnote": [],
1399
+ "bbox": [
1400
+ 235,
1401
+ 460,
1402
+ 758,
1403
+ 796
1404
+ ],
1405
+ "page_idx": 15
1406
+ },
1407
+ {
1408
+ "type": "image",
1409
+ "img_path": "images/7c01a7e17a903b7d9fb9bcda6bc84f0a1ec45a4f77a02f5a1600deaf86a14114.jpg",
1410
+ "image_caption": [
1411
+ "Figure 12: Reconstructions for the Shapes3D dataset. For each condition and model, these are some reconstruction examples for both training (left) and testing (right). In each case, the input image is shown in the left-most column and each subsequent column shows reconstruction by a different model. The test images always show a combination that was left out during training. All training images are successfully reproduced. However, reconstruction for test images only succeeds consistently for the Recombination-to-Element condition (top). All reconstructions fail in the Extrapolation condition (bottom) while most of them fail for the Recombination-to-Range condition (middle). There are occasional instances in Recombination-to-Range condition that seem to correctly reconstruct the input image. This seems to happen when the novel combination for color and shape is closest to the ones the model has experienced during training. For example, models are better when the oblong shape is paired with cyan (which is close to green, which it has seen) and worse on magenta. "
1412
+ ],
1413
+ "image_footnote": [],
1414
+ "bbox": [
1415
+ 236,
1416
+ 267,
1417
+ 763,
1418
+ 565
1419
+ ],
1420
+ "page_idx": 16
1421
+ }
1422
+ ]
parse/train/qbH974jKUVy/qbH974jKUVy_middle.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/qbH974jKUVy/qbH974jKUVy_model.json ADDED
The diff for this file is too large to render. See raw diff