ZHANGYUXUAN-zR commited on
Commit
63e19e7
·
verified ·
1 Parent(s): 086336c

Add files using upload-large-folder tool

Browse files
parse/train/PrzjugOsDeE/PrzjugOsDeE.md ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/PrzjugOsDeE/PrzjugOsDeE_content_list.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/PrzjugOsDeE/PrzjugOsDeE_middle.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/PrzjugOsDeE/PrzjugOsDeE_model.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/SkeHuCVFDr/SkeHuCVFDr.md ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/SkeHuCVFDr/SkeHuCVFDr_content_list.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/SkeHuCVFDr/SkeHuCVFDr_middle.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/SkeHuCVFDr/SkeHuCVFDr_model.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/bw5Arp3O3eY/bw5Arp3O3eY.md ADDED
@@ -0,0 +1,373 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # R-Drop: Regularized Dropout for Neural Networks
2
+
3
+ Xiaobo Liang1∗ Lijun $\mathbf { W } \mathbf { u } ^ { 2 * }$ Juntao Li1 Yue Wang1 Qi Meng2 Tao Qin2 Wei Chen2 Min Zhang1 Tie-Yan Liu2
4
+
5
+ 1Soochow University, 2Microsoft Research Asia xbliang3@stu.suda.edu.cn, {ljt,minzhang}@suda.edu.cn, wangyuenlp@gmail.com {lijuwu,meq,taoqin,wche,tyliu}@microsoft.com
6
+
7
+ # Abstract
8
+
9
+ Dropout is a powerful and widely used technique to regularize the training of deep neural networks. Though effective and performing well, the randomness introduced by dropout causes unnegligible inconsistency between training and inference. In this paper, we introduce a simple consistency training strategy to regularize dropout, namely R-Drop, which forces the output distributions of different sub models generated by dropout to be consistent with each other. Specifically, for each training sample, R-Drop minimizes the bidirectional KL-divergence between the output distributions of two sub models sampled by dropout. Theoretical analysis reveals that R-Drop reduces the above inconsistency. Experiments on 5 widely used deep learning tasks (18 datasets in total), including neural machine translation, abstractive summarization, language understanding, language modeling, and image classification, show that R-Drop is universally effective. In particular, it yields substantial improvements when applied to fine-tune large-scale pre-trained models, e.g., ViT, RoBERTa-large, and BART, and achieves state-of-the-art (SOTA) performances with the vanilla Transformer model on WMT14 English German translation (30.91 BLEU) and WMT14 English French translation (43.95 BLEU), even surpassing models trained with extra large-scale data and expert-designed advanced variants of Transformer models. Our code is available at GitHub2.
10
+
11
+ # 1 Introduction
12
+
13
+ In recent years, deep learning has achieved remarkable success in various areas, e.g., natural language processing, computer vision, speech/audio processing, etc. When training a deep neural network, regularization techniques [57, 60, 27, 3, 67, 58, 23, 71] are indispensable to prevent over-fitting and improve the generalization ability of deep models. Among them, the dropout technique [24], the most widely used one, aims to prevent co-adaptation and performs implicit ensemble by simply dropping a certain proportion of hidden units from the neural network during training. Existing literature [40, 77] has revealed the possible side effect of dropout that there is an unnegligible inconsistency between training and inference stage of dropout models, i.e., the randomly sampled sub model (caused by dropout) during training is inconsistent with the full model (without dropout) during inference. Through imposing $L _ { 2 }$ regularization on the inconsistent hidden states [40, 77], current methods can mitigate the inconsistency problem to some extent but are far from being widely used.
14
+
15
+ In this paper, we introduce a simple yet more effective alternative to regularize the training inconsistency induced by dropout, named as R-Drop. Concretely, in each mini-batch training, each data sample goes through the forward pass twice, and each pass is processed by a different sub model by randomly dropping out some hidden units. R-Drop forces the two distributions for the same data sample outputted by the two sub models to be consistent with each other, through minimizing the bidirectional Kullback-Leibler (KL) divergence between the two distributions. That is, R-Drop regularizes the outputs of two sub models randomly sampled from dropout for each data sample in training. In this way, the inconsistency between the training and inference stage can be alleviated. Compared with the dropout strategy in conventional neural network training, R-Drop only adds a KL-divergence loss without any structural modifications.
16
+
17
+ ![](images/ef9dda1af5faeb22ab4a1ffc0d5afb34ec2f0091a0bd22347bb37d5926b2e30f.jpg)
18
+ Figure 1: The overall framework of our proposed R-Drop. We take Transformer [59] structure for illustration. The left picture shows that one input $x$ will go through the model twice and obtain two distributions $\mathcal { P } _ { 1 }$ and $\mathcal { P } _ { 2 }$ , while the right one shows two different sub models produced by dropout.
19
+
20
+ From the perspective of deep neural network regularization, our proposed R-Drop can be treated as a new variation of dropout. Different from most of the previous methods that merely work on the hidden units of each layer (e.g., the standard dropout [24]) or model parameters (e.g., dropconnect [60]), R-Drop works on both the hidden units and the output of sub models sampled by dropout, which is much more effective. We theoretically analyze the regularization effect of R-Drop, where the result shows that R-Drop can reduce the inconsistency existed in the training and inference.
21
+
22
+ Though R-Drop regularization is simple, we find it is surprisingly effective through extensive experiments on 5 tasks with 18 datasets, spanning from natural language processing, including language modeling, neural machine translation, abstractive summarization, and language understanding, to computer vision, i.e., image classification. It creates new records on multiple datasets, such as 30.91 BLEU score on WMT14 English German and 43.95 on WMT14 English French translation tasks while only be simply applied to the training of the vanilla Transformer, and also achieves SOTA results on the CNN/DailyMail summarization dataset. These universal improvements clearly demonstrate the effectiveness of R-Drop.
23
+
24
+ Our main contributions are summarized as follows:
25
+
26
+ • We propose R-Drop, a simple yet effective regularization method built upon dropout, which can be universally applied to train different kinds of deep models.
27
+ • We theoretically show that our R-Drop can reduce the inconsistency between training and inference of the dropout based models.
28
+ • Through extensive experiments on 4 NLP and 1 CV tasks with a total of 18 datasets, we show that R-Drop achieves extremely strong performances, including multiple SOTA results.
29
+
30
+ # 2 Approach
31
+
32
+ The overall framework of our R-Drop regularization method is shown in Figure 1. Before elaborating on the details, we first present some necessary notations. Given the training dataset $\mathcal { D } = \{ ( x _ { i } , y _ { i } ) \} _ { i = 1 } ^ { n }$ the goal of the training is to learn a model $\mathcal { P } ^ { w } ( y | x )$ , where $n$ is the number of the training samples, $( x _ { i } , y _ { i } )$ is the labeled data pair. $x _ { i }$ is input data and $y _ { i }$ is the label. For example, in NLP, $x _ { i }$ can be the source language sentence in machine translation, and $y _ { i }$ is the corresponding target language sentence. In CV, $x _ { i }$ can be one image, and $y _ { i }$ is the categorical class label. The probability distribution of the mapping function is also denoted as $\mathcal { P } ^ { w } ( y | x )$ , and the Kullback-Leibler (KL) divergence between two distributions $\mathcal { P } _ { 1 }$ and $\mathcal { P } _ { 2 }$ is represented by $\mathcal { D } _ { K L } ( \mathcal { P } _ { 1 } | | \mathcal { P } _ { 2 } )$ . In the following, we will explain our proposed R-Drop, training algorithm, and theoretical analysis, respectively.
33
+
34
+ # 2.1 R-Drop Regularization
35
+
36
+ We introduce our simple regularization method in this part. Given the training data $\mathcal { D } = \{ ( x _ { i } , y _ { i } ) \} _ { i = 1 } ^ { n }$ , the main learning objective for a deep learning model is to minimize the negative log-likelihood loss function, which is as follow:
37
+
38
+ $$
39
+ \mathcal { L } _ { n l l } = \frac { 1 } { n } \sum _ { i = 1 } ^ { n } - \log \mathcal { P } ^ { w } ( y _ { i } | x _ { i } ) .
40
+ $$
41
+
42
+ Since the deep neural networks are prone to over-fitting, regularization methods such as dropout [57] are usually adopted during training to reduce the generalization error of the model. Specifically, dropout randomly drops part of units in each layer of the neural network to avoid co-adapting and over-fitting. Besides, dropout also approximately performs to combine exponentially many different neural network architectures efficiently [57], while model combination can always improve the model performance. Though simple and effective, there is a huge inconsistency between training and inference that hinders the model performance. That is, the training stage takes the sub model with randomly dropped units, while the inference phase adopts the full model without dropout. Also, the sub models caused by randomly sampled dropout units are also different without any constraints. Based on above observations and the randomness of the structure brought by dropout, we propose our R-Drop to regularize the output predictions of sub models from dropout.
43
+
44
+ Concretely, given the input data $x _ { i }$ at each training step, we feed $x _ { i }$ to go through the forward pass of the network twice. Therefore, we can obtain two distributions of the model predictions, denoted as $\mathcal { P } _ { 1 } ^ { w } ( y _ { i } | x _ { i } )$ and $\mathcal { P } _ { 2 } ^ { w } ( y _ { i } | x _ { i } )$ . As discussed above, since the dropout operator randomly drops units in a model, the two forward passes are indeed based on two different sub models (though in the same model). As shown in the right part of Figure 1, the dropped units in each layer of the left path for the output prediction $\mathcal { P } _ { 1 } ^ { w } ( y _ { i } | x _ { i } )$ are different from that of the right path for output distribution $\mathcal { P } _ { 2 } ^ { w } ( y _ { i } | x _ { i } )$ . Thus the distributions of $\mathcal { P } _ { 1 } ^ { w } ( y _ { i } | x _ { i } )$ and $\mathcal { P } _ { 2 } ^ { w } ( y _ { i } | x _ { i } )$ are different for the same input data pair $( x _ { i } , y _ { i } )$ . Then, at this training step, our R-Drop method tries to regularize on the model predictions by minimizing the bidirectional Kullback-Leibler (KL) divergence between these two output distributions for the same sample, which is:
45
+
46
+ $$
47
+ \mathcal { L } _ { K L } ^ { i } = \frac { 1 } { 2 } ( \mathcal { D } _ { K L } ( \mathcal { P } _ { 1 } ^ { w } ( y _ { i } | x _ { i } ) | | \mathcal { P } _ { 2 } ^ { w } ( y _ { i } | x _ { i } ) ) + \mathcal { D } _ { K L } ( \mathcal { P } _ { 2 } ^ { w } ( y _ { i } | x _ { i } ) | | \mathcal { P } _ { 1 } ^ { w } ( y _ { i } | x _ { i } ) ) ) .
48
+ $$
49
+
50
+ With the basic negative log-likelihood learning objective $\mathcal { L } _ { N L L } ^ { i }$ of the two forward passes:
51
+
52
+ $$
53
+ \mathcal { L } _ { N L L } ^ { i } = - \log \mathcal { P } _ { 1 } ^ { w } ( y _ { i } | x _ { i } ) - \log \mathcal { P } _ { 2 } ^ { w } ( y _ { i } | x _ { i } ) ,
54
+ $$
55
+
56
+ the final training objective is to minimize $\mathcal { L } ^ { i }$ for data $( x _ { i } , y _ { i } )$ :
57
+
58
+ $$
59
+ \begin{array} { l } { \displaystyle { \mathcal { L } ^ { i } = \mathcal { L } _ { N L L } ^ { i } + \alpha \cdot \mathcal { L } _ { K L } ^ { i } = - \log \mathcal { P } _ { 1 } ^ { w } ( y _ { i } | x _ { i } ) - \log \mathcal { P } _ { 2 } ^ { w } ( y _ { i } | x _ { i } ) } } \\ { \displaystyle { \phantom { \mathcal { L } ^ { i } = \mathcal { L } _ { N L } ^ { i } } + \frac { \alpha } { 2 } [ \mathcal { D } _ { K L } ( \mathcal { P } _ { 1 } ^ { w } ( y _ { i } | x _ { i } ) | | \mathcal { P } _ { 2 } ^ { w } ( y _ { i } | x _ { i } ) ) + \mathcal { D } _ { K L } ( \mathcal { P } _ { 2 } ^ { w } ( y _ { i } | x _ { i } ) | | \mathcal { P } _ { 1 } ^ { w } ( y _ { i } | x _ { i } ) ) ] , } } \end{array}
60
+ $$
61
+
62
+ where $\alpha$ is the coefficient weight to control $\mathcal { L } _ { K L } ^ { i }$ . In this way, our R-Drop further regularizes the model space beyond dropout and improves the generalization ability of a model. Compared Equation (1) with Equation (4), our R-Drop only adds a KL-divergence loss $\mathcal { L } _ { K L } ^ { i }$ based on two forward passes in training. Note that our regularization methodology can be universally applied on different model structures if there exists randomness in a model (e.g., dropout) that can produce different sub models or outputs. We leave further explorations as future work.
63
+
64
+ # 2.2 Training Algorithm
65
+
66
+ The overall training algorithm based on our R-Drop is presented in Algorithm 1. As introduced before, at each training step, Line 3-4 show that we go forward the model and obtain output distributions $\mathcal { P } _ { 1 } ^ { w } ( y | x )$ and $\mathcal { P } _ { 2 } ^ { w } ( y | x )$ , then Line 5-6 calculate the negative log-likelihood and the KL-divergence between the two distributions. It is worth nothing that we do not forward the input data twice, instead, we repeat the input data $x$ and concatenate them $( [ x ; x ] )$ in batch-size dimension, which can make forward procedure happen in the same mini-batch to save the training cost. Finally, the model parameters are updated (Line 7) according to the loss of Equation (4). The training will continue over the data epochs till convergence. Compared to the conventional training, our implementation is similar to enlarge the batch size to be double, and one potential limitation is that the computational cost of R-Drop increases at each step. As we show in Section 4.1, similar to other regularization methods (e.g., training w/ or w/o dropout), though R-Drop needs more training to converge, the final optimum is much better with a superior performance. We also show another study of baseline with doubled batch size in Appendix C.1.
67
+
68
+ Algorithm 1 R-Drop Training Algorithm
69
+
70
+ <table><tr><td colspan="2">Input: Training data D = {(xi, yi)}&quot;=1·</td></tr><tr><td colspan="2">Output: model parameter w.</td></tr><tr><td colspan="2">1:Initialize model with parameters w. 2: while not converged do</td></tr><tr><td colspan="2"></td></tr><tr><td colspan="2">3: randomly sample data pair (xi, yi) ~ D,</td></tr><tr><td colspan="2">4: repeat input data twice as [xi; xi] and obtain the output distribution [Pi(yi|xi),P2(yi|xi)],</td></tr><tr><td colspan="2">5: calculate the negative log-likelihood loss LN L, by Equation (3),</td></tr><tr><td colspan="2">6: calculate the KL-divergence loss LkL by Equation (2),</td></tr><tr><td colspan="2">7: update the model parameters by minimizing loss Li of Equation (4). 8: end while</td></tr></table>
71
+
72
+ # 2.3 Theoretical Analysis
73
+
74
+ We analyze the regularization effect of R-Drop in this subsection. Let $h ^ { l } ( x ) \in { \mathbb { R } } ^ { d }$ denote the output of the $l$ -th layer of a neural network with input vector $x$ , and let $\xi ^ { l } \in \mathbb { R } ^ { d }$ denote a random vector, each dimension of which is independently sampled from a Bernoulli distribution $B ( p )$ :
75
+
76
+ $$
77
+ \xi _ { i } ^ { l } = \left\{ \begin{array} { l l } { { 1 , } } & { { w i t h p r o b a b i l i t y p , } } \\ { { 0 , } } & { { w i t h p r o b a b i l i t y I - p . } } \end{array} \right.
78
+ $$
79
+
80
+ Then the dropout operation on $h ^ { l } ( x )$ can be represented by $\begin{array} { r } { h _ { \xi ^ { l } } ^ { l } ( x ) = \frac { 1 } { p } \xi ^ { l } \odot h ^ { l } ( x ) } \end{array}$ , where $\odot$ denotes the element-wised product. Hence, the output distribution of the neural network with parameter $w$ after applying dropout is $\mathcal { P } _ { \xi } ^ { w } ( y | x ) : = \operatorname { s o f t m a x } \ ( 1 \operatorname { i n e a r } ( h _ { \xi ^ { L } } ^ { L } \big ( \cdot \cdot \cdot \big ( h _ { \xi ^ { 1 } } ^ { 1 } \big ( x _ { \xi ^ { 0 } } \big ) \big ) \big ) ) )$ , where $\dot { \boldsymbol { \xi } } = ( \xi ^ { L } , \cdot \cdot \cdot , \xi ^ { 0 } )$ . The objective for R-Drop enhanced training can be formulated as solving the following constrained optimization problem:
81
+
82
+ $$
83
+ \begin{array} { r l } & { \displaystyle \underset { w } { \operatorname* { m i n } } \frac { 1 } { n } \sum _ { i = 1 } ^ { n } \mathbb { E } _ { \xi } [ - \log \mathcal { P } _ { \xi } ^ { w } ( y _ { i } | x _ { i } ) ] , } \\ & { } \\ & { s . t . \quad \displaystyle \frac { 1 } { n } \sum _ { i = 1 } ^ { n } \mathbb { E } _ { \xi ^ { ( 1 ) } , \xi ^ { ( 2 ) } } [ \mathcal { D } _ { K L } ( \mathcal { P } _ { \xi ^ { ( 1 ) } } ^ { w } ( y _ { i } | x _ { i } ) | | \mathcal { P } _ { \xi ^ { ( 2 ) } } ^ { w } ( y _ { i } | x _ { i } ) ) ) ] \leq \epsilon . } \end{array}
84
+ $$
85
+
86
+ More precisely, R-Drop optimizes the constrained optimization problem in Equation (5) and Equation (6) in a stochastic manner, i.e., it samples two random vectors $\xi ^ { ( 1 ) }$ and $\xi ^ { ( 2 ) }$ (corresponding to two dropout instantiations) from Bernoulli distribution and one training instance $( x _ { i } , y _ { i } )$ , and updates the parameter $w$ according to the stochastic gradient $\nabla _ { w } \mathcal { L } ^ { i }$ from Equation (4).
87
+
88
+ As we presented, one problem for dropout is the inconsistency between the training and inference models. Specifically, the training objective for dropout is the average loss of the sub models, i.e., $\begin{array} { r } { \operatorname* { m i n } _ { w } \frac { 1 } { n } \sum _ { i = 1 } ^ { n } \mathbb { E } _ { \xi } [ - \log \mathcal { P } _ { \xi } ^ { w } ( y _ { i } | x _ { i } ) ] } \end{array}$ , while the full model (denoted as $\bar { P } ^ { w } ( y | x ) )$ is used for inference. Our proposed R-Drop enhanced training reduces this inconsistency by forcing the sub structures to be similar. The following proposition uses a linear model to demonstrate that with the constraint in Equation (6), the inconsistency gap between the average loss of sub structures and the loss of the full model can be bounded (detailed proof can be found in Appendix B).
89
+
90
+ Proposition 2.1. For a linear model $\mathcal { P } ^ { w } ( y | x ) = s o f t m a x ( N o r m ( w ^ { T } x ) )$ where $N o r m ( \cdot )$ denotes the normalization layer and $x \in \mathbb { R } ^ { d }$ , with the constraint in Equation (6) in the main paper, we have $| \mathcal { L } _ { n l l } ( w ) - \mathbb { E } _ { \xi } [ \mathcal { L } _ { n l l } ( w , \xi ) ] | \le c \sqrt { \epsilon } ,$ , where $\mathcal { L } _ { n l l } ( w ) , \mathcal { L } _ { n l l } ( w , \xi )$ are the empirical loss calculated by the full model and a random sub model respectively, $c$ is a constant related to the Liptschtz constant of the softmax operator.
91
+
92
+ # 2.4 Discussion
93
+
94
+ The most related works with our R-Drop are ELD [40] and FD [77], which also study the consistency training with dropout. However, R-Drop has key differences with them. (1) The gap control is from different views. ELD works on directly reducing the gap between the sub model with dropout (train) and the expected full model without dropout (inference), while R-Drop and FD are both working on penalizing the discrepancy between the sub models, the superiority of regularizing the sub models has been proved in FD. (2) The regularization efficiency is different. ELD only back-propagates the gradients through sub model without the full model, which is less efficient than R-Drop that updates both sub models. (3) The regularization effect is different. Both ELD and FD use the $L _ { 2 }$ distance on hidden states as the regularization loss function. However, this is far away from the main training objective that minimizes the negative log-likelihood over model output distribution. The distance of hidden states is not in the same space as the probability distribution since log-softmax hugely affects the optimization. In comparison, R-Drop utilizes the KL-divergence between the output probability distributions as the consistency regularization, which is in the same space as the training objective. More analysis and experimental comparisons are shown in Appendix C.4.
95
+
96
+ # 3 Experiments
97
+
98
+ To evaluate our approach and show its universal impact, we conduct experiments on 5 different tasks, including 4 natural language processing (NLP) and 1 computer vision (CV) tasks, which are neural machine translation (NMT) (6 datasets), abstractive summarization (1 dataset), language understanding (8 datasets), language modeling (1 dataset), and image classification (2 datasets). For convenience, we utilize ‘RD’ to represent R-Drop in the tables of experimental results hereinafter. More details of experimental settings for each dataset can be found in Appendix A.
99
+
100
+ 3.1 Application to Neural Machine Translation
101
+
102
+ <table><tr><td>Model</td><td>En→De</td><td>De-→En</td><td>En→Fr</td><td>Fr→En</td><td>En→Zh</td><td>Zh→En</td><td>En→Es</td><td>Es-→En</td><td>Avg</td></tr><tr><td>Transformer [59]</td><td>28.57</td><td>34.64</td><td>35.9</td><td>36.1</td><td>26.3</td><td>18.4</td><td>39.0</td><td>40.6</td><td>32.44</td></tr><tr><td>Transformer + RD</td><td>30.72</td><td>37.25</td><td>38.0</td><td>38.9</td><td>28.1</td><td>19.5</td><td>41.8</td><td>43.2</td><td>34.68</td></tr></table>
103
+
104
+ Table 1: BLEU scores on 8 IWSLT machine translation tasks.
105
+
106
+ We first evaluate the NMT tasks, which is very important in NLP. To best show the effectiveness of our method, experiments are conducted on both low-resource and rich-resource translation tasks.
107
+
108
+ Datasets The datasets of low-resource scenario are from IWSLT competitions, which include IWSLT14 English German $[ \mathrm { E n } { } \mathrm { D e } )$ , English Spanish ( ${ \mathrm { E n } } { \mathrm { E s } }$ ), and IWSLT17 English French ${ \mathrm { E n } } { \mathrm { F r } }$ ), English Chinese $( \mathrm { E n } { } \mathrm { Z h }$ ) translations. The rich-resource datasets come from the widely acknowledged WMT translation tasks, and we take the WMT14 English German and English French tasks. The IWSLT datasets contain about $1 7 0 k$ training sentence pairs, $7 k$ valid pairs, and $7 k$ test pairs. The WMT data sizes are $4 . 5 M$ , $3 6 M$ for $\mathrm { E n } { } \mathrm { D e }$ and $\mathrm { E n } { } \mathrm { F r }$ respectively, valid and test data are from the corresponding newstest data.
109
+
110
+ <table><tr><td>Method</td><td>En→De</td><td>En→Fr</td></tr><tr><td>Transformer [59]</td><td>29.12</td><td>42.69</td></tr><tr><td>MUSE [73]</td><td>29.90</td><td>43.50</td></tr><tr><td>Depth Growing [66]</td><td>30.07</td><td>43.27</td></tr><tr><td>Transformer-Admin [37]</td><td>30.10</td><td>43.80</td></tr><tr><td>Data Diversification [47]</td><td>30.70</td><td>43.70</td></tr><tr><td>BERT-fused NMT[76]</td><td>30.75</td><td>43.78</td></tr><tr><td>Transformer+RD</td><td>30.91</td><td>43.95</td></tr></table>
111
+
112
+ Table 2: BLEU scores on WMT14 En→De and $\mathrm { E n } { } \mathrm { F r }$ machine translation tasks.
113
+
114
+ Model & Training We take the most popular Transformer [59] network as our model structure. The transformer_iwslt_de_en and transformer_vaswani_wmt_en_de_big are the configurations for IWSLT and WMT translations respectively. The weight $\alpha$ is set as 5 for all translation tasks. Implementation is developed on Fairseq [48].
115
+
116
+ Results We calculate the BLEU scores on these tasks for evaluation, following [76]. The IWSLT performances are shown in Table 1 and the rich-resource WMT results are in Table 2. First, we can see that our R-Drop achieves more than 2.0 BLEU score improvements on 8 IWSLT translation tasks, which clearly shows the effectiveness of our method. The results on WMT translations are more impressive. After applying our simple method on the basic Transformer network, we achieve the state-of-the-art (SOTA) BLEU score on WMT14 En De (30.91) and $\mathrm { E n } { } \mathrm { F r }$ (43.95) translation tasks, which surpass current SOTA models, such as the BERT-fused NMT [76] model that leverages large-scale monolingual data, and the Data Diversification [47] method trained with many translation models. Note that R-Drop is complementary to the above methods, and we believe stronger results can be achieved if we apply R-Drop on their methods and better backbone models beyond Transformer.
117
+
118
+ # 3.2 Application to Language Understanding
119
+
120
+ Dataset We further evaluate our proposed approach on the language understanding tasks by finetuning the pre-trained models3, which are the standard development sets of GLUE [61] benchmark. The GLUE benchmark includes 8 different text classification or regression tasks, which are MNLI, MRPC, QNLI, QQP, RTE, SST-2, STS-B (regression), CoLA. The detailed statistics are in Appendix.
121
+
122
+ Model & Training We take the BERT-base [9] and strong RoBERTa-large [38] pre-trained models as our backbones to perform fine-tuning, which are publicly available. For each task, different random seeds and parameter settings are required, thus we dynamically adjust the coefficient $\alpha$ among $\{ 0 . 1 , 0 . 5 , 1 . 0 \}$ for each setting. Other configurations are following the previous works [9, 38]. For the regression task STS-B, we use MSE instead of KL-divergence to regularize the outputs (see Appendix for MSE regularization details).
123
+
124
+ Results The evaluation metrics for above 8 tasks are as follows: The result for STS-B is the Pearson correlation; Matthew’s correlation is used for CoLA; Other tasks are measured by Accuracy. The results are presented in Table 3. We can see that R-Drop achieves 1.21 points and 0.80 points (on average) improvement over the two baselines BERT-base and RoBERTa-large, respectively, which clearly demonstrate the effectiveness of R-Drop. Specifically, our RoBERTa-large $^ +$ RD also surpasses the other two strong models: XLNet-large [68] and ELECTRA-large [7], which are specially designed with different model architecture and pre-training task.
125
+
126
+ <table><tr><td>Model</td><td>MNLI</td><td>MRPC</td><td>QNLI</td><td>QQP</td><td>RTE</td><td>SST-2</td><td>STS-B</td><td>CoLA</td><td>Avg</td></tr><tr><td>BERT-base [9]</td><td>83.8</td><td>85.3</td><td>90.8</td><td>91.0</td><td>68.2</td><td>92.4</td><td>89.3</td><td>62.3</td><td>82.85</td></tr><tr><td>BERT-base + RD</td><td>85.5</td><td>87.3</td><td>92.0</td><td>91.4</td><td>71.1</td><td>93.0</td><td>89.6</td><td>62.6</td><td>84.06</td></tr><tr><td>RoBERTa-large [38]</td><td>90.2</td><td>90.9</td><td>94.7</td><td>92.2</td><td>86.6</td><td>96.4</td><td>92.4</td><td>68.0</td><td>88.93</td></tr><tr><td>XLNet-large [68]</td><td>90.8</td><td>90.8</td><td>94.9</td><td>92.3</td><td>85.9</td><td>97.0</td><td>92.5</td><td>69.0</td><td>89.15</td></tr><tr><td>ELECRTA-large [7]</td><td>90.9</td><td>90.8</td><td>95.0</td><td>92.4</td><td>88.0</td><td>96.9</td><td>92.6</td><td>69.1</td><td>89.46</td></tr><tr><td>RoBERTa-large + RD</td><td>90.9</td><td>91.4</td><td>95.2</td><td>92.5</td><td>88.4</td><td>96.9</td><td>92.5</td><td>70.0</td><td>89.73</td></tr></table>
127
+
128
+ Table 3: Fine-tuned model performances on GLUE language understanding benchmark.
129
+
130
+ # 3.3 Application to Summarization
131
+
132
+ Dataset Abstractive summarization task is to summarize the long sentence/document into a short sequence/sentence (through generation) with the main content remained. For this generation task, we use the CNN/Daily Mail dataset originally introduced by Hermann et al. [22] to evaluate our method. This dataset contains news documents (source), and their corresponding highlights (target) crawled from CNN and Daily Mail website. It contains 287,226 documents for training, 13,368 documents for validation and 11,490 documents for test. We follow [34] to preprocess the dataset.
133
+
134
+ Model & Training To mostly show the effectiveness, we take the super strong pre-trained sequenceto-sequence BART [34] model as our backbone and fine-tune it using our method. In this task, the coefficient weight $\alpha$ is set as 0.7 to control the KL-divergence. For other hyper-parameters, we follow the setting of the original paper [34] without modification.
135
+
136
+ Results The performance is evaluated by ROUGE F1 score [36]. Specifically, we report the unigram ROUGE1 (RG-1) and bigram ROUGE-2 (RG-2) overlap to assess the informativeness, and the longest common subsequence ROUGE-L (RG-L) score to assess the fluency. The results are shown in Table 4. We can see that R-Drop based training outperforms the fine-tuned BART model by 0.3 points on RG-1 and RG-2 score and achieves the SOTA performance. Specifically, our result also surpasses the PEGASUS method [70], which brings a novel self-supervised paradigm carefully designed for summarization, and the previous best work BART+R3F [1], which introduces a parametric noise sampled from normal or uniform distributions. Instead, our R-Drop does not introduce any extra parameters or model structure changes during training.
137
+
138
+ <table><tr><td>Method</td><td>RG-1</td><td>RG-2</td><td>RG-L</td></tr><tr><td>Transformer [59]</td><td>39.50</td><td>16.06</td><td>36.63</td></tr><tr><td>ProphetNet [51]</td><td>44.02</td><td>21.17</td><td>41.30</td></tr><tr><td>BART [34]</td><td>44.16</td><td>21.28</td><td>40.90</td></tr><tr><td>PEGASUS [70]</td><td>44.17</td><td>21.47</td><td>41.11</td></tr><tr><td>BART+R3F[1]</td><td>44.38</td><td>21.53</td><td>41.17</td></tr><tr><td>BART+RD</td><td>44.51</td><td>21.58</td><td>41.24</td></tr></table>
139
+
140
+ Table 4: ROUGE results on CNN/Daily Mail summarization dataset. RG-1, RG2, RG-L stand for ROUGE-1, ROUGE-2, and ROUGE-L scores.
141
+
142
+ # 3.4 Application to Language Modeling
143
+
144
+ Dataset We also evaluate our approach on another widely acknowledged NLP task: language modeling. The dataset we choose for this task is the commonly adopted Wikitext-103 dataset [41], which is the largest available word-level language modeling benchmark with long-term dependency. WikiText-103 contains about $1 0 3 M$ training tokens from $2 8 K$ articles on Wikipedia, and the average length of tokens per article is about $3 . 6 K$ . The data is preprocessed by following [48].
145
+
146
+ Model & Training We take two models to conduct the language modeling task. One is the basic Transformer decoder [59], another is the more advanced one: Adaptive Input Transformer [5], which introduces adaptive input embeddings into the Transformer model. We use the open-source Fairseq [48] toolkit, and the corresponding model configurations are transformer_lm_gpt and transformer_lm_wiki103 for Transformer and Adaptive Input Transformer. We simply set the weight $\alpha$ to be 1.0 without tuning during training. Other configurations are same as [48] and [5].
147
+
148
+ Results The evaluation metric for language modeling is perplexity, which can well measure the probability of a sentence. Same as [5], we report the perplexity on both valid and test sets. The results are shown in Table 5. From the table, we can see that our R-Drop based training improves the perplexity on both two different model structures, e.g., 0.80 perplexity improvement on test set over Adaptive Input Transformer. Besides, more improvement can be achieved when the baseline model is not so strong, e.g., 1.79 perplexity gain on valid set and 1.68 on test set above the Transformer baseline.
149
+
150
+ Table 5: Perplexity results on Wikitext-103 language modeling task. Adaptive refers to Adaptive Input Transformer [5].
151
+
152
+ <table><tr><td>Method</td><td>Valid</td><td>Test</td></tr><tr><td>Transformer [59] Transformer +RD</td><td>25.76</td><td>26.62</td></tr><tr><td></td><td>23.97</td><td>24.94</td></tr><tr><td>Adaptive [5] Adaptive + RD</td><td>18.94 18.18</td><td>18.87</td></tr><tr><td></td><td></td><td>18.07</td></tr></table>
153
+
154
+ # 3.5 Application to Image Classification
155
+
156
+ Dataset For image classification, we conduct experiments on two widely acknowledged benchmark datasets, i.e., CIFAR-100 [31] and the ILSVRC-2012 ImageNet dataset [8] (denoted as ImageNet for short). CIFAR-100 dataset consists of $6 0 k$ images of 100 classes, and there are 600 images per class with 500 for training and 100 for testing.
157
+
158
+ The ImageNet dataset consists of $1 . 3 M$ image samples of 1, 000 categorical classes. We utilize the same data preprocessing strategies with [11], where the details are given in [29].
159
+
160
+ Model & Training We choose the recent strong and popular Vision Transformer (ViT) [11] model as our backbone. More specifically, we take the two publicly released pre-trained models, ViT-B/16 and ViT-L/16, with $8 6 M$ and $3 0 7 M$ parameters respectively, and we conduct model fine-tuning on the CIFAR-100 and ImageNet datasets. During fine-tuning, the weight $\alpha$ is set as 0.6 for both models, and we set other hyper-parameters/training details to be same as [11].
161
+
162
+ <table><tr><td>Method</td><td>CIFAR-100</td><td> ImageNet</td></tr><tr><td>ViT-B/16 [11]</td><td>92.64</td><td>83.97</td></tr><tr><td>ViT-B/16 + RD</td><td>93.29</td><td>84.38</td></tr><tr><td>ViT-L/16 [11]</td><td>93.44</td><td>85.15</td></tr><tr><td>ViT-L/16 + RD</td><td>93.85</td><td>85.57</td></tr></table>
163
+
164
+ Table 6: Accuracy on CIFAR-100 and ImageNet classification tasks.
165
+
166
+ Results The classification performance is measured by Accuracy, and the results are presented in Table 6. For CIFAR-100, we achieve about 0.65 accuracy improvement over ViT-B/16 baseline, and 0.41 points over ViT-L/16 model. Similarly, on the large-scale ImageNet dataset, consistent improvements are also obtained. These observations demonstrate that our R-Drop can still benefit the model performance even the baseline is powerful. In a word, through the above NLP tasks and this image classification task, we clearly show R-Drop is effective and can be universally applied.
167
+
168
+ # 4 Study
169
+
170
+ Beyond the superior experimental results, in this section, we conduct extensive studies on different perspectives to better understand our R-Drop method. The analysis experiments are performed on the IWSLT14 De→En translation task. More studies can be found in Appendix C.
171
+
172
+ # 4.1 Regularization and Cost Analysis
173
+
174
+ We first show the regularization effect of our R-Drop and study the potential limitation of training cost (as discussed in Section 2.2). Hence, we plot the curves of training/valid loss and valid BLEU along the training update number for Transformer and Transformer $+ \mathbf { R D }$ models. Besides, we also plot the corresponding curves along the training time (minutes). The curves are shown in Figure 2. We can observe: 1) Along with the training, Transformer quickly becomes over-fitting, and the gap between train and valid loss of Transformer is large, while R-Drop has a lower valid loss. This well proves that R-Drop can provide persistent regularization during training. 2) At the early training stage, Transformer improves the BLEU score quickly but converges to bad local optima soon. In comparison, R-Drop gradually improves the BLEU score and achieves a much superior performance. Though it needs more training to converge, the final optimum is better. This is same as other regularization methods (e.g., training w/ or w/o dropout). R-Drop indeed increases the training cost at each step since it requires repeating input $x$ for another computation in a mini-batch. Note that this is similar to batch size doubled training without KL-divergence. In Appendix C.1, we conduct this training and show that R-Drop increases negligible cost but with a much stronger performance.
175
+
176
+ ![](images/73f99e7168d1177f0139d37b2bbe098da4f172942a5760ab271a9d3e13a48df4.jpg)
177
+ Figure 2: Loss/BLEU curves along with model training.
178
+
179
+ ![](images/a9474a564d966ad01fe136ed87498fdee77bccb63eeda72029e5796149a6d324.jpg)
180
+ Figure 3: R-Drop with different step.
181
+
182
+ # 4.2 $k$ -step R-Drop
183
+
184
+ The above study shows that R-Drop can achieve much stronger performance, but with a lower convergence, thus we study another training strategy that is to perform R-Drop every $k$ steps to improve the training efficiency, instead of applying at each step. We vary $k$ in $\{ 1 , \bar { 2 } , 5 , 1 \bar { 0 } \}$ to see the difference, where $k = 1$ is the current training strategy. The valid BLEU curves along with training update number and training time are presented in Figure 3. From the curves, we can conclude that though the convergence is faster with larger $k$ , the training fails to fall into good optima, which quickly over-fits, and the BLEU scores become worse and worse when we increase $k$ . This proves that our R-Drop at each step can well regularize the training and obtain superior performances.
185
+
186
+ # 4.3 $m$ -time R-Drop
187
+
188
+ Our method regularizes the model output between two distributions $P _ { 1 } ^ { w } ( y | x )$ and $P _ { 2 } ^ { w } ( y | x )$ , and it is also interesting to see whether more improvements can be achieved if we regularize $m$ distributions for the same input data, where $m = 2$ is the current setting. Therefore, we extend our R-Drop to be: ) Pi6=ji,j∈1,··· ,m DKL(Pwi (y|x)||Pwj (y|x)), and we take m = 3 for a feasible implementation. The BLEU score for IWSLT14 $_ \mathrm { D e \to E n }$ test set is 37.30 when $m = 3$ , which is similar to that when $m = 2$ (37.25 BLEU score). This reflects that R-Drop already has a strong regularization effect between two distributions, without the necessity of stronger regularization.
189
+
190
+ # 4.4 Two Dropout Rates
191
+
192
+ Besides the above studies, we investigate RDrop from another perspective, i.e., the dropout values. In current training, the two distributions are based on the same dropout value (e.g., 0.3 for IWSLT translations). In this study, we utilize two different dropout values for the two output distributions during training (e.g., 0.1 for $\bar { P } _ { 1 } ^ { w } ( y | x )$ , 0.3 for $P _ { 2 } ^ { w } ( y | x ) )$ to see the difference. We choose the two dropout rates from $\{ 0 . 1 , 0 . 2 , 0 . 3 , 0 . 4 , 0 . 5 \}$ with total 15 $C _ { 5 } ^ { 2 }$ for two different rates $+ ~ C _ { 5 } ^ { 1 }$ for two same rates) combinations. The results are shown in Figure 4. Among these different results, we can see that: 1) Dropout rates with the same value (0.3, 0.3) is the best choice (current setting), 2) R-Drop
193
+
194
+ ![](images/a05ddbc73c5883ff2e7bdb07362e60d5813b2ffd3752f209b4b7d17f1db1697a.jpg)
195
+ Figure 4: R-Drop with two different dropout rate combinations. Among the 25 numbers, 15 are different since the table is symmetric and triangular.
196
+
197
+ can stably achieve strong results when the two dropout rates are in a reasonable range $( 0 . 3 \sim 0 . 5 )$ without a big performance difference. One interesting point is that even the two dropout values are both 0.5, which means half of the units are expected to be dropped, R-Drop can still obtain a satisfied result (36.48 BLEU) compared with the baseline Transformer (34.64 BLEU). These results all confirm the advantage of our R-Drop, and we are interested in studying more in the future.
198
+
199
+ # 4.5 Effect of Weight $\alpha$
200
+
201
+ Further, we investigate the impact of the KL-divergence loss weight $\alpha$ . As mentioned in Section 3.1, we set $\alpha = 5$ for NMT experiments. Here we vary the $\alpha$ in $\{ 1 , 3 , 5 , 7 , 1 0 \}$ and conduct experiments. As shown in Table 7, small $\alpha$ (e.g., 1) can not perform as good as large $\alpha$ (e.g., 5), which means we should pay more attention to the KLdivergence regularization. However, too much regularization $( \alpha = 1 0 )$ ) is also not good, and the best balanced choice is $\alpha = 5$ . Note that the choice of $\alpha$ is distinct for different tasks (e.g., NMT, language understanding), which depends on how easy the over-fitting happens caused by the specific data size and model size of each task.
202
+
203
+ Table 7: BLEU scores with different $\alpha$ .
204
+
205
+ <table><tr><td>α</td><td>TF+RD</td></tr><tr><td>α=1</td><td>36.05</td></tr><tr><td>α=3</td><td>36.85</td></tr><tr><td>α=5</td><td>37.25</td></tr><tr><td>α=7</td><td>37.20</td></tr><tr><td>α=10</td><td>36.95</td></tr></table>
206
+
207
+ # 5 Related Work
208
+
209
+ Regularization Methods. Bigger models always tend to have better performance, especially for various large-scale pre-trained models, e.g., Vision Transformer [11], Swin Transformer [39], GPT families [52, 53, 6], BERT [9], BART [34], Switch Transformers [14], etc. With millions and even billions of parameters, these deep models are prone to over-fitting, thus requiring regularization strategies to improve their generalization ability [33]. To tackle with over-fitting, many regularization techniques have been proposed, e.g., weight decay [32, 30, 28, 63], dropout [24, 60, 4, 62, 57], normalization [27, 54, 3, 26, 67], adding noise [25, 50], layer-wise pre-training and initialization [12, 21], label-smoothing [58], and so on. Among which, dropout and its variants are most popular owing to its effectiveness and moderate cost as well as good compatibility with other regularization methods [45], which has been successfully applied to regularize a wide range of neural network architectures [49], e.g., convolutional neural network layers [64, 10], recurrent neural networks [17, 55, 42], Transformer [69, 75, 65]. The success of dropout methods can be interpreted by preventing co-adaptation of neurons and performing an implicit ensemble of sub models from dropout. Owing to the effect in promoting sparsity of weights and stochastic nature, dropout methods are also adapted to other applications, e.g., contrastive learning for sentence representation learning [18], neural network compression [44, 46] and model uncertainty estimation [16].
210
+
211
+ Unlike previous researches of designing specific dropout variants or adapting dropout to different applications, we consider to further regularize the model on the success of dropout. Specifically, any two sub models sampled from dropout are encouraged to produce consistent model prediction for an input data by utilizing KL-divergence in the training stage. That is, we conduct regularization on the model output level. In doing so, the sub model outputs produced by the randomness of dropout are regularized to reduce the parameter freedom, which will enhance generalization in inference.
212
+
213
+ Consistency Training. Besides regularization methods, our work also relates to a few works of consistency training on dropout models or data augmentation. Among them, the most representative methods are ELD [40], FD [77], and Cutoff [56]. As discussed in Section 2.4, ELD only focuses on the inconsistency between the sub model with dropout (train) and the expected full-model without dropout (inference), while FD works between the sub models only (consistence between two sub models). Both ELD and FD utilize $L _ { 2 }$ to regularize the hidden space. Instead, our R-Drop performs consistency training on dropout from the output space with a more effective bidirectional KL loss. Unlike the above consistency training method on sub models, Cutoff resembles launching consistency training from a data perspective by regularizing the inconsistency between the original data the augmented samples with part of the information within an input sentence being erased.
214
+
215
+ Self-distillation. Minimizing the KL-divergence between the output distributions of two different models correlates with knowledge distillation [23, 15, 2, 35, 13, 74], where the two models refer to teacher and student, respectively. In our setting, the teacher and student are the dropout instantiations of the same model, and thus it resembles self-knowledge distillation [43] scenario. Different from existing method that exploits dark knowledge from the model itself [20, 19] or distills knowledge between different layers [71], our strategy can be regarded as an instance-wise self-knowledge distillation, i.e., each pair of sampled sub models perform distillation between each other for the same input, which also relates to mutual learning [72] but ours is much more efficient without extra parameters.
216
+
217
+ # 6 Conclusions and Future Work
218
+
219
+ In this paper, we proposed a simple yet very effective consistency training method built upon dropout, namely R-Drop, which minimizes the bidirectional KL-divergence of the output distributions of any pair of sub models sampled from dropout in model training. Experimental results on 18 popular deep learning datasets show that not only can our R-Drop effectively enhance strong models, e.g., ViT, BART, Roberta-large, but also work well on large-scale datasets and even achieve SOTA performances when combined with vanilla Transformer on WMT14 English German and English French translations. Due to the limitation of computational resources, for pre-training related tasks, we only tested R-Drop on downstream task fine-tuning in this work. We will test it on pre-training in the future. In this work, we focused on Transformer based models. We will apply R-Drop to other network architectures such as convolutional neural networks.
220
+
221
+ # Acknowledgments and Disclosure of Funding
222
+
223
+ We would like to thank the reviewers for their constructive comments. Juntao Li is the corresponding author. This work was supported by the National Science Foundation of China (NSFC No. 62036004).
224
+
225
+ # References
226
+
227
+ [1] Armen Aghajanyan, Akshat Shrivastava, Anchit Gupta, Naman Goyal, Luke Zettlemoyer, and Sonal Gupta. Better fine-tuning by reducing representational collapse. arXiv preprint arXiv:2008.03156, 2020.
228
+
229
+ [2] Zeyuan Allen-Zhu and Yuanzhi Li. Towards understanding ensemble, knowledge distillation and self-distillation in deep learning. arXiv preprint arXiv:2012.09816, 2020.
230
+
231
+ [3] Jimmy Lei Ba, Jamie Ryan Kiros, and Geoffrey E Hinton. Layer normalization. arXiv preprint arXiv:1607.06450, 2016.
232
+
233
+ [4] Lei Jimmy Ba and Brendan Frey. Adaptive dropout for training deep neural networks. In Proceedings of the 26th International Conference on Neural Information Processing SystemsVolume 2, pp. 3084–3092, 2013.
234
+
235
+ [5] Alexei Baevski and Michael Auli. Adaptive input representations for neural language modeling. In International Conference on Learning Representations, 2018.
236
+
237
+ [6] Tom B Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah, Jared Kaplan, Prafulla Dhariwal, Arvind Neelakantan, Pranav Shyam, Girish Sastry, Amanda Askell, et al. Language models are few-shot learners. arXiv preprint arXiv:2005.14165, 2020.
238
+
239
+ [7] Kevin Clark, Minh-Thang Luong, Quoc V Le, and Christopher D Manning. Electra: Pre-training text encoders as discriminators rather than generators. In International Conference on Learning Representations, 2019.
240
+
241
+ [8] Jia Deng, Wei Dong, Richard Socher, Li-Jia Li, Kai Li, and Li Fei-Fei. Imagenet: A largescale hierarchical image database. In 2009 IEEE conference on computer vision and pattern recognition, pp. 248–255. Ieee, 2009.
242
+
243
+ [9] Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. Bert: Pre-training of deep bidirectional transformers for language understanding. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pp. 4171–4186, 2019.
244
+
245
+ [10] Terrance DeVries and Graham W Taylor. Improved regularization of convolutional neural networks with cutout. arXiv preprint arXiv:1708.04552, 2017.
246
+
247
+ [11] Alexey Dosovitskiy, Lucas Beyer, Alexander Kolesnikov, Dirk Weissenborn, Xiaohua Zhai, Thomas Unterthiner, Mostafa Dehghani, Matthias Minderer, Georg Heigold, Sylvain Gelly, Jakob Uszkoreit, and Neil Houlsby. An image is worth 16x16 words: Transformers for image recognition at scale. In International Conference on Learning Representations, 2021.
248
+
249
+ [12] Dumitru Erhan, Pierre-Antoine Manzagol, Yoshua Bengio, Samy Bengio, and Pascal Vincent. The difficulty of training deep architectures and the effect of unsupervised pre-training. In Artificial Intelligence and Statistics, pp. 153–160. PMLR, 2009.
250
+
251
+ [13] Zhiyuan Fang, Jianfeng Wang, Lijuan Wang, Lei Zhang, Yezhou Yang, and Zicheng Liu. Seed: Self-supervised distillation for visual representation. International Conference on Learning Representations, 2021.
252
+
253
+ [14] William Fedus, Barret Zoph, and Noam Shazeer. Switch transformers: Scaling to trillion parameter models with simple and efficient sparsity. arXiv preprint arXiv:2101.03961, 2021.
254
+
255
+ [15] Tommaso Furlanello, Zachary Lipton, Michael Tschannen, Laurent Itti, and Anima Anandkumar. Born again neural networks. In International Conference on Machine Learning, pp. 1607–1616. PMLR, 2018.
256
+
257
+ [16] Yarin Gal and Zoubin Ghahramani. Dropout as a bayesian approximation: Representing model uncertainty in deep learning. In international conference on machine learning, pp. 1050–1059. PMLR, 2016.
258
+
259
+ [17] Yarin Gal and Zoubin Ghahramani. A theoretically grounded application of dropout in recurrent neural networks. Advances in neural information processing systems, 29:1019–1027, 2016.
260
+
261
+ [18] Tianyu Gao, Xingcheng Yao, and Danqi Chen. Simcse: Simple contrastive learning of sentence embeddings. arXiv preprint arXiv:2104.08821, 2021.
262
+
263
+ [19] Akhilesh Gotmare, Nitish Shirish Keskar, Caiming Xiong, and Richard Socher. A closer look at deep learning heuristics: Learning rate restarts, warmup and distillation. In International Conference on Learning Representations, 2019.
264
+
265
+ [20] Sangchul Hahn and Heeyoul Choi. Self-knowledge distillation in natural language processing. In Proceedings of the International Conference on Recent Advances in Natural Language Processing (RANLP 2019), pp. 423–430, 2019.
266
+
267
+ [21] Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. Delving deep into rectifiers: Surpassing human-level performance on imagenet classification. In Proceedings of the IEEE international conference on computer vision, pp. 1026–1034, 2015.
268
+
269
+ [22] Karl Moritz Hermann, Tomáš Kocisk ˇ y, Edward Grefenstette, Lasse Espeholt, Will Kay, Mustafa \` Suleyman, and Phil Blunsom. Teaching machines to read and comprehend. arXiv preprint arXiv:1506.03340, 2015.
270
+
271
+ [23] Geoffrey Hinton, Oriol Vinyals, and Jeff Dean. Distilling the knowledge in a neural network. arXiv preprint arXiv:1503.02531, 2015.
272
+
273
+ [24] Geoffrey E Hinton, Nitish Srivastava, Alex Krizhevsky, Ilya Sutskever, and Ruslan R Salakhutdinov. Improving neural networks by preventing co-adaptation of feature detectors. arXiv preprint arXiv:1207.0580, 2012.
274
+
275
+ [25] Sepp Hochreiter and Jürgen Schmidhuber. Simplifying neural nets by discovering flat minima. In Advances in neural information processing systems, pp. 529–536, 1995.
276
+
277
+ [26] Lei Huang, Xianglong Liu, Bo Lang, Adams Yu, Yongliang Wang, and Bo Li. Orthogonal weight normalization: Solution to optimization over multiple dependent stiefel manifolds in deep neural networks. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 32, 2018.
278
+
279
+ [27] Sergey Ioffe and Christian Szegedy. Batch normalization: Accelerating deep network training by reducing internal covariate shift. In International conference on machine learning, pp. 448–456. PMLR, 2015.
280
+
281
+ [28] Guoliang Kang, Jun Li, and Dacheng Tao. Shakeout: A new regularized deep neural network training scheme. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 30, 2016.
282
+
283
+ [29] 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.
284
+
285
+ [30] Alex Krizhevsky, Ilya Sutskever, and Geoffrey E Hinton. Imagenet classification with deep convolutional neural networks. Advances in neural information processing systems, 25:1097– 1105, 2012.
286
+
287
+ [31] Alex Krizhevsky et al. Learning multiple layers of features from tiny images. 2009.
288
+
289
+ [32] Anders Krogh and John A Hertz. A simple weight decay can improve generalization. In Advances in neural information processing systems, pp. 950–957, 1992.
290
+
291
+ [33] Alex Labach, Hojjat Salehinejad, and Shahrokh Valaee. Survey of dropout methods for deep neural networks. arXiv preprint arXiv:1904.13310, 2019.
292
+
293
+ [34] Mike Lewis, Yinhan Liu, Naman Goyal, Marjan Ghazvininejad, Abdelrahman Mohamed, Omer Levy, Veselin Stoyanov, and Luke Zettlemoyer. Bart: Denoising sequence-to-sequence pretraining for natural language generation, translation, and comprehension. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pp. 7871–7880, 2020.
294
+
295
+ [35] Kevin J Liang, Weituo Hao, Dinghan Shen, Yufan Zhou, Weizhu Chen, Changyou Chen, and Lawrence Carin. Mixkd: Towards efficient distillation of large-scale language models. International Conference on Learning Representations, 2021.
296
+
297
+ [36] Chin-Yew Lin and Eduard Hovy. Manual and automatic evaluation of summaries. In Proceedings of the ACL-02 Workshop on Automatic Summarization, pp. 45–51, 2002.
298
+ [37] Xiaodong Liu, Kevin Duh, Liyuan Liu, and Jianfeng Gao. Very deep transformers for neural machine translation. arXiv preprint arXiv:2008.07772, 2020.
299
+ [38] Yinhan Liu, Myle Ott, Naman Goyal, Jingfei Du, Mandar Joshi, Danqi Chen, Omer Levy, Mike Lewis, Luke Zettlemoyer, and Veselin Stoyanov. Roberta: A robustly optimized bert pretraining approach. arXiv preprint arXiv:1907.11692, 2019.
300
+ [39] Ze Liu, Yutong Lin, Yue Cao, Han Hu, Yixuan Wei, Zheng Zhang, Stephen Lin, and Baining Guo. Swin transformer: Hierarchical vision transformer using shifted windows. arXiv preprint arXiv:2103.14030, 2021.
301
+ [40] Xuezhe Ma, Yingkai Gao, Zhiting Hu, Yaoliang Yu, Yuntian Deng, and Eduard Hovy. Dropout with expectation-linear regularization. arXiv preprint arXiv:1609.08017, 2016.
302
+ [41] Stephen Merity, Caiming Xiong, James Bradbury, and Richard Socher. Pointer sentinel mixture models. arXiv preprint arXiv:1609.07843, 2016.
303
+ [42] Stephen Merity, Nitish Shirish Keskar, and Richard Socher. Regularizing and optimizing lstm language models. In International Conference on Learning Representations, 2018.
304
+ [43] Hossein Mobahi, Mehrdad Farajtabar, and Peter L Bartlett. Self-distillation amplifies regularization in hilbert space. arXiv preprint arXiv:2002.05715, 2020.
305
+ [44] Dmitry Molchanov, Arsenii Ashukha, and Dmitry Vetrov. Variational dropout sparsifies deep neural networks. In International Conference on Machine Learning, pp. 2498–2507. PMLR, 2017.
306
+ [45] Reza Moradi, Reza Berangi, and Behrouz Minaei. A survey of regularization strategies for deep models. Artificial Intelligence Review, 53(6):3947–3986, 2020.
307
+ [46] Kirill Neklyudov, Dmitry Molchanov, Arsenii Ashukha, and Dmitry Vetrov. Structured bayesian pruning via log-normal multiplicative noise. In Proceedings of the 31st International Conference on Neural Information Processing Systems, pp. 6778–6787, 2017.
308
+ [47] Xuan-Phi Nguyen, Shafiq Joty, Kui Wu, and Ai Ti Aw. Data diversification: A simple strategy for neural machine translation. In Advances in Neural Information Processing Systems, pp. 10018–10029, 2020.
309
+ [48] Myle Ott, Sergey Edunov, Alexei Baevski, Angela Fan, Sam Gross, Nathan Ng, David Grangier, and Michael Auli. fairseq: A fast, extensible toolkit for sequence modeling. In NAACL-HLT (Demonstrations), 2019.
310
+ [49] Hieu Pham and Quoc V Le. Autodropout: Learning dropout patterns to regularize deep networks. arXiv preprint arXiv:2101.01761, 2021.
311
+ [50] Ben Poole, Jascha Sohl-Dickstein, and Surya Ganguli. Analyzing noise in autoencoders and deep networks. arXiv preprint arXiv:1406.1831, 2014.
312
+ [51] Weizhen Qi, Yu Yan, Yeyun Gong, Dayiheng Liu, Nan Duan, Jiusheng Chen, Ruofei Zhang, and Ming Zhou. Prophetnet: Predicting future n-gram for sequence-to-sequence pre-training. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing: Findings, pp. 2401–2410, 2020.
313
+ [52] Alec Radford, Karthik Narasimhan, Tim Salimans, and Ilya Sutskever. Improving language understanding by generative pre-training.
314
+ [53] Alec Radford, Jeffrey Wu, Rewon Child, David Luan, Dario Amodei, and Ilya Sutskever. Language models are unsupervised multitask learners. OpenAI blog, 1(8):9, 2019.
315
+ [54] Tim Salimans and Diederik P Kingma. Weight normalization: a simple reparameterization to accelerate training of deep neural networks. In Proceedings of the 30th International Conference on Neural Information Processing Systems, pp. 901–909, 2016.
316
+ [55] Stanislau Semeniuta, Aliaksei Severyn, and Erhardt Barth. Recurrent dropout without memory loss. In Proceedings of COLING 2016, the 26th International Conference on Computational Linguistics: Technical Papers, pp. 1757–1766, 2016.
317
+ [56] Dinghan Shen, Mingzhi Zheng, Yelong Shen, Yanru Qu, and Weizhu Chen. A simple but tough-to-beat data augmentation approach for natural language understanding and generation. arXiv preprint arXiv:2009.13818, 2020.
318
+ [57] Nitish Srivastava, Geoffrey Hinton, Alex Krizhevsky, Ilya Sutskever, and Ruslan Salakhutdinov. Dropout: a simple way to prevent neural networks from overfitting. The journal of machine learning research, 15(1):1929–1958, 2014.
319
+ [58] Christian Szegedy, Vincent Vanhoucke, Sergey Ioffe, Jon Shlens, and Zbigniew Wojna. Rethinking the inception architecture for computer vision. In Proceedings of the IEEE conference on computer vision and pattern recognition, pp. 2818–2826, 2016.
320
+ [59] Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Łukasz Kaiser, and Illia Polosukhin. Attention is all you need. In Proceedings of the 31st International Conference on Neural Information Processing Systems, pp. 6000–6010, 2017.
321
+ [60] Li Wan, Matthew Zeiler, Sixin Zhang, Yann Le Cun, and Rob Fergus. Regularization of neural networks using dropconnect. In International conference on machine learning, pp. 1058–1066. PMLR, 2013.
322
+ [61] Alex Wang, Amanpreet Singh, Julian Michael, Felix Hill, Omer Levy, and Samuel Bowman. Glue: A multi-task benchmark and analysis platform for natural language understanding. In Proceedings of the 2018 EMNLP Workshop BlackboxNLP: Analyzing and Interpreting Neural Networks for NLP, pp. 353–355, 2018.
323
+ [62] Sida Wang and Christopher Manning. Fast dropout training. In international conference on machine learning, pp. 118–126. PMLR, 2013.
324
+ [63] Wei Wen, Chunpeng Wu, Yandan Wang, Yiran Chen, and Hai Li. Learning structured sparsity in deep neural networks. In Proceedings of the 30th International Conference on Neural Information Processing Systems, pp. 2082–2090, 2016.
325
+ [64] Haibing Wu and Xiaodong Gu. Towards dropout training for convolutional neural networks. Neural Networks, 71:1–10, 2015.
326
+ [65] Hongqiu Wu, Hai Zhao, and Min Zhang. Not all attention is all you need. arXiv preprint arXiv:2104.04692, 2021.
327
+ [66] Lijun Wu, Yiren Wang, Yingce Xia, Fei Tian, Fei Gao, Tao Qin, Jianhuang Lai, and Tie-Yan Liu. Depth growing for neural machine translation. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pp. 5558–5563, 2019.
328
+ [67] Yuxin Wu and Kaiming He. Group normalization. In Proceedings of the European conference on computer vision (ECCV), pp. 3–19, 2018.
329
+ [68] Zhilin Yang, Zihang Dai, Yiming Yang, Jaime Carbonell, Russ R Salakhutdinov, and Quoc V Le. Xlnet: Generalized autoregressive pretraining for language understanding. Advances in Neural Information Processing Systems, 32:5753–5763, 2019.
330
+ [69] Lin Zehui, Pengfei Liu, Luyao Huang, Junkun Chen, Xipeng Qiu, and Xuanjing Huang. Dropattention: A regularization method for fully-connected self-attention networks. arXiv preprint arXiv:1907.11065, 2019.
331
+ [70] Jingqing Zhang, Yao Zhao, Mohammad Saleh, and Peter Liu. Pegasus: Pre-training with extracted gap-sentences for abstractive summarization. In International Conference on Machine Learning, pp. 11328–11339. PMLR, 2020.
332
+ [71] Linfeng Zhang, Jiebo Song, Anni Gao, Jingwei Chen, Chenglong Bao, and Kaisheng Ma. Be your own teacher: Improve the performance of convolutional neural networks via self distillation. In Proceedings of the IEEE/CVF International Conference on Computer Vision, pp. 3713–3722, 2019.
333
+ [72] Ying Zhang, Tao Xiang, Timothy M Hospedales, and Huchuan Lu. Deep mutual learning. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pp. 4320–4328, 2018.
334
+ [73] Guangxiang Zhao, Xu Sun, Jingjing Xu, Zhiyuan Zhang, and Liangchen Luo. Muse: Parallel multi-scale attention for sequence to sequence learning. arXiv preprint arXiv:1911.09483, 2019.
335
+ [74] Helong Zhou, Liangchen Song, Jiajie Chen, Ye Zhou, Guoli Wang, Junsong Yuan, and Qian Zhang. Rethinking soft labels for knowledge distillation: A bias-variance tradeoff perspective. International Conference on Learning Representations, 2021.
336
+ [75] Wangchunshu Zhou, Tao Ge, Furu Wei, Ming Zhou, and Ke Xu. Scheduled drophead: A regularization method for transformer models. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing: Findings, pp. 1971–1980, 2020.
337
+ [76] Jinhua Zhu, Yingce Xia, Lijun Wu, Di He, Tao Qin, Wengang Zhou, Houqiang Li, and Tieyan Liu. Incorporating bert into neural machine translation. In International Conference on Learning Representations, 2019.
338
+ [77] Konrad Zolna, Devansh Arpit, Dendi Suhubdy, and Yoshua Bengio. Fraternal dropout. 2018.
339
+
340
+ # Checklist
341
+
342
+ 1. For all authors...
343
+
344
+ (a) Do the main claims made in the abstract and introduction accurately reflect the paper’s contributions and scope? [Yes] We provide strong results in the experiments, and our theoretical analysis in Section 2.3.
345
+ (b) Did you describe the limitations of your work? [Yes] Our limitation lies in potential training cost per epoch, but we demonstrate it is not when comparing with batch size doubled training and the superior performances can be achieved at almost same training time. We provide discussions in Section 2.2 and Section 4.
346
+ (c) Did you discuss any potential negative societal impacts of your work? [No] We think our general training method will not lead to any negative societal impact.
347
+ (d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
348
+
349
+ 2. If you are including theoretical results...
350
+
351
+ (a) Did you state the full set of assumptions of all theoretical results? [Yes] We discuss in Section 2.3.
352
+ (b) Did you include complete proofs of all theoretical results? [Yes] We provide discussion in Section 2.3 and Appendix B.
353
+
354
+ 3. If you ran experiments...
355
+
356
+ (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 provide a anonymous github url for our project.
357
+ (b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] We provide the details in Section 3 and Appendix A.
358
+ (c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [Yes] We report the average results (number) for multiple runs of most experiments instead of the error bars.
359
+ (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] We provide the details in Appendix A.
360
+
361
+ 4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
362
+
363
+ (a) If your work uses existing assets, did you cite the creators? [Yes] We provide the citations for each data and the url for open-souce code.
364
+ (b) Did you mention the license of the assets? [No] We use the publicly popular datasets for each experiments, and the details can be found in Section 3.
365
+ (c) Did you include any new assets either in the supplemental material or as a URL? [No] We do not provide new datasets.
366
+ (d) Did you discuss whether and how consent was obtained from people whose data you’re using/curating? [N/A] We use public dataset.
367
+ (e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A] We use public dataset.
368
+
369
+ 5. If you used crowdsourcing or conducted research with human subjects...
370
+
371
+ (a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
372
+ (b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
373
+ (c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
parse/train/bw5Arp3O3eY/bw5Arp3O3eY_content_list.json ADDED
@@ -0,0 +1,1757 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [
2
+ {
3
+ "type": "text",
4
+ "text": "R-Drop: Regularized Dropout for Neural Networks ",
5
+ "text_level": 1,
6
+ "bbox": [
7
+ 186,
8
+ 122,
9
+ 812,
10
+ 148
11
+ ],
12
+ "page_idx": 0
13
+ },
14
+ {
15
+ "type": "text",
16
+ "text": "Xiaobo Liang1∗ Lijun $\\mathbf { W } \\mathbf { u } ^ { 2 * }$ Juntao Li1 Yue Wang1 Qi Meng2 Tao Qin2 Wei Chen2 Min Zhang1 Tie-Yan Liu2 ",
17
+ "bbox": [
18
+ 258,
19
+ 199,
20
+ 743,
21
+ 229
22
+ ],
23
+ "page_idx": 0
24
+ },
25
+ {
26
+ "type": "text",
27
+ "text": "1Soochow University, 2Microsoft Research Asia xbliang3@stu.suda.edu.cn, {ljt,minzhang}@suda.edu.cn, wangyuenlp@gmail.com {lijuwu,meq,taoqin,wche,tyliu}@microsoft.com ",
28
+ "bbox": [
29
+ 184,
30
+ 229,
31
+ 816,
32
+ 272
33
+ ],
34
+ "page_idx": 0
35
+ },
36
+ {
37
+ "type": "text",
38
+ "text": "Abstract ",
39
+ "text_level": 1,
40
+ "bbox": [
41
+ 462,
42
+ 308,
43
+ 535,
44
+ 324
45
+ ],
46
+ "page_idx": 0
47
+ },
48
+ {
49
+ "type": "text",
50
+ "text": "Dropout is a powerful and widely used technique to regularize the training of deep neural networks. Though effective and performing well, the randomness introduced by dropout causes unnegligible inconsistency between training and inference. In this paper, we introduce a simple consistency training strategy to regularize dropout, namely R-Drop, which forces the output distributions of different sub models generated by dropout to be consistent with each other. Specifically, for each training sample, R-Drop minimizes the bidirectional KL-divergence between the output distributions of two sub models sampled by dropout. Theoretical analysis reveals that R-Drop reduces the above inconsistency. Experiments on 5 widely used deep learning tasks (18 datasets in total), including neural machine translation, abstractive summarization, language understanding, language modeling, and image classification, show that R-Drop is universally effective. In particular, it yields substantial improvements when applied to fine-tune large-scale pre-trained models, e.g., ViT, RoBERTa-large, and BART, and achieves state-of-the-art (SOTA) performances with the vanilla Transformer model on WMT14 English German translation (30.91 BLEU) and WMT14 English French translation (43.95 BLEU), even surpassing models trained with extra large-scale data and expert-designed advanced variants of Transformer models. Our code is available at GitHub2. ",
51
+ "bbox": [
52
+ 232,
53
+ 338,
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": "In recent years, deep learning has achieved remarkable success in various areas, e.g., natural language processing, computer vision, speech/audio processing, etc. When training a deep neural network, regularization techniques [57, 60, 27, 3, 67, 58, 23, 71] are indispensable to prevent over-fitting and improve the generalization ability of deep models. Among them, the dropout technique [24], the most widely used one, aims to prevent co-adaptation and performs implicit ensemble by simply dropping a certain proportion of hidden units from the neural network during training. Existing literature [40, 77] has revealed the possible side effect of dropout that there is an unnegligible inconsistency between training and inference stage of dropout models, i.e., the randomly sampled sub model (caused by dropout) during training is inconsistent with the full model (without dropout) during inference. Through imposing $L _ { 2 }$ regularization on the inconsistent hidden states [40, 77], current methods can mitigate the inconsistency problem to some extent but are far from being widely used. ",
74
+ "bbox": [
75
+ 174,
76
+ 647,
77
+ 825,
78
+ 799
79
+ ],
80
+ "page_idx": 0
81
+ },
82
+ {
83
+ "type": "text",
84
+ "text": "In this paper, we introduce a simple yet more effective alternative to regularize the training inconsistency induced by dropout, named as R-Drop. Concretely, in each mini-batch training, each data sample goes through the forward pass twice, and each pass is processed by a different sub model by randomly dropping out some hidden units. R-Drop forces the two distributions for the same data sample outputted by the two sub models to be consistent with each other, through minimizing the bidirectional Kullback-Leibler (KL) divergence between the two distributions. That is, R-Drop regularizes the outputs of two sub models randomly sampled from dropout for each data sample in training. In this way, the inconsistency between the training and inference stage can be alleviated. Compared with the dropout strategy in conventional neural network training, R-Drop only adds a KL-divergence loss without any structural modifications. ",
85
+ "bbox": [
86
+ 174,
87
+ 806,
88
+ 825,
89
+ 862
90
+ ],
91
+ "page_idx": 0
92
+ },
93
+ {
94
+ "type": "image",
95
+ "img_path": "images/ef9dda1af5faeb22ab4a1ffc0d5afb34ec2f0091a0bd22347bb37d5926b2e30f.jpg",
96
+ "image_caption": [
97
+ "Figure 1: The overall framework of our proposed R-Drop. We take Transformer [59] structure for illustration. The left picture shows that one input $x$ will go through the model twice and obtain two distributions $\\mathcal { P } _ { 1 }$ and $\\mathcal { P } _ { 2 }$ , while the right one shows two different sub models produced by dropout. "
98
+ ],
99
+ "image_footnote": [],
100
+ "bbox": [
101
+ 233,
102
+ 94,
103
+ 764,
104
+ 279
105
+ ],
106
+ "page_idx": 1
107
+ },
108
+ {
109
+ "type": "text",
110
+ "text": "",
111
+ "bbox": [
112
+ 174,
113
+ 359,
114
+ 825,
115
+ 443
116
+ ],
117
+ "page_idx": 1
118
+ },
119
+ {
120
+ "type": "text",
121
+ "text": "From the perspective of deep neural network regularization, our proposed R-Drop can be treated as a new variation of dropout. Different from most of the previous methods that merely work on the hidden units of each layer (e.g., the standard dropout [24]) or model parameters (e.g., dropconnect [60]), R-Drop works on both the hidden units and the output of sub models sampled by dropout, which is much more effective. We theoretically analyze the regularization effect of R-Drop, where the result shows that R-Drop can reduce the inconsistency existed in the training and inference. ",
122
+ "bbox": [
123
+ 174,
124
+ 449,
125
+ 825,
126
+ 534
127
+ ],
128
+ "page_idx": 1
129
+ },
130
+ {
131
+ "type": "text",
132
+ "text": "Though R-Drop regularization is simple, we find it is surprisingly effective through extensive experiments on 5 tasks with 18 datasets, spanning from natural language processing, including language modeling, neural machine translation, abstractive summarization, and language understanding, to computer vision, i.e., image classification. It creates new records on multiple datasets, such as 30.91 BLEU score on WMT14 English German and 43.95 on WMT14 English French translation tasks while only be simply applied to the training of the vanilla Transformer, and also achieves SOTA results on the CNN/DailyMail summarization dataset. These universal improvements clearly demonstrate the effectiveness of R-Drop. ",
133
+ "bbox": [
134
+ 174,
135
+ 539,
136
+ 825,
137
+ 650
138
+ ],
139
+ "page_idx": 1
140
+ },
141
+ {
142
+ "type": "text",
143
+ "text": "Our main contributions are summarized as follows: ",
144
+ "bbox": [
145
+ 174,
146
+ 656,
147
+ 509,
148
+ 671
149
+ ],
150
+ "page_idx": 1
151
+ },
152
+ {
153
+ "type": "text",
154
+ "text": "• We propose R-Drop, a simple yet effective regularization method built upon dropout, which can be universally applied to train different kinds of deep models. \n• We theoretically show that our R-Drop can reduce the inconsistency between training and inference of the dropout based models. \n• Through extensive experiments on 4 NLP and 1 CV tasks with a total of 18 datasets, we show that R-Drop achieves extremely strong performances, including multiple SOTA results. ",
155
+ "bbox": [
156
+ 217,
157
+ 683,
158
+ 825,
159
+ 777
160
+ ],
161
+ "page_idx": 1
162
+ },
163
+ {
164
+ "type": "text",
165
+ "text": "2 Approach ",
166
+ "text_level": 1,
167
+ "bbox": [
168
+ 173,
169
+ 796,
170
+ 289,
171
+ 814
172
+ ],
173
+ "page_idx": 1
174
+ },
175
+ {
176
+ "type": "text",
177
+ "text": "The overall framework of our R-Drop regularization method is shown in Figure 1. Before elaborating on the details, we first present some necessary notations. Given the training dataset $\\mathcal { D } = \\{ ( x _ { i } , y _ { i } ) \\} _ { i = 1 } ^ { n }$ the goal of the training is to learn a model $\\mathcal { P } ^ { w } ( y | x )$ , where $n$ is the number of the training samples, $( x _ { i } , y _ { i } )$ is the labeled data pair. $x _ { i }$ is input data and $y _ { i }$ is the label. For example, in NLP, $x _ { i }$ can be the source language sentence in machine translation, and $y _ { i }$ is the corresponding target language sentence. In CV, $x _ { i }$ can be one image, and $y _ { i }$ is the categorical class label. The probability distribution of the mapping function is also denoted as $\\mathcal { P } ^ { w } ( y | x )$ , and the Kullback-Leibler (KL) divergence between two distributions $\\mathcal { P } _ { 1 }$ and $\\mathcal { P } _ { 2 }$ is represented by $\\mathcal { D } _ { K L } ( \\mathcal { P } _ { 1 } | | \\mathcal { P } _ { 2 } )$ . In the following, we will explain our proposed R-Drop, training algorithm, and theoretical analysis, respectively. ",
178
+ "bbox": [
179
+ 174,
180
+ 827,
181
+ 825,
182
+ 911
183
+ ],
184
+ "page_idx": 1
185
+ },
186
+ {
187
+ "type": "text",
188
+ "text": "",
189
+ "bbox": [
190
+ 174,
191
+ 90,
192
+ 825,
193
+ 133
194
+ ],
195
+ "page_idx": 2
196
+ },
197
+ {
198
+ "type": "text",
199
+ "text": "2.1 R-Drop Regularization ",
200
+ "text_level": 1,
201
+ "bbox": [
202
+ 174,
203
+ 150,
204
+ 374,
205
+ 165
206
+ ],
207
+ "page_idx": 2
208
+ },
209
+ {
210
+ "type": "text",
211
+ "text": "We introduce our simple regularization method in this part. Given the training data $\\mathcal { D } = \\{ ( x _ { i } , y _ { i } ) \\} _ { i = 1 } ^ { n }$ , the main learning objective for a deep learning model is to minimize the negative log-likelihood loss function, which is as follow: ",
212
+ "bbox": [
213
+ 174,
214
+ 175,
215
+ 826,
216
+ 217
217
+ ],
218
+ "page_idx": 2
219
+ },
220
+ {
221
+ "type": "equation",
222
+ "img_path": "images/20be1b8af7ae4646bbc87327519036717efca3f94e8f7870c3ed84ae073298d8.jpg",
223
+ "text": "$$\n\\mathcal { L } _ { n l l } = \\frac { 1 } { n } \\sum _ { i = 1 } ^ { n } - \\log \\mathcal { P } ^ { w } ( y _ { i } | x _ { i } ) .\n$$",
224
+ "text_format": "latex",
225
+ "bbox": [
226
+ 393,
227
+ 223,
228
+ 604,
229
+ 265
230
+ ],
231
+ "page_idx": 2
232
+ },
233
+ {
234
+ "type": "text",
235
+ "text": "Since the deep neural networks are prone to over-fitting, regularization methods such as dropout [57] are usually adopted during training to reduce the generalization error of the model. Specifically, dropout randomly drops part of units in each layer of the neural network to avoid co-adapting and over-fitting. Besides, dropout also approximately performs to combine exponentially many different neural network architectures efficiently [57], while model combination can always improve the model performance. Though simple and effective, there is a huge inconsistency between training and inference that hinders the model performance. That is, the training stage takes the sub model with randomly dropped units, while the inference phase adopts the full model without dropout. Also, the sub models caused by randomly sampled dropout units are also different without any constraints. Based on above observations and the randomness of the structure brought by dropout, we propose our R-Drop to regularize the output predictions of sub models from dropout. ",
236
+ "bbox": [
237
+ 173,
238
+ 276,
239
+ 825,
240
+ 430
241
+ ],
242
+ "page_idx": 2
243
+ },
244
+ {
245
+ "type": "text",
246
+ "text": "Concretely, given the input data $x _ { i }$ at each training step, we feed $x _ { i }$ to go through the forward pass of the network twice. Therefore, we can obtain two distributions of the model predictions, denoted as $\\mathcal { P } _ { 1 } ^ { w } ( y _ { i } | x _ { i } )$ and $\\mathcal { P } _ { 2 } ^ { w } ( y _ { i } | x _ { i } )$ . As discussed above, since the dropout operator randomly drops units in a model, the two forward passes are indeed based on two different sub models (though in the same model). As shown in the right part of Figure 1, the dropped units in each layer of the left path for the output prediction $\\mathcal { P } _ { 1 } ^ { w } ( y _ { i } | x _ { i } )$ are different from that of the right path for output distribution $\\mathcal { P } _ { 2 } ^ { w } ( y _ { i } | x _ { i } )$ . Thus the distributions of $\\mathcal { P } _ { 1 } ^ { w } ( y _ { i } | x _ { i } )$ and $\\mathcal { P } _ { 2 } ^ { w } ( y _ { i } | x _ { i } )$ are different for the same input data pair $( x _ { i } , y _ { i } )$ . Then, at this training step, our R-Drop method tries to regularize on the model predictions by minimizing the bidirectional Kullback-Leibler (KL) divergence between these two output distributions for the same sample, which is: ",
247
+ "bbox": [
248
+ 173,
249
+ 435,
250
+ 825,
251
+ 575
252
+ ],
253
+ "page_idx": 2
254
+ },
255
+ {
256
+ "type": "equation",
257
+ "img_path": "images/2c000aacbb607f435e5dc430cc6699508e79061d87de70f1b8ad5aaa32c8862f.jpg",
258
+ "text": "$$\n\\mathcal { L } _ { K L } ^ { i } = \\frac { 1 } { 2 } ( \\mathcal { D } _ { K L } ( \\mathcal { P } _ { 1 } ^ { w } ( y _ { i } | x _ { i } ) | | \\mathcal { P } _ { 2 } ^ { w } ( y _ { i } | x _ { i } ) ) + \\mathcal { D } _ { K L } ( \\mathcal { P } _ { 2 } ^ { w } ( y _ { i } | x _ { i } ) | | \\mathcal { P } _ { 1 } ^ { w } ( y _ { i } | x _ { i } ) ) ) .\n$$",
259
+ "text_format": "latex",
260
+ "bbox": [
261
+ 251,
262
+ 582,
263
+ 745,
264
+ 611
265
+ ],
266
+ "page_idx": 2
267
+ },
268
+ {
269
+ "type": "text",
270
+ "text": "With the basic negative log-likelihood learning objective $\\mathcal { L } _ { N L L } ^ { i }$ of the two forward passes: ",
271
+ "bbox": [
272
+ 171,
273
+ 618,
274
+ 764,
275
+ 635
276
+ ],
277
+ "page_idx": 2
278
+ },
279
+ {
280
+ "type": "equation",
281
+ "img_path": "images/6b0cefdb0b45e4deb2fac20e496537a0e52f22c49d29caf9669ffafec9ea8547.jpg",
282
+ "text": "$$\n\\mathcal { L } _ { N L L } ^ { i } = - \\log \\mathcal { P } _ { 1 } ^ { w } ( y _ { i } | x _ { i } ) - \\log \\mathcal { P } _ { 2 } ^ { w } ( y _ { i } | x _ { i } ) ,\n$$",
283
+ "text_format": "latex",
284
+ "bbox": [
285
+ 352,
286
+ 641,
287
+ 643,
288
+ 660
289
+ ],
290
+ "page_idx": 2
291
+ },
292
+ {
293
+ "type": "text",
294
+ "text": "the final training objective is to minimize $\\mathcal { L } ^ { i }$ for data $( x _ { i } , y _ { i } )$ : ",
295
+ "bbox": [
296
+ 173,
297
+ 666,
298
+ 578,
299
+ 681
300
+ ],
301
+ "page_idx": 2
302
+ },
303
+ {
304
+ "type": "equation",
305
+ "img_path": "images/39472b84355ba619a23ab4af5f44852107aee383039c790d647ec9436536321c.jpg",
306
+ "text": "$$\n\\begin{array} { l } { \\displaystyle { \\mathcal { L } ^ { i } = \\mathcal { L } _ { N L L } ^ { i } + \\alpha \\cdot \\mathcal { L } _ { K L } ^ { i } = - \\log \\mathcal { P } _ { 1 } ^ { w } ( y _ { i } | x _ { i } ) - \\log \\mathcal { P } _ { 2 } ^ { w } ( y _ { i } | x _ { i } ) } } \\\\ { \\displaystyle { \\phantom { \\mathcal { L } ^ { i } = \\mathcal { L } _ { N L } ^ { i } } + \\frac { \\alpha } { 2 } [ \\mathcal { D } _ { K L } ( \\mathcal { P } _ { 1 } ^ { w } ( y _ { i } | x _ { i } ) | | \\mathcal { P } _ { 2 } ^ { w } ( y _ { i } | x _ { i } ) ) + \\mathcal { D } _ { K L } ( \\mathcal { P } _ { 2 } ^ { w } ( y _ { i } | x _ { i } ) | | \\mathcal { P } _ { 1 } ^ { w } ( y _ { i } | x _ { i } ) ) ] , } } \\end{array}\n$$",
307
+ "text_format": "latex",
308
+ "bbox": [
309
+ 183,
310
+ 688,
311
+ 812,
312
+ 738
313
+ ],
314
+ "page_idx": 2
315
+ },
316
+ {
317
+ "type": "text",
318
+ "text": "where $\\alpha$ is the coefficient weight to control $\\mathcal { L } _ { K L } ^ { i }$ . In this way, our R-Drop further regularizes the model space beyond dropout and improves the generalization ability of a model. Compared Equation (1) with Equation (4), our R-Drop only adds a KL-divergence loss $\\mathcal { L } _ { K L } ^ { i }$ based on two forward passes in training. Note that our regularization methodology can be universally applied on different model structures if there exists randomness in a model (e.g., dropout) that can produce different sub models or outputs. We leave further explorations as future work. ",
319
+ "bbox": [
320
+ 174,
321
+ 742,
322
+ 825,
323
+ 828
324
+ ],
325
+ "page_idx": 2
326
+ },
327
+ {
328
+ "type": "text",
329
+ "text": "2.2 Training Algorithm ",
330
+ "text_level": 1,
331
+ "bbox": [
332
+ 174,
333
+ 843,
334
+ 349,
335
+ 859
336
+ ],
337
+ "page_idx": 2
338
+ },
339
+ {
340
+ "type": "text",
341
+ "text": "The overall training algorithm based on our R-Drop is presented in Algorithm 1. As introduced before, at each training step, Line 3-4 show that we go forward the model and obtain output distributions $\\mathcal { P } _ { 1 } ^ { w } ( y | x )$ and $\\mathcal { P } _ { 2 } ^ { w } ( y | x )$ , then Line 5-6 calculate the negative log-likelihood and the KL-divergence between the two distributions. It is worth nothing that we do not forward the input data twice, instead, we repeat the input data $x$ and concatenate them $( [ x ; x ] )$ in batch-size dimension, which can make forward procedure happen in the same mini-batch to save the training cost. Finally, the model parameters are updated (Line 7) according to the loss of Equation (4). The training will continue over the data epochs till convergence. Compared to the conventional training, our implementation is similar to enlarge the batch size to be double, and one potential limitation is that the computational cost of R-Drop increases at each step. As we show in Section 4.1, similar to other regularization methods (e.g., training w/ or w/o dropout), though R-Drop needs more training to converge, the final optimum is much better with a superior performance. We also show another study of baseline with doubled batch size in Appendix C.1. ",
342
+ "bbox": [
343
+ 174,
344
+ 869,
345
+ 825,
346
+ 911
347
+ ],
348
+ "page_idx": 2
349
+ },
350
+ {
351
+ "type": "table",
352
+ "img_path": "images/163929b860f38b3fbd5c989472c386f9b2df02e332415830a3d6b531a5cf369c.jpg",
353
+ "table_caption": [
354
+ "Algorithm 1 R-Drop Training Algorithm "
355
+ ],
356
+ "table_footnote": [],
357
+ "table_body": "<table><tr><td colspan=\"2\">Input: Training data D = {(xi, yi)}&quot;=1·</td></tr><tr><td colspan=\"2\">Output: model parameter w.</td></tr><tr><td colspan=\"2\">1:Initialize model with parameters w. 2: while not converged do</td></tr><tr><td colspan=\"2\"></td></tr><tr><td colspan=\"2\">3: randomly sample data pair (xi, yi) ~ D,</td></tr><tr><td colspan=\"2\">4: repeat input data twice as [xi; xi] and obtain the output distribution [Pi(yi|xi),P2(yi|xi)],</td></tr><tr><td colspan=\"2\">5: calculate the negative log-likelihood loss LN L, by Equation (3),</td></tr><tr><td colspan=\"2\">6: calculate the KL-divergence loss LkL by Equation (2),</td></tr><tr><td colspan=\"2\">7: update the model parameters by minimizing loss Li of Equation (4). 8: end while</td></tr></table>",
358
+ "bbox": [
359
+ 178,
360
+ 109,
361
+ 821,
362
+ 253
363
+ ],
364
+ "page_idx": 3
365
+ },
366
+ {
367
+ "type": "text",
368
+ "text": "",
369
+ "bbox": [
370
+ 173,
371
+ 280,
372
+ 825,
373
+ 420
374
+ ],
375
+ "page_idx": 3
376
+ },
377
+ {
378
+ "type": "text",
379
+ "text": "2.3 Theoretical Analysis ",
380
+ "text_level": 1,
381
+ "bbox": [
382
+ 174,
383
+ 434,
384
+ 356,
385
+ 450
386
+ ],
387
+ "page_idx": 3
388
+ },
389
+ {
390
+ "type": "text",
391
+ "text": "We analyze the regularization effect of R-Drop in this subsection. Let $h ^ { l } ( x ) \\in { \\mathbb { R } } ^ { d }$ denote the output of the $l$ -th layer of a neural network with input vector $x$ , and let $\\xi ^ { l } \\in \\mathbb { R } ^ { d }$ denote a random vector, each dimension of which is independently sampled from a Bernoulli distribution $B ( p )$ : ",
392
+ "bbox": [
393
+ 173,
394
+ 460,
395
+ 826,
396
+ 503
397
+ ],
398
+ "page_idx": 3
399
+ },
400
+ {
401
+ "type": "equation",
402
+ "img_path": "images/efffb6c759d2b8ab70ea666996ebc9f1d866920aec7a618877c94c6f2aef7f34.jpg",
403
+ "text": "$$\n\\xi _ { i } ^ { l } = \\left\\{ \\begin{array} { l l } { { 1 , } } & { { w i t h p r o b a b i l i t y p , } } \\\\ { { 0 , } } & { { w i t h p r o b a b i l i t y I - p . } } \\end{array} \\right.\n$$",
404
+ "text_format": "latex",
405
+ "bbox": [
406
+ 400,
407
+ 508,
408
+ 594,
409
+ 541
410
+ ],
411
+ "page_idx": 3
412
+ },
413
+ {
414
+ "type": "text",
415
+ "text": "Then the dropout operation on $h ^ { l } ( x )$ can be represented by $\\begin{array} { r } { h _ { \\xi ^ { l } } ^ { l } ( x ) = \\frac { 1 } { p } \\xi ^ { l } \\odot h ^ { l } ( x ) } \\end{array}$ , where $\\odot$ denotes the element-wised product. Hence, the output distribution of the neural network with parameter $w$ after applying dropout is $\\mathcal { P } _ { \\xi } ^ { w } ( y | x ) : = \\operatorname { s o f t m a x } \\ ( 1 \\operatorname { i n e a r } ( h _ { \\xi ^ { L } } ^ { L } \\big ( \\cdot \\cdot \\cdot \\big ( h _ { \\xi ^ { 1 } } ^ { 1 } \\big ( x _ { \\xi ^ { 0 } } \\big ) \\big ) \\big ) ) )$ , where $\\dot { \\boldsymbol { \\xi } } = ( \\xi ^ { L } , \\cdot \\cdot \\cdot , \\xi ^ { 0 } )$ . The objective for R-Drop enhanced training can be formulated as solving the following constrained optimization problem: ",
416
+ "bbox": [
417
+ 173,
418
+ 546,
419
+ 826,
420
+ 621
421
+ ],
422
+ "page_idx": 3
423
+ },
424
+ {
425
+ "type": "equation",
426
+ "img_path": "images/d84dc8648f26854072e08ebe06aba2220b4178d428880a42a3767854dea2b2f5.jpg",
427
+ "text": "$$\n\\begin{array} { r l } & { \\displaystyle \\underset { w } { \\operatorname* { m i n } } \\frac { 1 } { n } \\sum _ { i = 1 } ^ { n } \\mathbb { E } _ { \\xi } [ - \\log \\mathcal { P } _ { \\xi } ^ { w } ( y _ { i } | x _ { i } ) ] , } \\\\ & { } \\\\ & { s . t . \\quad \\displaystyle \\frac { 1 } { n } \\sum _ { i = 1 } ^ { n } \\mathbb { E } _ { \\xi ^ { ( 1 ) } , \\xi ^ { ( 2 ) } } [ \\mathcal { D } _ { K L } ( \\mathcal { P } _ { \\xi ^ { ( 1 ) } } ^ { w } ( y _ { i } | x _ { i } ) | | \\mathcal { P } _ { \\xi ^ { ( 2 ) } } ^ { w } ( y _ { i } | x _ { i } ) ) ) ] \\leq \\epsilon . } \\end{array}\n$$",
428
+ "text_format": "latex",
429
+ "bbox": [
430
+ 299,
431
+ 626,
432
+ 700,
433
+ 710
434
+ ],
435
+ "page_idx": 3
436
+ },
437
+ {
438
+ "type": "text",
439
+ "text": "More precisely, R-Drop optimizes the constrained optimization problem in Equation (5) and Equation (6) in a stochastic manner, i.e., it samples two random vectors $\\xi ^ { ( 1 ) }$ and $\\xi ^ { ( 2 ) }$ (corresponding to two dropout instantiations) from Bernoulli distribution and one training instance $( x _ { i } , y _ { i } )$ , and updates the parameter $w$ according to the stochastic gradient $\\nabla _ { w } \\mathcal { L } ^ { i }$ from Equation (4). ",
440
+ "bbox": [
441
+ 173,
442
+ 713,
443
+ 825,
444
+ 772
445
+ ],
446
+ "page_idx": 3
447
+ },
448
+ {
449
+ "type": "text",
450
+ "text": "As we presented, one problem for dropout is the inconsistency between the training and inference models. Specifically, the training objective for dropout is the average loss of the sub models, i.e., $\\begin{array} { r } { \\operatorname* { m i n } _ { w } \\frac { 1 } { n } \\sum _ { i = 1 } ^ { n } \\mathbb { E } _ { \\xi } [ - \\log \\mathcal { P } _ { \\xi } ^ { w } ( y _ { i } | x _ { i } ) ] } \\end{array}$ , while the full model (denoted as $\\bar { P } ^ { w } ( y | x ) )$ is used for inference. Our proposed R-Drop enhanced training reduces this inconsistency by forcing the sub structures to be similar. The following proposition uses a linear model to demonstrate that with the constraint in Equation (6), the inconsistency gap between the average loss of sub structures and the loss of the full model can be bounded (detailed proof can be found in Appendix B). ",
451
+ "bbox": [
452
+ 173,
453
+ 777,
454
+ 826,
455
+ 878
456
+ ],
457
+ "page_idx": 3
458
+ },
459
+ {
460
+ "type": "text",
461
+ "text": "Proposition 2.1. For a linear model $\\mathcal { P } ^ { w } ( y | x ) = s o f t m a x ( N o r m ( w ^ { T } x ) )$ where $N o r m ( \\cdot )$ denotes the normalization layer and $x \\in \\mathbb { R } ^ { d }$ , with the constraint in Equation (6) in the main paper, we have $| \\mathcal { L } _ { n l l } ( w ) - \\mathbb { E } _ { \\xi } [ \\mathcal { L } _ { n l l } ( w , \\xi ) ] | \\le c \\sqrt { \\epsilon } ,$ , where $\\mathcal { L } _ { n l l } ( w ) , \\mathcal { L } _ { n l l } ( w , \\xi )$ are the empirical loss calculated by the full model and a random sub model respectively, $c$ is a constant related to the Liptschtz constant of the softmax operator. ",
462
+ "bbox": [
463
+ 173,
464
+ 881,
465
+ 823,
466
+ 911
467
+ ],
468
+ "page_idx": 3
469
+ },
470
+ {
471
+ "type": "text",
472
+ "text": "",
473
+ "bbox": [
474
+ 174,
475
+ 90,
476
+ 823,
477
+ 133
478
+ ],
479
+ "page_idx": 4
480
+ },
481
+ {
482
+ "type": "text",
483
+ "text": "2.4 Discussion ",
484
+ "text_level": 1,
485
+ "bbox": [
486
+ 174,
487
+ 148,
488
+ 285,
489
+ 162
490
+ ],
491
+ "page_idx": 4
492
+ },
493
+ {
494
+ "type": "text",
495
+ "text": "The most related works with our R-Drop are ELD [40] and FD [77], which also study the consistency training with dropout. However, R-Drop has key differences with them. (1) The gap control is from different views. ELD works on directly reducing the gap between the sub model with dropout (train) and the expected full model without dropout (inference), while R-Drop and FD are both working on penalizing the discrepancy between the sub models, the superiority of regularizing the sub models has been proved in FD. (2) The regularization efficiency is different. ELD only back-propagates the gradients through sub model without the full model, which is less efficient than R-Drop that updates both sub models. (3) The regularization effect is different. Both ELD and FD use the $L _ { 2 }$ distance on hidden states as the regularization loss function. However, this is far away from the main training objective that minimizes the negative log-likelihood over model output distribution. The distance of hidden states is not in the same space as the probability distribution since log-softmax hugely affects the optimization. In comparison, R-Drop utilizes the KL-divergence between the output probability distributions as the consistency regularization, which is in the same space as the training objective. More analysis and experimental comparisons are shown in Appendix C.4. ",
496
+ "bbox": [
497
+ 174,
498
+ 174,
499
+ 825,
500
+ 368
501
+ ],
502
+ "page_idx": 4
503
+ },
504
+ {
505
+ "type": "text",
506
+ "text": "3 Experiments ",
507
+ "text_level": 1,
508
+ "bbox": [
509
+ 174,
510
+ 386,
511
+ 312,
512
+ 402
513
+ ],
514
+ "page_idx": 4
515
+ },
516
+ {
517
+ "type": "text",
518
+ "text": "To evaluate our approach and show its universal impact, we conduct experiments on 5 different tasks, including 4 natural language processing (NLP) and 1 computer vision (CV) tasks, which are neural machine translation (NMT) (6 datasets), abstractive summarization (1 dataset), language understanding (8 datasets), language modeling (1 dataset), and image classification (2 datasets). For convenience, we utilize ‘RD’ to represent R-Drop in the tables of experimental results hereinafter. More details of experimental settings for each dataset can be found in Appendix A. ",
519
+ "bbox": [
520
+ 174,
521
+ 416,
522
+ 825,
523
+ 500
524
+ ],
525
+ "page_idx": 4
526
+ },
527
+ {
528
+ "type": "table",
529
+ "img_path": "images/6ec203fe71b88fcd550d9047f768c4b5e8f6ad6b3612e976f918ae0486b8c4e7.jpg",
530
+ "table_caption": [
531
+ "3.1 Application to Neural Machine Translation "
532
+ ],
533
+ "table_footnote": [
534
+ "Table 1: BLEU scores on 8 IWSLT machine translation tasks. "
535
+ ],
536
+ "table_body": "<table><tr><td>Model</td><td>En→De</td><td>De-→En</td><td>En→Fr</td><td>Fr→En</td><td>En→Zh</td><td>Zh→En</td><td>En→Es</td><td>Es-→En</td><td>Avg</td></tr><tr><td>Transformer [59]</td><td>28.57</td><td>34.64</td><td>35.9</td><td>36.1</td><td>26.3</td><td>18.4</td><td>39.0</td><td>40.6</td><td>32.44</td></tr><tr><td>Transformer + RD</td><td>30.72</td><td>37.25</td><td>38.0</td><td>38.9</td><td>28.1</td><td>19.5</td><td>41.8</td><td>43.2</td><td>34.68</td></tr></table>",
537
+ "bbox": [
538
+ 174,
539
+ 545,
540
+ 823,
541
+ 595
542
+ ],
543
+ "page_idx": 4
544
+ },
545
+ {
546
+ "type": "text",
547
+ "text": "We first evaluate the NMT tasks, which is very important in NLP. To best show the effectiveness of our method, experiments are conducted on both low-resource and rich-resource translation tasks. ",
548
+ "bbox": [
549
+ 173,
550
+ 621,
551
+ 828,
552
+ 650
553
+ ],
554
+ "page_idx": 4
555
+ },
556
+ {
557
+ "type": "text",
558
+ "text": "Datasets The datasets of low-resource scenario are from IWSLT competitions, which include IWSLT14 English German $[ \\mathrm { E n } { } \\mathrm { D e } )$ , English Spanish ( ${ \\mathrm { E n } } { \\mathrm { E s } }$ ), and IWSLT17 English French ${ \\mathrm { E n } } { \\mathrm { F r } }$ ), English Chinese $( \\mathrm { E n } { } \\mathrm { Z h }$ ) translations. The rich-resource datasets come from the widely acknowledged WMT translation tasks, and we take the WMT14 English German and English French tasks. The IWSLT datasets contain about $1 7 0 k$ training sentence pairs, $7 k$ valid pairs, and $7 k$ test pairs. The WMT data sizes are $4 . 5 M$ , $3 6 M$ for $\\mathrm { E n } { } \\mathrm { D e }$ and $\\mathrm { E n } { } \\mathrm { F r }$ respectively, valid and test data are from the corresponding newstest data. ",
559
+ "bbox": [
560
+ 174,
561
+ 656,
562
+ 485,
563
+ 849
564
+ ],
565
+ "page_idx": 4
566
+ },
567
+ {
568
+ "type": "table",
569
+ "img_path": "images/8a40ff17ffdaf4de3124008bab3758d8431428ffec1a887913cf0e71515b962f.jpg",
570
+ "table_caption": [],
571
+ "table_footnote": [
572
+ "Table 2: BLEU scores on WMT14 En→De and $\\mathrm { E n } { } \\mathrm { F r }$ machine translation tasks. "
573
+ ],
574
+ "table_body": "<table><tr><td>Method</td><td>En→De</td><td>En→Fr</td></tr><tr><td>Transformer [59]</td><td>29.12</td><td>42.69</td></tr><tr><td>MUSE [73]</td><td>29.90</td><td>43.50</td></tr><tr><td>Depth Growing [66]</td><td>30.07</td><td>43.27</td></tr><tr><td>Transformer-Admin [37]</td><td>30.10</td><td>43.80</td></tr><tr><td>Data Diversification [47]</td><td>30.70</td><td>43.70</td></tr><tr><td>BERT-fused NMT[76]</td><td>30.75</td><td>43.78</td></tr><tr><td>Transformer+RD</td><td>30.91</td><td>43.95</td></tr></table>",
575
+ "bbox": [
576
+ 508,
577
+ 665,
578
+ 816,
579
+ 795
580
+ ],
581
+ "page_idx": 4
582
+ },
583
+ {
584
+ "type": "text",
585
+ "text": "Model & Training We take the most popular Transformer [59] network as our model structure. The transformer_iwslt_de_en and transformer_vaswani_wmt_en_de_big are the configurations for IWSLT and WMT translations respectively. The weight $\\alpha$ is set as 5 for all translation tasks. Implementation is developed on Fairseq [48]. ",
586
+ "bbox": [
587
+ 174,
588
+ 856,
589
+ 826,
590
+ 911
591
+ ],
592
+ "page_idx": 4
593
+ },
594
+ {
595
+ "type": "text",
596
+ "text": "Results We calculate the BLEU scores on these tasks for evaluation, following [76]. The IWSLT performances are shown in Table 1 and the rich-resource WMT results are in Table 2. First, we can see that our R-Drop achieves more than 2.0 BLEU score improvements on 8 IWSLT translation tasks, which clearly shows the effectiveness of our method. The results on WMT translations are more impressive. After applying our simple method on the basic Transformer network, we achieve the state-of-the-art (SOTA) BLEU score on WMT14 En De (30.91) and $\\mathrm { E n } { } \\mathrm { F r }$ (43.95) translation tasks, which surpass current SOTA models, such as the BERT-fused NMT [76] model that leverages large-scale monolingual data, and the Data Diversification [47] method trained with many translation models. Note that R-Drop is complementary to the above methods, and we believe stronger results can be achieved if we apply R-Drop on their methods and better backbone models beyond Transformer. ",
597
+ "bbox": [
598
+ 173,
599
+ 90,
600
+ 825,
601
+ 229
602
+ ],
603
+ "page_idx": 5
604
+ },
605
+ {
606
+ "type": "text",
607
+ "text": "3.2 Application to Language Understanding ",
608
+ "text_level": 1,
609
+ "bbox": [
610
+ 174,
611
+ 247,
612
+ 493,
613
+ 262
614
+ ],
615
+ "page_idx": 5
616
+ },
617
+ {
618
+ "type": "text",
619
+ "text": "Dataset We further evaluate our proposed approach on the language understanding tasks by finetuning the pre-trained models3, which are the standard development sets of GLUE [61] benchmark. The GLUE benchmark includes 8 different text classification or regression tasks, which are MNLI, MRPC, QNLI, QQP, RTE, SST-2, STS-B (regression), CoLA. The detailed statistics are in Appendix. ",
620
+ "bbox": [
621
+ 173,
622
+ 273,
623
+ 826,
624
+ 330
625
+ ],
626
+ "page_idx": 5
627
+ },
628
+ {
629
+ "type": "text",
630
+ "text": "Model & Training We take the BERT-base [9] and strong RoBERTa-large [38] pre-trained models as our backbones to perform fine-tuning, which are publicly available. For each task, different random seeds and parameter settings are required, thus we dynamically adjust the coefficient $\\alpha$ among $\\{ 0 . 1 , 0 . 5 , 1 . 0 \\}$ for each setting. Other configurations are following the previous works [9, 38]. For the regression task STS-B, we use MSE instead of KL-divergence to regularize the outputs (see Appendix for MSE regularization details). ",
631
+ "bbox": [
632
+ 174,
633
+ 335,
634
+ 825,
635
+ 419
636
+ ],
637
+ "page_idx": 5
638
+ },
639
+ {
640
+ "type": "text",
641
+ "text": "Results The evaluation metrics for above 8 tasks are as follows: The result for STS-B is the Pearson correlation; Matthew’s correlation is used for CoLA; Other tasks are measured by Accuracy. The results are presented in Table 3. We can see that R-Drop achieves 1.21 points and 0.80 points (on average) improvement over the two baselines BERT-base and RoBERTa-large, respectively, which clearly demonstrate the effectiveness of R-Drop. Specifically, our RoBERTa-large $^ +$ RD also surpasses the other two strong models: XLNet-large [68] and ELECTRA-large [7], which are specially designed with different model architecture and pre-training task. ",
642
+ "bbox": [
643
+ 173,
644
+ 425,
645
+ 825,
646
+ 523
647
+ ],
648
+ "page_idx": 5
649
+ },
650
+ {
651
+ "type": "table",
652
+ "img_path": "images/a5004f7a626467a8273112a0976f37fd0a6d133a8cac9888c37e143a23ad43ea.jpg",
653
+ "table_caption": [],
654
+ "table_footnote": [
655
+ "Table 3: Fine-tuned model performances on GLUE language understanding benchmark. "
656
+ ],
657
+ "table_body": "<table><tr><td>Model</td><td>MNLI</td><td>MRPC</td><td>QNLI</td><td>QQP</td><td>RTE</td><td>SST-2</td><td>STS-B</td><td>CoLA</td><td>Avg</td></tr><tr><td>BERT-base [9]</td><td>83.8</td><td>85.3</td><td>90.8</td><td>91.0</td><td>68.2</td><td>92.4</td><td>89.3</td><td>62.3</td><td>82.85</td></tr><tr><td>BERT-base + RD</td><td>85.5</td><td>87.3</td><td>92.0</td><td>91.4</td><td>71.1</td><td>93.0</td><td>89.6</td><td>62.6</td><td>84.06</td></tr><tr><td>RoBERTa-large [38]</td><td>90.2</td><td>90.9</td><td>94.7</td><td>92.2</td><td>86.6</td><td>96.4</td><td>92.4</td><td>68.0</td><td>88.93</td></tr><tr><td>XLNet-large [68]</td><td>90.8</td><td>90.8</td><td>94.9</td><td>92.3</td><td>85.9</td><td>97.0</td><td>92.5</td><td>69.0</td><td>89.15</td></tr><tr><td>ELECRTA-large [7]</td><td>90.9</td><td>90.8</td><td>95.0</td><td>92.4</td><td>88.0</td><td>96.9</td><td>92.6</td><td>69.1</td><td>89.46</td></tr><tr><td>RoBERTa-large + RD</td><td>90.9</td><td>91.4</td><td>95.2</td><td>92.5</td><td>88.4</td><td>96.9</td><td>92.5</td><td>70.0</td><td>89.73</td></tr></table>",
658
+ "bbox": [
659
+ 176,
660
+ 537,
661
+ 823,
662
+ 660
663
+ ],
664
+ "page_idx": 5
665
+ },
666
+ {
667
+ "type": "text",
668
+ "text": "3.3 Application to Summarization ",
669
+ "text_level": 1,
670
+ "bbox": [
671
+ 174,
672
+ 699,
673
+ 423,
674
+ 714
675
+ ],
676
+ "page_idx": 5
677
+ },
678
+ {
679
+ "type": "text",
680
+ "text": "Dataset Abstractive summarization task is to summarize the long sentence/document into a short sequence/sentence (through generation) with the main content remained. For this generation task, we use the CNN/Daily Mail dataset originally introduced by Hermann et al. [22] to evaluate our method. This dataset contains news documents (source), and their corresponding highlights (target) crawled from CNN and Daily Mail website. It contains 287,226 documents for training, 13,368 documents for validation and 11,490 documents for test. We follow [34] to preprocess the dataset. ",
681
+ "bbox": [
682
+ 174,
683
+ 726,
684
+ 825,
685
+ 809
686
+ ],
687
+ "page_idx": 5
688
+ },
689
+ {
690
+ "type": "text",
691
+ "text": "Model & Training To mostly show the effectiveness, we take the super strong pre-trained sequenceto-sequence BART [34] model as our backbone and fine-tune it using our method. In this task, the coefficient weight $\\alpha$ is set as 0.7 to control the KL-divergence. For other hyper-parameters, we follow the setting of the original paper [34] without modification. ",
692
+ "bbox": [
693
+ 174,
694
+ 815,
695
+ 825,
696
+ 871
697
+ ],
698
+ "page_idx": 5
699
+ },
700
+ {
701
+ "type": "text",
702
+ "text": "Results The performance is evaluated by ROUGE F1 score [36]. Specifically, we report the unigram ROUGE1 (RG-1) and bigram ROUGE-2 (RG-2) overlap to assess the informativeness, and the longest common subsequence ROUGE-L (RG-L) score to assess the fluency. The results are shown in Table 4. We can see that R-Drop based training outperforms the fine-tuned BART model by 0.3 points on RG-1 and RG-2 score and achieves the SOTA performance. Specifically, our result also surpasses the PEGASUS method [70], which brings a novel self-supervised paradigm carefully designed for summarization, and the previous best work BART+R3F [1], which introduces a parametric noise sampled from normal or uniform distributions. Instead, our R-Drop does not introduce any extra parameters or model structure changes during training. ",
703
+ "bbox": [
704
+ 174,
705
+ 92,
706
+ 531,
707
+ 270
708
+ ],
709
+ "page_idx": 6
710
+ },
711
+ {
712
+ "type": "text",
713
+ "text": "",
714
+ "bbox": [
715
+ 173,
716
+ 271,
717
+ 823,
718
+ 299
719
+ ],
720
+ "page_idx": 6
721
+ },
722
+ {
723
+ "type": "table",
724
+ "img_path": "images/5650bca95da2a7f4df233342b8d4f50460edf31e667d6b8e9645e4b024e66102.jpg",
725
+ "table_caption": [],
726
+ "table_footnote": [
727
+ "Table 4: ROUGE results on CNN/Daily Mail summarization dataset. RG-1, RG2, RG-L stand for ROUGE-1, ROUGE-2, and ROUGE-L scores. "
728
+ ],
729
+ "table_body": "<table><tr><td>Method</td><td>RG-1</td><td>RG-2</td><td>RG-L</td></tr><tr><td>Transformer [59]</td><td>39.50</td><td>16.06</td><td>36.63</td></tr><tr><td>ProphetNet [51]</td><td>44.02</td><td>21.17</td><td>41.30</td></tr><tr><td>BART [34]</td><td>44.16</td><td>21.28</td><td>40.90</td></tr><tr><td>PEGASUS [70]</td><td>44.17</td><td>21.47</td><td>41.11</td></tr><tr><td>BART+R3F[1]</td><td>44.38</td><td>21.53</td><td>41.17</td></tr><tr><td>BART+RD</td><td>44.51</td><td>21.58</td><td>41.24</td></tr></table>",
730
+ "bbox": [
731
+ 545,
732
+ 93,
733
+ 833,
734
+ 204
735
+ ],
736
+ "page_idx": 6
737
+ },
738
+ {
739
+ "type": "text",
740
+ "text": "3.4 Application to Language Modeling ",
741
+ "text_level": 1,
742
+ "bbox": [
743
+ 176,
744
+ 320,
745
+ 455,
746
+ 337
747
+ ],
748
+ "page_idx": 6
749
+ },
750
+ {
751
+ "type": "text",
752
+ "text": "Dataset We also evaluate our approach on another widely acknowledged NLP task: language modeling. The dataset we choose for this task is the commonly adopted Wikitext-103 dataset [41], which is the largest available word-level language modeling benchmark with long-term dependency. WikiText-103 contains about $1 0 3 M$ training tokens from $2 8 K$ articles on Wikipedia, and the average length of tokens per article is about $3 . 6 K$ . The data is preprocessed by following [48]. ",
753
+ "bbox": [
754
+ 174,
755
+ 349,
756
+ 825,
757
+ 419
758
+ ],
759
+ "page_idx": 6
760
+ },
761
+ {
762
+ "type": "text",
763
+ "text": "Model & Training We take two models to conduct the language modeling task. One is the basic Transformer decoder [59], another is the more advanced one: Adaptive Input Transformer [5], which introduces adaptive input embeddings into the Transformer model. We use the open-source Fairseq [48] toolkit, and the corresponding model configurations are transformer_lm_gpt and transformer_lm_wiki103 for Transformer and Adaptive Input Transformer. We simply set the weight $\\alpha$ to be 1.0 without tuning during training. Other configurations are same as [48] and [5]. ",
764
+ "bbox": [
765
+ 173,
766
+ 425,
767
+ 825,
768
+ 508
769
+ ],
770
+ "page_idx": 6
771
+ },
772
+ {
773
+ "type": "text",
774
+ "text": "Results The evaluation metric for language modeling is perplexity, which can well measure the probability of a sentence. Same as [5], we report the perplexity on both valid and test sets. The results are shown in Table 5. From the table, we can see that our R-Drop based training improves the perplexity on both two different model structures, e.g., 0.80 perplexity improvement on test set over Adaptive Input Transformer. Besides, more improvement can be achieved when the baseline model is not so strong, e.g., 1.79 perplexity gain on valid set and 1.68 on test set above the Transformer baseline. ",
775
+ "bbox": [
776
+ 174,
777
+ 515,
778
+ 531,
779
+ 666
780
+ ],
781
+ "page_idx": 6
782
+ },
783
+ {
784
+ "type": "table",
785
+ "img_path": "images/37f036989966d132b2c5e89cd79b4e9ab69897d9143c8216682bf6fbced607b1.jpg",
786
+ "table_caption": [
787
+ "Table 5: Perplexity results on Wikitext-103 language modeling task. Adaptive refers to Adaptive Input Transformer [5]. "
788
+ ],
789
+ "table_footnote": [],
790
+ "table_body": "<table><tr><td>Method</td><td>Valid</td><td>Test</td></tr><tr><td>Transformer [59] Transformer +RD</td><td>25.76</td><td>26.62</td></tr><tr><td></td><td>23.97</td><td>24.94</td></tr><tr><td>Adaptive [5] Adaptive + RD</td><td>18.94 18.18</td><td>18.87</td></tr><tr><td></td><td></td><td>18.07</td></tr></table>",
791
+ "bbox": [
792
+ 562,
793
+ 531,
794
+ 808,
795
+ 617
796
+ ],
797
+ "page_idx": 6
798
+ },
799
+ {
800
+ "type": "text",
801
+ "text": "3.5 Application to Image Classification ",
802
+ "text_level": 1,
803
+ "bbox": [
804
+ 176,
805
+ 690,
806
+ 457,
807
+ 704
808
+ ],
809
+ "page_idx": 6
810
+ },
811
+ {
812
+ "type": "text",
813
+ "text": "Dataset For image classification, we conduct experiments on two widely acknowledged benchmark datasets, i.e., CIFAR-100 [31] and the ILSVRC-2012 ImageNet dataset [8] (denoted as ImageNet for short). CIFAR-100 dataset consists of $6 0 k$ images of 100 classes, and there are 600 images per class with 500 for training and 100 for testing. ",
814
+ "bbox": [
815
+ 173,
816
+ 718,
817
+ 825,
818
+ 773
819
+ ],
820
+ "page_idx": 6
821
+ },
822
+ {
823
+ "type": "text",
824
+ "text": "The ImageNet dataset consists of $1 . 3 M$ image samples of 1, 000 categorical classes. We utilize the same data preprocessing strategies with [11], where the details are given in [29]. ",
825
+ "bbox": [
826
+ 174,
827
+ 780,
828
+ 529,
829
+ 835
830
+ ],
831
+ "page_idx": 6
832
+ },
833
+ {
834
+ "type": "text",
835
+ "text": "Model & Training We choose the recent strong and popular Vision Transformer (ViT) [11] model as our backbone. More specifically, we take the two publicly released pre-trained models, ViT-B/16 and ViT-L/16, with $8 6 M$ and $3 0 7 M$ parameters respectively, and we conduct model fine-tuning on the CIFAR-100 and ImageNet datasets. During fine-tuning, the weight $\\alpha$ is set as 0.6 for both models, and we set other hyper-parameters/training details to be same as [11]. ",
836
+ "bbox": [
837
+ 173,
838
+ 842,
839
+ 531,
840
+ 911
841
+ ],
842
+ "page_idx": 6
843
+ },
844
+ {
845
+ "type": "table",
846
+ "img_path": "images/84b2bbf8dcfd1f102ccfc7a1e7ba56cec89230b30fda1fea40b5b4e68659630f.jpg",
847
+ "table_caption": [],
848
+ "table_footnote": [
849
+ "Table 6: Accuracy on CIFAR-100 and ImageNet classification tasks. "
850
+ ],
851
+ "table_body": "<table><tr><td>Method</td><td>CIFAR-100</td><td> ImageNet</td></tr><tr><td>ViT-B/16 [11]</td><td>92.64</td><td>83.97</td></tr><tr><td>ViT-B/16 + RD</td><td>93.29</td><td>84.38</td></tr><tr><td>ViT-L/16 [11]</td><td>93.44</td><td>85.15</td></tr><tr><td>ViT-L/16 + RD</td><td>93.85</td><td>85.57</td></tr></table>",
852
+ "bbox": [
853
+ 545,
854
+ 785,
855
+ 833,
856
+ 871
857
+ ],
858
+ "page_idx": 6
859
+ },
860
+ {
861
+ "type": "text",
862
+ "text": "",
863
+ "bbox": [
864
+ 171,
865
+ 90,
866
+ 825,
867
+ 119
868
+ ],
869
+ "page_idx": 7
870
+ },
871
+ {
872
+ "type": "text",
873
+ "text": "Results The classification performance is measured by Accuracy, and the results are presented in Table 6. For CIFAR-100, we achieve about 0.65 accuracy improvement over ViT-B/16 baseline, and 0.41 points over ViT-L/16 model. Similarly, on the large-scale ImageNet dataset, consistent improvements are also obtained. These observations demonstrate that our R-Drop can still benefit the model performance even the baseline is powerful. In a word, through the above NLP tasks and this image classification task, we clearly show R-Drop is effective and can be universally applied. ",
874
+ "bbox": [
875
+ 174,
876
+ 126,
877
+ 825,
878
+ 209
879
+ ],
880
+ "page_idx": 7
881
+ },
882
+ {
883
+ "type": "text",
884
+ "text": "4 Study ",
885
+ "text_level": 1,
886
+ "bbox": [
887
+ 174,
888
+ 234,
889
+ 253,
890
+ 252
891
+ ],
892
+ "page_idx": 7
893
+ },
894
+ {
895
+ "type": "text",
896
+ "text": "Beyond the superior experimental results, in this section, we conduct extensive studies on different perspectives to better understand our R-Drop method. The analysis experiments are performed on the IWSLT14 De→En translation task. More studies can be found in Appendix C. ",
897
+ "bbox": [
898
+ 174,
899
+ 270,
900
+ 825,
901
+ 313
902
+ ],
903
+ "page_idx": 7
904
+ },
905
+ {
906
+ "type": "text",
907
+ "text": "4.1 Regularization and Cost Analysis ",
908
+ "text_level": 1,
909
+ "bbox": [
910
+ 176,
911
+ 335,
912
+ 444,
913
+ 351
914
+ ],
915
+ "page_idx": 7
916
+ },
917
+ {
918
+ "type": "text",
919
+ "text": "We first show the regularization effect of our R-Drop and study the potential limitation of training cost (as discussed in Section 2.2). Hence, we plot the curves of training/valid loss and valid BLEU along the training update number for Transformer and Transformer $+ \\mathbf { R D }$ models. Besides, we also plot the corresponding curves along the training time (minutes). The curves are shown in Figure 2. We can observe: 1) Along with the training, Transformer quickly becomes over-fitting, and the gap between train and valid loss of Transformer is large, while R-Drop has a lower valid loss. This well proves that R-Drop can provide persistent regularization during training. 2) At the early training stage, Transformer improves the BLEU score quickly but converges to bad local optima soon. In comparison, R-Drop gradually improves the BLEU score and achieves a much superior performance. Though it needs more training to converge, the final optimum is better. This is same as other regularization methods (e.g., training w/ or w/o dropout). R-Drop indeed increases the training cost at each step since it requires repeating input $x$ for another computation in a mini-batch. Note that this is similar to batch size doubled training without KL-divergence. In Appendix C.1, we conduct this training and show that R-Drop increases negligible cost but with a much stronger performance. ",
920
+ "bbox": [
921
+ 173,
922
+ 363,
923
+ 826,
924
+ 558
925
+ ],
926
+ "page_idx": 7
927
+ },
928
+ {
929
+ "type": "image",
930
+ "img_path": "images/73f99e7168d1177f0139d37b2bbe098da4f172942a5760ab271a9d3e13a48df4.jpg",
931
+ "image_caption": [
932
+ "Figure 2: Loss/BLEU curves along with model training. "
933
+ ],
934
+ "image_footnote": [],
935
+ "bbox": [
936
+ 191,
937
+ 579,
938
+ 534,
939
+ 722
940
+ ],
941
+ "page_idx": 7
942
+ },
943
+ {
944
+ "type": "image",
945
+ "img_path": "images/a9474a564d966ad01fe136ed87498fdee77bccb63eeda72029e5796149a6d324.jpg",
946
+ "image_caption": [
947
+ "Figure 3: R-Drop with different step. "
948
+ ],
949
+ "image_footnote": [],
950
+ "bbox": [
951
+ 553,
952
+ 580,
953
+ 794,
954
+ 720
955
+ ],
956
+ "page_idx": 7
957
+ },
958
+ {
959
+ "type": "text",
960
+ "text": "4.2 $k$ -step R-Drop ",
961
+ "text_level": 1,
962
+ "bbox": [
963
+ 174,
964
+ 772,
965
+ 312,
966
+ 786
967
+ ],
968
+ "page_idx": 7
969
+ },
970
+ {
971
+ "type": "text",
972
+ "text": "The above study shows that R-Drop can achieve much stronger performance, but with a lower convergence, thus we study another training strategy that is to perform R-Drop every $k$ steps to improve the training efficiency, instead of applying at each step. We vary $k$ in $\\{ 1 , \\bar { 2 } , 5 , 1 \\bar { 0 } \\}$ to see the difference, where $k = 1$ is the current training strategy. The valid BLEU curves along with training update number and training time are presented in Figure 3. From the curves, we can conclude that though the convergence is faster with larger $k$ , the training fails to fall into good optima, which quickly over-fits, and the BLEU scores become worse and worse when we increase $k$ . This proves that our R-Drop at each step can well regularize the training and obtain superior performances. ",
973
+ "bbox": [
974
+ 173,
975
+ 800,
976
+ 825,
977
+ 911
978
+ ],
979
+ "page_idx": 7
980
+ },
981
+ {
982
+ "type": "text",
983
+ "text": "4.3 $m$ -time R-Drop ",
984
+ "text_level": 1,
985
+ "bbox": [
986
+ 174,
987
+ 90,
988
+ 320,
989
+ 106
990
+ ],
991
+ "page_idx": 8
992
+ },
993
+ {
994
+ "type": "text",
995
+ "text": "Our method regularizes the model output between two distributions $P _ { 1 } ^ { w } ( y | x )$ and $P _ { 2 } ^ { w } ( y | x )$ , and it is also interesting to see whether more improvements can be achieved if we regularize $m$ distributions for the same input data, where $m = 2$ is the current setting. Therefore, we extend our R-Drop to be: ) Pi6=ji,j∈1,··· ,m DKL(Pwi (y|x)||Pwj (y|x)), and we take m = 3 for a feasible implementation. The BLEU score for IWSLT14 $_ \\mathrm { D e \\to E n }$ test set is 37.30 when $m = 3$ , which is similar to that when $m = 2$ (37.25 BLEU score). This reflects that R-Drop already has a strong regularization effect between two distributions, without the necessity of stronger regularization. ",
996
+ "bbox": [
997
+ 173,
998
+ 117,
999
+ 825,
1000
+ 217
1001
+ ],
1002
+ "page_idx": 8
1003
+ },
1004
+ {
1005
+ "type": "text",
1006
+ "text": "4.4 Two Dropout Rates ",
1007
+ "text_level": 1,
1008
+ "bbox": [
1009
+ 174,
1010
+ 234,
1011
+ 348,
1012
+ 250
1013
+ ],
1014
+ "page_idx": 8
1015
+ },
1016
+ {
1017
+ "type": "text",
1018
+ "text": "Besides the above studies, we investigate RDrop from another perspective, i.e., the dropout values. In current training, the two distributions are based on the same dropout value (e.g., 0.3 for IWSLT translations). In this study, we utilize two different dropout values for the two output distributions during training (e.g., 0.1 for $\\bar { P } _ { 1 } ^ { w } ( y | x )$ , 0.3 for $P _ { 2 } ^ { w } ( y | x ) )$ to see the difference. We choose the two dropout rates from $\\{ 0 . 1 , 0 . 2 , 0 . 3 , 0 . 4 , 0 . 5 \\}$ with total 15 $C _ { 5 } ^ { 2 }$ for two different rates $+ ~ C _ { 5 } ^ { 1 }$ for two same rates) combinations. The results are shown in Figure 4. Among these different results, we can see that: 1) Dropout rates with the same value (0.3, 0.3) is the best choice (current setting), 2) R-Drop ",
1019
+ "bbox": [
1020
+ 174,
1021
+ 261,
1022
+ 485,
1023
+ 467
1024
+ ],
1025
+ "page_idx": 8
1026
+ },
1027
+ {
1028
+ "type": "image",
1029
+ "img_path": "images/a05ddbc73c5883ff2e7bdb07362e60d5813b2ffd3752f209b4b7d17f1db1697a.jpg",
1030
+ "image_caption": [
1031
+ "Figure 4: R-Drop with two different dropout rate combinations. Among the 25 numbers, 15 are different since the table is symmetric and triangular. "
1032
+ ],
1033
+ "image_footnote": [],
1034
+ "bbox": [
1035
+ 524,
1036
+ 258,
1037
+ 795,
1038
+ 415
1039
+ ],
1040
+ "page_idx": 8
1041
+ },
1042
+ {
1043
+ "type": "text",
1044
+ "text": "can stably achieve strong results when the two dropout rates are in a reasonable range $( 0 . 3 \\sim 0 . 5 )$ without a big performance difference. One interesting point is that even the two dropout values are both 0.5, which means half of the units are expected to be dropped, R-Drop can still obtain a satisfied result (36.48 BLEU) compared with the baseline Transformer (34.64 BLEU). These results all confirm the advantage of our R-Drop, and we are interested in studying more in the future. ",
1045
+ "bbox": [
1046
+ 174,
1047
+ 468,
1048
+ 825,
1049
+ 536
1050
+ ],
1051
+ "page_idx": 8
1052
+ },
1053
+ {
1054
+ "type": "text",
1055
+ "text": "4.5 Effect of Weight $\\alpha$ ",
1056
+ "text_level": 1,
1057
+ "bbox": [
1058
+ 174,
1059
+ 554,
1060
+ 339,
1061
+ 569
1062
+ ],
1063
+ "page_idx": 8
1064
+ },
1065
+ {
1066
+ "type": "text",
1067
+ "text": "Further, we investigate the impact of the KL-divergence loss weight $\\alpha$ . As mentioned in Section 3.1, we set $\\alpha = 5$ for NMT experiments. Here we vary the $\\alpha$ in $\\{ 1 , 3 , 5 , 7 , 1 0 \\}$ and conduct experiments. As shown in Table 7, small $\\alpha$ (e.g., 1) can not perform as good as large $\\alpha$ (e.g., 5), which means we should pay more attention to the KLdivergence regularization. However, too much regularization $( \\alpha = 1 0 )$ ) is also not good, and the best balanced choice is $\\alpha = 5$ . Note that the choice of $\\alpha$ is distinct for different tasks (e.g., NMT, language understanding), which depends on how easy the over-fitting happens caused by the specific data size and model size of each task. ",
1068
+ "bbox": [
1069
+ 174,
1070
+ 580,
1071
+ 624,
1072
+ 719
1073
+ ],
1074
+ "page_idx": 8
1075
+ },
1076
+ {
1077
+ "type": "table",
1078
+ "img_path": "images/ecb7388825810cf37527518ea9c43babe7eeb8fb427c731d10aa6f9cb5e0a9ec.jpg",
1079
+ "table_caption": [
1080
+ "Table 7: BLEU scores with different $\\alpha$ . "
1081
+ ],
1082
+ "table_footnote": [],
1083
+ "table_body": "<table><tr><td>α</td><td>TF+RD</td></tr><tr><td>α=1</td><td>36.05</td></tr><tr><td>α=3</td><td>36.85</td></tr><tr><td>α=5</td><td>37.25</td></tr><tr><td>α=7</td><td>37.20</td></tr><tr><td>α=10</td><td>36.95</td></tr></table>",
1084
+ "bbox": [
1085
+ 660,
1086
+ 579,
1087
+ 802,
1088
+ 671
1089
+ ],
1090
+ "page_idx": 8
1091
+ },
1092
+ {
1093
+ "type": "text",
1094
+ "text": "5 Related Work ",
1095
+ "text_level": 1,
1096
+ "bbox": [
1097
+ 174,
1098
+ 739,
1099
+ 321,
1100
+ 757
1101
+ ],
1102
+ "page_idx": 8
1103
+ },
1104
+ {
1105
+ "type": "text",
1106
+ "text": "Regularization Methods. Bigger models always tend to have better performance, especially for various large-scale pre-trained models, e.g., Vision Transformer [11], Swin Transformer [39], GPT families [52, 53, 6], BERT [9], BART [34], Switch Transformers [14], etc. With millions and even billions of parameters, these deep models are prone to over-fitting, thus requiring regularization strategies to improve their generalization ability [33]. To tackle with over-fitting, many regularization techniques have been proposed, e.g., weight decay [32, 30, 28, 63], dropout [24, 60, 4, 62, 57], normalization [27, 54, 3, 26, 67], adding noise [25, 50], layer-wise pre-training and initialization [12, 21], label-smoothing [58], and so on. Among which, dropout and its variants are most popular owing to its effectiveness and moderate cost as well as good compatibility with other regularization methods [45], which has been successfully applied to regularize a wide range of neural network architectures [49], e.g., convolutional neural network layers [64, 10], recurrent neural networks [17, 55, 42], Transformer [69, 75, 65]. The success of dropout methods can be interpreted by preventing co-adaptation of neurons and performing an implicit ensemble of sub models from dropout. Owing to the effect in promoting sparsity of weights and stochastic nature, dropout methods are also adapted to other applications, e.g., contrastive learning for sentence representation learning [18], neural network compression [44, 46] and model uncertainty estimation [16]. ",
1107
+ "bbox": [
1108
+ 174,
1109
+ 772,
1110
+ 825,
1111
+ 911
1112
+ ],
1113
+ "page_idx": 8
1114
+ },
1115
+ {
1116
+ "type": "text",
1117
+ "text": "",
1118
+ "bbox": [
1119
+ 174,
1120
+ 92,
1121
+ 825,
1122
+ 174
1123
+ ],
1124
+ "page_idx": 9
1125
+ },
1126
+ {
1127
+ "type": "text",
1128
+ "text": "Unlike previous researches of designing specific dropout variants or adapting dropout to different applications, we consider to further regularize the model on the success of dropout. Specifically, any two sub models sampled from dropout are encouraged to produce consistent model prediction for an input data by utilizing KL-divergence in the training stage. That is, we conduct regularization on the model output level. In doing so, the sub model outputs produced by the randomness of dropout are regularized to reduce the parameter freedom, which will enhance generalization in inference. ",
1129
+ "bbox": [
1130
+ 174,
1131
+ 181,
1132
+ 823,
1133
+ 263
1134
+ ],
1135
+ "page_idx": 9
1136
+ },
1137
+ {
1138
+ "type": "text",
1139
+ "text": "Consistency Training. Besides regularization methods, our work also relates to a few works of consistency training on dropout models or data augmentation. Among them, the most representative methods are ELD [40], FD [77], and Cutoff [56]. As discussed in Section 2.4, ELD only focuses on the inconsistency between the sub model with dropout (train) and the expected full-model without dropout (inference), while FD works between the sub models only (consistence between two sub models). Both ELD and FD utilize $L _ { 2 }$ to regularize the hidden space. Instead, our R-Drop performs consistency training on dropout from the output space with a more effective bidirectional KL loss. Unlike the above consistency training method on sub models, Cutoff resembles launching consistency training from a data perspective by regularizing the inconsistency between the original data the augmented samples with part of the information within an input sentence being erased. ",
1140
+ "bbox": [
1141
+ 174,
1142
+ 270,
1143
+ 825,
1144
+ 409
1145
+ ],
1146
+ "page_idx": 9
1147
+ },
1148
+ {
1149
+ "type": "text",
1150
+ "text": "Self-distillation. Minimizing the KL-divergence between the output distributions of two different models correlates with knowledge distillation [23, 15, 2, 35, 13, 74], where the two models refer to teacher and student, respectively. In our setting, the teacher and student are the dropout instantiations of the same model, and thus it resembles self-knowledge distillation [43] scenario. Different from existing method that exploits dark knowledge from the model itself [20, 19] or distills knowledge between different layers [71], our strategy can be regarded as an instance-wise self-knowledge distillation, i.e., each pair of sampled sub models perform distillation between each other for the same input, which also relates to mutual learning [72] but ours is much more efficient without extra parameters. ",
1151
+ "bbox": [
1152
+ 174,
1153
+ 415,
1154
+ 825,
1155
+ 539
1156
+ ],
1157
+ "page_idx": 9
1158
+ },
1159
+ {
1160
+ "type": "text",
1161
+ "text": "6 Conclusions and Future Work ",
1162
+ "text_level": 1,
1163
+ "bbox": [
1164
+ 176,
1165
+ 563,
1166
+ 457,
1167
+ 580
1168
+ ],
1169
+ "page_idx": 9
1170
+ },
1171
+ {
1172
+ "type": "text",
1173
+ "text": "In this paper, we proposed a simple yet very effective consistency training method built upon dropout, namely R-Drop, which minimizes the bidirectional KL-divergence of the output distributions of any pair of sub models sampled from dropout in model training. Experimental results on 18 popular deep learning datasets show that not only can our R-Drop effectively enhance strong models, e.g., ViT, BART, Roberta-large, but also work well on large-scale datasets and even achieve SOTA performances when combined with vanilla Transformer on WMT14 English German and English French translations. Due to the limitation of computational resources, for pre-training related tasks, we only tested R-Drop on downstream task fine-tuning in this work. We will test it on pre-training in the future. In this work, we focused on Transformer based models. We will apply R-Drop to other network architectures such as convolutional neural networks. ",
1174
+ "bbox": [
1175
+ 174,
1176
+ 595,
1177
+ 825,
1178
+ 734
1179
+ ],
1180
+ "page_idx": 9
1181
+ },
1182
+ {
1183
+ "type": "text",
1184
+ "text": "Acknowledgments and Disclosure of Funding ",
1185
+ "text_level": 1,
1186
+ "bbox": [
1187
+ 174,
1188
+ 757,
1189
+ 553,
1190
+ 775
1191
+ ],
1192
+ "page_idx": 9
1193
+ },
1194
+ {
1195
+ "type": "text",
1196
+ "text": "We would like to thank the reviewers for their constructive comments. Juntao Li is the corresponding author. This work was supported by the National Science Foundation of China (NSFC No. 62036004). ",
1197
+ "bbox": [
1198
+ 173,
1199
+ 791,
1200
+ 825,
1201
+ 819
1202
+ ],
1203
+ "page_idx": 9
1204
+ },
1205
+ {
1206
+ "type": "text",
1207
+ "text": "References ",
1208
+ "text_level": 1,
1209
+ "bbox": [
1210
+ 174,
1211
+ 843,
1212
+ 266,
1213
+ 859
1214
+ ],
1215
+ "page_idx": 9
1216
+ },
1217
+ {
1218
+ "type": "text",
1219
+ "text": "[1] Armen Aghajanyan, Akshat Shrivastava, Anchit Gupta, Naman Goyal, Luke Zettlemoyer, and Sonal Gupta. Better fine-tuning by reducing representational collapse. arXiv preprint arXiv:2008.03156, 2020. ",
1220
+ "bbox": [
1221
+ 183,
1222
+ 869,
1223
+ 825,
1224
+ 911
1225
+ ],
1226
+ "page_idx": 9
1227
+ },
1228
+ {
1229
+ "type": "text",
1230
+ "text": "[2] Zeyuan Allen-Zhu and Yuanzhi Li. Towards understanding ensemble, knowledge distillation and self-distillation in deep learning. arXiv preprint arXiv:2012.09816, 2020. ",
1231
+ "bbox": [
1232
+ 178,
1233
+ 90,
1234
+ 823,
1235
+ 121
1236
+ ],
1237
+ "page_idx": 10
1238
+ },
1239
+ {
1240
+ "type": "text",
1241
+ "text": "[3] Jimmy Lei Ba, Jamie Ryan Kiros, and Geoffrey E Hinton. Layer normalization. arXiv preprint arXiv:1607.06450, 2016. ",
1242
+ "bbox": [
1243
+ 178,
1244
+ 130,
1245
+ 823,
1246
+ 159
1247
+ ],
1248
+ "page_idx": 10
1249
+ },
1250
+ {
1251
+ "type": "text",
1252
+ "text": "[4] Lei Jimmy Ba and Brendan Frey. Adaptive dropout for training deep neural networks. In Proceedings of the 26th International Conference on Neural Information Processing SystemsVolume 2, pp. 3084–3092, 2013. ",
1253
+ "bbox": [
1254
+ 179,
1255
+ 169,
1256
+ 823,
1257
+ 212
1258
+ ],
1259
+ "page_idx": 10
1260
+ },
1261
+ {
1262
+ "type": "text",
1263
+ "text": "[5] Alexei Baevski and Michael Auli. Adaptive input representations for neural language modeling. In International Conference on Learning Representations, 2018. ",
1264
+ "bbox": [
1265
+ 179,
1266
+ 222,
1267
+ 823,
1268
+ 251
1269
+ ],
1270
+ "page_idx": 10
1271
+ },
1272
+ {
1273
+ "type": "text",
1274
+ "text": "[6] Tom B Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah, Jared Kaplan, Prafulla Dhariwal, Arvind Neelakantan, Pranav Shyam, Girish Sastry, Amanda Askell, et al. Language models are few-shot learners. arXiv preprint arXiv:2005.14165, 2020. ",
1275
+ "bbox": [
1276
+ 179,
1277
+ 261,
1278
+ 825,
1279
+ 304
1280
+ ],
1281
+ "page_idx": 10
1282
+ },
1283
+ {
1284
+ "type": "text",
1285
+ "text": "[7] Kevin Clark, Minh-Thang Luong, Quoc V Le, and Christopher D Manning. Electra: Pre-training text encoders as discriminators rather than generators. In International Conference on Learning Representations, 2019. ",
1286
+ "bbox": [
1287
+ 179,
1288
+ 314,
1289
+ 823,
1290
+ 357
1291
+ ],
1292
+ "page_idx": 10
1293
+ },
1294
+ {
1295
+ "type": "text",
1296
+ "text": "[8] Jia Deng, Wei Dong, Richard Socher, Li-Jia Li, Kai Li, and Li Fei-Fei. Imagenet: A largescale hierarchical image database. In 2009 IEEE conference on computer vision and pattern recognition, pp. 248–255. Ieee, 2009. ",
1297
+ "bbox": [
1298
+ 179,
1299
+ 366,
1300
+ 823,
1301
+ 410
1302
+ ],
1303
+ "page_idx": 10
1304
+ },
1305
+ {
1306
+ "type": "text",
1307
+ "text": "[9] Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. Bert: Pre-training of deep bidirectional transformers for language understanding. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pp. 4171–4186, 2019. ",
1308
+ "bbox": [
1309
+ 179,
1310
+ 420,
1311
+ 825,
1312
+ 477
1313
+ ],
1314
+ "page_idx": 10
1315
+ },
1316
+ {
1317
+ "type": "text",
1318
+ "text": "[10] Terrance DeVries and Graham W Taylor. Improved regularization of convolutional neural networks with cutout. arXiv preprint arXiv:1708.04552, 2017. ",
1319
+ "bbox": [
1320
+ 173,
1321
+ 486,
1322
+ 823,
1323
+ 516
1324
+ ],
1325
+ "page_idx": 10
1326
+ },
1327
+ {
1328
+ "type": "text",
1329
+ "text": "[11] Alexey Dosovitskiy, Lucas Beyer, Alexander Kolesnikov, Dirk Weissenborn, Xiaohua Zhai, Thomas Unterthiner, Mostafa Dehghani, Matthias Minderer, Georg Heigold, Sylvain Gelly, Jakob Uszkoreit, and Neil Houlsby. An image is worth 16x16 words: Transformers for image recognition at scale. In International Conference on Learning Representations, 2021. ",
1330
+ "bbox": [
1331
+ 173,
1332
+ 525,
1333
+ 825,
1334
+ 583
1335
+ ],
1336
+ "page_idx": 10
1337
+ },
1338
+ {
1339
+ "type": "text",
1340
+ "text": "[12] Dumitru Erhan, Pierre-Antoine Manzagol, Yoshua Bengio, Samy Bengio, and Pascal Vincent. The difficulty of training deep architectures and the effect of unsupervised pre-training. In Artificial Intelligence and Statistics, pp. 153–160. PMLR, 2009. ",
1341
+ "bbox": [
1342
+ 173,
1343
+ 592,
1344
+ 823,
1345
+ 636
1346
+ ],
1347
+ "page_idx": 10
1348
+ },
1349
+ {
1350
+ "type": "text",
1351
+ "text": "[13] Zhiyuan Fang, Jianfeng Wang, Lijuan Wang, Lei Zhang, Yezhou Yang, and Zicheng Liu. Seed: Self-supervised distillation for visual representation. International Conference on Learning Representations, 2021. ",
1352
+ "bbox": [
1353
+ 171,
1354
+ 645,
1355
+ 823,
1356
+ 689
1357
+ ],
1358
+ "page_idx": 10
1359
+ },
1360
+ {
1361
+ "type": "text",
1362
+ "text": "[14] William Fedus, Barret Zoph, and Noam Shazeer. Switch transformers: Scaling to trillion parameter models with simple and efficient sparsity. arXiv preprint arXiv:2101.03961, 2021. ",
1363
+ "bbox": [
1364
+ 171,
1365
+ 698,
1366
+ 823,
1367
+ 728
1368
+ ],
1369
+ "page_idx": 10
1370
+ },
1371
+ {
1372
+ "type": "text",
1373
+ "text": "[15] Tommaso Furlanello, Zachary Lipton, Michael Tschannen, Laurent Itti, and Anima Anandkumar. Born again neural networks. In International Conference on Machine Learning, pp. 1607–1616. PMLR, 2018. ",
1374
+ "bbox": [
1375
+ 173,
1376
+ 737,
1377
+ 825,
1378
+ 780
1379
+ ],
1380
+ "page_idx": 10
1381
+ },
1382
+ {
1383
+ "type": "text",
1384
+ "text": "[16] Yarin Gal and Zoubin Ghahramani. Dropout as a bayesian approximation: Representing model uncertainty in deep learning. In international conference on machine learning, pp. 1050–1059. PMLR, 2016. ",
1385
+ "bbox": [
1386
+ 173,
1387
+ 790,
1388
+ 825,
1389
+ 833
1390
+ ],
1391
+ "page_idx": 10
1392
+ },
1393
+ {
1394
+ "type": "text",
1395
+ "text": "[17] Yarin Gal and Zoubin Ghahramani. A theoretically grounded application of dropout in recurrent neural networks. Advances in neural information processing systems, 29:1019–1027, 2016. ",
1396
+ "bbox": [
1397
+ 171,
1398
+ 843,
1399
+ 825,
1400
+ 872
1401
+ ],
1402
+ "page_idx": 10
1403
+ },
1404
+ {
1405
+ "type": "text",
1406
+ "text": "[18] Tianyu Gao, Xingcheng Yao, and Danqi Chen. Simcse: Simple contrastive learning of sentence embeddings. arXiv preprint arXiv:2104.08821, 2021. ",
1407
+ "bbox": [
1408
+ 173,
1409
+ 882,
1410
+ 820,
1411
+ 911
1412
+ ],
1413
+ "page_idx": 10
1414
+ },
1415
+ {
1416
+ "type": "text",
1417
+ "text": "[19] Akhilesh Gotmare, Nitish Shirish Keskar, Caiming Xiong, and Richard Socher. A closer look at deep learning heuristics: Learning rate restarts, warmup and distillation. In International Conference on Learning Representations, 2019. ",
1418
+ "bbox": [
1419
+ 171,
1420
+ 90,
1421
+ 825,
1422
+ 133
1423
+ ],
1424
+ "page_idx": 11
1425
+ },
1426
+ {
1427
+ "type": "text",
1428
+ "text": "[20] Sangchul Hahn and Heeyoul Choi. Self-knowledge distillation in natural language processing. In Proceedings of the International Conference on Recent Advances in Natural Language Processing (RANLP 2019), pp. 423–430, 2019. ",
1429
+ "bbox": [
1430
+ 173,
1431
+ 142,
1432
+ 821,
1433
+ 185
1434
+ ],
1435
+ "page_idx": 11
1436
+ },
1437
+ {
1438
+ "type": "text",
1439
+ "text": "[21] Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. Delving deep into rectifiers: Surpassing human-level performance on imagenet classification. In Proceedings of the IEEE international conference on computer vision, pp. 1026–1034, 2015. ",
1440
+ "bbox": [
1441
+ 171,
1442
+ 195,
1443
+ 823,
1444
+ 238
1445
+ ],
1446
+ "page_idx": 11
1447
+ },
1448
+ {
1449
+ "type": "text",
1450
+ "text": "[22] Karl Moritz Hermann, Tomáš Kocisk ˇ y, Edward Grefenstette, Lasse Espeholt, Will Kay, Mustafa \\` Suleyman, and Phil Blunsom. Teaching machines to read and comprehend. arXiv preprint arXiv:1506.03340, 2015. ",
1451
+ "bbox": [
1452
+ 173,
1453
+ 247,
1454
+ 823,
1455
+ 290
1456
+ ],
1457
+ "page_idx": 11
1458
+ },
1459
+ {
1460
+ "type": "text",
1461
+ "text": "[23] Geoffrey Hinton, Oriol Vinyals, and Jeff Dean. Distilling the knowledge in a neural network. arXiv preprint arXiv:1503.02531, 2015. ",
1462
+ "bbox": [
1463
+ 171,
1464
+ 299,
1465
+ 825,
1466
+ 329
1467
+ ],
1468
+ "page_idx": 11
1469
+ },
1470
+ {
1471
+ "type": "text",
1472
+ "text": "[24] Geoffrey E Hinton, Nitish Srivastava, Alex Krizhevsky, Ilya Sutskever, and Ruslan R Salakhutdinov. Improving neural networks by preventing co-adaptation of feature detectors. arXiv preprint arXiv:1207.0580, 2012. ",
1473
+ "bbox": [
1474
+ 173,
1475
+ 337,
1476
+ 823,
1477
+ 380
1478
+ ],
1479
+ "page_idx": 11
1480
+ },
1481
+ {
1482
+ "type": "text",
1483
+ "text": "[25] Sepp Hochreiter and Jürgen Schmidhuber. Simplifying neural nets by discovering flat minima. In Advances in neural information processing systems, pp. 529–536, 1995. ",
1484
+ "bbox": [
1485
+ 169,
1486
+ 388,
1487
+ 825,
1488
+ 420
1489
+ ],
1490
+ "page_idx": 11
1491
+ },
1492
+ {
1493
+ "type": "text",
1494
+ "text": "[26] Lei Huang, Xianglong Liu, Bo Lang, Adams Yu, Yongliang Wang, and Bo Li. Orthogonal weight normalization: Solution to optimization over multiple dependent stiefel manifolds in deep neural networks. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 32, 2018. ",
1495
+ "bbox": [
1496
+ 173,
1497
+ 428,
1498
+ 826,
1499
+ 484
1500
+ ],
1501
+ "page_idx": 11
1502
+ },
1503
+ {
1504
+ "type": "text",
1505
+ "text": "[27] Sergey Ioffe and Christian Szegedy. Batch normalization: Accelerating deep network training by reducing internal covariate shift. In International conference on machine learning, pp. 448–456. PMLR, 2015. ",
1506
+ "bbox": [
1507
+ 173,
1508
+ 493,
1509
+ 823,
1510
+ 536
1511
+ ],
1512
+ "page_idx": 11
1513
+ },
1514
+ {
1515
+ "type": "text",
1516
+ "text": "[28] Guoliang Kang, Jun Li, and Dacheng Tao. Shakeout: A new regularized deep neural network training scheme. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 30, 2016. ",
1517
+ "bbox": [
1518
+ 173,
1519
+ 545,
1520
+ 823,
1521
+ 588
1522
+ ],
1523
+ "page_idx": 11
1524
+ },
1525
+ {
1526
+ "type": "text",
1527
+ "text": "[29] 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. ",
1528
+ "bbox": [
1529
+ 173,
1530
+ 597,
1531
+ 823,
1532
+ 641
1533
+ ],
1534
+ "page_idx": 11
1535
+ },
1536
+ {
1537
+ "type": "text",
1538
+ "text": "[30] Alex Krizhevsky, Ilya Sutskever, and Geoffrey E Hinton. Imagenet classification with deep convolutional neural networks. Advances in neural information processing systems, 25:1097– 1105, 2012. ",
1539
+ "bbox": [
1540
+ 174,
1541
+ 650,
1542
+ 826,
1543
+ 693
1544
+ ],
1545
+ "page_idx": 11
1546
+ },
1547
+ {
1548
+ "type": "text",
1549
+ "text": "[31] Alex Krizhevsky et al. Learning multiple layers of features from tiny images. 2009. ",
1550
+ "bbox": [
1551
+ 169,
1552
+ 702,
1553
+ 759,
1554
+ 718
1555
+ ],
1556
+ "page_idx": 11
1557
+ },
1558
+ {
1559
+ "type": "text",
1560
+ "text": "[32] Anders Krogh and John A Hertz. A simple weight decay can improve generalization. In Advances in neural information processing systems, pp. 950–957, 1992. ",
1561
+ "bbox": [
1562
+ 171,
1563
+ 727,
1564
+ 823,
1565
+ 756
1566
+ ],
1567
+ "page_idx": 11
1568
+ },
1569
+ {
1570
+ "type": "text",
1571
+ "text": "[33] Alex Labach, Hojjat Salehinejad, and Shahrokh Valaee. Survey of dropout methods for deep neural networks. arXiv preprint arXiv:1904.13310, 2019. ",
1572
+ "bbox": [
1573
+ 171,
1574
+ 765,
1575
+ 823,
1576
+ 795
1577
+ ],
1578
+ "page_idx": 11
1579
+ },
1580
+ {
1581
+ "type": "text",
1582
+ "text": "[34] Mike Lewis, Yinhan Liu, Naman Goyal, Marjan Ghazvininejad, Abdelrahman Mohamed, Omer Levy, Veselin Stoyanov, and Luke Zettlemoyer. Bart: Denoising sequence-to-sequence pretraining for natural language generation, translation, and comprehension. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pp. 7871–7880, 2020. ",
1583
+ "bbox": [
1584
+ 176,
1585
+ 803,
1586
+ 821,
1587
+ 859
1588
+ ],
1589
+ "page_idx": 11
1590
+ },
1591
+ {
1592
+ "type": "text",
1593
+ "text": "[35] Kevin J Liang, Weituo Hao, Dinghan Shen, Yufan Zhou, Weizhu Chen, Changyou Chen, and Lawrence Carin. Mixkd: Towards efficient distillation of large-scale language models. International Conference on Learning Representations, 2021. ",
1594
+ "bbox": [
1595
+ 174,
1596
+ 868,
1597
+ 828,
1598
+ 912
1599
+ ],
1600
+ "page_idx": 11
1601
+ },
1602
+ {
1603
+ "type": "text",
1604
+ "text": "[36] Chin-Yew Lin and Eduard Hovy. Manual and automatic evaluation of summaries. In Proceedings of the ACL-02 Workshop on Automatic Summarization, pp. 45–51, 2002. \n[37] Xiaodong Liu, Kevin Duh, Liyuan Liu, and Jianfeng Gao. Very deep transformers for neural machine translation. arXiv preprint arXiv:2008.07772, 2020. \n[38] Yinhan Liu, Myle Ott, Naman Goyal, Jingfei Du, Mandar Joshi, Danqi Chen, Omer Levy, Mike Lewis, Luke Zettlemoyer, and Veselin Stoyanov. Roberta: A robustly optimized bert pretraining approach. arXiv preprint arXiv:1907.11692, 2019. \n[39] Ze Liu, Yutong Lin, Yue Cao, Han Hu, Yixuan Wei, Zheng Zhang, Stephen Lin, and Baining Guo. Swin transformer: Hierarchical vision transformer using shifted windows. arXiv preprint arXiv:2103.14030, 2021. \n[40] Xuezhe Ma, Yingkai Gao, Zhiting Hu, Yaoliang Yu, Yuntian Deng, and Eduard Hovy. Dropout with expectation-linear regularization. arXiv preprint arXiv:1609.08017, 2016. \n[41] Stephen Merity, Caiming Xiong, James Bradbury, and Richard Socher. Pointer sentinel mixture models. arXiv preprint arXiv:1609.07843, 2016. \n[42] Stephen Merity, Nitish Shirish Keskar, and Richard Socher. Regularizing and optimizing lstm language models. In International Conference on Learning Representations, 2018. \n[43] Hossein Mobahi, Mehrdad Farajtabar, and Peter L Bartlett. Self-distillation amplifies regularization in hilbert space. arXiv preprint arXiv:2002.05715, 2020. \n[44] Dmitry Molchanov, Arsenii Ashukha, and Dmitry Vetrov. Variational dropout sparsifies deep neural networks. In International Conference on Machine Learning, pp. 2498–2507. PMLR, 2017. \n[45] Reza Moradi, Reza Berangi, and Behrouz Minaei. A survey of regularization strategies for deep models. Artificial Intelligence Review, 53(6):3947–3986, 2020. \n[46] Kirill Neklyudov, Dmitry Molchanov, Arsenii Ashukha, and Dmitry Vetrov. Structured bayesian pruning via log-normal multiplicative noise. In Proceedings of the 31st International Conference on Neural Information Processing Systems, pp. 6778–6787, 2017. \n[47] Xuan-Phi Nguyen, Shafiq Joty, Kui Wu, and Ai Ti Aw. Data diversification: A simple strategy for neural machine translation. In Advances in Neural Information Processing Systems, pp. 10018–10029, 2020. \n[48] Myle Ott, Sergey Edunov, Alexei Baevski, Angela Fan, Sam Gross, Nathan Ng, David Grangier, and Michael Auli. fairseq: A fast, extensible toolkit for sequence modeling. In NAACL-HLT (Demonstrations), 2019. \n[49] Hieu Pham and Quoc V Le. Autodropout: Learning dropout patterns to regularize deep networks. arXiv preprint arXiv:2101.01761, 2021. \n[50] Ben Poole, Jascha Sohl-Dickstein, and Surya Ganguli. Analyzing noise in autoencoders and deep networks. arXiv preprint arXiv:1406.1831, 2014. \n[51] Weizhen Qi, Yu Yan, Yeyun Gong, Dayiheng Liu, Nan Duan, Jiusheng Chen, Ruofei Zhang, and Ming Zhou. Prophetnet: Predicting future n-gram for sequence-to-sequence pre-training. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing: Findings, pp. 2401–2410, 2020. \n[52] Alec Radford, Karthik Narasimhan, Tim Salimans, and Ilya Sutskever. Improving language understanding by generative pre-training. \n[53] Alec Radford, Jeffrey Wu, Rewon Child, David Luan, Dario Amodei, and Ilya Sutskever. Language models are unsupervised multitask learners. OpenAI blog, 1(8):9, 2019. \n[54] Tim Salimans and Diederik P Kingma. Weight normalization: a simple reparameterization to accelerate training of deep neural networks. In Proceedings of the 30th International Conference on Neural Information Processing Systems, pp. 901–909, 2016. \n[55] Stanislau Semeniuta, Aliaksei Severyn, and Erhardt Barth. Recurrent dropout without memory loss. In Proceedings of COLING 2016, the 26th International Conference on Computational Linguistics: Technical Papers, pp. 1757–1766, 2016. \n[56] Dinghan Shen, Mingzhi Zheng, Yelong Shen, Yanru Qu, and Weizhu Chen. A simple but tough-to-beat data augmentation approach for natural language understanding and generation. arXiv preprint arXiv:2009.13818, 2020. \n[57] Nitish Srivastava, Geoffrey Hinton, Alex Krizhevsky, Ilya Sutskever, and Ruslan Salakhutdinov. Dropout: a simple way to prevent neural networks from overfitting. The journal of machine learning research, 15(1):1929–1958, 2014. \n[58] Christian Szegedy, Vincent Vanhoucke, Sergey Ioffe, Jon Shlens, and Zbigniew Wojna. Rethinking the inception architecture for computer vision. In Proceedings of the IEEE conference on computer vision and pattern recognition, pp. 2818–2826, 2016. \n[59] Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Łukasz Kaiser, and Illia Polosukhin. Attention is all you need. In Proceedings of the 31st International Conference on Neural Information Processing Systems, pp. 6000–6010, 2017. \n[60] Li Wan, Matthew Zeiler, Sixin Zhang, Yann Le Cun, and Rob Fergus. Regularization of neural networks using dropconnect. In International conference on machine learning, pp. 1058–1066. PMLR, 2013. \n[61] Alex Wang, Amanpreet Singh, Julian Michael, Felix Hill, Omer Levy, and Samuel Bowman. Glue: A multi-task benchmark and analysis platform for natural language understanding. In Proceedings of the 2018 EMNLP Workshop BlackboxNLP: Analyzing and Interpreting Neural Networks for NLP, pp. 353–355, 2018. \n[62] Sida Wang and Christopher Manning. Fast dropout training. In international conference on machine learning, pp. 118–126. PMLR, 2013. \n[63] Wei Wen, Chunpeng Wu, Yandan Wang, Yiran Chen, and Hai Li. Learning structured sparsity in deep neural networks. In Proceedings of the 30th International Conference on Neural Information Processing Systems, pp. 2082–2090, 2016. \n[64] Haibing Wu and Xiaodong Gu. Towards dropout training for convolutional neural networks. Neural Networks, 71:1–10, 2015. \n[65] Hongqiu Wu, Hai Zhao, and Min Zhang. Not all attention is all you need. arXiv preprint arXiv:2104.04692, 2021. \n[66] Lijun Wu, Yiren Wang, Yingce Xia, Fei Tian, Fei Gao, Tao Qin, Jianhuang Lai, and Tie-Yan Liu. Depth growing for neural machine translation. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pp. 5558–5563, 2019. \n[67] Yuxin Wu and Kaiming He. Group normalization. In Proceedings of the European conference on computer vision (ECCV), pp. 3–19, 2018. \n[68] Zhilin Yang, Zihang Dai, Yiming Yang, Jaime Carbonell, Russ R Salakhutdinov, and Quoc V Le. Xlnet: Generalized autoregressive pretraining for language understanding. Advances in Neural Information Processing Systems, 32:5753–5763, 2019. \n[69] Lin Zehui, Pengfei Liu, Luyao Huang, Junkun Chen, Xipeng Qiu, and Xuanjing Huang. Dropattention: A regularization method for fully-connected self-attention networks. arXiv preprint arXiv:1907.11065, 2019. \n[70] Jingqing Zhang, Yao Zhao, Mohammad Saleh, and Peter Liu. Pegasus: Pre-training with extracted gap-sentences for abstractive summarization. In International Conference on Machine Learning, pp. 11328–11339. PMLR, 2020. \n[71] Linfeng Zhang, Jiebo Song, Anni Gao, Jingwei Chen, Chenglong Bao, and Kaisheng Ma. Be your own teacher: Improve the performance of convolutional neural networks via self distillation. In Proceedings of the IEEE/CVF International Conference on Computer Vision, pp. 3713–3722, 2019. \n[72] Ying Zhang, Tao Xiang, Timothy M Hospedales, and Huchuan Lu. Deep mutual learning. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pp. 4320–4328, 2018. \n[73] Guangxiang Zhao, Xu Sun, Jingjing Xu, Zhiyuan Zhang, and Liangchen Luo. Muse: Parallel multi-scale attention for sequence to sequence learning. arXiv preprint arXiv:1911.09483, 2019. \n[74] Helong Zhou, Liangchen Song, Jiajie Chen, Ye Zhou, Guoli Wang, Junsong Yuan, and Qian Zhang. Rethinking soft labels for knowledge distillation: A bias-variance tradeoff perspective. International Conference on Learning Representations, 2021. \n[75] Wangchunshu Zhou, Tao Ge, Furu Wei, Ming Zhou, and Ke Xu. Scheduled drophead: A regularization method for transformer models. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing: Findings, pp. 1971–1980, 2020. \n[76] Jinhua Zhu, Yingce Xia, Lijun Wu, Di He, Tao Qin, Wengang Zhou, Houqiang Li, and Tieyan Liu. Incorporating bert into neural machine translation. In International Conference on Learning Representations, 2019. \n[77] Konrad Zolna, Devansh Arpit, Dendi Suhubdy, and Yoshua Bengio. Fraternal dropout. 2018. ",
1605
+ "bbox": [
1606
+ 171,
1607
+ 71,
1608
+ 828,
1609
+ 919
1610
+ ],
1611
+ "page_idx": 12
1612
+ },
1613
+ {
1614
+ "type": "text",
1615
+ "text": "",
1616
+ "bbox": [
1617
+ 169,
1618
+ 90,
1619
+ 828,
1620
+ 917
1621
+ ],
1622
+ "page_idx": 13
1623
+ },
1624
+ {
1625
+ "type": "text",
1626
+ "text": "",
1627
+ "bbox": [
1628
+ 169,
1629
+ 89,
1630
+ 828,
1631
+ 354
1632
+ ],
1633
+ "page_idx": 14
1634
+ },
1635
+ {
1636
+ "type": "text",
1637
+ "text": "Checklist ",
1638
+ "text_level": 1,
1639
+ "bbox": [
1640
+ 174,
1641
+ 89,
1642
+ 254,
1643
+ 106
1644
+ ],
1645
+ "page_idx": 15
1646
+ },
1647
+ {
1648
+ "type": "text",
1649
+ "text": "1. For all authors... ",
1650
+ "bbox": [
1651
+ 214,
1652
+ 116,
1653
+ 339,
1654
+ 130
1655
+ ],
1656
+ "page_idx": 15
1657
+ },
1658
+ {
1659
+ "type": "text",
1660
+ "text": "(a) Do the main claims made in the abstract and introduction accurately reflect the paper’s contributions and scope? [Yes] We provide strong results in the experiments, and our theoretical analysis in Section 2.3. \n(b) Did you describe the limitations of your work? [Yes] Our limitation lies in potential training cost per epoch, but we demonstrate it is not when comparing with batch size doubled training and the superior performances can be achieved at almost same training time. We provide discussions in Section 2.2 and Section 4. \n(c) Did you discuss any potential negative societal impacts of your work? [No] We think our general training method will not lead to any negative societal impact. \n(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes] ",
1661
+ "bbox": [
1662
+ 238,
1663
+ 135,
1664
+ 825,
1665
+ 295
1666
+ ],
1667
+ "page_idx": 15
1668
+ },
1669
+ {
1670
+ "type": "text",
1671
+ "text": "2. If you are including theoretical results... ",
1672
+ "bbox": [
1673
+ 215,
1674
+ 299,
1675
+ 493,
1676
+ 314
1677
+ ],
1678
+ "page_idx": 15
1679
+ },
1680
+ {
1681
+ "type": "text",
1682
+ "text": "(a) Did you state the full set of assumptions of all theoretical results? [Yes] We discuss in Section 2.3. \n(b) Did you include complete proofs of all theoretical results? [Yes] We provide discussion in Section 2.3 and Appendix B. ",
1683
+ "bbox": [
1684
+ 238,
1685
+ 318,
1686
+ 825,
1687
+ 376
1688
+ ],
1689
+ "page_idx": 15
1690
+ },
1691
+ {
1692
+ "type": "text",
1693
+ "text": "3. If you ran experiments... ",
1694
+ "bbox": [
1695
+ 214,
1696
+ 381,
1697
+ 393,
1698
+ 395
1699
+ ],
1700
+ "page_idx": 15
1701
+ },
1702
+ {
1703
+ "type": "text",
1704
+ "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 provide a anonymous github url for our project. \n(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] We provide the details in Section 3 and Appendix A. \n(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [Yes] We report the average results (number) for multiple runs of most experiments instead of the 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] We provide the details in Appendix A. ",
1705
+ "bbox": [
1706
+ 238,
1707
+ 400,
1708
+ 825,
1709
+ 558
1710
+ ],
1711
+ "page_idx": 15
1712
+ },
1713
+ {
1714
+ "type": "text",
1715
+ "text": "4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets... ",
1716
+ "bbox": [
1717
+ 212,
1718
+ 564,
1719
+ 823,
1720
+ 578
1721
+ ],
1722
+ "page_idx": 15
1723
+ },
1724
+ {
1725
+ "type": "text",
1726
+ "text": "(a) If your work uses existing assets, did you cite the creators? [Yes] We provide the citations for each data and the url for open-souce code. \n(b) Did you mention the license of the assets? [No] We use the publicly popular datasets for each experiments, and the details can be found in Section 3. \n(c) Did you include any new assets either in the supplemental material or as a URL? [No] We do not provide new datasets. \n(d) Did you discuss whether and how consent was obtained from people whose data you’re using/curating? [N/A] We use public dataset. \n(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A] We use public dataset. ",
1727
+ "bbox": [
1728
+ 238,
1729
+ 583,
1730
+ 825,
1731
+ 731
1732
+ ],
1733
+ "page_idx": 15
1734
+ },
1735
+ {
1736
+ "type": "text",
1737
+ "text": "5. If you used crowdsourcing or conducted research with human subjects... ",
1738
+ "bbox": [
1739
+ 214,
1740
+ 736,
1741
+ 705,
1742
+ 750
1743
+ ],
1744
+ "page_idx": 15
1745
+ },
1746
+ {
1747
+ "type": "text",
1748
+ "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] ",
1749
+ "bbox": [
1750
+ 238,
1751
+ 753,
1752
+ 825,
1753
+ 843
1754
+ ],
1755
+ "page_idx": 15
1756
+ }
1757
+ ]
parse/train/bw5Arp3O3eY/bw5Arp3O3eY_middle.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/bw5Arp3O3eY/bw5Arp3O3eY_model.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/rywDjg-RW/rywDjg-RW.md ADDED
@@ -0,0 +1,322 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # NEURAL-GUIDED DEDUCTIVE SEARCH FOR REALTIME PROGRAM SYNTHESIS FROM EXAMPLES
2
+
3
+ Ashwin K. Vijayakumar∗† & Dhruv Batra
4
+ School of Interactive Computing
5
+ Georgia Tech
6
+ Atlanta, GA 30308, USA
7
+ {ashwinkv,dbatra}@gatech.edu
8
+
9
+ # Abhishek Mohta† & Prateek Jain
10
+
11
+ # Oleksandr Polozov & Sumit Gulwani
12
+
13
+ Microsoft Research India Bengaluru, Karnataka 560001, India {t-abmoht,prajain}@microsoft.com
14
+
15
+ Microsoft Research Redmond Redmond, WA 98052, USA {polozov,sumitg}@microsoft.com
16
+
17
+ # ABSTRACT
18
+
19
+ Synthesizing user-intended programs from a small number of input-output examples is a challenging problem with several important applications like spreadsheet manipulation, data wrangling and code refactoring. Existing synthesis systems either completely rely on deductive logic techniques that are extensively handengineered or on purely statistical models that need massive amounts of data, and in general fail to provide real-time synthesis on challenging benchmarks. In this work, we propose Neural Guided Deductive Search (NGDS), a hybrid synthesis technique that combines the best of both symbolic logic techniques and statistical models. Thus, it produces programs that satisfy the provided specifications by construction and generalize well on unseen examples, similar to data-driven systems. Our technique effectively utilizes the deductive search framework to reduce the learning problem of the neural component to a simple supervised learning setup. Further, this allows us to both train on sparingly available real-world data and still leverage powerful recurrent neural network encoders. We demonstrate the effectiveness of our method by evaluating on real-world customer scenarios by synthesizing accurate programs with up to $1 2 \times$ speed-up compared to state-of-the-art systems.
20
+
21
+ # 1 INTRODUCTION
22
+
23
+ Automatic synthesis of programs that satisfy a given specification is a classical problem in AI (Waldinger & Lee, 1969), with extensive literature in both machine learning and programming languages communities. Recently, this area has gathered widespread interest, mainly spurred by the emergence of a sub-area – Programming by Examples (PBE) (Gulwani, 2011). A PBE system synthesizes programs that map a given set of example inputs to their specified example outputs. Such systems make many tasks accessible to a wider audience as example-based specifications can be easily provided even by end users without programming skills. See Figure 1 for an example. PBE systems are usually evaluated on three key criteria: (a) correctness: whether the synthesized program satisfies the spec i.e. the provided example input-output mapping, (b) generalization: whether the program produces the desired outputs on unseen inputs, and finally, (c) performance: synthesis time.
24
+
25
+ Figure 1: An example input-output spec; the goal is to learn a program that maps the given inputs to the corresponding outputs and generalizes well to new inputs. Both programs below satisfy the spec: (i) Concat( $1 ^ { \mathrm { s t } }$ letter of $1 ^ { \mathrm { s t } }$ word, $\bar { 2 } ^ { \mathrm { n d } }$ word), (ii) Concat $\mathrm { 4 ^ { t h } }$ -last letter of $1 ^ { \mathrm { s t } }$ word, $2 ^ { \mathrm { n d } }$ word). However, program (i) clearly generalizes better: for instance, its output on “Yoshua Bengio” is “Y Bengio” while program (ii) produces “s Bengio”.
26
+
27
+ <table><tr><td>Input</td><td>Output</td></tr><tr><td>Yann LeCunn Hugo Larochelle Tara Sainath</td><td>Y LeCunn HLarochelle T Sainath</td></tr><tr><td>Yoshua Bengio</td><td>?</td></tr></table>
28
+
29
+ ∗Work done during an internship at Microsoft Research. †Equal contribution.
30
+
31
+ State-of-the-art PBE systems are either symbolic, based on enumerative or deductive search (Gulwani, 2011; Polozov & Gulwani, 2015) or statistical, based on data-driven learning to induce the most likely program for the spec (Gaunt et al., 2016; Balog et al., 2017; Devlin et al., 2017). Symbolic systems are designed to produce a correct program by construction using logical reasoning and domain-specific knowledge. They also produce the intended program with few input-output examples (often just 1). However, they require significant engineering effort and their underlying search processes struggle with real-time performance, which is critical for user-facing PBE scenarios.
32
+
33
+ In contrast, statistical systems do not rely on specialized deductive algorithms, which makes their implementation and training easier. However, they lack in two critical aspects. First, they require a lot of training data and so are often trained using randomly generated tasks. As a result, induced programs can be fairly unnatural and fail to generalize to real-world tasks with a small number of examples. Second, purely statistical systems like RobustFill (Devlin et al., 2017) do not guarantee that the generated program satisfies the spec. Thus, solving the synthesis task requires generating multiple programs with a beam search and post-hoc filtering, which defeats real-time performance.
34
+
35
+ Neural-Guided Deductive Search Motivated by shortcomings of both the above approaches, we propose Neural-Guided Deductive Search (NGDS), a hybrid synthesis technique that brings together the desirable aspects of both methods. The symbolic foundation of NGDS is deductive search (Polozov & Gulwani, 2015) and is parameterized by an underlying domain-specific language (DSL) of target programs. Synthesis proceeds by recursively applying production rules of the DSL to decompose the initial synthesis problem into smaller sub-problems and further applying the same search technique on them. Our key observation I is that most of the deduced sub-problems do not contribute to the final best program and therefore a priori predicting the usefulness of pursuing a particular sub-problem streamlines the search process resulting in considerable time savings. In NGDS, we use a statistical model trained on real-world data to predict a score that corresponds to the likelihood of finding a generalizable program as a result of exploring a sub-problem branch.
36
+
37
+ Our key observation $\mathbf { I I }$ is that speeding up deductive search while retaining its correctness or generalization requires a close integration of symbolic and statistical approaches via an intelligent controller. It is based on the “branch & bound” technique from combinatorial optimization (Clausen, 1999). The overall algorithm integrates (i) deductive search, (ii) a statistical model that predicts, $a$ priori, the generalization score of the best program from a branch, and (iii) a controller that selects sub-problems for further exploration based on the model’s predictions.
38
+
39
+ Since program synthesis is a sequential process wherein a sequence of decisions (here, selections of DSL rules) collectively construct the final program, a reinforcement learning setup seems more natural. However, our key observation III is that deductive search is Markovian – it generates independent sub-problems at every level. In other words, we can reason about a satisfying program for the sub-problem without factoring in the bigger problem from which it was deduced. This brings three benefits enabling a supervised learning formulation: (a) a dataset of search decisions at every level over a relatively small set of PBE tasks that contains an exponential amount of information about the DSL promoting generalization, (b) such search traces can be generated and used for offline training, (c) we can learn separate models for different classes of sub-problems (e.g. DSL levels or rules), with relatively simpler supervised learning tasks.
40
+
41
+ Evaluation We evaluate NGDS on the string transformation domain, building on top of PROSE, a commercially successful deductive synthesis framework for PBE (Polozov & Gulwani, 2015). It represents one of the most widespread and challenging applications of PBE and has shipped in multiple mass-market tools including Microsoft Excel and Azure ML Workbench.1 We train and validate our method on 375 scenarios obtained from real-world customer tasks (Gulwani, 2011; Devlin et al., 2017). Thanks to the Markovian search properties described above, these scenarios generate a dataset of 400, $0 0 0 +$ intermediate search decisions. NGDS produces intended programs on $6 8 \%$ of the scenarios despite using only one input-output example. In contrast, state-of-the-art neural synthesis techniques (Balog et al., 2017; Devlin et al., 2017) learn intended programs from a single example in only $2 4 \mathrm { - } 3 6 \%$ of scenarios taking $\approx 4 \times$ more time. Moreover, NGDS matches the accuracy of baseline PROSE while providing a speed-up of up to $1 2 \times$ over challenging tasks.
42
+
43
+ Contributions First, we present a branch-and-bound optimization based controller that exploits deep neural network based score predictions to select grammar rules efficiently (Section 3.2). Second, we propose a program synthesis algorithm that combines key traits of a symbolic and a statistical approach to retain desirable properties like correctness, robust generalization, and real-time performance (Section 3.3). Third, we evaluate NGDS against state-of-the-art baselines on real customer tasks and show significant gains (speed-up of up to $1 2 \times$ ) on several critical cases (Section 4).
44
+
45
+ # 2 BACKGROUND
46
+
47
+ In this section, we provide a brief background on PBE and the PROSE framework, using established formalism from the programming languages community.
48
+
49
+ Domain-Specific Language A program synthesis problem is defined over a domain-specific language (DSL). A DSL is a restricted programming language that is suitable for expressing tasks in a given domain, but small enough to restrict a search space for program synthesis. For instance, typical real-life DSLs with applications in textual data transformations (Gulwani, 2011) often include conditionals, limited forms of loops, and domain-specific operators such as string concatenation, regular expressions, and date/time formatting. DSLs for tree transformations such as code refactoring (Rolim et al., 2017) and data extraction (Le & Gulwani, 2014) include list/data-type processing operators such as Map and Filter, as well as domain-specific matching operators. Formally, a DSL $\mathcal { L }$ is specified as a context-free grammar, with each non-terminal symbol $N$ defined by a set of productions. The right-hand side of each production is an application of some operator $F ( N _ { 1 } , \dots , N _ { k } )$ to some symbols of $\mathcal { L }$ . All symbols and operators are strongly typed. Figure 2 shows a subset of the Flash Fill DSL that we use as a running example in this paper.
50
+
51
+ Inductive Program Synthesis The task of inductive program synthesis is characterized by a spec. A spec $\varphi$ is a set of $m$ input-output constraints $\{ \sigma _ { i } \psi _ { i } \} _ { i = 1 } ^ { m }$ , where:
52
+
53
+ • $\sigma$ , an input state is a mapping of free variables of the desired program $P$ to some correspondingly typed values. At the top level of $\mathcal { L }$ , a program (and its expected input state) has only one free variable – the input variable of the DSL (e.g., inputs in Figure 2). Additional local variables are introduced inside $\mathcal { L }$ with a $\bot e t$ construct.
54
+ • $\psi$ is an output constraint on the execution result of the desired program $P ( \sigma _ { i } )$ . At the top level of $\mathcal { L }$ , when provided by the user, $\psi$ is usually the output example – precisely the expected result of $P ( \sigma _ { i } )$ . However, other intermediate constraints arise during the synthesis process. For instance, $\psi$ may be a disjunction of multiple allowed outputs.
55
+
56
+ The overall goal of program synthesis is thus: given a spec $\varphi$ , find a program $P$ in the underlying DSL $\mathcal { L }$ that satisfies $\varphi$ , i.e., its outputs $P ( \sigma _ { i } )$ satisfy all the corresponding constraints $\psi _ { i }$ .
57
+
58
+ Example 1. Consider the task of formatting a phone number, characterized by the spec $\varphi =$ {inputs: $[ ^ { * * } ( 6 1 2 ) ~ 8 7 2 9 1 2 8 ^ { \prime } ] \} \ \sim \ ^ { * * } 6 1 2 { \bar { - } } 8 7 { \bar { 2 } } { \cdot } 9 1 2 8 ^ { \prime } ,$ . It has a single input-output example, with an input state $\sigma$ containing a single variable inputs and its value which is a list with a single input string. The output constraint is simply the desired program result.
59
+
60
+ The program the user is most likely looking for is the one that extracts (a) the part of the input enclosed in the first pair of parentheses, (b) the $7 ^ { \mathrm { t h } }$ to $4 ^ { \mathrm { t h } }$ characters from the end, and (c) the last 4 characters, and then concatenates all three parts using hyphens. In our DSL, this corresponds to:
61
+
62
+ ConcatSubStr0(RegexPosition $( \boldsymbol { x } , ^ { 6 6 } ( ^ { 7 3 } , \varepsilon ) , 0 )$ , RegexPosition $( x , \langle \varepsilon , \overset { \ast } { , } ) \overset { \ast } { , } 0 ) ,$ ), ConstStr(“-”), SubStr0(AbsolutePosition $( x , - 8 )$ , AbsolutePosition $( x , - 5 )$ ), $\mathsf { C o n s t S t r } ( \mathsf { ^ { s \pm } _ { - } } , \mathsf { " } )$ , SubStr0(AbsolutePosition $( x , - 5 )$ , AbsolutePosition $( x , - 1 ) )$ 
63
+
64
+ where $\varepsilon$ is an empty regex, $\mathsf { S u b S t r } _ { 0 } ( p o s _ { 1 } , p o s _ { 2 } )$ is an abbreviation for “let $x = { \mathsf { s t d } } . { \mathsf { K t h } } ( i n p u t s , 0 )$ in Substring $( x , \langle p o s _ { 1 } , p o s _ { 2 } \rangle ) ^ { \prime }$ , and $\langle \cdot \rangle$ is an abbreviation for std.Pair.
65
+
66
+ However, many other programs in the DSL also satisfy $\varphi$ . For instance, all occurrences of $" 8 >$ in the output can be produced via a subprogram that simply extracts the last character. Such a program overfits to $\varphi$ and is bound to fail for other inputs where the last character and the $4 ^ { \mathrm { t h } }$ one differ.
67
+
68
+ # // Nonterminals
69
+
70
+ @start string transform $: =$ atom | Concat(atom, transform);
71
+ string atom $: =$ ConstStr(s)
72
+ | let string $\begin{array} { r l } { x } & { { } = } \end{array}$ std.Kth(inputs, k) in Substring(x, pp); Tuple<int, int> $p p : =$ std.Pair(pos, pos) | RegexOccurrence(x, r, $k$ ); int pos $: =$ AbsolutePosition(x, $k$ ) | RegexPosition(x, std.Pair $( r , \quad r ) , \quad k )$ ; // Terminals
73
+ @input string[] inputs; string s; int k; Regex r;
74
+
75
+ Figure 2: A subset of the FlashFill DSL (Gulwani, 2011), used as a running example in this paper. Every program takes as input a list of strings inputs, and returns an output string, a concatenation of atoms. Each atom is either a constant or a substring of one of the inputs $( x )$ , extracted using some position logic. The RegexOccurrence position logic finds $k ^ { \mathrm { { t h } } }$ occurrence of a regex $r$ in $x$ and returns its boundaries. Alternatively, start and end positions can be selected independently either as absolute indices in $x$ from left or right (AbsolutePosition) or as the $k ^ { \mathrm { { t h } } }$ occurrence of a pair of regexes surrounding the position (RegexPosition). See Gulwani (2011) for an in-depth DSL description.
76
+
77
+ As Example 1 shows, typical real-life problems are severely underspecified. A DSL like FlashFill may contain up to $1 0 ^ { 2 0 }$ programs that satisfy a given spec of 1-3 input-output examples (Polozov & Gulwani, 2015). Therefore, the main challenge lies in finding a program that not only satisfies the provided input-output examples but also generalizes to unseen inputs. Thus, the synthesis process usually interleaves search and ranking: the search phase finds a set of spec-satisfying programs in the DSL, from which the ranking phase selects top programs ordered using a domain-specific ranking function $h \colon \mathcal { L } \times \vec { \Sigma } \mathbb { R }$ where $\Sigma$ is the set of all input states. The ranking function takes as input a candidate program $P \in { \mathcal { L } }$ and a set of input states $\vec { \sigma } \in \vec { \Sigma }$ (usually $\vec { \sigma } =$ inputs in the given spec $^ +$ any available unlabeled inputs), and produces a score for $P$ ’s generalization.
78
+
79
+ The implementation of $h$ expresses a subtle balance between program generality, complexity, and behavior on available inputs. For instance, in FlashFill $h$ penalizes overly specific regexes, prefers programs that produce fewer empty outputs, and prioritizes lower Kolmogorov complexity, among other features. In modern PBE systems like PROSE, $h$ is usually learned in a data-driven manner from customer tasks (Singh & Gulwani, 2015; Ellis & Gulwani, 2017). While designing and learning such a ranking is an interesting problem in itself, in this work we assume a black-box access to $h$ . Finally, the problem of inductive program synthesis can be summarized as follows:
80
+
81
+ Problem 1. Given a DSL $\mathcal { L }$ , a ranking function $h$ , a spec $\varphi = \{ \sigma _ { i } \psi _ { i } \} _ { i = 1 } ^ { m }$ , optionally a set of unlabeled inputs $\vec { \sigma } _ { u }$ , and a target number of programs $K$ , let $\vec { \sigma } = \vec { \sigma } _ { u } \cup \{ \sigma _ { i } \} _ { i = 1 } ^ { m }$ . The goal of inductive program synthesis is to find a program set ${ \mathcal { S } } = \{ P _ { 1 } , \ldots , P _ { K } \} \subset { \mathcal { L } }$ such that (a) every program in $s$ satisfies $\varphi$ , and $( b )$ the programs in $s$ generalize best: $h ( P _ { i } , \vec { \sigma } ) \geq h ( P , \vec { \sigma } )$ for any other $P \in { \mathcal { L } }$ that satisfies $\varphi$ .
82
+
83
+ Search Strategy Deductive search strategy for program synthesis, employed by PROSE explores the grammar of $\mathcal { L }$ top-down – iteratively unrolling the productions into partial programs starting from the root symbol. Following the divide-and-conquer paradigm, at each step it reduces its synthesis problem to smaller subproblems defined over the parameters of the current production. Formally, given a spec $\varphi$ and a symbol $N$ , PROSE computes the set Learn $( N , \varphi )$ of top programs w.r.t. $h$ using two guiding principles:
84
+
85
+ 1. If $N$ is defined through $n$ productions $N : = F _ { 1 } ( . . . ) \mid . . . \mid F _ { n } ( . . . )$ , PROSE finds a $\varphi$ -satisfying program set for every $F _ { i }$ , and unites the results, i.e., L $\mathsf { e a r n } ( N , \varphi ) = \cup _ { i } \mathsf { L e a r n } ( F _ { i } ( . . . ) , \varphi )$ . 2. For a given production $N : = F ( N _ { 1 } , \ldots , N _ { k } )$ , PROSE spawns off $k$ smaller synthesis problems Learn $( N _ { j } , \varphi _ { j } )$ , $1 \le j \le k$ wherein PROSE deduces necessary and sufficient specs $\varphi _ { j }$ for each $N _ { j }$ such that every program of type $F ( P _ { 1 } , \ldots , P _ { k } )$ , where $P _ { j } \in \mathsf { L e a r n } ( N _ { j } , \varphi _ { j } )$ , satisfies $\varphi$ . The deduction logic (called a witness function) is domain-specific for each operator $F$ . PROSE then again recursively solves each subproblem and unites a cross-product of the results.
86
+
87
+ Example 2. Consider a spec $\varphi = \{ { ^ { \cdots } \mathrm { Y a n n } ^ { 3 \prime } } { ^ { \cdots } \mathrm { Y } } . \mathrm { L } ^ { 3 \prime } \}$ on a transform program. Via the first production transform := atom, the only $\varphi$ -satisfying program is $\mathsf { C o n s t S t r } ( ^ { \ast } \mathrm { Y } \cdot \mathrm { L } ^ { \ast } )$ . The second production on the same level is Concat(atom, transform). A necessary $\&$ sufficient spec on the atom sub-program is that it should produce some prefix of the output string. Thus, the witness function for the Concat operator produces a disjunctive spec $\varphi _ { a } = \{ { } ^ { \mathfrak { c } \mathfrak { c } } \mathtt { Y a n n } ^ { \mathfrak { W } } { } ^ { \mathfrak { c } \mathfrak { c } } \mathtt { Y } ^ { \mathfrak { W } } \lor ^ { \mathfrak { c } \mathfrak { c } } \mathtt { Y } \dotsc ^ { \mathfrak { W } } \lor ^ { \mathfrak { c } } \dotsc ^ { \mathfrak { P } } \} ,$ . Each of these disjuncts, in turn, induces a corresponding necessary and sufficient suffix spec on the second parameter: $\varphi _ { t 1 } = \{ { ^ { \ast \epsilon } \mathrm { Y a n n } ^ { 3 } } { ^ { \ast } \cdot \mathrm { L } ^ { 3 } } \}$ , and $\varphi _ { t 2 } = \{ { ^ { * * } \mathrm { Y } } \mathrm { a n n } ^ { , , * } { ^ { * } \mathrm { L } } ^ { , * } \}$ , respectively. The disjuncts in $\varphi _ { a }$ will be recursively satisfied by different program sets: “Y.” can only be produced via an atom path with a ConstStr program, whereas “Y” can also be extracted from the input using many Substring logics (their generalization capabilities vary). Figure 3 shows the resulting search DAG.
88
+
89
+ ![](images/17406fb562994604272c9df10d297347fb2eab5b2870748b35b804a93fc6e621.jpg)
90
+ Figure 3: A portion of the search DAG from Example 2. Only the output parts of the respective specs are shown in each node, their common input state is a single string “Yann”. Dashed arrows show recursive Learn calls on a corresponding DSL symbol.
91
+
92
+ Notice that the above mentioned principles create logical non-determinism due to which we might need to explore multiple alternatives in a search tree. As such non-determinism arises at every level of the DSL with potentially any operator, the search tree (and the resulting search process) is exponential in size. While all the branches of the tree by construction produce programs that satisfy the given spec, most of the branches do not contribute to the overall top-ranked generalizable program. During deductive search, PROSE has limited information about the programs potentially produced from each branch, and cannot estimate their quality, thus exploring the entire tree unnecessarily. Our main contribution is a neural-guided search algorithm that predicts the best program scores from each branch, and allows PROSE to omit branches that are unlikely to produce the desired program a priori.
93
+
94
+ # 3 SYNTHESIS ALGORITHM
95
+
96
+ Consider an arbitrary branching moment in the top-down search strategy of PROSE. For example, let $N$ be a nonterminal symbol in $\mathcal { L }$ , defined through a set of productions $N : = F _ { 1 } ( . . . ) \mid . . . \mid F _ { n } ( . . . )$ , and let $\varphi$ be a spec on $N$ , constructed earlier during the recursive descent over $\mathcal { L }$ . A conservative way to select the top $k$ programs rooted at $N$ (as defined by the ranking function $h$ ), i.e., to compute $\mathsf { L e a r n } ( N , \varphi )$ , is to learn the top $k$ programs of kind $F _ { i } ( \dots )$ for all $i \in [ k ]$ and then select the top $k$ programs overall from the union of program sets learned for each production. Naturally, exploring all the branches for each nonterminal in the search tree is computationally expensive.
97
+
98
+ In this work, we propose a data-driven method to select an appropriate production rule $N : =$ $F _ { i } ( N _ { 1 } , \ldots , N _ { k } )$ that would most likely lead to a top-ranked program. To this end, we use the current spec $\varphi$ to determine the “optimal” rule. Now, it might seem unintuitive that even without exploring a production rule and finding the best program in the corresponding program set, we can a priori determine optimality of that rule. However, we argue that by understanding $\varphi$ and its relationship with the ranking function $h$ , we can predict the intended branch in many real-life scenarios.
99
+
100
+ Example 3. Consider a spec $\begin{array} { r l r } { \varphi } & { { } = } & { \left\{ \begin{array} { l l } { \begin{array} { r l r } \end{array} } \end{array} \right. } \end{array}$ {“alice” “alice@iclr.org”, “bob” “bob@iclr.org”}. While learning a program in $\mathcal { L }$ given by Figure 2 that satisfies $\varphi$ , it is clear right at the beginning of the search procedure that the rule transfor $m : = a t o m$ does not apply. This is because any programs derived from transform $\because$ atom can either extract a substring from the input or return a constant string, both of which fail to produce the desired output. Hence, we should only consider transfor $m : = { \mathsf { C o n c a t } } ( . ~ . ~ . )$ , thus significantly reducing the search space.
101
+
102
+ Similarly, consider another spec $\varphi ~ = ~ \{$ “alice smith” “alice”, “bob jones” “bob”}. In this case, the output appears to be a substring of input, thus selecting transfor $m : = a t o m$ at the beginning of the search procedure is a better option than $t r a n s f o r m : = { \mathsf { C o n c a t } } ( . ~ . ~ . )$ .
103
+
104
+ However, many such decisions are more subtle and depend on the ranking function $h$ itself. For example, consider a spec $\varphi = \{ { } ^ { \ast } \mathsf { a l i c e }$ liddell” “al”, “bob ong” $ \ r g _ { 0 }$ . Now, both transfor $m : = a t o m$ and transfor $m : = { \mathsf { C o n c a t } } ( . . . )$ may lead to viable programs because the output can be constructed using the first two letters of the input (i.e. a substring atom) or by concatenating the first letters of each word. Hence, the branch that produces the best program is ultimately determined by the ranking function $h$ since both branches generate valid programs.
105
+
106
+ ![](images/918de665055678428764e6b9fb234a84e4ad894aaa5f299a68cd24595e6869fa.jpg)
107
+ Figure 4: LSTM-based model for predicting the score of a candidate production for a given spec $\varphi$
108
+
109
+ Example 3 shows that to design a data-driven search strategy for branch selection, we need to learn the subtle relationship between $\varphi , h$ , and the candidate branch. Below, we provide one such model.
110
+
111
+ # 3.1 PREDICTING THE GENERALIZATION SCORE
112
+
113
+ As mentioned above, our goal is to predict one or more production rules that for a given spec $\varphi$ will lead to a top-ranked program (as ranked a posteriori by $h$ ). Formally, given black-box access to $h$ , we want to learn a function $f$ such that,
114
+
115
+ $$
116
+ f ( \boldsymbol { \cal T } , \varphi ) \approx \operatorname* { m a x } _ { \boldsymbol { P } \in { \cal S } ( \boldsymbol { \cal T } , \varphi ) } h ( \boldsymbol { P } , \varphi ) ,
117
+ $$
118
+
119
+ where $\varGamma$ is a production rule in $\mathcal { L }$ , and $s ( \boldsymbol { { T } } , \boldsymbol { \varphi } )$ is a program set of all DSL programs derived from the rule $\varGamma$ that satisfy $\varphi$ . In other words, we want to predict the score of the top-ranked $\varphi$ -satisfying program that is synthesized by unrolling the rule $\varGamma$ . We assume that the symbolic search of PROSE handles the construction of $s ( \boldsymbol { { T } } , \boldsymbol { \varphi } )$ and ensures that programs in it satisfy $\varphi$ by construction. The goal of $f$ is to optimize the score of a program derived from $\varGamma$ assuming this program is valid. If no program derived from $\varGamma$ can satisfy $\varphi , f$ should return $- \infty$ . Note that, drawing upon observations mentioned in Section 1, we have cast the production selection problem as a supervised learning problem, thus simplifying the learning task as opposed to end-to-end reinforcement learning solution.
120
+
121
+ We have evaluated two models for learning $f$ . The loss function for the prediction is given by:
122
+
123
+ $$
124
+ L ( f ; T , \varphi ) = \big ( f ( T , \varphi ) - \operatorname* { m a x } _ { P \in \mathcal { S } ( T , \varphi ) } h ( P , \varphi ) \big ) ^ { 2 } .
125
+ $$
126
+
127
+ Figure 4 shows a common structure of both models we have evaluated. Both are based on a standard multi-layer LSTM architecture (Hochreiter & Schmidhuber, 1997) and involve (a) embedding the given spec $\varphi , ( \mathbf { b } )$ encoding the given production rule $\varGamma$ , and (c) a feed-forward network to output a score $f ( \boldsymbol { { T } } , \boldsymbol { \varphi } )$ . One model attends over input when it encodes the output, whereas another does not.
128
+
129
+ # 3.2 CONTROLLER FOR BRANCH SELECTION
130
+
131
+ A score model $f$ alone is insufficient to perfectly predict the branches that should be explored at every level. Consider again a branching decision moment $N : = F _ { 1 } ( . . . ) \mid . . . \mid F _ { n } ( . . . )$ in a search process for top $k$ programs satisfying a spec $\varphi$ . One naïve approach to using the predictions of $f$ is to always follow the highest-scored production rule argmaxi $f ( F _ { i } , \varphi )$ . However, this means that any single incorrect decision on the path from the DSL root to the desired program will eliminate that program from the learned program set. If our search algorithm fails to produce the desired program by committing to a suboptimal branch anytime during the search process, then the user may never discover that such a program exists unless they supply additional input-output example.
132
+
133
+ Thus, a branch selection strategy based on the predictions of $f$ must balance a trade-off of performance and generalization. Selecting too few branches (a single best branch in the extreme case) risks committing to an incorrect path early in the search process and producing a suboptimal program or no program at all. Selecting too many branches (all $n$ branches in the extreme case) is no different from baseline PROSE and fails to exploit the predictions of $f$ to improve its performance.
134
+
135
+ Formally, a controller for branch selection at a symbol $N : = F _ { 1 } ( . . . ) \mid . . . \mid F _ { n } ( . . . )$ targeting $k$ best programs must (a) predict the expected score of the best program from each program set:
136
+
137
+ function THRESHOLDBASED $( \varphi , h , k , s _ { 1 } , \ldots , s _ { n } )$
138
+
139
+ 1: Result set $S ^ { * } [ ]$
140
+ 2: $i ^ { * } \gets \mathrm { a r g m a x } _ { i } s _ { i }$
141
+ 3: for all $1 \leq i \leq n$ do
142
+ 4: if $| s _ { i } - s _ { i ^ { * } } | \leq \theta$ then
143
+ // Recursive search
144
+ 5: $\begin{array} { r } { S ^ { * } \mathrel { + } = \mathrm { L E A R N } \big ( F _ { i } , \varphi , k \big ) } \end{array}$
145
+ 6: return the top $k$ programs of $s$ w.r.t. h
146
+ function BNBBASED $( \varphi , h , k , s _ { 1 } , \ldots , s _ { n } )$
147
+ 1: Result set $S ^ { * } [ ]$ ; Program target $k ^ { \prime } k$
148
+ 2: Reorder $F _ { i }$ in the descending order of $s _ { i }$
149
+ 3: for all $1 \leq i \leq n$ do
150
+ 4: $S _ { i } \gets \mathrm { L E A R N } ( F _ { i } , \varphi , k ^ { \prime } )$ // Recursive search
151
+ 5: $j \gets \mathsf { B I N A R Y S E A R C H } ( s _ { i + 1 } , \mathsf { M a p } ( h , S _ { i } ) )$
152
+ 6: $S ^ { * } = S _ { i } ^ { * } \cup S _ { i } [ 0 . . j ]$ ; $k ^ { \prime } \gets k ^ { \prime } - j$
153
+ 7: if $k ^ { \prime } \le 0$ then break
154
+ 8: return $s ^ { * }$
155
+
156
+ Figure 5: The controllers for guiding the search process to construct a most generalizable $\varphi$ -satisfying program set $s$ of size $k$ given the $f$ -predicted best scores $s _ { 1 } , \ldots , s _ { n }$ of the productions $F _ { 1 } , \ldots , F _ { n }$ .
157
+
158
+ Given: DSL $\mathcal { L }$ , ranking function $h$ , controller $\mathcal { C }$ from Figure 5 (THRESHOLDBASED or BNBBASED), symbolic search algorithm LEARN(Production rule $\varGamma$ , spec $\varphi$ , target $k$ ) as in PROSE (Polozov & Gulwani, 2015, Figure 7) with all recursive calls to LEARN replaced with LEARNNGDS
159
+
160
+ function LEARNNGDS(Symbol $N : = F _ { 1 } ( . . . ) \mid . . . \mid F _ { n } ( . . . )$ , spec $\varphi$ , target number of programs $k$ )
161
+ 1: if $n = 1$ then return LEARN $( F _ { 1 } , \varphi , k )$
162
+ 2: Pick a score model $f$ based on depth $( N , \mathcal { L } )$
163
+ 3: $s 1 , \ldots , s _ { n } \gets f ( F _ { 1 } , \varphi ) , \ldots , f ( F _ { n } , \varphi )$
164
+ 4: return $\mathcal { C } ( \varphi , h , k , s _ { 1 } , \ldots , s _ { n } )$
165
+
166
+ Figure 6: Neural-guided deductive search over $\mathcal { L }$ , parameterized with a branch selection controller $\mathcal { C }$ $s _ { i } = f ( F _ { i } , \varphi ) ~ \forall 1 \leq i \leq n$ , and $\mathbf { ( b ) }$ use the predicted scores $s _ { i }$ to narrow down the set of productions $F _ { 1 } , \ldots , F _ { n }$ to explore and to obtain the overall result by selecting a subset of generated programs. In this work, we propose and evaluate two controllers. Their pseudocode is shown in Figure 5.
167
+
168
+ Threshold-based: Fix a score threshold $\theta$ , and explore those branches whose predicted score differs by at most $\theta$ from the maximum predicted score. This is a simple extension of the naïve “argmax” controller discussed earlier that also explores any branches that are predicted “approximately as good as the best one”. When $\theta = 0$ , it reduces to the “argmax” one.
169
+
170
+ Branch $\pmb { \& }$ Bound: This controller is based on the “branch $\&$ bound” technique in combinatorial optimization (Clausen, 1999). Assume the branches $F _ { i }$ are ordered in the descending order of their respective predicted scores $s _ { i }$ . After recursive learning produces its program set $S _ { i }$ , the controller proceeds to the next branch only if $s _ { i + 1 }$ exceeds the score of the worst program in $\boldsymbol { S } _ { i }$ . Moreover, it reduces the target number of programs to be learned, using $s _ { i + 1 }$ as a lower bound on the scores of the programs in $S _ { i }$ . That is, rather than relying blindly on the predicted scores, the controller guides the remaining search process by accounting for the actual synthesized programs as well.
171
+
172
+ # 3.3 NEURAL-GUIDED DEDUCTIVE SEARCH
173
+
174
+ We now combine the above components to present our unified algorithm for program synthesis. It builds upon the deductive search of the PROSE system, which uses symbolic PL insights in the form of witness functions to construct and narrow down the search space, and a ranking function $h$ to pick the most generalizable program from the found set of spec-satisfying ones. However, it significantly speeds up the search process by guiding it a priori at each branching decision using the learned score model $f$ and a branch selection controller, outlined in Sections 3.1 and 3.2. The resulting neural-guided deductive search (NGDS) keeps the symbolic insights that construct the search tree ensuring correctness of the found programs, but explores only those branches of this tree that are likely to produce the user-intended generalizable program, thus eliminating unproductive search time.
175
+
176
+ A key idea in NGDS is that the score prediction model $f$ does not have to be the same for all decisions in the search process. It is possible to train separate models for different DSL levels, symbols, or even productions. This allows the model to use different features of the input-output spec for evaluating the fitness of different productions, and also leads to much simpler supervised learning problems.
177
+
178
+ Figure 6 shows the pseudocode of NGDS. It builds upon the deductive search of PROSE, but augments every branching decision on a symbol with some branch selection controller from Section 3.2. We present a comprehensive evaluation of different strategies in Section 4.
179
+
180
+ <table><tr><td>Metric</td><td>PROSE</td><td>DC1</td><td>DC2</td><td>DC3</td><td>RF1</td><td>RF2</td><td>RF3</td><td>NGDS</td></tr><tr><td>Accuracy (% of 73)</td><td>67.12</td><td>35.81</td><td>47.38</td><td>62.92</td><td>24.53</td><td>39.72</td><td>56.41</td><td>68.49</td></tr><tr><td>Speed-up (× PROSE)</td><td>1.00</td><td>1.82</td><td>1.53</td><td>1.42</td><td>0.25</td><td>0.27</td><td>0.30</td><td>1.67</td></tr></table>
181
+
182
+ Table 1: Accuracy and average speed-up of NGDS vs. baseline methods. Accuracies are computed on a test set of 73 tasks. Speed-up of a method is the geometric mean of its per-task speed-up (ratio of synthesis time of PROSE and of the method) when restricted to a subset of tasks with PROSE’s synthesis time is $\geq 0 . 5$ sec.
183
+
184
+ # 4 EVALUATION
185
+
186
+ In this section, we evaluate our NGDS algorithm over the string manipulation domain with a DSL given by Figure 2; see Figure 1 for an example task. We evaluate NGDS, its ablations, and baseline techniques on two key metrics: (a) generalization accuracy on unseen inputs, (b) synthesis time.
187
+
188
+ Dataset. We use a dataset of 375 tasks collected from real-world customer string manipulation problems, split into $6 5 \%$ training, $1 5 \%$ validation, and $2 0 \%$ test data. Some of the common applications found in our dataset include date/time formatting, manipulating addresses, modifying names, automatically generating email IDs, etc. Each task contains about 10 inputs, of which only one is provided as the spec to the synthesis system, mimicking industrial applications. The remaining unseen examples are used to evaluate generalization performance of the synthesized programs. After running synthesis of top-1 programs with PROSE on all training tasks, we have collected a dataset of $\approx 4 0 0 { , } 0 0 0$ intermediate search decisions, i.e. triples hproduction $\varGamma$ , spec $\varphi$ , a posteriori best score $h ( P , \varphi ) \rangle$ .
189
+
190
+ Baselines. We compare our method against two state-of-the-art neural synthesis algorithms: RobustFill (Devlin et al., 2017) and DeepCoder (Balog et al., 2017). For RobustFill, we use the best-performing Attention- $C$ model and use their recommended DP-Beam Search with a beam size of 100 as it seems to perform the best; Table 3 in Appendix A presents results with different beam sizes. As in the original work, we select the top-1 program ranked according to the generated log-likelihood. DeepCoder is a generic framework that allows their neural predictions to be combined with any program synthesis method. So, for fair comparison, we combine DeepCoder’s predictions with PROSE. We train DeepCoder model to predict a distribution over $\mathcal { L }$ ’s operators and as proposed, use it to guide PROSE synthesis. Since both RobustFill and DeepCoder are trained on randomly sampled programs and are not optimized for generalization in the real-world, we include their variants trained with 2 or 3 examples (denoted $\mathrm { R F } _ { m }$ and $\mathrm { D C } _ { m . }$ ) for fairness, although $m = 1$ example is the most important scenario in real-life industrial usage.
191
+
192
+ Ablations. As mentioned in Section 3, our novel usage of score predictors to guide the search enables us to have multiple prediction models and controllers at various stages of the synthesis process. Here we investigate ablations of our approach with models that specialize in predictions for individual levels in the search process. The model $T _ { 1 }$ is trained for symbol transf orm (Figure 2) when expanded in the first level. Similarly, $P P$ , $P O S$ refer to models trained for the $p p$ and pos symbol, respectively. Finally, we train all our LSTM-based models with CNTK (Seide & Agarwal, 2016) using Adam (Kingma & Ba, 2014) with a learning rate of $1 0 ^ { - 2 }$ and a batch size of 32, using early stopping on the validation loss to select the best performing model (thus, 100-600 epochs).
193
+
194
+ We also evaluate three controllers: threshold-based (Thr) and branch-and-bound (BB) controllers given in Figure 5, and a combination of them – branch-and-bound with a 0.2 threshold predecessor $\mathrm { ( B B _ { 0 . 2 } ) }$ . In Tables 1 and 2 we denote different model combinations as $\operatorname { N G D S } ( f , { \mathcal { C } } )$ where $f$ is a symbol-based model and $\mathcal { C }$ is a controller. The final algorithm selection depends on its accuracyperformance trade-off. In Table 1, we use NGDS $\mathbf { \zeta } T _ { 1 } + P O S$ , BB), the best performing algorithm on the test set, although NGDS $T _ { 1 }$ , BB) performs slightly better on the validation set.
195
+
196
+ Evaluation Metrics. Generalization accuracy is the percentage of test tasks for which the generated program satisfies all unseen inputs in the task. Synthesis time is measured as the wall-clock time taken by a synthesis method to find the correct program, median over 5 runs. We run all the methods on the same machine with $2 . 3 \ : \mathrm { G H z }$ Intel Xeon processor, 64GB of RAM, and Windows Server 2016.
197
+
198
+ Results. Table 1 presents generalization accuracy as well as synthesis time speed-up of various methods w.r.t. PROSE. As we strive to provide real-time synthesis, we only compare the times for tasks which require PROSE more than 0.5 sec. Note that, with one example, NGDS and PROSE are
199
+
200
+ <table><tr><td rowspan="2">Method</td><td colspan="2">Validation</td><td colspan="2">Test</td><td rowspan="2">% of branches</td></tr><tr><td>Accuracy</td><td>Speed-up</td><td>Accuracy</td><td>Speed-up</td></tr><tr><td>PROSE</td><td>70.21</td><td>1</td><td>67.12</td><td>1</td><td>100.00</td></tr><tr><td>NGDS(T1,Thr)</td><td>59.57</td><td>1.15</td><td>67.12</td><td>1.27</td><td>62.72</td></tr><tr><td>NGDS(Ti,BB)</td><td>63.83</td><td>1.58</td><td>68.49</td><td>1.22</td><td>51.78</td></tr><tr><td>NGDS(T1,BB0.2)</td><td>61.70</td><td>1.03</td><td>67.12</td><td>1.22</td><td>63.16</td></tr><tr><td>NGDS(Ti +PP,Thr)</td><td>59.57</td><td>0.76</td><td>67.12</td><td>0.97</td><td>56.41</td></tr><tr><td>NGDS(Ti +PP,BB)</td><td>61.70</td><td>1.05</td><td>72.60</td><td>0.89</td><td>50.22</td></tr><tr><td>NGDS(Ti +PP,BB0.2)</td><td>61.70</td><td>0.72</td><td>67.12</td><td>0.86</td><td>56.43</td></tr><tr><td>NGDS(T1+ POS,Thr)</td><td>61.70</td><td>1.19</td><td>67.12</td><td>1.93</td><td>55.63</td></tr><tr><td>NGDS(Ti + POS,BB)</td><td>63.83</td><td>1.13</td><td>68.49</td><td>1.67</td><td>50.44</td></tr><tr><td>NGDS(Ti + POS,BB0.2)</td><td>63.83</td><td>1.19</td><td>67.12</td><td>1.73</td><td>55.73</td></tr></table>
201
+
202
+ Table 2: Accuracies, mean speed-ups, and $\%$ of branches taken for different ablations of NGDS.
203
+
204
+ significantly more accurate than RobustFill and DeepCoder. This is natural as those methods are not trained to optimize generalization, but it also highlights advantage of a close integration with a symbolic system (PROSE) that incorporates deep domain knowledge. Moreover, on an average, our method saves more than $5 0 \%$ of synthesis time over PROSE. While DeepCoder with one example speeds up the synthesis even more, it does so at the expense of accuracy, eliminating branches with correct programs in $6 5 \%$ of tasks.
205
+
206
+ Table 2 presents speed-up obtained by variations of our models and controllers. In addition to generalization accuracy and synthesis speed-up, we also show a fraction of branches that were selected for exploration by the controller. Our method obtains impressive speed-up of $> 1 . 5 \times$ in 22 cases. One such test case where we obtain $1 2 \times$ speedup is a simple extraction case which is fairly common in Web mining: {“alpha,beta,charlie,delta” $ \ r a l p h a ^ { \prime \prime } \}$ . For such cases, our model determine transform $: =$ atom to be the correct branch (that leads to the final Substring based program) and hence saves time required to explore the entire Concat operator which is expensive. Another interesting test case where we observe $2 . 7 \times$ speed-up is: {“457 124th St S, Seattle, WA $9 8 1 1 1 ^ { 9 } \ r s e a t t 1 e \ r$ . This test case involves learning a Concat operator initially followed by Substring and RegexPosition operator. Appendix B includes a comprehensive table of NGDS performance on all the validation and test tasks.
207
+
208
+ All the models in Table 2 run without attention. As measured by score flip accuracies (i.e. percentage of correct orderings of branch scores on the same level), attention-based models perform best, achieving $9 9 . 5 7 / 9 0 . { \bar { 4 } } / 9 6 . 4 \%$ accuracy on train/validation/test, respectively (as compared to $9 6 . 0 9 / 9 1 . 2 4 / 9 1 . 1 2 \%$ for non-attention models). However, an attention-based model is significantly more computationally expensive at prediction time. Evaluating it dominates the synthesis time and eliminates any potential speed-ups. Thus, we decided to forgo attention in initial NGDS and investigate model compression/binarization in future work.
209
+
210
+ Error Analysis. As Appendix B shows, NGDS is slower than PROSE on some tasks. This occurs when the predictions do not satisfy the constraints of the controller i.e. all the predicted scores are within the threshold or they violate the actual scores during B&B exploration. This leads to NGDS evaluating the LSTM for branches that were previously pruned. This is especially harmful when branches pruned out at the very beginning of the search need to be reconsidered – as it could lead to evaluating the neural network many times. While a single evaluation of the network is quick, a search tree involves many evaluations, and when performance of PROSE is already $< 1$ s, this results in considerable relative slowdown. We provide two examples to illustrate both the failure modes:
211
+
212
+ (a) “41.7114830017,-91.41233825683,41.60762786865,-91.63739013671” “41.7114830017”. The intended program is a simple substring extraction. However, at depth 1, the predicted score of Concat is much higher than the predicted score of Atom, and thus NGDS explores only the Concat branch. The found Concat program is incorrect because it uses absolute position indexes and does not generalize to other similar extraction tasks. We found this scenario common with punctuation in the output string, which the model considers a strong signal for Concat.
213
+
214
+ (b) “type size $= ~ 3 6$ : Bartok.Analysis.CallGraphNode type $\mathsf { s i z e } ~ = ~ 3 2$ Bartok.Analysis.CallGraphNode CallGraphNode” $3 6 \mathrm { - } > 3 2 ^ { \dag }$ . In this case, NGDS correctly explores only the Concat branch, but the slowdown happens at the pos symbol.
215
+
216
+ There are many different logics to extract the $\mathbf { \ddot { \varepsilon } } ^ { 6 } 3 6 \mathbf { \vec { \varepsilon } } ^ { 3 }$ and “32” substrings. NGDS explores the RelativePosition branch first, but the score of the resulting program is less then the prediction for RegexPositionRelative. Thus, the B&B controller explores both branches anyway, which leads to a relative slowdown caused by the network evaluation time.
217
+
218
+ # 5 RELATED WORK
219
+
220
+ Neural Program Induction systems synthesize a program by training a new neural network model to map the example inputs to example outputs (Graves et al., 2014; Reed & De Freitas, 2016; Zaremba et al., 2016). Examples include Neural Turing Machines (Graves et al., 2014) that can learn simple programs like copying/sorting, work of Kaiser & Sutskever (2015) that can perform more complex computations like binary multiplications, and more recent work of Cai et al. (2017) that can incorporate recursions. While we are interested in ultimately producing the right output, all these models need to be re-trained for a given problem type, thus making them unsuitable for real-life synthesis of different programs with few examples.
221
+
222
+ Neural Program Synthesis systems synthesize a program in a given $\mathcal { L }$ with a pre-learned neural network. Seminal works of Bosnjak et al. (2017) and Gaunt et al. (2016) proposed first producing a high-level sketch of the program using procedural knowledge, and then synthesizing the program by combining the sketch with a neural or enumerative synthesis engine. In contrast, R3NN (Parisotto et al., 2016) and RobustFill (Devlin et al., 2017) systems synthesize the program end-to-end using a neural network; Devlin et al. (2017) show that RobustFill in fact outperforms R3NN. However, RobustFill does not guarantee generation of spec-satisfying programs and often requires more than one example to find the intended program. In fact, our empirical evaluation (Section 4) shows that our hybrid synthesis approach significantly outperforms the purely statistical approach of RobustFill.
223
+
224
+ DeepCoder (Balog et al., 2017) is also a hybrid synthesis system that guides enumerative program synthesis by prioritizing DSL operators according to a spec-driven likelihood distribution on the same. However, NGDS differs from DeepCoder in two important ways: (a) it guides the search process at each recursive level in a top-down goal-oriented enumeration and thus reshapes the search tree, (b) it is trained on real-world data instead of random programs, thus achieving better generalization.
225
+
226
+ Symbolic Program Synthesis has been studied extensively in the PL community (Gulwani et al., 2017; Alur et al., 2013), dating back as far as 1960s (Waldinger & Lee, 1969). Most approaches employ either bottom-up enumerative search (Udupa et al., 2013), constraint solving (Torlak & Bodik, 2013), or inductive logic programming (Lin et al., 2014), and thus scale poorly to real-world industrial applications (e.g. data wrangling applications). In this work, we build upon deductive search, first studied for synthesis by Manna & Waldinger (1971), and primarily used for program synthesis from formal logical specifications (Puschel et al., 2005; Chaudhari & Damani, 2015). Gulwani (2011) and later Polozov & Gulwani (2015) used it to build PROSE, a commercially successful domain-agnostic system for PBE. While its deductive search guarantees program correctness and also good generalization via an accurate ranking function, it still takes several seconds on complex tasks. Thus, speeding up deductive search requires considerable engineering to develop manual heuristics. NGDS instead integrates neural-driven predictions at each level of deductive search to alleviate this drawback. Work of Loos et al. (2017) represents the closest work with a similar technique but their work is applied to an automated theorem prover, and hence need not care about generalization. In contrast, NGDS guides the search toward generalizable programs while relying on the underlying symbolic engine to generate correct programs.
227
+
228
+ # 6 CONCLUSION
229
+
230
+ We studied the problem of real-time program synthesis with a small number of input-output examples. For this problem, we proposed a neural-guided system that builds upon PROSE, a state-of-the-art symbolic logic based system. Our system avoids top-down enumerative grammar exploration required by PROSE thus providing impressive synthesis performance while still retaining key advantages of a deductive system. That is, compared to existing neural synthesis techniques, our system enjoys following advantages: a) correctness: programs generated by our system are guaranteed to satisfy the given input-output specification, b) generalization: our system learns the user-intended program with just one input-output example in around $60 \%$ test cases while existing neural systems learn such a program in only $16 \%$ test cases, c) synthesis time: our system can solve most of the test cases in less than 0.1 sec and provide impressive performance gains over both neural as well symbolic systems.
231
+
232
+ The key take-home message of this work is that a deep integration of a symbolic deductive inference based system with statistical techniques leads to best of both the worlds where we can avoid extensive engineering effort required by symbolic systems without compromising the quality of generated programs, and at the same time provide significant performance (when measured as synthesis time) gains. For future work, exploring better learning models for production rule selection and applying our technique to diverse and more powerful grammars should be important research directions.
233
+
234
+ # REFERENCES
235
+
236
+ Rajeev Alur, Rastislav Bodík, Garvit Juniwal, Milo M. K. Martin, Mukund Raghothaman, Sanjit A. Seshia, Rishabh Singh, Armando Solar-Lezama, Emina Torlak, and Abhishek Udupa. Syntaxguided synthesis. In Formal Methods in Computer-Aided Design (FMCAD), pp. 1–8, 2013.
237
+
238
+ Matej Balog, Alexander L Gaunt, Marc Brockschmidt, Sebastian Nowozin, and Daniel Tarlow. DeepCoder: Learning to write programs. In International Conference on Learning Representations (ICLR), 2017.
239
+
240
+ Matko Bosnjak, Tim Rocktäschel, Jason Naradowsky, and Sebastian Riedel. Programming with a differentiable Forth interpreter. In Proceedings of the 34th International Conference on Machine Learning, ICML 2017, Sydney, NSW, Australia, 6-11 August 2017, pp. 547–556, 2017.
241
+
242
+ Jonathon Cai, Richard Shin, and Dawn Song. Making neural programming architectures generalize via recursion. In International Conference on Learning Representations (ICLR), 2017.
243
+
244
+ Dipak L Chaudhari and Om Damani. Combining top-down and bottom-up techniques in program derivation. In International Symposium on Logic-Based Program Synthesis and Transformation, pp. 244–258. Springer, 2015.
245
+
246
+ Jens Clausen. Branch and bound algorithms – principles and examples. Department of Computer Science, University of Copenhagen, 1999.
247
+
248
+ Jacob Devlin, Jonathan Uesato, Surya Bhupatiraju, Rishabh Singh, Abdel-rahman Mohamed, and Pushmeet Kohli. RobustFill: Neural program learning under noisy I/O. In International Conference on Machine Learning (ICML), 2017.
249
+
250
+ Kevin Ellis and Sumit Gulwani. Learning to learn programs from examples: Going beyond program structure. In International Joint Conference on Artifical Intelligence (IJCAI), 2017.
251
+
252
+ Alexander L Gaunt, Marc Brockschmidt, Rishabh Singh, Nate Kushman, Pushmeet Kohli, Jonathan Taylor, and Daniel Tarlow. TerpreT: A probabilistic programming language for program induction. CoRR, abs/1608.04428, 2016. URL http://arxiv.org/abs/1608.04428.
253
+
254
+ Alex Graves, Greg Wayne, and Ivo Danihelka. Neural Turing machines. CoRR, abs/1410.5401, 2014. URL http://arxiv.org/abs/1410.5401.
255
+
256
+ Sumit Gulwani. Automating string processing in spreadsheets using input-output examples. In Principles of Programming Languages (POPL), volume 46, pp. 317–330, 2011.
257
+
258
+ Sumit Gulwani and Prateek Jain. Programming by examples: Pl meets ml. In Asian Symposium on Programming Languages and Systems, pp. 3–20. Springer, 2017.
259
+
260
+ Sumit Gulwani, Oleksandr Polozov, and Rishabh Singh. Program synthesis. Foundations and Trends in Programming Languages, 4(1-2):1–119, 2017. doi: 10.1561/2500000010. URL https: //doi.org/10.1561/2500000010.
261
+
262
+ Sepp Hochreiter and Jürgen Schmidhuber. Long short-term memory. Neural Comput., 9(8):1735– 1780, November 1997. ISSN 0899-7667. doi: 10.1162/neco.1997.9.8.1735. URL http://dx. doi.org/10.1162/neco.1997.9.8.1735.
263
+
264
+ Łukasz Kaiser and Ilya Sutskever. Neural GPUs learn algorithms. CoRR, abs/1511.08228, 2015. URL http://arxiv.org/abs/1511.08228.
265
+
266
+ Diederik Kingma and Jimmy Ba. Adam: A method for stochastic optimization. In International Conference on Learning Representations (ICLR), 2014.
267
+
268
+ Vu Le and Sumit Gulwani. FlashExtract: A framework for data extraction by examples. In ACM SIGPLAN Notices, volume 49, pp. 542–553. ACM, 2014.
269
+
270
+ Dianhuan Lin, Eyal Dechter, Kevin Ellis, Joshua Tenenbaum, and Stephen Muggleton. Bias reformulation for one-shot function induction. In Proceedings of the Twenty-first European Conference on Artificial Intelligence, pp. 525–530. IOS Press, 2014.
271
+
272
+ Sarah M. Loos, Geoffrey Irving, Christian Szegedy, and Cezary Kaliszyk. Deep network guided proof search. In LPAR-21, 21st International Conference on Logic for Programming, Artificial Intelligence and Reasoning, Maun, Botswana, 7-12th May 2017, pp. 85–105, 2017.
273
+
274
+ Zohar Manna and Richard J. Waldinger. Toward automatic program synthesis. Communications of the ACM, 14(3):151–165, 1971.
275
+
276
+ Emilio Parisotto, Abdel-rahman Mohamed, Rishabh Singh, Lihong Li, Dengyong Zhou, and Pushmeet Kohli. Neuro-symbolic program synthesis. In International Conference on Learning Representations (ICLR), 2016.
277
+
278
+ Oleksandr Polozov and Sumit Gulwani. FlashMeta: A framework for inductive program synthesis. In International Conference on Object-Oriented Programming, Systems, Languages, and Applications (OOPSLA), pp. 107–126, 2015.
279
+
280
+ Markus Puschel, José MF Moura, Jeremy R Johnson, David Padua, Manuela M Veloso, Bryan W Singer, Jianxin Xiong, Franz Franchetti, Aca Gacic, Yevgen Voronenko, et al. SPIRAL: Code generation for DSP transforms. Proceedings of the IEEE, 93(2):232–275, 2005.
281
+
282
+ Scott Reed and Nando De Freitas. Neural programmer-interpreters. In International Conference on Learning Representations (ICLR), 2016.
283
+
284
+ Reudismam Rolim, Gustavo Soares, Loris D’Antoni, Oleksandr Polozov, Sumit Gulwani, Rohit Gheyi, Ryo Suzuki, and Björn Hartmann. Learning syntactic program transformations from examples. In International Conference on Software Engineering (ICSE), pp. 404–415, 2017.
285
+
286
+ Frank Seide and Amit Agarwal. CNTK: Microsoft’s open-source deep-learning toolkit. In International Conference on Knowledge Discovery and Data Mining (KDD), pp. 2135–2135, 2016.
287
+
288
+ Rishabh Singh and Sumit Gulwani. Predicting a correct program in programming by example. In Computer-Aided Verification (CAV), 2015.
289
+
290
+ Emina Torlak and Rastislav Bodik. Growing solver-aided languages with Rosette. In Proceedings of the 2013 ACM international symposium on New ideas, new paradigms, and reflections on programming & software, pp. 135–152. ACM, 2013.
291
+
292
+ Abhishek Udupa, Arun Raghavan, Jyotirmoy V. Deshmukh, Sela Mador-Haim, Milo M.K. Martin, and Rajeev Alur. TRANSIT: Specifying protocols with concolic snippets. In Programming Languages Design and Implementation (PLDI), pp. 287–296, 2013.
293
+
294
+ Richard J Waldinger and Richard CT Lee. PROW: A step toward automatic program writing. In International Joint Conference on Artificial Intelligence (IJCAI), pp. 241–252, 1969.
295
+
296
+ Wojciech Zaremba, Tomas Mikolov, Armand Joulin, and Rob Fergus. Learning simple algorithms from examples. In International Conference on Machine Learning (ICML), 2016.
297
+
298
+ # A ROBUSTFILL PERFORMANCE WITH DIFFERENT BEAM SIZES
299
+
300
+ For our experiments, we implemented RobustFill with the beam size of 100, as it presented a good trade-off between generalization accuracy and performance hit. The following table shows a detailed comparison of RobustFill’s generalization accuracy and performance for different beam sizes and numbers of training examples.
301
+
302
+ <table><tr><td>Number of examples (m)</td><td>Beam size</td><td>Accuracy (%)</td><td>Speed-up(× PROSE)</td></tr><tr><td rowspan="3">1</td><td>10</td><td>18.4</td><td>0.41</td></tr><tr><td>100</td><td>24.5</td><td>0.25</td></tr><tr><td>1000</td><td>34.1</td><td>0.04</td></tr><tr><td rowspan="3">2</td><td>10</td><td>32.2</td><td>0.43</td></tr><tr><td>100</td><td>39.7</td><td>0.27</td></tr><tr><td>1000</td><td>47.6</td><td>0.04</td></tr><tr><td rowspan="3">3</td><td>10</td><td>49.8</td><td>0.48</td></tr><tr><td>100</td><td>56.4</td><td>0.30</td></tr><tr><td>1000</td><td>63.4</td><td>0.04</td></tr></table>
303
+
304
+ Table 3: Generalization accuracy and performance of RobustFill for different beam sizes and numbers of training examples.
305
+
306
+ B PERFORMANCE OF BEST NGDS MODEL ON ALL NON-TRAINING TASKS
307
+
308
+ <table><tr><td>Task #</td><td>Test/Val</td><td>PROSE Time (s)</td><td>NGDS Time (s)</td><td>Speed-up</td><td>PROSE Correct?</td><td>NGDS Correct?</td></tr><tr><td>1</td><td>Test</td><td>3.0032564</td><td>0.233686</td><td>12.85167</td><td></td><td>√</td></tr><tr><td>2</td><td>Validation</td><td>1.1687841</td><td>0.211069</td><td>5.53745</td><td></td><td></td></tr><tr><td>3</td><td>Validation</td><td>0.4490832</td><td>0.1307367</td><td>3.43502</td><td>√</td><td></td></tr><tr><td>4</td><td>Test</td><td>6.665234</td><td>2.012157</td><td>3.312482</td><td></td><td>x/x</td></tr><tr><td>5</td><td>Test</td><td>2.28298</td><td>0.83715</td><td>2.727086</td><td></td><td>X</td></tr><tr><td>6</td><td>Test</td><td>3.0391034</td><td>1.1410092</td><td>2.663522</td><td></td><td>X</td></tr><tr><td>7</td><td>Validation</td><td>0.5487662</td><td>0.2105728</td><td>2.606064</td><td></td><td></td></tr><tr><td>8</td><td>Test</td><td>2.4120103</td><td>0.9588959</td><td>2.515404</td><td></td><td>X</td></tr><tr><td>9</td><td>Validation</td><td>7.6010733</td><td>3.052303</td><td>2.490275</td><td>+</td><td></td></tr><tr><td>10</td><td>Test</td><td>2.1165486</td><td>0.8816776</td><td>2.400592</td><td></td><td>xx/x</td></tr><tr><td>11</td><td>Test</td><td>0.9622929</td><td>0.405093</td><td>2.375486</td><td></td><td></td></tr><tr><td>12</td><td>Validation</td><td>0.4033455</td><td>0.1936532</td><td>2.082824</td><td></td><td></td></tr><tr><td>13</td><td>Test</td><td>0.4012993</td><td>0.1929299</td><td>2.080026</td><td></td><td></td></tr><tr><td>14</td><td>Validation</td><td>2.9467418</td><td>1.4314372</td><td>2.05859</td><td></td><td></td></tr><tr><td>15</td><td>Test</td><td>0.3855433</td><td>0.1987497</td><td>1.939843</td><td></td><td>×</td></tr><tr><td>16</td><td>Test</td><td>6.0043011</td><td>3.1862577</td><td>1.884437</td><td></td><td>X</td></tr><tr><td>17</td><td>Test</td><td>3.0316721</td><td>1.6633142</td><td>1.82267</td><td></td><td>X</td></tr><tr><td>18</td><td>Test</td><td>0.3414629</td><td>0.1933263</td><td>1.766252</td><td></td><td></td></tr><tr><td>19</td><td>Validation</td><td>0.3454594</td><td>0.2014236</td><td>1.715089</td><td></td><td></td></tr><tr><td>20</td><td>Test</td><td>0.3185586</td><td>0.202928</td><td>1.569811</td><td></td><td></td></tr><tr><td>21</td><td>Test</td><td>0.2709963</td><td>0.1734634</td><td>1.562268</td><td></td><td></td></tr><tr><td>22</td><td>Test</td><td>0.4859534</td><td>0.3169533</td><td>1.533202</td><td></td><td></td></tr><tr><td>23</td><td>Test</td><td>0.8672071</td><td>0.5865048</td><td>1.478602</td><td></td><td></td></tr><tr><td>24</td><td>Validation</td><td>0.3626161</td><td>0.2590434</td><td>1.399828</td><td></td><td></td></tr><tr><td>25</td><td>Validation</td><td>2.3343791</td><td>1.6800684</td><td>1.389455</td><td></td><td></td></tr><tr><td>26</td><td>Test</td><td>0.2310051</td><td>0.1718745</td><td>1.344034</td><td></td><td></td></tr><tr><td>27</td><td>Test</td><td>0.1950921</td><td>0.1456817</td><td>1.339167</td><td></td><td></td></tr><tr><td>28</td><td>Test</td><td>0.8475303</td><td>0.6425532</td><td>1.319004</td><td></td><td></td></tr><tr><td>29</td><td>Validation</td><td>0.4064375</td><td>0.316499</td><td>1.284167</td><td></td><td></td></tr><tr><td>30</td><td>Test</td><td>0.2601689</td><td>0.2083826</td><td>1.248515</td><td></td><td></td></tr><tr><td>31</td><td>Test</td><td>0.2097732</td><td>0.1753706</td><td>1.196171</td><td></td><td></td></tr><tr><td>32</td><td>Test</td><td>1.2224533</td><td>1.0264273</td><td>1.190979</td><td></td><td>X</td></tr><tr><td>33</td><td>Test</td><td>0.5431827</td><td>0.4691296</td><td>1.157852</td><td></td><td></td></tr><tr><td>34</td><td>Validation</td><td>0.4183223</td><td>0.3685321</td><td>1.135104</td><td></td><td></td></tr></table>
309
+
310
+ <table><tr><td>Task #</td><td>Test/Val</td><td>PROSE Time (s))</td><td>NGDS Time (s)</td><td>Speed-up</td><td>PROSECorr</td></tr><tr><td>35</td><td>Validation</td><td>0.2497723</td><td>0.2214195</td><td>1.12805</td><td>X</td></tr><tr><td>36</td><td>Validation</td><td>0.2385918</td><td>0.212407</td><td>1.123277</td><td>X</td></tr><tr><td>37</td><td>Test</td><td>0.2241414</td><td>0.2004937</td><td>1.117947</td><td></td></tr><tr><td>38</td><td>Validation</td><td>0.2079995</td><td>0.1880859</td><td>1.105875</td><td></td></tr><tr><td>39</td><td>Test</td><td>0.2788713</td><td>0.2654384</td><td>1.050606</td><td></td></tr><tr><td>40</td><td>Test</td><td>0.1821743</td><td>0.1758255</td><td>1.036109</td><td></td></tr><tr><td>41</td><td>Validation</td><td>0.1486939</td><td>0.1456755</td><td>1.02072</td><td></td></tr><tr><td>42</td><td>Test</td><td>0.3981185</td><td>0.3900767</td><td>1.020616</td><td></td></tr><tr><td>43</td><td>Test</td><td>0.9959218</td><td>0.9960901</td><td>0.999831</td><td></td></tr><tr><td>44</td><td>Test</td><td>0.2174055</td><td>0.2239088</td><td>0.970956</td><td></td></tr><tr><td>45</td><td>Test</td><td>1.8684116</td><td>1.9473475</td><td>0.959465</td><td></td></tr><tr><td>46</td><td>Test</td><td>0.1357812</td><td>0.1428591</td><td>0.950455</td><td></td></tr><tr><td>47</td><td>Validation</td><td>0.2549691</td><td>0.2709866</td><td>0.940892</td><td></td></tr><tr><td>48</td><td>Test</td><td>0.1650636</td><td>0.1762617</td><td>0.936469</td><td></td></tr><tr><td>49</td><td>Validation</td><td>0.5368683</td><td>0.5781537</td><td>0.928591</td><td></td></tr><tr><td>50</td><td>Test</td><td>0.1640937</td><td>0.1851361</td><td>0.886341</td><td></td></tr><tr><td>51</td><td>Validation</td><td>0.5006552</td><td>0.5736976</td><td></td><td></td></tr><tr><td>52</td><td>Test</td><td>0.2064185</td><td>0.2401594</td><td>0.872681</td><td></td></tr><tr><td>53</td><td>Validation</td><td>0.2381335</td><td>0.277788</td><td>0.859506 0.857249</td><td></td></tr><tr><td>54</td><td>Test</td><td>0.2171637</td><td>0.2677121</td><td>0.811184</td><td></td></tr><tr><td>55</td><td>Test</td><td>0.6307356</td><td>0.7807711</td><td></td><td></td></tr><tr><td>56</td><td>Validation</td><td>0.3462029</td><td>0.4325302</td><td>0.807837</td><td></td></tr><tr><td>57</td><td>Test</td><td></td><td></td><td>0.800413</td><td></td></tr><tr><td>58</td><td>Validation</td><td>0.4285604</td><td>0.5464594</td><td>0.784249</td><td></td></tr><tr><td>59</td><td>Test</td><td>0.155915</td><td>0.1992245</td><td>0.78261</td><td></td></tr><tr><td>60</td><td>Validation</td><td>0.1651815</td><td>0.2135129</td><td>0.773637</td><td></td></tr><tr><td>61</td><td>Test</td><td>0.1212689</td><td>0.1571558</td><td>0.771648</td><td></td></tr><tr><td>62</td><td>Validation</td><td>0.1980844</td><td>0.257616</td><td>0.768913</td><td></td></tr><tr><td>63</td><td>Test</td><td>0.1534717</td><td>0.2004651</td><td>0.765578</td><td></td></tr><tr><td>64</td><td>Test</td><td>0.2443636</td><td>0.3258476</td><td>0.749932</td><td></td></tr><tr><td>65</td><td>Validation</td><td>0.1217696</td><td>0.1635984</td><td>0.74432</td><td></td></tr><tr><td>66</td><td>Validation</td><td>0.2446501</td><td>0.3301224</td><td>0.741089</td><td></td></tr><tr><td>67</td><td>Test</td><td>0.6579789</td><td>0.8886647</td><td>0.740413</td><td></td></tr><tr><td>68</td><td>Test</td><td>0.1490806</td><td>0.2022204</td><td>0.737218</td><td></td></tr><tr><td>69</td><td>Test</td><td>0.2668753 0.1072814</td><td>0.3681659</td><td>0.724878</td><td></td></tr><tr><td>70</td><td>Validation</td><td></td><td>0.1487589</td><td>0.721176</td><td></td></tr><tr><td>71</td><td>Test</td><td>0.1310034</td><td>0.181912</td><td>0.720147</td><td></td></tr><tr><td>72</td><td>Test</td><td>0.1954476</td><td>0.273414</td><td>0.714841</td><td></td></tr><tr><td>73</td><td>Test</td><td>0.3323319</td><td>0.468445</td><td>0.709436</td><td></td></tr><tr><td>74</td><td>Test</td><td>0.2679471</td><td>0.3806013</td><td>0.70401</td><td></td></tr><tr><td>75</td><td>Test</td><td>1.1505939</td><td>1.6429378</td><td>0.700327</td><td></td></tr><tr><td>76</td><td></td><td>0.1318375</td><td>0.1898685</td><td>0.694362</td><td></td></tr><tr><td>77</td><td>Test</td><td>0.15018</td><td>0.2189491</td><td>0.685913</td><td></td></tr><tr><td>78</td><td>Test</td><td>0.146774</td><td>0.2144594</td><td>0.684391</td><td></td></tr><tr><td>79</td><td>Test Test</td><td>0.1123303</td><td>0.1665129</td><td>0.674604</td><td></td></tr><tr><td>80</td><td>Test</td><td>0.1623439</td><td>0.2468262</td><td>0.657726</td><td></td></tr><tr><td>81</td><td>Test</td><td>0.4243661 0.2945639</td><td>0.6563517 0.4662018</td><td>0.646553 0.631838</td><td></td></tr><tr><td>82</td><td>Validation</td><td>0.0892761</td><td>0.1419142</td><td>0.629085</td><td></td></tr><tr><td>83</td><td>Test</td><td>0.1992316</td><td>0.3229269</td><td>0.616956</td><td></td></tr><tr><td>84</td><td>Validation</td><td>0.3260828</td><td>0.5294719</td><td>0.615864</td><td></td></tr><tr><td>85</td><td>Test</td><td>0.2181703</td><td>0.3576818</td><td>0.609956</td><td></td></tr><tr><td>86</td><td>Test</td><td>0.1757585</td><td>0.3006565</td><td>0.584582</td><td></td></tr><tr><td>87</td><td>Validation</td><td>0.1811467</td><td>0.3107196</td><td>0.582991</td><td></td></tr><tr><td>88</td><td>Test</td><td>0.2774191</td><td>0.4759698</td><td>0.58285</td><td></td></tr><tr><td>89</td><td>Test</td><td>0.137414</td><td>0.2358583</td><td>0.582613</td><td></td></tr><tr><td>90</td><td>Validation</td><td>0.1051238</td><td>0.1834589</td><td>0.57301</td><td></td></tr><tr><td>91</td><td>Validation</td><td>1.5624891</td><td>2.7446374</td><td>0.569288</td><td></td></tr><tr><td>92</td><td>Validation</td><td>0.1104184</td><td>0.1958337</td><td>0.563838</td><td></td></tr><tr><td>93</td><td>Validation</td><td>0.1233551</td><td>0.2228252</td><td>0.553596</td><td></td></tr><tr><td>94</td><td>Validation</td><td>0.189019</td><td>0.3445496</td><td>0.548597</td><td></td></tr><tr><td>95</td><td>Validation</td><td>0.2997031</td><td>0.5486731</td><td>0.546233 0.543648</td><td></td></tr><tr><td>96 97</td><td>Test Validation</td><td>0.1057559 0.129731</td><td>0.19453 0.2426926 0.534549</td></table>
311
+
312
+ <table><tr><td>Task #</td><td>Test/Val</td><td>PROSE Time (s)</td><td>NGDS Time (s)</td><td>Speed-up</td><td>PROSE Correct?</td><td>NGDS Correct?</td></tr><tr><td>98</td><td>Test</td><td>0.1706376</td><td>0.320323</td><td>0.532705</td><td></td><td></td></tr><tr><td>99</td><td>Test</td><td>0.0936175</td><td>0.1764753</td><td>0.530485</td><td></td><td></td></tr><tr><td>100</td><td>Test</td><td>0.2101397</td><td>0.40277</td><td>0.521736</td><td></td><td>X</td></tr><tr><td>101</td><td>Test</td><td>0.1816704</td><td>0.3507656</td><td>0.517925</td><td></td><td></td></tr><tr><td>102</td><td>Validation</td><td>0.1516109</td><td>0.2993282</td><td>0.506504</td><td>√νxνν√</td><td></td></tr><tr><td>103</td><td>Test</td><td>0.1102942</td><td>0.2185006</td><td>0.504778</td><td></td><td></td></tr><tr><td>104</td><td>Validation</td><td>1.1538661</td><td>2.3299578</td><td>0.49523</td><td></td><td></td></tr><tr><td>105</td><td>Test</td><td>0.1241092</td><td>0.251046</td><td>0.494368</td><td></td><td></td></tr><tr><td>106</td><td>Test</td><td>1.068263</td><td>2.176145</td><td>0.490897</td><td></td><td></td></tr><tr><td>107</td><td>Validation</td><td>0.1899474</td><td>0.389012</td><td>0.488282</td><td></td><td></td></tr><tr><td>108</td><td>Validation</td><td>0.205652</td><td>0.4312716</td><td>0.47685</td><td></td><td></td></tr><tr><td>109</td><td>Test</td><td>0.1332348</td><td>0.2819654</td><td>0.472522</td><td></td><td></td></tr><tr><td>110</td><td>Test</td><td>0.2137989</td><td>0.4625152</td><td>0.462253</td><td>X</td><td>X</td></tr><tr><td>111</td><td>Validation</td><td>0.2233911</td><td>0.4898705</td><td>0.456021</td><td></td><td>X</td></tr><tr><td>112</td><td>Validation</td><td>0.1742123</td><td>0.3872159</td><td>0.44991</td><td></td><td></td></tr><tr><td>113</td><td>Test</td><td>0.1798306</td><td>0.4059525</td><td>0.442984</td><td></td><td></td></tr><tr><td>114</td><td>Validation</td><td>0.1576141</td><td>0.3592128</td><td>0.438776</td><td></td><td></td></tr><tr><td>115</td><td>Test</td><td>0.1441545</td><td>0.3462711</td><td>0.416305</td><td></td><td></td></tr><tr><td>116</td><td>Validation</td><td>0.189833</td><td>0.4649153</td><td>0.408317</td><td></td><td>X</td></tr><tr><td>117</td><td>Validation</td><td>0.3401477</td><td>1.0468088</td><td>0.324938</td><td></td><td></td></tr><tr><td>118</td><td>Validation</td><td>0.1575744</td><td>0.6015111</td><td>0.261964</td><td></td><td>X</td></tr><tr><td>119</td><td>Validation</td><td>0.7252624</td><td>3.2088775</td><td>0.226017</td><td></td><td></td></tr><tr><td>120</td><td>Test</td><td>0.1288099</td><td>0.5958986</td><td>0.216161</td><td></td><td></td></tr></table>
313
+
314
+ # C ML-BASED RANKER
315
+
316
+ As noted in Section 2, learning a ranking function is an interesting problem in itself and is orthogonal to our work. Since our method can be used along with any accurate ranking function, we assume black-box access to such a high-quality ranker and specifically, use the state-of-the-art ranking function of PROSE that involves a significant amount of hand engineering.
317
+
318
+ In this section, we evaluate the performance of our method and PROSE when employing a competitive ranker learned in a data-driven manner (Gulwani & Jain, 2017). From the table below, it can be observed that when using an ML-based ranking function, our method achieves an average $\approx 2 \times$ speed-up over PROSE while still achieving comparable generalization accuracy .
319
+
320
+ Table 5: Generalization accuracy and speed-up of NGDS variants vs. PROSE where all methods use a machine learning based ranking function from Gulwani & Jain (2017).
321
+
322
+ <table><tr><td>Metric</td><td>PROSE</td><td>NGDS (T1,BB)</td><td>NGDS (Ti + POS,BB)</td></tr><tr><td>Accuracy (% of 73)</td><td>65.75</td><td>65.75</td><td>64.38</td></tr><tr><td>Speed-up (× PROSE)</td><td>1.00</td><td>2.15</td><td>2.46</td></tr></table>
parse/train/rywDjg-RW/rywDjg-RW_content_list.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/rywDjg-RW/rywDjg-RW_middle.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/rywDjg-RW/rywDjg-RW_model.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/te7PVH1sPxJ/te7PVH1sPxJ.md ADDED
@@ -0,0 +1,363 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # CONVEX POTENTIAL FLOWS: UNIVERSAL PROBABILITY DISTRIBUTIONS WITH OPTIMAL TRANSPORT AND CONVEX OPTIMIZATION
2
+
3
+ Chin-Wei Huang University of Montreal & Mila chin-wei.huang@umontreal.ca
4
+
5
+ Ricky T. Q. Chen University of Toronto & Vector Institute rtqichen@cs.toronto.edu
6
+
7
+ # Aaron Courville
8
+
9
+ Christos Tsirigotis University of Montreal & Mila christos.tsirigotis@umontreal.ca
10
+
11
+ University of Montreal, Mila & CIFAR Fellow aaron.courville@umontreal.ca
12
+
13
+ # ABSTRACT
14
+
15
+ Flow-based models are powerful tools for designing probabilistic models with tractable density. This paper introduces Convex Potential Flows (CP-Flow), a natural and efficient parameterization of invertible models inspired by the optimal transport (OT) theory. CP-Flows are the gradient map of a strongly convex neural potential function. The convexity implies invertibility and allows us to resort to convex optimization to solve the convex conjugate for efficient inversion. To enable maximum likelihood training, we derive a new gradient estimator of the log-determinant of the Jacobian, which involves solving an inverse-Hessian vector product using the conjugate gradient method. The gradient estimator has constantmemory cost, and can be made effectively unbiased by reducing the error tolerance level of the convex optimization routine. Theoretically, we prove that CP-Flows are universal density approximators and are optimal in the OT sense. Our empirical results show that CP-Flow performs competitively on standard benchmarks of density estimation and variational inference.
16
+
17
+ # 1 INTRODUCTION
18
+
19
+ Normalizing flows (Dinh et al., 2014; Rezende & Mohamed, 2015) have recently gathered much interest within the machine learning community, ever since its recent breakthrough in modelling high dimensional image data (Dinh et al., 2017; Kingma & Dhariwal, 2018). They are characterized by an invertible mapping that can reshape the distribution of its input data into a simpler or more complex one. To enable efficient training, numerous tricks have been proposed to impose structural constraints on its parameterization, such that the density of the model can be tractably computed.
20
+
21
+ We ask the following question: “what is the natural way to parameterize a normalizing flow?” To gain a bit more intuition, we start from the one-dimension case. If a function $f : \mathbb { R } \mathbb { R }$ is continuous, it is invertible (injective onto its image) if and only if it is strictly monotonic. This means that if we are only allowed to move the probability mass continuously without flipping the order of the particles, then we can only rearrange them by changing the distance in between.
22
+
23
+ In this work, we seek to generalize the above intuition of monotone rearrangement in 1D. We do so by motivating the parameterization of normalizing flows from an optimal transport perspective, which allows us to define some notion of rearrangement cost (Villani, 2008). It turns out, if we want the output of a flow to follow some desired distribution, under mild regularity conditions, we can characterize the unique optimal mapping by a convex potential (Brenier, 1991). In light of this, we propose to parameterize normalizing flows by the gradient map of a (strongly) convex potential. Owing to this theoretical insight, the proposed method is provably universal and optimal; this means the proposed flow family can approximate arbitrary distributions and requires the least amount of transport cost. Furthermore, the parameterization with convex potentials allows us to formulate model inversion and gradient estimation as convex optimization problems. As such, we make use of existing tools from the convex optimization literature to cheaply and efficiently estimate all quantities of interest.
24
+
25
+ In terms of the benefits of parameterizing a flow as a gradient field, the convex potential is an $\mathbb { R } ^ { d } \to \mathbb { R }$ function, which is different from most existing discrete-time flows which are $\mathbb { R } ^ { d } \to \mathbb { R } ^ { d }$ . This makes CP-Flow relatively compact. It is also arguably easier to design a convex architecture, as we do not need to satisfy constraints such as orthogonality or Lipschitzness; the latter two usually require a direct or an iterative reparameterization of the parameters. Finally, it is possible to incorporate additional structure such as equivariance (Cohen & Welling, 2016; Zaheer et al., 2017) into the flow’s parameterization, making CP-Flow a more flexible general purpose density model.
26
+
27
+ # 2 BACKGROUND: NORMALIZING FLOWS AND OPTIMAL TRANSPORT
28
+
29
+ Normalizing flows are characterized by a differentiable, invertible neural network $f$ such that the probability density of the network’s output can be computed conveniently using the change-ofvariable formula
30
+
31
+ $$
32
+ p _ { Y } ( f ( x ) ) = p _ { X } ( x ) \left| { \frac { \partial f ( x ) } { \partial x } } \right| ^ { - 1 } \qquad \Longleftrightarrow \qquad p _ { Y } ( y ) = p _ { X } ( f ^ { - 1 } ( y ) ) \left| { \frac { \partial f ^ { - 1 } ( y ) } { \partial y } } \right|
33
+ $$
34
+
35
+ where the Jacobian determinant term captures the local expansion or contraction of the density near $x$ (resp. $y$ ) induced by the mapping $f$ (resp. $f ^ { - 1 }$ ), and $p _ { X }$ is the density of a random variable $X$ . The invertibility requirement has led to the design of many special neural network parameterizations such as triangular maps, ordinary differential equations, orthogonality or Lipschitz constraints.
36
+
37
+ Universal Flows For a general learning framework to be meaningful, a model needs to be flexible enough to capture variations in the data distribution. In the context of density modeling, this corresponds to the model’s capability to represent arbitrary probability distributions of interest. Even though there exists a long history of literature on universal approximation capability of deep neural networks (Cybenko, 1989; Lu et al., 2017; Lin & Jegelka, 2018), invertible neural networks generally have limited expressivity and cannot approximate arbitrary functions. However, for the purpose of approximating a probability distribution, it suffices to show that the distribution induced by a normalizing flow is universal.
38
+
39
+ Among many ways to establish distributional universality of flow based methods (e.g. Huang et al. 2018; 2020b; Teshima et al. 2020; Kong & Chaudhuri 2020), one particular approach is to approximate a deterministic coupling between probability measures. Given a pair of probability densities $p _ { X }$ and $p _ { Y }$ , a deterministic coupling is a mapping $g$ such that $g ( X ) \sim p _ { Y }$ if $X \sim p _ { X }$ . We seek to find a coupling that is invertible, or at least can be approximated by invertible mappings.
40
+
41
+ Optimal Transport Let $c ( x , y )$ be a cost function. The Monge problem (Villani, 2008) pertains to finding the optimal transport map $g$ that realizes the minimal expected cost
42
+
43
+ $$
44
+ J _ { c } ( p _ { X } , p _ { Y } ) = \operatorname* { i n f } _ { \widetilde { g } : \widetilde { g } ( X ) \sim p _ { Y } } \mathbb { E } _ { X \sim p _ { X } } \left[ c ( X , \widetilde { g } ( X ) ) \right]
45
+ $$
46
+
47
+ When the second moments of $X$ and $Y$ are both finite, and $X$ is regular enough (e.g. having a density), then the special case of $c ( x , y ) \ = \ | | x - y | | ^ { 2 }$ has an interesting solution, a celebrated theorem due to Brenier (1987; 1991):
48
+
49
+ Theorem 1 (Brenier’s Theorem, Theorem 1.22 of Santambrogio (2015)). Let $\mu , \nu$ be probability measures with a finite second moment, and assume $\mu$ has a Lebesgue density $p _ { X }$ . Then there exists a convex potential $G$ such that the gradient map $g : = \nabla G$ (defined up to a null set) uniquely solves the Monge problem in eq. (2) with the quadratic cost function $c ( x , y ) = | | x - y | | ^ { 2 }$ .
50
+
51
+ Some recent works are also inspired by Brenier’s theorem and utilize a convex potential to parameterize a critic model, starting from Taghvaei & Jalali (2019), and further built upon by Makkuva et al. (2019) who parameterize a generator with a convex potential and concurrently by Korotin et al. (2019). Our work sets itself apart from these prior works in that it is entirely likelihood-based, minimizing the (empirical) KL divergence as opposed to an approximate optimal transport cost.
52
+
53
+ ![](images/88f501b26e8a23835a55bcdfca780564e9c1bf8c0b540c4e2ac5b9d64f1ee171.jpg)
54
+ Figure 1: Illustration of Convex Potential Flow. (a) Data $x$ drawn from a mixture of Gaussians. (b) Learned convex potential $F$ . (c) Mesh grid distorted by the gradient map of the convex potential $f = \nabla F$ . (d) Encoding of the data via the gradient map $z = f ( x )$ . Notably, the encoding is the value of the gradient of the convex potential. When the curvature of the potential function is locally flat, gradient values are small and this results in a contraction towards the origin.
55
+
56
+ # 3 CONVEX POTENTIAL FLOWS
57
+
58
+ Given a strictly convex potential $F$ , we can define an injective map (invertible from its image) via its gradient $f = \nabla F$ , since the Jacobian of $f$ is the Hessian matrix of $F$ , and is thus positive definite. In this section, we discuss the parameterization of the convex potential $F$ (3.1), and then address gradient estimation for CP-Flows (3.2). We examine the connection to other parameterization of normalizing flows (3.3), and finally rigorously prove universality in the next section.
59
+
60
+ # 3.1 MODELING
61
+
62
+ Input Convex Neural Networks We use $L ( x )$ to denote a linear layer, and $L ^ { + } ( x )$ to denote a linear layer with positive weights. We use the (fully) input-convex neural network (ICNN, Amos et al. (2017)) to parameterize the convex potential, which has the following form
63
+
64
+ $$
65
+ F ( x ) = L _ { K + 1 } ^ { + } ( s ( z _ { K } ) ) + L _ { K + 1 } ( x ) \qquad z _ { k } : = L _ { k } ^ { + } ( s ( z _ { k - 1 } ) ) + L _ { k } ( x ) \qquad z _ { 1 } : = L _ { 1 } ( x )
66
+ $$
67
+
68
+ where $s$ is a non-decreasing, convex activation function. In this work, we use softplus-type activation functions, which is a rich family of activation functions that can be shown to uniformly approximate the ReLU activation. See Appendix B for details.
69
+
70
+ Invertibility and Inversion Procedure If the activation $s$ is twice differentiable, then the Hessian $H _ { F }$ is positive semi-definite. We can make it strongly convex by adding a quadratic term $F _ { \alpha } ( x ) =$ $\begin{array} { r } { \frac { \alpha } { 2 } | | x | | _ { 2 } ^ { 2 } + F ( x ) } \end{array}$ , such that $H _ { F _ { \alpha } } \simeq \alpha I \succ 0$ . This means the gradient map $f _ { \alpha } = \nabla F _ { \alpha }$ is injective onto its image. Furthermore, it is surjective since for any $\boldsymbol { y } ~ \in ~ \bar { \mathbb { R } ^ { d } }$ , the potential $x \ \mapsto \ \bar { F } _ { \alpha } ( x ) - y ^ { \top } x$ has a unique minimizer1 satisfying the first order condition $\nabla F _ { \alpha } ( x ) = y$ , due to the strong convexity and differentiability. We refer to this invertible mapping $f _ { \alpha }$ as the convex potential flow, or the CP-Flow. The above discussion also implies we can plug in a black-box convex solver to invert the gradient map $f _ { \alpha }$ , which we summarize in Algorithm 1. Inverting a batch of independent inputs is as simple as summing the convex potential over all inputs: since all of the entries of the scalar $l$ in the minibatch are independent of each other, computing the gradient all $l$ ’s wrt all $x$ ’s amounts to computing the gradient of the summation of $l$ ’s wrt all $x$ ’s. Due to the convex nature of the problem, a wide selection of algorithms can be used with convergence guarantees (Nesterov, 1998). In practice, we use the L-BFGS algorithm (Byrd et al., 1995) as our CvxSolver.
71
+
72
+ <table><tr><td>Algorithm1Inverting CP-Flow.</td></tr><tr><td>1: procedure INVERT(F,y, CvxSolver)</td></tr><tr><td>2: Initializex←y</td></tr><tr><td>3: def closure():</td></tr><tr><td>4: Compute loss: l ← F(x) - yTx</td></tr><tr><td>5: return l</td></tr><tr><td>6: x ← CvxSolver(closure,x)</td></tr><tr><td>7: return x</td></tr></table>
73
+
74
+ Estimating Log Probability Following equation (1), computing the log density for CP-Flows requires taking the log determinant of a symmetric positive definite Jacobian matrix (as it is the Hessian of the potential). There exists numerous works on estimating spectral densities (e.g. TalEzer & Kosloff, 1984; Silver & Roder ¨ , 1994; Han et al., 2018; Adams et al., 2018), of which this quantity is a special case. See Lin et al. (2016) for an overview of methods that only require access to Hessian-vector products. Hessian-vector products (hvp) are cheap to compute with reverse-mode automatic differentiation (Baydin et al., 2017), which does not require constructing the full Hessian matrix and has the same asymptotic cost as evaluating $F _ { \alpha }$ .
75
+
76
+ In particular, the log determinant can be rewritten in the form of a generalized trace $\operatorname { t r } \log H$ . Chen et al. (2019a) limit the spectral norm (i.e. eigenvalues) of $H$ and directly use the Taylor expansion of the matrix logarithm. Since our $H$ has unbounded eigenvalues, we use a more complex algorithm designed for symmetric matrices, the stochastic Lanczos quadrature (SLQ; Ubaru et al., 2017). At the core of SLQ is the Lanczos method, which computes $m$ eigenvalues of $H$ by first constructing a symmetric tridiagonal matrix $T \in \mathbb { R } ^ { m \times m }$ and computing the eigenvalues of $T$ . The Lanczos procedure only requires Hessian-vector products, and it can be combined with a stochastic trace estimator to provide a stochastic estimate of our log probability. We chose SLQ because it has shown theoretically and empirically to have low variance (Ubaru et al., 2017).
77
+
78
+ # 3.2 $\mathcal { O } ( 1 )$ -MEMORY UNBIASED $\nabla \log \operatorname* { d e t } H$ ESTIMATOR
79
+
80
+ We would also like to have an estimator for the gradient of the log determinant to enable variants of stochastic gradient descent for optimization. Unfortunately, directly backpropagating through the log determinant estimator is not ideal. Two major drawbacks of directly differentiating through SLQ are that it requires (i) differentiating through an eigendecomposition routine and (ii) storing all Hessian-vector products in memory (see fig. 2). Problem (i) is more specific to SLQ, because the gradient of an eigendecomposition is not defined when the eigenvalues are not unique (Seeger et al., 2017). Consequently, we have empirically observed that differentiating through SLQ can be unstable, frequently resulting in NaNs due to the eigendecomposition. Problem (ii) will hold true for other algorithms that also estimate $\log \operatorname* { d e t } H$ with Hessian-vector products, and generally the only difference is that a different numerical routine would need to be differentiated through. Due to these problems, we do not differentiate through SLQ, but we still use it as an efficient method for monitoring training progress.
81
+
82
+ ![](images/0811c3799e43dfda077761083b792341e7ec861165822040a8e9163617769b54.jpg)
83
+ Figure 2: Memory for training CIFAR-10.
84
+
85
+ Instead, it is possible to construct an alternative formulation of the gradient as the solution of a convex optimization problem, foregoing the necessity of differentiating through an estimation routine of the log determinant. We adapt the gradient formula from Chen et al. (2019a, Appendix C) to the context of convex potentials. Using Jacobi’s formula⇤ and the adjugate representation of the matrix inverse†, for any invertible matrix $H$ with parameter $\theta$ , we have the following identity:
86
+
87
+ $$
88
+ \begin{array} { r } { \frac { \partial } { \partial \theta } \log \operatorname* { d e t } H = \frac { 1 } { \operatorname* { d e t } H } \frac { \partial } { \partial \theta } \operatorname* { d e t } H \stackrel { \ast } { = } - \frac { 1 } { \operatorname* { d e t } } \bigl ( \qquad \frac { \partial H } { \partial \theta } \bigr ) \stackrel { \dagger } { = } \operatorname { t r } \bigl ( \frac { \partial H } { \partial \theta } \bigr ) = \mathbb { E } _ { v } \left[ v ^ { \top } H ^ { - 1 } \frac { \partial H } { \partial \theta } v \right] . } \end{array}
89
+ $$
90
+
91
+ Notably, in the last equality, we used the Hutchinson trace estimator (Hutchinson, 1989) with a Rademacher random vector $v$ , leading to a $\mathcal { O } ( 1 )$ -memory, unbiased Monte Carlo gradient estimator.
92
+
93
+ Computing the quantity $v ^ { \top } H ^ { - 1 }$ in eq. (3) by constructing and inverting the full Hessian requires $d$ calls to an automatic differentiation routine and is too costly for our purposes. However, we can recast this quantity as the solution of a quadratic optimization problem
94
+
95
+ $$
96
+ \arg \operatorname* { m i n } _ { z } \left\{ { \frac { 1 } { 2 } } z ^ { \top } H z - v ^ { \top } z \right\}
97
+ $$
98
+
99
+ which has the unique minimizer $z ^ { * } = H ^ { - 1 } v$ since $H$ is symmetric positive definite.
100
+
101
+ We use the conjugate gradient (CG) method, which is specifically designed for solving the unconstrained optimization problems in eq. (4) with symmetric positive definite $H$ . It uses only Hessian-vector products and is straightforward to parallelize. Conjugate gradient is guaranteed to return the exact solution $z ^ { * }$ within $d$ iterations, and the error of the approximation is known to converge exponentially fast $| | z ^ { m } - z ^ { * } | | _ { H } ~ \leq$ $2 \gamma ^ { m } | | z ^ { 0 } - z ^ { * } | | _ { H } ^ { * }$ , where $z ^ { m }$ is the estimate after
102
+
103
+ <table><tr><td>Algorithm 2 Surrogate training objective.</td></tr><tr><td>1: procedure SURROGATEOBJ(F,x,CG)</td></tr><tr><td>2: Obtain the gradient f(x) = VxF(x)</td></tr><tr><td>3: Sample Rademacher random vector r</td></tr><tr><td>4: def hvp(v): 5: return ν</td></tr><tr><td>6: z ← stop-gradient (CG(hvp,r))</td></tr><tr><td>return hvp(z)Tr</td></tr><tr><td>7:</td></tr></table>
104
+
105
+ $m$ iterations. The rate of convergence $\gamma < 1$ relates to the condition number of $H$ . For more details, see Nocedal & Wright (2006, Ch. 5). In practice, we terminate CG when $| | H z ^ { m } - v | | _ { \infty } < \tau$ is satisfied for some user-controlled tolerance. Empirically, we find that stringent tolerance values are unnecessary for stochastic optimization (see appendix F).
106
+
107
+ Estimating the full quantity in eq. (3) is then simply a matter of computing and differentiating a scalar quantity (a surrogate objective) involving another Hessian-vector product: $\begin{array} { r } { \frac { d } { d \theta } \left( \left( z ^ { m } \right) ^ { \top } H \mathbf { \bar { v } } \right) } \end{array}$ , where only $H$ is differentiated through (since $z ^ { m }$ is only used to approximate $v ^ { \top } H ^ { - 1 }$ as a modifier of the gradient). We summarize this procedure in Algorithm 2. Similar to inversion, the hvp can also be computed in batch by summing over the data index, since all entries are independent.
108
+
109
+ # 3.3 CONNECTION TO OTHER NORMALIZING FLOWS
110
+
111
+ Residual Flow For $\alpha = 1$ , the gradient map $f _ { 1 }$ resembles the residual flow (Behrmann et al., 2019; Chen et al., 2019a). They require the residual block—equivalent to our gradient map $f$ —to be contractive (with Lipschitz constant strictly smaller than 1) as a sufficient condition for invertibility. In contrast, we enforce invertibility by using strongly convex potentials, which guarantees that the inverse of our flow is globally unique. With this, we do not pay the extra compute cost for having to satisfy Lipschitz constraints using methods such as spectral normalization (Miyato et al., 2018). Our gradient estimator is also derived similarly to that of Chen et al. (2019a), though we have the benefit of using well-studied convex optimization algorithms for computing the gradients.
112
+
113
+ Sylvester Flow By restricting the architecture of our ICNN to one hidden layer, we can also recover a form similar to Sylvester Flows. For a 1-hidden layer ICNN $K = 1$ ) and $\alpha = 1$ , we have $\begin{array} { r } { F _ { 1 } = \frac 1 2 | | \boldsymbol { x } | | _ { 2 } ^ { 2 } + L _ { 2 } ^ { + } ( s ( L _ { 1 } \dot { \boldsymbol { x } } ) ) + L _ { 2 } ( \boldsymbol { x } ) } \end{array}$ . Setting the weights of $L _ { 2 }$ to zero, we have
114
+
115
+ $$
116
+ f _ { 1 } ( x ) = \nabla _ { x } F _ { 1 } ( x ) = x + W _ { 1 } ^ { \top } \mathtt { d i a g } ( w _ { 2 } ^ { + } ) s ^ { \prime } ( W _ { 1 } x + b _ { 1 } ) .
117
+ $$
118
+
119
+ We notice the above form bears a close resemblance to the Sylvester normalizing flow (Van Den Berg et al., 2018) (with $Q$ , $\pmb { R }$ and $\widetilde { R }$ from Van Den Berg et al. (2018) being equal to $W _ { 1 } ^ { \top }$ , $\mathrm { d i a g ( } w _ { 2 } ^ { + } \mathrm { ) }$ and $I$ , respectively). For the Sylvester flow to be invertible, they require that $\pmb { R }$ and $\widetilde { R }$ be triangular and $Q$ be orthogonal, which is a computationally costly procedure. This orthogonality constraint also implies that the number of hidden units cannot exceed $d$ . This restriction to orthogonal matrices and one hidden layer are for applying Sylvester’s determinant identity. In contrast, we do not require our weight matrices to be orthogonal, and we can use any hidden width and depth for the ICNN.
120
+
121
+ Sigmoidal Flow Let $s$ be the softplus activation function and $\sigma = s ^ { \prime }$ . Then for the 1-dimensional case $d = 1$ ) and $\alpha = 0$ (without the residual connection), we have
122
+
123
+ $$
124
+ \frac { \partial } { \partial x } F _ { 0 } ( x ) = \sum _ { j = 1 } w _ { 1 , j } w _ { 2 , j } ^ { + } \sigma ( w _ { 1 , j } x + b _ { 1 , j } ) = \sum _ { j = 1 } | w _ { 1 , j } | w _ { 2 , j } ^ { + } \sigma ( | w _ { 1 , j } | x + \mathrm { s i g n } ( w _ { 1 , j } ) b _ { 1 , j } ) + \mathrm { c o n s t } .
125
+ $$
126
+
127
+ which is equivalent to the sigmoidal flow of Huang et al. (2018) up to rescaling (since the weighted sum is no longer a convex sum) and a constant shift, and is monotone due to the positive weights. This correspondence is not surprising since a differentiable function is convex if and only if its derivative is monotonically non-decreasing. It also means we can parameterize an increasing function as the derivative of a convex function, which opens up a new direction for parameterizing autoregressive normalizing flows (Kingma et al., 2016; Huang et al., 2018; Muller et al. ¨ , 2019; Jaini et al., 2019; Durkan et al., 2019; Wehenkel & Louppe, 2019).
128
+
129
+ Flows with Potential Parameterization Inspired by connections between optimal transport and continuous normalizing flows, some works (Zhang et al., 2018; Finlay et al., 2020a; Onken et al., 2020) have proposed to parameterize continuous-time transformations by taking the gradient of a scalar potential. They do not strictly require the potential to be convex since it is guaranteed to be invertible in the infinitesimal setting of continuous normalizing flows (Chen et al., 2018). There exist works (Yang & Karniadakis, 2019; Finlay et al., 2020b; Onken et al., 2020) that have applied the theory of optimal transport to regularize continuous-time flows to have low transport cost. In contrast, we connect optimal transport with discrete-time normalizing flows, and CP-Flow is guaranteed by construction to converge pointwise to the optimal mapping between distributions without explicit regularization (see Section 4).
130
+
131
+ # 4 THEORETICAL ANALYSES
132
+
133
+ As explained in Section 2, the parameterization of CP-Flow is inspired by the Brenier potential. So naturally we would hope to show that (1) CP-Flows are distributionally universal, and that (2) the learned invertible map is optimal in the sense of the average squared distance the input travels $\mathbb { E } [ | | x - f ( x ) | | ^ { 2 } ]$ . Proofs of statements made in this section can be found in Appendices C and D.
134
+
135
+ To show (1), our first step is to show that ICNNs can approximate arbitrary convex functions. However, convergence of potential functions does not generally imply convergence of the gradient fields. A classic example is the sequence $F _ { n } = \sin ( \bar { n } x ) / \sqrt { n }$ and the corresponding derivatives $f _ { n } = \cos ( n x ) { \sqrt { n } }$ : $F _ { n } \to 0$ as $n \to \infty$ but $f _ { n }$ does not. Fortunately, convexity allows us to control the variation of the gradient map (since the derivative of a convex function is monotone), so our second step of approximation holds.
136
+
137
+ Theorem 2. Let $F _ { n } : \mathbb { R } ^ { d } \mathbb { R }$ be differentiable convex functions and $G : \mathbb { R } ^ { d } \mathbb { R }$ be a proper convex function. Assume $F _ { n } \to G$ . Then for almost every $\mathbf { \bar { \Phi } } _ { x \in \mathbb { R } ^ { d } }$ , $G$ is differentiable and $f _ { n } ( x ) : =$ $\nabla F _ { n } ( \boldsymbol { \dot { x } } ) \nabla G ( \boldsymbol { x } ) = : g ( \boldsymbol { x } )$ .
138
+
139
+ Combining these two steps and Brenier’s theorem, we show that CP-Flow with softplus-type activation function is distributionally universal.
140
+
141
+ Theorem 3 (Universality). Given random variables $X \sim \mu$ and $Y \sim \nu$ , with $\mu$ being absolutely continuous w.r.t. the Lebesgue measure, there exists a sequence of ICNN $F _ { n }$ with a softplus-type activation, such that $\nabla F _ { n } \circ X Y$ in distribution.
142
+
143
+ N.B. In the theorem we do not require the second moment to be finite, as for arbitrary random variables we can apply the standard truncation technique and redistribute the probability mass so that the new random variables are almost surely bounded. For probability measures with finite second moments, we indeed use the gradient map of ICNN to approximate the optimal transport map corresponding to the Brenier potential. In the following theorem, we show that the optimal transport map is the only such mapping that we can approximate if we match the distributions.
144
+
145
+ Theorem 4 (Optimality). Let $G$ be the Brenier potential of $X \sim \mu$ and $Y \sim \nu$ , and let $F _ { n }$ be $a$ convergent sequence of differentiable, convex potentials, such that $\nabla F _ { n } \circ X Y$ in distribution. Then $\nabla F _ { n }$ converges almost surely to rG.
146
+
147
+ The theorem states that in practice, even if we optimize according to some loss that traces the convergence in distribution, our model is still able to recover the optimal transport map, as if we were optimizing according to the transport cost. This allows us to estimate optimal transport maps without solving the constrained optimization in (2). See Seguy et al. (2018) for some potential applications of the optimal transport map, such as domain adaptation or domain translation.
148
+
149
+ # 5 EXPERIMENT
150
+
151
+ We use CP-Flow to perform density estimation (RHS of (1)) and variational inference (LHS of (1)) to assess its approximation capability, and the effectiveness of the proposed gradient estimator. All the details of experiments can be found in Appendix E. Code is available at https://github.com/CWHuang/CP-Flow.
152
+
153
+ ![](images/33a437e328e3e761c9d8cd9c08bc654600d07ba8d88130ed54777e822f8f0ea3.jpg)
154
+ Figure 4: Approximating optimal transport map via maximum likelihood (minimizing KL divergence). In the first figure on the left we show the data in 2 dimensions. The datapoints are colored according to their horizontal values $( x _ { 1 } )$ . The flows $f _ { i a f }$ and $f _ { c p }$ are trained to transform the data into a standard Gaussian prior. In the figures on the right, we plot the expected quadratic transportation cost versus the KL divergence for different numbers of dimensionality. During training the KL is minimized, so the curves read from the right to the left.
155
+
156
+ ICNN Architecture Despite the universal property, having a poor parameterization can lead to difficulties in optimization and limit the effective expressivity of the model. We propose an architectural enhancement of ICNN, defined as follows (note the change in notation: instead of writing the pre-activations $z$ , we use $h$ to denote the activated units):
157
+
158
+ $$
159
+ \begin{array} { c c } { { F ^ { a u g } ( x ) : = L _ { K + 1 } ^ { + } ( h _ { K } ) + L _ { K + 1 } ( x ) } } & { { } } \\ { { h _ { k } : = \mathrm { c o n c a t } ( [ \widetilde { h } _ { k } , h _ { k } ^ { a u g } ] ) \qquad \widetilde { h } _ { k } : = s ( L _ { k } ^ { + } ( h _ { k - 1 } ) + L _ { k } ( x ) ) \qquad h _ { k } ^ { a u g } = s ( L _ { k } ^ { a u g } ( x ) ) } } & { { } } \end{array}
160
+ $$
161
+
162
+ where half of the hidden units are directly connected to the input, so the gradient would have some form of skip connection. We call this the input-augmented ICNN. Unless otherwise stated, we use the input-augmented ICNN as the default architecture.
163
+
164
+ # 5.1 TOY EXAMPLES
165
+
166
+ Having distributional universality for a single flow layer means that we can achieve high expressiveness without composing too many flows. We demonstrate this by fitting the density on some toy examples taken from Papamakarios et al. (2017) and Behrmann et al. (2019). We compare with the masked autoregressive flow (MAF, Papamakarios et al. (2017)) and the neural autoregressive flow (NAF, (Huang et al., 2018)). Results are presented in fig. 3. We try to match the network size for each data. All models fit the first data well. As affine couplings cannot split probability mass, MAF fails to fit to the second and third datasets2. Although the last dataset is intrinsi
167
+
168
+ ![](images/15a901b8d2626cb3b44ce09247c743b8ed5ae593bc8c32f679ac776b76bf79b3.jpg)
169
+ Figure 3: Learning toy densities.
170
+
171
+ cally harder to fit (as NAF, another universal density model, also fails to fit it well), the proposed method still manages to learn the correct density with high fidelity.
172
+
173
+ # 5.2 APPROXIMATING OPTIMAL COUPLING
174
+
175
+ As predicted by Theorem 4, CP-Flow is guaranteed to converge to the optimal coupling minimizing the expected quadratic cost. We empirically verify it by learning the Gaussian density and comparing the expected quadratic distance between the input and output of the flow against $J _ { | | x - y | | ^ { 2 } }$ between the Gaussian data and the standard Gaussian prior (as there is a closed-form expression). In fig. 4, we see that the transport cost gets closer to the optimal value when the learned density approaches the data distribution (measured by the KL divergence). We compare against the linear inverse autoregressive flow (Kingma et al., 2016), which has the capacity to represent the multivariate Gaussian density, yet it does not learn the optimal coupling.
176
+
177
+ Table 1: Average test negative log-likelihood (in nats) of tabular datasets in Papamakarios et al. (2017) for density estimation models (lower is better). Standard deviation is presented in the appendix E.4.
178
+
179
+ <table><tr><td>Model</td><td>POWER</td><td>GAS</td><td>HEPMASS</td><td>MINIBOONE</td><td>BSDS300</td></tr><tr><td>Real NVP (Dinh et al., 2017)</td><td>-0.17</td><td>-8.33</td><td>18.71</td><td>13.55</td><td>-153.28</td></tr><tr><td>FFJORD (Grathwohl et al., 2018)</td><td>-0.46</td><td>-8.59</td><td>14.92</td><td>10.43</td><td>-157.40</td></tr><tr><td>MADE (Germain et al., 2015)</td><td>3.08</td><td>-3.56</td><td>20.98</td><td>15.59</td><td>-148.85</td></tr><tr><td>MAF (Papamakarios et al., 2017)</td><td>-0.24</td><td>-10.08</td><td>17.70</td><td>11.75</td><td>-155.69</td></tr><tr><td>TAN (Oliva et al., 2018)</td><td>-0.48</td><td>-11.19</td><td>15.12</td><td>11.01</td><td>-157.03</td></tr><tr><td>NAF (Huang et al., 2018)</td><td>-0.62</td><td>-11.96</td><td>15.09</td><td>8.86</td><td>-157.73</td></tr><tr><td>CP-Flow (Ours)</td><td>-0.52</td><td>-10.36</td><td>16.93</td><td>10.58</td><td>-154.99</td></tr></table>
180
+
181
+ Table 2: Negative log-likelihood (in bits) on held-out test data (lower is better). †Taken from Durkan et al. (2019). ‡Obtained from official open source code.
182
+
183
+ <table><tr><td rowspan="2">Model</td><td colspan="2">MNIST</td><td colspan="2">CIFAR-10</td></tr><tr><td>Bits/dim</td><td>N. params</td><td>Bits/dim</td><td> N. params</td></tr><tr><td>Real NVP (Dinh et al., 2017)</td><td>1.05</td><td>N/A</td><td>3.49</td><td>N/A</td></tr><tr><td>Glow (Kingma &amp; Dhariwal, 2018)</td><td>1.06</td><td>N/A</td><td>3.35</td><td>44.0Mt</td></tr><tr><td>RQ-NSF (Durkan et al., 2019)</td><td>一</td><td>一</td><td>3.38</td><td>11.8M+</td></tr><tr><td>Residual Flow (Chen et al., 2019a)</td><td>0.97</td><td>16.6M‡</td><td>3.28</td><td>25.2M</td></tr><tr><td>Coupling Block Ablation</td><td>1.02</td><td>3.1M</td><td>3.58</td><td>2.9M</td></tr><tr><td>Residual Block Ablation</td><td>1.04</td><td>2.9M</td><td>3.46</td><td>3.1M</td></tr><tr><td>CP-Flow (Ours)</td><td>1.02</td><td>2.9M</td><td>3.40</td><td>1.9M</td></tr></table>
184
+
185
+ # 5.3 DENSITY ESTIMATION
186
+
187
+ We demonstrate the efficacy of our model and the proposed gradient estimator by performing density estimation on the standard benchmarks.
188
+
189
+ Tabular Data We use the datasets preprocessed by Papamakarios et al. (2017). In table 1, we report average negative log-likelihood estimates evaluated on held-out test sets, for the best hyperparameters found via grid search. The search was focused on the number of flow blocks, the width and depth of the ICNN potentials. See appendix E.4 for details. Our models perform competitively against alternative approaches in the literature. We also perform an ablation on the CG error tolerance and ICNN architectures in appendix F.
190
+
191
+ Image Data Next, we apply CP-Flow to model the density of standard image datasets, MNIST and CIFAR-10. For this, we use convolutional layers in place of fully connected layers. Prior works have had to use large architectures, with many flow blocks composed together, resulting in a large number of parameters to optimize. While we also compose multiple blocks of CP-Flows, we find that CP-Flow can perform relatively well with fewer number of parameters (table 2). Notably, we achieve comparable bits per dimension to Neural Spline Flows (Durkan et al., 2019)—another work promoting fewer parameters—while having using around $16 \%$ number of parameters.
192
+
193
+ As prior works use different architectures with widely varying hyperparameters, we perform a more careful ablation study using coupling (Dinh et al., 2014; 2017) and invertible residual blocks (Chen et al., 2019a). We replace each of our flow blocks with the corresponding baseline. We find that on CIFAR-10, the baseline flow models do not perform nearly as well as CP-Flow. We believe this may be because CP-Flows are universal with just one flow block, whereas coupling and invertible residual blocks are limited in expressivity or Lipschitz-constrained.
194
+
195
+ # 5.4 AMORTIZING ICNN FOR VARIATIONAL INFERENCE
196
+
197
+ Normalizing flows also allow us to employ a larger, more flexible family of distributions for variational inference (Rezende & Mohamed, 2015). We replicate the experiment conducted in Van Den Berg et al. (2018) to enhance the variational autoencoder (Kingma & Welling, 2013). For inference amortization, we use the partially input convex neural network from Amos et al. (2017), and use the output of the encoder as the additional input for conditioning. As table 3 shows, the performance of CPFlow is close to the best reported in Van Den Berg et al. (2018) without changing the experiment setup. This shows that the convex potential parameterization along with the proposed gradient estimator can learn to perform accurate amortized inference. Also, we show that replacing the vanilla ICNN with the input-augmented ICNN leads to improvement of the likelihood estimates.
198
+
199
+ <table><tr><td></td><td>FREYFACES OMNIGLOT</td><td>CALTECH</td></tr><tr><td>Gaussian</td><td>4.53</td><td>104.28 110.80</td></tr><tr><td>Planar</td><td>4.40</td><td>102.65 109.66</td></tr><tr><td>IAF</td><td>4.47</td><td>102.41 111.58</td></tr><tr><td>Sylvester</td><td>4.45</td><td>99.00 104.62</td></tr><tr><td>CP-Flow (vanilla)</td><td>4.47</td><td>102.06 106.53</td></tr><tr><td>CP-Flow (aug)</td><td>4.45</td><td>100.82 105.17</td></tr></table>
200
+
201
+ Table 3: Negative ELBO of VAE (lower is better). Standard deviation reported in appendix E.6.
202
+
203
+ # 6 CONCLUSION
204
+
205
+ We propose a new parameterization of normalizing flows using the gradient map of a convex potential. We make connections to the optimal transport theory to show that the proposed flow is a universal density model, and leverage tools from convex optimization to enable efficient training and model inversion. Experimentally, we show that the proposed method works reasonably well when evaluated on standard benchmarks.
206
+
207
+ Furthermore, we demonstrate that the performance can be improved by designing better ICNN architectures. We leave the exploration for a better ICNN and convolutional ICNN architecture to improve density estimation and generative modeling for future research.
208
+
209
+ # ACKNOWLEDGEMENTS
210
+
211
+ We would like to acknowledge the Python community (Van Rossum & Drake Jr, 1995; Oliphant, 2007) for developing the tools that enabled this work, including numpy (Oliphant, 2006; Van Der Walt et al., 2011; Walt et al., 2011; Harris et al., 2020), PyTorch (Paszke et al., 2019), Matplotlib (Hunter, 2007), seaborn (Waskom et al., 2018), pandas (McKinney, 2012), and SciPy (Jones et al., 2014).
212
+
213
+ # REFERENCES
214
+
215
+ Ryan P Adams, Jeffrey Pennington, Matthew J Johnson, Jamie Smith, Yaniv Ovadia, Brian Patton, and James Saunderson. Estimating the spectral density of large implicit matrices. arXiv preprint arXiv:1802.03451, 2018.
216
+ Brandon Amos, Lei Xu, and J Zico Kolter. Input convex neural networks. In International Conference on Machine Learning, pp. 146–155, 2017.
217
+ Atılım Gunes Baydin, Barak A Pearlmutter, Alexey Andreyevich Radul, and Jeffrey Mark Siskind. ¨ Automatic differentiation in machine learning: a survey. The Journal of Machine Learning Research, 18(1):5595–5637, 2017.
218
+ Jens Behrmann, Will Grathwohl, Ricky T. Q. Chen, David Duvenaud, and Jorn-Henrik Jacobsen. ¨ Invertible residual networks. In International Conference on Machine Learning, pp. 573–582, 2019.
219
+ Jens Behrmann, Paul Vicol, Kuan-Chieh Wang, Roger Grosse, and Jorn-Henrik Jacobsen. Un- ¨ derstanding and mitigating exploding inverses in invertible neural networks. arXiv preprint arXiv:2006.09347, 2020.
220
+
221
+ Yann Brenier. Decomposition polaire et r ´ earrangement monotone des champs de vecteurs. ´ CR Acad. Sci. Paris Ser. I Math. ´ , 305:805–808, 1987.
222
+
223
+ Yann Brenier. Polar factorization and monotone rearrangement of vector-valued functions. Communications on pure and applied mathematics, 44(4):375–417, 1991.
224
+
225
+ Richard H Byrd, Peihuang Lu, Jorge Nocedal, and Ciyou Zhu. A limited memory algorithm for bound constrained optimization. SIAM Journal on scientific computing, 16(5):1190–1208, 1995.
226
+
227
+ Ricky T. Q. Chen, Yulia Rubanova, Jesse Bettencourt, and David K Duvenaud. Neural ordinary differential equations. In Advances in neural information processing systems, pp. 6571–6583, 2018.
228
+
229
+ Ricky T. Q. Chen, Jens Behrmann, David K Duvenaud, and Jorn-Henrik Jacobsen. Residual flows ¨ for invertible generative modeling. In Advances in Neural Information Processing Systems, pp. 9916–9926, 2019a.
230
+
231
+ Yize Chen, Yuanyuan Shi, and Baosen Zhang. Optimal control via neural networks: A convex approach. In International Conference on Learning Representations, 2019b.
232
+
233
+ Mircea Cimpoi, Subhransu Maji, Iasonas Kokkinos, Sammy Mohamed, and Andrea Vedaldi. Describing textures in the wild. In Conference on Computer Vision and Pattern Recognition, 2014.
234
+
235
+ Taco Cohen and Max Welling. Group equivariant convolutional networks. In International conference on machine learning, pp. 2990–2999, 2016.
236
+
237
+ George Cybenko. Approximation by superpositions of a sigmoidal function. Mathematics of control, signals and systems, 2(4):303–314, 1989.
238
+
239
+ Laurent Dinh, David Krueger, and Yoshua Bengio. Nice: Non-linear independent components estimation. arXiv preprint arXiv:1410.8516, 2014.
240
+
241
+ Laurent Dinh, Jascha Sohl-Dickstein, and Samy Bengio. Density estimation using real nvp. In International Conference on Learning Representations, 2017.
242
+
243
+ Vincent Dumoulin, Ethan Perez, Nathan Schucher, Florian Strub, Harm de Vries, Aaron Courville, and Yoshua Bengio. Feature-wise transformations. Distill, 3(7):e11, 2018.
244
+
245
+ Conor Durkan, Artur Bekasov, Iain Murray, and George Papamakarios. Neural spline flows. In Advances in Neural Information Processing Systems, pp. 7511–7522, 2019.
246
+
247
+ Chris Finlay, Augusto Gerolin, Adam M Oberman, and Aram-Alexandre Pooladian. Learning normalizing flows from entropy-kantorovich potentials. arXiv preprint arXiv:2006.06033, 2020a.
248
+
249
+ Chris Finlay, Jorn-Henrik Jacobsen, Levon Nurbekyan, and Adam M Oberman. How to train your ¨ neural ode: the world of jacobian and kinetic regularization. In International Conference on Machine Learning, 2020b.
250
+
251
+ Mathieu Germain, Karol Gregor, Iain Murray, and Hugo Larochelle. Made: Masked autoencoder for distribution estimation. In Proceedings of the 32nd International Conference on Machine Learning, volume 37 of Proceedings of Machine Learning Research, pp. 881–889. PMLR, 07–09 Jul 2015.
252
+
253
+ Ian Goodfellow, David Warde-Farley, Mehdi Mirza, Aaron Courville, and Yoshua Bengio. Maxout networks. In International conference on machine learning, pp. 1319–1327. PMLR, 2013.
254
+
255
+ Will Grathwohl, Ricky T. Q. Chen, Jesse Bettencourt, Ilya Sutskever, and David Duvenaud. Ffjord: Free-form continuous dynamics for scalable reversible generative models. In International Conference on Learning Representations, 2018.
256
+
257
+ David Ha, Andrew Dai, and Quoc V Le. Hypernetworks. arXiv preprint arXiv:1609.09106, 2016.
258
+
259
+ Insu Han, Haim Avron, and Jinwoo Shin. Stochastic chebyshev gradient descent for spectral optimization. In Advances in Neural Information Processing Systems, pp. 7386–7396, 2018.
260
+
261
+ Charles R Harris, K Jarrod Millman, Stefan J van der Walt, Ralf Gommers, Pauli Virtanen, David´ Cournapeau, Eric Wieser, Julian Taylor, Sebastian Berg, Nathaniel J Smith, et al. Array programming with numpy. Nature, 585(7825):357–362, 2020.
262
+
263
+ Chin-Wei Huang, David Krueger, Alexandre Lacoste, and Aaron Courville. Neural autoregressive flows. In International Conference on Machine Learning, pp. 2078–2087, 2018.
264
+
265
+ Chin-Wei Huang, Laurent Dinh, and Aaron Courville. Augmented normalizing flows: Bridging the gap between generative flows and latent variable models. arXiv preprint arXiv:2002.07101, 2020a.
266
+
267
+ Chin-Wei Huang, Laurent Dinh, and Aaron Courville. Solving ode with universal flows: Approximation theory for flow-based models. In ICLR 2020 Workshop on Integration of Deep Neural Models and Differential Equations, 2020b.
268
+
269
+ Gao Huang, Zhuang Liu, Laurens Van Der Maaten, and Kilian Q Weinberger. Densely connected convolutional networks. In Proceedings of the IEEE conference on computer vision and pattern recognition, pp. 4700–4708, 2017.
270
+
271
+ John D Hunter. Matplotlib: A 2d graphics environment. Computing in science & engineering, 9(3): 90, 2007.
272
+
273
+ Michael F Hutchinson. A stochastic estimator of the trace of the influence matrix for laplacian smoothing splines. Communications in Statistics-Simulation and Computation, 18(3):1059–1076, 1989.
274
+
275
+ Priyank Jaini, Kira A Selby, and Yaoliang Yu. Sum-of-squares polynomial flow. In International Conference on Machine Learning, pp. 3009–3018, 2019.
276
+
277
+ Eric Jones, Travis Oliphant, and Pearu Peterson. {SciPy}: Open source scientific tools for $\{ { \mathrm { P y t h o n } } \}$ . 2014.
278
+
279
+ Diederik P Kingma and Max Welling. Auto-encoding variational bayes. arXiv preprint arXiv:1312.6114, 2013.
280
+
281
+ Durk P Kingma and Prafulla Dhariwal. Glow: Generative flow with invertible 1x1 convolutions. In Advances in neural information processing systems, pp. 10215–10224, 2018.
282
+
283
+ Durk P Kingma, Tim Salimans, Rafal Jozefowicz, Xi Chen, Ilya Sutskever, and Max Welling. Improved variational inference with inverse autoregressive flow. In Advances in neural information processing systems, pp. 4743–4751, 2016.
284
+
285
+ Zhifeng Kong and Kamalika Chaudhuri. The expressive power of a class of normalizing flow models. arXiv preprint arXiv:2006.00392, 2020.
286
+
287
+ Alexander Korotin, Vage Egiazarian, Arip Asadulaev, Alexander Safin, and Evgeny Burnaev. Wasserstein-2 generative networks. arXiv preprint arXiv:1909.13082, 2019.
288
+
289
+ Hongzhou Lin and Stefanie Jegelka. Resnet with one-neuron hidden layers is a universal approximator. In Advances in neural information processing systems, pp. 6169–6178, 2018.
290
+
291
+ Lin Lin, Yousef Saad, and Chao Yang. Approximating spectral densities of large matrices. SIAM review, 58(1):34–65, 2016.
292
+
293
+ Zhou Lu, Hongming Pu, Feicheng Wang, Zhiqiang Hu, and Liwei Wang. The expressive power of neural networks: A view from the width. In Advances in neural information processing systems, pp. 6231–6239, 2017.
294
+
295
+ Ashok Vardhan Makkuva, Amirhossein Taghvaei, Sewoong Oh, and Jason D Lee. Optimal transport mapping via input convex neural networks. arXiv preprint arXiv:1908.10962, 2019.
296
+
297
+ Wes McKinney. Python for data analysis: Data wrangling with Pandas, NumPy, and IPython. O’Reilly Media, Inc.”, 2012.
298
+
299
+ Takeru Miyato, Toshiki Kataoka, Masanori Koyama, and Yuichi Yoshida. Spectral normalization for generative adversarial networks. arXiv preprint arXiv:1802.05957, 2018.
300
+
301
+ Thomas Muller, Brian McWilliams, Fabrice Rousselle, Markus Gross, and Jan Nov ¨ ak. Neural im- ´ portance sampling. ACM Transactions on Graphics (TOG), 38(5):1–19, 2019.
302
+
303
+ Yurii Nesterov. Introductory lectures on convex programming volume i: Basic course. Lecture notes, 3(4):5, 1998.
304
+
305
+ Yuval Netzer, Tao Wang, Adam Coates, Alessandro Bissacco, Bo Wu, and Andrew Y Ng. Reading digits in natural images with unsupervised feature learning. 2011.
306
+
307
+ Jorge Nocedal and Stephen Wright. Numerical optimization. Springer Science & Business Media, 2006.
308
+
309
+ Travis E Oliphant. A guide to NumPy, volume 1. Trelgol Publishing USA, 2006.
310
+
311
+ Travis E Oliphant. Python for scientific computing. Computing in Science & Engineering, 9(3): 10–20, 2007.
312
+
313
+ Junier Oliva, Avinava Dubey, Manzil Zaheer, Barnabas Poczos, Ruslan Salakhutdinov, Eric Xing, and Jeff Schneider. Transformation autoregressive networks. In Proceedings of the 35th International Conference on Machine Learning, volume 80 of Proceedings of Machine Learning Research, pp. 3898–3907. PMLR, 10–15 Jul 2018.
314
+
315
+ Derek Onken, Samy Wu Fung, Xingjian Li, and Lars Ruthotto. Ot-flow: Fast and accurate continuous normalizing flows via optimal transport. arXiv preprint arXiv:2006.00104, 2020.
316
+
317
+ George Papamakarios, Theo Pavlakou, and Iain Murray. Masked autoregressive flow for density estimation. In Advances in Neural Information Processing Systems, pp. 2338–2347, 2017.
318
+
319
+ 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, highperformance deep learning library. In Advances in neural information processing systems, pp. 8026–8037, 2019.
320
+
321
+ Danilo Rezende and Shakir Mohamed. Variational inference with normalizing flows. In International Conference on Machine Learning, pp. 1530–1538, 2015.
322
+
323
+ R Tyrrell Rockafellar. Convex analysis. Number 28. Princeton university press, 1970.
324
+
325
+ Ludger Ruschendorf and Svetlozar T Rachev. A characterization of random variables with minimum ¨ l2-distance. Journal of multivariate analysis, 32(1):48–54, 1990.
326
+
327
+ Filippo Santambrogio. Optimal transport for applied mathematicians. Birkauser, NY ¨ , 55(58-63):94, 2015.
328
+
329
+ Matthias Seeger, Asmus Hetzel, Zhenwen Dai, Eric Meissner, and Neil D Lawrence. Autodifferentiating linear algebra. arXiv preprint arXiv:1710.08717, 2017.
330
+
331
+ Vivien Seguy, Bharath Bhushan Damodaran, Remi Flamary, Nicolas Courty, Antoine Rolet, and Mathieu Blondel. Large scale optimal transport and mapping estimation. In International Conference on Learning Representations, 2018.
332
+
333
+ RN Silver and H Roder. Densities of states of mega-dimensional hamiltonian matrices. ¨ International Journal of Modern Physics C, 5(04):735–753, 1994.
334
+
335
+ Amirhossein Taghvaei and Amin Jalali. 2-wasserstein approximation via restricted convex potentials with application to improved training for gans. arXiv preprint arXiv:1902.07197, 2019.
336
+
337
+ Hillel Tal-Ezer and Ronnie Kosloff. An accurate and efficient scheme for propagating the time dependent schrodinger equation. ¨ The Journal of chemical physics, 81(9):3967–3971, 1984.
338
+
339
+ Takeshi Teshima, Isao Ishikawa, Koichi Tojo, Kenta Oono, Masahiro Ikeda, and Masashi Sugiyama. Coupling-based invertible neural networks are universal diffeomorphism approximators. arXiv preprint arXiv:2006.11469, 2020.
340
+
341
+ Shashanka Ubaru, Jie Chen, and Yousef Saad. Fast estimation of tr(f(A)) via Stochastic Lanczos Quadrature. SIAM Journal on Matrix Analysis and Applications, 38(4):1075–1099, 2017.
342
+
343
+ Rianne Van Den Berg, Leonard Hasenclever, Jakub M Tomczak, and Max Welling. Sylvester normalizing flows for variational inference. In 34th Conference on Uncertainty in Artificial Intelligence 2018, UAI 2018, pp. 393–402. Association For Uncertainty in Artificial Intelligence (AUAI), 2018.
344
+
345
+ Stefan Van Der Walt, S Chris Colbert, and Gael Varoquaux. The numpy array: a structure for efficient numerical computation. Computing in Science & Engineering, 13(2):22, 2011.
346
+
347
+ Guido Van Rossum and Fred L Drake Jr. Python reference manual. Centrum voor Wiskunde en Informatica Amsterdam, 1995.
348
+
349
+ Cedric Villani. ´ Optimal transport: old and new, volume 338. Springer Science & Business Media, 2008.
350
+
351
+ Stefan van der Walt, S Chris Colbert, and Gael Varoquaux. The numpy array: a structure for efficient ´ numerical computation. Computing in science & engineering, 13(2):22–30, 2011.
352
+
353
+ Michael Waskom, Olga Botvinnik, Drew O’Kane, Paul Hobson, Joel Ostblom, Saulius Lukauskas, David C Gemperline, Tom Augspurger, Yaroslav Halchenko, John B. Cole, Jordi Warmenhoven, Julian de Ruiter, Cameron Pye, Stephan Hoyer, Jake Vanderplas, Santi Villalba, Gero Kunter, Eric Quintero, Pete Bachant, Marcel Martin, Kyle Meyer, Alistair Miles, Yoav Ram, Thomas Brunner, Tal Yarkoni, Mike Lee Williams, Constantine Evans, Clark Fitzgerald, Brian, and Adel Qalieh. mwaskom/seaborn: v0.9.0 (july 2018), July 2018. URL https://doi.org/10. 5281/zenodo.1313201.
354
+
355
+ Antoine Wehenkel and Gilles Louppe. Unconstrained monotonic neural networks. In Advances in Neural Information Processing Systems, pp. 1545–1555, 2019.
356
+
357
+ Liu Yang and George Em Karniadakis. Potential flow generator with $l _ { 2 }$ optimal transport regularity for generative models. arXiv preprint arXiv:1908.11462, 2019.
358
+
359
+ Manzil Zaheer, Satwik Kottur, Siamak Ravanbakhsh, Barnabas Poczos, Russ R Salakhutdinov, and Alexander J Smola. Deep sets. In Advances in neural information processing systems, pp. 3391– 3401, 2017.
360
+
361
+ Linfeng Zhang, Lei Wang, et al. Monge-ampere flow for generative modeling. \` arXiv preprint arXiv:1809.10188, 2018.
362
+
363
+ Bolei Zhou, Agata Lapedriza, Aditya Khosla, Aude Oliva, and Antonio Torralba. Places: A 10 million image database for scene recognition. IEEE Transactions on Pattern Analysis and Machine Intelligence, 2017.
parse/train/te7PVH1sPxJ/te7PVH1sPxJ_content_list.json ADDED
@@ -0,0 +1,1965 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [
2
+ {
3
+ "type": "text",
4
+ "text": "CONVEX POTENTIAL FLOWS: UNIVERSAL PROBABILITY DISTRIBUTIONS WITH OPTIMAL TRANSPORT AND CONVEX OPTIMIZATION ",
5
+ "text_level": 1,
6
+ "bbox": [
7
+ 174,
8
+ 98,
9
+ 803,
10
+ 171
11
+ ],
12
+ "page_idx": 0
13
+ },
14
+ {
15
+ "type": "text",
16
+ "text": "Chin-Wei Huang University of Montreal & Mila chin-wei.huang@umontreal.ca ",
17
+ "bbox": [
18
+ 184,
19
+ 195,
20
+ 449,
21
+ 237
22
+ ],
23
+ "page_idx": 0
24
+ },
25
+ {
26
+ "type": "text",
27
+ "text": "Ricky T. Q. Chen University of Toronto & Vector Institute rtqichen@cs.toronto.edu ",
28
+ "bbox": [
29
+ 514,
30
+ 195,
31
+ 779,
32
+ 237
33
+ ],
34
+ "page_idx": 0
35
+ },
36
+ {
37
+ "type": "text",
38
+ "text": "Aaron Courville ",
39
+ "text_level": 1,
40
+ "bbox": [
41
+ 517,
42
+ 260,
43
+ 630,
44
+ 272
45
+ ],
46
+ "page_idx": 0
47
+ },
48
+ {
49
+ "type": "text",
50
+ "text": "Christos Tsirigotis University of Montreal & Mila christos.tsirigotis@umontreal.ca ",
51
+ "bbox": [
52
+ 183,
53
+ 258,
54
+ 496,
55
+ 300
56
+ ],
57
+ "page_idx": 0
58
+ },
59
+ {
60
+ "type": "text",
61
+ "text": "University of Montreal, Mila & CIFAR Fellow aaron.courville@umontreal.ca ",
62
+ "bbox": [
63
+ 516,
64
+ 273,
65
+ 821,
66
+ 300
67
+ ],
68
+ "page_idx": 0
69
+ },
70
+ {
71
+ "type": "text",
72
+ "text": "ABSTRACT ",
73
+ "text_level": 1,
74
+ "bbox": [
75
+ 454,
76
+ 338,
77
+ 544,
78
+ 352
79
+ ],
80
+ "page_idx": 0
81
+ },
82
+ {
83
+ "type": "text",
84
+ "text": "Flow-based models are powerful tools for designing probabilistic models with tractable density. This paper introduces Convex Potential Flows (CP-Flow), a natural and efficient parameterization of invertible models inspired by the optimal transport (OT) theory. CP-Flows are the gradient map of a strongly convex neural potential function. The convexity implies invertibility and allows us to resort to convex optimization to solve the convex conjugate for efficient inversion. To enable maximum likelihood training, we derive a new gradient estimator of the log-determinant of the Jacobian, which involves solving an inverse-Hessian vector product using the conjugate gradient method. The gradient estimator has constantmemory cost, and can be made effectively unbiased by reducing the error tolerance level of the convex optimization routine. Theoretically, we prove that CP-Flows are universal density approximators and are optimal in the OT sense. Our empirical results show that CP-Flow performs competitively on standard benchmarks of density estimation and variational inference. ",
85
+ "bbox": [
86
+ 233,
87
+ 367,
88
+ 764,
89
+ 560
90
+ ],
91
+ "page_idx": 0
92
+ },
93
+ {
94
+ "type": "text",
95
+ "text": "1 INTRODUCTION ",
96
+ "text_level": 1,
97
+ "bbox": [
98
+ 176,
99
+ 587,
100
+ 334,
101
+ 602
102
+ ],
103
+ "page_idx": 0
104
+ },
105
+ {
106
+ "type": "text",
107
+ "text": "Normalizing flows (Dinh et al., 2014; Rezende & Mohamed, 2015) have recently gathered much interest within the machine learning community, ever since its recent breakthrough in modelling high dimensional image data (Dinh et al., 2017; Kingma & Dhariwal, 2018). They are characterized by an invertible mapping that can reshape the distribution of its input data into a simpler or more complex one. To enable efficient training, numerous tricks have been proposed to impose structural constraints on its parameterization, such that the density of the model can be tractably computed. ",
108
+ "bbox": [
109
+ 174,
110
+ 617,
111
+ 825,
112
+ 700
113
+ ],
114
+ "page_idx": 0
115
+ },
116
+ {
117
+ "type": "text",
118
+ "text": "We ask the following question: “what is the natural way to parameterize a normalizing flow?” To gain a bit more intuition, we start from the one-dimension case. If a function $f : \\mathbb { R } \\mathbb { R }$ is continuous, it is invertible (injective onto its image) if and only if it is strictly monotonic. This means that if we are only allowed to move the probability mass continuously without flipping the order of the particles, then we can only rearrange them by changing the distance in between. ",
119
+ "bbox": [
120
+ 174,
121
+ 708,
122
+ 823,
123
+ 777
124
+ ],
125
+ "page_idx": 0
126
+ },
127
+ {
128
+ "type": "text",
129
+ "text": "In this work, we seek to generalize the above intuition of monotone rearrangement in 1D. We do so by motivating the parameterization of normalizing flows from an optimal transport perspective, which allows us to define some notion of rearrangement cost (Villani, 2008). It turns out, if we want the output of a flow to follow some desired distribution, under mild regularity conditions, we can characterize the unique optimal mapping by a convex potential (Brenier, 1991). In light of this, we propose to parameterize normalizing flows by the gradient map of a (strongly) convex potential. Owing to this theoretical insight, the proposed method is provably universal and optimal; this means the proposed flow family can approximate arbitrary distributions and requires the least amount of transport cost. Furthermore, the parameterization with convex potentials allows us to formulate model inversion and gradient estimation as convex optimization problems. As such, we make use of existing tools from the convex optimization literature to cheaply and efficiently estimate all quantities of interest. ",
130
+ "bbox": [
131
+ 174,
132
+ 785,
133
+ 825,
134
+ 924
135
+ ],
136
+ "page_idx": 0
137
+ },
138
+ {
139
+ "type": "text",
140
+ "text": "",
141
+ "bbox": [
142
+ 173,
143
+ 103,
144
+ 823,
145
+ 132
146
+ ],
147
+ "page_idx": 1
148
+ },
149
+ {
150
+ "type": "text",
151
+ "text": "In terms of the benefits of parameterizing a flow as a gradient field, the convex potential is an $\\mathbb { R } ^ { d } \\to \\mathbb { R }$ function, which is different from most existing discrete-time flows which are $\\mathbb { R } ^ { d } \\to \\mathbb { R } ^ { d }$ . This makes CP-Flow relatively compact. It is also arguably easier to design a convex architecture, as we do not need to satisfy constraints such as orthogonality or Lipschitzness; the latter two usually require a direct or an iterative reparameterization of the parameters. Finally, it is possible to incorporate additional structure such as equivariance (Cohen & Welling, 2016; Zaheer et al., 2017) into the flow’s parameterization, making CP-Flow a more flexible general purpose density model. ",
152
+ "bbox": [
153
+ 174,
154
+ 138,
155
+ 825,
156
+ 237
157
+ ],
158
+ "page_idx": 1
159
+ },
160
+ {
161
+ "type": "text",
162
+ "text": "2 BACKGROUND: NORMALIZING FLOWS AND OPTIMAL TRANSPORT ",
163
+ "text_level": 1,
164
+ "bbox": [
165
+ 171,
166
+ 258,
167
+ 758,
168
+ 276
169
+ ],
170
+ "page_idx": 1
171
+ },
172
+ {
173
+ "type": "text",
174
+ "text": "Normalizing flows are characterized by a differentiable, invertible neural network $f$ such that the probability density of the network’s output can be computed conveniently using the change-ofvariable formula ",
175
+ "bbox": [
176
+ 174,
177
+ 291,
178
+ 823,
179
+ 334
180
+ ],
181
+ "page_idx": 1
182
+ },
183
+ {
184
+ "type": "equation",
185
+ "img_path": "images/b155802ebbc1bef6013a130931b9c0b765dfffdb4e466d10266c92a3f54df9ef.jpg",
186
+ "text": "$$\np _ { Y } ( f ( x ) ) = p _ { X } ( x ) \\left| { \\frac { \\partial f ( x ) } { \\partial x } } \\right| ^ { - 1 } \\qquad \\Longleftrightarrow \\qquad p _ { Y } ( y ) = p _ { X } ( f ^ { - 1 } ( y ) ) \\left| { \\frac { \\partial f ^ { - 1 } ( y ) } { \\partial y } } \\right|\n$$",
187
+ "text_format": "latex",
188
+ "bbox": [
189
+ 232,
190
+ 340,
191
+ 766,
192
+ 378
193
+ ],
194
+ "page_idx": 1
195
+ },
196
+ {
197
+ "type": "text",
198
+ "text": "where the Jacobian determinant term captures the local expansion or contraction of the density near $x$ (resp. $y$ ) induced by the mapping $f$ (resp. $f ^ { - 1 }$ ), and $p _ { X }$ is the density of a random variable $X$ . The invertibility requirement has led to the design of many special neural network parameterizations such as triangular maps, ordinary differential equations, orthogonality or Lipschitz constraints. ",
199
+ "bbox": [
200
+ 174,
201
+ 386,
202
+ 825,
203
+ 443
204
+ ],
205
+ "page_idx": 1
206
+ },
207
+ {
208
+ "type": "text",
209
+ "text": "Universal Flows For a general learning framework to be meaningful, a model needs to be flexible enough to capture variations in the data distribution. In the context of density modeling, this corresponds to the model’s capability to represent arbitrary probability distributions of interest. Even though there exists a long history of literature on universal approximation capability of deep neural networks (Cybenko, 1989; Lu et al., 2017; Lin & Jegelka, 2018), invertible neural networks generally have limited expressivity and cannot approximate arbitrary functions. However, for the purpose of approximating a probability distribution, it suffices to show that the distribution induced by a normalizing flow is universal. ",
210
+ "bbox": [
211
+ 173,
212
+ 458,
213
+ 825,
214
+ 571
215
+ ],
216
+ "page_idx": 1
217
+ },
218
+ {
219
+ "type": "text",
220
+ "text": "Among many ways to establish distributional universality of flow based methods (e.g. Huang et al. 2018; 2020b; Teshima et al. 2020; Kong & Chaudhuri 2020), one particular approach is to approximate a deterministic coupling between probability measures. Given a pair of probability densities $p _ { X }$ and $p _ { Y }$ , a deterministic coupling is a mapping $g$ such that $g ( X ) \\sim p _ { Y }$ if $X \\sim p _ { X }$ . We seek to find a coupling that is invertible, or at least can be approximated by invertible mappings. ",
221
+ "bbox": [
222
+ 173,
223
+ 577,
224
+ 825,
225
+ 648
226
+ ],
227
+ "page_idx": 1
228
+ },
229
+ {
230
+ "type": "text",
231
+ "text": "Optimal Transport Let $c ( x , y )$ be a cost function. The Monge problem (Villani, 2008) pertains to finding the optimal transport map $g$ that realizes the minimal expected cost ",
232
+ "bbox": [
233
+ 173,
234
+ 665,
235
+ 823,
236
+ 694
237
+ ],
238
+ "page_idx": 1
239
+ },
240
+ {
241
+ "type": "equation",
242
+ "img_path": "images/5854dfcda542f09af3f667456a04618a0ca296f2d10e8b9d1eeb7de4facfc36d.jpg",
243
+ "text": "$$\nJ _ { c } ( p _ { X } , p _ { Y } ) = \\operatorname* { i n f } _ { \\widetilde { g } : \\widetilde { g } ( X ) \\sim p _ { Y } } \\mathbb { E } _ { X \\sim p _ { X } } \\left[ c ( X , \\widetilde { g } ( X ) ) \\right]\n$$",
244
+ "text_format": "latex",
245
+ "bbox": [
246
+ 344,
247
+ 703,
248
+ 651,
249
+ 728
250
+ ],
251
+ "page_idx": 1
252
+ },
253
+ {
254
+ "type": "text",
255
+ "text": "When the second moments of $X$ and $Y$ are both finite, and $X$ is regular enough (e.g. having a density), then the special case of $c ( x , y ) \\ = \\ | | x - y | | ^ { 2 }$ has an interesting solution, a celebrated theorem due to Brenier (1987; 1991): ",
256
+ "bbox": [
257
+ 174,
258
+ 737,
259
+ 825,
260
+ 780
261
+ ],
262
+ "page_idx": 1
263
+ },
264
+ {
265
+ "type": "text",
266
+ "text": "Theorem 1 (Brenier’s Theorem, Theorem 1.22 of Santambrogio (2015)). Let $\\mu , \\nu$ be probability measures with a finite second moment, and assume $\\mu$ has a Lebesgue density $p _ { X }$ . Then there exists a convex potential $G$ such that the gradient map $g : = \\nabla G$ (defined up to a null set) uniquely solves the Monge problem in eq. (2) with the quadratic cost function $c ( x , y ) = | | x - y | | ^ { 2 }$ . ",
267
+ "bbox": [
268
+ 174,
269
+ 784,
270
+ 823,
271
+ 842
272
+ ],
273
+ "page_idx": 1
274
+ },
275
+ {
276
+ "type": "text",
277
+ "text": "Some recent works are also inspired by Brenier’s theorem and utilize a convex potential to parameterize a critic model, starting from Taghvaei & Jalali (2019), and further built upon by Makkuva et al. (2019) who parameterize a generator with a convex potential and concurrently by Korotin et al. (2019). Our work sets itself apart from these prior works in that it is entirely likelihood-based, minimizing the (empirical) KL divergence as opposed to an approximate optimal transport cost. ",
278
+ "bbox": [
279
+ 174,
280
+ 853,
281
+ 823,
282
+ 924
283
+ ],
284
+ "page_idx": 1
285
+ },
286
+ {
287
+ "type": "image",
288
+ "img_path": "images/88f501b26e8a23835a55bcdfca780564e9c1bf8c0b540c4e2ac5b9d64f1ee171.jpg",
289
+ "image_caption": [
290
+ "Figure 1: Illustration of Convex Potential Flow. (a) Data $x$ drawn from a mixture of Gaussians. (b) Learned convex potential $F$ . (c) Mesh grid distorted by the gradient map of the convex potential $f = \\nabla F$ . (d) Encoding of the data via the gradient map $z = f ( x )$ . Notably, the encoding is the value of the gradient of the convex potential. When the curvature of the potential function is locally flat, gradient values are small and this results in a contraction towards the origin. "
291
+ ],
292
+ "image_footnote": [],
293
+ "bbox": [
294
+ 194,
295
+ 103,
296
+ 802,
297
+ 242
298
+ ],
299
+ "page_idx": 2
300
+ },
301
+ {
302
+ "type": "text",
303
+ "text": "3 CONVEX POTENTIAL FLOWS ",
304
+ "text_level": 1,
305
+ "bbox": [
306
+ 176,
307
+ 342,
308
+ 444,
309
+ 358
310
+ ],
311
+ "page_idx": 2
312
+ },
313
+ {
314
+ "type": "text",
315
+ "text": "Given a strictly convex potential $F$ , we can define an injective map (invertible from its image) via its gradient $f = \\nabla F$ , since the Jacobian of $f$ is the Hessian matrix of $F$ , and is thus positive definite. In this section, we discuss the parameterization of the convex potential $F$ (3.1), and then address gradient estimation for CP-Flows (3.2). We examine the connection to other parameterization of normalizing flows (3.3), and finally rigorously prove universality in the next section. ",
316
+ "bbox": [
317
+ 173,
318
+ 373,
319
+ 825,
320
+ 444
321
+ ],
322
+ "page_idx": 2
323
+ },
324
+ {
325
+ "type": "text",
326
+ "text": "3.1 MODELING ",
327
+ "text_level": 1,
328
+ "bbox": [
329
+ 174,
330
+ 460,
331
+ 294,
332
+ 476
333
+ ],
334
+ "page_idx": 2
335
+ },
336
+ {
337
+ "type": "text",
338
+ "text": "Input Convex Neural Networks We use $L ( x )$ to denote a linear layer, and $L ^ { + } ( x )$ to denote a linear layer with positive weights. We use the (fully) input-convex neural network (ICNN, Amos et al. (2017)) to parameterize the convex potential, which has the following form ",
339
+ "bbox": [
340
+ 173,
341
+ 487,
342
+ 825,
343
+ 530
344
+ ],
345
+ "page_idx": 2
346
+ },
347
+ {
348
+ "type": "equation",
349
+ "img_path": "images/f1482f7991f0a9da76129d4eaf4306d87dbc1457ac763c3b4536834c3004df1f.jpg",
350
+ "text": "$$\nF ( x ) = L _ { K + 1 } ^ { + } ( s ( z _ { K } ) ) + L _ { K + 1 } ( x ) \\qquad z _ { k } : = L _ { k } ^ { + } ( s ( z _ { k - 1 } ) ) + L _ { k } ( x ) \\qquad z _ { 1 } : = L _ { 1 } ( x )\n$$",
351
+ "text_format": "latex",
352
+ "bbox": [
353
+ 212,
354
+ 535,
355
+ 785,
356
+ 554
357
+ ],
358
+ "page_idx": 2
359
+ },
360
+ {
361
+ "type": "text",
362
+ "text": "where $s$ is a non-decreasing, convex activation function. In this work, we use softplus-type activation functions, which is a rich family of activation functions that can be shown to uniformly approximate the ReLU activation. See Appendix B for details. ",
363
+ "bbox": [
364
+ 174,
365
+ 559,
366
+ 825,
367
+ 602
368
+ ],
369
+ "page_idx": 2
370
+ },
371
+ {
372
+ "type": "text",
373
+ "text": "Invertibility and Inversion Procedure If the activation $s$ is twice differentiable, then the Hessian $H _ { F }$ is positive semi-definite. We can make it strongly convex by adding a quadratic term $F _ { \\alpha } ( x ) =$ $\\begin{array} { r } { \\frac { \\alpha } { 2 } | | x | | _ { 2 } ^ { 2 } + F ( x ) } \\end{array}$ , such that $H _ { F _ { \\alpha } } \\simeq \\alpha I \\succ 0$ . This means the gradient map $f _ { \\alpha } = \\nabla F _ { \\alpha }$ is injective onto its image. Furthermore, it is surjective since for any $\\boldsymbol { y } ~ \\in ~ \\bar { \\mathbb { R } ^ { d } }$ , the potential $x \\ \\mapsto \\ \\bar { F } _ { \\alpha } ( x ) - y ^ { \\top } x$ has a unique minimizer1 satisfying the first order condition $\\nabla F _ { \\alpha } ( x ) = y$ , due to the strong convexity and differentiability. We refer to this invertible mapping $f _ { \\alpha }$ as the convex potential flow, or the CP-Flow. The above discussion also implies we can plug in a black-box convex solver to invert the gradient map $f _ { \\alpha }$ , which we summarize in Algorithm 1. Inverting a batch of independent inputs is as simple as summing the convex potential over all inputs: since all of the entries of the scalar $l$ in the minibatch are independent of each other, computing the gradient all $l$ ’s wrt all $x$ ’s amounts to computing the gradient of the summation of $l$ ’s wrt all $x$ ’s. Due to the convex nature of the problem, a wide selection of algorithms can be used with convergence guarantees (Nesterov, 1998). In practice, we use the L-BFGS algorithm (Byrd et al., 1995) as our CvxSolver. ",
374
+ "bbox": [
375
+ 174,
376
+ 617,
377
+ 516,
378
+ 757
379
+ ],
380
+ "page_idx": 2
381
+ },
382
+ {
383
+ "type": "table",
384
+ "img_path": "images/35fe79cc83d46563b9cf36c19b133d2b3e4ead04925584d342dc8ebdd8dbacd8.jpg",
385
+ "table_caption": [],
386
+ "table_footnote": [],
387
+ "table_body": "<table><tr><td>Algorithm1Inverting CP-Flow.</td></tr><tr><td>1: procedure INVERT(F,y, CvxSolver)</td></tr><tr><td>2: Initializex←y</td></tr><tr><td>3: def closure():</td></tr><tr><td>4: Compute loss: l ← F(x) - yTx</td></tr><tr><td>5: return l</td></tr><tr><td>6: x ← CvxSolver(closure,x)</td></tr><tr><td>7: return x</td></tr></table>",
388
+ "bbox": [
389
+ 531,
390
+ 625,
391
+ 823,
392
+ 747
393
+ ],
394
+ "page_idx": 2
395
+ },
396
+ {
397
+ "type": "text",
398
+ "text": "",
399
+ "bbox": [
400
+ 174,
401
+ 757,
402
+ 825,
403
+ 867
404
+ ],
405
+ "page_idx": 2
406
+ },
407
+ {
408
+ "type": "text",
409
+ "text": "Estimating Log Probability Following equation (1), computing the log density for CP-Flows requires taking the log determinant of a symmetric positive definite Jacobian matrix (as it is the Hessian of the potential). There exists numerous works on estimating spectral densities (e.g. TalEzer & Kosloff, 1984; Silver & Roder ¨ , 1994; Han et al., 2018; Adams et al., 2018), of which this quantity is a special case. See Lin et al. (2016) for an overview of methods that only require access to Hessian-vector products. Hessian-vector products (hvp) are cheap to compute with reverse-mode automatic differentiation (Baydin et al., 2017), which does not require constructing the full Hessian matrix and has the same asymptotic cost as evaluating $F _ { \\alpha }$ . ",
410
+ "bbox": [
411
+ 173,
412
+ 103,
413
+ 825,
414
+ 215
415
+ ],
416
+ "page_idx": 3
417
+ },
418
+ {
419
+ "type": "text",
420
+ "text": "In particular, the log determinant can be rewritten in the form of a generalized trace $\\operatorname { t r } \\log H$ . Chen et al. (2019a) limit the spectral norm (i.e. eigenvalues) of $H$ and directly use the Taylor expansion of the matrix logarithm. Since our $H$ has unbounded eigenvalues, we use a more complex algorithm designed for symmetric matrices, the stochastic Lanczos quadrature (SLQ; Ubaru et al., 2017). At the core of SLQ is the Lanczos method, which computes $m$ eigenvalues of $H$ by first constructing a symmetric tridiagonal matrix $T \\in \\mathbb { R } ^ { m \\times m }$ and computing the eigenvalues of $T$ . The Lanczos procedure only requires Hessian-vector products, and it can be combined with a stochastic trace estimator to provide a stochastic estimate of our log probability. We chose SLQ because it has shown theoretically and empirically to have low variance (Ubaru et al., 2017). ",
421
+ "bbox": [
422
+ 173,
423
+ 222,
424
+ 825,
425
+ 348
426
+ ],
427
+ "page_idx": 3
428
+ },
429
+ {
430
+ "type": "text",
431
+ "text": "3.2 $\\mathcal { O } ( 1 )$ -MEMORY UNBIASED $\\nabla \\log \\operatorname* { d e t } H$ ESTIMATOR ",
432
+ "text_level": 1,
433
+ "bbox": [
434
+ 173,
435
+ 363,
436
+ 568,
437
+ 378
438
+ ],
439
+ "page_idx": 3
440
+ },
441
+ {
442
+ "type": "text",
443
+ "text": "We would also like to have an estimator for the gradient of the log determinant to enable variants of stochastic gradient descent for optimization. Unfortunately, directly backpropagating through the log determinant estimator is not ideal. Two major drawbacks of directly differentiating through SLQ are that it requires (i) differentiating through an eigendecomposition routine and (ii) storing all Hessian-vector products in memory (see fig. 2). Problem (i) is more specific to SLQ, because the gradient of an eigendecomposition is not defined when the eigenvalues are not unique (Seeger et al., 2017). Consequently, we have empirically observed that differentiating through SLQ can be unstable, frequently resulting in NaNs due to the eigendecomposition. Problem (ii) will hold true for other algorithms that also estimate $\\log \\operatorname* { d e t } H$ with Hessian-vector products, and generally the only difference is that a different numerical routine would need to be differentiated through. Due to these problems, we do not differentiate through SLQ, but we still use it as an efficient method for monitoring training progress. ",
444
+ "bbox": [
445
+ 174,
446
+ 390,
447
+ 549,
448
+ 529
449
+ ],
450
+ "page_idx": 3
451
+ },
452
+ {
453
+ "type": "image",
454
+ "img_path": "images/0811c3799e43dfda077761083b792341e7ec861165822040a8e9163617769b54.jpg",
455
+ "image_caption": [
456
+ "Figure 2: Memory for training CIFAR-10. "
457
+ ],
458
+ "image_footnote": [],
459
+ "bbox": [
460
+ 568,
461
+ 392,
462
+ 812,
463
+ 500
464
+ ],
465
+ "page_idx": 3
466
+ },
467
+ {
468
+ "type": "text",
469
+ "text": "",
470
+ "bbox": [
471
+ 174,
472
+ 529,
473
+ 825,
474
+ 613
475
+ ],
476
+ "page_idx": 3
477
+ },
478
+ {
479
+ "type": "text",
480
+ "text": "Instead, it is possible to construct an alternative formulation of the gradient as the solution of a convex optimization problem, foregoing the necessity of differentiating through an estimation routine of the log determinant. We adapt the gradient formula from Chen et al. (2019a, Appendix C) to the context of convex potentials. Using Jacobi’s formula⇤ and the adjugate representation of the matrix inverse†, for any invertible matrix $H$ with parameter $\\theta$ , we have the following identity: ",
481
+ "bbox": [
482
+ 173,
483
+ 619,
484
+ 825,
485
+ 689
486
+ ],
487
+ "page_idx": 3
488
+ },
489
+ {
490
+ "type": "equation",
491
+ "img_path": "images/ec9b5c91ea0eac122ad09f689b46819e0ed878a08d01df41466be22a037d2b79.jpg",
492
+ "text": "$$\n\\begin{array} { r } { \\frac { \\partial } { \\partial \\theta } \\log \\operatorname* { d e t } H = \\frac { 1 } { \\operatorname* { d e t } H } \\frac { \\partial } { \\partial \\theta } \\operatorname* { d e t } H \\stackrel { \\ast } { = } - \\frac { 1 } { \\operatorname* { d e t } } \\bigl ( \\qquad \\frac { \\partial H } { \\partial \\theta } \\bigr ) \\stackrel { \\dagger } { = } \\operatorname { t r } \\bigl ( \\frac { \\partial H } { \\partial \\theta } \\bigr ) = \\mathbb { E } _ { v } \\left[ v ^ { \\top } H ^ { - 1 } \\frac { \\partial H } { \\partial \\theta } v \\right] . } \\end{array}\n$$",
493
+ "text_format": "latex",
494
+ "bbox": [
495
+ 181,
496
+ 696,
497
+ 821,
498
+ 720
499
+ ],
500
+ "page_idx": 3
501
+ },
502
+ {
503
+ "type": "text",
504
+ "text": "Notably, in the last equality, we used the Hutchinson trace estimator (Hutchinson, 1989) with a Rademacher random vector $v$ , leading to a $\\mathcal { O } ( 1 )$ -memory, unbiased Monte Carlo gradient estimator. ",
505
+ "bbox": [
506
+ 173,
507
+ 741,
508
+ 823,
509
+ 770
510
+ ],
511
+ "page_idx": 3
512
+ },
513
+ {
514
+ "type": "text",
515
+ "text": "Computing the quantity $v ^ { \\top } H ^ { - 1 }$ in eq. (3) by constructing and inverting the full Hessian requires $d$ calls to an automatic differentiation routine and is too costly for our purposes. However, we can recast this quantity as the solution of a quadratic optimization problem ",
516
+ "bbox": [
517
+ 176,
518
+ 775,
519
+ 823,
520
+ 819
521
+ ],
522
+ "page_idx": 3
523
+ },
524
+ {
525
+ "type": "equation",
526
+ "img_path": "images/d52303e3547626027b9485d074dc46948c6470136d5f8bab831d8e363836d120.jpg",
527
+ "text": "$$\n\\arg \\operatorname* { m i n } _ { z } \\left\\{ { \\frac { 1 } { 2 } } z ^ { \\top } H z - v ^ { \\top } z \\right\\}\n$$",
528
+ "text_format": "latex",
529
+ "bbox": [
530
+ 406,
531
+ 825,
532
+ 593,
533
+ 859
534
+ ],
535
+ "page_idx": 3
536
+ },
537
+ {
538
+ "type": "text",
539
+ "text": "which has the unique minimizer $z ^ { * } = H ^ { - 1 } v$ since $H$ is symmetric positive definite. ",
540
+ "bbox": [
541
+ 173,
542
+ 866,
543
+ 723,
544
+ 882
545
+ ],
546
+ "page_idx": 3
547
+ },
548
+ {
549
+ "type": "text",
550
+ "text": "We use the conjugate gradient (CG) method, which is specifically designed for solving the unconstrained optimization problems in eq. (4) with symmetric positive definite $H$ . It uses only Hessian-vector products and is straightforward to parallelize. Conjugate gradient is guaranteed to return the exact solution $z ^ { * }$ within $d$ iterations, and the error of the approximation is known to converge exponentially fast $| | z ^ { m } - z ^ { * } | | _ { H } ~ \\leq$ $2 \\gamma ^ { m } | | z ^ { 0 } - z ^ { * } | | _ { H } ^ { * }$ , where $z ^ { m }$ is the estimate after ",
551
+ "bbox": [
552
+ 174,
553
+ 103,
554
+ 496,
555
+ 242
556
+ ],
557
+ "page_idx": 4
558
+ },
559
+ {
560
+ "type": "table",
561
+ "img_path": "images/6b3aadb0afbde1f9435b3e35674b1e64fe7450dbdfd8cf4df5686f55d57765c2.jpg",
562
+ "table_caption": [],
563
+ "table_footnote": [],
564
+ "table_body": "<table><tr><td>Algorithm 2 Surrogate training objective.</td></tr><tr><td>1: procedure SURROGATEOBJ(F,x,CG)</td></tr><tr><td>2: Obtain the gradient f(x) = VxF(x)</td></tr><tr><td>3: Sample Rademacher random vector r</td></tr><tr><td>4: def hvp(v): 5: return ν</td></tr><tr><td>6: z ← stop-gradient (CG(hvp,r))</td></tr><tr><td>return hvp(z)Tr</td></tr><tr><td>7:</td></tr></table>",
565
+ "bbox": [
566
+ 513,
567
+ 106,
568
+ 820,
569
+ 229
570
+ ],
571
+ "page_idx": 4
572
+ },
573
+ {
574
+ "type": "text",
575
+ "text": "$m$ iterations. The rate of convergence $\\gamma < 1$ relates to the condition number of $H$ . For more details, see Nocedal & Wright (2006, Ch. 5). In practice, we terminate CG when $| | H z ^ { m } - v | | _ { \\infty } < \\tau$ is satisfied for some user-controlled tolerance. Empirically, we find that stringent tolerance values are unnecessary for stochastic optimization (see appendix F). ",
576
+ "bbox": [
577
+ 174,
578
+ 242,
579
+ 825,
580
+ 299
581
+ ],
582
+ "page_idx": 4
583
+ },
584
+ {
585
+ "type": "text",
586
+ "text": "Estimating the full quantity in eq. (3) is then simply a matter of computing and differentiating a scalar quantity (a surrogate objective) involving another Hessian-vector product: $\\begin{array} { r } { \\frac { d } { d \\theta } \\left( \\left( z ^ { m } \\right) ^ { \\top } H \\mathbf { \\bar { v } } \\right) } \\end{array}$ , where only $H$ is differentiated through (since $z ^ { m }$ is only used to approximate $v ^ { \\top } H ^ { - 1 }$ as a modifier of the gradient). We summarize this procedure in Algorithm 2. Similar to inversion, the hvp can also be computed in batch by summing over the data index, since all entries are independent. ",
587
+ "bbox": [
588
+ 174,
589
+ 304,
590
+ 825,
591
+ 377
592
+ ],
593
+ "page_idx": 4
594
+ },
595
+ {
596
+ "type": "text",
597
+ "text": "3.3 CONNECTION TO OTHER NORMALIZING FLOWS ",
598
+ "text_level": 1,
599
+ "bbox": [
600
+ 174,
601
+ 395,
602
+ 540,
603
+ 409
604
+ ],
605
+ "page_idx": 4
606
+ },
607
+ {
608
+ "type": "text",
609
+ "text": "Residual Flow For $\\alpha = 1$ , the gradient map $f _ { 1 }$ resembles the residual flow (Behrmann et al., 2019; Chen et al., 2019a). They require the residual block—equivalent to our gradient map $f$ —to be contractive (with Lipschitz constant strictly smaller than 1) as a sufficient condition for invertibility. In contrast, we enforce invertibility by using strongly convex potentials, which guarantees that the inverse of our flow is globally unique. With this, we do not pay the extra compute cost for having to satisfy Lipschitz constraints using methods such as spectral normalization (Miyato et al., 2018). Our gradient estimator is also derived similarly to that of Chen et al. (2019a), though we have the benefit of using well-studied convex optimization algorithms for computing the gradients. ",
610
+ "bbox": [
611
+ 173,
612
+ 420,
613
+ 825,
614
+ 534
615
+ ],
616
+ "page_idx": 4
617
+ },
618
+ {
619
+ "type": "text",
620
+ "text": "Sylvester Flow By restricting the architecture of our ICNN to one hidden layer, we can also recover a form similar to Sylvester Flows. For a 1-hidden layer ICNN $K = 1$ ) and $\\alpha = 1$ , we have $\\begin{array} { r } { F _ { 1 } = \\frac 1 2 | | \\boldsymbol { x } | | _ { 2 } ^ { 2 } + L _ { 2 } ^ { + } ( s ( L _ { 1 } \\dot { \\boldsymbol { x } } ) ) + L _ { 2 } ( \\boldsymbol { x } ) } \\end{array}$ . Setting the weights of $L _ { 2 }$ to zero, we have ",
621
+ "bbox": [
622
+ 173,
623
+ 547,
624
+ 825,
625
+ 592
626
+ ],
627
+ "page_idx": 4
628
+ },
629
+ {
630
+ "type": "equation",
631
+ "img_path": "images/eab06468babad9c3abc6a25e952f8fb5708ee89aaf806ca85e1bf1d61d85eb06.jpg",
632
+ "text": "$$\nf _ { 1 } ( x ) = \\nabla _ { x } F _ { 1 } ( x ) = x + W _ { 1 } ^ { \\top } \\mathtt { d i a g } ( w _ { 2 } ^ { + } ) s ^ { \\prime } ( W _ { 1 } x + b _ { 1 } ) .\n$$",
633
+ "text_format": "latex",
634
+ "bbox": [
635
+ 316,
636
+ 599,
637
+ 681,
638
+ 618
639
+ ],
640
+ "page_idx": 4
641
+ },
642
+ {
643
+ "type": "text",
644
+ "text": "We notice the above form bears a close resemblance to the Sylvester normalizing flow (Van Den Berg et al., 2018) (with $Q$ , $\\pmb { R }$ and $\\widetilde { R }$ from Van Den Berg et al. (2018) being equal to $W _ { 1 } ^ { \\top }$ , $\\mathrm { d i a g ( } w _ { 2 } ^ { + } \\mathrm { ) }$ and $I$ , respectively). For the Sylvester flow to be invertible, they require that $\\pmb { R }$ and $\\widetilde { R }$ be triangular and $Q$ be orthogonal, which is a computationally costly procedure. This orthogonality constraint also implies that the number of hidden units cannot exceed $d$ . This restriction to orthogonal matrices and one hidden layer are for applying Sylvester’s determinant identity. In contrast, we do not require our weight matrices to be orthogonal, and we can use any hidden width and depth for the ICNN. ",
645
+ "bbox": [
646
+ 173,
647
+ 625,
648
+ 825,
649
+ 729
650
+ ],
651
+ "page_idx": 4
652
+ },
653
+ {
654
+ "type": "text",
655
+ "text": "Sigmoidal Flow Let $s$ be the softplus activation function and $\\sigma = s ^ { \\prime }$ . Then for the 1-dimensional case $d = 1$ ) and $\\alpha = 0$ (without the residual connection), we have ",
656
+ "bbox": [
657
+ 173,
658
+ 744,
659
+ 823,
660
+ 773
661
+ ],
662
+ "page_idx": 4
663
+ },
664
+ {
665
+ "type": "equation",
666
+ "img_path": "images/0dfb41d970e215c75d537f6d605f882127c8907d5ea25d01c69d9b93d2a0cf5f.jpg",
667
+ "text": "$$\n\\frac { \\partial } { \\partial x } F _ { 0 } ( x ) = \\sum _ { j = 1 } w _ { 1 , j } w _ { 2 , j } ^ { + } \\sigma ( w _ { 1 , j } x + b _ { 1 , j } ) = \\sum _ { j = 1 } | w _ { 1 , j } | w _ { 2 , j } ^ { + } \\sigma ( | w _ { 1 , j } | x + \\mathrm { s i g n } ( w _ { 1 , j } ) b _ { 1 , j } ) + \\mathrm { c o n s t } .\n$$",
668
+ "text_format": "latex",
669
+ "bbox": [
670
+ 181,
671
+ 782,
672
+ 797,
673
+ 819
674
+ ],
675
+ "page_idx": 4
676
+ },
677
+ {
678
+ "type": "text",
679
+ "text": "which is equivalent to the sigmoidal flow of Huang et al. (2018) up to rescaling (since the weighted sum is no longer a convex sum) and a constant shift, and is monotone due to the positive weights. This correspondence is not surprising since a differentiable function is convex if and only if its derivative is monotonically non-decreasing. It also means we can parameterize an increasing function as the derivative of a convex function, which opens up a new direction for parameterizing autoregressive normalizing flows (Kingma et al., 2016; Huang et al., 2018; Muller et al. ¨ , 2019; Jaini et al., 2019; Durkan et al., 2019; Wehenkel & Louppe, 2019). ",
680
+ "bbox": [
681
+ 173,
682
+ 825,
683
+ 825,
684
+ 924
685
+ ],
686
+ "page_idx": 4
687
+ },
688
+ {
689
+ "type": "text",
690
+ "text": "Flows with Potential Parameterization Inspired by connections between optimal transport and continuous normalizing flows, some works (Zhang et al., 2018; Finlay et al., 2020a; Onken et al., 2020) have proposed to parameterize continuous-time transformations by taking the gradient of a scalar potential. They do not strictly require the potential to be convex since it is guaranteed to be invertible in the infinitesimal setting of continuous normalizing flows (Chen et al., 2018). There exist works (Yang & Karniadakis, 2019; Finlay et al., 2020b; Onken et al., 2020) that have applied the theory of optimal transport to regularize continuous-time flows to have low transport cost. In contrast, we connect optimal transport with discrete-time normalizing flows, and CP-Flow is guaranteed by construction to converge pointwise to the optimal mapping between distributions without explicit regularization (see Section 4). ",
691
+ "bbox": [
692
+ 173,
693
+ 103,
694
+ 825,
695
+ 242
696
+ ],
697
+ "page_idx": 5
698
+ },
699
+ {
700
+ "type": "text",
701
+ "text": "4 THEORETICAL ANALYSES ",
702
+ "text_level": 1,
703
+ "bbox": [
704
+ 176,
705
+ 262,
706
+ 421,
707
+ 279
708
+ ],
709
+ "page_idx": 5
710
+ },
711
+ {
712
+ "type": "text",
713
+ "text": "As explained in Section 2, the parameterization of CP-Flow is inspired by the Brenier potential. So naturally we would hope to show that (1) CP-Flows are distributionally universal, and that (2) the learned invertible map is optimal in the sense of the average squared distance the input travels $\\mathbb { E } [ | | x - f ( x ) | | ^ { 2 } ]$ . Proofs of statements made in this section can be found in Appendices C and D. ",
714
+ "bbox": [
715
+ 174,
716
+ 292,
717
+ 823,
718
+ 349
719
+ ],
720
+ "page_idx": 5
721
+ },
722
+ {
723
+ "type": "text",
724
+ "text": "To show (1), our first step is to show that ICNNs can approximate arbitrary convex functions. However, convergence of potential functions does not generally imply convergence of the gradient fields. A classic example is the sequence $F _ { n } = \\sin ( \\bar { n } x ) / \\sqrt { n }$ and the corresponding derivatives $f _ { n } = \\cos ( n x ) { \\sqrt { n } }$ : $F _ { n } \\to 0$ as $n \\to \\infty$ but $f _ { n }$ does not. Fortunately, convexity allows us to control the variation of the gradient map (since the derivative of a convex function is monotone), so our second step of approximation holds. ",
725
+ "bbox": [
726
+ 174,
727
+ 356,
728
+ 825,
729
+ 440
730
+ ],
731
+ "page_idx": 5
732
+ },
733
+ {
734
+ "type": "text",
735
+ "text": "Theorem 2. Let $F _ { n } : \\mathbb { R } ^ { d } \\mathbb { R }$ be differentiable convex functions and $G : \\mathbb { R } ^ { d } \\mathbb { R }$ be a proper convex function. Assume $F _ { n } \\to G$ . Then for almost every $\\mathbf { \\bar { \\Phi } } _ { x \\in \\mathbb { R } ^ { d } }$ , $G$ is differentiable and $f _ { n } ( x ) : =$ $\\nabla F _ { n } ( \\boldsymbol { \\dot { x } } ) \\nabla G ( \\boldsymbol { x } ) = : g ( \\boldsymbol { x } )$ . ",
736
+ "bbox": [
737
+ 174,
738
+ 449,
739
+ 825,
740
+ 493
741
+ ],
742
+ "page_idx": 5
743
+ },
744
+ {
745
+ "type": "text",
746
+ "text": "Combining these two steps and Brenier’s theorem, we show that CP-Flow with softplus-type activation function is distributionally universal. ",
747
+ "bbox": [
748
+ 174,
749
+ 503,
750
+ 821,
751
+ 532
752
+ ],
753
+ "page_idx": 5
754
+ },
755
+ {
756
+ "type": "text",
757
+ "text": "Theorem 3 (Universality). Given random variables $X \\sim \\mu$ and $Y \\sim \\nu$ , with $\\mu$ being absolutely continuous w.r.t. the Lebesgue measure, there exists a sequence of ICNN $F _ { n }$ with a softplus-type activation, such that $\\nabla F _ { n } \\circ X Y$ in distribution. ",
758
+ "bbox": [
759
+ 174,
760
+ 541,
761
+ 823,
762
+ 585
763
+ ],
764
+ "page_idx": 5
765
+ },
766
+ {
767
+ "type": "text",
768
+ "text": "N.B. In the theorem we do not require the second moment to be finite, as for arbitrary random variables we can apply the standard truncation technique and redistribute the probability mass so that the new random variables are almost surely bounded. For probability measures with finite second moments, we indeed use the gradient map of ICNN to approximate the optimal transport map corresponding to the Brenier potential. In the following theorem, we show that the optimal transport map is the only such mapping that we can approximate if we match the distributions. ",
769
+ "bbox": [
770
+ 174,
771
+ 599,
772
+ 825,
773
+ 684
774
+ ],
775
+ "page_idx": 5
776
+ },
777
+ {
778
+ "type": "text",
779
+ "text": "Theorem 4 (Optimality). Let $G$ be the Brenier potential of $X \\sim \\mu$ and $Y \\sim \\nu$ , and let $F _ { n }$ be $a$ convergent sequence of differentiable, convex potentials, such that $\\nabla F _ { n } \\circ X Y$ in distribution. Then $\\nabla F _ { n }$ converges almost surely to rG. ",
780
+ "bbox": [
781
+ 176,
782
+ 694,
783
+ 823,
784
+ 736
785
+ ],
786
+ "page_idx": 5
787
+ },
788
+ {
789
+ "type": "text",
790
+ "text": "The theorem states that in practice, even if we optimize according to some loss that traces the convergence in distribution, our model is still able to recover the optimal transport map, as if we were optimizing according to the transport cost. This allows us to estimate optimal transport maps without solving the constrained optimization in (2). See Seguy et al. (2018) for some potential applications of the optimal transport map, such as domain adaptation or domain translation. ",
791
+ "bbox": [
792
+ 174,
793
+ 747,
794
+ 825,
795
+ 816
796
+ ],
797
+ "page_idx": 5
798
+ },
799
+ {
800
+ "type": "text",
801
+ "text": "5 EXPERIMENT ",
802
+ "text_level": 1,
803
+ "bbox": [
804
+ 176,
805
+ 837,
806
+ 316,
807
+ 852
808
+ ],
809
+ "page_idx": 5
810
+ },
811
+ {
812
+ "type": "text",
813
+ "text": "We use CP-Flow to perform density estimation (RHS of (1)) and variational inference (LHS of (1)) to assess its approximation capability, and the effectiveness of the proposed gradient estimator. All the details of experiments can be found in Appendix E. Code is available at https://github.com/CWHuang/CP-Flow. ",
814
+ "bbox": [
815
+ 174,
816
+ 867,
817
+ 823,
818
+ 922
819
+ ],
820
+ "page_idx": 5
821
+ },
822
+ {
823
+ "type": "image",
824
+ "img_path": "images/33a437e328e3e761c9d8cd9c08bc654600d07ba8d88130ed54777e822f8f0ea3.jpg",
825
+ "image_caption": [
826
+ "Figure 4: Approximating optimal transport map via maximum likelihood (minimizing KL divergence). In the first figure on the left we show the data in 2 dimensions. The datapoints are colored according to their horizontal values $( x _ { 1 } )$ . The flows $f _ { i a f }$ and $f _ { c p }$ are trained to transform the data into a standard Gaussian prior. In the figures on the right, we plot the expected quadratic transportation cost versus the KL divergence for different numbers of dimensionality. During training the KL is minimized, so the curves read from the right to the left. "
827
+ ],
828
+ "image_footnote": [],
829
+ "bbox": [
830
+ 179,
831
+ 97,
832
+ 821,
833
+ 234
834
+ ],
835
+ "page_idx": 6
836
+ },
837
+ {
838
+ "type": "text",
839
+ "text": "ICNN Architecture Despite the universal property, having a poor parameterization can lead to difficulties in optimization and limit the effective expressivity of the model. We propose an architectural enhancement of ICNN, defined as follows (note the change in notation: instead of writing the pre-activations $z$ , we use $h$ to denote the activated units): ",
840
+ "bbox": [
841
+ 173,
842
+ 339,
843
+ 825,
844
+ 396
845
+ ],
846
+ "page_idx": 6
847
+ },
848
+ {
849
+ "type": "equation",
850
+ "img_path": "images/6a3f445bf0e661ec3615fff1cb0b5c96c7910719721d8fb66147440bc84f1301.jpg",
851
+ "text": "$$\n\\begin{array} { c c } { { F ^ { a u g } ( x ) : = L _ { K + 1 } ^ { + } ( h _ { K } ) + L _ { K + 1 } ( x ) } } & { { } } \\\\ { { h _ { k } : = \\mathrm { c o n c a t } ( [ \\widetilde { h } _ { k } , h _ { k } ^ { a u g } ] ) \\qquad \\widetilde { h } _ { k } : = s ( L _ { k } ^ { + } ( h _ { k - 1 } ) + L _ { k } ( x ) ) \\qquad h _ { k } ^ { a u g } = s ( L _ { k } ^ { a u g } ( x ) ) } } & { { } } \\end{array}\n$$",
852
+ "text_format": "latex",
853
+ "bbox": [
854
+ 212,
855
+ 401,
856
+ 784,
857
+ 445
858
+ ],
859
+ "page_idx": 6
860
+ },
861
+ {
862
+ "type": "text",
863
+ "text": "where half of the hidden units are directly connected to the input, so the gradient would have some form of skip connection. We call this the input-augmented ICNN. Unless otherwise stated, we use the input-augmented ICNN as the default architecture. ",
864
+ "bbox": [
865
+ 174,
866
+ 450,
867
+ 825,
868
+ 492
869
+ ],
870
+ "page_idx": 6
871
+ },
872
+ {
873
+ "type": "text",
874
+ "text": "5.1 TOY EXAMPLES ",
875
+ "text_level": 1,
876
+ "bbox": [
877
+ 174,
878
+ 510,
879
+ 325,
880
+ 523
881
+ ],
882
+ "page_idx": 6
883
+ },
884
+ {
885
+ "type": "text",
886
+ "text": "Having distributional universality for a single flow layer means that we can achieve high expressiveness without composing too many flows. We demonstrate this by fitting the density on some toy examples taken from Papamakarios et al. (2017) and Behrmann et al. (2019). We compare with the masked autoregressive flow (MAF, Papamakarios et al. (2017)) and the neural autoregressive flow (NAF, (Huang et al., 2018)). Results are presented in fig. 3. We try to match the network size for each data. All models fit the first data well. As affine couplings cannot split probability mass, MAF fails to fit to the second and third datasets2. Although the last dataset is intrinsi",
887
+ "bbox": [
888
+ 174,
889
+ 536,
890
+ 483,
891
+ 743
892
+ ],
893
+ "page_idx": 6
894
+ },
895
+ {
896
+ "type": "image",
897
+ "img_path": "images/15a901b8d2626cb3b44ce09247c743b8ed5ae593bc8c32f679ac776b76bf79b3.jpg",
898
+ "image_caption": [
899
+ "Figure 3: Learning toy densities. "
900
+ ],
901
+ "image_footnote": [],
902
+ "bbox": [
903
+ 501,
904
+ 523,
905
+ 820,
906
+ 713
907
+ ],
908
+ "page_idx": 6
909
+ },
910
+ {
911
+ "type": "text",
912
+ "text": "cally harder to fit (as NAF, another universal density model, also fails to fit it well), the proposed method still manages to learn the correct density with high fidelity. ",
913
+ "bbox": [
914
+ 174,
915
+ 743,
916
+ 823,
917
+ 772
918
+ ],
919
+ "page_idx": 6
920
+ },
921
+ {
922
+ "type": "text",
923
+ "text": "5.2 APPROXIMATING OPTIMAL COUPLING ",
924
+ "text_level": 1,
925
+ "bbox": [
926
+ 176,
927
+ 790,
928
+ 477,
929
+ 803
930
+ ],
931
+ "page_idx": 6
932
+ },
933
+ {
934
+ "type": "text",
935
+ "text": "As predicted by Theorem 4, CP-Flow is guaranteed to converge to the optimal coupling minimizing the expected quadratic cost. We empirically verify it by learning the Gaussian density and comparing the expected quadratic distance between the input and output of the flow against $J _ { | | x - y | | ^ { 2 } }$ between the Gaussian data and the standard Gaussian prior (as there is a closed-form expression). In fig. 4, we see that the transport cost gets closer to the optimal value when the learned density approaches the data distribution (measured by the KL divergence). We compare against the linear inverse autoregressive flow (Kingma et al., 2016), which has the capacity to represent the multivariate Gaussian density, yet it does not learn the optimal coupling. ",
936
+ "bbox": [
937
+ 174,
938
+ 815,
939
+ 825,
940
+ 886
941
+ ],
942
+ "page_idx": 6
943
+ },
944
+ {
945
+ "type": "table",
946
+ "img_path": "images/233f9f36356994c79db303502ec55adc07f12f9e144ce45f4d0dd381ff299724.jpg",
947
+ "table_caption": [
948
+ "Table 1: Average test negative log-likelihood (in nats) of tabular datasets in Papamakarios et al. (2017) for density estimation models (lower is better). Standard deviation is presented in the appendix E.4. "
949
+ ],
950
+ "table_footnote": [],
951
+ "table_body": "<table><tr><td>Model</td><td>POWER</td><td>GAS</td><td>HEPMASS</td><td>MINIBOONE</td><td>BSDS300</td></tr><tr><td>Real NVP (Dinh et al., 2017)</td><td>-0.17</td><td>-8.33</td><td>18.71</td><td>13.55</td><td>-153.28</td></tr><tr><td>FFJORD (Grathwohl et al., 2018)</td><td>-0.46</td><td>-8.59</td><td>14.92</td><td>10.43</td><td>-157.40</td></tr><tr><td>MADE (Germain et al., 2015)</td><td>3.08</td><td>-3.56</td><td>20.98</td><td>15.59</td><td>-148.85</td></tr><tr><td>MAF (Papamakarios et al., 2017)</td><td>-0.24</td><td>-10.08</td><td>17.70</td><td>11.75</td><td>-155.69</td></tr><tr><td>TAN (Oliva et al., 2018)</td><td>-0.48</td><td>-11.19</td><td>15.12</td><td>11.01</td><td>-157.03</td></tr><tr><td>NAF (Huang et al., 2018)</td><td>-0.62</td><td>-11.96</td><td>15.09</td><td>8.86</td><td>-157.73</td></tr><tr><td>CP-Flow (Ours)</td><td>-0.52</td><td>-10.36</td><td>16.93</td><td>10.58</td><td>-154.99</td></tr></table>",
952
+ "bbox": [
953
+ 200,
954
+ 101,
955
+ 797,
956
+ 234
957
+ ],
958
+ "page_idx": 7
959
+ },
960
+ {
961
+ "type": "table",
962
+ "img_path": "images/f55a1bd5ecbc668b7ba6403df2db85f32a5a1c61f81dff72e4f797f5ce4f4d9e.jpg",
963
+ "table_caption": [
964
+ "Table 2: Negative log-likelihood (in bits) on held-out test data (lower is better). †Taken from Durkan et al. (2019). ‡Obtained from official open source code. "
965
+ ],
966
+ "table_footnote": [],
967
+ "table_body": "<table><tr><td rowspan=\"2\">Model</td><td colspan=\"2\">MNIST</td><td colspan=\"2\">CIFAR-10</td></tr><tr><td>Bits/dim</td><td>N. params</td><td>Bits/dim</td><td> N. params</td></tr><tr><td>Real NVP (Dinh et al., 2017)</td><td>1.05</td><td>N/A</td><td>3.49</td><td>N/A</td></tr><tr><td>Glow (Kingma &amp; Dhariwal, 2018)</td><td>1.06</td><td>N/A</td><td>3.35</td><td>44.0Mt</td></tr><tr><td>RQ-NSF (Durkan et al., 2019)</td><td>一</td><td>一</td><td>3.38</td><td>11.8M+</td></tr><tr><td>Residual Flow (Chen et al., 2019a)</td><td>0.97</td><td>16.6M‡</td><td>3.28</td><td>25.2M</td></tr><tr><td>Coupling Block Ablation</td><td>1.02</td><td>3.1M</td><td>3.58</td><td>2.9M</td></tr><tr><td>Residual Block Ablation</td><td>1.04</td><td>2.9M</td><td>3.46</td><td>3.1M</td></tr><tr><td>CP-Flow (Ours)</td><td>1.02</td><td>2.9M</td><td>3.40</td><td>1.9M</td></tr></table>",
968
+ "bbox": [
969
+ 230,
970
+ 285,
971
+ 769,
972
+ 439
973
+ ],
974
+ "page_idx": 7
975
+ },
976
+ {
977
+ "type": "text",
978
+ "text": "",
979
+ "bbox": [
980
+ 176,
981
+ 503,
982
+ 821,
983
+ 546
984
+ ],
985
+ "page_idx": 7
986
+ },
987
+ {
988
+ "type": "text",
989
+ "text": "5.3 DENSITY ESTIMATION ",
990
+ "text_level": 1,
991
+ "bbox": [
992
+ 176,
993
+ 564,
994
+ 369,
995
+ 579
996
+ ],
997
+ "page_idx": 7
998
+ },
999
+ {
1000
+ "type": "text",
1001
+ "text": "We demonstrate the efficacy of our model and the proposed gradient estimator by performing density estimation on the standard benchmarks. ",
1002
+ "bbox": [
1003
+ 174,
1004
+ 590,
1005
+ 823,
1006
+ 619
1007
+ ],
1008
+ "page_idx": 7
1009
+ },
1010
+ {
1011
+ "type": "text",
1012
+ "text": "Tabular Data We use the datasets preprocessed by Papamakarios et al. (2017). In table 1, we report average negative log-likelihood estimates evaluated on held-out test sets, for the best hyperparameters found via grid search. The search was focused on the number of flow blocks, the width and depth of the ICNN potentials. See appendix E.4 for details. Our models perform competitively against alternative approaches in the literature. We also perform an ablation on the CG error tolerance and ICNN architectures in appendix F. ",
1013
+ "bbox": [
1014
+ 174,
1015
+ 636,
1016
+ 825,
1017
+ 719
1018
+ ],
1019
+ "page_idx": 7
1020
+ },
1021
+ {
1022
+ "type": "text",
1023
+ "text": "Image Data Next, we apply CP-Flow to model the density of standard image datasets, MNIST and CIFAR-10. For this, we use convolutional layers in place of fully connected layers. Prior works have had to use large architectures, with many flow blocks composed together, resulting in a large number of parameters to optimize. While we also compose multiple blocks of CP-Flows, we find that CP-Flow can perform relatively well with fewer number of parameters (table 2). Notably, we achieve comparable bits per dimension to Neural Spline Flows (Durkan et al., 2019)—another work promoting fewer parameters—while having using around $16 \\%$ number of parameters. ",
1024
+ "bbox": [
1025
+ 174,
1026
+ 734,
1027
+ 825,
1028
+ 833
1029
+ ],
1030
+ "page_idx": 7
1031
+ },
1032
+ {
1033
+ "type": "text",
1034
+ "text": "As prior works use different architectures with widely varying hyperparameters, we perform a more careful ablation study using coupling (Dinh et al., 2014; 2017) and invertible residual blocks (Chen et al., 2019a). We replace each of our flow blocks with the corresponding baseline. We find that on CIFAR-10, the baseline flow models do not perform nearly as well as CP-Flow. We believe this may be because CP-Flows are universal with just one flow block, whereas coupling and invertible residual blocks are limited in expressivity or Lipschitz-constrained. ",
1035
+ "bbox": [
1036
+ 174,
1037
+ 840,
1038
+ 825,
1039
+ 924
1040
+ ],
1041
+ "page_idx": 7
1042
+ },
1043
+ {
1044
+ "type": "text",
1045
+ "text": "5.4 AMORTIZING ICNN FOR VARIATIONAL INFERENCE ",
1046
+ "text_level": 1,
1047
+ "bbox": [
1048
+ 171,
1049
+ 104,
1050
+ 570,
1051
+ 117
1052
+ ],
1053
+ "page_idx": 8
1054
+ },
1055
+ {
1056
+ "type": "text",
1057
+ "text": "Normalizing flows also allow us to employ a larger, more flexible family of distributions for variational inference (Rezende & Mohamed, 2015). We replicate the experiment conducted in Van Den Berg et al. (2018) to enhance the variational autoencoder (Kingma & Welling, 2013). For inference amortization, we use the partially input convex neural network from Amos et al. (2017), and use the output of the encoder as the additional input for conditioning. As table 3 shows, the performance of CPFlow is close to the best reported in Van Den Berg et al. (2018) without changing the experiment setup. This shows that the convex potential parameterization along with the proposed gradient estimator can learn to perform accurate amortized inference. Also, we show that replacing the vanilla ICNN with the input-augmented ICNN leads to improvement of the likelihood estimates. ",
1058
+ "bbox": [
1059
+ 174,
1060
+ 130,
1061
+ 516,
1062
+ 309
1063
+ ],
1064
+ "page_idx": 8
1065
+ },
1066
+ {
1067
+ "type": "table",
1068
+ "img_path": "images/8289309b3011ac2bacbb10c47c49869fca2bb67607e90ef4572a23a8ca3b4782.jpg",
1069
+ "table_caption": [],
1070
+ "table_footnote": [
1071
+ "Table 3: Negative ELBO of VAE (lower is better). Standard deviation reported in appendix E.6. "
1072
+ ],
1073
+ "table_body": "<table><tr><td></td><td>FREYFACES OMNIGLOT</td><td>CALTECH</td></tr><tr><td>Gaussian</td><td>4.53</td><td>104.28 110.80</td></tr><tr><td>Planar</td><td>4.40</td><td>102.65 109.66</td></tr><tr><td>IAF</td><td>4.47</td><td>102.41 111.58</td></tr><tr><td>Sylvester</td><td>4.45</td><td>99.00 104.62</td></tr><tr><td>CP-Flow (vanilla)</td><td>4.47</td><td>102.06 106.53</td></tr><tr><td>CP-Flow (aug)</td><td>4.45</td><td>100.82 105.17</td></tr></table>",
1074
+ "bbox": [
1075
+ 529,
1076
+ 138,
1077
+ 821,
1078
+ 255
1079
+ ],
1080
+ "page_idx": 8
1081
+ },
1082
+ {
1083
+ "type": "text",
1084
+ "text": "",
1085
+ "bbox": [
1086
+ 176,
1087
+ 310,
1088
+ 825,
1089
+ 352
1090
+ ],
1091
+ "page_idx": 8
1092
+ },
1093
+ {
1094
+ "type": "text",
1095
+ "text": "6 CONCLUSION ",
1096
+ "text_level": 1,
1097
+ "bbox": [
1098
+ 176,
1099
+ 371,
1100
+ 318,
1101
+ 388
1102
+ ],
1103
+ "page_idx": 8
1104
+ },
1105
+ {
1106
+ "type": "text",
1107
+ "text": "We propose a new parameterization of normalizing flows using the gradient map of a convex potential. We make connections to the optimal transport theory to show that the proposed flow is a universal density model, and leverage tools from convex optimization to enable efficient training and model inversion. Experimentally, we show that the proposed method works reasonably well when evaluated on standard benchmarks. ",
1108
+ "bbox": [
1109
+ 174,
1110
+ 404,
1111
+ 825,
1112
+ 473
1113
+ ],
1114
+ "page_idx": 8
1115
+ },
1116
+ {
1117
+ "type": "text",
1118
+ "text": "Furthermore, we demonstrate that the performance can be improved by designing better ICNN architectures. We leave the exploration for a better ICNN and convolutional ICNN architecture to improve density estimation and generative modeling for future research. ",
1119
+ "bbox": [
1120
+ 176,
1121
+ 481,
1122
+ 823,
1123
+ 522
1124
+ ],
1125
+ "page_idx": 8
1126
+ },
1127
+ {
1128
+ "type": "text",
1129
+ "text": "ACKNOWLEDGEMENTS ",
1130
+ "text_level": 1,
1131
+ "bbox": [
1132
+ 176,
1133
+ 544,
1134
+ 367,
1135
+ 559
1136
+ ],
1137
+ "page_idx": 8
1138
+ },
1139
+ {
1140
+ "type": "text",
1141
+ "text": "We would like to acknowledge the Python community (Van Rossum & Drake Jr, 1995; Oliphant, 2007) for developing the tools that enabled this work, including numpy (Oliphant, 2006; Van Der Walt et al., 2011; Walt et al., 2011; Harris et al., 2020), PyTorch (Paszke et al., 2019), Matplotlib (Hunter, 2007), seaborn (Waskom et al., 2018), pandas (McKinney, 2012), and SciPy (Jones et al., 2014). ",
1142
+ "bbox": [
1143
+ 174,
1144
+ 574,
1145
+ 825,
1146
+ 643
1147
+ ],
1148
+ "page_idx": 8
1149
+ },
1150
+ {
1151
+ "type": "text",
1152
+ "text": "REFERENCES ",
1153
+ "text_level": 1,
1154
+ "bbox": [
1155
+ 174,
1156
+ 666,
1157
+ 285,
1158
+ 680
1159
+ ],
1160
+ "page_idx": 8
1161
+ },
1162
+ {
1163
+ "type": "text",
1164
+ "text": "Ryan P Adams, Jeffrey Pennington, Matthew J Johnson, Jamie Smith, Yaniv Ovadia, Brian Patton, and James Saunderson. Estimating the spectral density of large implicit matrices. arXiv preprint arXiv:1802.03451, 2018. \nBrandon Amos, Lei Xu, and J Zico Kolter. Input convex neural networks. In International Conference on Machine Learning, pp. 146–155, 2017. \nAtılım Gunes Baydin, Barak A Pearlmutter, Alexey Andreyevich Radul, and Jeffrey Mark Siskind. ¨ Automatic differentiation in machine learning: a survey. The Journal of Machine Learning Research, 18(1):5595–5637, 2017. \nJens Behrmann, Will Grathwohl, Ricky T. Q. Chen, David Duvenaud, and Jorn-Henrik Jacobsen. ¨ Invertible residual networks. In International Conference on Machine Learning, pp. 573–582, 2019. \nJens Behrmann, Paul Vicol, Kuan-Chieh Wang, Roger Grosse, and Jorn-Henrik Jacobsen. Un- ¨ derstanding and mitigating exploding inverses in invertible neural networks. arXiv preprint arXiv:2006.09347, 2020. ",
1165
+ "bbox": [
1166
+ 169,
1167
+ 688,
1168
+ 825,
1169
+ 922
1170
+ ],
1171
+ "page_idx": 8
1172
+ },
1173
+ {
1174
+ "type": "text",
1175
+ "text": "Yann Brenier. Decomposition polaire et r ´ earrangement monotone des champs de vecteurs. ´ CR Acad. Sci. Paris Ser. I Math. ´ , 305:805–808, 1987. ",
1176
+ "bbox": [
1177
+ 173,
1178
+ 103,
1179
+ 823,
1180
+ 132
1181
+ ],
1182
+ "page_idx": 9
1183
+ },
1184
+ {
1185
+ "type": "text",
1186
+ "text": "Yann Brenier. Polar factorization and monotone rearrangement of vector-valued functions. Communications on pure and applied mathematics, 44(4):375–417, 1991. ",
1187
+ "bbox": [
1188
+ 173,
1189
+ 141,
1190
+ 823,
1191
+ 170
1192
+ ],
1193
+ "page_idx": 9
1194
+ },
1195
+ {
1196
+ "type": "text",
1197
+ "text": "Richard H Byrd, Peihuang Lu, Jorge Nocedal, and Ciyou Zhu. A limited memory algorithm for bound constrained optimization. SIAM Journal on scientific computing, 16(5):1190–1208, 1995. ",
1198
+ "bbox": [
1199
+ 173,
1200
+ 179,
1201
+ 823,
1202
+ 209
1203
+ ],
1204
+ "page_idx": 9
1205
+ },
1206
+ {
1207
+ "type": "text",
1208
+ "text": "Ricky T. Q. Chen, Yulia Rubanova, Jesse Bettencourt, and David K Duvenaud. Neural ordinary differential equations. In Advances in neural information processing systems, pp. 6571–6583, 2018. ",
1209
+ "bbox": [
1210
+ 174,
1211
+ 217,
1212
+ 823,
1213
+ 260
1214
+ ],
1215
+ "page_idx": 9
1216
+ },
1217
+ {
1218
+ "type": "text",
1219
+ "text": "Ricky T. Q. Chen, Jens Behrmann, David K Duvenaud, and Jorn-Henrik Jacobsen. Residual flows ¨ for invertible generative modeling. In Advances in Neural Information Processing Systems, pp. 9916–9926, 2019a. ",
1220
+ "bbox": [
1221
+ 173,
1222
+ 268,
1223
+ 825,
1224
+ 313
1225
+ ],
1226
+ "page_idx": 9
1227
+ },
1228
+ {
1229
+ "type": "text",
1230
+ "text": "Yize Chen, Yuanyuan Shi, and Baosen Zhang. Optimal control via neural networks: A convex approach. In International Conference on Learning Representations, 2019b. ",
1231
+ "bbox": [
1232
+ 174,
1233
+ 320,
1234
+ 821,
1235
+ 351
1236
+ ],
1237
+ "page_idx": 9
1238
+ },
1239
+ {
1240
+ "type": "text",
1241
+ "text": "Mircea Cimpoi, Subhransu Maji, Iasonas Kokkinos, Sammy Mohamed, and Andrea Vedaldi. Describing textures in the wild. In Conference on Computer Vision and Pattern Recognition, 2014. ",
1242
+ "bbox": [
1243
+ 173,
1244
+ 358,
1245
+ 820,
1246
+ 388
1247
+ ],
1248
+ "page_idx": 9
1249
+ },
1250
+ {
1251
+ "type": "text",
1252
+ "text": "Taco Cohen and Max Welling. Group equivariant convolutional networks. In International conference on machine learning, pp. 2990–2999, 2016. ",
1253
+ "bbox": [
1254
+ 173,
1255
+ 397,
1256
+ 823,
1257
+ 426
1258
+ ],
1259
+ "page_idx": 9
1260
+ },
1261
+ {
1262
+ "type": "text",
1263
+ "text": "George Cybenko. Approximation by superpositions of a sigmoidal function. Mathematics of control, signals and systems, 2(4):303–314, 1989. ",
1264
+ "bbox": [
1265
+ 174,
1266
+ 434,
1267
+ 823,
1268
+ 464
1269
+ ],
1270
+ "page_idx": 9
1271
+ },
1272
+ {
1273
+ "type": "text",
1274
+ "text": "Laurent Dinh, David Krueger, and Yoshua Bengio. Nice: Non-linear independent components estimation. arXiv preprint arXiv:1410.8516, 2014. ",
1275
+ "bbox": [
1276
+ 173,
1277
+ 473,
1278
+ 823,
1279
+ 502
1280
+ ],
1281
+ "page_idx": 9
1282
+ },
1283
+ {
1284
+ "type": "text",
1285
+ "text": "Laurent Dinh, Jascha Sohl-Dickstein, and Samy Bengio. Density estimation using real nvp. In International Conference on Learning Representations, 2017. ",
1286
+ "bbox": [
1287
+ 174,
1288
+ 511,
1289
+ 823,
1290
+ 541
1291
+ ],
1292
+ "page_idx": 9
1293
+ },
1294
+ {
1295
+ "type": "text",
1296
+ "text": "Vincent Dumoulin, Ethan Perez, Nathan Schucher, Florian Strub, Harm de Vries, Aaron Courville, and Yoshua Bengio. Feature-wise transformations. Distill, 3(7):e11, 2018. ",
1297
+ "bbox": [
1298
+ 174,
1299
+ 549,
1300
+ 823,
1301
+ 579
1302
+ ],
1303
+ "page_idx": 9
1304
+ },
1305
+ {
1306
+ "type": "text",
1307
+ "text": "Conor Durkan, Artur Bekasov, Iain Murray, and George Papamakarios. Neural spline flows. In Advances in Neural Information Processing Systems, pp. 7511–7522, 2019. ",
1308
+ "bbox": [
1309
+ 174,
1310
+ 587,
1311
+ 823,
1312
+ 617
1313
+ ],
1314
+ "page_idx": 9
1315
+ },
1316
+ {
1317
+ "type": "text",
1318
+ "text": "Chris Finlay, Augusto Gerolin, Adam M Oberman, and Aram-Alexandre Pooladian. Learning normalizing flows from entropy-kantorovich potentials. arXiv preprint arXiv:2006.06033, 2020a. ",
1319
+ "bbox": [
1320
+ 173,
1321
+ 625,
1322
+ 823,
1323
+ 655
1324
+ ],
1325
+ "page_idx": 9
1326
+ },
1327
+ {
1328
+ "type": "text",
1329
+ "text": "Chris Finlay, Jorn-Henrik Jacobsen, Levon Nurbekyan, and Adam M Oberman. How to train your ¨ neural ode: the world of jacobian and kinetic regularization. In International Conference on Machine Learning, 2020b. ",
1330
+ "bbox": [
1331
+ 176,
1332
+ 662,
1333
+ 825,
1334
+ 705
1335
+ ],
1336
+ "page_idx": 9
1337
+ },
1338
+ {
1339
+ "type": "text",
1340
+ "text": "Mathieu Germain, Karol Gregor, Iain Murray, and Hugo Larochelle. Made: Masked autoencoder for distribution estimation. In Proceedings of the 32nd International Conference on Machine Learning, volume 37 of Proceedings of Machine Learning Research, pp. 881–889. PMLR, 07–09 Jul 2015. ",
1341
+ "bbox": [
1342
+ 173,
1343
+ 714,
1344
+ 825,
1345
+ 771
1346
+ ],
1347
+ "page_idx": 9
1348
+ },
1349
+ {
1350
+ "type": "text",
1351
+ "text": "Ian Goodfellow, David Warde-Farley, Mehdi Mirza, Aaron Courville, and Yoshua Bengio. Maxout networks. In International conference on machine learning, pp. 1319–1327. PMLR, 2013. ",
1352
+ "bbox": [
1353
+ 169,
1354
+ 780,
1355
+ 823,
1356
+ 810
1357
+ ],
1358
+ "page_idx": 9
1359
+ },
1360
+ {
1361
+ "type": "text",
1362
+ "text": "Will Grathwohl, Ricky T. Q. Chen, Jesse Bettencourt, Ilya Sutskever, and David Duvenaud. Ffjord: Free-form continuous dynamics for scalable reversible generative models. In International Conference on Learning Representations, 2018. ",
1363
+ "bbox": [
1364
+ 174,
1365
+ 819,
1366
+ 821,
1367
+ 862
1368
+ ],
1369
+ "page_idx": 9
1370
+ },
1371
+ {
1372
+ "type": "text",
1373
+ "text": "David Ha, Andrew Dai, and Quoc V Le. Hypernetworks. arXiv preprint arXiv:1609.09106, 2016. ",
1374
+ "bbox": [
1375
+ 171,
1376
+ 871,
1377
+ 815,
1378
+ 887
1379
+ ],
1380
+ "page_idx": 9
1381
+ },
1382
+ {
1383
+ "type": "text",
1384
+ "text": "Insu Han, Haim Avron, and Jinwoo Shin. Stochastic chebyshev gradient descent for spectral optimization. In Advances in Neural Information Processing Systems, pp. 7386–7396, 2018. ",
1385
+ "bbox": [
1386
+ 174,
1387
+ 895,
1388
+ 820,
1389
+ 924
1390
+ ],
1391
+ "page_idx": 9
1392
+ },
1393
+ {
1394
+ "type": "text",
1395
+ "text": "Charles R Harris, K Jarrod Millman, Stefan J van der Walt, Ralf Gommers, Pauli Virtanen, David´ Cournapeau, Eric Wieser, Julian Taylor, Sebastian Berg, Nathaniel J Smith, et al. Array programming with numpy. Nature, 585(7825):357–362, 2020. ",
1396
+ "bbox": [
1397
+ 178,
1398
+ 103,
1399
+ 823,
1400
+ 146
1401
+ ],
1402
+ "page_idx": 10
1403
+ },
1404
+ {
1405
+ "type": "text",
1406
+ "text": "Chin-Wei Huang, David Krueger, Alexandre Lacoste, and Aaron Courville. Neural autoregressive flows. In International Conference on Machine Learning, pp. 2078–2087, 2018. ",
1407
+ "bbox": [
1408
+ 171,
1409
+ 155,
1410
+ 823,
1411
+ 185
1412
+ ],
1413
+ "page_idx": 10
1414
+ },
1415
+ {
1416
+ "type": "text",
1417
+ "text": "Chin-Wei Huang, Laurent Dinh, and Aaron Courville. Augmented normalizing flows: Bridging the gap between generative flows and latent variable models. arXiv preprint arXiv:2002.07101, 2020a. ",
1418
+ "bbox": [
1419
+ 174,
1420
+ 194,
1421
+ 823,
1422
+ 237
1423
+ ],
1424
+ "page_idx": 10
1425
+ },
1426
+ {
1427
+ "type": "text",
1428
+ "text": "Chin-Wei Huang, Laurent Dinh, and Aaron Courville. Solving ode with universal flows: Approximation theory for flow-based models. In ICLR 2020 Workshop on Integration of Deep Neural Models and Differential Equations, 2020b. ",
1429
+ "bbox": [
1430
+ 173,
1431
+ 246,
1432
+ 826,
1433
+ 290
1434
+ ],
1435
+ "page_idx": 10
1436
+ },
1437
+ {
1438
+ "type": "text",
1439
+ "text": "Gao Huang, Zhuang Liu, Laurens Van Der Maaten, and Kilian Q Weinberger. Densely connected convolutional networks. In Proceedings of the IEEE conference on computer vision and pattern recognition, pp. 4700–4708, 2017. ",
1440
+ "bbox": [
1441
+ 173,
1442
+ 297,
1443
+ 825,
1444
+ 342
1445
+ ],
1446
+ "page_idx": 10
1447
+ },
1448
+ {
1449
+ "type": "text",
1450
+ "text": "John D Hunter. Matplotlib: A 2d graphics environment. Computing in science & engineering, 9(3): 90, 2007. ",
1451
+ "bbox": [
1452
+ 171,
1453
+ 352,
1454
+ 823,
1455
+ 381
1456
+ ],
1457
+ "page_idx": 10
1458
+ },
1459
+ {
1460
+ "type": "text",
1461
+ "text": "Michael F Hutchinson. A stochastic estimator of the trace of the influence matrix for laplacian smoothing splines. Communications in Statistics-Simulation and Computation, 18(3):1059–1076, 1989. ",
1462
+ "bbox": [
1463
+ 176,
1464
+ 390,
1465
+ 825,
1466
+ 433
1467
+ ],
1468
+ "page_idx": 10
1469
+ },
1470
+ {
1471
+ "type": "text",
1472
+ "text": "Priyank Jaini, Kira A Selby, and Yaoliang Yu. Sum-of-squares polynomial flow. In International Conference on Machine Learning, pp. 3009–3018, 2019. ",
1473
+ "bbox": [
1474
+ 171,
1475
+ 443,
1476
+ 825,
1477
+ 472
1478
+ ],
1479
+ "page_idx": 10
1480
+ },
1481
+ {
1482
+ "type": "text",
1483
+ "text": "Eric Jones, Travis Oliphant, and Pearu Peterson. {SciPy}: Open source scientific tools for $\\{ { \\mathrm { P y t h o n } } \\}$ . 2014. ",
1484
+ "bbox": [
1485
+ 174,
1486
+ 481,
1487
+ 823,
1488
+ 511
1489
+ ],
1490
+ "page_idx": 10
1491
+ },
1492
+ {
1493
+ "type": "text",
1494
+ "text": "Diederik P Kingma and Max Welling. Auto-encoding variational bayes. arXiv preprint arXiv:1312.6114, 2013. ",
1495
+ "bbox": [
1496
+ 176,
1497
+ 520,
1498
+ 821,
1499
+ 549
1500
+ ],
1501
+ "page_idx": 10
1502
+ },
1503
+ {
1504
+ "type": "text",
1505
+ "text": "Durk P Kingma and Prafulla Dhariwal. Glow: Generative flow with invertible 1x1 convolutions. In Advances in neural information processing systems, pp. 10215–10224, 2018. ",
1506
+ "bbox": [
1507
+ 173,
1508
+ 558,
1509
+ 821,
1510
+ 588
1511
+ ],
1512
+ "page_idx": 10
1513
+ },
1514
+ {
1515
+ "type": "text",
1516
+ "text": "Durk P Kingma, Tim Salimans, Rafal Jozefowicz, Xi Chen, Ilya Sutskever, and Max Welling. Improved variational inference with inverse autoregressive flow. In Advances in neural information processing systems, pp. 4743–4751, 2016. ",
1517
+ "bbox": [
1518
+ 173,
1519
+ 597,
1520
+ 823,
1521
+ 640
1522
+ ],
1523
+ "page_idx": 10
1524
+ },
1525
+ {
1526
+ "type": "text",
1527
+ "text": "Zhifeng Kong and Kamalika Chaudhuri. The expressive power of a class of normalizing flow models. arXiv preprint arXiv:2006.00392, 2020. ",
1528
+ "bbox": [
1529
+ 173,
1530
+ 648,
1531
+ 821,
1532
+ 679
1533
+ ],
1534
+ "page_idx": 10
1535
+ },
1536
+ {
1537
+ "type": "text",
1538
+ "text": "Alexander Korotin, Vage Egiazarian, Arip Asadulaev, Alexander Safin, and Evgeny Burnaev. Wasserstein-2 generative networks. arXiv preprint arXiv:1909.13082, 2019. ",
1539
+ "bbox": [
1540
+ 174,
1541
+ 688,
1542
+ 821,
1543
+ 718
1544
+ ],
1545
+ "page_idx": 10
1546
+ },
1547
+ {
1548
+ "type": "text",
1549
+ "text": "Hongzhou Lin and Stefanie Jegelka. Resnet with one-neuron hidden layers is a universal approximator. In Advances in neural information processing systems, pp. 6169–6178, 2018. ",
1550
+ "bbox": [
1551
+ 171,
1552
+ 727,
1553
+ 821,
1554
+ 756
1555
+ ],
1556
+ "page_idx": 10
1557
+ },
1558
+ {
1559
+ "type": "text",
1560
+ "text": "Lin Lin, Yousef Saad, and Chao Yang. Approximating spectral densities of large matrices. SIAM review, 58(1):34–65, 2016. ",
1561
+ "bbox": [
1562
+ 171,
1563
+ 765,
1564
+ 825,
1565
+ 795
1566
+ ],
1567
+ "page_idx": 10
1568
+ },
1569
+ {
1570
+ "type": "text",
1571
+ "text": "Zhou Lu, Hongming Pu, Feicheng Wang, Zhiqiang Hu, and Liwei Wang. The expressive power of neural networks: A view from the width. In Advances in neural information processing systems, pp. 6231–6239, 2017. ",
1572
+ "bbox": [
1573
+ 173,
1574
+ 804,
1575
+ 825,
1576
+ 847
1577
+ ],
1578
+ "page_idx": 10
1579
+ },
1580
+ {
1581
+ "type": "text",
1582
+ "text": "Ashok Vardhan Makkuva, Amirhossein Taghvaei, Sewoong Oh, and Jason D Lee. Optimal transport mapping via input convex neural networks. arXiv preprint arXiv:1908.10962, 2019. ",
1583
+ "bbox": [
1584
+ 169,
1585
+ 856,
1586
+ 825,
1587
+ 886
1588
+ ],
1589
+ "page_idx": 10
1590
+ },
1591
+ {
1592
+ "type": "text",
1593
+ "text": "Wes McKinney. Python for data analysis: Data wrangling with Pandas, NumPy, and IPython. O’Reilly Media, Inc.”, 2012. ",
1594
+ "bbox": [
1595
+ 174,
1596
+ 895,
1597
+ 821,
1598
+ 924
1599
+ ],
1600
+ "page_idx": 10
1601
+ },
1602
+ {
1603
+ "type": "text",
1604
+ "text": "Takeru Miyato, Toshiki Kataoka, Masanori Koyama, and Yuichi Yoshida. Spectral normalization for generative adversarial networks. arXiv preprint arXiv:1802.05957, 2018. ",
1605
+ "bbox": [
1606
+ 171,
1607
+ 103,
1608
+ 823,
1609
+ 133
1610
+ ],
1611
+ "page_idx": 11
1612
+ },
1613
+ {
1614
+ "type": "text",
1615
+ "text": "Thomas Muller, Brian McWilliams, Fabrice Rousselle, Markus Gross, and Jan Nov ¨ ak. Neural im- ´ portance sampling. ACM Transactions on Graphics (TOG), 38(5):1–19, 2019. ",
1616
+ "bbox": [
1617
+ 171,
1618
+ 142,
1619
+ 823,
1620
+ 171
1621
+ ],
1622
+ "page_idx": 11
1623
+ },
1624
+ {
1625
+ "type": "text",
1626
+ "text": "Yurii Nesterov. Introductory lectures on convex programming volume i: Basic course. Lecture notes, 3(4):5, 1998. ",
1627
+ "bbox": [
1628
+ 176,
1629
+ 181,
1630
+ 821,
1631
+ 212
1632
+ ],
1633
+ "page_idx": 11
1634
+ },
1635
+ {
1636
+ "type": "text",
1637
+ "text": "Yuval Netzer, Tao Wang, Adam Coates, Alessandro Bissacco, Bo Wu, and Andrew Y Ng. Reading digits in natural images with unsupervised feature learning. 2011. ",
1638
+ "bbox": [
1639
+ 174,
1640
+ 222,
1641
+ 823,
1642
+ 251
1643
+ ],
1644
+ "page_idx": 11
1645
+ },
1646
+ {
1647
+ "type": "text",
1648
+ "text": "Jorge Nocedal and Stephen Wright. Numerical optimization. Springer Science & Business Media, 2006. ",
1649
+ "bbox": [
1650
+ 173,
1651
+ 261,
1652
+ 821,
1653
+ 290
1654
+ ],
1655
+ "page_idx": 11
1656
+ },
1657
+ {
1658
+ "type": "text",
1659
+ "text": "Travis E Oliphant. A guide to NumPy, volume 1. Trelgol Publishing USA, 2006. ",
1660
+ "bbox": [
1661
+ 173,
1662
+ 300,
1663
+ 702,
1664
+ 316
1665
+ ],
1666
+ "page_idx": 11
1667
+ },
1668
+ {
1669
+ "type": "text",
1670
+ "text": "Travis E Oliphant. Python for scientific computing. Computing in Science & Engineering, 9(3): 10–20, 2007. ",
1671
+ "bbox": [
1672
+ 171,
1673
+ 325,
1674
+ 825,
1675
+ 356
1676
+ ],
1677
+ "page_idx": 11
1678
+ },
1679
+ {
1680
+ "type": "text",
1681
+ "text": "Junier Oliva, Avinava Dubey, Manzil Zaheer, Barnabas Poczos, Ruslan Salakhutdinov, Eric Xing, and Jeff Schneider. Transformation autoregressive networks. In Proceedings of the 35th International Conference on Machine Learning, volume 80 of Proceedings of Machine Learning Research, pp. 3898–3907. PMLR, 10–15 Jul 2018. ",
1682
+ "bbox": [
1683
+ 173,
1684
+ 366,
1685
+ 825,
1686
+ 422
1687
+ ],
1688
+ "page_idx": 11
1689
+ },
1690
+ {
1691
+ "type": "text",
1692
+ "text": "Derek Onken, Samy Wu Fung, Xingjian Li, and Lars Ruthotto. Ot-flow: Fast and accurate continuous normalizing flows via optimal transport. arXiv preprint arXiv:2006.00104, 2020. ",
1693
+ "bbox": [
1694
+ 173,
1695
+ 433,
1696
+ 821,
1697
+ 463
1698
+ ],
1699
+ "page_idx": 11
1700
+ },
1701
+ {
1702
+ "type": "text",
1703
+ "text": "George Papamakarios, Theo Pavlakou, and Iain Murray. Masked autoregressive flow for density estimation. In Advances in Neural Information Processing Systems, pp. 2338–2347, 2017. ",
1704
+ "bbox": [
1705
+ 173,
1706
+ 472,
1707
+ 823,
1708
+ 502
1709
+ ],
1710
+ "page_idx": 11
1711
+ },
1712
+ {
1713
+ "type": "text",
1714
+ "text": "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, highperformance deep learning library. In Advances in neural information processing systems, pp. 8026–8037, 2019. ",
1715
+ "bbox": [
1716
+ 174,
1717
+ 511,
1718
+ 825,
1719
+ 568
1720
+ ],
1721
+ "page_idx": 11
1722
+ },
1723
+ {
1724
+ "type": "text",
1725
+ "text": "Danilo Rezende and Shakir Mohamed. Variational inference with normalizing flows. In International Conference on Machine Learning, pp. 1530–1538, 2015. ",
1726
+ "bbox": [
1727
+ 171,
1728
+ 579,
1729
+ 823,
1730
+ 608
1731
+ ],
1732
+ "page_idx": 11
1733
+ },
1734
+ {
1735
+ "type": "text",
1736
+ "text": "R Tyrrell Rockafellar. Convex analysis. Number 28. Princeton university press, 1970. ",
1737
+ "bbox": [
1738
+ 176,
1739
+ 618,
1740
+ 735,
1741
+ 635
1742
+ ],
1743
+ "page_idx": 11
1744
+ },
1745
+ {
1746
+ "type": "text",
1747
+ "text": "Ludger Ruschendorf and Svetlozar T Rachev. A characterization of random variables with minimum ¨ l2-distance. Journal of multivariate analysis, 32(1):48–54, 1990. ",
1748
+ "bbox": [
1749
+ 173,
1750
+ 643,
1751
+ 821,
1752
+ 674
1753
+ ],
1754
+ "page_idx": 11
1755
+ },
1756
+ {
1757
+ "type": "text",
1758
+ "text": "Filippo Santambrogio. Optimal transport for applied mathematicians. Birkauser, NY ¨ , 55(58-63):94, 2015. ",
1759
+ "bbox": [
1760
+ 173,
1761
+ 683,
1762
+ 823,
1763
+ 713
1764
+ ],
1765
+ "page_idx": 11
1766
+ },
1767
+ {
1768
+ "type": "text",
1769
+ "text": "Matthias Seeger, Asmus Hetzel, Zhenwen Dai, Eric Meissner, and Neil D Lawrence. Autodifferentiating linear algebra. arXiv preprint arXiv:1710.08717, 2017. ",
1770
+ "bbox": [
1771
+ 173,
1772
+ 723,
1773
+ 823,
1774
+ 752
1775
+ ],
1776
+ "page_idx": 11
1777
+ },
1778
+ {
1779
+ "type": "text",
1780
+ "text": "Vivien Seguy, Bharath Bhushan Damodaran, Remi Flamary, Nicolas Courty, Antoine Rolet, and Mathieu Blondel. Large scale optimal transport and mapping estimation. In International Conference on Learning Representations, 2018. ",
1781
+ "bbox": [
1782
+ 174,
1783
+ 762,
1784
+ 825,
1785
+ 806
1786
+ ],
1787
+ "page_idx": 11
1788
+ },
1789
+ {
1790
+ "type": "text",
1791
+ "text": "RN Silver and H Roder. Densities of states of mega-dimensional hamiltonian matrices. ¨ International Journal of Modern Physics C, 5(04):735–753, 1994. ",
1792
+ "bbox": [
1793
+ 171,
1794
+ 815,
1795
+ 823,
1796
+ 845
1797
+ ],
1798
+ "page_idx": 11
1799
+ },
1800
+ {
1801
+ "type": "text",
1802
+ "text": "Amirhossein Taghvaei and Amin Jalali. 2-wasserstein approximation via restricted convex potentials with application to improved training for gans. arXiv preprint arXiv:1902.07197, 2019. ",
1803
+ "bbox": [
1804
+ 171,
1805
+ 856,
1806
+ 823,
1807
+ 885
1808
+ ],
1809
+ "page_idx": 11
1810
+ },
1811
+ {
1812
+ "type": "text",
1813
+ "text": "Hillel Tal-Ezer and Ronnie Kosloff. An accurate and efficient scheme for propagating the time dependent schrodinger equation. ¨ The Journal of chemical physics, 81(9):3967–3971, 1984. ",
1814
+ "bbox": [
1815
+ 174,
1816
+ 895,
1817
+ 821,
1818
+ 924
1819
+ ],
1820
+ "page_idx": 11
1821
+ },
1822
+ {
1823
+ "type": "text",
1824
+ "text": "Takeshi Teshima, Isao Ishikawa, Koichi Tojo, Kenta Oono, Masahiro Ikeda, and Masashi Sugiyama. Coupling-based invertible neural networks are universal diffeomorphism approximators. arXiv preprint arXiv:2006.11469, 2020. ",
1825
+ "bbox": [
1826
+ 176,
1827
+ 103,
1828
+ 823,
1829
+ 146
1830
+ ],
1831
+ "page_idx": 12
1832
+ },
1833
+ {
1834
+ "type": "text",
1835
+ "text": "Shashanka Ubaru, Jie Chen, and Yousef Saad. Fast estimation of tr(f(A)) via Stochastic Lanczos Quadrature. SIAM Journal on Matrix Analysis and Applications, 38(4):1075–1099, 2017. ",
1836
+ "bbox": [
1837
+ 173,
1838
+ 155,
1839
+ 823,
1840
+ 184
1841
+ ],
1842
+ "page_idx": 12
1843
+ },
1844
+ {
1845
+ "type": "text",
1846
+ "text": "Rianne Van Den Berg, Leonard Hasenclever, Jakub M Tomczak, and Max Welling. Sylvester normalizing flows for variational inference. In 34th Conference on Uncertainty in Artificial Intelligence 2018, UAI 2018, pp. 393–402. Association For Uncertainty in Artificial Intelligence (AUAI), 2018. ",
1847
+ "bbox": [
1848
+ 173,
1849
+ 193,
1850
+ 825,
1851
+ 250
1852
+ ],
1853
+ "page_idx": 12
1854
+ },
1855
+ {
1856
+ "type": "text",
1857
+ "text": "Stefan Van Der Walt, S Chris Colbert, and Gael Varoquaux. The numpy array: a structure for efficient numerical computation. Computing in Science & Engineering, 13(2):22, 2011. ",
1858
+ "bbox": [
1859
+ 173,
1860
+ 257,
1861
+ 821,
1862
+ 287
1863
+ ],
1864
+ "page_idx": 12
1865
+ },
1866
+ {
1867
+ "type": "text",
1868
+ "text": "Guido Van Rossum and Fred L Drake Jr. Python reference manual. Centrum voor Wiskunde en Informatica Amsterdam, 1995. ",
1869
+ "bbox": [
1870
+ 174,
1871
+ 295,
1872
+ 823,
1873
+ 324
1874
+ ],
1875
+ "page_idx": 12
1876
+ },
1877
+ {
1878
+ "type": "text",
1879
+ "text": "Cedric Villani. ´ Optimal transport: old and new, volume 338. Springer Science & Business Media, 2008. ",
1880
+ "bbox": [
1881
+ 174,
1882
+ 333,
1883
+ 823,
1884
+ 363
1885
+ ],
1886
+ "page_idx": 12
1887
+ },
1888
+ {
1889
+ "type": "text",
1890
+ "text": "Stefan van der Walt, S Chris Colbert, and Gael Varoquaux. The numpy array: a structure for efficient ´ numerical computation. Computing in science & engineering, 13(2):22–30, 2011. ",
1891
+ "bbox": [
1892
+ 173,
1893
+ 371,
1894
+ 820,
1895
+ 400
1896
+ ],
1897
+ "page_idx": 12
1898
+ },
1899
+ {
1900
+ "type": "text",
1901
+ "text": "Michael Waskom, Olga Botvinnik, Drew O’Kane, Paul Hobson, Joel Ostblom, Saulius Lukauskas, David C Gemperline, Tom Augspurger, Yaroslav Halchenko, John B. Cole, Jordi Warmenhoven, Julian de Ruiter, Cameron Pye, Stephan Hoyer, Jake Vanderplas, Santi Villalba, Gero Kunter, Eric Quintero, Pete Bachant, Marcel Martin, Kyle Meyer, Alistair Miles, Yoav Ram, Thomas Brunner, Tal Yarkoni, Mike Lee Williams, Constantine Evans, Clark Fitzgerald, Brian, and Adel Qalieh. mwaskom/seaborn: v0.9.0 (july 2018), July 2018. URL https://doi.org/10. 5281/zenodo.1313201. ",
1902
+ "bbox": [
1903
+ 174,
1904
+ 409,
1905
+ 825,
1906
+ 507
1907
+ ],
1908
+ "page_idx": 12
1909
+ },
1910
+ {
1911
+ "type": "text",
1912
+ "text": "Antoine Wehenkel and Gilles Louppe. Unconstrained monotonic neural networks. In Advances in Neural Information Processing Systems, pp. 1545–1555, 2019. ",
1913
+ "bbox": [
1914
+ 171,
1915
+ 516,
1916
+ 823,
1917
+ 545
1918
+ ],
1919
+ "page_idx": 12
1920
+ },
1921
+ {
1922
+ "type": "text",
1923
+ "text": "Liu Yang and George Em Karniadakis. Potential flow generator with $l _ { 2 }$ optimal transport regularity for generative models. arXiv preprint arXiv:1908.11462, 2019. ",
1924
+ "bbox": [
1925
+ 171,
1926
+ 554,
1927
+ 823,
1928
+ 583
1929
+ ],
1930
+ "page_idx": 12
1931
+ },
1932
+ {
1933
+ "type": "text",
1934
+ "text": "Manzil Zaheer, Satwik Kottur, Siamak Ravanbakhsh, Barnabas Poczos, Russ R Salakhutdinov, and Alexander J Smola. Deep sets. In Advances in neural information processing systems, pp. 3391– 3401, 2017. ",
1935
+ "bbox": [
1936
+ 173,
1937
+ 592,
1938
+ 825,
1939
+ 635
1940
+ ],
1941
+ "page_idx": 12
1942
+ },
1943
+ {
1944
+ "type": "text",
1945
+ "text": "Linfeng Zhang, Lei Wang, et al. Monge-ampere flow for generative modeling. \\` arXiv preprint arXiv:1809.10188, 2018. ",
1946
+ "bbox": [
1947
+ 169,
1948
+ 642,
1949
+ 825,
1950
+ 672
1951
+ ],
1952
+ "page_idx": 12
1953
+ },
1954
+ {
1955
+ "type": "text",
1956
+ "text": "Bolei Zhou, Agata Lapedriza, Aditya Khosla, Aude Oliva, and Antonio Torralba. Places: A 10 million image database for scene recognition. IEEE Transactions on Pattern Analysis and Machine Intelligence, 2017. ",
1957
+ "bbox": [
1958
+ 174,
1959
+ 680,
1960
+ 825,
1961
+ 723
1962
+ ],
1963
+ "page_idx": 12
1964
+ }
1965
+ ]
parse/train/te7PVH1sPxJ/te7PVH1sPxJ_middle.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/te7PVH1sPxJ/te7PVH1sPxJ_model.json ADDED
The diff for this file is too large to render. See raw diff