ZHANGYUXUAN-zR commited on
Commit
74950a4
·
verified ·
1 Parent(s): 12d4241

Add files using upload-large-folder tool

Browse files
parse/train/37nvvqkCo5/37nvvqkCo5.md ADDED
@@ -0,0 +1,631 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # LONG-TAIL LEARNING VIA LOGIT ADJUSTMENT
2
+
3
+ Aditya Krishna Menon, Sadeep Jayasumana, Ankit Singh Rawat, Himanshu Jain Andreas Veit & Sanjiv Kumar
4
+
5
+ Google Research
6
+ New York, NY
7
+ {adityakmenon,sadeep,ankitsrawat,himj,aveit,sanjivk}@google.com
8
+
9
+ # ABSTRACT
10
+
11
+ Real-world classification problems typically exhibit an imbalanced or long-tailed label distribution, wherein many labels have only a few associated samples. This poses a challenge for generalisation on such labels, and also makes naïve learning biased towards dominant labels. In this paper, we present a statistical framework that unifies and generalises several recent proposals to cope with these challenges. Our framework revisits the classic idea of logit adjustment based on the label frequencies, which encourages a large relative margin between logits of rare positive versus dominant negative labels. This yields two techniques for long-tail learning, where such adjustment is either applied post-hoc to a trained model, or enforced in the loss during training. These techniques are statistically grounded, and practically effective on four real-world datasets with long-tailed label distributions.
12
+
13
+ # 1 INTRODUCTION
14
+
15
+ Real-world classification problems typically exhibit a long-tailed label distribution, wherein most labels are associated with only a few samples (Van Horn & Perona, 2017; Buda et al., 2017; Liu et al., 2019). Owing to this paucity of samples, generalisation on such labels is challenging; moreover, naïve learning on such data is susceptible to an undesirable bias towards dominant labels. This problem has been widely studied in the literature on learning under class imbalance (Kubat et al., 1997; Chawla et al., 2002; He & Garcia, 2009), and the related problem of cost-sensitive learning (Elkan, 2001).
16
+
17
+ Recently, long-tail learning has received renewed interest in the context of neural networks. Two active strands of work involve post-hoc normalisation of the classification weights (Zhang et al., 2019; Kim & Kim, 2019; Kang et al., 2020; Ye et al., 2020), and modification of the underlying loss to account for varying class penalties (Zhang et al., 2017; Cui et al., 2019; Cao et al., 2019; Tan et al., 2020). Each of these strands are intuitive, and have proven empirically successful. However, they are not without limitation: e.g., weight normalisation crucially relies on the weight norms being smaller for rare classes; however, this assumption is sensitive to the choice of optimiser (see $\textrm { \tiny \begin{array} { r l } { \ S } & { { } \mathbf { \sigma } } \end{array} } )$ . On the other hand, loss modification sacrifices the consistency that underpins the canonical softmax cross-entropy (see $\textrm { \ s } )$ ). Consequently, such techniques may prove suboptimal even in simple settings (see $\ S 6 . 1 \ r ,$ ).
18
+
19
+ In this paper, we establish a statistical framework for long-tail learning that offers a unified view of post-hoc normalisation and loss modification techniques, while overcoming their limitations. Our framework revisits the classic idea of logit adjustment based on label frequencies (Provost, 2000; Zhou & Liu, 2006; Collell et al., 2016), which encourages a large relative margin between a pair of rare positive and dominant negative labels. Such adjustment can be achieved by shifting the learned logits post-hoc, or augmenting the softmax cross-entropy with a pairwise label margin (cf. (11)). While similar in nature to recent techniques, our logit adjustment approaches additionally have a firm statistical grounding: they are Fisher consistent for minimising the balanced error (cf. (2)), a common metric in long-tail settings which averages the per-class errors. This statistical grounding translates into strong empirical performance on four real-world datasets with long-tailed label distributions.
20
+
21
+ In summary, our contributions are:
22
+
23
+ (i) we establish a statistical framework for long-tail learning (§3) based on logit adjustment that provides a unified view of post-hoc correction and loss modification
24
+
25
+ Table 1: Comparison of approaches to long-tail learning. Weight normalisation re-scales the classification weights; by contrast, we add per-label offsets to the logits. Margin approaches uniformly increase the margin between a rare positive and all negatives (Cao et al., 2019), or decrease the margin between all positives and a rare negative (Tan et al., 2020) to prevent rare labels’ gradient suppression. By contrast, we increase the margin between a rare positive and a dominant negative.
26
+
27
+ <table><tr><td>Method</td><td>Procedure</td><td>Consistent?</td><td>?Reference</td></tr><tr><td>Weight normalisation</td><td>Post-hoc weight scaling</td><td>×</td><td>(Kang et al., 2020)</td></tr><tr><td>Adaptive margin</td><td>Softmax with rare +ve upweighting</td><td>×</td><td>(Cao et al., 2019)</td></tr><tr><td>Equalised margin</td><td>Softmax with rare -ve downweighting</td><td>×</td><td>(Tan et al., 2020)</td></tr><tr><td>Logit-adjusted threshold</td><td>1Post-hoc logit translation</td><td>√</td><td>This paper (cf. (9))</td></tr><tr><td>Logit-adjusted loss</td><td>Softmax with logit translation</td><td>√</td><td>This paper (cf.(10))</td></tr></table>
28
+
29
+ (ii) we present two realisations of logit adjustment, applied either post-hoc (§4.1) or during training (§5.1); unlike recent proposals (Table 1), these are consistent for minimising the balanced error
30
+ (iii) we confirm the efficacy of the proposed logit adjustment techniques compared to several baselines on four real-world datasets with long-tailed label distributions $( \ S 6 )$ .
31
+
32
+ # 2 PROBLEM SETUP AND RELATED WORK
33
+
34
+ Consider a multiclass classification problem with instances $\mathcal { X }$ and labels $\mathcal { Y } = [ L ] \doteq \{ 1 , 2 , \ldots , L \}$ . Given a sample $S = \{ ( x _ { n } , y _ { n } ) \} _ { n = 1 } ^ { N } \dot { \bf \Phi } \sim { \mathbb P } ^ { N }$ for unknown distribution $\mathbb { P }$ over $\mathcal X \times \mathcal Y$ , our goal is to learn a scorer $f \colon \mathcal { X } \to \mathbb { R } ^ { L }$ that minimises the misclassification error $\mathbb { P } _ { x , y } \big ( y \notin \operatorname { a r g m a x } _ { y ^ { \prime } \in \mathcal { Y } } f _ { y ^ { \prime } } ( x ) \big )$ . Typically, one minimises a surrogate loss $\ell \colon \mathcal { Y } \times \mathbb { R } ^ { L } \to \mathbb { R }$ such as the softmax cross-entropy,
35
+
36
+ $$
37
+ \ell ( y , f ( x ) ) = \log \left[ \sum _ { y ^ { \prime } \in [ L ] } e ^ { f _ { y ^ { \prime } } ( x ) } \right] - f _ { y } ( x ) = \log \left[ 1 + \sum _ { y ^ { \prime } \not = y } e ^ { f _ { y ^ { \prime } } ( x ) - f _ { y } ( x ) } \right] .
38
+ $$
39
+
40
+ We may view the resulting softmax probabilities $p _ { y } ( x ) \propto e ^ { f _ { y } ( x ) }$ as estimates of $\mathbb { P } ( y \mid x )$
41
+
42
+ The setting of learning under class imbalance or long-tail learning is where the distribution $\mathbb { P } ( y )$ is highly skewed, so that many rare (or “tail”) labels have a low probability of occurrence. Here, the misclassification error is not a suitable measure of performance: a trivial predictor which classifies every instance to the majority label will attain a low misclassification error. To cope with this, a natural alternative is the balanced error (Chan & Stolfo, 1998; Brodersen et al., 2010; Menon et al., 2013), which averages each of the per-class error rates: under a uniform label distribution
43
+
44
+ $$
45
+ \mathrm { B E R } ( f ) \doteq \frac { 1 } { L } \sum _ { y \in [ L ] } \mathbb { P } _ { x | y } \big ( y \notin \mathrm { a r g m a x } _ { y ^ { \prime } \in \mathcal { Y } } f _ { y ^ { \prime } } ( x ) \big ) .
46
+ $$
47
+
48
+ This can be seen as implicitly using a balanced class-probability function $\mathbb { P } ^ { \mathrm { b a l } } ( y \mid x ) \propto \frac { 1 } { L } \cdot \mathbb { P } ( x \mid y )$ as opposed to the native $\mathbb { P } ( y \mid x ) \propto \mathbb { P } ( y ) \cdot \mathbb { P } ( x \mid y )$ that is employed in the misclassification error.1
49
+
50
+ Broadly, extant approaches to coping with class imbalance modify:
51
+
52
+ (i) the inputs to a model, for example by over- or under-sampling (Kubat & Matwin, 1997; Chawla et al., 2002; Wallace et al., 2011; Mikolov et al., 2013; Mahajan et al., 2018; Yin et al., 2018);
53
+ (ii) the outputs of a model, for example by post-hoc correction of the decision threshold (Fawcett & Provost, 1996; Collell et al., 2016) or weights (Kim & Kim, 2019; Kang et al., 2020); or
54
+ (iii) the training procedure of a model, for example by modifying the loss function (Zhang et al., 2017; Cui et al., 2019; Cao et al., 2019; Tan et al., 2020; Jamal et al., 2020).
55
+
56
+ One may easily combine approaches from the first stream with those from the latter two. Consequently, we focus on the latter two in this work, and describe some representative recent examples from each.
57
+
58
+ Post-hoc weight normalisation. Suppose $f _ { y } ( x ) = w _ { y } ^ { \top } \Phi ( x )$ for classification weights $w _ { y } \in \mathbb { R } ^ { D }$ and representations $\Phi \colon \mathcal { X } \mathbb { R } ^ { D }$ , as learned by a neural network. (We may add per-label bias terms to $f _ { y }$ by adding a constant feature to $\Phi$ .) A fruitful avenue of exploration involves decoupling of representation and classifier learning (Zhang et al., 2019). Concretely, we first learn $\{ w _ { y } , \Phi \}$ via standard training on the long-tailed training sample $S$ , and then for $x \in { \mathcal { X } }$ predict the label
59
+
60
+ ![](images/1dc745aac064685562774527059fa985cc63ea8b3209fce8078e4627c346397c.jpg)
61
+ Figure 1: Mean and standard deviation of per-class weight norms $\| w _ { y } \| _ { 2 }$ over 5 runs for a ResNet-32 under momentum and Adam optimisers. We use long-tailed (“LT”) versions of CIFAR-10 and CIFAR-100, and sort classes in descending order of frequency; the first class is $1 0 0 \times$ more likely to appear than the last class (see $\begin{array} { r l } { \ S } & { { } \} } \end{array}$ ). Both optimisers yield comparable balanced error. However, the weight norms have incompatible trends: under momentum, the norms are strongly correlated with class frequency, while with Adam, the norms are anti-correlated or independent of the class frequency. Consequently, weight normalisation under Adam is ineffective for combatting class imbalance.
62
+
63
+ $$
64
+ \begin{array} { r } { \mathrm { a r g m a x } _ { y \in [ L ] } w _ { y } ^ { \top } \Phi ( x ) / \nu _ { y } ^ { \tau } = \mathrm { a r g m a x } _ { y \in [ L ] } f _ { y } ( x ) / \nu _ { y } ^ { \tau } , } \end{array}
65
+ $$
66
+
67
+ for $\tau > 0$ , where $\nu _ { y } = \mathbb { P } ( y )$ in Kim & Kim (2019); Ye et al. (2020) and $\nu _ { y } = \| w _ { y } \| _ { 2 }$ in Kang et al. (2020). Intuitively, either choice of $\nu _ { y }$ upweights the contribution of rare labels through weight normalisation. The choice $\nu _ { y } = \| w _ { y } \| _ { 2 }$ is motivated by the observations that $\| w _ { y } \| _ { 2 }$ tends to correlate with $\mathbb { P } ( y )$ . Further to the above, one may enforce $\| w _ { y } \| _ { 2 } = 1$ during training (Kim & Kim, 2019).
68
+
69
+ Loss modification. A classic means of coping with class imbalance is to balance the loss, wherein $\ell ( y , f ( x ) )$ is weighted by $\mathbb { P } ( y ) ^ { - 1 }$ (Xie & Manski, 1989; Morik et al., 1999): e.g., applied to (1),
70
+
71
+ $$
72
+ \ell ( y , f ( x ) ) = { \frac { 1 } { \mathbb { P } ( y ) } } \cdot \log \left[ 1 + \sum _ { y ^ { \prime } \neq y } e ^ { f _ { y ^ { \prime } } ( x ) - f _ { y } ( x ) } \right] .
73
+ $$
74
+
75
+ While intuitive, balancing has minimal effect in separable settings: solutions that achieve zero training loss will necessarily remain optimal even under weighting (Byrd $\&$ Lipton, 2019). Intuitively, one would instead like to shift the separator closer to a dominant class. Li et al. (2002); Wu et al. (2008); Masnadi-Shirazi $\&$ Vasconcelos (2010) thus proposed to add per-class margins into the hinge loss. Cao et al. (2019) similarly proposed to add a per-class margin into the softmax cross-entropy:
76
+
77
+ $$
78
+ \ell ( y , f ( x ) ) = \log \Big [ 1 + \sum _ { y ^ { \prime } \neq y } e ^ { \delta _ { y } } \cdot e ^ { f _ { y ^ { \prime } } ( x ) - f _ { y } ( x ) } \Big ] ,
79
+ $$
80
+
81
+ where $\delta _ { y } \propto \mathbb { P } ( y ) ^ { - 1 / 4 }$ . This upweights rare “positive” $y$ to encourage a larger gap $f _ { y } ( x ) - f _ { y ^ { \prime } } ( x )$ i.e., the margin between $y$ and any “negative” $y ^ { \prime } \ne y$ . Separately, Tan et al. (2020) proposed
82
+
83
+ $$
84
+ \ell ( y , f ( x ) ) = \log \Big [ 1 + \sum _ { y ^ { \prime } \neq y } e ^ { \delta _ { y ^ { \prime } } } \cdot e ^ { f _ { y ^ { \prime } } ( x ) - f _ { y } ( x ) } \Big ] ,
85
+ $$
86
+
87
+ where $\delta _ { y ^ { \prime } } \leq 0$ is a non-decreasing transform of $\mathbb { P } ( y ^ { \prime } )$ . Note that in the original softmax cross-entropy with $\delta _ { y ^ { \prime } } = 0$ , a rare label often receives a strong inhibitory gradient signal as it disproportionately appear as a negative for dominant labels. This can be modulated by letting $\delta _ { y ^ { \prime } } \ll 0$ .
88
+
89
+ # 2.1 LIMITATIONS OF EXISTING APPROACHES
90
+
91
+ Each of the above methods are intuitive, and have shown strong empirical performance. However, a closer analysis identifies some subtle limitations.
92
+
93
+ Limitations of weight normalisation. Post-hoc weight normalisation with $\nu _ { y } = \| w _ { y } \| _ { 2 }$ per Kang et al. (2020) is motivated by the observation that the weight norm $\| w _ { y } \| _ { 2 }$ tends to correlate with $\mathbb { P } ( y )$ However, this assumption is highly dependent on the choice of optimiser, as Figure 1 illustrates: for
94
+
95
+ ResNet-32 models trained on long-tailed versions of CIFAR-10 and CIFAR-100, when using the Adam optimiser, the norms are either anti-correlated or independent of $\mathbb { P } ( y )$ . Weight normalisation thus cannot achieve the desired effect of boosting rare labels’ scores. One may hope to side-step this by simply using $\nu _ { y } = \mathbb { P } ( y )$ ; unfortunately, this choice has more subtle limitations (see $\ S 4 . 2$ ).
96
+
97
+ Limitations of loss modification. Enforcing a per-label margin per (5) and (6) is intuitive, as it allows for shifting the decision boundary away from rare classes. However, when doing so, it is important to ensure Fisher consistency (Lin, 2004) (or classification calibration (Bartlett et al., 2006)) of the resulting loss for the balanced error. That is, the minimiser of the expected loss (equally, the empirical risk in the infinite sample limit) should result in a minimal balanced error. Unfortunately, both (5) and (6) are not consistent in this sense, even for binary problems; see $\ S 5 . 1$ , $\ S 6 . 1$ for details.
98
+
99
+ # 3 LOGIT ADJUSTMENT FOR LONG-TAIL LEARNING: A STATISTICAL VIEW
100
+
101
+ The above suggests that there is scope for improving performance on long-tail problems, both in terms of post-hoc correction and loss modification. We now show how a statistical perspective suggests simple procedures of each type, both of which overcome the limitations discussed above.
102
+
103
+ Recall that our goal is to minimise the balanced error (2). A classical result is that the best possible or Bayes-optimal scorer for this problem, i.e., $f ^ { * } \in \mathrm { a r g m i n } _ { f }$ : $\mathcal { X } { } \mathbb { R } ^ { L } \operatorname { B E R } ( f )$ , satisfies the following (Menon et al., 2013), (Koyejo et al., 2014, Corollary 4), (Collell et al., 2016, Theorem 1):
104
+
105
+ $$
106
+ \begin{array} { r } { \operatorname * { a r g m a x } _ { y \in [ L ] } f _ { y } ^ { * } ( x ) = \operatorname * { a r g m a x } _ { y \in [ L ] } \mathbb { P } ^ { \mathrm { b a l } } ( y \mid x ) = \operatorname * { a r g m a x } _ { y \in [ L ] } \mathbb { P } ( x \mid y ) , } \end{array}
107
+ $$
108
+
109
+ where $\mathbb { P } ^ { \mathrm { b a l } }$ is the balanced class-probability as per $\ S 2$ . In words, the Bayes-optimal prediction is the label under which the given instance $x \in { \mathfrak { X } }$ is most likely. Consequently, for fixed class-conditionals $\mathbb { P } ( x \mid y )$ , varying the class priors $\mathbb { P } ( y )$ arbitrarily will not affect the optimal scorers. This is intuitively desirable: the balanced error is agnostic to the level of imbalance in the label distribution.
110
+
111
+ To further probe (7), suppose the underlying class-probabilities $\mathbb { P } ( y \mid x ) \propto \exp ( s _ { y } ^ { * } ( x ) )$ , for scorer $s ^ { * } \colon \mathcal { X } \to \mathbb { R } ^ { L }$ . Since by definition $\mathbb { P } ^ { \mathrm { b a l } } ( y \mid x ) \propto \mathbb { P } ( y \mid x ) / \mathbb { P } ( y )$ , (7) becomes
112
+
113
+ $$
114
+ \begin{array} { r } { \mathrm { a r g m a x } _ { y \in [ L ] } \mathbb { P } ^ { \mathrm { b a l } } ( y \mid x ) = \mathrm { a r g m a x } _ { y \in [ L ] } \exp ( s _ { y } ^ { * } ( x ) ) / \mathbb { P } ( y ) = \mathrm { a r g m a x } _ { y \in [ L ] } s _ { y } ^ { * } ( x ) - \ln \mathbb { P } ( y ) , } \end{array}
115
+ $$
116
+
117
+ i.e., we translate the optimal logits based on the class priors. Equation 8 provides the ideal predictions for optimising the balanced error, which necessarily rely on unknown quantities $s _ { y } ^ { * } ( x ) , \mathbb { P } ( y )$ that depend on the underlying distribution. Nonetheless, we may seek to approximate these quantities based on our training sample. Concretely, (8) suggests two means of optimising for the balanced error:
118
+
119
+ (i) train a model to estimate the standard $\mathbb { P } ( y \mid x )$ (e.g., by minimising the standard softmax-cross entropy on the long-tailed data), and then explicitly modify its logits post-hoc as per (8) (ii) train a model to estimate the balanced $\mathbb { P } ^ { \mathrm { b a l } } ( y \mid x )$ , whose logits are implicitly modified as per (8).
120
+
121
+ Such logit adjustment techniques — which have been a classic approach to class-imbalance (Provost, 2000) — neatly align with the post-hoc and loss modification streams discussed in $\ S$ . However, unlike most previous techniques from these streams, logit adjustment is endowed with a clear statistical grounding: by construction, the optimal solution under such adjustment coincides with the Bayes-optimal solution (7) for the balanced error, i.e., it is Fisher consistent for minimising the balanced error. We now study each of the techniques (i) and (ii) in turn.
122
+
123
+ # 4 POST-HOC LOGIT ADJUSTMENT
124
+
125
+ We now propose a post-hoc logit adjustment scheme for a classifier trained on long-tailed data. We further show this has subtle advantages over recent weight normalisation schemes.
126
+
127
+ # 4.1 THE POST-HOC LOGIT ADJUSTMENT PROCEDURE
128
+
129
+ When employing the softmax cross-entropy to train a neural network, we aim to approximate the underlying $\mathbb { P } ( y \mid x )$ with $p _ { y } ( x ) \propto \exp ( f _ { y } ( { \bar { x } } ) )$ for logits $f _ { y } ( x ) = w _ { y } ^ { \top } \Phi ( x )$ . Given learned $\{ w , \Phi \}$ ,
130
+
131
+ one typically predicts the label $\mathrm { a r g m a x } _ { y \in [ L ] } f _ { y } ( x )$ , i.e., the most likely label under the model’s $\mathbb { P } ( y \mid x )$ . In post-hoc logit adjustment, we propose to instead predict, for suitable $\tau > 0$ :
132
+
133
+ $$
134
+ \begin{array} { r } { \mathrm { a r g m a x } _ { y \in [ L ] } \exp ( w _ { y } ^ { \top } \Phi ( x ) ) / \pi _ { y } ^ { \tau } = \mathrm { a r g m a x } _ { y \in [ L ] } f _ { y } ( x ) - \tau \cdot \log \pi _ { y } , } \end{array}
135
+ $$
136
+
137
+ where $\pi \in \Delta _ { L }$ (for simplex $\Delta$ ) are estimates of the class priors $\mathbb { P } ( y )$ , e.g., the empirical frequencies on the training sample $S$ . Effectively, (9) adds a label-dependent offset to each of the logits.
138
+
139
+ When $\tau = 1$ , this can be seen as applying (8) with a plugin estimate of $\mathbb { P } ( y \mid x )$ , i.e., $p _ { y } ( x ) \propto$ $\exp ( w _ { y } ^ { \top } \Phi ( x ) )$ . When $\tau \neq 1$ , this can be seen as applying (8) to temperature scaled estimates $\bar { p } _ { y } ( x ) \overset { \cdot } { \propto } \exp ( \tau ^ { - 1 } \cdot w _ { y } ^ { \top } \Phi ( x ) )$ . To unpack this, recall that (8) justifies post-hoc logit thresholding given access to the true probabilities $\mathbb { P } ( y \mid x )$ . In practice, high-capacity neural networks often produce uncalibrated estimates of these probabilities (Guo et al., 2017). Temperature scaling is a means to calibrate the estimates, and is routinely employed for distillation (Hinton et al., 2015).
140
+
141
+ One may treat $\tau$ as a tuning parameter to be chosen based on holdout calibration, e.g., the expected calibration error (Murphy & Winkler, 1987; Guo et al., 2017), probabilistic sharpness (Gneiting et al., 2007; Kuleshov et al., 2018), or a proper scoring rule such as the log-loss or squared error (Gneiting & Raftery, 2007). One may alternately fix $\tau = 1$ and aim to learn inherently calibrated probabilities, e.g., via label smoothing (Szegedy et al., 2016; Müller et al., 2019).
142
+
143
+ Post-hoc logit adjustment with $\tau = 1$ is not a new idea in the classical label imbalance literature (Fawcett & Provost, 1996; Provost, 2000; Maloof, 2003; Zhou & Liu, 2006; Collell et al., 2016); however, it has had limited exploration in the recent long-tail learning literature. Further, the case $\tau \neq 1$ is important in practical usage of neural networks, owing to their typical lack of probabilistic calibration (Guo et al., 2017). Interestingly, post-hoc logit adjustment also has an important advantage over recently proposed weight normalisation techniques, as we now discuss.
144
+
145
+ # 4.2 COMPARISON TO POST-HOC WEIGHT NORMALISAITON
146
+
147
+ Recall that weight normalisation involves learning logits $f _ { y } ( x ) = w _ { y } ^ { \top } \Phi ( x )$ , and then post-hoc normalising the weights via $w _ { y } / \nu _ { y } ^ { \tau }$ for $\tau > 0$ . We demonstrated in $\ S$ that using $\nu _ { y } = \| w _ { y } \| _ { 2 }$ may be ineffective when using adaptive optimisers. However, even with $\nu _ { y } = \pi _ { y }$ , there is a subtle contrast to post-hoc logit adjustment: while the former performs a multiplicative update to the logits, the latter performs an additive update. The two techniques may thus yield different orderings over labels, since
148
+
149
+ $$
150
+ w _ { 1 } ^ { \top } \Phi ( x ) / \pi _ { 1 } < w _ { 2 } ^ { \top } \Phi ( x ) / \pi _ { 2 } \stackrel { } { } \exp ( w _ { 1 } ^ { \top } \Phi ( x ) ) / \pi _ { 1 } < \exp ( w _ { 2 } ^ { \top } \Phi ( x ) ) / \pi _ { 2 } .
151
+ $$
152
+
153
+ Observe that if a rare label $y$ has a negative score $w _ { y } ^ { \top } \Phi ( x ) < 0$ , and there is another label with a positive score, then it is impossible for the weight normalisation to give $y$ the highest score. By contrast, under logit adjustment, $w _ { y } ^ { \top } \Phi ( x ) - \ln \pi _ { y }$ will be lower for dominant classes, regardless of the original sign. Weight normalisation is thus not consistent for the balanced error, unlike logit adjustment.
154
+
155
+ # 5 THE LOGIT ADJUSTED SOFTMAX CROSS-ENTROPY
156
+
157
+ We now show how to directly encode logit adjustment into the softmax cross-entropy. The resulting approach has an intuitive relation to existing loss modification techniques.
158
+
159
+ # 5.1 THE LOGIT ADJUSTED LOSS
160
+
161
+ From $\ S$ , the second approach to optimising for the balanced error is to directly model $\mathbb { P } ^ { \mathrm { b a l } } ( y \mid x ) \propto$ $\mathbb { P } ( y \mid x ) / \mathbb { P } ( y )$ . To do so, consider the following logit adjusted softmax cross-entropy loss for $\tau > 0$ :
162
+
163
+ $$
164
+ \ell ( y , f ( x ) ) = - \log { \frac { e ^ { f _ { y } ( x ) + \tau \cdot \log { \pi _ { y } } } } { \sum _ { y ^ { \prime } \in [ L ] } e ^ { f _ { y ^ { \prime } } ( x ) + \tau \cdot \log { \pi _ { y ^ { \prime } } } } } } = \log \left[ 1 + \sum _ { y ^ { \prime } \neq y } \left( { \frac { \pi _ { y ^ { \prime } } } { \pi _ { y } } } \right) ^ { \tau } \cdot e ^ { f _ { y ^ { \prime } } ( x ) - f _ { y } ( x ) } \right] .
165
+ $$
166
+
167
+ Given a scorer that minimises the above, we now predict $\mathrm { a r g m a x } _ { y \in [ L ] } f _ { y } ( x )$ as usual.
168
+
169
+ Compared to the standard softmax cross-entropy (1), the above applies a label-dependent offset to each logit. Compared to (9), we directly enforce the class prior offset while learning the logits, rather than doing this post-hoc. The two approaches have a deeper connection: observe that (10) is equivalent to using a scorer of the form $g _ { y } ( x ) = f _ { y } ( x ) + \tau \cdot \log \pi _ { y }$ , with $\mathrm { a r g m a x } _ { y \in [ L ] } f _ { y } ( x ) =$ $\mathrm { a r g m a x } _ { y \in [ L ] } g _ { y } ( x ) - \tau \cdot \log \pi _ { y }$ . Consequently, one can equivalently view learning with this loss as learning a standard scorer $g ( x )$ , and post-hoc adjusting its logits. For non-convex objectives, as encountered in neural networks, the bias endowed by adding $\tau \cdot \log \pi _ { y }$ to the logits is likely to result in a different local minima, typically with improved performance.
170
+
171
+ # 5.2 COMPARISON TO LOSS MODIFICATION TECHNIQUES
172
+
173
+ For more insight into the logit adjusted loss, consider the following pairwise margin loss
174
+
175
+ $$
176
+ \ell ( y , f ( x ) ) = \alpha _ { y } \cdot \log { \Big [ 1 + \sum _ { y ^ { \prime } \neq y } e ^ { \Delta _ { y y ^ { \prime } } } \cdot e ^ { ( f _ { y ^ { \prime } } ( x ) - f _ { y } ( x ) ) } \Big ] } ,
177
+ $$
178
+
179
+ for label weights $\alpha _ { y } > 0$ , and pairwise label margins $\Delta _ { y y ^ { \prime } }$ representing the desired gap between scores for $y$ and $y ^ { \prime }$ . For $\tau = 1$ , our logit adjusted loss (10) corresponds to (11) with $\alpha _ { y } = 1$ and $\begin{array} { r } { \Delta _ { y y ^ { \prime } } = \log { \left( \frac { \pi _ { y ^ { \prime } } } { \pi _ { y } } \right) } } \end{array}$ . This demands a larger margin between rare positive $( \pi _ { y } \sim 0 )$ ) and dominant negative $\mathit { \Pi } _ { \pi _ { y ^ { \prime } } } \sim 1 $ ) labels, so that scores for dominant classes do not overwhelm those for rare ones.
180
+
181
+ Existing loss modification techniques can be viewed as special cases of (11). For example, $\alpha _ { y } =$ $1 / \pi _ { y }$ and $\Delta _ { y y ^ { \prime } } = 0$ yields the balanced loss (4). When $\alpha _ { y } ~ = ~ 1$ , the choice $\Delta _ { y y ^ { \prime } } = \pi _ { y } ^ { - 1 / 4 }$ yields (5). Finally, $\bar { \Delta _ { y y ^ { \prime } } } = \log F ( \pi _ { y ^ { \prime } } )$ yields (6), where $F \colon [ 0 , 1 ] ( 0 , 1 ]$ is some non-decreasing function. These losses thus either consider the frequency of the positive $y$ or negative $y ^ { \prime }$ , but not both. Remarkably, the specific choice that leads to our loss in (10) has a firm statistical grounding: it ensures Fisher consistency (in the sense of, e.g., Bartlett et al. (2006)) for the balanced error. Proofs for all results are in the supplementary.
182
+
183
+ Theorem 1. For any $\delta \in \mathbb { R } _ { + } ^ { L }$ , the pairwise loss in (11) is Fisher consistent with weights and margins
184
+
185
+ $$
186
+ \begin{array} { r } { \alpha _ { y } = \delta _ { y } / \mathbb { P } ( y ) \qquad \Delta _ { y y ^ { \prime } } = \log \left( \delta _ { y ^ { \prime } } / \delta _ { y } \right) . } \end{array}
187
+ $$
188
+
189
+ Letting $\delta _ { y } = \pi _ { y }$ , we immediately deduce that the logit-adjusted loss of (10) is consistent, provided our $\pi _ { y }$ is a consistent estimate of $\mathbb { P } ( y )$ . Similarly, $\delta _ { y } = 1$ recovers the classic result that the balanced loss is consistent. While Theorem 1 only provides a sufficient condition in multi-class setting, one can provide a necessary and sufficient condition that rules out other choices of $\Delta$ in the binary case.
190
+
191
+ Theorem 2. Suppose $\mathcal { Y } = \{ \pm 1 \}$ . Let $\delta _ { y } \doteq \Delta _ { y , - y }$ , and $\sigma ( z ) = ( 1 + \exp ( z ) ) ^ { - 1 }$ . Then, the pairwise margin loss in (11) is Fisher consistent for the balanced error iff
192
+
193
+ $$
194
+ \frac { \alpha _ { + 1 } } { \alpha _ { - 1 } } \cdot \frac { \sigma ( \delta _ { + 1 } ) } { \sigma ( \delta _ { - 1 } ) } = \frac { 1 - \mathbb { P } ( y = + 1 ) } { \mathbb { P } ( y = + 1 ) } .
195
+ $$
196
+
197
+ # 5.3 DISCUSSION AND EXTENSIONS
198
+
199
+ Our pairwise margin loss in (11) subsumes several existing loss-correction approaches in the literature. Further, it suggests the exploration of new choices of $\Delta$ . For example, we shall see the efficacy of combining the $\Delta$ implicit in the adaptive loss of Cao et al. (2019) with our proposed $\Delta$ . One may also generalise the formulation in Theorem 1, and employ $\Delta _ { y y ^ { \prime } } = \tau _ { 1 } \cdot \log \pi _ { y } - \tau _ { 2 } \cdot \log \pi _ { y ^ { \prime } }$ , where $\tau _ { 1 } , \tau _ { 2 } > 0$ . This interpolates between our loss $\tau _ { 1 } = \tau _ { 2 }$ ) and a version of the equalised loss $\mathit { \check { \tau } _ { 1 } = 0 }$ ).
200
+
201
+ For $\tau = - 1$ , a similar loss to (10) has been considered in the context of negative sampling for scalability (Yi et al., 2019): here, one samples a subset of negatives based on $\pi$ , and corrects the logits to obtain an unbiased estimate of the loss based on all negatives (Bengio & Senecal, 2008). Losses of the general form (11) have also been explored for structured prediction (Pletscher et al., 2010).
202
+
203
+ Cao et al. (2019, Theorem 2) provides a rigorous generalisation bound for the adaptive margin loss under the assumption of separable data with binary labels. The inconsistency of the loss with respect to the balanced error concerns the more general scenario of non-separable multiclass data, which may occur, e.g., owing to label noise or limited model capacity. We shall subsequently demonstrate that encouraging consistency is not merely of theoretical interest, and can lead to gains in practice.
204
+
205
+ ![](images/d5ece5aaec500d4cbc5888f90db3ae7b03cb3dd2bb2e79418b830e3cfca8796e.jpg)
206
+ Figure 2: Results on synthetic binary classification problem. Our logit adjusted loss tracks the Bayes-optimal solution and separator (left & middle panel). Post-hoc logit adjustment matches the Bayes performance with suitable scaling (right panel); however, any weight normalisation fails.
207
+
208
+ # 6 EXPERIMENTAL RESULTS
209
+
210
+ We now present experiments confirming our main claims: (i) on simple binary problems, existing weight normalisation and loss modification techniques may not converge to the optimal solution (§6.1); (ii) on real-world datasets, our post-hoc logit adjustment generally outperforms weight normalisation, and one can obtain further gains via our logit adjusted softmax cross-entropy $( \ S 6 . 2 )$ .
211
+
212
+ # 6.1 RESULTS ON SYNTHETIC DATASET
213
+
214
+ We begin with a binary classification task, wherein samples from class $y \in \{ \pm 1 \}$ are drawn from a 2D Gaussian with isotropic covariance and means $\mu _ { y } = y \cdot ( + 1 , + 1 )$ . We introduce class imbalance by setting $\mathbb { P } ( y = + 1 ) = \bar { 5 } \%$ . The Bayes-optimal classifier for the balanced error is (see Appendix F)
215
+
216
+ $$
217
+ f ^ { * } ( x ) = + 1 \ \Longleftrightarrow \ \mathbb { P } ( x \mid y = + 1 ) > \mathbb { P } ( x \mid y = - 1 ) \ \Longleftrightarrow \ ( \mu _ { 1 } - \mu _ { - 1 } ) ^ { \top } x > 0 ,
218
+ $$
219
+
220
+ i.e., it is a linear separator passing through the origin. We compare this separator against those found by several margin losses based on (11): standard ERM $\Delta _ { y y ^ { \prime } } = 0 \rangle$ , the adaptive loss (Cao et al., 2019) $( \Delta _ { y y ^ { \prime } } = \pi _ { y } ^ { - 1 / 4 } )$ −1/4y ), an instantiation of the equalised loss (Tan et al., 2020) (∆yy0 = log πy0 ), and our logit adjusted loss $\begin{array} { r } { ( \Delta _ { y y ^ { \prime } } = \log { \frac { \pi _ { y ^ { \prime } } } { \pi _ { y } } } ) } \end{array}$ ). For each loss, we train an affine classifier on a sample of $1 0 , 0 0 0$ instances, and evaluate the balanced error on a test set of 10, 000 samples over 100 independent trials.
221
+
222
+ Figure 2 confirms that the logit adjusted margin loss attains a balanced error close to that of the Bayes-optimal, which is visually reflected by its learned separator closely matching that in (12). This is in line with our claim of the logit adjusted margin loss being consistent for the balanced error, unlike other approaches. Figure 2 also compares post-hoc weight normalisation and logit adjustment for varying scaling parameter $\tau$ (c.f. (3), (9)). Logit adjustment is seen to approach the performance of the Bayes predictor; any weight normalisation is however seen to hamper performance. This verifies the consistency of logit adjustment, and inconsistency of weight normalisation (§4.2).
223
+
224
+ # 6.2 RESULTS ON REAL-WORLD DATASETS
225
+
226
+ We present results on the CIFAR-10, CIFAR-100, ImageNet and iNaturalist 2018 datasets. Following prior work, we create “long-tailed versions” of the CIFAR datasets by suitably downsampling examples per label following the EXP profile of Cui et al. (2019); Cao et al. (2019) with imbalance ratio $\rho = \mathrm { m a x } _ { y } \mathbb { P } ( y ) / \mathrm { m i n } _ { y } \mathbb { P } ( y ) = 1 0 0$ . Similarly, we use the long-tailed version of ImageNet produced by Liu et al. (2019). We employ a ResNet-32 for CIFAR, and a ResNet-50 for ImageNet and iNaturalist. All models are trained using SGD with momentum; see Appendix C for more details. See also Appendix D.3 for results on CIFAR under the STEP profile also considered in the literature.
227
+
228
+ Baselines. We consider several representative baselines: (i) empirical risk minimisation (ERM) on the long-tailed data, (ii) post-hoc weight normalisation (Kang et al., 2020) per (3) (using $\nu _ { y } = \| w _ { y } \| _ { 2 } )$ applied to ERM, (iii) the class-balanced loss of Cui et al. (2019), (iv) the adaptive margin loss (Cao et al., 2019) per (5), including with the “deferred reweighting” (DRW) training scheme, and (v) the equalised loss (Tan et al., 2020) per (6), with $\delta _ { y ^ { \prime } } = F ( \pi _ { y ^ { \prime } } )$ for the threshold-based $F$ of Tan et al. (2020). Where possible, we report numbers for the baselines from the respective papers.
229
+
230
+ Table 2: Test set balanced error (averaged over 5 trials) on real-world datasets. Here, $^ { \dag } , ^ { \star } , ^ { \ddag }$ are numbers for $\mathrm { \cdot _ { L D A M } + S G D ^ { \mathrm { 3 } } }$ and “LDAM $^ +$ DRW” from Cao et al. (2019, Table 2, 3); “ $\tau$ -normalised” from Kang et al. (2020, Table 3, 7); and “Class-Balanced” from Cui et al. (2019, Table 2, 3). Here, $\tau = \tau ^ { * }$ refers to using the best possible tuning parameter $\tau$ ; see Figure 3 for results on various $\tau$ . Highlighted cells denote the best performing method for a given dataset.
231
+
232
+ <table><tr><td>Method</td><td>CIFAR-10-LT</td><td>CIFAR-100-LT</td><td>ImageNet-LT</td><td>iNaturalist</td></tr><tr><td>ERM</td><td>27.16</td><td>61.64</td><td>53.11</td><td>38.66</td></tr><tr><td>Weight normalisation (T = 1) (Kang et al., 2020)</td><td>24.02</td><td>58.89</td><td>52.00</td><td>48.05</td></tr><tr><td>Weight normalisation (T = T*) (Kang et al., 2020)</td><td>21.50</td><td>58.76</td><td>49.37</td><td>34.40*</td></tr><tr><td>Class-balanced (Cui et al., 2019)</td><td>25.43t</td><td>60.40t</td><td>53.21</td><td>35.84</td></tr><tr><td>Adaptive (Cao et al., 2019)</td><td>26.65t</td><td>60.40†</td><td>52.15</td><td>33.31</td></tr><tr><td>Adaptive + DRW (Cao et al., 2019)</td><td>22.97†</td><td>57.96†</td><td>49.85</td><td>32.00t</td></tr><tr><td>Equalised (Tan et al., 2020)</td><td>26.02</td><td>57.26</td><td>54.02</td><td>38.37</td></tr><tr><td>Logit adjustment post-hoc (T = 1)</td><td>22.60</td><td>58.24</td><td>49.66</td><td>33.98</td></tr><tr><td>Logit adjustment loss (T = 1)</td><td>22.33</td><td>56.11</td><td>48.89</td><td>33.64</td></tr><tr><td>Logit adjustment plus adaptive loss (T = 1)</td><td>22.42</td><td>55.92</td><td>51.25</td><td>31.56</td></tr></table>
233
+
234
+ ![](images/74e26c26f1a23542e6515fa23b4dc72fe3738006d3a1dc5c7739e6e92a4c48d3.jpg)
235
+ Figure 3: Comparison of balanced error for post-hoc correction techniques when varying scaling parameter $\tau$ (c.f. (3), (9)). Post-hoc logit adjustment consistently outperforms weight normalisation.
236
+
237
+ We compare the above methods against our proposed post-hoc logit adjustment (9), and logit adjusted loss (10). For post-hoc logit adjustment, we fix the scalar $\tau = 1$ for our basic results; we analyse the effect of tuning this in Figure 3. We additionally evaluate a combination of our logit adjusted softmax cross-entropy with the adaptive margin of Cao et al. (2019); this uses (11) with $\Delta _ { y y ^ { \prime } } = \log ( \pi _ { y ^ { \prime } } / \pi _ { y } ) + \pi _ { y } ^ { - 1 / 4 }$ . We do not perform any further tuning of our techniques. For all methods, we report the balanced error on the test set. (Note that since the test sets are all balanced for these benchmarks, the balanced error is equivalent to the misclassification error.) For all methods, we pre-compute $\pi$ as the empirical label frequency on the entire training set.
238
+
239
+ Results and analysis. Table 2 demonstrates that our proposed logit adjustment techniques consistently outperform existing methods. Indeed, weight normalisation with $\tau = 1$ is generally improved significantly by post-hoc logit adjustment (e.g., $8 \%$ relative reduction on CIFAR-10). Similarly, loss correction techniques are generally outperformed by our logit adjusted softmax cross-entropy (e.g., $6 \%$ relative reduction on iNaturalist). Cao et al. (2019) observed that their loss benefits from a deferred reweighting scheme (DRW), wherein class-weighting is applied after a fixed number of epochs. Table 2 indicates this is consistently outperformed by suitable variants of logit adjustment.
240
+
241
+ Table 2 only reports the results for logit adjustment with scalar $\tau = 1$ . In practice, tuning $\tau$ can significantly improve performance further. Figure 3 studies the effect of tuning $\tau$ for post-hoc weight normalisation (using $\nu _ { y } = \| w _ { y } \| _ { 2 } )$ and post-hoc logit adjustment. Even without any scaling, post-hoc logit adjustment generally offers superior performance to the best result from weight normalisation (cf. Table 2); with scaling, this is further improved. In practice, one may choose $\tau$ via cross-validation against the balanced error on the training set. For example, on CIFAR-10-LT, we estimate $\tau ^ { * } = 2 . 6$ for post-hoc logit adjustment, for which the resulting balanced test error of $\mathbf { 1 8 . 7 3 \% }$ is superior to that of weight normalisation for any $\tau$ .
242
+
243
+ To better understand the gains, Figure 4 reports errors on a per-group basis, where following Kang et al. (2020) we construct three groups of classes — “Many”, “Medium”, and “Few” — comprising those with $\geq 1 0 0$ , between (20, 100), and $\leq 2 0$ training examples respectively. Logit adjustment shows consistent gains over the “Medium” and “Few” groups, albeit at some expense in “Many” group performance. See Appendix D.2 for a finer-grained breakdown.
244
+
245
+ ![](images/9ef2005bd4d0f67c2918199cd284023728af760585f0d429f5761a955297d9b0.jpg)
246
+ Figure 4: Comparison of per-group errors for loss modification techniques. We construct three groups of classes: “Many”, comprising those with at least 100 training examples; “Medium”, comprising those with at least 20 and at most 100 training examples; and “Few”, comprising those with at most 20 training examples.
247
+
248
+ While both logit adjustment techniques perform similarly, there is a slight advantage to the loss function version. Nonetheless, the strong performance of post-hoc logit adjustment corroborates the ability to decouple representation and classifier learning in long-tail settings (Zhang et al., 2019). A reference implementation of our methods is planned for release at:
249
+
250
+ https://github.com/google-research/google-research/tree/master/logit_adjustment.
251
+
252
+ # 7 DISCUSSION AND FUTURE WORK
253
+
254
+ Table 2 shows the advantage of logit adjustment over recent proposals, under standard setups from the literature. Further improvements are possible by fusing complementary ideas, and we remark on a few such options. First, one may use a more complex base architecture; e.g., Kang et al. (2020) found gains by employing a ResNet-152, and training for 200 epochs. Table 3 (Appendix) confirms that logit adjustment similarly benefits from this choice, achieving a balanced error of $\mathbf { 3 0 . 1 2 \% }$ on iNaturalist, and $\mathbf { 2 8 . 0 2 \% }$ when combined with the adaptive margin. Second, the DRW training scheme (which applies to any loss) may result in further gains for our techniques. Third, incorporating developments in meta-learning (Wang et al., 2017; Jamal et al., 2020) is also a promising avenue. While further exploring such variants are of empirical interest, we hope to have illustrated the conceptual and empirical value of logit adjustment, and leave this for future work.
255
+
256
+ # REFERENCES
257
+
258
+ Peter L. Bartlett, Michael I. Jordan, and Jon D. McAuliffe. Convexity, classification, and risk bounds. Journal of the American Statistical Association, 101(473):138–156, 2006.
259
+ Y. Bengio and J. S. Senecal. Adaptive importance sampling to accelerate training of a neural probabilistic language model. Trans. Neur. Netw., 19(4):713–722, April 2008. ISSN 1045-9227.
260
+ Kay H. Brodersen, Cheng Soon Ong, Klaas E. Stephan, and Joachim M. Buhmann. The balanced accuracy and its posterior distribution. In Proceedings of the International Conference on Pattern Recognition (ICPR), pp. 3121–3124, Aug 2010.
261
+ Mateusz Buda, Atsuto Maki, and Maciej A. Mazurowski. A systematic study of the class imbalance problem in convolutional neural networks. arXiv:1710.05381 [cs, stat], October 2017.
262
+ Jonathon Byrd and Zachary Chase Lipton. What is the effect of importance weighting in deep learning? In Proceedings of the 36th International Conference on Machine Learning, ICML 2019, 9-15 June 2019, Long Beach, California, USA, pp. 872–881, 2019.
263
+ Kaidi Cao, Colin Wei, Adrien Gaidon, Nikos Arechiga, and Tengyu Ma. Learning imbalanced datasets with label-distribution-aware margin loss. In Advances in Neural Information Processing Systems, 2019.
264
+
265
+ Philip K. Chan and Salvatore J. Stolfo. Learning with non-uniform class and cost distributions: Effects and a distributed multi-classifier approach. In KDD-98 Workshop on Distributed Data Mining, 1998.
266
+
267
+ Nitesh V. Chawla, Kevin W. Bowyer, Lawrence O. Hall, and W. Philip Kegelmeyer. SMOTE: Synthetic minority over-sampling technique. Journal of Artificial Intelligence Research (JAIR), 16: 321–357, 2002.
268
+
269
+ Guillem Collell, Drazen Prelec, and Kaustubh R. Patil. Reviving threshold-moving: a simple plug-in bagging ensemble for binary and multiclass imbalanced data. CoRR, abs/1606.08698, 2016.
270
+
271
+ Yin Cui, Menglin Jia, Tsung-Yi Lin, Yang Song, and Serge Belongie. Class-balanced loss based on effective number of samples. In CVPR, 2019.
272
+
273
+ Charles Elkan. The foundations of cost-sensitive learning. In Proceedings of the International Joint Conference on Artificial Intelligence (IJCAI), 2001.
274
+
275
+ Tom Fawcett and Foster Provost. Combining data mining and machine learning for effective user profiling. In Proceedings of the ACM SIGKDD International Conference on Knowledge Discovery and Data Mining (KDD), pp. 8–13. AAAI Press, 1996.
276
+
277
+ Tilmann Gneiting and Adrian E Raftery. Strictly proper scoring rules, prediction, and estimation. Journal of the American Statistical Association, 102(477):359–378, 2007.
278
+
279
+ Tilmann Gneiting, Fadoua Balabdaoui, and Adrian E. Raftery. Probabilistic forecasts, calibration and sharpness. Journal of the Royal Statistical Society: Series B (Statistical Methodology), 69(2): 243–268, 2007.
280
+
281
+ Priya Goyal, Piotr Dollár, Ross Girshick, Pieter Noordhuis, Lukasz Wesolowski, Aapo Kyrola, Andrew Tulloch, Yangqing Jia, and Kaiming He. Accurate, large minibatch sgd: Training imagenet in 1 hour. arXiv preprint arXiv:1706.02677, 2017.
282
+
283
+ Chuan Guo, Geoff Pleiss, Yu Sun, and Kilian Q. Weinberger. On calibration of modern neural networks. In Proceedings of the 34th International Conference on Machine Learning, ICML 2017, Sydney, NSW, Australia, 6-11 August 2017, pp. 1321–1330, 2017.
284
+
285
+ Haibo He and Edwardo A. Garcia. Learning from imbalanced data. IEEE Transactions on Knowledge and Data Engineering, 21(9):1263–1284, 2009.
286
+
287
+ K. He, X. Zhang, S. Ren, and J. Sun. Deep residual learning for image recognition. In 2016 IEEE Conference on Computer Vision and Pattern Recognition (CVPR), 2016.
288
+
289
+ Geoffrey E. Hinton, Oriol Vinyals, and Jeffrey Dean. Distilling the knowledge in a neural network. CoRR, abs/1503.02531, 2015.
290
+
291
+ Muhammad Abdullah Jamal, Matthew Brown, Ming-Hsuan Yang, Liqiang Wang, and Boqing Gong. Rethinking class-balanced methods for long-tailed visual recognition from a domain adaptation perspective, 2020.
292
+
293
+ Bingyi Kang, Saining Xie, Marcus Rohrbach, Zhicheng Yan, Albert Gordo, Jiashi Feng, and Yannis Kalantidis. Decoupling representation and classifier for long-tailed recognition. In Eighth International Conference on Learning Representations (ICLR), 2020.
294
+
295
+ Byungju Kim and Junmo Kim. Adjusting decision boundary for class imbalanced learning, 2019.
296
+
297
+ Vladimir Koltchinskii, Dmitriy Panchenko, and Fernando Lozano. Some new bounds on the generalization error of combined classifiers. In T. K. Leen, T. G. Dietterich, and V. Tresp (eds.), Advances in Neural Information Processing Systems 13, pp. 245–251. MIT Press, 2001.
298
+
299
+ Oluwasanmi Koyejo, Nagarajan Natarajan, Pradeep Ravikumar, and Inderjit S. Dhillon. Consistent binary classification with generalized performance metrics. In Proceedings of the 27th International Conference on Neural Information Processing Systems - Volume 2, NIPS’14, pp. 2744–2752, Cambridge, MA, USA, 2014. MIT Press.
300
+
301
+ Miroslav Kubat and Stan Matwin. Addressing the curse of imbalanced training sets: One-sided selection. In Proceedings of the International Conference on Machine Learning (ICML), 1997.
302
+
303
+ Miroslav Kubat, Robert Holte, and Stan Matwin. Learning when negative examples abound. In Maarten van Someren and Gerhard Widmer (eds.), Proceedings of the European Conference on Machine Learning (ECML), volume 1224 of Lecture Notes in Computer Science, pp. 146–153. Springer Berlin Heidelberg, 1997. ISBN 978-3-540-62858-3.
304
+
305
+ Volodymyr Kuleshov, Nathan Fenner, and Stefano Ermon. Accurate uncertainties for deep learning using calibrated regression. In Jennifer Dy and Andreas Krause (eds.), Proceedings of the 35th International Conference on Machine Learning, volume 80 of Proceedings of Machine Learning Research, pp. 2796–2804, Stockholmsmässan, Stockholm Sweden, 10–15 Jul 2018. PMLR.
306
+
307
+ M. Lapin, M. Hein, and B. Schiele. Analysis and optimization of loss functions for multiclass, top-k, and multilabel classification. IEEE Transactions on Pattern Analysis and Machine Intelligence, 40 (7):1533–1554, July 2018.
308
+
309
+ Yaoyong Li, Hugo Zaragoza, Ralf Herbrich, John Shawe-Taylor, and Jaz S. Kandola. The perceptron algorithm with uneven margins. In Proceedings of the Nineteenth International Conference on Machine Learning, ICML ’02, pp. 379–386, San Francisco, CA, USA, 2002. Morgan Kaufmann Publishers Inc. ISBN 1558608737.
310
+
311
+ Yi Lin. A note on margin-based loss functions in classification. Statistics & Probability Letters, 68 (1):73 – 82, 2004. ISSN 0167-7152.
312
+
313
+ Ziwei Liu, Zhongqi Miao, Xiaohang Zhan, Jiayun Wang, Boqing Gong, and Stella X. Yu. Large-scale long-tailed recognition in an open world. In IEEE Conference on Computer Vision and Pattern Recognition, CVPR 2019, Long Beach, CA, USA, June 16-20, 2019, pp. 2537–2546. Computer Vision Foundation / IEEE, 2019.
314
+
315
+ Dhruv Mahajan, Ross Girshick, Vignesh Ramanathan, Kaiming He, Manohar Paluri, Yixuan Li, Ashwin Bharambe, and Laurens van der Maaten. Exploring the limits of weakly supervised pretraining. In Vittorio Ferrari, Martial Hebert, Cristian Sminchisescu, and Yair Weiss (eds.), Computer Vision – ECCV 2018, pp. 185–201, Cham, 2018. Springer International Publishing. ISBN 978-3-030-01216-8.
316
+
317
+ Marcus A. Maloof. Learning when data sets are imbalanced and when costs are unequal and unknown. In ICML 2003 Workshop on Learning from Imbalanced Datasets, 2003.
318
+
319
+ Hamed Masnadi-Shirazi and Nuno Vasconcelos. Risk minimization, probability elicitation, and costsensitive SVMs. In Proceedings of the 27th International Conference on International Conference on Machine Learning, ICML’10, pp. 759–766, Madison, WI, USA, 2010. Omnipress. ISBN 9781605589077.
320
+
321
+ Aditya Krishna Menon, Harikrishna Narasimhan, Shivani Agarwal, and Sanjay Chawla. On the statistical consistency of algorithms for binary classification under class imbalance. In Proceedings of the 30th International Conference on Machine Learning, ICML 2013, Atlanta, GA, USA, 16-21 June 2013, pp. 603–611, 2013.
322
+
323
+ Tomas Mikolov, Ilya Sutskever, Kai Chen, Greg Corrado, and Jeffrey Dean. Distributed representations of words and phrases and their compositionality. In Proceedings of the 26th International Conference on Neural Information Processing Systems, NIPS’13, pp. 3111–3119, Red Hook, NY, USA, 2013. Curran Associates Inc.
324
+
325
+ Katharina Morik, Peter Brockhausen, and Thorsten Joachims. Combining statistical learning with a knowledge-based approach - a case study in intensive care monitoring. In Proceedings of the Sixteenth International Conference on Machine Learning (ICML), pp. 268–277, San Francisco, CA, USA, 1999. Morgan Kaufmann Publishers Inc. ISBN 1-55860-612-2.
326
+
327
+ Rafael Müller, Simon Kornblith, and Geoffrey E. Hinton. When does label smoothing help? In Advances in Neural Information Processing Systems 32: Annual Conference on Neural Information Processing Systems 2019, NeurIPS 2019, 8-14 December 2019, Vancouver, BC, Canada, pp. 4696–4705, 2019.
328
+
329
+ Allan H. Murphy and Robert L. Winkler. A general framework for forecast verification. Monthly Weather Review, 115(7):1330–1338, 1987.
330
+
331
+ Patrick Pletscher, Cheng Soon Ong, and Joachim M. Buhmann. Entropy and margin maximization for structured output learning. In José Luis Balcázar, Francesco Bonchi, Aristides Gionis, and Michèle Sebag (eds.), Machine Learning and Knowledge Discovery in Databases, pp. 83–98, Berlin, Heidelberg, 2010. Springer Berlin Heidelberg.
332
+
333
+ Foster Provost. Machine learning from imbalanced data sets 101. In Proceedings of the AAAI-2000 Workshop on Imbalanced Data Sets, 2000.
334
+
335
+ Mark D. Reid and Robert C. Williamson. Composite binary losses. Journal of Machine Learning Research, 11:2387–2422, 2010.
336
+
337
+ Christian Szegedy, Vincent Vanhoucke, Sergey Ioffe, Jonathon Shlens, and Zbigniew Wojna. Rethinking the inception architecture for computer vision. In 2016 IEEE Conference on Computer Vision and Pattern Recognition, CVPR 2016, Las Vegas, NV, USA, June 27-30, 2016, pp. 2818–2826, 2016.
338
+
339
+ J. Tan, C. Wang, B. Li, Q. Li, W. Ouyang, C. Yin, and J. Yan. Equalization loss for long-tailed object recognition. In 2020 IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), pp. 11659–11668, 2020.
340
+
341
+ Keiji Tatsumi and Tetsuzo Tanino. Support vector machines maximizing geometric margins for multi-class classification. TOP, 22(3):815–840, 2014.
342
+
343
+ Keiji Tatsumi, Masashi Akao, Ryo Kawachi, and Tetsuzo Tanino. Performance evaluation of multiobjective multiclass support vector machines maximizing geometric margins. Numerical Algebra, Control & Optimization, 1:151, 2011. ISSN 2155-3289.
344
+
345
+ Grant Van Horn and Pietro Perona. The devil is in the tails: Fine-grained classification in the wild. arXiv preprint arXiv:1709.01450, 2017.
346
+
347
+ B.C. Wallace, K.Small, C.E. Brodley, and T.A. Trikalinos. Class imbalance, redux. In Proc. ICDM, 2011.
348
+
349
+ Yu-Xiong Wang, Deva Ramanan, and Martial Hebert. Learning to model the tail. 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. 7029–7039. Curran Associates, Inc., 2017.
350
+
351
+ Shan-Hung Wu, Keng-Pei Lin, Chung-Min Chen, and Ming-Syan Chen. Asymmetric support vector machines: Low false-positive learning under the user tolerance. In Proceedings of the 14th ACM SIGKDD International Conference on Knowledge Discovery and Data Mining, KDD ’08, pp. 749–757, New York, NY, USA, 2008. Association for Computing Machinery. ISBN 9781605581934.
352
+
353
+ Yu Xie and Charles F. Manski. The logit model and response-based samples. Sociological Methods & Research, 17(3):283–302, 1989.
354
+
355
+ Han-Jia Ye, Hong-You Chen, De-Chuan Zhan, and Wei-Lun Chao. Identifying and compensating for feature deviation in imbalanced deep learning, 2020.
356
+
357
+ Xinyang Yi, Ji Yang, Lichan Hong, Derek Zhiyuan Cheng, Lukasz Heldt, Aditee Kumthekar, Zhe Zhao, Li Wei, and Ed Chi. Sampling-bias-corrected neural modeling for large corpus item recommendations. In Proceedings of the 13th ACM Conference on Recommender Systems, RecSys ’19, pp. 269–277, New York, NY, USA, 2019. Association for Computing Machinery. ISBN 9781450362436.
358
+
359
+ Xi Yin, Xiang Yu, Kihyuk Sohn, Xiaoming Liu, and Manmohan Chandraker. Feature transfer learning for deep face recognition with long-tail data. CoRR, abs/1803.09014, 2018.
360
+
361
+ Junjie Zhang, Lingqiao Liu, Peng Wang, and Chunhua Shen. To balance or not to balance: A simple-yet-effective approach for learning with long-tailed distributions, 2019.
362
+
363
+ X. Zhang, Z. Fang, Y. Wen, Z. Li, and Y. Qiao. Range loss for deep face recognition with long-tailed training data. In 2017 IEEE International Conference on Computer Vision (ICCV), pp. 5419–5428, 2017.
364
+
365
+ Zhi-Hua Zhou and Xu-Ying Liu. Training cost-sensitive neural networks with methods addressing the class imbalance problem. IEEE Transactions on Knowledge and Data Engineering (TKDE), 18(1), 2006.
366
+
367
+ # Supplementary material for “Long tail learning via logit adjustment”
368
+
369
+ A PROOFS OF RESULTS IN BODY
370
+
371
+ Proof of Theorem 1. Denote $\eta _ { y } ( x ) = \mathbb { P } ( y \mid x )$ . Suppose we employ a margin $\Delta _ { y y ^ { \prime } } = \log { \frac { \delta _ { y ^ { \prime } } } { \delta _ { y } } }$ . Then, the loss is
372
+
373
+ $$
374
+ \ell ( y , f ( x ) ) = - \log \frac { \delta _ { y } \cdot e ^ { f _ { y } ( x ) } } { \sum _ { y ^ { \prime } \in [ L ] } \delta _ { y ^ { \prime } } \cdot e ^ { f _ { y ^ { \prime } } ( x ) } } = - \log \frac { e ^ { f _ { y } ( x ) + \log \delta _ { y } } } { \sum _ { y ^ { \prime } \in [ L ] } e ^ { f _ { y ^ { \prime } } ( x ) + \log \delta _ { y ^ { \prime } } } } .
375
+ $$
376
+
377
+ Consequently, under constant weights $\alpha _ { y } = 1$ , the Bayes-optimal score will satisfy $f _ { y } ^ { * } ( x ) + \log \delta _ { y } =$ $\log \eta _ { y } ( x )$ , or $\begin{array} { r } { f _ { y } ^ { * } ( x ) = \log \frac { \eta _ { y } ( x ) } { \delta _ { y } } } \end{array}$
378
+
379
+ Now suppose we use generic weights $\alpha \in \mathbb { R } _ { + } ^ { L }$ . The risk under this loss is
380
+
381
+ $$
382
+ \begin{array} { r l } { \mathbb { E } _ { x , y } \left[ \ell _ { \alpha } ( y , f ( x ) ) \right] = \displaystyle \sum _ { y \in [ L ] } \pi _ { y } \cdot \mathbb { E } _ { x | y = y } \left[ \ell _ { \alpha } ( y , f ( x ) ) \right] } & { } \\ { = \displaystyle \sum _ { y \in [ L ] } \pi _ { y } \cdot \mathbb { E } _ { x | y = y } \left[ \ell _ { \alpha } ( y , f ( x ) ) \right] } & { } \\ { = \displaystyle \sum _ { y \in [ L ] } \pi _ { y } \cdot \alpha _ { y } \cdot \mathbb { E } _ { x | y = y } \left[ \ell ( y , f ( x ) ) \right] } & { } \\ { \propto \displaystyle \sum _ { y \in [ L ] } \pi _ { y } \cdot \mathbb { E } _ { x | y = y } \left[ \ell ( y , f ( x ) ) \right] , } \end{array}
383
+ $$
384
+
385
+ where $\bar { \pi } _ { y } \propto \pi _ { y } \cdot \alpha _ { y }$ . Consequently, learning with the weighted loss is equivalent to learning with the original loss, on a distribution with modified base-rates $\bar { \pi }$ . Under such a distribution, we have class-conditional distribution
386
+
387
+ $$
388
+ { \bar { \eta } } _ { y } ( x ) = { \bar { \mathbb { P } } } ( y \mid x ) = { \frac { \mathbb { P } ( x \mid y ) \cdot { \bar { \pi } } _ { y } } { { \bar { \mathbb { P } } } ( x ) } } = \eta _ { y } ( x ) \cdot { \frac { { \bar { \pi } } _ { y } } { \pi _ { y } } } \cdot { \frac { \mathbb { P } ( x ) } { { \bar { \mathbb { P } } } ( x ) } } \propto \eta _ { y } ( x ) \cdot \alpha _ { y } .
389
+ $$
390
+
391
+ Consequently, suppose $\begin{array} { r } { \alpha _ { y } = \frac { \delta _ { y } } { \pi _ { y } } } \end{array}$ . Then, $\begin{array} { r } { f _ { y } ^ { * } ( x ) = \log \frac { \bar { \eta } _ { y } ( x ) } { \delta _ { y } } = \log \frac { \eta _ { y } ( x ) } { \pi _ { y } } + C ( x ) } \end{array}$ , where $C ( x )$ does not depend on y. Consequently, argmaxy∈[L] f∗y (x) = argmaxy∈[L] πy , which is the Bayes-optimal prediction for the balanced error.
392
+
393
+ In sum, a consistent family can be obtained by choosing any set of constants $\delta _ { y } > 0$ and setting
394
+
395
+ $$
396
+ \begin{array} { c } { \displaystyle \alpha _ { y } = \frac { \delta _ { y } } { \pi _ { y } } } \\ { \displaystyle \Delta _ { y y ^ { \prime } } = \log \frac { \delta _ { y ^ { \prime } } } { \delta _ { y } } . } \end{array}
397
+ $$
398
+
399
+ Proof of Theorem 2. We establish a more general result in Lemma 3 of the next section, which allows for a temperature parameter in the loss. This allows for interpolating between the standard softmax cross-entropy and margin based losses. □
400
+
401
+ # B ON THE CONSISTENCY OF BINARY MARGIN-BASED LOSSES
402
+
403
+ It is instructive to study the pairwise margin loss (11) in the binary case. Endowing the loss with a temperature parameter $\gamma > 0$ , we get2
404
+
405
+ $$
406
+ \begin{array} { l } { \ell ( + 1 , f ) = \displaystyle \frac { \omega _ { + 1 } } { \gamma } \cdot \log ( 1 + e ^ { \gamma \cdot \delta _ { + 1 } } \cdot e ^ { - \gamma \cdot f } ) } \\ { \ell ( - 1 , f ) = \displaystyle \frac { \omega _ { - 1 } } { \gamma } \cdot \log ( 1 + e ^ { \gamma \cdot \delta _ { - 1 } } \cdot e ^ { \gamma \cdot f } ) } \end{array}
407
+ $$
408
+
409
+ for constants $\omega _ { \pm 1 } , \gamma > 0$ and $\delta _ { \pm 1 } \in \mathbb { R }$ . Here, we have used $\delta _ { + 1 } = \Delta _ { + 1 , - 1 }$ and $\delta _ { - 1 } = \Delta _ { - 1 , + 1 }$ for simplicity. The choice $\omega _ { \pm 1 } = 1 , \delta _ { \pm 1 } = 0$ recovers the temperature scaled binary logistic loss. Evidently, as $\gamma + \infty$ , these converge to weighted hinge losses with variable margins, i.e.,
410
+
411
+ $$
412
+ \begin{array} { l } { \ell ( + 1 , f ) = \omega _ { + 1 } \cdot [ \delta _ { + 1 } - f ] _ { + } } \\ { \ell ( - 1 , f ) = \omega _ { - 1 } \cdot [ \delta _ { - 1 } + f ] _ { + } . } \end{array}
413
+ $$
414
+
415
+ We study two properties of this family losses. First, under what conditions are the losses Fisher consistent for the balanced error? We shall show that in fact there is a simple condition characterising this. Second, do the losses preserve properness of the original binary logistic loss? We shall show that this is always the case, but that the losses involve fundamentally different approximations.
416
+
417
+ # B.1 CONSISTENCY OF THE BINARY PAIRWISE MARGIN LOSS
418
+
419
+ Given a loss $\ell$ , its Bayes optimal solution is $f ^ { * } \in \mathrm { a r g m i n } _ { f }$ : $\boldsymbol { x } _ { \ u { } \mathbb { R } } \mathbb { E } [ \ell ( y , f ( x ) ) ]$ . For consistency with respect to the balanced error in the binary case, we require this optimal solution $f ^ { * }$ to satisfy $f ^ { * } ( x ) > 0 \iff \eta ( x ) > \pi$ , where $\eta ( x ) \doteq \mathbb { P } ( y = 1 \mid x )$ and $\pi \doteq \mathbb { P } ( y = 1 )$ (Menon et al., 2013). This is equivalent to a simple condition on the weights $\omega$ and margins $\delta$ of the pairwise margin loss.
420
+
421
+ Lemma 3. The losses in (13) are consistent for the balanced error iff
422
+
423
+ $$
424
+ \frac { \omega _ { + 1 } } { \omega _ { - 1 } } \cdot \frac { \sigma ( \gamma \cdot \delta _ { + 1 } ) } { \sigma ( \gamma \cdot \delta _ { - 1 } ) } = \frac { 1 - \pi } { \pi } ,
425
+ $$
426
+
427
+ where $\sigma ( z ) = ( 1 + \exp ( z ) ) ^ { - 1 }$
428
+
429
+ Proof of Lemma 3. Denote $\eta ( x ) \doteq \mathbb { P } ( y = + 1 \mid x )$ , and $\pi \doteq \mathbb { P } ( y = + 1 )$ . From Lemma 4 below, the pairwise margin loss is proper composite with invertible link function $\Psi : [ 0 , 1 ] \to \mathbb { R } \cup \{ \pm \infty \}$ . Consequently, since by definition the Bayes-optimal score for a proper composite loss is $f ^ { * } ( x ) =$ $\Psi ( \eta ( x ) )$ (Reid & Williamson, 2010), to have consistency for the balanced error, from (14), (15), we require
430
+
431
+ $$
432
+ \begin{array} { r l } & { \Psi ^ { - 1 } ( 0 ) = \pi \iff \frac { 1 } { 1 - \frac { \ell ^ { \prime } ( + 1 , 0 ) } { \ell ^ { \prime } ( - 1 , 0 ) } } = \pi } \\ & { \qquad \iff 1 - \frac { \ell ^ { \prime } ( + 1 , 0 ) } { \ell ^ { \prime } ( - 1 , 0 ) } = \frac { 1 } { \pi } } \\ & { \qquad \iff - \frac { \ell ^ { \prime } ( + 1 , 0 ) } { \ell ^ { \prime } ( - 1 , 0 ) } = \frac { 1 - \pi } { \pi } } \\ & { \qquad \iff \frac { \omega _ { + 1 } } { \omega _ { - 1 } } \cdot \frac { \sigma ( \gamma \cdot \delta _ { + 1 } ) } { \sigma ( \gamma \cdot \delta _ { - 1 } ) } = \frac { 1 - \pi } { \pi } . } \end{array}
433
+ $$
434
+
435
+ From the above, some admissible parameter choices include:
436
+
437
+ • $\textstyle \omega _ { + 1 } = { \frac { 1 } { \pi } }$ , $\begin{array} { r } { \omega _ { - 1 } = \frac { 1 } { 1 - \pi } } \end{array}$ , $\delta _ { \pm 1 } = 1$ ; i.e., the standard weighted loss with a constant margin • $\omega _ { \pm 1 } = 1$ , $\begin{array} { r } { \delta _ { + 1 } = \frac { 1 } { \gamma } \cdot \log \frac { 1 - \pi } { \pi } } \end{array}$ , $\begin{array} { r } { \delta _ { - 1 } = \frac { 1 } { \gamma } \cdot \log \frac { \pi } { 1 - \pi } } \end{array}$ ; i.e., the unweighted loss with a margin biased towards the rare class, as per our logit adjustment procedure
438
+
439
+ The second example above is unusual in that it requires scaling the margin with the temperature; consequently, the margin disappears as $\gamma + \infty$ . Other combinations are of course possible, but note that one cannot arbitrarily choose parameters and hope for consistency in general. Indeed, some inadmissible choices are naïve applications of the margin modification or weighting, e.g.,
440
+
441
+ • $\textstyle \omega _ { + 1 } = { \frac { 1 } { \pi } }$ , $\begin{array} { r } { \omega _ { - 1 } = \frac { 1 } { 1 - \pi } } \end{array}$ , $\begin{array} { r } { \delta _ { + 1 } = \frac { 1 } { \gamma } \cdot \log \frac { 1 - \pi } { \pi } } \end{array}$ , $\begin{array} { r } { \delta _ { - 1 } = \frac { 1 } { \gamma } \cdot \log \frac { \pi } { 1 - \pi } } \end{array}$ ; i.e., combining both weighting and margin modification • $\omega _ { \pm 1 } = 1$ $\begin{array} { r } { = 1 , \delta _ { + 1 } = \frac { 1 } { \gamma } \cdot ( 1 - \pi ) , \delta _ { - 1 } = \frac { 1 } { \gamma } \cdot \pi } \end{array}$ ; i.e., specific margin modification
442
+
443
+ Note further that the choices of Cao et al. (2019); Tan et al. (2020) do not meet the requirements of Lemma 3.
444
+
445
+ We make two final remarks. First, the above only considers consistency of the result of loss minimisation. For any choice of weights and margins, we may apply suitable post-hoc correction to the predictions to account for any bias in the optimal scores. Second, as $\gamma \to + \infty$ , any constant margins $\delta _ { \pm 1 } > 0$ will have no effect on the consistency condition, since $\sigma ( \gamma \cdot \delta _ { \pm 1 } ) 1$ . The condition will be wholly determined by the weights $\omega _ { \pm 1 }$ . For example, we may choose $\textstyle \omega _ { + 1 } = { \frac { 1 } { \pi } }$ , $\begin{array} { r } { \omega _ { - 1 } = \frac { 1 } { 1 - \pi } } \end{array}$ , $\delta _ { + 1 } = 1$ , and $\begin{array} { r } { \delta _ { - 1 } = \frac { \pi } { 1 - \pi } } \end{array}$ ; the resulting loss will not be consistent for finite $\gamma$ , but will become so in the limit $\gamma \to + \infty$ .
446
+
447
+ # B.2 PROPERNESS OF THE PAIRWISE MARGIN LOSS
448
+
449
+ In the above, we appealed to the pairwise margin loss being proper composite, in the sense of Reid & Williamson (2010). Intuitively, this specifies that the loss has Bayes-optimal score of the form $f ^ { * } ( x ) = \Psi ( \eta ( x ) )$ , where $\Psi$ is some invertible function, and $\eta ( x ) = \mathbb { P } ( y = 1 \mid x )$ . We have the following general result about properness of any member of the pairwise margin family.
450
+
451
+ Lemma 4. The losses in (13) are proper composite, with link function
452
+
453
+ $$
454
+ \Psi ( p ) = \frac { 1 } { \gamma } \cdot \log \left[ \left( \frac { a \cdot b } { q } - c \right) \pm \sqrt { \left( \frac { a \cdot b } { q } - c \right) ^ { 2 } + 4 \cdot \frac { a } { q } } \right] - \log 2 ,
455
+ $$
456
+
457
+ where $\begin{array} { r } { a = \frac { \omega _ { + 1 } } { \omega _ { - 1 } } \cdot \frac { e ^ { \gamma \cdot \delta _ { + 1 } } } { e ^ { \gamma \cdot \delta _ { - 1 } } } } \end{array}$ , $b = e ^ { \gamma \cdot \delta _ { - 1 } }$ , $c = e ^ { \gamma \cdot \delta _ { + 1 } }$ , and $\begin{array} { r } { q = \frac { 1 - p } { p } } \end{array}$ .
458
+
459
+ Proof of Lemma 4. The above family of losses is proper composite iff the function
460
+
461
+ $$
462
+ f \mapsto { \frac { 1 } { 1 - { \frac { \ell ^ { \prime } ( + 1 , f ) } { \ell ^ { \prime } ( - 1 , f ) } } } }
463
+ $$
464
+
465
+ is invertible (Reid & Williamson, 2010, Corollary 12); the resulting inverse is the link function $\Psi$ . We have
466
+
467
+ $$
468
+ \begin{array} { l } { { \ell ^ { \prime } ( + 1 , f ) = - \omega _ { + 1 } \cdot \frac { e ^ { \gamma \cdot \delta _ { + 1 } } \cdot e ^ { - \gamma \cdot f } } { 1 + e ^ { \gamma \cdot \delta _ { + 1 } } \cdot e ^ { - \gamma \cdot f } } } } \\ { { \ell ^ { \prime } ( - 1 , f ) = + \omega _ { - 1 } \cdot \frac { e ^ { \gamma \cdot \delta _ { - 1 } } \cdot e ^ { \gamma \cdot f } } { 1 + e ^ { \gamma \cdot \delta _ { - 1 } } \cdot e ^ { \gamma \cdot f } } . } } \end{array}
469
+ $$
470
+
471
+ The invertibility of (14) is immediate. To compute the link function $\Psi$ , note that
472
+
473
+ $$
474
+ \begin{array} { r l } { p = \cfrac { 1 } { 1 - \cfrac { \ell ^ { \prime } ( + 1 , f ) } { \ell ^ { \prime } ( - 1 , f ) } } \iff \frac { 1 } { p } = 1 - \cfrac { \ell ^ { \prime } ( + 1 , f ) } { \ell ^ { \prime } ( - 1 , f ) } } \\ { \iff - \cfrac { \ell ^ { \prime } ( + 1 , f ) } { \ell ^ { \prime } ( - 1 , f ) } = \cfrac { 1 - p } { p } } \\ { \iff \frac { \omega _ { + 1 } } { \omega _ { - 1 } } \cdot \cfrac { e ^ { \gamma \cdot \delta _ { + 1 } } \cdot e ^ { - \gamma \cdot f } } { 1 + e ^ { \gamma \cdot \delta _ { + 1 } } \cdot e ^ { - \gamma \cdot f } } \cdot \cfrac { 1 + e ^ { \gamma \cdot \delta _ { - 1 } } \cdot e ^ { \gamma \cdot f } } { e ^ { \gamma \cdot \delta _ { - 1 } } \cdot e ^ { \gamma \cdot f } } = \cfrac { 1 - p } { p } } \end{array}
475
+ $$
476
+
477
+ $$
478
+ \begin{array} { l } { { \iff \frac { \omega _ { + 1 } } { \omega _ { - 1 } } \cdot \frac { e ^ { \gamma \cdot \delta _ { + 1 } } } { e ^ { \gamma \cdot \delta _ { - 1 } } } \cdot \frac { 1 } { e ^ { \gamma \cdot f } + e ^ { \gamma \cdot \delta _ { + 1 } } } \cdot \frac { 1 + e ^ { \gamma \cdot \delta _ { - 1 } } \cdot e ^ { \gamma \cdot f } } { e ^ { \gamma \cdot f } } = \frac { 1 - p } { p } } } \\ { { \iff a \cdot \frac { 1 + b \cdot g } { g ^ { 2 } + c \cdot g } = q , } } \end{array}
479
+ $$
480
+
481
+ where $\begin{array} { r } { a = \frac { \omega _ { + 1 } } { \omega _ { - 1 } } \cdot \frac { e ^ { \gamma \cdot \delta _ { + 1 } } } { e ^ { \gamma \cdot \delta _ { - 1 } } } } \end{array}$ , $b = e ^ { \gamma \cdot \delta _ { - 1 } }$ , $c = e ^ { \gamma \cdot \delta _ { + 1 } }$ , $g = e ^ { \gamma \cdot f }$ , and $\begin{array} { r } { q = \frac { 1 - p } { p } } \end{array}$ . Thus,
482
+
483
+ $$
484
+ \begin{array} { r l } & { a \cdot \frac { 1 + b \cdot g } { g ^ { 2 } + c \cdot g } = q \iff \frac { g ^ { 2 } + c \cdot g } { 1 + b \cdot g } = \frac { a } { q } } \\ & { \iff g ^ { 2 } + \left( c - \frac { a \cdot b } { q } \right) \cdot g - \frac { a } { q } = 0 } \\ & { \iff g = \frac { \left( \frac { a \cdot b } { q } - c \right) \pm \sqrt { \left( \frac { a \cdot b } { q } - c \right) ^ { 2 } + 4 \cdot \frac { a } { q } } } { 2 } . } \end{array}
485
+ $$
486
+
487
+ As a sanity check, suppose $a = b = c = \gamma = 1$ . This corresponds to the standard logistic loss. Then,
488
+
489
+ $$
490
+ \Psi ( p ) = \log { \frac { \left( { \frac { 1 } { q } } - 1 \right) \pm { \sqrt { \left( { \frac { 1 } { q } } - 1 \right) ^ { 2 } + 4 \cdot { \frac { 1 } { q } } } } } { 2 } } = \log { \frac { p } { 1 - p } } ,
491
+ $$
492
+
493
+ which is the standard logit function.
494
+
495
+ Figure 5 and 6 compares the link functions for a few different settings:
496
+
497
+ • the balanced loss, where $\begin{array} { r } { \omega _ { + 1 } = \frac { 1 } { \pi } } \end{array}$ , $\begin{array} { r } { \omega _ { - 1 } = \frac { 1 } { 1 - \pi } } \end{array}$ , and $\delta _ { \pm 1 } = 1$ • an unequal margin loss, where $\omega _ { \pm 1 } = 1$ , $\begin{array} { r } { \delta _ { + 1 } = \frac { 1 } { \gamma } \cdot \log \frac { 1 - \pi } { \pi } } \end{array}$ , and $\begin{array} { r } { \delta _ { - 1 } = \frac { 1 } { \gamma } \cdot \log \frac { \pi } { 1 - \pi } } \end{array}$ • a balanced $^ +$ margin loss, where $\textstyle \omega _ { + 1 } = { \frac { 1 } { \pi } }$ , $\begin{array} { r } { \omega _ { - 1 } = \frac { 1 } { 1 - \pi } } \end{array}$ , $\delta _ { + 1 } = 1$ , and $\begin{array} { r } { \delta _ { - 1 } = \frac { \pi } { 1 - \pi } } \end{array}$ .
498
+
499
+ The property $\Psi ^ { - 1 } ( 0 ) = \pi$ for $\pi = \mathbb { P } ( y = 1 )$ holds for the first two choices with any $\gamma > 0$ , and the third choice as $\gamma \to + \infty$ . This indicates the Fisher consistency of these losses for the balanced error. However, the precise way this is achieved is strikingly different in each case. In particular, each loss implicitly involves a fundamentally different link function.
500
+
501
+ To better understand the effect of parameter choices, Figure 7 illustrates the conditional Bayes risk curves, i.e.,
502
+
503
+ $$
504
+ \underline { { \mathsf { L } } } ( p ) = p \cdot \ell ( + 1 , \Psi ( p ) ) + ( 1 - p ) \cdot \ell ( + 1 , \Psi ( p ) ) .
505
+ $$
506
+
507
+ We remark here that for the balanced error, this function takes the form $\begin{array} { r } { \underline { { \mathrm { L } } } ( p ) = p \cdot \left[ \left[ p < \pi \right] \right] + ( 1 - } \end{array}$ $p ) \cdot \mathbb { \left[ p > \pi \right] }$ , i.e., it is a “tent shaped” concave function with a maximum at $p = \pi$ .
508
+
509
+ For ease of comparison, we normalise this curves to have a maximum of 1. Figure 7 shows that simply applying unequal margins does not affect the underlying conditional Bayes risk compared to the standard log-loss; thus, the change here is purely in terms of the link function. By contrast, either balancing the loss or applying a combination of weighting and margin modification results in a closer approximation to the conditional Bayes risk curve for the cost-sensitive loss with cost $\pi$ .
510
+
511
+ ![](images/8e66ef8d277d52b1dcef1ab43da852f0196c1ac898dac02fcf64cdf209f3c3ae.jpg)
512
+ Figure 5: Comparison of link functions for various losses assuming $\pi = 0 . 2$ , with $\gamma = 1$ (left) and $\gamma = 8$ (ried t). The balanced l margin loss uses $\begin{array} { r } { \omega _ { y } = \frac { 1 } { \pi _ { y } } } \end{array}$ , margin loss uses . $\begin{array} { r } { \delta _ { y } = \frac { 1 } { \gamma } \cdot \log \frac { 1 - \pi } { \pi } } \end{array}$ . The $^ +$ $\begin{array} { r } { \delta _ { - 1 } = \frac { \pi } { 1 - \pi } } \end{array}$ $\delta _ { + 1 } = 1$ $\begin{array} { r } { \omega _ { + 1 } = \frac { 1 } { \pi } } \end{array}$
513
+
514
+ ![](images/601833c0cc44a0a4b283238967651f807662505ddfb2def121513c9fc2cd49e1.jpg)
515
+ Figure 6: Comparison of link functions for various losses assuming $\pi = 0 . 2$ , with $\gamma = 1$ (left) and $\gamma = 8$ (right). The balanced loss uses $\begin{array} { r } { \omega _ { y } = \frac { 1 } { \pi _ { y } } } \end{array}$ . The unequal margin loss uses $\begin{array} { r } { \delta _ { y } = \frac { 1 } { \gamma } \cdot \log \frac { 1 - \pi _ { y } } { \pi _ { y } } } \end{array}$ The balanced $^ +$ margin loss uses $\begin{array} { r } { \delta _ { - 1 } = \frac { \pi } { 1 - \pi } } \end{array}$ , $\delta _ { + 1 } = 1$ , $\begin{array} { r } { \omega _ { + 1 } = \frac { 1 } { \pi } } \end{array}$ .
516
+
517
+ ![](images/a93ebb67ecaec1aa5454820b4888c20e60826180f2b17373e8ddbe77a2aebff6.jpg)
518
+ Figure 7: Comparison of conditional Bayes risk functions for various losses assuming $\pi = 0 . 2$ , with $\gamma = 1$ (left) and $\gamma = 8$ (right). The balanced loss uses $\begin{array} { r } { \omega _ { y } = \frac { 1 } { \pi _ { y } } } \end{array}$ . The unequal margin loss uses $\begin{array} { r } { \delta _ { y } = \frac { 1 } { \gamma } \cdot \log \frac { 1 - \pi _ { y } } { \pi _ { y } } } \end{array}$ . The first balanced $^ +$ margin loss uses $\delta _ { - 1 } = \pi$ , $\delta _ { + 1 } = 1$ , $\begin{array} { r } { \omega _ { + 1 } = \frac { 1 } { \pi } } \end{array}$ . The second balanced $^ +$ y margin loss uses $\begin{array} { r } { \delta _ { - 1 } = \frac { \pi } { 1 - \pi } } \end{array}$ , $\delta _ { + 1 } = 1$ , $\textstyle \omega _ { + 1 } = { \frac { 1 } { \pi } }$ .
519
+
520
+ # C EXPERIMENTAL SETUP
521
+
522
+ Intending a fair comparison, we use the same setup for all the methods for each dataset. Unless otherwise specified, all networks are trained with SGD with a momentum value of 0.9, a linear learning rate warm-up in the first 5 epochs to reach the base learning rate, and a weight decay of $1 0 ^ { - 4 }$ . Other dataset specific details are given below.
523
+
524
+ CIFAR-10 and CIFAR-100: We use a CIFAR ResNet-32 model trained for 120K steps with a batch size of 128. The base learning rate is 0.1, with a linear warmup for the first 2000 steps, and a decay of 0.1 at 60K, 90K, and 110K steps.3 We also use the standard CIFAR data augmentation procedure used in previous works such as Cao et al. (2019); He et al. (2016), where 4 pixels are padded on each size and a random $3 2 \times 3 2$ crop is taken. Images are horizontally flipped with a probability of 0.5.
525
+
526
+ ImageNet: We use a ResNet-50 model trained for 90 epochs with batch size of 512. The base learning rate is 0.4, with cosine learning rate decay and Nesterov momentum. We use a weight decay of $5 \times \bar { 1 } 0 ^ { - 4 }$ following Kang et al. (2020). Additionally, we apply the standard data augmentation comprising of random cropping and flipping as described in Goyal et al. (2017).
527
+
528
+ iNaturalist: We use a ResNet-50 trained for 90 epochs with a batch size of 1024. (Note however that for the ResNet-152 experiments in Appendix D.1, we use a batch size of 512.) The base learning rate is 0.4, with cosine learning rate decay. The data augmentation procedure is the same as used in ImageNet.
529
+
530
+ # D ADDITIONAL EXPERIMENTS
531
+
532
+ We present here additional experiments:
533
+
534
+ (i) we present a detailed table of results with a more complex base architecture and number of training epochs for ImageNet-LT and iNaturalist;
535
+ (ii) we present results for CIFAR-10 and CIFAR-100 on the STEP profile (Cao et al., 2019) with $\rho = 1 0 0$ .
536
+ (iii) we present results on synthetic data with varying imbalance ratios.
537
+
538
+ # D.1 RESULTS WITH MORE COMPLEX BASE ARCHITECTURE
539
+
540
+ Table 3 presents results when using a ResNet-152, trained for either 90 or 200 epochs, on the larger ImageNet-LT and iNaturalist datasets. Consistent with the findings in Kang et al. (2020), training with a more complex architecture for longer generally yields significant gains. Logit adjustment, potentially when combined with the adaptive margin, is generally superior to baselines with the sole exception of results for ResNet-152 with 200 epochs on iNaturalist.
541
+
542
+ Table 3: Test set balanced error (averaged over 5 trials) on real-world datasets with more complex base architectures. Employing a ResNet-152 systematically improves all methods’ performance, with logit adjustment remaining superior to existing approaches. The final row reports the results of combining logit adjustment with the adaptive margin loss of Cao et al. (2019), which yields further gains on iNaturalist.
543
+
544
+ <table><tr><td rowspan="2">Method</td><td colspan="2">ImageNet-LT</td><td colspan="2">iNaturalist</td><td></td></tr><tr><td>ResNet-50</td><td>ResNet-152</td><td>ResNet-50 90 epochs</td><td>ResNet-152 90 epochs</td><td>ResNet-152 200 epochs</td></tr><tr><td>ERM</td><td>53.11</td><td>53.30</td><td>38.66</td><td>35.88</td><td>34.38</td></tr><tr><td>Weight normalisation (T = 1) (Kang et al., 2020)</td><td>52.00</td><td>51.49</td><td>48.05</td><td>45.17</td><td>45.33</td></tr><tr><td>Weight normalisation (T = T*) (Kang et al.,2020)</td><td>49.37</td><td>48.97</td><td>34.10</td><td>31.85</td><td>30.34</td></tr><tr><td>Learnable weight scaling (LWS) (Kang et al., 2020)</td><td>52.30</td><td>49.50</td><td>34.10</td><td>30.90</td><td>27.90</td></tr><tr><td>Classifier retraining (cRT) (Kang et al., 2020)</td><td>52.70</td><td>49.90</td><td>34.80</td><td>31.50</td><td>28.80</td></tr><tr><td>Adaptive (Cao et al., 2019)</td><td>52.15</td><td>53.34</td><td>35.42</td><td>31.18</td><td>29.46</td></tr><tr><td>Equalised (Tan et al., 2020)</td><td>54.02</td><td>51.38</td><td>38.37</td><td>35.86</td><td>34.53</td></tr><tr><td>Logit adjustment post-hoc (T =1)</td><td>49.66</td><td>49.25</td><td>33.98</td><td>31.46</td><td>30.15</td></tr><tr><td>Logit adjustment post-hoc (T = T*)</td><td>49.56</td><td>49.15</td><td>33.80</td><td>31.08</td><td>29.74</td></tr><tr><td>Logit adjustment loss (T = 1)</td><td>48.89</td><td>47.86</td><td>33.64</td><td>31.15</td><td>30.12</td></tr><tr><td>Logit adjustment plus adaptive loss (T = 1)</td><td>51.25</td><td>50.46</td><td>31.56</td><td>29.22</td><td>28.02</td></tr></table>
545
+
546
+ # D.2 PER-CLASS ERROR RATES
547
+
548
+ Figure 8 breaks down the per-class accuracies on CIFAR-10, CIFAR-100, and iNaturalist. On the latter two datasets, for ease of visualisation, we aggregate the classes into ten groups based on their frequency-sorted order (so that, e.g., group 0 comprises the top $\frac { L } { 1 0 }$ most frequent classes). As expected, dominant classes generally see a lower error rate with all methods. However, the logit adjusted loss is seen to systematically improve performance over ERM, particularly on rare classes.
549
+
550
+ # D.3 RESULTS ON CIFAR-LT WITH STEP-100 PROFILE
551
+
552
+ Table 4 summarises results on the STEP-100 profile. Here, with $\tau = 1$ , weight normalisation slightly outperforms logit adjustment. However, with $\tau > 1$ , logit adjustment is again found to be superior (54.80); see Figure 9.
553
+
554
+ # D.4 RESULTS ON SYNTHETIC DATA WITH VARYING IMBALANCE RATIO
555
+
556
+ Figure 10 shows results on the synthetic data of $\ S$ for varying choice of $\mathbb { P } ( y = + 1 )$ . As expected, we see that as $\mathbb { P } ( y = + 1 )$ increases, all methods become equitable in terms of performance. We
557
+
558
+ ![](images/512766d7aa70f9233f465279f1eb50963e9d0772d8eb0582ee1a39df13af5999.jpg)
559
+ Figure 8: Per-class error rates of loss modification techniques. For (b) and (c), we aggregate the classes into 10 groups. ERM displays a strong bias towards dominant classes (lower indices). Our proposed logit adjusted softmax loss achieves significant gains on rare classes (higher indices).
560
+
561
+ Table 4: Test set balanced error (averaged over 5 trials) on CIFAR-10-LT and CIFAR-100-LT under the STEP-100 profile; lower is better. On CIFAR-100-LT, weight normalisation edges out logit adjustment. See Figure 9 for a demonstrated that tuned versions of the same outperfom weight normalisation.
562
+
563
+ <table><tr><td>Method</td><td>CIFAR-10-LT</td><td>CIFAR-100-LT</td></tr><tr><td>ERM</td><td>36.54</td><td>60.23</td></tr><tr><td>Weight normalisation (T = 1)</td><td>30.86</td><td> 55.19</td></tr><tr><td>Adaptive</td><td>34.61</td><td>58.86</td></tr><tr><td>Equalised</td><td>31.42</td><td>57.82</td></tr><tr><td>Logit adjustment post-hoc (T = 1)</td><td>28.66</td><td>55.82</td></tr><tr><td>Logit adjustment (loss)</td><td>27.57</td><td>55.52</td></tr></table>
564
+
565
+ generally find a consistent trend in the relative performance of the various methods, which matches the results in the body.
566
+
567
+ ![](images/c3ea3090e9ad4a0694df4c5d863e06138248424354594f4170272b9e7556e42b.jpg)
568
+ Figure 9: Post-hoc adjustment on STEP-100 profile, CIFAR-10-LT and CIFAR-100-LT. Logit adjustment outperforms weight normalisation with suitable tuning.
569
+
570
+ ![](images/ca7dc53492c6d6e9dc31f0bb33da09838cbf59aa6b7f6b41bc07d07ea2646e2f.jpg)
571
+ Figure 10: Results on synthetic data with varying imbalance ratio.
572
+
573
+ # E DOES WEIGHT NORMALISATION INCREASE MARGINS?
574
+
575
+ Suppose that one uses SGD with a momentum, and finds solutions where $\| w _ { y } \| _ { 2 }$ tracks the class priors. One intuition behind normalisation of weights is that, drawing inspiration from the binary case, this ought to increase the classification margins for tail classes. Unfortunately, as discussed below, this intuition is not necessarily borne out.
576
+
577
+ Consider a scorer $f _ { y } ( x ) = w _ { y } ^ { \top } \Phi ( x )$ , where $w _ { y } \in \mathbb { R } ^ { d }$ and $\Phi \colon \mathcal { X } \mathbb { R } ^ { d }$ . The functional margin for an example $( x , y )$ is (Koltchinskii et al., 2001)
578
+
579
+ $$
580
+ \gamma _ { f } ( x , y ) \doteq w _ { y } ^ { \top } \Phi ( x ) - \operatorname* { m a x } _ { y ^ { \prime } \ne y } w _ { y ^ { \prime } } ^ { \top } \Phi ( x ) .
581
+ $$
582
+
583
+ This generalises the classical binary margin, wherein by convention $\mathcal { Y } = \{ \pm 1 \}$ , $w _ { - 1 } = - w _ { 1 }$ , and
584
+
585
+ $$
586
+ \gamma _ { \mathrm { f } } ( x , y ) \doteq y \cdot w _ { 1 } ^ { \top } \Phi ( x ) = \frac { 1 } { 2 } \cdot \left( w _ { y } ^ { \top } \Phi ( x ) - w _ { - y } ^ { \top } \Phi ( x ) \right) ,
587
+ $$
588
+
589
+ which agrees with (16) upto scaling. One may also define the geometric margin in the binary case to be the distance of $( x , y )$ from its classifier:
590
+
591
+ $$
592
+ \gamma _ { g , \mathrm { b } } ( x ) \doteq \frac { | w _ { 1 } \cdot \Phi ( x ) | } { \| w _ { 1 } \| _ { 2 } } .
593
+ $$
594
+
595
+ Clearly, γg,b(x) = |γf (x,y)|k k , and so for fixed functional margin, one may increase the geometric margin by minimising $\lVert \boldsymbol { w } _ { 1 } \rVert _ { 2 }$ . However, the same is not necessarily true in the multiclass setting, since here the functional and geometric margins do not generally align (Tatsumi et al., 2011; Tatsumi & Tanino, 2014). In particular, controlling each $\| w _ { y } \| _ { 2 }$ does not necessarily control the geometric margin.
596
+
597
+ # F BAYES-OPTIMAL CLASSIFIER UNDER GAUSSIAN CLASS-CONDITIONALS
598
+
599
+ Derivation of (12). Suppose
600
+
601
+ $$
602
+ \mathbb { P } ( x \mid y ) = { \frac { 1 } { { \sqrt { 2 \pi } } \sigma } } \cdot \exp \left( - { \frac { \| x - \mu _ { y } \| ^ { 2 } } { 2 \sigma ^ { 2 } } } \right)
603
+ $$
604
+
605
+ for suitable $\mu _ { y }$ and $\sigma$ . Then,
606
+
607
+ $$
608
+ \begin{array} { r l } & { \mathbb { P } ( x \mid y = + 1 ) > \mathbb { P } ( x \mid y = - 1 ) \iff \exp \left( - \frac { \| x - \mu _ { + 1 } \| ^ { 2 } } { 2 \sigma ^ { 2 } } \right) > \exp \left( - \frac { \| x - \mu _ { - 1 } \| ^ { 2 } } { 2 \sigma ^ { 2 } } \right) } \\ & { \iff \frac { \| x - \mu _ { + 1 } \| ^ { 2 } } { 2 \sigma ^ { 2 } } < \frac { \| x - \mu _ { - 1 } \| ^ { 2 } } { 2 \sigma ^ { 2 } } } \\ & { \iff \| x - \mu _ { + 1 } \| ^ { 2 } < \| x - \mu _ { - 1 } \| ^ { 2 } } \\ & { \iff 2 \cdot ( \mu _ { + 1 } - \mu _ { - 1 } ) ^ { \top } x > \| \mu _ { + 1 } \| ^ { 2 } - \| \mu _ { - 1 } \| ^ { 2 } . } \end{array}
609
+ $$
610
+
611
+ Now use the fact that in our setting, $\| \mu _ { + 1 } \| ^ { 2 } = \| \mu _ { - 1 } \| ^ { 2 }$ .
612
+
613
+ We now explicate that the class-probability function for the synthetic dataset in $\ S$ is exactly in the family assumed by the logistic regression. This implies that logistic regression is well-specified for this problem, and thus can perfectly model $\mathbb { P } ( y = \bar { + } 1 \mid x )$ in the infinite sample limit. Note that
614
+
615
+ $$
616
+ { \begin{array} { r l } & { \mathbb { P } ( y = + 1 \mid x ) = { \frac { \mathbb { P } ( x \mid y = + 1 ) \cdot \mathbb { P } ( y = + 1 ) } { \mathbb { P } ( x ) } } } \\ & { \qquad = { \frac { \mathbb { P } ( x \mid y = + 1 ) \cdot \mathbb { P } ( y = + 1 ) } { \sum _ { y ^ { \prime } } \mathbb { P } ( x \mid y ^ { \prime } ) \cdot \mathbb { P } ( y ^ { \prime } ) } } } \\ & { \qquad = { \frac { 1 } { 1 + { \frac { \mathbb { P } ( x \mid y = - 1 ) \cdot \mathbb { P } ( y = - 1 ) } { \mathbb { P } ( x \mid y = + 1 ) \cdot \mathbb { P } ( y = + 1 ) } } } } . } \end{array} }
617
+ $$
618
+
619
+ Now,
620
+
621
+ $$
622
+ \begin{array} { r l } & { \frac { \mathbb { P } ( x \mid y = - 1 ) } { \mathbb { P } ( x \mid y = + 1 ) } = \exp \left( \frac { \| x - \mu _ { + 1 } \| ^ { 2 } - \| x - \mu _ { - 1 } \| ^ { 2 } } { 2 \sigma ^ { 2 } } \right) } \\ & { \quad \quad \quad = \exp \left( \frac { \| \mu _ { + 1 } \| ^ { 2 } - \| \mu _ { - 1 } \| ^ { 2 } - 2 \cdot ( \mu _ { + 1 } - \mu _ { - 1 } ) ^ { \top } x } { 2 \sigma ^ { 2 } } \right) } \\ & { \quad \quad \quad = \exp \left( \frac { - ( \mu _ { + 1 } - \mu _ { - 1 } ) ^ { \top } x } { \sigma ^ { 2 } } \right) . } \end{array}
623
+ $$
624
+
625
+ Thus,
626
+
627
+ $$
628
+ \mathbb { P } ( y = + 1 \mid x ) = \frac { 1 } { 1 + \exp ( - w _ { * } ^ { \top } x + b _ { * } ) } ,
629
+ $$
630
+
631
+ where w∗ = 1σ2 · (µ+1 − µ−1), and b∗ = log P(y=−1)P(y=+1) . This implies that a sigmoid model for $\mathbb { P } ( y = + 1 \mid x )$ , as employed by logistic regression, is well-specified for the problem. Further, the bias term $b _ { * }$ is seen to take the form of the log-odds of the class-priors per (8), as expected.
parse/train/37nvvqkCo5/37nvvqkCo5_content_list.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/37nvvqkCo5/37nvvqkCo5_middle.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/37nvvqkCo5/37nvvqkCo5_model.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/AAWuCvzaVt/AAWuCvzaVt.md ADDED
@@ -0,0 +1,267 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Diffusion Models Beat GANs on Image Synthesis
2
+
3
+ Prafulla Dhariwal⇤ OpenAI prafulla@openai.com
4
+
5
+ Alex Nichol⇤
6
+ OpenAI
7
+ alex@openai.com
8
+
9
+ # Abstract
10
+
11
+ We show that diffusion models can achieve image sample quality superior to the current state-of-the-art generative models. We achieve this on unconditional image synthesis by finding a better architecture through a series of ablations. For conditional image synthesis, we further improve sample quality with classifier guidance: a simple, compute-efficient method for trading off diversity for fidelity using gradients from a classifier. We achieve an FID of 2.97 on ImageNet $1 2 8 \times 1 2 8$ , 4.59 on ImageNet $2 5 6 \times 2 5 6$ , and 7.72 on ImageNet $5 1 2 \times 5 1 2$ , and we match BigGAN-deep even with as few as 25 forward passes per sample, all while maintaining better coverage of the distribution. Finally, we find that classifier guidance combines well with upsampling diffusion models, further improving FID to 3.94 on ImageNet $2 5 6 \times 2 5 6$ and 3.85 on ImageNet $5 1 2 \times 5 1 2$ .
12
+
13
+ # 1 Introduction
14
+
15
+ ![](images/88360c3236154304146ad2cec322e05f63a49acb48c6c1b23c464f964e2fe1f0.jpg)
16
+ Figure 1: Selected samples from our best ImageNet $5 1 2 \times 5 1 2$ model (FID 3.85)
17
+
18
+ Over the past few years, generative models have gained the ability to generate human-like natural language $\mathbf { \partial } [ \mathbf { \overline { { 9 } } } ]$ , high-quality synthetic images [8, 34, 57] and highly diverse human speech and music [70, 17]. These models can be used in a variety of ways, such as generating images from text prompts [78, 56] or learning useful feature representations [18, 10]. While these models are already capable of producing realistic images and sound, there is still much room for improvement beyond the current state-of-the-art, and better generative models could have wide-ranging impacts on graphic design, games, music production, and countless other fields.
19
+
20
+ GANs $\lVert 2 5 \rVert$ currently hold the state-of-the-art on most image generation tasks $\textcircled { 1 8 } \textcircled { 7 4 } \textcircled { 3 4 } \textcircled { 1 }$ as measured by sample quality metrics such as FID $\left[ \left[ 2 9 \right] \right]$ , Inception Score $\pmb { \mathbb { \left| 6 1 \right| } }$ and Precision $\textcircled { 1 3 8 } \textcircled { 1 }$ . However, some of these metrics do not fully capture diversity, and it has been shown that GANs capture less diversity than state-of-the-art likelihood-based models [57, 49, 48]. Furthermore, GANs are often difficult to train, collapsing without carefully selected hyperparameters and regularizers $ { \mathbb { R } } , { \mathbb { G } } { \mathbb { Z } } , { \mathbb { Z } } { \mathbb { I } }$ . While GANs hold the state-of-the-art, their drawbacks make them difficult to scale and apply to new domains. As a result, much work has been done to achieve GAN-like sample quality with likelihood-based models $\pmb { \bigtriangledown } 2 2 \mathbf { l }$ 57, 31, 48, 12]. While these models capture more diversity and are typically easier to scale and train than GANs, they still fall short in terms of visual fidelity. Furthermore, except for VAEs, sampling from these models is slower than GANs in terms of wall-clock time.
21
+
22
+ Diffusion models are a class of likelihood-based models which have recently been shown to produce high-quality images $\pmb { \mathbb { B } } 3 \pmb { \mathbb { B } } 6 2 \pmb { \mathbb { B } } \pmb { \mathbb { B } } \pmb { \mathbb { B } }$ while offering desirable properties such as distribution coverage, a stationary training objective, and easy scalability. These models generate samples by gradually removing noise from a signal, and their training objective can be expressed as a reweighted variational lower-bound $\pmb { \mathbb { B } } \mathbf { \mathbb { 1 } }$ . This class of models already holds the state-of-the-art $\pmb { \Vert 6 7 \Vert }$ on CIFAR-10 [37], but still lags behind GANs on difficult generation datasets like LSUN and ImageNet. We hypothesize that this gap exists for at least two reasons: first, that the model architectures used by recent GAN literature have been heavily explored and refined; second, that GANs are able to trade off diversity for fidelity, producing high quality samples but not covering the whole distribution. We aim to bring these benefits to diffusion models, first by improving model architecture and then by devising a scheme for trading off diversity for fidelity.
23
+
24
+ The rest of the paper is organized as follows. In Section $^ { 2 , }$ we give a brief background of diffusion models based on Ho et al. [31] and the improvements from Nichol and Dhariwal [49] and Song et al. $\pmb { \mathbb { \lVert 6 4 \rVert } }$ , and we describe our evaluation setup. In Section ${ \overline { { 3 , } } }$ we introduce simple architecture improvements that give a substantial boost to FID. In Section $^ { 4 , }$ we describe a method for using gradients from a classifier to guide a diffusion model during sampling. Finally, in Section 5 we show that models with our improved architecture achieve state-of-the-art on unconditional image synthesis tasks, and with classifier guidance achieve state-of-the-art on conditional image synthesis.
25
+
26
+ # 2 Background
27
+
28
+ In this section, we provide a brief overview of diffusion models. For a more detailed mathematical description, we refer the reader to Appendix $\boxplus$ On a high level, diffusion models sample from a distribution by reversing a gradual noising process. In particular, sampling starts with noise $x _ { T }$ and produces gradually less-noisy samples $x _ { T - 1 } , x _ { T - 2 } , . . .$ until reaching a final sample $x _ { 0 }$ . In particular, a diffusion model learns to produce a slightly more “denoised” $x _ { t - 1 }$ from $x _ { t }$ . $\mathbb { H o } \operatorname { e t } { \mathrm { a l } } .$ $\bar { \big \| } 3 1 \big \|$ parameterize this model using a function $\epsilon _ { \theta } ( x _ { t } , t )$ which predicts the noise component of a noisy sample $x _ { t }$ . To train this function, each sample in a minibatch is produced by randomly drawing a data sample $x _ { 0 }$ , a timestep $t$ , and noise $\epsilon$ , which together give rise to a noised sample $x _ { t }$ (Equation 3, Appendix $\mathrm { ^ C } )$ . The training objective is then $| | \epsilon _ { \theta } ( x _ { t } , t ) - \mathbf { \bar { \epsilon } } \epsilon | | ^ { 2 }$ , i.e. a simple mean-squared error loss between the true noise and the predicted noise (Equation 12, Appendix $\bigtriangledown$ .
29
+
30
+ Ho et al. [31] show that, under reasonable assumptions, we can then model the denoising distribution $\overline { { p _ { \theta } ( x _ { t - 1 } | } } x _ { t } )$ of $x _ { t - 1 }$ given $x _ { t }$ as a diagonal Gaussian $\mathcal { N } ( x _ { t - 1 } ; \mu _ { \theta } ( x _ { t } , t ) , \Sigma _ { \theta } ( x _ { t } , t ) )$ , where the mean $\mu _ { \theta } ( x _ { t } , t )$ can be calculated as a function of $\epsilon _ { \theta } ( x _ { t } , t )$ (Equation $^ { 1 3 , }$ Appendix $\underset { . } { \mathbf { C } } )$ Ho et al. [31] observe that the simple mean-squared error objective, $L _ { \mathrm { s i m p l e } }$ , works better in practice than the actual variational lower bound $L _ { \mathrm { v l b } }$ that can be derived from interpreting the denoising diffusion model as a VAE. They also note that training with this objective and using their corresponding sampling procedure is equivalent to the denoising score matching model from $\boxed { \mathrm { S o n g ~ a n d ~ E r m o n } } \boxed { \overline { { 6 5 } } }$ , who use Langevin dynamics to sample from a denoising model trained with multiple noise levels to produce high quality image samples. We often use “diffusion models” as shorthand to refer to both classes of models.
31
+
32
+ Following the breakthrough work of Song and Ermon [65] and Ho et al. [31], several recent papers have proposed improvements to diffusion models. Nichol and Dhariwal [49] find that fixing the variance $\Sigma _ { \theta } ( x _ { t } , t )$ to a constant as done in Ho et al. $\pmb { \mathbb { B } } \mathbf { \mathbb { 1 } }$ is sub-optimal for sampling with fewer diffusion steps, and propose to parameterize $\overline { { \Sigma _ { \theta } ( x _ { t } , t ) } }$ as a neural network whose output $v$ is interpolated as $\Sigma _ { \theta } ( x _ { t } , t ) = \exp ( v \log \beta _ { t } + ( 1 - v ) \log \tilde { \beta } _ { t } )$ . Here, $\beta _ { t }$ and $\tilde { \beta } _ { t }$ (Equation ${ \mathfrak { s } } ,$ Appendix $\mathbf { C } )$ are the variances in Ho et al. $\pmb { \mathbb { B } } \pmb { \mathbb { 1 } }$ corresponding to upper and lower bounds for the reverse process variances. Additionally, Nichol and Dhariwal $\textcircled { \lVert { 4 9 } \rVert }$ propose a hybrid objective for training both $\epsilon _ { \theta } ( x _ { t } , t )$ and $\Sigma _ { \theta } ( x _ { t } , t )$ using the weighted sum $\overline { { L } } _ { \mathrm { s i m p l e } } + \lambda L _ { \mathrm { v l b } }$ . Learning the reverse process variances with their hybrid objective allows sampling with fewer steps without much drop in sample quality. We adopt this objective and parameterization, and use it throughout our experiments.
33
+
34
+ Song et al. [64] propose DDIM, which formulates an alternative non-Markovian noising process that has the same forward marginals as DDPM, but allows producing different reverse samplers by changing the variance of the reverse noise. By setting this noise to 0, they provide a way to turn any model $\epsilon _ { \theta } ( x _ { t } , t )$ into a deterministic mapping from latents to images, and find that this provides an alternative way to sample with fewer steps. We adopt this sampling approach when using fewer than 50 sampling steps, since Nichol and Dhariwal [49] found it to be beneficial in this regime.
35
+
36
+ Sample Quality Metrics: For comparing sample quality across models, we perform quantitative evaluations using the following metrics. While these metrics are often used in practice and correspond well with human judgement, they are not a perfect proxy, and finding better metrics for sample quality evaluation is still an open problem.
37
+
38
+ We use FID $\pmb { \mathbb { Z } } 9 \|$ as our default metric for overall sample quality comparisons as it captures both fidelity and diversity and has been the de facto standard metric for state-of-the-art generative models [33, 34, 8, 31]. We use Precision and Recall $[ [ 3 8 ] ]$ as proxies for separately measuring fidelity and diversity, respectively. We include sFID $\lVert \overline { { 4 8 } } \rVert$ as a metric that better captures spatial relationships than FID, and also include Inception Score (IS) $\pmb { \mathbb { \left[ 6 1 \right] } }$ as another proxy for fidelity. When comparing against other methods, we re-compute these metrics using public samples or models whenever possible. This is for two reasons: first, some papers [33, 34, 31] compare against arbitrary subsets of the training set which are not readily available; and second, subtle implementation differences can affect the resulting FID values $\pmb { \mathbb { B } } \mathbf { \mathbb { 1 } }$ . For consistent comparisons, we use the full training set as the reference batch [29, $\textcircled { 8 } ]$ , and evaluate metrics for all models using the same codebase.
39
+
40
+ # 3 Architecture Improvements
41
+
42
+ Ho et al. [31] adopted the UNet architecture $\pmb { \Vert 5 8 \Vert }$ for diffusion models, which Jolicoeur-Martineau et al. [32] found to substantially improve sample quality over the previous architectures [65, 39] used for denoising score matching. The UNet model uses a stack of residual layers and downsampling convolutions, followed by a stack of residual layers with upsampling convolutions, with skip connections connecting the layers with the same spatial size. In addition, they use a global attention layer at the $1 6 \times 1 6$ resolution with a single head, and add a projection of the timestep embedding into each residual block. $\boxed { \mathrm { S o n g ~ e t ~ a l . } \parallel \boxed { 6 7 } }$ found that further changes to the UNet architecture improved performance on the CIFAR-10 [37] and CelebA-64 [40] datasets. We show the same result on ImageNet $1 2 8 \times 1 2 8$ , finding that architecture can indeed give a substantial boost to sample quality on a much larger and more diverse datasets at a higher resolution.
43
+
44
+ We explore the following architectural changes: increasing depth versus width, holding model size relatively constant; increasing the number of attention heads; using attention at $3 2 \times 3 2$ , $1 6 \times 1 6$ , and $8 \times 8$ resolutions rather than only at $1 6 \times 1 6$ ; using the BigGAN $\pmb { \Vert 8 \Vert }$ residual block for upsampling and downsampling the activations, following $ { \mathbb { I } } { \mathbb { I } }$ ; and finally; rescaling residual connections with $\scriptstyle { \frac { 1 } { \sqrt { 2 } } }$ , following [67, 33, 34].
45
+
46
+ We train models with the above architecture changes on ImageNet $1 2 8 \times 1 2 8$ and compare them on FID, evaluated at two different points of training, in Table $\nsupseteq$ Aside from rescaling residual connections, all of the other modifications improve performance and have a positive compounding effect. On wall-clock (Figure $5 ,$ Appendix $\bar { \bigstar . 1 \bigstar }$ we find that increased depth hurts training time most, so we opt not to use this change in further experiments. We also study other attention configurations that better match the Transformer architecture $\lVert \ b { 7 2 } \rVert$ . We try two configurations: constant attention heads, or constant channels per head. Table $\bigstar$ shows our results, indicating that more heads or fewer channels per head improves FID. On wall-clock (Figure $\boxed { 5 }$ Appendix $\mathbf { A . l } )$ , we see that 64 channels is best so we opt to use 64 channels per head as our default. We note that this choice also better matches modern transformer architectures, and is on par with our other configurations in terms of final FID.
47
+
48
+ Table 1: Ablation of various architecture changes, evaluated at 700K and 1200K iterations
49
+
50
+ <table><tr><td>Channels</td><td>Depth</td><td>Heads</td><td>Attention resolutions</td><td>BigGAN up/downsample</td><td>Rescale resblock</td><td>FID 700K</td><td>FID 1200K</td></tr><tr><td>160</td><td>2</td><td>1</td><td>16</td><td>X</td><td>X</td><td>15.33</td><td>13.21</td></tr><tr><td>128</td><td>4</td><td></td><td></td><td></td><td></td><td>-0.21</td><td>-0.48</td></tr><tr><td></td><td></td><td>4</td><td></td><td></td><td></td><td>-0.54</td><td>-0.82</td></tr><tr><td></td><td></td><td></td><td>32,16,8</td><td></td><td></td><td>-0.72</td><td>-0.66</td></tr><tr><td></td><td></td><td></td><td></td><td>√</td><td></td><td>-1.20</td><td>-1.21</td></tr><tr><td></td><td></td><td></td><td></td><td></td><td></td><td>0.16</td><td>0.25</td></tr><tr><td>160</td><td>2</td><td>4</td><td>32,16,8</td><td>√</td><td>×</td><td>-3.14</td><td>-3.00</td></tr></table>
51
+
52
+ Table 2: Ablation of attention heads. More heads or lower channels per heads both improve FID. The base model was a smaller version of the best model from Table 1.
53
+
54
+ <table><tr><td>Number of heads</td><td>Channels per head</td><td>FID</td></tr><tr><td>1</td><td></td><td>14.08</td></tr><tr><td>2</td><td></td><td>-0.50</td></tr><tr><td>4</td><td></td><td>-0.97</td></tr><tr><td>8</td><td></td><td>-1.17</td></tr><tr><td></td><td>32</td><td>-1.36</td></tr><tr><td></td><td>64</td><td>-1.03</td></tr><tr><td></td><td>128</td><td>-1.08</td></tr></table>
55
+
56
+ We also experiment with a layer $\boxed { \boxplus 9 }$ that we refer to as adaptive group normalization (AdaGN), which incorporates the timestep and class embedding into each residual block after a group normalization operation $\mathbb { [ [ \mathsf { Z } \mathsf { S } ] ] }$ , similar to adaptive instance norm $\pmb { \Vert 3 3 \Vert }$ and FiLM [54]. We define this layer as $\mathrm { A d a G N } ( h , y ) = y _ { s }$ $\mathrm { G r o u p N o r m } ( h ) + y _ { b }$ , where $h$ is the intermediate activations of the residual block following the first convolution, and $y = [ y _ { s } , y _ { b } ]$ is obtained from a linear projection of the timestep and class embedding. We had already seen AdaGN improve our earliest diffusion models, and so had included it by default in all our runs. We explicitly ablate this choice (Table $6 ,$ , Appendix $\underline { { \vert \overline { { \mathbf { A . } } } \mathbf { l } \mathbf { \rangle } } }$ , and find that FID becomes worse by 2.02 when we remove the adaptive group normalization layer.
57
+
58
+ In the rest of the paper, we use this final improved model architecture as our default: variable width with 2 residual blocks per resolution, multiple heads with 64 channels per head, attention at 32, 16 and 8 resolutions, BigGAN residual blocks for up and downsampling, and adaptive group normalization for injecting timestep and class embeddings into residual blocks.
59
+
60
+ # 4 Classifier Guidance
61
+
62
+ In addition to employing well designed architectures, GANs for conditional image synthesis [45, 8] make heavy use of class labels. This often takes the form of class-conditional normalization statistics $\mathbb { \ Z O } \mathbb { \perp } \mathbb { \perp } \mathbb { I }$ as well as discriminators with heads explicitly designed to behave like classifiers $p ( y | x )$ [46]. As further evidence that class information is crucial to the success of these models, Lucic et al. [42] find that it is helpful to generate synthetic labels when working in a label-limited regime. Given this observation for GANs, it makes sense to explore different ways to condition diffusion models on class labels. We already incorporate class information into adaptive group normalization layers (Section $3 )$ . Here, we explore a different approach: exploiting a classifier $p ( y | x )$ to improve a diffusion generator. Sohl-Dickstein et al. $\mathbb { \left[ 6 3 \right] }$ and $\widetilde { \mathbb { S } \mathrm { o n g } \ e t \ a l . } \Vert \widehat { \mathbb { b } \mathrm { 7 } } \Vert$ show one way to achieve this, wherein a pre-trained diffusion model can be conditioned using the gradients of a classifier. In particular, we can train a classifier $p _ { \phi } ( y | x _ { t } , t )$ on noisy images $x _ { t }$ , and then use gradients $\nabla _ { x _ { t } } \log \overset { \cdot } { p _ { \phi } } ( y | x _ { t } , t )$ to guide the diffusion sampling process towards an arbitrary class label $y$ .
63
+
64
+ For class conditional diffusion sampling, we reproduce the derivation from Sohl-Dickstein et al. [63] in Appendix $\mathbb { D . 2 }$ For DDIM, we perform a score-based derivation in Appendix $\overline { { \mathbf { D } . 3 } }$ inspired by Song et al. $[ \overbrace { 6 7 } ]$ . The resulting sampling algorithms we use for guidance are Algorithms $\mathbf { \overline { { \Pi } } }$ and $\dot { 2 }$ respectively. Both algorithms incorporate class information by adding the gradients of a classifier to each sampling step with an appropriate step size. In these algorithms, we choose the notation
65
+
66
+ Algorithm 1 Classifier guided diffusion sampling, given a diffusion model $( \mu _ { \theta } ( x _ { t } ) , \Sigma _ { \theta } ( x _ { t } ) )$ , classifier $p _ { \phi } ( y | x _ { t } )$ , and gradient scale $s$ .
67
+
68
+ Input: class label $y$ , gradient scale $s$
69
+ $x _ { T } \gets$ sample from $\mathcal { N } ( 0 , \bf { I } )$
70
+ for all $t$ from $T$ to 1 do $\mu , \Sigma \mu _ { \theta } ( x _ { t } ) , \Sigma _ { \theta } ( x _ { t } )$ $x _ { t - 1 } \gets$ sample from $\overset { \vartriangle } { \mathcal { N } } ( \mu + s \Sigma \nabla _ { x _ { t } } \log p _ { \phi } ( y | x _ { t } ) , \Sigma )$
71
+ end for
72
+ return $x _ { 0 }$
73
+
74
+ Algorithm 2 Classifier guided DDIM sampling, given a diffusion model $\epsilon _ { \theta } ( x _ { t } )$ , classifier $\overline { { p _ { \phi } ( y | x _ { t } ) } }$ and gradient scale $s$ .
75
+
76
+ Input: class label $y$ , gradient scale $s$
77
+ $x _ { T } \gets$ sample from $\bar { \mathcal { N } } ( 0 , \mathbf { I } )$
78
+ for all $t$ from $T$ to 1 do $\begin{array} { r l } & { \hat { \epsilon } \epsilon _ { \theta } ( x _ { t } ) - \sqrt { 1 - \bar { \alpha } _ { t } } \nabla _ { x _ { t } } \log p _ { \phi } ( y \vert x _ { t } ) } \\ & { x _ { t - 1 } \sqrt { \bar { \alpha } _ { t - 1 } } ( \frac { x _ { t } - \sqrt { 1 - \bar { \alpha } _ { t } } \hat { \epsilon } } { \sqrt { \bar { \alpha } _ { t } } } ) + \sqrt { 1 - \bar { \alpha } _ { t - 1 } } \hat { \epsilon } } \end{array}$
79
+ end for
80
+ return $x _ { 0 }$
81
+
82
+ ![](images/17ede98c7663465d7ae64d6b390139ee6801c95c8a9097d5ed812d3bb08e68d8.jpg)
83
+ Figure 2: Samples from an unconditional diffusion model with classifier guidance to condition on the class "Pembroke Welsh corgi". Using classifier scale 1.0 (left; FID: 33.0) does not produce convincing samples in this class, whereas classifier scale 10.0 (right; FID: 12.0) produces much more class-consistent images.
84
+
85
+ $p _ { \phi } ( y | x _ { t } , t ) = p _ { \phi } ( y | x _ { t } )$ and $\epsilon _ { \theta } ( x _ { t } , t ) = \epsilon _ { \theta } ( x _ { t } )$ for brevity, noting that they refer to separate functions for each timestep $t$ and at training time the models must be conditioned on the input $t$ .
86
+
87
+ To apply classifier guidance to a large scale generative task, we train classification models on ImageNet. Our classifier architecture is simply the downsampling trunk of the UNet model with an attention pool $\begin{array} { r l } { \| \boldsymbol { \bar { 5 } } \boldsymbol { \bar { 5 } } \| } & { { } } \end{array}$ at the $8 \mathrm { x } 8$ layer to produce the final output. We train these classifiers on the same noising distribution as the corresponding diffusion model, and also add random crops to reduce overfitting.
88
+
89
+ In initial experiments with unconditional ImageNet models, we found it necessary to scale the classifier gradients by a constant factor larger than 1. When using a scale of 1, we observed that the classifier assigned reasonable probabilities (around $5 0 \%$ ) to the desired classes for the final samples, but these samples did not match the intended classes upon visual inspection. Scaling up the classifier gradients remedied this problem, and the class probabilities from the classifier increased to nearly $100 \%$ . Figure $2$ shows an example of this effect. To understand the effect of scaling classifier gradients, note that $\begin{array} { r } { s \cdot \nabla _ { x } \log p ( y | x ) \stackrel { \cdot } { = } \nabla _ { x } \log \frac { 1 } { Z } p ( y | x ) ^ { s } } \end{array}$ , where $Z$ is an arbitrary constant. As a result, the conditioning process is still theoretically grounded in a re-normalized classifier distribution proportional to $p ( y | x ) ^ { s }$ . When $s > 1$ , this distribution becomes sharper than $p ( y | x )$ , since larger values are amplified by the exponent. In other words, using a larger gradient scale focuses more on the modes of the classifier, which is potentially desirable for producing higher quality (but less diverse) samples.
90
+
91
+ In the above derivations, we assumed that the underlying diffusion model was unconditional, modeling $p ( x )$ . It is also possible to train conditional diffusion models, $p ( x | y )$ , and use classifier guidance in the exact same way. Table $3$ shows that the sample quality of both unconditional and conditional models can be greatly improved by classifier guidance. We see that, with a high enough scale, the guided unconditional model can get quite close to the FID of an unguided conditional model, although training directly with the class labels still helps. Guiding a conditional model further improves FID.
92
+
93
+ ![](images/b972c296c95e38207891fcbe7c43985a22a9400506330b2ed868ce523a2947d5.jpg)
94
+ Figure 3: Change in sample quality as we vary scale of the classifier gradients for a class-conditional ImageNet $1 2 8 \times 1 2 8$ model.
95
+
96
+ Table $3$ also shows that classifier guidance improves precision at the cost of recall, thus introducing a trade-off in sample fidelity versus diversity. We explicitly evaluate how this trade-off varies with the gradient scale in Figure $\textcircled { 3 }$ We see that scaling the gradients beyond 1.0 smoothly trades off recall (a measure of diversity) for higher precision and IS (measures of fidelity). Since FID and sFID depend on both diversity and fidelity, their best values are obtained at an intermediate point. We also compare our guidance with the truncation trick from BigGAN (Figure $6 ,$ Appendix A.2). We find that classifier guidance is strictly better than BigGAN-deep when trading off FID for Inception Score. Less clear cut is the precision/recall trade-off, which shows that classifier guidance is only a better choice up until a certain precision threshold, after which point it cannot achieve better precision.
97
+
98
+ # 5 Results
99
+
100
+ To evaluate our improved model architecture on unconditional image generation, we train separate diffusion models on three LSUN $\mathbb { \ m }$ classes: bedroom, horse, and cat. To evaluate classifier guidance, we train conditional diffusion models on the ImageNet $\mathbb { \left[ 5 9 \right] }$ dataset at $1 2 8 \times 1 2 8$ , $2 5 6 \times 2 5 6$ , and $5 1 2 \times 5 1 2$ resolution.
101
+
102
+ Table 4 summarizes our results. ADM refers to our ablated diffusion model, and ADM-G additionally uses classifier guidance. Our diffusion models can obtain the best FID on each task, and the best sFID on all but one task. With the improved architecture, we already obtain state-of-the-art image generation on LSUN and ImageNet $6 4 \times 6 4$ . For higher resolution ImageNet, we observe that classifier guidance allows our models to substantially outperform the best GANs. These models obtain perceptual quality similar to GANs, while maintaining a higher coverage of the distribution as measured by recall, and can even do so using only 25 sampling steps. We also evaluate the computational requirements for training our models (Table $\underline { { \overline { { 1 0 } } } } ,$ Appendix $\mathbf { B } )$ , and find that we can obtain competitive sample quality while using the same or less compute than the corresponding BigGAN-deep or StyleGAN2 model.
103
+
104
+ Figure 4 compares random samples from the best BigGAN-deep model to our guided diffusion model. While the samples are of similar perceptual quality, the diffusion model contains more modes than the GAN, such as zoomed ostrich heads, single flamingos, different orientations of cheeseburgers, and a tinca fish with no human holding it. We also check our generated samples for nearest neighbors in the Inception-V3 feature space in Appendix E, and we show additional samples in Appendices M-O.
105
+
106
+ Table 4: Sample quality comparison with state-of-the-art generative models for each task. LSUN diffusion models are sampled using 1000 steps (see Appendix $\bigstar \bigstar$ . ImageNet diffusion models are sampled using 250 steps, except when we use the DDIM sampler with 25 steps. \*No BigGAN-deep model was available at this resolution, so we trained our own. †Values are taken from a previous paper, due to lack of public models or samples. ‡Results use two-resolution stacks. §Results use compute-intensive classifier rejection sampling.
107
+
108
+ <table><tr><td>Model</td><td>FID</td><td>sFID</td><td>Prec</td><td>Rec</td></tr><tr><td colspan="5">LSUN Bedrooms 256×256 DCTransformer+ 48</td></tr><tr><td>DDPM [31]</td><td>6.40 4.89</td><td>6.66 9.07</td><td>0.44 0.60</td><td>0.56 0.45</td></tr><tr><td>IDDPM[49]</td><td>4.24</td><td>8.21</td><td>0.62</td><td>0.46</td></tr><tr><td>StyleGAN [33]</td><td>2.35</td><td>6.62</td><td>0.59</td><td>0.48</td></tr><tr><td>ADM (dropout)</td><td>1.90</td><td>5.59</td><td>0.66</td><td>0.51</td></tr><tr><td colspan="5">LSUN Horses 256×256</td></tr><tr><td>StyleGAN2 34 ADM ADM (dropout)</td><td>3.84 2.95</td><td>6.46 5.94</td><td>0.63 0.69</td><td>0.48 0.55</td></tr><tr><td></td><td>2.57</td><td>6.81</td><td>0.71</td><td>0.55</td></tr><tr><td>LSUN Cats 256×256</td><td></td><td></td><td></td><td></td></tr><tr><td colspan="5">DDPM [31]</td></tr><tr><td>StyleGAN2 [34]</td><td>17.1</td><td>12.4</td><td>0.53</td><td>0.48</td></tr><tr><td></td><td>7.25</td><td>6.33</td><td>0.58</td><td>0.43</td></tr><tr><td>ADM (dropout)</td><td>5.57</td><td>6.69</td><td>0.63</td><td>0.52</td></tr><tr><td>ImageNet 64×64</td><td></td><td></td><td></td><td></td></tr><tr><td colspan="5">BigGAN-deep* 回</td></tr><tr><td></td><td>4.06</td><td>3.96</td><td>0.79</td><td>0.48</td></tr><tr><td>IDDPM[ [49]</td><td>2.92</td><td>3.79</td><td>0.74</td><td>0.62</td></tr><tr><td>ADM</td><td>2.61</td><td>3.77</td><td>0.73</td><td>0.63</td></tr><tr><td>ADM (dropout)</td><td>2.07</td><td>4.29</td><td>0.74</td><td>0.63</td></tr></table>
109
+
110
+ <table><tr><td>Model</td><td>FID</td><td>SFID</td><td>Prec</td><td>Rec</td></tr><tr><td>ImageNet 128×128 BigGAN-deep 8</td><td>6.02</td><td>7.18</td><td>0.86</td><td>0.35</td></tr><tr><td>LOGANt 四</td><td>3.36</td><td></td><td></td><td></td></tr><tr><td>ADM</td><td>5.91</td><td>5.09</td><td>0.70</td><td>0.65</td></tr><tr><td>ADM-G (25 steps)</td><td>5.98</td><td>7.04</td><td>0.78</td><td>0.51</td></tr><tr><td>ADM-G</td><td>2.97</td><td>5.09</td><td>0.78</td><td>0.59</td></tr><tr><td>ImageNet 256×256</td><td></td><td></td><td></td><td></td></tr><tr><td>DCTransformer† 8</td><td>36.51</td><td>8.24</td><td></td><td>0.67</td></tr><tr><td>VQ-VAE-2†‡ 回</td><td></td><td></td><td>0.36</td><td></td></tr><tr><td></td><td>31.11</td><td>17.38</td><td>0.36</td><td>0.57</td></tr><tr><td>VQ-VAE-2 (RS)t‡ $ 四</td><td>~10</td><td></td><td></td><td>0.58</td></tr><tr><td>VQ-GAN* 四</td><td>15.97</td><td>19.05</td><td>0.63</td><td>0.48</td></tr><tr><td>VQ-GAN (RS)t$ 四 IDDPM‡ [ 49</td><td>5.06 12.26</td><td>7.34 5.42</td><td>0.79 0.70</td><td>0.62</td></tr><tr><td>SR3tt 四</td><td>11.30</td><td></td><td></td><td></td></tr><tr><td>BigGAN-deep 回</td><td>6.95</td><td>7.36</td><td>0.87</td><td>0.28</td></tr><tr><td>ADM</td><td>10.94</td><td>6.02</td><td>0.69</td><td>0.63</td></tr><tr><td>ADM-G (25 steps)</td><td>5.44</td><td>5.32</td><td>0.81</td><td>0.49</td></tr><tr><td>ADM-G</td><td>4.59</td><td>5.25</td><td>0.82</td><td>0.52</td></tr><tr><td>ImageNet 512×512</td><td></td><td></td><td></td><td></td></tr><tr><td>BigGAN-deep 图</td><td>8.43</td><td>8.13</td><td></td><td>0.29</td></tr><tr><td>ADM</td><td></td><td></td><td>0.88</td><td></td></tr><tr><td></td><td>23.24</td><td>10.19</td><td>0.73</td><td>0.60</td></tr><tr><td>ADM-G (25 steps)</td><td>8.41</td><td>9.67</td><td>0.83</td><td>0.47</td></tr><tr><td>ADM-G</td><td>7.72</td><td>6.57</td><td>0.87</td><td>0.42</td></tr></table>
111
+
112
+ We also compare guidance to using a two-stage upsampling stack. Nichol and Dhariwal [49] and Saharia et al. $\boxed { 6 0 }$ train two-stage diffusion models by combining a low-resolution diffusion model with a corresponding upsampling diffusion model. In this approach, the upsampling model is trained to upsample images from the training set, and conditions on low-resolution images that are concatenated channel-wise to the model input using a simple interpolation (e.g. bilinear). During sampling, the low-resolution model produces a sample, and then the upsampling model is conditioned on this sample. This greatly improves FID on ImageNet $2 5 6 \times 2 5 6$ , but does not reach the same performance as state-of-the-art models like BigGAN-deep [49, 60], as seen in Table 4.
113
+
114
+ In Table $\boxed { 5 }$ we show that guidance and upsampling improve sample quality along different axes. We use the upsampling stack from Nichol and Dhariwal [49] combined with our architecture improvements, which we refer to as ADM-U. While upsampling improves precision while keeping a high recall, guidance provides a knob to trade off diversity for much higher precision. We achieve the best FIDs by using guidance at a lower resolution before upsampling to a higher resolution, indicating that these approaches complement one another.
115
+
116
+ # 6 Related Work
117
+
118
+ Score based generative models were introduced by Song and Ermon [66] as a way of modeling a data distribution using its gradients, and then sampling using Langevin dynamics [73]. Ho et al. [31] found a connection between this method and diffusion models $\pmb { \mathbb { E 3 } } ] $ , and achieved excellent sample quality by leveraging this connection. After this breakthrough work, many works followed up with more promising results: Kong et al. [36] and Chen et al. [11] demonstrated that diffusion models work well for audio; Jolicoeur-Martineau et al. [32] found that a GAN-like setup could improve samples from these models; Song et al. [67] explored ways to leverage techniques from stochastic differential equations to improve the sample quality obtained by score-based models; Song et al. [64] and Nichol and Dhariwal [49] proposed methods to improve sampling speed; Nichol and Dhariwal [49] and Saharia et al. [60] demonstrated promising results on the difficult ImageNet generation task using upsampling diffusion models. Also related to diffusion models, and following the work of Sohl-Dickstein et al. [63], Goyal et al. [27] described a technique for learning a model with learned iterative generation steps, and found that it could achieve good image samples when trained with a likelihood objective.
119
+
120
+ ![](images/d9704a85040ab49727c123479c513cf7b2c243c18519d8a70391578c96ff2109.jpg)
121
+ Figure 4: Samples from BigGAN-deep with truncation 1.0 (FID 6.95, left) vs samples from our diffusion model with guidance (FID 4.59, middle) and samples from the training set (right).
122
+
123
+ Table 5: Comparing our single, upsampling and classifier guided models. The upsamplers are $6 4 2 5 6$ and $1 2 8 \to 5 1 2$ . When combining guidance with upsampling, we only guide the lower resolution model. All models are sampled using 250 sampling steps.
124
+
125
+ <table><tr><td>Model</td><td>FID</td><td>sFID</td><td>IS</td><td>Prec</td><td>Rec</td><td>Model</td><td>FID</td><td>SFID</td><td>IS</td><td>Prec</td><td>Rec</td></tr><tr><td>ImageNet 256×256</td><td></td><td></td><td></td><td></td><td></td><td>ImageNet 512×512</td><td></td><td></td><td></td><td></td><td></td></tr><tr><td>ADM</td><td>10.94</td><td>6.02</td><td>100.98</td><td>0.69</td><td>0.63</td><td>ADM</td><td>23.24</td><td>10.19</td><td>58.06</td><td>0.73</td><td>0.60</td></tr><tr><td>ADM, ADM-U</td><td>7.49</td><td>5.13</td><td>127.49</td><td>0.72</td><td>0.63</td><td>ADM, ADM-U</td><td>9.96</td><td>5.62</td><td>121.78</td><td>0.75</td><td>0.64</td></tr><tr><td>ADM-G</td><td>4.59</td><td>5.25</td><td>186.70</td><td>0.82</td><td>0.52</td><td>ADM-G</td><td>7.72</td><td>6.57</td><td>172.71</td><td>0.87</td><td>0.42</td></tr><tr><td>ADM-G,ADM-U</td><td>3.94</td><td>6.14</td><td>215.84</td><td>0.83</td><td>0.53</td><td>ADM-G, ADM-U</td><td>3.85</td><td>5.86</td><td>221.72</td><td>0.84</td><td>0.53</td></tr></table>
126
+
127
+ One missing element from previous work on diffusion models is a way to trade off diversity for fidelity. Other generative techniques provide natural levers for this trade-off. Brock et al. [8] introduced the truncation trick for GANs, wherein the latent vector is sampled from a truncated normal distribution. They found that increasing truncation naturally led to a decrease in diversity but an increase in fidelity. More recently, Razavi et al. [57] proposed to use classifier rejection sampling to filter out bad samples from an autoregressive likelihood-based model, and found that this technique improved FID. DeVries et al. [16] found that filtering out low-density regions of the training set improves GAN training performance. Most likelihood-based models also allow for low-temperature sampling [1], which provides a natural way to emphasize modes of the data distribution (see Appendix I).
128
+
129
+ Other likelihood-based models have been shown to produce high-fidelity image samples. VQ-VAE $\pmb { \mathbb { Z } 1 }$ and VQ-VAE-2 $ { \mathbb { B } } { \mathbb { Z } }$ are autoregressive models trained on top of quantized latent codes, greatly reducing the computational resources required to train these models on large images. These models produce diverse and high quality images, but still fall short of GANs without expensive rejection sampling and special metrics to compensate for blurriness. DCTransformer $\lVert \rVert$ is a related method which relies on a more intelligent compression scheme. VAEs are another promising class of likelihood-based models, and recent methods such as NVAE $\textcircled { 1 6 9 } \textcircled { 1 }$ and VDVAE $\lVert \dot { 1 } \dot { 2 } \rVert$ have successfully been applied to difficult image generation domains. Energy-based models are another class of likelihood-based models with a rich history [1, 13, 30]. Sampling from the EBM distribution is challenging, and Xie et al. $\pmb { \mathbb { Z } } \pmb { 6 } \|$ demonstrate that Langevin dynamics can be used to sample coherent images from these models. Du and Mordatch [19] further improve upon this approach, obtaining high quality images. More recently, Gao et al. [24] incorporate diffusion steps into an energy-based model, and find that doing so improves image samples from these models.
130
+
131
+ Other works have controlled generative models with a pre-trained classifier. For example, an emerging body of work [23, 53, 2] aims to optimize GAN latent spaces for text prompts using pre-trained CLIP $\pmb { \| 5 5 \| }$ models. More similar to our work, Song et al. $\textcircled { 6 7 }$ uses a classifier to generate class-conditional CIFAR-10 images with a diffusion model. In some cases, classifiers can act as stand-alone generative models. For example, Santurkar et al. [62] demonstrate that a robust image classifier can be used as a stand-alone generative model, and Grathwohl et al. [28] train a model which is jointly a classifier and an energy-based model.
132
+
133
+ # 7 Limitations and Future Work
134
+
135
+ While we believe diffusion models are an extremely promising direction for generative modeling, they are still slower than GANs at sampling time due to the use of multiple denoising steps (and therefore forward passes). Since our diffusion models are also larger than the competing GAN generators, each forward pass takes anywhere from 5-20 times longer too. A promising direction to reduce this latency gap is Luhman and Luhman [43], who explore a way to distill the DDIM sampling process into a single step model. The samples from the single step model are not yet competitive with GANs, but are much better than previous single-step likelihood-based models. Future work in this direction might be able to completely close the sampling speed gap between diffusion models and GANs without sacrificing image quality.
136
+
137
+ Unlike GANs, Flows, and VAEs, diffusion models do not learn an explicit latent representation. While DDIM provides a way to encode images into an implicit latent space, it is unclear how semantically meaningful this latent representation is compared to those of other model classes. This could make it difficult to use diffusion models for representation learning or image editing applications.
138
+
139
+ The effectiveness of classifier guidance demonstrates that we can obtain powerful generative models from the gradients of a classification function. This could be used to condition an image generator with a text caption using a noisy version of CLIP $ { \mathbb { I } } { \mathbb { I } } ^ { { 5 } { 5 } { \mathbb { I } } }$ , similar to recent methods that guide GANs using text prompts $\pm \sqrt { 2 3 } \sqrt { 5 3 } \sqrt { 2 }$ . Our proposed classifier guidance technique is currently limited to labeled datasets. In the future, our method could be extended to unlabeled data by clustering samples to produce synthetic labels $[ | \overline { { 4 2 } } | |$ or by training discriminative models to use for guidance. This also suggests that large unlabeled datasets could be leveraged in the future to pre-train powerful diffusion models that can later be improved by using a classifier with desirable properties.
140
+
141
+ # 8 Societal Impact
142
+
143
+ Our proposed technique makes generative models more accessible in terms of compute costs, especially because new classifiers can be trained and used on top of existing high-quality diffusion models. While we believe this is generally a benefit of these models, it could also have negative societal implications. For example, cheaper generative models could enable bad actors to generate fake news, propaganda images, or doctored photos. Additionally, the wide-spread deployment of these models could displace jobs in art, graphic design, animation, and photography. One could imagine, however, that democratizing generative models could also have positive impacts in the long run, creating new types of jobs such as generative photo editing. Intentionally deceitful generated images are a more direct concern, and detecting and mitigating propaganda and fake news based on generative models is an ongoing area of research [4, 3, 5].
144
+
145
+ # 9 Conclusion
146
+
147
+ We have shown that diffusion models, a class of likelihood-based models with a stationary training objective, can obtain better sample quality than state-of-the-art GANs. Our improved architecture is sufficient to achieve this on unconditional image generation tasks, and our classifier guidance technique allows us to do so on class-conditional tasks. In the latter case, we find that the scale of the classifier gradients can be adjusted to trade off diversity for fidelity. These guided diffusion models can reduce the sampling time gap between GANs and diffusion models, although diffusion models still require multiple forward passes during sampling. Finally, by combining guidance with upsampling, we can further improve sample quality on high-resolution conditional image synthesis.
148
+
149
+ # References
150
+
151
+ [1] David Ackley, Geoffrey Hinton, and Terrence Sejnowski. A learning algorithm for boltzmann machines. Cognitive science, 9(1):147-169, 1985.
152
+ [2] Adverb. The big sleep. https://twitter.com/advadnoun/status/ 1351038053033406468, 2021.
153
+ [3] Shruti Agarwal, Hany Farid, Yuming Gu, Mingming He, Koki Nagano, and Hao Li. Protecting world leaders against deep fakes. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR) Workshops, June 2019.
154
+ [4] Hadeer Ahmed, Issa Traore, and Sherif Saad. Detection of online fake news using n-gram analysis and machine learning techniques. pages 127–138, 10 2017. ISBN 978-3-319-69154-1. doi: 10.1007/978-3-319-69155-8_9.
155
+ [5] Hadeer Ahmed, Issa Traore, and Sherif Saad. Detecting opinion spams and fake news using text classification. Security and Privacy, 1(1):e9, 2018. doi: https://doi.org/10.1002/spy2.9. URL https://onlinelibrary.wiley.com/doi/abs/10.1002/spy2.9.
156
+ [6] Shane Barratt and Rishi Sharma. A note on the inception score. arXiv:1801.01973, 2018.
157
+ [7] Andrew Brock, Theodore Lim, J. M. Ritchie, and Nick Weston. Neural photo editing with introspective adversarial networks. arXiv:1609.07093, 2016.
158
+ [8] Andrew Brock, Jeff Donahue, and Karen Simonyan. Large scale gan training for high fidelity natural image synthesis. arXiv:1809.11096, 2018.
159
+ [9] Tom B. Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah, Jared Kaplan, Prafulla Dhariwal, Arvind Neelakantan, Pranav Shyam, Girish Sastry, Amanda Askell, Sandhini Agarwal, Ariel Herbert-Voss, Gretchen Krueger, Tom Henighan, Rewon Child, Aditya Ramesh, Daniel M. Ziegler, Jeffrey Wu, Clemens Winter, Christopher Hesse, Mark Chen, Eric Sigler, Mateusz Litwin, Scott Gray, Benjamin Chess, Jack Clark, Christopher Berner, Sam McCandlish, Alec Radford, Ilya Sutskever, and Dario Amodei. Language models are few-shot learners. arXiv:2005.14165, 2020.
160
+ [10] Mark Chen, Alec Radford, Rewon Child, Jeffrey Wu, Heewoo Jun, David Luan, and Ilya Sutskever. Generative pretraining from pixels. In International Conference on Machine Learning, pages 1691–1703. PMLR, 2020.
161
+ [11] Nanxin Chen, Yu Zhang, Heiga Zen, Ron J. Weiss, Mohammad Norouzi, and William Chan. Wavegrad: Estimating gradients for waveform generation. arXiv:2009.00713, 2020.
162
+ [12] Rewon Child. Very deep vaes generalize autoregressive models and can outperform them on images. arXiv:2011.10650, 2021.
163
+ [13] Peter Dayan, Geoffrey E Hinton, Radford M Neal, and Richard S Zemel. The helmholtz machine. Neural computation, 7(5):889–904, 1995.
164
+ [14] Harm de Vries, Florian Strub, Jérémie Mary, Hugo Larochelle, Olivier Pietquin, and Aaron Courville. Modulating early visual processing by language. arXiv:1707.00683, 2017.
165
+ [15] DeepMind. Biggan-deep $1 2 8 \mathrm { x } 1 2 8$ on tensorflow hub. https://tfhub.dev/deepmind/ biggan-deep-128/1, 2018.
166
+ [16] Terrance DeVries, Michal Drozdzal, and Graham W. Taylor. Instance selection for gans. arXiv:2007.15255, 2020.
167
+ [17] Prafulla Dhariwal, Heewoo Jun, Christine Payne, Jong Wook Kim, Alec Radford, and Ilya Sutskever. Jukebox: A generative model for music. arXiv:2005.00341, 2020.
168
+ [18] Jeff Donahue and Karen Simonyan. Large scale adversarial representation learning. arXiv:1907.02544, 2019.
169
+ [19] Yilun Du and Igor Mordatch. Implicit generation and generalization in energy-based models. arXiv:1903.08689, 2019.
170
+ [20] Vincent Dumoulin, Jonathon Shlens, and Manjunath Kudlur. A learned representation for artistic style. arXiv:1610.07629, 2017.
171
+ [21] Patrick Esser, Robin Rombach, and Björn Ommer. Taming transformers for high-resolution image synthesis. arXiv:2012.09841, 2020.
172
+ [22] Jeffrey De Fauw, Sander Dieleman, and Karen Simonyan. Hierarchical autoregressive image models with auxiliary decoders. arXiv:1903.04933, 2019.
173
+ [23] Federico A. Galatolo, Mario G. C. A. Cimino, and Gigliola Vaglini. Generating images from caption and vice versa via clip-guided generative latent space search. arXiv:2102.01645, 2021.
174
+ [24] Ruiqi Gao, Yang Song, Ben Poole, Ying Nian Wu, and Diederik P. Kingma. Learning energybased models by diffusion recovery likelihood. arXiv:2012.08125, 2020.
175
+ [25] Ian J. Goodfellow, Jean Pouget-Abadie, Mehdi Mirza, Bing Xu, David Warde-Farley, Sherjil Ozair, Aaron Courville, and Yoshua Bengio. Generative adversarial networks. arXiv:1406.2661, 2014.
176
+ [26] Google. Cloud tpus. https://cloud.google.com/tpu/, 2018.
177
+ [27] Anirudh Goyal, Nan Rosemary Ke, Surya Ganguli, and Yoshua Bengio. Variational walkback: Learning a transition operator as a stochastic recurrent net. arXiv:1711.02282, 2017.
178
+ [28] Will Grathwohl, Kuan-Chieh Wang, Jörn-Henrik Jacobsen, David Duvenaud, Mohammad Norouzi, and Kevin Swersky. Your classifier is secretly an energy based model and you should treat it like one. arXiv:1912.03263, 2019.
179
+ [29] Martin Heusel, Hubert Ramsauer, Thomas Unterthiner, Bernhard Nessler, and Sepp Hochreiter. Gans trained by a two time-scale update rule converge to a local nash equilibrium. Advances in Neural Information Processing Systems 30 (NIPS 2017), 2017.
180
+ [30] Geoffrey E Hinton. Training products of experts by minimizing contrastive divergence. Neural computation, 14(8):1771–1800, 2002.
181
+ [31] Jonathan Ho, Ajay Jain, and Pieter Abbeel. Denoising diffusion probabilistic models. arXiv:2006.11239, 2020.
182
+ [32] Alexia Jolicoeur-Martineau, Rémi Piché-Taillefer, Rémi Tachet des Combes, and Ioannis Mitliagkas. Adversarial score matching and improved sampling for image generation. arXiv:2009.05475, 2020.
183
+ [33] Tero Karras, Samuli Laine, and Timo Aila. A style-based generator architecture for generative adversarial networks. arXiv:arXiv:1812.04948, 2019.
184
+ [34] Tero Karras, Samuli Laine, Miika Aittala, Janne Hellsten, Jaakko Lehtinen, and Timo Aila. Analyzing and improving the image quality of stylegan. arXiv:1912.04958, 2019.
185
+ [35] Diederik P. Kingma and Jimmy Ba. Adam: A method for stochastic optimization. arXiv:1412.6980, 2014.
186
+ [36] Zhifeng Kong, Wei Ping, Jiaji Huang, Kexin Zhao, and Bryan Catanzaro. Diffwave: A versatile diffusion model for audio synthesis. arXiv:2009.09761, 2020.
187
+ [37] Alex Krizhevsky, Vinod Nair, and Geoffrey Hinton. CIFAR-10 (Canadian Institute for Advanced Research), 2009. URL http://www.cs.toronto.edu/\~kriz/cifar.html.
188
+ [38] Tuomas Kynkäänniemi, Tero Karras, Samuli Laine, Jaakko Lehtinen, and Timo Aila. Improved precision and recall metric for assessing generative models. arXiv:1904.06991, 2019.
189
+ [39] Guosheng Lin, Anton Milan, Chunhua Shen, and Ian Reid. Refinenet: Multi-path refinement networks for high-resolution semantic segmentation. arXiv:1611.06612, 2016.
190
+ [40] Ziwei Liu, Ping Luo, Xiaogang Wang, and Xiaoou Tang. Deep learning face attributes in the wild. In Proceedings of International Conference on Computer Vision (ICCV), December 2015.
191
+ [41] Ilya Loshchilov and Frank Hutter. Decoupled weight decay regularization. arXiv:1711.05101, 2017.
192
+ [42] Mario Lucic, Michael Tschannen, Marvin Ritter, Xiaohua Zhai, Olivier Bachem, and Sylvain Gelly. High-fidelity image generation with fewer labels. arXiv:1903.02271, 2019.
193
+ [43] Eric Luhman and Troy Luhman. Knowledge distillation in iterative generative models for improved sampling speed. arXiv:2101.02388, 2021.
194
+ [44] Paulius Micikevicius, Sharan Narang, Jonah Alben, Gregory Diamos, Erich Elsen, David Garcia, Boris Ginsburg, Michael Houston, Oleksii Kuchaiev, Ganesh Venkatesh, and Hao Wu. Mixed precision training. arXiv:1710.03740, 2017.
195
+ [45] Mehdi Mirza and Simon Osindero. Conditional generative adversarial nets. arXiv:1411.1784, 2014.
196
+ [46] Takeru Miyato and Masanori Koyama. cgans with projection discriminator. arXiv:1802.05637, 2018.
197
+ [47] Takeru Miyato, Toshiki Kataoka, Masanori Koyama, and Yuichi Yoshida. Spectral normalization for generative adversarial networks. arXiv:1802.05957, 2018.
198
+ [48] Charlie Nash, Jacob Menick, Sander Dieleman, and Peter W. Battaglia. Generating images with sparse representations. arXiv:2103.03841, 2021.
199
+ [49] Alex Nichol and Prafulla Dhariwal. Improved denoising diffusion probabilistic models. arXiv:2102.09672, 2021.
200
+ [50] NVIDIA. Stylegan2. https://github.com/NVlabs/stylegan2, 2019.
201
+ [51] Gaurav Parmar, Richard Zhang, and Jun-Yan Zhu. On buggy resizing libraries and surprising subtleties in fid calculation. arXiv:2104.11222, 2021.
202
+ [52] Adam Paszke, Sam Gross, Francisco Massa, Adam Lerer, James Bradbury, Gregory Chanan, Trevor Killeen, Zeming Lin, Natalia Gimelshein, Luca Antiga, et al. Pytorch: An imperative style, high-performance deep learning library. arXiv:1912.01703, 2019.
203
+ [53] Or Patashnik, Zongze Wu, Eli Shechtman, Daniel Cohen-Or, and Dani Lischinski. Styleclip: Text-driven manipulation of stylegan imagery. arXiv:2103.17249, 2021.
204
+ [54] Ethan Perez, Florian Strub, Harm de Vries, Vincent Dumoulin, and Aaron Courville. Film: Visual reasoning with a general conditioning layer. arXiv:1709.07871, 2017.
205
+ [55] Alec Radford, Jong Wook Kim, Chris Hallacy, Aditya Ramesh, Gabriel Goh, Sandhini Agarwal, Girish Sastry, Amanda Askell, Pamela Mishkin, Jack Clark, Gretchen Krueger, and Ilya Sutskever. Learning transferable visual models from natural language supervision. arXiv:2103.00020, 2021.
206
+ [56] Aditya Ramesh, Mikhail Pavlov, Gabriel Goh, Scott Gray, Chelsea Voss, Alec Radford, Mark Chen, and Ilya Sutskever. Zero-shot text-to-image generation. arXiv:2102.12092, 2021.
207
+ [57] Ali Razavi, Aaron van den Oord, and Oriol Vinyals. Generating diverse high-fidelity images with VQ-VAE-2. arXiv:1906.00446, 2019.
208
+ [58] Olaf Ronneberger, Philipp Fischer, and Thomas Brox. U-net: Convolutional networks for biomedical image segmentation. arXiv:1505.04597, 2015.
209
+ [59] Olga Russakovsky, Jia Deng, Hao Su, Jonathan Krause, Sanjeev Satheesh, Sean Ma, Zhiheng Huang, Andrej Karpathy, Aditya Khosla, Michael Bernstein, Alexander C. Berg, and Li Fei-Fei. Imagenet large scale visual recognition challenge. arXiv:1409.0575, 2014.
210
+ [60] Chitwan Saharia, Jonathan Ho, William Chan, Tim Salimans, David J. Fleet, and Mohammad Norouzi. Image super-resolution via iterative refinement. arXiv:arXiv:2104.07636, 2021.
211
+ [61] Tim Salimans, Ian Goodfellow, Wojciech Zaremba, Vicki Cheung, Alec Radford, and Xi Chen. Improved techniques for training gans. arXiv:1606.03498, 2016.
212
+ [62] Shibani Santurkar, Dimitris Tsipras, Brandon Tran, Andrew Ilyas, Logan Engstrom, and Aleksander Madry. Image synthesis with a single (robust) classifier. arXiv:1906.09453, 2019.
213
+ [63] Jascha Sohl-Dickstein, Eric A. Weiss, Niru Maheswaranathan, and Surya Ganguli. Deep unsupervised learning using nonequilibrium thermodynamics. arXiv:1503.03585, 2015.
214
+ [64] Jiaming Song, Chenlin Meng, and Stefano Ermon. Denoising diffusion implicit models. arXiv:2010.02502, 2020.
215
+ [65] Yang Song and Stefano Ermon. Improved techniques for training score-based generative models. arXiv:2006.09011, 2020.
216
+ [66] Yang Song and Stefano Ermon. Generative modeling by estimating gradients of the data distribution. arXiv:arXiv:1907.05600, 2020.
217
+ [67] Yang Song, Jascha Sohl-Dickstein, Diederik P. Kingma, Abhishek Kumar, Stefano Ermon, and Ben Poole. Score-based generative modeling through stochastic differential equations. arXiv:2011.13456, 2020.
218
+ [68] Christian Szegedy, Vincent Vanhoucke, Sergey Ioffe, Jonathon Shlens, and Zbigniew Wojna. Rethinking the inception architecture for computer vision. arXiv:1512.00567, 2015.
219
+ [69] Arash Vahdat and Jan Kautz. Nvae: A deep hierarchical variational autoencoder. arXiv:2007.03898, 2020.
220
+ [70] Aaron van den Oord, Sander Dieleman, Heiga Zen, Karen Simonyan, Oriol Vinyals, Alex Graves, Nal Kalchbrenner, Andrew Senior, and Koray Kavukcuoglu. Wavenet: A generative model for raw audio. arXiv:1609.03499, 2016.
221
+ [71] Aaron van den Oord, Oriol Vinyals, and Koray Kavukcuoglu. Neural discrete representation learning. arXiv:1711.00937, 2017.
222
+ [72] Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N. Gomez, Lukasz Kaiser, and Illia Polosukhin. Attention is all you need. arXiv:1706.03762, 2017.
223
+ [73] Max Welling and Yee W Teh. Bayesian learning via stochastic gradient langevin dynamics. In Proceedings of the 28th international conference on machine learning (ICML-11), pages 681–688. Citeseer, 2011.
224
+ [74] Yan Wu, Jeff Donahue, David Balduzzi, Karen Simonyan, and Timothy Lillicrap. Logan: Latent optimisation for generative adversarial networks. arXiv:1912.00953, 2019.
225
+ [75] Yuxin Wu and Kaiming He. Group normalization. arXiv:1803.08494, 2018.
226
+ [76] Jianwen Xie, Yang Lu, Song-Chun Zhu, and Ying Nian Wu. A theory of generative convnet. arXiv:1602.03264, 2016.
227
+
228
+ [77] Fisher Yu, Ari Seff, Yinda Zhang, Shuran Song, Thomas Funkhouser, and Jianxiong Xiao. Lsun: Construction of a large-scale image dataset using deep learning with humans in the loop. arXiv:1506.03365, 2015.
229
+
230
+ [78] Han Zhang, Tao Xu, Hongsheng Li, Shaoting Zhang, Xiaogang Wang, Xiaolei Huang, and Dimitris Metaxas. Stackgan: Text to photo-realistic image synthesis with stacked generative adversarial networks. arXiv:1612.03242, 2016.
231
+
232
+ # Checklist
233
+
234
+ • Did you include the license to the code and datasets? [No] We were unable to find the official license for either ImageNet or LSUN. We do include a license for our released source code.
235
+
236
+ 1. For all authors...
237
+
238
+ (a) Do the main claims made in the abstract and introduction accurately reflect the paper’s contributions and scope? [Yes]
239
+ (b) Did you describe the limitations of your work? [Yes] See Section 7.
240
+ (c) Did you discuss any potential negative societal impacts of your work? [Yes] See Section 8.
241
+ (d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
242
+
243
+ 2. If you are including theoretical results...
244
+
245
+ (a) Did you state the full set of assumptions of all theoretical results? [Yes] See Appendix D.
246
+ (b) Did you include complete proofs of all theoretical results? [Yes] We provide detailed derivations in Appendix D.
247
+
248
+ 3. If you ran experiments...
249
+
250
+ (a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes] We include the source code and instructions for running it.
251
+ (b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] See Appendix K.
252
+ (c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [No] Each experiment requires several hundred GPU days to run, so it is quite costly to compute error bars.
253
+ (d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] See Appendix B.
254
+
255
+ 4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
256
+
257
+ (a) If your work uses existing assets, did you cite the creators? [Yes] Our codebase references the codebase it is forked from [49, 31]. We also cite PyTorch [52], which we use throughout our experiments.
258
+ (b) Did you mention the license of the assets? [Yes] A license file is included with the code release.
259
+ (c) Did you include any new assets either in the supplemental material or as a URL? [Yes] The code is included in the supplemental material.
260
+ (d) Did you discuss whether and how consent was obtained from people whose data you’re using/curating? [N/A]
261
+ (e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A]
262
+
263
+ 5. If you used crowdsourcing or conducted research with human subjects...
264
+
265
+ (a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
266
+ (b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
267
+ (c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
parse/train/AAWuCvzaVt/AAWuCvzaVt_content_list.json ADDED
@@ -0,0 +1,1022 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [
2
+ {
3
+ "type": "text",
4
+ "text": "Diffusion Models Beat GANs on Image Synthesis ",
5
+ "text_level": 1,
6
+ "bbox": [
7
+ 202,
8
+ 122,
9
+ 795,
10
+ 147
11
+ ],
12
+ "page_idx": 0
13
+ },
14
+ {
15
+ "type": "text",
16
+ "text": "Prafulla Dhariwal⇤ OpenAI prafulla@openai.com ",
17
+ "bbox": [
18
+ 287,
19
+ 200,
20
+ 455,
21
+ 243
22
+ ],
23
+ "page_idx": 0
24
+ },
25
+ {
26
+ "type": "text",
27
+ "text": "Alex Nichol⇤ \nOpenAI \nalex@openai.com ",
28
+ "bbox": [
29
+ 576,
30
+ 200,
31
+ 709,
32
+ 243
33
+ ],
34
+ "page_idx": 0
35
+ },
36
+ {
37
+ "type": "text",
38
+ "text": "Abstract ",
39
+ "text_level": 1,
40
+ "bbox": [
41
+ 462,
42
+ 279,
43
+ 535,
44
+ 295
45
+ ],
46
+ "page_idx": 0
47
+ },
48
+ {
49
+ "type": "text",
50
+ "text": "We show that diffusion models can achieve image sample quality superior to the current state-of-the-art generative models. We achieve this on unconditional image synthesis by finding a better architecture through a series of ablations. For conditional image synthesis, we further improve sample quality with classifier guidance: a simple, compute-efficient method for trading off diversity for fidelity using gradients from a classifier. We achieve an FID of 2.97 on ImageNet $1 2 8 \\times 1 2 8$ , 4.59 on ImageNet $2 5 6 \\times 2 5 6$ , and 7.72 on ImageNet $5 1 2 \\times 5 1 2$ , and we match BigGAN-deep even with as few as 25 forward passes per sample, all while maintaining better coverage of the distribution. Finally, we find that classifier guidance combines well with upsampling diffusion models, further improving FID to 3.94 on ImageNet $2 5 6 \\times 2 5 6$ and 3.85 on ImageNet $5 1 2 \\times 5 1 2$ . ",
51
+ "bbox": [
52
+ 232,
53
+ 310,
54
+ 766,
55
+ 463
56
+ ],
57
+ "page_idx": 0
58
+ },
59
+ {
60
+ "type": "text",
61
+ "text": "1 Introduction ",
62
+ "text_level": 1,
63
+ "bbox": [
64
+ 174,
65
+ 489,
66
+ 312,
67
+ 507
68
+ ],
69
+ "page_idx": 0
70
+ },
71
+ {
72
+ "type": "image",
73
+ "img_path": "images/88360c3236154304146ad2cec322e05f63a49acb48c6c1b23c464f964e2fe1f0.jpg",
74
+ "image_caption": [
75
+ "Figure 1: Selected samples from our best ImageNet $5 1 2 \\times 5 1 2$ model (FID 3.85) "
76
+ ],
77
+ "image_footnote": [],
78
+ "bbox": [
79
+ 174,
80
+ 527,
81
+ 823,
82
+ 779
83
+ ],
84
+ "page_idx": 0
85
+ },
86
+ {
87
+ "type": "text",
88
+ "text": "Over the past few years, generative models have gained the ability to generate human-like natural language $\\mathbf { \\partial } [ \\mathbf { \\overline { { 9 } } } ]$ , high-quality synthetic images [8, 34, 57] and highly diverse human speech and music [70, 17]. These models can be used in a variety of ways, such as generating images from text prompts [78, 56] or learning useful feature representations [18, 10]. While these models are already capable of producing realistic images and sound, there is still much room for improvement beyond the current state-of-the-art, and better generative models could have wide-ranging impacts on graphic design, games, music production, and countless other fields. ",
89
+ "bbox": [
90
+ 174,
91
+ 819,
92
+ 825,
93
+ 876
94
+ ],
95
+ "page_idx": 0
96
+ },
97
+ {
98
+ "type": "text",
99
+ "text": "",
100
+ "bbox": [
101
+ 174,
102
+ 90,
103
+ 825,
104
+ 132
105
+ ],
106
+ "page_idx": 1
107
+ },
108
+ {
109
+ "type": "text",
110
+ "text": "GANs $\\lVert 2 5 \\rVert$ currently hold the state-of-the-art on most image generation tasks $\\textcircled { 1 8 } \\textcircled { 7 4 } \\textcircled { 3 4 } \\textcircled { 1 }$ as measured by sample quality metrics such as FID $\\left[ \\left[ 2 9 \\right] \\right]$ , Inception Score $\\pmb { \\mathbb { \\left| 6 1 \\right| } }$ and Precision $\\textcircled { 1 3 8 } \\textcircled { 1 }$ . However, some of these metrics do not fully capture diversity, and it has been shown that GANs capture less diversity than state-of-the-art likelihood-based models [57, 49, 48]. Furthermore, GANs are often difficult to train, collapsing without carefully selected hyperparameters and regularizers $ { \\mathbb { R } } , { \\mathbb { G } } { \\mathbb { Z } } , { \\mathbb { Z } } { \\mathbb { I } }$ . While GANs hold the state-of-the-art, their drawbacks make them difficult to scale and apply to new domains. As a result, much work has been done to achieve GAN-like sample quality with likelihood-based models $\\pmb { \\bigtriangledown } 2 2 \\mathbf { l }$ 57, 31, 48, 12]. While these models capture more diversity and are typically easier to scale and train than GANs, they still fall short in terms of visual fidelity. Furthermore, except for VAEs, sampling from these models is slower than GANs in terms of wall-clock time. ",
111
+ "bbox": [
112
+ 173,
113
+ 138,
114
+ 825,
115
+ 279
116
+ ],
117
+ "page_idx": 1
118
+ },
119
+ {
120
+ "type": "text",
121
+ "text": "Diffusion models are a class of likelihood-based models which have recently been shown to produce high-quality images $\\pmb { \\mathbb { B } } 3 \\pmb { \\mathbb { B } } 6 2 \\pmb { \\mathbb { B } } \\pmb { \\mathbb { B } } \\pmb { \\mathbb { B } }$ while offering desirable properties such as distribution coverage, a stationary training objective, and easy scalability. These models generate samples by gradually removing noise from a signal, and their training objective can be expressed as a reweighted variational lower-bound $\\pmb { \\mathbb { B } } \\mathbf { \\mathbb { 1 } }$ . This class of models already holds the state-of-the-art $\\pmb { \\Vert 6 7 \\Vert }$ on CIFAR-10 [37], but still lags behind GANs on difficult generation datasets like LSUN and ImageNet. We hypothesize that this gap exists for at least two reasons: first, that the model architectures used by recent GAN literature have been heavily explored and refined; second, that GANs are able to trade off diversity for fidelity, producing high quality samples but not covering the whole distribution. We aim to bring these benefits to diffusion models, first by improving model architecture and then by devising a scheme for trading off diversity for fidelity. ",
122
+ "bbox": [
123
+ 173,
124
+ 284,
125
+ 825,
126
+ 436
127
+ ],
128
+ "page_idx": 1
129
+ },
130
+ {
131
+ "type": "text",
132
+ "text": "The rest of the paper is organized as follows. In Section $^ { 2 , }$ we give a brief background of diffusion models based on Ho et al. [31] and the improvements from Nichol and Dhariwal [49] and Song et al. $\\pmb { \\mathbb { \\lVert 6 4 \\rVert } }$ , and we describe our evaluation setup. In Section ${ \\overline { { 3 , } } }$ we introduce simple architecture improvements that give a substantial boost to FID. In Section $^ { 4 , }$ we describe a method for using gradients from a classifier to guide a diffusion model during sampling. Finally, in Section 5 we show that models with our improved architecture achieve state-of-the-art on unconditional image synthesis tasks, and with classifier guidance achieve state-of-the-art on conditional image synthesis. ",
133
+ "bbox": [
134
+ 173,
135
+ 443,
136
+ 825,
137
+ 540
138
+ ],
139
+ "page_idx": 1
140
+ },
141
+ {
142
+ "type": "text",
143
+ "text": "2 Background ",
144
+ "text_level": 1,
145
+ "bbox": [
146
+ 174,
147
+ 560,
148
+ 308,
149
+ 578
150
+ ],
151
+ "page_idx": 1
152
+ },
153
+ {
154
+ "type": "text",
155
+ "text": "In this section, we provide a brief overview of diffusion models. For a more detailed mathematical description, we refer the reader to Appendix $\\boxplus$ On a high level, diffusion models sample from a distribution by reversing a gradual noising process. In particular, sampling starts with noise $x _ { T }$ and produces gradually less-noisy samples $x _ { T - 1 } , x _ { T - 2 } , . . .$ until reaching a final sample $x _ { 0 }$ . In particular, a diffusion model learns to produce a slightly more “denoised” $x _ { t - 1 }$ from $x _ { t }$ . $\\mathbb { H o } \\operatorname { e t } { \\mathrm { a l } } .$ $\\bar { \\big \\| } 3 1 \\big \\|$ parameterize this model using a function $\\epsilon _ { \\theta } ( x _ { t } , t )$ which predicts the noise component of a noisy sample $x _ { t }$ . To train this function, each sample in a minibatch is produced by randomly drawing a data sample $x _ { 0 }$ , a timestep $t$ , and noise $\\epsilon$ , which together give rise to a noised sample $x _ { t }$ (Equation 3, Appendix $\\mathrm { ^ C } )$ . The training objective is then $| | \\epsilon _ { \\theta } ( x _ { t } , t ) - \\mathbf { \\bar { \\epsilon } } \\epsilon | | ^ { 2 }$ , i.e. a simple mean-squared error loss between the true noise and the predicted noise (Equation 12, Appendix $\\bigtriangledown$ . ",
156
+ "bbox": [
157
+ 173,
158
+ 593,
159
+ 826,
160
+ 733
161
+ ],
162
+ "page_idx": 1
163
+ },
164
+ {
165
+ "type": "text",
166
+ "text": "Ho et al. [31] show that, under reasonable assumptions, we can then model the denoising distribution $\\overline { { p _ { \\theta } ( x _ { t - 1 } | } } x _ { t } )$ of $x _ { t - 1 }$ given $x _ { t }$ as a diagonal Gaussian $\\mathcal { N } ( x _ { t - 1 } ; \\mu _ { \\theta } ( x _ { t } , t ) , \\Sigma _ { \\theta } ( x _ { t } , t ) )$ , where the mean $\\mu _ { \\theta } ( x _ { t } , t )$ can be calculated as a function of $\\epsilon _ { \\theta } ( x _ { t } , t )$ (Equation $^ { 1 3 , }$ Appendix $\\underset { . } { \\mathbf { C } } )$ Ho et al. [31] observe that the simple mean-squared error objective, $L _ { \\mathrm { s i m p l e } }$ , works better in practice than the actual variational lower bound $L _ { \\mathrm { v l b } }$ that can be derived from interpreting the denoising diffusion model as a VAE. They also note that training with this objective and using their corresponding sampling procedure is equivalent to the denoising score matching model from $\\boxed { \\mathrm { S o n g ~ a n d ~ E r m o n } } \\boxed { \\overline { { 6 5 } } }$ , who use Langevin dynamics to sample from a denoising model trained with multiple noise levels to produce high quality image samples. We often use “diffusion models” as shorthand to refer to both classes of models. ",
167
+ "bbox": [
168
+ 173,
169
+ 738,
170
+ 825,
171
+ 876
172
+ ],
173
+ "page_idx": 1
174
+ },
175
+ {
176
+ "type": "text",
177
+ "text": "Following the breakthrough work of Song and Ermon [65] and Ho et al. [31], several recent papers have proposed improvements to diffusion models. Nichol and Dhariwal [49] find that fixing the variance $\\Sigma _ { \\theta } ( x _ { t } , t )$ to a constant as done in Ho et al. $\\pmb { \\mathbb { B } } \\mathbf { \\mathbb { 1 } }$ is sub-optimal for sampling with fewer diffusion steps, and propose to parameterize $\\overline { { \\Sigma _ { \\theta } ( x _ { t } , t ) } }$ as a neural network whose output $v$ is interpolated as $\\Sigma _ { \\theta } ( x _ { t } , t ) = \\exp ( v \\log \\beta _ { t } + ( 1 - v ) \\log \\tilde { \\beta } _ { t } )$ . Here, $\\beta _ { t }$ and $\\tilde { \\beta } _ { t }$ (Equation ${ \\mathfrak { s } } ,$ Appendix $\\mathbf { C } )$ are the variances in Ho et al. $\\pmb { \\mathbb { B } } \\pmb { \\mathbb { 1 } }$ corresponding to upper and lower bounds for the reverse process variances. Additionally, Nichol and Dhariwal $\\textcircled { \\lVert { 4 9 } \\rVert }$ propose a hybrid objective for training both $\\epsilon _ { \\theta } ( x _ { t } , t )$ and $\\Sigma _ { \\theta } ( x _ { t } , t )$ using the weighted sum $\\overline { { L } } _ { \\mathrm { s i m p l e } } + \\lambda L _ { \\mathrm { v l b } }$ . Learning the reverse process variances with their hybrid objective allows sampling with fewer steps without much drop in sample quality. We adopt this objective and parameterization, and use it throughout our experiments. ",
178
+ "bbox": [
179
+ 174,
180
+ 882,
181
+ 821,
182
+ 912
183
+ ],
184
+ "page_idx": 1
185
+ },
186
+ {
187
+ "type": "text",
188
+ "text": "",
189
+ "bbox": [
190
+ 173,
191
+ 89,
192
+ 825,
193
+ 205
194
+ ],
195
+ "page_idx": 2
196
+ },
197
+ {
198
+ "type": "text",
199
+ "text": "Song et al. [64] propose DDIM, which formulates an alternative non-Markovian noising process that has the same forward marginals as DDPM, but allows producing different reverse samplers by changing the variance of the reverse noise. By setting this noise to 0, they provide a way to turn any model $\\epsilon _ { \\theta } ( x _ { t } , t )$ into a deterministic mapping from latents to images, and find that this provides an alternative way to sample with fewer steps. We adopt this sampling approach when using fewer than 50 sampling steps, since Nichol and Dhariwal [49] found it to be beneficial in this regime. ",
200
+ "bbox": [
201
+ 174,
202
+ 210,
203
+ 825,
204
+ 295
205
+ ],
206
+ "page_idx": 2
207
+ },
208
+ {
209
+ "type": "text",
210
+ "text": "Sample Quality Metrics: For comparing sample quality across models, we perform quantitative evaluations using the following metrics. While these metrics are often used in practice and correspond well with human judgement, they are not a perfect proxy, and finding better metrics for sample quality evaluation is still an open problem. ",
211
+ "bbox": [
212
+ 173,
213
+ 300,
214
+ 825,
215
+ 356
216
+ ],
217
+ "page_idx": 2
218
+ },
219
+ {
220
+ "type": "text",
221
+ "text": "We use FID $\\pmb { \\mathbb { Z } } 9 \\|$ as our default metric for overall sample quality comparisons as it captures both fidelity and diversity and has been the de facto standard metric for state-of-the-art generative models [33, 34, 8, 31]. We use Precision and Recall $[ [ 3 8 ] ]$ as proxies for separately measuring fidelity and diversity, respectively. We include sFID $\\lVert \\overline { { 4 8 } } \\rVert$ as a metric that better captures spatial relationships than FID, and also include Inception Score (IS) $\\pmb { \\mathbb { \\left[ 6 1 \\right] } }$ as another proxy for fidelity. When comparing against other methods, we re-compute these metrics using public samples or models whenever possible. This is for two reasons: first, some papers [33, 34, 31] compare against arbitrary subsets of the training set which are not readily available; and second, subtle implementation differences can affect the resulting FID values $\\pmb { \\mathbb { B } } \\mathbf { \\mathbb { 1 } }$ . For consistent comparisons, we use the full training set as the reference batch [29, $\\textcircled { 8 } ]$ , and evaluate metrics for all models using the same codebase. ",
222
+ "bbox": [
223
+ 173,
224
+ 362,
225
+ 825,
226
+ 501
227
+ ],
228
+ "page_idx": 2
229
+ },
230
+ {
231
+ "type": "text",
232
+ "text": "3 Architecture Improvements ",
233
+ "text_level": 1,
234
+ "bbox": [
235
+ 174,
236
+ 518,
237
+ 437,
238
+ 536
239
+ ],
240
+ "page_idx": 2
241
+ },
242
+ {
243
+ "type": "text",
244
+ "text": "Ho et al. [31] adopted the UNet architecture $\\pmb { \\Vert 5 8 \\Vert }$ for diffusion models, which Jolicoeur-Martineau et al. [32] found to substantially improve sample quality over the previous architectures [65, 39] used for denoising score matching. The UNet model uses a stack of residual layers and downsampling convolutions, followed by a stack of residual layers with upsampling convolutions, with skip connections connecting the layers with the same spatial size. In addition, they use a global attention layer at the $1 6 \\times 1 6$ resolution with a single head, and add a projection of the timestep embedding into each residual block. $\\boxed { \\mathrm { S o n g ~ e t ~ a l . } \\parallel \\boxed { 6 7 } }$ found that further changes to the UNet architecture improved performance on the CIFAR-10 [37] and CelebA-64 [40] datasets. We show the same result on ImageNet $1 2 8 \\times 1 2 8$ , finding that architecture can indeed give a substantial boost to sample quality on a much larger and more diverse datasets at a higher resolution. ",
245
+ "bbox": [
246
+ 173,
247
+ 547,
248
+ 825,
249
+ 688
250
+ ],
251
+ "page_idx": 2
252
+ },
253
+ {
254
+ "type": "text",
255
+ "text": "We explore the following architectural changes: increasing depth versus width, holding model size relatively constant; increasing the number of attention heads; using attention at $3 2 \\times 3 2$ , $1 6 \\times 1 6$ , and $8 \\times 8$ resolutions rather than only at $1 6 \\times 1 6$ ; using the BigGAN $\\pmb { \\Vert 8 \\Vert }$ residual block for upsampling and downsampling the activations, following $ { \\mathbb { I } } { \\mathbb { I } }$ ; and finally; rescaling residual connections with $\\scriptstyle { \\frac { 1 } { \\sqrt { 2 } } }$ , following [67, 33, 34]. ",
256
+ "bbox": [
257
+ 174,
258
+ 694,
259
+ 825,
260
+ 767
261
+ ],
262
+ "page_idx": 2
263
+ },
264
+ {
265
+ "type": "text",
266
+ "text": "We train models with the above architecture changes on ImageNet $1 2 8 \\times 1 2 8$ and compare them on FID, evaluated at two different points of training, in Table $\\nsupseteq$ Aside from rescaling residual connections, all of the other modifications improve performance and have a positive compounding effect. On wall-clock (Figure $5 ,$ Appendix $\\bar { \\bigstar . 1 \\bigstar }$ we find that increased depth hurts training time most, so we opt not to use this change in further experiments. We also study other attention configurations that better match the Transformer architecture $\\lVert \\ b { 7 2 } \\rVert$ . We try two configurations: constant attention heads, or constant channels per head. Table $\\bigstar$ shows our results, indicating that more heads or fewer channels per head improves FID. On wall-clock (Figure $\\boxed { 5 }$ Appendix $\\mathbf { A . l } )$ , we see that 64 channels is best so we opt to use 64 channels per head as our default. We note that this choice also better matches modern transformer architectures, and is on par with our other configurations in terms of final FID. ",
267
+ "bbox": [
268
+ 173,
269
+ 772,
270
+ 825,
271
+ 911
272
+ ],
273
+ "page_idx": 2
274
+ },
275
+ {
276
+ "type": "table",
277
+ "img_path": "images/ea871b934771676e9ea41668de1762b06bc8f98e20e41089cdd1c8919705bc6a.jpg",
278
+ "table_caption": [
279
+ "Table 1: Ablation of various architecture changes, evaluated at 700K and 1200K iterations "
280
+ ],
281
+ "table_footnote": [],
282
+ "table_body": "<table><tr><td>Channels</td><td>Depth</td><td>Heads</td><td>Attention resolutions</td><td>BigGAN up/downsample</td><td>Rescale resblock</td><td>FID 700K</td><td>FID 1200K</td></tr><tr><td>160</td><td>2</td><td>1</td><td>16</td><td>X</td><td>X</td><td>15.33</td><td>13.21</td></tr><tr><td>128</td><td>4</td><td></td><td></td><td></td><td></td><td>-0.21</td><td>-0.48</td></tr><tr><td></td><td></td><td>4</td><td></td><td></td><td></td><td>-0.54</td><td>-0.82</td></tr><tr><td></td><td></td><td></td><td>32,16,8</td><td></td><td></td><td>-0.72</td><td>-0.66</td></tr><tr><td></td><td></td><td></td><td></td><td>√</td><td></td><td>-1.20</td><td>-1.21</td></tr><tr><td></td><td></td><td></td><td></td><td></td><td></td><td>0.16</td><td>0.25</td></tr><tr><td>160</td><td>2</td><td>4</td><td>32,16,8</td><td>√</td><td>×</td><td>-3.14</td><td>-3.00</td></tr></table>",
283
+ "bbox": [
284
+ 215,
285
+ 117,
286
+ 782,
287
+ 257
288
+ ],
289
+ "page_idx": 3
290
+ },
291
+ {
292
+ "type": "table",
293
+ "img_path": "images/a1e65038291f832a19e5c0ef781639de95383e6632b61e3d322e5d067b13d596.jpg",
294
+ "table_caption": [
295
+ "Table 2: Ablation of attention heads. More heads or lower channels per heads both improve FID. The base model was a smaller version of the best model from Table 1. "
296
+ ],
297
+ "table_footnote": [],
298
+ "table_body": "<table><tr><td>Number of heads</td><td>Channels per head</td><td>FID</td></tr><tr><td>1</td><td></td><td>14.08</td></tr><tr><td>2</td><td></td><td>-0.50</td></tr><tr><td>4</td><td></td><td>-0.97</td></tr><tr><td>8</td><td></td><td>-1.17</td></tr><tr><td></td><td>32</td><td>-1.36</td></tr><tr><td></td><td>64</td><td>-1.03</td></tr><tr><td></td><td>128</td><td>-1.08</td></tr></table>",
299
+ "bbox": [
300
+ 346,
301
+ 301,
302
+ 650,
303
+ 429
304
+ ],
305
+ "page_idx": 3
306
+ },
307
+ {
308
+ "type": "text",
309
+ "text": "We also experiment with a layer $\\boxed { \\boxplus 9 }$ that we refer to as adaptive group normalization (AdaGN), which incorporates the timestep and class embedding into each residual block after a group normalization operation $\\mathbb { [ [ \\mathsf { Z } \\mathsf { S } ] ] }$ , similar to adaptive instance norm $\\pmb { \\Vert 3 3 \\Vert }$ and FiLM [54]. We define this layer as $\\mathrm { A d a G N } ( h , y ) = y _ { s }$ $\\mathrm { G r o u p N o r m } ( h ) + y _ { b }$ , where $h$ is the intermediate activations of the residual block following the first convolution, and $y = [ y _ { s } , y _ { b } ]$ is obtained from a linear projection of the timestep and class embedding. We had already seen AdaGN improve our earliest diffusion models, and so had included it by default in all our runs. We explicitly ablate this choice (Table $6 ,$ , Appendix $\\underline { { \\vert \\overline { { \\mathbf { A . } } } \\mathbf { l } \\mathbf { \\rangle } } }$ , and find that FID becomes worse by 2.02 when we remove the adaptive group normalization layer. ",
310
+ "bbox": [
311
+ 173,
312
+ 443,
313
+ 825,
314
+ 555
315
+ ],
316
+ "page_idx": 3
317
+ },
318
+ {
319
+ "type": "text",
320
+ "text": "In the rest of the paper, we use this final improved model architecture as our default: variable width with 2 residual blocks per resolution, multiple heads with 64 channels per head, attention at 32, 16 and 8 resolutions, BigGAN residual blocks for up and downsampling, and adaptive group normalization for injecting timestep and class embeddings into residual blocks. ",
321
+ "bbox": [
322
+ 174,
323
+ 560,
324
+ 825,
325
+ 617
326
+ ],
327
+ "page_idx": 3
328
+ },
329
+ {
330
+ "type": "text",
331
+ "text": "4 Classifier Guidance ",
332
+ "text_level": 1,
333
+ "bbox": [
334
+ 176,
335
+ 637,
336
+ 369,
337
+ 655
338
+ ],
339
+ "page_idx": 3
340
+ },
341
+ {
342
+ "type": "text",
343
+ "text": "In addition to employing well designed architectures, GANs for conditional image synthesis [45, 8] make heavy use of class labels. This often takes the form of class-conditional normalization statistics $\\mathbb { \\ Z O } \\mathbb { \\perp } \\mathbb { \\perp } \\mathbb { I }$ as well as discriminators with heads explicitly designed to behave like classifiers $p ( y | x )$ [46]. As further evidence that class information is crucial to the success of these models, Lucic et al. [42] find that it is helpful to generate synthetic labels when working in a label-limited regime. Given this observation for GANs, it makes sense to explore different ways to condition diffusion models on class labels. We already incorporate class information into adaptive group normalization layers (Section $3 )$ . Here, we explore a different approach: exploiting a classifier $p ( y | x )$ to improve a diffusion generator. Sohl-Dickstein et al. $\\mathbb { \\left[ 6 3 \\right] }$ and $\\widetilde { \\mathbb { S } \\mathrm { o n g } \\ e t \\ a l . } \\Vert \\widehat { \\mathbb { b } \\mathrm { 7 } } \\Vert$ show one way to achieve this, wherein a pre-trained diffusion model can be conditioned using the gradients of a classifier. In particular, we can train a classifier $p _ { \\phi } ( y | x _ { t } , t )$ on noisy images $x _ { t }$ , and then use gradients $\\nabla _ { x _ { t } } \\log \\overset { \\cdot } { p _ { \\phi } } ( y | x _ { t } , t )$ to guide the diffusion sampling process towards an arbitrary class label $y$ . ",
344
+ "bbox": [
345
+ 173,
346
+ 669,
347
+ 826,
348
+ 835
349
+ ],
350
+ "page_idx": 3
351
+ },
352
+ {
353
+ "type": "text",
354
+ "text": "For class conditional diffusion sampling, we reproduce the derivation from Sohl-Dickstein et al. [63] in Appendix $\\mathbb { D . 2 }$ For DDIM, we perform a score-based derivation in Appendix $\\overline { { \\mathbf { D } . 3 } }$ inspired by Song et al. $[ \\overbrace { 6 7 } ]$ . The resulting sampling algorithms we use for guidance are Algorithms $\\mathbf { \\overline { { \\Pi } } }$ and $\\dot { 2 }$ respectively. Both algorithms incorporate class information by adding the gradients of a classifier to each sampling step with an appropriate step size. In these algorithms, we choose the notation ",
355
+ "bbox": [
356
+ 173,
357
+ 842,
358
+ 825,
359
+ 911
360
+ ],
361
+ "page_idx": 3
362
+ },
363
+ {
364
+ "type": "text",
365
+ "text": "Algorithm 1 Classifier guided diffusion sampling, given a diffusion model $( \\mu _ { \\theta } ( x _ { t } ) , \\Sigma _ { \\theta } ( x _ { t } ) )$ , classifier $p _ { \\phi } ( y | x _ { t } )$ , and gradient scale $s$ . ",
366
+ "bbox": [
367
+ 169,
368
+ 90,
369
+ 826,
370
+ 121
371
+ ],
372
+ "page_idx": 4
373
+ },
374
+ {
375
+ "type": "text",
376
+ "text": "Input: class label $y$ , gradient scale $s$ \n$x _ { T } \\gets$ sample from $\\mathcal { N } ( 0 , \\bf { I } )$ \nfor all $t$ from $T$ to 1 do $\\mu , \\Sigma \\mu _ { \\theta } ( x _ { t } ) , \\Sigma _ { \\theta } ( x _ { t } )$ $x _ { t - 1 } \\gets$ sample from $\\overset { \\vartriangle } { \\mathcal { N } } ( \\mu + s \\Sigma \\nabla _ { x _ { t } } \\log p _ { \\phi } ( y | x _ { t } ) , \\Sigma )$ \nend for \nreturn $x _ { 0 }$ ",
377
+ "bbox": [
378
+ 184,
379
+ 126,
380
+ 560,
381
+ 224
382
+ ],
383
+ "page_idx": 4
384
+ },
385
+ {
386
+ "type": "text",
387
+ "text": "Algorithm 2 Classifier guided DDIM sampling, given a diffusion model $\\epsilon _ { \\theta } ( x _ { t } )$ , classifier $\\overline { { p _ { \\phi } ( y | x _ { t } ) } }$ and gradient scale $s$ . ",
388
+ "bbox": [
389
+ 174,
390
+ 243,
391
+ 821,
392
+ 272
393
+ ],
394
+ "page_idx": 4
395
+ },
396
+ {
397
+ "type": "text",
398
+ "text": "Input: class label $y$ , gradient scale $s$ \n$x _ { T } \\gets$ sample from $\\bar { \\mathcal { N } } ( 0 , \\mathbf { I } )$ \nfor all $t$ from $T$ to 1 do $\\begin{array} { r l } & { \\hat { \\epsilon } \\epsilon _ { \\theta } ( x _ { t } ) - \\sqrt { 1 - \\bar { \\alpha } _ { t } } \\nabla _ { x _ { t } } \\log p _ { \\phi } ( y \\vert x _ { t } ) } \\\\ & { x _ { t - 1 } \\sqrt { \\bar { \\alpha } _ { t - 1 } } ( \\frac { x _ { t } - \\sqrt { 1 - \\bar { \\alpha } _ { t } } \\hat { \\epsilon } } { \\sqrt { \\bar { \\alpha } _ { t } } } ) + \\sqrt { 1 - \\bar { \\alpha } _ { t - 1 } } \\hat { \\epsilon } } \\end{array}$ \nend for \nreturn $x _ { 0 }$ ",
399
+ "bbox": [
400
+ 181,
401
+ 276,
402
+ 511,
403
+ 386
404
+ ],
405
+ "page_idx": 4
406
+ },
407
+ {
408
+ "type": "image",
409
+ "img_path": "images/17ede98c7663465d7ae64d6b390139ee6801c95c8a9097d5ed812d3bb08e68d8.jpg",
410
+ "image_caption": [
411
+ "Figure 2: Samples from an unconditional diffusion model with classifier guidance to condition on the class \"Pembroke Welsh corgi\". Using classifier scale 1.0 (left; FID: 33.0) does not produce convincing samples in this class, whereas classifier scale 10.0 (right; FID: 12.0) produces much more class-consistent images. "
412
+ ],
413
+ "image_footnote": [],
414
+ "bbox": [
415
+ 178,
416
+ 401,
417
+ 820,
418
+ 522
419
+ ],
420
+ "page_idx": 4
421
+ },
422
+ {
423
+ "type": "text",
424
+ "text": "$p _ { \\phi } ( y | x _ { t } , t ) = p _ { \\phi } ( y | x _ { t } )$ and $\\epsilon _ { \\theta } ( x _ { t } , t ) = \\epsilon _ { \\theta } ( x _ { t } )$ for brevity, noting that they refer to separate functions for each timestep $t$ and at training time the models must be conditioned on the input $t$ . ",
425
+ "bbox": [
426
+ 174,
427
+ 599,
428
+ 821,
429
+ 628
430
+ ],
431
+ "page_idx": 4
432
+ },
433
+ {
434
+ "type": "text",
435
+ "text": "To apply classifier guidance to a large scale generative task, we train classification models on ImageNet. Our classifier architecture is simply the downsampling trunk of the UNet model with an attention pool $\\begin{array} { r l } { \\| \\boldsymbol { \\bar { 5 } } \\boldsymbol { \\bar { 5 } } \\| } & { { } } \\end{array}$ at the $8 \\mathrm { x } 8$ layer to produce the final output. We train these classifiers on the same noising distribution as the corresponding diffusion model, and also add random crops to reduce overfitting. ",
436
+ "bbox": [
437
+ 174,
438
+ 635,
439
+ 825,
440
+ 705
441
+ ],
442
+ "page_idx": 4
443
+ },
444
+ {
445
+ "type": "text",
446
+ "text": "In initial experiments with unconditional ImageNet models, we found it necessary to scale the classifier gradients by a constant factor larger than 1. When using a scale of 1, we observed that the classifier assigned reasonable probabilities (around $5 0 \\%$ ) to the desired classes for the final samples, but these samples did not match the intended classes upon visual inspection. Scaling up the classifier gradients remedied this problem, and the class probabilities from the classifier increased to nearly $100 \\%$ . Figure $2$ shows an example of this effect. To understand the effect of scaling classifier gradients, note that $\\begin{array} { r } { s \\cdot \\nabla _ { x } \\log p ( y | x ) \\stackrel { \\cdot } { = } \\nabla _ { x } \\log \\frac { 1 } { Z } p ( y | x ) ^ { s } } \\end{array}$ , where $Z$ is an arbitrary constant. As a result, the conditioning process is still theoretically grounded in a re-normalized classifier distribution proportional to $p ( y | x ) ^ { s }$ . When $s > 1$ , this distribution becomes sharper than $p ( y | x )$ , since larger values are amplified by the exponent. In other words, using a larger gradient scale focuses more on the modes of the classifier, which is potentially desirable for producing higher quality (but less diverse) samples. ",
447
+ "bbox": [
448
+ 174,
449
+ 710,
450
+ 825,
451
+ 876
452
+ ],
453
+ "page_idx": 4
454
+ },
455
+ {
456
+ "type": "text",
457
+ "text": "In the above derivations, we assumed that the underlying diffusion model was unconditional, modeling $p ( x )$ . It is also possible to train conditional diffusion models, $p ( x | y )$ , and use classifier guidance in the exact same way. Table $3$ shows that the sample quality of both unconditional and conditional models can be greatly improved by classifier guidance. We see that, with a high enough scale, the guided unconditional model can get quite close to the FID of an unguided conditional model, although training directly with the class labels still helps. Guiding a conditional model further improves FID. ",
458
+ "bbox": [
459
+ 173,
460
+ 883,
461
+ 821,
462
+ 911
463
+ ],
464
+ "page_idx": 4
465
+ },
466
+ {
467
+ "type": "image",
468
+ "img_path": "images/b972c296c95e38207891fcbe7c43985a22a9400506330b2ed868ce523a2947d5.jpg",
469
+ "image_caption": [
470
+ "Figure 3: Change in sample quality as we vary scale of the classifier gradients for a class-conditional ImageNet $1 2 8 \\times 1 2 8$ model. "
471
+ ],
472
+ "image_footnote": [],
473
+ "bbox": [
474
+ 202,
475
+ 131,
476
+ 794,
477
+ 368
478
+ ],
479
+ "page_idx": 5
480
+ },
481
+ {
482
+ "type": "text",
483
+ "text": "",
484
+ "bbox": [
485
+ 174,
486
+ 421,
487
+ 825,
488
+ 477
489
+ ],
490
+ "page_idx": 5
491
+ },
492
+ {
493
+ "type": "text",
494
+ "text": "Table $3$ also shows that classifier guidance improves precision at the cost of recall, thus introducing a trade-off in sample fidelity versus diversity. We explicitly evaluate how this trade-off varies with the gradient scale in Figure $\\textcircled { 3 }$ We see that scaling the gradients beyond 1.0 smoothly trades off recall (a measure of diversity) for higher precision and IS (measures of fidelity). Since FID and sFID depend on both diversity and fidelity, their best values are obtained at an intermediate point. We also compare our guidance with the truncation trick from BigGAN (Figure $6 ,$ Appendix A.2). We find that classifier guidance is strictly better than BigGAN-deep when trading off FID for Inception Score. Less clear cut is the precision/recall trade-off, which shows that classifier guidance is only a better choice up until a certain precision threshold, after which point it cannot achieve better precision. ",
495
+ "bbox": [
496
+ 174,
497
+ 483,
498
+ 825,
499
+ 608
500
+ ],
501
+ "page_idx": 5
502
+ },
503
+ {
504
+ "type": "text",
505
+ "text": "5 Results ",
506
+ "text_level": 1,
507
+ "bbox": [
508
+ 174,
509
+ 630,
510
+ 266,
511
+ 646
512
+ ],
513
+ "page_idx": 5
514
+ },
515
+ {
516
+ "type": "text",
517
+ "text": "To evaluate our improved model architecture on unconditional image generation, we train separate diffusion models on three LSUN $\\mathbb { \\ m }$ classes: bedroom, horse, and cat. To evaluate classifier guidance, we train conditional diffusion models on the ImageNet $\\mathbb { \\left[ 5 9 \\right] }$ dataset at $1 2 8 \\times 1 2 8$ , $2 5 6 \\times 2 5 6$ , and $5 1 2 \\times 5 1 2$ resolution. ",
518
+ "bbox": [
519
+ 174,
520
+ 662,
521
+ 825,
522
+ 718
523
+ ],
524
+ "page_idx": 5
525
+ },
526
+ {
527
+ "type": "text",
528
+ "text": "Table 4 summarizes our results. ADM refers to our ablated diffusion model, and ADM-G additionally uses classifier guidance. Our diffusion models can obtain the best FID on each task, and the best sFID on all but one task. With the improved architecture, we already obtain state-of-the-art image generation on LSUN and ImageNet $6 4 \\times 6 4$ . For higher resolution ImageNet, we observe that classifier guidance allows our models to substantially outperform the best GANs. These models obtain perceptual quality similar to GANs, while maintaining a higher coverage of the distribution as measured by recall, and can even do so using only 25 sampling steps. We also evaluate the computational requirements for training our models (Table $\\underline { { \\overline { { 1 0 } } } } ,$ Appendix $\\mathbf { B } )$ , and find that we can obtain competitive sample quality while using the same or less compute than the corresponding BigGAN-deep or StyleGAN2 model. ",
529
+ "bbox": [
530
+ 174,
531
+ 724,
532
+ 825,
533
+ 863
534
+ ],
535
+ "page_idx": 5
536
+ },
537
+ {
538
+ "type": "text",
539
+ "text": "Figure 4 compares random samples from the best BigGAN-deep model to our guided diffusion model. While the samples are of similar perceptual quality, the diffusion model contains more modes than the GAN, such as zoomed ostrich heads, single flamingos, different orientations of cheeseburgers, and a tinca fish with no human holding it. We also check our generated samples for nearest neighbors in the Inception-V3 feature space in Appendix E, and we show additional samples in Appendices M-O. ",
540
+ "bbox": [
541
+ 174,
542
+ 869,
543
+ 825,
544
+ 911
545
+ ],
546
+ "page_idx": 5
547
+ },
548
+ {
549
+ "type": "table",
550
+ "img_path": "images/78bd8a08e63c24eeb994d0756e48d868e96fe7cc0cf92927f51ade174974d4e8.jpg",
551
+ "table_caption": [
552
+ "Table 4: Sample quality comparison with state-of-the-art generative models for each task. LSUN diffusion models are sampled using 1000 steps (see Appendix $\\bigstar \\bigstar$ . ImageNet diffusion models are sampled using 250 steps, except when we use the DDIM sampler with 25 steps. \\*No BigGAN-deep model was available at this resolution, so we trained our own. †Values are taken from a previous paper, due to lack of public models or samples. ‡Results use two-resolution stacks. §Results use compute-intensive classifier rejection sampling. "
553
+ ],
554
+ "table_footnote": [],
555
+ "table_body": "<table><tr><td>Model</td><td>FID</td><td>sFID</td><td>Prec</td><td>Rec</td></tr><tr><td colspan=\"5\">LSUN Bedrooms 256×256 DCTransformer+ 48</td></tr><tr><td>DDPM [31]</td><td>6.40 4.89</td><td>6.66 9.07</td><td>0.44 0.60</td><td>0.56 0.45</td></tr><tr><td>IDDPM[49]</td><td>4.24</td><td>8.21</td><td>0.62</td><td>0.46</td></tr><tr><td>StyleGAN [33]</td><td>2.35</td><td>6.62</td><td>0.59</td><td>0.48</td></tr><tr><td>ADM (dropout)</td><td>1.90</td><td>5.59</td><td>0.66</td><td>0.51</td></tr><tr><td colspan=\"5\">LSUN Horses 256×256</td></tr><tr><td>StyleGAN2 34 ADM ADM (dropout)</td><td>3.84 2.95</td><td>6.46 5.94</td><td>0.63 0.69</td><td>0.48 0.55</td></tr><tr><td></td><td>2.57</td><td>6.81</td><td>0.71</td><td>0.55</td></tr><tr><td>LSUN Cats 256×256</td><td></td><td></td><td></td><td></td></tr><tr><td colspan=\"5\">DDPM [31]</td></tr><tr><td>StyleGAN2 [34]</td><td>17.1</td><td>12.4</td><td>0.53</td><td>0.48</td></tr><tr><td></td><td>7.25</td><td>6.33</td><td>0.58</td><td>0.43</td></tr><tr><td>ADM (dropout)</td><td>5.57</td><td>6.69</td><td>0.63</td><td>0.52</td></tr><tr><td>ImageNet 64×64</td><td></td><td></td><td></td><td></td></tr><tr><td colspan=\"5\">BigGAN-deep* 回</td></tr><tr><td></td><td>4.06</td><td>3.96</td><td>0.79</td><td>0.48</td></tr><tr><td>IDDPM[ [49]</td><td>2.92</td><td>3.79</td><td>0.74</td><td>0.62</td></tr><tr><td>ADM</td><td>2.61</td><td>3.77</td><td>0.73</td><td>0.63</td></tr><tr><td>ADM (dropout)</td><td>2.07</td><td>4.29</td><td>0.74</td><td>0.63</td></tr></table>",
556
+ "bbox": [
557
+ 173,
558
+ 186,
559
+ 478,
560
+ 555
561
+ ],
562
+ "page_idx": 6
563
+ },
564
+ {
565
+ "type": "table",
566
+ "img_path": "images/94831f3cabb144dad55bcbfb158783030f5497ff9f18ae02e337e69f8a8092bd.jpg",
567
+ "table_caption": [],
568
+ "table_footnote": [],
569
+ "table_body": "<table><tr><td>Model</td><td>FID</td><td>SFID</td><td>Prec</td><td>Rec</td></tr><tr><td>ImageNet 128×128 BigGAN-deep 8</td><td>6.02</td><td>7.18</td><td>0.86</td><td>0.35</td></tr><tr><td>LOGANt 四</td><td>3.36</td><td></td><td></td><td></td></tr><tr><td>ADM</td><td>5.91</td><td>5.09</td><td>0.70</td><td>0.65</td></tr><tr><td>ADM-G (25 steps)</td><td>5.98</td><td>7.04</td><td>0.78</td><td>0.51</td></tr><tr><td>ADM-G</td><td>2.97</td><td>5.09</td><td>0.78</td><td>0.59</td></tr><tr><td>ImageNet 256×256</td><td></td><td></td><td></td><td></td></tr><tr><td>DCTransformer† 8</td><td>36.51</td><td>8.24</td><td></td><td>0.67</td></tr><tr><td>VQ-VAE-2†‡ 回</td><td></td><td></td><td>0.36</td><td></td></tr><tr><td></td><td>31.11</td><td>17.38</td><td>0.36</td><td>0.57</td></tr><tr><td>VQ-VAE-2 (RS)t‡ $ 四</td><td>~10</td><td></td><td></td><td>0.58</td></tr><tr><td>VQ-GAN* 四</td><td>15.97</td><td>19.05</td><td>0.63</td><td>0.48</td></tr><tr><td>VQ-GAN (RS)t$ 四 IDDPM‡ [ 49</td><td>5.06 12.26</td><td>7.34 5.42</td><td>0.79 0.70</td><td>0.62</td></tr><tr><td>SR3tt 四</td><td>11.30</td><td></td><td></td><td></td></tr><tr><td>BigGAN-deep 回</td><td>6.95</td><td>7.36</td><td>0.87</td><td>0.28</td></tr><tr><td>ADM</td><td>10.94</td><td>6.02</td><td>0.69</td><td>0.63</td></tr><tr><td>ADM-G (25 steps)</td><td>5.44</td><td>5.32</td><td>0.81</td><td>0.49</td></tr><tr><td>ADM-G</td><td>4.59</td><td>5.25</td><td>0.82</td><td>0.52</td></tr><tr><td>ImageNet 512×512</td><td></td><td></td><td></td><td></td></tr><tr><td>BigGAN-deep 图</td><td>8.43</td><td>8.13</td><td></td><td>0.29</td></tr><tr><td>ADM</td><td></td><td></td><td>0.88</td><td></td></tr><tr><td></td><td>23.24</td><td>10.19</td><td>0.73</td><td>0.60</td></tr><tr><td>ADM-G (25 steps)</td><td>8.41</td><td>9.67</td><td>0.83</td><td>0.47</td></tr><tr><td>ADM-G</td><td>7.72</td><td>6.57</td><td>0.87</td><td>0.42</td></tr></table>",
570
+ "bbox": [
571
+ 495,
572
+ 186,
573
+ 826,
574
+ 556
575
+ ],
576
+ "page_idx": 6
577
+ },
578
+ {
579
+ "type": "text",
580
+ "text": "",
581
+ "bbox": [
582
+ 174,
583
+ 570,
584
+ 826,
585
+ 599
586
+ ],
587
+ "page_idx": 6
588
+ },
589
+ {
590
+ "type": "text",
591
+ "text": "We also compare guidance to using a two-stage upsampling stack. Nichol and Dhariwal [49] and Saharia et al. $\\boxed { 6 0 }$ train two-stage diffusion models by combining a low-resolution diffusion model with a corresponding upsampling diffusion model. In this approach, the upsampling model is trained to upsample images from the training set, and conditions on low-resolution images that are concatenated channel-wise to the model input using a simple interpolation (e.g. bilinear). During sampling, the low-resolution model produces a sample, and then the upsampling model is conditioned on this sample. This greatly improves FID on ImageNet $2 5 6 \\times 2 5 6$ , but does not reach the same performance as state-of-the-art models like BigGAN-deep [49, 60], as seen in Table 4. ",
592
+ "bbox": [
593
+ 173,
594
+ 604,
595
+ 825,
596
+ 715
597
+ ],
598
+ "page_idx": 6
599
+ },
600
+ {
601
+ "type": "text",
602
+ "text": "In Table $\\boxed { 5 }$ we show that guidance and upsampling improve sample quality along different axes. We use the upsampling stack from Nichol and Dhariwal [49] combined with our architecture improvements, which we refer to as ADM-U. While upsampling improves precision while keeping a high recall, guidance provides a knob to trade off diversity for much higher precision. We achieve the best FIDs by using guidance at a lower resolution before upsampling to a higher resolution, indicating that these approaches complement one another. ",
603
+ "bbox": [
604
+ 174,
605
+ 722,
606
+ 825,
607
+ 805
608
+ ],
609
+ "page_idx": 6
610
+ },
611
+ {
612
+ "type": "text",
613
+ "text": "6 Related Work ",
614
+ "text_level": 1,
615
+ "bbox": [
616
+ 174,
617
+ 824,
618
+ 321,
619
+ 842
620
+ ],
621
+ "page_idx": 6
622
+ },
623
+ {
624
+ "type": "text",
625
+ "text": "Score based generative models were introduced by Song and Ermon [66] as a way of modeling a data distribution using its gradients, and then sampling using Langevin dynamics [73]. Ho et al. [31] found a connection between this method and diffusion models $\\pmb { \\mathbb { E 3 } } ] $ , and achieved excellent sample quality by leveraging this connection. After this breakthrough work, many works followed up with more promising results: Kong et al. [36] and Chen et al. [11] demonstrated that diffusion models work well for audio; Jolicoeur-Martineau et al. [32] found that a GAN-like setup could improve samples from these models; Song et al. [67] explored ways to leverage techniques from stochastic differential equations to improve the sample quality obtained by score-based models; Song et al. [64] and Nichol and Dhariwal [49] proposed methods to improve sampling speed; Nichol and Dhariwal [49] and Saharia et al. [60] demonstrated promising results on the difficult ImageNet generation task using upsampling diffusion models. Also related to diffusion models, and following the work of Sohl-Dickstein et al. [63], Goyal et al. [27] described a technique for learning a model with learned iterative generation steps, and found that it could achieve good image samples when trained with a likelihood objective. ",
626
+ "bbox": [
627
+ 174,
628
+ 854,
629
+ 825,
630
+ 911
631
+ ],
632
+ "page_idx": 6
633
+ },
634
+ {
635
+ "type": "image",
636
+ "img_path": "images/d9704a85040ab49727c123479c513cf7b2c243c18519d8a70391578c96ff2109.jpg",
637
+ "image_caption": [
638
+ "Figure 4: Samples from BigGAN-deep with truncation 1.0 (FID 6.95, left) vs samples from our diffusion model with guidance (FID 4.59, middle) and samples from the training set (right). "
639
+ ],
640
+ "image_footnote": [],
641
+ "bbox": [
642
+ 179,
643
+ 88,
644
+ 818,
645
+ 409
646
+ ],
647
+ "page_idx": 7
648
+ },
649
+ {
650
+ "type": "table",
651
+ "img_path": "images/5a624c8a26062f9098379d544f29790768a0f85259ec2ef83690f4192c23f929.jpg",
652
+ "table_caption": [
653
+ "Table 5: Comparing our single, upsampling and classifier guided models. The upsamplers are $6 4 2 5 6$ and $1 2 8 \\to 5 1 2$ . When combining guidance with upsampling, we only guide the lower resolution model. All models are sampled using 250 sampling steps. "
654
+ ],
655
+ "table_footnote": [],
656
+ "table_body": "<table><tr><td>Model</td><td>FID</td><td>sFID</td><td>IS</td><td>Prec</td><td>Rec</td><td>Model</td><td>FID</td><td>SFID</td><td>IS</td><td>Prec</td><td>Rec</td></tr><tr><td>ImageNet 256×256</td><td></td><td></td><td></td><td></td><td></td><td>ImageNet 512×512</td><td></td><td></td><td></td><td></td><td></td></tr><tr><td>ADM</td><td>10.94</td><td>6.02</td><td>100.98</td><td>0.69</td><td>0.63</td><td>ADM</td><td>23.24</td><td>10.19</td><td>58.06</td><td>0.73</td><td>0.60</td></tr><tr><td>ADM, ADM-U</td><td>7.49</td><td>5.13</td><td>127.49</td><td>0.72</td><td>0.63</td><td>ADM, ADM-U</td><td>9.96</td><td>5.62</td><td>121.78</td><td>0.75</td><td>0.64</td></tr><tr><td>ADM-G</td><td>4.59</td><td>5.25</td><td>186.70</td><td>0.82</td><td>0.52</td><td>ADM-G</td><td>7.72</td><td>6.57</td><td>172.71</td><td>0.87</td><td>0.42</td></tr><tr><td>ADM-G,ADM-U</td><td>3.94</td><td>6.14</td><td>215.84</td><td>0.83</td><td>0.53</td><td>ADM-G, ADM-U</td><td>3.85</td><td>5.86</td><td>221.72</td><td>0.84</td><td>0.53</td></tr></table>",
657
+ "bbox": [
658
+ 174,
659
+ 515,
660
+ 820,
661
+ 616
662
+ ],
663
+ "page_idx": 7
664
+ },
665
+ {
666
+ "type": "text",
667
+ "text": "",
668
+ "bbox": [
669
+ 173,
670
+ 641,
671
+ 825,
672
+ 780
673
+ ],
674
+ "page_idx": 7
675
+ },
676
+ {
677
+ "type": "text",
678
+ "text": "One missing element from previous work on diffusion models is a way to trade off diversity for fidelity. Other generative techniques provide natural levers for this trade-off. Brock et al. [8] introduced the truncation trick for GANs, wherein the latent vector is sampled from a truncated normal distribution. They found that increasing truncation naturally led to a decrease in diversity but an increase in fidelity. More recently, Razavi et al. [57] proposed to use classifier rejection sampling to filter out bad samples from an autoregressive likelihood-based model, and found that this technique improved FID. DeVries et al. [16] found that filtering out low-density regions of the training set improves GAN training performance. Most likelihood-based models also allow for low-temperature sampling [1], which provides a natural way to emphasize modes of the data distribution (see Appendix I). ",
679
+ "bbox": [
680
+ 173,
681
+ 786,
682
+ 826,
683
+ 912
684
+ ],
685
+ "page_idx": 7
686
+ },
687
+ {
688
+ "type": "text",
689
+ "text": "Other likelihood-based models have been shown to produce high-fidelity image samples. VQ-VAE $\\pmb { \\mathbb { Z } 1 }$ and VQ-VAE-2 $ { \\mathbb { B } } { \\mathbb { Z } }$ are autoregressive models trained on top of quantized latent codes, greatly reducing the computational resources required to train these models on large images. These models produce diverse and high quality images, but still fall short of GANs without expensive rejection sampling and special metrics to compensate for blurriness. DCTransformer $\\lVert \\rVert$ is a related method which relies on a more intelligent compression scheme. VAEs are another promising class of likelihood-based models, and recent methods such as NVAE $\\textcircled { 1 6 9 } \\textcircled { 1 }$ and VDVAE $\\lVert \\dot { 1 } \\dot { 2 } \\rVert$ have successfully been applied to difficult image generation domains. Energy-based models are another class of likelihood-based models with a rich history [1, 13, 30]. Sampling from the EBM distribution is challenging, and Xie et al. $\\pmb { \\mathbb { Z } } \\pmb { 6 } \\|$ demonstrate that Langevin dynamics can be used to sample coherent images from these models. Du and Mordatch [19] further improve upon this approach, obtaining high quality images. More recently, Gao et al. [24] incorporate diffusion steps into an energy-based model, and find that doing so improves image samples from these models. ",
690
+ "bbox": [
691
+ 174,
692
+ 90,
693
+ 825,
694
+ 271
695
+ ],
696
+ "page_idx": 8
697
+ },
698
+ {
699
+ "type": "text",
700
+ "text": "Other works have controlled generative models with a pre-trained classifier. For example, an emerging body of work [23, 53, 2] aims to optimize GAN latent spaces for text prompts using pre-trained CLIP $\\pmb { \\| 5 5 \\| }$ models. More similar to our work, Song et al. $\\textcircled { 6 7 }$ uses a classifier to generate class-conditional CIFAR-10 images with a diffusion model. In some cases, classifiers can act as stand-alone generative models. For example, Santurkar et al. [62] demonstrate that a robust image classifier can be used as a stand-alone generative model, and Grathwohl et al. [28] train a model which is jointly a classifier and an energy-based model. ",
701
+ "bbox": [
702
+ 174,
703
+ 277,
704
+ 825,
705
+ 375
706
+ ],
707
+ "page_idx": 8
708
+ },
709
+ {
710
+ "type": "text",
711
+ "text": "7 Limitations and Future Work ",
712
+ "text_level": 1,
713
+ "bbox": [
714
+ 176,
715
+ 400,
716
+ 450,
717
+ 417
718
+ ],
719
+ "page_idx": 8
720
+ },
721
+ {
722
+ "type": "text",
723
+ "text": "While we believe diffusion models are an extremely promising direction for generative modeling, they are still slower than GANs at sampling time due to the use of multiple denoising steps (and therefore forward passes). Since our diffusion models are also larger than the competing GAN generators, each forward pass takes anywhere from 5-20 times longer too. A promising direction to reduce this latency gap is Luhman and Luhman [43], who explore a way to distill the DDIM sampling process into a single step model. The samples from the single step model are not yet competitive with GANs, but are much better than previous single-step likelihood-based models. Future work in this direction might be able to completely close the sampling speed gap between diffusion models and GANs without sacrificing image quality. ",
724
+ "bbox": [
725
+ 174,
726
+ 435,
727
+ 825,
728
+ 560
729
+ ],
730
+ "page_idx": 8
731
+ },
732
+ {
733
+ "type": "text",
734
+ "text": "Unlike GANs, Flows, and VAEs, diffusion models do not learn an explicit latent representation. While DDIM provides a way to encode images into an implicit latent space, it is unclear how semantically meaningful this latent representation is compared to those of other model classes. This could make it difficult to use diffusion models for representation learning or image editing applications. ",
735
+ "bbox": [
736
+ 174,
737
+ 566,
738
+ 825,
739
+ 622
740
+ ],
741
+ "page_idx": 8
742
+ },
743
+ {
744
+ "type": "text",
745
+ "text": "The effectiveness of classifier guidance demonstrates that we can obtain powerful generative models from the gradients of a classification function. This could be used to condition an image generator with a text caption using a noisy version of CLIP $ { \\mathbb { I } } { \\mathbb { I } } ^ { { 5 } { 5 } { \\mathbb { I } } }$ , similar to recent methods that guide GANs using text prompts $\\pm \\sqrt { 2 3 } \\sqrt { 5 3 } \\sqrt { 2 }$ . Our proposed classifier guidance technique is currently limited to labeled datasets. In the future, our method could be extended to unlabeled data by clustering samples to produce synthetic labels $[ | \\overline { { 4 2 } } | |$ or by training discriminative models to use for guidance. This also suggests that large unlabeled datasets could be leveraged in the future to pre-train powerful diffusion models that can later be improved by using a classifier with desirable properties. ",
746
+ "bbox": [
747
+ 174,
748
+ 628,
749
+ 825,
750
+ 739
751
+ ],
752
+ "page_idx": 8
753
+ },
754
+ {
755
+ "type": "text",
756
+ "text": "8 Societal Impact ",
757
+ "text_level": 1,
758
+ "bbox": [
759
+ 174,
760
+ 765,
761
+ 334,
762
+ 782
763
+ ],
764
+ "page_idx": 8
765
+ },
766
+ {
767
+ "type": "text",
768
+ "text": "Our proposed technique makes generative models more accessible in terms of compute costs, especially because new classifiers can be trained and used on top of existing high-quality diffusion models. While we believe this is generally a benefit of these models, it could also have negative societal implications. For example, cheaper generative models could enable bad actors to generate fake news, propaganda images, or doctored photos. Additionally, the wide-spread deployment of these models could displace jobs in art, graphic design, animation, and photography. One could imagine, however, that democratizing generative models could also have positive impacts in the long run, creating new types of jobs such as generative photo editing. Intentionally deceitful generated images are a more direct concern, and detecting and mitigating propaganda and fake news based on generative models is an ongoing area of research [4, 3, 5]. ",
769
+ "bbox": [
770
+ 174,
771
+ 800,
772
+ 825,
773
+ 911
774
+ ],
775
+ "page_idx": 8
776
+ },
777
+ {
778
+ "type": "text",
779
+ "text": "",
780
+ "bbox": [
781
+ 171,
782
+ 92,
783
+ 823,
784
+ 119
785
+ ],
786
+ "page_idx": 9
787
+ },
788
+ {
789
+ "type": "text",
790
+ "text": "9 Conclusion ",
791
+ "text_level": 1,
792
+ "bbox": [
793
+ 174,
794
+ 138,
795
+ 299,
796
+ 155
797
+ ],
798
+ "page_idx": 9
799
+ },
800
+ {
801
+ "type": "text",
802
+ "text": "We have shown that diffusion models, a class of likelihood-based models with a stationary training objective, can obtain better sample quality than state-of-the-art GANs. Our improved architecture is sufficient to achieve this on unconditional image generation tasks, and our classifier guidance technique allows us to do so on class-conditional tasks. In the latter case, we find that the scale of the classifier gradients can be adjusted to trade off diversity for fidelity. These guided diffusion models can reduce the sampling time gap between GANs and diffusion models, although diffusion models still require multiple forward passes during sampling. Finally, by combining guidance with upsampling, we can further improve sample quality on high-resolution conditional image synthesis. ",
803
+ "bbox": [
804
+ 173,
805
+ 170,
806
+ 825,
807
+ 281
808
+ ],
809
+ "page_idx": 9
810
+ },
811
+ {
812
+ "type": "text",
813
+ "text": "References ",
814
+ "text_level": 1,
815
+ "bbox": [
816
+ 174,
817
+ 300,
818
+ 266,
819
+ 316
820
+ ],
821
+ "page_idx": 9
822
+ },
823
+ {
824
+ "type": "text",
825
+ "text": "[1] David Ackley, Geoffrey Hinton, and Terrence Sejnowski. A learning algorithm for boltzmann machines. Cognitive science, 9(1):147-169, 1985. \n[2] Adverb. The big sleep. https://twitter.com/advadnoun/status/ 1351038053033406468, 2021. \n[3] Shruti Agarwal, Hany Farid, Yuming Gu, Mingming He, Koki Nagano, and Hao Li. Protecting world leaders against deep fakes. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR) Workshops, June 2019. \n[4] Hadeer Ahmed, Issa Traore, and Sherif Saad. Detection of online fake news using n-gram analysis and machine learning techniques. pages 127–138, 10 2017. ISBN 978-3-319-69154-1. doi: 10.1007/978-3-319-69155-8_9. \n[5] Hadeer Ahmed, Issa Traore, and Sherif Saad. Detecting opinion spams and fake news using text classification. Security and Privacy, 1(1):e9, 2018. doi: https://doi.org/10.1002/spy2.9. URL https://onlinelibrary.wiley.com/doi/abs/10.1002/spy2.9. \n[6] Shane Barratt and Rishi Sharma. A note on the inception score. arXiv:1801.01973, 2018. \n[7] Andrew Brock, Theodore Lim, J. M. Ritchie, and Nick Weston. Neural photo editing with introspective adversarial networks. arXiv:1609.07093, 2016. \n[8] Andrew Brock, Jeff Donahue, and Karen Simonyan. Large scale gan training for high fidelity natural image synthesis. arXiv:1809.11096, 2018. \n[9] Tom B. Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah, Jared Kaplan, Prafulla Dhariwal, Arvind Neelakantan, Pranav Shyam, Girish Sastry, Amanda Askell, Sandhini Agarwal, Ariel Herbert-Voss, Gretchen Krueger, Tom Henighan, Rewon Child, Aditya Ramesh, Daniel M. Ziegler, Jeffrey Wu, Clemens Winter, Christopher Hesse, Mark Chen, Eric Sigler, Mateusz Litwin, Scott Gray, Benjamin Chess, Jack Clark, Christopher Berner, Sam McCandlish, Alec Radford, Ilya Sutskever, and Dario Amodei. Language models are few-shot learners. arXiv:2005.14165, 2020. \n[10] Mark Chen, Alec Radford, Rewon Child, Jeffrey Wu, Heewoo Jun, David Luan, and Ilya Sutskever. Generative pretraining from pixels. In International Conference on Machine Learning, pages 1691–1703. PMLR, 2020. \n[11] Nanxin Chen, Yu Zhang, Heiga Zen, Ron J. Weiss, Mohammad Norouzi, and William Chan. Wavegrad: Estimating gradients for waveform generation. arXiv:2009.00713, 2020. \n[12] Rewon Child. Very deep vaes generalize autoregressive models and can outperform them on images. arXiv:2011.10650, 2021. \n[13] Peter Dayan, Geoffrey E Hinton, Radford M Neal, and Richard S Zemel. The helmholtz machine. Neural computation, 7(5):889–904, 1995. \n[14] Harm de Vries, Florian Strub, Jérémie Mary, Hugo Larochelle, Olivier Pietquin, and Aaron Courville. Modulating early visual processing by language. arXiv:1707.00683, 2017. \n[15] DeepMind. Biggan-deep $1 2 8 \\mathrm { x } 1 2 8$ on tensorflow hub. https://tfhub.dev/deepmind/ biggan-deep-128/1, 2018. \n[16] Terrance DeVries, Michal Drozdzal, and Graham W. Taylor. Instance selection for gans. arXiv:2007.15255, 2020. \n[17] Prafulla Dhariwal, Heewoo Jun, Christine Payne, Jong Wook Kim, Alec Radford, and Ilya Sutskever. Jukebox: A generative model for music. arXiv:2005.00341, 2020. \n[18] Jeff Donahue and Karen Simonyan. Large scale adversarial representation learning. arXiv:1907.02544, 2019. \n[19] Yilun Du and Igor Mordatch. Implicit generation and generalization in energy-based models. arXiv:1903.08689, 2019. \n[20] Vincent Dumoulin, Jonathon Shlens, and Manjunath Kudlur. A learned representation for artistic style. arXiv:1610.07629, 2017. \n[21] Patrick Esser, Robin Rombach, and Björn Ommer. Taming transformers for high-resolution image synthesis. arXiv:2012.09841, 2020. \n[22] Jeffrey De Fauw, Sander Dieleman, and Karen Simonyan. Hierarchical autoregressive image models with auxiliary decoders. arXiv:1903.04933, 2019. \n[23] Federico A. Galatolo, Mario G. C. A. Cimino, and Gigliola Vaglini. Generating images from caption and vice versa via clip-guided generative latent space search. arXiv:2102.01645, 2021. \n[24] Ruiqi Gao, Yang Song, Ben Poole, Ying Nian Wu, and Diederik P. Kingma. Learning energybased models by diffusion recovery likelihood. arXiv:2012.08125, 2020. \n[25] Ian J. Goodfellow, Jean Pouget-Abadie, Mehdi Mirza, Bing Xu, David Warde-Farley, Sherjil Ozair, Aaron Courville, and Yoshua Bengio. Generative adversarial networks. arXiv:1406.2661, 2014. \n[26] Google. Cloud tpus. https://cloud.google.com/tpu/, 2018. \n[27] Anirudh Goyal, Nan Rosemary Ke, Surya Ganguli, and Yoshua Bengio. Variational walkback: Learning a transition operator as a stochastic recurrent net. arXiv:1711.02282, 2017. \n[28] Will Grathwohl, Kuan-Chieh Wang, Jörn-Henrik Jacobsen, David Duvenaud, Mohammad Norouzi, and Kevin Swersky. Your classifier is secretly an energy based model and you should treat it like one. arXiv:1912.03263, 2019. \n[29] Martin Heusel, Hubert Ramsauer, Thomas Unterthiner, Bernhard Nessler, and Sepp Hochreiter. Gans trained by a two time-scale update rule converge to a local nash equilibrium. Advances in Neural Information Processing Systems 30 (NIPS 2017), 2017. \n[30] Geoffrey E Hinton. Training products of experts by minimizing contrastive divergence. Neural computation, 14(8):1771–1800, 2002. \n[31] Jonathan Ho, Ajay Jain, and Pieter Abbeel. Denoising diffusion probabilistic models. arXiv:2006.11239, 2020. \n[32] Alexia Jolicoeur-Martineau, Rémi Piché-Taillefer, Rémi Tachet des Combes, and Ioannis Mitliagkas. Adversarial score matching and improved sampling for image generation. arXiv:2009.05475, 2020. \n[33] Tero Karras, Samuli Laine, and Timo Aila. A style-based generator architecture for generative adversarial networks. arXiv:arXiv:1812.04948, 2019. \n[34] Tero Karras, Samuli Laine, Miika Aittala, Janne Hellsten, Jaakko Lehtinen, and Timo Aila. Analyzing and improving the image quality of stylegan. arXiv:1912.04958, 2019. \n[35] Diederik P. Kingma and Jimmy Ba. Adam: A method for stochastic optimization. arXiv:1412.6980, 2014. \n[36] Zhifeng Kong, Wei Ping, Jiaji Huang, Kexin Zhao, and Bryan Catanzaro. Diffwave: A versatile diffusion model for audio synthesis. arXiv:2009.09761, 2020. \n[37] Alex Krizhevsky, Vinod Nair, and Geoffrey Hinton. CIFAR-10 (Canadian Institute for Advanced Research), 2009. URL http://www.cs.toronto.edu/\\~kriz/cifar.html. \n[38] Tuomas Kynkäänniemi, Tero Karras, Samuli Laine, Jaakko Lehtinen, and Timo Aila. Improved precision and recall metric for assessing generative models. arXiv:1904.06991, 2019. \n[39] Guosheng Lin, Anton Milan, Chunhua Shen, and Ian Reid. Refinenet: Multi-path refinement networks for high-resolution semantic segmentation. arXiv:1611.06612, 2016. \n[40] Ziwei Liu, Ping Luo, Xiaogang Wang, and Xiaoou Tang. Deep learning face attributes in the wild. In Proceedings of International Conference on Computer Vision (ICCV), December 2015. \n[41] Ilya Loshchilov and Frank Hutter. Decoupled weight decay regularization. arXiv:1711.05101, 2017. \n[42] Mario Lucic, Michael Tschannen, Marvin Ritter, Xiaohua Zhai, Olivier Bachem, and Sylvain Gelly. High-fidelity image generation with fewer labels. arXiv:1903.02271, 2019. \n[43] Eric Luhman and Troy Luhman. Knowledge distillation in iterative generative models for improved sampling speed. arXiv:2101.02388, 2021. \n[44] Paulius Micikevicius, Sharan Narang, Jonah Alben, Gregory Diamos, Erich Elsen, David Garcia, Boris Ginsburg, Michael Houston, Oleksii Kuchaiev, Ganesh Venkatesh, and Hao Wu. Mixed precision training. arXiv:1710.03740, 2017. \n[45] Mehdi Mirza and Simon Osindero. Conditional generative adversarial nets. arXiv:1411.1784, 2014. \n[46] Takeru Miyato and Masanori Koyama. cgans with projection discriminator. arXiv:1802.05637, 2018. \n[47] Takeru Miyato, Toshiki Kataoka, Masanori Koyama, and Yuichi Yoshida. Spectral normalization for generative adversarial networks. arXiv:1802.05957, 2018. \n[48] Charlie Nash, Jacob Menick, Sander Dieleman, and Peter W. Battaglia. Generating images with sparse representations. arXiv:2103.03841, 2021. \n[49] Alex Nichol and Prafulla Dhariwal. Improved denoising diffusion probabilistic models. arXiv:2102.09672, 2021. \n[50] NVIDIA. Stylegan2. https://github.com/NVlabs/stylegan2, 2019. \n[51] Gaurav Parmar, Richard Zhang, and Jun-Yan Zhu. On buggy resizing libraries and surprising subtleties in fid calculation. arXiv:2104.11222, 2021. \n[52] Adam Paszke, Sam Gross, Francisco Massa, Adam Lerer, James Bradbury, Gregory Chanan, Trevor Killeen, Zeming Lin, Natalia Gimelshein, Luca Antiga, et al. Pytorch: An imperative style, high-performance deep learning library. arXiv:1912.01703, 2019. \n[53] Or Patashnik, Zongze Wu, Eli Shechtman, Daniel Cohen-Or, and Dani Lischinski. Styleclip: Text-driven manipulation of stylegan imagery. arXiv:2103.17249, 2021. \n[54] Ethan Perez, Florian Strub, Harm de Vries, Vincent Dumoulin, and Aaron Courville. Film: Visual reasoning with a general conditioning layer. arXiv:1709.07871, 2017. \n[55] Alec Radford, Jong Wook Kim, Chris Hallacy, Aditya Ramesh, Gabriel Goh, Sandhini Agarwal, Girish Sastry, Amanda Askell, Pamela Mishkin, Jack Clark, Gretchen Krueger, and Ilya Sutskever. Learning transferable visual models from natural language supervision. arXiv:2103.00020, 2021. \n[56] Aditya Ramesh, Mikhail Pavlov, Gabriel Goh, Scott Gray, Chelsea Voss, Alec Radford, Mark Chen, and Ilya Sutskever. Zero-shot text-to-image generation. arXiv:2102.12092, 2021. \n[57] Ali Razavi, Aaron van den Oord, and Oriol Vinyals. Generating diverse high-fidelity images with VQ-VAE-2. arXiv:1906.00446, 2019. \n[58] Olaf Ronneberger, Philipp Fischer, and Thomas Brox. U-net: Convolutional networks for biomedical image segmentation. arXiv:1505.04597, 2015. \n[59] Olga Russakovsky, Jia Deng, Hao Su, Jonathan Krause, Sanjeev Satheesh, Sean Ma, Zhiheng Huang, Andrej Karpathy, Aditya Khosla, Michael Bernstein, Alexander C. Berg, and Li Fei-Fei. Imagenet large scale visual recognition challenge. arXiv:1409.0575, 2014. \n[60] Chitwan Saharia, Jonathan Ho, William Chan, Tim Salimans, David J. Fleet, and Mohammad Norouzi. Image super-resolution via iterative refinement. arXiv:arXiv:2104.07636, 2021. \n[61] Tim Salimans, Ian Goodfellow, Wojciech Zaremba, Vicki Cheung, Alec Radford, and Xi Chen. Improved techniques for training gans. arXiv:1606.03498, 2016. \n[62] Shibani Santurkar, Dimitris Tsipras, Brandon Tran, Andrew Ilyas, Logan Engstrom, and Aleksander Madry. Image synthesis with a single (robust) classifier. arXiv:1906.09453, 2019. \n[63] Jascha Sohl-Dickstein, Eric A. Weiss, Niru Maheswaranathan, and Surya Ganguli. Deep unsupervised learning using nonequilibrium thermodynamics. arXiv:1503.03585, 2015. \n[64] Jiaming Song, Chenlin Meng, and Stefano Ermon. Denoising diffusion implicit models. arXiv:2010.02502, 2020. \n[65] Yang Song and Stefano Ermon. Improved techniques for training score-based generative models. arXiv:2006.09011, 2020. \n[66] Yang Song and Stefano Ermon. Generative modeling by estimating gradients of the data distribution. arXiv:arXiv:1907.05600, 2020. \n[67] Yang Song, Jascha Sohl-Dickstein, Diederik P. Kingma, Abhishek Kumar, Stefano Ermon, and Ben Poole. Score-based generative modeling through stochastic differential equations. arXiv:2011.13456, 2020. \n[68] Christian Szegedy, Vincent Vanhoucke, Sergey Ioffe, Jonathon Shlens, and Zbigniew Wojna. Rethinking the inception architecture for computer vision. arXiv:1512.00567, 2015. \n[69] Arash Vahdat and Jan Kautz. Nvae: A deep hierarchical variational autoencoder. arXiv:2007.03898, 2020. \n[70] Aaron van den Oord, Sander Dieleman, Heiga Zen, Karen Simonyan, Oriol Vinyals, Alex Graves, Nal Kalchbrenner, Andrew Senior, and Koray Kavukcuoglu. Wavenet: A generative model for raw audio. arXiv:1609.03499, 2016. \n[71] Aaron van den Oord, Oriol Vinyals, and Koray Kavukcuoglu. Neural discrete representation learning. arXiv:1711.00937, 2017. \n[72] Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N. Gomez, Lukasz Kaiser, and Illia Polosukhin. Attention is all you need. arXiv:1706.03762, 2017. \n[73] Max Welling and Yee W Teh. Bayesian learning via stochastic gradient langevin dynamics. In Proceedings of the 28th international conference on machine learning (ICML-11), pages 681–688. Citeseer, 2011. \n[74] Yan Wu, Jeff Donahue, David Balduzzi, Karen Simonyan, and Timothy Lillicrap. Logan: Latent optimisation for generative adversarial networks. arXiv:1912.00953, 2019. \n[75] Yuxin Wu and Kaiming He. Group normalization. arXiv:1803.08494, 2018. \n[76] Jianwen Xie, Yang Lu, Song-Chun Zhu, and Ying Nian Wu. A theory of generative convnet. arXiv:1602.03264, 2016. ",
826
+ "bbox": [
827
+ 179,
828
+ 321,
829
+ 826,
830
+ 916
831
+ ],
832
+ "page_idx": 9
833
+ },
834
+ {
835
+ "type": "text",
836
+ "text": "",
837
+ "bbox": [
838
+ 171,
839
+ 65,
840
+ 828,
841
+ 912
842
+ ],
843
+ "page_idx": 10
844
+ },
845
+ {
846
+ "type": "text",
847
+ "text": "",
848
+ "bbox": [
849
+ 169,
850
+ 60,
851
+ 828,
852
+ 917
853
+ ],
854
+ "page_idx": 11
855
+ },
856
+ {
857
+ "type": "text",
858
+ "text": "",
859
+ "bbox": [
860
+ 171,
861
+ 56,
862
+ 830,
863
+ 912
864
+ ],
865
+ "page_idx": 12
866
+ },
867
+ {
868
+ "type": "text",
869
+ "text": "[77] Fisher Yu, Ari Seff, Yinda Zhang, Shuran Song, Thomas Funkhouser, and Jianxiong Xiao. Lsun: Construction of a large-scale image dataset using deep learning with humans in the loop. arXiv:1506.03365, 2015. ",
870
+ "bbox": [
871
+ 171,
872
+ 90,
873
+ 826,
874
+ 133
875
+ ],
876
+ "page_idx": 13
877
+ },
878
+ {
879
+ "type": "text",
880
+ "text": "[78] Han Zhang, Tao Xu, Hongsheng Li, Shaoting Zhang, Xiaogang Wang, Xiaolei Huang, and Dimitris Metaxas. Stackgan: Text to photo-realistic image synthesis with stacked generative adversarial networks. arXiv:1612.03242, 2016. ",
881
+ "bbox": [
882
+ 171,
883
+ 142,
884
+ 825,
885
+ 184
886
+ ],
887
+ "page_idx": 13
888
+ },
889
+ {
890
+ "type": "text",
891
+ "text": "Checklist ",
892
+ "text_level": 1,
893
+ "bbox": [
894
+ 174,
895
+ 89,
896
+ 254,
897
+ 106
898
+ ],
899
+ "page_idx": 14
900
+ },
901
+ {
902
+ "type": "text",
903
+ "text": "• Did you include the license to the code and datasets? [No] We were unable to find the official license for either ImageNet or LSUN. We do include a license for our released source code. ",
904
+ "bbox": [
905
+ 215,
906
+ 116,
907
+ 825,
908
+ 145
909
+ ],
910
+ "page_idx": 14
911
+ },
912
+ {
913
+ "type": "text",
914
+ "text": "1. For all authors... ",
915
+ "bbox": [
916
+ 214,
917
+ 157,
918
+ 339,
919
+ 171
920
+ ],
921
+ "page_idx": 14
922
+ },
923
+ {
924
+ "type": "text",
925
+ "text": "(a) Do the main claims made in the abstract and introduction accurately reflect the paper’s contributions and scope? [Yes] \n(b) Did you describe the limitations of your work? [Yes] See Section 7. \n(c) Did you discuss any potential negative societal impacts of your work? [Yes] See Section 8. \n(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes] ",
926
+ "bbox": [
927
+ 238,
928
+ 176,
929
+ 825,
930
+ 281
931
+ ],
932
+ "page_idx": 14
933
+ },
934
+ {
935
+ "type": "text",
936
+ "text": "2. If you are including theoretical results... ",
937
+ "bbox": [
938
+ 215,
939
+ 285,
940
+ 493,
941
+ 299
942
+ ],
943
+ "page_idx": 14
944
+ },
945
+ {
946
+ "type": "text",
947
+ "text": "(a) Did you state the full set of assumptions of all theoretical results? [Yes] See Appendix D. \n(b) Did you include complete proofs of all theoretical results? [Yes] We provide detailed derivations in Appendix D. ",
948
+ "bbox": [
949
+ 238,
950
+ 303,
951
+ 825,
952
+ 363
953
+ ],
954
+ "page_idx": 14
955
+ },
956
+ {
957
+ "type": "text",
958
+ "text": "3. If you ran experiments... ",
959
+ "bbox": [
960
+ 214,
961
+ 366,
962
+ 393,
963
+ 381
964
+ ],
965
+ "page_idx": 14
966
+ },
967
+ {
968
+ "type": "text",
969
+ "text": "(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes] We include the source code and instructions for running it. \n(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] See Appendix K. \n(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [No] Each experiment requires several hundred GPU days to run, so it is quite costly to compute error bars. \n(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] See Appendix B. ",
970
+ "bbox": [
971
+ 238,
972
+ 386,
973
+ 825,
974
+ 531
975
+ ],
976
+ "page_idx": 14
977
+ },
978
+ {
979
+ "type": "text",
980
+ "text": "4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets... ",
981
+ "bbox": [
982
+ 212,
983
+ 535,
984
+ 823,
985
+ 549
986
+ ],
987
+ "page_idx": 14
988
+ },
989
+ {
990
+ "type": "text",
991
+ "text": "(a) If your work uses existing assets, did you cite the creators? [Yes] Our codebase references the codebase it is forked from [49, 31]. We also cite PyTorch [52], which we use throughout our experiments. \n(b) Did you mention the license of the assets? [Yes] A license file is included with the code release. \n(c) Did you include any new assets either in the supplemental material or as a URL? [Yes] The code is included in the supplemental material. \n(d) Did you discuss whether and how consent was obtained from people whose data you’re using/curating? [N/A] \n(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A] ",
992
+ "bbox": [
993
+ 238,
994
+ 555,
995
+ 825,
996
+ 717
997
+ ],
998
+ "page_idx": 14
999
+ },
1000
+ {
1001
+ "type": "text",
1002
+ "text": "5. If you used crowdsourcing or conducted research with human subjects... ",
1003
+ "bbox": [
1004
+ 214,
1005
+ 720,
1006
+ 705,
1007
+ 736
1008
+ ],
1009
+ "page_idx": 14
1010
+ },
1011
+ {
1012
+ "type": "text",
1013
+ "text": "(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A] \n(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A] \n(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A] ",
1014
+ "bbox": [
1015
+ 238,
1016
+ 739,
1017
+ 825,
1018
+ 829
1019
+ ],
1020
+ "page_idx": 14
1021
+ }
1022
+ ]
parse/train/AAWuCvzaVt/AAWuCvzaVt_middle.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/AAWuCvzaVt/AAWuCvzaVt_model.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/Hyp3i2xRb/Hyp3i2xRb.md ADDED
@@ -0,0 +1,325 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # OVERCOMING THE VANISHING GRADIENT PROBLEM INPLAIN RECURRENT NETWORKS
2
+
3
+ Anonymous authors Paper under double-blind review
4
+
5
+ # ABSTRACT
6
+
7
+ Plain recurrent networks greatly suffer from the vanishing gradient problem while Gated Neural Networks (GNNs) such as Long-short Term Memory (LSTM) and Gated Recurrent Unit (GRU) deliver promising results in many sequence learning tasks through sophisticated network designs. This paper shows how we can address this problem in a plain recurrent network by analyzing the gating mechanisms in GNNs. We propose a novel network called the Recurrent Identity Network (RIN) which allows a plain recurrent network to overcome the vanishing gradient problem while training very deep models without the use of gates. We compare this model with IRNNs and LSTMs on multiple sequence modeling benchmarks. The RINs demonstrate competitive performance and converge faster in all tasks. Notably, small RIN models produce $12 \% { - } 6 7 \%$ higher accuracy on the Sequential and Permuted MNIST datasets and reach state-of-the-art performance on the bAbI question answering dataset.
8
+
9
+ # 1 INTRODUCTION
10
+
11
+ Numerous methods have been proposed for mitigating the vanishing gradient problem including the use of second-order optimization methods (e.g., Hessian-free optimization (Martens & Sutskever, 2011)), specific training schedules (e.g., Greedy Layer-wise training (Schmidhuber, 1992; Hinton et al., 2006; Vincent et al., 2008)), and special weight initialization methods when training on both plain FFNs and RNNs (Glorot & Bengio, 2010; Mishkin & Matas, 2015; Le et al., 2015; Jing et al., 2016; Xie et al., 2017; Jing et al., 2017).
12
+
13
+ Gated Neural Networks (GNNs) also help to mitigate this problem by introducing “gates” to control information flow through the network over layers or sequences. Notable examples include recurrent networks such as Long-short Term Memory (LSTM) (Hochreiter & Schmidhuber, 1997), Gated Recurrent Unit (GRU) (Chung et al., 2014; Cho et al., 2014), and feedforward networks such as Highway Networks (HNs) (Srivastava et al., 2015), and Residual Networks (ResNets) (He et al., 2015). One can successfully train very deep models by employing these models, e.g., ResNets can be trained with over 1,000 layers. It has been demonstrated that removing (lesioning) or reordering (re-shuffling) random layers in deep feedforward GNNs does not noticeable affect the performance of the network (Veit et al., 2016) Noticeably, one interpretation for this effect as given by Greff et al. (2016) is that the functional blocks in HNs or ResNets engage in an Unrolled Iterative Estimate (UIE) of representations and that layers in this block of HNs or ResNets iteratively refine a single set of representations.
14
+
15
+ In this paper, we investigate if the view of Iterative Estimation (IE) can also be applied towards recurrent GNNs (Section 2.1). We present a formal analysis for GNNs by examining a dual gate design common in LSTM and GRU (Section 2.2). The analysis suggests that the use of gates in GNNs encourages the network to learn an identity mapping which can be beneficial in training deep architectures (He et al., 2016; Greff et al., 2016).
16
+
17
+ We propose a new formulation of a plain RNN, called a Recurrent Identity Network (RIN), that is encouraged to learn an identity mapping without the use of gates (Section 2). This network uses ReLU as the activation function and contains a set of non-trainable parameters. This simple yet effective method helps the plain recurrent network to overcome the vanishing gradient problem while it is still able to model long-range dependencies. This network is compared against two competing networks, the IRNN (Le et al., 2015) and LSTM, on several long sequence modeling tasks including the adding problem (Section 3.1), Sequential and Permuted MNIST classification tasks (Section 3.2), and bAbI question answering tasks (Section 3.3). RINs show faster convergence than IRNNs and LSTMs in the early stage of the training phase and reach competitive performance in all benchmarks. Note that the use of ReLU in RNNs usually leads to training instability, and therefore the network is sensitive to training hyperparameters. Our proposed RIN network demonstrates that a plain RNN does not suffer from this problem even with the use of ReLUs as shown in Section 3. We discuss further implications of this network and related work in Section 4.
18
+
19
+ # 2 METHODS
20
+
21
+ # 2.1 ITERATIVE ESTIMATION VIEW IN RNNS
22
+
23
+ Representation learning in RNNs requires that the network build a latent state, which reflects the temporal dependencies over a sequence of inputs. In this section, we explore an interpretation of this process using iterative estimation (IE), a view that is similar to the UIE view for feedforward GNNs. Formally, we characterize this viewpoint in Eq. 1, that is, the expectation of the difference between the hidden activation at step $t$ , $\mathbf { h } _ { t }$ , and the last hidden activation at step $T$ , $\mathbf { h } _ { T }$ , is zero:
24
+
25
+ $$
26
+ \mathbb { E } _ { \mathbf { x } _ { 1 , . . . , T } } \left[ \mathbf { h } _ { t } - \mathbf { h } _ { T } \right] = 0 .
27
+ $$
28
+
29
+ This formulation implies that an RNN layer maintains and updates the same set of representations over the input sequence. Given the fact that the hidden activation at every step is an estimation of the final activation, we derive Eq. 3.
30
+
31
+ $$
32
+ \begin{array} { r l } & { \mathbb { E } _ { \mathbf { x } _ { 1 , \ldots , T } } \left[ \mathbf { h } _ { t } - \mathbf { h } _ { T } \right] - \mathbb { E } _ { \mathbf { x } _ { 1 , \ldots , T } } \left[ \mathbf { h } _ { t - 1 } - \mathbf { h } _ { T } \right] = 0 } \\ { \Rightarrow } & { \mathbb { E } _ { \mathbf { x } _ { 1 , \ldots , T } } \left[ \mathbf { h } _ { t } - \mathbf { h } _ { t - 1 } \right] = 0 } \end{array}
33
+ $$
34
+
35
+ ![](images/90b47af417914bf54d9b1c363199634637e193e353d6e4fdf11079c6775a24c1.jpg)
36
+ Figure 1: Observation of learning identity mapping in an LSTM model trained on the adding problem task (see Section 3.1). The average estimation error is computed over a batch of 128 samples of the test set. (a) and $\mathbf { ( b ) }$ show the evaluation of Eq. 1 and Eq. 3 respectively. The $\mathbf { X }$ -axis indicates the index of the step that compares with the final output $\mathbf { h } _ { T }$ or its previous step $\mathbf { h } _ { t - 1 }$ .
37
+
38
+ Fig. 1 shows an empirical observation of the IE in the adding problem (experimental details in Section 3.1). Here, we use the Average Estimation Error (AEE) measure (Greff et al., 2016) to quantify the expectation of the difference between two hidden activations. The measured AEEs in Fig. 1 are close to 0 indicating that the LSTM model fulfills the view of IE. The results also suggest that the network learns an identity mapping since the activation levels are similar on average across all recurrent updates. In the next section, we shall show that the use of gates in GNNs encourages the network to learn an identity mapping and whether this analysis can be extended to plain recurrent networks.
39
+
40
+ # 2.2 ANALYSIS OF GNNS
41
+
42
+ Popular GNNs such as LSTM, GRU; and recent variants such as the Phased-LSTM (Neil et al., 2016), and Intersection RNN (Collins et al., 2017), share the same dual gate design following:
43
+
44
+ $$
45
+ \mathbf h _ { t } = \mathbf H _ { t } \odot \mathbf T _ { t } + \mathbf h _ { t - 1 } \odot \mathbf C _ { t }
46
+ $$
47
+
48
+ where $t \in [ 1 , T ]$ , $\mathbf H _ { t } = \sigma ( \mathbf x _ { t } , \mathbf h _ { t - 1 } )$ represents the hidden transformation, $\mathbf T _ { t } = \tau ( \mathbf x _ { t } , \mathbf h _ { t - 1 } )$ is the transform gate, and $\mathbf { C } _ { t } = \phi ( \mathbf { x } _ { t } , \mathbf { h } _ { t - 1 } )$ is the carry gate. $\sigma , \tau$ and $\phi$ are recurrent layers that have their trainable parameters and activation functions. $\odot$ represents element-wise product operator. Note that $\mathbf { h } _ { t }$ may not be the output activation at the recurrent step $t$ . For example in LSTM, $\mathbf { h } _ { t }$ represents the memory cell state. Typically, the elements of transform gate $\mathbf { T } _ { t , k }$ and carry gate $\mathbf { C } _ { t , k }$ are between 0 (close) and 1 (open), the value indicates the openness of the gate at the $k$ th neuron. Hence, a plain recurrent network is a subcase of Eq. 4 when $\mathbf { T } _ { t } = \mathbf { 1 }$ and $\mathbf { C } _ { t } = \mathbf { 0 }$ .
49
+
50
+ Note that conventionally, the initial hidden activation $\mathbf { h } _ { 0 }$ is 0 to represent a “void state” at the start of computation. For $\mathbf { h } _ { 0 }$ to fit into Eq. 4’s framework, we define an auxiliary state $\mathbf { h } _ { - 1 }$ as the previous state of $\mathbf { h } _ { 0 }$ , and $\mathbf { T } _ { 0 } = \mathbf { 1 }$ , $\mathbf { C } _ { 0 } = \mathbf { 0 }$ . We also define another auxiliary state ${ \bf h } _ { T + 1 } = { \bf h } _ { T }$ , $\mathbf { T } _ { T + 1 } = \mathbf { 0 }$ , and ${ \bf C } _ { T + 1 } = { \bf 1 }$ as the succeeding state of $\mathbf { h } _ { T }$ .
51
+
52
+ Based on the recursive definition in Eq. 4, we can write the final layer output $\mathbf { h } _ { T }$ as follows:
53
+
54
+ $$
55
+ \mathbf { h } _ { T } = \mathbf { h } _ { 0 } \odot \prod _ { t = 1 } ^ { T } \mathbf { C } _ { t } + \sum _ { t = 1 } ^ { T } \left( \mathbf { H } _ { t } \odot \mathbf { T } _ { t } \odot \prod _ { i = t + 1 } ^ { T + 1 } \mathbf { C } _ { i } \right)
56
+ $$
57
+
58
+ where we use $\prod$ to represent element-wise multiplication over a series of terms.
59
+
60
+ According to Eq. 3, and supposing that Eq. 5 fulfills the Eq. 1, we can use a zero-mean residual $\epsilon _ { t }$ for describing the difference between the outputs of recurrent steps:
61
+
62
+ $$
63
+ \begin{array} { c } { \mathbf { h } _ { t } - \mathbf { h } _ { t - 1 } = \pmb { \epsilon } _ { t } } \\ { \mathbf { \epsilon } _ { \mathbf { \epsilon } _ { 0 } } = \mathbf { 0 } } \end{array}
64
+ $$
65
+
66
+ Plugging Eq. 6 into Eq. 5, we get
67
+
68
+ $$
69
+ { \bf h } _ { T } = { \bf h } _ { 0 } + \lambda
70
+ $$
71
+
72
+ where
73
+
74
+ $$
75
+ \lambda = \sum _ { t = 1 } ^ { T } \lambda _ { t } = \sum _ { t = 1 } ^ { T } \left( \left( \sum _ { i = 1 } ^ { t } \epsilon _ { i } \right) \odot \prod _ { j = t + 1 } ^ { T + 1 } \mathbf { C } _ { j } - \left( \sum _ { i = 0 } ^ { t - 1 } \epsilon _ { i } \right) \odot \prod _ { j = t } ^ { T } \mathbf { C } _ { j } \right)
76
+ $$
77
+
78
+ The complete deduction of Eqs. 8–9 is presented in Appendix A. Eq. 8 performs an identity mapping when the carry gate $\mathbf { C } _ { t }$ is always open. In Eq. 9, the term $\textstyle \sum _ { i = 1 } ^ { t } \epsilon _ { i }$ represents “a level of representation that is formed between $\mathbf { h } _ { 1 }$ and $\mathbf { h } _ { t } \mathbf { \Psi } ^ { \mathsf { N } }$ . Moreover, the term $\textstyle \prod _ { j = t } ^ { T } \mathbf { C } _ { j }$ extract the “useful” part of this representation and contribute to the final representation of the recurrent layer. Here, we interpret “useful” as any quantity that helps in minimizing the cost function. Therefore, the contribution, $\lambda _ { t }$ , at each recurrent step, quantifies the representation that is learned in the step $t$ . Furthermore, it is generally believed that a GNN manages and maintains the latent state through the carry gate, such as the forget gate in LSTM. If the carry gate is closed, then it is impossible for the old state to be preserved while undergoing recurrent updates. However, if we set $\mathbf { C } _ { t } = \mathbf { 0 }$ , $t \in [ 1 , T ]$ in Eq. 9, we get:
79
+
80
+ $$
81
+ { \mathbf { h } } _ { T } = { \mathbf { h } } _ { 0 } + \sum _ { t = 1 } ^ { T } \epsilon _ { t }
82
+ $$
83
+
84
+ If $\mathbf { h } _ { 0 } = \mathbf { 0 }$ (void state at the start), we can turn Eq. 10 into:
85
+
86
+ $$
87
+ { \mathbf h } _ { T } = { \mathbf \epsilon } _ { 1 } + \sum _ { t = 2 } ^ { T } { \boldsymbol { \epsilon } } _ { t } = { \mathbf h } _ { 1 } + \sum _ { t = 2 } ^ { T } { \boldsymbol { \epsilon } } _ { t }
88
+ $$
89
+
90
+ Eq. 11 shows that the state can be preserved without the help of the carry gate. This result indicates that it is possible for a plain recurrent network to learn an identity mapping as well.
91
+
92
+ # 2.3 RECURRENT IDENTITY NETWORKS
93
+
94
+ Motivated by the previous iterative estimation interpretation of RNNs, we formulate a novel plain recurrent network variant — Recurrent Identity Network (RIN):
95
+
96
+ $$
97
+ \begin{array} { r l } & { \mathbf { h } _ { t } = \mathrm { R e L U } \left( \mathbf { W } \mathbf { x } _ { t } + \mathbf { U } \mathbf { h } _ { t - 1 } + \mathbf { h } _ { t - 1 } + \mathbf { b } \right) } \\ & { \quad = \mathrm { R e L U } \left( \mathbf { W } \mathbf { x } _ { t } + ( \mathbf { U } + \mathbf { I } ) \mathbf { h } _ { t - 1 } + \mathbf { b } \right) } \end{array}
98
+ $$
99
+
100
+ where W is the input-to-hidden weight matrix, U is the hidden-to-hidden weight matrix, and I is a non-trainable identity matrix that acts as a “surrogate memory” component. This formulation encourages the network to preserve a copy of the last state by embedding I into the hidden-tohidden weights. This “surrogate memory” component maintains the representation encoded in the past recurrent steps.
101
+
102
+ # 3 RESULTS
103
+
104
+ In this section, we compare the performances of the RIN, IRNN, and LSTM in a set of tasks that require modeling long-range dependencies.
105
+
106
+ # 3.1 THE ADDING PROBLEM
107
+
108
+ The adding problem is a standard task for examining the capability of RNNs for modeling longrange dependencies (Hochreiter & Schmidhuber, 1997). In this task, two numbers are randomly selected from a long sequence. The network has to predict the sum of these two numbers. The task becomes challenging as the length of the sequence $T$ increases because the relevant numbers can be far from each other in a long sequence. We report experimental results from three datasets that have sequence lengths of $T _ { 1 } = 2 0 0$ , $T _ { 2 } = 3 0 0$ , and $T _ { 3 } = 4 0 0$ respectively. Each dataset has 100,000 training samples and 10,000 testing samples. Each sequence of a dataset has $T _ { i }$ numbers that are randomly sampled from a uniform distribution in $[ 0 , 1 ]$ . Each sequence is accompanied by a mask that indicates the two chosen random positions.
109
+
110
+ ![](images/b4265b1bcd22abc502e23a7ad248890ca6f669652c137bf5d0a83e6ffc4156f8.jpg)
111
+ Figure 2: Mean Squared Error (MSE) plots during the testing phase of the adding problem task for different sequence lengths. The errors are presented in log scale. LSTM performs the worst in all three tasks. RIN and IRNN models are comparable in (a) and (b), and (c).
112
+
113
+ We compare the performance between RINs, IRNNs, and LSTMs using the same experimental settings. Each network has one hidden layer with 100 hidden units. Note that a LSTM has four times more parameters than corresponding RIN and IRNN models. The optimizer minimizes the Mean Squared Error (MSE) between the target sum and the predicted sum. We initially used the RMSprop (Tieleman & Hinton, 2012) optimizer. However, some IRNN models failed to converge using this optimizer. Therefore, we chose the Adam optimizer (Kingma & Ba, 2014) so a fair comparison can be made between the different networks. The batch size is 32. Gradient clipping value for all models is 100. The models are trained with maximum 300 epochs until they converged. The initial learning rates are different between the datasets because we found that IRNNs are sensitive to the initial learning rate as the sequence length increases. The learning rates $\alpha _ { 2 0 0 } = 1 0 ^ { - 4 }$ , $\alpha _ { 3 0 0 } = 1 0 ^ { - 5 }$ and $\alpha _ { 4 0 0 } = \mathrm { i } 0 ^ { - 6 }$ are applied to $T _ { 1 }$ , $T _ { 2 }$ and $T _ { 3 }$ correspondingly. The input-to-hidden weights of RINs and IRNNs and hidden-to-hidden weights of RINs are initialized using a similar method to Le et al. (2015) where the weights are drawn from a Gaussian distribution $\mathcal { N } ( 0 , 1 0 ^ { - 3 } )$ . The LSTM is initialized with the settings where the input-to-hidden weights use Glorot Uniform (Glorot & Bengio, 2010) and hidden-to-hidden weights use an orthogonal matrix as suggested by Saxe et al.
114
+
115
+ (2013). Bias values for all networks are initialized to 0. No explicit regularization is employed. We do not perform an exhaustive hyperparameter search in these experiments.
116
+
117
+ The baseline MSE of the task is 0.167. This score is achieved by predicting the sum of two numbers as 1 regardless of the input sequence. Fig. 2 shows MSE plots for different test datasets. RINs and IRNNs reached the same level of performance in all experiments, and LSTMs performed the worst. Notably, LSTM fails to converge in the dataset with $T _ { 3 } = 4 0 0$ . The use of ReLU in RINs and IRNNs causes some degree of instability in the training phase. However, in most cases, RINs converge faster and are more stable than IRNNs (see training loss plots in Fig. 5 of Appendix B). Note that because IRNNs are sensitive to the initial learning rate, applying high learning rates such as $\alpha = 1 0 ^ { - 3 }$ for $T _ { 2 }$ and $T _ { 3 }$ could cause the training of the network to fail.
118
+
119
+ # 3.2 SEQUENTIAL AND PERMUTED MNIST
120
+
121
+ Sequential and Permuted MNIST are introduced by Le et al. (2015) for evaluating RNNs. Sequential MNIST presents each pixel of the MNIST handwritten image (Lecun et al., 1998) to the network sequentially (e.g., from the top left corner of the image to the bottom right corner of the image). After the network has seen all $2 8 \times 2 8 = 7 8 4$ pixels, the network produces the class of the image. This task requires the network to model a very long sequence that has 784 steps. Permuted MNIST is an even harder task than the Sequential MNIST in that a fixed random index permutation is applied to all images. This random permutation breaks the association between adjacent pixels. The network is expected to find the hidden relations between pixels so that it can correctly classify the image.
122
+
123
+ All networks are trained with the RMSprop optimizer (Tieleman & Hinton, 2012) and a batch size of 128. The networks are trained with maximum 500 epochs until they are converged. The initial learning rate is set to $\alpha = 1 0 ^ { - 6 }$ . Weight initialization follows the same setup as Section 3.1. No explicit regularization is added.
124
+
125
+ Table 1 summarizes the accuracy performance of the networks on the Sequential and Permuted MNIST datasets. For small network sizes (1–100, 1–200), RINs outperform IRNNs in their accuracy performance. For bigger networks, RINs and IRNNs achieve similar performance; however, RINs converge much faster than IRNNs in the early stage of training (see Fig. 3). LSTMs perform the worst on both tasks in terms of both convergence speed and final accuracy. Appendix C presents the full experimental results.
126
+
127
+ To investigate the limit of RINs, we adopted the concept of Deep Transition (DT) Networks (Pascanu et al., 2013) for increasing the implicit network depth. In this extended RIN model called RINDT, each recurrent step performs two hidden transitions instead of one (the formulation is given in Appendix D). The network modification increases the inherent depth by a factor of two. The results showed that the error signal could survive $7 8 4 \times 2 = 1 5 6 8$ computation steps in RIN-DTs.
128
+
129
+ In Fig. 4, we show the evidence of learning identity mapping empirically by collecting the hidden activation from all recurrent steps and evaluating Eqs. 1 and 3. The network matches the IE when AEE is close to zero. We also compute the variance of the difference between two recurrent steps. Fig. 4(a) suggests that all networks bound the variance across recurrent steps. Fig. 4(b) offers a closer perspective where it measures the AEE between two adjacent steps. The levels of activations for all networks are always kept the same on an average, which is an evidence of learning identity mapping. We also observed that the magnitude of the variance becomes significantly larger at the last 200 steps in IRNN and RIN. Repeated application of ReLU may cause this effect during recurrent update (Jastrzebski et al., 2017). Other experiments in this section exhibit similar behaviors, complete results are shown in Appendix C (Fig. 8–12). Note that this empirical analysis only demonstrates that the tested RNNs have the evidence of learning identity mapping across recurrent updates as RINs and IRNNs largely fulfill the view of IE. We do not over-explain the relationship between this analysis and the performance of the network.
130
+
131
+ Table 1: Accuracies of RINs, IRNNs and LSTM on Sequential and Permuted MNIST. The network type is represented by No. layers-No. units, e.g., 3–100 means that the network has 3 layers and each layer has 100 hidden units. The LSTM results matches with Le et al. (2015)
132
+
133
+ <table><tr><td>Network Type</td><td colspan="3">Sequential MNIST</td><td colspan="3">Permuted MNIST</td></tr><tr><td></td><td>RIN</td><td>IRNN</td><td>LSTM</td><td>RIN</td><td>IRNN</td><td>LSTM</td></tr><tr><td>1-100</td><td>91.64%</td><td>83.55%</td><td>24.10%</td><td>78.89%</td><td>62.11%</td><td>28.49%</td></tr><tr><td>1-200</td><td>94.60%</td><td>92.86%</td><td>47.13%</td><td>85.03%</td><td>73.73%</td><td>30.63%</td></tr><tr><td>2-100</td><td>93.69%</td><td>92.15%</td><td>39.50%</td><td>83.37%</td><td>76.31%</td><td>41.31%</td></tr><tr><td>2-200</td><td>94.82%</td><td>94.78%</td><td>22.27%</td><td>85.31%</td><td>83.78%</td><td>55.44%</td></tr><tr><td>3-100</td><td>94.15%</td><td>94.03%</td><td>54.98%</td><td>84.15%</td><td>78.78%</td><td>38.61%</td></tr><tr><td>3-200</td><td>95.19%</td><td>95.05%</td><td>61.20%</td><td>83.41%</td><td>84.24%</td><td>53.29%</td></tr><tr><td></td><td>RIN-DT</td><td></td><td></td><td>RIN-DT</td><td></td><td></td></tr><tr><td>1-100</td><td>95.41%</td><td></td><td></td><td>86.23%</td><td></td><td></td></tr></table>
134
+
135
+ ![](images/ce393191984108625006c43ca6cc5336f1f42d211707cd3e8df80cf4c81daaf2.jpg)
136
+ Figure 3: Results for network type 1–200. (a) and (b) show the loss and accuracy curves on Sequential MNIST; (c) and (d) present the loss and accuracy curves on Permuted MNIST. RINs and RIN-DTs converge much faster than IRNNs and LSTMs in the early stage of training (first 100 epochs) and achieve a better final accuracy.
137
+
138
+ ![](images/9529610afea9893a0b23e428d1f76115e71d3b140707b5ca5131fb73d99dc937.jpg)
139
+ Figure 4: Evidence of learning identity mapping in RIN, IRNN and LSTM for network type 1–200 over a batch of 128 samples. (a) evaluates Eq. 1 and $\mathbf { ( b ) }$ evaluates Eq. 3. The $\mathbf { X }$ -axis indicates the index of the step that compares with the final output $\mathbf { h } _ { T }$ or its previous step $\mathbf { h } _ { t - 1 }$ , and $_ \textrm { y }$ -axis represents the average estimation error (AEE).
140
+
141
+ # 3.3 BABI QUESTION ANSWERING TASKS
142
+
143
+ The bAbI dataset provides 20 question answering tasks that measure the understanding of language and the performance of reasoning in neural networks (Weston et al., 2015). Each task consists of 1,000 training samples and 1,000 test samples. A sample consists of three parts: a list of statements, a question and an answer (examples in Table 2). The answer to the question can be inferred from the statements that are logically organized together.
144
+
145
+ Table 2: Examples of bAbI tasks.
146
+
147
+ <table><tr><td>Statements: Mary went to the office. Then she journeyed to the garden.</td><td>Statements:</td><td>The red square is below the blue square. The red square is to the left of the pink rectangle.</td></tr><tr><td>Question: Answer:</td><td>Where is Mary? Garden.</td><td>Question: Answer:</td><td>Is the blue square below the pink rectangle? No.</td></tr></table>
148
+
149
+ We compare the performance of the RIN, IRNN, and LSTM on these tasks. All networks follow a network design where the network firstly embeds each word into a vector of 200 dimensions. The statements are then appended together to a single sequence and encoded by a recurrent layer while another recurrent layer encodes the question sequence. The outputs of these two recurrent layers are concatenated together, and this concatenated sequence is then passed to a different recurrent layer for decoding the answer. Finally, the network predicts the answer via a softmax layer. The recurrent layers in all networks have 100 hidden units. This network design roughly follows the architecture presented in Jing et al. (2017). The initial learning rates are set to $\alpha = 1 0 ^ { - 3 }$ for RINs and LSTMs and $\alpha = 1 0 ^ { - 4 }$ for IRNNs because IRNNs fail to converge with a higher learning rate on many tasks. We chose the Adam optimizer over the RMSprop optimizer because of the same reasons as in the adding problem. The batch size is 32. Each network is trained for maximum 100 epochs until the network converges. The recurrent layers in the network follow the same initialization steps as in Section 3.1.
150
+
151
+ The results in Table 3 show that RINs can reach mean performance similar to the state-of-theart performance reported in Jing et al. (2017). As discussed in Section 3.1, the use of ReLU as the activation function can lead to instability during training of IRNN for tasks that have lengthy statements (e.g.. 3-Three Supporting Facts, 5-Three Arg. Relations).
152
+
153
+ Table 3: Test accuracy $( \% )$ of 20 bAbI Question Answering Tasks.
154
+
155
+ <table><tr><td>Task</td><td>RIN</td><td>IRNN</td><td>LSTM</td><td>Jing et al. (2017)</td><td>Weston et al. (2015)</td></tr><tr><td>1: Single Supporting Fact</td><td>51.9</td><td>48.4</td><td>50.3</td><td>48.2</td><td>50</td></tr><tr><td>2: Two Supporting Facts</td><td>18.7</td><td>18.7</td><td>19</td><td>15.8</td><td>20</td></tr><tr><td>3: Three Supporting Facts</td><td>18.5</td><td>15.3</td><td>22.9</td><td>19.1</td><td>20</td></tr><tr><td>4: Two Arg.Relations</td><td>71.2</td><td>72.6</td><td>71.6</td><td>75.8</td><td>61</td></tr><tr><td>5: Three Arg. Relations</td><td>16.4</td><td>18.9</td><td>36.4</td><td>33.7</td><td>70</td></tr><tr><td>6:Yes/No Questions</td><td>50.3</td><td>50.3</td><td>52.3</td><td>49</td><td>48</td></tr><tr><td>7: Counting</td><td>48.8</td><td>48.8</td><td>48.9</td><td>48</td><td>49</td></tr><tr><td>8:Lists/Sets</td><td>33.6</td><td>33.6</td><td>33.6</td><td>33.6</td><td>45</td></tr><tr><td>9: Simple Negation</td><td>64.6</td><td>64.7</td><td>63.8</td><td>63.2</td><td>64</td></tr><tr><td>10: Indefinite Knowledge</td><td>45.1</td><td>43.7</td><td>45.1</td><td>43.9</td><td>44</td></tr><tr><td>11:Basic Coreference</td><td>71.6</td><td>67.8</td><td>78.4</td><td>68.8</td><td>72</td></tr><tr><td>12:Conjunction</td><td>70.6</td><td>71.4</td><td>75.3</td><td>73</td><td>74</td></tr><tr><td>13: Compound Coref.</td><td>94.4</td><td>94.2</td><td>94.4</td><td>93.9</td><td>94</td></tr><tr><td>14:Time Reasoning</td><td>36.7</td><td>17.6</td><td>23.2</td><td>19.7</td><td>27</td></tr><tr><td>15:Basic Deduction</td><td>54.8</td><td>54.1</td><td>26.7</td><td>54.9</td><td>21</td></tr><tr><td>16:Basic Induction</td><td>48.8</td><td>49</td><td>25.8</td><td>46.6</td><td>23</td></tr><tr><td>17: Positional Reasoning</td><td>53.9</td><td>53.4</td><td>52</td><td>60.5</td><td>51</td></tr><tr><td>18:Size Reasoning</td><td>92.6</td><td>46.9</td><td>93</td><td>91.3</td><td>52</td></tr><tr><td>19: Path Finding</td><td>10.5</td><td>10.9</td><td>9.9</td><td>10</td><td>8</td></tr><tr><td>20:Agent’s Motivations</td><td>98</td><td>98.2</td><td>97.3</td><td>97.4</td><td>91</td></tr><tr><td>Mean Performance</td><td>52.6</td><td>48.9</td><td>51.0</td><td>52.3</td><td>49.2</td></tr></table>
156
+
157
+ # 4 DISCUSSION
158
+
159
+ In this paper, we discussed the iterative representation refinement in RNNs and how this viewpoint could help in learning identity mapping. Under this observation, we demonstrated that the contribution of each recurrent step a GNN can be jointly determined by the representation that is formed up to the current step, and the openness of the carry gate in later recurrent updates. Note in Eq. 9, the element-wise multiplication of $\mathbf { C } _ { t } \mathbf { s }$ selects the encoded representation that could arrive at the output of the layer. Thus, it is possible to embed a special function in $\mathbf { C } _ { t } \mathbf { s }$ so that they are sensitive to certain pattern of interests. For example, in Phased LSTM, the time gate is inherently interested in temporal frequency selection (Neil et al., 2016).
160
+
161
+ Motivated by the analysis presented in Section 2, we propose a novel plain recurrent network variant, the Recurrent Identity Network (RIN), that can model long-range dependencies without the use of gates. Compared to the conventional formulation of plain RNNs, the formulation of RINs only adds a set of non-trainable weights to represent a “surrogate memory” component so that the learned representation can be maintained across two recurrent steps.
162
+
163
+ Experimental results in Section 3 show that RINs are competitive against other network models such as IRNNs and LSTMs. Particularly, small RINs produce $12 \% { - } 6 7 \%$ higher accuracy in the Sequential and Permuted MNIST. Furthermore, RINs demonstrated much faster convergence speed in early phase of training, which is a desirable advantage for platforms with limited computing resources. RINs work well without advanced methods of weight initializations and are relatively insensitive to hyperparameters such as learning rate, batch size, and selection of optimizer. This property can be very helpful when the time available for choosing hyperparameters is limited. Note that we do not claim that RINs outperform LSTMs in general because LSTMs may achieve comparable performance with finely-tuned hyperparameters.
164
+
165
+ The use of ReLU in RNNs might be counterintuitive at first sight because the repeated application of this activation is more likely causing gradient explosion than conventional choices of activation function, such as hyperbolic tangent (tanh) function or sigmoid function. Although the proposed IRNN (Le et al., 2015) reduces the problem by the identity initialization, in our experiments, we usually found that IRNN is more sensitive to training parameters and more unstable than RINs and LSTMs. On the contrary, feedforward models that use ReLU usually produce better results and converge faster than FFNs that use the tanh or sigmoid activation function. In this paper, we provide a promising method of using ReLU in RNNs so that the network is less sensitive to the training conditions. The experimental results also support the argument that the use of ReLU significantly speeds up the convergence.
166
+
167
+ During the development of this paper, a recent independent work (Zagoruyko & Komodakis, 2017) presented a similar network formulation with a focus on training of deep plain FFNs without skip connections. DiracNet uses the idea of ResNets where it assumes that the identity initialization can replace the role of the skip-connection in ResNets. DiracNet employed a particular kind of activation function — negative concatenated ReLU (NCReLU), and this activation function allows the layer output to approximate the layer input when the expectation of the weights are close to zero. In this paper, we showed that an RNN can be trained without the use of gates or special activation functions, which complements the findings and provides theoretical basis in Zagoruyko & Komodakis (2017).
168
+
169
+ We hope to see more empirical and theoretical insights that explains the effectiveness of the RIN by simply embedding a non-trainable identity matrix. In future, we will investigate the reasons for the faster convergence speed of the RIN during training. Furthermore, we will investigate why RIN can be trained stably with the repeated application of ReLU and why it is less sensitive to training parameters than the two other models.
170
+
171
+ # REFERENCES
172
+
173
+ Kyunghyun Cho, Bart van Merrienboer, C¸ aglar Gulc¸ehre, Fethi Bougares, Holger Schwenk, and ¨ Yoshua Bengio. Learning phrase representations using RNN encoder-decoder for statistical machine translation. CoRR, abs/1406.1078, 2014.
174
+
175
+ Junyoung Chung, C¸ aglar Gulc¸ehre, KyungHyun Cho, and Yoshua Bengio. Empirical evaluation of ¨ gated recurrent neural networks on sequence modeling. CoRR, abs/1412.3555, 2014.
176
+
177
+ Jasmine Collins, Jascha Sohl-Dickstein, and David Sussillo. Capacity and trainability in recurrent neural networks. In 5th International Conference on Learning Representations, Palais des Congres Neptune, Toulon, France, 2017. \`
178
+
179
+ Xavier Glorot and Yoshua Bengio. Understanding the difficulty of training deep feedforward neural networks. In Yee Whye Teh and Mike Titterington (eds.), Proceedings of the Thirteenth International Conference on Artificial Intelligence and Statistics, volume 9 of Proceedings of Machine Learning Research, pp. 249–256, Chia Laguna Resort, Sardinia, Italy, 13–15 May 2010. PMLR.
180
+
181
+ Klaus Greff, Rupesh Kumar Srivastava, and Jurgen Schmidhuber. Highway and residual networks ¨ learn unrolled iterative estimation. CoRR, abs/1612.07771, 2016.
182
+
183
+ Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. Deep residual learning for image recognition. CoRR, abs/1512.03385, 2015.
184
+
185
+ Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. Identity Mappings in Deep Residual Networks, pp. 630–645. Springer International Publishing, Cham, 2016. ISBN 978-3-319-46493- 0.
186
+
187
+ Geoffrey E. Hinton, Simon Osindero, and Yee-Whye Teh. A fast learning algorithm for deep belief nets. Neural Comput., 18(7):1527–1554, July 2006. ISSN 0899-7667.
188
+
189
+ Sepp Hochreiter and Jurgen Schmidhuber. Long short-term memory. ¨ Neural Computation, 9(8): 1735–1780, November 1997. ISSN 0899-7667.
190
+
191
+ S. Jastrzebski, D. Arpit, N. Ballas, V. Verma, T. Che, and Y. Bengio. Residual Connections Encourage Iterative Inference. CoRR, abs/1710.04773, October 2017.
192
+
193
+ Li Jing, Yichen Shen, Tena Dubcek, John Peurifoy, Scott A. Skirlo, Max Tegmark, and Marin Soljacic. Tunable efficient unitary neural networks (EUNN) and their application to RNN. CoRR, abs/1612.05231, 2016.
194
+
195
+ Li Jing, Cagla Gulcehre, John Peurifoy, Yichen Shen, Max Tegmark, Marin Soljaciˇ c, and Yoshua ´ Bengio. Gated Orthogonal Recurrent Units: On Learning to Forget. CoRR, abs/1706.02761, 2017.
196
+
197
+ Diederik P. Kingma and Jimmy Ba. Adam: A method for stochastic optimization. In Proceedings of the 3rd International Conference on Learning Representations (ICLR), 2014.
198
+
199
+ Quoc V. Le, Navdeep Jaitly, and Geoffrey E. Hinton. A simple way to initialize recurrent networks of rectified linear units. CoRR, abs/1504.00941, 2015.
200
+
201
+ Yann Lecun, Leon Bottou, Yoshua Bengio, and Patrick Haffner. Gradient-based learning applied to ´ document recognition. Proceedings of the IEEE, 86(11):2278–2324, Nov 1998. ISSN 0018-9219. doi: 10.1109/5.726791.
202
+
203
+ James Martens and Ilya Sutskever. Learning recurrent neural networks with hessian-free optimization. In Proceedings of the 28th International Conference on Machine Learning, ICML 2011, Bellevue, Washington, USA, June 28 - July 2, 2011, pp. 1033–1040, 2011.
204
+
205
+ Dmytro Mishkin and Jiri Matas. All you need is a good init. CoRR, abs/1511.06422, 2015.
206
+
207
+ Daniel Neil, Michael Pfeiffer, and Shih-Chii Liu. Phased lstm: Accelerating recurrent network training for long or event-based sequences. In D. D. Lee, M. Sugiyama, U. V. Luxburg, I. Guyon, and R. Garnett (eds.), Advances in Neural Information Processing Systems 29, pp. 3882–3890. Curran Associates, Inc., 2016.
208
+
209
+ Razvan Pascanu, C¸ aglar Gulc¸ehre, Kyunghyun Cho, and Yoshua Bengio. How to construct deep ¨ recurrent neural networks. CoRR, abs/1312.6026, 2013.
210
+
211
+ Andrew M. Saxe, James L. McClelland, and Surya Ganguli. Exact solutions to the nonlinear dynamics of learning in deep linear neural networks. CoRR, abs/1312.6120, 2013.
212
+
213
+ Jurgen Schmidhuber. Learning complex, extended sequences using the principle of history com-¨ pression. Neural Computation, 4(2):234–242, March 1992. ISSN 0899-7667.
214
+
215
+ Rupesh K Srivastava, Klaus Greff, and Juergen Schmidhuber. Training very deep networks. In C. Cortes, N. D. Lawrence, D. D. Lee, M. Sugiyama, and R. Garnett (eds.), Advances in Neural Information Processing Systems 28, pp. 2377–2385. Curran Associates, Inc., 2015.
216
+
217
+ Tijmen Tieleman and Geoffrey Hinton. Lecture 6.5—RmsProp: Divide the gradient by a running average of its recent magnitude. COURSERA: Neural Networks for Machine Learning, 2012.
218
+
219
+ Andreas Veit, Michael J. Wilber, and Serge J. Belongie. Residual networks are exponential ensembles of relatively shallow networks. CoRR, abs/1605.06431, 2016.
220
+
221
+ Pascal Vincent, Hugo Larochelle, Yoshua Bengio, and Pierre-Antoine Manzagol. Extracting and composing robust features with denoising autoencoders. In Proceedings of the 25th International Conference on Machine Learning, ICML ’08, pp. 1096–1103, New York, NY, USA, 2008. ACM. ISBN 978-1-60558-205-4.
222
+
223
+ Jason Weston, Antoine Bordes, Sumit Chopra, and Tomas Mikolov. Towards ai-complete question answering: A set of prerequisite toy tasks. CoRR, abs/1502.05698, 2015.
224
+
225
+ Di Xie, Jiang Xiong, and Shiliang Pu. All you need is beyond a good init: Exploring better solution for training extremely deep convolutional neural networks with orthonormality and modulation. CoRR, abs/1703.01827, 2017.
226
+
227
+ Sergey Zagoruyko and Nikos Komodakis. DiracNets: Training Very Deep Neural Networks Without Skip-Connections. CoRR, abs/1706.00388, 2017.
228
+
229
+ # A ALGEBRA OF EQS. 8–9
230
+
231
+ Popular GNNs such as LSTM, GRU; and recent variants such as the Phased-LSTM (Neil et al., 2016), and Intersection RNN (Collins et al., 2017), share the same dual gate design described as follows:
232
+
233
+ $$
234
+ \mathbf h _ { t } = \mathbf H _ { t } \odot \mathbf T _ { t } + \mathbf h _ { t - 1 } \odot \mathbf C _ { t }
235
+ $$
236
+
237
+ where $t \in [ 1 , T ]$ , $\mathbf H _ { t } = \sigma ( \mathbf x _ { t } , \mathbf h _ { t - 1 } )$ represents the hidden transformation, $\mathbf T _ { t } = \tau ( \mathbf x _ { t } , \mathbf h _ { t - 1 } )$ is the transform gate, and $\mathbf { C } _ { t } = \phi ( \mathbf { x } _ { t } , \mathbf { h } _ { t - 1 } )$ is the carry gate. $\sigma , \tau$ and $\phi$ are recurrent layers that have their trainable parameters and activation functions. $\odot$ represents element-wise product operator. Note that $\mathbf { h } _ { t }$ may not be the output activation at the recurrent step $t$ . For example in LSTM, $\mathbf { h } _ { t }$ represents the memory cell state. Typically, the elements of transform gate $\mathbf { T } _ { t , k }$ and carry gate $\mathbf { C } _ { t , k }$ are between 0 (close) and 1 (open), the value indicates the openness of the gate at the $k$ th neuron. Hence, a plain recurrent network is a subcase of Eq. 14 when $\mathbf { T } _ { t } = \mathbf { 1 }$ and $\mathbf { C } _ { t } = \mathbf { 0 }$ .
238
+
239
+ Note that conventionally, the initial hidden activation $\mathbf { h } _ { 0 }$ is 0 to represent a “void state” at the start of computation. For $\mathbf { h } _ { 0 }$ to fit into Eq. 4’s framework, we define an auxiliary state $\mathbf { h } _ { - 1 }$ as the previous state of $\mathbf { h } _ { 0 }$ , and $\mathbf { T } _ { 0 } = \mathbf { 1 }$ , $\mathbf { C } _ { 0 } = \mathbf { 0 }$ . We also define another auxiliary state ${ \bf h } _ { T + 1 } = { \bf h } _ { T }$ , $\mathbf { T } _ { T + 1 } = \mathbf { 0 }$ , and ${ \bf C } _ { T + 1 } = { \bf 1 }$ as the succeeding state of $\mathbf { h } _ { T }$ .
240
+
241
+ Based on the recursive definition in Eq. 4, we can write the final layer output $\mathbf { h } _ { T }$ as follows:
242
+
243
+ $$
244
+ \mathbf { h } _ { T } = \mathbf { h } _ { 0 } \odot \prod _ { t = 1 } ^ { T } \mathbf { C } _ { t } + \sum _ { t = 1 } ^ { T } \left( \mathbf { H } _ { t } \odot \mathbf { T } _ { t } \odot \prod _ { i = t + 1 } ^ { T + 1 } \mathbf { C } _ { i } \right)
245
+ $$
246
+
247
+ where we use $\prod$ to represent element-wise multiplication over a series of terms.
248
+
249
+ According to Eq. 3, and supposing that Eq. 5 fulfills the Eq. 1, we can use a zero-mean residual $\epsilon _ { t }$ for describing the difference between the outputs of recurrent steps:
250
+
251
+ $$
252
+ \begin{array} { c } { \mathbf { h } _ { t } - \mathbf { h } _ { t - 1 } = \pmb { \epsilon } _ { t } } \\ { \mathbf { \epsilon } _ { \mathbf { \epsilon } _ { 0 } } = \mathbf { 0 } } \end{array}
253
+ $$
254
+
255
+ Then we can rewrite Eq. 16 as:
256
+
257
+ $$
258
+ \mathbf { H } _ { t } \odot \mathbf { T } _ { t } + \mathbf { h } _ { t - 1 } \odot \mathbf { C } _ { t } = \mathbf { h } _ { t - 1 } + \epsilon _ { t }
259
+ $$
260
+
261
+ Substituting Eq. 18 into Eq. 15:
262
+
263
+ $$
264
+ \begin{array} { r l } & { \mathbf { h } _ { T } = \mathbf { h } _ { 0 } \odot \displaystyle \prod _ { t = 1 } ^ { T } \mathbf { C } _ { t } + \sum _ { t = 1 } ^ { T } \left( \left( \left( 1 - \mathbf { C } _ { t } \right) \odot \mathbf { h } _ { t - 1 } + \boldsymbol { \epsilon } _ { t } \right) \odot \prod _ { j = t + 1 } ^ { T + 1 } \mathbf { C } _ { j } \right) } \\ & { \mathbf { \Theta } = \mathbf { h } _ { 0 } \odot \displaystyle \prod _ { t = 1 } ^ { T } \mathbf { C } _ { t } + \sum _ { t = 1 } ^ { T } \left( \left( \left( 1 - \mathbf { C } _ { t } \right) \odot \left( \mathbf { h } _ { 0 } + \sum _ { i = 1 } ^ { t - 1 } \boldsymbol { \epsilon } _ { i } \right) + \boldsymbol { \epsilon } _ { t } \right) \odot \prod _ { j = t + 1 } ^ { T + 1 } \mathbf { C } _ { j } \right) } \end{array}
265
+ $$
266
+
267
+ We can rearrange Eqn. 20 to
268
+
269
+ $$
270
+ \begin{array} { l } { { \displaystyle { \bf h } _ { T } = { \bf h } _ { 0 } \odot \left( \sum _ { t = 0 } ^ { T } ( { \bf 1 } - { \bf C } _ { t } ) \prod _ { i = t + 1 } ^ { T + 1 } { \bf C } _ { i } \right) + \lambda } \ ~ } \\ { { \displaystyle ~ = { \bf h } _ { 0 } \odot \left( { \bf C } _ { T + 1 } - \prod _ { t = 0 } ^ { T + 1 } { \bf C } _ { t } \right) + \lambda } \ ~ } \\ { { \displaystyle ~ = { \bf h } _ { 0 } + \lambda } \ ~ } \end{array}
271
+ $$
272
+
273
+ where
274
+
275
+ $$
276
+ \lambda = \sum _ { t = 1 } ^ { T } \lambda _ { t } = \sum _ { t = 1 } ^ { T } \left( \left( \left( \mathbf { 1 } - \mathbf { C } _ { t } \right) \odot \sum _ { i = 1 } ^ { t - 1 } \epsilon _ { i } + \epsilon _ { t } \right) \odot \prod _ { j = t + 1 } ^ { T + 1 } \mathbf { C } _ { j } \right)
277
+ $$
278
+
279
+ The term $\boldsymbol { \lambda }$ in Eq. 23 can be reorganized to,
280
+
281
+ $$
282
+ \begin{array} { l } { { \displaystyle \lambda = \sum _ { t = 1 } ^ { T } \lambda _ { t } = \sum _ { t = 1 } ^ { T } \left( \left( \left( \mathbf { 1 } - \mathbf { C } _ { t } \right) \odot \sum _ { i = 1 } ^ { t - 1 } \epsilon _ { i } + \epsilon _ { t } \right) \odot \prod _ { j = t + 1 } ^ { T + 1 } \mathbf { C } _ { j } \right) } } \\ { { \displaystyle ~ = \sum _ { t = 1 } ^ { T } \left( \left( \sum _ { i = 1 } ^ { t } \epsilon _ { i } - \mathbf { C } _ { t } \odot \sum _ { i = 0 } ^ { t - 1 } \epsilon _ { i } \right) \odot \prod _ { j = t + 1 } ^ { T + 1 } \mathbf { C } _ { j } \right) } } \\ { { \displaystyle ~ = \sum _ { t = 1 } ^ { T } \left( \sum _ { i = 1 } ^ { t } \epsilon _ { i } \odot \prod _ { j = t + 1 } ^ { T + 1 } \mathbf { C } _ { j } - \sum _ { i = 0 } ^ { t - 1 } \epsilon _ { i } \odot \prod _ { j = t } ^ { T } \mathbf { C } _ { j } \right) } } \end{array}
283
+ $$
284
+
285
+ # B DETAILS IN THE ADDING PROBLEM EXPERIMENTS
286
+
287
+ Fig. 5 presents the MSE plots during the training phase. As we discussed in Section 3.1, the choice of ReLU can occur some degree of instability during the training. Compared to RINs, IRNNs are much more unstable in $T _ { 3 } = 4 0 0$ .
288
+
289
+ ![](images/8c5d1d6089348c9e94fd491d62dc0b61947fad2f27dcc82e104927507ca7b5c6.jpg)
290
+ Figure 5: Mean Squared Error (MSE) plots for the adding problem with different sequence lengths at training phase. The figures are presented in log scale. All models are trained up to 300 epochs.
291
+
292
+ # C DETAILS IN SEQUENTIAL AND PERMUTED MNIST EXPERIMENTS
293
+
294
+ Fig. 6–7 show all training and testing curves for Sequential and Permuted MNIST experiments.
295
+ RINs and RIN-DTs converge much faster than IRNNs and LSTMs.
296
+
297
+ ![](images/20d94115c13df76adcee7abf908a563310a0c1bdc2b8a0d1abb2bb2883b32ec7.jpg)
298
+ Figure 6: (a) and (b) show the training loss and accuracy plots for Sequential MNIST; (c) and (d) present training loss and accuracy plots for Permuted MNIST. We use blue color palette to represent RIN experiments, orange color palette to represent IRNN experiments, purple color palette to represent LSTM experiments and green color palette to represent RIN-DT experiments. RINs and RIN-DTs are much better than IRNNs and LSTMs in the early stage of training (first 200 epochs).
299
+
300
+ ![](images/f645842c3b09cce04a0589c05006910b68081f3cd473bd837292a05269b6682a.jpg)
301
+ Figure 7: (a) and (b) show the test loss and accuracy plots for Sequential MNIST; (c) and (d) present test loss and accuracy plots for Permuted MNIST.
302
+
303
+ ![](images/dc6e1b90fb320db9697eb1225a031764d767db0c1ad33ea72f33e4120988e1ed.jpg)
304
+ Fig. 8–12 show validation of the Iterative Estimation hypothesis in all network types.
305
+ Figure 8: Evidence of learning identity mapping in RIN, IRNN and LSTM for network type 1–100 over a batch of 128 samples. (a) evaluates Eq. 1 and (b) evaluates Eq. 3.
306
+
307
+ ![](images/241dfed27d728bbac4b7f87c080df4bf3b2a8126efd9dfaf889391c22b11c47c.jpg)
308
+ Figure 9: Evidence of learning identity mapping in RIN, IRNN and LSTM for network type 2–100 over a batch of 128 samples. (a) evaluates Eq. 1 and (b) evaluates Eq. 3.
309
+
310
+ ![](images/79b5650d9e9727ddb5a68d5a729a863babf0168b770a4becab5c0b78d77a0c61.jpg)
311
+ Figure 10: Evidence of learning identity mapping in RIN, IRNN and LSTM for network type 2–200 over a batch of 128 samples. (a) evaluates Eq. 1 and $\mathbf { ( b ) }$ evaluates Eq. 3.
312
+
313
+ ![](images/12930052951b63b10a67ac7fadb27fcbf018df19c8c3ede635f92cd0772c1238.jpg)
314
+ Figure 11: Evidence of learning identity mapping in RIN, IRNN and LSTM for network type 3–100 over a batch of 128 samples. (a) evaluates Eq. 1 and $\mathbf { ( b ) }$ evaluates Eq. 3.
315
+
316
+ ![](images/f46cee661148d3b0663fcaf916c349e00d5406b09841eba6dfafc689596fd99d.jpg)
317
+ Figure 12: Evidence of learning identity mapping in RIN, IRNN and LSTM for network type 3–200 over a batch of 128 samples. (a) evaluates Eq. 1 and $\mathbf { ( b ) }$ evaluates Eq. 3.
318
+
319
+ # D RINS WITH DEEP TRANSITIONS
320
+
321
+ In Section 3.2, we tested an additional model for RINs, which takes the concept of Deep Transition Networks (DTNs) Pascanu et al. (2013). Instead of stacking the recurrent layers, DTNs add multiple nonlinear transitions in a single recurrent step. This modification massively increases the depth of the network. In our RIN-DTs, the number of transition per recurrent step is two. Because the length of the sequence for Sequential and Permuted MNIST tasks is 784, RIN-DTs have the depth of $7 8 4 \times 2 = 1 5 6 8$ . The recurrent layer is defined in Eqs. 26–27.
322
+
323
+ $$
324
+ \begin{array} { r l } & { \hat { \mathbf { h } } _ { t } = f ( \mathbf { W } _ { 1 } \mathbf { x } _ { t } + ( \mathbf { U } _ { 1 } + \mathbf { I } ) \mathbf { h } _ { t - 1 } + \mathbf { b } _ { 1 } ) } \\ & { \mathbf { h } _ { t } = f ( ( \mathbf { U } _ { 2 } + \mathbf { I } ) \hat { \mathbf { h } } _ { t } + \mathbf { b } _ { 2 } ) } \end{array}
325
+ $$
parse/train/Hyp3i2xRb/Hyp3i2xRb_content_list.json ADDED
@@ -0,0 +1,1617 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [
2
+ {
3
+ "type": "text",
4
+ "text": "OVERCOMING THE VANISHING GRADIENT PROBLEM INPLAIN RECURRENT NETWORKS",
5
+ "text_level": 1,
6
+ "bbox": [
7
+ 176,
8
+ 101,
9
+ 823,
10
+ 146
11
+ ],
12
+ "page_idx": 0
13
+ },
14
+ {
15
+ "type": "text",
16
+ "text": "Anonymous authors Paper under double-blind review ",
17
+ "bbox": [
18
+ 183,
19
+ 171,
20
+ 398,
21
+ 198
22
+ ],
23
+ "page_idx": 0
24
+ },
25
+ {
26
+ "type": "text",
27
+ "text": "ABSTRACT ",
28
+ "text_level": 1,
29
+ "bbox": [
30
+ 454,
31
+ 234,
32
+ 544,
33
+ 251
34
+ ],
35
+ "page_idx": 0
36
+ },
37
+ {
38
+ "type": "text",
39
+ "text": "Plain recurrent networks greatly suffer from the vanishing gradient problem while Gated Neural Networks (GNNs) such as Long-short Term Memory (LSTM) and Gated Recurrent Unit (GRU) deliver promising results in many sequence learning tasks through sophisticated network designs. This paper shows how we can address this problem in a plain recurrent network by analyzing the gating mechanisms in GNNs. We propose a novel network called the Recurrent Identity Network (RIN) which allows a plain recurrent network to overcome the vanishing gradient problem while training very deep models without the use of gates. We compare this model with IRNNs and LSTMs on multiple sequence modeling benchmarks. The RINs demonstrate competitive performance and converge faster in all tasks. Notably, small RIN models produce $12 \\% { - } 6 7 \\%$ higher accuracy on the Sequential and Permuted MNIST datasets and reach state-of-the-art performance on the bAbI question answering dataset. ",
40
+ "bbox": [
41
+ 232,
42
+ 265,
43
+ 764,
44
+ 444
45
+ ],
46
+ "page_idx": 0
47
+ },
48
+ {
49
+ "type": "text",
50
+ "text": "1 INTRODUCTION ",
51
+ "text_level": 1,
52
+ "bbox": [
53
+ 176,
54
+ 468,
55
+ 336,
56
+ 484
57
+ ],
58
+ "page_idx": 0
59
+ },
60
+ {
61
+ "type": "text",
62
+ "text": "Numerous methods have been proposed for mitigating the vanishing gradient problem including the use of second-order optimization methods (e.g., Hessian-free optimization (Martens & Sutskever, 2011)), specific training schedules (e.g., Greedy Layer-wise training (Schmidhuber, 1992; Hinton et al., 2006; Vincent et al., 2008)), and special weight initialization methods when training on both plain FFNs and RNNs (Glorot & Bengio, 2010; Mishkin & Matas, 2015; Le et al., 2015; Jing et al., 2016; Xie et al., 2017; Jing et al., 2017). ",
63
+ "bbox": [
64
+ 174,
65
+ 498,
66
+ 825,
67
+ 583
68
+ ],
69
+ "page_idx": 0
70
+ },
71
+ {
72
+ "type": "text",
73
+ "text": "Gated Neural Networks (GNNs) also help to mitigate this problem by introducing “gates” to control information flow through the network over layers or sequences. Notable examples include recurrent networks such as Long-short Term Memory (LSTM) (Hochreiter & Schmidhuber, 1997), Gated Recurrent Unit (GRU) (Chung et al., 2014; Cho et al., 2014), and feedforward networks such as Highway Networks (HNs) (Srivastava et al., 2015), and Residual Networks (ResNets) (He et al., 2015). One can successfully train very deep models by employing these models, e.g., ResNets can be trained with over 1,000 layers. It has been demonstrated that removing (lesioning) or reordering (re-shuffling) random layers in deep feedforward GNNs does not noticeable affect the performance of the network (Veit et al., 2016) Noticeably, one interpretation for this effect as given by Greff et al. (2016) is that the functional blocks in HNs or ResNets engage in an Unrolled Iterative Estimate (UIE) of representations and that layers in this block of HNs or ResNets iteratively refine a single set of representations. ",
74
+ "bbox": [
75
+ 174,
76
+ 589,
77
+ 825,
78
+ 756
79
+ ],
80
+ "page_idx": 0
81
+ },
82
+ {
83
+ "type": "text",
84
+ "text": "In this paper, we investigate if the view of Iterative Estimation (IE) can also be applied towards recurrent GNNs (Section 2.1). We present a formal analysis for GNNs by examining a dual gate design common in LSTM and GRU (Section 2.2). The analysis suggests that the use of gates in GNNs encourages the network to learn an identity mapping which can be beneficial in training deep architectures (He et al., 2016; Greff et al., 2016). ",
85
+ "bbox": [
86
+ 174,
87
+ 763,
88
+ 823,
89
+ 833
90
+ ],
91
+ "page_idx": 0
92
+ },
93
+ {
94
+ "type": "text",
95
+ "text": "We propose a new formulation of a plain RNN, called a Recurrent Identity Network (RIN), that is encouraged to learn an identity mapping without the use of gates (Section 2). This network uses ReLU as the activation function and contains a set of non-trainable parameters. This simple yet effective method helps the plain recurrent network to overcome the vanishing gradient problem while it is still able to model long-range dependencies. This network is compared against two competing networks, the IRNN (Le et al., 2015) and LSTM, on several long sequence modeling tasks including the adding problem (Section 3.1), Sequential and Permuted MNIST classification tasks (Section 3.2), and bAbI question answering tasks (Section 3.3). RINs show faster convergence than IRNNs and LSTMs in the early stage of the training phase and reach competitive performance in all benchmarks. Note that the use of ReLU in RNNs usually leads to training instability, and therefore the network is sensitive to training hyperparameters. Our proposed RIN network demonstrates that a plain RNN does not suffer from this problem even with the use of ReLUs as shown in Section 3. We discuss further implications of this network and related work in Section 4. ",
96
+ "bbox": [
97
+ 174,
98
+ 840,
99
+ 825,
100
+ 924
101
+ ],
102
+ "page_idx": 0
103
+ },
104
+ {
105
+ "type": "text",
106
+ "text": "",
107
+ "bbox": [
108
+ 173,
109
+ 103,
110
+ 825,
111
+ 202
112
+ ],
113
+ "page_idx": 1
114
+ },
115
+ {
116
+ "type": "text",
117
+ "text": "2 METHODS ",
118
+ "text_level": 1,
119
+ "bbox": [
120
+ 174,
121
+ 220,
122
+ 290,
123
+ 238
124
+ ],
125
+ "page_idx": 1
126
+ },
127
+ {
128
+ "type": "text",
129
+ "text": "2.1 ITERATIVE ESTIMATION VIEW IN RNNS ",
130
+ "text_level": 1,
131
+ "bbox": [
132
+ 176,
133
+ 252,
134
+ 491,
135
+ 267
136
+ ],
137
+ "page_idx": 1
138
+ },
139
+ {
140
+ "type": "text",
141
+ "text": "Representation learning in RNNs requires that the network build a latent state, which reflects the temporal dependencies over a sequence of inputs. In this section, we explore an interpretation of this process using iterative estimation (IE), a view that is similar to the UIE view for feedforward GNNs. Formally, we characterize this viewpoint in Eq. 1, that is, the expectation of the difference between the hidden activation at step $t$ , $\\mathbf { h } _ { t }$ , and the last hidden activation at step $T$ , $\\mathbf { h } _ { T }$ , is zero: ",
142
+ "bbox": [
143
+ 173,
144
+ 279,
145
+ 825,
146
+ 349
147
+ ],
148
+ "page_idx": 1
149
+ },
150
+ {
151
+ "type": "equation",
152
+ "img_path": "images/10bd6876e4861b0cc713816ed881b711e84f4c2f123e26d52ceff4bf76af35c8.jpg",
153
+ "text": "$$\n\\mathbb { E } _ { \\mathbf { x } _ { 1 , . . . , T } } \\left[ \\mathbf { h } _ { t } - \\mathbf { h } _ { T } \\right] = 0 .\n$$",
154
+ "text_format": "latex",
155
+ "bbox": [
156
+ 418,
157
+ 356,
158
+ 578,
159
+ 375
160
+ ],
161
+ "page_idx": 1
162
+ },
163
+ {
164
+ "type": "text",
165
+ "text": "This formulation implies that an RNN layer maintains and updates the same set of representations over the input sequence. Given the fact that the hidden activation at every step is an estimation of the final activation, we derive Eq. 3. ",
166
+ "bbox": [
167
+ 176,
168
+ 378,
169
+ 825,
170
+ 422
171
+ ],
172
+ "page_idx": 1
173
+ },
174
+ {
175
+ "type": "equation",
176
+ "img_path": "images/6bdb50ee91c3f3b6dc73a3e1f009554b99e1aee79ff54edfc7032c91d67641b2.jpg",
177
+ "text": "$$\n\\begin{array} { r l } & { \\mathbb { E } _ { \\mathbf { x } _ { 1 , \\ldots , T } } \\left[ \\mathbf { h } _ { t } - \\mathbf { h } _ { T } \\right] - \\mathbb { E } _ { \\mathbf { x } _ { 1 , \\ldots , T } } \\left[ \\mathbf { h } _ { t - 1 } - \\mathbf { h } _ { T } \\right] = 0 } \\\\ { \\Rightarrow } & { \\mathbb { E } _ { \\mathbf { x } _ { 1 , \\ldots , T } } \\left[ \\mathbf { h } _ { t } - \\mathbf { h } _ { t - 1 } \\right] = 0 } \\end{array}\n$$",
178
+ "text_format": "latex",
179
+ "bbox": [
180
+ 321,
181
+ 428,
182
+ 673,
183
+ 467
184
+ ],
185
+ "page_idx": 1
186
+ },
187
+ {
188
+ "type": "image",
189
+ "img_path": "images/90b47af417914bf54d9b1c363199634637e193e353d6e4fdf11079c6775a24c1.jpg",
190
+ "image_caption": [
191
+ "Figure 1: Observation of learning identity mapping in an LSTM model trained on the adding problem task (see Section 3.1). The average estimation error is computed over a batch of 128 samples of the test set. (a) and $\\mathbf { ( b ) }$ show the evaluation of Eq. 1 and Eq. 3 respectively. The $\\mathbf { X }$ -axis indicates the index of the step that compares with the final output $\\mathbf { h } _ { T }$ or its previous step $\\mathbf { h } _ { t - 1 }$ . "
192
+ ],
193
+ "image_footnote": [],
194
+ "bbox": [
195
+ 207,
196
+ 498,
197
+ 790,
198
+ 640
199
+ ],
200
+ "page_idx": 1
201
+ },
202
+ {
203
+ "type": "text",
204
+ "text": "Fig. 1 shows an empirical observation of the IE in the adding problem (experimental details in Section 3.1). Here, we use the Average Estimation Error (AEE) measure (Greff et al., 2016) to quantify the expectation of the difference between two hidden activations. The measured AEEs in Fig. 1 are close to 0 indicating that the LSTM model fulfills the view of IE. The results also suggest that the network learns an identity mapping since the activation levels are similar on average across all recurrent updates. In the next section, we shall show that the use of gates in GNNs encourages the network to learn an identity mapping and whether this analysis can be extended to plain recurrent networks. ",
205
+ "bbox": [
206
+ 173,
207
+ 718,
208
+ 825,
209
+ 830
210
+ ],
211
+ "page_idx": 1
212
+ },
213
+ {
214
+ "type": "text",
215
+ "text": "2.2 ANALYSIS OF GNNS ",
216
+ "text_level": 1,
217
+ "bbox": [
218
+ 176,
219
+ 847,
220
+ 359,
221
+ 861
222
+ ],
223
+ "page_idx": 1
224
+ },
225
+ {
226
+ "type": "text",
227
+ "text": "Popular GNNs such as LSTM, GRU; and recent variants such as the Phased-LSTM (Neil et al., 2016), and Intersection RNN (Collins et al., 2017), share the same dual gate design following: ",
228
+ "bbox": [
229
+ 173,
230
+ 872,
231
+ 825,
232
+ 901
233
+ ],
234
+ "page_idx": 1
235
+ },
236
+ {
237
+ "type": "equation",
238
+ "img_path": "images/1af9aaa8c96ffcb7fdd9047d86bed5cd9ce95eb791a6e0d2338c918c2b01559c.jpg",
239
+ "text": "$$\n\\mathbf h _ { t } = \\mathbf H _ { t } \\odot \\mathbf T _ { t } + \\mathbf h _ { t - 1 } \\odot \\mathbf C _ { t }\n$$",
240
+ "text_format": "latex",
241
+ "bbox": [
242
+ 401,
243
+ 909,
244
+ 596,
245
+ 925
246
+ ],
247
+ "page_idx": 1
248
+ },
249
+ {
250
+ "type": "text",
251
+ "text": "where $t \\in [ 1 , T ]$ , $\\mathbf H _ { t } = \\sigma ( \\mathbf x _ { t } , \\mathbf h _ { t - 1 } )$ represents the hidden transformation, $\\mathbf T _ { t } = \\tau ( \\mathbf x _ { t } , \\mathbf h _ { t - 1 } )$ is the transform gate, and $\\mathbf { C } _ { t } = \\phi ( \\mathbf { x } _ { t } , \\mathbf { h } _ { t - 1 } )$ is the carry gate. $\\sigma , \\tau$ and $\\phi$ are recurrent layers that have their trainable parameters and activation functions. $\\odot$ represents element-wise product operator. Note that $\\mathbf { h } _ { t }$ may not be the output activation at the recurrent step $t$ . For example in LSTM, $\\mathbf { h } _ { t }$ represents the memory cell state. Typically, the elements of transform gate $\\mathbf { T } _ { t , k }$ and carry gate $\\mathbf { C } _ { t , k }$ are between 0 (close) and 1 (open), the value indicates the openness of the gate at the $k$ th neuron. Hence, a plain recurrent network is a subcase of Eq. 4 when $\\mathbf { T } _ { t } = \\mathbf { 1 }$ and $\\mathbf { C } _ { t } = \\mathbf { 0 }$ . ",
252
+ "bbox": [
253
+ 173,
254
+ 102,
255
+ 825,
256
+ 202
257
+ ],
258
+ "page_idx": 2
259
+ },
260
+ {
261
+ "type": "text",
262
+ "text": "Note that conventionally, the initial hidden activation $\\mathbf { h } _ { 0 }$ is 0 to represent a “void state” at the start of computation. For $\\mathbf { h } _ { 0 }$ to fit into Eq. 4’s framework, we define an auxiliary state $\\mathbf { h } _ { - 1 }$ as the previous state of $\\mathbf { h } _ { 0 }$ , and $\\mathbf { T } _ { 0 } = \\mathbf { 1 }$ , $\\mathbf { C } _ { 0 } = \\mathbf { 0 }$ . We also define another auxiliary state ${ \\bf h } _ { T + 1 } = { \\bf h } _ { T }$ , $\\mathbf { T } _ { T + 1 } = \\mathbf { 0 }$ , and ${ \\bf C } _ { T + 1 } = { \\bf 1 }$ as the succeeding state of $\\mathbf { h } _ { T }$ . ",
263
+ "bbox": [
264
+ 174,
265
+ 207,
266
+ 825,
267
+ 265
268
+ ],
269
+ "page_idx": 2
270
+ },
271
+ {
272
+ "type": "text",
273
+ "text": "Based on the recursive definition in Eq. 4, we can write the final layer output $\\mathbf { h } _ { T }$ as follows: ",
274
+ "bbox": [
275
+ 173,
276
+ 270,
277
+ 776,
278
+ 286
279
+ ],
280
+ "page_idx": 2
281
+ },
282
+ {
283
+ "type": "equation",
284
+ "img_path": "images/a59fa9b5715f15577ffbc8ed0abbb6db7e1298e3ad5db7298880ef54ceb98f45.jpg",
285
+ "text": "$$\n\\mathbf { h } _ { T } = \\mathbf { h } _ { 0 } \\odot \\prod _ { t = 1 } ^ { T } \\mathbf { C } _ { t } + \\sum _ { t = 1 } ^ { T } \\left( \\mathbf { H } _ { t } \\odot \\mathbf { T } _ { t } \\odot \\prod _ { i = t + 1 } ^ { T + 1 } \\mathbf { C } _ { i } \\right)\n$$",
286
+ "text_format": "latex",
287
+ "bbox": [
288
+ 330,
289
+ 287,
290
+ 666,
291
+ 332
292
+ ],
293
+ "page_idx": 2
294
+ },
295
+ {
296
+ "type": "text",
297
+ "text": "where we use $\\prod$ to represent element-wise multiplication over a series of terms. ",
298
+ "bbox": [
299
+ 176,
300
+ 334,
301
+ 697,
302
+ 349
303
+ ],
304
+ "page_idx": 2
305
+ },
306
+ {
307
+ "type": "text",
308
+ "text": "According to Eq. 3, and supposing that Eq. 5 fulfills the Eq. 1, we can use a zero-mean residual $\\epsilon _ { t }$ for describing the difference between the outputs of recurrent steps: ",
309
+ "bbox": [
310
+ 173,
311
+ 354,
312
+ 820,
313
+ 383
314
+ ],
315
+ "page_idx": 2
316
+ },
317
+ {
318
+ "type": "equation",
319
+ "img_path": "images/001b87522d100030381e300987ff2f477b14f62d9a2fac4f9d08f76ad7ce9968.jpg",
320
+ "text": "$$\n\\begin{array} { c } { \\mathbf { h } _ { t } - \\mathbf { h } _ { t - 1 } = \\pmb { \\epsilon } _ { t } } \\\\ { \\mathbf { \\epsilon } _ { \\mathbf { \\epsilon } _ { 0 } } = \\mathbf { 0 } } \\end{array}\n$$",
321
+ "text_format": "latex",
322
+ "bbox": [
323
+ 442,
324
+ 386,
325
+ 553,
326
+ 421
327
+ ],
328
+ "page_idx": 2
329
+ },
330
+ {
331
+ "type": "text",
332
+ "text": "Plugging Eq. 6 into Eq. 5, we get ",
333
+ "bbox": [
334
+ 173,
335
+ 430,
336
+ 393,
337
+ 445
338
+ ],
339
+ "page_idx": 2
340
+ },
341
+ {
342
+ "type": "equation",
343
+ "img_path": "images/ccb0a71fdfd241c22f5ba161f1466863f778ccffadd30a6ec3db425bd1b41489.jpg",
344
+ "text": "$$\n{ \\bf h } _ { T } = { \\bf h } _ { 0 } + \\lambda\n$$",
345
+ "text_format": "latex",
346
+ "bbox": [
347
+ 450,
348
+ 443,
349
+ 547,
350
+ 459
351
+ ],
352
+ "page_idx": 2
353
+ },
354
+ {
355
+ "type": "text",
356
+ "text": "where ",
357
+ "bbox": [
358
+ 174,
359
+ 460,
360
+ 217,
361
+ 473
362
+ ],
363
+ "page_idx": 2
364
+ },
365
+ {
366
+ "type": "equation",
367
+ "img_path": "images/1f0dc95e080695fda5d0b075d2e96c1895664a9ca858691df9691852da652935.jpg",
368
+ "text": "$$\n\\lambda = \\sum _ { t = 1 } ^ { T } \\lambda _ { t } = \\sum _ { t = 1 } ^ { T } \\left( \\left( \\sum _ { i = 1 } ^ { t } \\epsilon _ { i } \\right) \\odot \\prod _ { j = t + 1 } ^ { T + 1 } \\mathbf { C } _ { j } - \\left( \\sum _ { i = 0 } ^ { t - 1 } \\epsilon _ { i } \\right) \\odot \\prod _ { j = t } ^ { T } \\mathbf { C } _ { j } \\right)\n$$",
369
+ "text_format": "latex",
370
+ "bbox": [
371
+ 272,
372
+ 469,
373
+ 723,
374
+ 520
375
+ ],
376
+ "page_idx": 2
377
+ },
378
+ {
379
+ "type": "text",
380
+ "text": "The complete deduction of Eqs. 8–9 is presented in Appendix A. Eq. 8 performs an identity mapping when the carry gate $\\mathbf { C } _ { t }$ is always open. In Eq. 9, the term $\\textstyle \\sum _ { i = 1 } ^ { t } \\epsilon _ { i }$ represents “a level of representation that is formed between $\\mathbf { h } _ { 1 }$ and $\\mathbf { h } _ { t } \\mathbf { \\Psi } ^ { \\mathsf { N } }$ . Moreover, the term $\\textstyle \\prod _ { j = t } ^ { T } \\mathbf { C } _ { j }$ extract the “useful” part of this representation and contribute to the final representation of the recurrent layer. Here, we interpret “useful” as any quantity that helps in minimizing the cost function. Therefore, the contribution, $\\lambda _ { t }$ , at each recurrent step, quantifies the representation that is learned in the step $t$ . Furthermore, it is generally believed that a GNN manages and maintains the latent state through the carry gate, such as the forget gate in LSTM. If the carry gate is closed, then it is impossible for the old state to be preserved while undergoing recurrent updates. However, if we set $\\mathbf { C } _ { t } = \\mathbf { 0 }$ , $t \\in [ 1 , T ]$ in Eq. 9, we get: ",
381
+ "bbox": [
382
+ 173,
383
+ 518,
384
+ 825,
385
+ 666
386
+ ],
387
+ "page_idx": 2
388
+ },
389
+ {
390
+ "type": "equation",
391
+ "img_path": "images/d0767765659c5dd0c502a11031a19da1d2b3437f194d1ba9a88f8a2f2326dee2.jpg",
392
+ "text": "$$\n{ \\mathbf { h } } _ { T } = { \\mathbf { h } } _ { 0 } + \\sum _ { t = 1 } ^ { T } \\epsilon _ { t }\n$$",
393
+ "text_format": "latex",
394
+ "bbox": [
395
+ 436,
396
+ 681,
397
+ 562,
398
+ 724
399
+ ],
400
+ "page_idx": 2
401
+ },
402
+ {
403
+ "type": "text",
404
+ "text": "If $\\mathbf { h } _ { 0 } = \\mathbf { 0 }$ (void state at the start), we can turn Eq. 10 into: ",
405
+ "bbox": [
406
+ 171,
407
+ 724,
408
+ 555,
409
+ 739
410
+ ],
411
+ "page_idx": 2
412
+ },
413
+ {
414
+ "type": "equation",
415
+ "img_path": "images/1b43bf39072e32f177b79e9a3e868a38bf7fcbfdb72a4cd102db4ded97974bce.jpg",
416
+ "text": "$$\n{ \\mathbf h } _ { T } = { \\mathbf \\epsilon } _ { 1 } + \\sum _ { t = 2 } ^ { T } { \\boldsymbol { \\epsilon } } _ { t } = { \\mathbf h } _ { 1 } + \\sum _ { t = 2 } ^ { T } { \\boldsymbol { \\epsilon } } _ { t }\n$$",
417
+ "text_format": "latex",
418
+ "bbox": [
419
+ 387,
420
+ 739,
421
+ 609,
422
+ 784
423
+ ],
424
+ "page_idx": 2
425
+ },
426
+ {
427
+ "type": "text",
428
+ "text": "Eq. 11 shows that the state can be preserved without the help of the carry gate. This result indicates that it is possible for a plain recurrent network to learn an identity mapping as well. ",
429
+ "bbox": [
430
+ 173,
431
+ 785,
432
+ 823,
433
+ 814
434
+ ],
435
+ "page_idx": 2
436
+ },
437
+ {
438
+ "type": "text",
439
+ "text": "2.3 RECURRENT IDENTITY NETWORKS",
440
+ "text_level": 1,
441
+ "bbox": [
442
+ 174,
443
+ 829,
444
+ 459,
445
+ 844
446
+ ],
447
+ "page_idx": 2
448
+ },
449
+ {
450
+ "type": "text",
451
+ "text": "Motivated by the previous iterative estimation interpretation of RNNs, we formulate a novel plain recurrent network variant — Recurrent Identity Network (RIN): ",
452
+ "bbox": [
453
+ 173,
454
+ 856,
455
+ 821,
456
+ 883
457
+ ],
458
+ "page_idx": 2
459
+ },
460
+ {
461
+ "type": "equation",
462
+ "img_path": "images/6cb411f586dfa9044dc43fd5ed7e6e305becccab733f29ab4f5e34a4bd924160.jpg",
463
+ "text": "$$\n\\begin{array} { r l } & { \\mathbf { h } _ { t } = \\mathrm { R e L U } \\left( \\mathbf { W } \\mathbf { x } _ { t } + \\mathbf { U } \\mathbf { h } _ { t - 1 } + \\mathbf { h } _ { t - 1 } + \\mathbf { b } \\right) } \\\\ & { \\quad = \\mathrm { R e L U } \\left( \\mathbf { W } \\mathbf { x } _ { t } + ( \\mathbf { U } + \\mathbf { I } ) \\mathbf { h } _ { t - 1 } + \\mathbf { b } \\right) } \\end{array}\n$$",
464
+ "text_format": "latex",
465
+ "bbox": [
466
+ 356,
467
+ 886,
468
+ 640,
469
+ 922
470
+ ],
471
+ "page_idx": 2
472
+ },
473
+ {
474
+ "type": "text",
475
+ "text": "where W is the input-to-hidden weight matrix, U is the hidden-to-hidden weight matrix, and I is a non-trainable identity matrix that acts as a “surrogate memory” component. This formulation encourages the network to preserve a copy of the last state by embedding I into the hidden-tohidden weights. This “surrogate memory” component maintains the representation encoded in the past recurrent steps. ",
476
+ "bbox": [
477
+ 174,
478
+ 103,
479
+ 825,
480
+ 174
481
+ ],
482
+ "page_idx": 3
483
+ },
484
+ {
485
+ "type": "text",
486
+ "text": "3 RESULTS ",
487
+ "text_level": 1,
488
+ "bbox": [
489
+ 176,
490
+ 194,
491
+ 281,
492
+ 210
493
+ ],
494
+ "page_idx": 3
495
+ },
496
+ {
497
+ "type": "text",
498
+ "text": "In this section, we compare the performances of the RIN, IRNN, and LSTM in a set of tasks that require modeling long-range dependencies. ",
499
+ "bbox": [
500
+ 176,
501
+ 227,
502
+ 823,
503
+ 255
504
+ ],
505
+ "page_idx": 3
506
+ },
507
+ {
508
+ "type": "text",
509
+ "text": "3.1 THE ADDING PROBLEM ",
510
+ "text_level": 1,
511
+ "bbox": [
512
+ 176,
513
+ 272,
514
+ 375,
515
+ 286
516
+ ],
517
+ "page_idx": 3
518
+ },
519
+ {
520
+ "type": "text",
521
+ "text": "The adding problem is a standard task for examining the capability of RNNs for modeling longrange dependencies (Hochreiter & Schmidhuber, 1997). In this task, two numbers are randomly selected from a long sequence. The network has to predict the sum of these two numbers. The task becomes challenging as the length of the sequence $T$ increases because the relevant numbers can be far from each other in a long sequence. We report experimental results from three datasets that have sequence lengths of $T _ { 1 } = 2 0 0$ , $T _ { 2 } = 3 0 0$ , and $T _ { 3 } = 4 0 0$ respectively. Each dataset has 100,000 training samples and 10,000 testing samples. Each sequence of a dataset has $T _ { i }$ numbers that are randomly sampled from a uniform distribution in $[ 0 , 1 ]$ . Each sequence is accompanied by a mask that indicates the two chosen random positions. ",
522
+ "bbox": [
523
+ 173,
524
+ 299,
525
+ 825,
526
+ 424
527
+ ],
528
+ "page_idx": 3
529
+ },
530
+ {
531
+ "type": "image",
532
+ "img_path": "images/b4265b1bcd22abc502e23a7ad248890ca6f669652c137bf5d0a83e6ffc4156f8.jpg",
533
+ "image_caption": [
534
+ "Figure 2: Mean Squared Error (MSE) plots during the testing phase of the adding problem task for different sequence lengths. The errors are presented in log scale. LSTM performs the worst in all three tasks. RIN and IRNN models are comparable in (a) and (b), and (c). "
535
+ ],
536
+ "image_footnote": [],
537
+ "bbox": [
538
+ 199,
539
+ 446,
540
+ 813,
541
+ 640
542
+ ],
543
+ "page_idx": 3
544
+ },
545
+ {
546
+ "type": "text",
547
+ "text": "We compare the performance between RINs, IRNNs, and LSTMs using the same experimental settings. Each network has one hidden layer with 100 hidden units. Note that a LSTM has four times more parameters than corresponding RIN and IRNN models. The optimizer minimizes the Mean Squared Error (MSE) between the target sum and the predicted sum. We initially used the RMSprop (Tieleman & Hinton, 2012) optimizer. However, some IRNN models failed to converge using this optimizer. Therefore, we chose the Adam optimizer (Kingma & Ba, 2014) so a fair comparison can be made between the different networks. The batch size is 32. Gradient clipping value for all models is 100. The models are trained with maximum 300 epochs until they converged. The initial learning rates are different between the datasets because we found that IRNNs are sensitive to the initial learning rate as the sequence length increases. The learning rates $\\alpha _ { 2 0 0 } = 1 0 ^ { - 4 }$ , $\\alpha _ { 3 0 0 } = 1 0 ^ { - 5 }$ and $\\alpha _ { 4 0 0 } = \\mathrm { i } 0 ^ { - 6 }$ are applied to $T _ { 1 }$ , $T _ { 2 }$ and $T _ { 3 }$ correspondingly. The input-to-hidden weights of RINs and IRNNs and hidden-to-hidden weights of RINs are initialized using a similar method to Le et al. (2015) where the weights are drawn from a Gaussian distribution $\\mathcal { N } ( 0 , 1 0 ^ { - 3 } )$ . The LSTM is initialized with the settings where the input-to-hidden weights use Glorot Uniform (Glorot & Bengio, 2010) and hidden-to-hidden weights use an orthogonal matrix as suggested by Saxe et al. ",
548
+ "bbox": [
549
+ 174,
550
+ 715,
551
+ 825,
552
+ 924
553
+ ],
554
+ "page_idx": 3
555
+ },
556
+ {
557
+ "type": "text",
558
+ "text": "(2013). Bias values for all networks are initialized to 0. No explicit regularization is employed. We do not perform an exhaustive hyperparameter search in these experiments. ",
559
+ "bbox": [
560
+ 171,
561
+ 103,
562
+ 823,
563
+ 132
564
+ ],
565
+ "page_idx": 4
566
+ },
567
+ {
568
+ "type": "text",
569
+ "text": "The baseline MSE of the task is 0.167. This score is achieved by predicting the sum of two numbers as 1 regardless of the input sequence. Fig. 2 shows MSE plots for different test datasets. RINs and IRNNs reached the same level of performance in all experiments, and LSTMs performed the worst. Notably, LSTM fails to converge in the dataset with $T _ { 3 } = 4 0 0$ . The use of ReLU in RINs and IRNNs causes some degree of instability in the training phase. However, in most cases, RINs converge faster and are more stable than IRNNs (see training loss plots in Fig. 5 of Appendix B). Note that because IRNNs are sensitive to the initial learning rate, applying high learning rates such as $\\alpha = 1 0 ^ { - 3 }$ for $T _ { 2 }$ and $T _ { 3 }$ could cause the training of the network to fail. ",
570
+ "bbox": [
571
+ 174,
572
+ 138,
573
+ 825,
574
+ 251
575
+ ],
576
+ "page_idx": 4
577
+ },
578
+ {
579
+ "type": "text",
580
+ "text": "3.2 SEQUENTIAL AND PERMUTED MNIST ",
581
+ "text_level": 1,
582
+ "bbox": [
583
+ 176,
584
+ 267,
585
+ 480,
586
+ 281
587
+ ],
588
+ "page_idx": 4
589
+ },
590
+ {
591
+ "type": "text",
592
+ "text": "Sequential and Permuted MNIST are introduced by Le et al. (2015) for evaluating RNNs. Sequential MNIST presents each pixel of the MNIST handwritten image (Lecun et al., 1998) to the network sequentially (e.g., from the top left corner of the image to the bottom right corner of the image). After the network has seen all $2 8 \\times 2 8 = 7 8 4$ pixels, the network produces the class of the image. This task requires the network to model a very long sequence that has 784 steps. Permuted MNIST is an even harder task than the Sequential MNIST in that a fixed random index permutation is applied to all images. This random permutation breaks the association between adjacent pixels. The network is expected to find the hidden relations between pixels so that it can correctly classify the image. ",
593
+ "bbox": [
594
+ 174,
595
+ 292,
596
+ 825,
597
+ 405
598
+ ],
599
+ "page_idx": 4
600
+ },
601
+ {
602
+ "type": "text",
603
+ "text": "All networks are trained with the RMSprop optimizer (Tieleman & Hinton, 2012) and a batch size of 128. The networks are trained with maximum 500 epochs until they are converged. The initial learning rate is set to $\\alpha = 1 0 ^ { - 6 }$ . Weight initialization follows the same setup as Section 3.1. No explicit regularization is added. ",
604
+ "bbox": [
605
+ 174,
606
+ 411,
607
+ 825,
608
+ 467
609
+ ],
610
+ "page_idx": 4
611
+ },
612
+ {
613
+ "type": "text",
614
+ "text": "Table 1 summarizes the accuracy performance of the networks on the Sequential and Permuted MNIST datasets. For small network sizes (1–100, 1–200), RINs outperform IRNNs in their accuracy performance. For bigger networks, RINs and IRNNs achieve similar performance; however, RINs converge much faster than IRNNs in the early stage of training (see Fig. 3). LSTMs perform the worst on both tasks in terms of both convergence speed and final accuracy. Appendix C presents the full experimental results. ",
615
+ "bbox": [
616
+ 173,
617
+ 474,
618
+ 825,
619
+ 558
620
+ ],
621
+ "page_idx": 4
622
+ },
623
+ {
624
+ "type": "text",
625
+ "text": "To investigate the limit of RINs, we adopted the concept of Deep Transition (DT) Networks (Pascanu et al., 2013) for increasing the implicit network depth. In this extended RIN model called RINDT, each recurrent step performs two hidden transitions instead of one (the formulation is given in Appendix D). The network modification increases the inherent depth by a factor of two. The results showed that the error signal could survive $7 8 4 \\times 2 = 1 5 6 8$ computation steps in RIN-DTs. ",
626
+ "bbox": [
627
+ 174,
628
+ 565,
629
+ 825,
630
+ 635
631
+ ],
632
+ "page_idx": 4
633
+ },
634
+ {
635
+ "type": "text",
636
+ "text": "In Fig. 4, we show the evidence of learning identity mapping empirically by collecting the hidden activation from all recurrent steps and evaluating Eqs. 1 and 3. The network matches the IE when AEE is close to zero. We also compute the variance of the difference between two recurrent steps. Fig. 4(a) suggests that all networks bound the variance across recurrent steps. Fig. 4(b) offers a closer perspective where it measures the AEE between two adjacent steps. The levels of activations for all networks are always kept the same on an average, which is an evidence of learning identity mapping. We also observed that the magnitude of the variance becomes significantly larger at the last 200 steps in IRNN and RIN. Repeated application of ReLU may cause this effect during recurrent update (Jastrzebski et al., 2017). Other experiments in this section exhibit similar behaviors, complete results are shown in Appendix C (Fig. 8–12). Note that this empirical analysis only demonstrates that the tested RNNs have the evidence of learning identity mapping across recurrent updates as RINs and IRNNs largely fulfill the view of IE. We do not over-explain the relationship between this analysis and the performance of the network. ",
637
+ "bbox": [
638
+ 173,
639
+ 641,
640
+ 825,
641
+ 821
642
+ ],
643
+ "page_idx": 4
644
+ },
645
+ {
646
+ "type": "table",
647
+ "img_path": "images/46be9b1a397cbb9374bc3bdb35c67039ad3787b199206fc32a4554a45fd815d4.jpg",
648
+ "table_caption": [
649
+ "Table 1: Accuracies of RINs, IRNNs and LSTM on Sequential and Permuted MNIST. The network type is represented by No. layers-No. units, e.g., 3–100 means that the network has 3 layers and each layer has 100 hidden units. The LSTM results matches with Le et al. (2015) "
650
+ ],
651
+ "table_footnote": [],
652
+ "table_body": "<table><tr><td>Network Type</td><td colspan=\"3\">Sequential MNIST</td><td colspan=\"3\">Permuted MNIST</td></tr><tr><td></td><td>RIN</td><td>IRNN</td><td>LSTM</td><td>RIN</td><td>IRNN</td><td>LSTM</td></tr><tr><td>1-100</td><td>91.64%</td><td>83.55%</td><td>24.10%</td><td>78.89%</td><td>62.11%</td><td>28.49%</td></tr><tr><td>1-200</td><td>94.60%</td><td>92.86%</td><td>47.13%</td><td>85.03%</td><td>73.73%</td><td>30.63%</td></tr><tr><td>2-100</td><td>93.69%</td><td>92.15%</td><td>39.50%</td><td>83.37%</td><td>76.31%</td><td>41.31%</td></tr><tr><td>2-200</td><td>94.82%</td><td>94.78%</td><td>22.27%</td><td>85.31%</td><td>83.78%</td><td>55.44%</td></tr><tr><td>3-100</td><td>94.15%</td><td>94.03%</td><td>54.98%</td><td>84.15%</td><td>78.78%</td><td>38.61%</td></tr><tr><td>3-200</td><td>95.19%</td><td>95.05%</td><td>61.20%</td><td>83.41%</td><td>84.24%</td><td>53.29%</td></tr><tr><td></td><td>RIN-DT</td><td></td><td></td><td>RIN-DT</td><td></td><td></td></tr><tr><td>1-100</td><td>95.41%</td><td></td><td></td><td>86.23%</td><td></td><td></td></tr></table>",
653
+ "bbox": [
654
+ 241,
655
+ 190,
656
+ 758,
657
+ 352
658
+ ],
659
+ "page_idx": 5
660
+ },
661
+ {
662
+ "type": "image",
663
+ "img_path": "images/ce393191984108625006c43ca6cc5336f1f42d211707cd3e8df80cf4c81daaf2.jpg",
664
+ "image_caption": [
665
+ "Figure 3: Results for network type 1–200. (a) and (b) show the loss and accuracy curves on Sequential MNIST; (c) and (d) present the loss and accuracy curves on Permuted MNIST. RINs and RIN-DTs converge much faster than IRNNs and LSTMs in the early stage of training (first 100 epochs) and achieve a better final accuracy. "
666
+ ],
667
+ "image_footnote": [],
668
+ "bbox": [
669
+ 199,
670
+ 438,
671
+ 813,
672
+ 823
673
+ ],
674
+ "page_idx": 5
675
+ },
676
+ {
677
+ "type": "image",
678
+ "img_path": "images/9529610afea9893a0b23e428d1f76115e71d3b140707b5ca5131fb73d99dc937.jpg",
679
+ "image_caption": [
680
+ "Figure 4: Evidence of learning identity mapping in RIN, IRNN and LSTM for network type 1–200 over a batch of 128 samples. (a) evaluates Eq. 1 and $\\mathbf { ( b ) }$ evaluates Eq. 3. The $\\mathbf { X }$ -axis indicates the index of the step that compares with the final output $\\mathbf { h } _ { T }$ or its previous step $\\mathbf { h } _ { t - 1 }$ , and $_ \\textrm { y }$ -axis represents the average estimation error (AEE). "
681
+ ],
682
+ "image_footnote": [],
683
+ "bbox": [
684
+ 200,
685
+ 114,
686
+ 803,
687
+ 284
688
+ ],
689
+ "page_idx": 6
690
+ },
691
+ {
692
+ "type": "text",
693
+ "text": "3.3 BABI QUESTION ANSWERING TASKS ",
694
+ "text_level": 1,
695
+ "bbox": [
696
+ 176,
697
+ 404,
698
+ 464,
699
+ 416
700
+ ],
701
+ "page_idx": 6
702
+ },
703
+ {
704
+ "type": "text",
705
+ "text": "The bAbI dataset provides 20 question answering tasks that measure the understanding of language and the performance of reasoning in neural networks (Weston et al., 2015). Each task consists of 1,000 training samples and 1,000 test samples. A sample consists of three parts: a list of statements, a question and an answer (examples in Table 2). The answer to the question can be inferred from the statements that are logically organized together. ",
706
+ "bbox": [
707
+ 174,
708
+ 434,
709
+ 825,
710
+ 503
711
+ ],
712
+ "page_idx": 6
713
+ },
714
+ {
715
+ "type": "table",
716
+ "img_path": "images/72edb37274ba61dcb9985ee3d2117577ab98de4a255c120ecbbfc5ba84dd91bc.jpg",
717
+ "table_caption": [
718
+ "Table 2: Examples of bAbI tasks. "
719
+ ],
720
+ "table_footnote": [],
721
+ "table_body": "<table><tr><td>Statements: Mary went to the office. Then she journeyed to the garden.</td><td>Statements:</td><td>The red square is below the blue square. The red square is to the left of the pink rectangle.</td></tr><tr><td>Question: Answer:</td><td>Where is Mary? Garden.</td><td>Question: Answer:</td><td>Is the blue square below the pink rectangle? No.</td></tr></table>",
722
+ "bbox": [
723
+ 202,
724
+ 560,
725
+ 795,
726
+ 640
727
+ ],
728
+ "page_idx": 6
729
+ },
730
+ {
731
+ "type": "text",
732
+ "text": "We compare the performance of the RIN, IRNN, and LSTM on these tasks. All networks follow a network design where the network firstly embeds each word into a vector of 200 dimensions. The statements are then appended together to a single sequence and encoded by a recurrent layer while another recurrent layer encodes the question sequence. The outputs of these two recurrent layers are concatenated together, and this concatenated sequence is then passed to a different recurrent layer for decoding the answer. Finally, the network predicts the answer via a softmax layer. The recurrent layers in all networks have 100 hidden units. This network design roughly follows the architecture presented in Jing et al. (2017). The initial learning rates are set to $\\alpha = 1 0 ^ { - 3 }$ for RINs and LSTMs and $\\alpha = 1 0 ^ { - 4 }$ for IRNNs because IRNNs fail to converge with a higher learning rate on many tasks. We chose the Adam optimizer over the RMSprop optimizer because of the same reasons as in the adding problem. The batch size is 32. Each network is trained for maximum 100 epochs until the network converges. The recurrent layers in the network follow the same initialization steps as in Section 3.1. ",
733
+ "bbox": [
734
+ 173,
735
+ 680,
736
+ 825,
737
+ 861
738
+ ],
739
+ "page_idx": 6
740
+ },
741
+ {
742
+ "type": "text",
743
+ "text": "The results in Table 3 show that RINs can reach mean performance similar to the state-of-theart performance reported in Jing et al. (2017). As discussed in Section 3.1, the use of ReLU as the activation function can lead to instability during training of IRNN for tasks that have lengthy statements (e.g.. 3-Three Supporting Facts, 5-Three Arg. Relations). ",
744
+ "bbox": [
745
+ 174,
746
+ 867,
747
+ 823,
748
+ 924
749
+ ],
750
+ "page_idx": 6
751
+ },
752
+ {
753
+ "type": "table",
754
+ "img_path": "images/0b7060cf8352758466a1b6683058dcf8deffa9f561d8a1322e7c687e3576f88f.jpg",
755
+ "table_caption": [
756
+ "Table 3: Test accuracy $( \\% )$ of 20 bAbI Question Answering Tasks. "
757
+ ],
758
+ "table_footnote": [],
759
+ "table_body": "<table><tr><td>Task</td><td>RIN</td><td>IRNN</td><td>LSTM</td><td>Jing et al. (2017)</td><td>Weston et al. (2015)</td></tr><tr><td>1: Single Supporting Fact</td><td>51.9</td><td>48.4</td><td>50.3</td><td>48.2</td><td>50</td></tr><tr><td>2: Two Supporting Facts</td><td>18.7</td><td>18.7</td><td>19</td><td>15.8</td><td>20</td></tr><tr><td>3: Three Supporting Facts</td><td>18.5</td><td>15.3</td><td>22.9</td><td>19.1</td><td>20</td></tr><tr><td>4: Two Arg.Relations</td><td>71.2</td><td>72.6</td><td>71.6</td><td>75.8</td><td>61</td></tr><tr><td>5: Three Arg. Relations</td><td>16.4</td><td>18.9</td><td>36.4</td><td>33.7</td><td>70</td></tr><tr><td>6:Yes/No Questions</td><td>50.3</td><td>50.3</td><td>52.3</td><td>49</td><td>48</td></tr><tr><td>7: Counting</td><td>48.8</td><td>48.8</td><td>48.9</td><td>48</td><td>49</td></tr><tr><td>8:Lists/Sets</td><td>33.6</td><td>33.6</td><td>33.6</td><td>33.6</td><td>45</td></tr><tr><td>9: Simple Negation</td><td>64.6</td><td>64.7</td><td>63.8</td><td>63.2</td><td>64</td></tr><tr><td>10: Indefinite Knowledge</td><td>45.1</td><td>43.7</td><td>45.1</td><td>43.9</td><td>44</td></tr><tr><td>11:Basic Coreference</td><td>71.6</td><td>67.8</td><td>78.4</td><td>68.8</td><td>72</td></tr><tr><td>12:Conjunction</td><td>70.6</td><td>71.4</td><td>75.3</td><td>73</td><td>74</td></tr><tr><td>13: Compound Coref.</td><td>94.4</td><td>94.2</td><td>94.4</td><td>93.9</td><td>94</td></tr><tr><td>14:Time Reasoning</td><td>36.7</td><td>17.6</td><td>23.2</td><td>19.7</td><td>27</td></tr><tr><td>15:Basic Deduction</td><td>54.8</td><td>54.1</td><td>26.7</td><td>54.9</td><td>21</td></tr><tr><td>16:Basic Induction</td><td>48.8</td><td>49</td><td>25.8</td><td>46.6</td><td>23</td></tr><tr><td>17: Positional Reasoning</td><td>53.9</td><td>53.4</td><td>52</td><td>60.5</td><td>51</td></tr><tr><td>18:Size Reasoning</td><td>92.6</td><td>46.9</td><td>93</td><td>91.3</td><td>52</td></tr><tr><td>19: Path Finding</td><td>10.5</td><td>10.9</td><td>9.9</td><td>10</td><td>8</td></tr><tr><td>20:Agent’s Motivations</td><td>98</td><td>98.2</td><td>97.3</td><td>97.4</td><td>91</td></tr><tr><td>Mean Performance</td><td>52.6</td><td>48.9</td><td>51.0</td><td>52.3</td><td>49.2</td></tr></table>",
760
+ "bbox": [
761
+ 200,
762
+ 127,
763
+ 797,
764
+ 426
765
+ ],
766
+ "page_idx": 7
767
+ },
768
+ {
769
+ "type": "text",
770
+ "text": "4 DISCUSSION ",
771
+ "text_level": 1,
772
+ "bbox": [
773
+ 174,
774
+ 452,
775
+ 310,
776
+ 468
777
+ ],
778
+ "page_idx": 7
779
+ },
780
+ {
781
+ "type": "text",
782
+ "text": "In this paper, we discussed the iterative representation refinement in RNNs and how this viewpoint could help in learning identity mapping. Under this observation, we demonstrated that the contribution of each recurrent step a GNN can be jointly determined by the representation that is formed up to the current step, and the openness of the carry gate in later recurrent updates. Note in Eq. 9, the element-wise multiplication of $\\mathbf { C } _ { t } \\mathbf { s }$ selects the encoded representation that could arrive at the output of the layer. Thus, it is possible to embed a special function in $\\mathbf { C } _ { t } \\mathbf { s }$ so that they are sensitive to certain pattern of interests. For example, in Phased LSTM, the time gate is inherently interested in temporal frequency selection (Neil et al., 2016). ",
783
+ "bbox": [
784
+ 173,
785
+ 484,
786
+ 825,
787
+ 597
788
+ ],
789
+ "page_idx": 7
790
+ },
791
+ {
792
+ "type": "text",
793
+ "text": "Motivated by the analysis presented in Section 2, we propose a novel plain recurrent network variant, the Recurrent Identity Network (RIN), that can model long-range dependencies without the use of gates. Compared to the conventional formulation of plain RNNs, the formulation of RINs only adds a set of non-trainable weights to represent a “surrogate memory” component so that the learned representation can be maintained across two recurrent steps. ",
794
+ "bbox": [
795
+ 174,
796
+ 603,
797
+ 825,
798
+ 674
799
+ ],
800
+ "page_idx": 7
801
+ },
802
+ {
803
+ "type": "text",
804
+ "text": "Experimental results in Section 3 show that RINs are competitive against other network models such as IRNNs and LSTMs. Particularly, small RINs produce $12 \\% { - } 6 7 \\%$ higher accuracy in the Sequential and Permuted MNIST. Furthermore, RINs demonstrated much faster convergence speed in early phase of training, which is a desirable advantage for platforms with limited computing resources. RINs work well without advanced methods of weight initializations and are relatively insensitive to hyperparameters such as learning rate, batch size, and selection of optimizer. This property can be very helpful when the time available for choosing hyperparameters is limited. Note that we do not claim that RINs outperform LSTMs in general because LSTMs may achieve comparable performance with finely-tuned hyperparameters. ",
805
+ "bbox": [
806
+ 174,
807
+ 680,
808
+ 825,
809
+ 806
810
+ ],
811
+ "page_idx": 7
812
+ },
813
+ {
814
+ "type": "text",
815
+ "text": "The use of ReLU in RNNs might be counterintuitive at first sight because the repeated application of this activation is more likely causing gradient explosion than conventional choices of activation function, such as hyperbolic tangent (tanh) function or sigmoid function. Although the proposed IRNN (Le et al., 2015) reduces the problem by the identity initialization, in our experiments, we usually found that IRNN is more sensitive to training parameters and more unstable than RINs and LSTMs. On the contrary, feedforward models that use ReLU usually produce better results and converge faster than FFNs that use the tanh or sigmoid activation function. In this paper, we provide a promising method of using ReLU in RNNs so that the network is less sensitive to the training conditions. The experimental results also support the argument that the use of ReLU significantly speeds up the convergence. ",
816
+ "bbox": [
817
+ 174,
818
+ 811,
819
+ 825,
820
+ 924
821
+ ],
822
+ "page_idx": 7
823
+ },
824
+ {
825
+ "type": "text",
826
+ "text": "",
827
+ "bbox": [
828
+ 173,
829
+ 103,
830
+ 823,
831
+ 132
832
+ ],
833
+ "page_idx": 8
834
+ },
835
+ {
836
+ "type": "text",
837
+ "text": "During the development of this paper, a recent independent work (Zagoruyko & Komodakis, 2017) presented a similar network formulation with a focus on training of deep plain FFNs without skip connections. DiracNet uses the idea of ResNets where it assumes that the identity initialization can replace the role of the skip-connection in ResNets. DiracNet employed a particular kind of activation function — negative concatenated ReLU (NCReLU), and this activation function allows the layer output to approximate the layer input when the expectation of the weights are close to zero. In this paper, we showed that an RNN can be trained without the use of gates or special activation functions, which complements the findings and provides theoretical basis in Zagoruyko & Komodakis (2017). ",
838
+ "bbox": [
839
+ 174,
840
+ 138,
841
+ 825,
842
+ 251
843
+ ],
844
+ "page_idx": 8
845
+ },
846
+ {
847
+ "type": "text",
848
+ "text": "We hope to see more empirical and theoretical insights that explains the effectiveness of the RIN by simply embedding a non-trainable identity matrix. In future, we will investigate the reasons for the faster convergence speed of the RIN during training. Furthermore, we will investigate why RIN can be trained stably with the repeated application of ReLU and why it is less sensitive to training parameters than the two other models. ",
849
+ "bbox": [
850
+ 174,
851
+ 257,
852
+ 823,
853
+ 327
854
+ ],
855
+ "page_idx": 8
856
+ },
857
+ {
858
+ "type": "text",
859
+ "text": "REFERENCES ",
860
+ "text_level": 1,
861
+ "bbox": [
862
+ 176,
863
+ 102,
864
+ 287,
865
+ 117
866
+ ],
867
+ "page_idx": 9
868
+ },
869
+ {
870
+ "type": "text",
871
+ "text": "Kyunghyun Cho, Bart van Merrienboer, C¸ aglar Gulc¸ehre, Fethi Bougares, Holger Schwenk, and ¨ Yoshua Bengio. Learning phrase representations using RNN encoder-decoder for statistical machine translation. CoRR, abs/1406.1078, 2014. ",
872
+ "bbox": [
873
+ 176,
874
+ 126,
875
+ 823,
876
+ 167
877
+ ],
878
+ "page_idx": 9
879
+ },
880
+ {
881
+ "type": "text",
882
+ "text": "Junyoung Chung, C¸ aglar Gulc¸ehre, KyungHyun Cho, and Yoshua Bengio. Empirical evaluation of ¨ gated recurrent neural networks on sequence modeling. CoRR, abs/1412.3555, 2014. ",
883
+ "bbox": [
884
+ 168,
885
+ 176,
886
+ 825,
887
+ 205
888
+ ],
889
+ "page_idx": 9
890
+ },
891
+ {
892
+ "type": "text",
893
+ "text": "Jasmine Collins, Jascha Sohl-Dickstein, and David Sussillo. Capacity and trainability in recurrent neural networks. In 5th International Conference on Learning Representations, Palais des Congres Neptune, Toulon, France, 2017. \\` ",
894
+ "bbox": [
895
+ 174,
896
+ 213,
897
+ 823,
898
+ 256
899
+ ],
900
+ "page_idx": 9
901
+ },
902
+ {
903
+ "type": "text",
904
+ "text": "Xavier Glorot and Yoshua Bengio. Understanding the difficulty of training deep feedforward neural networks. In Yee Whye Teh and Mike Titterington (eds.), Proceedings of the Thirteenth International Conference on Artificial Intelligence and Statistics, volume 9 of Proceedings of Machine Learning Research, pp. 249–256, Chia Laguna Resort, Sardinia, Italy, 13–15 May 2010. PMLR. ",
905
+ "bbox": [
906
+ 173,
907
+ 265,
908
+ 825,
909
+ 320
910
+ ],
911
+ "page_idx": 9
912
+ },
913
+ {
914
+ "type": "text",
915
+ "text": "Klaus Greff, Rupesh Kumar Srivastava, and Jurgen Schmidhuber. Highway and residual networks ¨ learn unrolled iterative estimation. CoRR, abs/1612.07771, 2016. ",
916
+ "bbox": [
917
+ 171,
918
+ 329,
919
+ 823,
920
+ 358
921
+ ],
922
+ "page_idx": 9
923
+ },
924
+ {
925
+ "type": "text",
926
+ "text": "Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. Deep residual learning for image recognition. CoRR, abs/1512.03385, 2015. ",
927
+ "bbox": [
928
+ 171,
929
+ 366,
930
+ 823,
931
+ 395
932
+ ],
933
+ "page_idx": 9
934
+ },
935
+ {
936
+ "type": "text",
937
+ "text": "Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. Identity Mappings in Deep Residual Networks, pp. 630–645. Springer International Publishing, Cham, 2016. ISBN 978-3-319-46493- 0. ",
938
+ "bbox": [
939
+ 176,
940
+ 404,
941
+ 823,
942
+ 445
943
+ ],
944
+ "page_idx": 9
945
+ },
946
+ {
947
+ "type": "text",
948
+ "text": "Geoffrey E. Hinton, Simon Osindero, and Yee-Whye Teh. A fast learning algorithm for deep belief nets. Neural Comput., 18(7):1527–1554, July 2006. ISSN 0899-7667. ",
949
+ "bbox": [
950
+ 169,
951
+ 454,
952
+ 825,
953
+ 483
954
+ ],
955
+ "page_idx": 9
956
+ },
957
+ {
958
+ "type": "text",
959
+ "text": "Sepp Hochreiter and Jurgen Schmidhuber. Long short-term memory. ¨ Neural Computation, 9(8): 1735–1780, November 1997. ISSN 0899-7667. ",
960
+ "bbox": [
961
+ 171,
962
+ 491,
963
+ 823,
964
+ 520
965
+ ],
966
+ "page_idx": 9
967
+ },
968
+ {
969
+ "type": "text",
970
+ "text": "S. Jastrzebski, D. Arpit, N. Ballas, V. Verma, T. Che, and Y. Bengio. Residual Connections Encourage Iterative Inference. CoRR, abs/1710.04773, October 2017. ",
971
+ "bbox": [
972
+ 171,
973
+ 529,
974
+ 823,
975
+ 558
976
+ ],
977
+ "page_idx": 9
978
+ },
979
+ {
980
+ "type": "text",
981
+ "text": "Li Jing, Yichen Shen, Tena Dubcek, John Peurifoy, Scott A. Skirlo, Max Tegmark, and Marin Soljacic. Tunable efficient unitary neural networks (EUNN) and their application to RNN. CoRR, abs/1612.05231, 2016. ",
982
+ "bbox": [
983
+ 173,
984
+ 565,
985
+ 823,
986
+ 608
987
+ ],
988
+ "page_idx": 9
989
+ },
990
+ {
991
+ "type": "text",
992
+ "text": "Li Jing, Cagla Gulcehre, John Peurifoy, Yichen Shen, Max Tegmark, Marin Soljaciˇ c, and Yoshua ´ Bengio. Gated Orthogonal Recurrent Units: On Learning to Forget. CoRR, abs/1706.02761, 2017. ",
993
+ "bbox": [
994
+ 173,
995
+ 616,
996
+ 823,
997
+ 659
998
+ ],
999
+ "page_idx": 9
1000
+ },
1001
+ {
1002
+ "type": "text",
1003
+ "text": "Diederik P. Kingma and Jimmy Ba. Adam: A method for stochastic optimization. In Proceedings of the 3rd International Conference on Learning Representations (ICLR), 2014. ",
1004
+ "bbox": [
1005
+ 171,
1006
+ 667,
1007
+ 823,
1008
+ 696
1009
+ ],
1010
+ "page_idx": 9
1011
+ },
1012
+ {
1013
+ "type": "text",
1014
+ "text": "Quoc V. Le, Navdeep Jaitly, and Geoffrey E. Hinton. A simple way to initialize recurrent networks of rectified linear units. CoRR, abs/1504.00941, 2015. ",
1015
+ "bbox": [
1016
+ 173,
1017
+ 705,
1018
+ 823,
1019
+ 734
1020
+ ],
1021
+ "page_idx": 9
1022
+ },
1023
+ {
1024
+ "type": "text",
1025
+ "text": "Yann Lecun, Leon Bottou, Yoshua Bengio, and Patrick Haffner. Gradient-based learning applied to ´ document recognition. Proceedings of the IEEE, 86(11):2278–2324, Nov 1998. ISSN 0018-9219. doi: 10.1109/5.726791. ",
1026
+ "bbox": [
1027
+ 174,
1028
+ 742,
1029
+ 823,
1030
+ 785
1031
+ ],
1032
+ "page_idx": 9
1033
+ },
1034
+ {
1035
+ "type": "text",
1036
+ "text": "James Martens and Ilya Sutskever. Learning recurrent neural networks with hessian-free optimization. In Proceedings of the 28th International Conference on Machine Learning, ICML 2011, Bellevue, Washington, USA, June 28 - July 2, 2011, pp. 1033–1040, 2011. ",
1037
+ "bbox": [
1038
+ 173,
1039
+ 792,
1040
+ 826,
1041
+ 837
1042
+ ],
1043
+ "page_idx": 9
1044
+ },
1045
+ {
1046
+ "type": "text",
1047
+ "text": "Dmytro Mishkin and Jiri Matas. All you need is a good init. CoRR, abs/1511.06422, 2015. ",
1048
+ "bbox": [
1049
+ 169,
1050
+ 844,
1051
+ 771,
1052
+ 859
1053
+ ],
1054
+ "page_idx": 9
1055
+ },
1056
+ {
1057
+ "type": "text",
1058
+ "text": "Daniel Neil, Michael Pfeiffer, and Shih-Chii Liu. Phased lstm: Accelerating recurrent network training for long or event-based sequences. In D. D. Lee, M. Sugiyama, U. V. Luxburg, I. Guyon, and R. Garnett (eds.), Advances in Neural Information Processing Systems 29, pp. 3882–3890. Curran Associates, Inc., 2016. ",
1059
+ "bbox": [
1060
+ 174,
1061
+ 867,
1062
+ 825,
1063
+ 924
1064
+ ],
1065
+ "page_idx": 9
1066
+ },
1067
+ {
1068
+ "type": "text",
1069
+ "text": "Razvan Pascanu, C¸ aglar Gulc¸ehre, Kyunghyun Cho, and Yoshua Bengio. How to construct deep ¨ recurrent neural networks. CoRR, abs/1312.6026, 2013. ",
1070
+ "bbox": [
1071
+ 171,
1072
+ 103,
1073
+ 825,
1074
+ 132
1075
+ ],
1076
+ "page_idx": 10
1077
+ },
1078
+ {
1079
+ "type": "text",
1080
+ "text": "Andrew M. Saxe, James L. McClelland, and Surya Ganguli. Exact solutions to the nonlinear dynamics of learning in deep linear neural networks. CoRR, abs/1312.6120, 2013. ",
1081
+ "bbox": [
1082
+ 171,
1083
+ 140,
1084
+ 821,
1085
+ 170
1086
+ ],
1087
+ "page_idx": 10
1088
+ },
1089
+ {
1090
+ "type": "text",
1091
+ "text": "Jurgen Schmidhuber. Learning complex, extended sequences using the principle of history com-¨ pression. Neural Computation, 4(2):234–242, March 1992. ISSN 0899-7667. ",
1092
+ "bbox": [
1093
+ 171,
1094
+ 179,
1095
+ 821,
1096
+ 208
1097
+ ],
1098
+ "page_idx": 10
1099
+ },
1100
+ {
1101
+ "type": "text",
1102
+ "text": "Rupesh K Srivastava, Klaus Greff, and Juergen Schmidhuber. Training very deep networks. In C. Cortes, N. D. Lawrence, D. D. Lee, M. Sugiyama, and R. Garnett (eds.), Advances in Neural Information Processing Systems 28, pp. 2377–2385. Curran Associates, Inc., 2015. ",
1103
+ "bbox": [
1104
+ 176,
1105
+ 217,
1106
+ 823,
1107
+ 260
1108
+ ],
1109
+ "page_idx": 10
1110
+ },
1111
+ {
1112
+ "type": "text",
1113
+ "text": "Tijmen Tieleman and Geoffrey Hinton. Lecture 6.5—RmsProp: Divide the gradient by a running average of its recent magnitude. COURSERA: Neural Networks for Machine Learning, 2012. ",
1114
+ "bbox": [
1115
+ 171,
1116
+ 267,
1117
+ 825,
1118
+ 297
1119
+ ],
1120
+ "page_idx": 10
1121
+ },
1122
+ {
1123
+ "type": "text",
1124
+ "text": "Andreas Veit, Michael J. Wilber, and Serge J. Belongie. Residual networks are exponential ensembles of relatively shallow networks. CoRR, abs/1605.06431, 2016. ",
1125
+ "bbox": [
1126
+ 171,
1127
+ 306,
1128
+ 823,
1129
+ 335
1130
+ ],
1131
+ "page_idx": 10
1132
+ },
1133
+ {
1134
+ "type": "text",
1135
+ "text": "Pascal Vincent, Hugo Larochelle, Yoshua Bengio, and Pierre-Antoine Manzagol. Extracting and composing robust features with denoising autoencoders. In Proceedings of the 25th International Conference on Machine Learning, ICML ’08, pp. 1096–1103, New York, NY, USA, 2008. ACM. ISBN 978-1-60558-205-4. ",
1136
+ "bbox": [
1137
+ 173,
1138
+ 343,
1139
+ 825,
1140
+ 400
1141
+ ],
1142
+ "page_idx": 10
1143
+ },
1144
+ {
1145
+ "type": "text",
1146
+ "text": "Jason Weston, Antoine Bordes, Sumit Chopra, and Tomas Mikolov. Towards ai-complete question answering: A set of prerequisite toy tasks. CoRR, abs/1502.05698, 2015. ",
1147
+ "bbox": [
1148
+ 171,
1149
+ 409,
1150
+ 823,
1151
+ 438
1152
+ ],
1153
+ "page_idx": 10
1154
+ },
1155
+ {
1156
+ "type": "text",
1157
+ "text": "Di Xie, Jiang Xiong, and Shiliang Pu. All you need is beyond a good init: Exploring better solution for training extremely deep convolutional neural networks with orthonormality and modulation. CoRR, abs/1703.01827, 2017. ",
1158
+ "bbox": [
1159
+ 171,
1160
+ 446,
1161
+ 823,
1162
+ 489
1163
+ ],
1164
+ "page_idx": 10
1165
+ },
1166
+ {
1167
+ "type": "text",
1168
+ "text": "Sergey Zagoruyko and Nikos Komodakis. DiracNets: Training Very Deep Neural Networks Without Skip-Connections. CoRR, abs/1706.00388, 2017. ",
1169
+ "bbox": [
1170
+ 173,
1171
+ 498,
1172
+ 825,
1173
+ 527
1174
+ ],
1175
+ "page_idx": 10
1176
+ },
1177
+ {
1178
+ "type": "text",
1179
+ "text": "A ALGEBRA OF EQS. 8–9 ",
1180
+ "text_level": 1,
1181
+ "bbox": [
1182
+ 176,
1183
+ 102,
1184
+ 403,
1185
+ 118
1186
+ ],
1187
+ "page_idx": 11
1188
+ },
1189
+ {
1190
+ "type": "text",
1191
+ "text": "Popular GNNs such as LSTM, GRU; and recent variants such as the Phased-LSTM (Neil et al., 2016), and Intersection RNN (Collins et al., 2017), share the same dual gate design described as follows: ",
1192
+ "bbox": [
1193
+ 173,
1194
+ 133,
1195
+ 825,
1196
+ 176
1197
+ ],
1198
+ "page_idx": 11
1199
+ },
1200
+ {
1201
+ "type": "equation",
1202
+ "img_path": "images/52eb6e19246e524800695ce14446c53919eeb15f994d0fcfc0b44e16fe44398a.jpg",
1203
+ "text": "$$\n\\mathbf h _ { t } = \\mathbf H _ { t } \\odot \\mathbf T _ { t } + \\mathbf h _ { t - 1 } \\odot \\mathbf C _ { t }\n$$",
1204
+ "text_format": "latex",
1205
+ "bbox": [
1206
+ 401,
1207
+ 179,
1208
+ 596,
1209
+ 195
1210
+ ],
1211
+ "page_idx": 11
1212
+ },
1213
+ {
1214
+ "type": "text",
1215
+ "text": "where $t \\in [ 1 , T ]$ , $\\mathbf H _ { t } = \\sigma ( \\mathbf x _ { t } , \\mathbf h _ { t - 1 } )$ represents the hidden transformation, $\\mathbf T _ { t } = \\tau ( \\mathbf x _ { t } , \\mathbf h _ { t - 1 } )$ is the transform gate, and $\\mathbf { C } _ { t } = \\phi ( \\mathbf { x } _ { t } , \\mathbf { h } _ { t - 1 } )$ is the carry gate. $\\sigma , \\tau$ and $\\phi$ are recurrent layers that have their trainable parameters and activation functions. $\\odot$ represents element-wise product operator. Note that $\\mathbf { h } _ { t }$ may not be the output activation at the recurrent step $t$ . For example in LSTM, $\\mathbf { h } _ { t }$ represents the memory cell state. Typically, the elements of transform gate $\\mathbf { T } _ { t , k }$ and carry gate $\\mathbf { C } _ { t , k }$ are between 0 (close) and 1 (open), the value indicates the openness of the gate at the $k$ th neuron. Hence, a plain recurrent network is a subcase of Eq. 14 when $\\mathbf { T } _ { t } = \\mathbf { 1 }$ and $\\mathbf { C } _ { t } = \\mathbf { 0 }$ . ",
1216
+ "bbox": [
1217
+ 173,
1218
+ 200,
1219
+ 825,
1220
+ 300
1221
+ ],
1222
+ "page_idx": 11
1223
+ },
1224
+ {
1225
+ "type": "text",
1226
+ "text": "Note that conventionally, the initial hidden activation $\\mathbf { h } _ { 0 }$ is 0 to represent a “void state” at the start of computation. For $\\mathbf { h } _ { 0 }$ to fit into Eq. 4’s framework, we define an auxiliary state $\\mathbf { h } _ { - 1 }$ as the previous state of $\\mathbf { h } _ { 0 }$ , and $\\mathbf { T } _ { 0 } = \\mathbf { 1 }$ , $\\mathbf { C } _ { 0 } = \\mathbf { 0 }$ . We also define another auxiliary state ${ \\bf h } _ { T + 1 } = { \\bf h } _ { T }$ , $\\mathbf { T } _ { T + 1 } = \\mathbf { 0 }$ , and ${ \\bf C } _ { T + 1 } = { \\bf 1 }$ as the succeeding state of $\\mathbf { h } _ { T }$ . ",
1227
+ "bbox": [
1228
+ 174,
1229
+ 305,
1230
+ 825,
1231
+ 363
1232
+ ],
1233
+ "page_idx": 11
1234
+ },
1235
+ {
1236
+ "type": "text",
1237
+ "text": "Based on the recursive definition in Eq. 4, we can write the final layer output $\\mathbf { h } _ { T }$ as follows: ",
1238
+ "bbox": [
1239
+ 173,
1240
+ 368,
1241
+ 774,
1242
+ 383
1243
+ ],
1244
+ "page_idx": 11
1245
+ },
1246
+ {
1247
+ "type": "equation",
1248
+ "img_path": "images/747ea03947b1cafc11b462211e0a12ff4064eea8a20c7765d746f655de2204dc.jpg",
1249
+ "text": "$$\n\\mathbf { h } _ { T } = \\mathbf { h } _ { 0 } \\odot \\prod _ { t = 1 } ^ { T } \\mathbf { C } _ { t } + \\sum _ { t = 1 } ^ { T } \\left( \\mathbf { H } _ { t } \\odot \\mathbf { T } _ { t } \\odot \\prod _ { i = t + 1 } ^ { T + 1 } \\mathbf { C } _ { i } \\right)\n$$",
1250
+ "text_format": "latex",
1251
+ "bbox": [
1252
+ 330,
1253
+ 391,
1254
+ 666,
1255
+ 436
1256
+ ],
1257
+ "page_idx": 11
1258
+ },
1259
+ {
1260
+ "type": "text",
1261
+ "text": "where we use $\\prod$ to represent element-wise multiplication over a series of terms. ",
1262
+ "bbox": [
1263
+ 176,
1264
+ 444,
1265
+ 697,
1266
+ 460
1267
+ ],
1268
+ "page_idx": 11
1269
+ },
1270
+ {
1271
+ "type": "text",
1272
+ "text": "According to Eq. 3, and supposing that Eq. 5 fulfills the Eq. 1, we can use a zero-mean residual $\\epsilon _ { t }$ for describing the difference between the outputs of recurrent steps: ",
1273
+ "bbox": [
1274
+ 171,
1275
+ 465,
1276
+ 820,
1277
+ 496
1278
+ ],
1279
+ "page_idx": 11
1280
+ },
1281
+ {
1282
+ "type": "equation",
1283
+ "img_path": "images/f48a15dbd59ed48f84dbee0ee4b9064d76f2a49f5b667cff61b244c1a3317dc0.jpg",
1284
+ "text": "$$\n\\begin{array} { c } { \\mathbf { h } _ { t } - \\mathbf { h } _ { t - 1 } = \\pmb { \\epsilon } _ { t } } \\\\ { \\mathbf { \\epsilon } _ { \\mathbf { \\epsilon } _ { 0 } } = \\mathbf { 0 } } \\end{array}\n$$",
1285
+ "text_format": "latex",
1286
+ "bbox": [
1287
+ 444,
1288
+ 503,
1289
+ 553,
1290
+ 540
1291
+ ],
1292
+ "page_idx": 11
1293
+ },
1294
+ {
1295
+ "type": "text",
1296
+ "text": "Then we can rewrite Eq. 16 as: ",
1297
+ "bbox": [
1298
+ 174,
1299
+ 547,
1300
+ 379,
1301
+ 561
1302
+ ],
1303
+ "page_idx": 11
1304
+ },
1305
+ {
1306
+ "type": "equation",
1307
+ "img_path": "images/caa2cbae5549d306d85398dd83c59ec7ae391fb3e6a54e2dd1bffdb496d8acba.jpg",
1308
+ "text": "$$\n\\mathbf { H } _ { t } \\odot \\mathbf { T } _ { t } + \\mathbf { h } _ { t - 1 } \\odot \\mathbf { C } _ { t } = \\mathbf { h } _ { t - 1 } + \\epsilon _ { t }\n$$",
1309
+ "text_format": "latex",
1310
+ "bbox": [
1311
+ 377,
1312
+ 570,
1313
+ 620,
1314
+ 588
1315
+ ],
1316
+ "page_idx": 11
1317
+ },
1318
+ {
1319
+ "type": "text",
1320
+ "text": "Substituting Eq. 18 into Eq. 15: ",
1321
+ "bbox": [
1322
+ 174,
1323
+ 595,
1324
+ 383,
1325
+ 611
1326
+ ],
1327
+ "page_idx": 11
1328
+ },
1329
+ {
1330
+ "type": "equation",
1331
+ "img_path": "images/a59908923469cbdd34b6c3afe783af4780823b81d1e05abf6624ca7db8c90d0c.jpg",
1332
+ "text": "$$\n\\begin{array} { r l } & { \\mathbf { h } _ { T } = \\mathbf { h } _ { 0 } \\odot \\displaystyle \\prod _ { t = 1 } ^ { T } \\mathbf { C } _ { t } + \\sum _ { t = 1 } ^ { T } \\left( \\left( \\left( 1 - \\mathbf { C } _ { t } \\right) \\odot \\mathbf { h } _ { t - 1 } + \\boldsymbol { \\epsilon } _ { t } \\right) \\odot \\prod _ { j = t + 1 } ^ { T + 1 } \\mathbf { C } _ { j } \\right) } \\\\ & { \\mathbf { \\Theta } = \\mathbf { h } _ { 0 } \\odot \\displaystyle \\prod _ { t = 1 } ^ { T } \\mathbf { C } _ { t } + \\sum _ { t = 1 } ^ { T } \\left( \\left( \\left( 1 - \\mathbf { C } _ { t } \\right) \\odot \\left( \\mathbf { h } _ { 0 } + \\sum _ { i = 1 } ^ { t - 1 } \\boldsymbol { \\epsilon } _ { i } \\right) + \\boldsymbol { \\epsilon } _ { t } \\right) \\odot \\prod _ { j = t + 1 } ^ { T + 1 } \\mathbf { C } _ { j } \\right) } \\end{array}\n$$",
1333
+ "text_format": "latex",
1334
+ "bbox": [
1335
+ 236,
1336
+ 619,
1337
+ 759,
1338
+ 720
1339
+ ],
1340
+ "page_idx": 11
1341
+ },
1342
+ {
1343
+ "type": "text",
1344
+ "text": "We can rearrange Eqn. 20 to ",
1345
+ "bbox": [
1346
+ 174,
1347
+ 728,
1348
+ 362,
1349
+ 742
1350
+ ],
1351
+ "page_idx": 11
1352
+ },
1353
+ {
1354
+ "type": "equation",
1355
+ "img_path": "images/7cbfa1f8fbdfb0193a928e286205787fdfb607be4d104f6eb6bf9794cf451891.jpg",
1356
+ "text": "$$\n\\begin{array} { l } { { \\displaystyle { \\bf h } _ { T } = { \\bf h } _ { 0 } \\odot \\left( \\sum _ { t = 0 } ^ { T } ( { \\bf 1 } - { \\bf C } _ { t } ) \\prod _ { i = t + 1 } ^ { T + 1 } { \\bf C } _ { i } \\right) + \\lambda } \\ ~ } \\\\ { { \\displaystyle ~ = { \\bf h } _ { 0 } \\odot \\left( { \\bf C } _ { T + 1 } - \\prod _ { t = 0 } ^ { T + 1 } { \\bf C } _ { t } \\right) + \\lambda } \\ ~ } \\\\ { { \\displaystyle ~ = { \\bf h } _ { 0 } + \\lambda } \\ ~ } \\end{array}\n$$",
1357
+ "text_format": "latex",
1358
+ "bbox": [
1359
+ 356,
1360
+ 751,
1361
+ 640,
1362
+ 858
1363
+ ],
1364
+ "page_idx": 11
1365
+ },
1366
+ {
1367
+ "type": "text",
1368
+ "text": "where ",
1369
+ "bbox": [
1370
+ 173,
1371
+ 866,
1372
+ 217,
1373
+ 880
1374
+ ],
1375
+ "page_idx": 11
1376
+ },
1377
+ {
1378
+ "type": "equation",
1379
+ "img_path": "images/772b6e870de94e3ae22f3fcc010cf63bc451e102385be645a362880d26734581.jpg",
1380
+ "text": "$$\n\\lambda = \\sum _ { t = 1 } ^ { T } \\lambda _ { t } = \\sum _ { t = 1 } ^ { T } \\left( \\left( \\left( \\mathbf { 1 } - \\mathbf { C } _ { t } \\right) \\odot \\sum _ { i = 1 } ^ { t - 1 } \\epsilon _ { i } + \\epsilon _ { t } \\right) \\odot \\prod _ { j = t + 1 } ^ { T + 1 } \\mathbf { C } _ { j } \\right)\n$$",
1381
+ "text_format": "latex",
1382
+ "bbox": [
1383
+ 289,
1384
+ 878,
1385
+ 705,
1386
+ 929
1387
+ ],
1388
+ "page_idx": 11
1389
+ },
1390
+ {
1391
+ "type": "text",
1392
+ "text": "The term $\\boldsymbol { \\lambda }$ in Eq. 23 can be reorganized to, ",
1393
+ "bbox": [
1394
+ 174,
1395
+ 103,
1396
+ 462,
1397
+ 118
1398
+ ],
1399
+ "page_idx": 12
1400
+ },
1401
+ {
1402
+ "type": "equation",
1403
+ "img_path": "images/8872162e65a42790632594741a9870952de38b926fff0d38aa6e896c59bea5c2.jpg",
1404
+ "text": "$$\n\\begin{array} { l } { { \\displaystyle \\lambda = \\sum _ { t = 1 } ^ { T } \\lambda _ { t } = \\sum _ { t = 1 } ^ { T } \\left( \\left( \\left( \\mathbf { 1 } - \\mathbf { C } _ { t } \\right) \\odot \\sum _ { i = 1 } ^ { t - 1 } \\epsilon _ { i } + \\epsilon _ { t } \\right) \\odot \\prod _ { j = t + 1 } ^ { T + 1 } \\mathbf { C } _ { j } \\right) } } \\\\ { { \\displaystyle ~ = \\sum _ { t = 1 } ^ { T } \\left( \\left( \\sum _ { i = 1 } ^ { t } \\epsilon _ { i } - \\mathbf { C } _ { t } \\odot \\sum _ { i = 0 } ^ { t - 1 } \\epsilon _ { i } \\right) \\odot \\prod _ { j = t + 1 } ^ { T + 1 } \\mathbf { C } _ { j } \\right) } } \\\\ { { \\displaystyle ~ = \\sum _ { t = 1 } ^ { T } \\left( \\sum _ { i = 1 } ^ { t } \\epsilon _ { i } \\odot \\prod _ { j = t + 1 } ^ { T + 1 } \\mathbf { C } _ { j } - \\sum _ { i = 0 } ^ { t - 1 } \\epsilon _ { i } \\odot \\prod _ { j = t } ^ { T } \\mathbf { C } _ { j } \\right) } } \\end{array}\n$$",
1405
+ "text_format": "latex",
1406
+ "bbox": [
1407
+ 290,
1408
+ 125,
1409
+ 705,
1410
+ 277
1411
+ ],
1412
+ "page_idx": 12
1413
+ },
1414
+ {
1415
+ "type": "text",
1416
+ "text": "B DETAILS IN THE ADDING PROBLEM EXPERIMENTS ",
1417
+ "text_level": 1,
1418
+ "bbox": [
1419
+ 173,
1420
+ 102,
1421
+ 632,
1422
+ 118
1423
+ ],
1424
+ "page_idx": 13
1425
+ },
1426
+ {
1427
+ "type": "text",
1428
+ "text": "Fig. 5 presents the MSE plots during the training phase. As we discussed in Section 3.1, the choice of ReLU can occur some degree of instability during the training. Compared to RINs, IRNNs are much more unstable in $T _ { 3 } = 4 0 0$ . ",
1429
+ "bbox": [
1430
+ 173,
1431
+ 133,
1432
+ 825,
1433
+ 176
1434
+ ],
1435
+ "page_idx": 13
1436
+ },
1437
+ {
1438
+ "type": "image",
1439
+ "img_path": "images/8c5d1d6089348c9e94fd491d62dc0b61947fad2f27dcc82e104927507ca7b5c6.jpg",
1440
+ "image_caption": [
1441
+ "Figure 5: Mean Squared Error (MSE) plots for the adding problem with different sequence lengths at training phase. The figures are presented in log scale. All models are trained up to 300 epochs. "
1442
+ ],
1443
+ "image_footnote": [],
1444
+ "bbox": [
1445
+ 197,
1446
+ 198,
1447
+ 813,
1448
+ 388
1449
+ ],
1450
+ "page_idx": 13
1451
+ },
1452
+ {
1453
+ "type": "text",
1454
+ "text": "C DETAILS IN SEQUENTIAL AND PERMUTED MNIST EXPERIMENTS ",
1455
+ "text_level": 1,
1456
+ "bbox": [
1457
+ 169,
1458
+ 102,
1459
+ 758,
1460
+ 118
1461
+ ],
1462
+ "page_idx": 14
1463
+ },
1464
+ {
1465
+ "type": "text",
1466
+ "text": "Fig. 6–7 show all training and testing curves for Sequential and Permuted MNIST experiments. \nRINs and RIN-DTs converge much faster than IRNNs and LSTMs. ",
1467
+ "bbox": [
1468
+ 173,
1469
+ 133,
1470
+ 821,
1471
+ 161
1472
+ ],
1473
+ "page_idx": 14
1474
+ },
1475
+ {
1476
+ "type": "image",
1477
+ "img_path": "images/20d94115c13df76adcee7abf908a563310a0c1bdc2b8a0d1abb2bb2883b32ec7.jpg",
1478
+ "image_caption": [
1479
+ "Figure 6: (a) and (b) show the training loss and accuracy plots for Sequential MNIST; (c) and (d) present training loss and accuracy plots for Permuted MNIST. We use blue color palette to represent RIN experiments, orange color palette to represent IRNN experiments, purple color palette to represent LSTM experiments and green color palette to represent RIN-DT experiments. RINs and RIN-DTs are much better than IRNNs and LSTMs in the early stage of training (first 200 epochs). "
1480
+ ],
1481
+ "image_footnote": [],
1482
+ "bbox": [
1483
+ 199,
1484
+ 183,
1485
+ 813,
1486
+ 608
1487
+ ],
1488
+ "page_idx": 14
1489
+ },
1490
+ {
1491
+ "type": "image",
1492
+ "img_path": "images/f645842c3b09cce04a0589c05006910b68081f3cd473bd837292a05269b6682a.jpg",
1493
+ "image_caption": [
1494
+ "Figure 7: (a) and (b) show the test loss and accuracy plots for Sequential MNIST; (c) and (d) present test loss and accuracy plots for Permuted MNIST. "
1495
+ ],
1496
+ "image_footnote": [],
1497
+ "bbox": [
1498
+ 199,
1499
+ 111,
1500
+ 813,
1501
+ 536
1502
+ ],
1503
+ "page_idx": 15
1504
+ },
1505
+ {
1506
+ "type": "image",
1507
+ "img_path": "images/dc6e1b90fb320db9697eb1225a031764d767db0c1ad33ea72f33e4120988e1ed.jpg",
1508
+ "image_caption": [
1509
+ "Fig. 8–12 show validation of the Iterative Estimation hypothesis in all network types. ",
1510
+ "Figure 8: Evidence of learning identity mapping in RIN, IRNN and LSTM for network type 1–100 over a batch of 128 samples. (a) evaluates Eq. 1 and (b) evaluates Eq. 3. "
1511
+ ],
1512
+ "image_footnote": [],
1513
+ "bbox": [
1514
+ 200,
1515
+ 145,
1516
+ 803,
1517
+ 310
1518
+ ],
1519
+ "page_idx": 16
1520
+ },
1521
+ {
1522
+ "type": "image",
1523
+ "img_path": "images/241dfed27d728bbac4b7f87c080df4bf3b2a8126efd9dfaf889391c22b11c47c.jpg",
1524
+ "image_caption": [
1525
+ "Figure 9: Evidence of learning identity mapping in RIN, IRNN and LSTM for network type 2–100 over a batch of 128 samples. (a) evaluates Eq. 1 and (b) evaluates Eq. 3. "
1526
+ ],
1527
+ "image_footnote": [],
1528
+ "bbox": [
1529
+ 220,
1530
+ 378,
1531
+ 776,
1532
+ 693
1533
+ ],
1534
+ "page_idx": 16
1535
+ },
1536
+ {
1537
+ "type": "image",
1538
+ "img_path": "images/79b5650d9e9727ddb5a68d5a729a863babf0168b770a4becab5c0b78d77a0c61.jpg",
1539
+ "image_caption": [
1540
+ "Figure 10: Evidence of learning identity mapping in RIN, IRNN and LSTM for network type 2–200 over a batch of 128 samples. (a) evaluates Eq. 1 and $\\mathbf { ( b ) }$ evaluates Eq. 3. "
1541
+ ],
1542
+ "image_footnote": [],
1543
+ "bbox": [
1544
+ 220,
1545
+ 138,
1546
+ 776,
1547
+ 450
1548
+ ],
1549
+ "page_idx": 17
1550
+ },
1551
+ {
1552
+ "type": "image",
1553
+ "img_path": "images/12930052951b63b10a67ac7fadb27fcbf018df19c8c3ede635f92cd0772c1238.jpg",
1554
+ "image_caption": [
1555
+ "Figure 11: Evidence of learning identity mapping in RIN, IRNN and LSTM for network type 3–100 over a batch of 128 samples. (a) evaluates Eq. 1 and $\\mathbf { ( b ) }$ evaluates Eq. 3. "
1556
+ ],
1557
+ "image_footnote": [],
1558
+ "bbox": [
1559
+ 220,
1560
+ 559,
1561
+ 777,
1562
+ 856
1563
+ ],
1564
+ "page_idx": 17
1565
+ },
1566
+ {
1567
+ "type": "image",
1568
+ "img_path": "images/f46cee661148d3b0663fcaf916c349e00d5406b09841eba6dfafc689596fd99d.jpg",
1569
+ "image_caption": [
1570
+ "Figure 12: Evidence of learning identity mapping in RIN, IRNN and LSTM for network type 3–200 over a batch of 128 samples. (a) evaluates Eq. 1 and $\\mathbf { ( b ) }$ evaluates Eq. 3. "
1571
+ ],
1572
+ "image_footnote": [],
1573
+ "bbox": [
1574
+ 220,
1575
+ 349,
1576
+ 776,
1577
+ 645
1578
+ ],
1579
+ "page_idx": 18
1580
+ },
1581
+ {
1582
+ "type": "text",
1583
+ "text": "D RINS WITH DEEP TRANSITIONS ",
1584
+ "text_level": 1,
1585
+ "bbox": [
1586
+ 174,
1587
+ 102,
1588
+ 477,
1589
+ 118
1590
+ ],
1591
+ "page_idx": 19
1592
+ },
1593
+ {
1594
+ "type": "text",
1595
+ "text": "In Section 3.2, we tested an additional model for RINs, which takes the concept of Deep Transition Networks (DTNs) Pascanu et al. (2013). Instead of stacking the recurrent layers, DTNs add multiple nonlinear transitions in a single recurrent step. This modification massively increases the depth of the network. In our RIN-DTs, the number of transition per recurrent step is two. Because the length of the sequence for Sequential and Permuted MNIST tasks is 784, RIN-DTs have the depth of $7 8 4 \\times 2 = 1 5 6 8$ . The recurrent layer is defined in Eqs. 26–27. ",
1596
+ "bbox": [
1597
+ 174,
1598
+ 132,
1599
+ 825,
1600
+ 217
1601
+ ],
1602
+ "page_idx": 19
1603
+ },
1604
+ {
1605
+ "type": "equation",
1606
+ "img_path": "images/c9955b7c8c35772a3135439627d234c379285b8d3861d888bb1ec0214ad5104a.jpg",
1607
+ "text": "$$\n\\begin{array} { r l } & { \\hat { \\mathbf { h } } _ { t } = f ( \\mathbf { W } _ { 1 } \\mathbf { x } _ { t } + ( \\mathbf { U } _ { 1 } + \\mathbf { I } ) \\mathbf { h } _ { t - 1 } + \\mathbf { b } _ { 1 } ) } \\\\ & { \\mathbf { h } _ { t } = f ( ( \\mathbf { U } _ { 2 } + \\mathbf { I } ) \\hat { \\mathbf { h } } _ { t } + \\mathbf { b } _ { 2 } ) } \\end{array}\n$$",
1608
+ "text_format": "latex",
1609
+ "bbox": [
1610
+ 367,
1611
+ 242,
1612
+ 629,
1613
+ 286
1614
+ ],
1615
+ "page_idx": 19
1616
+ }
1617
+ ]
parse/train/Hyp3i2xRb/Hyp3i2xRb_middle.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/Hyp3i2xRb/Hyp3i2xRb_model.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/QkljT4mrfs/QkljT4mrfs.md ADDED
@@ -0,0 +1,219 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Partial success in closing the gap between human and machine vision
2
+
3
+ Robert Geirhos1-2§ Kantharaju Narayanappa1 Benjamin Mitzkus1
4
+
5
+ Tizian Thieringer1 Matthias Bethge1∗ Felix A. Wichmann1∗ Wieland Brendel1∗
6
+
7
+ 1University of Tübingen 2International Max Planck Research School for Intelligent Systems ∗Joint senior authors §To whom correspondence should be addressed: robert.geirhos@uni-tuebingen.de
8
+
9
+ # Abstract
10
+
11
+ A few years ago, the first CNN surpassed human performance on ImageNet. However, it soon became clear that machines lack robustness on more challenging test cases, a major obstacle towards deploying machines “in the wild” and towards obtaining better computational models of human visual perception. Here we ask: Are we making progress in closing the gap between human and machine vision? To answer this question, we tested human observers on a broad range of out-ofdistribution (OOD) datasets, recording 85,120 psychophysical trials across 90 participants. We then investigated a range of promising machine learning developments that crucially deviate from standard supervised CNNs along three axes: objective function (self-supervised, adversarially trained, CLIP language-image training), architecture (e.g. vision transformers), and dataset size (ranging from 1M to 1B).
12
+
13
+ Our findings are threefold. (1.) The longstanding distortion robustness gap between humans and CNNs is closing, with the best models now exceeding human feedforward performance on most of the investigated OOD datasets. (2.) There is still a substantial image-level consistency gap, meaning that humans make different errors than models. In contrast, most models systematically agree in their categorisation errors, even substantially different ones like contrastive self-supervised vs. standard supervised models. (3.) In many cases, human-to-model consistency improves when training dataset size is increased by one to three orders of magnitude. Our results give reason for cautious optimism: While there is still much room for improvement, the behavioural difference between human and machine vision is narrowing. In order to measure future progress, 17 OOD datasets with image-level human behavioural data and evaluation code are provided as a toolbox and benchmark at https://github.com/bethgelab/model-vs-human/.
14
+
15
+ # 1 Introduction
16
+
17
+ Looking back at the last decade, deep learning has made tremendous leaps of progress by any standard. What started in 2012 with AlexNet [1] as the surprise winner of the ImageNet Large-Scale Visual Recognition Challenge quickly became the birth of a new AI “summer”, a summer lasting much longer than just a season. With it, just like with any summer, came great expectations: the hope that the deep learning revolution will see widespread applications in industry, that it will propel breakthroughs in the sciences, and that it will ultimately close the gap between human and machine perception. We have now reached the point where deep learning has indeed become a significant driver of progress in industry [e.g. 2, 3], and where many disciplines are employing deep learning for scientific discoveries [4–9]—but are we making progress in closing the gap between human and machine vision?
18
+
19
+ IID vs. OOD benchmarking. For a long time, the gap between human and machine vision was mainly approximated by comparing benchmark accuracies on IID (independent and identically distributed) test data: as long as models are far from reaching human-level performance on challenging datasets like ImageNet, this approach is adequate [10]. Currently, models are routinely matching and in many cases even outperforming humans on IID data. At the same time, it is becoming increasingly clear that models systematically exploit shortcuts shared between training and test data [11–14]. Therefore we are witnessing a major shift towards measuring model performance on out-of-distribution (OOD) data rather than IID data alone, which aims at testing models on more challenging test cases where there is still a ground truth category, but certain image statistics differ from the training distribution. Many OOD generalisation tests have been proposed: ImageNet-C [15] for corrupted imaes, ImageNet-Sketch [16] for sketches, Stylized-ImageNet [17] for image style changes, [18] for unfamiliar object poses, and many more [19–29]. While it is great to have many viable and valuable options to measure generalisation, most of these datasets unfortunately lack human comparison data. This is less than ideal, since we can no longer assume that humans reach near-ceiling accuracies on these challenging test cases as they do on standard noise-free IID object recognition datasets. In order to address this issue, we carefully tested human observers in the Wichmannlab’s vision laboratory on a broad range of OOD datasets, providing some 85K psychophysical trials across 90 participants. Crucially, we showed exactly the same images to multiple observers, which means that we are able to compare human and machine vision on the fine-grained level of individual images [30–32]). The focus of our datasets is measuring distortion robustness: we tested 17 variations that include changes to image style, texture, and various forms of synthetic additive noise.
20
+
21
+ Contributions & outlook. The resulting 17 OOD datasets with large-scale human comparion data enable us to investigate recent exciting machine learning developments that crucially deviate from “vanilla” CNNs along three axes: objective function (supervised vs. self-supervised, adversarially trained, and CLIP’s joint language-image training), architecture (convolutional vs. vision transformer) and training dataset size (ranging from 1M to 1B images). Taken together, these are some of the most promising directions our field has developed to date—but this field would not be machine learning if new breakthroughs weren’t within reach in the next few weeks, months and years. Therefore, we open-sourced modelvshuman, a Python toolbox that enables testing both PyTorch and TensorFlow models on our comprehensive benchmark suite of OOD generalisation data in order to measure future progress. Even today, our results give cause for (cautious) optimism. After a method overview (Section 2), we are able to report that the human-machine distortion robustness gap is closing: the best models now match or in many cases even exceed human feedforward performance on most of the investigated OOD datasets (Section 3). While there is still a substantial image-level consistency gap between humans and machines, this gap is narrowing on some—but not all—datasets when the size of the training dataset is increased (Section 4).
22
+
23
+ # 2 Methods: datasets, psychophysical experiments, models, metrics, toolbox
24
+
25
+ OOD datasets with consistency-grade human data. We collected human data for 17 generalisation datasets (visualized in Figures 7 and 8 in the Appendix, which also state the number of subjects and trials per experiment) on a carefully calibrated screen in a dedicated psychophysical laboratory (a total of 85,120 trials across 90 observers). Five datasets each correspond to a single manipulation (sketches, edge-filtered images, silhouettes, images with a texture-shape cue conflict, and stylized images where the original image texture is replaced by the style of a painting); the remaining twelve datasets correspond to parametric image degradations (e.g. different levels of noise or blur). Those OOD datasets have in common that they are designed to test ImageNet-trained models. OOD images were obtained from different sources: sketches from ImageNet-Sketch [16], stylized images from
26
+
27
+ Stylized-ImageNet [17], edge-filtered images, silhouettes and cue conflict images from $[ 1 7 ] ^ { 1 }$ , and the remaining twelve parametric datasets were adapted from [33]. For these parametric datasets, [33] collected human accuracies but unfortunately, they showed different images to different observers implying that we cannot use their human data to assess image-level consistency between humans and machines. Thus we collected psychophysical data for those images ourselves by showing exactly the same images to multiple observers for each of those twelve datasets. Additionally, we cropped the images from [33] to $2 2 4 \times 2 2 4$ pixels to allow for a fair comparison to ImageNet models (all models included in our comparison receive $2 2 4 \times 2 2 4$ input images; [33] showed $2 5 6 \times 2 5 6$ images to human observers in many cases).
28
+
29
+ Psychophysical experiments. 90 observers were tested in a darkened chamber. Stimuli were presented at the center of a $2 2 '$ monitor with $1 9 2 0 \times 1 2 0 0$ pixels resolution (refresh rate: $1 2 0 \mathrm { H z } ,$ ). Viewing distance was $1 0 7 \mathrm { c m }$ and target images subtended $3 \times 3$ degrees of visual angle. Human observers were presented with an image and asked to select the correct category out of 16 basic categories (such as chair, dog, airplane, etc.). Stimuli were balanced w.r.t. classes and presented in random order. For ImageNet-trained models, in order to obtain a choice from the same 16 categories, the 1,000 class decision vector was mapped to those 16 classes using the WordNet hierarchy [34]. In Appendix I, we explain why this mapping is optimal. We closely followed the experimental protocol defined by [33], who presented images for $2 0 0 ~ \mathrm { { m s } }$ followed by a $1 / f$ backward mask to limit the influence of recurrent processing (otherwise comparing to feedforward models would be difficult). Further experimental details are provided in Appendix C.
30
+
31
+ Why not use crowdsourcing instead? Our approach of investigating few observers in a highquality laboratory setting performing many trials is known as the so-called “small-N design”, the bread-and-butter approach in high-quality psychophysics—see, e.g., the review “Small is beautiful: In defense of the small-N design” [35]. This is in contrast to the “crowdsourcing approach” (many observers in a noisy setting performing fewer trials each). The highly controlled conditions of the Wichmannlab’s psychophysical laboratory come with many advantages over crowdsourced data collection: precise timing control (down to the millisecond), carefully calibrated monitors (especially important for e.g. low-contrast stimuli), controlled viewing distance (important for foveal presentation), full visual acuity (we performed an acuity test with every observer prior to the experiment), observer attention (e.g. no multitasking or children running around during an experiment, which may happen in a crowdsourcing study), just to name a few [36]. Jointly, these factors contribute to high data quality.
32
+
33
+ Models. In order to disentangle the influence of objective function, architecture and training dataset size, we tested a total of 52 models: 24 standard ImageNet-trained CNNs [37], 8 selfsupervised models [38–43], $^ 2 6$ Big Transfer models [45], 5 adversarially trained models [46], 5 vision transformers [47, 48], two semi-weakly supervised models [49] as well as Noisy Student [50] and CLIP [51]. Technical details for all models are provided in the Appendix.
34
+
35
+ Metrics. In addition to $o o D$ accuracy (averaged across conditions and datasets), the following three metrics quantify how closely machines are aligned with the decision behaviour of humans.
36
+
37
+ Accuracy difference $A ( m )$ is a simple aggregate measure that compares the accuracy of a machine $m$ to the accuracy of human observers in different out-of-distribution tests,
38
+
39
+ $$
40
+ A ( m ) : \mathbb { R } \to [ 0 , 1 ] , m \mapsto { \frac { 1 } { | D | } } \sum _ { d \in D } { \frac { 1 } { | H _ { d } | } } \sum _ { h \in H _ { d } } { \frac { 1 } { | C _ { d } | } } \sum _ { c \in C _ { d } } ( \operatorname { a c c } _ { d , c } ( h ) - \operatorname { a c c } _ { d , c } ( m ) ) ^ { 2 }
41
+ $$
42
+
43
+ where $\operatorname { a c c } _ { d , c } ( \cdot )$ is the accuracy of the model or the human on dataset $d \in D$ and condition $c \in C _ { d }$ (e.g. a particular noise level), and $h \in H _ { D }$ denotes a human observer tested on dataset $d$ . Analogously, one can compute the average accuracy difference between a human observer $h _ { 1 }$ and all other human observers by substituting $h _ { 1 }$ for $m$ and $h \in H _ { D } \setminus \{ h _ { 1 } \}$ for $h \in H _ { D }$ (which can also be applied for the two metrics defined below).
44
+
45
+ Aggregated metrics like $A ( m )$ ignore individual image-level decisions. Two models with vastly different image-level decision behaviour might still end up with the same accuracies on each dataset and condition. Hence, we include two additional metrics in our benchmark that are sensitive to decisions on individual images.
46
+
47
+ Observed consistency $O ( m )$ [32] measures the fraction of samples for which humans and a model $m$ get the same sample either both right or both wrong. More precisely, let $b _ { h , m } ( s )$ be one if both a human observer $h$ and $m$ decide either correctly or incorrectly on a given sample $s$ , and zero otherwise. We calculate the average observed consistency as
48
+
49
+ $$
50
+ O ( m ) : \mathbb { R } \to [ 0 , 1 ] , m \mapsto \frac { 1 } { | D | } \sum _ { d \in D } \frac { 1 } { | H _ { d } | } \sum _ { h \in H _ { d } } \frac { 1 } { | C _ { d } | } \sum _ { c \in C _ { d } } \frac { 1 } { | S _ { d , c } | } \sum _ { s \in S _ { d , c } } b _ { h , m } ( s )
51
+ $$
52
+
53
+ where $s \in S _ { d , c }$ denotes a sample $s$ (in our case, an image) of condition $c$ from dataset $d$ . Note that this measure can only be zero if the accuracy of $h$ and $m$ are exactly the same in each dataset and condition.
54
+
55
+ Error consistency $E ( m )$ [32] tracks whether there is above-chance consistency. This is an important distinction, since e.g. two decision makers with $9 5 \%$ accuracy each will have at least $90 \%$ observed consistency, even if their $5 \%$ errors occur on non-overlapping subsets of the test data (intuitively, they both get most images correct and thus observed overlap is high). To this end, error consistency (a.k.a. Cohen’s kappa, cf. [52]) indicates whether the observed consistency is larger than what could have been expected given two independent binomial decision makers with matched accuracy, which we denote as $\hat { o } _ { h , m }$ . This can easily be computed analytically [e.g. 32, equation 1]. Then, the average error consistency is given by
56
+
57
+ $$
58
+ E ( m ) : \mathbb { R } \to [ - 1 , 1 ] , m \mapsto \frac { 1 } { | D | } \sum _ { d \in D } \frac { 1 } { | H _ { d } | } \sum _ { h \in H _ { d } } \frac { 1 } { | C _ { d } | } \sum _ { c \in C _ { d } } \frac { \big ( \frac { 1 } { | S _ { d , c } | } \sum _ { s \in S _ { d , c } } b _ { h , m } ( s ) \big ) - \hat { o } _ { h , m } ( S _ { d , c } ) } { 1 - \hat { o } _ { h , m } ( S _ { d , c } ) }
59
+ $$
60
+
61
+ Benchmark $\pmb { \& }$ toolbox. $A ( m ) , O ( m )$ and $E ( m )$ each quantify a certain aspect of the humanmachine gap. We use the mean rank order across these metrics to determine an overall model ranking (Table 2 in the Appendix). However, we would like to emphasise that the primary purpose of this benchmark is to generate insights, not winners. Since insights are best gained from detailed plots and analyses, we open-source modelvshuman, a Python project to benchmark models against human data.3 The current model zoo already includes $5 0 +$ models, and an option to add new ones (both PyTorch and TensorFlow). Evaluating a model produces a $1 5 +$ page report on model behaviour. All plots in this paper can be generated for future models—to track whether they narrow the gap towards human vision, or to determine whether an algorithmic modification to a baseline model (e.g., an architectural improvement) changes model behaviour.
62
+
63
+ # 3 Robustness across models: the OOD distortion robustness gap between human and machine vision is closing
64
+
65
+ We are interested in measuring whether we are making progress in closing the gap between human and machine vision. For a long time, CNNs were unable to match human robustness in terms of generalisation beyond the training distribution—a large OOD distortion robustness gap [14, 33, 53– 55]. Having tested human observers on 17 OOD datasets, we are now able to compare the latest developments in machine vision to human perception. Our core results are shown in Figure 1: the OOD distortion robustness gap between human and machine vision is closing (1a, 1b), especially for models trained on large-scale datasets. On the individual image level, a human-machine consistency gap remains (especially 1d), which will be discussed later.
66
+
67
+ Self-supervised models “If intelligence is a cake, the bulk of the cake is unsupervised learning, the icing on the cake is supervised learning and the cherry on the cake is reinforcement learning”,
68
+
69
+ ![](images/86ad5cf2160560092b0909f92fdf790c91243559e5415051f373514e6ac54b68.jpg)
70
+ Figure 1: Core results, aggregated over 17 out-of-distribution (OOD) datasets: The OOD robustness gap between human and machine vision is closing (top), but an image-level consistency gap remains (bottom). Results compare humans, standard supervised CNNs, self-supervised models, adversarially trained models, vision transformers, noisy student, BiT, SWSL and CLIP. For convenience, $\downarrow$ marks models that are trained on large-scale datasets. Metrics defined in Section 2. Best viewed on screen.
71
+
72
+ Yann LeCun said in 2016 [56]. A few years later, the entire cake is finally on the table—the representations learned via self-supervised learning4 now compete with supervised methods on ImageNet [43] and outperform supervised pre-training for object detection [41]. But how do recent self-supervised models differ from their supervised counterparts in terms of their behaviour? Do they bring machine vision closer to human vision? Humans, too, rapidly learn to recognise new objects without requiring hundreds of labels per instance; additionally a number of studies reported increased similarities between self-supervised models and human perception [57–61]. Figure 2 compares the generalisation behaviour of eight self-supervised models in orange (PIRL, MoCo, MoCoV2, InfoMin, InsDis, SimCLR-x1, SimCLR-x2, SimCLR-x4)—with 24 standard supervised models (grey). We find only marginal differences between self-supervised and supervised models: Across distortion types, self-supervised networks are well within the range of their poorly generalising supervised counterparts. However, there is one exception: the three SimCLR variants show strong generalisation improvements on uniform noise, low contrast, and high-pass images, where they are the three topperforming self-supervised networks—quite remarkable given that SimCLR models were trained on a different set of augmentations (random crop with flip and resize, colour distortion, and Gaussian blur). Curious by the outstanding performance of SimCLR, we asked whether the self-supervised objective function or the choice of training data augmentations was the defining factor. When comparing self-supervised SimCLR models with augmentation-matched baseline models trained in the standard supervised fashion (Figure 15 in the Appendix), we find that the augmentation scheme (rather than the self-supervised objective) indeed made the crucial difference: supervised baselines show just the same generalisation behaviour, a finding that fits well with [62], who observed that the influence of training data augmentations is stronger than the role of architecture or training objective. In conclusion, our analyses indicate that the “cake” of contrastive self-supervised learning currently (and disappointingly) tastes much like the “icing”.
73
+
74
+ ![](images/b9146a455daf8e1079d24472deb22b20808730c3d00b07d903cdfcd7e8f5e30f.jpg)
75
+ Figure 2: The OOD distortion robustness gap between human and machine vision is closing. Robustness towards parametric distortions for humans, standard supervised CNNs, self-supervised models, adversarially trained models, vision transformers, noisy student, BiT, SWSL, CLIP. Symbols indicate architecture type ( $\bigcirc$ convolutional, $\bigtriangledown$ vision transformer, $\diamondsuit$ human); best viewed on screen.
76
+
77
+ Adversarially trained models The vulnerability of CNNs to adversarial input perturbations is, arguably, one of the most striking shortcomings of this model class compared to robust human perception. A successful method to increase adversarial robustness is adversarial training [e.g. 63, 64]. The resulting models were found to transfer better, have meaningful gradients [65], and enable interpolating between two input images [66]: “robust optimization can actually be viewed as inducing a human prior over the features that models are able to learn” [67, p. 10]. Therefore, we include five models with a ResNet-50 architecture and different accuracy-robustness tradeoffs, adversarially trained on ImageNet with Microsoft-scale resources by [46] to test whether models with “perceptually-aligned representations” also show human-aligned OOD generalisation behaviour—as we would hope. This is not the case: the stronger the model is trained adversarially (darker shades of blue in Figure 2), the more susceptible it becomes to (random) image degradations. Most strikingly, a simple rotation by 90 degrees leads to a $50 \%$ drop in classification accuracy. Adversarial robustness seems to come at the cost of increased vulnerability to large-scale perturbations.5 On the other hand, there is a silver lining: when testing whether models are biased towards texture or shape by testing them on cue conflict images (Figure 3), in accordance with [69, 70] we observe a perfect relationship between shape bias and the degree of adversarial training, a big step in the direction of human shape bias (and a stronger shape bias than nearly all other models).
78
+
79
+ Vision transformers In computer vision, convolutional networks have become by far the dominating model class over the last decade. Vision transformers [47] break with the long tradition of using convolutions and are rapidly gaining traction [71]. We find that the best vision transformer (ViT-L trained on 14M images) even exceeds human OOD accuracy (Figure 1a shows the average across 17 datasets). There appears to be an additive effect of architecture and data: vision transformers trained on 1M images (light green) are already better than standard convolutional models; training on 14M images (dark green) gives another performance boost. In line with [72, 73], we observe a higher shape bias compared to most standard CNNs.
80
+
81
+ ![](images/011898817b7a7a617c58c30085614f1ce242e09dfb249b86d8c62339fec5a6f2.jpg)
82
+ Figure 3: Shape vs. texture biases of different models. While human shape bias is not yet matched, several approaches improve over vanilla CNNs. Box plots show category-dependent distribution of shape / texture biases (shape bias: high values, texture bias: low values).
83
+
84
+ Standard models trained on more data: BiT-M, SWSL, Noisy Student Interestingly, the biggest effect on OOD robustness we find simply comes from training on larger datasets, not from advanced architectures. When standard models are combined with large-scale training (14M images for BiT-M, 300M for Noisy Student and a remarkable 940M for SWSL), OOD accuracies reach levels not known from standard ImageNet-trained models; these models even outperform a more powerful architecture (vision transformer ViT-S) trained on less data (1M) as shown in Figure 1a. Simply training on (substantially) more data substantially narrows the gap to human OOD accuracies (1b), a finding that we quantified in Appendix H by means of a regression model. (The regression model also revealed a significant interaction between dataset size and objective function, as well as a significant main effect for transformers over CNNs.) Noisy Student in particular outperforms humans by a large margin overall (Figure 1a)—the beginning of a new human-machine gap, this time in favour of machines?
85
+
86
+ CLIP CLIP is special: trained on 400M images6 (more data) with joint language-image supervision (novel objective) and a vision transformer backbone (non-standard architecture), it scores close to humans across all of our metrics presented in Figure 1; most strikingly in terms of error consistency (which will be discussed in the next section). We tested a number of hypotheses to disentangle why CLIP appears “special”. H1: because CLIP is trained on a lot of data? Presumably no: Noisy Student—a model trained on a comparably large dataset of 300M images—performs very well on OOD accuracy, but poorly on error consistency. A caveat in this comparison is the quality of the labels: while Noisy Student uses pseudolabeling, CLIP receives web-based labels for all images. H2: because CLIP receives higher-quality labels? About $6 \%$ of ImageNet labels are plainly wrong [74]. Could it be the case that CLIP simply performs better since it doesn’t suffer from this issue? In order to test this, we used CLIP to generate new labels for all 1.3M ImageNet images: (a) hard labels, i.e. the top-1 class predicted by CLIP; and (b) soft labels, i.e. using CLIP’s full posterior distribution as a target. We then trained ResNet-50 from scratch on CLIP hard and soft labels (for details see Appendix E). However, this does not show any robustness improvements over a vanilla ImageNet-trained ResNet-50, thus different/better labels are not a likely root cause. H3: because CLIP has a special image+text loss? Yes and no: CLIP training on ResNet-50 leads to astonishingly poor OOD results, so training a standard model with CLIP loss alone is insufficient. However, while neither architecture nor loss alone sufficiently explain why CLIP is special, we find a clear interaction between architecture and loss (described in more detail in the Appendix along with the other “CLIP ablation” experiments mentioned above).
87
+
88
+ # 4 Consistency between models: data-rich models narrow the substantial image-level consistency gap between human and machine vision
89
+
90
+ In the previous section we have seen that while self-supervised and adversarially trained models lack OOD distortion robustness, models based on vision transformers and/or trained on large-scale datasets now match or exceed human feedforward performance on most datasets. Behaviourally, a natural follow-up question is to ask not just how many, but which errors models make—i.e., do they make errors on the same individual images as humans on OOD data (an important characteristic of a “human-like” model, cf. [32, 75])? This is quantified via error consistency (defined in Section 2); which additionally allows us to compare models with each other, asking e.g. which model classes make similar errors. In Figure 4, we compare all models with each other and with humans, asking whether they make errors on the same images. On this particular dataset (sketch images), we can see one big model cluster. Irrespective of whether one takes a standard supervised model, a selfsupervised model, an adversarially trained model or a vision transformer, all those models make highly systematic errors (which extends the results of [32, 76] who found similarities between standard vanilla CNNs). Humans, on the other hand, show a very different pattern of errors. Interestingly, the boundary between humans and some data-rich models at the bottom of the figure—especially CLIP (400M images) and SWSL (940M)—is blurry: some (but not all) data-rich models much more closely mirror the patterns of errors that humans make, and we identified the first models to achieve higher error consistency with humans than with other (standard) models. Are these promising results shared across datasets, beyond the sketch images? In Figures 1c and 1d, aggregated results over 17 datasets are presented. Here, we can see that data-rich models approach human-to-human observed consistency, but not error consistency. Taken in isolation, observed consistency is not a good measure of image-level consistency since it does not take consistency by chance into account; error consistency tracks whether there is consistency beyond chance; here we see that there is still a substantial image-level consistency gap between human and machine vision. However, several models improve over vanilla CNNs, especially BiT-M (trained on 14M images) and CLIP (400M images). This progress is non-trivial; at the same time, there is ample room for future improvement.
91
+
92
+ ![](images/a17382a03d11cd860c34972f94aa95b35c09aac1a36b70cc63b7199f445e2bdc.jpg)
93
+ Figure 4: Data-rich models narrow the substantial image-level consistency gap between humans and machines. Error consistency analysis on a single dataset (sketch images; for other datasets see Appendix, Figures 9, 11, 12, 13, 14) shows that most models cluster (dark red $=$ highly consistent errors) irrespective of their architecture and objective function; humans cluster differently (high human-to-human consistency, low human-to-model consistency); but some data-rich models including CLIP and SWSL blur the boundary, making more human-like errors than standard models.
94
+
95
+ ![](images/454421bb94ec0b451e543d9dbf78de3ac22a934484765c3e9915c81e54a8807a.jpg)
96
+ Figure 5: Partial failure, partial success: Error consistency with humans aggregated over multiple datasets. Left: 12 datasets where model accuracies exceed human accuracies; here, there is still a substantial image-level consistency gap to humans. Right: 5 datasets (sketch, silhouette, edge, cue conflict, low-pass) where humans are more robust. Here, OOD accuracy is a near-perfect predictor of image-level consistency; especially data-rich models (e.g. CLIP, SWSL, BiT) narrow the consistency gap to humans. Symbols indicate architecture type $\bigcirc$ convolutional, $\bigtriangledown$ vision transformer, $\diamondsuit$ human).
97
+
98
+ How do the findings from Figure 4 (showing nearly human-level error consistency for sketch images) and from Figure 1d (showing a substantial consistency gap when aggregating over 17 datasets) fit together? Upon closer inspection, we discovered that there are two distinct cases. On 12 datasets (stylized, colour/greyscale, contrast, high-pass, phase-scrambling, power-equalisation, false colour, rotation, eidolonI, -II and -III as well as uniform noise), the human-machine gap is large; here, more robust models do not show improved error consistency (as can be see in Figure 5a). On the other hand, for five datasets (sketch, silhouette, edge, cue conflict, low-pass filtering), there is a completely different result pattern: Here, OOD accuracy is a near-perfect predictor of error consistency, which means that improved generalisation robustness leads to more human-like errors (Figure 5b). Furthermore, training on large-scale datasets leads to considerable improvements along both axes for standard CNNs. Within models trained on larger datasets, CLIP scores best; but models with a standard architecture (SWSL: based on ResNet-50 and ResNeXt-101) closely follow suit.
99
+
100
+ It remains an open question why the training dataset appears to have the most important impact on a model’s decision boundary as measured by error consistency (as opposed to other aspects of a model’s inductive bias). Datasets contain various shortcut opportunities [14], and if two different models are trained on similar data, they might converge to a similar solution simply by exploiting the same shortcuts—which would also fit well to the finding that adversarial examples typically transfer very well between different models [77, 78]. Making models more flexible (such as transformers, a generalisation of CNNs) wouldn’t change much in this regard, since flexible models can still exploit the same shortcuts. Two predictions immediately follow from this hypothesis: (1.) error consistency between two identical models trained on very different datasets, such as ImageNet vs. Stylized-ImageNet, is much lower than error consistency between very different models (ResNet-50 vs. VGG-16) trained on the same dataset. (2.) error consistency between ResNet-50 and a highly flexible model (e.g., a vision transformer) is much higher than error consistency between ResNet-50 and a highly constrained model like BagNet-9 [79]. We provide evidence for both predictions in Appendix B, which makes the shortcut hypothesis of model similarity a potential starting point for future analyses. Looking forward, it may be worth exploring the links between shortcut learning and image difficulty, such as understanding whether many “trivially easy” images in common datasets like ImageNet causes models to expoit the same characteristics irrespective of their architecture [80].
101
+
102
+ # 5 Discussion
103
+
104
+ Summary We set out to answer the question: Are we making progress in closing the gap between human and machine vision? In order to quantify progress, we performed large-scale psychophysical experiments on 17 out-of-distribution distortion datasets (open-sourced along with evaluation code as a benchmark to track future progress). We then investigated models that push the boundaries of traditional deep learning (different objective functions, architectures, and dataset sizes ranging from 1M to 1B), asking how they perform relative to human visual perception. We found that the OOD distortion robustness gap between human and machine vision is closing, as the best models now match or exceed human accuracies. At the same time, an image-level consistency gap remains; however, this gap that is at least in some cases narrowing for models trained on large-scale datasets.
105
+
106
+ Limitations Model robustness is studied from many different viewpoints, including adversarial robustness [77], theoretical robustness guarantees [e.g. 81], or label noise robustness [e.g. 82]. The focus of our study is robustness towards non-adversarial out-of-distribution data, which is particularly well-suited for comparisons with humans. Since we aimed at a maximally fair comparison between feedforward models and human perception, presentation times for human observers were limited to $2 0 0 \mathrm { { m s } }$ in order to limit the influence of recurrent processing. Therefore, human ceiling performance might be higher still (given more time); investigating this would mean going beyond “core object recognition”, which happens within less than $2 0 0 ~ \mathrm { { m s } }$ during a single fixation [83]. Furthermore, human and machine vision can be compared in many different ways. This includes comparing against neural data [84, 85], contrasting Gestalt effects [e.g. 86], object similarity judgments [87], or mid-level properties [61] and is of course not limited to studying object recognition. By no means do we mean to imply that our behavioural comparison is the only feasible option—on the contrary, we believe it will be all the more exciting to investigate whether our behavioural findings have implications for other means of comparison!
107
+
108
+ Discussion We have to admit that we view our results concerning the benefits of increasing dataset size by one-to-three orders of magnitude with mixed feelings. On the one hand, “simply” training standard models on (a lot) more data certainly has an intellectually disappointing element—particularly given many rich ideas in the cognitive science and neuroscience literature on which architectural changes might be required to bring machine vision closer to human vision [88–93]. Additionally, large-scale training comes with infrastructure demands that are hard to meet for many academic researchers. On the other hand, we find it truly exciting to see that machine models are closing not just the OOD distortion robustness gap to humans, but that also, at least for some datasets, those models are actually making more human-like decisions on an individual image level; image-level response consistency is a much stricter behavioural requirement than just e.g. matching overall accuracies. Taken together, our results give reason to celebrate partial success in closing the gap between human and machine vision. In those cases where there is still ample room for improvement, our psychophysical benchmark datasets and toolbox may prove useful in quantifying future progress.
109
+
110
+ # Acknowledgments and disclosure of funding
111
+
112
+ We thank Andreas Geiger, Simon Kornblith, Kristof Meding, Claudio Michaelis and Ludwig Schmidt for helpful discussions regarding different aspects of this work; Lukas Huber, Maximus Mutschler, David-Elias Künstle for feedback on the manuscript; Ken Kahn for pointing out typos; Santiago Cadena for sharing a PyTorch implementation of SimCLR; Katherine Hermann and her collaborators for providing supervised SimCLR baselines; Uli Wannek and Silke Gramer for infrastructure/administrative support; the many authors who made their models publicly available; and our anonymous reviewers for many valuable suggestions.
113
+
114
+ Furthermore, we are grateful to the International Max Planck Research School for Intelligent Systems (IMPRSIS) for supporting R.G.; the Collaborative Research Center (Projektnummer 276693517—SFB 1233: Robust Vision) for supporting M.B. and F.A.W. This work was supported by the German Federal Ministry of Education and Research (BMBF): Tübingen AI Center, FKZ: 01IS18039A (W.B. and M.B.). F.A.W. is a member of the Machine Learning Cluster of Excellence, EXC number 2064/1—Project number 390727645. M.B. and W.B. acknowledge funding from the MICrONS program of the Intelligence Advanced Research Projects Activity (IARPA) via Department of Interior/Interior Business Center (DoI/IBC) contract number D16PC00003. W.B. acknowledges financial support via the Emmy Noether Research Group on The Role of Strong Response Consistency for Robust and Explainable Machine Vision funded by the German Research Foundation (DFG) under grant no. BR 6382/1-1.
115
+
116
+ # Author contributions
117
+
118
+ Project idea: R.G. and W.B.; project lead: R.G.; coding toolbox and model evaluation pipeline: R.G., K.N. and B.M. based on a prototype by R.G.; training models: K.N. with input from R.G., W.B. and M.B.; data visualisation: R.G., B.M. and K.N. with input from M.B., F.A.W. and W.B.; psychophysical data collection: T.T. (12 datasets) and B.M. (2 datasets) under the guidance of R.G. and F.A.W.; curating stimuli: R.G.; interpreting analyses and findings: R.G., M.B., F.A.W. and W.B.; guidance, feedback, infrastructure & funding acquisition: M.B., F.A.W. and W.B.; paper writing: R.G. with help from F.A.W. and W.B. and input from all other authors.
119
+
120
+ # References
121
+
122
+ [1] Alex Krizhevsky, Ilya Sutskever, and Geoffrey E Hinton. ImageNet classification with deep convolutional neural networks. In Advances in Neural Information Processing Systems, pages 1097–1105, 2012.
123
+ [2] Jinjiang Wang, Yulin Ma, Laibin Zhang, Robert X Gao, and Dazhong Wu. Deep learning for smart manufacturing: Methods and applications. Journal of Manufacturing Systems, 48:144–156, 2018.
124
+ [3] Javier Villalba-Diez, Daniel Schmidt, Roman Gevers, Joaquín Ordieres-Meré, Martin Buchwitz, and Wanja Wellbrock. Deep learning for industrial computer vision quality control in the printing industry 4.0. Sensors, 19(18):3987, 2019.
125
+ [4] Christof Angermueller, Tanel Pärnamaa, Leopold Parts, and Oliver Stegle. Deep learning for computational biology. Molecular Systems Biology, 12(7):878, 2016.
126
+ [5] Adam H Marblestone, Greg Wayne, and Konrad P Kording. Toward an integration of deep learning and neuroscience. Frontiers in Computational Neuroscience, 10:94, 2016.
127
+ [6] Garrett B Goh, Nathan O Hodas, and Abhinav Vishnu. Deep learning for computational chemistry. Journal of Computational Chemistry, 38(16):1291–1307, 2017.
128
+ [7] Travers Ching, Daniel S Himmelstein, Brett K Beaulieu-Jones, Alexandr A Kalinin, Brian T Do, Gregory P Way, Enrico Ferrero, Paul-Michael Agapow, Michael Zietz, Michael M Hoffman, et al. Opportunities and obstacles for deep learning in biology and medicine. Journal of The Royal Society Interface, 15(141): 20170387, 2018.
129
+ [8] Dan Guest, Kyle Cranmer, and Daniel Whiteson. Deep learning and its application to LHC physics. Annual Review of Nuclear and Particle Science, 68:161–181, 2018.
130
+ [9] Andrew W Senior, Richard Evans, John Jumper, James Kirkpatrick, Laurent Sifre, Tim Green, Chongli Qin, Augustin Žídek, Alexander WR Nelson, Alex Bridgland, et al. Improved protein structure prediction using potentials from deep learning. Nature, 577(7792):706–710, 2020.
131
+ [10] Olga Russakovsky, Jia Deng, Hao Su, Jonathan Krause, Sanjeev Satheesh, Sean Ma, Zhiheng Huang, Andrej Karpathy, Aditya Khosla, Michael Bernstein, Alexander C Berg, and Li Fei-Fei. ImageNet Large Scale Visual Recognition Challenge. International Journal of Computer Vision, 115(3):211–252, 2015.
132
+ [11] Jason Jo and Yoshua Bengio. Measuring the tendency of cnns to learn surface statistical regularities. arXiv preprint arXiv:1711.11561, 2017.
133
+ [12] Sara Beery, Grant Van Horn, and Pietro Perona. Recognition in terra incognita. In Proceedings of the European Conference on Computer Vision, pages 456–473, 2018.
134
+ [13] Timothy Niven and Hung-Yu Kao. Probing neural network comprehension of natural language arguments. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 4658–4664, 2019.
135
+ [14] Robert Geirhos, Jörn-Henrik Jacobsen, Claudio Michaelis, Richard Zemel, Wieland Brendel, Matthias Bethge, and Felix A Wichmann. Shortcut learning in deep neural networks. Nature Machine Intelligence, 2:665–673, 2020.
136
+ [15] Dan Hendrycks and Thomas Dietterich. Benchmarking neural network robustness to common corruptions and perturbations. In International Conference on Learning Representations, 2019.
137
+ [16] Haohan Wang, Songwei Ge, Eric P Xing, and Zachary C Lipton. Learning robust global representations by penalizing local predictive power. arXiv preprint arXiv:1905.13549, 2019.
138
+ [17] Robert Geirhos, Patricia Rubisch, Claudio Michaelis, Matthias Bethge, Felix A. Wichmann, and Wieland Brendel. ImageNet-trained CNNs are biased towards texture; increasing shape bias improves accuracy and robustness. In International Conference on Learning Representations, 2019.
139
+ [18] Michael A Alcorn, Qi Li, Zhitao Gong, Chengfei Wang, Long Mai, Wei-Shinn Ku, and Anh Nguyen. Strike (with) a pose: Neural networks are easily fooled by strange poses of familiar objects. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, 2019.
140
+ [19] Brenden M Lake, Ruslan Salakhutdinov, and Joshua B Tenenbaum. Human-level concept learning through probabilistic program induction. Science, 350(6266):1332–1338, 2015.
141
+ [20] Andrei Barbu, David Mayo, Julian Alverio, William Luo, Christopher Wang, Dan Gutfreund, Josh Tenenbaum, and Boris Katz. ObjectNet: a large-scale bias-controlled dataset for pushing the limits of object recognition models. In Advances in Neural Information Processing Systems, pages 9448–9458, 2019.
142
+ [21] Claudio Michaelis, Benjamin Mitzkus, Robert Geirhos, Evgenia Rusak, Oliver Bringmann, Alexander S Ecker, Matthias Bethge, and Wieland Brendel. Benchmarking robustness in object detection: Autonomous driving when winter is coming. arXiv:1907.07484, 2019.
143
+ [22] Rohan Taori, Achal Dave, Vaishaal Shankar, Nicholas Carlini, Benjamin Recht, and Ludwig Schmidt. Measuring robustness to natural distribution shifts in image classification. In Advances in Neural Information Processing Systems, 2020.
144
+ [23] Josip Djolonga, Jessica Yung, Michael Tschannen, Rob Romijnders, Lucas Beyer, Alexander Kolesnikov, Joan Puigcerver, Matthias Minderer, Alexander D’Amour, Dan Moldovan, et al. On robustness and transferability of convolutional neural networks. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 16458–16468, 2021.
145
+ [24] Isaac Dunn, Hadrien Pouget, Daniel Kroening, and Tom Melham. Exposing previously undetectable faults in deep neural networks. arXiv preprint arXiv:2106.00576, 2021.
146
+ [25] Yue He, Zheyan Shen, and Peng Cui. Towards non-iid image classification: A dataset and baselines. Pattern Recognition, 110:107383, 2021.
147
+ [26] Dan Hendrycks, Steven Basart, Norman Mu, Saurav Kadavath, Frank Wang, Evan Dorundo, Rahul Desai, Tyler Zhu, Samyak Parajuli, Mike Guo, et al. The many faces of robustness: A critical analysis of out-of-distribution generalization. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 8340–8349, 2021.
148
+ [27] Dan Hendrycks, Kevin Zhao, Steven Basart, Jacob Steinhardt, and Dawn Song. Natural adversarial examples. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 15262–15271, 2021.
149
+ [28] Spandan Madan, Tomotake Sasaki, Tzu-Mao Li, Xavier Boix, and Hanspeter Pfister. Small in-distribution changes in 3D perspective and lighting fool both CNNs and transformers. arXiv preprint arXiv:2106.16198, 2021.
150
+ [29] Vaishaal Shankar, Achal Dave, Rebecca Roelofs, Deva Ramanan, Benjamin Recht, and Ludwig Schmidt. Do image classifiers generalize across time? In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 9661–9669, 2021.
151
+ [30] David M. Green. Consistency of auditory detection judgments. Psychological Review, 71(5):392–407, 1964.
152
+ [31] Kristof Meding, Dominik Janzing, Bernhard Schölkopf, and Felix A. Wichmann. Perceiving the arrow of time in autoregressive motion. Advances in Neural Information Processing Systems (NeurIPS), 32: 2303–2314, 2019.
153
+ [32] Robert Geirhos, Kristof Meding, and Felix A Wichmann. Beyond accuracy: quantifying trial-by-trial behaviour of CNNs and humans by measuring error consistency. Advances in Neural Information Processing Systems, 33, 2020.
154
+ [33] Robert Geirhos, Carlos RM Temme, Jonas Rauber, Heiko H Schütt, Matthias Bethge, and Felix A Wichmann. Generalisation in humans and deep neural networks. In Advances in Neural Information Processing Systems, 2018.
155
+ [34] George A Miller. WordNet: a lexical database for English. Communications of the ACM, 38(11):39–41, 1995.
156
+ [35] Philip L Smith and Daniel R Little. Small is beautiful: In defense of the small-N design. Psychonomic Bulletin & Review, 25(6):2083–2101, 2018.
157
+ [36] Siavash Haghiri, Patricia Rubisch, Robert Geirhos, Felix Wichmann, and Ulrike von Luxburg. Comparisonbased framework for psychophysics: lab versus crowdsourcing. arXiv preprint arXiv:1905.07234, 2019.
158
+ [37] Sébastien Marcel and Yann Rodriguez. Torchvision the machine-vision package of torch. In Proceedings of the 18th ACM International Conference on Multimedia, pages 1485–1488, 2010.
159
+ [38] Zhirong Wu, Yuanjun Xiong, Stella X Yu, and Dahua Lin. Unsupervised feature learning via nonparametric instance discrimination. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 3733–3742, 2018.
160
+ [39] Kaiming He, Haoqi Fan, Yuxin Wu, Saining Xie, and Ross Girshick. Momentum contrast for unsupervised visual representation learning. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 9729–9738, 2020.
161
+ [40] Xinlei Chen, Haoqi Fan, Ross Girshick, and Kaiming He. Improved baselines with momentum contrastive learning. arXiv preprint arXiv:2003.04297, 2020.
162
+ [41] Ishan Misra and Laurens van der Maaten. Self-supervised learning of pretext-invariant representations. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 6707–6717, 2020.
163
+ [42] Yonglong Tian, Chen Sun, Ben Poole, Dilip Krishnan, Cordelia Schmid, and Phillip Isola. What makes for good views for contrastive learning. arXiv preprint arXiv:2005.10243, 2020.
164
+ [43] Ting Chen, Simon Kornblith, Mohammad Norouzi, and Geoffrey Hinton. A simple framework for contrastive learning of visual representations. arXiv preprint arXiv:2002.05709, 2020.
165
+ [44] Robert Geirhos, Kantharaju Narayanappa, Benjamin Mitzkus, Matthias Bethge, Felix A Wichmann, and Wieland Brendel. On the surprising similarities between supervised and self-supervised models. arXiv preprint arXiv:2010.08377, 2020.
166
+ [45] Alexander Kolesnikov, Lucas Beyer, Xiaohua Zhai, Joan Puigcerver, Jessica Yung, Sylvain Gelly, and Neil Houlsby. Big transfer (BiT): General visual representation learning. arXiv preprint arXiv:1912.11370, 6 (2):8, 2019.
167
+ [46] Hadi Salman, Andrew Ilyas, Logan Engstrom, Ashish Kapoor, and Aleksander Madry. Do adversarially robust ImageNet models transfer better? arXiv preprint arXiv:2007.08489, 2020.
168
+ [47] Alexey Dosovitskiy, Lucas Beyer, Alexander Kolesnikov, Dirk Weissenborn, Xiaohua Zhai, Thomas Unterthiner, Mostafa Dehghani, Matthias Minderer, Georg Heigold, Sylvain Gelly, et al. An image is worth 16x16 words: Transformers for image recognition at scale. arXiv preprint arXiv:2010.11929, 2020.
169
+ [48] Ross Wightman. PyTorch image models. https://github.com/rwightman/ pytorch-image-models, 2019.
170
+ [49] I Zeki Yalniz, Hervé Jégou, Kan Chen, Manohar Paluri, and Dhruv Mahajan. Billion-scale semi-supervised learning for image classification. arXiv preprint arXiv:1905.00546, 2019.
171
+ [50] Qizhe Xie, Minh-Thang Luong, Eduard Hovy, and Quoc V Le. Self-training with noisy student improves ImageNet classification. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 10687–10698, 2020.
172
+ [51] Alec Radford, Jong Wook Kim, Chris Hallacy, Aditya Ramesh, Gabriel Goh, Sandhini Agarwal, Girish Sastry, Amanda Askell, Pamela Mishkin, Jack Clark, et al. Learning transferable visual models from natural language supervision. arXiv preprint arXiv:2103.00020, 2021.
173
+ [52] Jacob Cohen. A coefficient of agreement for nominal scales. Educational and Psychological Measurement, 20(1):37–46, 1960.
174
+ [53] Samuel Dodge and Lina Karam. A study and comparison of human and deep learning recognition performance under visual distortions. In 26th International Conference on Computer Communication and Networks, pages 1–7. IEEE, 2017.
175
+ [54] Felix A Wichmann, David HJ Janssen, Robert Geirhos, Guillermo Aguilar, Heiko H Schütt, Marianne Maertens, and Matthias Bethge. Methods and measurements to compare men against machines. Electronic Imaging, Human Vision and Electronic Imaging, 2017(14):36–45, 2017.
176
+ [55] Thomas Serre. Deep learning: the good, the bad, and the ugly. Annual Review of Vision Science, 5:399–426, 2019.
177
+ [56] Yann LeCun. Predictive learning, 2016. URL https://www.youtube.com/watch?v=Ount2Y4qxQo.
178
+ [57] William Lotter, Gabriel Kreiman, and David Cox. A neural network trained for prediction mimics diverse features of biological neurons and perception. Nature Machine Intelligence, 2(4):210–219, 2020.
179
+ [58] A Emin Orhan, Vaibhav V Gupta, and Brenden M Lake. Self-supervised learning through the eyes of a child. arXiv preprint arXiv:2007.16189, 2020.
180
+ [59] Talia Konkle and George A Alvarez. Instance-level contrastive learning yields human brain-like representation without category-supervision. bioRxiv, 2020.
181
+ [60] Chengxu Zhuang, Siming Yan, Aran Nayebi, Martin Schrimpf, Michael Frank, James DiCarlo, and Daniel Yamins. Unsupervised neural network models of the ventral visual stream. bioRxiv, 2020.
182
+ [61] Katherine R Storrs, Barton L Anderson, and Roland W Fleming. Unsupervised learning predicts human perception and misperception of gloss. Nature Human Behaviour, pages 1–16, 2021.
183
+ [62] Katherine Hermann, Ting Chen, and Simon Kornblith. The origins and prevalence of texture bias in convolutional neural networks. Advances in Neural Information Processing Systems, 33, 2020.
184
+ [63] Ian J Goodfellow, Jonathon Shlens, and Christian Szegedy. Explaining and harnessing adversarial examples. arXiv preprint arXiv:1412.6572, 2014.
185
+ [64] Ruitong Huang, Bing Xu, Dale Schuurmans, and Csaba Szepesvári. Learning with a strong adversary. arXiv preprint arXiv:1511.03034, 2015.
186
+ [65] Simran Kaur, Jeremy Cohen, and Zachary C Lipton. Are perceptually-aligned gradients a general property of robust classifiers? arXiv preprint arXiv:1910.08640, 2019.
187
+ [66] Shibani Santurkar, Dimitris Tsipras, Brandon Tran, Andrew Ilyas, Logan Engstrom, and Aleksander Madry. Image synthesis with a single (robust) classifier. arXiv:1906.09453, 2019.
188
+ [67] Logan Engstrom, Andrew Ilyas, Shibani Santurkar, Dimitris Tsipras, Brandon Tran, and Aleksander Madry. Adversarial robustness as a prior for learned representations. arXiv preprint arXiv:1906.00945, 2019.
189
+ [68] Florian Tramèr, Jens Behrmann, Nicholas Carlini, Nicolas Papernot, and Jörn-Henrik Jacobsen. Fundamental tradeoffs between invariance and sensitivity to adversarial perturbations. In International Conference on Machine Learning, pages 9561–9571. PMLR, 2020.
190
+ [69] Tianyuan Zhang and Zhanxing Zhu. Interpreting adversarially trained convolutional neural networks. In International Conference on Machine Learning, pages 7502–7511. PMLR, 2019.
191
+ [70] Peijie Chen, Chirag Agarwal, and Anh Nguyen. The shape and simplicity biases of adversarially robust ImageNet-trained CNNs. arXiv preprint arXiv:2006.09373, 2020.
192
+ [71] Kai Han, Yunhe Wang, Hanting Chen, Xinghao Chen, Jianyuan Guo, Zhenhua Liu, Yehui Tang, An Xiao, Chunjing Xu, Yixing Xu, et al. A survey on visual transformer. arXiv preprint arXiv:2012.12556, 2020.
193
+ [72] Muzammal Naseer, Kanchana Ranasinghe, Salman Khan, Munawar Hayat, Fahad Shahbaz Khan, and Ming-Hsuan Yang. Intriguing properties of vision transformers. arXiv preprint arXiv:2105.10497, 2021.
194
+ [73] Shikhar Tuli, Ishita Dasgupta, Erin Grant, and Thomas L Griffiths. Are convolutional neural networks or transformers more like human vision? arXiv preprint arXiv:2105.07197, 2021.
195
+ [74] Curtis G Northcutt, Anish Athalye, and Jonas Mueller. Pervasive label errors in test sets destabilize machine learning benchmarks. arXiv preprint arXiv:2103.14749, 2021.
196
+ [75] Rishi Rajalingham, Elias B Issa, Pouya Bashivan, Kohitij Kar, Kailyn Schmidt, and James J DiCarlo. Large-scale, high-resolution comparison of the core visual object recognition behavior of humans, monkeys, and state-of-the-art deep artificial neural networks. Journal of Neuroscience, 38(33):7255–7269, 2018.
197
+ [76] Horia Mania, John Miller, Ludwig Schmidt, Moritz Hardt, and Benjamin Recht. Model similarity mitigates test set overuse. Advances in Neural Information Processing Systems, 2019.
198
+ [77] Christian Szegedy, Wojciech Zaremba, Ilya Sutskever, Joan Bruna, Dumitru Erhan, Ian Goodfellow, and Rob Fergus. Intriguing properties of neural networks. arXiv:1312.6199, 2013.
199
+ [78] Florian Tramèr, Nicolas Papernot, Ian Goodfellow, Dan Boneh, and Patrick McDaniel. The space of transferable adversarial examples. arXiv preprint arXiv:1704.03453, 2017.
200
+ [79] Wieland Brendel and Matthias Bethge. Approximating CNNs with bag-of-local-features models works surprisingly well on ImageNet. In International Conference on Learning Representations, 2019.
201
+ [80] Kristof Meding, Luca M Schulze Buschoff, Robert Geirhos, and Felix A Wichmann. Trivial or impossible–dichotomous data difficulty masks model differences (on ImageNet and beyond). arXiv preprint arXiv:2110.05922, 2021.
202
+ [81] Matthias Hein and Maksym Andriushchenko. Formal guarantees on the robustness of a classifier against adversarial manipulation. arXiv preprint arXiv:1705.08475, 2017.
203
+ [82] Arash Vahdat. Toward robustness against label noise in training deep discriminative neural networks. arXiv preprint arXiv:1706.00038, 2017.
204
+ [83] James J DiCarlo, Davide Zoccolan, and Nicole C Rust. How does the brain solve visual object recognition? Neuron, 73(3):415–434, 2012.
205
+ [84] Daniel LK Yamins, Ha Hong, Charles F Cadieu, Ethan A Solomon, Darren Seibert, and James J DiCarlo. Performance-optimized hierarchical models predict neural responses in higher visual cortex. Proceedings of the National Academy of Sciences, 111(23):8619–8624, 2014.
206
+ [85] Jonas Kubilius, Martin Schrimpf, Kohitij Kar, Rishi Rajalingham, Ha Hong, Najib Majaj, Elias Issa, Pouya Bashivan, Jonathan Prescott-Roy, Kailyn Schmidt, et al. Brain-like object recognition with high-performing shallow recurrent ANNs. Advances in Neural Information Processing Systems, 32:12805–12816, 2019.
207
+ [86] Been Kim, Emily Reif, Martin Wattenberg, Samy Bengio, and Michael C Mozer. Neural networks trained on natural scenes exhibit Gestalt closure. Computational Brain & Behavior, pages 1–13, 2021.
208
+ [87] Martin N Hebart, Charles Y Zheng, Francisco Pereira, and Chris I Baker. Revealing the multidimensional mental representations of natural objects underlying human similarity judgements. Nature Human Behaviour, 4(11):1173–1185, 2020.
209
+ [88] Nikolaus Kriegeskorte. Deep neural networks: a new framework for modeling biological vision and brain information processing. Annual Review of Vision Science, 1:417–446, 2015.
210
+ [89] 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.
211
+ [90] Amirhossein Tavanaei, Masoud Ghodrati, Saeed Reza Kheradpisheh, Timothée Masquelier, and Anthony Maida. Deep learning in spiking neural networks. Neural Networks, 111:47–63, 2019.
212
+ [91] Fabian H Sinz, Xaq Pitkow, Jacob Reimer, Matthias Bethge, and Andreas S Tolias. Engineering a less artificial intelligence. Neuron, 103(6):967–979, 2019.
213
+ [92] Joel Dapello, Tiago Marques, Martin Schrimpf, Franziska Geiger, David D Cox, and James J DiCarlo. Simulating a primary visual cortex at the front of CNNs improves robustness to image perturbations. bioRxiv, 2020.
214
+ [93] Benjamin D Evans, Gaurav Malhotra, and Jeffrey S Bowers. Biological convolutions improve dnn robustness to noise and generalisation. bioRxiv, 2021.
215
+ [94] Adam Paszke, Sam Gross, Francisco Massa, Adam Lerer, James Bradbury, Gregory Chanan, Trevor Killeen, Zeming Lin, Natalia Gimelshein, Luca Antiga, et al. PyTorch: An imperative style, high-performance deep learning library. In Advances in Neural Information Processing Systems, pages 8026–8037, 2019.
216
+ [95] Aaron van den Oord, Yazhe Li, and Oriol Vinyals. Representation learning with contrastive predictive coding. arXiv:1807.03748, 2018.
217
+ [96] Jia Deng, Wei Dong, Richard Socher, Li-Jia Li, Kai Li, and Li Fei-Fei. ImageNet: a large-scale hierarchical image database. In IEEE Conference on Computer Vision and Pattern Recognition, pages 248–255, 2009.
218
+ [97] Evgenia Rusak, Steffen Schneider, Peter Gehler, Oliver Bringmann, Wieland Brendel, and Matthias Bethge. Adapting ImageNet-scale models to complex distribution shifts with self-learning. arXiv preprint arXiv:2104.12928, 2021.
219
+ [98] Eleanor Rosch. Principles of categorization. In E. Margolis and S. Laurence, editors, Concepts: core readings, pages 189–206. 1999.
parse/train/QkljT4mrfs/QkljT4mrfs_content_list.json ADDED
@@ -0,0 +1,731 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [
2
+ {
3
+ "type": "text",
4
+ "text": "Partial success in closing the gap between human and machine vision ",
5
+ "text_level": 1,
6
+ "bbox": [
7
+ 248,
8
+ 122,
9
+ 750,
10
+ 172
11
+ ],
12
+ "page_idx": 0
13
+ },
14
+ {
15
+ "type": "text",
16
+ "text": "Robert Geirhos1-2§ Kantharaju Narayanappa1 Benjamin Mitzkus1 ",
17
+ "bbox": [
18
+ 212,
19
+ 219,
20
+ 781,
21
+ 237
22
+ ],
23
+ "page_idx": 0
24
+ },
25
+ {
26
+ "type": "text",
27
+ "text": "Tizian Thieringer1 Matthias Bethge1∗ Felix A. Wichmann1∗ Wieland Brendel1∗ ",
28
+ "bbox": [
29
+ 189,
30
+ 256,
31
+ 805,
32
+ 272
33
+ ],
34
+ "page_idx": 0
35
+ },
36
+ {
37
+ "type": "text",
38
+ "text": "1University of Tübingen 2International Max Planck Research School for Intelligent Systems ∗Joint senior authors §To whom correspondence should be addressed: robert.geirhos@uni-tuebingen.de ",
39
+ "bbox": [
40
+ 204,
41
+ 289,
42
+ 794,
43
+ 348
44
+ ],
45
+ "page_idx": 0
46
+ },
47
+ {
48
+ "type": "text",
49
+ "text": "Abstract ",
50
+ "text_level": 1,
51
+ "bbox": [
52
+ 462,
53
+ 382,
54
+ 535,
55
+ 400
56
+ ],
57
+ "page_idx": 0
58
+ },
59
+ {
60
+ "type": "text",
61
+ "text": "A few years ago, the first CNN surpassed human performance on ImageNet. However, it soon became clear that machines lack robustness on more challenging test cases, a major obstacle towards deploying machines “in the wild” and towards obtaining better computational models of human visual perception. Here we ask: Are we making progress in closing the gap between human and machine vision? To answer this question, we tested human observers on a broad range of out-ofdistribution (OOD) datasets, recording 85,120 psychophysical trials across 90 participants. We then investigated a range of promising machine learning developments that crucially deviate from standard supervised CNNs along three axes: objective function (self-supervised, adversarially trained, CLIP language-image training), architecture (e.g. vision transformers), and dataset size (ranging from 1M to 1B). ",
62
+ "bbox": [
63
+ 232,
64
+ 415,
65
+ 767,
66
+ 579
67
+ ],
68
+ "page_idx": 0
69
+ },
70
+ {
71
+ "type": "text",
72
+ "text": "Our findings are threefold. (1.) The longstanding distortion robustness gap between humans and CNNs is closing, with the best models now exceeding human feedforward performance on most of the investigated OOD datasets. (2.) There is still a substantial image-level consistency gap, meaning that humans make different errors than models. In contrast, most models systematically agree in their categorisation errors, even substantially different ones like contrastive self-supervised vs. standard supervised models. (3.) In many cases, human-to-model consistency improves when training dataset size is increased by one to three orders of magnitude. Our results give reason for cautious optimism: While there is still much room for improvement, the behavioural difference between human and machine vision is narrowing. In order to measure future progress, 17 OOD datasets with image-level human behavioural data and evaluation code are provided as a toolbox and benchmark at https://github.com/bethgelab/model-vs-human/. ",
73
+ "bbox": [
74
+ 233,
75
+ 580,
76
+ 766,
77
+ 760
78
+ ],
79
+ "page_idx": 0
80
+ },
81
+ {
82
+ "type": "text",
83
+ "text": "1 Introduction ",
84
+ "text_level": 1,
85
+ "bbox": [
86
+ 174,
87
+ 785,
88
+ 310,
89
+ 803
90
+ ],
91
+ "page_idx": 0
92
+ },
93
+ {
94
+ "type": "text",
95
+ "text": "Looking back at the last decade, deep learning has made tremendous leaps of progress by any standard. What started in 2012 with AlexNet [1] as the surprise winner of the ImageNet Large-Scale Visual Recognition Challenge quickly became the birth of a new AI “summer”, a summer lasting much longer than just a season. With it, just like with any summer, came great expectations: the hope that the deep learning revolution will see widespread applications in industry, that it will propel breakthroughs in the sciences, and that it will ultimately close the gap between human and machine perception. We have now reached the point where deep learning has indeed become a significant driver of progress in industry [e.g. 2, 3], and where many disciplines are employing deep learning for scientific discoveries [4–9]—but are we making progress in closing the gap between human and machine vision? ",
96
+ "bbox": [
97
+ 174,
98
+ 818,
99
+ 825,
100
+ 901
101
+ ],
102
+ "page_idx": 0
103
+ },
104
+ {
105
+ "type": "text",
106
+ "text": "",
107
+ "bbox": [
108
+ 174,
109
+ 92,
110
+ 825,
111
+ 146
112
+ ],
113
+ "page_idx": 1
114
+ },
115
+ {
116
+ "type": "text",
117
+ "text": "IID vs. OOD benchmarking. For a long time, the gap between human and machine vision was mainly approximated by comparing benchmark accuracies on IID (independent and identically distributed) test data: as long as models are far from reaching human-level performance on challenging datasets like ImageNet, this approach is adequate [10]. Currently, models are routinely matching and in many cases even outperforming humans on IID data. At the same time, it is becoming increasingly clear that models systematically exploit shortcuts shared between training and test data [11–14]. Therefore we are witnessing a major shift towards measuring model performance on out-of-distribution (OOD) data rather than IID data alone, which aims at testing models on more challenging test cases where there is still a ground truth category, but certain image statistics differ from the training distribution. Many OOD generalisation tests have been proposed: ImageNet-C [15] for corrupted imaes, ImageNet-Sketch [16] for sketches, Stylized-ImageNet [17] for image style changes, [18] for unfamiliar object poses, and many more [19–29]. While it is great to have many viable and valuable options to measure generalisation, most of these datasets unfortunately lack human comparison data. This is less than ideal, since we can no longer assume that humans reach near-ceiling accuracies on these challenging test cases as they do on standard noise-free IID object recognition datasets. In order to address this issue, we carefully tested human observers in the Wichmannlab’s vision laboratory on a broad range of OOD datasets, providing some 85K psychophysical trials across 90 participants. Crucially, we showed exactly the same images to multiple observers, which means that we are able to compare human and machine vision on the fine-grained level of individual images [30–32]). The focus of our datasets is measuring distortion robustness: we tested 17 variations that include changes to image style, texture, and various forms of synthetic additive noise. ",
118
+ "bbox": [
119
+ 174,
120
+ 174,
121
+ 825,
122
+ 478
123
+ ],
124
+ "page_idx": 1
125
+ },
126
+ {
127
+ "type": "text",
128
+ "text": "Contributions & outlook. The resulting 17 OOD datasets with large-scale human comparion data enable us to investigate recent exciting machine learning developments that crucially deviate from “vanilla” CNNs along three axes: objective function (supervised vs. self-supervised, adversarially trained, and CLIP’s joint language-image training), architecture (convolutional vs. vision transformer) and training dataset size (ranging from 1M to 1B images). Taken together, these are some of the most promising directions our field has developed to date—but this field would not be machine learning if new breakthroughs weren’t within reach in the next few weeks, months and years. Therefore, we open-sourced modelvshuman, a Python toolbox that enables testing both PyTorch and TensorFlow models on our comprehensive benchmark suite of OOD generalisation data in order to measure future progress. Even today, our results give cause for (cautious) optimism. After a method overview (Section 2), we are able to report that the human-machine distortion robustness gap is closing: the best models now match or in many cases even exceed human feedforward performance on most of the investigated OOD datasets (Section 3). While there is still a substantial image-level consistency gap between humans and machines, this gap is narrowing on some—but not all—datasets when the size of the training dataset is increased (Section 4). ",
129
+ "bbox": [
130
+ 173,
131
+ 507,
132
+ 825,
133
+ 714
134
+ ],
135
+ "page_idx": 1
136
+ },
137
+ {
138
+ "type": "text",
139
+ "text": "2 Methods: datasets, psychophysical experiments, models, metrics, toolbox ",
140
+ "text_level": 1,
141
+ "bbox": [
142
+ 173,
143
+ 747,
144
+ 810,
145
+ 765
146
+ ],
147
+ "page_idx": 1
148
+ },
149
+ {
150
+ "type": "text",
151
+ "text": "OOD datasets with consistency-grade human data. We collected human data for 17 generalisation datasets (visualized in Figures 7 and 8 in the Appendix, which also state the number of subjects and trials per experiment) on a carefully calibrated screen in a dedicated psychophysical laboratory (a total of 85,120 trials across 90 observers). Five datasets each correspond to a single manipulation (sketches, edge-filtered images, silhouettes, images with a texture-shape cue conflict, and stylized images where the original image texture is replaced by the style of a painting); the remaining twelve datasets correspond to parametric image degradations (e.g. different levels of noise or blur). Those OOD datasets have in common that they are designed to test ImageNet-trained models. OOD images were obtained from different sources: sketches from ImageNet-Sketch [16], stylized images from ",
152
+ "bbox": [
153
+ 174,
154
+ 786,
155
+ 825,
156
+ 911
157
+ ],
158
+ "page_idx": 1
159
+ },
160
+ {
161
+ "type": "text",
162
+ "text": "Stylized-ImageNet [17], edge-filtered images, silhouettes and cue conflict images from $[ 1 7 ] ^ { 1 }$ , and the remaining twelve parametric datasets were adapted from [33]. For these parametric datasets, [33] collected human accuracies but unfortunately, they showed different images to different observers implying that we cannot use their human data to assess image-level consistency between humans and machines. Thus we collected psychophysical data for those images ourselves by showing exactly the same images to multiple observers for each of those twelve datasets. Additionally, we cropped the images from [33] to $2 2 4 \\times 2 2 4$ pixels to allow for a fair comparison to ImageNet models (all models included in our comparison receive $2 2 4 \\times 2 2 4$ input images; [33] showed $2 5 6 \\times 2 5 6$ images to human observers in many cases). ",
163
+ "bbox": [
164
+ 174,
165
+ 90,
166
+ 825,
167
+ 215
168
+ ],
169
+ "page_idx": 2
170
+ },
171
+ {
172
+ "type": "text",
173
+ "text": "Psychophysical experiments. 90 observers were tested in a darkened chamber. Stimuli were presented at the center of a $2 2 '$ monitor with $1 9 2 0 \\times 1 2 0 0$ pixels resolution (refresh rate: $1 2 0 \\mathrm { H z } ,$ ). Viewing distance was $1 0 7 \\mathrm { c m }$ and target images subtended $3 \\times 3$ degrees of visual angle. Human observers were presented with an image and asked to select the correct category out of 16 basic categories (such as chair, dog, airplane, etc.). Stimuli were balanced w.r.t. classes and presented in random order. For ImageNet-trained models, in order to obtain a choice from the same 16 categories, the 1,000 class decision vector was mapped to those 16 classes using the WordNet hierarchy [34]. In Appendix I, we explain why this mapping is optimal. We closely followed the experimental protocol defined by [33], who presented images for $2 0 0 ~ \\mathrm { { m s } }$ followed by a $1 / f$ backward mask to limit the influence of recurrent processing (otherwise comparing to feedforward models would be difficult). Further experimental details are provided in Appendix C. ",
174
+ "bbox": [
175
+ 173,
176
+ 229,
177
+ 825,
178
+ 382
179
+ ],
180
+ "page_idx": 2
181
+ },
182
+ {
183
+ "type": "text",
184
+ "text": "Why not use crowdsourcing instead? Our approach of investigating few observers in a highquality laboratory setting performing many trials is known as the so-called “small-N design”, the bread-and-butter approach in high-quality psychophysics—see, e.g., the review “Small is beautiful: In defense of the small-N design” [35]. This is in contrast to the “crowdsourcing approach” (many observers in a noisy setting performing fewer trials each). The highly controlled conditions of the Wichmannlab’s psychophysical laboratory come with many advantages over crowdsourced data collection: precise timing control (down to the millisecond), carefully calibrated monitors (especially important for e.g. low-contrast stimuli), controlled viewing distance (important for foveal presentation), full visual acuity (we performed an acuity test with every observer prior to the experiment), observer attention (e.g. no multitasking or children running around during an experiment, which may happen in a crowdsourcing study), just to name a few [36]. Jointly, these factors contribute to high data quality. ",
185
+ "bbox": [
186
+ 174,
187
+ 396,
188
+ 825,
189
+ 563
190
+ ],
191
+ "page_idx": 2
192
+ },
193
+ {
194
+ "type": "text",
195
+ "text": "Models. In order to disentangle the influence of objective function, architecture and training dataset size, we tested a total of 52 models: 24 standard ImageNet-trained CNNs [37], 8 selfsupervised models [38–43], $^ 2 6$ Big Transfer models [45], 5 adversarially trained models [46], 5 vision transformers [47, 48], two semi-weakly supervised models [49] as well as Noisy Student [50] and CLIP [51]. Technical details for all models are provided in the Appendix. ",
196
+ "bbox": [
197
+ 174,
198
+ 575,
199
+ 825,
200
+ 646
201
+ ],
202
+ "page_idx": 2
203
+ },
204
+ {
205
+ "type": "text",
206
+ "text": "Metrics. In addition to $o o D$ accuracy (averaged across conditions and datasets), the following three metrics quantify how closely machines are aligned with the decision behaviour of humans. ",
207
+ "bbox": [
208
+ 173,
209
+ 660,
210
+ 823,
211
+ 689
212
+ ],
213
+ "page_idx": 2
214
+ },
215
+ {
216
+ "type": "text",
217
+ "text": "Accuracy difference $A ( m )$ is a simple aggregate measure that compares the accuracy of a machine $m$ to the accuracy of human observers in different out-of-distribution tests, ",
218
+ "bbox": [
219
+ 169,
220
+ 694,
221
+ 823,
222
+ 722
223
+ ],
224
+ "page_idx": 2
225
+ },
226
+ {
227
+ "type": "equation",
228
+ "img_path": "images/ef8c47b0e4bc5c49a115fa26f140430e5899ec448f42fc547004d70e0145a8e6.jpg",
229
+ "text": "$$\nA ( m ) : \\mathbb { R } \\to [ 0 , 1 ] , m \\mapsto { \\frac { 1 } { | D | } } \\sum _ { d \\in D } { \\frac { 1 } { | H _ { d } | } } \\sum _ { h \\in H _ { d } } { \\frac { 1 } { | C _ { d } | } } \\sum _ { c \\in C _ { d } } ( \\operatorname { a c c } _ { d , c } ( h ) - \\operatorname { a c c } _ { d , c } ( m ) ) ^ { 2 }\n$$",
230
+ "text_format": "latex",
231
+ "bbox": [
232
+ 228,
233
+ 726,
234
+ 767,
235
+ 765
236
+ ],
237
+ "page_idx": 2
238
+ },
239
+ {
240
+ "type": "text",
241
+ "text": "where $\\operatorname { a c c } _ { d , c } ( \\cdot )$ is the accuracy of the model or the human on dataset $d \\in D$ and condition $c \\in C _ { d }$ (e.g. a particular noise level), and $h \\in H _ { D }$ denotes a human observer tested on dataset $d$ . Analogously, one can compute the average accuracy difference between a human observer $h _ { 1 }$ and all other human observers by substituting $h _ { 1 }$ for $m$ and $h \\in H _ { D } \\setminus \\{ h _ { 1 } \\}$ for $h \\in H _ { D }$ (which can also be applied for the two metrics defined below). ",
242
+ "bbox": [
243
+ 173,
244
+ 768,
245
+ 825,
246
+ 838
247
+ ],
248
+ "page_idx": 2
249
+ },
250
+ {
251
+ "type": "text",
252
+ "text": "Aggregated metrics like $A ( m )$ ignore individual image-level decisions. Two models with vastly different image-level decision behaviour might still end up with the same accuracies on each dataset and condition. Hence, we include two additional metrics in our benchmark that are sensitive to decisions on individual images. ",
253
+ "bbox": [
254
+ 174,
255
+ 90,
256
+ 825,
257
+ 147
258
+ ],
259
+ "page_idx": 3
260
+ },
261
+ {
262
+ "type": "text",
263
+ "text": "Observed consistency $O ( m )$ [32] measures the fraction of samples for which humans and a model $m$ get the same sample either both right or both wrong. More precisely, let $b _ { h , m } ( s )$ be one if both a human observer $h$ and $m$ decide either correctly or incorrectly on a given sample $s$ , and zero otherwise. We calculate the average observed consistency as ",
264
+ "bbox": [
265
+ 174,
266
+ 152,
267
+ 825,
268
+ 209
269
+ ],
270
+ "page_idx": 3
271
+ },
272
+ {
273
+ "type": "equation",
274
+ "img_path": "images/bb8b20090e0751822a8fb2f05295b2d0b4f3f48349c9eebbd656c3a30e5613f2.jpg",
275
+ "text": "$$\nO ( m ) : \\mathbb { R } \\to [ 0 , 1 ] , m \\mapsto \\frac { 1 } { | D | } \\sum _ { d \\in D } \\frac { 1 } { | H _ { d } | } \\sum _ { h \\in H _ { d } } \\frac { 1 } { | C _ { d } | } \\sum _ { c \\in C _ { d } } \\frac { 1 } { | S _ { d , c } | } \\sum _ { s \\in S _ { d , c } } b _ { h , m } ( s )\n$$",
276
+ "text_format": "latex",
277
+ "bbox": [
278
+ 243,
279
+ 224,
280
+ 756,
281
+ 265
282
+ ],
283
+ "page_idx": 3
284
+ },
285
+ {
286
+ "type": "text",
287
+ "text": "where $s \\in S _ { d , c }$ denotes a sample $s$ (in our case, an image) of condition $c$ from dataset $d$ . Note that this measure can only be zero if the accuracy of $h$ and $m$ are exactly the same in each dataset and condition. ",
288
+ "bbox": [
289
+ 174,
290
+ 275,
291
+ 823,
292
+ 316
293
+ ],
294
+ "page_idx": 3
295
+ },
296
+ {
297
+ "type": "text",
298
+ "text": "Error consistency $E ( m )$ [32] tracks whether there is above-chance consistency. This is an important distinction, since e.g. two decision makers with $9 5 \\%$ accuracy each will have at least $90 \\%$ observed consistency, even if their $5 \\%$ errors occur on non-overlapping subsets of the test data (intuitively, they both get most images correct and thus observed overlap is high). To this end, error consistency (a.k.a. Cohen’s kappa, cf. [52]) indicates whether the observed consistency is larger than what could have been expected given two independent binomial decision makers with matched accuracy, which we denote as $\\hat { o } _ { h , m }$ . This can easily be computed analytically [e.g. 32, equation 1]. Then, the average error consistency is given by ",
299
+ "bbox": [
300
+ 173,
301
+ 321,
302
+ 825,
303
+ 435
304
+ ],
305
+ "page_idx": 3
306
+ },
307
+ {
308
+ "type": "equation",
309
+ "img_path": "images/cc265edfd05ab96a6314d288d579cd189dfafd4b2f26e092beafee4fb3b1aecf.jpg",
310
+ "text": "$$\nE ( m ) : \\mathbb { R } \\to [ - 1 , 1 ] , m \\mapsto \\frac { 1 } { | D | } \\sum _ { d \\in D } \\frac { 1 } { | H _ { d } | } \\sum _ { h \\in H _ { d } } \\frac { 1 } { | C _ { d } | } \\sum _ { c \\in C _ { d } } \\frac { \\big ( \\frac { 1 } { | S _ { d , c } | } \\sum _ { s \\in S _ { d , c } } b _ { h , m } ( s ) \\big ) - \\hat { o } _ { h , m } ( S _ { d , c } ) } { 1 - \\hat { o } _ { h , m } ( S _ { d , c } ) }\n$$",
311
+ "text_format": "latex",
312
+ "bbox": [
313
+ 181,
314
+ 440,
315
+ 821,
316
+ 486
317
+ ],
318
+ "page_idx": 3
319
+ },
320
+ {
321
+ "type": "text",
322
+ "text": "Benchmark $\\pmb { \\& }$ toolbox. $A ( m ) , O ( m )$ and $E ( m )$ each quantify a certain aspect of the humanmachine gap. We use the mean rank order across these metrics to determine an overall model ranking (Table 2 in the Appendix). However, we would like to emphasise that the primary purpose of this benchmark is to generate insights, not winners. Since insights are best gained from detailed plots and analyses, we open-source modelvshuman, a Python project to benchmark models against human data.3 The current model zoo already includes $5 0 +$ models, and an option to add new ones (both PyTorch and TensorFlow). Evaluating a model produces a $1 5 +$ page report on model behaviour. All plots in this paper can be generated for future models—to track whether they narrow the gap towards human vision, or to determine whether an algorithmic modification to a baseline model (e.g., an architectural improvement) changes model behaviour. ",
323
+ "bbox": [
324
+ 173,
325
+ 511,
326
+ 825,
327
+ 651
328
+ ],
329
+ "page_idx": 3
330
+ },
331
+ {
332
+ "type": "text",
333
+ "text": "3 Robustness across models: the OOD distortion robustness gap between human and machine vision is closing ",
334
+ "text_level": 1,
335
+ "bbox": [
336
+ 176,
337
+ 670,
338
+ 797,
339
+ 705
340
+ ],
341
+ "page_idx": 3
342
+ },
343
+ {
344
+ "type": "text",
345
+ "text": "We are interested in measuring whether we are making progress in closing the gap between human and machine vision. For a long time, CNNs were unable to match human robustness in terms of generalisation beyond the training distribution—a large OOD distortion robustness gap [14, 33, 53– 55]. Having tested human observers on 17 OOD datasets, we are now able to compare the latest developments in machine vision to human perception. Our core results are shown in Figure 1: the OOD distortion robustness gap between human and machine vision is closing (1a, 1b), especially for models trained on large-scale datasets. On the individual image level, a human-machine consistency gap remains (especially 1d), which will be discussed later. ",
346
+ "bbox": [
347
+ 173,
348
+ 719,
349
+ 826,
350
+ 830
351
+ ],
352
+ "page_idx": 3
353
+ },
354
+ {
355
+ "type": "text",
356
+ "text": "Self-supervised models “If intelligence is a cake, the bulk of the cake is unsupervised learning, the icing on the cake is supervised learning and the cherry on the cake is reinforcement learning”, ",
357
+ "bbox": [
358
+ 174,
359
+ 845,
360
+ 823,
361
+ 875
362
+ ],
363
+ "page_idx": 3
364
+ },
365
+ {
366
+ "type": "image",
367
+ "img_path": "images/86ad5cf2160560092b0909f92fdf790c91243559e5415051f373514e6ac54b68.jpg",
368
+ "image_caption": [
369
+ "Figure 1: Core results, aggregated over 17 out-of-distribution (OOD) datasets: The OOD robustness gap between human and machine vision is closing (top), but an image-level consistency gap remains (bottom). Results compare humans, standard supervised CNNs, self-supervised models, adversarially trained models, vision transformers, noisy student, BiT, SWSL and CLIP. For convenience, $\\downarrow$ marks models that are trained on large-scale datasets. Metrics defined in Section 2. Best viewed on screen. "
370
+ ],
371
+ "image_footnote": [],
372
+ "bbox": [
373
+ 171,
374
+ 83,
375
+ 825,
376
+ 410
377
+ ],
378
+ "page_idx": 4
379
+ },
380
+ {
381
+ "type": "text",
382
+ "text": "Yann LeCun said in 2016 [56]. A few years later, the entire cake is finally on the table—the representations learned via self-supervised learning4 now compete with supervised methods on ImageNet [43] and outperform supervised pre-training for object detection [41]. But how do recent self-supervised models differ from their supervised counterparts in terms of their behaviour? Do they bring machine vision closer to human vision? Humans, too, rapidly learn to recognise new objects without requiring hundreds of labels per instance; additionally a number of studies reported increased similarities between self-supervised models and human perception [57–61]. Figure 2 compares the generalisation behaviour of eight self-supervised models in orange (PIRL, MoCo, MoCoV2, InfoMin, InsDis, SimCLR-x1, SimCLR-x2, SimCLR-x4)—with 24 standard supervised models (grey). We find only marginal differences between self-supervised and supervised models: Across distortion types, self-supervised networks are well within the range of their poorly generalising supervised counterparts. However, there is one exception: the three SimCLR variants show strong generalisation improvements on uniform noise, low contrast, and high-pass images, where they are the three topperforming self-supervised networks—quite remarkable given that SimCLR models were trained on a different set of augmentations (random crop with flip and resize, colour distortion, and Gaussian blur). Curious by the outstanding performance of SimCLR, we asked whether the self-supervised objective function or the choice of training data augmentations was the defining factor. When comparing self-supervised SimCLR models with augmentation-matched baseline models trained in the standard supervised fashion (Figure 15 in the Appendix), we find that the augmentation scheme (rather than the self-supervised objective) indeed made the crucial difference: supervised baselines show just the same generalisation behaviour, a finding that fits well with [62], who observed that the influence of training data augmentations is stronger than the role of architecture or training objective. In conclusion, our analyses indicate that the “cake” of contrastive self-supervised learning currently (and disappointingly) tastes much like the “icing”. ",
383
+ "bbox": [
384
+ 173,
385
+ 526,
386
+ 825,
387
+ 858
388
+ ],
389
+ "page_idx": 4
390
+ },
391
+ {
392
+ "type": "image",
393
+ "img_path": "images/b9146a455daf8e1079d24472deb22b20808730c3d00b07d903cdfcd7e8f5e30f.jpg",
394
+ "image_caption": [
395
+ "Figure 2: The OOD distortion robustness gap between human and machine vision is closing. Robustness towards parametric distortions for humans, standard supervised CNNs, self-supervised models, adversarially trained models, vision transformers, noisy student, BiT, SWSL, CLIP. Symbols indicate architecture type ( $\\bigcirc$ convolutional, $\\bigtriangledown$ vision transformer, $\\diamondsuit$ human); best viewed on screen. "
396
+ ],
397
+ "image_footnote": [],
398
+ "bbox": [
399
+ 171,
400
+ 85,
401
+ 823,
402
+ 445
403
+ ],
404
+ "page_idx": 5
405
+ },
406
+ {
407
+ "type": "text",
408
+ "text": "Adversarially trained models The vulnerability of CNNs to adversarial input perturbations is, arguably, one of the most striking shortcomings of this model class compared to robust human perception. A successful method to increase adversarial robustness is adversarial training [e.g. 63, 64]. The resulting models were found to transfer better, have meaningful gradients [65], and enable interpolating between two input images [66]: “robust optimization can actually be viewed as inducing a human prior over the features that models are able to learn” [67, p. 10]. Therefore, we include five models with a ResNet-50 architecture and different accuracy-robustness tradeoffs, adversarially trained on ImageNet with Microsoft-scale resources by [46] to test whether models with “perceptually-aligned representations” also show human-aligned OOD generalisation behaviour—as we would hope. This is not the case: the stronger the model is trained adversarially (darker shades of blue in Figure 2), the more susceptible it becomes to (random) image degradations. Most strikingly, a simple rotation by 90 degrees leads to a $50 \\%$ drop in classification accuracy. Adversarial robustness seems to come at the cost of increased vulnerability to large-scale perturbations.5 On the other hand, there is a silver lining: when testing whether models are biased towards texture or shape by testing them on cue conflict images (Figure 3), in accordance with [69, 70] we observe a perfect relationship between shape bias and the degree of adversarial training, a big step in the direction of human shape bias (and a stronger shape bias than nearly all other models). ",
409
+ "bbox": [
410
+ 173,
411
+ 537,
412
+ 825,
413
+ 772
414
+ ],
415
+ "page_idx": 5
416
+ },
417
+ {
418
+ "type": "text",
419
+ "text": "Vision transformers In computer vision, convolutional networks have become by far the dominating model class over the last decade. Vision transformers [47] break with the long tradition of using convolutions and are rapidly gaining traction [71]. We find that the best vision transformer (ViT-L trained on 14M images) even exceeds human OOD accuracy (Figure 1a shows the average across 17 datasets). There appears to be an additive effect of architecture and data: vision transformers trained on 1M images (light green) are already better than standard convolutional models; training on 14M images (dark green) gives another performance boost. In line with [72, 73], we observe a higher shape bias compared to most standard CNNs. ",
420
+ "bbox": [
421
+ 174,
422
+ 777,
423
+ 825,
424
+ 887
425
+ ],
426
+ "page_idx": 5
427
+ },
428
+ {
429
+ "type": "image",
430
+ "img_path": "images/011898817b7a7a617c58c30085614f1ce242e09dfb249b86d8c62339fec5a6f2.jpg",
431
+ "image_caption": [
432
+ "Figure 3: Shape vs. texture biases of different models. While human shape bias is not yet matched, several approaches improve over vanilla CNNs. Box plots show category-dependent distribution of shape / texture biases (shape bias: high values, texture bias: low values). "
433
+ ],
434
+ "image_footnote": [],
435
+ "bbox": [
436
+ 173,
437
+ 87,
438
+ 825,
439
+ 232
440
+ ],
441
+ "page_idx": 6
442
+ },
443
+ {
444
+ "type": "text",
445
+ "text": "Standard models trained on more data: BiT-M, SWSL, Noisy Student Interestingly, the biggest effect on OOD robustness we find simply comes from training on larger datasets, not from advanced architectures. When standard models are combined with large-scale training (14M images for BiT-M, 300M for Noisy Student and a remarkable 940M for SWSL), OOD accuracies reach levels not known from standard ImageNet-trained models; these models even outperform a more powerful architecture (vision transformer ViT-S) trained on less data (1M) as shown in Figure 1a. Simply training on (substantially) more data substantially narrows the gap to human OOD accuracies (1b), a finding that we quantified in Appendix H by means of a regression model. (The regression model also revealed a significant interaction between dataset size and objective function, as well as a significant main effect for transformers over CNNs.) Noisy Student in particular outperforms humans by a large margin overall (Figure 1a)—the beginning of a new human-machine gap, this time in favour of machines? ",
446
+ "bbox": [
447
+ 174,
448
+ 310,
449
+ 825,
450
+ 462
451
+ ],
452
+ "page_idx": 6
453
+ },
454
+ {
455
+ "type": "text",
456
+ "text": "CLIP CLIP is special: trained on 400M images6 (more data) with joint language-image supervision (novel objective) and a vision transformer backbone (non-standard architecture), it scores close to humans across all of our metrics presented in Figure 1; most strikingly in terms of error consistency (which will be discussed in the next section). We tested a number of hypotheses to disentangle why CLIP appears “special”. H1: because CLIP is trained on a lot of data? Presumably no: Noisy Student—a model trained on a comparably large dataset of 300M images—performs very well on OOD accuracy, but poorly on error consistency. A caveat in this comparison is the quality of the labels: while Noisy Student uses pseudolabeling, CLIP receives web-based labels for all images. H2: because CLIP receives higher-quality labels? About $6 \\%$ of ImageNet labels are plainly wrong [74]. Could it be the case that CLIP simply performs better since it doesn’t suffer from this issue? In order to test this, we used CLIP to generate new labels for all 1.3M ImageNet images: (a) hard labels, i.e. the top-1 class predicted by CLIP; and (b) soft labels, i.e. using CLIP’s full posterior distribution as a target. We then trained ResNet-50 from scratch on CLIP hard and soft labels (for details see Appendix E). However, this does not show any robustness improvements over a vanilla ImageNet-trained ResNet-50, thus different/better labels are not a likely root cause. H3: because CLIP has a special image+text loss? Yes and no: CLIP training on ResNet-50 leads to astonishingly poor OOD results, so training a standard model with CLIP loss alone is insufficient. However, while neither architecture nor loss alone sufficiently explain why CLIP is special, we find a clear interaction between architecture and loss (described in more detail in the Appendix along with the other “CLIP ablation” experiments mentioned above). ",
457
+ "bbox": [
458
+ 173,
459
+ 477,
460
+ 825,
461
+ 752
462
+ ],
463
+ "page_idx": 6
464
+ },
465
+ {
466
+ "type": "text",
467
+ "text": "4 Consistency between models: data-rich models narrow the substantial image-level consistency gap between human and machine vision ",
468
+ "text_level": 1,
469
+ "bbox": [
470
+ 176,
471
+ 772,
472
+ 789,
473
+ 808
474
+ ],
475
+ "page_idx": 6
476
+ },
477
+ {
478
+ "type": "text",
479
+ "text": "In the previous section we have seen that while self-supervised and adversarially trained models lack OOD distortion robustness, models based on vision transformers and/or trained on large-scale datasets now match or exceed human feedforward performance on most datasets. Behaviourally, a natural follow-up question is to ask not just how many, but which errors models make—i.e., do they make errors on the same individual images as humans on OOD data (an important characteristic of a “human-like” model, cf. [32, 75])? This is quantified via error consistency (defined in Section 2); which additionally allows us to compare models with each other, asking e.g. which model classes make similar errors. In Figure 4, we compare all models with each other and with humans, asking whether they make errors on the same images. On this particular dataset (sketch images), we can see one big model cluster. Irrespective of whether one takes a standard supervised model, a selfsupervised model, an adversarially trained model or a vision transformer, all those models make highly systematic errors (which extends the results of [32, 76] who found similarities between standard vanilla CNNs). Humans, on the other hand, show a very different pattern of errors. Interestingly, the boundary between humans and some data-rich models at the bottom of the figure—especially CLIP (400M images) and SWSL (940M)—is blurry: some (but not all) data-rich models much more closely mirror the patterns of errors that humans make, and we identified the first models to achieve higher error consistency with humans than with other (standard) models. Are these promising results shared across datasets, beyond the sketch images? In Figures 1c and 1d, aggregated results over 17 datasets are presented. Here, we can see that data-rich models approach human-to-human observed consistency, but not error consistency. Taken in isolation, observed consistency is not a good measure of image-level consistency since it does not take consistency by chance into account; error consistency tracks whether there is consistency beyond chance; here we see that there is still a substantial image-level consistency gap between human and machine vision. However, several models improve over vanilla CNNs, especially BiT-M (trained on 14M images) and CLIP (400M images). This progress is non-trivial; at the same time, there is ample room for future improvement. ",
480
+ "bbox": [
481
+ 174,
482
+ 820,
483
+ 823,
484
+ 862
485
+ ],
486
+ "page_idx": 6
487
+ },
488
+ {
489
+ "type": "image",
490
+ "img_path": "images/a17382a03d11cd860c34972f94aa95b35c09aac1a36b70cc63b7199f445e2bdc.jpg",
491
+ "image_caption": [
492
+ "Figure 4: Data-rich models narrow the substantial image-level consistency gap between humans and machines. Error consistency analysis on a single dataset (sketch images; for other datasets see Appendix, Figures 9, 11, 12, 13, 14) shows that most models cluster (dark red $=$ highly consistent errors) irrespective of their architecture and objective function; humans cluster differently (high human-to-human consistency, low human-to-model consistency); but some data-rich models including CLIP and SWSL blur the boundary, making more human-like errors than standard models. "
493
+ ],
494
+ "image_footnote": [],
495
+ "bbox": [
496
+ 207,
497
+ 90,
498
+ 800,
499
+ 522
500
+ ],
501
+ "page_idx": 7
502
+ },
503
+ {
504
+ "type": "text",
505
+ "text": "",
506
+ "bbox": [
507
+ 173,
508
+ 648,
509
+ 825,
510
+ 911
511
+ ],
512
+ "page_idx": 7
513
+ },
514
+ {
515
+ "type": "image",
516
+ "img_path": "images/454421bb94ec0b451e543d9dbf78de3ac22a934484765c3e9915c81e54a8807a.jpg",
517
+ "image_caption": [
518
+ "Figure 5: Partial failure, partial success: Error consistency with humans aggregated over multiple datasets. Left: 12 datasets where model accuracies exceed human accuracies; here, there is still a substantial image-level consistency gap to humans. Right: 5 datasets (sketch, silhouette, edge, cue conflict, low-pass) where humans are more robust. Here, OOD accuracy is a near-perfect predictor of image-level consistency; especially data-rich models (e.g. CLIP, SWSL, BiT) narrow the consistency gap to humans. Symbols indicate architecture type $\\bigcirc$ convolutional, $\\bigtriangledown$ vision transformer, $\\diamondsuit$ human). "
519
+ ],
520
+ "image_footnote": [],
521
+ "bbox": [
522
+ 200,
523
+ 85,
524
+ 790,
525
+ 329
526
+ ],
527
+ "page_idx": 8
528
+ },
529
+ {
530
+ "type": "text",
531
+ "text": "",
532
+ "bbox": [
533
+ 174,
534
+ 455,
535
+ 825,
536
+ 498
537
+ ],
538
+ "page_idx": 8
539
+ },
540
+ {
541
+ "type": "text",
542
+ "text": "How do the findings from Figure 4 (showing nearly human-level error consistency for sketch images) and from Figure 1d (showing a substantial consistency gap when aggregating over 17 datasets) fit together? Upon closer inspection, we discovered that there are two distinct cases. On 12 datasets (stylized, colour/greyscale, contrast, high-pass, phase-scrambling, power-equalisation, false colour, rotation, eidolonI, -II and -III as well as uniform noise), the human-machine gap is large; here, more robust models do not show improved error consistency (as can be see in Figure 5a). On the other hand, for five datasets (sketch, silhouette, edge, cue conflict, low-pass filtering), there is a completely different result pattern: Here, OOD accuracy is a near-perfect predictor of error consistency, which means that improved generalisation robustness leads to more human-like errors (Figure 5b). Furthermore, training on large-scale datasets leads to considerable improvements along both axes for standard CNNs. Within models trained on larger datasets, CLIP scores best; but models with a standard architecture (SWSL: based on ResNet-50 and ResNeXt-101) closely follow suit. ",
543
+ "bbox": [
544
+ 173,
545
+ 503,
546
+ 825,
547
+ 670
548
+ ],
549
+ "page_idx": 8
550
+ },
551
+ {
552
+ "type": "text",
553
+ "text": "It remains an open question why the training dataset appears to have the most important impact on a model’s decision boundary as measured by error consistency (as opposed to other aspects of a model’s inductive bias). Datasets contain various shortcut opportunities [14], and if two different models are trained on similar data, they might converge to a similar solution simply by exploiting the same shortcuts—which would also fit well to the finding that adversarial examples typically transfer very well between different models [77, 78]. Making models more flexible (such as transformers, a generalisation of CNNs) wouldn’t change much in this regard, since flexible models can still exploit the same shortcuts. Two predictions immediately follow from this hypothesis: (1.) error consistency between two identical models trained on very different datasets, such as ImageNet vs. Stylized-ImageNet, is much lower than error consistency between very different models (ResNet-50 vs. VGG-16) trained on the same dataset. (2.) error consistency between ResNet-50 and a highly flexible model (e.g., a vision transformer) is much higher than error consistency between ResNet-50 and a highly constrained model like BagNet-9 [79]. We provide evidence for both predictions in Appendix B, which makes the shortcut hypothesis of model similarity a potential starting point for future analyses. Looking forward, it may be worth exploring the links between shortcut learning and image difficulty, such as understanding whether many “trivially easy” images in common datasets like ImageNet causes models to expoit the same characteristics irrespective of their architecture [80]. ",
554
+ "bbox": [
555
+ 174,
556
+ 676,
557
+ 825,
558
+ 911
559
+ ],
560
+ "page_idx": 8
561
+ },
562
+ {
563
+ "type": "text",
564
+ "text": "5 Discussion ",
565
+ "text_level": 1,
566
+ "bbox": [
567
+ 174,
568
+ 89,
569
+ 294,
570
+ 106
571
+ ],
572
+ "page_idx": 9
573
+ },
574
+ {
575
+ "type": "text",
576
+ "text": "Summary We set out to answer the question: Are we making progress in closing the gap between human and machine vision? In order to quantify progress, we performed large-scale psychophysical experiments on 17 out-of-distribution distortion datasets (open-sourced along with evaluation code as a benchmark to track future progress). We then investigated models that push the boundaries of traditional deep learning (different objective functions, architectures, and dataset sizes ranging from 1M to 1B), asking how they perform relative to human visual perception. We found that the OOD distortion robustness gap between human and machine vision is closing, as the best models now match or exceed human accuracies. At the same time, an image-level consistency gap remains; however, this gap that is at least in some cases narrowing for models trained on large-scale datasets. ",
577
+ "bbox": [
578
+ 174,
579
+ 116,
580
+ 825,
581
+ 241
582
+ ],
583
+ "page_idx": 9
584
+ },
585
+ {
586
+ "type": "text",
587
+ "text": "Limitations Model robustness is studied from many different viewpoints, including adversarial robustness [77], theoretical robustness guarantees [e.g. 81], or label noise robustness [e.g. 82]. The focus of our study is robustness towards non-adversarial out-of-distribution data, which is particularly well-suited for comparisons with humans. Since we aimed at a maximally fair comparison between feedforward models and human perception, presentation times for human observers were limited to $2 0 0 \\mathrm { { m s } }$ in order to limit the influence of recurrent processing. Therefore, human ceiling performance might be higher still (given more time); investigating this would mean going beyond “core object recognition”, which happens within less than $2 0 0 ~ \\mathrm { { m s } }$ during a single fixation [83]. Furthermore, human and machine vision can be compared in many different ways. This includes comparing against neural data [84, 85], contrasting Gestalt effects [e.g. 86], object similarity judgments [87], or mid-level properties [61] and is of course not limited to studying object recognition. By no means do we mean to imply that our behavioural comparison is the only feasible option—on the contrary, we believe it will be all the more exciting to investigate whether our behavioural findings have implications for other means of comparison! ",
588
+ "bbox": [
589
+ 174,
590
+ 260,
591
+ 825,
592
+ 453
593
+ ],
594
+ "page_idx": 9
595
+ },
596
+ {
597
+ "type": "text",
598
+ "text": "Discussion We have to admit that we view our results concerning the benefits of increasing dataset size by one-to-three orders of magnitude with mixed feelings. On the one hand, “simply” training standard models on (a lot) more data certainly has an intellectually disappointing element—particularly given many rich ideas in the cognitive science and neuroscience literature on which architectural changes might be required to bring machine vision closer to human vision [88–93]. Additionally, large-scale training comes with infrastructure demands that are hard to meet for many academic researchers. On the other hand, we find it truly exciting to see that machine models are closing not just the OOD distortion robustness gap to humans, but that also, at least for some datasets, those models are actually making more human-like decisions on an individual image level; image-level response consistency is a much stricter behavioural requirement than just e.g. matching overall accuracies. Taken together, our results give reason to celebrate partial success in closing the gap between human and machine vision. In those cases where there is still ample room for improvement, our psychophysical benchmark datasets and toolbox may prove useful in quantifying future progress. ",
599
+ "bbox": [
600
+ 174,
601
+ 473,
602
+ 825,
603
+ 652
604
+ ],
605
+ "page_idx": 9
606
+ },
607
+ {
608
+ "type": "text",
609
+ "text": "Acknowledgments and disclosure of funding ",
610
+ "text_level": 1,
611
+ "bbox": [
612
+ 174,
613
+ 672,
614
+ 483,
615
+ 686
616
+ ],
617
+ "page_idx": 9
618
+ },
619
+ {
620
+ "type": "text",
621
+ "text": "We thank Andreas Geiger, Simon Kornblith, Kristof Meding, Claudio Michaelis and Ludwig Schmidt for helpful discussions regarding different aspects of this work; Lukas Huber, Maximus Mutschler, David-Elias Künstle for feedback on the manuscript; Ken Kahn for pointing out typos; Santiago Cadena for sharing a PyTorch implementation of SimCLR; Katherine Hermann and her collaborators for providing supervised SimCLR baselines; Uli Wannek and Silke Gramer for infrastructure/administrative support; the many authors who made their models publicly available; and our anonymous reviewers for many valuable suggestions. ",
622
+ "bbox": [
623
+ 174,
624
+ 690,
625
+ 825,
626
+ 766
627
+ ],
628
+ "page_idx": 9
629
+ },
630
+ {
631
+ "type": "text",
632
+ "text": "Furthermore, we are grateful to the International Max Planck Research School for Intelligent Systems (IMPRSIS) for supporting R.G.; the Collaborative Research Center (Projektnummer 276693517—SFB 1233: Robust Vision) for supporting M.B. and F.A.W. This work was supported by the German Federal Ministry of Education and Research (BMBF): Tübingen AI Center, FKZ: 01IS18039A (W.B. and M.B.). F.A.W. is a member of the Machine Learning Cluster of Excellence, EXC number 2064/1—Project number 390727645. M.B. and W.B. acknowledge funding from the MICrONS program of the Intelligence Advanced Research Projects Activity (IARPA) via Department of Interior/Interior Business Center (DoI/IBC) contract number D16PC00003. W.B. acknowledges financial support via the Emmy Noether Research Group on The Role of Strong Response Consistency for Robust and Explainable Machine Vision funded by the German Research Foundation (DFG) under grant no. BR 6382/1-1. ",
633
+ "bbox": [
634
+ 174,
635
+ 773,
636
+ 825,
637
+ 911
638
+ ],
639
+ "page_idx": 9
640
+ },
641
+ {
642
+ "type": "text",
643
+ "text": "Author contributions ",
644
+ "text_level": 1,
645
+ "bbox": [
646
+ 174,
647
+ 92,
648
+ 323,
649
+ 106
650
+ ],
651
+ "page_idx": 10
652
+ },
653
+ {
654
+ "type": "text",
655
+ "text": "Project idea: R.G. and W.B.; project lead: R.G.; coding toolbox and model evaluation pipeline: R.G., K.N. and B.M. based on a prototype by R.G.; training models: K.N. with input from R.G., W.B. and M.B.; data visualisation: R.G., B.M. and K.N. with input from M.B., F.A.W. and W.B.; psychophysical data collection: T.T. (12 datasets) and B.M. (2 datasets) under the guidance of R.G. and F.A.W.; curating stimuli: R.G.; interpreting analyses and findings: R.G., M.B., F.A.W. and W.B.; guidance, feedback, infrastructure & funding acquisition: M.B., F.A.W. and W.B.; paper writing: R.G. with help from F.A.W. and W.B. and input from all other authors. ",
656
+ "bbox": [
657
+ 174,
658
+ 109,
659
+ 826,
660
+ 190
661
+ ],
662
+ "page_idx": 10
663
+ },
664
+ {
665
+ "type": "text",
666
+ "text": "References ",
667
+ "text_level": 1,
668
+ "bbox": [
669
+ 174,
670
+ 209,
671
+ 266,
672
+ 226
673
+ ],
674
+ "page_idx": 10
675
+ },
676
+ {
677
+ "type": "text",
678
+ "text": "[1] Alex Krizhevsky, Ilya Sutskever, and Geoffrey E Hinton. ImageNet classification with deep convolutional neural networks. In Advances in Neural Information Processing Systems, pages 1097–1105, 2012. \n[2] Jinjiang Wang, Yulin Ma, Laibin Zhang, Robert X Gao, and Dazhong Wu. Deep learning for smart manufacturing: Methods and applications. Journal of Manufacturing Systems, 48:144–156, 2018. \n[3] Javier Villalba-Diez, Daniel Schmidt, Roman Gevers, Joaquín Ordieres-Meré, Martin Buchwitz, and Wanja Wellbrock. Deep learning for industrial computer vision quality control in the printing industry 4.0. Sensors, 19(18):3987, 2019. \n[4] Christof Angermueller, Tanel Pärnamaa, Leopold Parts, and Oliver Stegle. Deep learning for computational biology. Molecular Systems Biology, 12(7):878, 2016. \n[5] Adam H Marblestone, Greg Wayne, and Konrad P Kording. Toward an integration of deep learning and neuroscience. Frontiers in Computational Neuroscience, 10:94, 2016. \n[6] Garrett B Goh, Nathan O Hodas, and Abhinav Vishnu. Deep learning for computational chemistry. Journal of Computational Chemistry, 38(16):1291–1307, 2017. \n[7] Travers Ching, Daniel S Himmelstein, Brett K Beaulieu-Jones, Alexandr A Kalinin, Brian T Do, Gregory P Way, Enrico Ferrero, Paul-Michael Agapow, Michael Zietz, Michael M Hoffman, et al. Opportunities and obstacles for deep learning in biology and medicine. Journal of The Royal Society Interface, 15(141): 20170387, 2018. \n[8] Dan Guest, Kyle Cranmer, and Daniel Whiteson. Deep learning and its application to LHC physics. Annual Review of Nuclear and Particle Science, 68:161–181, 2018. \n[9] Andrew W Senior, Richard Evans, John Jumper, James Kirkpatrick, Laurent Sifre, Tim Green, Chongli Qin, Augustin Žídek, Alexander WR Nelson, Alex Bridgland, et al. Improved protein structure prediction using potentials from deep learning. Nature, 577(7792):706–710, 2020. \n[10] Olga Russakovsky, Jia Deng, Hao Su, Jonathan Krause, Sanjeev Satheesh, Sean Ma, Zhiheng Huang, Andrej Karpathy, Aditya Khosla, Michael Bernstein, Alexander C Berg, and Li Fei-Fei. ImageNet Large Scale Visual Recognition Challenge. International Journal of Computer Vision, 115(3):211–252, 2015. \n[11] Jason Jo and Yoshua Bengio. Measuring the tendency of cnns to learn surface statistical regularities. arXiv preprint arXiv:1711.11561, 2017. \n[12] Sara Beery, Grant Van Horn, and Pietro Perona. Recognition in terra incognita. In Proceedings of the European Conference on Computer Vision, pages 456–473, 2018. \n[13] Timothy Niven and Hung-Yu Kao. Probing neural network comprehension of natural language arguments. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 4658–4664, 2019. \n[14] Robert Geirhos, Jörn-Henrik Jacobsen, Claudio Michaelis, Richard Zemel, Wieland Brendel, Matthias Bethge, and Felix A Wichmann. Shortcut learning in deep neural networks. Nature Machine Intelligence, 2:665–673, 2020. \n[15] Dan Hendrycks and Thomas Dietterich. Benchmarking neural network robustness to common corruptions and perturbations. In International Conference on Learning Representations, 2019. \n[16] Haohan Wang, Songwei Ge, Eric P Xing, and Zachary C Lipton. Learning robust global representations by penalizing local predictive power. arXiv preprint arXiv:1905.13549, 2019. \n[17] Robert Geirhos, Patricia Rubisch, Claudio Michaelis, Matthias Bethge, Felix A. Wichmann, and Wieland Brendel. ImageNet-trained CNNs are biased towards texture; increasing shape bias improves accuracy and robustness. In International Conference on Learning Representations, 2019. \n[18] Michael A Alcorn, Qi Li, Zhitao Gong, Chengfei Wang, Long Mai, Wei-Shinn Ku, and Anh Nguyen. Strike (with) a pose: Neural networks are easily fooled by strange poses of familiar objects. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, 2019. \n[19] Brenden M Lake, Ruslan Salakhutdinov, and Joshua B Tenenbaum. Human-level concept learning through probabilistic program induction. Science, 350(6266):1332–1338, 2015. \n[20] Andrei Barbu, David Mayo, Julian Alverio, William Luo, Christopher Wang, Dan Gutfreund, Josh Tenenbaum, and Boris Katz. ObjectNet: a large-scale bias-controlled dataset for pushing the limits of object recognition models. In Advances in Neural Information Processing Systems, pages 9448–9458, 2019. \n[21] Claudio Michaelis, Benjamin Mitzkus, Robert Geirhos, Evgenia Rusak, Oliver Bringmann, Alexander S Ecker, Matthias Bethge, and Wieland Brendel. Benchmarking robustness in object detection: Autonomous driving when winter is coming. arXiv:1907.07484, 2019. \n[22] Rohan Taori, Achal Dave, Vaishaal Shankar, Nicholas Carlini, Benjamin Recht, and Ludwig Schmidt. Measuring robustness to natural distribution shifts in image classification. In Advances in Neural Information Processing Systems, 2020. \n[23] Josip Djolonga, Jessica Yung, Michael Tschannen, Rob Romijnders, Lucas Beyer, Alexander Kolesnikov, Joan Puigcerver, Matthias Minderer, Alexander D’Amour, Dan Moldovan, et al. On robustness and transferability of convolutional neural networks. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 16458–16468, 2021. \n[24] Isaac Dunn, Hadrien Pouget, Daniel Kroening, and Tom Melham. Exposing previously undetectable faults in deep neural networks. arXiv preprint arXiv:2106.00576, 2021. \n[25] Yue He, Zheyan Shen, and Peng Cui. Towards non-iid image classification: A dataset and baselines. Pattern Recognition, 110:107383, 2021. \n[26] Dan Hendrycks, Steven Basart, Norman Mu, Saurav Kadavath, Frank Wang, Evan Dorundo, Rahul Desai, Tyler Zhu, Samyak Parajuli, Mike Guo, et al. The many faces of robustness: A critical analysis of out-of-distribution generalization. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 8340–8349, 2021. \n[27] Dan Hendrycks, Kevin Zhao, Steven Basart, Jacob Steinhardt, and Dawn Song. Natural adversarial examples. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 15262–15271, 2021. \n[28] Spandan Madan, Tomotake Sasaki, Tzu-Mao Li, Xavier Boix, and Hanspeter Pfister. Small in-distribution changes in 3D perspective and lighting fool both CNNs and transformers. arXiv preprint arXiv:2106.16198, 2021. \n[29] Vaishaal Shankar, Achal Dave, Rebecca Roelofs, Deva Ramanan, Benjamin Recht, and Ludwig Schmidt. Do image classifiers generalize across time? In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 9661–9669, 2021. \n[30] David M. Green. Consistency of auditory detection judgments. Psychological Review, 71(5):392–407, 1964. \n[31] Kristof Meding, Dominik Janzing, Bernhard Schölkopf, and Felix A. Wichmann. Perceiving the arrow of time in autoregressive motion. Advances in Neural Information Processing Systems (NeurIPS), 32: 2303–2314, 2019. \n[32] Robert Geirhos, Kristof Meding, and Felix A Wichmann. Beyond accuracy: quantifying trial-by-trial behaviour of CNNs and humans by measuring error consistency. Advances in Neural Information Processing Systems, 33, 2020. \n[33] Robert Geirhos, Carlos RM Temme, Jonas Rauber, Heiko H Schütt, Matthias Bethge, and Felix A Wichmann. Generalisation in humans and deep neural networks. In Advances in Neural Information Processing Systems, 2018. \n[34] George A Miller. WordNet: a lexical database for English. Communications of the ACM, 38(11):39–41, 1995. \n[35] Philip L Smith and Daniel R Little. Small is beautiful: In defense of the small-N design. Psychonomic Bulletin & Review, 25(6):2083–2101, 2018. \n[36] Siavash Haghiri, Patricia Rubisch, Robert Geirhos, Felix Wichmann, and Ulrike von Luxburg. Comparisonbased framework for psychophysics: lab versus crowdsourcing. arXiv preprint arXiv:1905.07234, 2019. \n[37] Sébastien Marcel and Yann Rodriguez. Torchvision the machine-vision package of torch. In Proceedings of the 18th ACM International Conference on Multimedia, pages 1485–1488, 2010. \n[38] Zhirong Wu, Yuanjun Xiong, Stella X Yu, and Dahua Lin. Unsupervised feature learning via nonparametric instance discrimination. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 3733–3742, 2018. \n[39] Kaiming He, Haoqi Fan, Yuxin Wu, Saining Xie, and Ross Girshick. Momentum contrast for unsupervised visual representation learning. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 9729–9738, 2020. \n[40] Xinlei Chen, Haoqi Fan, Ross Girshick, and Kaiming He. Improved baselines with momentum contrastive learning. arXiv preprint arXiv:2003.04297, 2020. \n[41] Ishan Misra and Laurens van der Maaten. Self-supervised learning of pretext-invariant representations. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 6707–6717, 2020. \n[42] Yonglong Tian, Chen Sun, Ben Poole, Dilip Krishnan, Cordelia Schmid, and Phillip Isola. What makes for good views for contrastive learning. arXiv preprint arXiv:2005.10243, 2020. \n[43] Ting Chen, Simon Kornblith, Mohammad Norouzi, and Geoffrey Hinton. A simple framework for contrastive learning of visual representations. arXiv preprint arXiv:2002.05709, 2020. \n[44] Robert Geirhos, Kantharaju Narayanappa, Benjamin Mitzkus, Matthias Bethge, Felix A Wichmann, and Wieland Brendel. On the surprising similarities between supervised and self-supervised models. arXiv preprint arXiv:2010.08377, 2020. \n[45] Alexander Kolesnikov, Lucas Beyer, Xiaohua Zhai, Joan Puigcerver, Jessica Yung, Sylvain Gelly, and Neil Houlsby. Big transfer (BiT): General visual representation learning. arXiv preprint arXiv:1912.11370, 6 (2):8, 2019. \n[46] Hadi Salman, Andrew Ilyas, Logan Engstrom, Ashish Kapoor, and Aleksander Madry. Do adversarially robust ImageNet models transfer better? arXiv preprint arXiv:2007.08489, 2020. \n[47] Alexey Dosovitskiy, Lucas Beyer, Alexander Kolesnikov, Dirk Weissenborn, Xiaohua Zhai, Thomas Unterthiner, Mostafa Dehghani, Matthias Minderer, Georg Heigold, Sylvain Gelly, et al. An image is worth 16x16 words: Transformers for image recognition at scale. arXiv preprint arXiv:2010.11929, 2020. \n[48] Ross Wightman. PyTorch image models. https://github.com/rwightman/ pytorch-image-models, 2019. \n[49] I Zeki Yalniz, Hervé Jégou, Kan Chen, Manohar Paluri, and Dhruv Mahajan. Billion-scale semi-supervised learning for image classification. arXiv preprint arXiv:1905.00546, 2019. \n[50] Qizhe Xie, Minh-Thang Luong, Eduard Hovy, and Quoc V Le. Self-training with noisy student improves ImageNet classification. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 10687–10698, 2020. \n[51] Alec Radford, Jong Wook Kim, Chris Hallacy, Aditya Ramesh, Gabriel Goh, Sandhini Agarwal, Girish Sastry, Amanda Askell, Pamela Mishkin, Jack Clark, et al. Learning transferable visual models from natural language supervision. arXiv preprint arXiv:2103.00020, 2021. \n[52] Jacob Cohen. A coefficient of agreement for nominal scales. Educational and Psychological Measurement, 20(1):37–46, 1960. \n[53] Samuel Dodge and Lina Karam. A study and comparison of human and deep learning recognition performance under visual distortions. In 26th International Conference on Computer Communication and Networks, pages 1–7. IEEE, 2017. \n[54] Felix A Wichmann, David HJ Janssen, Robert Geirhos, Guillermo Aguilar, Heiko H Schütt, Marianne Maertens, and Matthias Bethge. Methods and measurements to compare men against machines. Electronic Imaging, Human Vision and Electronic Imaging, 2017(14):36–45, 2017. \n[55] Thomas Serre. Deep learning: the good, the bad, and the ugly. Annual Review of Vision Science, 5:399–426, 2019. \n[56] Yann LeCun. Predictive learning, 2016. URL https://www.youtube.com/watch?v=Ount2Y4qxQo. \n[57] William Lotter, Gabriel Kreiman, and David Cox. A neural network trained for prediction mimics diverse features of biological neurons and perception. Nature Machine Intelligence, 2(4):210–219, 2020. \n[58] A Emin Orhan, Vaibhav V Gupta, and Brenden M Lake. Self-supervised learning through the eyes of a child. arXiv preprint arXiv:2007.16189, 2020. \n[59] Talia Konkle and George A Alvarez. Instance-level contrastive learning yields human brain-like representation without category-supervision. bioRxiv, 2020. \n[60] Chengxu Zhuang, Siming Yan, Aran Nayebi, Martin Schrimpf, Michael Frank, James DiCarlo, and Daniel Yamins. Unsupervised neural network models of the ventral visual stream. bioRxiv, 2020. \n[61] Katherine R Storrs, Barton L Anderson, and Roland W Fleming. Unsupervised learning predicts human perception and misperception of gloss. Nature Human Behaviour, pages 1–16, 2021. \n[62] Katherine Hermann, Ting Chen, and Simon Kornblith. The origins and prevalence of texture bias in convolutional neural networks. Advances in Neural Information Processing Systems, 33, 2020. \n[63] Ian J Goodfellow, Jonathon Shlens, and Christian Szegedy. Explaining and harnessing adversarial examples. arXiv preprint arXiv:1412.6572, 2014. \n[64] Ruitong Huang, Bing Xu, Dale Schuurmans, and Csaba Szepesvári. Learning with a strong adversary. arXiv preprint arXiv:1511.03034, 2015. \n[65] Simran Kaur, Jeremy Cohen, and Zachary C Lipton. Are perceptually-aligned gradients a general property of robust classifiers? arXiv preprint arXiv:1910.08640, 2019. \n[66] Shibani Santurkar, Dimitris Tsipras, Brandon Tran, Andrew Ilyas, Logan Engstrom, and Aleksander Madry. Image synthesis with a single (robust) classifier. arXiv:1906.09453, 2019. \n[67] Logan Engstrom, Andrew Ilyas, Shibani Santurkar, Dimitris Tsipras, Brandon Tran, and Aleksander Madry. Adversarial robustness as a prior for learned representations. arXiv preprint arXiv:1906.00945, 2019. \n[68] Florian Tramèr, Jens Behrmann, Nicholas Carlini, Nicolas Papernot, and Jörn-Henrik Jacobsen. Fundamental tradeoffs between invariance and sensitivity to adversarial perturbations. In International Conference on Machine Learning, pages 9561–9571. PMLR, 2020. \n[69] Tianyuan Zhang and Zhanxing Zhu. Interpreting adversarially trained convolutional neural networks. In International Conference on Machine Learning, pages 7502–7511. PMLR, 2019. \n[70] Peijie Chen, Chirag Agarwal, and Anh Nguyen. The shape and simplicity biases of adversarially robust ImageNet-trained CNNs. arXiv preprint arXiv:2006.09373, 2020. \n[71] Kai Han, Yunhe Wang, Hanting Chen, Xinghao Chen, Jianyuan Guo, Zhenhua Liu, Yehui Tang, An Xiao, Chunjing Xu, Yixing Xu, et al. A survey on visual transformer. arXiv preprint arXiv:2012.12556, 2020. \n[72] Muzammal Naseer, Kanchana Ranasinghe, Salman Khan, Munawar Hayat, Fahad Shahbaz Khan, and Ming-Hsuan Yang. Intriguing properties of vision transformers. arXiv preprint arXiv:2105.10497, 2021. \n[73] Shikhar Tuli, Ishita Dasgupta, Erin Grant, and Thomas L Griffiths. Are convolutional neural networks or transformers more like human vision? arXiv preprint arXiv:2105.07197, 2021. \n[74] Curtis G Northcutt, Anish Athalye, and Jonas Mueller. Pervasive label errors in test sets destabilize machine learning benchmarks. arXiv preprint arXiv:2103.14749, 2021. \n[75] Rishi Rajalingham, Elias B Issa, Pouya Bashivan, Kohitij Kar, Kailyn Schmidt, and James J DiCarlo. Large-scale, high-resolution comparison of the core visual object recognition behavior of humans, monkeys, and state-of-the-art deep artificial neural networks. Journal of Neuroscience, 38(33):7255–7269, 2018. \n[76] Horia Mania, John Miller, Ludwig Schmidt, Moritz Hardt, and Benjamin Recht. Model similarity mitigates test set overuse. Advances in Neural Information Processing Systems, 2019. \n[77] Christian Szegedy, Wojciech Zaremba, Ilya Sutskever, Joan Bruna, Dumitru Erhan, Ian Goodfellow, and Rob Fergus. Intriguing properties of neural networks. arXiv:1312.6199, 2013. \n[78] Florian Tramèr, Nicolas Papernot, Ian Goodfellow, Dan Boneh, and Patrick McDaniel. The space of transferable adversarial examples. arXiv preprint arXiv:1704.03453, 2017. \n[79] Wieland Brendel and Matthias Bethge. Approximating CNNs with bag-of-local-features models works surprisingly well on ImageNet. In International Conference on Learning Representations, 2019. \n[80] Kristof Meding, Luca M Schulze Buschoff, Robert Geirhos, and Felix A Wichmann. Trivial or impossible–dichotomous data difficulty masks model differences (on ImageNet and beyond). arXiv preprint arXiv:2110.05922, 2021. \n[81] Matthias Hein and Maksym Andriushchenko. Formal guarantees on the robustness of a classifier against adversarial manipulation. arXiv preprint arXiv:1705.08475, 2017. \n[82] Arash Vahdat. Toward robustness against label noise in training deep discriminative neural networks. arXiv preprint arXiv:1706.00038, 2017. \n[83] James J DiCarlo, Davide Zoccolan, and Nicole C Rust. How does the brain solve visual object recognition? Neuron, 73(3):415–434, 2012. \n[84] Daniel LK Yamins, Ha Hong, Charles F Cadieu, Ethan A Solomon, Darren Seibert, and James J DiCarlo. Performance-optimized hierarchical models predict neural responses in higher visual cortex. Proceedings of the National Academy of Sciences, 111(23):8619–8624, 2014. \n[85] Jonas Kubilius, Martin Schrimpf, Kohitij Kar, Rishi Rajalingham, Ha Hong, Najib Majaj, Elias Issa, Pouya Bashivan, Jonathan Prescott-Roy, Kailyn Schmidt, et al. Brain-like object recognition with high-performing shallow recurrent ANNs. Advances in Neural Information Processing Systems, 32:12805–12816, 2019. \n[86] Been Kim, Emily Reif, Martin Wattenberg, Samy Bengio, and Michael C Mozer. Neural networks trained on natural scenes exhibit Gestalt closure. Computational Brain & Behavior, pages 1–13, 2021. \n[87] Martin N Hebart, Charles Y Zheng, Francisco Pereira, and Chris I Baker. Revealing the multidimensional mental representations of natural objects underlying human similarity judgements. Nature Human Behaviour, 4(11):1173–1185, 2020. \n[88] Nikolaus Kriegeskorte. Deep neural networks: a new framework for modeling biological vision and brain information processing. Annual Review of Vision Science, 1:417–446, 2015. \n[89] 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. \n[90] Amirhossein Tavanaei, Masoud Ghodrati, Saeed Reza Kheradpisheh, Timothée Masquelier, and Anthony Maida. Deep learning in spiking neural networks. Neural Networks, 111:47–63, 2019. \n[91] Fabian H Sinz, Xaq Pitkow, Jacob Reimer, Matthias Bethge, and Andreas S Tolias. Engineering a less artificial intelligence. Neuron, 103(6):967–979, 2019. \n[92] Joel Dapello, Tiago Marques, Martin Schrimpf, Franziska Geiger, David D Cox, and James J DiCarlo. Simulating a primary visual cortex at the front of CNNs improves robustness to image perturbations. bioRxiv, 2020. \n[93] Benjamin D Evans, Gaurav Malhotra, and Jeffrey S Bowers. Biological convolutions improve dnn robustness to noise and generalisation. bioRxiv, 2021. \n[94] Adam Paszke, Sam Gross, Francisco Massa, Adam Lerer, James Bradbury, Gregory Chanan, Trevor Killeen, Zeming Lin, Natalia Gimelshein, Luca Antiga, et al. PyTorch: An imperative style, high-performance deep learning library. In Advances in Neural Information Processing Systems, pages 8026–8037, 2019. \n[95] Aaron van den Oord, Yazhe Li, and Oriol Vinyals. Representation learning with contrastive predictive coding. arXiv:1807.03748, 2018. \n[96] Jia Deng, Wei Dong, Richard Socher, Li-Jia Li, Kai Li, and Li Fei-Fei. ImageNet: a large-scale hierarchical image database. In IEEE Conference on Computer Vision and Pattern Recognition, pages 248–255, 2009. \n[97] Evgenia Rusak, Steffen Schneider, Peter Gehler, Oliver Bringmann, Wieland Brendel, and Matthias Bethge. Adapting ImageNet-scale models to complex distribution shifts with self-learning. arXiv preprint arXiv:2104.12928, 2021. \n[98] Eleanor Rosch. Principles of categorization. In E. Margolis and S. Laurence, editors, Concepts: core readings, pages 189–206. 1999. ",
679
+ "bbox": [
680
+ 173,
681
+ 222,
682
+ 826,
683
+ 915
684
+ ],
685
+ "page_idx": 10
686
+ },
687
+ {
688
+ "type": "text",
689
+ "text": "",
690
+ "bbox": [
691
+ 169,
692
+ 69,
693
+ 828,
694
+ 920
695
+ ],
696
+ "page_idx": 11
697
+ },
698
+ {
699
+ "type": "text",
700
+ "text": "",
701
+ "bbox": [
702
+ 171,
703
+ 37,
704
+ 828,
705
+ 919
706
+ ],
707
+ "page_idx": 12
708
+ },
709
+ {
710
+ "type": "text",
711
+ "text": "",
712
+ "bbox": [
713
+ 169,
714
+ 68,
715
+ 828,
716
+ 920
717
+ ],
718
+ "page_idx": 13
719
+ },
720
+ {
721
+ "type": "text",
722
+ "text": "",
723
+ "bbox": [
724
+ 171,
725
+ 54,
726
+ 828,
727
+ 878
728
+ ],
729
+ "page_idx": 14
730
+ }
731
+ ]
parse/train/QkljT4mrfs/QkljT4mrfs_middle.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/QkljT4mrfs/QkljT4mrfs_model.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/RJ7XFI15Q8f/RJ7XFI15Q8f.md ADDED
@@ -0,0 +1,267 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Achieving Forgetting Prevention and Knowledge Transfer in Continual Learning
2
+
3
+ Zixuan $\mathbf { K } \mathbf { e } ^ { 1 }$ , Bing Liu1, Nianzu $\mathbf { M } \mathbf { a } ^ { 1 }$ , $\mathbf { H } \mathbf { u } \mathbf { X } \mathbf { u } ^ { 2 }$ and Lei $\mathbf { S h u ^ { 3 * } }$
4
+
5
+ 1Department of Computer Science, University of Illinois at Chicago 2Facebook AI Research 3Amazon AWS AI 1{zke4,liub,nma4}@uic.edu 2huxu@fb.com 3shulindt@gmail.com
6
+
7
+ # Abstract
8
+
9
+ Continual learning (CL) learns a sequence of tasks incrementally with the goal of achieving two main objectives: overcoming catastrophic forgetting (CF) and encouraging knowledge transfer (KT) across tasks. However, most existing techniques focus only on overcoming CF and have no mechanism to encourage KT, and thus do not do well in KT. Although several papers have tried to deal with both CF and KT, our experiments show that they suffer from serious CF when the tasks do not have much shared knowledge. Another observation is that most current CL methods do not use pre-trained models, but it has been shown that such models can significantly improve the end task performance. For example, in natural language processing, fine-tuning a BERT-like pre-trained language model is one of the most effective approaches. However, for CL, this approach suffers from serious CF. An interesting question is how to make the best use of pre-trained models for CL. This paper proposes a novel model called CTR to solve these problems. Our experimental results demonstrate the effectiveness of CTR.2
10
+
11
+ # 1 Introduction
12
+
13
+ This paper studies continual learning (CL) of a sequence of natural language processing (NLP) tasks in the task continual learning (Task-CL) setting. It aims to (i) prevent catastrophic forgetting (CF), and (ii) transfer knowledge across tasks. (ii) is particularly important because many tasks in NLP share similar knowledge that can be leveraged to achieve better accuracy. CF means that in learning a new task, the existing network parameters learned for the previous tasks may be modified, which degrades the performance of previous tasks [40]. In the Task-CL setting, the task id is provided for each test case in testing so that the specific model for the task in the network can be applied to classify the test case. Another popular CL setting is class continual learning, which does not provide the task id during testing but it is for solving a different type of problems.
14
+
15
+ Most existing CL papers focus on dealing with CF [21, 5]. There are also some papers that perform knowledge transfer. To achieve both objectives is highly challenging. To overcome CF in the Task-CL setting, we don’t want the training of the new task to update the model parameters learned for previous tasks to achieve model separation. But to transfer knowledge across tasks, we want the new task to leverage the knowledge learned from previous tasks for learning a better model (forward transfer) and also want the new task to enhance the performance of similar previous tasks (backward transfer).
16
+
17
+ This means it is necessary to update previous model parameters. This is a dilemma. Although several papers have tried to deal with both [22, 37], they were only tested using sentiment analysis tasks with strong shared knowledge. When tested with tasks that don’t have much shared knowledge, they suffer from severe CF (see Sec. 5.4). Those existing papers that focus on dealing with CF do not do well with knowledge transfer as they have no explicit mechanism to facilitate the transfer.
18
+
19
+ Another observation about the current CL research is that most techniques do not use pre-trained models. But such pre-trained models or feature extractors can significantly improve the CL performance [18, 24]. An important question is how to make the best use of pre-trained models in CL. This paper studies the problem as well using NLP tasks, but we believe that the developed ideas are also applicable to computer vision tasks because most pre-trained models are based on the transformer architecture [60]. We will see that the naive or the conventional way of directly adding the CL module on top of a pre-trained model is not the best choice (see Sec. 5.4).
20
+
21
+ In NLP, fine-tuning a BERT [8] like pre-trained language model has been regarded as one of the most effective techniques in applications [65, 57]. However, fine-tuning works poorly for continual learning. This is because the fine-tuned BERT for a task captures highly task-specific information [41], which is difficult to be used by other tasks. When fine-tuning for a new task, it has to update the already fine-tuned parameters for previous tasks, which causes serious CF (see Sec. 5.4).
22
+
23
+ This paper proposes a novel neural architecture to achieve both CF prevention and knowledge transfer, which also deals with the CF problem with BERT fine-tuning. The proposed system is called CTR (Capsules and Transfer Routing for continual learning). CTR inserts a continual learning plug-in (CL-plugin) module in two locations in BERT. With the pair of CL-plugin modules added to BERT, we no longer need to fine-tune BERT for each task, which causes CF in BERT, and yet we can achieve the power of BERT fine-tuning. CTR has some similarity to Adapter-BERT [16], which adds adapters in BERT for parameter efficient transfer learning such that different end tasks can have their separate adapters (which are very small in size) to adapt BERT for individual end tasks and to transfer the knowledge from BERT to the end tasks. Then, there is no need to employ a separate BERT and fine-tuning it for each task, which is extremely parameter inefficient if many tasks need to be learned. An adapter is a simple 2-layer fully-connected network for adapting BERT to a specific end task. A CL-plugin is very different from an adapter. We do not use a pair of CL-plugin modules to adapt BERT for each task. Instead, CTR learns all tasks using only one pair of CL-plugin modules inserted into BERT. A CL-plugin is a full CL network that can leverage a pre-trained model and deal with both CF and knowledge transfer. Specifically, it uses a capsule [15] to represent each task and a proposed transfer routing algorithm to identify and transfer knowledge across tasks to achieve improved accuracy. It further learns and uses task masks to protect task-specific knowledge to avoid forgetting. Empirical evaluations show that CTR outperforms strong baselines. Ablation experiments have also been conducted to study where to insert the CL-plugin module in BERT in order to achieve the best performance (see Sec. 5.4).
24
+
25
+ # 2 Related Work
26
+
27
+ Catastrophic Forgetting: Existing work in CL mainly focused on overcoming CF using the following approaches. (1) Regularization-based approaches, such as those in [27, 30, 51, 69], add a regularization in the loss to consolidate weights for previous tasks when learning a new task. (2) Replay-based approaches, such as those in [45, 36, 4, 63], retain some training data of old tasks and use them in learning a new task. The methods in [54, 20, 47, 14] learn data generators and generate old task data for learning a new task. (3) Parameter isolation-based approaches, such as those in [52, 21, 39, 10], allocate model parameters dedicated to different tasks and mask them out when learning a new task. (4) Gradient projection-based approaches [68] ensure the gradient updates occur only in the orthogonal direction to the input of old tasks and thus will not affect old tasks. Some recent papers used pre-trained models [18, 23, 24] and learn one class per task [18]. Tackling CF only deals with model deterioration. These methods perform worse than learning each task separately. An empirical study of the cause of CF and the impact of task similarity on CF was done in [44].
28
+
29
+ Some NLP applications have also dealt with CF. For example, CL models have been proposed for sentiment analysis [23, 24, 37, 43], dialogue slot filling [53], language modeling [58, 7], language learning [31], sentence embedding [33], machine translation [25], cross-lingual modeling [35], and question answering [12]. A dialogue CL dataset is also reported in [38].
30
+
31
+ Knowledge Transfer: Ideally, learning from a sequence of tasks should also allow multiple tasks to support each other via knowledge transfer. CAT [21] (a Task-CL system) works on a mixed sequence of similar and dissimilar tasks and can transfer knowledge among similar tasks detected automatically. Progressive Network [48] does forward transfer but it is for class continual learning (Class-CL).
32
+
33
+ Knowledge transfer in this paper is closely related to lifelong learning (LL), which aims to improve the new/last task learning without handling CF [56, 49, 5]. In the NLP area, NELL [3] performs LL information extraction, and several other papers worked on lifelong document sentiment classification (DSC) and aspect sentiment classification (ASC). [6] and [61] proposed two Naive Bayesian methods to help improve the new task learning. [64] proposed a LL approach based on voting. [55] used LL for aspect extraction. [43] and [62] used neural networks for DSC and ASC, respectively. Several papers also studied lifelong topic modeling [5, 13]. However, all these works do not deal with CF.
34
+
35
+ SRK [37] and KAN [22] try to deal with both CF and knowledge transfer in continual sentiment classification. However, they have two critical weaknesses: (i) Their RNN architectures cannot use plug-in or adapter modules to tune BERT, which significantly limits their power. (ii) Since they were mainly designed for knowledge transfer, they suffer from serious CF (see Sec. 5.4). B-CL [24] uses the adapter idea [16] to adapt BERT for sentiment analysis tasks, which are similar to each other. However, since its mechanism of dynamic routing for knowledge transfer is very week, its knowledge transfer ability is markedly poorer than CTR (see Sec. 5.4). CLASSIC [23] is another recent work on continual learning for knowledge transfer, but its CL setting is domain continual learning. Its knowledge transfer method is based on contrastive learning.
36
+
37
+ AdapterFusion [42] used adapters proposed in [16]. It proposes a two-stage method to learn a set of tasks. In the first stage, it learns one adapter for each task independently using the task’s training data. In the second stage, it uses the training data again to learn a good composition of the learned adapters in the first stage to produce the final model for all tasks. AdapterFusion basically tries to improve multi-task learning. It is not for continual learning and thus has no CF. As explained in Sec. 1, the CL-plugin concept in CTR is different from that of adapters for adapting BERT for each task. CL-plugins are continual learning systems that make use of a pre-trained model.
38
+
39
+ # 3 CTR Architecture
40
+
41
+ This section describes the general architecture of CTR. The details about its key component CLplugin is presented in the next section. Due to its good performance, BERT [8] and its transformer [60] architecture are used as the base in our model CTR. Since BERT fine-tuning is prone to CF (Sec. 1), we propose the CL plug-in idea, which is inspired by Adapter-BERT [16]. CL-plugin is a full continual learning module designed to interact with a pre-trained model, in our case, BERT.
42
+
43
+ Inserting CL-plugins in BERT. A commonly used method of leveraging a pre-trained model is to add the end task module on top of the pre-trained model. However, as explained in Sec. 1, fine-tuning the pre-trained model can cause serious CF for CL. The CL system PCL [18], which uses this approach, has the pre-trained model frozen to avoid forgetting. But as we will see in Sec. 5.4, this is not the best choice. CTR inserts the proposed CL-plugin in two locations in BERT, i.e., in each transformer layer of BERT. We will also see in Sec. 5.4 that inserting only one CL-plugin in one location is sub-optimal. Figure 1 gives the CTR architecture and we can see the two CL-plugins are added into BERT. In learning, only the two CL-plugins and the classification heads are trained. The components of the original pre-trained BERT are fixed.
44
+
45
+ Continual learning plug-in (CL-plugin). CL-plugin employs a capsule network (CapsNet) [15, 50] like architecture. In the classic neural network, a neuron outputs a scalar, real-valued activation as a feature detector. CapsNets replaces that with a vector-output capsule to preserve additional information. A simple CapsNet consists of two capsule layers. The first layer stores low-level feature maps, and the second layer generates the classification probability with each capsule corresponding to one class. CapsNet uses a dynamic routing algorithm to make each lower-level capsule to send its output to a similar (or “agreed”, computed by dot product) higher-level capsule. This property can already be used to group similar tasks and their shareable features to produce a CL system (see the ablation study in Sec. 5.4). One of the key ideas of CL-plugin (see Figure 2(A)) is a transfer capsule layer with a new transfer routing algorithm to explicitly identify transferable features/knowledge from previous tasks to transfer to the new task. Additionally, transfer routing avoids the need for hyper-parameter tuning on the number of iterations of dynamic routing [50] to update the agreements.
46
+
47
+ ![](images/7fcebe2141532fd920633052504d05428c323dfe7e3d6216b689bcb7570d3ef1.jpg)
48
+ Figure 1: Architecture of BERT (left) and the proposed system CTR (right), which inserts two CL-plugins in BERT. Each CL-plugin module (far right) has two sub-modules and a skip connection: knowledge sharing sub-module (KSM) and task-specific sub-module (TSM).
49
+
50
+ ![](images/2bac79b64fa04786b82b8f655269d1ffe4edb9cf7ec62f3efaa8b92c276969e8.jpg)
51
+ Figure 2: (A) CL-plugin Architecture. (B) Illustration of task masking. Cells/neurons in brown, green and red are respectively used by tasks 0, 1 and 2. Neurons with two colors are used by two tasks
52
+
53
+ # 4 Continual Learning Plug-in (CL-plugin)
54
+
55
+ The architecture of our continual learning plug-in (CL-plugin) is shown in Figure 2(A). CL-plugin takes two inputs: (1) hidden states $h ^ { ( t ) }$ from the feed-forward layer inside a transformer layer and (2) task $\textrm Ḋ \textrm Ḋ \textrm Ḋ \textrm Ḋ t Ḍ Ḍ Ḍ$ , which is required by task continual learning (Task-CL). The outputs are hidden states with features suitable for the $t$ -th task for classification. Inside CL-plugin, there are two modules: (1) knowledge sharing module (KSM) for identifying and transferring the shareable knowledge from similar previous tasks to the new task $t$ , and (2) task specific module (TSM) for learning task specific neurons and their masks (which can protect the neurons from being updated by future tasks to deal with CF). Since TSM is differentiable, the whole system CTR can be trained end-to-end.
56
+
57
+ # 4.1 Knowledge Sharing Module (KSM)
58
+
59
+ KSM achieves knowledge transfer among similar tasks via a task capsule layer (TK-Layer), a transfer capsule layer (TR-Layer), and a transfer routing mechanism.
60
+
61
+ # 4.1.1 Task Capsule Layer (TK-Layer)
62
+
63
+ Each capsule in the TK-Layer represents a task, and it prepares the low-level features derived from each task (Figure 2(A)). As such, a capsule is added to the TK-Layer for each new task. This incremental growth is efficient and easy because these capsules are discrete and do not share parameters. Also, each capsule is simply a 2-layer fully connected network with a small number of parameters. Let $h ^ { ( t ) } \in \mathbb { R } ^ { d _ { t } \times d _ { e } }$ be the input of CL-plugin, where $d _ { t }$ is the number of tokens, $d _ { e }$ the number of dimensions, and $t$ is the current task. In the TK-Layer, we have one capsule for each task. Assume we have learned $t$ tasks so far. The capsule for the $i$ -th $( i \leq t )$ ) task is
64
+
65
+ $$
66
+ p _ { i } ^ { ( t ) } = f _ { i } ( h ^ { ( t ) } ) ,
67
+ $$
68
+
69
+ where $f _ { i } ( \cdot ) = \mathbf { M } \mathbf { L } \mathbf { P } _ { i } ( \cdot )$ denotes a 2-layer fully-connected network.
70
+
71
+ # 4.1.2 Transfer Routing and Transfer Capsule Layer
72
+
73
+ Each capsule in the transfer capsule layer (TR-Layer) represents the transferable representation extracted from TK-Layer. As shown in Figure 2(A), transfer routing between the lower-level capsules in TK-Layer and high-level capsules in TR-Layer has three components: pre-route vector generator $( P V G )$ , similarity estimator $( S E )$ and task router $( T R )$ . Given the task capsules in the TK-Layer, we first transform the feature through a trainable weight matrix. We call the output of this transformation the pre-route vector. Each SE estimates the similarity between a previous task and the current task using the pre-route vector, resulting in a similarity score for each higher-level capsule. Additionally, each SE is augmented by a TR module, a differentiable task router acting as a gate. This router estimates a binary signal that decides whether to connect or disconnect the current route between the two consecutive capsule layers (i.e. TK-Layer and TR-Layer in CL-plugin). The binary signal estimated by TR can be seen as a differentiable binary attention. Conceptually, each SE and TR pair together learns the connectivity between capsules in a stochastic and differentiable manner, which can be seen as a task similarity-based connectivity search mechanism. This transfer routing identifies the shared features/knowledge from multiple task capsules and helps knowledge transfer across similar tasks. Next, we discuss the pre-route vector generator, similarity estimator and task router.
74
+
75
+ Pre-route Vector Generator (PVG). We first turns each transfer capsule $p _ { i } ^ { ( t ) }$ into a pre-route vector,
76
+
77
+ $$
78
+ u _ { j | i } ^ { ( t ) } = W _ { i j } p _ { i } ^ { ( t ) } ,
79
+ $$
80
+
81
+ where $W _ { i j } \in \mathbb { R } ^ { d _ { s } \times d _ { k } }$ is the weight matrix, $d _ { s }$ and $d _ { k }$ are the dimensions of task capsule $i$ (also representing a task) and transfer capsule $j$ , and $t$ is the current task. The number of transfer capsules $n _ { j }$ is a hyperparameter detailed in Sec. 5.
82
+
83
+ Similarity Estimator (SE). Since tasks $i$ and $t$ are different, it is crucial to determine what in task $i$ ’s representation is transferable. Inspired by [67], we use a convolution layer and activation units to compare task $i$ with task $t$ to determine the transferable proportion from the previous task $i$ . In SE, we compute the task similarity as follows:
84
+
85
+ $$
86
+ \begin{array} { r } { \boldsymbol q _ { j | t } ^ { ( t ) } = \mathbf { M a x P o o l } ( \mathbf { R e l u } ( \boldsymbol u _ { j | t } ^ { ( t ) } * W _ { q } + b _ { q } ) ) , } \end{array}
87
+ $$
88
+
89
+ $$
90
+ a _ { j | i } ^ { ( t ) } = \mathbf { M a x P o o l } ( \operatorname { R e l u } ( u _ { j | i } ^ { ( t ) } * W _ { a } + f _ { a } ( q _ { j | t } ^ { ( t ) } ) + b _ { a } ) ) ,
91
+ $$
92
+
93
+ where $b _ { a } , b _ { q } \in \mathbb { R }$ are the bias, $W _ { a } , W _ { q } \in \mathbb { R } ^ { d _ { e } \times d _ { w } }$ are convolutions filters and $d _ { w }$ is the windows size. We extract important features from the current task representation u(t)j|t via the convolution network in Eq. (3). The MaxPool helps remove the insignificant features to generate a fixed-size vector with the size equal to the number of filters $n _ { w }$ . Similarly, we extract important features from the previous task i’s representation u(t)j|i . Using the important features for the current and previous tasks, we compute a similarity score between them in Eq. (4) with ReLU activation. Note $f _ { a }$ is a 1-layer fully-connected network to match the dimensions. As a result, $a _ { j | i } ^ { ( t ) }$ indicates how similar the representation of the $i$ -th task is to the current task t. For those tasks with a very low a(t)j|i , t heir representations are less similar to the current task and thus has little transferable knowledge.
94
+
95
+ Task Router (TR). TR controls which previous task representation should flow to the next layer with the goal of letting only the transferable information to flow. Given the similarity $a _ { j | i } ^ { ( t ) }$ , TR estimates a binary decision signal $\delta _ { j \vert t } ^ { ( t ) } \in \{ 0$ :disconnect, 1:connect}. We first apply a convolution layer with 2 output channels and $1 \times 1$ kernel size to generate un-normalized decision value. To estimate the binary decision, we need to generate a decision chosen from the set of two mutually exclusive and exhaustive events (disconnect and connect). In our work, we adopt the Gumbel-Softmax [19] to help make the TR gate differentiable.
96
+
97
+ $$
98
+ \delta _ { j | i } ^ { ( t ) } = \mathrm { G u m b e l \_ s o f t m a x } ( a _ { j | i } ^ { ( t ) } * W _ { \delta } + b _ { \delta } ) .
99
+ $$
100
+
101
+ Given the similarity aj |t , binary decision δ(t )t and the pre-route vector u(t)j|t, we compute the transferable representation ${ v _ { j \mid i } ^ { \mathrm { t r a n } ( t ) } }$ and final output $v _ { j } ^ { ( t ) }$ as follows:
102
+
103
+ $$
104
+ v _ { j | i } ^ { \mathrm { t r a n } ( t ) } = a _ { j | i } ^ { ( t ) } \otimes u _ { j | i } ^ { ( t ) } , ~ v _ { j } ^ { ( t ) } = \sum _ { i = 1 \atop \delta _ { i j } ^ { ( t ) } = 1 } ^ { n + 1 } v _ { j | i } ^ { \mathrm { t r a n } ( t ) } .
105
+ $$
106
+
107
+ This makes sure only task capsules for tasks that are salient or similar to the new task are used, and the others task capsules are ignored (and thus protected) to learn more general shareable knowledge. As many NLP applications have similar tasks, such learning of task-sharing features can be very important. Note that in backpropagation, only the similar tasks with connected gate $( \delta _ { i j } ^ { ( t ) } = 1 )$ are
108
+
109
+ # 4.2 Task Specific Module (TSM)
110
+
111
+ We now discuss how to preserve task-specific knowledge of previous tasks to prevent forgetting (CF). To achieve this, we use task masks (Figure 2(B)). Specifically, we first detect the neurons used by each old task and then block off or mask out all the used neurons when learning a new task.
112
+
113
+ The task-specific module consists of differentiable layers (a 2-layer fully-connected network is used). Each layer’s output is further applied with a task mask to indicate which neurons should be protected for that task to overcome CF and forbids gradient updates for those neurons during backpropagation for a new task. Those tasks with overlapping masks indicate some parameter sharing. Due to KSM, the features flowing into those overlapping neurons enable the related old tasks to also improve in learning the new task. Here we borrow the hard attention idea in [52] and leverage the task ID embedding to train the task mask. Further details can be found in Supplementary.
114
+
115
+ Illustration. The task masking process is illustrated in Figure 2(B), which shows the learning process of three tasks. Before training, those solid cells with a 0 are the neurons that have been used by some previous tasks and should be protected (masked). Those empty cells are free neurons (not used). After training, those solid cells with a 1 are neurons that are important for the current task, which will be used as masks in the future. Those solid cells with a 0 are masked as they are important for previous tasks. Those non-solid cells with a 0 are neurons that are not used so far.
116
+
117
+ Let us walk through the learning process of the three tasks. After training task 0, we obtain its useful neurons indicated by the 1 entries. Before training task 1, those useful neurons for task 0 are first masked (those previous 1’s entries are turned to 0’s). After training task 1, two neurons with 1 are used by the task. When task 2 arrives, all used neurons by tasks 0 and 1 are masked before training, i.e., their entries are set to 0. After training task 2, we see that tasks 2 and 1 have a shared neuron (the cell with two colors, red and green), which is used by both of tasks.
118
+
119
+ # 5 Experiments
120
+
121
+ We evaluate CTR using three applications. We follow the continual learning (CL) evaluation method given in [29]. CTR first learns a sequence of tasks. After a task is trained, the training data of the task is no longer accessible. After all tasks are learned, their task models are tested using their respective test sets. In training each task, we use its validation set to decide when to stop training.
122
+
123
+ # 5.1 Three Applications and Their Datasets
124
+
125
+ The first two applications (and datasets) are used to show the knowledge transferability of CTR because their tasks are similar and have shared knowledge. Catastrophic forgetting (CF) is not a major concern for them. The third application (and dataset) is mainly used to test CTR’s ability to overcome CF as its tasks are very different and have little shared knowledge to transfer.
126
+
127
+ <table><tr><td>Data source</td><td colspan="3">Liu3domain</td><td colspan="5">HL5domain</td><td colspan="10">Ding9domain</td></tr><tr><td>Task/</td><td>paede</td><td>Poener</td><td>Ccoindetr</td><td>NO990T90</td><td>NN14am00</td><td>Ceieea</td><td>Conoees</td><td>AAx2dA</td><td>Capoong0</td><td>Craonen</td><td>radera</td><td>Thah</td><td></td><td>srss</td><td>JITIIT5</td><td>NO994P00</td><td>UOJION</td><td>Jreererer</td><td>doider</td></tr><tr><td>Train</td><td>352</td><td>245</td><td>283</td><td>271</td><td>162</td><td>677</td><td>228</td><td>343</td><td>118</td><td>175</td><td>191</td><td>212</td><td>153</td><td>176</td><td>484</td><td>362</td><td>194</td><td>3452</td><td>2163</td></tr><tr><td>Val.</td><td>44</td><td>31</td><td>35</td><td>34</td><td>20</td><td>85</td><td>29</td><td>43</td><td>15</td><td>22</td><td>24</td><td>26</td><td>19</td><td>22</td><td>61</td><td>45</td><td>24</td><td>150</td><td>150</td></tr><tr><td>Test</td><td>44</td><td>31</td><td>36</td><td>34</td><td>21</td><td>85</td><td>29</td><td>43</td><td>15</td><td>22</td><td>24</td><td>27</td><td>20</td><td>23</td><td>61</td><td>46</td><td>25</td><td>1120</td><td>638</td></tr></table>
128
+
129
+ Table 1: Statistics of datasets for ASC. The datasets statistics for DSC and 20News have been described in the text. More detailed data statistics are given in Supplementary.
130
+
131
+ 1. Document Sentiment Classification (DSC). This application is to classify each full product review into one of the two opinion classes (positive and negative). The training data of each task consists of reviews of a particular type of product. We adopt the text classification formulation in [8], where a [CLS] token is used to predict the opinion polarity.
132
+
133
+ We employ a set of 10 DSC datasets (reviews of 10 products) to produce sequences of tasks. The products are Sports, Toys, Tools, Video, Pet, Musical, Movies, Garden, Offices, and Kindle [22]. Two experiments are conducted: (1) using small data in each task: 100 positive and 100 negative training reviews per task; (2) using the full data in each task: 2500 positive and 2500 negative training reviews per task [22]. (1) is more useful in practice because labeling a large number of examples is very costly. The same validation reviews (250 positive and 250 negative) and the same test reviews (250 positive and 250 negative) are used in both experiments.
134
+
135
+ 2. Aspect Sentiment Classification (ASC). It classifies a review sentence on the aspect-level sentiment (one of positive, negative, and neutral). For example, the sentence “The picture is great but the sound is lousy” about a TV expresses a positive opinion about the aspect “picture” and a negative opinion about the aspect “sound.” We adopt the ASC formulation in [65], where the aspect term and sentence are concatenated via [SEP] in BERT. The opinion is predicted on top of the [CLS] token.
136
+
137
+ We employ a set of 19 ASC datasets (review sentences of 19 products) to produce sequences of tasks. Each dataset represents a task. The datasets are from 4 sources: (1) HL5Domains [17] with reviews of 5 products; (2) Liu3Domains [32] with reviews of 3 products; (3) Ding9Domains [9] with reviews of 9 products; and (4) SemEval14 with reviews of 2 products - SemEval 2014 Task 4 for laptop and restaurant. For (1), (2) and (3), we use about $10 \%$ of the original data as the validate data, another about $10 \%$ of the original data as the testing data. For (4), we use 150 examples from the training set for validation. To be consistent with existing research [59], sentences with conflict opinions about a single aspect are not used. Statistics of the 19 datasets are given in Table 1.
138
+
139
+ 3. Text classification using 20News data. This dataset [28] has 20 classes and each class has about 1000 documents. The data split for train/validation/test is 1600/200/200. We created 10 tasks, 2 classes per task. Since this is topic-based text classification data, the classes are very different and have little shared knowledge. As mentioned above, this application (and dataset) is mainly used to show CTR’s ability to overcome forgetting.
140
+
141
+ # 5.2 Baselines
142
+
143
+ We setup 38 baselines, including both standalone and continual learning methods.
144
+
145
+ Multitask learning (MTL: Results of multitask learning is considered the upper-bound of those of continual learning. Here MTL fine-tunes BERT.
146
+
147
+ Standalone (SDL) Baselines: The SDL setting builds a model for each task independently using a separate network. It clearly has no knowledge transfer or forgetting. We have 4 baselines under SDL, BERT, BERT (Frozen), Adapter-BERT and W2V (word2vec embeddings). For BERT, we use trainable BERT, i.e., fine-tuning. BERT (Frozen) uses frozen BERT with a trainable CNN text classification network [26] on top of it.; Adapter-BERT adapts the BERT as in [16], where only the adapter blocks are trainable; W2V uses embeddings trained on the Amazon review data in [66] using FastText [11]. For ASC, we adopt the ASC classification network in [67], which takes aspect term and review sentence as input. For DSC and 20News, we adopt the classification network in [8].
148
+
149
+ Continual Learning (CL) Baselines. CL setting includes 4 baselines with no forgetting handling (NFH) (corresponding to the 4 standalone baselines), and 25 baselines from 9 state-of-the art task continual learning (Task-CL) methods that deal with forgetting (CF). NFH baselines learn the tasks one by one with no awareness of forgetting/transfer.
150
+
151
+ The 12 state-of-the-art CL systems are: KAN [22] and SRK [37] are Task-CL methods for document sentiment classification. The rest were designed initially for image classification. Therefore, we replace their original MLP or CNN image classification network with CNN for text classification [26]. HAT [52] is one of the best Task-CL methods with almost no forgetting. CAT [21] is similar to HAT but can work with a mixed sequence. UCL [1] is a recent Task-CL method. EWC [27] is a popular regularization-based class continual learning (Class-CL) method, which was adapted for Task-CL by only training on the corresponding head of the specific task ID during training and only considering the corresponding head’s prediction during testing. OWM [68] is also a Class-CL method, which we also adapt to Task-CL. L2 [27] is a classic regularization based Class-CL method, which we adapt to Task-CL. A-GEM [4] is an efficient version of the replay Task-CL method GEM [36], which penalizes the previous task loss from being increased. $\mathbf { D E R + + }$ [2] is a recent replay method using distillation to regularize the new task training and it can function as a Task-CL method. B-CL [24] is similar to CTR but uses dynamic routing for knowledge transfer and it performs markedly worse than CTR. LAMOL [58] is a pseudo-replay method based on GPT-2.
152
+
153
+ From the 10 systems, we created 10 baselines using W2V embeddings with the aspect term added before the sentence so that the Task-CL methods can take both aspect and the review sentence for ASC; 7 baselines using Adapter-BERT (SRK, KAN and CAT’s architectures cannot work with adapters); and 10 baselines using BERT (Frozen) (which replaces W2V embeddings). The BERT formulation in Sec. 3 naturally takes both aspect and review sentence in the ASC case.
154
+
155
+ # 5.3 Hyper-parameters
156
+
157
+ Unless otherwise stated, the same hyper-parameters are used in experiments for ASC, DSC and 20News datasets. For the knowledge sharing module (KSM), we employ 2 layers of fully connected network with dimensions 768 in the TK-Layer. We employ 3 transfer capsules. We experimented with 2 to 15 capsules and selected 3 based on the validation data accuracy. For the task specific module (TSM), we use 2000 dimensions as the final and the hidden layers of the TSM. The task ID embeddings have 2000 dimensions. A fully connected layer with softmax output is used as the classification heads in the last layer of the BERT, together with the categorical cross-entropy loss. dropout of 0.5 between fully connected layers. The training of BERT, Adapter-BERT and CTR follows that of [65]. We adopt BERTBASE (uncased). The maximum input length is set to 128 which is long enough for both ASC and DSC. We use Adam optimizer and set the learning rate to 3e-5. We use 10 epochs for SemEval datasets and 30 epochs for the other datasets in the ASC application. For DSC, we use 20 epochs. For 20News, we use 10 epochs. These are selected based on the validation results. The batch size is set to 32 for all cases. For all the other CL baselines, we use the code provided by their authors and adapt them for text classification. We also adopt their original parameters, including learning rate, early stopping, and batch size.
158
+
159
+ # 5.4 Evaluation Results and Analysis
160
+
161
+ Since the order of the tasks in a sequence may impact the final results, we randomly sampled 5 task sequences and averaged their results. We compute both accuracy and Macro-F1, where Macro-F1 is the primary metric as the imbalanced classes (in ASC) introduce biases on accuracy. Table 2 gives the average results of all the 19 tasks (or datasets) for ASC and 10 tasks (or datasets) for DSC and 20News over the 5 random task sequences.
162
+
163
+ Overall Performance. Table 2 shows that CTR clearly outperforms all baselines.
164
+
165
+ (1). For the standalone (SDL) baselines, BERT (with fine-tuning) and Adapter-BERT perform similarly. W2V and BERT (Frozen) are poorer, which is understandable.
166
+
167
+ (2). Comparing SDL (standalone learning) and NFH (continual learning with no forgetting handling), we see NFH is much better than SDL for W2V and BERT (Frozen). This indicates ASC and DSC tasks have similarities and thus shared knowledge. Catastrophic forgetting (CF) is not a major issue for W2V and BERT (Frozen). However, for 20News, NFH variants have serious CF. NFH with BERT (fine-tuning) is much worse than SDL and Adapter-BERT, which we explained in Introduction.
168
+
169
+ <table><tr><td rowspan="2">Scenarios</td><td rowspan="2">Category</td><td rowspan="2">Model</td><td colspan="2">ASC</td><td colspan="2">DSC (small)</td><td colspan="2">DSC (full)</td><td colspan="2">20News</td><td colspan="2">20News (FR)</td></tr><tr><td>Acc.</td><td>MF1</td><td>Acc.</td><td>MF1</td><td>Acc.</td><td>MF1</td><td>Acc.</td><td>MF1</td><td>Acc.</td><td>MF1</td></tr><tr><td rowspan="2">Non-continual Learning (SDL)</td><td>BERT BERT BERT (Frozen)</td><td>MTL SDL SDL</td><td>91.91 85.84 78.14</td><td>88.11 76.35 58.13</td><td>85.05 78.04 73.88</td><td>84.03 74.17</td><td>89.77 87.84</td><td>89.28 86.80</td><td>96.77 96.49</td><td>96.77 96.48</td><td></td><td></td></tr><tr><td>Adapter-BERT W2V BERT</td><td>SDL SDL NFH</td><td>85.96 77.01 49.60</td><td>78.07 51.89 43.08</td><td>76.31 62.06 73.87</td><td>67.97 71.04 53.80 69.44</td><td>85.34 88.30 69.57 73.08</td><td>80.17 87.31 65.51 71.81</td><td>96.49 96.20 94.72 52.50</td><td>96.48 96.19 94.72 39.22</td><td>24.29</td><td>30.52</td></tr><tr><td rowspan="10">Continual Learning (CL)</td><td>BERT (Frozen) Adapter-BERT W2V</td><td>NFH NFH NFH L2</td><td>85.51 54.03 82.69</td><td>76.64 44.81 73.56</td><td>83.12 63.76 65.16</td><td>79.23 53.95 57.48</td><td>61.88 64.94 70.40</td><td>45.79 63.40 68.03</td><td>83.28 68.29</td><td>81.81 61.70</td><td>8.76 30.59 4.30</td><td>9.73 3.79 4.47</td></tr><tr><td rowspan="5">BERT (frozen)</td><td rowspan="5">A-GEM DER++ KAN</td><td rowspan="5">56.04 86.06 84.27 85.49</td><td rowspan="5">38.40 78.44 75.08</td><td rowspan="5">59.17 59.33 72.29</td><td rowspan="5">48.39 45.94</td><td rowspan="5">69.80 70.67 86.70</td><td rowspan="5">62.63 61.77 85.46</td><td rowspan="5">90.74 72.14 93.31</td><td rowspan="5">90.59</td><td rowspan="5">24.57 4.09</td><td rowspan="5">32.05 4.48</td></tr><tr><td></td></tr><tr><td></td></tr><tr><td>65.39</td></tr><tr><td>92.95</td></tr><tr><td>66.28</td></tr><tr><td colspan="10"></td><td>49.67</td><td>10.54</td><td>12.16</td></tr><tr><td rowspan="6"></td><td rowspan="6"></td><td>SRK EWC</td><td>84.76 86.37</td><td>77.38 78.52 74.52</td><td>77.27 78.58 82.38</td><td>72.34 76.03</td><td>82.32 83.99</td><td>81.23</td><td>73.07 69.97 77.89</td><td></td><td>15.52 12.06</td><td>18.87 13.97 3.03</td></tr><tr><td>UCL</td><td>83.89</td><td></td><td>78.41</td><td>72.77 74.76</td><td>82.66 65.76 69.48</td><td>79.64 80.26 94.65</td><td>78.60</td><td>3.50</td><td>0.48</td></tr><tr><td></td><td></td><td>74.82</td><td>74.13</td><td></td><td></td><td></td><td>94.63</td><td>0.48</td><td></td></tr><tr><td>OWM HAT</td><td>87.02</td><td>79.31</td><td>80.12 58.07</td><td>42.63</td><td>86.30</td><td>85.36</td><td>84.54</td><td>82.73</td><td>13.80</td></tr><tr><td>CAT</td><td>86.74 83.68</td><td>78.16</td><td>79.48</td><td>72.78</td><td></td><td></td><td></td><td></td><td>15.81 2.89</td></tr><tr><td></td><td>63.97</td><td>68.64 52.43</td><td>67.41</td><td>56.22</td><td>87.29 87.34</td><td>86.14 86.51</td><td>93.51 95.17</td><td>92.93 95.16</td><td>2.26 0.80</td></tr><tr><td rowspan="4"></td><td rowspan="4">Adapter-BERT</td><td>L2</td><td></td><td>67.26</td><td>62.76</td><td>73.03</td><td>71.50</td><td>69.56</td><td>65.50</td><td>23.12</td><td>0.81 27.39</td></tr><tr><td>A-GEM</td><td>45.88 47.63</td><td>28.21 62.89</td><td>55.96</td><td>71.22</td><td>69.94</td><td>60.29</td><td>50.40</td><td>40.22</td><td>51.20</td></tr><tr><td>DER++ EWC</td><td>56.30</td><td>35.54 49.58</td><td>70.52 63.56</td><td>59.67</td><td>57.82</td><td>58.95</td><td>49.58</td><td>36.39</td><td>45.30</td></tr><tr><td>UCL OWM</td><td>64.46 72.99</td><td>58.23 36.64 48.30</td><td>51.03 32.07</td><td>62.69 57.06</td><td>61.51 55.86</td><td>61.86 51.75</td><td>53.94 36.06</td><td>37.79 4.70</td><td>46.58 6.60</td></tr><tr><td rowspan="4">W2V</td><td rowspan="4">HAT L2 KAN</td><td>86.14 60.36</td><td>66.51</td><td>73.97 80.83</td><td>71.96 78.41</td><td>85.46</td><td>84.57</td><td>71.10</td><td>66.25 95.21</td><td>27.38 0.33</td><td>32.76 0.34</td></tr><tr><td>81.33</td><td>78.52 39.13 63.35</td><td>54.34</td><td>43.19</td><td>88.00 57.71</td><td>87.26 48.00</td><td>95.22 59.54</td><td>54.40</td><td>7.83</td><td>11.89</td></tr><tr><td>A-GEM DER++</td><td>69.93</td><td>69.80</td><td>60.07</td><td>77.67</td><td>70.75</td><td>90.72</td><td>90.60</td><td>3.94</td><td>4.08</td></tr><tr><td>SRK</td><td>83.27 40.01</td><td>77.51 57.13 64.47</td><td>73.13 43.75</td><td>74.79</td><td>66.68</td><td>89.28</td><td>89.19</td><td>4.32</td><td>4.42</td></tr><tr><td rowspan="6"></td><td rowspan="5">HAT CAT</td><td rowspan="5">EWC UCL OWM</td><td>72.06 71.01 84.16</td><td></td><td>55.93</td><td>69.35</td><td>64.78</td><td>57.92</td><td>51.65</td><td>20.98</td><td>27.02 8.81</td></tr><tr><td></td><td>39.63</td><td></td><td>69.65</td><td>65.25</td><td>61.07</td><td>58.47</td><td>7.26</td><td></td></tr><tr><td></td><td>72.29</td><td>64.82</td><td>57.20 70.00</td><td>65.11</td><td>91.86</td><td>91.80</td><td>2.64</td><td>2.71 4.70</td></tr><tr><td>84.41 82.70</td><td>75.99</td><td>56.23</td><td>41.34</td><td>70.56</td><td>67.01</td><td>90.61</td><td>90.46</td><td>4.53</td></tr><tr><td></td><td>71.18</td><td>53.40</td><td>38.44</td><td>67.15</td><td>65.42</td><td>71.97</td><td>68.75</td><td>24.00</td></tr><tr><td colspan="2">B-CL LAMOL</td><td>80.83 76.28 88.29 88.91</td><td>63.63 54.65</td><td>62.57 55.19</td><td>50.83 35.28</td><td>69.75 79.58</td><td>65.44 75.99</td><td>67.73 70.38</td><td>64.43 68.04</td><td>26.04 24.37</td><td>27.56 29.70 26.95</td></tr><tr><td colspan="2"></td><td></td><td>81.40</td><td>82.01</td><td>80.63</td><td>79.76</td><td>76.51</td><td>95.07</td><td>95.04</td><td></td><td></td><td>0.59</td></tr><tr><td colspan="2">CTR(forward) CTR</td><td>87.89 89.47</td><td>80.59 80.25</td><td>89.12 83.75</td><td>86.58 82.55</td><td></td><td>92.11 89.86</td><td>91.72 89.16 95.63</td><td>66.13</td><td>45.74 95.62</td><td>0.58 20.03</td><td>16.60</td></tr></table>
170
+
171
+ Table 2: Accuracy (Acc.) and Macro-F1 (MF1), averaged over 5 random sequences. The architectures of SRK, KAN and CAT cannot work with Adapter-BERT. “—” means not applicable. Due to the limited space, standard deviation, running time and network size are given in Supplementary.
172
+
173
+ (3). Unlike BERT and Adapter-BERT, CTR does very well in both forgetting avoidance and knowledge transfer (outperforming all baselines). For baselines, EWC, UCL, OWM and HAT, although they perform better than NFH, they are significantly poorer than CTR as they don’t have methods to encourage knowledge transfer for ASC and DSC. KAN and SRK do knowledge transfer but they are weaker than many other CL methods. They perform very poorly for 20News as they have limited ability to overcome CF. CAT works well with large datasets, but is weak for small datasets.
174
+
175
+ (4). CTR’s improvements over SDL variants for DSC (large) is less than for DCS (small). This is understandable because when the training data is large, learning a separate model is already good, and knowledge transfer is less important.
176
+
177
+ (5). Compared with the SDL results, we can see that CTR has the least forgetting on 20News.
178
+
179
+ (6). Compared to B-CL, CTR is markedly better in knowledge transfer. The forgetting rates (FR) of B-CL and CTR are both low. The comparison is in fact the same as comparing dynamics routing and transfer routing. We can see that the proposed transfer routing is dramatically better than dynamic routing for knowledge transfer. Additionally, transfer routing eliminates the need for hyper-parameter tuning on the number of iterations of dynamic routing [50] to update the agreements.
180
+
181
+ (7). CTR outperforms LAMOL in ASC and 20News even with the less powerful BERT model that CTR adopts. LAMOL outperforms BERT-based MTL in DSC. This may be because LAMOL is based on GPT-2, which is known to be more powerful than BERT (also shown in the LAMOL paper). For 20News, since its tasks are very different/dissimilar, there is little shared knowledge. Dealing with CF is the main issue. LAMOL has serious forgetting as its FR values show.
182
+
183
+ (8). The results of MTL (the upper bound) are only slightly better than CTR, which again shows that CTR is highly effective in overcoming forgetting and encouraging knowledge transfer.
184
+
185
+ <table><tr><td rowspan="2">Model</td><td colspan="2">ASC</td><td colspan="2">DSC (small)</td><td colspan="2">DSC (full)</td><td colspan="2">20News</td></tr><tr><td>Acc.</td><td>MF1</td><td>Acc.</td><td>MF1</td><td>Acc.</td><td>MF1</td><td>Acc.</td><td>MF1</td></tr><tr><td>CTR(-KSM;-TSM)</td><td>0.5403</td><td>0.4481</td><td>0.6376</td><td>0.5395</td><td>0.6494</td><td>0.6340</td><td>0.6829</td><td>0.6170</td></tr><tr><td>CTR (-TSM)</td><td>0.8312</td><td>0.7107</td><td>0.7085</td><td>0.6759</td><td>0.8545</td><td>0.8380</td><td>0.8275</td><td>0.8064</td></tr><tr><td>CTR (-KSM)</td><td>0.8614</td><td>0.7852</td><td>0.8083</td><td>0.7841</td><td>0.8800</td><td>0.8726</td><td>0.9522</td><td>0.9521</td></tr><tr><td>CTR(-TR/KSM)</td><td>0.8819</td><td>0.8155</td><td>0.8244</td><td>0.8119</td><td>0.8831</td><td>0.8762</td><td>0.9476</td><td>0.9469</td></tr><tr><td>CTR(dynamic routing) (B-CL)</td><td>0.8829</td><td>0.8140</td><td>0.8201</td><td>0.8063</td><td>0.7976</td><td>0.7651</td><td>0.9507</td><td>0.9504</td></tr><tr><td>CTR (on top)</td><td>0.8135</td><td>0.6390</td><td>0.7301</td><td>0.6875</td><td>0.8266</td><td>0.8105</td><td>0.8927</td><td>0.8920</td></tr><tr><td>CTR (after the first FF layer)</td><td>0.8741</td><td>0.8014</td><td>0.8300</td><td>0.8183</td><td>0.8699</td><td>0.8596</td><td>0.9381</td><td>0.9373</td></tr><tr><td>CTR (after the other two FF layers)</td><td>0.8662</td><td>0.7863</td><td>0.8269</td><td>0.8161</td><td>0.8714</td><td>0.8612</td><td>0.9339</td><td>0.9316</td></tr><tr><td>CTR</td><td>0.8947</td><td>0.8362</td><td>0.8434</td><td>0.8329</td><td>0.8931</td><td>0.8875</td><td>0.9525</td><td>0.9523</td></tr></table>
186
+
187
+ Table 3: Ablation experiment results.
188
+
189
+ Effectiveness of Knowledge Transfer. Forward transfer is defined as the forward performance (CTR(forward) in Table 2) subtracting the standalone (SDL) result. CTR(forward) is the test accuracy or MF1 of each task when it was first learned. Backward transfer is defined as the difference between the backward performance (CTR in Table 2, the final result after all tasks are learned) and the forward performance. The average results of CTR (forward) and CTR are given in Table 2. We observe that forward transfer of CTR is highly effective for the three datasets with similar tasks. For DSC, the less the data, the more effective is the transfer, which is reasonable. Backward transfer improves the accuracy and MF1 of ASC and DSC (small). For DSC (full), it is slightly weaker and for 20News, it is also slightly weaker due to a very small amount of forgetting, but the less than 0.0055 CF is negligible. Note that in [36, 46], forward transfer is measured by comparing the test results of the new task on the current learned network and a random initialized network before/without training the new task (like zero-shot). This method indicates whether the learned network contains some useful knowledge for the new task. However, it does not tell how much forward transfer actually happens after learning the new task, which is more important and is what our method measures.
190
+
191
+ Overcoming Forgetting. To validate CTR’s effectiveness in dealing forgetting with a sequence of dissimilar tasks, we compute the Forgetting Rate [34], $\begin{array} { r } { \mathrm { F R } = \frac { 1 } { t - 1 } \bar { \sum _ { i = 1 } ^ { t - 1 } A _ { i , i } } - \bar { A _ { t , i } } } \end{array}$ , where $A _ { i , i }$ is the forward accuracy of task $i$ and $A _ { t , i }$ is the accuracy of task $i$ after training the last task $t$ . We average over all tasks except the last one because the last task obviously has no forgetting. We report the forgetting rate FR (averaged over 5 random task sequences) for the 20News data on the two evaluation metrics in the last two columns of Table 2 (the other two datasets are mainly for knowledge transfer). CTR has very low FR values which indicate very little forgetting.
192
+
193
+ Ablation Study. The results of ablation experiments are in Table 3. “-KSM;-TSM” means that the knowledge sharing module (KSM) and the task specific module (TSM) are not used, and we simply deploy the Adapter-BERT. “-KSM” means that the knowledge sharing module (KSM) is not used. “-TSM” means that the task specific module (TSM) is not used. “-TR/KSM” means that the task router (TR) in KSM is not used. We directly send the transferable representation vtran(j|i to the next layer. “dynamic routing” means that we replace our transfer routing (-(SE&TR)/KSM) with dynamic routing [50], which is one of the most popular routing algorithms in capsule networks. “on top” means adding a CL-plugin on top of BERT. “after the first FF layer” means adding only one CL-plugin there in BERT. ”after the other two FF layers” means adding only one CL-plugin module there in BERT. Table 3 shows that the full CTR system gives the best results, indicating every component contributes to the model and other options of adding CL-plugins are all poorer.
194
+
195
+ # 6 Conclusion
196
+
197
+ This paper studied task continual learning (Task-CL) using the pre-trained model BERT to achieve both CF presentation and knowledge transfer. It proposed a novel technique called CTR to leverage the pre-trained BERT for CL. The key component of CTR is the CL-plugin inserted in BERT. A CL-plugin is a capsule network with a new transfer routing mechanism to encourage knowledge transfer among tasks and also to isolate task-specific knowledge to avoid forgetting. Experimental results using three NLP applications showed that CTR markedly improves the performance of both the new task and the old tasks via knowledge transfer and is also effective at overcoming catastrophic forgetting. One limitation of our work is the efficiency due to the use of capsules. Capsules try to represent a group of neurons in a vector reflecting properties of an entity. In NLP, an entity is a sentence/document which contains many tokens (e.g., 128) and features (e.g. 768 in BERTBASE). Grouping them makes the capsule very large (e.g., $1 2 8 \times 7 6 8 $ ), which slows down training.
198
+
199
+ # Acknowledgments
200
+
201
+ This work was supported in part by two National Science Foundation (NSF) grants (IIS-1910424 and IIS-1838770), a DARPA Contract HR001120C0023, and a Northrop Grumman research gift.
202
+
203
+ # References
204
+
205
+ [1] H. Ahn, S. Cha, D. Lee, and T. Moon. Uncertainty-based continual learning with adaptive regularization. In NIPS, 2019. [2] P. Buzzega, M. Boschini, A. Porrello, D. Abati, and S. Calderara. Dark experience for general continual learning: a strong, simple baseline. arXiv preprint arXiv:2004.07211, 2020.
206
+ [3] A. Carlson, J. Betteridge, B. Kisiel, B. Settles, E. Hruschka, and T. Mitchell. Toward an architecture for never-ending language learning. In AAAI, volume 24, 2010. [4] A. Chaudhry, M. Ranzato, M. Rohrbach, and M. Elhoseiny. Efficient lifelong learning with A-GEM. In ICLR, 2019. [5] Z. Chen and B. Liu. Lifelong machine learning. Synthesis Lectures on Artificial Intelligence and Machine Learning, 12(3):1–207, 2018. [6] Z. Chen, N. Ma, and B. Liu. Lifelong learning for sentiment classification. In ACL, 2015. [7] Y.-S. Chuang, S.-Y. Su, and Y.-N. Chen. Lifelong language knowledge distillation. arXiv preprint arXiv:2010.02123, 2020.
207
+ [8] J. Devlin, M. Chang, K. Lee, and K. Toutanova. BERT: pre-training of deep bidirectional transformers for language understanding. In J. Burstein, C. Doran, and T. Solorio, editors, NAACL-HLT, 2019. [9] X. Ding, B. Liu, and P. S. Yu. A holistic lexicon-based approach to opinion mining. In Proceedings of the 2008 international conference on web search and data mining, 2008.
208
+ [10] C. Fernando, D. Banarse, C. Blundell, Y. Zwols, D. Ha, A. A. Rusu, A. Pritzel, and D. Wierstra. Pathnet: Evolution channels gradient descent in super neural networks. CoRR, 2017.
209
+ [11] E. Grave, P. Bojanowski, P. Gupta, A. Joulin, and T. Mikolov. Learning word vectors for 157 languages. In LREC, 2018.
210
+ [12] C. Greco, B. Plank, R. Fernández, and R. Bernardi. Psycholinguistics meets continual learning: Measuring catastrophic forgetting in visual question answering. arXiv preprint arXiv:1906.04229, 2019.
211
+ [13] P. Gupta, Y. Chaudhary, T. Runkler, and H. Schuetze. Neural topic modeling with continual lifelong learning. In International Conference on Machine Learning, pages 3907–3917. PMLR, 2020.
212
+ [14] X. He and H. Jaeger. Overcoming catastrophic interference using conceptor-aided backpropagation. In ICLR, 2018.
213
+ [15] G. E. Hinton, A. Krizhevsky, and S. D. Wang. Transforming auto-encoders. In International conference on artificial neural networks, 2011.
214
+ [16] N. Houlsby, A. Giurgiu, S. Jastrzebski, B. Morrone, Q. de Laroussilhe, A. Gesmundo, M. Attariyan, and S. Gelly. Parameter-efficient transfer learning for NLP. In K. Chaudhuri and R. Salakhutdinov, editors, ICML, 2019.
215
+ [17] M. Hu and B. Liu. Mining and summarizing customer reviews. In Proceedings of ACM SIGKDD, 2004.
216
+ [18] W. Hu, Q. Qin, M. Wang, J. Ma, and B. Liu. Continual learning by using information of each class holistically. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 35, pages 7797–7805, 2021.
217
+ [19] E. Jang, S. Gu, and B. Poole. Categorical reparameterization with gumbel-softmax. In ICLR, 2017.
218
+ [20] N. Kamra, U. Gupta, and Y. Liu. Deep generative dual memory network for continual learning. CoRR, 2017.
219
+ [21] Z. Ke, B. Liu, and X. Huang. Continual learning of a mixed sequence of similar and dissimilar tasks. In NeurIPS, 2020.
220
+ [22] Z. Ke, B. Liu, H. Wang, and L. Shu. Continual learning with knowledge transfer for sentiment classification. In ECML-PKDD, 2020.
221
+ [23] Z. Ke, B. Liu, H. Xu, and L. Shu. Classic: Continual and contrastive learning of aspect sentiment classification tasks. In EMNLP, 2021.
222
+ [24] Z. Ke, H. Xu, and B. Liu. Adapting bert for continual learning of a sequence of aspect sentiment classification tasks. In NAACL, pages 4746–4755, 2021.
223
+ [25] H. Khayrallah, B. Thompson, K. Duh, and P. Koehn. Regularized training objective for continued training for domain adaptation in neural machine translation. In Proceedings of the 2nd Workshop on Neural Machine Translation and Generation, pages 36–44, 2018.
224
+ [26] Y. Kim. Convolutional neural networks for sentence classification. In A. Moschitti, B. Pang, and W. Daelemans, editors, EMNLP, 2014.
225
+ [27] J. Kirkpatrick, R. Pascanu, N. C. Rabinowitz, J. Veness, G. Desjardins, A. A. Rusu, K. Milan, J. Quan, T. Ramalho, A. Grabska-Barwinska, D. Hassabis, C. Clopath, D. Kumaran, and R. Hadsell. Overcoming catastrophic forgetting in neural networks. CoRR, 2016.
226
+ [28] K. Lang. Newsweeder: Learning to filter netnews. In Proceedings of the Twelfth International Conference on Machine Learning, 1995.
227
+ [29] M. D. Lange, R. Aljundi, M. Masana, and T. Tuytelaars. Continual learning: A comparative study on how to defy forgetting in classification tasks. CoRR, 2019.
228
+ [30] S. Lee, J. Kim, J. Jun, J. Ha, and B. Zhang. Overcoming catastrophic forgetting by incremental moment matching. In NIPS.
229
+ [31] Y. Li, L. Zhao, K. Church, and M. Elhoseiny. Compositional language continual learning. In International Conference on Learning Representations, 2019.
230
+ [32] Q. Liu, Z. Gao, B. Liu, and Y. Zhang. Automated rule selection for aspect extraction in opinion mining. In IJCAI, 2015.
231
+ [33] T. Liu, L. Ungar, and J. Sedoc. Continual learning for sentence representations using conceptors. arXiv preprint arXiv:1904.09187, 2019.
232
+ [34] Y. Liu, Y. Su, A. Liu, B. Schiele, and Q. Sun. Mnemonics training: Multi-class incremental learning without forgetting. In CVPR, 2020.
233
+ [35] Z. Liu, G. I. Winata, A. Madotto, and P. Fung. Exploring fine-tuning techniques for pre-trained cross-lingual models via continual learning. arXiv preprint arXiv:2004.14218, 2020.
234
+ [36] D. Lopez-Paz and M. Ranzato. Gradient episodic memory for continual learning. In NIPS, 2017.
235
+ [37] G. Lv, S. Wang, B. Liu, E. Chen, and K. Zhang. Sentiment classification by leveraging the shared knowledge from a sequence of domains. In DASFAA, 2019.
236
+ [38] A. Madotto, Z. Lin, Z. Zhou, S. Moon, P. Crook, B. Liu, Z. Yu, E. Cho, and Z. Wang. Continual learning in task-oriented dialogue systems. arXiv preprint arXiv:2012.15504, 2020.
237
+ [39] A. Mallya and S. Lazebnik. Packnet: Adding multiple tasks to a single network by iterative pruning. In CVPR, 2018.
238
+ [40] M. McCloskey and N. J. Cohen. Catastrophic interference in connectionist networks: The sequential learning problem. In Psychology of learning and motivation. 1989.
239
+ [41] A. Merchant, E. Rahimtoroghi, E. Pavlick, and I. Tenney. What happens to BERT embeddings during fine-tuning? CoRR, 2020.
240
+ [42] J. Pfeiffer, A. Kamath, A. Rücklé, K. Cho, and I. Gurevych. Adapterfusion: Non-destructive task composition for transfer learning.
241
+ [43] Q. Qin, W. Hu, and B. Liu. Using the past knowledge to improve sentiment classification. In EMNLP-findings, 2020.
242
+ [44] V. V. Ramasesh, E. Dyer, and M. Raghu. Anatomy of catastrophic forgetting: Hidden representations and task semantics. In ICLR, 2021.
243
+ [45] S. Rebuffi, A. Kolesnikov, G. Sperl, and C. H. Lampert. icarl: Incremental classifier and representation learning. In CVPR, 2017.
244
+ [46] M. Riemer, I. Cases, R. Ajemian, M. Liu, I. Rish, Y. Tu, , and G. Tesauro. Learning to learn without forgetting by maximizing transfer and minimizing interference. In International Conference on Learning Representations, 2019.
245
+ [47] M. Rostami, S. Kolouri, and P. K. Pilly. Complementary learning for overcoming catastrophic forgetting using experience replay. In IJCAI, 2019.
246
+ [48] A. A. Rusu, N. C. Rabinowitz, G. Desjardins, H. Soyer, J. Kirkpatrick, K. Kavukcuoglu, R. Pascanu, and R. Hadsell. Progressive neural networks. CoRR, 2016.
247
+ [49] P. Ruvolo and E. Eaton. ELLA: an efficient lifelong learning algorithm. In ICML, pages 507–515, 2013.
248
+ [50] S. Sabour, N. Frosst, and G. E. Hinton. Dynamic routing between capsules. In NIPS, 2017.
249
+ [51] A. Seff, A. Beatson, D. Suo, and H. Liu. Continual learning in generative adversarial nets. CoRR, abs/1705.08395, 2017.
250
+ [52] J. Serrà, D. Suris, M. Miron, and A. Karatzoglou. Overcoming catastrophic forgetting with hard attention to the task. In ICML, 2018.
251
+ [53] Y. Shen, X. Zeng, and H. Jin. A progressive model to enable continual learning for semantic slot filling. In EMNLP-IJCNLP, Nov. 2019.
252
+ [54] H. Shin, J. K. Lee, J. Kim, and J. Kim. Continual learning with deep generative replay. In NIPS, 2017.
253
+ [55] L. Shu, H. Xu, and B. Liu. Lifelong learning CRF for supervised aspect extraction. In ACL, 2017.
254
+ [56] D. L. Silver, Q. Yang, and L. Li. Lifelong machine learning systems: Beyond learning algorithms. In Lifelong Machine Learning, Papers from the 2013 AAAI Spring Symposium, Palo Alto, California, USA, March 25-27, 2013, 2013.
255
+ [57] C. Sun, L. Huang, and X. Qiu. Utilizing BERT for aspect-based sentiment analysis via constructing auxiliary sentence. In NAACL, 2019.
256
+ [58] F.-K. Sun, C.-H. Ho, and H.-Y. Lee. Lamol: Language modeling is all you need for lifelong language learning. In ICLR, 2020.
257
+ [59] D. Tang, B. Qin, and T. Liu. Aspect level sentiment classification with deep memory network. In EMNLP, Nov. 2016.
258
+ [60] A. Vaswani, N. Shazeer, N. Parmar, J. Uszkoreit, L. Jones, A. N. Gomez, Ł. Kaiser, and I. Polosukhin. Attention is all you need. In NeurIPS, 2017.
259
+ [61] H. Wang, B. Liu, S. Wang, N. Ma, and Y. Yang. Forward and backward knowledge transfer for sentiment classification. In ACML, 2019.
260
+ [62] S. Wang, G. Lv, S. Mazumder, G. Fei, and B. Liu. Lifelong learning memory networks for aspect sentiment classification. In IEEE International Conference on Big Data, 2018.
261
+ [63] Z. Wang, S. V. Mehta, B. Póczos, and J. Carbonell. Efficient meta lifelong-learning with limited memory. In EMNLP, 2020.
262
+ [64] R. Xia, J. Jiang, and H. He. Distantly supervised lifelong learning for large-scale social media sentiment analysis. IEEE Trans. Affective Computing, 8(4):480–491, 2017.
263
+ [65] H. Xu, B. Liu, L. Shu, and P. S. Yu. BERT post-training for review reading comprehension and aspect-based sentiment analysis. In J. Burstein, C. Doran, and T. Solorio, editors, NAACL-HLT, 2019.
264
+ [66] H. Xu, S. Xie, L. Shu, and P. S. Yu. Dual attention network for product compatibility and function satisfiability analysis. In AAAI, 2018.
265
+ [67] W. Xue and T. Li. Aspect based sentiment analysis with gated convolutional networks. In I. Gurevych and Y. Miyao, editors, ACL, 2018.
266
+ [68] G. Zeng, Y. Chen, B. Cui, and S. Yu. Continuous learning of context-dependent processing in neural networks. Nature Machine Intelligence, 2019.
267
+ [69] F. Zenke, B. Poole, and S. Ganguli. Continual learning through synaptic intelligence. In International Conference on Machine Learning, pages 3987–3995. PMLR, 2017.
parse/train/RJ7XFI15Q8f/RJ7XFI15Q8f_content_list.json ADDED
@@ -0,0 +1,1133 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [
2
+ {
3
+ "type": "text",
4
+ "text": "Achieving Forgetting Prevention and Knowledge Transfer in Continual Learning ",
5
+ "text_level": 1,
6
+ "bbox": [
7
+ 207,
8
+ 122,
9
+ 792,
10
+ 172
11
+ ],
12
+ "page_idx": 0
13
+ },
14
+ {
15
+ "type": "text",
16
+ "text": "Zixuan $\\mathbf { K } \\mathbf { e } ^ { 1 }$ , Bing Liu1, Nianzu $\\mathbf { M } \\mathbf { a } ^ { 1 }$ , $\\mathbf { H } \\mathbf { u } \\mathbf { X } \\mathbf { u } ^ { 2 }$ and Lei $\\mathbf { S h u ^ { 3 * } }$ ",
17
+ "bbox": [
18
+ 290,
19
+ 224,
20
+ 714,
21
+ 239
22
+ ],
23
+ "page_idx": 0
24
+ },
25
+ {
26
+ "type": "text",
27
+ "text": "1Department of Computer Science, University of Illinois at Chicago 2Facebook AI Research 3Amazon AWS AI 1{zke4,liub,nma4}@uic.edu 2huxu@fb.com 3shulindt@gmail.com ",
28
+ "bbox": [
29
+ 277,
30
+ 241,
31
+ 723,
32
+ 327
33
+ ],
34
+ "page_idx": 0
35
+ },
36
+ {
37
+ "type": "text",
38
+ "text": "Abstract ",
39
+ "text_level": 1,
40
+ "bbox": [
41
+ 462,
42
+ 362,
43
+ 535,
44
+ 378
45
+ ],
46
+ "page_idx": 0
47
+ },
48
+ {
49
+ "type": "text",
50
+ "text": "Continual learning (CL) learns a sequence of tasks incrementally with the goal of achieving two main objectives: overcoming catastrophic forgetting (CF) and encouraging knowledge transfer (KT) across tasks. However, most existing techniques focus only on overcoming CF and have no mechanism to encourage KT, and thus do not do well in KT. Although several papers have tried to deal with both CF and KT, our experiments show that they suffer from serious CF when the tasks do not have much shared knowledge. Another observation is that most current CL methods do not use pre-trained models, but it has been shown that such models can significantly improve the end task performance. For example, in natural language processing, fine-tuning a BERT-like pre-trained language model is one of the most effective approaches. However, for CL, this approach suffers from serious CF. An interesting question is how to make the best use of pre-trained models for CL. This paper proposes a novel model called CTR to solve these problems. Our experimental results demonstrate the effectiveness of CTR.2 ",
51
+ "bbox": [
52
+ 233,
53
+ 395,
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
+ 174,
65
+ 614,
66
+ 310,
67
+ 632
68
+ ],
69
+ "page_idx": 0
70
+ },
71
+ {
72
+ "type": "text",
73
+ "text": "This paper studies continual learning (CL) of a sequence of natural language processing (NLP) tasks in the task continual learning (Task-CL) setting. It aims to (i) prevent catastrophic forgetting (CF), and (ii) transfer knowledge across tasks. (ii) is particularly important because many tasks in NLP share similar knowledge that can be leveraged to achieve better accuracy. CF means that in learning a new task, the existing network parameters learned for the previous tasks may be modified, which degrades the performance of previous tasks [40]. In the Task-CL setting, the task id is provided for each test case in testing so that the specific model for the task in the network can be applied to classify the test case. Another popular CL setting is class continual learning, which does not provide the task id during testing but it is for solving a different type of problems. ",
74
+ "bbox": [
75
+ 174,
76
+ 647,
77
+ 825,
78
+ 772
79
+ ],
80
+ "page_idx": 0
81
+ },
82
+ {
83
+ "type": "text",
84
+ "text": "Most existing CL papers focus on dealing with CF [21, 5]. There are also some papers that perform knowledge transfer. To achieve both objectives is highly challenging. To overcome CF in the Task-CL setting, we don’t want the training of the new task to update the model parameters learned for previous tasks to achieve model separation. But to transfer knowledge across tasks, we want the new task to leverage the knowledge learned from previous tasks for learning a better model (forward transfer) and also want the new task to enhance the performance of similar previous tasks (backward transfer). ",
85
+ "bbox": [
86
+ 174,
87
+ 777,
88
+ 825,
89
+ 861
90
+ ],
91
+ "page_idx": 0
92
+ },
93
+ {
94
+ "type": "text",
95
+ "text": "This means it is necessary to update previous model parameters. This is a dilemma. Although several papers have tried to deal with both [22, 37], they were only tested using sentiment analysis tasks with strong shared knowledge. When tested with tasks that don’t have much shared knowledge, they suffer from severe CF (see Sec. 5.4). Those existing papers that focus on dealing with CF do not do well with knowledge transfer as they have no explicit mechanism to facilitate the transfer. ",
96
+ "bbox": [
97
+ 174,
98
+ 92,
99
+ 825,
100
+ 160
101
+ ],
102
+ "page_idx": 1
103
+ },
104
+ {
105
+ "type": "text",
106
+ "text": "Another observation about the current CL research is that most techniques do not use pre-trained models. But such pre-trained models or feature extractors can significantly improve the CL performance [18, 24]. An important question is how to make the best use of pre-trained models in CL. This paper studies the problem as well using NLP tasks, but we believe that the developed ideas are also applicable to computer vision tasks because most pre-trained models are based on the transformer architecture [60]. We will see that the naive or the conventional way of directly adding the CL module on top of a pre-trained model is not the best choice (see Sec. 5.4). ",
107
+ "bbox": [
108
+ 174,
109
+ 166,
110
+ 825,
111
+ 263
112
+ ],
113
+ "page_idx": 1
114
+ },
115
+ {
116
+ "type": "text",
117
+ "text": "In NLP, fine-tuning a BERT [8] like pre-trained language model has been regarded as one of the most effective techniques in applications [65, 57]. However, fine-tuning works poorly for continual learning. This is because the fine-tuned BERT for a task captures highly task-specific information [41], which is difficult to be used by other tasks. When fine-tuning for a new task, it has to update the already fine-tuned parameters for previous tasks, which causes serious CF (see Sec. 5.4). ",
118
+ "bbox": [
119
+ 174,
120
+ 270,
121
+ 825,
122
+ 340
123
+ ],
124
+ "page_idx": 1
125
+ },
126
+ {
127
+ "type": "text",
128
+ "text": "This paper proposes a novel neural architecture to achieve both CF prevention and knowledge transfer, which also deals with the CF problem with BERT fine-tuning. The proposed system is called CTR (Capsules and Transfer Routing for continual learning). CTR inserts a continual learning plug-in (CL-plugin) module in two locations in BERT. With the pair of CL-plugin modules added to BERT, we no longer need to fine-tune BERT for each task, which causes CF in BERT, and yet we can achieve the power of BERT fine-tuning. CTR has some similarity to Adapter-BERT [16], which adds adapters in BERT for parameter efficient transfer learning such that different end tasks can have their separate adapters (which are very small in size) to adapt BERT for individual end tasks and to transfer the knowledge from BERT to the end tasks. Then, there is no need to employ a separate BERT and fine-tuning it for each task, which is extremely parameter inefficient if many tasks need to be learned. An adapter is a simple 2-layer fully-connected network for adapting BERT to a specific end task. A CL-plugin is very different from an adapter. We do not use a pair of CL-plugin modules to adapt BERT for each task. Instead, CTR learns all tasks using only one pair of CL-plugin modules inserted into BERT. A CL-plugin is a full CL network that can leverage a pre-trained model and deal with both CF and knowledge transfer. Specifically, it uses a capsule [15] to represent each task and a proposed transfer routing algorithm to identify and transfer knowledge across tasks to achieve improved accuracy. It further learns and uses task masks to protect task-specific knowledge to avoid forgetting. Empirical evaluations show that CTR outperforms strong baselines. Ablation experiments have also been conducted to study where to insert the CL-plugin module in BERT in order to achieve the best performance (see Sec. 5.4). ",
129
+ "bbox": [
130
+ 174,
131
+ 345,
132
+ 825,
133
+ 622
134
+ ],
135
+ "page_idx": 1
136
+ },
137
+ {
138
+ "type": "text",
139
+ "text": "2 Related Work ",
140
+ "text_level": 1,
141
+ "bbox": [
142
+ 174,
143
+ 645,
144
+ 321,
145
+ 662
146
+ ],
147
+ "page_idx": 1
148
+ },
149
+ {
150
+ "type": "text",
151
+ "text": "Catastrophic Forgetting: Existing work in CL mainly focused on overcoming CF using the following approaches. (1) Regularization-based approaches, such as those in [27, 30, 51, 69], add a regularization in the loss to consolidate weights for previous tasks when learning a new task. (2) Replay-based approaches, such as those in [45, 36, 4, 63], retain some training data of old tasks and use them in learning a new task. The methods in [54, 20, 47, 14] learn data generators and generate old task data for learning a new task. (3) Parameter isolation-based approaches, such as those in [52, 21, 39, 10], allocate model parameters dedicated to different tasks and mask them out when learning a new task. (4) Gradient projection-based approaches [68] ensure the gradient updates occur only in the orthogonal direction to the input of old tasks and thus will not affect old tasks. Some recent papers used pre-trained models [18, 23, 24] and learn one class per task [18]. Tackling CF only deals with model deterioration. These methods perform worse than learning each task separately. An empirical study of the cause of CF and the impact of task similarity on CF was done in [44]. ",
152
+ "bbox": [
153
+ 174,
154
+ 683,
155
+ 825,
156
+ 849
157
+ ],
158
+ "page_idx": 1
159
+ },
160
+ {
161
+ "type": "text",
162
+ "text": "Some NLP applications have also dealt with CF. For example, CL models have been proposed for sentiment analysis [23, 24, 37, 43], dialogue slot filling [53], language modeling [58, 7], language learning [31], sentence embedding [33], machine translation [25], cross-lingual modeling [35], and question answering [12]. A dialogue CL dataset is also reported in [38]. ",
163
+ "bbox": [
164
+ 176,
165
+ 856,
166
+ 825,
167
+ 911
168
+ ],
169
+ "page_idx": 1
170
+ },
171
+ {
172
+ "type": "text",
173
+ "text": "Knowledge Transfer: Ideally, learning from a sequence of tasks should also allow multiple tasks to support each other via knowledge transfer. CAT [21] (a Task-CL system) works on a mixed sequence of similar and dissimilar tasks and can transfer knowledge among similar tasks detected automatically. Progressive Network [48] does forward transfer but it is for class continual learning (Class-CL). ",
174
+ "bbox": [
175
+ 174,
176
+ 92,
177
+ 825,
178
+ 147
179
+ ],
180
+ "page_idx": 2
181
+ },
182
+ {
183
+ "type": "text",
184
+ "text": "Knowledge transfer in this paper is closely related to lifelong learning (LL), which aims to improve the new/last task learning without handling CF [56, 49, 5]. In the NLP area, NELL [3] performs LL information extraction, and several other papers worked on lifelong document sentiment classification (DSC) and aspect sentiment classification (ASC). [6] and [61] proposed two Naive Bayesian methods to help improve the new task learning. [64] proposed a LL approach based on voting. [55] used LL for aspect extraction. [43] and [62] used neural networks for DSC and ASC, respectively. Several papers also studied lifelong topic modeling [5, 13]. However, all these works do not deal with CF. ",
185
+ "bbox": [
186
+ 174,
187
+ 152,
188
+ 825,
189
+ 251
190
+ ],
191
+ "page_idx": 2
192
+ },
193
+ {
194
+ "type": "text",
195
+ "text": "SRK [37] and KAN [22] try to deal with both CF and knowledge transfer in continual sentiment classification. However, they have two critical weaknesses: (i) Their RNN architectures cannot use plug-in or adapter modules to tune BERT, which significantly limits their power. (ii) Since they were mainly designed for knowledge transfer, they suffer from serious CF (see Sec. 5.4). B-CL [24] uses the adapter idea [16] to adapt BERT for sentiment analysis tasks, which are similar to each other. However, since its mechanism of dynamic routing for knowledge transfer is very week, its knowledge transfer ability is markedly poorer than CTR (see Sec. 5.4). CLASSIC [23] is another recent work on continual learning for knowledge transfer, but its CL setting is domain continual learning. Its knowledge transfer method is based on contrastive learning. ",
196
+ "bbox": [
197
+ 174,
198
+ 256,
199
+ 825,
200
+ 382
201
+ ],
202
+ "page_idx": 2
203
+ },
204
+ {
205
+ "type": "text",
206
+ "text": "AdapterFusion [42] used adapters proposed in [16]. It proposes a two-stage method to learn a set of tasks. In the first stage, it learns one adapter for each task independently using the task’s training data. In the second stage, it uses the training data again to learn a good composition of the learned adapters in the first stage to produce the final model for all tasks. AdapterFusion basically tries to improve multi-task learning. It is not for continual learning and thus has no CF. As explained in Sec. 1, the CL-plugin concept in CTR is different from that of adapters for adapting BERT for each task. CL-plugins are continual learning systems that make use of a pre-trained model. ",
207
+ "bbox": [
208
+ 174,
209
+ 387,
210
+ 825,
211
+ 484
212
+ ],
213
+ "page_idx": 2
214
+ },
215
+ {
216
+ "type": "text",
217
+ "text": "3 CTR Architecture ",
218
+ "text_level": 1,
219
+ "bbox": [
220
+ 174,
221
+ 506,
222
+ 356,
223
+ 523
224
+ ],
225
+ "page_idx": 2
226
+ },
227
+ {
228
+ "type": "text",
229
+ "text": "This section describes the general architecture of CTR. The details about its key component CLplugin is presented in the next section. Due to its good performance, BERT [8] and its transformer [60] architecture are used as the base in our model CTR. Since BERT fine-tuning is prone to CF (Sec. 1), we propose the CL plug-in idea, which is inspired by Adapter-BERT [16]. CL-plugin is a full continual learning module designed to interact with a pre-trained model, in our case, BERT. ",
230
+ "bbox": [
231
+ 174,
232
+ 537,
233
+ 825,
234
+ 608
235
+ ],
236
+ "page_idx": 2
237
+ },
238
+ {
239
+ "type": "text",
240
+ "text": "Inserting CL-plugins in BERT. A commonly used method of leveraging a pre-trained model is to add the end task module on top of the pre-trained model. However, as explained in Sec. 1, fine-tuning the pre-trained model can cause serious CF for CL. The CL system PCL [18], which uses this approach, has the pre-trained model frozen to avoid forgetting. But as we will see in Sec. 5.4, this is not the best choice. CTR inserts the proposed CL-plugin in two locations in BERT, i.e., in each transformer layer of BERT. We will also see in Sec. 5.4 that inserting only one CL-plugin in one location is sub-optimal. Figure 1 gives the CTR architecture and we can see the two CL-plugins are added into BERT. In learning, only the two CL-plugins and the classification heads are trained. The components of the original pre-trained BERT are fixed. ",
241
+ "bbox": [
242
+ 174,
243
+ 614,
244
+ 825,
245
+ 739
246
+ ],
247
+ "page_idx": 2
248
+ },
249
+ {
250
+ "type": "text",
251
+ "text": "Continual learning plug-in (CL-plugin). CL-plugin employs a capsule network (CapsNet) [15, 50] like architecture. In the classic neural network, a neuron outputs a scalar, real-valued activation as a feature detector. CapsNets replaces that with a vector-output capsule to preserve additional information. A simple CapsNet consists of two capsule layers. The first layer stores low-level feature maps, and the second layer generates the classification probability with each capsule corresponding to one class. CapsNet uses a dynamic routing algorithm to make each lower-level capsule to send its output to a similar (or “agreed”, computed by dot product) higher-level capsule. This property can already be used to group similar tasks and their shareable features to produce a CL system (see the ablation study in Sec. 5.4). One of the key ideas of CL-plugin (see Figure 2(A)) is a transfer capsule layer with a new transfer routing algorithm to explicitly identify transferable features/knowledge from previous tasks to transfer to the new task. Additionally, transfer routing avoids the need for hyper-parameter tuning on the number of iterations of dynamic routing [50] to update the agreements. ",
252
+ "bbox": [
253
+ 174,
254
+ 746,
255
+ 825,
256
+ 911
257
+ ],
258
+ "page_idx": 2
259
+ },
260
+ {
261
+ "type": "image",
262
+ "img_path": "images/7fcebe2141532fd920633052504d05428c323dfe7e3d6216b689bcb7570d3ef1.jpg",
263
+ "image_caption": [
264
+ "Figure 1: Architecture of BERT (left) and the proposed system CTR (right), which inserts two CL-plugins in BERT. Each CL-plugin module (far right) has two sub-modules and a skip connection: knowledge sharing sub-module (KSM) and task-specific sub-module (TSM). "
265
+ ],
266
+ "image_footnote": [],
267
+ "bbox": [
268
+ 236,
269
+ 88,
270
+ 761,
271
+ 198
272
+ ],
273
+ "page_idx": 3
274
+ },
275
+ {
276
+ "type": "image",
277
+ "img_path": "images/2bac79b64fa04786b82b8f655269d1ffe4edb9cf7ec62f3efaa8b92c276969e8.jpg",
278
+ "image_caption": [
279
+ "Figure 2: (A) CL-plugin Architecture. (B) Illustration of task masking. Cells/neurons in brown, green and red are respectively used by tasks 0, 1 and 2. Neurons with two colors are used by two tasks "
280
+ ],
281
+ "image_footnote": [],
282
+ "bbox": [
283
+ 220,
284
+ 265,
285
+ 781,
286
+ 627
287
+ ],
288
+ "page_idx": 3
289
+ },
290
+ {
291
+ "type": "text",
292
+ "text": "4 Continual Learning Plug-in (CL-plugin) ",
293
+ "text_level": 1,
294
+ "bbox": [
295
+ 174,
296
+ 684,
297
+ 542,
298
+ 702
299
+ ],
300
+ "page_idx": 3
301
+ },
302
+ {
303
+ "type": "text",
304
+ "text": "The architecture of our continual learning plug-in (CL-plugin) is shown in Figure 2(A). CL-plugin takes two inputs: (1) hidden states $h ^ { ( t ) }$ from the feed-forward layer inside a transformer layer and (2) task $\\textrm Ḋ \\textrm Ḋ \\textrm Ḋ \\textrm Ḋ t Ḍ Ḍ Ḍ$ , which is required by task continual learning (Task-CL). The outputs are hidden states with features suitable for the $t$ -th task for classification. Inside CL-plugin, there are two modules: (1) knowledge sharing module (KSM) for identifying and transferring the shareable knowledge from similar previous tasks to the new task $t$ , and (2) task specific module (TSM) for learning task specific neurons and their masks (which can protect the neurons from being updated by future tasks to deal with CF). Since TSM is differentiable, the whole system CTR can be trained end-to-end. ",
305
+ "bbox": [
306
+ 173,
307
+ 719,
308
+ 825,
309
+ 833
310
+ ],
311
+ "page_idx": 3
312
+ },
313
+ {
314
+ "type": "text",
315
+ "text": "4.1 Knowledge Sharing Module (KSM) ",
316
+ "text_level": 1,
317
+ "bbox": [
318
+ 176,
319
+ 856,
320
+ 459,
321
+ 872
322
+ ],
323
+ "page_idx": 3
324
+ },
325
+ {
326
+ "type": "text",
327
+ "text": "KSM achieves knowledge transfer among similar tasks via a task capsule layer (TK-Layer), a transfer capsule layer (TR-Layer), and a transfer routing mechanism. ",
328
+ "bbox": [
329
+ 174,
330
+ 883,
331
+ 821,
332
+ 911
333
+ ],
334
+ "page_idx": 3
335
+ },
336
+ {
337
+ "type": "text",
338
+ "text": "4.1.1 Task Capsule Layer (TK-Layer) ",
339
+ "text_level": 1,
340
+ "bbox": [
341
+ 174,
342
+ 90,
343
+ 449,
344
+ 106
345
+ ],
346
+ "page_idx": 4
347
+ },
348
+ {
349
+ "type": "text",
350
+ "text": "Each capsule in the TK-Layer represents a task, and it prepares the low-level features derived from each task (Figure 2(A)). As such, a capsule is added to the TK-Layer for each new task. This incremental growth is efficient and easy because these capsules are discrete and do not share parameters. Also, each capsule is simply a 2-layer fully connected network with a small number of parameters. Let $h ^ { ( t ) } \\in \\mathbb { R } ^ { d _ { t } \\times d _ { e } }$ be the input of CL-plugin, where $d _ { t }$ is the number of tokens, $d _ { e }$ the number of dimensions, and $t$ is the current task. In the TK-Layer, we have one capsule for each task. Assume we have learned $t$ tasks so far. The capsule for the $i$ -th $( i \\leq t )$ ) task is ",
351
+ "bbox": [
352
+ 173,
353
+ 114,
354
+ 826,
355
+ 213
356
+ ],
357
+ "page_idx": 4
358
+ },
359
+ {
360
+ "type": "equation",
361
+ "img_path": "images/027163c112300be8337ad4e1314aca8848ec73d453d159007a7f92f6491e98ed.jpg",
362
+ "text": "$$\np _ { i } ^ { ( t ) } = f _ { i } ( h ^ { ( t ) } ) ,\n$$",
363
+ "text_format": "latex",
364
+ "bbox": [
365
+ 446,
366
+ 218,
367
+ 550,
368
+ 239
369
+ ],
370
+ "page_idx": 4
371
+ },
372
+ {
373
+ "type": "text",
374
+ "text": "where $f _ { i } ( \\cdot ) = \\mathbf { M } \\mathbf { L } \\mathbf { P } _ { i } ( \\cdot )$ denotes a 2-layer fully-connected network. ",
375
+ "bbox": [
376
+ 173,
377
+ 242,
378
+ 609,
379
+ 258
380
+ ],
381
+ "page_idx": 4
382
+ },
383
+ {
384
+ "type": "text",
385
+ "text": "4.1.2 Transfer Routing and Transfer Capsule Layer ",
386
+ "text_level": 1,
387
+ "bbox": [
388
+ 173,
389
+ 271,
390
+ 547,
391
+ 287
392
+ ],
393
+ "page_idx": 4
394
+ },
395
+ {
396
+ "type": "text",
397
+ "text": "Each capsule in the transfer capsule layer (TR-Layer) represents the transferable representation extracted from TK-Layer. As shown in Figure 2(A), transfer routing between the lower-level capsules in TK-Layer and high-level capsules in TR-Layer has three components: pre-route vector generator $( P V G )$ , similarity estimator $( S E )$ and task router $( T R )$ . Given the task capsules in the TK-Layer, we first transform the feature through a trainable weight matrix. We call the output of this transformation the pre-route vector. Each SE estimates the similarity between a previous task and the current task using the pre-route vector, resulting in a similarity score for each higher-level capsule. Additionally, each SE is augmented by a TR module, a differentiable task router acting as a gate. This router estimates a binary signal that decides whether to connect or disconnect the current route between the two consecutive capsule layers (i.e. TK-Layer and TR-Layer in CL-plugin). The binary signal estimated by TR can be seen as a differentiable binary attention. Conceptually, each SE and TR pair together learns the connectivity between capsules in a stochastic and differentiable manner, which can be seen as a task similarity-based connectivity search mechanism. This transfer routing identifies the shared features/knowledge from multiple task capsules and helps knowledge transfer across similar tasks. Next, we discuss the pre-route vector generator, similarity estimator and task router. ",
398
+ "bbox": [
399
+ 173,
400
+ 295,
401
+ 826,
402
+ 502
403
+ ],
404
+ "page_idx": 4
405
+ },
406
+ {
407
+ "type": "text",
408
+ "text": "Pre-route Vector Generator (PVG). We first turns each transfer capsule $p _ { i } ^ { ( t ) }$ into a pre-route vector, ",
409
+ "bbox": [
410
+ 171,
411
+ 508,
412
+ 820,
413
+ 527
414
+ ],
415
+ "page_idx": 4
416
+ },
417
+ {
418
+ "type": "equation",
419
+ "img_path": "images/bc9b31c0e524f30ddf5841d154dedefe58d9c194ba1dccd69c67fdd13177b9ad.jpg",
420
+ "text": "$$\nu _ { j | i } ^ { ( t ) } = W _ { i j } p _ { i } ^ { ( t ) } ,\n$$",
421
+ "text_format": "latex",
422
+ "bbox": [
423
+ 446,
424
+ 532,
425
+ 552,
426
+ 556
427
+ ],
428
+ "page_idx": 4
429
+ },
430
+ {
431
+ "type": "text",
432
+ "text": "where $W _ { i j } \\in \\mathbb { R } ^ { d _ { s } \\times d _ { k } }$ is the weight matrix, $d _ { s }$ and $d _ { k }$ are the dimensions of task capsule $i$ (also representing a task) and transfer capsule $j$ , and $t$ is the current task. The number of transfer capsules $n _ { j }$ is a hyperparameter detailed in Sec. 5. ",
433
+ "bbox": [
434
+ 174,
435
+ 561,
436
+ 825,
437
+ 604
438
+ ],
439
+ "page_idx": 4
440
+ },
441
+ {
442
+ "type": "text",
443
+ "text": "Similarity Estimator (SE). Since tasks $i$ and $t$ are different, it is crucial to determine what in task $i$ ’s representation is transferable. Inspired by [67], we use a convolution layer and activation units to compare task $i$ with task $t$ to determine the transferable proportion from the previous task $i$ . In SE, we compute the task similarity as follows: ",
444
+ "bbox": [
445
+ 174,
446
+ 611,
447
+ 825,
448
+ 666
449
+ ],
450
+ "page_idx": 4
451
+ },
452
+ {
453
+ "type": "equation",
454
+ "img_path": "images/cd3f616aebb604c69c0699ea9b59d1fcc51b3b5084e921b2578a0774140c8e42.jpg",
455
+ "text": "$$\n\\begin{array} { r } { \\boldsymbol q _ { j | t } ^ { ( t ) } = \\mathbf { M a x P o o l } ( \\mathbf { R e l u } ( \\boldsymbol u _ { j | t } ^ { ( t ) } * W _ { q } + b _ { q } ) ) , } \\end{array}\n$$",
456
+ "text_format": "latex",
457
+ "bbox": [
458
+ 364,
459
+ 671,
460
+ 630,
461
+ 695
462
+ ],
463
+ "page_idx": 4
464
+ },
465
+ {
466
+ "type": "equation",
467
+ "img_path": "images/d3d9fe8dfc88fb9367a627fe7fad0289fe1416f50a7231ecc2ece366c7ba36d5.jpg",
468
+ "text": "$$\na _ { j | i } ^ { ( t ) } = \\mathbf { M a x P o o l } ( \\operatorname { R e l u } ( u _ { j | i } ^ { ( t ) } * W _ { a } + f _ { a } ( q _ { j | t } ^ { ( t ) } ) + b _ { a } ) ) ,\n$$",
469
+ "text_format": "latex",
470
+ "bbox": [
471
+ 328,
472
+ 698,
473
+ 668,
474
+ 719
475
+ ],
476
+ "page_idx": 4
477
+ },
478
+ {
479
+ "type": "text",
480
+ "text": "where $b _ { a } , b _ { q } \\in \\mathbb { R }$ are the bias, $W _ { a } , W _ { q } \\in \\mathbb { R } ^ { d _ { e } \\times d _ { w } }$ are convolutions filters and $d _ { w }$ is the windows size. We extract important features from the current task representation u(t)j|t via the convolution network in Eq. (3). The MaxPool helps remove the insignificant features to generate a fixed-size vector with the size equal to the number of filters $n _ { w }$ . Similarly, we extract important features from the previous task i’s representation u(t)j|i . Using the important features for the current and previous tasks, we compute a similarity score between them in Eq. (4) with ReLU activation. Note $f _ { a }$ is a 1-layer fully-connected network to match the dimensions. As a result, $a _ { j | i } ^ { ( t ) }$ indicates how similar the representation of the $i$ -th task is to the current task t. For those tasks with a very low a(t)j|i , t heir representations are less similar to the current task and thus has little transferable knowledge. ",
481
+ "bbox": [
482
+ 173,
483
+ 722,
484
+ 826,
485
+ 875
486
+ ],
487
+ "page_idx": 4
488
+ },
489
+ {
490
+ "type": "text",
491
+ "text": "Task Router (TR). TR controls which previous task representation should flow to the next layer with the goal of letting only the transferable information to flow. Given the similarity $a _ { j | i } ^ { ( t ) }$ , TR estimates a binary decision signal $\\delta _ { j \\vert t } ^ { ( t ) } \\in \\{ 0$ :disconnect, 1:connect}. We first apply a convolution layer with 2 output channels and $1 \\times 1$ kernel size to generate un-normalized decision value. To estimate the binary decision, we need to generate a decision chosen from the set of two mutually exclusive and exhaustive events (disconnect and connect). In our work, we adopt the Gumbel-Softmax [19] to help make the TR gate differentiable. ",
492
+ "bbox": [
493
+ 173,
494
+ 878,
495
+ 821,
496
+ 914
497
+ ],
498
+ "page_idx": 4
499
+ },
500
+ {
501
+ "type": "text",
502
+ "text": "",
503
+ "bbox": [
504
+ 173,
505
+ 89,
506
+ 825,
507
+ 164
508
+ ],
509
+ "page_idx": 5
510
+ },
511
+ {
512
+ "type": "equation",
513
+ "img_path": "images/3fe86212b143ae8a54d0f253740f44162ea221c52760926734b7db81c91115db.jpg",
514
+ "text": "$$\n\\delta _ { j | i } ^ { ( t ) } = \\mathrm { G u m b e l \\_ s o f t m a x } ( a _ { j | i } ^ { ( t ) } * W _ { \\delta } + b _ { \\delta } ) .\n$$",
515
+ "text_format": "latex",
516
+ "bbox": [
517
+ 361,
518
+ 167,
519
+ 637,
520
+ 190
521
+ ],
522
+ "page_idx": 5
523
+ },
524
+ {
525
+ "type": "text",
526
+ "text": "Given the similarity aj |t , binary decision δ(t )t and the pre-route vector u(t)j|t, we compute the transferable representation ${ v _ { j \\mid i } ^ { \\mathrm { t r a n } ( t ) } }$ and final output $v _ { j } ^ { ( t ) }$ as follows: ",
527
+ "bbox": [
528
+ 174,
529
+ 194,
530
+ 826,
531
+ 236
532
+ ],
533
+ "page_idx": 5
534
+ },
535
+ {
536
+ "type": "equation",
537
+ "img_path": "images/cd489fbb501b0482e7e09e48fe71db0f4ae77ff659bc952515125c7fd6c434e5.jpg",
538
+ "text": "$$\nv _ { j | i } ^ { \\mathrm { t r a n } ( t ) } = a _ { j | i } ^ { ( t ) } \\otimes u _ { j | i } ^ { ( t ) } , ~ v _ { j } ^ { ( t ) } = \\sum _ { i = 1 \\atop \\delta _ { i j } ^ { ( t ) } = 1 } ^ { n + 1 } v _ { j | i } ^ { \\mathrm { t r a n } ( t ) } .\n$$",
539
+ "text_format": "latex",
540
+ "bbox": [
541
+ 348,
542
+ 239,
543
+ 650,
544
+ 296
545
+ ],
546
+ "page_idx": 5
547
+ },
548
+ {
549
+ "type": "text",
550
+ "text": "This makes sure only task capsules for tasks that are salient or similar to the new task are used, and the others task capsules are ignored (and thus protected) to learn more general shareable knowledge. As many NLP applications have similar tasks, such learning of task-sharing features can be very important. Note that in backpropagation, only the similar tasks with connected gate $( \\delta _ { i j } ^ { ( t ) } = 1 )$ are ",
551
+ "bbox": [
552
+ 173,
553
+ 297,
554
+ 825,
555
+ 372
556
+ ],
557
+ "page_idx": 5
558
+ },
559
+ {
560
+ "type": "text",
561
+ "text": "4.2 Task Specific Module (TSM) ",
562
+ "text_level": 1,
563
+ "bbox": [
564
+ 176,
565
+ 386,
566
+ 411,
567
+ 401
568
+ ],
569
+ "page_idx": 5
570
+ },
571
+ {
572
+ "type": "text",
573
+ "text": "We now discuss how to preserve task-specific knowledge of previous tasks to prevent forgetting (CF). To achieve this, we use task masks (Figure 2(B)). Specifically, we first detect the neurons used by each old task and then block off or mask out all the used neurons when learning a new task. ",
574
+ "bbox": [
575
+ 174,
576
+ 412,
577
+ 825,
578
+ 454
579
+ ],
580
+ "page_idx": 5
581
+ },
582
+ {
583
+ "type": "text",
584
+ "text": "The task-specific module consists of differentiable layers (a 2-layer fully-connected network is used). Each layer’s output is further applied with a task mask to indicate which neurons should be protected for that task to overcome CF and forbids gradient updates for those neurons during backpropagation for a new task. Those tasks with overlapping masks indicate some parameter sharing. Due to KSM, the features flowing into those overlapping neurons enable the related old tasks to also improve in learning the new task. Here we borrow the hard attention idea in [52] and leverage the task ID embedding to train the task mask. Further details can be found in Supplementary. ",
585
+ "bbox": [
586
+ 174,
587
+ 460,
588
+ 825,
589
+ 558
590
+ ],
591
+ "page_idx": 5
592
+ },
593
+ {
594
+ "type": "text",
595
+ "text": "Illustration. The task masking process is illustrated in Figure 2(B), which shows the learning process of three tasks. Before training, those solid cells with a 0 are the neurons that have been used by some previous tasks and should be protected (masked). Those empty cells are free neurons (not used). After training, those solid cells with a 1 are neurons that are important for the current task, which will be used as masks in the future. Those solid cells with a 0 are masked as they are important for previous tasks. Those non-solid cells with a 0 are neurons that are not used so far. ",
596
+ "bbox": [
597
+ 173,
598
+ 564,
599
+ 825,
600
+ 647
601
+ ],
602
+ "page_idx": 5
603
+ },
604
+ {
605
+ "type": "text",
606
+ "text": "Let us walk through the learning process of the three tasks. After training task 0, we obtain its useful neurons indicated by the 1 entries. Before training task 1, those useful neurons for task 0 are first masked (those previous 1’s entries are turned to 0’s). After training task 1, two neurons with 1 are used by the task. When task 2 arrives, all used neurons by tasks 0 and 1 are masked before training, i.e., their entries are set to 0. After training task 2, we see that tasks 2 and 1 have a shared neuron (the cell with two colors, red and green), which is used by both of tasks. ",
607
+ "bbox": [
608
+ 174,
609
+ 654,
610
+ 825,
611
+ 737
612
+ ],
613
+ "page_idx": 5
614
+ },
615
+ {
616
+ "type": "text",
617
+ "text": "5 Experiments ",
618
+ "text_level": 1,
619
+ "bbox": [
620
+ 174,
621
+ 756,
622
+ 312,
623
+ 773
624
+ ],
625
+ "page_idx": 5
626
+ },
627
+ {
628
+ "type": "text",
629
+ "text": "We evaluate CTR using three applications. We follow the continual learning (CL) evaluation method given in [29]. CTR first learns a sequence of tasks. After a task is trained, the training data of the task is no longer accessible. After all tasks are learned, their task models are tested using their respective test sets. In training each task, we use its validation set to decide when to stop training. ",
630
+ "bbox": [
631
+ 174,
632
+ 786,
633
+ 825,
634
+ 842
635
+ ],
636
+ "page_idx": 5
637
+ },
638
+ {
639
+ "type": "text",
640
+ "text": "5.1 Three Applications and Their Datasets ",
641
+ "text_level": 1,
642
+ "bbox": [
643
+ 174,
644
+ 857,
645
+ 482,
646
+ 872
647
+ ],
648
+ "page_idx": 5
649
+ },
650
+ {
651
+ "type": "text",
652
+ "text": "The first two applications (and datasets) are used to show the knowledge transferability of CTR because their tasks are similar and have shared knowledge. Catastrophic forgetting (CF) is not a major concern for them. The third application (and dataset) is mainly used to test CTR’s ability to overcome CF as its tasks are very different and have little shared knowledge to transfer. ",
653
+ "bbox": [
654
+ 176,
655
+ 883,
656
+ 821,
657
+ 911
658
+ ],
659
+ "page_idx": 5
660
+ },
661
+ {
662
+ "type": "table",
663
+ "img_path": "images/25f44c4519c6e6f25f1beb8d19fd569f1ce4157013bb1104d15162bf75f7c97a.jpg",
664
+ "table_caption": [],
665
+ "table_footnote": [
666
+ "Table 1: Statistics of datasets for ASC. The datasets statistics for DSC and 20News have been described in the text. More detailed data statistics are given in Supplementary. "
667
+ ],
668
+ "table_body": "<table><tr><td>Data source</td><td colspan=\"3\">Liu3domain</td><td colspan=\"5\">HL5domain</td><td colspan=\"10\">Ding9domain</td></tr><tr><td>Task/</td><td>paede</td><td>Poener</td><td>Ccoindetr</td><td>NO990T90</td><td>NN14am00</td><td>Ceieea</td><td>Conoees</td><td>AAx2dA</td><td>Capoong0</td><td>Craonen</td><td>radera</td><td>Thah</td><td></td><td>srss</td><td>JITIIT5</td><td>NO994P00</td><td>UOJION</td><td>Jreererer</td><td>doider</td></tr><tr><td>Train</td><td>352</td><td>245</td><td>283</td><td>271</td><td>162</td><td>677</td><td>228</td><td>343</td><td>118</td><td>175</td><td>191</td><td>212</td><td>153</td><td>176</td><td>484</td><td>362</td><td>194</td><td>3452</td><td>2163</td></tr><tr><td>Val.</td><td>44</td><td>31</td><td>35</td><td>34</td><td>20</td><td>85</td><td>29</td><td>43</td><td>15</td><td>22</td><td>24</td><td>26</td><td>19</td><td>22</td><td>61</td><td>45</td><td>24</td><td>150</td><td>150</td></tr><tr><td>Test</td><td>44</td><td>31</td><td>36</td><td>34</td><td>21</td><td>85</td><td>29</td><td>43</td><td>15</td><td>22</td><td>24</td><td>27</td><td>20</td><td>23</td><td>61</td><td>46</td><td>25</td><td>1120</td><td>638</td></tr></table>",
669
+ "bbox": [
670
+ 176,
671
+ 90,
672
+ 821,
673
+ 199
674
+ ],
675
+ "page_idx": 6
676
+ },
677
+ {
678
+ "type": "text",
679
+ "text": "",
680
+ "bbox": [
681
+ 173,
682
+ 241,
683
+ 821,
684
+ 268
685
+ ],
686
+ "page_idx": 6
687
+ },
688
+ {
689
+ "type": "text",
690
+ "text": "1. Document Sentiment Classification (DSC). This application is to classify each full product review into one of the two opinion classes (positive and negative). The training data of each task consists of reviews of a particular type of product. We adopt the text classification formulation in [8], where a [CLS] token is used to predict the opinion polarity. ",
691
+ "bbox": [
692
+ 173,
693
+ 275,
694
+ 825,
695
+ 330
696
+ ],
697
+ "page_idx": 6
698
+ },
699
+ {
700
+ "type": "text",
701
+ "text": "We employ a set of 10 DSC datasets (reviews of 10 products) to produce sequences of tasks. The products are Sports, Toys, Tools, Video, Pet, Musical, Movies, Garden, Offices, and Kindle [22]. Two experiments are conducted: (1) using small data in each task: 100 positive and 100 negative training reviews per task; (2) using the full data in each task: 2500 positive and 2500 negative training reviews per task [22]. (1) is more useful in practice because labeling a large number of examples is very costly. The same validation reviews (250 positive and 250 negative) and the same test reviews (250 positive and 250 negative) are used in both experiments. ",
702
+ "bbox": [
703
+ 174,
704
+ 337,
705
+ 825,
706
+ 434
707
+ ],
708
+ "page_idx": 6
709
+ },
710
+ {
711
+ "type": "text",
712
+ "text": "2. Aspect Sentiment Classification (ASC). It classifies a review sentence on the aspect-level sentiment (one of positive, negative, and neutral). For example, the sentence “The picture is great but the sound is lousy” about a TV expresses a positive opinion about the aspect “picture” and a negative opinion about the aspect “sound.” We adopt the ASC formulation in [65], where the aspect term and sentence are concatenated via [SEP] in BERT. The opinion is predicted on top of the [CLS] token. ",
713
+ "bbox": [
714
+ 174,
715
+ 440,
716
+ 825,
717
+ 510
718
+ ],
719
+ "page_idx": 6
720
+ },
721
+ {
722
+ "type": "text",
723
+ "text": "We employ a set of 19 ASC datasets (review sentences of 19 products) to produce sequences of tasks. Each dataset represents a task. The datasets are from 4 sources: (1) HL5Domains [17] with reviews of 5 products; (2) Liu3Domains [32] with reviews of 3 products; (3) Ding9Domains [9] with reviews of 9 products; and (4) SemEval14 with reviews of 2 products - SemEval 2014 Task 4 for laptop and restaurant. For (1), (2) and (3), we use about $10 \\%$ of the original data as the validate data, another about $10 \\%$ of the original data as the testing data. For (4), we use 150 examples from the training set for validation. To be consistent with existing research [59], sentences with conflict opinions about a single aspect are not used. Statistics of the 19 datasets are given in Table 1. ",
724
+ "bbox": [
725
+ 173,
726
+ 516,
727
+ 825,
728
+ 627
729
+ ],
730
+ "page_idx": 6
731
+ },
732
+ {
733
+ "type": "text",
734
+ "text": "3. Text classification using 20News data. This dataset [28] has 20 classes and each class has about 1000 documents. The data split for train/validation/test is 1600/200/200. We created 10 tasks, 2 classes per task. Since this is topic-based text classification data, the classes are very different and have little shared knowledge. As mentioned above, this application (and dataset) is mainly used to show CTR’s ability to overcome forgetting. ",
735
+ "bbox": [
736
+ 174,
737
+ 633,
738
+ 823,
739
+ 703
740
+ ],
741
+ "page_idx": 6
742
+ },
743
+ {
744
+ "type": "text",
745
+ "text": "5.2 Baselines ",
746
+ "text_level": 1,
747
+ "bbox": [
748
+ 174,
749
+ 719,
750
+ 277,
751
+ 733
752
+ ],
753
+ "page_idx": 6
754
+ },
755
+ {
756
+ "type": "text",
757
+ "text": "We setup 38 baselines, including both standalone and continual learning methods. ",
758
+ "bbox": [
759
+ 176,
760
+ 746,
761
+ 710,
762
+ 760
763
+ ],
764
+ "page_idx": 6
765
+ },
766
+ {
767
+ "type": "text",
768
+ "text": "Multitask learning (MTL: Results of multitask learning is considered the upper-bound of those of continual learning. Here MTL fine-tunes BERT. ",
769
+ "bbox": [
770
+ 173,
771
+ 766,
772
+ 821,
773
+ 794
774
+ ],
775
+ "page_idx": 6
776
+ },
777
+ {
778
+ "type": "text",
779
+ "text": "Standalone (SDL) Baselines: The SDL setting builds a model for each task independently using a separate network. It clearly has no knowledge transfer or forgetting. We have 4 baselines under SDL, BERT, BERT (Frozen), Adapter-BERT and W2V (word2vec embeddings). For BERT, we use trainable BERT, i.e., fine-tuning. BERT (Frozen) uses frozen BERT with a trainable CNN text classification network [26] on top of it.; Adapter-BERT adapts the BERT as in [16], where only the adapter blocks are trainable; W2V uses embeddings trained on the Amazon review data in [66] using FastText [11]. For ASC, we adopt the ASC classification network in [67], which takes aspect term and review sentence as input. For DSC and 20News, we adopt the classification network in [8]. ",
780
+ "bbox": [
781
+ 174,
782
+ 800,
783
+ 825,
784
+ 911
785
+ ],
786
+ "page_idx": 6
787
+ },
788
+ {
789
+ "type": "text",
790
+ "text": "Continual Learning (CL) Baselines. CL setting includes 4 baselines with no forgetting handling (NFH) (corresponding to the 4 standalone baselines), and 25 baselines from 9 state-of-the art task continual learning (Task-CL) methods that deal with forgetting (CF). NFH baselines learn the tasks one by one with no awareness of forgetting/transfer. ",
791
+ "bbox": [
792
+ 174,
793
+ 90,
794
+ 825,
795
+ 147
796
+ ],
797
+ "page_idx": 7
798
+ },
799
+ {
800
+ "type": "text",
801
+ "text": "The 12 state-of-the-art CL systems are: KAN [22] and SRK [37] are Task-CL methods for document sentiment classification. The rest were designed initially for image classification. Therefore, we replace their original MLP or CNN image classification network with CNN for text classification [26]. HAT [52] is one of the best Task-CL methods with almost no forgetting. CAT [21] is similar to HAT but can work with a mixed sequence. UCL [1] is a recent Task-CL method. EWC [27] is a popular regularization-based class continual learning (Class-CL) method, which was adapted for Task-CL by only training on the corresponding head of the specific task ID during training and only considering the corresponding head’s prediction during testing. OWM [68] is also a Class-CL method, which we also adapt to Task-CL. L2 [27] is a classic regularization based Class-CL method, which we adapt to Task-CL. A-GEM [4] is an efficient version of the replay Task-CL method GEM [36], which penalizes the previous task loss from being increased. $\\mathbf { D E R + + }$ [2] is a recent replay method using distillation to regularize the new task training and it can function as a Task-CL method. B-CL [24] is similar to CTR but uses dynamic routing for knowledge transfer and it performs markedly worse than CTR. LAMOL [58] is a pseudo-replay method based on GPT-2. ",
802
+ "bbox": [
803
+ 173,
804
+ 154,
805
+ 825,
806
+ 347
807
+ ],
808
+ "page_idx": 7
809
+ },
810
+ {
811
+ "type": "text",
812
+ "text": "From the 10 systems, we created 10 baselines using W2V embeddings with the aspect term added before the sentence so that the Task-CL methods can take both aspect and the review sentence for ASC; 7 baselines using Adapter-BERT (SRK, KAN and CAT’s architectures cannot work with adapters); and 10 baselines using BERT (Frozen) (which replaces W2V embeddings). The BERT formulation in Sec. 3 naturally takes both aspect and review sentence in the ASC case. ",
813
+ "bbox": [
814
+ 174,
815
+ 353,
816
+ 825,
817
+ 422
818
+ ],
819
+ "page_idx": 7
820
+ },
821
+ {
822
+ "type": "text",
823
+ "text": "5.3 Hyper-parameters ",
824
+ "text_level": 1,
825
+ "bbox": [
826
+ 174,
827
+ 439,
828
+ 341,
829
+ 454
830
+ ],
831
+ "page_idx": 7
832
+ },
833
+ {
834
+ "type": "text",
835
+ "text": "Unless otherwise stated, the same hyper-parameters are used in experiments for ASC, DSC and 20News datasets. For the knowledge sharing module (KSM), we employ 2 layers of fully connected network with dimensions 768 in the TK-Layer. We employ 3 transfer capsules. We experimented with 2 to 15 capsules and selected 3 based on the validation data accuracy. For the task specific module (TSM), we use 2000 dimensions as the final and the hidden layers of the TSM. The task ID embeddings have 2000 dimensions. A fully connected layer with softmax output is used as the classification heads in the last layer of the BERT, together with the categorical cross-entropy loss. dropout of 0.5 between fully connected layers. The training of BERT, Adapter-BERT and CTR follows that of [65]. We adopt BERTBASE (uncased). The maximum input length is set to 128 which is long enough for both ASC and DSC. We use Adam optimizer and set the learning rate to 3e-5. We use 10 epochs for SemEval datasets and 30 epochs for the other datasets in the ASC application. For DSC, we use 20 epochs. For 20News, we use 10 epochs. These are selected based on the validation results. The batch size is set to 32 for all cases. For all the other CL baselines, we use the code provided by their authors and adapt them for text classification. We also adopt their original parameters, including learning rate, early stopping, and batch size. ",
836
+ "bbox": [
837
+ 174,
838
+ 465,
839
+ 825,
840
+ 672
841
+ ],
842
+ "page_idx": 7
843
+ },
844
+ {
845
+ "type": "text",
846
+ "text": "5.4 Evaluation Results and Analysis ",
847
+ "text_level": 1,
848
+ "bbox": [
849
+ 176,
850
+ 685,
851
+ 436,
852
+ 700
853
+ ],
854
+ "page_idx": 7
855
+ },
856
+ {
857
+ "type": "text",
858
+ "text": "Since the order of the tasks in a sequence may impact the final results, we randomly sampled 5 task sequences and averaged their results. We compute both accuracy and Macro-F1, where Macro-F1 is the primary metric as the imbalanced classes (in ASC) introduce biases on accuracy. Table 2 gives the average results of all the 19 tasks (or datasets) for ASC and 10 tasks (or datasets) for DSC and 20News over the 5 random task sequences. ",
859
+ "bbox": [
860
+ 174,
861
+ 710,
862
+ 825,
863
+ 780
864
+ ],
865
+ "page_idx": 7
866
+ },
867
+ {
868
+ "type": "text",
869
+ "text": "Overall Performance. Table 2 shows that CTR clearly outperforms all baselines. ",
870
+ "bbox": [
871
+ 173,
872
+ 786,
873
+ 709,
874
+ 801
875
+ ],
876
+ "page_idx": 7
877
+ },
878
+ {
879
+ "type": "text",
880
+ "text": "(1). For the standalone (SDL) baselines, BERT (with fine-tuning) and Adapter-BERT perform similarly. W2V and BERT (Frozen) are poorer, which is understandable. ",
881
+ "bbox": [
882
+ 173,
883
+ 806,
884
+ 818,
885
+ 835
886
+ ],
887
+ "page_idx": 7
888
+ },
889
+ {
890
+ "type": "text",
891
+ "text": "(2). Comparing SDL (standalone learning) and NFH (continual learning with no forgetting handling), we see NFH is much better than SDL for W2V and BERT (Frozen). This indicates ASC and DSC tasks have similarities and thus shared knowledge. Catastrophic forgetting (CF) is not a major issue for W2V and BERT (Frozen). However, for 20News, NFH variants have serious CF. NFH with BERT (fine-tuning) is much worse than SDL and Adapter-BERT, which we explained in Introduction. ",
892
+ "bbox": [
893
+ 174,
894
+ 842,
895
+ 825,
896
+ 911
897
+ ],
898
+ "page_idx": 7
899
+ },
900
+ {
901
+ "type": "table",
902
+ "img_path": "images/464fea620046cf57c3d4c52305b3d6a41751054f6ca4bd06403c2233bf3d8d32.jpg",
903
+ "table_caption": [],
904
+ "table_footnote": [
905
+ "Table 2: Accuracy (Acc.) and Macro-F1 (MF1), averaged over 5 random sequences. The architectures of SRK, KAN and CAT cannot work with Adapter-BERT. “—” means not applicable. Due to the limited space, standard deviation, running time and network size are given in Supplementary. "
906
+ ],
907
+ "table_body": "<table><tr><td rowspan=\"2\">Scenarios</td><td rowspan=\"2\">Category</td><td rowspan=\"2\">Model</td><td colspan=\"2\">ASC</td><td colspan=\"2\">DSC (small)</td><td colspan=\"2\">DSC (full)</td><td colspan=\"2\">20News</td><td colspan=\"2\">20News (FR)</td></tr><tr><td>Acc.</td><td>MF1</td><td>Acc.</td><td>MF1</td><td>Acc.</td><td>MF1</td><td>Acc.</td><td>MF1</td><td>Acc.</td><td>MF1</td></tr><tr><td rowspan=\"2\">Non-continual Learning (SDL)</td><td>BERT BERT BERT (Frozen)</td><td>MTL SDL SDL</td><td>91.91 85.84 78.14</td><td>88.11 76.35 58.13</td><td>85.05 78.04 73.88</td><td>84.03 74.17</td><td>89.77 87.84</td><td>89.28 86.80</td><td>96.77 96.49</td><td>96.77 96.48</td><td></td><td></td></tr><tr><td>Adapter-BERT W2V BERT</td><td>SDL SDL NFH</td><td>85.96 77.01 49.60</td><td>78.07 51.89 43.08</td><td>76.31 62.06 73.87</td><td>67.97 71.04 53.80 69.44</td><td>85.34 88.30 69.57 73.08</td><td>80.17 87.31 65.51 71.81</td><td>96.49 96.20 94.72 52.50</td><td>96.48 96.19 94.72 39.22</td><td>24.29</td><td>30.52</td></tr><tr><td rowspan=\"10\">Continual Learning (CL)</td><td>BERT (Frozen) Adapter-BERT W2V</td><td>NFH NFH NFH L2</td><td>85.51 54.03 82.69</td><td>76.64 44.81 73.56</td><td>83.12 63.76 65.16</td><td>79.23 53.95 57.48</td><td>61.88 64.94 70.40</td><td>45.79 63.40 68.03</td><td>83.28 68.29</td><td>81.81 61.70</td><td>8.76 30.59 4.30</td><td>9.73 3.79 4.47</td></tr><tr><td rowspan=\"5\">BERT (frozen)</td><td rowspan=\"5\">A-GEM DER++ KAN</td><td rowspan=\"5\">56.04 86.06 84.27 85.49</td><td rowspan=\"5\">38.40 78.44 75.08</td><td rowspan=\"5\">59.17 59.33 72.29</td><td rowspan=\"5\">48.39 45.94</td><td rowspan=\"5\">69.80 70.67 86.70</td><td rowspan=\"5\">62.63 61.77 85.46</td><td rowspan=\"5\">90.74 72.14 93.31</td><td rowspan=\"5\">90.59</td><td rowspan=\"5\">24.57 4.09</td><td rowspan=\"5\">32.05 4.48</td></tr><tr><td></td></tr><tr><td></td></tr><tr><td>65.39</td></tr><tr><td>92.95</td></tr><tr><td>66.28</td></tr><tr><td colspan=\"10\"></td><td>49.67</td><td>10.54</td><td>12.16</td></tr><tr><td rowspan=\"6\"></td><td rowspan=\"6\"></td><td>SRK EWC</td><td>84.76 86.37</td><td>77.38 78.52 74.52</td><td>77.27 78.58 82.38</td><td>72.34 76.03</td><td>82.32 83.99</td><td>81.23</td><td>73.07 69.97 77.89</td><td></td><td>15.52 12.06</td><td>18.87 13.97 3.03</td></tr><tr><td>UCL</td><td>83.89</td><td></td><td>78.41</td><td>72.77 74.76</td><td>82.66 65.76 69.48</td><td>79.64 80.26 94.65</td><td>78.60</td><td>3.50</td><td>0.48</td></tr><tr><td></td><td></td><td>74.82</td><td>74.13</td><td></td><td></td><td></td><td>94.63</td><td>0.48</td><td></td></tr><tr><td>OWM HAT</td><td>87.02</td><td>79.31</td><td>80.12 58.07</td><td>42.63</td><td>86.30</td><td>85.36</td><td>84.54</td><td>82.73</td><td>13.80</td></tr><tr><td>CAT</td><td>86.74 83.68</td><td>78.16</td><td>79.48</td><td>72.78</td><td></td><td></td><td></td><td></td><td>15.81 2.89</td></tr><tr><td></td><td>63.97</td><td>68.64 52.43</td><td>67.41</td><td>56.22</td><td>87.29 87.34</td><td>86.14 86.51</td><td>93.51 95.17</td><td>92.93 95.16</td><td>2.26 0.80</td></tr><tr><td rowspan=\"4\"></td><td rowspan=\"4\">Adapter-BERT</td><td>L2</td><td></td><td>67.26</td><td>62.76</td><td>73.03</td><td>71.50</td><td>69.56</td><td>65.50</td><td>23.12</td><td>0.81 27.39</td></tr><tr><td>A-GEM</td><td>45.88 47.63</td><td>28.21 62.89</td><td>55.96</td><td>71.22</td><td>69.94</td><td>60.29</td><td>50.40</td><td>40.22</td><td>51.20</td></tr><tr><td>DER++ EWC</td><td>56.30</td><td>35.54 49.58</td><td>70.52 63.56</td><td>59.67</td><td>57.82</td><td>58.95</td><td>49.58</td><td>36.39</td><td>45.30</td></tr><tr><td>UCL OWM</td><td>64.46 72.99</td><td>58.23 36.64 48.30</td><td>51.03 32.07</td><td>62.69 57.06</td><td>61.51 55.86</td><td>61.86 51.75</td><td>53.94 36.06</td><td>37.79 4.70</td><td>46.58 6.60</td></tr><tr><td rowspan=\"4\">W2V</td><td rowspan=\"4\">HAT L2 KAN</td><td>86.14 60.36</td><td>66.51</td><td>73.97 80.83</td><td>71.96 78.41</td><td>85.46</td><td>84.57</td><td>71.10</td><td>66.25 95.21</td><td>27.38 0.33</td><td>32.76 0.34</td></tr><tr><td>81.33</td><td>78.52 39.13 63.35</td><td>54.34</td><td>43.19</td><td>88.00 57.71</td><td>87.26 48.00</td><td>95.22 59.54</td><td>54.40</td><td>7.83</td><td>11.89</td></tr><tr><td>A-GEM DER++</td><td>69.93</td><td>69.80</td><td>60.07</td><td>77.67</td><td>70.75</td><td>90.72</td><td>90.60</td><td>3.94</td><td>4.08</td></tr><tr><td>SRK</td><td>83.27 40.01</td><td>77.51 57.13 64.47</td><td>73.13 43.75</td><td>74.79</td><td>66.68</td><td>89.28</td><td>89.19</td><td>4.32</td><td>4.42</td></tr><tr><td rowspan=\"6\"></td><td rowspan=\"5\">HAT CAT</td><td rowspan=\"5\">EWC UCL OWM</td><td>72.06 71.01 84.16</td><td></td><td>55.93</td><td>69.35</td><td>64.78</td><td>57.92</td><td>51.65</td><td>20.98</td><td>27.02 8.81</td></tr><tr><td></td><td>39.63</td><td></td><td>69.65</td><td>65.25</td><td>61.07</td><td>58.47</td><td>7.26</td><td></td></tr><tr><td></td><td>72.29</td><td>64.82</td><td>57.20 70.00</td><td>65.11</td><td>91.86</td><td>91.80</td><td>2.64</td><td>2.71 4.70</td></tr><tr><td>84.41 82.70</td><td>75.99</td><td>56.23</td><td>41.34</td><td>70.56</td><td>67.01</td><td>90.61</td><td>90.46</td><td>4.53</td></tr><tr><td></td><td>71.18</td><td>53.40</td><td>38.44</td><td>67.15</td><td>65.42</td><td>71.97</td><td>68.75</td><td>24.00</td></tr><tr><td colspan=\"2\">B-CL LAMOL</td><td>80.83 76.28 88.29 88.91</td><td>63.63 54.65</td><td>62.57 55.19</td><td>50.83 35.28</td><td>69.75 79.58</td><td>65.44 75.99</td><td>67.73 70.38</td><td>64.43 68.04</td><td>26.04 24.37</td><td>27.56 29.70 26.95</td></tr><tr><td colspan=\"2\"></td><td></td><td>81.40</td><td>82.01</td><td>80.63</td><td>79.76</td><td>76.51</td><td>95.07</td><td>95.04</td><td></td><td></td><td>0.59</td></tr><tr><td colspan=\"2\">CTR(forward) CTR</td><td>87.89 89.47</td><td>80.59 80.25</td><td>89.12 83.75</td><td>86.58 82.55</td><td></td><td>92.11 89.86</td><td>91.72 89.16 95.63</td><td>66.13</td><td>45.74 95.62</td><td>0.58 20.03</td><td>16.60</td></tr></table>",
908
+ "bbox": [
909
+ 181,
910
+ 90,
911
+ 823,
912
+ 516
913
+ ],
914
+ "page_idx": 8
915
+ },
916
+ {
917
+ "type": "text",
918
+ "text": "(3). Unlike BERT and Adapter-BERT, CTR does very well in both forgetting avoidance and knowledge transfer (outperforming all baselines). For baselines, EWC, UCL, OWM and HAT, although they perform better than NFH, they are significantly poorer than CTR as they don’t have methods to encourage knowledge transfer for ASC and DSC. KAN and SRK do knowledge transfer but they are weaker than many other CL methods. They perform very poorly for 20News as they have limited ability to overcome CF. CAT works well with large datasets, but is weak for small datasets. ",
919
+ "bbox": [
920
+ 173,
921
+ 573,
922
+ 825,
923
+ 656
924
+ ],
925
+ "page_idx": 8
926
+ },
927
+ {
928
+ "type": "text",
929
+ "text": "(4). CTR’s improvements over SDL variants for DSC (large) is less than for DCS (small). This is understandable because when the training data is large, learning a separate model is already good, and knowledge transfer is less important. ",
930
+ "bbox": [
931
+ 174,
932
+ 662,
933
+ 825,
934
+ 704
935
+ ],
936
+ "page_idx": 8
937
+ },
938
+ {
939
+ "type": "text",
940
+ "text": "(5). Compared with the SDL results, we can see that CTR has the least forgetting on 20News. ",
941
+ "bbox": [
942
+ 173,
943
+ 710,
944
+ 785,
945
+ 726
946
+ ],
947
+ "page_idx": 8
948
+ },
949
+ {
950
+ "type": "text",
951
+ "text": "(6). Compared to B-CL, CTR is markedly better in knowledge transfer. The forgetting rates (FR) of B-CL and CTR are both low. The comparison is in fact the same as comparing dynamics routing and transfer routing. We can see that the proposed transfer routing is dramatically better than dynamic routing for knowledge transfer. Additionally, transfer routing eliminates the need for hyper-parameter tuning on the number of iterations of dynamic routing [50] to update the agreements. ",
952
+ "bbox": [
953
+ 174,
954
+ 731,
955
+ 825,
956
+ 801
957
+ ],
958
+ "page_idx": 8
959
+ },
960
+ {
961
+ "type": "text",
962
+ "text": "(7). CTR outperforms LAMOL in ASC and 20News even with the less powerful BERT model that CTR adopts. LAMOL outperforms BERT-based MTL in DSC. This may be because LAMOL is based on GPT-2, which is known to be more powerful than BERT (also shown in the LAMOL paper). For 20News, since its tasks are very different/dissimilar, there is little shared knowledge. Dealing with CF is the main issue. LAMOL has serious forgetting as its FR values show. ",
963
+ "bbox": [
964
+ 174,
965
+ 806,
966
+ 825,
967
+ 877
968
+ ],
969
+ "page_idx": 8
970
+ },
971
+ {
972
+ "type": "text",
973
+ "text": "(8). The results of MTL (the upper bound) are only slightly better than CTR, which again shows that CTR is highly effective in overcoming forgetting and encouraging knowledge transfer. ",
974
+ "bbox": [
975
+ 171,
976
+ 883,
977
+ 821,
978
+ 911
979
+ ],
980
+ "page_idx": 8
981
+ },
982
+ {
983
+ "type": "table",
984
+ "img_path": "images/2860d63fe9cb8a606639c284ca2989d0e80d76cf5e3d7c432db4102290f3501e.jpg",
985
+ "table_caption": [],
986
+ "table_footnote": [
987
+ "Table 3: Ablation experiment results. "
988
+ ],
989
+ "table_body": "<table><tr><td rowspan=\"2\">Model</td><td colspan=\"2\">ASC</td><td colspan=\"2\">DSC (small)</td><td colspan=\"2\">DSC (full)</td><td colspan=\"2\">20News</td></tr><tr><td>Acc.</td><td>MF1</td><td>Acc.</td><td>MF1</td><td>Acc.</td><td>MF1</td><td>Acc.</td><td>MF1</td></tr><tr><td>CTR(-KSM;-TSM)</td><td>0.5403</td><td>0.4481</td><td>0.6376</td><td>0.5395</td><td>0.6494</td><td>0.6340</td><td>0.6829</td><td>0.6170</td></tr><tr><td>CTR (-TSM)</td><td>0.8312</td><td>0.7107</td><td>0.7085</td><td>0.6759</td><td>0.8545</td><td>0.8380</td><td>0.8275</td><td>0.8064</td></tr><tr><td>CTR (-KSM)</td><td>0.8614</td><td>0.7852</td><td>0.8083</td><td>0.7841</td><td>0.8800</td><td>0.8726</td><td>0.9522</td><td>0.9521</td></tr><tr><td>CTR(-TR/KSM)</td><td>0.8819</td><td>0.8155</td><td>0.8244</td><td>0.8119</td><td>0.8831</td><td>0.8762</td><td>0.9476</td><td>0.9469</td></tr><tr><td>CTR(dynamic routing) (B-CL)</td><td>0.8829</td><td>0.8140</td><td>0.8201</td><td>0.8063</td><td>0.7976</td><td>0.7651</td><td>0.9507</td><td>0.9504</td></tr><tr><td>CTR (on top)</td><td>0.8135</td><td>0.6390</td><td>0.7301</td><td>0.6875</td><td>0.8266</td><td>0.8105</td><td>0.8927</td><td>0.8920</td></tr><tr><td>CTR (after the first FF layer)</td><td>0.8741</td><td>0.8014</td><td>0.8300</td><td>0.8183</td><td>0.8699</td><td>0.8596</td><td>0.9381</td><td>0.9373</td></tr><tr><td>CTR (after the other two FF layers)</td><td>0.8662</td><td>0.7863</td><td>0.8269</td><td>0.8161</td><td>0.8714</td><td>0.8612</td><td>0.9339</td><td>0.9316</td></tr><tr><td>CTR</td><td>0.8947</td><td>0.8362</td><td>0.8434</td><td>0.8329</td><td>0.8931</td><td>0.8875</td><td>0.9525</td><td>0.9523</td></tr></table>",
990
+ "bbox": [
991
+ 209,
992
+ 90,
993
+ 789,
994
+ 210
995
+ ],
996
+ "page_idx": 9
997
+ },
998
+ {
999
+ "type": "text",
1000
+ "text": "Effectiveness of Knowledge Transfer. Forward transfer is defined as the forward performance (CTR(forward) in Table 2) subtracting the standalone (SDL) result. CTR(forward) is the test accuracy or MF1 of each task when it was first learned. Backward transfer is defined as the difference between the backward performance (CTR in Table 2, the final result after all tasks are learned) and the forward performance. The average results of CTR (forward) and CTR are given in Table 2. We observe that forward transfer of CTR is highly effective for the three datasets with similar tasks. For DSC, the less the data, the more effective is the transfer, which is reasonable. Backward transfer improves the accuracy and MF1 of ASC and DSC (small). For DSC (full), it is slightly weaker and for 20News, it is also slightly weaker due to a very small amount of forgetting, but the less than 0.0055 CF is negligible. Note that in [36, 46], forward transfer is measured by comparing the test results of the new task on the current learned network and a random initialized network before/without training the new task (like zero-shot). This method indicates whether the learned network contains some useful knowledge for the new task. However, it does not tell how much forward transfer actually happens after learning the new task, which is more important and is what our method measures. ",
1001
+ "bbox": [
1002
+ 173,
1003
+ 244,
1004
+ 825,
1005
+ 438
1006
+ ],
1007
+ "page_idx": 9
1008
+ },
1009
+ {
1010
+ "type": "text",
1011
+ "text": "Overcoming Forgetting. To validate CTR’s effectiveness in dealing forgetting with a sequence of dissimilar tasks, we compute the Forgetting Rate [34], $\\begin{array} { r } { \\mathrm { F R } = \\frac { 1 } { t - 1 } \\bar { \\sum _ { i = 1 } ^ { t - 1 } A _ { i , i } } - \\bar { A _ { t , i } } } \\end{array}$ , where $A _ { i , i }$ is the forward accuracy of task $i$ and $A _ { t , i }$ is the accuracy of task $i$ after training the last task $t$ . We average over all tasks except the last one because the last task obviously has no forgetting. We report the forgetting rate FR (averaged over 5 random task sequences) for the 20News data on the two evaluation metrics in the last two columns of Table 2 (the other two datasets are mainly for knowledge transfer). CTR has very low FR values which indicate very little forgetting. ",
1012
+ "bbox": [
1013
+ 173,
1014
+ 444,
1015
+ 825,
1016
+ 545
1017
+ ],
1018
+ "page_idx": 9
1019
+ },
1020
+ {
1021
+ "type": "text",
1022
+ "text": "Ablation Study. The results of ablation experiments are in Table 3. “-KSM;-TSM” means that the knowledge sharing module (KSM) and the task specific module (TSM) are not used, and we simply deploy the Adapter-BERT. “-KSM” means that the knowledge sharing module (KSM) is not used. “-TSM” means that the task specific module (TSM) is not used. “-TR/KSM” means that the task router (TR) in KSM is not used. We directly send the transferable representation vtran(j|i to the next layer. “dynamic routing” means that we replace our transfer routing (-(SE&TR)/KSM) with dynamic routing [50], which is one of the most popular routing algorithms in capsule networks. “on top” means adding a CL-plugin on top of BERT. “after the first FF layer” means adding only one CL-plugin there in BERT. ”after the other two FF layers” means adding only one CL-plugin module there in BERT. Table 3 shows that the full CTR system gives the best results, indicating every component contributes to the model and other options of adding CL-plugins are all poorer. ",
1023
+ "bbox": [
1024
+ 173,
1025
+ 549,
1026
+ 825,
1027
+ 709
1028
+ ],
1029
+ "page_idx": 9
1030
+ },
1031
+ {
1032
+ "type": "text",
1033
+ "text": "6 Conclusion ",
1034
+ "text_level": 1,
1035
+ "bbox": [
1036
+ 174,
1037
+ 728,
1038
+ 299,
1039
+ 744
1040
+ ],
1041
+ "page_idx": 9
1042
+ },
1043
+ {
1044
+ "type": "text",
1045
+ "text": "This paper studied task continual learning (Task-CL) using the pre-trained model BERT to achieve both CF presentation and knowledge transfer. It proposed a novel technique called CTR to leverage the pre-trained BERT for CL. The key component of CTR is the CL-plugin inserted in BERT. A CL-plugin is a capsule network with a new transfer routing mechanism to encourage knowledge transfer among tasks and also to isolate task-specific knowledge to avoid forgetting. Experimental results using three NLP applications showed that CTR markedly improves the performance of both the new task and the old tasks via knowledge transfer and is also effective at overcoming catastrophic forgetting. One limitation of our work is the efficiency due to the use of capsules. Capsules try to represent a group of neurons in a vector reflecting properties of an entity. In NLP, an entity is a sentence/document which contains many tokens (e.g., 128) and features (e.g. 768 in BERTBASE). Grouping them makes the capsule very large (e.g., $1 2 8 \\times 7 6 8 $ ), which slows down training. ",
1046
+ "bbox": [
1047
+ 173,
1048
+ 758,
1049
+ 825,
1050
+ 911
1051
+ ],
1052
+ "page_idx": 9
1053
+ },
1054
+ {
1055
+ "type": "text",
1056
+ "text": "Acknowledgments ",
1057
+ "text_level": 1,
1058
+ "bbox": [
1059
+ 176,
1060
+ 89,
1061
+ 330,
1062
+ 106
1063
+ ],
1064
+ "page_idx": 10
1065
+ },
1066
+ {
1067
+ "type": "text",
1068
+ "text": "This work was supported in part by two National Science Foundation (NSF) grants (IIS-1910424 and IIS-1838770), a DARPA Contract HR001120C0023, and a Northrop Grumman research gift. ",
1069
+ "bbox": [
1070
+ 176,
1071
+ 121,
1072
+ 825,
1073
+ 148
1074
+ ],
1075
+ "page_idx": 10
1076
+ },
1077
+ {
1078
+ "type": "text",
1079
+ "text": "References ",
1080
+ "text_level": 1,
1081
+ "bbox": [
1082
+ 174,
1083
+ 169,
1084
+ 267,
1085
+ 184
1086
+ ],
1087
+ "page_idx": 10
1088
+ },
1089
+ {
1090
+ "type": "text",
1091
+ "text": "[1] H. Ahn, S. Cha, D. Lee, and T. Moon. Uncertainty-based continual learning with adaptive regularization. In NIPS, 2019. [2] P. Buzzega, M. Boschini, A. Porrello, D. Abati, and S. Calderara. Dark experience for general continual learning: a strong, simple baseline. arXiv preprint arXiv:2004.07211, 2020. \n[3] A. Carlson, J. Betteridge, B. Kisiel, B. Settles, E. Hruschka, and T. Mitchell. Toward an architecture for never-ending language learning. In AAAI, volume 24, 2010. [4] A. Chaudhry, M. Ranzato, M. Rohrbach, and M. Elhoseiny. Efficient lifelong learning with A-GEM. In ICLR, 2019. [5] Z. Chen and B. Liu. Lifelong machine learning. Synthesis Lectures on Artificial Intelligence and Machine Learning, 12(3):1–207, 2018. [6] Z. Chen, N. Ma, and B. Liu. Lifelong learning for sentiment classification. In ACL, 2015. [7] Y.-S. Chuang, S.-Y. Su, and Y.-N. Chen. Lifelong language knowledge distillation. arXiv preprint arXiv:2010.02123, 2020. \n[8] J. Devlin, M. Chang, K. Lee, and K. Toutanova. BERT: pre-training of deep bidirectional transformers for language understanding. In J. Burstein, C. Doran, and T. Solorio, editors, NAACL-HLT, 2019. [9] X. Ding, B. Liu, and P. S. Yu. A holistic lexicon-based approach to opinion mining. In Proceedings of the 2008 international conference on web search and data mining, 2008. \n[10] C. Fernando, D. Banarse, C. Blundell, Y. Zwols, D. Ha, A. A. Rusu, A. Pritzel, and D. Wierstra. Pathnet: Evolution channels gradient descent in super neural networks. CoRR, 2017. \n[11] E. Grave, P. Bojanowski, P. Gupta, A. Joulin, and T. Mikolov. Learning word vectors for 157 languages. In LREC, 2018. \n[12] C. Greco, B. Plank, R. Fernández, and R. Bernardi. Psycholinguistics meets continual learning: Measuring catastrophic forgetting in visual question answering. arXiv preprint arXiv:1906.04229, 2019. \n[13] P. Gupta, Y. Chaudhary, T. Runkler, and H. Schuetze. Neural topic modeling with continual lifelong learning. In International Conference on Machine Learning, pages 3907–3917. PMLR, 2020. \n[14] X. He and H. Jaeger. Overcoming catastrophic interference using conceptor-aided backpropagation. In ICLR, 2018. \n[15] G. E. Hinton, A. Krizhevsky, and S. D. Wang. Transforming auto-encoders. In International conference on artificial neural networks, 2011. \n[16] N. Houlsby, A. Giurgiu, S. Jastrzebski, B. Morrone, Q. de Laroussilhe, A. Gesmundo, M. Attariyan, and S. Gelly. Parameter-efficient transfer learning for NLP. In K. Chaudhuri and R. Salakhutdinov, editors, ICML, 2019. \n[17] M. Hu and B. Liu. Mining and summarizing customer reviews. In Proceedings of ACM SIGKDD, 2004. \n[18] W. Hu, Q. Qin, M. Wang, J. Ma, and B. Liu. Continual learning by using information of each class holistically. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 35, pages 7797–7805, 2021. \n[19] E. Jang, S. Gu, and B. Poole. Categorical reparameterization with gumbel-softmax. In ICLR, 2017. \n[20] N. Kamra, U. Gupta, and Y. Liu. Deep generative dual memory network for continual learning. CoRR, 2017. \n[21] Z. Ke, B. Liu, and X. Huang. Continual learning of a mixed sequence of similar and dissimilar tasks. In NeurIPS, 2020. \n[22] Z. Ke, B. Liu, H. Wang, and L. Shu. Continual learning with knowledge transfer for sentiment classification. In ECML-PKDD, 2020. \n[23] Z. Ke, B. Liu, H. Xu, and L. Shu. Classic: Continual and contrastive learning of aspect sentiment classification tasks. In EMNLP, 2021. \n[24] Z. Ke, H. Xu, and B. Liu. Adapting bert for continual learning of a sequence of aspect sentiment classification tasks. In NAACL, pages 4746–4755, 2021. \n[25] H. Khayrallah, B. Thompson, K. Duh, and P. Koehn. Regularized training objective for continued training for domain adaptation in neural machine translation. In Proceedings of the 2nd Workshop on Neural Machine Translation and Generation, pages 36–44, 2018. \n[26] Y. Kim. Convolutional neural networks for sentence classification. In A. Moschitti, B. Pang, and W. Daelemans, editors, EMNLP, 2014. \n[27] J. Kirkpatrick, R. Pascanu, N. C. Rabinowitz, J. Veness, G. Desjardins, A. A. Rusu, K. Milan, J. Quan, T. Ramalho, A. Grabska-Barwinska, D. Hassabis, C. Clopath, D. Kumaran, and R. Hadsell. Overcoming catastrophic forgetting in neural networks. CoRR, 2016. \n[28] K. Lang. Newsweeder: Learning to filter netnews. In Proceedings of the Twelfth International Conference on Machine Learning, 1995. \n[29] M. D. Lange, R. Aljundi, M. Masana, and T. Tuytelaars. Continual learning: A comparative study on how to defy forgetting in classification tasks. CoRR, 2019. \n[30] S. Lee, J. Kim, J. Jun, J. Ha, and B. Zhang. Overcoming catastrophic forgetting by incremental moment matching. In NIPS. \n[31] Y. Li, L. Zhao, K. Church, and M. Elhoseiny. Compositional language continual learning. In International Conference on Learning Representations, 2019. \n[32] Q. Liu, Z. Gao, B. Liu, and Y. Zhang. Automated rule selection for aspect extraction in opinion mining. In IJCAI, 2015. \n[33] T. Liu, L. Ungar, and J. Sedoc. Continual learning for sentence representations using conceptors. arXiv preprint arXiv:1904.09187, 2019. \n[34] Y. Liu, Y. Su, A. Liu, B. Schiele, and Q. Sun. Mnemonics training: Multi-class incremental learning without forgetting. In CVPR, 2020. \n[35] Z. Liu, G. I. Winata, A. Madotto, and P. Fung. Exploring fine-tuning techniques for pre-trained cross-lingual models via continual learning. arXiv preprint arXiv:2004.14218, 2020. \n[36] D. Lopez-Paz and M. Ranzato. Gradient episodic memory for continual learning. In NIPS, 2017. \n[37] G. Lv, S. Wang, B. Liu, E. Chen, and K. Zhang. Sentiment classification by leveraging the shared knowledge from a sequence of domains. In DASFAA, 2019. \n[38] A. Madotto, Z. Lin, Z. Zhou, S. Moon, P. Crook, B. Liu, Z. Yu, E. Cho, and Z. Wang. Continual learning in task-oriented dialogue systems. arXiv preprint arXiv:2012.15504, 2020. \n[39] A. Mallya and S. Lazebnik. Packnet: Adding multiple tasks to a single network by iterative pruning. In CVPR, 2018. \n[40] M. McCloskey and N. J. Cohen. Catastrophic interference in connectionist networks: The sequential learning problem. In Psychology of learning and motivation. 1989. \n[41] A. Merchant, E. Rahimtoroghi, E. Pavlick, and I. Tenney. What happens to BERT embeddings during fine-tuning? CoRR, 2020. \n[42] J. Pfeiffer, A. Kamath, A. Rücklé, K. Cho, and I. Gurevych. Adapterfusion: Non-destructive task composition for transfer learning. \n[43] Q. Qin, W. Hu, and B. Liu. Using the past knowledge to improve sentiment classification. In EMNLP-findings, 2020. \n[44] V. V. Ramasesh, E. Dyer, and M. Raghu. Anatomy of catastrophic forgetting: Hidden representations and task semantics. In ICLR, 2021. \n[45] S. Rebuffi, A. Kolesnikov, G. Sperl, and C. H. Lampert. icarl: Incremental classifier and representation learning. In CVPR, 2017. \n[46] M. Riemer, I. Cases, R. Ajemian, M. Liu, I. Rish, Y. Tu, , and G. Tesauro. Learning to learn without forgetting by maximizing transfer and minimizing interference. In International Conference on Learning Representations, 2019. \n[47] M. Rostami, S. Kolouri, and P. K. Pilly. Complementary learning for overcoming catastrophic forgetting using experience replay. In IJCAI, 2019. \n[48] A. A. Rusu, N. C. Rabinowitz, G. Desjardins, H. Soyer, J. Kirkpatrick, K. Kavukcuoglu, R. Pascanu, and R. Hadsell. Progressive neural networks. CoRR, 2016. \n[49] P. Ruvolo and E. Eaton. ELLA: an efficient lifelong learning algorithm. In ICML, pages 507–515, 2013. \n[50] S. Sabour, N. Frosst, and G. E. Hinton. Dynamic routing between capsules. In NIPS, 2017. \n[51] A. Seff, A. Beatson, D. Suo, and H. Liu. Continual learning in generative adversarial nets. CoRR, abs/1705.08395, 2017. \n[52] J. Serrà, D. Suris, M. Miron, and A. Karatzoglou. Overcoming catastrophic forgetting with hard attention to the task. In ICML, 2018. \n[53] Y. Shen, X. Zeng, and H. Jin. A progressive model to enable continual learning for semantic slot filling. In EMNLP-IJCNLP, Nov. 2019. \n[54] H. Shin, J. K. Lee, J. Kim, and J. Kim. Continual learning with deep generative replay. In NIPS, 2017. \n[55] L. Shu, H. Xu, and B. Liu. Lifelong learning CRF for supervised aspect extraction. In ACL, 2017. \n[56] D. L. Silver, Q. Yang, and L. Li. Lifelong machine learning systems: Beyond learning algorithms. In Lifelong Machine Learning, Papers from the 2013 AAAI Spring Symposium, Palo Alto, California, USA, March 25-27, 2013, 2013. \n[57] C. Sun, L. Huang, and X. Qiu. Utilizing BERT for aspect-based sentiment analysis via constructing auxiliary sentence. In NAACL, 2019. \n[58] F.-K. Sun, C.-H. Ho, and H.-Y. Lee. Lamol: Language modeling is all you need for lifelong language learning. In ICLR, 2020. \n[59] D. Tang, B. Qin, and T. Liu. Aspect level sentiment classification with deep memory network. In EMNLP, Nov. 2016. \n[60] A. Vaswani, N. Shazeer, N. Parmar, J. Uszkoreit, L. Jones, A. N. Gomez, Ł. Kaiser, and I. Polosukhin. Attention is all you need. In NeurIPS, 2017. \n[61] H. Wang, B. Liu, S. Wang, N. Ma, and Y. Yang. Forward and backward knowledge transfer for sentiment classification. In ACML, 2019. \n[62] S. Wang, G. Lv, S. Mazumder, G. Fei, and B. Liu. Lifelong learning memory networks for aspect sentiment classification. In IEEE International Conference on Big Data, 2018. \n[63] Z. Wang, S. V. Mehta, B. Póczos, and J. Carbonell. Efficient meta lifelong-learning with limited memory. In EMNLP, 2020. \n[64] R. Xia, J. Jiang, and H. He. Distantly supervised lifelong learning for large-scale social media sentiment analysis. IEEE Trans. Affective Computing, 8(4):480–491, 2017. \n[65] H. Xu, B. Liu, L. Shu, and P. S. Yu. BERT post-training for review reading comprehension and aspect-based sentiment analysis. In J. Burstein, C. Doran, and T. Solorio, editors, NAACL-HLT, 2019. \n[66] H. Xu, S. Xie, L. Shu, and P. S. Yu. Dual attention network for product compatibility and function satisfiability analysis. In AAAI, 2018. \n[67] W. Xue and T. Li. Aspect based sentiment analysis with gated convolutional networks. In I. Gurevych and Y. Miyao, editors, ACL, 2018. \n[68] G. Zeng, Y. Chen, B. Cui, and S. Yu. Continuous learning of context-dependent processing in neural networks. Nature Machine Intelligence, 2019. \n[69] F. Zenke, B. Poole, and S. Ganguli. Continual learning through synaptic intelligence. In International Conference on Machine Learning, pages 3987–3995. PMLR, 2017. ",
1092
+ "bbox": [
1093
+ 173,
1094
+ 194,
1095
+ 828,
1096
+ 915
1097
+ ],
1098
+ "page_idx": 10
1099
+ },
1100
+ {
1101
+ "type": "text",
1102
+ "text": "",
1103
+ "bbox": [
1104
+ 171,
1105
+ 58,
1106
+ 828,
1107
+ 915
1108
+ ],
1109
+ "page_idx": 11
1110
+ },
1111
+ {
1112
+ "type": "text",
1113
+ "text": "",
1114
+ "bbox": [
1115
+ 171,
1116
+ 83,
1117
+ 830,
1118
+ 915
1119
+ ],
1120
+ "page_idx": 12
1121
+ },
1122
+ {
1123
+ "type": "text",
1124
+ "text": "",
1125
+ "bbox": [
1126
+ 169,
1127
+ 89,
1128
+ 828,
1129
+ 398
1130
+ ],
1131
+ "page_idx": 13
1132
+ }
1133
+ ]
parse/train/RJ7XFI15Q8f/RJ7XFI15Q8f_middle.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/RJ7XFI15Q8f/RJ7XFI15Q8f_model.json ADDED
The diff for this file is too large to render. See raw diff