ZHANGYUXUAN-zR commited on
Commit
f4e0ed3
·
verified ·
1 Parent(s): 4589634

Add files using upload-large-folder tool

Browse files
parse/train/Byx93sC9tm/Byx93sC9tm.md ADDED
@@ -0,0 +1,264 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # DEEP ENSEMBLE BAYESIAN ACTIVE LEARNING : ADRESSING THE MODE COLLAPSE ISSUE IN MONTE CARLO DROPOUT VIA ENSEMBLES
2
+
3
+ Anonymous authors Paper under double-blind review
4
+
5
+ # ABSTRACT
6
+
7
+ In image classification tasks, the ability of deep convolutional neural networks (CNNs) to deal with complex image data has proved to be unrivalled. Deep CNNs, however, require large amounts of labeled training data to reach their full potential. In specialized domains such as healthcare, labeled data can be difficult and expensive to obtain. One way to alleviate this problem is to rely on active learning, a learning technique that aims to reduce the amount of labelled data needed for a specific task while still delivering satisfactory performance. We propose a new active learning strategy designed for deep neural networks. This method improves upon the current state-of-the-art deep Bayesian active learning method, which suffers from the mode collapse problem. We correct for this deficiency by making use of the expressive power and statistical properties of model ensembles. Our proposed method manages to capture superior data uncertainty, which translates into improved classification performance. We demonstrate empirically that our ensemble method yields faster convergence of CNNs trained on the MNIST and CIFAR-10 datasets.
8
+
9
+ # 1 INTRODUCTION
10
+
11
+ The success of deep learning in the last decade has been attributed to more computational power, better algorithms and larger datasets. In object classification tasks, CNNs widely outperform alternative methods in benchmark datasets (LeCun et al., 2015) and have been used in medical imaging for critical situations such as skin cancer detection (Haenssle et al., 2018), retinal disease detection (De Fauw et al., 2018) or even brain tumour survival prediction (Lao et al., 2017).
12
+
13
+ Although their performance is unrivalled, their success strongly depends on huge amounts of annotated data (Bengio et al., 2007; Krizhevsky et al., 2012). In specialized domains such as medicine or chemistry, expert labelled data is costly and time consuming to acquire (Hoi et al., 2006; Smith et al., 2018). Active Learning (AL) provides a theoretically sound framework (Cohn et al., 1996) that reduces the amount of labelled data needed for a specific task. Developed as an iterative process, AL progressively adds unlabelled data points to the training set using an acquisition function, ranking them in order of importance to maximize performance.
14
+
15
+ Using Active Learning within a Deep Learning framework (DAL) has recently seen successful applications in text classification (Zhang et al., 2017; Shen et al., 2017), visual question answering (Lin & Parikh, 2017) and image classification with CNNs (Gal et al., 2017; Sener & Savarese, 2017; Beluch et al., 2018). One key difference between DAL and classical AL is the sampling in batches, which is needed to keep computational costs low. As such, developing scalable DAL methods for CNNs presents challenging problems. Firstly, acquisitions functions do not scale well for high dimensional data or parameter spaces, due to the cost of estimating uncertainty measures, which is the main approach. Secondly, even with scalability not being an issue, one needs to obtain good uncertainty estimates in order to avoid having overconfident predictions. One of the most promising techniques is Deep Bayesian Active Learning (DBAL) (Gal, 2016; Gal & Ghahramani, 2016), which uses Monte-Carlo dropout (MC-dropout) as a Bayesian framework to obtain uncertainty estimates. However, as mentioned in Ducoffe & Precioso (2018), uncertainty-based methods can be fooled by adversarial examples, where small perturbations in inputs can result in overconfident and surprising outputs. Another approach presented by Beluch et al. (2018) uses ensemble models to obtain better uncertainty estimates than DBAL methods, although there are no result on how it deals with adversarial perturbations. Whereas uncertainty-based methods aim to pick data points the model is most uncertain about, density-based approaches try to identify the samples that are most representative of the entire unlabelled set, albeit at a computational cost (Sener & Savarese, 2017). Hybrid methods aim to trade uncertainty for representativeness. Our belief is that overconfident predictions for DBAL methods are an outcome of the mode collapse phenomenon in variational inference methods (Srivastava et al., 2017), and that by combining the expressive power of ensemble methods with MC-dropout we can obtain ”better” uncertainties without trading representativeness.
16
+
17
+ In this paper we provide evidence for the mode collapse phenomenon in the form of a highly imbalanced training set acquired during AL with MC-dropout, and show that ’preferential’ behaviour is not beneficial for the AL process. Furthermore, we link the mode collapse phenomenon to overconfident classifications. We compare the use of ensemble models to MC-Dropout for uncertainty estimation and give intuitive reasons why combining the two might perform better. We present Deep Ensemble Bayesian Active Learning (DEBAL) which confirms our intuition for experiments on MNIST and CIFAR-10.
18
+
19
+ In Section 2 we give an overview of current popular methods for DAL. In Section 3, various acquisition functions are introduced and the mode collapse issue is empirically identified. Further on, the use of model ensembles is motivated before presenting our method DEBAL. The last part of section 3 is devoted to understanding the cause of the observed improvements in performance.
20
+
21
+ # 2 BACKGROUND
22
+
23
+ The area of active learning has been studied extensively before (see Settles (2012) for a comprehensive review), but with the emergence of deep learning, it has seen widespread interest. As proved by Dasgupta (2005) there is no good universal AL strategy, researchers instead relying on heuristics tailored for their particular tasks.
24
+
25
+ Uncertainty-based Methods. We identify uncertainty-based methods as being the main ones used by the image classification community. Deep Bayesian Active Learning (Gal et al., 2017) models a Gaussian prior over the CNNs weights and uses variational inference techniques to obtain a posterior distribution over the network’s predictions, using these samples as a measure of uncertainty and as input to the acquisition function of the AL process. In practice, posterior samples are obtained using Monte-Carlo dropout (MC-dropout)(Srivastava et al., 2014), a computationally inexpensive and powerful stochastic regularization technique that performs well on real-world datasets (Leibig et al., 2017; Kendall et al., 2015) and has been shown to be equivalent to performing variational inference (Gal & Ghahramani, 2016). However, these approximating methods suffer from mode collapse, as evidenced in Blei et al. (2017). Another method, Cost-Effective Active Learning (CEAL) (Wang et al., 2016), uses the entropy of the network’s outputs to quantify uncertainty, with additional pseudo-labelling. This can be seen as the deterministic counterpart of DBAL, that adds highly confident samples directly from predictions, without the query process. Kading et al. (2016) ¨ propose a method on the expected model output change principle. This method approximates the expected reduction in the model’s error to avoid selecting redundant queries, albeit at a computational cost. Lastly, as this work was being developed, we found the work of Beluch et al. (2018), who propose to use deterministic ensemble models to obtain uncertainty approximations. Their method scores high both in terms of performance and robustness.
26
+
27
+ Density-based Methods & Hybrid Methods. Sener & Savarese (2017) looked at the data selection process from a set theory approach (core set) and showed their heuristic-free method outperforms existing uncertainty-based ones. Their acquisition function uses the geometry in the data-space to select the most informative samples. The main idea is to try to find a diverse subset of the entire input data space that best represents it. Although achieving promising results, the core set approach is computationally expensive as it requires solving a mixed integer programming optimisation problem. Ducoffe & Precioso (2018), on the other hand, rely on adversarial perturbation to select unlabeled samples. Their approach can be seen as margin based active learning, whereby distances to decision boundaries are approximated by distances to adversarial examples. To the best of our knowledge, the only hybrid method (combining measures of both uncertainty and representativeness) tested within a CNN-based DAL framework is the one proposed in Wang & Ye (2015).
28
+
29
+ Although originally not tested on CNNs, this method was shown to perform worse than the core set approach in Sener & Savarese (2017).
30
+
31
+ Deep Bayesian Active Learning. Given the set of inputs $\mathbb { X } = \{ \pmb { x } _ { 1 } , . . , \pmb { x } _ { n } \}$ and outputs $\mathbb { Y } =$ $\{ y _ { 1 } , . . , y _ { n } \}$ belonging to classes $c$ , one can define a probabilistic neural network by defining a model $f ( \pmb { x } ; \pmb { \theta } )$ with a prior $p ( \pmb \theta )$ over the parameter space $\pmb \theta$ , usually Gaussian, and a likelihood $p ( y =$ $c | \boldsymbol { x } , \boldsymbol { \theta } )$ which is usually given by softmax $\left( f ( \pmb { x } ; \pmb { \theta } ) \right)$ . The goal is to obtain the posterior distribution over $\pmb \theta$ :
32
+
33
+ $$
34
+ p ( \pmb \theta | \mathbb { X } , \mathbb { Y } ) = \frac { p ( \mathbb { Y } | \mathbb { X } , \pmb \theta ) p ( \pmb \theta ) } { p ( \mathbb { Y } | \mathbb { X } ) }
35
+ $$
36
+
37
+ One can make predictions $y ^ { * }$ about new data points $\pmb { x } ^ { * }$ by taking a weighted average of the forecasts obtained using all possible values of the parameters $\pmb \theta$ , weighted by the posterior probability of each parameter:
38
+
39
+ $$
40
+ p ( y ^ { * } | \mathbf { x } ^ { * } , \mathbb { X } , \mathbb { Y } ) = \int p ( y ^ { * } | x , \pmb { \theta } ) p ( \pmb { \theta } | \mathbb { X } , \mathbb { Y } ) d \pmb { \theta } = \mathbb { E } _ { \pmb { \theta } \sim p ( \pmb { \theta } | \mathbb { X } , \mathbb { Y } ) } [ f ( \mathbf { x } ; \pmb { \theta } ) ]
41
+ $$
42
+
43
+ The real difficulty arises when trying to compute these expectations, as has been previously covered in the literature (Neal, 2012; Hinton & Van Camp, 1993; Barber & Bishop, 1998; Lawrence, 2001). One way to circumvent this issue is to use Monte Carlo (MC) techniques (Hoffman et al., 2013; Paisley et al., 2012; Kingma & Welling, 2013), which approximate the exact expectations using averages over finite independent samples from the posterior predictive distribution (Robert & Casella, 2013). The MC-Dropout technique (Srivastava et al., 2014) will replace $p ( \pmb { \theta } | \mathbb { X } , \mathbb { Y } )$ with the dropout distribution $\hat { q } ( \pmb \theta )$ . This method scales well to high dimensional data, it is highly flexible to accommodate complex models and it is extremely applicable to existing neural network architectures, as well as easy to use.
44
+
45
+ In DBAL (Gal, 2016), the authors incorporate Bayesian uncertainty via MC-dropout and use acquisition functions that originate from information theory to try and capture two types of uncertainty: epistemic and aleatoric (Smith & Gal, 2018; Depeweg et al., 2017). Epistemic uncertainty is a consequence of insufficient learning of model parameters due to lack of data, leading to broad posteriors. On the other hand, aleatoric uncertainty arises due to the genuine stochasticity in the data (noise) and always leads to predictions with high uncertainty. We briefly describe the three main types of acquisition functions:
46
+
47
+ • MaxEntropy (Shannon, 2001). The higher the entropy of the predictive distribution, the more uncertain the model is:
48
+
49
+ $$
50
+ H [ y | \mathbf { x } , \pmb { \theta } ] = - \sum _ { c } p ( y = c | \pmb { x } , \pmb { \theta } ) \mathrm { l o g } p ( y = c | \pmb { x } , \pmb { \theta } )
51
+ $$
52
+
53
+ • Bayesian Active Learning by Disagreement $( B A L D )$ ) (Houlsby et al., 2011). Based on the mutual information between the input data and posterior, and quantifies the information gain about the model parameters if the correct label would be provided.
54
+
55
+ $$
56
+ I ( y , \pmb \theta | \pmb x , \pmb \theta ) = H [ y | \pmb x ; \mathbb { X } , \mathbb { Y } ] - \mathbb { E } _ { \pmb \theta \sim p ( \pmb \theta | \mathbb { X } , \mathbb { Y } ) } \Big [ H [ \pmb y | \pmb x , \pmb \theta ] \Big ]
57
+ $$
58
+
59
+ • Variation Ratio (Freeman, 1965). Measures the statistical dispersion of a categorical variable, with larger values indicating higher uncertainty:
60
+
61
+ $$
62
+ \mathrm { V a r R a t i o } ( { \pmb x } ) = 1 - \operatorname* { m a x } _ { \pmb y } p ( { \pmb y } | { \pmb x } , { \pmb \theta } )
63
+ $$
64
+
65
+ As seen in Gal (2016), for the above deterministic acquisition functions we can write the stochastic versions using the Bayesian MC-Dropout framework, where the class conditional probability $p ( y | \mathbf { \boldsymbol { x } } , \mathbf { \boldsymbol { \theta } } )$ can be approximated by the average over the MC-Dropout forward passes. The stochastic predictive entropy becomes:
66
+
67
+ $$
68
+ H [ y | x , \theta ] = - \sum _ { c } { \Big ( } { \frac { 1 } { K } } \sum _ { k } p ( y = c | { \pmb x } , \theta _ { k } ) { \Big ) } \mathrm { l o g } { \Big ( } { \frac { 1 } { K } } \sum _ { k } p ( y = c | { \pmb x } , \theta _ { k } ) { \Big ) }
69
+ $$
70
+
71
+ K corresponds to the total number of MC-Dropout forward passes at test time. Equivalent stochastic versions can be obtained for all other acquisition functions.
72
+
73
+ Table 1: Experiment settings for MNIST and CIFAR-10
74
+
75
+ <table><tr><td>Dataset</td><td>Model</td><td>Training epochs</td><td>Data size pool/val/test</td><td>Acquisition size</td></tr><tr><td></td><td></td><td></td><td></td><td></td></tr><tr><td>MNIST</td><td>2-Conv</td><td>500</td><td>59,780 /200 /10.000</td><td>20 +10—&gt;1,000</td></tr><tr><td>CIFAR-10</td><td>4-Conv</td><td>500</td><td>47,800/2000/10.000</td><td>200 +100—&gt;10,000</td></tr></table>
76
+
77
+ # 3 DEBAL: DEEP ENSEMBLE BAYESIAN ACTIVE LEARNING
78
+
79
+ # 3.1 EXPERIMENTAL DETAILS
80
+
81
+ We consider the multiclass image classification task on two well-studied datasets: MNIST (LeCun, 1998) and CIFAR-10 (Krizhevsky & Hinton, 2009). Table 1 contains a summary of the results, with the acquisition size containing the initial training set with the batch size for one iteration up to the maximum number of points acquired. At each acquisition step, a fixed sample set from the unlabelled pool is added to the initial balanced labelled data set and models are re-trained from the entire training set. We evaluate the model on the dataset’s standard test set. The CNN model architecture is the same as in the Keras CNN implementation for MNIST and CIFAR-10 (Chollet et al., 2015). We use Glorot initialization for weights, Adam optimizer and early stopping with patience of 15 epochs, for a maximum of 500 epochs. We select the best performing model during the patience duration. We use MC-Dropout with $K = 1 0 0$ forward passes for the stochastic acquisition functions. In all experiments results are averaged over three repetitions. For the ensemble models discussed later, each ensemble consists of $M = 3$ networks of identical architecture but different random initializations.
82
+
83
+ # 3.2 EVIDENCE OF MODE COLLAPSE IN DBAL
84
+
85
+ Our experimental results confirmed the performance of Gal (2016) using MC-dropout. However, we observe a lack of diversity in the data acquired during the AL process. This effect is more extreme in the initial phase, which is an important factor when dealing with a small dataset classification problem (see Figure 1).
86
+
87
+ ![](images/3c738152d4ef6d9c19fdd595e4abb7ad09d30e2fc93123094421b1273088c4a7.jpg)
88
+ Figure 1: MNIST histograms of true labels in the training set. Top: End of AL process. Total number of images in training set: 1,000. Bottom: After first 8 acquisition iterations. Total number of images in training set: 100.
89
+
90
+ One can argue that the preferential behaviour observed is a desirable one and is arising from the fact that images belonging to some specific classes are more uncertain and difficult to classify, due to resemblance of data from other classes. To debunk this hypothesis, we trained a model with the same architecture on the entire 60,000 sample training set available and used this model to rank the uncertainty for each sample from the 10,000 samples test set. As can be seen in Appendix Figure 7, over-represented class labels during the AL experiment do not have high uncertainty. To assess positive effects of over-sampling, we evaluated how easy models at the end of AL process classified them and observed no such effect (Appendix Figure 8).
91
+
92
+ ![](images/8427446c91ace661fe6f7fd8c754f4024f3591464dc2f8599b435cfffd7bc95d.jpg)
93
+ Figure 2: MNIST uncertainty visualization in VAE space at the end of the AL process for all measures. Colours represent different classes. Low uncertainty: black, High uncertainty: white.
94
+
95
+ Smith & Gal (2018) argue that the MC-Dropout technique suffers from over-confident predictions. They are particularly concerned with the interpolation behaviour of the uncertainty methods across unknown regions (regions of the input space not seen during the model training phase). We performed a similar analysis in order to gain understanding into how these methods behave. Following their experimental setting, we use a VAE (Kingma & Welling, 2013) to project the MNIST dataset into a 2-dimensional latent space. Figure 2 allows us to visualize the encodings and decode points from latent space to image space, together with their associated measures of uncertainty. The large black regions behind the data suggest that the model is unrealistically over-confident about data that does not resemble anything seen during training, thus providing further evidence supporting MC-Dropouts main deficiency: mode-collapse.
96
+
97
+ # .3 DEEP ENSEMBLES: A RECIPE FOR USEFUL UNCERTAINTY ESTIMATIO
98
+
99
+ We hypothesize that one of DBALs main deficiencies is its inability to capture the full posterior distribution of the data (mode collapse). This can prevent the model from learning in an optimal way, leading to unsatisfactory performance when classifying previously unseen images. As suggested in Smith & Gal (2018) and Lakshminarayanan et al. (2017), one intuitive fix would be to replace the single MC-Dropout model in the AL process with an ensemble of MC-Dropout models, with each member of the ensemble using a different initialization. Since one MC-Dropout model collapses around a subspace (one, or a few local modes) of the posterior distribution, a collection of such models, starting from different initial configurations, will end up covering different (and somehow overlapping) sub-regions of the probability density space. However, one key assumption here, is that each model member of the ensemble will end up capturing the behaviour around a different local mode. Beluch et al. (2018) test this idea in a deterministic setting, where the uncertainty resulting from the use of a deterministic ensemble proved to be more useful for the active learner than the uncertainty provided from a single MC-Dropout network.
100
+
101
+ We propose DEBAL, a stochastic ensemble of $M$ MC-Dropout models, with $M \ < < \ K$ . Each member of the ensemble is characterized by a different set of weights $\pmb { \theta } _ { m }$ . We use the randomizationbased approach to ensembles (Breiman, 1996), where each member of the ensemble is trained in parallel without any interaction with the other members of the ensemble. We consider the ensemble as a mixture model where each member of the ensemble is uniformly weighted at prediction time. For our task, this corresponds to averaging the predictions as follows:
102
+
103
+ $$
104
+ p ( y | \mathbf { x } ; \mathbb { X } , \mathbb { Y } ) = \frac { 1 } { M } \sum _ { m } p ( y | \pmb { x } , \pmb { \theta } _ { m } )
105
+ $$
106
+
107
+ Input: $\mathcal { L }$ - initial labeled training set, $\mathcal { U }$ - initial unlabeled training set, $\mathcal { H }$ - initial set of hyperparameters to train the network, acq. $f n$ . - acquisition function, $n _ { q u e r y }$ - query batch size, $N$ - final training set size, $K$ - number of forward passes in MC-Dropout, $M$ - number of models in the ensemble Initialize: $\mathrm { i } { = } 0 , \mathscr { L } \gets \mathscr { L } _ { 0 } , \mathscr { U } \gets \mathscr { U } _ { 0 }$ while $i < N$ do Train the ensemble members $A _ { m , i } ( m \in M )$ given the current labeled training set $A _ { m , i } = t r a i n i n g ( \mathcal { H } , \mathcal { L } _ { i } )$ Form ensemble model $E _ { i } = { \mathrm { e n s e m b l e } } ( A _ { 1 } , \mathbf { A } _ { 2 } , . . . , \mathbf { A } _ { M } )$ for $x _ { j } \in \mathcal { U }$ do Compute uncertainty using the ensemble and MC-Dropout $r _ { j } \gets a c q . f n . ( x _ { j } , E _ { i } ; K )$ end for Query the labels of the $n _ { q u e r y } ^ { \mathrm { t h } }$ samples $\mathcal { Q } _ { j }$ with the largest uncertainty values $\begin{array} { r l } & { i n d e x _ { j } a r g s o r t ( r _ { j } ; n _ { q u e r y } ) } \\ & { \mathcal { Q } _ { j } \{ x _ { z } | z \in i n d e x _ { j } [ 0 : n _ { q u e r y } ] \} } \\ & { \mathcal { L } _ { i + 1 } \mathcal { L } _ { i } \cup \mathcal { Q } _ { j } } \\ & { \mathcal { U } _ { i + \frac { 1 } { 4 } } \mathcal { U } _ { i } \setminus \mathcal { Q } _ { j } } \end{array}$ end while
108
+
109
+ Equation 7 corresponds to the deterministic ensemble case. Our predictions are further averaged by a number of MC-Dropout forward passes, giving rise to what we call a stochastic ensemble:
110
+
111
+ $$
112
+ p ( y | \mathbf { x } ; \mathbb { X } , \mathbb { Y } ) = \frac { 1 } { M } \frac { 1 } { K } \sum _ { m } \sum _ { k } p ( y | \mathbf { x } , \pmb { \theta } _ { m , k } )
113
+ $$
114
+
115
+ $\theta _ { m , k }$ denotes the model parameters for ensemble model member $m$ in the $k$ MC-Dropout forward pass. Each of the two equations can then be used with acquisitions functions previously described. In the deterministic ensemble case, we just replace the number of forward passes $k$ with the number of ensemble classifiers $m$ to obtain expressions for uncertainty. The predictive entropy for our stochastic ensemble becomes:
116
+
117
+ $$
118
+ \mathrm { H } [ y | x ; \mathbb { X } , \mathbb { Y } ] = - \sum _ { c } { \Big ( } { \frac { 1 } { M } } { \frac { 1 } { K } } \sum _ { m } \sum _ { k } p ( y = c | \mathbf { x } , \theta _ { m , k } ) { \Big ) } \mathrm { l o g } { \Big ( } { \frac { 1 } { M } } { \frac { 1 } { K } } \sum _ { m } \sum _ { k } p ( y | \mathbf { x } , \theta _ { m , k } ) { \Big ) }
119
+ $$
120
+
121
+ For both datasets, DEBAL shows significant improvements in classification accuracy (Figure 3 - similar results obtained for all other acquisition functions but for sake of clarity we illustrate results for BALD only). The better performance of the deterministic ensemble method over the single MCDropout one is in agreement with similar results presented in Beluch et al. (2018), and is attributed to better uncertainty estimates obtained from the ensemble. We hypothesize that the additional improvement is a result of better uncertainty estimates from the stochastic ensemble.
122
+
123
+ To validate our claims, we compare the uncertainty behaviour between single network MC-dropout and DEBAL, as can be seen qualitatively in Appendix Figure 10 by the elimination of ”black holes” in the latent space of DEBAL. Secondly, we observe how the methods behave on both seen and unseen distributions, using the NotMNIST dataset of letters A-J from different fonts (Bulatov, 2011). BALD uncertainty results for this approach are evidenced in Figure 4. We sample 2,000 balanced and random images from the MNIST test set and, similarly, 2,000 images from the NotMNIST test set. For MNIST, we make sure that the randomly selected images did not end up being acquired during AL. This corresponds to data unseen during training but originating from the same distribution source. For the known distribution, both methods produce low uncertainty for the majority of the test samples, as expected. However, for the single MC-Dropout network the distribution is characterized by fatter tails (both extremely confident and extremely uncertain about a significant number of images). The ensemble method, however, results in a more clustered distribution of the uncertainty. This further illustrates that ensemble learns a more representative part of the input space.
124
+
125
+ On the unseen distribution (Figure 4), the broad uniform distribution of uncertainty from the single network illustrates the presence of images about which the classifier is both extremely certain and uncertain. This implies that the network learned some specific transferable features that are recognizable in part of the new dataset. For the ensemble, on the other hand, the uncertainty is much smaller and more centered on a few values. This implies that the features learned during the initial training on MNIST are more general. This behaviour is a more realistic one to expect when evaluating a similar but new dataset. Apart from correcting for the mode-collapse phenomena, the MC-Dropout ensemble also does a better job in identifying and acquiring images from the pool set that are inherently more difficult to assign to a particular class (Appendix Figure 11).
126
+
127
+ ![](images/fe9e906eaf044fcf6e09410538419199a7a355954b718717d7341dbb202756c3.jpg)
128
+ Figure 3: Test accuracy as a function of size of the incremental training set during AL. Effect of using an ensemble of three similar models (stochastic or deterministic) instead of one single MCDropout network. Left: MNIST. Right: CIFAR-10
129
+
130
+ ![](images/bcd86cb27fe7a6407948cde476012eaaf0432786611db775b41f9ca993870fc2.jpg)
131
+ Figure 4: Histogram of BALD uncertainty of MNIST (left) and NotMNIST (right) images (2,000 random but balanced test set). Uncertainty obtained from single MC-Dropout and ensemble MCDropout methods at the end of the AL process.
132
+
133
+ # 3.4 DETERMINISTIC VS STOCHASTIC ENSEMBLE
134
+
135
+ In order to explain the additional improvement in DEBAL, we performed an analysis on both seen (MNIST) and unseen (NotMNIST) distributions similar to the one presented before. Figure 5 compares the histograms of BALD uncertainty obtained from the two methods using the ensemble models obtained at the end of the AL process. Additionally, we show the accuracy of the models corresponding to each binned subset of the test data. When the images are coming from a known distribution (MNIST), for both methods the accuracy decreases as the level of uncertainty increases. This observation suggests that the ambiguity captured by these methods is meaningful. However, the stochastic ensemble is more confident. Judging by the accuracy along the bins, this additional confidence seems to reflect meaningful uncertainty.
136
+
137
+ By observing the uncertainty behaviour on the unseen distribution (Figure 5, right), the stochastic ensemble is more confident overall than its deterministic counterpart, but at the same time, its uncertainty is more meaningful, as evidenced by the reduction in classification accuracy as we move towards the uncertain (right) tail of the distribution. On the other hand, the classification accuracy of the deterministic ensemble is more uniform, with both tails of the distributions (most and least certain) seeing similar levels of accuracy. This suggests that the uncertainty produced by the deterministic ensemble is less correlated with the level of its uncertainty and hence less meaningful.
138
+
139
+ ![](images/0cf0bfedfbce8ed00af3bdc597f62a2c6118b3bf708e44512016abbdaa6e6c4b.jpg)
140
+ Figure 5: Histogram of BALD uncertainty of MNIST (left) and NotMNIST (right) images (2,000 random but balanced test set). Uncertainty obtained from deterministic and MC-Dropout ensemble methods at the end of the AL process. Numbers correspond to accuracy for corresponding binned subset of test data (in percentage).
141
+
142
+ ![](images/da5f07530322708c9edcff977512d2da3411dcaea69eb679f0aa47bbb8ee15e5.jpg)
143
+ Figure 6: Left MNIST uncertainty calibration. Expected fraction and observed fraction. Ideal output is the dashed black line. MSE reported in paranthesis. Calibration averaged over 3 different runs.
144
+
145
+ Uncertainty calibration. We used the ensemble models obtained at the end of the AL experiments to evaluate the entire MNIST test set. We looked whether the expected fraction of correct classifications matches the observed proportion. The expected proportion of correct classifications is derived from the models confidence. When plotting expected against observed fraction, a well-calibrated model should lie very close to the diagonal. Figure 6(left) shows that the stochastic ensemble method leads to a better calibrated uncertainty. An additional measure for uncertainty calibration (quality) is the Brier score (Brier, 1950), where a smaller value corresponds to better calibrated predictions. We find that the stochastic ensemble has a better quality of uncertainty (Brier score: 0.0244) compared to the deterministic one (Brier score: 0.0297). Finally, we investigated the effect of training the deterministic ensemble with data acquired by the stochastic one. Figure 6 (right) shows that incorporating stochasticity in the ensemble via MC-Dropout leads to an overall increase in performance, further reinforcing our hypothesis.
146
+
147
+ # 4 CONCLUSION AND FUTURE WORK
148
+
149
+ In this work, we focused on the use of active learning in a deep learning framework for the image classification task. We showed empirically how the mode collapse phenomenon is having a negative impact on the current state-of-the-art Bayesian active learning method. We improved upon this method by leveraging off the expressive power and statistical properties of model ensembles. We linked the performance improvement to a better representation of data uncertainty resulting from our method. For future work, this superior uncertainty representation could be used to address one of the major issues of deep networks in safety-critical applications: adversarial examples.
150
+
151
+ # REFERENCES
152
+
153
+ David Barber and Christopher M Bishop. Ensemble learning in bayesian neural networks. NATO ASI SERIES F COMPUTER AND SYSTEMS SCIENCES, 168:215–238, 1998.
154
+
155
+ William H Beluch, Tim Genewein, Andreas Nurnberger, and Jan M K ¨ ohler. The power of ensembles ¨ for active learning in image classification. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pp. 9368–9377, 2018.
156
+
157
+ Yoshua Bengio, Pascal Lamblin, Dan Popovici, and Hugo Larochelle. Greedy layer-wise training of deep networks. In Advances in neural information processing systems, pp. 153–160, 2007.
158
+
159
+ David M Blei, Alp Kucukelbir, and Jon D McAuliffe. Variational inference: A review for statisticians. Journal of the American Statistical Association, 112(518):859–877, 2017.
160
+
161
+ Leo Breiman. Bagging predictors. Machine learning, 24(2):123–140, 1996.
162
+
163
+ Glenn W Brier. Verification of forecasts expressed in terms of probability. Monthey Weather Review, 78(1):1–3, 1950.
164
+
165
+ Yaroslav Bulatov. Notmnist. 2011. http://yaroslavvb.blogspot.com/2011/09/ notmnist-dataset.html.
166
+
167
+ Franc¸ois Chollet et al. Keras. https://keras.io, 2015.
168
+
169
+ David A Cohn, Zoubin Ghahramani, and Michael I Jordan. Active learning with statistical models. Journal of artificial intelligence research, 4:129–145, 1996.
170
+
171
+ Sanjoy Dasgupta. Analysis of a greedy active learning strategy. In Advances in neural information processing systems, pp. 337–344, 2005.
172
+
173
+ Jeffrey De Fauw, Joseph R Ledsam, Bernardino Romera-Paredes, Stanislav Nikolov, Nenad Tomasev, Sam Blackwell, Harry Askham, Xavier Glorot, Brendan ODonoghue, Daniel Visentin, et al. Clinically applicable deep learning for diagnosis and referral in retinal disease. Nature medicine, 24(9):1342, 2018.
174
+
175
+ Stefan Depeweg, Jose Miguel Hern ´ andez-Lobato, Finale Doshi-Velez, and Steffen Udluft. Un- ´ certainty decomposition in bayesian neural networks with latent variables. arXiv preprint arXiv:1706.08495, 2017.
176
+
177
+ Melanie Ducoffe and Frederic Precioso. Adversarial active learning for deep networks: a margin based approach. arXiv preprint arXiv:1802.09841, 2018.
178
+
179
+ Linton C Freeman. Elementary applied statistics: for students in behavioral science. John Wiley & Sons, 1965.
180
+
181
+ Yarin Gal. Uncertainty in deep learning. University of Cambridge, 2016.
182
+
183
+ 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, 2016.
184
+
185
+ Yarin Gal, Riashat Islam, and Zoubin Ghahramani. Deep bayesian active learning with image data. arXiv preprint arXiv:1703.02910, 2017.
186
+
187
+ HA Haenssle, C Fink, R Schneiderbauer, F Toberer, T Buhl, A Blum, A Kalloo, A Hassen, L Thomas, A Enk, et al. Man against machine: diagnostic performance of a deep learning convolutional neural network for dermoscopic melanoma recognition in comparison to 58 dermatologists. Annals of Oncology, 2018.
188
+
189
+ Geoffrey E Hinton and Drew Van Camp. Keeping the neural networks simple by minimizing the description length of the weights. In Proceedings of the sixth annual conference on Computational learning theory, pp. 5–13. ACM, 1993.
190
+
191
+ Matthew D Hoffman, David M Blei, Chong Wang, and John Paisley. Stochastic variational inference. The Journal of Machine Learning Research, 14(1):1303–1347, 2013.
192
+
193
+ Steven CH Hoi, Rong Jin, Jianke Zhu, and Michael R Lyu. Batch mode active learning and its application to medical image classification. In Proceedings of the 23rd international conference on Machine learning, pp. 417–424. ACM, 2006.
194
+
195
+ Neil Houlsby, Ferenc Huszar, Zoubin Ghahramani, and M ´ at´ e Lengyel. Bayesian active learning for ´ classification and preference learning. arXiv preprint arXiv:1112.5745, 2011.
196
+
197
+ Christoph Kading, Erik Rodner, Alexander Freytag, and Joachim Denzler. Active and continu- ¨ ous exploration with deep neural networks and expected model output changes. arXiv preprint arXiv:1612.06129, 2016.
198
+
199
+ Alex Kendall, Vijay Badrinarayanan, and Roberto Cipolla. Bayesian segnet: Model uncertainty in deep convolutional encoder-decoder architectures for scene understanding. arXiv preprint arXiv:1511.02680, 2015.
200
+
201
+ Diederik $\mathrm { \bf P }$ Kingma and Max Welling. Auto-encoding variational bayes. arXiv preprint arXiv:1312.6114, 2013.
202
+
203
+ Alex Krizhevsky and Geoffrey Hinton. Learning multiple layers of features from tiny images. Technical report, Citeseer, 2009.
204
+
205
+ Alex Krizhevsky, Ilya Sutskever, and Geoffrey E Hinton. Imagenet classification with deep convolutional neural networks. In Advances in neural information processing systems, pp. 1097–1105, 2012.
206
+
207
+ Balaji Lakshminarayanan, Alexander Pritzel, and Charles Blundell. Simple and scalable predictive uncertainty estimation using deep ensembles. In Advances in Neural Information Processing Systems, pp. 6402–6413, 2017.
208
+
209
+ Jiangwei Lao, Yinsheng Chen, Zhi-Cheng Li, Qihua Li, Ji Zhang, Jing Liu, and Guangtao Zhai. A deep learning-based radiomics model for prediction of survival in glioblastoma multiforme. Scientific reports, 7(1):10353, 2017.
210
+
211
+ Neil David Lawrence. Variational inference in probabilistic models. PhD thesis, University of Cambridge, 2001.
212
+
213
+ Yann LeCun. The mnist database of handwritten digits. http://yann. lecun. com/exdb/mnist/, 1998.
214
+
215
+ Yann LeCun, Yoshua Bengio, and Geoffrey Hinton. Deep learning. Nature, 521(7553):436–444, 2015.
216
+
217
+ Christian Leibig, Vaneeda Allken, Murat Sec¸kin Ayhan, Philipp Berens, and Siegfried Wahl. Leveraging uncertainty information from deep neural networks for disease detection. Scientific reports, 7(1):17816, 2017.
218
+
219
+ Xiao Lin and Devi Parikh. Active learning for visual question answering: An empirical study. arXiv preprint arXiv:1711.01732, 2017.
220
+
221
+ Radford M Neal. Bayesian learning for neural networks, volume 118. Springer Science & Business Media, 2012.
222
+
223
+ John Paisley, David Blei, and Michael Jordan. Variational bayesian inference with stochastic search. arXiv preprint arXiv:1206.6430, 2012.
224
+
225
+ Christian Robert and George Casella. Monte Carlo statistical methods. Springer Science & Business Media, 2013.
226
+
227
+ Ozan Sener and Silvio Savarese. Active learning for convolutional neural networks: Acore-set approach. stat, 1050:27, 2017.
228
+
229
+ Burr Settles. Active learning. Synthesis Lectures on Artificial Intelligence and Machine Learning, 6 (1):1–114, 2012.
230
+
231
+ Claude Elwood Shannon. A mathematical theory of communication. ACM SIGMOBILE mobile computing and communications review, 5(1):3–55, 2001.
232
+
233
+ Yanyao Shen, Hyokun Yun, Zachary C Lipton, Yakov Kronrod, and Animashree Anandkumar. Deep active learning for named entity recognition. arXiv preprint arXiv:1707.05928, 2017.
234
+
235
+ Justin S Smith, Ben Nebgen, Nicholas Lubbers, Olexandr Isayev, and Adrian E Roitberg. Less is more: Sampling chemical space with active learning. The Journal of Chemical Physics, 148(24): 241733, 2018.
236
+
237
+ Lewis Smith and Yarin Gal. Understanding measures of uncertainty for adversarial example detection. arXiv preprint arXiv:1803.08533, 2018.
238
+
239
+ Akash Srivastava, Lazar Valkoz, Chris Russell, Michael U Gutmann, and Charles Sutton. Veegan: Reducing mode collapse in gans using implicit variational learning. In Advances in Neural Information Processing Systems, pp. 3308–3318, 2017.
240
+
241
+ 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.
242
+
243
+ Keze Wang, Dongyu Zhang, Ya Li, Ruimao Zhang, and Liang Lin. Cost-effective active learning for deep image classification. IEEE Transactions on Circuits and Systems for Video Technology, 2016.
244
+
245
+ Zheng Wang and Jieping Ye. Querying discriminative and representative samples for batch mode active learning. ACM Transactions on Knowledge Discovery from Data (TKDD), 9(3):17, 2015.
246
+
247
+ Ye Zhang, Matthew Lease, and Byron C Wallace. Active discriminative text representation learning. In AAAI, pp. 3386–3392, 2017.
248
+
249
+ # Appendices
250
+
251
+ ![](images/5e937a5ee2e5a7ce0c98ee8fa8b1addf5bfc449b5d8bf1c23e8adfa4f5152b46.jpg)
252
+ Figure 7: MNIST histograms of the top 1,000 most uncertain samples from test set as ranked by the LeNet model trained on the entire training set.
253
+
254
+ ![](images/fe9ae034b83785e93f1f3c233ffc4cae1d8f898ecfc0e1daf5a8b34f4a639390.jpg)
255
+ Figure 8: MNIST confusion matrix for the models at the end of the AL process. Test set: 10,000. Additionally, the fully trained model (top left) is shown as baseline.
256
+
257
+ ![](images/7b63b1863e3fc79d84dbffbae42a309068c56a047c0549eccf1a95ccf3d46121.jpg)
258
+ Figure 9: MNIST histogram of true labels in the training set after 8 acquisition iterations. Total number of images in training set: 100 Top: Single MC-Dropout network. Bottom: Ensemble of three networks of similar architecture but different random initialization.
259
+
260
+ ![](images/71f6fc3cdb3db4a4054695add8ba6a3e8977c60758a34a05be9d491de20f5c7a.jpg)
261
+ Figure 10: Uncertainty visualization in latent space. MNIST dataset removed for a clearer visualization of the uncertainty. Uncertainty is in white (a lighter background corresponds to higher uncertainty while a darker one represents regions of lower uncertainty) Top: Uncertainty obtained at the end of the AL process using an ensemble of three similar networks. Bottom: Uncertainty obtained at the end of the AL process using a single network.
262
+
263
+ ![](images/1a66dfce36977bb29ea249c7c6298e8eb296c51e0c321ab000e6c55725d68ac3.jpg)
264
+ Figure 11: tSNE embeddings of the MNIST dataset. Effect of using an ensemble of three similar models (stochastic or deterministic) instead of one single MC-Dropout network. Orange points correspond to images acquired during the AL process.
parse/train/Byx93sC9tm/Byx93sC9tm_content_list.json ADDED
@@ -0,0 +1,1412 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [
2
+ {
3
+ "type": "text",
4
+ "text": "DEEP ENSEMBLE BAYESIAN ACTIVE LEARNING : ADRESSING THE MODE COLLAPSE ISSUE IN MONTE CARLO DROPOUT VIA ENSEMBLES ",
5
+ "text_level": 1,
6
+ "bbox": [
7
+ 174,
8
+ 98,
9
+ 823,
10
+ 171
11
+ ],
12
+ "page_idx": 0
13
+ },
14
+ {
15
+ "type": "text",
16
+ "text": "Anonymous authors Paper under double-blind review ",
17
+ "bbox": [
18
+ 183,
19
+ 195,
20
+ 398,
21
+ 223
22
+ ],
23
+ "page_idx": 0
24
+ },
25
+ {
26
+ "type": "text",
27
+ "text": "ABSTRACT ",
28
+ "text_level": 1,
29
+ "bbox": [
30
+ 454,
31
+ 260,
32
+ 544,
33
+ 275
34
+ ],
35
+ "page_idx": 0
36
+ },
37
+ {
38
+ "type": "text",
39
+ "text": "In image classification tasks, the ability of deep convolutional neural networks (CNNs) to deal with complex image data has proved to be unrivalled. Deep CNNs, however, require large amounts of labeled training data to reach their full potential. In specialized domains such as healthcare, labeled data can be difficult and expensive to obtain. One way to alleviate this problem is to rely on active learning, a learning technique that aims to reduce the amount of labelled data needed for a specific task while still delivering satisfactory performance. We propose a new active learning strategy designed for deep neural networks. This method improves upon the current state-of-the-art deep Bayesian active learning method, which suffers from the mode collapse problem. We correct for this deficiency by making use of the expressive power and statistical properties of model ensembles. Our proposed method manages to capture superior data uncertainty, which translates into improved classification performance. We demonstrate empirically that our ensemble method yields faster convergence of CNNs trained on the MNIST and CIFAR-10 datasets. ",
40
+ "bbox": [
41
+ 233,
42
+ 292,
43
+ 764,
44
+ 500
45
+ ],
46
+ "page_idx": 0
47
+ },
48
+ {
49
+ "type": "text",
50
+ "text": "1 INTRODUCTION ",
51
+ "text_level": 1,
52
+ "bbox": [
53
+ 176,
54
+ 530,
55
+ 336,
56
+ 545
57
+ ],
58
+ "page_idx": 0
59
+ },
60
+ {
61
+ "type": "text",
62
+ "text": "The success of deep learning in the last decade has been attributed to more computational power, better algorithms and larger datasets. In object classification tasks, CNNs widely outperform alternative methods in benchmark datasets (LeCun et al., 2015) and have been used in medical imaging for critical situations such as skin cancer detection (Haenssle et al., 2018), retinal disease detection (De Fauw et al., 2018) or even brain tumour survival prediction (Lao et al., 2017). ",
63
+ "bbox": [
64
+ 174,
65
+ 563,
66
+ 823,
67
+ 631
68
+ ],
69
+ "page_idx": 0
70
+ },
71
+ {
72
+ "type": "text",
73
+ "text": "Although their performance is unrivalled, their success strongly depends on huge amounts of annotated data (Bengio et al., 2007; Krizhevsky et al., 2012). In specialized domains such as medicine or chemistry, expert labelled data is costly and time consuming to acquire (Hoi et al., 2006; Smith et al., 2018). Active Learning (AL) provides a theoretically sound framework (Cohn et al., 1996) that reduces the amount of labelled data needed for a specific task. Developed as an iterative process, AL progressively adds unlabelled data points to the training set using an acquisition function, ranking them in order of importance to maximize performance. ",
74
+ "bbox": [
75
+ 174,
76
+ 638,
77
+ 823,
78
+ 736
79
+ ],
80
+ "page_idx": 0
81
+ },
82
+ {
83
+ "type": "text",
84
+ "text": "Using Active Learning within a Deep Learning framework (DAL) has recently seen successful applications in text classification (Zhang et al., 2017; Shen et al., 2017), visual question answering (Lin & Parikh, 2017) and image classification with CNNs (Gal et al., 2017; Sener & Savarese, 2017; Beluch et al., 2018). One key difference between DAL and classical AL is the sampling in batches, which is needed to keep computational costs low. As such, developing scalable DAL methods for CNNs presents challenging problems. Firstly, acquisitions functions do not scale well for high dimensional data or parameter spaces, due to the cost of estimating uncertainty measures, which is the main approach. Secondly, even with scalability not being an issue, one needs to obtain good uncertainty estimates in order to avoid having overconfident predictions. One of the most promising techniques is Deep Bayesian Active Learning (DBAL) (Gal, 2016; Gal & Ghahramani, 2016), which uses Monte-Carlo dropout (MC-dropout) as a Bayesian framework to obtain uncertainty estimates. However, as mentioned in Ducoffe & Precioso (2018), uncertainty-based methods can be fooled by adversarial examples, where small perturbations in inputs can result in overconfident and surprising outputs. Another approach presented by Beluch et al. (2018) uses ensemble models to obtain better uncertainty estimates than DBAL methods, although there are no result on how it deals with adversarial perturbations. Whereas uncertainty-based methods aim to pick data points the model is most uncertain about, density-based approaches try to identify the samples that are most representative of the entire unlabelled set, albeit at a computational cost (Sener & Savarese, 2017). Hybrid methods aim to trade uncertainty for representativeness. Our belief is that overconfident predictions for DBAL methods are an outcome of the mode collapse phenomenon in variational inference methods (Srivastava et al., 2017), and that by combining the expressive power of ensemble methods with MC-dropout we can obtain ”better” uncertainties without trading representativeness. ",
85
+ "bbox": [
86
+ 174,
87
+ 743,
88
+ 825,
89
+ 922
90
+ ],
91
+ "page_idx": 0
92
+ },
93
+ {
94
+ "type": "text",
95
+ "text": "",
96
+ "bbox": [
97
+ 174,
98
+ 104,
99
+ 825,
100
+ 229
101
+ ],
102
+ "page_idx": 1
103
+ },
104
+ {
105
+ "type": "text",
106
+ "text": "In this paper we provide evidence for the mode collapse phenomenon in the form of a highly imbalanced training set acquired during AL with MC-dropout, and show that ’preferential’ behaviour is not beneficial for the AL process. Furthermore, we link the mode collapse phenomenon to overconfident classifications. We compare the use of ensemble models to MC-Dropout for uncertainty estimation and give intuitive reasons why combining the two might perform better. We present Deep Ensemble Bayesian Active Learning (DEBAL) which confirms our intuition for experiments on MNIST and CIFAR-10. ",
107
+ "bbox": [
108
+ 174,
109
+ 237,
110
+ 823,
111
+ 334
112
+ ],
113
+ "page_idx": 1
114
+ },
115
+ {
116
+ "type": "text",
117
+ "text": "In Section 2 we give an overview of current popular methods for DAL. In Section 3, various acquisition functions are introduced and the mode collapse issue is empirically identified. Further on, the use of model ensembles is motivated before presenting our method DEBAL. The last part of section 3 is devoted to understanding the cause of the observed improvements in performance. ",
118
+ "bbox": [
119
+ 174,
120
+ 342,
121
+ 825,
122
+ 397
123
+ ],
124
+ "page_idx": 1
125
+ },
126
+ {
127
+ "type": "text",
128
+ "text": "2 BACKGROUND ",
129
+ "text_level": 1,
130
+ "bbox": [
131
+ 176,
132
+ 419,
133
+ 326,
134
+ 435
135
+ ],
136
+ "page_idx": 1
137
+ },
138
+ {
139
+ "type": "text",
140
+ "text": "The area of active learning has been studied extensively before (see Settles (2012) for a comprehensive review), but with the emergence of deep learning, it has seen widespread interest. As proved by Dasgupta (2005) there is no good universal AL strategy, researchers instead relying on heuristics tailored for their particular tasks. ",
141
+ "bbox": [
142
+ 174,
143
+ 450,
144
+ 823,
145
+ 507
146
+ ],
147
+ "page_idx": 1
148
+ },
149
+ {
150
+ "type": "text",
151
+ "text": "Uncertainty-based Methods. We identify uncertainty-based methods as being the main ones used by the image classification community. Deep Bayesian Active Learning (Gal et al., 2017) models a Gaussian prior over the CNNs weights and uses variational inference techniques to obtain a posterior distribution over the network’s predictions, using these samples as a measure of uncertainty and as input to the acquisition function of the AL process. In practice, posterior samples are obtained using Monte-Carlo dropout (MC-dropout)(Srivastava et al., 2014), a computationally inexpensive and powerful stochastic regularization technique that performs well on real-world datasets (Leibig et al., 2017; Kendall et al., 2015) and has been shown to be equivalent to performing variational inference (Gal & Ghahramani, 2016). However, these approximating methods suffer from mode collapse, as evidenced in Blei et al. (2017). Another method, Cost-Effective Active Learning (CEAL) (Wang et al., 2016), uses the entropy of the network’s outputs to quantify uncertainty, with additional pseudo-labelling. This can be seen as the deterministic counterpart of DBAL, that adds highly confident samples directly from predictions, without the query process. Kading et al. (2016) ¨ propose a method on the expected model output change principle. This method approximates the expected reduction in the model’s error to avoid selecting redundant queries, albeit at a computational cost. Lastly, as this work was being developed, we found the work of Beluch et al. (2018), who propose to use deterministic ensemble models to obtain uncertainty approximations. Their method scores high both in terms of performance and robustness. ",
152
+ "bbox": [
153
+ 173,
154
+ 512,
155
+ 825,
156
+ 763
157
+ ],
158
+ "page_idx": 1
159
+ },
160
+ {
161
+ "type": "text",
162
+ "text": "Density-based Methods & Hybrid Methods. Sener & Savarese (2017) looked at the data selection process from a set theory approach (core set) and showed their heuristic-free method outperforms existing uncertainty-based ones. Their acquisition function uses the geometry in the data-space to select the most informative samples. The main idea is to try to find a diverse subset of the entire input data space that best represents it. Although achieving promising results, the core set approach is computationally expensive as it requires solving a mixed integer programming optimisation problem. Ducoffe & Precioso (2018), on the other hand, rely on adversarial perturbation to select unlabeled samples. Their approach can be seen as margin based active learning, whereby distances to decision boundaries are approximated by distances to adversarial examples. To the best of our knowledge, the only hybrid method (combining measures of both uncertainty and representativeness) tested within a CNN-based DAL framework is the one proposed in Wang & Ye (2015). ",
163
+ "bbox": [
164
+ 174,
165
+ 770,
166
+ 825,
167
+ 922
168
+ ],
169
+ "page_idx": 1
170
+ },
171
+ {
172
+ "type": "text",
173
+ "text": "Although originally not tested on CNNs, this method was shown to perform worse than the core set approach in Sener & Savarese (2017). ",
174
+ "bbox": [
175
+ 173,
176
+ 104,
177
+ 823,
178
+ 133
179
+ ],
180
+ "page_idx": 2
181
+ },
182
+ {
183
+ "type": "text",
184
+ "text": "Deep Bayesian Active Learning. Given the set of inputs $\\mathbb { X } = \\{ \\pmb { x } _ { 1 } , . . , \\pmb { x } _ { n } \\}$ and outputs $\\mathbb { Y } =$ $\\{ y _ { 1 } , . . , y _ { n } \\}$ belonging to classes $c$ , one can define a probabilistic neural network by defining a model $f ( \\pmb { x } ; \\pmb { \\theta } )$ with a prior $p ( \\pmb \\theta )$ over the parameter space $\\pmb \\theta$ , usually Gaussian, and a likelihood $p ( y =$ $c | \\boldsymbol { x } , \\boldsymbol { \\theta } )$ which is usually given by softmax $\\left( f ( \\pmb { x } ; \\pmb { \\theta } ) \\right)$ . The goal is to obtain the posterior distribution over $\\pmb \\theta$ : ",
185
+ "bbox": [
186
+ 173,
187
+ 140,
188
+ 825,
189
+ 208
190
+ ],
191
+ "page_idx": 2
192
+ },
193
+ {
194
+ "type": "equation",
195
+ "img_path": "images/7001547f197f5b201928a0d7bf998e3df55857dd5b07bb02c6f3e323ab7ac9c8.jpg",
196
+ "text": "$$\np ( \\pmb \\theta | \\mathbb { X } , \\mathbb { Y } ) = \\frac { p ( \\mathbb { Y } | \\mathbb { X } , \\pmb \\theta ) p ( \\pmb \\theta ) } { p ( \\mathbb { Y } | \\mathbb { X } ) }\n$$",
197
+ "text_format": "latex",
198
+ "bbox": [
199
+ 401,
200
+ 205,
201
+ 594,
202
+ 239
203
+ ],
204
+ "page_idx": 2
205
+ },
206
+ {
207
+ "type": "text",
208
+ "text": "One can make predictions $y ^ { * }$ about new data points $\\pmb { x } ^ { * }$ by taking a weighted average of the forecasts obtained using all possible values of the parameters $\\pmb \\theta$ , weighted by the posterior probability of each parameter: ",
209
+ "bbox": [
210
+ 174,
211
+ 241,
212
+ 826,
213
+ 284
214
+ ],
215
+ "page_idx": 2
216
+ },
217
+ {
218
+ "type": "equation",
219
+ "img_path": "images/91f97bdd82610d45750b628d367afdb58d86f8c745959c0d88b61d1fdd06fb60.jpg",
220
+ "text": "$$\np ( y ^ { * } | \\mathbf { x } ^ { * } , \\mathbb { X } , \\mathbb { Y } ) = \\int p ( y ^ { * } | x , \\pmb { \\theta } ) p ( \\pmb { \\theta } | \\mathbb { X } , \\mathbb { Y } ) d \\pmb { \\theta } = \\mathbb { E } _ { \\pmb { \\theta } \\sim p ( \\pmb { \\theta } | \\mathbb { X } , \\mathbb { Y } ) } [ f ( \\mathbf { x } ; \\pmb { \\theta } ) ]\n$$",
221
+ "text_format": "latex",
222
+ "bbox": [
223
+ 271,
224
+ 287,
225
+ 725,
226
+ 320
227
+ ],
228
+ "page_idx": 2
229
+ },
230
+ {
231
+ "type": "text",
232
+ "text": "The real difficulty arises when trying to compute these expectations, as has been previously covered in the literature (Neal, 2012; Hinton & Van Camp, 1993; Barber & Bishop, 1998; Lawrence, 2001). One way to circumvent this issue is to use Monte Carlo (MC) techniques (Hoffman et al., 2013; Paisley et al., 2012; Kingma & Welling, 2013), which approximate the exact expectations using averages over finite independent samples from the posterior predictive distribution (Robert & Casella, 2013). The MC-Dropout technique (Srivastava et al., 2014) will replace $p ( \\pmb { \\theta } | \\mathbb { X } , \\mathbb { Y } )$ with the dropout distribution $\\hat { q } ( \\pmb \\theta )$ . This method scales well to high dimensional data, it is highly flexible to accommodate complex models and it is extremely applicable to existing neural network architectures, as well as easy to use. ",
233
+ "bbox": [
234
+ 173,
235
+ 330,
236
+ 825,
237
+ 458
238
+ ],
239
+ "page_idx": 2
240
+ },
241
+ {
242
+ "type": "text",
243
+ "text": "In DBAL (Gal, 2016), the authors incorporate Bayesian uncertainty via MC-dropout and use acquisition functions that originate from information theory to try and capture two types of uncertainty: epistemic and aleatoric (Smith & Gal, 2018; Depeweg et al., 2017). Epistemic uncertainty is a consequence of insufficient learning of model parameters due to lack of data, leading to broad posteriors. On the other hand, aleatoric uncertainty arises due to the genuine stochasticity in the data (noise) and always leads to predictions with high uncertainty. We briefly describe the three main types of acquisition functions: ",
244
+ "bbox": [
245
+ 173,
246
+ 463,
247
+ 825,
248
+ 561
249
+ ],
250
+ "page_idx": 2
251
+ },
252
+ {
253
+ "type": "text",
254
+ "text": "• MaxEntropy (Shannon, 2001). The higher the entropy of the predictive distribution, the more uncertain the model is: ",
255
+ "bbox": [
256
+ 214,
257
+ 573,
258
+ 825,
259
+ 602
260
+ ],
261
+ "page_idx": 2
262
+ },
263
+ {
264
+ "type": "equation",
265
+ "img_path": "images/dbe62b06464e7dbe81747809ad638d5aed6c0a615a29b03f36c952629a0639ed.jpg",
266
+ "text": "$$\nH [ y | \\mathbf { x } , \\pmb { \\theta } ] = - \\sum _ { c } p ( y = c | \\pmb { x } , \\pmb { \\theta } ) \\mathrm { l o g } p ( y = c | \\pmb { x } , \\pmb { \\theta } )\n$$",
267
+ "text_format": "latex",
268
+ "bbox": [
269
+ 361,
270
+ 603,
271
+ 694,
272
+ 637
273
+ ],
274
+ "page_idx": 2
275
+ },
276
+ {
277
+ "type": "text",
278
+ "text": "• Bayesian Active Learning by Disagreement $( B A L D )$ ) (Houlsby et al., 2011). Based on the mutual information between the input data and posterior, and quantifies the information gain about the model parameters if the correct label would be provided. ",
279
+ "bbox": [
280
+ 215,
281
+ 643,
282
+ 825,
283
+ 685
284
+ ],
285
+ "page_idx": 2
286
+ },
287
+ {
288
+ "type": "equation",
289
+ "img_path": "images/792746112c590b7f8c69b8712697dde9368a1e773d839d5ba698934626c9a4ce.jpg",
290
+ "text": "$$\nI ( y , \\pmb \\theta | \\pmb x , \\pmb \\theta ) = H [ y | \\pmb x ; \\mathbb { X } , \\mathbb { Y } ] - \\mathbb { E } _ { \\pmb \\theta \\sim p ( \\pmb \\theta | \\mathbb { X } , \\mathbb { Y } ) } \\Big [ H [ \\pmb y | \\pmb x , \\pmb \\theta ] \\Big ]\n$$",
291
+ "text_format": "latex",
292
+ "bbox": [
293
+ 343,
294
+ 690,
295
+ 712,
296
+ 718
297
+ ],
298
+ "page_idx": 2
299
+ },
300
+ {
301
+ "type": "text",
302
+ "text": "• Variation Ratio (Freeman, 1965). Measures the statistical dispersion of a categorical variable, with larger values indicating higher uncertainty: ",
303
+ "bbox": [
304
+ 214,
305
+ 724,
306
+ 825,
307
+ 753
308
+ ],
309
+ "page_idx": 2
310
+ },
311
+ {
312
+ "type": "equation",
313
+ "img_path": "images/20a3361e9887abf25e414df2ef03f3467497ffb30502212a03e4e800322b2e0d.jpg",
314
+ "text": "$$\n\\mathrm { V a r R a t i o } ( { \\pmb x } ) = 1 - \\operatorname* { m a x } _ { \\pmb y } p ( { \\pmb y } | { \\pmb x } , { \\pmb \\theta } )\n$$",
315
+ "text_format": "latex",
316
+ "bbox": [
317
+ 413,
318
+ 758,
319
+ 643,
320
+ 781
321
+ ],
322
+ "page_idx": 2
323
+ },
324
+ {
325
+ "type": "text",
326
+ "text": "As seen in Gal (2016), for the above deterministic acquisition functions we can write the stochastic versions using the Bayesian MC-Dropout framework, where the class conditional probability $p ( y | \\mathbf { \\boldsymbol { x } } , \\mathbf { \\boldsymbol { \\theta } } )$ can be approximated by the average over the MC-Dropout forward passes. The stochastic predictive entropy becomes: ",
327
+ "bbox": [
328
+ 173,
329
+ 791,
330
+ 825,
331
+ 848
332
+ ],
333
+ "page_idx": 2
334
+ },
335
+ {
336
+ "type": "equation",
337
+ "img_path": "images/88e5c5d1a814aee8aeb73b1fa0fedcc34eb6b161658bde20682059be0a998137.jpg",
338
+ "text": "$$\nH [ y | x , \\theta ] = - \\sum _ { c } { \\Big ( } { \\frac { 1 } { K } } \\sum _ { k } p ( y = c | { \\pmb x } , \\theta _ { k } ) { \\Big ) } \\mathrm { l o g } { \\Big ( } { \\frac { 1 } { K } } \\sum _ { k } p ( y = c | { \\pmb x } , \\theta _ { k } ) { \\Big ) }\n$$",
339
+ "text_format": "latex",
340
+ "bbox": [
341
+ 256,
342
+ 853,
343
+ 740,
344
+ 891
345
+ ],
346
+ "page_idx": 2
347
+ },
348
+ {
349
+ "type": "text",
350
+ "text": "K corresponds to the total number of MC-Dropout forward passes at test time. Equivalent stochastic versions can be obtained for all other acquisition functions. ",
351
+ "bbox": [
352
+ 174,
353
+ 895,
354
+ 823,
355
+ 924
356
+ ],
357
+ "page_idx": 2
358
+ },
359
+ {
360
+ "type": "table",
361
+ "img_path": "images/5ea4140428d5ee9c5a7636cc49b0f6ec1fdac841df1e1bb460e5e250826179bc.jpg",
362
+ "table_caption": [
363
+ "Table 1: Experiment settings for MNIST and CIFAR-10 "
364
+ ],
365
+ "table_footnote": [],
366
+ "table_body": "<table><tr><td>Dataset</td><td>Model</td><td>Training epochs</td><td>Data size pool/val/test</td><td>Acquisition size</td></tr><tr><td></td><td></td><td></td><td></td><td></td></tr><tr><td>MNIST</td><td>2-Conv</td><td>500</td><td>59,780 /200 /10.000</td><td>20 +10—&gt;1,000</td></tr><tr><td>CIFAR-10</td><td>4-Conv</td><td>500</td><td>47,800/2000/10.000</td><td>200 +100—&gt;10,000</td></tr></table>",
367
+ "bbox": [
368
+ 187,
369
+ 131,
370
+ 808,
371
+ 205
372
+ ],
373
+ "page_idx": 3
374
+ },
375
+ {
376
+ "type": "text",
377
+ "text": "3 DEBAL: DEEP ENSEMBLE BAYESIAN ACTIVE LEARNING ",
378
+ "text_level": 1,
379
+ "bbox": [
380
+ 174,
381
+ 236,
382
+ 678,
383
+ 252
384
+ ],
385
+ "page_idx": 3
386
+ },
387
+ {
388
+ "type": "text",
389
+ "text": "3.1 EXPERIMENTAL DETAILS ",
390
+ "text_level": 1,
391
+ "bbox": [
392
+ 174,
393
+ 267,
394
+ 390,
395
+ 282
396
+ ],
397
+ "page_idx": 3
398
+ },
399
+ {
400
+ "type": "text",
401
+ "text": "We consider the multiclass image classification task on two well-studied datasets: MNIST (LeCun, 1998) and CIFAR-10 (Krizhevsky & Hinton, 2009). Table 1 contains a summary of the results, with the acquisition size containing the initial training set with the batch size for one iteration up to the maximum number of points acquired. At each acquisition step, a fixed sample set from the unlabelled pool is added to the initial balanced labelled data set and models are re-trained from the entire training set. We evaluate the model on the dataset’s standard test set. The CNN model architecture is the same as in the Keras CNN implementation for MNIST and CIFAR-10 (Chollet et al., 2015). We use Glorot initialization for weights, Adam optimizer and early stopping with patience of 15 epochs, for a maximum of 500 epochs. We select the best performing model during the patience duration. We use MC-Dropout with $K = 1 0 0$ forward passes for the stochastic acquisition functions. In all experiments results are averaged over three repetitions. For the ensemble models discussed later, each ensemble consists of $M = 3$ networks of identical architecture but different random initializations. ",
402
+ "bbox": [
403
+ 173,
404
+ 294,
405
+ 825,
406
+ 474
407
+ ],
408
+ "page_idx": 3
409
+ },
410
+ {
411
+ "type": "text",
412
+ "text": "3.2 EVIDENCE OF MODE COLLAPSE IN DBAL ",
413
+ "text_level": 1,
414
+ "bbox": [
415
+ 176,
416
+ 491,
417
+ 506,
418
+ 506
419
+ ],
420
+ "page_idx": 3
421
+ },
422
+ {
423
+ "type": "text",
424
+ "text": "Our experimental results confirmed the performance of Gal (2016) using MC-dropout. However, we observe a lack of diversity in the data acquired during the AL process. This effect is more extreme in the initial phase, which is an important factor when dealing with a small dataset classification problem (see Figure 1). ",
425
+ "bbox": [
426
+ 174,
427
+ 517,
428
+ 825,
429
+ 574
430
+ ],
431
+ "page_idx": 3
432
+ },
433
+ {
434
+ "type": "image",
435
+ "img_path": "images/3c738152d4ef6d9c19fdd595e4abb7ad09d30e2fc93123094421b1273088c4a7.jpg",
436
+ "image_caption": [
437
+ "Figure 1: MNIST histograms of true labels in the training set. Top: End of AL process. Total number of images in training set: 1,000. Bottom: After first 8 acquisition iterations. Total number of images in training set: 100. "
438
+ ],
439
+ "image_footnote": [],
440
+ "bbox": [
441
+ 238,
442
+ 587,
443
+ 754,
444
+ 791
445
+ ],
446
+ "page_idx": 3
447
+ },
448
+ {
449
+ "type": "text",
450
+ "text": "One can argue that the preferential behaviour observed is a desirable one and is arising from the fact that images belonging to some specific classes are more uncertain and difficult to classify, due to resemblance of data from other classes. To debunk this hypothesis, we trained a model with the same architecture on the entire 60,000 sample training set available and used this model to rank the uncertainty for each sample from the 10,000 samples test set. As can be seen in Appendix Figure 7, over-represented class labels during the AL experiment do not have high uncertainty. To assess positive effects of over-sampling, we evaluated how easy models at the end of AL process classified them and observed no such effect (Appendix Figure 8). ",
451
+ "bbox": [
452
+ 174,
453
+ 867,
454
+ 825,
455
+ 924
456
+ ],
457
+ "page_idx": 3
458
+ },
459
+ {
460
+ "type": "image",
461
+ "img_path": "images/8427446c91ace661fe6f7fd8c754f4024f3591464dc2f8599b435cfffd7bc95d.jpg",
462
+ "image_caption": [
463
+ "Figure 2: MNIST uncertainty visualization in VAE space at the end of the AL process for all measures. Colours represent different classes. Low uncertainty: black, High uncertainty: white. "
464
+ ],
465
+ "image_footnote": [],
466
+ "bbox": [
467
+ 241,
468
+ 103,
469
+ 745,
470
+ 242
471
+ ],
472
+ "page_idx": 4
473
+ },
474
+ {
475
+ "type": "text",
476
+ "text": "",
477
+ "bbox": [
478
+ 174,
479
+ 332,
480
+ 825,
481
+ 387
482
+ ],
483
+ "page_idx": 4
484
+ },
485
+ {
486
+ "type": "text",
487
+ "text": "Smith & Gal (2018) argue that the MC-Dropout technique suffers from over-confident predictions. They are particularly concerned with the interpolation behaviour of the uncertainty methods across unknown regions (regions of the input space not seen during the model training phase). We performed a similar analysis in order to gain understanding into how these methods behave. Following their experimental setting, we use a VAE (Kingma & Welling, 2013) to project the MNIST dataset into a 2-dimensional latent space. Figure 2 allows us to visualize the encodings and decode points from latent space to image space, together with their associated measures of uncertainty. The large black regions behind the data suggest that the model is unrealistically over-confident about data that does not resemble anything seen during training, thus providing further evidence supporting MC-Dropouts main deficiency: mode-collapse. ",
488
+ "bbox": [
489
+ 174,
490
+ 393,
491
+ 825,
492
+ 534
493
+ ],
494
+ "page_idx": 4
495
+ },
496
+ {
497
+ "type": "text",
498
+ "text": ".3 DEEP ENSEMBLES: A RECIPE FOR USEFUL UNCERTAINTY ESTIMATIO ",
499
+ "text_level": 1,
500
+ "bbox": [
501
+ 187,
502
+ 568,
503
+ 687,
504
+ 580
505
+ ],
506
+ "page_idx": 4
507
+ },
508
+ {
509
+ "type": "text",
510
+ "text": "We hypothesize that one of DBALs main deficiencies is its inability to capture the full posterior distribution of the data (mode collapse). This can prevent the model from learning in an optimal way, leading to unsatisfactory performance when classifying previously unseen images. As suggested in Smith & Gal (2018) and Lakshminarayanan et al. (2017), one intuitive fix would be to replace the single MC-Dropout model in the AL process with an ensemble of MC-Dropout models, with each member of the ensemble using a different initialization. Since one MC-Dropout model collapses around a subspace (one, or a few local modes) of the posterior distribution, a collection of such models, starting from different initial configurations, will end up covering different (and somehow overlapping) sub-regions of the probability density space. However, one key assumption here, is that each model member of the ensemble will end up capturing the behaviour around a different local mode. Beluch et al. (2018) test this idea in a deterministic setting, where the uncertainty resulting from the use of a deterministic ensemble proved to be more useful for the active learner than the uncertainty provided from a single MC-Dropout network. ",
511
+ "bbox": [
512
+ 174,
513
+ 599,
514
+ 825,
515
+ 780
516
+ ],
517
+ "page_idx": 4
518
+ },
519
+ {
520
+ "type": "text",
521
+ "text": "We propose DEBAL, a stochastic ensemble of $M$ MC-Dropout models, with $M \\ < < \\ K$ . Each member of the ensemble is characterized by a different set of weights $\\pmb { \\theta } _ { m }$ . We use the randomizationbased approach to ensembles (Breiman, 1996), where each member of the ensemble is trained in parallel without any interaction with the other members of the ensemble. We consider the ensemble as a mixture model where each member of the ensemble is uniformly weighted at prediction time. For our task, this corresponds to averaging the predictions as follows: ",
522
+ "bbox": [
523
+ 174,
524
+ 786,
525
+ 825,
526
+ 871
527
+ ],
528
+ "page_idx": 4
529
+ },
530
+ {
531
+ "type": "equation",
532
+ "img_path": "images/802885729577301a819fac40c9fc20bdfabb021ae001f817a54f15ed564383ff.jpg",
533
+ "text": "$$\np ( y | \\mathbf { x } ; \\mathbb { X } , \\mathbb { Y } ) = \\frac { 1 } { M } \\sum _ { m } p ( y | \\pmb { x } , \\pmb { \\theta } _ { m } )\n$$",
534
+ "text_format": "latex",
535
+ "bbox": [
536
+ 382,
537
+ 892,
538
+ 614,
539
+ 929
540
+ ],
541
+ "page_idx": 4
542
+ },
543
+ {
544
+ "type": "text",
545
+ "text": "Input: $\\mathcal { L }$ - initial labeled training set, $\\mathcal { U }$ - initial unlabeled training set, $\\mathcal { H }$ - initial set of hyperparameters to train the network, acq. $f n$ . - acquisition function, $n _ { q u e r y }$ - query batch size, $N$ - final training set size, $K$ - number of forward passes in MC-Dropout, $M$ - number of models in the ensemble Initialize: $\\mathrm { i } { = } 0 , \\mathscr { L } \\gets \\mathscr { L } _ { 0 } , \\mathscr { U } \\gets \\mathscr { U } _ { 0 }$ while $i < N$ do Train the ensemble members $A _ { m , i } ( m \\in M )$ given the current labeled training set $A _ { m , i } = t r a i n i n g ( \\mathcal { H } , \\mathcal { L } _ { i } )$ Form ensemble model $E _ { i } = { \\mathrm { e n s e m b l e } } ( A _ { 1 } , \\mathbf { A } _ { 2 } , . . . , \\mathbf { A } _ { M } )$ for $x _ { j } \\in \\mathcal { U }$ do Compute uncertainty using the ensemble and MC-Dropout $r _ { j } \\gets a c q . f n . ( x _ { j } , E _ { i } ; K )$ end for Query the labels of the $n _ { q u e r y } ^ { \\mathrm { t h } }$ samples $\\mathcal { Q } _ { j }$ with the largest uncertainty values $\\begin{array} { r l } & { i n d e x _ { j } a r g s o r t ( r _ { j } ; n _ { q u e r y } ) } \\\\ & { \\mathcal { Q } _ { j } \\{ x _ { z } | z \\in i n d e x _ { j } [ 0 : n _ { q u e r y } ] \\} } \\\\ & { \\mathcal { L } _ { i + 1 } \\mathcal { L } _ { i } \\cup \\mathcal { Q } _ { j } } \\\\ & { \\mathcal { U } _ { i + \\frac { 1 } { 4 } } \\mathcal { U } _ { i } \\setminus \\mathcal { Q } _ { j } } \\end{array}$ end while ",
546
+ "bbox": [
547
+ 183,
548
+ 114,
549
+ 823,
550
+ 401
551
+ ],
552
+ "page_idx": 5
553
+ },
554
+ {
555
+ "type": "text",
556
+ "text": "Equation 7 corresponds to the deterministic ensemble case. Our predictions are further averaged by a number of MC-Dropout forward passes, giving rise to what we call a stochastic ensemble: ",
557
+ "bbox": [
558
+ 174,
559
+ 426,
560
+ 820,
561
+ 455
562
+ ],
563
+ "page_idx": 5
564
+ },
565
+ {
566
+ "type": "equation",
567
+ "img_path": "images/d7edac8386e3b54f71c97b1ae0736cc725abdecb33f2d92376c8b8f72e9ed932.jpg",
568
+ "text": "$$\np ( y | \\mathbf { x } ; \\mathbb { X } , \\mathbb { Y } ) = \\frac { 1 } { M } \\frac { 1 } { K } \\sum _ { m } \\sum _ { k } p ( y | \\mathbf { x } , \\pmb { \\theta } _ { m , k } )\n$$",
569
+ "text_format": "latex",
570
+ "bbox": [
571
+ 354,
572
+ 458,
573
+ 643,
574
+ 496
575
+ ],
576
+ "page_idx": 5
577
+ },
578
+ {
579
+ "type": "text",
580
+ "text": "$\\theta _ { m , k }$ denotes the model parameters for ensemble model member $m$ in the $k$ MC-Dropout forward pass. Each of the two equations can then be used with acquisitions functions previously described. In the deterministic ensemble case, we just replace the number of forward passes $k$ with the number of ensemble classifiers $m$ to obtain expressions for uncertainty. The predictive entropy for our stochastic ensemble becomes: ",
581
+ "bbox": [
582
+ 174,
583
+ 498,
584
+ 825,
585
+ 568
586
+ ],
587
+ "page_idx": 5
588
+ },
589
+ {
590
+ "type": "equation",
591
+ "img_path": "images/3c0ccb07dcfe301a134cc1dea940a3950caba5ce348e785da6a93d2562585500.jpg",
592
+ "text": "$$\n\\mathrm { H } [ y | x ; \\mathbb { X } , \\mathbb { Y } ] = - \\sum _ { c } { \\Big ( } { \\frac { 1 } { M } } { \\frac { 1 } { K } } \\sum _ { m } \\sum _ { k } p ( y = c | \\mathbf { x } , \\theta _ { m , k } ) { \\Big ) } \\mathrm { l o g } { \\Big ( } { \\frac { 1 } { M } } { \\frac { 1 } { K } } \\sum _ { m } \\sum _ { k } p ( y | \\mathbf { x } , \\theta _ { m , k } ) { \\Big ) }\n$$",
593
+ "text_format": "latex",
594
+ "bbox": [
595
+ 189,
596
+ 569,
597
+ 789,
598
+ 607
599
+ ],
600
+ "page_idx": 5
601
+ },
602
+ {
603
+ "type": "text",
604
+ "text": "For both datasets, DEBAL shows significant improvements in classification accuracy (Figure 3 - similar results obtained for all other acquisition functions but for sake of clarity we illustrate results for BALD only). The better performance of the deterministic ensemble method over the single MCDropout one is in agreement with similar results presented in Beluch et al. (2018), and is attributed to better uncertainty estimates obtained from the ensemble. We hypothesize that the additional improvement is a result of better uncertainty estimates from the stochastic ensemble. ",
605
+ "bbox": [
606
+ 173,
607
+ 617,
608
+ 825,
609
+ 702
610
+ ],
611
+ "page_idx": 5
612
+ },
613
+ {
614
+ "type": "text",
615
+ "text": "To validate our claims, we compare the uncertainty behaviour between single network MC-dropout and DEBAL, as can be seen qualitatively in Appendix Figure 10 by the elimination of ”black holes” in the latent space of DEBAL. Secondly, we observe how the methods behave on both seen and unseen distributions, using the NotMNIST dataset of letters A-J from different fonts (Bulatov, 2011). BALD uncertainty results for this approach are evidenced in Figure 4. We sample 2,000 balanced and random images from the MNIST test set and, similarly, 2,000 images from the NotMNIST test set. For MNIST, we make sure that the randomly selected images did not end up being acquired during AL. This corresponds to data unseen during training but originating from the same distribution source. For the known distribution, both methods produce low uncertainty for the majority of the test samples, as expected. However, for the single MC-Dropout network the distribution is characterized by fatter tails (both extremely confident and extremely uncertain about a significant number of images). The ensemble method, however, results in a more clustered distribution of the uncertainty. This further illustrates that ensemble learns a more representative part of the input space. ",
616
+ "bbox": [
617
+ 174,
618
+ 708,
619
+ 825,
620
+ 888
621
+ ],
622
+ "page_idx": 5
623
+ },
624
+ {
625
+ "type": "text",
626
+ "text": "On the unseen distribution (Figure 4), the broad uniform distribution of uncertainty from the single network illustrates the presence of images about which the classifier is both extremely certain and uncertain. This implies that the network learned some specific transferable features that are recognizable in part of the new dataset. For the ensemble, on the other hand, the uncertainty is much smaller and more centered on a few values. This implies that the features learned during the initial training on MNIST are more general. This behaviour is a more realistic one to expect when evaluating a similar but new dataset. Apart from correcting for the mode-collapse phenomena, the MC-Dropout ensemble also does a better job in identifying and acquiring images from the pool set that are inherently more difficult to assign to a particular class (Appendix Figure 11). ",
627
+ "bbox": [
628
+ 174,
629
+ 895,
630
+ 823,
631
+ 924
632
+ ],
633
+ "page_idx": 5
634
+ },
635
+ {
636
+ "type": "image",
637
+ "img_path": "images/fe9e906eaf044fcf6e09410538419199a7a355954b718717d7341dbb202756c3.jpg",
638
+ "image_caption": [
639
+ "Figure 3: Test accuracy as a function of size of the incremental training set during AL. Effect of using an ensemble of three similar models (stochastic or deterministic) instead of one single MCDropout network. Left: MNIST. Right: CIFAR-10 "
640
+ ],
641
+ "image_footnote": [],
642
+ "bbox": [
643
+ 238,
644
+ 103,
645
+ 753,
646
+ 277
647
+ ],
648
+ "page_idx": 6
649
+ },
650
+ {
651
+ "type": "image",
652
+ "img_path": "images/bcd86cb27fe7a6407948cde476012eaaf0432786611db775b41f9ca993870fc2.jpg",
653
+ "image_caption": [
654
+ "Figure 4: Histogram of BALD uncertainty of MNIST (left) and NotMNIST (right) images (2,000 random but balanced test set). Uncertainty obtained from single MC-Dropout and ensemble MCDropout methods at the end of the AL process. "
655
+ ],
656
+ "image_footnote": [],
657
+ "bbox": [
658
+ 238,
659
+ 353,
660
+ 746,
661
+ 505
662
+ ],
663
+ "page_idx": 6
664
+ },
665
+ {
666
+ "type": "text",
667
+ "text": "",
668
+ "bbox": [
669
+ 174,
670
+ 590,
671
+ 825,
672
+ 689
673
+ ],
674
+ "page_idx": 6
675
+ },
676
+ {
677
+ "type": "text",
678
+ "text": "3.4 DETERMINISTIC VS STOCHASTIC ENSEMBLE ",
679
+ "text_level": 1,
680
+ "bbox": [
681
+ 174,
682
+ 709,
683
+ 522,
684
+ 723
685
+ ],
686
+ "page_idx": 6
687
+ },
688
+ {
689
+ "type": "text",
690
+ "text": "In order to explain the additional improvement in DEBAL, we performed an analysis on both seen (MNIST) and unseen (NotMNIST) distributions similar to the one presented before. Figure 5 compares the histograms of BALD uncertainty obtained from the two methods using the ensemble models obtained at the end of the AL process. Additionally, we show the accuracy of the models corresponding to each binned subset of the test data. When the images are coming from a known distribution (MNIST), for both methods the accuracy decreases as the level of uncertainty increases. This observation suggests that the ambiguity captured by these methods is meaningful. However, the stochastic ensemble is more confident. Judging by the accuracy along the bins, this additional confidence seems to reflect meaningful uncertainty. ",
691
+ "bbox": [
692
+ 174,
693
+ 734,
694
+ 825,
695
+ 861
696
+ ],
697
+ "page_idx": 6
698
+ },
699
+ {
700
+ "type": "text",
701
+ "text": "By observing the uncertainty behaviour on the unseen distribution (Figure 5, right), the stochastic ensemble is more confident overall than its deterministic counterpart, but at the same time, its uncertainty is more meaningful, as evidenced by the reduction in classification accuracy as we move towards the uncertain (right) tail of the distribution. On the other hand, the classification accuracy of the deterministic ensemble is more uniform, with both tails of the distributions (most and least certain) seeing similar levels of accuracy. This suggests that the uncertainty produced by the deterministic ensemble is less correlated with the level of its uncertainty and hence less meaningful. ",
702
+ "bbox": [
703
+ 174,
704
+ 868,
705
+ 823,
706
+ 924
707
+ ],
708
+ "page_idx": 6
709
+ },
710
+ {
711
+ "type": "image",
712
+ "img_path": "images/0cf0bfedfbce8ed00af3bdc597f62a2c6118b3bf708e44512016abbdaa6e6c4b.jpg",
713
+ "image_caption": [
714
+ "Figure 5: Histogram of BALD uncertainty of MNIST (left) and NotMNIST (right) images (2,000 random but balanced test set). Uncertainty obtained from deterministic and MC-Dropout ensemble methods at the end of the AL process. Numbers correspond to accuracy for corresponding binned subset of test data (in percentage). "
715
+ ],
716
+ "image_footnote": [],
717
+ "bbox": [
718
+ 235,
719
+ 99,
720
+ 745,
721
+ 244
722
+ ],
723
+ "page_idx": 7
724
+ },
725
+ {
726
+ "type": "image",
727
+ "img_path": "images/da5f07530322708c9edcff977512d2da3411dcaea69eb679f0aa47bbb8ee15e5.jpg",
728
+ "image_caption": [
729
+ "Figure 6: Left MNIST uncertainty calibration. Expected fraction and observed fraction. Ideal output is the dashed black line. MSE reported in paranthesis. Calibration averaged over 3 different runs. "
730
+ ],
731
+ "image_footnote": [],
732
+ "bbox": [
733
+ 243,
734
+ 333,
735
+ 751,
736
+ 483
737
+ ],
738
+ "page_idx": 7
739
+ },
740
+ {
741
+ "type": "text",
742
+ "text": "",
743
+ "bbox": [
744
+ 174,
745
+ 558,
746
+ 825,
747
+ 599
748
+ ],
749
+ "page_idx": 7
750
+ },
751
+ {
752
+ "type": "text",
753
+ "text": "Uncertainty calibration. We used the ensemble models obtained at the end of the AL experiments to evaluate the entire MNIST test set. We looked whether the expected fraction of correct classifications matches the observed proportion. The expected proportion of correct classifications is derived from the models confidence. When plotting expected against observed fraction, a well-calibrated model should lie very close to the diagonal. Figure 6(left) shows that the stochastic ensemble method leads to a better calibrated uncertainty. An additional measure for uncertainty calibration (quality) is the Brier score (Brier, 1950), where a smaller value corresponds to better calibrated predictions. We find that the stochastic ensemble has a better quality of uncertainty (Brier score: 0.0244) compared to the deterministic one (Brier score: 0.0297). Finally, we investigated the effect of training the deterministic ensemble with data acquired by the stochastic one. Figure 6 (right) shows that incorporating stochasticity in the ensemble via MC-Dropout leads to an overall increase in performance, further reinforcing our hypothesis. ",
754
+ "bbox": [
755
+ 174,
756
+ 607,
757
+ 825,
758
+ 773
759
+ ],
760
+ "page_idx": 7
761
+ },
762
+ {
763
+ "type": "text",
764
+ "text": "4 CONCLUSION AND FUTURE WORK ",
765
+ "text_level": 1,
766
+ "bbox": [
767
+ 174,
768
+ 795,
769
+ 495,
770
+ 810
771
+ ],
772
+ "page_idx": 7
773
+ },
774
+ {
775
+ "type": "text",
776
+ "text": "In this work, we focused on the use of active learning in a deep learning framework for the image classification task. We showed empirically how the mode collapse phenomenon is having a negative impact on the current state-of-the-art Bayesian active learning method. We improved upon this method by leveraging off the expressive power and statistical properties of model ensembles. We linked the performance improvement to a better representation of data uncertainty resulting from our method. For future work, this superior uncertainty representation could be used to address one of the major issues of deep networks in safety-critical applications: adversarial examples. ",
777
+ "bbox": [
778
+ 174,
779
+ 825,
780
+ 825,
781
+ 924
782
+ ],
783
+ "page_idx": 7
784
+ },
785
+ {
786
+ "type": "text",
787
+ "text": "REFERENCES ",
788
+ "text_level": 1,
789
+ "bbox": [
790
+ 174,
791
+ 103,
792
+ 287,
793
+ 119
794
+ ],
795
+ "page_idx": 8
796
+ },
797
+ {
798
+ "type": "text",
799
+ "text": "David Barber and Christopher M Bishop. Ensemble learning in bayesian neural networks. NATO ASI SERIES F COMPUTER AND SYSTEMS SCIENCES, 168:215–238, 1998. ",
800
+ "bbox": [
801
+ 171,
802
+ 127,
803
+ 825,
804
+ 156
805
+ ],
806
+ "page_idx": 8
807
+ },
808
+ {
809
+ "type": "text",
810
+ "text": "William H Beluch, Tim Genewein, Andreas Nurnberger, and Jan M K ¨ ohler. The power of ensembles ¨ for active learning in image classification. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pp. 9368–9377, 2018. ",
811
+ "bbox": [
812
+ 176,
813
+ 165,
814
+ 823,
815
+ 209
816
+ ],
817
+ "page_idx": 8
818
+ },
819
+ {
820
+ "type": "text",
821
+ "text": "Yoshua Bengio, Pascal Lamblin, Dan Popovici, and Hugo Larochelle. Greedy layer-wise training of deep networks. In Advances in neural information processing systems, pp. 153–160, 2007. ",
822
+ "bbox": [
823
+ 171,
824
+ 218,
825
+ 825,
826
+ 248
827
+ ],
828
+ "page_idx": 8
829
+ },
830
+ {
831
+ "type": "text",
832
+ "text": "David M Blei, Alp Kucukelbir, and Jon D McAuliffe. Variational inference: A review for statisticians. Journal of the American Statistical Association, 112(518):859–877, 2017. ",
833
+ "bbox": [
834
+ 174,
835
+ 257,
836
+ 820,
837
+ 286
838
+ ],
839
+ "page_idx": 8
840
+ },
841
+ {
842
+ "type": "text",
843
+ "text": "Leo Breiman. Bagging predictors. Machine learning, 24(2):123–140, 1996. ",
844
+ "bbox": [
845
+ 173,
846
+ 295,
847
+ 673,
848
+ 311
849
+ ],
850
+ "page_idx": 8
851
+ },
852
+ {
853
+ "type": "text",
854
+ "text": "Glenn W Brier. Verification of forecasts expressed in terms of probability. Monthey Weather Review, 78(1):1–3, 1950. ",
855
+ "bbox": [
856
+ 173,
857
+ 320,
858
+ 820,
859
+ 349
860
+ ],
861
+ "page_idx": 8
862
+ },
863
+ {
864
+ "type": "text",
865
+ "text": "Yaroslav Bulatov. Notmnist. 2011. http://yaroslavvb.blogspot.com/2011/09/ notmnist-dataset.html. ",
866
+ "bbox": [
867
+ 173,
868
+ 359,
869
+ 825,
870
+ 388
871
+ ],
872
+ "page_idx": 8
873
+ },
874
+ {
875
+ "type": "text",
876
+ "text": "Franc¸ois Chollet et al. Keras. https://keras.io, 2015. ",
877
+ "bbox": [
878
+ 173,
879
+ 398,
880
+ 575,
881
+ 414
882
+ ],
883
+ "page_idx": 8
884
+ },
885
+ {
886
+ "type": "text",
887
+ "text": "David A Cohn, Zoubin Ghahramani, and Michael I Jordan. Active learning with statistical models. Journal of artificial intelligence research, 4:129–145, 1996. ",
888
+ "bbox": [
889
+ 173,
890
+ 424,
891
+ 823,
892
+ 452
893
+ ],
894
+ "page_idx": 8
895
+ },
896
+ {
897
+ "type": "text",
898
+ "text": "Sanjoy Dasgupta. Analysis of a greedy active learning strategy. In Advances in neural information processing systems, pp. 337–344, 2005. ",
899
+ "bbox": [
900
+ 173,
901
+ 462,
902
+ 823,
903
+ 492
904
+ ],
905
+ "page_idx": 8
906
+ },
907
+ {
908
+ "type": "text",
909
+ "text": "Jeffrey De Fauw, Joseph R Ledsam, Bernardino Romera-Paredes, Stanislav Nikolov, Nenad Tomasev, Sam Blackwell, Harry Askham, Xavier Glorot, Brendan ODonoghue, Daniel Visentin, et al. Clinically applicable deep learning for diagnosis and referral in retinal disease. Nature medicine, 24(9):1342, 2018. ",
910
+ "bbox": [
911
+ 173,
912
+ 501,
913
+ 825,
914
+ 558
915
+ ],
916
+ "page_idx": 8
917
+ },
918
+ {
919
+ "type": "text",
920
+ "text": "Stefan Depeweg, Jose Miguel Hern ´ andez-Lobato, Finale Doshi-Velez, and Steffen Udluft. Un- ´ certainty decomposition in bayesian neural networks with latent variables. arXiv preprint arXiv:1706.08495, 2017. ",
921
+ "bbox": [
922
+ 173,
923
+ 568,
924
+ 825,
925
+ 611
926
+ ],
927
+ "page_idx": 8
928
+ },
929
+ {
930
+ "type": "text",
931
+ "text": "Melanie Ducoffe and Frederic Precioso. Adversarial active learning for deep networks: a margin based approach. arXiv preprint arXiv:1802.09841, 2018. ",
932
+ "bbox": [
933
+ 171,
934
+ 619,
935
+ 821,
936
+ 650
937
+ ],
938
+ "page_idx": 8
939
+ },
940
+ {
941
+ "type": "text",
942
+ "text": "Linton C Freeman. Elementary applied statistics: for students in behavioral science. John Wiley & Sons, 1965. ",
943
+ "bbox": [
944
+ 174,
945
+ 659,
946
+ 823,
947
+ 688
948
+ ],
949
+ "page_idx": 8
950
+ },
951
+ {
952
+ "type": "text",
953
+ "text": "Yarin Gal. Uncertainty in deep learning. University of Cambridge, 2016. ",
954
+ "bbox": [
955
+ 173,
956
+ 698,
957
+ 653,
958
+ 714
959
+ ],
960
+ "page_idx": 8
961
+ },
962
+ {
963
+ "type": "text",
964
+ "text": "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, 2016. ",
965
+ "bbox": [
966
+ 174,
967
+ 723,
968
+ 826,
969
+ 765
970
+ ],
971
+ "page_idx": 8
972
+ },
973
+ {
974
+ "type": "text",
975
+ "text": "Yarin Gal, Riashat Islam, and Zoubin Ghahramani. Deep bayesian active learning with image data. arXiv preprint arXiv:1703.02910, 2017. ",
976
+ "bbox": [
977
+ 173,
978
+ 775,
979
+ 821,
980
+ 805
981
+ ],
982
+ "page_idx": 8
983
+ },
984
+ {
985
+ "type": "text",
986
+ "text": "HA Haenssle, C Fink, R Schneiderbauer, F Toberer, T Buhl, A Blum, A Kalloo, A Hassen, L Thomas, A Enk, et al. Man against machine: diagnostic performance of a deep learning convolutional neural network for dermoscopic melanoma recognition in comparison to 58 dermatologists. Annals of Oncology, 2018. ",
987
+ "bbox": [
988
+ 174,
989
+ 814,
990
+ 825,
991
+ 872
992
+ ],
993
+ "page_idx": 8
994
+ },
995
+ {
996
+ "type": "text",
997
+ "text": "Geoffrey E Hinton and Drew Van Camp. Keeping the neural networks simple by minimizing the description length of the weights. In Proceedings of the sixth annual conference on Computational learning theory, pp. 5–13. ACM, 1993. ",
998
+ "bbox": [
999
+ 174,
1000
+ 882,
1001
+ 823,
1002
+ 924
1003
+ ],
1004
+ "page_idx": 8
1005
+ },
1006
+ {
1007
+ "type": "text",
1008
+ "text": "Matthew D Hoffman, David M Blei, Chong Wang, and John Paisley. Stochastic variational inference. The Journal of Machine Learning Research, 14(1):1303–1347, 2013. ",
1009
+ "bbox": [
1010
+ 171,
1011
+ 104,
1012
+ 823,
1013
+ 133
1014
+ ],
1015
+ "page_idx": 9
1016
+ },
1017
+ {
1018
+ "type": "text",
1019
+ "text": "Steven CH Hoi, Rong Jin, Jianke Zhu, and Michael R Lyu. Batch mode active learning and its application to medical image classification. In Proceedings of the 23rd international conference on Machine learning, pp. 417–424. ACM, 2006. ",
1020
+ "bbox": [
1021
+ 173,
1022
+ 143,
1023
+ 825,
1024
+ 188
1025
+ ],
1026
+ "page_idx": 9
1027
+ },
1028
+ {
1029
+ "type": "text",
1030
+ "text": "Neil Houlsby, Ferenc Huszar, Zoubin Ghahramani, and M ´ at´ e Lengyel. Bayesian active learning for ´ classification and preference learning. arXiv preprint arXiv:1112.5745, 2011. ",
1031
+ "bbox": [
1032
+ 173,
1033
+ 196,
1034
+ 821,
1035
+ 227
1036
+ ],
1037
+ "page_idx": 9
1038
+ },
1039
+ {
1040
+ "type": "text",
1041
+ "text": "Christoph Kading, Erik Rodner, Alexander Freytag, and Joachim Denzler. Active and continu- ¨ ous exploration with deep neural networks and expected model output changes. arXiv preprint arXiv:1612.06129, 2016. ",
1042
+ "bbox": [
1043
+ 173,
1044
+ 236,
1045
+ 825,
1046
+ 280
1047
+ ],
1048
+ "page_idx": 9
1049
+ },
1050
+ {
1051
+ "type": "text",
1052
+ "text": "Alex Kendall, Vijay Badrinarayanan, and Roberto Cipolla. Bayesian segnet: Model uncertainty in deep convolutional encoder-decoder architectures for scene understanding. arXiv preprint arXiv:1511.02680, 2015. ",
1053
+ "bbox": [
1054
+ 173,
1055
+ 289,
1056
+ 823,
1057
+ 332
1058
+ ],
1059
+ "page_idx": 9
1060
+ },
1061
+ {
1062
+ "type": "text",
1063
+ "text": "Diederik $\\mathrm { \\bf P }$ Kingma and Max Welling. Auto-encoding variational bayes. arXiv preprint arXiv:1312.6114, 2013. ",
1064
+ "bbox": [
1065
+ 171,
1066
+ 342,
1067
+ 825,
1068
+ 372
1069
+ ],
1070
+ "page_idx": 9
1071
+ },
1072
+ {
1073
+ "type": "text",
1074
+ "text": "Alex Krizhevsky and Geoffrey Hinton. Learning multiple layers of features from tiny images. Technical report, Citeseer, 2009. ",
1075
+ "bbox": [
1076
+ 173,
1077
+ 381,
1078
+ 821,
1079
+ 411
1080
+ ],
1081
+ "page_idx": 9
1082
+ },
1083
+ {
1084
+ "type": "text",
1085
+ "text": "Alex Krizhevsky, Ilya Sutskever, and Geoffrey E Hinton. Imagenet classification with deep convolutional neural networks. In Advances in neural information processing systems, pp. 1097–1105, 2012. ",
1086
+ "bbox": [
1087
+ 174,
1088
+ 420,
1089
+ 825,
1090
+ 463
1091
+ ],
1092
+ "page_idx": 9
1093
+ },
1094
+ {
1095
+ "type": "text",
1096
+ "text": "Balaji Lakshminarayanan, Alexander Pritzel, and Charles Blundell. Simple and scalable predictive uncertainty estimation using deep ensembles. In Advances in Neural Information Processing Systems, pp. 6402–6413, 2017. ",
1097
+ "bbox": [
1098
+ 174,
1099
+ 473,
1100
+ 825,
1101
+ 517
1102
+ ],
1103
+ "page_idx": 9
1104
+ },
1105
+ {
1106
+ "type": "text",
1107
+ "text": "Jiangwei Lao, Yinsheng Chen, Zhi-Cheng Li, Qihua Li, Ji Zhang, Jing Liu, and Guangtao Zhai. A deep learning-based radiomics model for prediction of survival in glioblastoma multiforme. Scientific reports, 7(1):10353, 2017. ",
1108
+ "bbox": [
1109
+ 176,
1110
+ 526,
1111
+ 821,
1112
+ 570
1113
+ ],
1114
+ "page_idx": 9
1115
+ },
1116
+ {
1117
+ "type": "text",
1118
+ "text": "Neil David Lawrence. Variational inference in probabilistic models. PhD thesis, University of Cambridge, 2001. ",
1119
+ "bbox": [
1120
+ 171,
1121
+ 580,
1122
+ 823,
1123
+ 609
1124
+ ],
1125
+ "page_idx": 9
1126
+ },
1127
+ {
1128
+ "type": "text",
1129
+ "text": "Yann LeCun. The mnist database of handwritten digits. http://yann. lecun. com/exdb/mnist/, 1998. ",
1130
+ "bbox": [
1131
+ 174,
1132
+ 619,
1133
+ 818,
1134
+ 636
1135
+ ],
1136
+ "page_idx": 9
1137
+ },
1138
+ {
1139
+ "type": "text",
1140
+ "text": "Yann LeCun, Yoshua Bengio, and Geoffrey Hinton. Deep learning. Nature, 521(7553):436–444, 2015. ",
1141
+ "bbox": [
1142
+ 174,
1143
+ 645,
1144
+ 821,
1145
+ 674
1146
+ ],
1147
+ "page_idx": 9
1148
+ },
1149
+ {
1150
+ "type": "text",
1151
+ "text": "Christian Leibig, Vaneeda Allken, Murat Sec¸kin Ayhan, Philipp Berens, and Siegfried Wahl. Leveraging uncertainty information from deep neural networks for disease detection. Scientific reports, 7(1):17816, 2017. ",
1152
+ "bbox": [
1153
+ 173,
1154
+ 684,
1155
+ 825,
1156
+ 728
1157
+ ],
1158
+ "page_idx": 9
1159
+ },
1160
+ {
1161
+ "type": "text",
1162
+ "text": "Xiao Lin and Devi Parikh. Active learning for visual question answering: An empirical study. arXiv preprint arXiv:1711.01732, 2017. ",
1163
+ "bbox": [
1164
+ 174,
1165
+ 737,
1166
+ 825,
1167
+ 767
1168
+ ],
1169
+ "page_idx": 9
1170
+ },
1171
+ {
1172
+ "type": "text",
1173
+ "text": "Radford M Neal. Bayesian learning for neural networks, volume 118. Springer Science & Business Media, 2012. ",
1174
+ "bbox": [
1175
+ 171,
1176
+ 776,
1177
+ 825,
1178
+ 806
1179
+ ],
1180
+ "page_idx": 9
1181
+ },
1182
+ {
1183
+ "type": "text",
1184
+ "text": "John Paisley, David Blei, and Michael Jordan. Variational bayesian inference with stochastic search. arXiv preprint arXiv:1206.6430, 2012. ",
1185
+ "bbox": [
1186
+ 169,
1187
+ 815,
1188
+ 823,
1189
+ 845
1190
+ ],
1191
+ "page_idx": 9
1192
+ },
1193
+ {
1194
+ "type": "text",
1195
+ "text": "Christian Robert and George Casella. Monte Carlo statistical methods. Springer Science & Business Media, 2013. ",
1196
+ "bbox": [
1197
+ 171,
1198
+ 854,
1199
+ 825,
1200
+ 885
1201
+ ],
1202
+ "page_idx": 9
1203
+ },
1204
+ {
1205
+ "type": "text",
1206
+ "text": "Ozan Sener and Silvio Savarese. Active learning for convolutional neural networks: Acore-set approach. stat, 1050:27, 2017. ",
1207
+ "bbox": [
1208
+ 174,
1209
+ 895,
1210
+ 823,
1211
+ 924
1212
+ ],
1213
+ "page_idx": 9
1214
+ },
1215
+ {
1216
+ "type": "text",
1217
+ "text": "Burr Settles. Active learning. Synthesis Lectures on Artificial Intelligence and Machine Learning, 6 (1):1–114, 2012. ",
1218
+ "bbox": [
1219
+ 173,
1220
+ 104,
1221
+ 823,
1222
+ 133
1223
+ ],
1224
+ "page_idx": 10
1225
+ },
1226
+ {
1227
+ "type": "text",
1228
+ "text": "Claude Elwood Shannon. A mathematical theory of communication. ACM SIGMOBILE mobile computing and communications review, 5(1):3–55, 2001. ",
1229
+ "bbox": [
1230
+ 173,
1231
+ 143,
1232
+ 825,
1233
+ 172
1234
+ ],
1235
+ "page_idx": 10
1236
+ },
1237
+ {
1238
+ "type": "text",
1239
+ "text": "Yanyao Shen, Hyokun Yun, Zachary C Lipton, Yakov Kronrod, and Animashree Anandkumar. Deep active learning for named entity recognition. arXiv preprint arXiv:1707.05928, 2017. ",
1240
+ "bbox": [
1241
+ 173,
1242
+ 181,
1243
+ 823,
1244
+ 212
1245
+ ],
1246
+ "page_idx": 10
1247
+ },
1248
+ {
1249
+ "type": "text",
1250
+ "text": "Justin S Smith, Ben Nebgen, Nicholas Lubbers, Olexandr Isayev, and Adrian E Roitberg. Less is more: Sampling chemical space with active learning. The Journal of Chemical Physics, 148(24): 241733, 2018. ",
1251
+ "bbox": [
1252
+ 173,
1253
+ 220,
1254
+ 823,
1255
+ 263
1256
+ ],
1257
+ "page_idx": 10
1258
+ },
1259
+ {
1260
+ "type": "text",
1261
+ "text": "Lewis Smith and Yarin Gal. Understanding measures of uncertainty for adversarial example detection. arXiv preprint arXiv:1803.08533, 2018. ",
1262
+ "bbox": [
1263
+ 171,
1264
+ 273,
1265
+ 821,
1266
+ 304
1267
+ ],
1268
+ "page_idx": 10
1269
+ },
1270
+ {
1271
+ "type": "text",
1272
+ "text": "Akash Srivastava, Lazar Valkoz, Chris Russell, Michael U Gutmann, and Charles Sutton. Veegan: Reducing mode collapse in gans using implicit variational learning. In Advances in Neural Information Processing Systems, pp. 3308–3318, 2017. ",
1273
+ "bbox": [
1274
+ 173,
1275
+ 313,
1276
+ 823,
1277
+ 357
1278
+ ],
1279
+ "page_idx": 10
1280
+ },
1281
+ {
1282
+ "type": "text",
1283
+ "text": "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. ",
1284
+ "bbox": [
1285
+ 178,
1286
+ 366,
1287
+ 823,
1288
+ 409
1289
+ ],
1290
+ "page_idx": 10
1291
+ },
1292
+ {
1293
+ "type": "text",
1294
+ "text": "Keze Wang, Dongyu Zhang, Ya Li, Ruimao Zhang, and Liang Lin. Cost-effective active learning for deep image classification. IEEE Transactions on Circuits and Systems for Video Technology, 2016. ",
1295
+ "bbox": [
1296
+ 174,
1297
+ 419,
1298
+ 823,
1299
+ 462
1300
+ ],
1301
+ "page_idx": 10
1302
+ },
1303
+ {
1304
+ "type": "text",
1305
+ "text": "Zheng Wang and Jieping Ye. Querying discriminative and representative samples for batch mode active learning. ACM Transactions on Knowledge Discovery from Data (TKDD), 9(3):17, 2015. ",
1306
+ "bbox": [
1307
+ 171,
1308
+ 472,
1309
+ 823,
1310
+ 501
1311
+ ],
1312
+ "page_idx": 10
1313
+ },
1314
+ {
1315
+ "type": "text",
1316
+ "text": "Ye Zhang, Matthew Lease, and Byron C Wallace. Active discriminative text representation learning. In AAAI, pp. 3386–3392, 2017. ",
1317
+ "bbox": [
1318
+ 176,
1319
+ 511,
1320
+ 823,
1321
+ 540
1322
+ ],
1323
+ "page_idx": 10
1324
+ },
1325
+ {
1326
+ "type": "text",
1327
+ "text": "Appendices ",
1328
+ "text_level": 1,
1329
+ "bbox": [
1330
+ 176,
1331
+ 99,
1332
+ 343,
1333
+ 127
1334
+ ],
1335
+ "page_idx": 11
1336
+ },
1337
+ {
1338
+ "type": "image",
1339
+ "img_path": "images/5e937a5ee2e5a7ce0c98ee8fa8b1addf5bfc449b5d8bf1c23e8adfa4f5152b46.jpg",
1340
+ "image_caption": [
1341
+ "Figure 7: MNIST histograms of the top 1,000 most uncertain samples from test set as ranked by the LeNet model trained on the entire training set. "
1342
+ ],
1343
+ "image_footnote": [],
1344
+ "bbox": [
1345
+ 187,
1346
+ 165,
1347
+ 799,
1348
+ 337
1349
+ ],
1350
+ "page_idx": 11
1351
+ },
1352
+ {
1353
+ "type": "image",
1354
+ "img_path": "images/fe9ae034b83785e93f1f3c233ffc4cae1d8f898ecfc0e1daf5a8b34f4a639390.jpg",
1355
+ "image_caption": [
1356
+ "Figure 8: MNIST confusion matrix for the models at the end of the AL process. Test set: 10,000. Additionally, the fully trained model (top left) is shown as baseline. "
1357
+ ],
1358
+ "image_footnote": [],
1359
+ "bbox": [
1360
+ 168,
1361
+ 244,
1362
+ 810,
1363
+ 724
1364
+ ],
1365
+ "page_idx": 12
1366
+ },
1367
+ {
1368
+ "type": "image",
1369
+ "img_path": "images/7b63b1863e3fc79d84dbffbae42a309068c56a047c0549eccf1a95ccf3d46121.jpg",
1370
+ "image_caption": [
1371
+ "Figure 9: MNIST histogram of true labels in the training set after 8 acquisition iterations. Total number of images in training set: 100 Top: Single MC-Dropout network. Bottom: Ensemble of three networks of similar architecture but different random initialization. "
1372
+ ],
1373
+ "image_footnote": [],
1374
+ "bbox": [
1375
+ 174,
1376
+ 117,
1377
+ 805,
1378
+ 373
1379
+ ],
1380
+ "page_idx": 13
1381
+ },
1382
+ {
1383
+ "type": "image",
1384
+ "img_path": "images/71f6fc3cdb3db4a4054695add8ba6a3e8977c60758a34a05be9d491de20f5c7a.jpg",
1385
+ "image_caption": [
1386
+ "Figure 10: Uncertainty visualization in latent space. MNIST dataset removed for a clearer visualization of the uncertainty. Uncertainty is in white (a lighter background corresponds to higher uncertainty while a darker one represents regions of lower uncertainty) Top: Uncertainty obtained at the end of the AL process using an ensemble of three similar networks. Bottom: Uncertainty obtained at the end of the AL process using a single network. "
1387
+ ],
1388
+ "image_footnote": [],
1389
+ "bbox": [
1390
+ 173,
1391
+ 478,
1392
+ 810,
1393
+ 804
1394
+ ],
1395
+ "page_idx": 13
1396
+ },
1397
+ {
1398
+ "type": "image",
1399
+ "img_path": "images/1a66dfce36977bb29ea249c7c6298e8eb296c51e0c321ab000e6c55725d68ac3.jpg",
1400
+ "image_caption": [
1401
+ "Figure 11: tSNE embeddings of the MNIST dataset. Effect of using an ensemble of three similar models (stochastic or deterministic) instead of one single MC-Dropout network. Orange points correspond to images acquired during the AL process. "
1402
+ ],
1403
+ "image_footnote": [],
1404
+ "bbox": [
1405
+ 181,
1406
+ 247,
1407
+ 754,
1408
+ 699
1409
+ ],
1410
+ "page_idx": 14
1411
+ }
1412
+ ]
parse/train/Byx93sC9tm/Byx93sC9tm_middle.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/Byx93sC9tm/Byx93sC9tm_model.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/HyxGB2AcY7/HyxGB2AcY7.md ADDED
@@ -0,0 +1,367 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # CONTINGENCY-AWARE EXPLORATION IN REINFORCEMENT LEARNING
2
+
3
+ Jongwook Choi∗,1 Yijie Guo∗,1 Marcin Moczulski $^ { * , 2 }$ Junhyuk $\mathbf { O h } ^ { 1 , \dagger }$ Neal Wu2 Mohammad Norouzi2 Honglak Lee2,1
4
+
5
+ 1University of Michigan 2Google Brain {jwook,guoyijie}@umich.edu moczulski@google.com {junhyuk,nealwu,mnorouzi,honglak}@google.com
6
+
7
+ # ABSTRACT
8
+
9
+ This paper investigates whether learning contingency-awareness and controllable aspects of an environment can lead to better exploration in reinforcement learning. To investigate this question, we consider an instantiation of this hypothesis evaluated on the Arcade Learning Element (ALE). In this study, we develop an attentive dynamics model (ADM) that discovers controllable elements of the observations, which are often associated with the location of the character in Atari games. The ADM is trained in a self-supervised fashion to predict the actions taken by the agent. The learned contingency information is used as a part of the state representation for exploration purposes. We demonstrate that combining actor-critic algorithm with count-based exploration using our representation achieves impressive results on a set of notoriously challenging Atari games due to sparse rewards.1 For example, we report a state-of-the-art score of ${ > } 1 1 { , } 0 0 0$ points on MONTEZUMA’S REVENGE without using expert demonstrations, explicit high-level information (e.g., RAM states), or supervisory data. Our experiments confirm that contingency-awareness is indeed an extremely powerful concept for tackling exploration problems in reinforcement learning and opens up interesting research questions for further investigations.
10
+
11
+ # 1 INTRODUCTION
12
+
13
+ The success of reinforcement learning (RL) algorithms in complex environments hinges on the way they balance exploration and exploitation. There has been a surge of recent interest in developing effective exploration strategies for problems with high-dimensional state spaces and sparse rewards (Schmidhuber, 1991; Oudeyer & Kaplan, 2009; Houthooft et al., 2016; Bellemare et al., 2016; Osband et al., 2016; Pathak et al., 2017; Plappert et al., 2018; Zheng et al., 2018). Deep neural networks have seen great success as expressive function approximators within RL and as powerful representation learning methods for many domains. In addition, there have been recent studies on using neural network representations for exploration (Tang et al., 2017; Martin et al., 2017; Pathak et al., 2017). For example, count-based exploration with neural density estimation (Bellemare et al., 2016; Tang et al., 2017; Ostrovski et al., 2017) presents one of the state-of-the-art techniques on the most challenging Atari games with sparse rewards.
14
+
15
+ Despite the success of recent exploration methods, it is still an open question on how to construct an optimal representation for exploration. For example, the concept of visual similarity is used for learning density models as a basis for calculating pseudo-counts (Bellemare et al., 2016; Ostrovski et al., 2017). However, as Tang et al. (2017) noted, the ideal way to represent states should be based on what is relevant to solving the MDP, rather than only relying on visual similarity. In addition, there remains another question on whether the representations used for recent exploration works are easily interpretable. To address these questions, we investigate whether we can learn a complementary, more intuitive, and interpretable high-level abstraction that can be very effective in exploration by using the ideas of contingency awareness and controllable dynamics.
16
+
17
+ The key idea that we focus on in this work is the notion of contingency awareness (Watson, 1966; Bellemare et al., 2012) — the agent’s understanding of the environmental dynamics and recognizing that some aspects of the dynamics are under the agent’s control. Intuitively speaking, this can represent the segmentation mask of the agent operating in the 2D or 3D environments (yet one can think of more abstract and general state spaces). In this study, we investigate the concept of contingency awareness based on self-localization, i.e., the awareness of where the agent is located in the abstract state space. We are interested in discovering parts of the world that are directly dependent on the agent’s immediate action, which often reveal the agent’s approximate location.
18
+
19
+ For further motivation on the problem, we note that contingency awareness is a very important concept in neuroscience and psychology. In other words, being self-aware of one’s location is an important property within many observed intelligent organisms and systems. For example, recent breakthroughs in neuroscience, such as the Nobel Prize winning work on the grid cells (Moser et al., 2015; Banino et al., 2018), show that organisms that perform very well in spatially-challenging tasks are self-aware of their location. This allows rats to navigate, remember paths to previously visited places and important sub-goals, and find shortcuts. In addition, the notion of contingency awareness has been shown as an important factor in developmental psychology (Watson, 1966; Baeyens et al., 1990). We can think of self-localization (and more broadly self-awareness) as a principled and fundamental direction towards intelligent agents.
20
+
21
+ Based on these discussions, we hypothesize that contingency awareness can be a powerful mechanism for tackling exploration problems in reinforcement learning. We consider an instantiation of this hypothesis evaluated on the Arcade Learning Element (ALE). For example, in the context of 2D Atari games, contingency-awareness roughly corresponds to understanding the notion of controllable entities (e.g., the player’s avatar), which Bellemare et al. (2012) refer to as contingent regions. More concretely, as shown in Figure 1, in the game FREEWAY, only the chicken sprite is under the agent’s control and not the multiple moving cars; therefore the chicken’s location should be an informative element for exploration (Bellemare et al., 2012; Pathak et al., 2017).
22
+
23
+ In this study, we also investigate whether contingency awareness can be learned without any external annotations or supervision. For this, we provide an instantiation of an algorithm for automatically learning such information and using it for improving exploration on a 2D ALE environment (Bellemare et al., 2013). Concretely, we employ an attentive dynamics model (ADM) to predict the agent’s action chosen between consecutive states. It allows us to approximate the agent’s position in 2D environments, but unlike other approaches such as (Bellemare et al., 2012), it does not require any additional supervision to do so. The ADM learns in an online and self-supervised fashion with pure observations as the agent’s policy is updated and does not require hand-crafted features, an environment simulator, or supervision labels for training.
24
+
25
+ In experimental evaluation, our methods significantly improve the performance of A2C on hardexploration Atari games in comparison with competitive methods such as density-based exploration (Bellemare et al., 2016; Ostrovski et al., 2017) and SimHash (Tang et al., 2017). We report very strong results on sparse-reward Atari games, including the state-of-the-art performance on the notoriously difficult MONTEZUMA’S REVENGE, when combining our proposed exploration strategy with PPO (Schulman et al., 2017), without using expert demonstrations, explicit high-level information (e.g., RAM states), or resetting the environment to an arbitrary state.
26
+
27
+ We summarize our contributions as follows:
28
+
29
+ • We demonstrate the importance of learning contingency awareness for efficient exploration in challenging sparse-reward RL problems. • We develop a novel instance of attentive dynamics model using contingency and controllable dynamics to provide robust localization abilities across the most challenging Atari environments. • We achieve a strong performance on difficult sparse-reward Atari games, including the state-ofthe-art score on the notoriously challenging MONTEZUMA’S REVENGE.
30
+
31
+ Overall, we believe that our experiments confirm the hypothesis that contingency awareness is an extremely powerful concept for tackling exploration problems in reinforcement learning, which opens up interesting research questions for further investigations.
32
+
33
+ ![](images/018b0299735a868ce7d476f2807806134fae950d5519ef9ff1de18773f331677.jpg)
34
+ Figure 1: Left: Contingent region in FREEWAY; an object in a red box denotes what is under the agent’s control, whereas the rest is not. Right: A diagram for the proposed ADM architecture.
35
+
36
+ # 2 RELATED WORK
37
+
38
+ Self-Localization. The discovery of grid cells (Moser et al., 2015) motivates working on agents that are self-aware of their location. Banino et al. (2018) emphasize the importance of self-localization and train a neural network which learns a similar mechanism to grid cells to perform tasks related to spatial navigation. The presence of grid cells is correlated with high performance. Although grid cells seem tailored to 2D or 3D problems that animals encounter in their life, it is speculated that their use can be extended to more abstract spaces. A set of potential approaches to self-localization ranges from ideas specific to a given environment, e.g., SLAM (Durrant-Whyte & Bailey, 2006), to methods with potential generalizability (Mirowski et al., 2017; Jaderberg et al., 2017; Mirowski et al., 2018).
39
+
40
+ Self-supervised Dynamics Model and Controllable Dynamics. Several works have used forward and/or inverse dynamics models of the environment (Oh et al., 2015; Agrawal et al., 2016; Shelhamer et al., 2017). Pathak et al. (2017) employ a similar dynamics model to learn feature representations of states that captures controllable aspects of the environment. This dense representation is used to design a curiosity-driven intrinsic reward. The idea of learning representations on relevant aspects of the environment by learning auxiliary tasks is also explored in (Jaderberg et al., 2017; Bengio et al., 2017; Sawada, 2018). Our presented approach is different as we focus on explicitly discovering controllable aspects using an attention mechanism, resulting in better interpretability.
41
+
42
+ Exploration and Intrinsic Motivation. The idea of providing an exploration bonus reward depending on the state-action visit-count was proposed by Strehl & Littman (2008) (MBIE-EB), originally under a tabular setting. Later it has been combined with different techniques to deal with high-dimensional state spaces. Bellemare et al. (2016) use a Context-Tree Switching (CTS) density model to derive a state pseudo-count, whereas Ostrovski et al. (2017) use PixelCNN as a state density estimator. Martin et al. (2017) also construct a visitation density model over a compressed feature space rather than the raw observation space. Alternatively, Tang et al. (2017) propose a localitysensitive hashing (LSH) method to cluster states and maintain a state-visitation counter based on a form of similarity between frames. We train an agent with a similar count-based exploration bonus, but the way of maintaining state counter seems relatively simpler in that key feature information (i.e., controllable region) is explicitly extracted from the observation and directly used for counting states.
43
+
44
+ Another popular family of exploration strategies in RL uses intrinsic motivation (Schmidhuber, 1991; Singh et al., 2004; Oudeyer & Kaplan, 2009; Barto, 2013). These methods encourage the agent to look for something surprising in the environment which motivates its search for novel states, such as surprise (Achiam & Sastry, 2017), curiosity (Pathak et al., 2017; Burda et al., 2018), and diversity (Eysenbach et al., 2018), or via feature control (Jaderberg et al., 2017; Dilokthanakul et al., 2017).
45
+
46
+ # 3 APPROACH
47
+
48
+ # 3.1 DISCOVERING CONTINGENCY VIA ATTENTIVE DYNAMICS MODEL
49
+
50
+ To discover the region of the observation that is controllable by the agent, we develop an instance of attentive dynamics model (ADM) based on inverse dynamics $f _ { \mathrm { i n v } }$ . The model takes two consecutive input frames (observations) $s _ { t - 1 } , s _ { t } \in S$ as input and aims to predict the action $( a _ { t - 1 } \in \mathcal { A } )$ taken by
51
+
52
+ the agent to transition from $s _ { t - 1 }$ to $s _ { t }$
53
+
54
+ $$
55
+ \widehat { a } _ { t - 1 } = f _ { \mathrm { i n v } } ( s _ { t - 1 } , s _ { t } ) .
56
+ $$
57
+
58
+ Our key intuition is that the inverse dynamics model should attend to the most relevant part of the observation, which is controllable by the agent, to be able to classify the actions. We determine whether each region in a $H \times W$ grid is controllable, or in other words, useful for predicting the agent’s action, by using a spatial attention mechanism (Bahdanau et al., 2015; Xu et al., 2015). An overview of the model is shown in Figure 1.
59
+
60
+ Model. To perform action classification, we first compute a convolutional feature map $\phi _ { t } ^ { s } = \phi ( s _ { t } ) \in$ $\mathbb { R } ^ { H \times W \times K }$ based on the observation $s _ { t }$ using a convolutional neural network $\phi$ . We estimate a set of logit (score) vectors, denoted $e _ { t } ( i , j ) \in \mathbb { R } ^ { | \mathcal { A } | }$ , for action classification from each grid cell $( i , j )$ of the convolutional feature map. The local convolution features and feature differences for consecutive frames are fed into a shared multi-layer perceptron (MLP) to derive the logits as:
61
+
62
+ $$
63
+ \begin{array} { r } { e _ { t } ( i , j ) = \mathrm { M L P } \Big ( \big [ \phi _ { t } ^ { s } ( i , j ) - \phi _ { t - 1 } ^ { s } ( i , j ) ; ~ \phi _ { t } ^ { s } ( i , j ) \big ] \Big ) \in \mathbb { R } ^ { | \cal { A } | } . } \end{array}
64
+ $$
65
+
66
+ We then compute an attention mask $\alpha _ { t } \in \mathbb { R } ^ { H \times W }$ corresponding to frame $t$ , which indicates the controllable parts of the observation $s _ { t }$ . Such attention masks are computed via a separate MLP from the features of each region $( i , j )$ , and then converted into a probability distribution using softmax or sparsemax operators (Martins $\&$ Astudillo, 2016):
67
+
68
+ $$
69
+ \alpha _ { t } = \mathrm { s p a r s e m a x } ( \widetilde { \alpha } _ { t } ) \quad \mathrm { w h e r e } \quad \widetilde { \alpha } _ { t } ( i , j ) = \mathrm { M L P } \big ( \phi _ { t } ^ { s } ( i , j ) \big ) ,
70
+ $$
71
+
72
+ so that $\begin{array} { r } { \sum _ { i , j } \alpha _ { t } ( i , j ) = 1 } \end{array}$ . The sparsemax operator is similar to softmax but yields a sparse attention, leading to more stable performance. Finally, the logits $e _ { t } ( i , j )$ from all regions are linearly combined using the attention probabilities $\alpha _ { t }$ :
73
+
74
+ $$
75
+ \begin{array} { r } { p ( \widehat { a } _ { t - 1 } \mid s _ { t - 1 } , s _ { t } ) = \mathrm { s o f t m a x } \Big ( \sum _ { i , j } \alpha _ { t } ( i , j ) \cdot e _ { t } ( i , j ) \Big ) \in \mathbb { R } ^ { | \mathcal { A } | } . } \end{array}
76
+ $$
77
+
78
+ Training. The model can be optimized with the standard cross-entropy loss $\mathcal { L } _ { \mathrm { a c t i o n } } \big ( a _ { t - 1 } ^ { * } , \widehat { a } _ { t - 1 } \big )$ with respect to the ground-truth action $a _ { t - 1 } ^ { * } \in { \mathcal { A } }$ bthat the agent actually has taken. Based on this formulation, the attention probability $\alpha _ { t } ( i , j )$ should be high only on regions $( i , j )$ that are predictive of the agent’s actions. Our formulation enables learning to localize controllable entities in a selfsupervised way without any additional supervisory signal, unlike some prior work (e.g., (Bellemare et al., 2012)) that adopts simulators to collect extra supervisory labels.
79
+
80
+ Optimizing the parameters of ADM on on-policy data is challenging for several reasons. First, the ground-truth action may be unpredictable for given pairs of frames, leading to noisy labels. For example, actions taken in uncontrollable situations do not have any effect (e.g., when the agent is in the middle of jumping in MONTEZUMA’S REVENGE). Second, since we train the ADM online along with the policy, the training examples are not independently and identically distributed, and the data distribution can shift dramatically over time. Third, the action distribution from the agent’s policy can run into a low entropy2, being biased towards certain actions. These issues may prevent the ADM from generalization to novel observations, which hurts exploration. Generally, we prefer models that quickly adapt to the policy and learn to localize the controllable regions in a robust manner.
81
+
82
+ To mitigate the aforementioned issues, we adopt a few additional objective functions. We encourage the attention distribution to attain a high entropy by including an attention entropy regularization loss, i.e., ${ \mathcal { L } } _ { \mathrm { e n t } } = - { \mathcal { H } } ( \alpha _ { t } )$ . This term penalizes over-confident attention masks, making the attention closer to uniform whenever action prediction is not possible. We also train the logits corresponding to each grid cell independently using a separate cross-entropy loss: $p ( \widehat { a } _ { t - 1 } ^ { i , j } \mid e _ { t } ( i , j ) ) = \mathrm { s o f t m a x } ( e _ { t } ( i , j ) )$ . These additional cross-entropy losses, denoted $\mathcal { L } _ { \mathrm { c e l l } } ^ { i , j }$ b , allow the model to learn from unseen observations even when attention fails to perform well at first. The entire training objective becomes:
83
+
84
+ $$
85
+ \begin{array} { r } { \mathcal { L } ^ { \mathrm { A D M } } = \mathcal { L } _ { \mathrm { a c t i o n } } + \sum _ { i , j } \mathcal { L } _ { \mathrm { c e l l } } ^ { i , j } + \lambda _ { \mathrm { e n t } } \mathcal { L } _ { \mathrm { e n t } } } \end{array}
86
+ $$
87
+
88
+ where $\lambda _ { \mathrm { e n t } }$ is a mixing hyperparameter.
89
+
90
+ # 3.2 COUNT-BASED EXPLORATION WITH CONTINGENT REGIONS
91
+
92
+ One natural way to take advantage of discovered contingent regions for exploration is count-based exploration. The ADM can be used to localize the controllable entity (e.g., the agent’s avatar)
93
+
94
+ ![](images/bd11c0917306d6504412ef5291030b1224e067561b045a15333f3635c7d3c6cd.jpg)
95
+ Figure 2: Learning curves on several Atari games: $_ { \mathrm { A 2 C + C o E X } }$ and A2C. The $\mathbf { X }$ -axis represents total environment steps and the y-axis the mean episode reward averaged over 40 recent episodes. The mean curve is obtained by averaging over 3 random seeds, each shown in a light color.
96
+
97
+ from an observation $s _ { t }$ experienced by the agent. In 2D environments, a natural discretization $( x , y ) = \mathrm { a r g m a x } _ { ( j , i ) } \alpha _ { t } ( i , j )$ provides a good approximation of the agent’s location within the current observation3. This provides a key piece of information about the current state of the agent.
98
+
99
+ Inspired by previous work (Bellemare et al., 2016; Tang et al., 2017), we add an exploration bonus of $r ^ { + }$ to the environment reward, where $r ^ { + } ( s ) = 1 / \sqrt { \# ( \psi ( s ) ) }$ and $\# ( \psi ( s ) )$ denotes the visitation count of the (discrete) mapped state $\psi ( s )$ , which consists of the contingent region $( x , y )$ . We want to find a policy $\pi$ that maximizes the expected discounted sum of environment rewards $r ^ { \mathrm { e x t } }$ plus count-based exploration rewards $r ^ { + }$ , denoted $\begin{array} { r } { \mathcal { R } = \mathbb { E } _ { \pi } \big [ \sum _ { t } \gamma ^ { t } \left( \beta _ { 1 } r ^ { \mathrm { e x t } } ( s _ { t } , a _ { t } ) + \beta _ { 2 } r ^ { + } ( s _ { t } ) \right) \big ] } \end{array}$ , where $\beta _ { 1 } , \beta _ { 2 } \geq 0$ are hyperparameters that balance the weight of environment reward and exploration bonus. For every state $s _ { t }$ encountered at time step $t$ , we increase the counter value $\# ( \psi ( s _ { t } ) )$ by 1 during training. The full procedure is summarized in Algorithm 1 in Appendix A.
100
+
101
+ # 4 EXPERIMENTS
102
+
103
+ In the experiments below we investigate the following key questions:
104
+
105
+ • Does the contingency awareness in terms of self-localization provide a useful state abstraction for exploration? • How well can the self-supervised model discover the ground-truth abstract states? • How well does the proposed exploration strategy perform against other exploration methods?
106
+
107
+ # 4.1 EXPERIMENTS WITH A2C
108
+
109
+ We evaluate the proposed exploration strategy on several difficult exploration Atari 2600 games from the Arcade Learning Environment (ALE) (Bellemare et al., 2013). We focus on 8 Atari games including FREEWAY, FROSTBITE, HERO, PRIVATEEYE, MONTEZUMA’S REVENGE, QBERT, SEAQUEST, and VENTURE. In these games, an agent without an effective exploration strategy can often converge to a suboptimal policy. For example, as depicted in Figure 2, the Advantage Actor-Critic (A2C) baseline (Mnih et al., 2016) achieves a reward close to 0 on MONTEZUMA’S REVENGE, VENTURE, FREEWAY, FROSTBITE, and PRIVATEEYE, even after 100M steps of training. By contrast, our proposed technique, which augments A2C with count-based exploration with the location information learned by the attentive dynamics model, denoted $\mathbf { A 2 C + C o E X }$ (CoEX stands for “Contingency-aware Exploration”), significantly outperforms the A2C baseline on six out of the 8 games.
110
+
111
+ We compare our proposed $_ { \mathrm { A 2 C + C o E X } }$ technique against the following baselines:4 • A2C: an implementation adopted from OpenAI baselines (Dhariwal et al., 2017) using the default hyperparameters, which serves as the building block of our more complicated baselines. • A2C+Pixel-SimHash: Following (Tang et al., 2017), we map $5 2 \times 5 2$ gray-scale observations to 128-bit binary codes using random projection followed by quantization (Charikar, 2002). Then, we add a count-based exploration bonus based on quantized observations.
112
+
113
+ Table 1: Performance of our method and its baselines on Atari games: maximum mean scores (averaged over 40 recent episodes) achieved over total 100M environment timesteps (400M frames) of training, averaged over 3 seeds. The best entry in the group of experiments without supervision is shown in bold. ∗ denotes that $\mathrm { A 2 C + C o E X + R A M }$ acts as a control experiment, which includes some supervision. More experimental results on $\mathrm { A 2 C + C o E X + R A M }$ are shown in Appendix C.
114
+
115
+ <table><tr><td>Method</td><td>Freeway</td><td>Frostbite</td><td>Hero</td><td>Montezuma</td><td>PrivateEye</td><td>Qbert</td><td>Seaquest</td><td>Venture</td></tr><tr><td>A2C</td><td>7.2</td><td>1099</td><td>34352</td><td>13</td><td>574</td><td>19620</td><td>2401</td><td>0</td></tr><tr><td>A2C+Pixel-SimHash</td><td>0.0</td><td>829</td><td>28181</td><td>412</td><td>276</td><td>18180</td><td>2177</td><td>31</td></tr><tr><td>A2C+CoEX</td><td>34.0</td><td>4260</td><td>36827</td><td>6635</td><td>5316</td><td>23962</td><td>5169</td><td>204</td></tr><tr><td>A2C+CoEX+RAM*</td><td>34.0</td><td>4418</td><td>36765</td><td>6600</td><td>24296</td><td>24422</td><td>6113</td><td>1100</td></tr></table>
116
+
117
+ Table 2: Performance of our method and state-of-the-art exploration methods on Atari games. For fair comparison, we report the maximum mean score achieved over the specific number of timesteps during training, averaged over 3 seeds. The best entry is shown in bold. Baselines (for reference) are: $\mathrm { D D Q N + }$ and ${ \bf A } 3 { \bf C } +$ (Bellemare et al., 2016), TRPO-AE-SimHash (Tang et al., 2017), Sarsa- $\phi$ -EB (Martin et al., 2017), DQN-PixelCNN (Ostrovski et al., 2017), and Curiosity-Driven (Burda et al., 2018). The numbers for $\mathrm { D D Q N + }$ were taken from (Tang et al., 2017) or were read from a plot.
118
+
119
+ <table><tr><td>Method</td><td>#Steps</td><td>Freeway</td><td>Frostbite</td><td>Hero</td><td>Montezuma</td><td>aPrivateEye</td><td>Qbert</td><td>Seaquest</td><td>Venture</td></tr><tr><td>A2C+CoEX (Ours)</td><td>50M</td><td>33.9</td><td>3900</td><td>31367</td><td>4100</td><td>5316</td><td>17724</td><td>2620</td><td>128</td></tr><tr><td>A2C+CoEX(Ours)</td><td>100M</td><td>34.0</td><td>4260</td><td>36827</td><td>6635</td><td>5316</td><td>23962</td><td>5169</td><td>204</td></tr><tr><td>DDQN+</td><td>25M</td><td>29.2</td><td></td><td>20300</td><td>3439</td><td>1880</td><td>-</td><td>-</td><td>369</td></tr><tr><td>A3C+</td><td>50M</td><td>27.3</td><td>507</td><td>15210</td><td>142</td><td>100</td><td>15805</td><td>2274</td><td>0</td></tr><tr><td>TRPO-AE-SimHash</td><td>50M</td><td>33.5</td><td>5214</td><td></td><td>75</td><td>-</td><td>1</td><td>-</td><td>445</td></tr><tr><td>Sarsa-Φ-EB</td><td>25M</td><td>0.0</td><td>2770</td><td></td><td>2745</td><td>-</td><td>4112</td><td></td><td>1169</td></tr><tr><td>DQN-PixelCNN</td><td>37.5M</td><td>31.7</td><td>-</td><td></td><td>2514</td><td>15806</td><td>5501</td><td></td><td>1356</td></tr><tr><td>Curiosity-Driven</td><td>25M</td><td>32.8</td><td>=</td><td>=</td><td>2505</td><td>3037</td><td>-</td><td>=</td><td>416</td></tr></table>
120
+
121
+ As a control experiment, we evaluate $\mathbf { A 2 C + C o E X + R A M ^ { * } }$ , our contingency-aware exploration method together with the ground-truth location information obtained from game’s RAM. It is roughly an upper-bound of the performance of our approach.
122
+
123
+ # 4.2 IMPLEMENTATION DETAILS
124
+
125
+ For the A2C (Mnih et al., 2016) algorithm, we use 16 parallel actors to collect the agent’s experience, with 5-step rollout, which yields a minibatch of size 80 for on-policy transitions. We use the last 4 observation frames stacked as input, each of which is resized to $8 4 \times 8 4$ and converted to grayscale as in (Mnih et al., 2015; 2016). We set the end of an episode to when the game ends, rather than when the agent loses a life. Each episode is initialized with a random number of no-ops (Mnih et al., 2015). More implementation details can be found in Appendix A and B.
126
+
127
+ For the ADM, we take observation frames of size $1 6 0 \times 1 6 0$ as input (resized from the raw observation of size $2 1 0 \times 1 6 0 $ ).5 We employ a 4-layer convolutional neural network that produces a feature map $\phi ( s _ { t } )$ with a spatial grid size of $\boldsymbol { H } \times \boldsymbol { W } = 9 \times 9$ . As a result, the prediction of location coordinates lies in the $9 \times 9$ grid.
128
+
129
+ In some environments, the contingent regions within the visual observation alone are not sufficient to determine the exact location of the agent within the game; for example, the coordinate cannot solely distinguish between different rooms in HERO, MONTEZUMA’S REVENGE, and PRIVATEEYE, etc. Therefore, we introduce a discrete context representation $c \in \mathbb { Z }$ that summarizes the high-level visual context in which the agent currently lies. We use a simple clustering method similar to (Kulis & Jordan, 2012), which we refer to as observation embedding clustering that clusters the random projection vectors of the input frames as in (Tang et al., 2017), so that different contexts are assigned to different clusters. We further explain this heuristic approach more in detail in Appendix D.
130
+
131
+ ![](images/6fce768a51bd25ae52bf975e17741a486d3abbcf4737f60180c5fd3056990610.jpg)
132
+ Figure 3: Performance plot of ADM trained using on-policy samples from the $_ { \mathrm { A 2 C + C o E X } }$ agent.
133
+
134
+ In sparse-reward problems, the act of collecting a reward is rare but frequently instrumental for the future states of the environment. The cumulative reward $\begin{array} { r } { R _ { t } = \sum _ { t ^ { \prime } = 0 } ^ { t - 1 } r ^ { \mathrm { e x t } } \bar { ( } s _ { t ^ { \prime } } , \bar { a _ { t ^ { \prime } } } ) } \end{array}$ from the beginning , can provide a useful high-level behavioral context because collecting rewards can trigger significant changes to the agent’s state and as a result the optimal behavior can change as well. In this sense, the agent should revisit the previously visited location for exploration when the context changes. For example, in MONTEZUMA’S REVENGE, if the agent is in the first room and the cumulative reward is 0, we know the agent has not picked up the key and the optimal policy is to reach the key. However, if the cumulative reward in the first room is 100, it means the agent has picked up the key and the next optimal goal is to open a door and move on to the next room. Therefore, we could include the cumulative reward as a part of state abstraction for exploration, which leads to empirically better performance.
135
+
136
+ To sum up, for the purpose of count-based exploration, we utilize the location $( x , y )$ of the controllable entity (i.e., the agent) in the current observation discovered by ADM (Section 3.1), a context representation $c \in \mathbb { Z }$ that denotes the high level visual context, and a cumulative environment reward $R \in \mathbb { Z }$ that represents the exploration behavioral state. In such setting, we may denote $\psi ( s ) = ( x , y , c , R )$ .
137
+
138
+ # 4.3 PERFORMANCE OF COUNT-BASED EXPLORATION
139
+
140
+ Figure 2 shows the learning curves of the proposed methods on 8 Atari games. The performance of our method $_ { \mathrm { A 2 C + C o E X } }$ and A2C+CoEX $^ { + }$ RAM as well as the baselines A2C and $\mathbf { A } 2 \mathbf { C } +$ PixelSimHash are summarized in Table 1. In order to find a balance between the environment reward and the exploration bonus reward, we perform a hyper-parameter search for the proper weight of the environment reward $\beta _ { 1 }$ and the exploration reward $\beta _ { 2 }$ for $_ { \mathrm { A 2 C + C o E X + R A M } }$ , as well as for $_ { \mathrm { A 2 C + C o E X } }$ . The hyper-parameters for the two ended up being the same, which is consistent with our results. For fair comparison, we also search for the proper weight of environment reward for A2C baseline. The best hyper-parameters for each game are shown in Table 5 in Appendix B.
141
+
142
+ Compared to the vanilla A2C, the proposed exploration strategy improves the score on all the hard-exploration games. As shown in Table 1, provided the representation $( x , y , c , R )$ is perfect, $\mathrm { A 2 C + C o E X + R A M }$ achieves a significant improvement over A2C by encouraging the agent to visit novel locations, and could nearly solve these hard exploration games as training goes on.
143
+
144
+ Furthermore, $_ { \mathrm { A 2 C + C o E X } }$ using representations learned with our proposed attentive dynamics model and observation embedding clustering also outperforms the A2C baseline. Especially on FREEWAY, FROSTBITE, HERO, MONTEZUMA’S REVENGE, QBERT and SEAQUEST, the performance is comparable with A2C+CoEX $\cdot +$ RAM, demonstrating the usefulness of the contigency-awareness information discovered by ADM.
145
+
146
+ Comparison to other count-based exploration methods. Table 2 compares the proposed method with previous state-of-the-art results, where our proposed method outperforms the other methods on 5 out of 8 games. DQN-PixelCNN is the strongest alternative achieving a state-of-the-art performance on some of the most difficult sparse-reward games. We argue that using Q-learning as the base learner with DQN-PixelCNN makes the direct comparison with $_ { \mathrm { A 2 C + C o E X } }$ not completely adequate. Note that the closest alternative count-based exploration method to $_ { \mathrm { A 2 C + C o E X } }$ would be ${ \bf A } 3 { \bf C } +$ (Bellemare et al., 2016), which augments A3C (Mnih et al., 2016) with exploration bonus derived from pseudocount, because A2C and A3C share a similar policy learning method. With that in mind, one can observe a clear improvement of $_ { \mathrm { A 2 C + C o E X } }$ over ${ \bf A } 3 { \bf C } +$ on all of the 8 Atari games.
147
+
148
+ ![](images/c3905f8aa249f8efbe329951118e779c353158e2bd8a110158ff0877764e1a94.jpg)
149
+ Figure 4: Curves of ARI score during training of $_ { \mathrm { A 2 C + C o E X } }$ , averaged over 100 recent observations.
150
+
151
+ # 4.4 ANALYSIS OF ATTENTIVE DYNAMICS MODEL
152
+
153
+ We also analyze the performance of the ADM that learns the controllable dynamics of the environment. As a performance metric, we report the average distance between the ground-truth agent location $( x ^ { * } , y ^ { * } )$ and the predicted location $( x , y )$ within the $9 \times 9$ grid: $\lVert ( x , y ) - ( x ^ { * } , y ^ { * } ) \rVert _ { 2 }$ . The ground-truth location of the agent is extracted from $\mathrm { \bf { R A M } } ^ { 6 }$ , then rescaled so that the observation image frame fits into the $9 \times 9$ grid.
154
+
155
+ Figure 3 shows the results on 4 Atari games (MONTEZUMA’S REVENGE, SEAQUEST, HERO, and VENTURE). The ADM is able to quickly capture the location of the agent without any supervision of localization, despite the agent constantly visiting new places. Typically the predicted location is on average 1 or 2 grid cells away from the ground-truth location. Whenever a novel scene is encountered (e.g., the second room in MONTEZUMA’S REVENGE at around 10M steps), the average distance temporarily increases but quickly drops again as the model learns the new room. We provide videos of the agents playing and localization information as the supplementary material.7
156
+
157
+ # 4.5 ANALYSIS OF OBSERVATION EMBEDDING CLUSTERING
158
+
159
+ To make the agent aware of a change in high-level visual context (i.e., rooms in Atari games) in some games such as MONTEZUMA’S REVENGE, VENTURE, HERO, and PRIVATEEYE, we obtain a representation of the high-level context and use it for exploration. The high-level visual contexts are different from each other (different layouts, objects, colors, etc.), so the embedding generated by a random projection is quite distinguishable and the clustering is accurate and robust.
160
+
161
+ For evaluation, given an observation in Atari games, we compare the discrete representation (i.e., which cluster it is assigned to) based on the embedding from random projection to the ground-truth room number extracted from RAM. The Adjusted Rand Index (ARI) (Rand, 1971) measures the similarity between these two data clusterings. The ARI may only yield a value between 0 and 1, and is exactly 1 when the clusterings are identical.
162
+
163
+ The curves of the Adjusted Rand Index are shown in Figure 4. For MONTEZUMA’S REVENGE and VENTURE, the discrete representation as room number is roughly as good as the ground-truth. For HERO and PRIVATEEYE, since there are many rooms quite similar to one another, it is more challenging to accurately cluster the embeddings. The samples shown in Figure 7 in Appendix D show reasonable performances of the clustering method on all these games.
164
+
165
+ # 4.6 ADDITIONAL EXPERIMENTS WITH PPO
166
+
167
+ We also evaluate the proposed exploration algorithm on MONTEZUMA’S REVENGE using the sticky actions environment setup (Machado et al., 2017) identical to the setup found in (Burda et al., 2019). In the sticky action setup, the agent randomly repeats the previous action with probability of 0.25, preventing the algorithm from simply memorizing the correct sequence of actions and relying on determinism. The agent is trained with Proximal Policy Optimization (PPO) (Schulman et al., 2017) in conjunction with the proposed exploration method using 128 parallel actors to collect the experience. We used reward normalization and advantage normalization as in (Burda et al., 2018).
168
+
169
+ ![](images/d3a7455a83b173f0aec01883675f31e822a2c7f15974716112e466cb952ffe73.jpg)
170
+ Figure 5: The learning curve of $\mathrm { P P O + C o E X }$ on several Atari games with sticky actions setup. The $\mathbf { X }$ -axis represents the total number of environment steps and the y-axis the mean episode reward averaged over 40 recent episodes. The mean curve is obtained by averaging over 3 random seeds, each shown in a light color.
171
+
172
+ Table 3: Performance of PPO and $\mathrm { P P O + C o E X }$ : maximum mean scores (average over 40 recent episodes) achieved over total 500M environment steps (2B frames) of training, averaged over 3 seeds.
173
+
174
+ <table><tr><td>Method</td><td>#Steps</td><td>Freeway</td><td>Frostbite</td><td>Hero</td><td>Montezuma</td><td>PrivateEye</td><td>Qbert</td><td>Seaquest</td><td>Venture</td></tr><tr><td>PPO</td><td>500M</td><td>34.0</td><td>7340</td><td>36263</td><td>29</td><td>942</td><td>19980</td><td>2806</td><td>1875</td></tr><tr><td>PPO+CoEX</td><td>500M</td><td>34.0</td><td>9076</td><td>36664</td><td>11618</td><td>11000</td><td>22647</td><td>11794</td><td>1916</td></tr></table>
175
+
176
+ The method, denoted $\mathbf { P P O + C o E X }$ , achieves the score of 11,618 at 500M environment steps (2 billion frames) on MONTEZUMA’S REVENGE, when averaged over 3 runs. The learning curve is illustrated in Figure 5. Since the vanilla PPO baseline achieves a score near 0 (our runs) or 1,797 (Burda et al., 2019), this result is not solely due to the benefits of PPO. There is another approach "Exploration by Random Network Distillation" (Burda et al., 2019) concurrent with our work which achieves similar performance by following a slightly different philosophy.
177
+
178
+ # 4.7 DISCUSSIONS AND FUTURE WORK
179
+
180
+ This paper investigates whether discovering controllable dynamics via an attentive dynamics model (ADM) can help exploration in challenging sparse-reward environments. We demonstrate the effectiveness of this approach by achieving significant improvements on notoriously difficult video games. That being said, we acknowledge that our approach has certain limitations. Our currently presented instance of state abstraction method mainly focuses on controllable dynamics and employs a simple clustering scheme to abstract away uncontrollable elements of the scene. In more general setting, one can imagine using attentive (forward or inverse) dynamics models to learn an effective and compact abstraction of the controllable and uncontrollable dynamics as well, but we leave this to future work.
181
+
182
+ Key elements of the current ADM method include the use of spatial attention and modelling of the dynamics. These ideas can be generalized by a set of attention-based dynamics models (ADM) operating in forward, inverse, or combined mode. Such models could use attention over a lowerdimensional embedding that corresponds to an intrinsic manifold structure from the environment (i.e., intuitively speaking, this also corresponds to being self-aware of (e.g., locating) where the agent is in the abstract state space). Our experiments with the inverse dynamics model suggest that the mechanism does not have to be perfectly precise, allowing for some error in practice. We speculate that mapping to such subspace could be obtained by techniques of embedding learning.
183
+
184
+ We note that RL environments with different visual characteristics may require different forms of attention-based techniques and properties of the model (e.g., partial observability). Even though this paper focuses on 2D video games, we believe that the presented high-level ideas of learning contingency-awareness (with attention and dynamics models) are more general and could be applicable to more complex 3D environments with some extension. We leave this as future work.
185
+
186
+ # 5 CONCLUSION
187
+
188
+ We proposed a method of providing contingency-awareness through an attentive dynamics model (ADM). It enables approximate self-localization for an RL agent in 2D environments (as a specific perspective). The agent is able to estimate its position in the space and therefore benefits from a compact and informative representation of the world. This idea combined with a variant of countbased exploration achieves strong results in various sparse-reward Atari games. Furthermore, we report state-of-the-art results of ${ > } 1 1 { , } 0 0 0$ points on the infamously challenging MONTEZUMA’S REVENGE without using expert demonstrations or supervision. Though in this work we focus mostly on 2D environments in the form of sparse-reward Atari games, we view our presented high-level concept and approach as a stepping stone towards more universal algorithms capable of similar abilities in various RL environments.
189
+
190
+ # REFERENCES
191
+
192
+ Joshua Achiam and Shankar Sastry. Surprise-Based Intrinsic Motivation for Deep Reinforcement Learning. arXiv preprint arXiv:1703.01732, 2017.
193
+
194
+ Pulkit Agrawal, Ashvin Nair, Pieter Abbeel, Jitendra Malik, and Sergey Levine. Learning to Poke by Poking: Experiential Learning of Intuitive Physics. In NIPS, 2016.
195
+
196
+ Frank Baeyens, Paul Eelen, and Omer van den Bergh. Contingency awareness in evaluative conditioning: A case for unaware affective-evaluative learning. Cognition and emotion, 4(1):3–18, 1990.
197
+
198
+ Dzmitry Bahdanau, Kyunghyun Cho, and Yoshua Bengio. Neural Machine Translation by Jointly Learning to Align and Translate. In ICLR, 2015.
199
+
200
+ Andrea Banino, Caswell Barry, Benigno Uria, Charles Blundell, Timothy Lillicrap, Piotr Mirowski, Alexander Pritzel, Martin J Chadwick, Thomas Degris, Joseph Modayil, Greg Wayne, Hubert Soyer, Fabio Viola, Brian Zhang, Ross Goroshin, Neil Rabinowitz, Razvan Pascanu, Charlie Beattie, Stig Petersen, Amir Sadik, Stephen Gaffney, Helen King, Koray Kavukcuoglu, Demis Hassabis, Raia Hadsell, and Dharshan Kumaran. Vector-based navigation using grid-like representations in artificial agents. Nature, 557(7705):429–433, 2018.
201
+
202
+ Andrew G Barto. Intrinsic motivation and reinforcement learning. In Intrinsically motivated learning in natural and artificial systems, pp. 17–47. Springer, 2013.
203
+
204
+ Marc G Bellemare, Joel Veness, and Michael Bowling. Investigating Contingency Awareness Using Atari 2600 Games. In AAAI, 2012.
205
+
206
+ Marc G. Bellemare, Yavar Naddaf, Joel Veness, and Michael Bowling. The Arcade Learning Environment: An Evaluation Platform for General Agents. Journal of Artificial Intelligence Research 47, 2013.
207
+
208
+ Marc G. Bellemare, Sriram Srinivasan, Georg Ostrovski, Tom Schaul, David Saxton, and Remi Munos. Unifying Count-Based Exploration and Intrinsic Motivation. In NIPS, 2016.
209
+
210
+ Emmanuel Bengio, Valentin Thomas, Joelle Pineau, Doina Precup, and Yoshua Bengio. Independently Controllable Features. arXiv preprint arXiv:1703.07718, 2017.
211
+
212
+ Yuri Burda, Harri Edwards, Deepak Pathak, Amos Storkey, Trevor Darrell, and Alexei A. Efros. Large-scale study of curiosity-driven learning. arXiv preprint arXiv:1808.04355, 2018.
213
+
214
+ Yuri Burda, Harrison Edwards, Amos Storkey, and Oleg Klimov. Exploration by random network distillation. In ICLR, 2019. URL https://openreview.net/forum?id=H1lJJnR5Ym.
215
+
216
+ Moses S Charikar. Similarity estimation techniques from rounding algorithms. In Proceedings of the thiry-fourth annual ACM symposium on Theory of computing, pp. 380–388. ACM, 2002.
217
+
218
+ Prafulla Dhariwal, Christopher Hesse, Oleg Klimov, Alex Nichol, Matthias Plappert, Alec Radford, John Schulman, Szymon Sidor, and Yuhuai Wu. OpenAI Baselines. https://github.com/openai/ baselines, 2017.
219
+
220
+ Nat Dilokthanakul, Christos Kaplanis, Nick Pawlowski, and Murray Shanahan. Feature Control as Intrinsic Motivation for Hierarchical Reinforcement Learning. arXiv preprint arXiv:1705.06769, 2017.
221
+
222
+ Hugh Durrant-Whyte and Tim Bailey. Simultaneous Localization and Mapping: Part I. IEEE robotics & automation magazine, 13(2):99–110, 2006.
223
+
224
+ Benjamin Eysenbach, Abhishek Gupta, Julian Ibarz, and Sergey Levine. Diversity is All You Need: Learning Skills without a Reward Function. 2018.
225
+
226
+ Rein Houthooft, Xi Chen, Yan Duan, John Schulman, Filip De Turck, and Pieter Abbeel. VIME: Variational Information Maximizing Exploration. In NIPS, 2016.
227
+
228
+ Max Jaderberg, Volodymyr Mnih, Wojciech Marian Czarnecki, Tom Schaul, Joel Z Leibo, David Silver, and Koray Kavukcuoglu. Reinforcement Learning with Unsupervised Auxiliary Tasks. In ICLR, 2017.
229
+
230
+ Brian Kulis and Michael I . Jordan. Revisiting k-means: New Algorithms via Bayesian Nonparametrics. In ICML, 2012.
231
+
232
+ Marlos C Machado, Marc G Bellemare, Erik Talvitie, Joel Veness, Matthew Hausknecht, and Michael Bowling. Revisiting the arcade learning environment: Evaluation protocols and open problems for general agents. Journal of Artificial Intelligence Research, 61:523–562, 2017.
233
+
234
+ Jarryd Martin, Suraj Narayanan Sasikumar, Tom Everitt, and Marcus Hutter. Count-Based Exploration in Feature Space for Reinforcement Learning. In IJCAI, 2017.
235
+
236
+ André F T Martins and Ramón Fernandez Astudillo. From Softmax to Sparsemax: A Sparse Model of Attention and Multi-Label Classification. In ICML, 2016.
237
+
238
+ Piotr Mirowski, Razvan Pascanu, Fabio Viola, Hubert Soyer, Andrew J Ballard, Andrea Banino, Misha Denil, Ross Goroshin, Laurent Sifre, Koray Kavukcuoglu, Dharshan Kumaran, and Raia Hadsell. Learning to Navigate in Complex Environments. In ICLR, 2017.
239
+
240
+ Piotr Mirowski, Matthew Koichi Grimes, Mateusz Malinowski, Karl Moritz Hermann, Keith Anderson, Denis Teplyashin, Karen Simonyan, Koray Kavukcuoglu, Andrew Zisserman, and Raia Hadsell. Learning to Navigate in Cities Without a Map. In NIPS, 2018.
241
+
242
+ Volodymyr Mnih, Koray Kavukcuoglu, David Silver, Andrei A. Rusu, Joel Veness, Marc G. Bellemare, Alex Graves, Martin Riedmiller, Andreas K. Fidjeland, Georg Ostrovski, Stig Petersen, Charles Beattie, Amir Sadik, Ioannis Antonoglou, Helen King, Dharshan Kumaran, Daan Wierstra, Shane Legg, and Demis Hassabis. Human-level control through deep reinforcement learning. Nature, 2015.
243
+
244
+ Volodymyr Mnih, Adrià Puigdomènech Badia, Mehdi Mirza, Alex Graves, Timothy P Lillicrap, Tim Harley, David Silver, and Koray Kavukcuoglu. Asynchronous Methods for Deep Reinforcement Learning. In ICML, 2016.
245
+
246
+ May-Britt Moser, David Rowland, and Edvard I Moser. Place Cells, Grid Cells, and Memory. Cold Spring Harbor perspectives in medicine, 5, 2015.
247
+
248
+ Junhyuk Oh, Xiaoxiao Guo, Honglak Lee, Richard L Lewis, and Satinder P Singh. Action-Conditional Video Prediction using Deep Networks in Atari Games. In NIPS, 2015.
249
+
250
+ Ian Osband, Charles Blundell, Alexander Pritzel, and Benjamin Van Roy. Deep Exploration via Bootstrapped DQN. In NIPS, 2016.
251
+
252
+ Georg Ostrovski, Marc G. Bellemare, Aaron van den Oord, and Remi Munos. Count-Based Exploration with Neural Density Models. In ICML, 2017.
253
+
254
+ Pierre-Yves Oudeyer and Frederic Kaplan. What is intrinsic motivation? A typology of computational approaches. Frontiers in Neurorobotics, 2009.
255
+
256
+ Deepak Pathak, Pulkit Agrawal, Alexei A Efros, and Trevor Darrell. Curiosity-driven Exploration by Self-supervised Prediction. In ICML, 2017.
257
+
258
+ Matthias Plappert, Rein Houthooft, Prafulla Dhariwal, Szymon Sidor, Richard Y Chen, Xi Chen, Tamim Asfour, Pieter Abbeel, and Marcin Andrychowicz. Parameter Space Noise for Exploration. In ICLR, 2018.
259
+
260
+ William M. Rand. Objective criteria for the evaluation of clustering methods. Journal of the American Statistical Association, 66(336):846–850, 1971.
261
+
262
+ Yoshihide Sawada. Disentangling Controllable and Uncontrollable Factors of Variation by Interacting with the World. arXiv preprint arXiv:1804.06955, 2018.
263
+
264
+ Jürgen Schmidhuber. Adaptive confidence and adaptive curiosity. 1991.
265
+
266
+ John Schulman, Filip Wolski, Prafulla Dhariwal, Alec Radford, and Oleg Klimov. Proximal policy optimization algorithms. arXiv preprint arXiv:1707.06347, 2017.
267
+
268
+ Evan Shelhamer, Parsa Mahmoudieh, Max Argus, and Trevor Darrell. Loss is its own Reward: Self-Supervision for Reinforcement Learning. arXiv preprint arXiv:1612.07307, 2017.
269
+
270
+ Satinder Singh, Nuttapong Chentanez, and Andrew G. Barto. Intrinsically Motivated Reinforcement Learning. In NIPS, 2004.
271
+
272
+ Alexander L. Strehl and Michael L. Littman. An analysis of model-based interval estimation for markov decision processes. Journal of Computer and System Sciences, 74(8), 2008.
273
+
274
+ Haoran Tang, Rein Houthooft, Davis Foote, Adam Stooke, Xi Chen, Yan Duan, John Schulman, Filip De Turck, and Pieter Abbeel. #Exploration: A Study of Count-Based Exploration for Deep Reinforcement Learning. In NIPS, 2017.
275
+
276
+ John S Watson. The development and generalization of "contingency awareness" in early infancy: Some hypotheses. Merrill-Palmer Quarterly of Behavior and Development, 12(2):123–135, 1966.
277
+
278
+ Kelvin Xu, Jimmy Ba, Ryan Kiros, Kyunghyun Cho, Aaron C. Courville, Ruslan Salakhutdinov, Richard S Zemel, and Yoshua Bengio. Show, Attend and Tell: Neural Image Caption Generation with Visual Attention. In ICML, 2015.
279
+
280
+ Zeyu Zheng, Junhyuk Oh, and Satinder Singh. On Learning Intrinsic Rewards for Policy Gradient Methods. In NIPS, 2018.
281
+
282
+ # APPENDIX
283
+
284
+ A SUMMARY OF TRAINING ALGORITHM
285
+
286
+ # Algorithm $\mathbf { 1 } \mathrm { A } 2 \mathrm { C } \mathrm { + } \mathrm { C o E X }$
287
+
288
+ <table><tr><td>Initialize parameter 0ADm for attentive dynamics model fADM Initialize parameter θA2c for actor-critic network Initialize parameter θc for context embedding projector if applicable (which is not trainable) Initialize transition bufferε←@ for each iteration do Collect on-policy transition samples,distributed over K parallel actors</td></tr><tr><td>for each step t do St ← Observe state at~Tθ(at|st) St+1,rext ← Perform action at in the environment</td></tr><tr><td>DCompute the contingent region information αt+1 ← Compute the attention map of St+1 using fADM c(St+1)← Compute the observation embedding cluster of St+1 (Algorithm 2)</td></tr><tr><td>DIncrement state visitation counter based on the representation (st+1)←(argmax(,j)t+1(𝑖,j),c(St+1),[∑=0r1)</td></tr><tr><td>#((St+1))←#((St+1))+1 r ↑ 1 #((st+1))</td></tr><tr><td>Store transitionε ← εU {(st,at, St+1,β1clip(rext,-1,1) + β2rt)} end for</td></tr><tr><td>DPerform actor-critic using on-policy samples in ε 0A2C ←0A2C -nVθA2CCA2C DTrain the attentive dynamics model using on-policy samples in ε</td></tr></table>
289
+
290
+ # end for
291
+
292
+ The learning objective $\mathcal { L } ^ { \mathrm { A D M } }$ is from Equation (5). The objective ${ \mathcal { L } } ^ { \mathrm { A 2 C } }$ of Advantage Actor-Critic (A2C) is as in (Mnih et al., 2016; Dhariwal et al., 2017):
293
+
294
+ $$
295
+ \begin{array} { r l } & { \mathcal { L } ^ { \mathrm { A 2 C } } = \mathbb { E } _ { ( s , a , r ) \sim \mathcal { E } } \bigg [ \mathcal { L } _ { \mathrm { p o l i c y } } ^ { \mathrm { A 2 C } } + \frac { 1 } { 2 } \mathcal { L } _ { \mathrm { v a l u e } } ^ { \mathrm { A 2 C } } \bigg ] } \\ & { \mathcal { L } _ { \mathrm { p o l i c y } } ^ { \mathrm { A 2 C } } = - \log \pi _ { \theta } ( a _ { t } | s _ { t } ) ( R _ { t } ^ { n } - V _ { \theta } ( s _ { t } ) ) - \alpha \mathcal { H } _ { t } ( \pi _ { \theta } ) } \\ & { \mathcal { L } _ { \mathrm { v a l u e } } ^ { \mathrm { A 2 C } } = \frac { 1 } { 2 } \Big ( V _ { \theta } ( s _ { t } ) - R _ { t } ^ { n } \Big ) ^ { 2 } } \\ & { \mathcal { H } _ { t } ( \pi _ { \theta } ) = - \sum _ { a } \pi _ { \theta } ( a | s _ { t } ) \log \pi _ { \theta } ( a | s _ { t } ) } \end{array}
296
+ $$
297
+
298
+ where $\begin{array} { r } { R _ { t } ^ { n } = \sum _ { i = 0 } ^ { n - 1 } \gamma ^ { i } r _ { t + i } + \gamma ^ { n } V _ { \theta } ( s _ { t + n } ) } \end{array}$ is the $n$ -step bootstrapped return and $\alpha$ is a weight for the standard entropy regularization loss term $\mathcal { H } _ { t } ( \pi _ { \theta } )$ $\theta = \theta _ { \mathrm { { A 2 C } } }$
299
+
300
+ # B ARCHITECTURE AND HYPERPARAMETER DETAILS
301
+
302
+ The architecture details of the attentive dynamics model (ADM), the policy network, and hyperparameters are as follows.
303
+
304
+ Table 4: Network architecture and hyperparameters
305
+
306
+ <table><tr><td>Hyperparameters</td><td colspan="2">Value</td></tr><tr><td>Policy and Value Network Architecture</td><td colspan="2">Input: 84x84x1</td></tr><tr><td></td><td>- Conv(32-8x8-4)</td><td>/ReLU</td></tr><tr><td></td><td>- Conv(64-4x4-2)</td><td>/ReLU</td></tr><tr><td></td><td>- Conv(64-3x3-1)</td><td>/ReLU</td></tr><tr><td></td><td>- FC(512)</td><td>/ReLU</td></tr><tr><td></td><td>- FC(|AI), FC(1)</td><td></td></tr><tr><td>ADM Encoder Architecture</td><td colspan="2">Input: 160x160x3</td></tr><tr><td></td><td>- Conv(8-4x4-2)</td><td>/LeakyReLU</td></tr><tr><td></td><td>- Conv(8-3x3-2)</td><td>/LeakyReLU</td></tr><tr><td></td><td>- Conv(16-3x3-2)</td><td>/LeakyReLU</td></tr><tr><td></td><td>- Conv(16-3x3-2)</td><td>/LeakyReLU</td></tr><tr><td>MLP Architecture for et(𝑖, j)</td><td>FC(1296,256)</td><td>/ReLU</td></tr><tr><td></td><td>- FC(256,128)</td><td>/ReLU</td></tr><tr><td></td><td>- FC(128,JA|)</td><td></td></tr><tr><td>MLP Architecture for &amp;t(𝑖, j)</td><td>FC(1296,64)</td><td>/ReLU</td></tr><tr><td></td><td>- FC(64,64)</td><td>/ReLU</td></tr><tr><td></td><td>- FC(64,1)</td><td></td></tr><tr><td>Xent for Loss</td><td>0.001</td><td></td></tr><tr><td>A2C Discount Factor </td><td>0.99</td><td></td></tr><tr><td>Learning Rate (RMSProp)</td><td>0.0007</td><td></td></tr><tr><td>Number of Parallel Environments</td><td>16</td><td></td></tr><tr><td>Number of Roll-out Steps per Iteration</td><td>5</td><td></td></tr><tr><td>Entropy Regularization of Policy (α)</td><td>0.01</td><td></td></tr><tr><td>PPO Discount Factor </td><td>0.99</td><td></td></tr><tr><td>入 for GAE</td><td>0.95</td><td></td></tr><tr><td>Learning rate (Adam)</td><td>0.00001</td><td></td></tr><tr><td>Number of Parallel Environments</td><td>128</td><td></td></tr><tr><td>Rollout Length</td><td>128</td><td></td></tr><tr><td>Number of Minibatches</td><td>4</td><td></td></tr><tr><td>Number of Optimization Epochs</td><td></td><td></td></tr><tr><td>Coefficient of Extrinsic and Intrinsic reward</td><td>4 β=2,β=1</td><td></td></tr><tr><td>Entropy Regularization of Policy (α)</td><td>0.01</td><td></td></tr></table>
307
+
308
+ Table 5: The list of hyperparameters used for $_ { \mathrm { A 2 C + C o E X } }$ in each game. For the four games where there is no change of high-level visual context (FREEWAY, FROSTBITE, QBERT and SEAQUEST), we do not include $c$ in the state representation $\psi ( s )$ , hence there is no $\tau$ . The same values of $\tau$ are used in $\mathrm { P P O + C o E X }$ .
309
+
310
+ <table><tr><td>Games</td><td>β1 in A2C+CoEX</td><td>β2 in A2C+CoEX</td><td>β1 in A2C</td><td>T for clustering</td></tr><tr><td>FREEWAY</td><td>10</td><td>10</td><td>10</td><td>-</td></tr><tr><td>FROSTBITE</td><td>10</td><td>10</td><td>10</td><td>-</td></tr><tr><td>HERO</td><td>1</td><td>0.1</td><td>1</td><td>0.7</td></tr><tr><td>MONTEZUMA&#x27;SREVENGE</td><td>10</td><td>10</td><td>10</td><td>0.7</td></tr><tr><td>PRIVATEEYE</td><td>10</td><td>10</td><td>10</td><td>0.55</td></tr><tr><td>QBERT</td><td>1</td><td>0.5</td><td>1</td><td>-</td></tr><tr><td>SEAQUEST</td><td>1</td><td>0.5</td><td>10</td><td>-</td></tr><tr><td>VENTURE</td><td>10</td><td>10</td><td>10</td><td>0.7</td></tr></table>
311
+
312
+ ![](images/e20bc9532db3245c4bc0e17209266d7b056d5792ecce7a71d396eea2745b307d.jpg)
313
+ Figure 6: Learning curves on several Atari games: A2C, $_ { \mathrm { A 2 C + C o E X } }$ , and $_ { \mathrm { A 2 C + C o E X + R A M } }$ .
314
+
315
+ # C EXPERIMENT WITH RAM INFORMATION
316
+
317
+ In order to understand the performance of exploration with perfect representation, we extract the ground-truth location of the agent and the room number from RAM, and then run count-based exploration with the perfect $( x , y , c , R )$ . Figure 6 shows the learning curves of the experiments; we could see $\mathrm { A 2 C + C o E X + R A M }$ acts as an upper bound performance of our proposed method.
318
+
319
+ # D OBSERVATION EMBEDDING CLUSTERING
320
+
321
+ We describe the detail of a method to obtain the observation embedding. Given an observation of shape (84, 84, 3), we flatten the observation and project it to an embedding of dimension 64. We randomly initialize the parameter of the fully-connected layer for projection, and keep the values unchanged during the training to make the embedding stationary.
322
+
323
+ For the embedding of these observations, we cluster them based on a threshold value $\tau$ . The value of $\tau$ for each game with change of rooms is listed in Table 5. If the distance between the current embedding and the center ${ \mathrm { m e a n } } ( c )$ of a cluster $c$ is less than the threshold, we assign this embedding to the cluster with the smallest distance and update its center with the mean value of all embeddings belonging to this cluster. If the distance between the current embedding and the center of any cluster is larger than the threshold, we create a new cluster and this embedding is assigned to this new cluster.
324
+
325
+ # Algorithm 2 Observation Embedding Clustering
326
+
327
+ <table><tr><td>Initialize parameter θc for context embedding projector if applicable (which is not trainable) Initialize thresholdT for clustering Initialize clusters set C←@</td></tr><tr><td>for each observation s do DGet embedding of the observation from the random projection</td></tr><tr><td>U←fθ(s)</td></tr><tr><td>DFind a cluster to which the current embedding fits,if any Find a cluster c ∈ C with smallest |lmean(c) - vll ≤ T,or NIL if there is no such</td></tr><tr><td>if c≠NIL then</td></tr><tr><td>c↑cUv else</td></tr><tr><td>Dif there&#x27;s no existing cluster that v should be assigned to,create a new one</td></tr><tr><td>C↑Cu{u}</td></tr><tr><td>end if</td></tr><tr><td>end for</td></tr><tr><td></td></tr><tr><td></td></tr></table>
328
+
329
+ In Figure 7, we also show the samples of observation in each cluster. We could see observations from the same room are assigned to the same cluster and different clusters correspond to different rooms.
330
+
331
+ ![](images/b6bc5be5191a36c5fbb47c75b92f0c85ada4241f57b08dec9047d4687590bd33.jpg)
332
+
333
+ ![](images/22000869323c23338a4b19df7b8fa5172f90544898c3f43f056aaa0fa16042c3.jpg)
334
+ Figure 7: Sample of clustering results for VENTURE, HERO, PRIVATEEYE, and MONTEZUMA’S REVENGE. Each column is one cluster, and we show 3 random samples assigned into this cluster.
335
+
336
+ # E ABLATION STUDY ON ATTENTIVE DYNAMICS MODEL
337
+
338
+ We conduct a simple ablation study on the learning objectives of ADM, described in Equation (5). We evaluate the performance of ADM when trained on the same trajectory data under different combinations of loss terms, simulating batches of on-policy transition data to be replayed. The sample trajectory was obtained from an instance of $\mathbf { A } 2 \mathbf { C } + \mathbf { C } \mathbf { o } \mathbf { E } \mathbf { X } + \mathbf { R } \mathbf { A } \mathbf { M }$ and kept same across all the runs, which allows a fair comparison between different variants. We compare the following four methods:
339
+
340
+ • ADM (action) : train ADM using $\mathcal { L } _ { \mathrm { a c t i o n } }$ only • ADM (action, cell) : train ADM using $\mathcal { L } _ { \mathrm { a c t i o n } }$ and $\mathcal { L } _ { \mathrm { c e l l } }$ • ADM (action, ent) : train ADM using $\mathcal { L } _ { \mathrm { a c t i o n } }$ and $\mathcal { L } _ { \mathrm { e n t } }$ • ADM (action, cell, ent) $:$ train ADM using all losses $( \mathcal { L } _ { \mathrm { a c t i o n } } , \mathcal { L } _ { \mathrm { c e l l } } , \mathcal { L } _ { \mathrm { e n t } } )$
341
+
342
+ Figure 8 shows the average distance between the ground-truth location of the agent and the predicted one by ADM during the early stages of training. On MONTEZUMA’S REVENGE, there is only little difference between the variants although the full model worked slightly better on average. On FREEWAY, the effect of loss terms is more clear; in the beginning the agent tends to behave suboptimally by taking mostly single actions only (UP out of three action choices — UP, DOWN, and NO-OP), hence very low entropy $\mathcal { H } ( \pi ( \cdot | s ) )$ , which can confuse the ADM of telling which part is actually controllable as the action classifier would give correct answer regardless of attention. We can observe additional loss terms help the model quickly correct the attention to localize the controllable object among the uncontrollable clutters with better stability.
343
+
344
+ ![](images/a1e0d08ef84564439375320fdcbd2c0687d2ab585a9f80d4407351fb61d257e5.jpg)
345
+ Figure 8: Performance of ADM in terms of mean distance under different loss combinations in early stages, trained using the same online trajectory data. Plots were obtained by averaging runs over 5 random seeds.
346
+
347
+ In another ablation study, we compare the end performance of the $_ { \mathrm { A 2 C + C o E X } }$ agent with the ADM jointly trained under different loss objectives on these three games (MONTEZUMA’S REVENGE, FREEWAY and SEAQUEST). In our experiments, the variant with full ADM worked best on MONTEZUMA’S REVENGE and FREEWAY. The minimal training objective of ADM (i.e., $\mathcal { L } _ { \mathrm { a c t i o n } } )$ also solely works reasonably well, but with the combination of other loss terms we can attain a more stable performance.
348
+
349
+ ![](images/79064fb60cb0214666bd0cf101f15fccf94b76c97e989755553619fef2bba8a8.jpg)
350
+ Figure 9: Learning curves of $_ { \mathrm { A 2 C + C o E X } }$ with ADM trained under different training objectives. The curve in solid line shows the mean episode over 40 recent episodes, averaged over 3 random seeds.
351
+
352
+ ![](images/69d8f9da206db84630601005c2d1f891a6c85280b08d7a394a530ecc889b5008.jpg)
353
+ Figure 10: Learning curves for the ablation study of state representation. The exploration algorithm without the contingent region information (purple) performs significantly worse, yielding almost no improvement on hard-exploration games such as MONTEZUMA’S REVENGE, VENTURE, and FROSTBITE. The mean curve is obtained by averaging over 3 random seeds. See Table 6 for numbers.
354
+
355
+ <table><tr><td>Method</td><td>Freeway</td><td>Frostbite</td><td>Hero</td><td>Montezuma</td><td>PrivateEye</td><td>Qbert</td><td>Seaquest</td><td> Venture</td></tr><tr><td>A2C</td><td>7.2</td><td>1099</td><td>34352</td><td>12.5</td><td>574</td><td>19620</td><td>2401</td><td>0</td></tr><tr><td>A2C+CoEX (c)</td><td>10.7</td><td>1313</td><td>34269</td><td>14.7</td><td>2692</td><td>20942</td><td>1810</td><td>94</td></tr><tr><td>A2C+CoEX (c,R)</td><td>34.0</td><td>941</td><td>34046</td><td>9.2</td><td>5458</td><td>21587</td><td>2056</td><td>77</td></tr><tr><td>A2C+CoEX(x,y,c)</td><td>33.7</td><td>5066</td><td>36934</td><td>6558</td><td>5377</td><td>21130</td><td>1978</td><td>1374</td></tr><tr><td>A2C+CoEX (x, y,c, R)</td><td>34.0</td><td>4260</td><td>36827</td><td>6635</td><td>5316</td><td>23962</td><td>5169</td><td>204</td></tr></table>
356
+
357
+ Table 6: Summary of the results of the ablation study of the state representation. We report the maximum mean score (averaged over 40 recent episodes) achieved over 100M environment steps, averaged over 3 random seeds.
358
+
359
+ # F ABLATION STUDY ON THE STATE REPRESENTATION
360
+
361
+ We present a result of additional ablation study on the state representation $\psi ( s )$ used in count-based exploration. The following baselines are considered:
362
+
363
+ • $_ { Ḋ } \mathrm { A } 2 \mathrm { C } \mathrm { + } \mathrm { C o E X } ( c )$ : Uses only the context embedding for exploration, i.e., $\psi ( s ) = ( c )$ . • $\mathbf { A } 2 \mathbf { C } \mathbf { + } \mathbf { C o E X } ( c , R )$ : Uses only the context embedding and the cumulative reward for exploration without contingent region information, i.e., $\boldsymbol { \psi } ( s ) = \ : \mathbf { \bar { ( } } c , R )$ . • $\mathbf { A } 2 \mathbf { C } + \mathbf { C o E X } ( x , y , c )$ : Uses the contingent region information $( x , y )$ as well as the context embedding $c$ , however without the cumulative reward component, i.e., $\psi ( s ) = ( x , y , c )$ .
364
+
365
+ One can also consider another baseline similar to $\mathbf { A } 2 \mathbf { C } \mathbf { + } \mathbf { C o E X } ( c , R )$ with $\psi ( s ) = ( x , y , c , R )$ , where the location information $( x , y )$ is replaced with random coordinates uniformly sampled from the grid. It ablates the learned contingent regions. However, we found that it performs similarly to the presented $\mathbf { A } 2 \mathbf { C } \substack { + } \mathbf { C o E X } ( c , R )$ baseline.
366
+
367
+ The experimental results are summarized in Table 6 and Figure 10. The variants without contingent regions (i.e., $_ { \mathrm { A 2 C + C o E X } ( c ) }$ and $\mathbf { A } 2 \mathbf { C } \substack { + } \mathbf { C o E X } ( c , R )$ performed significantly worse in most of the games than $\mathrm { A } 2 \mathrm { C } + \mathrm { C o E X } ( x , y , c )$ and $\mathsf { A 2 C + C o E X } ( x , y , c , R )$ giving little improvement over the A2C baseline. Most notably, in the games with the hardest exploration such as MONTEZUMA’S REVENGE and VENTURE, the performance is hardly better than the vanilla A2C or a random policy, achieving a score as low as zero. The variants with contingent region information worked best and comparable to each other. We observe that using the cumulative reward (total score) for exploration gives a slight improvement on some environments. These results support the effectiveness of the learned contingency-awareness information in count-based exploration.
parse/train/HyxGB2AcY7/HyxGB2AcY7_content_list.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/HyxGB2AcY7/HyxGB2AcY7_middle.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/HyxGB2AcY7/HyxGB2AcY7_model.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/S1xtAjR5tX/S1xtAjR5tX.md ADDED
@@ -0,0 +1,433 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # IMPROVING SEQUENCE-TO-SEQUENCE LEARNING VIA OPTIMAL TRANSPORT
2
+
3
+ Liqun Chen1, Yizhe Zhang2, Ruiyi Zhang1, Chenyang $\mathbf { T a o } ^ { 1 }$ , Zhe $\mathbf { G a n ^ { 3 } }$ , Haichao Zhang4, Bai $\mathbf { L i } ^ { 1 }$ , Dinghan Shen1, Changyou Chen5, Lawrence Carin1 1Duke University, 2Microsoft Research, 3Microsoft Dynamics 365 AI Research 4Baidu Research, 5SUNY at Buffalo {liqun.chen}@duke.edu
4
+
5
+ # ABSTRACT
6
+
7
+ Sequence-to-sequence models are commonly trained via maximum likelihood estimation (MLE). However, standard MLE training considers a word-level objective, predicting the next word given the previous ground-truth partial sentence. This procedure focuses on modeling local syntactic patterns, and may fail to capture long-range semantic structure. We present a novel solution to alleviate these issues. Our approach imposes global sequence-level guidance via new supervision based on optimal transport, enabling the overall characterization and preservation of semantic features. We further show that this method can be understood as a Wasserstein gradient flow trying to match our model to the ground truth sequence distribution. Extensive experiments are conducted to validate the utility of the proposed approach, showing consistent improvements over a wide variety of NLP tasks, including machine translation, abstractive text summarization, and image captioning.
8
+
9
+ # 1 INTRODUCTION
10
+
11
+ Sequence-to-sequence (Seq2Seq) models are widely used in various natural language processing tasks, such as machine translation (Bahdanau et al., 2015; Cho et al., 2014; Sutskever et al., 2014), text summarization (Chopra et al., 2016; Rush et al., 2015) and image captioning (Vinyals et al., 2015; Xu et al., 2015). Typically, Seq2Seq models are based on an encoder-decoder architecture, with an encoder mapping a source sequence into a latent vector, and a decoder translating the latent vector into a target sequence. The goal of a Seq2Seq model is to optimize this encoder-decoder network to generate sequences close to the target. Therefore, a proper measure of the distance between sequences is crucial for model training.
12
+
13
+ Maximum likelihood estimation (MLE) is often used as the training paradigm in existing Seq2Seq models (Goodfellow et al., 2016; Lamb et al., 2016). The MLE-based approach maximizes the likelihood of the next word conditioned on its previous ground-truth words. Such an approach adopts cross-entropy loss as the objective, essentially measuring the word difference at each position of the target sequence (assuming truth for the preceding words). That is, MLE only provides a word-level training loss (Ranzato et al., 2016). Consequently, MLE-based methods suffer from the so-called exposure bias problem (Bengio et al., 2015; Ranzato et al., 2016), i.e., the discrepancy between training and inference stages. During inference, each word is generated sequentially based on previously generated words. However, ground-truth words are used in each timestep during training (Huszr, 2015; Wiseman & Rush, 2016). Such discrepancy in training and testing leads to accumulated errors along the sequence-generation trajectory, and may therefore produce unstable results in practice. Further, commonly used metrics for evaluating the generated sentences at test time are sequence-level, such as BLEU (Papineni et al., 2002) and ROUGE (Lin, 2004). This also indicates a mismatch of the training loss and test-time evaluation metrics.
14
+
15
+ Attempts have been made to alleviate the above issues, via a sequence-level training loss that enables comparisons between the entire generated and reference sequences. Such efforts roughly fall into two categories: $( i )$ reinforcement-learning-based (RL) methods (Bahdanau et al., 2017; Ranzato et al., 2016) and $( i i )$ adversarial-learning-based methods (Yu et al., 2017; Zhang et al., 2017). These methods overcome the exposure bias issue through criticizing model output during training; however, both schemes have their own vulnerabilities. RL methods often suffer from large variance on policy-gradient estimation, and control variates and carefully designed baselines (such as a selfcritic) are needed to make RL training more robust (Liu et al., 2018; Rennie et al., 2017). Further, the rewards used by RL training are often criticized as a bad proxy for human evaluation, as they are usually highly biased towards certain particular aspects (Wang et al., 2018b). On the other hand, adversarial supervision relies on the delicate balance of a mini-max game, which can be easily undermined by mode-trapping and gradient-vanishing problems (Arjovsky et al., 2017; Zhang et al., 2017). Sophisticated tuning is often desired for successful adversarial training.
16
+
17
+ ![](images/2340c4dae5dbcfe3177b03113bf5808ef7a9a09da9034aaee59a1a441508e24e.jpg)
18
+ Figure 1: Different matching schemes. Left to right: hard matching, soft bipartite matching and OT matching. Dominant edges are shown in dark green for OT matching.
19
+
20
+ We present a novel Seq2Seq learning scheme that leverages optimal transport (OT) to construct sequence-level loss. Specifically, the OT objective aims to find an optimal matching of similar words/phrases between two sequences, providing a way to promote their semantic similarity (Kusner et al., 2015). Compared with the above RL and adversarial schemes, our approach has: $( i )$ semanticinvariance, allowing better preservation of sequence-level semantic information; and $( i i )$ improved robustness, since neither the reinforce gradient nor the mini-max game is involved. The OT loss allows end-to-end supervised training and acts as an effective sequence-level regularization to the MLE loss.
21
+
22
+ Another novel strategy distinguishing our model from previous approaches is that during training we consider not only the OT distance between the generated sentence and ground-truth references, but also the OT distance between the generated sentence and its corresponding input. This enables our model to simultaneously match the generated output sentence with both the source sentence(s) and target reference sentence, thus enforcing the generator to leverage information contained in the input sentence(s) during generation.
23
+
24
+ The main contributions of this paper are summarized as follows. (i) A new sequence-level training algorithm based on optimal transport is proposed for Seq2Seq learning. In practice, the OT distance is introduced as a regularization term to the MLE training loss. (ii) Our model can be interpreted as approximate Wasserstein gradient flows, learning to approximately match the sequence distribution induced by the generator and a target data distribution. (iii) In order to demonstrate the versatility of the proposed method, we conduct extensive empirical evaluations on three tasks: machine translation, text summarization, and image captioning.
25
+
26
+ # 2 SEMANTIC MATCHING WITH OPTIMAL TRANSPORT
27
+
28
+ We consider two components of a sentence: its syntactic and semantic parts. In a Seq2Seq model, it is often desirable to keep the semantic meaning while the syntactic part can be more flexible. Conventional training schemes, such as MLE, are known to be well-suited for capturing the syntactic structure. As such, we focus on the semantic part. An intuitive way to assess semantic similarity is to directly match the “key words” between the synthesized and the reference sequences. Consider the respective sequences as sets A and $\mathbb { B }$ , with vocabularies as their elements. Then the matching can be evaluated by $| \mathbb { A } \cap \mathbb { B } |$ , where $| \cdot |$ is the counting measure for sets. We call this hard matching, as it seeks to exactly match words from both sequences.
29
+
30
+ For language models, the above hard matching could be an over simplification. This is because words have semantic meaning, and two different words can be close to each other in the semantic space. To account for such ambiguity, we can relax the hard matching to soft bipartite matching (SBM). More specifically, assuming all sequences have the same length $n$ , we pair $w _ { i _ { k } } \in \mathbb { A }$ and $\pmb { w } _ { j _ { k } } ^ { \prime } \in \mathbb { B }$ for $k \in [ 1 , K ]$ , such that $K \leq n$ , $\{ i _ { k } \} , \{ j _ { k } \}$ are unique and $\begin{array} { r } { \mathcal { L } _ { \mathrm { S B M } } = \sum _ { k } c ( \bar { \mathbf { w } _ { i _ { k } } } , \mathbf { w } _ { j _ { k } } ^ { \prime } ) } \end{array}$ is minimized. Here $c ( \pmb { w } , \pmb { w } ^ { \prime } )$ is a cost function measuring the semantic dissimilarity between the two words. For instance, the cosine distance $\begin{array} { r } { c ( \pmb { x } , \pmb { y } ) = 1 - \frac { \pmb { x } ^ { \top } \pmb { y } } { \| \pmb { x } \| _ { 2 } \| \pmb { y } \| _ { 2 } } } \end{array}$ between two word embedding vectors $_ { \textbf { \em x } }$ and $\textbf { { y } }$ is a popular choice (Pennington et al., 2014). This minimization can be solved exactly, e.g., via the Hungarian algorithm (Kuhn, 1955). Unfortunately, its $O ( n ^ { 3 } )$ complexity scales badly for common NLP tasks, and the objective is also non-differentiable wrt model parameters. As such, end-to-end supervised training is not feasible with the Hungarian matching scheme. To overcome this difficulty, we propose to further relax the matching criteria while keeping the favorable features of a semantic bipartite matching. OT arises as a natural candidate.
31
+
32
+ ![](images/2f8fd6257583385ebbf1530476e321ec4f1da0c72d4432ee60be85ac0bdc9094.jpg)
33
+ Figure 2: Schematic computation graph of OT loss.
34
+
35
+ # 2.1 OPTIMAL TRANSPORT AND WASSERSTEIN DISTANCE
36
+
37
+ We first provide a brief review of optimal transport, which defines distances between probability measures on a domain $\mathbb { X }$ (the sequence space in our setting). The optimal transport distance for two probability measures $\mu$ and $\nu$ is defined as (Peyre et al., 2017): ´
38
+
39
+ $$
40
+ \mathcal { D } _ { c } ( \mu , \nu ) = \operatorname* { i n f } _ { \gamma \in \Pi ( \mu , \nu ) } \mathbb { E } _ { ( { \pmb x } , { \pmb y } ) \sim \gamma } \left[ c ( { \pmb x } , { \pmb y } ) \right] ,
41
+ $$
42
+
43
+ where $\Pi ( \mu , \nu )$ denotes the set of all joint distributions $\gamma ( \pmb { x } , \pmb { y } )$ with marginals $\mu ( { \pmb x } )$ and $\nu ( \pmb { y } )$ ; $c ( \pmb { x } , \pmb { y } ) : \mathbb { X } \times \mathbb { X } \mathbb { R }$ is the cost function for moving $_ { \textbf { \em x } }$ to $\textbf { { y } }$ , e.g., the Euclidean or cosine distance. Intuitively, the optimal transport distance is the minimum cost that $\gamma$ induces in order to transport from $\mu$ to $\nu$ . When $c ( { \pmb x } , { \pmb y } )$ is a metric on $\mathbb { X }$ , $\mathcal { D } _ { c } ( \mu , \nu )$ induces a proper metric on the space of probability distributions supported on $\mathbb { X }$ , commonly known as the Wasserstein distance (Villani, 2008). One of the most popular choices is the 2−Wasserstein distance $W _ { 2 } ^ { 2 } ( \mu , \nu )$ where the squared Euclidean distance $c ( { \pmb x } , { \pmb y } ) = \| { \pmb x } - { \pmb y } \| ^ { 2 }$ is used as cost.
44
+
45
+ OT distance on discrete domains We mainly focus on applying the OT distance on textual data. Therefore, we only consider OT between discrete distributions. Specifically, consider two discrete distributions $\mu , \pmb { \nu } \in \mathbf { P } ( \mathbb { X } )$ , which can be written as $\begin{array} { r } { \pmb { \mu } = \sum _ { i = 1 } ^ { n } \mathbf { u } _ { i } \delta _ { \mathbf { x } _ { i } } } \end{array}$ and $\begin{array} { r } { \pmb { \nu } ^ { * } = \sum _ { j = 1 } ^ { m } \mathbf { v } _ { j } \delta _ { \mathbf { y } _ { j } } } \end{array}$ with $\delta _ { \mathbf { x } }$ the Dirac function centered on x. The weight vectors u = {ui}ni=1 and $\mathbf { v } = \{ \mathbf { v } _ { i } \} _ { i = 1 } ^ { m } \in \Delta _ { m }$ respectively belong to the $n$ and $m$ -dimensional simplex, i.e., $\textstyle \sum _ { i = 1 } ^ { n ^ { \widehat { \mathbf { \phi } } } } \mathbf { u } _ { i } = \sum _ { j = 1 } ^ { m } \mathbf { v } _ { j } \doteq \bar { 1 }$ , as both $\pmb { \mu }$ and $\pmb { \nu }$ are probability distributions. Under such a setting, computing the OT distance as defined in (1) is equivalent to solving the following network-flow problem (Luise et al., 2018):
46
+
47
+ $$
48
+ \mathcal { L } _ { \mathrm { o t } } ( \mu , \nu ) = \operatorname* { m i n } _ { \mathbf { T } \in \Pi ( \mathbf { u } , \mathbf { v } ) } \sum _ { i = 1 } ^ { n } \sum _ { j = 1 } ^ { m } \mathbf { T } _ { i j } \cdot c ( \pmb { x } _ { i } , \pmb { y } _ { j } ) = \operatorname* { m i n } _ { \mathbf { T } \in \Pi ( \mathbf { u } , \mathbf { v } ) } \left. \mathbf { T } , \mathbf { C } \right. ,
49
+ $$
50
+
51
+ where $\Pi ( \mathbf { u } , \mathbf { v } ) \ = \ \{ \mathbf { T } \ \in \ \mathbb { R } _ { + } ^ { n \times m } | \mathbf { T } \mathbf { 1 } _ { m } \ = \ \mathbf { u } , \mathbf { T } ^ { \top } \mathbf { 1 } _ { n } \ = \ \mathbf { v } \}$ , ${ \bf 1 } _ { n }$ denotes an $n$ -dimensional all-one vector, $\mathbf { C }$ is the cost matrix given by ${ \bf C } _ { i j } = c ( { \bf x } _ { i } , { \bf y } _ { j } )$ and $\langle \mathbf { T } , \mathbf { C } \rangle = \operatorname { T r } ( \mathbf { T } ^ { \top } \mathbf { C } )$ represents the Frobenius dot-product. We refer to the minimizer $\mathbf { T } ^ { * }$ of (2) as OT matching. Comparing the two objectives, one can readily recognize that soft bipartite matching represents a special constrained solution to (2), where $\mathbf { T }$ can only take values in $\Gamma = \{ { \bf T } | \operatorname* { m a x } _ { i } \{ \| { \bf \hat { T } e } _ { i } \| _ { 0 } , \| { \bf e } _ { i } ^ { T } { \bf \hat { T } } \| _ { 0 } \} \le 1 , { \bf T } _ { i j } \ \in$ $\{ 0 , 1 \} , \| \mathbf { T } \| _ { 0 } = K \}$ instead of $\scriptstyle \Pi ( \mathbf { u } , \mathbf { v } )$ ; here $\| \cdot \| _ { 0 }$ is the $L _ { 0 }$ norm and $\mathbf { e } _ { i }$ is the unit vector along $i$ -th axis. As such, OT matching can be regarded as a relaxed version of soft bipartite matching. In Figure 1 we illustrate the three matching schemes discussed above.
52
+
53
+ The IPOT algorithm Unfortunately, the exact minimization over $\mathbf { T }$ is in general computational intractable (Arjovsky et al., 2017; Genevay et al., 2018; Salimans et al., 2018). To overcome such intractability, we consider an efficient iterative approach to approximate the OT distance. We propose to use the recently introduced Inexact Proximal point method for Optimal Transport (IPOT) algorithm to compute the OT matrix $\mathbf { T } ^ { * }$ , thus also the OT distance (Xie et al., 2018). IPOT provides a solution to the original OT problem specified in (2). Specifically, IPOT iteratively solves the following optimization problem using the proximal point method (Boyd & Vandenberghe, 2004):
54
+
55
+ $$
56
+ \mathbf { T } ^ { ( t + 1 ) } = \underset { \mathbf { T } \in \Pi ( \pmb { x } , \pmb { y } ) } { \arg \operatorname* { m i n } } \left. \left. \mathbf { T } , \mathbf { C } \right. + \beta \cdot \mathcal { B } ( \mathbf { T } , \mathbf { T } ^ { ( t ) } ) \right. ,
57
+ $$
58
+
59
+ where the proximity metric term $B ( \mathbf { T } , \mathbf { T } ^ { ( t ) } )$ penalizes solutions that are too distant from the latest approximation, and $\frac { 1 } { \beta }$ is understood as the generalized stepsize. This renders a tractable iterative scheme towards the exact OT solution. In this work, we employ the generalized KL Bregman diver$\begin{array} { r } { \mathcal { B } ( \mathbf { T } , \mathbf { T } ^ { ( t ) } ) = \sum _ { i , j } \mathbf { T } _ { i j } \log \frac { \mathbf { T } _ { i j } } { \mathbf { T } _ { i j } ^ { ( t ) } } - \sum _ { i , j } \mathbf { T } _ { i j } + \sum _ { i , j } \mathbf { T } _ { i j } ^ { ( t ) } } \end{array}$ as the proximity metric. Algorithm 1 describes the implementation details for IPOT
60
+
61
+ Note that the Sinkhorn algorithm (Cuturi, 2013) can also be used to compute the OT matrix. Specifically, the Sinkhorn algorithm tries to solve the entropy regularized optimization problem: $\begin{array} { r } { \hat { \mathcal { L } } _ { \mathrm { o t } } ( { \pmb \mu } , { \pmb \nu } ) = \operatorname* { m i n } _ { { \bf T } \in \Pi ( { \bf u } , { \bf v } ) } \left. { \bf T } , { \bf C } \right. - { \frac { 1 } { \epsilon } } H ( { \bf T } ) , } \end{array}$ where $\begin{array} { r } { H ( \mathbf { T } ) = - \sum _ { i , j } \mathbf { T } _ { i j } \big ( \log ( \mathbf { T } _ { i j } ) \big ) - 1 \big ) } \end{array}$ is the entropy regularization term and $\epsilon > 0$ is the regularization strength. However, in our experiments, we empirically found that the numerical stability and performance of the Sinkhorn algorithm is quite sensitive to the choice of the hyper-parameter $\epsilon$ , thus only IPOT is considered in our model training.
62
+
63
+ # Algorithm 1 IPOT algorithm
64
+
65
+ 1: Input: Feature vectors $\mathbf { S } = \{ z _ { i } \} _ { 1 } ^ { n }$ , ${ \bf S } ^ { \prime } = \{ z _ { j } ^ { \prime } \} _ { 1 } ^ { m }$
66
+ and generalized stepsize $1 / \beta$ ,
67
+ 2: $\begin{array} { r } { \pmb { \sigma } = \frac { 1 } { m } \pmb { 1 } _ { \mathbf { m } } } \end{array}$ , $\mathbf { T } ^ { ( 1 ) } = \mathbf { 1 _ { n } } { \mathbf { 1 _ { m } } } ^ { \top }$
68
+ 3: $\mathbf { C } _ { i j } = c ( z _ { i } , z _ { j } ^ { \prime } )$ , $\mathbf { A } _ { i j } = \mathrm { e } ^ { - \frac { \mathbf { C } _ { i j } } { \beta } }$
69
+ 4: for $t = 1 , 2 , 3 \ldots { } \mathbf { d o }$
70
+ 5: $\mathbf { Q } = \mathbf { A } \odot \mathbf { T } ^ { \left( t \right) } / / \odot$ is Hadamard product
71
+ 6: for $k = 1 , \dots K$ do // $K = 1$ in practice
72
+ 7: $\begin{array} { r } { \pmb { \delta } = \frac { 1 } { n \mathbf { Q } \sigma } , \pmb { \sigma } = \frac { 1 } { m \mathbf { Q } ^ { \top } \pmb { \delta } } } \end{array}$
73
+ 8: end for
74
+ 9: $\mathbf { T } ^ { ( t + 1 ) } = \mathrm { d i a g } ( \delta ) \mathbf { Q } \mathrm { d i a g } ( { \boldsymbol { \sigma } } )$
75
+ 10: end for
76
+ 11: Return $\langle \mathbf { T } , \mathbf { C } \rangle$
77
+
78
+ # 2.2 OPTIMAL TRANSPORT DISTANCE AS A SEQUENCE LEVEL LOSS
79
+
80
+ Figure 2 illustrates how OT is computed to construct the sequence-level loss. Given two sentences, we can construct their word-level or phrase-level embedding matrices $\mathbf { S }$ and $\mathbf { S } ^ { \prime }$ , where ${ \bf { S } } = \{ { z } _ { i } \}$ is usually recognized as the reference sequence embedding and $\mathbf { S } ^ { \prime } = \{ z _ { j } ^ { \prime } \}$ for the model output sequence embedding. The cost matrix C is then computed by $\mathbf { C } _ { i j } = c ( z _ { i } , z _ { j } ^ { \prime } )$ and passed on to the IPOT algorithm to get the OT distance. Our full algorithm is summarized in Algorithm 2, and more detailed model specifications are given below.
81
+
82
+ Encoding model belief with a differentiable sequence generator We first describe how to design a differentiable sequence generator so that the gradients can be backpropagated from the OT losses to update the model belief. The Long Short-Term Memory (LSTM) recurrent neural network (Hochreiter & Schmidhuber, 1997) is used as our sequence model. At each timestep $t$ , the LSTM decoder outputs a logit vector ${ \mathbf { } } v _ { t }$ for the vocabularies, based on its context. Directly sampling from the multinomial distribution $\hat { \pmb { w } } _ { t } \sim \mathrm { S o f t m a x } ( \pmb { v } _ { t } )$ is a non-differentiable operation1, so we consider the following differentiable alternatives:
83
+
84
+ • Soft-argmax: $\hat { \pmb { w } } _ { t } ^ { S A } = \mathrm { S o f t m a x } ( \pmb { v } _ { t } / \tau )$ , where $\tau \in ( 0 , 1 )$ is the annealing parameter (Zhang et al., 2017). This approximates the deterministic sampling scheme $\hat { \pmb { w } } _ { t } ^ { \operatorname* { m a x } } = \arg \operatorname* { m a x } \{ \pmb { v } _ { t } \}$ ; • Gumbel-softmax (GS): $\hat { \pmb { w } } _ { t } ^ { G S } = \mathrm { S o f t m a x } ( ( \pmb { v } _ { t } + \pmb { \xi } _ { t } ) / \tau )$ , where $\xi _ { t }$ are iid Gumbel random variables for each of the vocabulary. It is also known as the Concrete distribution (Jang et al., 2016; Maddison et al., 2017).
85
+
86
+ Unstable training and sub-optimal solutions have been observed for the GS-based scheme for the Seq2Seq tasks we considered (see Appendix G, Table 11), possibly due to the extra uncertainty introduced. As such, we will assume the use of soft-argmax to encode model belief in $\hat { \pmb { w } } _ { t }$ unless otherwise specified. Note $\hat { \mathbf { \Omega } } \hat { \mathbf { \Omega } } ^ { \hat { \mathbf { \Omega } } } \hat { \mathbf { \Omega } } ^ { \hat { \mathbf { \Omega } } } \hat { \mathbf { \Omega } } ^ { \hat { \mathbf { \Omega } } } \hat { \mathbf { \Omega } } \hat { \mathbf { \Omega } } \mathrm { ~ \Omega ~ } \hat { \mathbf { \Omega } } ^ { \hat { \mathbf { \Omega } } } \hat { \mathbf { \Omega } } \mathrm { ~ \Omega ~ } \hat { \mathbf { \Omega } } \mathrm { ~ \Omega ~ } \hat { \mathbf { \Omega } } \mathrm { ~ \Omega ~ } \hat { \mathbf { \Omega } } \mathrm { ~ \Omega ~ } \hat { \mathbf { \Omega } } \mathrm { ~ \Omega ~ }$ is a normalized non-negative vector that sums up to one.
87
+
88
+ Sequence-level OT-matching loss To pass on the model belief to the OT loss, we use the mean word embedding predicted by the model, given by $\hat { z } _ { t } = \mathbf { E } ^ { T } \hat { w } _ { t }$ , where $\mathbf { E } \in \mathbb { R } ^ { V \times d }$ is the word embedding matrix, $V$ is the vocabulary size and $d$ is the dimension for the embedding vector. We collect the predicted sequence embeddings into $\mathbf { S } _ { g } = \{ \hat { z } _ { t } \} _ { t = 1 } ^ { L }$ , where $L$ is the length of sequence. Similarly we denote the reference sequence embeddings as $\mathbf { S } _ { r } = \{ z _ { t } \} _ { t = 1 } ^ { L }$ , using ground truth onehot input token sequence $\{ { \pmb w } _ { t } \}$ . Based on the sequence embeddings $\mathbf { S } _ { r }$ and $\mathbf { S } _ { g }$ , we can compute the sequence-level OT loss between ground-truth and model prediction using the IPOT algorithm described above for different Seq2Seq tasks:
89
+
90
+ $$
91
+ \mathcal { L } _ { \mathrm { s e q } } \triangleq \operatorname { I P O T } ( \mathbf { S } _ { g } , \mathbf { S } _ { r } ) .
92
+ $$
93
+
94
+ 1: Input: batch size $m$ , paired input and output sequences $( \mathbf { X } , \mathbf { Y } )$
95
+ 2: Load MLE pre-trained Seq2Seq model $\mathcal { M } ( \cdot ; \theta )$ and word embedding $\mathbf { E }$
96
+ 3: for iteration $= 1 , \ldots$ MaxIter do
97
+ 4: for $i = 1 , \ldots , m$ do
98
+ 5: Draw a pair of sequences ${ \pmb x } _ { i } , { \pmb y } _ { i } \sim ( { \bf X } , { \bf Y } )$ , where $\pmb { x } _ { i } = \{ \tilde { \pmb { w } } _ { i , t } \} , \pmb { y } _ { i } = \{ \pmb { w } _ { i , t } \}$
99
+ 6: Compute logit vectors from model: $\{ \pmb { v } _ { i , t } \} = \mathcal { M } ( \pmb { x } _ { i } ; \theta )$
100
+ 7: Encode model belief: $\hat { \pmb { w } } _ { i , t } = \mathrm { S o f t - a r g m a x } ( \pmb { v } _ { i , t } )$
101
+ 8: Feature vector embedding: $\mathbf { S } _ { r , i } = \{ \mathbf { E } ^ { T } \pmb { w } _ { i , t } \} , \mathbf { S } _ { g , i } = \{ \mathbf { E } ^ { T } \pmb { \hat { w } } _ { i , t } \}$
102
+ 9: end for
103
+ 10: Update the $\mathcal { M } ( \cdot ; \theta )$ by optimizing: $\begin{array} { r } { \frac { 1 } { m } \sum _ { i = 1 } ^ { m } [ \mathcal { L } _ { \mathrm { M L E } } ( \pmb { x } _ { i } , \pmb { y } _ { i } ; \theta ) + \gamma \mathcal { L } _ { \mathrm { s e q } } ( \mathbf { S } _ { r , i } , \mathbf { S } _ { g , i } ) ] } \end{array}$
104
+ 11: end for
105
+
106
+ Soft-copying mechanism We additionally consider feature matching using the OT criteria between the source and target. Intuitively, it will encourage the global semantic meaning to be preserved from source to target. This is related to the copy network (Gu et al., 2016). However, in our framework, the copying mechanism can be understood as a soft optimal-transport-based copying, instead of the original hard retrieved-based copying used by Gu et al. (2016). This soft copying mechanism considers semantic similarity in the embedding space, and thus presumably delivers smoother transformation of information. In the case where the source and target sequences do not share vocabulary (e.g., machine translation), this objective can still be applied by sharing the word embedding space between source and target. Ideally, the embedding for the same concept in different languages will automatically be aligned by optimizing such loss, making available a cosinesimilarity-based cost matrix. This is also related to bilingual skip-gram (Luong et al., 2015b). We denote this loss as $\mathcal { L } _ { \mathrm { c o p y } } \triangleq \operatorname { I P O T } ( \mathbf { S } _ { g } , \mathbf { S } _ { s } )$ , where $\mathbf { S } _ { s }$ represents the source sequence embeddings.
107
+
108
+ Complementing MLE training with OT regularization OT training objectives discussed above can not train a proper language model on its own, as they do not explicitly consider word ordering, i.e., the syntactic strucuture of a language model. To overcome this issue, we propose to combine the OT loss with the de facto likelihood loss $\mathcal { L } _ { \mathrm { M L E } }$ , which gives us the final training objective: $\mathcal { L } = \mathcal { L } _ { \mathrm { M L E } } + \gamma \mathcal { L } _ { \mathrm { s e q } }$ , where $\gamma > 0$ is a hyper-parameter to be tuned. For tasks with both input and output sentences, such as machine translation and text summarization, $\mathcal { L } _ { \mathrm { c o p y } }$ can be applied, in which case the final objective can be written as $\mathcal { L } = \mathcal { L } _ { \mathrm { M L E } } + \gamma _ { 1 } \mathcal { L } _ { \mathrm { c o p y } } + \gamma _ { 2 } \mathcal { L } _ { \mathrm { s e q } }$ .
109
+
110
+ # 3 INTERPRETATION AS APPROXIMATE WASSERSTEIN GRADIENT FLOWS
111
+
112
+ To further justify the use of our approach (minimizing the loss $\{ \mathcal { L } _ { \mathrm { M L E } } + \gamma \mathcal { L } _ { o t } \}$ , where $\mathcal { L } _ { o t }$ denotes the Wasserstein loss), we now explain how our model approximately learns to match the ground-truth sequence distribution. Our derivation is based on the theory of Wasserstein gradient flows (WGF) (Villani, 2008). In WGF, the Wasserstein distance describes the local geometry of a trajectory in the space of probability measures converging to a target distribution (Ambrosio et al., 2005). In the following, we show that the proposed method learns to approximately match the data distribution, from the perspective of WGF. For simplicity we only discuss the continuous case, while a similar argument also holds for the discrete case (Li & Montufar, 2018).
113
+
114
+ We denote the induced distribution of the sequences generated from the decoder at the $l$ -th iteration as $\mu _ { l }$ . Assume the sequence data distribution is given by $p _ { d } ( \mathbf { x } )$ . Intuitively, the optimal generator in a Seq2Seq model learns a distribution $\mu ^ { * } ( \mathbf { x } )$ that matches $p _ { d } ( \mathbf { x } )$ . Based on Craig (2014), this can be achieved by composing a sequence of discretized WGFs given by:
115
+
116
+ $$
117
+ \mu _ { l } = J _ { h } ( \mu _ { l - 1 } ) = J _ { h } ( J _ { h } ( \cdot \cdot \cdot ( \mu _ { 0 } ) ) ) ,
118
+ $$
119
+
120
+ with $J _ { h } ( \cdot )$ defined as
121
+
122
+ $$
123
+ J _ { h } ( \mu ) = \underset { \nu \in \mathcal { P } _ { s } } { \arg \operatorname* { m i n } } \left\{ \frac { 1 } { 2 h } W _ { 2 } ^ { 2 } ( \mu , \nu ) + D _ { \mathrm { K L } } ( \nu \parallel \mathbf { \mathit { p } } _ { d } ) \right\} = \underset { \nu \in \mathcal { P } _ { s } } { \arg \operatorname* { m i n } } \{ \mathcal { L } _ { \mathrm { W G F } } ( \mu , \nu ) \} ,
124
+ $$
125
+
126
+ where $\lambda = 1 / ( 2 h )$ is a regularization parameter ( $h$ is the generalized learning rate); $W _ { 2 } ^ { 2 } ( \mu , \nu )$ denotes the 2-Wasserstein distance between $\mu$ and $\nu$ ; $\mathcal { P } _ { s }$ is the space of distributions with finite 2nd-order moments; and $D _ { \mathrm { K L } } ( \nu \parallel p _ { d } ) = \mathbb { E } _ { \mathbf { x } \sim \nu } [ \log \nu ( \mathbf { x } ) - \log p _ { d } ( \mathbf { x } ) ]$ is the Kullback-Leibler (KL)
127
+
128
+ divergence. It is not difficult to see that discreteized WGF is essentially optimizing the KL divergence with a proximal descent scheme, using the 2-Wasserstein distance as the proximity metric.
129
+
130
+ We denote $\mu _ { h } ^ { * } = \operatorname* { l i m } _ { l \to \infty } \mu _ { l }$ with generalized learning rate $h$ . It is well known that $\mathrm { l i m } _ { h 0 } \mu _ { h } ^ { * } =$ $p _ { d }$ (Chen et al., 2018a), that is to say the induced model distribution $\mu _ { l }$ asymptotically converges to the data distribution $p _ { d }$ . In our case, instead of using $\mathcal { L } _ { \mathrm { W G F } } ( \mu , \nu )$ as the loss function, we define a surrogate loss using its upper bound $\mathcal L _ { \operatorname { W G F } } ( \mu , \nu ) \le \mathcal L _ { \operatorname { W G F } } ( p _ { d } , \nu )$ , where the inequality holds because (6) converges to $p _ { d }$ . When our model distribution $\mu$ is parameterized by $\theta , \mu _ { l }$ can be solved with stochastic updates on $\theta$ based on the following equation with stepsize $\eta$ :
131
+
132
+ $$
133
+ \theta _ { l } \xleftarrow \theta _ { l - 1 } + \eta \nabla _ { \theta } \mathcal { L } _ { \mathrm { W G F } } ( p _ { d } , \mu _ { l - 1 } ) = \theta _ { l - 1 } + \eta \{ \nabla _ { \theta } D _ { \mathrm { K L } } ( \mu _ { l - 1 } ~ \Vert ~ p _ { d } ) + \frac { 1 } { 2 h } \nabla _ { \theta } W _ { 2 } ^ { 2 } ( p _ { d } , \mu _ { l - 1 } ) \} .
134
+ $$
135
+
136
+ Unfortunately, (7) is an infeasible update as we do not know $p _ { d }$ . However, we argue that this update is still locally valid when current model approximation $\mu _ { l - 1 }$ is close to $p _ { d }$ . To see this, recall that the KL-divergence is a natural Riemannian metric on the space of probability measures (Amari, 1985), therefore it is locally symmetric. So we can safely replace the $D _ { \mathrm { K L } } ( \mu \parallel p _ { d } )$ term with $D _ { \mathrm { K L } } ( p _ { d } \parallel \mathbf { \mu } \mathbf { \mu } )$ when $\mu$ is close to $p _ { d }$ . This recovers the loss function $\mathcal { L } _ { \mathrm { M L E } } + \gamma \mathcal { L } _ { \mathrm { s e q } }$ derived in Section 2.2 as $D _ { \mathrm { K L } } ( p _ { d } \parallel \mu ) = \mathcal { L } _ { \mathrm { M L E } } + H ( p _ { d } )$ , where $H ( p _ { d } )$ is the entropy of $p _ { d }$ , independent of $\mu$ , and $\mathcal { L } _ { \mathrm { s e q } } = W _ { 2 } ^ { 2 } ( p _ { d } , \mu )$ . This justifies the use of our proposed scheme in a model-refinement stage, where model distribution $\mu$ is sufficiently close to $p _ { d }$ . Empirically, we have observed that our scheme also improves training even when $\mu$ is distant from $p _ { d }$ . While the above justification is developed based on Euclidean transport, other non-Euclidean costs such as cosine distance usually yield better empirical performance as they are more adjusted to the geometry of sequence data.
137
+
138
+ # 4 RELATED WORK AND DISCUSSION
139
+
140
+ Optimal transport in NLP Although widely used in other fields such as computer vision (Rubner et al., 2000), OT has only been applied in NLP recently. Pioneered by the work of Kusner et al. (2015) on word mover’s distance (WMD), existing literature primarily considers OT either on a macroscopic level like topic modeling (Huang et al., 2016), or a microscopic level such as word embedding (Xu et al., 2018). Euclidean distance, instead of other more general distance, is often used as the transportation cost, in order to approximate the OT distance with the KantorovichRubinstein duality (Gulrajani et al., 2017) or a more efficient yet less accurate lower bound (Kusner et al., 2015). Our work employs OT for mesoscopic sequence-to-sequence models, presenting an efficient IPOT-based implementation to enable end-to-end learning for general cost functions. The proposed OT not only refines the word embedding matrix but also improves the Seq2Seq model (see Appendix H for details).
141
+
142
+ RL for sequence generation A commonly employed strategy for sequence-level training is via reinforcement learning (RL). Typically, this type of method employs RL by considering the evaluation metrics as the reward to guide the generation (Bahdanau et al., 2017; Huang et al., 2018; Ranzato et al., 2016; Rennie et al., 2017; Zhang et al., 2018a). However, these approaches often introduce procedures that may yield large-variance gradients, resulting in unstable training. Moreover, it has been recognized that these automatic metrics may have poor correlation with human judgments in many scenarios (Wang et al., 2018b). As such, reinforcing the evaluation metrics can potentially boost the quantitative scores but not necessarily improve the generation quality, as such metrics usually encourage exact text snippets overlapping rather than semantic similarity. Some nonstandard metrics like SPICE (Anderson et al., 2016) also consider semantic similarity, however they also can not learn a good model on their own (Liu et al., 2017). Unlike RL methods, our method requires no human-defined rewards, thus preventing the model from over-fitting to one specific metric. As a concrete example, the two semantically similar sentences “do you want to have lunch with us ” and “would you like to join us for lunch” would be considered as a bad match based on automatic metrics like BLEU, however, be rated as reasonable match in OT objective.
143
+
144
+ GAN for sequence generation Another type of method adopts the framework of generative adversarial networks (GANs) (Goodfellow et al., 2014), by providing sequence-level guidance based on a learned discriminator (or, critic). To construct such a loss, Fedus et al. (2018); Guo et al. (2018); Lin et al. (2017); Yu et al. (2017) combine the policy-gradient algorithm with the original GAN training procedure, while Chen et al. (2018b); Zhang et al. (2017) uses a so-called feature mover distance and maximum mean discrepancy (MMD) to match features of real and generated sentences, respectively.
145
+
146
+ Table 1: BLEU scores on VI-EN and EN-VI.
147
+
148
+ <table><tr><td>Systems</td><td>NT2012</td><td>NT2013</td></tr><tr><td>VI-EN:GNMT</td><td>20.7</td><td>23.8</td></tr><tr><td>VI-EN: GNMT+ Lseq</td><td>21.9</td><td>25.4</td></tr><tr><td>VI-EN: GNMT+Lseq+Lcopy</td><td>21.9</td><td>25.5</td></tr><tr><td>EN-VI: GNMT</td><td>23.8</td><td>26.1</td></tr><tr><td>EN-VI: GNMT+ Lseq</td><td>24.4</td><td>26.5</td></tr><tr><td>EN-VI: GNMT+Lseq+Lcopy</td><td>24.5</td><td>26.9</td></tr></table>
149
+
150
+ Table 2: BLEU scores on DE-EN and EN-DE.
151
+
152
+ <table><tr><td>Systems</td><td>NT2013</td><td>NT2015</td></tr><tr><td>DE-EN: GNMT</td><td>29.0</td><td>29.9</td></tr><tr><td>DE-EN: GNMT+Lseq</td><td>29.1</td><td>29.9</td></tr><tr><td>DE-EN: GNMT+Lseq+Lcopy</td><td>29.2</td><td>30.1</td></tr><tr><td>EN-DE: GNMT</td><td>24.3</td><td>26.5</td></tr><tr><td>EN-DE: GNMT+Lseq</td><td>24.3</td><td>26.6</td></tr><tr><td>EN-DE: GNMT+Lseq+Lcopy</td><td>24.6</td><td>26.8</td></tr></table>
153
+
154
+ However, mode-collapse and gradient-vanishing problems make the training of these methods challenging. Unlike GAN methods, since no min-max games are involved, the training of our model is more robust. Moreover, compared with GAN, no additional critic is introduced in our model, which makes the model complexity comparable to MLE and less demanding to tune.
155
+
156
+ # 5 EXPERIMENTS
157
+
158
+ We consider a wide range of NLP tasks to experimentally validate the proposed model, and benchmark it with other strong baselines. All experiments are implemented with Tensorflow and run on a single NVIDIA TITAN X GPU. Code for our experiments are available from https: //github.com/LiqunChen0606/Seq2Seq-OT.
159
+
160
+ # 5.1 NEURAL MACHINE TRANSLATION
161
+
162
+ We test our model on two datasets: $( i )$ a small-scale English-Vietnamese parallel corpus of TEDtalks, which has 133K sentence pairs from the IWSLT Evaluation Campaign (Cettolo et al., 2015); and $( i i )$ a large-scale English-German parallel corpus with $4 . 5 \mathrm { M }$ sentence pairs, from the WMT Evaluation Campaign (Vaswani et al., 2017). We used Google’s Neural Machine Translation (GMNT) model (Wu et al., 2016) as our baseline, following the architecture and hyper-parameter settings from the GNMT repository2 to make a fair comparison. For the English-Vietnamese (i.e., VI-EN and EN-VI) tasks, a 2-layer LSTM with 512 units in each layer is adopted as the decoder, with a 1-layer bidirectional-LSTM adopted as the encoder; the word embedding dimension is set to 512. Attention proposed in Luong et al. (2015a) is used together with a dropout rate of 0.2. For the English-German (i.e., DE-EN and EN-DE) tasks, we train a 4-layer LSTM decoder with 1024 units in each layer. A 2-layer bidirectional-LSTM is used as the encoder, and we adopt the attention used in Wu et al. (2016). The word embedding dimension is set to 1024. Standard stochastic gradient descent is used for training with a decreasing learning rate, and we set $\beta = 0 . 5$ for the IPOT algorithm. More training details are provided in Appendix A. In terms of wall-clock time, our model only slightly increases training time. For the German-English task, it took roughly 5.5 days to train the GNMT model, and 6 days to train our proposed model from scratch, which only amounts to a roughly $1 0 \%$ increase.
163
+
164
+ We apply different combinations of $\mathcal { L } _ { \mathrm { c o p y } }$ and $\mathcal { L } _ { \mathrm { s e q } }$ to fine-tune the pre-trained GNMT model (Luong et al., 2018) and the results are summarized in Table 1 and 2. . Additional results for training from scratch are provided in Appendix B. The proposed OT approach consistently improves upon MLE training in all experimental setups.
165
+
166
+ We additionally tested our model with a more expressive 8-layer LSTM model on the EN-DE task. The BLEU score of our method is 28.0 on NT2015. For reference, the GNMT model (same architecture) and a Transformer model (Vaswani et al., 2017) respectively report a score of 27.6 and 27.3. Our method outperforms both baselines, and it is also competitive to the state-of-the-art BLEU score 28.4 reported by Vaswani et al. (2017) using a highly sophisticated model design.
167
+
168
+ The German-to-English translation examples are provided in Table 3 for qualitative assessment. The main differences among the reference translation, our translation and the GNMT translation are highlighted in blue and red. Our OT-augmented translations are more faithful to the reference than its MLE-trained counterpart. The soft-copying mechanism introduced by OT successfully maintains the key semantic content from the reference. Presumably, the OT loss helps refine the word embedding matrices, and promotes matching between words with similar semantic meanings. Vanilla
169
+
170
+ Table 3: Comparison of German-to-English translation examples. Matched key phrases are shown in the same color. First example: “May” is not the date when the new prime minister visited Japan, but actually is the time he won the election. Second example: GNMT’s paraphrase choices are not as accurate as ours. Third example: “nominating committee” is controlled by the government, not a “UN-controlled nomination committee” in GNMT’s result, and it also fails to capture the word “retain”.
171
+
172
+ <table><tr><td>Reference: GNMT: Ours:</td><td>India&#x27;s new prime minister,Narendra Modi, ismeeting his Japanese counterpart,Shinzo Abe,in Tokyo to discuss economic and security ties,on his first major foreign visit since winning May&#x27;s election. India s new prime minister,Narendra Modi,is meeting his Japanese counterpart,Shinzo Abe,in Tokyo at his first important visit abroad in May to discuss economic and security relations. Indias new Prime Minister Narendra Modi meets his Japanese counterpart,Shinzo Abe,in Tokyo at his first major foreign visit since his election in May in order to discuss economic and security relations .</td></tr><tr><td>Reference: GNMT:</td><td>The next day, turning up for work as usual, she was knocked down by a motorcyclist who had mounted the pavement inwhat passers-by described as a &quot;vicious rage.&quot; 57 The next day,when she went to work as usual,she was driven by a motorcyclist who ,as passants</td></tr><tr><td>Ours:</td><td>described,went on foot in a kind of “brutal anger” The next day,when she went to work as usual,she was crossed by a motorcyclist who,was described by passers-by,in a sort of“brutal rage ”on the road </td></tr><tr><td>Reference:</td><td>Chinese leaders presented the Sundayruling asa democratic breakthrough because it gives Hong Kongers a directvote,but the decision also makes clear that Chinese leaders would retain a firm hold on the process through a nominating committee tightly controlled by Beijing. The Chinese leadership presented Sunday’s decision as a democratic breakthrough,because Hong</td></tr><tr><td>GNMT: Ours:</td><td>Kong&#x27;scitizens have a direct right to vote,butthe decision also makes itclear that the Chinese leadership is firmly in control of the process through a UN-controlled nomination committee The Chinese leadership presented Sunday’s decision as a democratic breakthrough because it gives</td></tr><tr><td></td><td>the citizens of Hong Kong a direct right to vote,but the decision also makes it clear that the Chinese leadership keeps the process firmly in the hands of a government-controlled Nomination Commitee .</td></tr></table>
173
+
174
+ Table 4: ROUGE scores on Gigaword.
175
+
176
+ <table><tr><td>Systems</td><td>RG-1</td><td>RG-2</td><td>RG-L</td></tr><tr><td>Seq2Seq</td><td>33.4</td><td>15.7</td><td>32.4</td></tr><tr><td>Seq2Seq+Lseq</td><td>35.8</td><td>17.5</td><td>33.7</td></tr><tr><td>Seq2Seq+Lseq+Lcopy</td><td>36.2</td><td>18.1</td><td>34.0</td></tr></table>
177
+
178
+ Table 5: ROUGE scores on DUC2004.
179
+
180
+ <table><tr><td>Systems</td><td>RG-1</td><td>RG-2</td><td>RG-L</td></tr><tr><td>Seq2Seq</td><td>28.0</td><td>9.4</td><td>24.8</td></tr><tr><td>Seq2Seq+Lseq</td><td>29.5</td><td>9.8</td><td>25.5</td></tr><tr><td>Seq2Seq+Lseq+Lcopy</td><td>30.1</td><td>10.1</td><td>26.0</td></tr></table>
181
+
182
+ GNMT translations, on the other hand, ignores or misinterprets some of the key terms. More examples are provided in Appendix E.
183
+
184
+ We also test the robustness of our method wrt the hyper-parameter $\gamma$ . Results are summarized in Appendix C. Our OT-augmented model is robust to the choice of $\gamma$ . The test BLEU scores are consistently higher than the baseline for $\gamma \in ( 0 , 1 ]$ .
185
+
186
+ # 5.2 ABSTRACTIVE TEXT SUMMARIZATION
187
+
188
+ We consider two datasets for abstractive text summarization. The first one is the Gigaword corpus (Graff et al., 2003), which has around $3 . 8 { \bf M }$ training samples, 190K validation samples, and 1951 test samples. The input pairs consist of the first sentence and the headline of an article. We also evaluate our model on the DUC-2004 test set (Over et al., 2007), which consists of 500 news articles. Our implementation of the Seq2Seq model adopts a simple architecture, which consists of a bidirectional GRU encoder and a GRU decoder with attention mechanism (Bahdanau et al., 2015)3.
189
+
190
+ Results are summarized in Tables 4 and 5. Our OT-regularized model outperforms respective baselines. The state-of-the-art ROUGE result for the Gigawords dataset is 36.92 reported by Wang et al. (2018a). However, much more complex architectures are used to achieve that score. We use a relatively simple Seq2Seq model in our experiments to demonstrate the versatility of the proposed OT method. Applying it for (i) more complicated models and $( i i )$ more recent datasets such as CNN/DailyMail (See et al., 2017) will be interesting future work.
191
+
192
+ Summarization examples are provided in Appendix D. Similar to the machine translation task, our proposed method captures the key semantic information in both the source and reference sentences.
193
+
194
+ # 5.3 IMAGE CAPTIONING
195
+
196
+ We also consider an image captioning task using the COCO dataset (Lin et al., 2014), which contains 123,287 images in total and each image is annotated with at least 5 captions. Following Karpathy’s split (Karpathy & Fei-Fei, 2015), 113,287 images are used for training and 5,000 images are used for validation and testing. We follow the implementation of the Show, Attend (Xu et al., 2015)4, and use Resnet-152 (He et al., 2016), image tagging (Gan et al., 2017), and FastRCNN (Anderson et al., 2018) as the image feature extractor (encoder), and a one-layer LSTM with 1024 units as the decoder. The word embedding dimension is set to 512. Note that in this task, the input are images instead of sequences, therefore $\mathcal { L } _ { \mathrm { c o p y } }$ cannot be applied.
197
+
198
+ Table 6: Results for image captioning on the COCO dataset.
199
+
200
+ <table><tr><td>Method</td><td>BLEU-1</td><td>BLEU-2</td><td>BLEU-3</td><td>BLEU-4</td><td>METEOR</td><td>CIDEr</td></tr><tr><td>Soft Attention (Xu et al.,2015)</td><td>70.7</td><td>49.2</td><td>34.4</td><td>24.3</td><td>23.9</td><td>-</td></tr><tr><td>Hard Attention (Xu et al., 2015)</td><td>71.8</td><td>50.4</td><td>35.7</td><td>25.0</td><td>23.0</td><td>=</td></tr><tr><td>Show &amp; Tell(Vinyals et al.,2015)</td><td>-</td><td>1</td><td>1</td><td>27.7</td><td>23.7</td><td>85.5</td></tr><tr><td>ATT-FCN(You et al.,2016)</td><td>70.9</td><td>53.7</td><td>40.2</td><td>30.4</td><td>24.3</td><td>-</td></tr><tr><td>SCN-LSTM(Gan et al., 2017)</td><td>72.8</td><td>56.6</td><td>43.3</td><td>33.0</td><td>25.7</td><td>101.2</td></tr><tr><td>Adaptive Attention (Lu et al.,2017)</td><td>74.2</td><td>58.0</td><td>43.9</td><td>33.2</td><td>26.6</td><td>108.5</td></tr><tr><td>Top-Down Attention (Anderson et al.,2018)</td><td>77.2</td><td>一</td><td>二</td><td>36.2</td><td>27.0</td><td>113.5</td></tr><tr><td>No attention,Resnet-152</td><td></td><td></td><td></td><td></td><td></td><td></td></tr><tr><td>Show&amp;Tell</td><td>70.3</td><td>53.7</td><td>39.9</td><td>29.5</td><td>23.6</td><td>87.1</td></tr><tr><td>Show &amp; Tell+Lseq (Ours)</td><td>70.9</td><td>54.2</td><td>40.4</td><td>30.1</td><td>23.9</td><td>90.0</td></tr><tr><td>No attention,Tag</td><td></td><td></td><td></td><td></td><td></td><td></td></tr><tr><td>Show&amp;Tell</td><td>72.1</td><td>55.2</td><td>41.3</td><td>30.1</td><td>24.5</td><td>93.4</td></tr><tr><td>Show&amp; Tell+Lseq(Ours)</td><td>72.3</td><td>55.4</td><td>41.5</td><td>31.0</td><td>24.6</td><td>94.7</td></tr><tr><td>Soft attention,FastRCNN</td><td></td><td></td><td></td><td></td><td></td><td></td></tr><tr><td>Show,Attend &amp; Tell</td><td>74.0</td><td>58.0</td><td>44.0</td><td>33.1</td><td>25.2</td><td>99.1</td></tr><tr><td>Show,Attend&amp;Tell+Lseq(Ours)</td><td>74.5</td><td>58.4</td><td>44.5</td><td>33.8</td><td>25.6</td><td>102.9</td></tr></table>
201
+
202
+ We report BLEU- $k$ $k$ from 1 to 4) (Papineni et al., 2002), CIDEr (Vedantam et al., 2015), and METEOR (Banerjee & Lavie, 2005) scores and the results with different settings are shown in Table 6. Consistent across-the-board improvements are observed with the introduction of the OT loss, in contrast to the RL-based methods where drastic improvements can only be observed for the optimized evaluation metric (Rennie et al., 2017). Consequently, the OT loss is a more reliable method to improve the quality of generated captions when compared with RL methods that aim to optimize and therefore potentially overfit one specific metric. Examples of generated captions are provided in Appendix F.
203
+
204
+ # 6 CONCLUSION
205
+
206
+ This work is motivated by the major deficiency in training Seq2Seq models: that the MLE training loss does not operate at sequence-level. Inspired by soft bipartite matching, we propose the usage of optimal transport as a sequence-level loss to improve Seq2Seq learning. By applying this new method to machine translation, text summarization, and image captioning, we demonstrate that our proposed model can be used to help improve the performance compared to strong baselines. We believe the proposed method is a general framework, and will be useful to other sequence generation tasks as well, such as conversational response generation (Li et al., 2017; Zhang et al., 2018c), which is left as future work.
207
+
208
+ # REFERENCES
209
+
210
+ Shun-ichi Amari. Differential-geometrical methods in statistics, volume 28. Springer Science & Business Media, 1985.
211
+
212
+ Luigi Ambrosio, Nicola Gigli, and Giuseppe Savare.´ Gradient flows: in metric spaces and in the space of probability measures. 2005.
213
+
214
+ Peter Anderson, Basura Fernando, Mark Johnson, and Stephen Gould. Spice: Semantic propositional image caption evaluation. In European Conference on Computer Vision, pp. 382–398. Springer, 2016.
215
+
216
+ Peter Anderson, Xiaodong He, Chris Buehler, Damien Teney, Mark Johnson, Stephen Gould, and Lei Zhang. Bottom-up and top-down attention for image captioning and visual question answering. In CVPR, 2018.
217
+
218
+ Martin Arjovsky, Soumith Chintala, and Leon Bottou. Wasserstein generative adversarial networks.´ In ICML, 2017.
219
+
220
+ Dzmitry Bahdanau, Kyunghyun Cho, and Yoshua Bengio. Neural machine translation by jointly learning to align and translate. In ICLR, 2015.
221
+
222
+ Dzmitry Bahdanau, Philemon Brakel, Kelvin Xu, Anirudh Goyal, Ryan Lowe, Joelle Pineau, Aaron Courville, and Yoshua Bengio. An actor-critic algorithm for sequence prediction. In ICLR, 2017.
223
+
224
+ Satanjeev Banerjee and Alon Lavie. Meteor: An automatic metric for mt evaluation with improved correlation with human judgments. In ACL Workshop, 2005.
225
+
226
+ Samy Bengio, Oriol Vinyals, Navdeep Jaitly, and Noam Shazeer. Scheduled sampling for sequence prediction with recurrent neural networks. In NIPS, 2015.
227
+
228
+ Stephen Boyd and Lieven Vandenberghe. Convex optimization. Cambridge university press, 2004.
229
+
230
+ Mauro Cettolo, Jan Niehues, Sebastian Stuker, Luisa Bentivogli, Roldano Cattoni, and Marcello ¨ Federico. The IWSLT 2015 evaluation campaign. In IWSLT 2015, International Workshop on Spoken Language Translation, 2015.
231
+
232
+ Changyou Chen, Ruiyi Zhang, Wenlin Wang, Bai Li, and Liqun Chen. A unified particleoptimization framework for scalable bayesian sampling. In UAI, 2018a.
233
+
234
+ Liqun Chen, Shuyang Dai, Chenyang Tao, Haichao Zhang, Zhe Gan, Dinghan Shen, Yizhe Zhang, Guoyin Wang, Ruiyi Zhang, and Lawrence Carin. Adversarial text generation via feature-mover’s distance. In NeurIPS, 2018b.
235
+
236
+ Kyunghyun Cho, Bart Van Merrienboer, Caglar Gulcehre, Dzmitry Bahdanau, Fethi Bougares, Hol- ¨ ger Schwenk, and Yoshua Bengio. Learning phrase representations using rnn encoder-decoder for statistical machine translation. In EMNLP, 2014.
237
+
238
+ Sumit Chopra, Michael Auli, and Alexander M Rush. Abstractive sentence summarization with attentive recurrent neural networks. In NAACL, 2016.
239
+
240
+ Katy Craig (ed.). The exponential formula for the Wasserstein metric. PhD thesis, The State University of New Jersey, 2014.
241
+
242
+ Marco Cuturi. Sinkhorn distances: Lightspeed computation of optimal transport. In NIPS, 2013.
243
+
244
+ William Fedus, Ian Goodfellow, and Andrew M Dai. MaskGAN: Better text generation via filling in the . In ICLR, 2018.
245
+
246
+ Zhe Gan, Chuang Gan, Xiaodong He, Yunchen Pu, Kenneth Tran, Jianfeng Gao, Lawrence Carin, and Li Deng. Semantic compositional networks for visual captioning. In CVPR, 2017.
247
+
248
+ Aude Genevay, Gabriel Peyre, and Marco Cuturi. Learning generative models with sinkhorn diver- ´ gences. In AISTATS, 2018.
249
+
250
+ Ian Goodfellow, Jean Pouget-Abadie, Mehdi Mirza, Bing Xu, David Warde-Farley, Sherjil Ozair, Aaron Courville, and Yoshua Bengio. Generative adversarial nets. In NIPS, 2014.
251
+
252
+ Ian Goodfellow, Yoshua Bengio, Aaron Courville, and Yoshua Bengio. Deep learning, volume 1. MIT press Cambridge, 2016.
253
+
254
+ David Graff, Junbo Kong, Ke Chen, and Kazuaki Maeda. English gigaword. Linguistic Data Consortium, Philadelphia, 2003.
255
+
256
+ Jiatao Gu, Zhengdong Lu, Hang Li, and Victor OK Li. Incorporating copying mechanism in sequence-to-sequence learning. In ACL, 2016.
257
+
258
+ Ishaan Gulrajani, Faruk Ahmed, Martin Arjovsky, Vincent Dumoulin, and Aaron C Courville. Improved training of Wasserstein GANs. In NIPS, 2017.
259
+
260
+ Jiaxian Guo, Sidi Lu, Han Cai, Weinan Zhang, Yong Yu, and Jun Wang. Long text generation via adversarial training with leaked information. In AAAI, 2018.
261
+
262
+ Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. Deep residual learning for image recognition. In CVPR, 2016.
263
+
264
+ Sepp Hochreiter and Jurgen Schmidhuber. Long short-term memory. ¨ Neural Computation, 1997.
265
+
266
+ Gao Huang, Chuan Guo, Matt J Kusner, Yu Sun, Fei Sha, and Kilian Q Weinberger. Supervised word mover’s distance. In NIPS, 2016.
267
+
268
+ Qiuyuan Huang, Zhe Gan, Asli Celikyilmaz, Dapeng Wu, Jianfeng Wang, and Xiaodong He. Hierarchically structured reinforcement learning for topically coherent visual story generation. arXiv preprint arXiv:1805.08191, 2018.
269
+
270
+ Ferenc Huszr. How (not) to train your generative model: scheduled sampling, likelihood, adversary? In arXiv:1511.05101, 2015.
271
+
272
+ Eric Jang, Shixiang Gu, and Ben Poole. Categorical reparameterization with Gumbel-softmax. In arXiv:1611.01144, 2016.
273
+
274
+ Andrej Karpathy and Li Fei-Fei. Deep visual-semantic alignments for generating image descriptions. In CVPR, 2015.
275
+
276
+ Harold W Kuhn. The Hungarian method for the assignment problem. Naval research logistics quarterly, 1955.
277
+
278
+ Matt Kusner, Yu Sun, Nicholas Kolkin, and Kilian Weinberger. From word embeddings to document distances. In ICML, 2015.
279
+
280
+ Alex Lamb, Anirudh Goyal ALIAS PARTH GOYAL, Ying Zhang, Saizheng Zhang, Aaron C Courville, and Yoshua Bengio. Professor forcing: A new algorithm for training recurrent networks. In NIPS, 2016.
281
+
282
+ Jiwei Li, Will Monroe, Tianlin Shi, Alan Ritter, and Dan Jurafsky. Adversarial learning for neural dialogue generation. In EMNLP, 2017.
283
+
284
+ W. Li and G. Montufar. Natural gradient via optimal transport. arXiv preprint arXiv:1803.07033, 2018.
285
+
286
+ Chin-Yew Lin. Rouge: A package for automatic evaluation of summaries. Text Summarization Branches Out, 2004.
287
+
288
+ Kevin Lin, Dianqi Li, Xiaodong He, Zhengyou Zhang, and Ming-Ting Sun. Adversarial ranking for language generation. In NIPS, 2017.
289
+
290
+ Tsung-Yi Lin, Michael Maire, Serge Belongie, James Hays, Pietro Perona, Deva Ramanan, Piotr Dollar, and C Lawrence Zitnick. Microsoft COCO: Common objects in context. In ´ ECCV, 2014.
291
+
292
+ Hao Liu, Yihao Feng, Yi Mao, Dengyong Zhou, Jian Peng, and Qiang Liu. Action-depedent control variates for policy optimization via stein’s identity. In ICLR, 2018.
293
+
294
+ Siqi Liu, Zhenhai Zhu, Ning Ye, Sergio Guadarrama, and Kevin Murphy. Improved image captioning via policy gradient optimization of spider. In ICCV, 2017.
295
+
296
+ Jiasen Lu, Caiming Xiong, Devi Parikh, and Richard Socher. Knowing when to look: Adaptive attention via a visual sentinel for image captioning. In CVPR, 2017.
297
+
298
+ Giulia Luise, Alessandro Rudi, Massimiliano Pontil, and Carlo Ciliberto. Differential properties of sinkhorn approximation for learning with wasserstein distance. arXiv:1805.11897, 2018.
299
+
300
+ Minh-Thang Luong, Hieu Pham, and Christopher D Manning. Effective approaches to attentionbased neural machine translation. arXiv:1508.04025, 2015a.
301
+
302
+ Thang Luong, Hieu Pham, and Christopher D Manning. Bilingual word representations with monolingual quality in mind. In Proceedings of the 1st Workshop on Vector Space Modeling for Natural Language Processing, 2015b.
303
+
304
+ Thang Luong, Eugene Brevdo, and Rui Zhao. Neural machine translation (seq2seq) tutorial, 2018. URL https://github.com/tensorflow/nmt.
305
+
306
+ Chris J Maddison, Andriy Mnih, and Yee Whye Teh. The concrete distribution: A continuous relaxation of discrete random variables. ICLR, 2017.
307
+
308
+ Paul Over, Hoa Dang, and Donna Harman. DUC in context. Information Processing & Management, 2007.
309
+
310
+ Kishore Papineni, Salim Roukos, Todd Ward, and Wei-Jing Zhu. BLEU: a method for automatic evaluation of machine translation. In ACL, 2002.
311
+
312
+ Jeffrey Pennington, Richard Socher, and Christopher Manning. Glove: Global vectors for word representation. In EMNLP, 2014.
313
+
314
+ Gabriel Peyre, Marco Cuturi, et al. Computational optimal transport. Technical report, 2017. ´
315
+
316
+ Marc’Aurelio Ranzato, Sumit Chopra, Michael Auli, and Wojciech Zaremba. Sequence level training with recurrent neural networks. In ICLR, 2016.
317
+
318
+ Steven J Rennie, Etienne Marcheret, Youssef Mroueh, Jarret Ross, and Vaibhava Goel. Self-critical sequence training for image captioning. In CVPR, 2017.
319
+
320
+ Yossi Rubner, Carlo Tomasi, and Leonidas J Guibas. The earth mover’s distance as a metric for image retrieval. IJCV, 2000.
321
+
322
+ Alexander M Rush, Sumit Chopra, and Jason Weston. A neural attention model for abstractive sentence summarization. In EMNLP, 2015.
323
+
324
+ Tim Salimans, Han Zhang, Alec Radford, and Dimitris Metaxas. Improving GANs using optimal transport. In ICLR, 2018.
325
+
326
+ Abigail See, Peter J Liu, and Christopher D Manning. Get to the point: summarization with pointergenerator networks. ACL, 2017.
327
+
328
+ Ilya Sutskever, Oriol Vinyals, and Quoc V Le. Sequence to sequence learning with neural networks. In NIPS, 2014.
329
+
330
+ Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Łukasz Kaiser, and Illia Polosukhin. Attention is all you need. In NIPS, 2017.
331
+
332
+ Ramakrishna Vedantam, C Lawrence Zitnick, and Devi Parikh. Cider: Consensus-based image description evaluation. In CVPR, 2015.
333
+
334
+ Cedric Villani. ´ Optimal Transport: Old and New. Grundlehren der mathematischen Wissenschaften. Springer, 2008.
335
+
336
+ Oriol Vinyals, Alexander Toshev, Samy Bengio, and Dumitru Erhan. Show and tell: A neural image caption generator. In CVPR, 2015.
337
+
338
+ Li Wang, Junlin Yao, Yunzhe Tao, Li Zhong, Wei Liu, and Qiang Du. A reinforced topic-aware convolutional sequence-to-sequence model for abstractive text summarization. IJCAI, 2018a.
339
+
340
+ Xin Wang, Wenhu Chen, Yuan-Fang Wang, and William Yang Wang. No metrics are perfect: Adversarial reward learning for visual storytelling. In ACL, 2018b.
341
+
342
+ Sam Wiseman and Alexander M Rush. Sequence-to-sequence learning as beam-search optimization. In EMNLP, 2016.
343
+
344
+ Yonghui Wu, Mike Schuster, Zhifeng Chen, Quoc V Le, Mohammad Norouzi, Wolfgang Macherey, Maxim Krikun, Yuan Cao, Qin Gao, Klaus Macherey, et al. Google’s neural machine translation system: Bridging the gap between human and machine translation. arXiv:1609.08144, 2016.
345
+
346
+ Yujia Xie, Xiangfeng Wang, Ruijia Wang, and Hongyuan Zha. A fast proximal point method for Wasserstein distance. In arXiv:1802.04307, 2018.
347
+
348
+ Hongteng Xu, Wenlin Wang, Wei Liu, and Lawrence Carin. Distilled Wasserstein learning for word embedding and topic modeling. In NeurIPS, 2018.
349
+
350
+ Kelvin Xu, Jimmy Ba, Ryan Kiros, Kyunghyun Cho, Aaron C Courville, Ruslan Salakhutdinov, Richard S Zemel, and Yoshua Bengio. Show, attend and tell: Neural image caption generation with visual attention. In ICML, 2015.
351
+
352
+ Quanzeng You, Hailin Jin, Zhaowen Wang, Chen Fang, and Jiebo Luo. Image captioning with semantic attention. In CVPR, 2016.
353
+
354
+ Lantao Yu, Weinan Zhang, Jun Wang, and Yong Yu. SeqGAN: Sequence generative adversarial nets with policy gradient. In AAAI, 2017.
355
+
356
+ Ruiyi Zhang, Changyou Chen, Zhe Gan, Wenlin Wang, Liqun Chen, Dinghan Shen, Guoyin Wang, and Lawrence Carin. Sequence generation with guider network. arXiv preprint arXiv:1811.00696, 2018a.
357
+
358
+ Ruiyi Zhang, Changyou Chen, Chunyuan Li, and Lawrence Carin. Policy optimization as wasserstein gradient flows. In ICML, 2018b.
359
+
360
+ Yizhe Zhang, Zhe Gan, Kai Fan, Zhi Chen, Ricardo Henao, Dinghan Shen, and Lawrence Carin. Adversarial feature matching for text generation. In ICML, 2017.
361
+
362
+ Yizhe Zhang, Michel Galley, Jianfeng Gao, Zhe Gan, Xiujun Li, Chris Brockett, and Bill Dolan. Generating informative and diverse conversational responses via adversarial information maximization. In NeurIPS, 2018c.
363
+
364
+ # APPENDIX
365
+
366
+ # A TRAINING DETAILS FOR NMT TASK
367
+
368
+ The following training details are basically the same as the intructions from the Tensorflow/nmt github repository:
369
+
370
+ EN-VI 2-layer LSTMs of 512 units with bidirectional encoder (i.e., 1 bidirectional layer for the encoder), embedding dim is 512. LuongAttention (Luong et al., 2015a) (scale $\fallingdotseq$ True) is used together with dropout keep-prob $_ { = 0 . 8 }$ . All parameters are uniformly initialized. We use SGD with learning rate 1.0 as follows: train for 12K steps (around 12 epochs); after 8K steps, we start halving learning rate every 1K step.
371
+
372
+ DE-EN The training hyperparameters are similar to the EN-VI experiments except for the following details. The data is split into subword units using BPE (32K operations). We train 4- layer LSTMs of 1024 units with bidirectional encoder (i.e., 2 bidirectional layers for the encoder), embedding dimension is 1024. We train for 350K steps (around 10 epochs); after 170K steps, we start halving learning rate every 17K step.
373
+
374
+ # B END-TO-END NEURAL MACHINE TRANSLATION
375
+
376
+ Table 7: BLEU scores on VI-EN and EN-VI.
377
+
378
+ <table><tr><td>Systems</td><td>NT2012</td><td>NT2013</td></tr><tr><td>VI-EN: GNMT</td><td>20.7</td><td>23.8</td></tr><tr><td>VI-EN: GNMT+OT(Ours)</td><td>21.9</td><td>25.5</td></tr><tr><td>EN-VI: GNMT</td><td>23.0</td><td>25.4</td></tr><tr><td>EN-VI: GNMT+OT(Ours)</td><td>24.1</td><td>26.5</td></tr></table>
379
+
380
+ Table 8: BLEU scores on DE-EN and EN-DE.
381
+
382
+ <table><tr><td>Systems</td><td>NT2013</td><td>NT2015</td></tr><tr><td>DE-EN: GNMT</td><td>28.5</td><td>29.0</td></tr><tr><td>DE-EN: GNMT+OT(Ours)</td><td>28.8</td><td>29.5</td></tr><tr><td>EN-DE: GNMT</td><td>23.7</td><td>25.3</td></tr><tr><td>EN-DE: GNMT+OT(Ours)</td><td>24.1</td><td>26.2</td></tr></table>
383
+
384
+ Table 7 and 8 show the quantitative comparison for training from random initialization.
385
+
386
+ # C BLEU SCORE FOR DIFFERENT HYPER-PARAMETERS
387
+
388
+ We tested different $\gamma$ for the OT loss term and summarized the results in Figure 3. $\gamma = 0 . 1$ gave the best performance for the EN-VI experiment. The results are robust wrt the choice of $\gamma \leq 1 . 0$ .
389
+
390
+ ![](images/6f59e61eb36d7a5595d0819fb977e241094e4153c50ba45e675a71fe6a280ec0.jpg)
391
+ Figure 3: the performance of EN-VI translation by different $\gamma$
392
+
393
+ # D SUMMARIZATION EXAMPLES
394
+
395
+ Table 9: Examples on Text Summarization.
396
+ Examples
397
+
398
+ <table><tr><td>Source:</td><td> japan &#x27;s nec corp.and UNK computer corp. of the united states said wednesday they had agreed to join</td></tr><tr><td>Reference:</td><td>forces in supercomputer sales. nec UNK in computer sales tie-up</td></tr><tr><td>Baseline:</td><td>nec UNK computer corp.</td></tr><tr><td>Ours:</td><td>nec UNK computer corp sales supercomputer.</td></tr><tr><td>Source:</td><td>five east timorese youths who scaled the french embassy&#x27;sfence here thursday,left the embassy on their</td></tr><tr><td>Reference:</td><td>way to portugal friday.</td></tr><tr><td rowspan="3">Baseline: Ours:</td><td>UNK latest east timorese asylum seekers leave for portugal</td></tr><tr><td>five east timorese youths leave embassy</td></tr><tr><td>five east timorese seekers leave embassy for portugal theus space shuttle atlantis separated from the orbiting russanmir space station earlysaturday,after threedaysof</td></tr><tr><td rowspan="2">Source: Reference: Baseline:</td><td>test runs for life in a future space facility,nasa announced .</td></tr><tr><td>atlantis mir part ways after three-day space collaboration by emmanuel UNK</td></tr><tr><td rowspan="2">Ours: Source:</td><td>atlantis separate from mir atlantis separate from mir space by UNK</td></tr><tr><td>australia &#x27;s newscorp announced monday it was joining brazil&#x27;s globo,mexico&#x27;s grupo televisa and the us tele-communications inc.in a venture to broadcast ### channels via satelite to latin america.</td></tr><tr><td rowspan="2">Reference:</td><td></td></tr><tr><td>news corp globo televisa and tele-communications in satellite venture australia &#x27;s news corp joins brazil</td></tr><tr><td rowspan="2">Baseline: Ours:</td><td></td></tr><tr><td>australia &#x27;s news corp joins brazil in satellite venture</td></tr></table>
399
+
400
+ Examples for abstract summarization are provided in Table 9.
401
+
402
+ # E NEURAL MACHINE TRANSLATION EXAMPLES
403
+
404
+ In Table 10, we show more examples for comparison. From these examples, sentences generated from our model are more faithful to the reference sentences.
405
+
406
+ # F IMAGE CAPTION EXAMPLES
407
+
408
+ Table 4 shows the comparison of our model with other baselines.
409
+
410
+ G ENCODING MODEL BELIEF WITH SOFTMAX AND GUMBEL-SOFTMAX
411
+
412
+ ![](images/a4bc01a9fcefb66fea60d894bfac1b9daf271dd26b7d7d75bea7ff5475d6ec2d.jpg)
413
+ Figure 4: Examples of image captioning on MS COCO.
414
+
415
+ To find out the best differentiable sequence generating mechanism, we also experimented with Softmax and Gumbel-softmax (a.k.a. concrete distribution). Detailed results are summarized in Table 11. We can see Softmax and Gumbelsoftmax based OT model provide less significant gains in terms of BLEU score compared with the baseline MLE model. In some situation, the performance even degenerate. We hypothesized that this is because Softmax encodes more ambiguity and Gumbel-softmax has a larger variance due to the extra random variable involved. These in turn hurts the learning. More involved variance reduction scheme might offset such negative impacts for Gumbel-softmax, which is left as our future work.
416
+
417
+ Table 11: BLEU scores on VI-EN and EN-VI using different choices of model’s belief.
418
+
419
+ <table><tr><td>Systems</td><td>NT2012</td><td>NT2013</td></tr><tr><td>VI-EN: GNMT</td><td>20.7</td><td>23.8</td></tr><tr><td>VI-EN: :GNMT+OT(GS)</td><td>20.9</td><td>24.5</td></tr><tr><td>VI-EN: GNMT+OT(softmax)</td><td>21.8</td><td>24.3</td></tr><tr><td>VI-EN: GNMT+OT(ours)</td><td>21.9</td><td>25.5</td></tr><tr><td>EN-VI: GNMT</td><td>23.0</td><td>25.4</td></tr><tr><td>EN-VI: GNMT+OT (GS)</td><td>23.3</td><td>25.7</td></tr><tr><td>EN-VI: GNMT+OT (softmax)</td><td>23.5</td><td>26.0</td></tr><tr><td>EN-VI: GNMT+OT(ours)</td><td>24.1</td><td>26.5</td></tr></table>
420
+
421
+ # H OT IMPROVES BOTH MODEL AND WORD EMBEDDING MATRIX
422
+
423
+ To identify the source of performance gains, we designed a toy sequence-to-sequence experiment to show that OT help to refine the language model and word embedding matrix. We use the English corpus from WMT dataset (from our machine translation task) and trained an auto-encoder (Seq2Seq model) on this dataset. We evaluated the reconstruction quality with the BLEU score. In Case 1, we stop the OT gradient from flowing back to the
424
+
425
+ Table 12: Comparison experiment.
426
+
427
+ <table><tr><td>Metric</td><td>Baseline</td><td>Case 1</td><td>Case 2</td></tr><tr><td>BLEU-2</td><td>71.87</td><td>73.60</td><td>75.12</td></tr><tr><td>BLEU-3</td><td>61.18</td><td>63.07</td><td>64.82</td></tr><tr><td>BLEU-4</td><td>56.59</td><td>58.48</td><td>60.27</td></tr><tr><td>BLEU-5</td><td>53.73</td><td>55.69</td><td>57.50</td></tr></table>
428
+
429
+ sequence model ( only affecting the word embedding matrix); while in Case 2, the gradient from OT can affect the entire model. Detailed results are shown in Table G. We can see that Case 1 is better than the baseline model, which means OT helps to refine the word embedding matrix. Case 2 achieves the highest BLEU, which implies OT also helps to improve the language model.
430
+
431
+ Table 10: More DE-EN translation examples.
432
+
433
+ <table><tr><td>Examples</td><td></td></tr><tr><td>Reference:</td><td>When former First Lady Eleanor Roosevelt chaired the International Commission on Human Rights,which drafted the Universal Declaration of Human Rights that would in 1948 be adopted bythe United Nations as a global covenant,Roosevelt and the drafters included a guarantee that &quot;everyone has the right to form and to</td></tr><tr><td>Ours:</td><td>join trade unions for the protection of his interests.&quot; When formerFirst Lady Eleanor Roosevelt held the presidency of the International Commission on Human Rights,drafted bythe Universal Declaration of Human Rights,adopted in1948by the United Nations as a</td></tr><tr><td>GNMT:</td><td>global agreement,Roosevelt and the other authors gave a guarantee that”everyone has the right to form or join trade unions to protect their interests .” When former FirstLady Eleanor Roosevelt presided over the International Human Rights Commitee ,which</td></tr><tr><td></td><td>drew up the Universal Declarationof Human Rights,as adopted by the United Nations in 1948as a global agreement ,Roosevelt and the other authors added a guarantee that ”everyone has the right to form trade unions to protect their interests or to accede to them ”.</td></tr><tr><td>Reference:</td><td>India&#x27;s new prime minister,Narendra Modi,ismeeting his Japanese counterpart,Shinzo Abe,in Tokyo to discuss economic and security ties,on his first major foreign visit since winning May&#x27;s election.</td></tr><tr><td>Ours:</td><td>India s new Prime Minister Narendra Modi meets his Japanese counterpart,Shinzo Abe,in Tokyoat his first major foreign visit since his election in May in order to discuss economic and security relations</td></tr><tr><td>GNMT:</td><td>Indias new prime minister,Narendra Modi,is meeting his Japanese counterpart,Shinzo Abe,in Tokyo at</td></tr><tr><td></td><td>his first important visit abroad in May to discuss economic and security relations The police used tear gas.</td></tr><tr><td>Reference: Ours:</td><td>The police used tear gas .</td></tr><tr><td>GNMT:</td><td>The police put in tear gas.</td></tr><tr><td>Reference:</td><td>There were three people killed.</td></tr><tr><td>Ours:</td><td>Three people were killed .</td></tr><tr><td>GNMT:</td><td>Three people had been killed</td></tr><tr><td>Reference:</td><td>The next day,turning up for work as usual,she was knocked down by a motorcyclist who had mounted the pavement in what passers-by described as a &quot;vicious rage.&quot;</td></tr><tr><td>Ours:</td><td>The next day,when she went to work as usual,she was crossed by a motorcyclist who ,as described by</td></tr><tr><td>GNMT:</td><td>passers-by,was in a sort of”brutal rage ”on the road . The next day,when she went to work as usual,she was driven by a motorcyclist who,as passants described,</td></tr><tr><td>Reference:</td><td>went on foot in a kind of ”brutal anger” Double-check your gear.</td></tr><tr><td>Ours:</td><td>Check your equipment twice .</td></tr><tr><td>GNMT:</td><td>Control your equipment twice . Chinese leaders presented the Sunday ruling as a democratic breakthrough because it gives Hong Kongers a</td></tr><tr><td>Reference:</td><td>direct vote,but the decision also makes clear that Chinese leaders would retain a firm hold on the process</td></tr><tr><td>Ours:</td><td>through a nominating committee tightly controlled by Beijing. The Chinese leadership presented Sunday s decision as a democratic breakthrough because it gives the citizens</td></tr><tr><td></td><td>of Hong Konga directright to vote,but the decision also makes it clearthat the Chinese leadership keeps the process firmly in the hands of a government-controlled Nomination Commitee .</td></tr><tr><td>GNMT:</td><td>The Chinese leadership presented Sunday s decision as a democratic breakthrough ,because Hong Kongs citizens havea directright to vote,butthe decision also makes itclear thatthe Chinese leadership is firmly in control of the process through a UN-controlled nomination committee .</td></tr><tr><td>Reference:</td><td>Her mother arrived at Mount Sinai Hospital Thursday after an emergency callthat she was in cardiac arrest at an Upper East Side clinic,Yorkville Endoscopy,sources said.</td></tr><tr><td>Ours:</td><td>According to sources,her mother was sent to Mount Sinai on Thursday after an emergency due to heart failure in a clinic at the Upper East Side,Yorkville Endoscopy .</td></tr><tr><td>GNMT:</td><td>According to sources,her mother was sent to Mount Sinai hospital on Thursday after an emergency due to heart closure in a clinic at the Upper East Side,Yorkville Endoscopy.</td></tr><tr><td>Reference:</td><td>Ukrainian soldiers had to withdraw from their positions in Ilovaysk after two columns of Russian armor and 1,000 troops last week moved into the Donetsk region to bolsterthe beleaguered separatists,Col.Andriy Ly-</td></tr><tr><td>Ours:</td><td>senko,spokesman for the Ukrainian National Security and Defense Council, told reporters in Kievon Saturday. Ukrainian soldiers hadto withdraw from their positions in lowajsk after two Russan tanks and1,0oo soldiers enteredthe Donetsk region last week to support the belated separatists,said Colonel Andrij Lysenko,Speaker</td></tr><tr><td>GNMT:</td><td>of the Ukrainian National Security and Defence Council Reporters on Saturday in Kiev. Ukrainian soldiers had to withdraw from their positions in Ilowajsk after two Russian tanksand 1,Oo0 sol-</td></tr><tr><td></td><td>diers invaded the Donetsk region last week to support the beloved separatists,said Colonel Andriy Lysenko, Ukrainian National Security and Defence Council spokesman on Saturday in Kiev . Mountain Rescue doctor,Professr Volker Lischke,who was there with his team to provide safety,and who</td></tr><tr><td>Reference:</td><td>was equipped with a four-wheel Bullyand Quad,said: &quot;I know him from Frankfurt - he trains fora specialist</td></tr><tr><td></td><td>sleigh trail - it&#x27;s just that he pulls the sleigh himself.”The man is,therefore,ina sense his own sleigh dog. Bergwacht doctor Professor Volker Lischke,who,with his team,endowed with Allrad-Bullyand Quad for</td></tr><tr><td>Ours:</td><td></td></tr><tr><td></td><td></td></tr><tr><td></td><td></td></tr><tr><td></td><td></td></tr><tr><td></td><td>safety,said :”The kenn ”I from Frankfurt,trained fora special sleigh trail,just that he trains the sleigh</td></tr><tr><td></td><td></td></tr><tr><td></td><td></td></tr><tr><td></td><td></td></tr><tr><td></td><td></td></tr><tr><td></td><td></td></tr><tr><td></td><td></td></tr><tr><td></td><td></td></tr><tr><td></td><td></td></tr><tr><td></td><td>himself”,so the man is,in a sense,his own sled dog.</td></tr><tr><td></td><td></td></tr><tr><td></td><td></td></tr><tr><td></td><td></td></tr><tr><td></td><td></td></tr><tr><td>GNMT:</td><td>Bergwacht physician Professor Volker Lischke,who with his team,equipped with Allrad-Bully and Quad ,for</td></tr><tr><td></td><td></td></tr><tr><td></td><td></td></tr><tr><td></td><td></td></tr><tr><td></td><td>safety,said :”Den kenn”ichaus Frankfurt,which trained foraspecial Schlitentrail,only to stop the sleigh</td></tr></table>
parse/train/S1xtAjR5tX/S1xtAjR5tX_content_list.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/S1xtAjR5tX/S1xtAjR5tX_middle.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/S1xtAjR5tX/S1xtAjR5tX_model.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/af_hng9tuNj/af_hng9tuNj.md ADDED
@@ -0,0 +1,322 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # GEOMOL: Torsional Geometric Generation of Molecular 3D Conformer Ensembles
2
+
3
+ Octavian-Eugen Ganea ⇤, ‡
4
+
5
+ Lagnajit Pattanaik \*, †
6
+
7
+ Connor W. Coley Regina Barzilay ‡ Klavs F. Jensen †
8
+
9
+ William H. Green †
10
+
11
+ Tommi S. Jaakkola ‡
12
+
13
+ # Abstract
14
+
15
+ Prediction of a molecule’s 3D conformer ensemble from the molecular graph holds a key role in areas of cheminformatics and drug discovery. Existing generative models have several drawbacks including lack of modeling important molecular geometry elements (e.g., torsion angles), separate optimization stages prone to error accumulation, and the need for structure fine-tuning based on approximate classical force-fields or computationally expensive methods. We propose GEOMOL — an end-to-end, non-autoregressive, and SE(3)-invariant machine learning approach to generate distributions of low-energy molecular 3D conformers. Leveraging the power of message passing neural networks (MPNNs) to capture local and global graph information, we predict local atomic 3D structures and torsion angles, avoiding unnecessary over-parameterization of the geometric degrees of freedom (e.g., one angle per non-terminal bond). Such local predictions suffice both for both the training loss computation and for the full deterministic conformer assembly (at test time). We devise a non-adversarial optimal transport based loss function to promote diverse conformer generation. GEOMOL predominantly outperforms popular open-source, commercial, or state-of-the-art machine learning (ML) models, while achieving significant speed-ups. We expect such differentiable 3D structure generators to significantly impact molecular modeling and related applications. 4
16
+
17
+ # 1 Overview
18
+
19
+ Problem & importance. We tackle the problem of molecular conformer generation (MCG), i.e., predicting the ensemble of low-energy 3D conformations of a small molecule solely based on the molecular graph (fig. 1). A single conformation is represented by the list of 3D coordinates for each atom in the respective molecule. In this work, we assume that the low-energy states are implicitly defined by the given dataset, i.e., our training data consist of molecular graphs and corresponding sets of energetically favorable 3D conformations. Low-energy structures are the most stable configurations and, thus, expected to be observed most often experimentally.
20
+
21
+ ![](images/70aec0ad4d34f607aed941f2a3c564b7bede2249f30521392b428f7de22dd555.jpg)
22
+ Figure 1: We generate a representative set of low-energy 3D conformers from the input molecular graph. This example molecule has both rigid (rings) and flexible parts. Conformers are shown aligned and juxtaposed.
23
+
24
+ Dealing with molecules in their natural 3D structure is of great importance in areas such as cheminformatics or computational drug discovery because conformations determine biological, chemical, and physical properties [Guimaraes et al., 2012, Schütt et al., 2018, Klicpera et al., 2019, Axelrod and Gomez-Bombarelli, 2020b, Schütt et al., 2021, Liu et al., 2021] such as charge distribution, potential energy, docking poses [McGann, 2011], shape similarity [Kumar and Zhang, 2018], pharmacophore searching [Schwab, $\overline { { 2 0 1 0 } }$ , or descriptors for 3/4D QSAR [Verma et al., 2010]. For instance, in drug design it is crucial to understand how a molecule binds to a specific target protein; this process heavily depends on the 3D structures of the two components, both in terms of geometric (shape matching) and chemical (hydrophobic/hydrophilic) interactions [Gainza et al., 2020, Sverrisson et al., 2020].
25
+
26
+ Motivation & challenges of existing methods. The main challenge in MCG comes from the enormous size of the 3D structure space consisting of bond lengths, bond angles, and torsion angles. It is known that the molecular graph imposes specific constraints on possible 3D conformations, e.g., bond length ranges depend on the respective bond types, while tetrahedral centers dictate local spatial arrangement. However, the space of possible conformations grows exponentially with the graph size and number of rotatable bonds, thus hindering exhaustive brute force exploration even for relatively small molecules. Additionally, the number of plausibly-stable low-energy states is unknown a priori and can vary between one and several thousand conformations for a single molecule [Chan et al., $\boxed { 2 0 2 1 }$ . Nevertheless, various facets of the curse of dimensionality have been favorably tackled by ML models in different contexts, and our goal is to build on the recent ML efforts for MCG [Mansimov et al., 2019, Simm and Hernandez-Lobato, 2020, Lemm et al., 2021, Xu et al., 2021]
27
+
28
+ Molecular conformations can be determined experimentally, but existing techniques are very expensive. As a consequence, predictive computational models have been developed over the past few decades, traditionally being categorized as either stochastic or systematic (rule-based) methods $\lVert \mathbf { H a w k i n s } \rVert \mathbf { 2 0 1 7 } \rVert$ . Stochastic approaches have traditionally been based on molecular dynamics (MD) or Markov chain Monte Carlo (MCMC) techniques, potentially combined with genetic algorithms (GAs). They can do extensive explorations of the energy landscape and accurately sample equilibrium structures, but quickly become prohibitively slow for larger molecules [Shim and MacKerell Jr, 2011, Ballard et al., 2015, De Vivo et al., 2016, Hawkins, 2017], e.g., they require several CPU minutes for a single drug-like molecule. Moreover, stochastic methods have difficulties sampling diverse and representative conformers, prioritizing quantity over quality. On the other hand, rule-based systematic methods achieve state-of-the-art in commercial software [Friedrich et al., $\mathbb { Z 0 1 7 }$ with OMEGA [Hawkins et al., 2010, Hawkins and Nicholls, 2012] being a popular example. They usually process a single drug-like molecule under a second. They address the aforementioned challenges of stochastic methods by relying on carefully curated torsion templates (torsion rules), rule-based generators, and knowledge bases of rigid 3D fragments, which are assembled together and combined with subsequent stability score ranking. However, torsion angles are mostly varied independently (based on their fragments), without explicitly capturing their global interactions, which results in difficulties for larger and more flexible molecules. Furthermore, the curated fragments and rules are inadequate for more challenging inputs (e.g., transition states or open-shell molecules).
29
+
30
+ Both types of methods can be combined with Distance Geometry (DG) techniques to generate the initial 3D conformation. First, the 3D atom distance matrix is generated based on a set of distance constraints or from a specialized model. Subsequently, the corresponding 3D atom coordinates are learned to approximately match these predicted distances [Havel et al., 1983b,a, Crippen et al., 1988, Havel, 1998, Lagorce et al., 2009, Riniker and Landrum, 2015]. Indeed, modern stochastic algorithms are entirely based on DG methods [Riniker and Landrum, 2015]. The inductive bias of rotational and translational invariance is guaranteed for DG, thus being appealing for ML models [Simm and Hernandez-Lobato, 2020, Xu et al., 2021, Pattanaik et al., 2020b]. However, several drawbacks weaken this important direction: i) the distance matrix is overparameterized compared to the actual number of degrees of freedom, ii) it is difficult to enforce 3D Euclidean distance constraints as well as geometric graph constraints (e.g., on torsion angles or rings [Riniker and Landrum, $\boxed { 2 0 1 5 } ] )$ ; iii) important aspects of molecular geometry are not explicitly modeled, e.g., torsion angles of rotatable bonds or tetrahedral centers; iv) expensive force-field energy fine-tuning of the generated conformers is vital for a reasonable quality [Xu et al., 2021, Simm and Hernandez-Lobato, $\check { 2 0 } 2 0 \|$ ; iv) the resulting multi-stage pipeline is prone to error accumulation as opposed to an end-to-end model.
31
+
32
+ Previous methods often rely on a force field (FF) energy function minimization to fine-tune the conformers. These are hand-designed energy models which use parameters estimated from experiment and/or computed from quantum mechanics (e.g., Universal Force Field [Rappé et al., 1992], Merck Molecular Force Field [Halgren, 1996]). However, FFs are crude approximations of the true molecular potential energy surface [Kanal et al., 2018], limited in the interactions they can capture in biomolecules due to their strong assumptions [Barman et al., 2015]. In addition, FF energy optimization is relatively slow and increases error accumulation in a multi-pipeline method.
33
+
34
+ Relation to protein folding. There has been impressive recent progress on modeling protein folding dynamics [Ingraham et al., 2018, AlQuraishi, 2019, Noé et al., 2019, Senior et al., 2020], where crystallized 3D structures are predicted solely from the amino-acid sequence using ML methods. However, molecules pose unique challenges, being highly branched graphs containing cycles, different types of bonds, and chirality information. This makes protein folding approaches not readily transferable to general molecular data.
35
+
36
+ Our key contributions & model in a nutshell. In this work, we investigate the question:
37
+
38
+ Can we design a fast and generalizable deep learning model to predict high-quality, representative, and diverse 3D conformational ensembles from input molecular graphs?
39
+
40
+ To tackle this question, we propose GEOMOL (shown in fig. 2), exhibiting the following merits:
41
+
42
+ • It is end-to-end trainable, non-autoregressive, and does not rely on DG techniques (thus avoiding aforementioned drawbacks). More precisely, it outputs a minimal set of geometric quantities (i.e., angles and distances) sufficient for full deterministic reconstruction of the 3D conformer.
43
+
44
+ • It models conformers in an SE(3)-invariant (translation/rotation) manner by design. This desirable inductive bias was previously either achieved using multi-step DG methods [Simm and HernandezLobato, 2020] or not captured at all [Mansimov et al., 2019].
45
+
46
+ • It explicitly models and predicts essential molecular geometry elements: torsion angles and local 3D structures (bond distances and bond angles adjacent to each atom). Together with the input molecular graph, these are used for k-hop distance computation at train time and full deterministic conformation assembly at test time. Crucially, we do not over-parameterize these predictions, i.e., a single torsion angle is computed per each non-terminal bond, irrespective of the number and permutation of the neighboring atoms at each end-point of the respective bond.
47
+
48
+ • The above geometric elements (torsion angles, local structures) are SE(3)-invariant (by definition or usage) and we jointly predict them using MPNNs $\lVert \mathbf { G i l m e r \ e t \ a l . } \rVert \mathbf { 2 0 1 7 } \rVert$ and self-attention networks. Thus, unlike [Mansimov et al., $\boxed { 2 0 1 9 }$ , we are not affected by MPNNs’ pitfalls that obstruct direct predictions of 3D atom coordinates from node embeddings, e.g., symmetric or locally isomorphic nodes would always have identical MPNN embeddings [Xu et al., 2019, Garg et al., 2020] and, as a consequence, would be inappropriately assigned identical 3D coordinates.
49
+
50
+ • To promote diverse conformer ensembles with good coverage, we devise a tailored generative loss that does not use slow or difficult-to-optimize adversarial training techniques. Using optimal transport, GEOMOL finds the best matching between generated and ground truth conformers based on their pairwise log-likelihood loss, requiring only minimization.
51
+
52
+ • It explicitly and deterministically distinguishes reflected structures (enantiomers) by solving tetrahedral stereocenters using oriented volumes and local chiral descriptors, bypassing the need for iterative optimization usually done in DG approaches.
53
+
54
+ • Empirically, we conduct experiments on two benchmarks: GEOM-QM9 (smaller molecules relevant to gas-phase chemistry) and GEOM-DRUGS (drug-like molecules) [Axelrod and GomezBombarelli, 2020a]. Our method often outperforms previous ML and two popular open-source or commercial methods in different metrics. Moreover, we show competitive quality even without the frequently-used computationally-demanding fine-tuning FF strategies.
55
+
56
+ • GEOMOL processes drug-like molecules in seconds or less, being orders of magnitude faster than popular baselines (e.g., ETKDG/RDKit[Riniker and Landrum, 2015]), without sacrificing quality.
57
+
58
+ ![](images/31e0aa356d96eace50fef04723567f255d16587a60f11e1ed4a51635aa0ce93b.jpg)
59
+ Figure 2: Overview of the GEOMOL model, which is SE(3)-invariant by design. Given a molecular graph, we first compute MPNNs atom embeddings. Next, we predict the local 3D structures (LS) of each non-terminal atom in a permutation invariant way, explicitly solving chirality. Third, for each bond connecting non-terminal vertices, we assemble the two LS by predicting a single torsion angle, avoiding overparameterization. Finally, the full conformer is assembled (only) at test time.
60
+
61
+ # 2 Method
62
+
63
+ Problem setup $\pmb { \& }$ notations. Our input is any molecular graph $G = ( V , E )$ with node and edge features, $\mathbf { x } _ { v } \in \mathbb { R } ^ { f } , \forall v \in V$ and $\mathbf { e } _ { u , v } \in \mathbb { R } ^ { f ^ { \prime } } , \forall ( u , v ) \in E$ representing atom types, formal charges, bond types, etc. For each molecular graph $\mathbf { G }$ , we have a variable-size set of low-energy ground truth 3D conformers $\{ \mathcal { C } _ { l } ^ { * } \} _ { l }$ that we predict with a model $\{ { \mathcal { C } } _ { k } \} _ { k } \ { \overset { \underset { \mathrm { d e f } } { } } { = } } \ \zeta ( G )$ . A conformer is a map $\mathcal { C } : V \to \mathbb { R } ^ { 3 }$ from graph nodes to 3D coordinates, but a simplified notation is $\mathbf { c } _ { v } \in \mathbb { R } ^ { 3 }$ for $v \in V$ . We use additional notations: $d ( X , Y ) = \| \mathbf { c } _ { X } - \mathbf { c } _ { Y } \|$ is the 3D distance between X and Y; $\angle X Y Z$ is the counter-clockwise (CCW) angle $\angle \mathbf { c } _ { X } \mathbf { c } _ { Y } \mathbf { c } _ { Z }$ ; $\angle ( X Y Z , X Y T )$ is the CCW dihedral angle of the 2D planes $\mathbf { c } _ { X } \mathbf { c } _ { Y } \mathbf { c } _ { Z }$ and $\mathbf { c } _ { X } \mathbf { c } _ { Y } \mathbf { c } _ { T }$ (formula is in appendix $\checkmark$ . We use the corresponding $\mathbf { c } _ { v } ^ { * } , d ^ { * } ( X , Y ) , \angle ^ { * } X Y Z , \angle ^ { * } ( X Y Z , X Y T )$ when manipulating a ground truth conformer.
64
+
65
+ Any conformer is defined up to a SE(3) transformation, i.e., any translation or rotation applied to the set $\{ \mathbf { c } _ { v } \} _ { v \in V }$ . A classic conformer distance function that satisfies this constraint is root-mean-square deviation of atomic positions (RMSD), computed by the Kabsch alignment algorithm [Kabsch, 1976].
66
+
67
+ # 2.1 GEOMOL high-level overview
68
+
69
+ Our approach, shown in fig. $\mathbb { Z } ,$ comprises three steps. First, we predict the local 3D structure of each non-terminal atom, which we deem local structure (LS), by combining self-attention layers and MPNNs with deterministic corrections for tetrahedral centers. Bond distances and bond angles are computed from the predicted LS. Next, we assemble all neighboring pairs of LSs by predicting the torsion angles and aligning them. Importantly, since LSs are fixed, it suffices to only predict a single value for the dihedral angle of each bond. Towards this goal, we develop a canonical representation of torsion angles via a local coordinate system defined SE(3)-equivariantly w.r.t. the full structure, which allows us to predict exactly the number of degrees of freedom. Finally, at test time, we assemble all predicted pairs of neighboring LSs to construct the full conformer, applying deterministic ring corrections. In order to generate diverse conformers, we append random Gaussian noise vectors to each initial node feature vector and use an optimal transport-based loss function for training.
70
+
71
+ # 2.2 Message passing neural networks (MPNNs)
72
+
73
+ Given an input graph $\mathbf { G }$ , an MPNN [Gilmer et al., 2017, Battaglia et al., 2018, Yang et al., 2019] computes node embeddings $\mathbf { h } _ { v } \in \mathbb { R } ^ { d } , \overline { { \forall v \in V } }$ using $\overline { T }$ layers of iterative message passing:
74
+
75
+ $$
76
+ \mathbf { h } _ { u } ^ { ( t + 1 ) } = \psi \left( \mathbf { h } _ { u } ^ { ( t ) } , \sum _ { v \in \mathcal { N } _ { u } } \phi ( \mathbf { h } _ { v } ^ { ( t ) } , \mathbf { h } _ { u } ^ { ( t ) } , \mathbf { e } _ { u , v } ) \right) , \quad \mathrm { w h e r e ~ } \mathbf { h } _ { v } ^ { ( 0 ) } \overset { \mathrm { d e f } } { = } c o n c a t [ \mathbf { x } _ { v } , \mathbf { z } _ { v } ] , \mathbf { z } _ { v } \sim \mathcal { N } ( \mathbf { 0 } , s \mathbf { I } _ { d } )
77
+ $$
78
+
79
+ for each $t \in [ 0 \dots T - 1 ]$ , where $\mathcal { N } _ { u } = \{ v \in V | ( u , v ) \in E \}$ , while $\psi$ and $\phi$ are generic functions, e.g., implemented using multilayer perceptrons (MLP) or attention [Velickovi ˇ c et al.,´ $\boxed { 2 0 1 7 }$ . Final node embeddings are obtained by the embedding of the last layer: $\mathbf { h } _ { v } \overline { { \stackrel { \mathrm { d e f } } { = } \mathbf { h } _ { v } ^ { ( T ) } , \forall v \in V } }$ . Finally, we
80
+
81
+ also compute a molecular embedding: $\begin{array} { r } { \mathbf { h } _ { m o l } \overset { \mathrm { d e f } } { = } M L P ( \sum _ { v \in V } \mathbf { h } _ { v } ) } \end{array}$ . We leave comparison with other 2 MPNN variants for future work, e.g., Kipf and Welling [2017], Velickovi ˇ c et al. [2017], Hamilton ´ et al. [2017], Xu et al. [2019].
82
+
83
+ # 2.3 Local structure (1-hop) prediction model
84
+
85
+ Following notations in fig. $^ { 3 , }$ , for each non-terminal graph vertex $X \in V$ having $n$ graph neighbors $\mathcal { N } _ { X } = \{ T _ { i } \} _ { i \in [ 1 \ldots n ] }$ , we predict its local $3 D$ structure (LS), i.e., the relative 3D positions of all $T _ { i }$ , when $\mathbf { X }$ is centered in the origin. The generic model is a function $f ( \mathbf { h } _ { T _ { 1 } } , \dots , \mathbf { h } _ { T _ { n } } ; \mathbf { h } _ { X } ) =$ $( \mathbf { p } _ { 1 } , \ldots , \mathbf { p } _ { n } ) \in \mathbb { R } ^ { 3 \times n }$ that, additionally, should satisfy permutation equivariance w.r.t. $T _ { i }$ ’s, namely, the 3D position of each neighbor $T _ { i }$ should not change regardless of the ordering of the $X$ ’s neighbors:
86
+
87
+ $$
88
+ f ( \mathbf { h } _ { T _ { \pi ( 1 ) } } , \ldots , \mathbf { h } _ { T _ { \pi ( n ) } } ; \mathbf { h } _ { X } ) = ( \mathbf { p } _ { \pi ( 1 ) } , \ldots , \mathbf { p } _ { \pi ( n ) } ) , \forall \pi \in S _ { n }
89
+ $$
90
+
91
+ Our choice is the encoder part of a transformer [Vaswani et al., $\boxed { 2 0 1 7 }$ , without any positional encoding, thus satisfying permutation equivariance. This model takes as input the set $\{ c o n c a t [ \mathbf { h } _ { T _ { i } } , \mathbf { h } _ { X } ] ; i \in [ 1 . . n ] \}$ in any order and synchronously updates the $n$ embeddings based on several transformer layers. The final layer projects the embeddings to 3 dimensions, resulting in a list $( \mathbf { p } _ { 1 } , \ldots , \mathbf { p } _ { n } ) \in \mathbb { R } ^ { 3 \times n }$ having the exact same node order as the input list.
92
+
93
+ ![](images/fd6b2182d6366014d199253b60ac5c409c547a8bfb3d5644b7494a34ad60941e.jpg)
94
+ Figure 3: For each non-terminal atom X, we predict the relative 3D position of each of its graph neighbors, $\{ T _ { i } \} _ { i \in [ 1 \ldots n ] }$ , in a permutation equivariant manner.
95
+
96
+ Enforcing local consistency. We desire the LS model $f ( )$ to be distance-consistent, i.e., any bond distance $d ( X , Y )$ is the same, no matter if it is computed from the LS of node $\mathbf { X }$ or of node Y. To achieve this, we use the above transformer just to compute bond directions (which will be aligned using a separate approach described in section $\underline { { \widehat { | 2 . 4 ) } } }$ while we obtain the bond distances with a separate symmetric model. Concretely, let the above transformer $f ( )$ predict $( \mathbf { p } _ { 1 } , \ldots , \mathbf { p } _ { n } ) \in \mathbb { R } ^ { 3 \times n }$ , while the final local 3D coordinates are $\mathbf { p } _ { i } ^ { \prime } { \stackrel { \mathrm { d e f } } { = } } \frac { \mathbf { p } _ { i } } { \| \mathbf { p } _ { i } \| } d _ { G N N } ( \mathbf { h } _ { X } , \mathbf { h } _ { T _ { i } } ) , \forall i$ , where each bond distance is predicted with a symmetric model $d _ { G N N } ( \mathbf { h } _ { X } , \mathbf { h } _ { Y } ) \overset { \mathrm { d e f } } { = } \mathrm { s o f t p l u s } ( \psi ( \mathbf { h } _ { X } , \mathbf { h } _ { Y } ) + \psi ( \mathbf { h } _ { Y } , \mathbf { h } _ { X } ) ) , \forall ( X , Y ) \in E$ , with the same shared $\psi$ (e.g., an MLP). For notation simplicity, we will just use $\mathbf { p } _ { i }$ instead of $\mathbf { p } _ { i } ^ { \prime }$ .
97
+
98
+ Regarding SE(3) invariance. The above model is not SE(3)-invariant per se, but it is used as such. Namely, on one hand we compute SE(3)-invariant quantities: 1- hop distances $d ( T _ { i } , X )$ , 2-hop distances $d ( T _ { i } , T _ { j } )$ , and bending angles $\angle T _ { i } X T _ { j }$ . These will be compared to their ground-truth counterparts in the final loss, see section $2 . 5 .$
99
+
100
+ On the other hand, the LS of adjacent graph nodes are assembled together for computing torsion angles or for building the full conformer at test time. This process is explicitly defined to be SE(3)-invariant as described in section 2.4.
101
+
102
+ Tetrahedral chiral corrections. When embedding the local neighborhood of a node in 3D space, one has to carefully account for tetrahedral stereocenters (fig. 4). Tetrahedral chirality is a common form of stereochemistry which restricts the 3D location of neighboring substituents of a central atom with four distinct neighbors; molecules which differ by a single tetrahedral stereocenter, i.e., enantiomers, are mirror images of each other. Chirality heavily impacts some properties of small molecules–e.g., bioactivity. Existing MPNNs using only the molecular graph cannot distinguish chiral centers (fig. 4), but solutions exist [Pattanaik et al., 2020a]. Mathematically, enantiomers can be differentiated based on the oriented volume around the tetrahedral center. That is, given the ordered set of neighbor 3D coordinates around the center, namely $\mathbf { p } _ { 1 } , \mathbf { p } _ { 2 } , \mathbf { p } _ { 3 } , \mathbf { p } _ { 4 } \in \mathbb { R } ^ { 3 }$ , the sign of the volume of the tetrahedron formed by the neighbors is
103
+
104
+ ![](images/c1d80bf941cbd5f7d6d32f0e8cd4203450cd3a11ba9c08b06b0d008f6c320863.jpg)
105
+ Figure 4: Chirality: even if the two shown graphs are isomorphic, they have distinct 3D structures that can be distinguished by the order of the carbon center’s neighbors.
106
+
107
+ $$
108
+ O V ( \mathbf { p } _ { 1 } , \mathbf { p } _ { 2 } , \mathbf { p } _ { 3 } , \mathbf { p } _ { 4 } ) \stackrel { \mathrm { d e f } } { = } s i g n \left( \left| \begin{array} { c c c c } { 1 } & { 1 } & { 1 } & { 1 } \\ { x _ { 1 } } & { x _ { 2 } } & { x _ { 3 } } & { x _ { 4 } } \\ { y _ { 1 } } & { y _ { 2 } } & { y _ { 3 } } & { y _ { 4 } } \\ { z _ { 1 } } & { z _ { 2 } } & { z _ { 3 } } & { z _ { 4 } } \end{array} \right| \right)
109
+ $$
110
+
111
+ Enantiomeric structures always have opposite signs for the oriented volume $[ \mathrm { C r i p p e n \ e t a l . } ] , [ \mathrm { 9 8 8 } ]$ Since we generate local 3D structures directly, we can also use local 3D chiral descriptors to ensure the correct generation of tetrahedral stereocenters. RDKit internally keeps track of these local chiral labels, denoted by CW/CCW labels (detailed in e.g., Pattanaik et al. $\pm { \overline { { [ 2 0 2 0 \mathrm { a } ] } } } )$ . Importantly, each local chiral label corresponds to a certain oriented volume ( $\boldsymbol { \overline { { \mathrm { C W } } } } = + 1$ and $\overline { { \mathrm { C C W } } } = - 1$ ). Thus, when generating an LS for a tetrahedral center, we calculate the oriented volume and check against the internal RDKit label. If it results in the incorrect oriented volume (i.e., the incorrect stereocenter was generated), we simply reflect the structure by flipping against the z-axis. This ensures that all tetrahedral stereocenters centers are generated exactly, and no iterative optimization is necessary as with traditional DG-based generators.
112
+
113
+ # 2.4 Torsion angle representation and local structure (LS) assembly
114
+
115
+ Once the LS of each atom/vertex is predicted, we assemble them in pairs corresponding to each non-terminal bond in the molecular graph. We describe this process for a bond connecting atoms $\mathrm { X }$ and Y, each having additional graph neighbors $\{ T _ { i } \} _ { i \in [ 1 , . . n ] }$ and, resp., $\{ Z _ { j } \} _ { j \in [ 1 . . m ] }$ . See fig. 5.
116
+
117
+ Torsion angle over-parameterization. We first note that, for any assembled bond XY (fig. 5, right), and $\forall i , k \in [ 1 . . n ] , \forall j , l \in [ 1 . . m ]$ , the dihedral angles $\angle ( X Y T _ { i } , \dot { X } Y T _ { k } )$ and $\angle ( X Y Z _ { l } , X { \bar { Y Z } } _ { j } )$ are fully determined by the LS of nodes $\mathrm { X }$ and Y, respectively, so they do not depend on the torsion angle of bond XY. Next, observe that there is exactly one torsion angle for any bond XY, given unique indexing of the neighbors. This happens because of the following constraint:
118
+
119
+ $$
120
+ \angle ( X Y T _ { i } , X Y Z _ { j } ) = [ \angle ( X Y T _ { k } , X Y Z _ { l } ) + \angle ( X Y T _ { i } , X Y T _ { k } ) + \angle ( X Y Z _ { l } , X Y Z _ { j } ) ] ( \mathrm { m o d } 2 \pi )
121
+ $$
122
+
123
+ Thus, in order to avoid unnecessary over-parameterization, we predict a single torsion angle $\alpha$ per each bond $X Y$ connecting non-terminal atoms.
124
+
125
+ Torsion angle formulation. However, it is still unclear at this point how to define this unique angle in a canonical way that is: i) permutation invariant w.r.t. the nodes in the set $\{ T _ { i } \} _ { i \in [ 1 , . . n ] }$ and, respectively, in the set $\{ Z _ { j } \} _ { j \in [ 1 . . m ] }$ , ii) SE(3)-invariant w.r.t. the full 3D conformer, and iii) agrees with eq. $( 3 )$ .
126
+
127
+ ![](images/5c02b628b31f1488776698de4c431238fc96a33db88df7c39e4cf8b3d231cfd8.jpg)
128
+ Figure 5: Assembly of the local structures of bonded atoms $\mathrm { X }$ and $\mathrm { Y }$ based on the predicted torsion angle.
129
+
130
+ Let $\Delta _ { i j } \ { \stackrel { \mathrm { d e f } } { = } } \ \angle ( X Y T _ { i } , X Y Z _ { j } )$ and $\begin{array} { r } { \mathbf { s } _ { i j } \ \stackrel { \mathrm { d e f } } { = } \ \left[ \stackrel { \cos \left( \Delta _ { i j } \right) } { \sin \left( \Delta _ { i j } \right) } \right] } \end{array}$ Let $c _ { i j } \in \mathbb { R }$ be real coefficients such that $\begin{array} { r } { \mathbf { s } \triangleq \sum _ { i , j } c _ { i j } \mathbf { s } _ { i j } \in \mathbb { R } ^ { 2 } } \end{array}$ is not the null vector. Then, we define the torsion angle as5: $\begin{array} { r } { \alpha \stackrel { \mathrm { d e f } } { = } a t a n 2 ( \frac { \mathbf { s } } { \| \mathbf { s } \| } ) } \end{array}$ . It is easy to see that this formulation satisfies both invariances claimed above. We further state (and prove in appendix $\mathbf { A } )$ that our proposed formulation gives a torsion angle uniquely determined by all local angles $\bar { \angle } ( Y X T _ { i } , Y X T _ { k } )$ , $\angle ( Y X Z _ { j } , Y X Z _ { l } )$ and by the true underlying torsion angle:
131
+
132
+ Proposition 1. Given $3 D$ coordinates of nodes $X , Y , T _ { i } , Z _ { j }$ and fixed weights $c _ { i j } \in \mathbb { R }$ such that $\textstyle \sum _ { i , j } c _ { i j } \mathbf { s } _ { i j } \in \mathbb { R } ^ { 2 }$ is not the null vector, then $\alpha \stackrel { \mathrm { d e f } } { = } a t a n 2 ( \frac { \mathbf { s } } { \| \mathbf { s } \| } )$ is unique, i.e., if we change the torsion angle of bond $X Y ,$ then $\alpha$ will change. Formally, if we rotate the set of bonds $\{ X T _ { i } \} _ { i }$ jointly around the line $X Y$ with the same angle $\gamma$ , then $\alpha$ will be exactly shifted with $\gamma$ .
133
+
134
+ How to set $c _ { i j } \mathbf { \hat { \theta } } ^ { } $ Breaking symmetries. A simple solution is to choose $c _ { i j } = 1 , \forall i , j$ . However, in some important cases, local symmetries may result in $\mathbf { s } = 0$ . For example, this happens if, for some betw $j$ , we have n the diffe $\begin{array} { r } { \Delta _ { i j } = \frac { 2 i \pi } { n } + \dot { c } \dot { t } . , \forall i \in [ 1 . . n ] } \end{array}$ . Oneerent lution is to use dif(and similarly for ent ). $c _ { i j }$ to differentiates is reminiscent $T _ { i }$ $Z _ { j }$ of traditional group priorities used for distinguishing $\mathrm { E } / \mathrm { Z }$ isomers. We devise a flexible solution to distinguish these subgraphs: a differentiable real valued function computed from the MPNN node embeddings as $c _ { i j } = \bar { M L P } ( \mathbf { h } _ { T _ { i } } + \mathbf { h } _ { Z _ { j } } ) \in \mathbb { R }$ , with MLP being a neural network shared across all bonds and molecules. Note that we constrain $c _ { i j } = c _ { j i }$ , thus guaranteeing that the same $\alpha$ is obtained if we swap $\mathrm { X }$ and $\mathrm { Y }$ (and their neighbors, respectively).
135
+
136
+ Final LS assembly for a single bond. We now describe the assembly process depicted in fig. $\boxed { 5 }$ We first predict the LS of node $\mathrm { X }$ as in section $\boxed { 2 . 3 }$ obtaining several 3D coordinates: $\mathbf { p } _ { X } = \mathbf { 0 } , \mathbf { p } _ { Y } , \mathbf { \overline { { \mathbf { p } } } } _ { T _ { i } } \in$ $\mathbb { R } ^ { 3 } , \dot { \forall } i \in [ 1 . . n ]$ , as well as the LS of node $\mathrm { Y }$ : $\mathbf { q } _ { Y } = \bar { \mathbf { 0 } _ { \cdot } } \mathbf { q } _ { X } , \mathbf { q } _ { Z _ { j } } \in \mathbb { R } ^ { 3 } , \forall j \in [ 1 . . m ]$ . By design, we have that $\| \mathbf { q } _ { X } \| = \| \mathbf { p } _ { Y } \|$ . These two sets are currently not aligned. To achieve this, we first rotate the LS of $\mathrm { X }$ such that $\mathbf { p } _ { Y }$ becomes $\left[ \left. \mathbf { p } _ { Y } \right. \quad 0 \quad 0 \right] ^ { \intercal }$ , while $\mathbf { p } _ { X }$ remains 0. Next, we rotate and translate the LS of $\mathrm { Y }$ such that $\mathbf { q } _ { Y }$ becomes $\mathbf { p } _ { Y }$ and $\mathbf { q } _ { X }$ becomes $\mathbf { p } _ { X } = \mathbf { 0 }$ . These two rotations have one degree of freedom each, which we set randomly. Exact formulas are in appendix B. Thus, the bond XY is now matched, but the torsional rotation is still arbitrary/random. The remaining step is to rotate the LS of $\mathrm { X }$ with an angle $\gamma$ such that all dihedrals $\angle ( X Y T _ { i } , X Y Z _ { j } )$ match their true counterparts. This is done by applying to all vectors $\mathbf { p } _ { T _ { i } }$ the same rotation of type: $\mathbf { H } _ { \gamma } : = \left[ \begin{array} { c c c } { 1 } & { 0 } & { 0 } \\ { 0 } & { \cos ( \gamma ) } & { - \sin ( \gamma ) } \\ { 0 } & { \sin ( \gamma ) } & { \cos ( \gamma ) } \end{array} \right] .$
137
+
138
+ How to compute $\gamma$ ? The current dihedrals $\Delta _ { i j } ^ { c u r } \ \stackrel { \mathsf { d e f } } { = } \ \angle ^ { c u r } ( X Y T _ { i } , X Y Z _ { j } )$ depend on the random torsional rotations from the initial assembly step of LS of $\mathbf { X }$ and of $\mathrm { Y }$ . After applying the $\mathbf { H } _ { \gamma }$ rotation, we obtain the new dihedral angles: $[ \Delta _ { i j } ^ { c u r } - \gamma ]$ mod $2 \pi$ that should match the ground truth dihedral angles $\Delta _ { i j } ^ { * } \ { \stackrel { \mathrm { d e f } } { = } } \ \angle ^ { * } ( X Y T _ { i } , X Y Z _ { j } )$ . This is equivalently written as $\mathbf { s } _ { i j } ^ { * } = \mathbf { A } _ { i j } ^ { c u r } \mathbf { s } _ { \gamma }$ , where $\mathbf { s } _ { \gamma } \ { \stackrel { \mathrm { d e f } } { = } } \ \left[ \cos ( \gamma ) \right]$ and Acurij def=  $\begin{array} { r } { \mathbf { A } _ { i j } ^ { c u r } \stackrel { \mathrm { d e f } } { = } \left[ \begin{array} { c c } { \cos ( \Delta _ { i j } ^ { c u r } ) } & { \sin ( \Delta _ { i j } ^ { c u r } ) } \\ { \sin ( \Delta _ { i j } ^ { c u r } ) } & { - \cos ( \Delta _ { i j } ^ { c u r } ) } \end{array} \right] . } \end{array}$ . Let $\begin{array} { r } { \mathbf { s } ^ { * } \overset { \mathrm { d e f } } { = } \sum _ { i , j } c _ { i j } \mathbf { s } _ { i j } ^ { * } } \end{array}$ and $\mathbf { A } ^ { c u r } \ { \stackrel { \mathrm { d e } 1 } { = } }$ $\begin{array} { r } { \sum _ { i , j } c _ { i j } \mathbf { A } _ { i j } ^ { c u r } } \end{array}$ . The necessary condition for becomes $\mathbf { s } _ { \gamma } = \left( \mathbf { A } ^ { c u r } \right) ^ { \top } \mathbf { s } ^ { * }$ , which is also sufficient due i,j to proposition $\bigstar \bigstar \bigstar$ This implies it is enough to predict only the normalized $\frac { \mathbf { s } ^ { * } } { \| \mathbf { s } ^ { * } \| }$ and, in practice, we do that by predicting $\mathbf { s } _ { \alpha } \triangleq \left[ \cos ( \alpha ) \right]$ using a function commutative in $\mathrm { X }$ and $\mathrm { Y }$ (i.e., swapping $\mathrm { X }$ and $\mathrm { Y }$ does not change $\alpha$ ):
139
+
140
+ $$
141
+ \alpha = [ \phi ( \mathbf { h } _ { X } , \mathbf { h } _ { Y } , \mathbf { h } _ { m o l } ) + \phi ( \mathbf { h } _ { Y } , \mathbf { h } _ { X } , \mathbf { h } _ { m o l } ) ] { \bmod { 2 \pi } }
142
+ $$
143
+
144
+ where is a neural network (e.g., MLP). Finally, s = $\begin{array} { r } { { \bf s } _ { \gamma } = \left[ \begin{array} { c c } { \cos ( \gamma ) } \\ { \sin ( \gamma ) } \end{array} \right] = \frac { 1 } { \Vert ( { \bf A } ^ { c u r } ) ^ { \top } { \bf s } _ { \alpha } \Vert } \left( { \bf A } ^ { c u r } \right) ^ { \top } { \bf s } _ { \alpha } . } \end{array}$
145
+
146
+ # 2.5 An optimal transport (OT) loss function for diverse conformer generation
147
+
148
+ Loss per single conformer. Assume first that we predict a single conformer $\mathcal { C }$ . Based on all LS and torsion angle predictions, we deterministically compute all 1/2/3-hop distances and bond/torsion angles. If the corresponding ground truth conformer $\mathcal { C } ^ { * }$ is known, we feed those quantities into a negative log-likelihood loss, denote by ${ \mathcal { L } } ( { \mathcal { C } } , { \mathcal { C } } ^ { * } )$ and detailed in appendix $\bigtriangledown$ Similar to Senior et al. $\underline { { \lVert 2 0 2 0 \rVert } }$ , we fit distances using normal distributions and angles using von Mises distributions. This is a much faster approach compared to habitual RMSD losses that compare full conformers.
149
+
150
+ Node symmetries. Our current formulation has difficulties distinguishing pairs of symmetric graph nodes that are less than 3 hops away, e.g., hydrogen groups. We address this using a tailored matching loss detailed in appendix D and exemplified in fig. 6.
151
+
152
+ ![](images/b8f60e2cfae1ae6d2c583056bd1f9e0ba44e45b7e9a7536d90c04af7fc900e39.jpg)
153
+ Figure 6: Before (left) and after (right) introducing a matching loss to distinguish symmetric graph nodes. Hydrogen predictions in both groups are visibly improved.
154
+
155
+ Table 1: Results on the GEOM-DRUGS dataset. All models are without FF fine-tuning. "R" and "P" denote Recall and Precision. Note: OMEGA is an established commercial (C) software.
156
+
157
+ <table><tr><td rowspan=2 colspan=1>Models</td><td rowspan=1 colspan=2>COV -R(%) ↑</td><td rowspan=1 colspan=2>AMR -R(A)↓</td><td rowspan=1 colspan=2>COV - P(%) ↑</td><td rowspan=1 colspan=2>AMR -P(A)↓</td></tr><tr><td rowspan=1 colspan=1>Mean</td><td rowspan=1 colspan=1>Median</td><td rowspan=1 colspan=1>Mean</td><td rowspan=1 colspan=1>Median</td><td rowspan=1 colspan=1>Mean</td><td rowspan=1 colspan=1>Median</td><td rowspan=1 colspan=1>Mean</td><td rowspan=1 colspan=1>Median</td></tr><tr><td rowspan=2 colspan=1>GraphDG (ML)CGCF (ML)</td><td rowspan=2 colspan=1>10.3754.35</td><td rowspan=1 colspan=1>0.00</td><td rowspan=2 colspan=1>1.9501.248</td><td rowspan=2 colspan=1>1.9331.224</td><td rowspan=2 colspan=1>3.9824.48</td><td rowspan=2 colspan=1>0.0015.00</td><td rowspan=2 colspan=1>2.4201.837</td><td rowspan=2 colspan=1>2.4201.829</td></tr><tr><td rowspan=1 colspan=1>56.74</td></tr><tr><td rowspan=1 colspan=1>RDKit/ETKDGOMEGA (C)</td><td rowspan=1 colspan=1>68.7881.64</td><td rowspan=1 colspan=1>76.0497.25</td><td rowspan=1 colspan=1>1.0420.851</td><td rowspan=1 colspan=1>0.9820.771</td><td rowspan=1 colspan=1>71.0677.18</td><td rowspan=1 colspan=1>88.2496.15</td><td rowspan=1 colspan=1>1.0360.951</td><td rowspan=1 colspan=1>0.9430.854</td></tr><tr><td rowspan=1 colspan=1>GEOMOL (s= 9.5)GEOMOL (s = 5)</td><td rowspan=1 colspan=1>86.0782.43</td><td rowspan=1 colspan=1>98.0695.10</td><td rowspan=1 colspan=1>0.8460.862</td><td rowspan=1 colspan=1>0.8200.837</td><td rowspan=1 colspan=1>71.7878.52</td><td rowspan=1 colspan=1>83.7794.40</td><td rowspan=1 colspan=1>1.0390.933</td><td rowspan=1 colspan=1>0.9820.856</td></tr></table>
158
+
159
+ Table 2: Results on the GEOM-QM9 dataset. See caption of table 1.
160
+
161
+ <table><tr><td rowspan=2 colspan=1>Models</td><td rowspan=1 colspan=2>COV -R (%) ↑</td><td rowspan=1 colspan=2>AMR -R(A)↓</td><td rowspan=1 colspan=2>COV - P (%) ↑</td><td rowspan=1 colspan=2>AMR -P(A)↓</td></tr><tr><td rowspan=1 colspan=1>Mean</td><td rowspan=1 colspan=1>Median</td><td rowspan=1 colspan=1>Mean</td><td rowspan=1 colspan=1>Median</td><td rowspan=1 colspan=1>Mean</td><td rowspan=1 colspan=1>Median</td><td rowspan=1 colspan=1>Mean</td><td rowspan=1 colspan=1>Median</td></tr><tr><td rowspan=1 colspan=1>GraphDG (ML)CGCF (ML)</td><td rowspan=1 colspan=1>74.6669.47</td><td rowspan=1 colspan=1>100.0096.15</td><td rowspan=1 colspan=1>0.3730.425</td><td rowspan=1 colspan=1>0.3370.374</td><td rowspan=1 colspan=1>63.0338.20</td><td rowspan=1 colspan=1>77.6033.33</td><td rowspan=1 colspan=1>0.4500.711</td><td rowspan=1 colspan=1>0.4040.695</td></tr><tr><td rowspan=1 colspan=1>RDKit/ETKDGOMEGA (C)</td><td rowspan=1 colspan=1>85.1385.51</td><td rowspan=1 colspan=1>100.00100.00</td><td rowspan=1 colspan=1>0.2350.177</td><td rowspan=1 colspan=1>0.1990.126</td><td rowspan=1 colspan=1>86.8082.86</td><td rowspan=1 colspan=1>100.00100.00</td><td rowspan=1 colspan=1>0.2320.224</td><td rowspan=1 colspan=1>0.2050.186</td></tr><tr><td rowspan=1 colspan=1>GEOMOL (s = 5)</td><td rowspan=1 colspan=1>91.52</td><td rowspan=1 colspan=1>100.00</td><td rowspan=1 colspan=1>0.225</td><td rowspan=1 colspan=1>0.193</td><td rowspan=1 colspan=1>86.71</td><td rowspan=1 colspan=1>100.00</td><td rowspan=1 colspan=1>0.270</td><td rowspan=1 colspan=1>0.241</td></tr></table>
162
+
163
+ Total OT loss per ensemble of conformers. In practice, our model generates a set of conformers $\{ \mathcal { C } _ { k } \} _ { k \in [ 1 \ldots K ] }$ that needs to match a variable sized set of low-energy ground truth conformers, $\{ \mathcal { C } _ { l } ^ { * } \} _ { l \in [ 1 , . . L ] }$ . However, we do not know a priori the number $L$ of true conformers or the matching between generated and true conformers. We also wish to avoid expensive and problematic adversarial training. Our solution is an OT-based, minimization-only, loss function:
164
+
165
+ $$
166
+ \mathcal { L } ^ { e n s e m b l e } \stackrel { \mathrm { d e f } } { = } E M D _ { \mathcal { L } ( \cdot , \cdot ) } ( \{ \mathcal { C } _ { k } \} _ { k } , \{ \mathcal { C } _ { l } ^ { * } \} _ { l } ) = \operatorname* { m i n } _ { { \bf T } \in \mathcal { Q } _ { K , L } } \sum _ { k , l } T _ { k l } \mathcal { L } ( \mathcal { C } _ { k } , \mathcal { C } _ { l } ^ { * } )
167
+ $$
168
+
169
+ Distance, . The min $\mathbf { T }$ is the transpization w.r.t. t plan satisfying is computed qui $\mathcal { Q } _ { K , L } \overset { \mathtt { d e f } } { = } \{ \mathbf { T } \in \mathbb { R } _ { + } ^ { K \times L }$ $\begin{array} { r } { { \bf T 1 } _ { L } = \frac { 1 } { K } { \bf 1 } _ { K } , { \bf T } ^ { T } { \bf 1 } _ { K } = \frac { 1 } { L } { \bf 1 } _ { L } \Big \} } \end{array}$ $\mathbf { T }$ Distance and the POT library [Flamary and Courty, 2017].
170
+
171
+ # 2.6 Full conformer assembly at test time
172
+
173
+ Knowing all true LSs and torsion angles is, in theory, enough for a deterministic unique SE(3)- invariant reconstruction of the full conformer. However, in practice, these predictions might have small errors that accumulate, e.g., in rings. To mitigate this issue, we deterministically build the full conformer (only at test time) by first predicting a smoothed structure of (fused) rings separately, and then assembling the full conformer following any graph traversal order (any order gives the same conformer, so this procedure does not break the non-autoregressive behavior). We detail this step in appendix E.
174
+
175
+ # 3 Experiments
176
+
177
+ We empirically evaluate GEOMOL on the task of low-energy conformer ensemble generation for small and drug-like molecules. We largely follow the evaluation protocols of recent methods [Simm and Hernandez-Lobato, 2020, Xu et al., 2021], but also introduce new useful metrics.
178
+
179
+ Datasets & splits. We use two popular datasets: GEOM-QM9 [Ramakrishnan et al., 2014] and GEOM-DRUGS [Axelrod and Gomez-Bombarelli, $\textcircled { 2 0 2 0 2 }$ . Statistics and other details are in fig. 10 and in Mansimov et al. [2019]. Datasets are preprocessed as described in appendix $\boxed { \mathbf { G } }$ We split them randomly based on molecules into train/validation/test $( 8 0 \% / 1 0 \% / 1 0 \% )$ ). At the end, for each dataset, we sample 1000 random test molecules as the final test set. Thus, the splits contain 106586/13323/1000 and 243473/30433/1000 molecules for GEOM-QM9 and GEOM-DRUGS, resp.
180
+
181
+ ![](images/d9a3a42a0435d2a5af6926bc026d2e53b2ef8602c5a945d51409bebd6826261f.jpg)
182
+ Figure 7: Left: Examples of generated structures. For every model, we show the best generated conformer, i.e., with the smallest RMSD to the shown ground truth. More examples are in appendix $\mathbb { N } .$ Right/top: Number of rotatable bonds per DRUGS test molecule versus COV Recall ( $9 5 \%$ confidence intervals). Right/bottom: conformer generation times for each model.
183
+
184
+ Baselines. We compare to established or recent baselines (discussed in section 1). ETKDG/RDKit [Riniker and Landrum, $\boxed { 2 0 1 5 } \|$ is likely the most popular open-source software, a stochastic DG-based method developed in the RDKit package. OMEGA [Hawkins et al., 2010, Hawkins and Nicholls, 2012, Friedrich et al., 2017], a rule-based method, is one of the most established commercial software, with more than a decade of continuous development. OMEGA and ETKDG are some of the fastest and best scaling existing approaches. Finally, we compare with the recent ML models of highest reported quality: GraphDG [Simm and Hernandez-Lobato, $\underline { 2 0 2 0 } \|$ and CGCF [Xu et al., 2021].
185
+
186
+ Evaluation metrics. We follow prior work [Simm and Hernandez-Lobato, 2020, Xu et al., 2021] and use root-mean-square deviation of atomic positions (RMSD) to compare any two conformers. This is defined as the normalized Frobenius norm of the two corresponding matrices of 3D coordinates after being SE(3)-aligned a priori (using the Kabsch alignment algorithm $\pm \pm \mathrm { { \mathbb { K } a b s c h } } \mathrm { { \mathbb { 1 9 7 6 } } } \mathrm { { \mathrm { I } } } .$ ). Next, we introduce four types of metrics to compare two conformer ensembles, generated by a method, $\{ \mathcal { C } _ { k } \} _ { k \in [ 1 \ldots K ] }$ , and ground truth, $\{ \mathcal { C } _ { l } ^ { * } \} _ { l \in [ 1 , . . L ] }$ . These metrics follow the established classification metrics of Precision and Recall and are defined for a given threshold $\delta > 0$ as:
187
+
188
+ $$
189
+ \begin{array} { l } { \displaystyle \mathrm { C O V - R } ( \mathrm { R e c a l l } ) \stackrel { \mathrm { d e f } } { = } \frac { 1 } { L } | \{ l \in [ 1 . . L ] : \exists k \in [ 1 . . K ] , R M S D ( \mathscr { C } _ { k } , \mathscr { C } _ { l } ^ { * } ) < \delta \} | } \\ { \displaystyle \mathrm { A M R - R } ( \mathrm { R e c a l l } ) \stackrel { \mathrm { d e f } } { = } \frac { 1 } { L } \sum _ { l \in [ 1 . . L ] } \underset { k \in [ 1 . . K ] } { \operatorname* { m i n } } R M S D ( \mathscr { C } _ { k } , \mathscr { C } _ { l } ^ { * } ) } \end{array}
190
+ $$
191
+
192
+ where AMR is "Average Minimum RMSD", COV is "Coverage", and $C O V - P$ (Precision) and AMR - $P$ (Precision) are defined as in eq. $\textcircled{5}$ , but with the generated and ground truth conformer sets swapped. The recall metrics measure how many of the ground truth conformers are correctly predicted, while the precision metrics indicate how many generated structures are of high quality. Specifically, in terms of recall, COV measures the percentage of correct generated conformers from the ground truth set (where a correct conformer is defined as one within an RMSD threshold of the true conformer), while AMR measures the average RMSD of each generated conformer with its closest groun truth match. Depending on the application, either of the metrics might be of greater interest. We follow Xu et al. [2021] and set $\delta = 0 . { \overset { - } { 5 } } { \overset { \circ } { \mathrm { A } } }$ for GEOM-QM9 and $\delta = 1 . 2 \bar { 5 } \mathring \mathrm { A }$ for GEOM-DRUGS.
193
+
194
+ Training and test details. For each input molecule having $K$ ground truth conformers, we generate exactly $2 K$ conformers using any of the considered methods. For GEOMOL, this is done by sampling different random noise vectors that are appended to node and edge features before the MPNN (eq. $\mathbb { \underline { { \left( \mathrm { 1 } \right) } } }$ ). At train time, our model uses a standard deviation (std) $s$ (see eq. $( 1 )$ ) of 5 for both GEOM-QM9 and GEOM-DRUGS. At test time, GEOMOL can use the same or different $s$ values, depending on the downstream application, i.e., higher $s$ results in more diverse conformers, while lower $s$ gives more quality (better precision). For OMEGA, it is not possible to specify a desired number of conformers. So, we tune the RMSD threshold (which decides how many conformers to keep) such that the total generated conformers by OMEGA are approximately $2 K$ . For GEOM-QM9, this corresponds to no RMSD cutoff (i.e., OMEGA generates all possible conformers), and for GEOM-DRUGS, this corresponds to a cutoff of $0 . 7 \mathring \mathrm { A }$ (meaning no two generated conformers will have a distance smaller than this cutoff). We discuss hyper-parameters and additional training details in appendix H.
195
+
196
+ Results & discussion. Results are shown in table $^ 1$ and table $2 ,$ and confidence intervals are in appendix $\mathbb { L }$ As noted above, GEOMOL can be run with different noise std at test time, depending on which metric the user is interested in. Even though OMEGA is an established commercial software with more than a decade of continuous development, our model remarkably frequently outperforms it. Note that OMEGA fails to generate any conformers for $7 \%$ of the QM9 test set (many of which include fused rings). Moreover, we also outperform the popular RDKit/ETKDG open-source model (except for AMR-P on QM9) and very recent ML models such as GraphDG and CGCF, sometimes by a large margin. For a qualitative insight, we show generated examples in fig. 7 and appendix N.
197
+
198
+ Additionally, we show in fig. $\perp$ how COV Recall results are affected by the increasing number of rotatable bonds in the test molecule. As expected, having more rotatable bonds makes the problem harder, and this affects all baselines, but GEOMOL maintains a reasonable coverage even for more difficult molecules. Moreover, in appendix K and table 8 we show energy calculations of the generated conformers to support their plausibility. Additionally, results with energy-based relaxations are given in appendix J.
199
+
200
+ Running time. Fig. 7 shows conformer generation test running times. Our model is the fastest method from the considered baselines, being much faster than CGCF or ETKDG/RDKit. Moreover, GEOMOL scales favorably for molecules with increasing number of rotatable bonds.
201
+
202
+ # 4 Conclusion
203
+
204
+ We proposed GEOMOL, an end-to-end generative approach for molecular 3D conformation ensembles that explicitly models various molecular geometric aspects such as torsion angles or chirality. We expect that such differentiable structure generators will significantly impact small molecule conformer generation along with many related applications (e.g., protein-ligand binding), thus speeding up areas such as drug discovery. GEOMOL’s full source code will be made publicly available.
205
+
206
+ Limitations & future work. A few current limitations are highlighted and left for future extensions (see also discussion in appendix $\bigstar$ . First, our model does not currently support disconnected molecular graphs, e.g., ionic salts, but it can be applied to each connected component, followed by a 3D alignment. Next, our approach would benefit from explicit modeling of long distance interactions, especially for macrocycles or large molecules. This remains to be addressed in an efficient manner. Third, explicitly using ground truth energy values could further improve GEOMOL. Last, we look forward to fine-tune GEOMOL on applications such as generating molecular docking poses or descriptors for 4D QSAR.
207
+
208
+ # Acknowledgments and Disclosure of Funding
209
+
210
+ OEG thanks Bracha Laufer, Tian Xie, Xiang Fu, Peter Mikhael, and the rest of the RB and TJ group members for their helpful comments and suggestions. LP thanks Camille Bilodeau and the rest of the WHG, KFJ, and CWC research groups for their useful discussions. We also thank Pat Walters, Simon Axelrod, and Rafael Gomez-Bombarelli for their insightful feedback as well as Minkai Xu and Shitong Luo for helping run the CGCF model. Both OEG and LP are funded by the Machine Learning for Pharmaceutical Discovery and Synthesis consortium.
211
+
212
+ # References
213
+
214
+ Mohammed AlQuraishi. End-to-end differentiable learning of protein structure. Cell systems, 8(4): 292–301, 2019.
215
+
216
+ Simon Axelrod and Rafael Gomez-Bombarelli. Geom: Energy-annotated molecular conformations for property prediction and molecular generation. arXiv preprint arXiv:2006.05531, 2020a.
217
+
218
+ Simon Axelrod and Rafael Gomez-Bombarelli. Molecular machine learning with conformer ensembles. arXiv preprint arXiv:2012.08452, 2020b.
219
+
220
+ Andrew J Ballard, Stefano Martiniani, Jacob D Stevenson, Sandeep Somani, and David J Wales. Exploiting the potential energy landscape to sample free energy. Wiley Interdisciplinary Reviews: Computational Molecular Science, 5(3):273–289, 2015.
221
+
222
+ Arghya Barman, Bruce Batiste, and Donald Hamelberg. Pushing the limits of a molecular mechanics force field to probe weak ch··· $\pi$ interactions in proteins. Journal of chemical theory and computation, 11(4):1854–1863, 2015.
223
+
224
+ Peter W Battaglia, Jessica B Hamrick, Victor Bapst, Alvaro Sanchez-Gonzalez, Vinicius Zambaldi, Mateusz Malinowski, Andrea Tacchetti, David Raposo, Adam Santoro, Ryan Faulkner, et al. Relational inductive biases, deep learning, and graph networks. arXiv preprint arXiv:1806.01261, 2018.
225
+
226
+ Lucian Chan, Garrett M Morris, and Geoffrey R Hutchison. Understanding conformational entropy in small molecules. Journal of Chemical Theory and Computation, 17(4):2099–2106, 2021.
227
+
228
+ Gordon M Crippen, Timothy F Havel, et al. Distance geometry and molecular conformation, volume 74. Research Studies Press Taunton, 1988.
229
+
230
+ Marco De Vivo, Matteo Masetti, Giovanni Bottegoni, and Andrea Cavalli. Role of molecular dynamics and related methods in drug discovery. Journal of medicinal chemistry, 59(9):4035–4061, 2016.
231
+
232
+ Rémi Flamary and Nicolas Courty. Pot python optimal transport library. GitHub: https://github. com/rflamary/POT, 2017.
233
+
234
+ Nils-Ole Friedrich, Christina de Bruyn Kops, Florian Flachsenberg, Kai Sommer, Matthias Rarey, and Johannes Kirchmair. Benchmarking commercial conformer ensemble generators. Journal of chemical information and modeling, 57(11):2719–2728, 2017.
235
+
236
+ Pablo Gainza, Freyr Sverrisson, Frederico Monti, Emanuele Rodola, D Boscaini, MM Bronstein, and BE Correia. Deciphering interaction fingerprints from protein molecular surfaces using geometric deep learning. Nature Methods, 17(2):184–192, 2020.
237
+
238
+ Vikas Garg, Stefanie Jegelka, and Tommi Jaakkola. Generalization and representational limits of graph neural networks. In International Conference on Machine Learning, pages 3419–3430. PMLR, 2020.
239
+
240
+ Justin Gilmer, Samuel S Schoenholz, Patrick F Riley, Oriol Vinyals, and George E Dahl. Neural message passing for quantum chemistry. In Proceedings of the 34th International Conference on Machine Learning-Volume 70, pages 1263–1272. JMLR. org, 2017.
241
+
242
+ Stefan Grimme. Exploration of chemical compound, conformer, and reaction space with metadynamics simulations based on tight-binding quantum chemical calculations. Journal of chemical theory and computation, 15(5):2847–2862, 2019.
243
+
244
+ Cristiano RW Guimaraes, Alan M Mathiowetz, Marina Shalaeva, Gilles Goetz, and Spiros Liras. Use of 3d properties to characterize beyond rule-of-5 property space for passive permeation. Journal of chemical information and modeling, 52(4):882–890, 2012.
245
+
246
+ Thomas A Halgren. Merck molecular force field. i. basis, form, scope, parameterization, and performance of mmff94. Journal of computational chemistry, 17(5-6):490–519, 1996.
247
+
248
+ Thomas A Halgren. Mmff vi. mmff94s option for energy minimization studies. Journal of Computational Chemistry, 20(7):720–729, 1999.
249
+
250
+ William L Hamilton, Rex Ying, and Jure Leskovec. Inductive representation learning on large graphs. In Proceedings of the 31st International Conference on Neural Information Processing Systems, pages 1025–1035, 2017.
251
+
252
+ Timothy F Havel. Distance geometry: Theory, algorithms, and chemical applications. Encyclopedia of Computational Chemistry, 120:723–742, 1998.
253
+
254
+ Timothy F Havel, Gordon M Crippen, Irwin D Kuntz, and Jeffrey M Blaney. The combinatorial distance geometry method for the calculation of molecular conformation ii. sample problems and computational statistics. Journal of theoretical biology, 104(3):383–400, 1983a.
255
+
256
+ Timothy F Havel, Irwin D Kuntz, and Gordon M Crippen. The combinatorial distance geometry method for the calculation of molecular conformation. i. a new approach to an old problem. Journal of theoretical biology, 104(3):359–381, 1983b.
257
+
258
+ Paul CD Hawkins. Conformation generation: the state of the art. Journal of Chemical Information and Modeling, 57(8):1747–1756, 2017.
259
+
260
+ Paul CD Hawkins and Anthony Nicholls. Conformer generation with omega: learning from the data set and the analysis of failures. Journal of chemical information and modeling, 52(11):2919–2936, 2012.
261
+
262
+ Paul CD Hawkins, A Geoffrey Skillman, Gregory L Warren, Benjamin A Ellingson, and Matthew T Stahl. Conformer generation with omega: algorithm and validation using high quality structures from the protein databank and cambridge structural database. Journal of chemical information and modeling, 50(4):572–584, 2010.
263
+
264
+ John Ingraham, Adam Riesselman, Chris Sander, and Debora Marks. Learning protein structure with a differentiable simulator. In International Conference on Learning Representations, 2018.
265
+
266
+ Wolfgang Kabsch. A solution for the best rotation to relate two sets of vectors. Acta Crystallographica Section A: Crystal Physics, Diffraction, Theoretical and General Crystallography, 32(5):922–923, 1976.
267
+
268
+ Ilana Y Kanal, John A Keith, and Geoffrey R Hutchison. A sobering assessment of small-molecule force field methods for low energy conformer predictions. International Journal of Quantum Chemistry, 118(5):e25512, 2018.
269
+
270
+ Thomas N Kipf and Max Welling. Semi-supervised classification with graph convolutional networks. International Conference on Learning Representations (ICLR), 2017.
271
+
272
+ Johannes Klicpera, Janek Groß, and Stephan Günnemann. Directional message passing for molecular graphs. In International Conference on Learning Representations, 2019.
273
+
274
+ Ashutosh Kumar and Kam YJ Zhang. Advances in the development of shape similarity methods and their application in drug discovery. Frontiers in chemistry, 6:315, 2018.
275
+
276
+ David Lagorce, Tania Pencheva, Bruno O Villoutreix, and Maria A Miteva. Dg-ammos: A new tool to generate 3d conformation of small molecules using d istance g eometry and a utomated m olecular m echanics o ptimization for in silico s creening. BMC Chemical Biology, 9(1):1–10, 2009.
277
+
278
+ Dominik Lemm, Guido Falk von Rudorff, and O Anatole von Lilienfeld. Energy-free machine learning predictions of ab initio structures. arXiv preprint arXiv:2102.02806, 2021.
279
+
280
+ Yi Liu, Limei Wang, Meng Liu, Xuan Zhang, Bora Oztekin, and Shuiwang Ji. Spherical message passing for 3d graph networks. arXiv preprint arXiv:2102.05013, 2021.
281
+
282
+ Elman Mansimov, Omar Mahmood, Seokho Kang, and Kyunghyun Cho. Molecular geometry prediction using a deep generative graph neural network. Scientific reports, 9(1):1–13, 2019.
283
+
284
+ Mark McGann. Fred pose prediction and virtual screening accuracy. Journal of chemical information and modeling, 51(3):578–596, 2011.
285
+
286
+ Frank Noé, Simon Olsson, Jonas Köhler, and Hao Wu. Boltzmann generators: Sampling equilibrium states of many-body systems with deep learning. Science, 365(6457), 2019.
287
+
288
+ Lagnajit Pattanaik, Octavian E Ganea, Ian Coley, Klavs F Jensen, William H Green, and Connor W Coley. Message passing networks for molecules with tetrahedral chirality. arXiv preprint arXiv:2012.00094, 2020a.
289
+
290
+ Lagnajit Pattanaik, John B Ingraham, Colin A Grambow, and William H Green. Generating transition states of isomerization reactions with deep learning. Physical Chemistry Chemical Physics, 22 (41):23618–23626, 2020b.
291
+
292
+ Raghunathan Ramakrishnan, Pavlo O Dral, Matthias Rupp, and O Anatole Von Lilienfeld. Quantum chemistry structures and properties of 134 kilo molecules. Scientific data, 1(1):1–7, 2014.
293
+
294
+ Anthony K Rappé, Carla J Casewit, KS Colwell, William A Goddard III, and W Mason Skiff. Uff, a full periodic table force field for molecular mechanics and molecular dynamics simulations. Journal of the American chemical society, 114(25):10024–10035, 1992.
295
+
296
+ Sereina Riniker and Gregory A Landrum. Better informed distance geometry: using what we know to improve conformation generation. Journal of chemical information and modeling, 55(12): 2562–2574, 2015.
297
+
298
+ Kristof T Schütt, Huziel E Sauceda, P-J Kindermans, Alexandre Tkatchenko, and K-R Müller. Schnet–a deep learning architecture for molecules and materials. The Journal of Chemical Physics, 148(24):241722, 2018.
299
+
300
+ Kristof T Schütt, Oliver T Unke, and Michael Gastegger. Equivariant message passing for the prediction of tensorial properties and molecular spectra. arXiv preprint arXiv:2102.03150, 2021.
301
+
302
+ Christof H Schwab. Conformations and 3d pharmacophore searching. Drug Discovery Today: Technologies, 7(4):e245–e253, 2010.
303
+
304
+ Andrew W Senior, Richard Evans, John Jumper, James Kirkpatrick, Laurent Sifre, Tim Green, Chongli Qin, Augustin Žídek, Alexander WR Nelson, Alex Bridgland, et al. Improved protein structure prediction using potentials from deep learning. Nature, 577(7792):706–710, 2020.
305
+
306
+ Jihyun Shim and Alexander D MacKerell Jr. Computational ligand-based rational design: role of conformational sampling and force fields in model development. MedChemComm, 2(5):356–370, 2011.
307
+
308
+ Gregor Simm and Jose Miguel Hernandez-Lobato. A generative model for molecular distance geometry. In International Conference on Machine Learning, pages 8949–8958. PMLR, 2020.
309
+
310
+ Freyr Sverrisson, Jean Feydy, Bruno Correia, and Michael Bronstein. Fast end-to-end learning on protein surfaces. bioRxiv, 2020.
311
+
312
+ 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, pages 6000–6010, 2017.
313
+
314
+ Petar Velickovi ˇ c, Guillem Cucurull, Arantxa Casanova, Adriana Romero, Pietro Lio, and Yoshua ´ Bengio. Graph attention networks. arXiv preprint arXiv:1710.10903, 2017.
315
+
316
+ Jitender Verma, Vijay M Khedkar, and Evans C Coutinho. 3d-qsar in drug design-a review. Current topics in medicinal chemistry, 10(1):95–115, 2010.
317
+
318
+ Keyulu Xu, Weihua Hu, Jure Leskovec, and Stefanie Jegelka. How powerful are graph neural networks? International Conference on Learning Representations (ICLR), 2019.
319
+
320
+ Minkai Xu, Shitong Luo, Yoshua Bengio, Jian Peng, and Jian Tang. Learning neural generative dynamics for molecular conformation generation. International Conference on Learning Representations (ICLR), 2021.
321
+
322
+ Kevin Yang, Kyle Swanson, Wengong Jin, Connor Coley, Philipp Eiden, Hua Gao, Angel GuzmanPerez, Timothy Hopper, Brian Kelley, Miriam Mathea, et al. Analyzing learned molecular representations for property prediction. Journal of chemical information and modeling, 59(8): 3370–3388, 2019.
parse/train/af_hng9tuNj/af_hng9tuNj_content_list.json ADDED
@@ -0,0 +1,1773 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [
2
+ {
3
+ "type": "text",
4
+ "text": "GEOMOL: Torsional Geometric Generation of Molecular 3D Conformer Ensembles ",
5
+ "text_level": 1,
6
+ "bbox": [
7
+ 218,
8
+ 122,
9
+ 781,
10
+ 172
11
+ ],
12
+ "page_idx": 0
13
+ },
14
+ {
15
+ "type": "text",
16
+ "text": "Octavian-Eugen Ganea ⇤, ‡ ",
17
+ "bbox": [
18
+ 279,
19
+ 220,
20
+ 465,
21
+ 236
22
+ ],
23
+ "page_idx": 0
24
+ },
25
+ {
26
+ "type": "text",
27
+ "text": "Lagnajit Pattanaik \\*, † ",
28
+ "bbox": [
29
+ 573,
30
+ 220,
31
+ 728,
32
+ 236
33
+ ],
34
+ "page_idx": 0
35
+ },
36
+ {
37
+ "type": "text",
38
+ "text": "Connor W. Coley Regina Barzilay ‡ Klavs F. Jensen † ",
39
+ "bbox": [
40
+ 236,
41
+ 256,
42
+ 756,
43
+ 272
44
+ ],
45
+ "page_idx": 0
46
+ },
47
+ {
48
+ "type": "text",
49
+ "text": "William H. Green † ",
50
+ "bbox": [
51
+ 294,
52
+ 292,
53
+ 429,
54
+ 308
55
+ ],
56
+ "page_idx": 0
57
+ },
58
+ {
59
+ "type": "text",
60
+ "text": "Tommi S. Jaakkola ‡ ",
61
+ "bbox": [
62
+ 558,
63
+ 292,
64
+ 702,
65
+ 308
66
+ ],
67
+ "page_idx": 0
68
+ },
69
+ {
70
+ "type": "text",
71
+ "text": "Abstract ",
72
+ "text_level": 1,
73
+ "bbox": [
74
+ 462,
75
+ 343,
76
+ 535,
77
+ 359
78
+ ],
79
+ "page_idx": 0
80
+ },
81
+ {
82
+ "type": "text",
83
+ "text": "Prediction of a molecule’s 3D conformer ensemble from the molecular graph holds a key role in areas of cheminformatics and drug discovery. Existing generative models have several drawbacks including lack of modeling important molecular geometry elements (e.g., torsion angles), separate optimization stages prone to error accumulation, and the need for structure fine-tuning based on approximate classical force-fields or computationally expensive methods. We propose GEOMOL — an end-to-end, non-autoregressive, and SE(3)-invariant machine learning approach to generate distributions of low-energy molecular 3D conformers. Leveraging the power of message passing neural networks (MPNNs) to capture local and global graph information, we predict local atomic 3D structures and torsion angles, avoiding unnecessary over-parameterization of the geometric degrees of freedom (e.g., one angle per non-terminal bond). Such local predictions suffice both for both the training loss computation and for the full deterministic conformer assembly (at test time). We devise a non-adversarial optimal transport based loss function to promote diverse conformer generation. GEOMOL predominantly outperforms popular open-source, commercial, or state-of-the-art machine learning (ML) models, while achieving significant speed-ups. We expect such differentiable 3D structure generators to significantly impact molecular modeling and related applications. 4 ",
84
+ "bbox": [
85
+ 232,
86
+ 372,
87
+ 766,
88
+ 622
89
+ ],
90
+ "page_idx": 0
91
+ },
92
+ {
93
+ "type": "text",
94
+ "text": "1 Overview ",
95
+ "text_level": 1,
96
+ "bbox": [
97
+ 174,
98
+ 643,
99
+ 284,
100
+ 661
101
+ ],
102
+ "page_idx": 0
103
+ },
104
+ {
105
+ "type": "text",
106
+ "text": "Problem & importance. We tackle the problem of molecular conformer generation (MCG), i.e., predicting the ensemble of low-energy 3D conformations of a small molecule solely based on the molecular graph (fig. 1). A single conformation is represented by the list of 3D coordinates for each atom in the respective molecule. In this work, we assume that the low-energy states are implicitly defined by the given dataset, i.e., our training data consist of molecular graphs and corresponding sets of energetically favorable 3D conformations. Low-energy structures are the most stable configurations and, thus, expected to be observed most often experimentally. ",
107
+ "bbox": [
108
+ 174,
109
+ 675,
110
+ 517,
111
+ 839
112
+ ],
113
+ "page_idx": 0
114
+ },
115
+ {
116
+ "type": "image",
117
+ "img_path": "images/70aec0ad4d34f607aed941f2a3c564b7bede2249f30521392b428f7de22dd555.jpg",
118
+ "image_caption": [
119
+ "Figure 1: We generate a representative set of low-energy 3D conformers from the input molecular graph. This example molecule has both rigid (rings) and flexible parts. Conformers are shown aligned and juxtaposed. "
120
+ ],
121
+ "image_footnote": [],
122
+ "bbox": [
123
+ 531,
124
+ 643,
125
+ 821,
126
+ 736
127
+ ],
128
+ "page_idx": 0
129
+ },
130
+ {
131
+ "type": "text",
132
+ "text": "",
133
+ "bbox": [
134
+ 179,
135
+ 827,
136
+ 774,
137
+ 840
138
+ ],
139
+ "page_idx": 0
140
+ },
141
+ {
142
+ "type": "text",
143
+ "text": "Dealing with molecules in their natural 3D structure is of great importance in areas such as cheminformatics or computational drug discovery because conformations determine biological, chemical, and physical properties [Guimaraes et al., 2012, Schütt et al., 2018, Klicpera et al., 2019, Axelrod and Gomez-Bombarelli, 2020b, Schütt et al., 2021, Liu et al., 2021] such as charge distribution, potential energy, docking poses [McGann, 2011], shape similarity [Kumar and Zhang, 2018], pharmacophore searching [Schwab, $\\overline { { 2 0 1 0 } }$ , or descriptors for 3/4D QSAR [Verma et al., 2010]. For instance, in drug design it is crucial to understand how a molecule binds to a specific target protein; this process heavily depends on the 3D structures of the two components, both in terms of geometric (shape matching) and chemical (hydrophobic/hydrophilic) interactions [Gainza et al., 2020, Sverrisson et al., 2020]. ",
144
+ "bbox": [
145
+ 173,
146
+ 90,
147
+ 826,
148
+ 217
149
+ ],
150
+ "page_idx": 1
151
+ },
152
+ {
153
+ "type": "text",
154
+ "text": "Motivation & challenges of existing methods. The main challenge in MCG comes from the enormous size of the 3D structure space consisting of bond lengths, bond angles, and torsion angles. It is known that the molecular graph imposes specific constraints on possible 3D conformations, e.g., bond length ranges depend on the respective bond types, while tetrahedral centers dictate local spatial arrangement. However, the space of possible conformations grows exponentially with the graph size and number of rotatable bonds, thus hindering exhaustive brute force exploration even for relatively small molecules. Additionally, the number of plausibly-stable low-energy states is unknown a priori and can vary between one and several thousand conformations for a single molecule [Chan et al., $\\boxed { 2 0 2 1 }$ . Nevertheless, various facets of the curse of dimensionality have been favorably tackled by ML models in different contexts, and our goal is to build on the recent ML efforts for MCG [Mansimov et al., 2019, Simm and Hernandez-Lobato, 2020, Lemm et al., 2021, Xu et al., 2021] ",
155
+ "bbox": [
156
+ 173,
157
+ 242,
158
+ 825,
159
+ 396
160
+ ],
161
+ "page_idx": 1
162
+ },
163
+ {
164
+ "type": "text",
165
+ "text": "Molecular conformations can be determined experimentally, but existing techniques are very expensive. As a consequence, predictive computational models have been developed over the past few decades, traditionally being categorized as either stochastic or systematic (rule-based) methods $\\lVert \\mathbf { H a w k i n s } \\rVert \\mathbf { 2 0 1 7 } \\rVert$ . Stochastic approaches have traditionally been based on molecular dynamics (MD) or Markov chain Monte Carlo (MCMC) techniques, potentially combined with genetic algorithms (GAs). They can do extensive explorations of the energy landscape and accurately sample equilibrium structures, but quickly become prohibitively slow for larger molecules [Shim and MacKerell Jr, 2011, Ballard et al., 2015, De Vivo et al., 2016, Hawkins, 2017], e.g., they require several CPU minutes for a single drug-like molecule. Moreover, stochastic methods have difficulties sampling diverse and representative conformers, prioritizing quantity over quality. On the other hand, rule-based systematic methods achieve state-of-the-art in commercial software [Friedrich et al., $\\mathbb { Z 0 1 7 }$ with OMEGA [Hawkins et al., 2010, Hawkins and Nicholls, 2012] being a popular example. They usually process a single drug-like molecule under a second. They address the aforementioned challenges of stochastic methods by relying on carefully curated torsion templates (torsion rules), rule-based generators, and knowledge bases of rigid 3D fragments, which are assembled together and combined with subsequent stability score ranking. However, torsion angles are mostly varied independently (based on their fragments), without explicitly capturing their global interactions, which results in difficulties for larger and more flexible molecules. Furthermore, the curated fragments and rules are inadequate for more challenging inputs (e.g., transition states or open-shell molecules). ",
166
+ "bbox": [
167
+ 173,
168
+ 401,
169
+ 826,
170
+ 662
171
+ ],
172
+ "page_idx": 1
173
+ },
174
+ {
175
+ "type": "text",
176
+ "text": "Both types of methods can be combined with Distance Geometry (DG) techniques to generate the initial 3D conformation. First, the 3D atom distance matrix is generated based on a set of distance constraints or from a specialized model. Subsequently, the corresponding 3D atom coordinates are learned to approximately match these predicted distances [Havel et al., 1983b,a, Crippen et al., 1988, Havel, 1998, Lagorce et al., 2009, Riniker and Landrum, 2015]. Indeed, modern stochastic algorithms are entirely based on DG methods [Riniker and Landrum, 2015]. The inductive bias of rotational and translational invariance is guaranteed for DG, thus being appealing for ML models [Simm and Hernandez-Lobato, 2020, Xu et al., 2021, Pattanaik et al., 2020b]. However, several drawbacks weaken this important direction: i) the distance matrix is overparameterized compared to the actual number of degrees of freedom, ii) it is difficult to enforce 3D Euclidean distance constraints as well as geometric graph constraints (e.g., on torsion angles or rings [Riniker and Landrum, $\\boxed { 2 0 1 5 } ] )$ ; iii) important aspects of molecular geometry are not explicitly modeled, e.g., torsion angles of rotatable bonds or tetrahedral centers; iv) expensive force-field energy fine-tuning of the generated conformers is vital for a reasonable quality [Xu et al., 2021, Simm and Hernandez-Lobato, $\\check { 2 0 } 2 0 \\|$ ; iv) the resulting multi-stage pipeline is prone to error accumulation as opposed to an end-to-end model. ",
177
+ "bbox": [
178
+ 173,
179
+ 670,
180
+ 825,
181
+ 876
182
+ ],
183
+ "page_idx": 1
184
+ },
185
+ {
186
+ "type": "text",
187
+ "text": "Previous methods often rely on a force field (FF) energy function minimization to fine-tune the conformers. These are hand-designed energy models which use parameters estimated from experiment and/or computed from quantum mechanics (e.g., Universal Force Field [Rappé et al., 1992], Merck Molecular Force Field [Halgren, 1996]). However, FFs are crude approximations of the true molecular potential energy surface [Kanal et al., 2018], limited in the interactions they can capture in biomolecules due to their strong assumptions [Barman et al., 2015]. In addition, FF energy optimization is relatively slow and increases error accumulation in a multi-pipeline method. ",
188
+ "bbox": [
189
+ 174,
190
+ 883,
191
+ 823,
192
+ 911
193
+ ],
194
+ "page_idx": 1
195
+ },
196
+ {
197
+ "type": "text",
198
+ "text": "",
199
+ "bbox": [
200
+ 174,
201
+ 92,
202
+ 825,
203
+ 160
204
+ ],
205
+ "page_idx": 2
206
+ },
207
+ {
208
+ "type": "text",
209
+ "text": "Relation to protein folding. There has been impressive recent progress on modeling protein folding dynamics [Ingraham et al., 2018, AlQuraishi, 2019, Noé et al., 2019, Senior et al., 2020], where crystallized 3D structures are predicted solely from the amino-acid sequence using ML methods. However, molecules pose unique challenges, being highly branched graphs containing cycles, different types of bonds, and chirality information. This makes protein folding approaches not readily transferable to general molecular data. ",
210
+ "bbox": [
211
+ 174,
212
+ 180,
213
+ 825,
214
+ 263
215
+ ],
216
+ "page_idx": 2
217
+ },
218
+ {
219
+ "type": "text",
220
+ "text": "Our key contributions & model in a nutshell. In this work, we investigate the question: ",
221
+ "bbox": [
222
+ 173,
223
+ 282,
224
+ 769,
225
+ 296
226
+ ],
227
+ "page_idx": 2
228
+ },
229
+ {
230
+ "type": "text",
231
+ "text": "Can we design a fast and generalizable deep learning model to predict high-quality, representative, and diverse 3D conformational ensembles from input molecular graphs? ",
232
+ "bbox": [
233
+ 178,
234
+ 313,
235
+ 825,
236
+ 340
237
+ ],
238
+ "page_idx": 2
239
+ },
240
+ {
241
+ "type": "text",
242
+ "text": "To tackle this question, we propose GEOMOL (shown in fig. 2), exhibiting the following merits: ",
243
+ "bbox": [
244
+ 173,
245
+ 354,
246
+ 802,
247
+ 371
248
+ ],
249
+ "page_idx": 2
250
+ },
251
+ {
252
+ "type": "text",
253
+ "text": "• It is end-to-end trainable, non-autoregressive, and does not rely on DG techniques (thus avoiding aforementioned drawbacks). More precisely, it outputs a minimal set of geometric quantities (i.e., angles and distances) sufficient for full deterministic reconstruction of the 3D conformer. ",
254
+ "bbox": [
255
+ 181,
256
+ 383,
257
+ 823,
258
+ 425
259
+ ],
260
+ "page_idx": 2
261
+ },
262
+ {
263
+ "type": "text",
264
+ "text": "• It models conformers in an SE(3)-invariant (translation/rotation) manner by design. This desirable inductive bias was previously either achieved using multi-step DG methods [Simm and HernandezLobato, 2020] or not captured at all [Mansimov et al., 2019]. ",
265
+ "bbox": [
266
+ 184,
267
+ 434,
268
+ 823,
269
+ 477
270
+ ],
271
+ "page_idx": 2
272
+ },
273
+ {
274
+ "type": "text",
275
+ "text": "• It explicitly models and predicts essential molecular geometry elements: torsion angles and local 3D structures (bond distances and bond angles adjacent to each atom). Together with the input molecular graph, these are used for k-hop distance computation at train time and full deterministic conformation assembly at test time. Crucially, we do not over-parameterize these predictions, i.e., a single torsion angle is computed per each non-terminal bond, irrespective of the number and permutation of the neighboring atoms at each end-point of the respective bond. ",
276
+ "bbox": [
277
+ 184,
278
+ 484,
279
+ 825,
280
+ 568
281
+ ],
282
+ "page_idx": 2
283
+ },
284
+ {
285
+ "type": "text",
286
+ "text": "• The above geometric elements (torsion angles, local structures) are SE(3)-invariant (by definition or usage) and we jointly predict them using MPNNs $\\lVert \\mathbf { G i l m e r \\ e t \\ a l . } \\rVert \\mathbf { 2 0 1 7 } \\rVert$ and self-attention networks. Thus, unlike [Mansimov et al., $\\boxed { 2 0 1 9 }$ , we are not affected by MPNNs’ pitfalls that obstruct direct predictions of 3D atom coordinates from node embeddings, e.g., symmetric or locally isomorphic nodes would always have identical MPNN embeddings [Xu et al., 2019, Garg et al., 2020] and, as a consequence, would be inappropriately assigned identical 3D coordinates. ",
287
+ "bbox": [
288
+ 186,
289
+ 575,
290
+ 825,
291
+ 660
292
+ ],
293
+ "page_idx": 2
294
+ },
295
+ {
296
+ "type": "text",
297
+ "text": "• To promote diverse conformer ensembles with good coverage, we devise a tailored generative loss that does not use slow or difficult-to-optimize adversarial training techniques. Using optimal transport, GEOMOL finds the best matching between generated and ground truth conformers based on their pairwise log-likelihood loss, requiring only minimization. ",
298
+ "bbox": [
299
+ 184,
300
+ 667,
301
+ 825,
302
+ 723
303
+ ],
304
+ "page_idx": 2
305
+ },
306
+ {
307
+ "type": "text",
308
+ "text": "• It explicitly and deterministically distinguishes reflected structures (enantiomers) by solving tetrahedral stereocenters using oriented volumes and local chiral descriptors, bypassing the need for iterative optimization usually done in DG approaches. ",
309
+ "bbox": [
310
+ 186,
311
+ 731,
312
+ 820,
313
+ 773
314
+ ],
315
+ "page_idx": 2
316
+ },
317
+ {
318
+ "type": "text",
319
+ "text": "• Empirically, we conduct experiments on two benchmarks: GEOM-QM9 (smaller molecules relevant to gas-phase chemistry) and GEOM-DRUGS (drug-like molecules) [Axelrod and GomezBombarelli, 2020a]. Our method often outperforms previous ML and two popular open-source or commercial methods in different metrics. Moreover, we show competitive quality even without the frequently-used computationally-demanding fine-tuning FF strategies. ",
320
+ "bbox": [
321
+ 186,
322
+ 781,
323
+ 825,
324
+ 852
325
+ ],
326
+ "page_idx": 2
327
+ },
328
+ {
329
+ "type": "text",
330
+ "text": "• GEOMOL processes drug-like molecules in seconds or less, being orders of magnitude faster than popular baselines (e.g., ETKDG/RDKit[Riniker and Landrum, 2015]), without sacrificing quality. ",
331
+ "bbox": [
332
+ 186,
333
+ 859,
334
+ 823,
335
+ 902
336
+ ],
337
+ "page_idx": 2
338
+ },
339
+ {
340
+ "type": "image",
341
+ "img_path": "images/31e0aa356d96eace50fef04723567f255d16587a60f11e1ed4a51635aa0ce93b.jpg",
342
+ "image_caption": [
343
+ "Figure 2: Overview of the GEOMOL model, which is SE(3)-invariant by design. Given a molecular graph, we first compute MPNNs atom embeddings. Next, we predict the local 3D structures (LS) of each non-terminal atom in a permutation invariant way, explicitly solving chirality. Third, for each bond connecting non-terminal vertices, we assemble the two LS by predicting a single torsion angle, avoiding overparameterization. Finally, the full conformer is assembled (only) at test time. "
344
+ ],
345
+ "image_footnote": [],
346
+ "bbox": [
347
+ 178,
348
+ 51,
349
+ 826,
350
+ 227
351
+ ],
352
+ "page_idx": 3
353
+ },
354
+ {
355
+ "type": "text",
356
+ "text": "2 Method ",
357
+ "text_level": 1,
358
+ "bbox": [
359
+ 174,
360
+ 328,
361
+ 271,
362
+ 344
363
+ ],
364
+ "page_idx": 3
365
+ },
366
+ {
367
+ "type": "text",
368
+ "text": "Problem setup $\\pmb { \\& }$ notations. Our input is any molecular graph $G = ( V , E )$ with node and edge features, $\\mathbf { x } _ { v } \\in \\mathbb { R } ^ { f } , \\forall v \\in V$ and $\\mathbf { e } _ { u , v } \\in \\mathbb { R } ^ { f ^ { \\prime } } , \\forall ( u , v ) \\in E$ representing atom types, formal charges, bond types, etc. For each molecular graph $\\mathbf { G }$ , we have a variable-size set of low-energy ground truth 3D conformers $\\{ \\mathcal { C } _ { l } ^ { * } \\} _ { l }$ that we predict with a model $\\{ { \\mathcal { C } } _ { k } \\} _ { k } \\ { \\overset { \\underset { \\mathrm { d e f } } { } } { = } } \\ \\zeta ( G )$ . A conformer is a map $\\mathcal { C } : V \\to \\mathbb { R } ^ { 3 }$ from graph nodes to 3D coordinates, but a simplified notation is $\\mathbf { c } _ { v } \\in \\mathbb { R } ^ { 3 }$ for $v \\in V$ . We use additional notations: $d ( X , Y ) = \\| \\mathbf { c } _ { X } - \\mathbf { c } _ { Y } \\|$ is the 3D distance between X and Y; $\\angle X Y Z$ is the counter-clockwise (CCW) angle $\\angle \\mathbf { c } _ { X } \\mathbf { c } _ { Y } \\mathbf { c } _ { Z }$ ; $\\angle ( X Y Z , X Y T )$ is the CCW dihedral angle of the 2D planes $\\mathbf { c } _ { X } \\mathbf { c } _ { Y } \\mathbf { c } _ { Z }$ and $\\mathbf { c } _ { X } \\mathbf { c } _ { Y } \\mathbf { c } _ { T }$ (formula is in appendix $\\checkmark$ . We use the corresponding $\\mathbf { c } _ { v } ^ { * } , d ^ { * } ( X , Y ) , \\angle ^ { * } X Y Z , \\angle ^ { * } ( X Y Z , X Y T )$ when manipulating a ground truth conformer. ",
369
+ "bbox": [
370
+ 173,
371
+ 358,
372
+ 826,
373
+ 492
374
+ ],
375
+ "page_idx": 3
376
+ },
377
+ {
378
+ "type": "text",
379
+ "text": "Any conformer is defined up to a SE(3) transformation, i.e., any translation or rotation applied to the set $\\{ \\mathbf { c } _ { v } \\} _ { v \\in V }$ . A classic conformer distance function that satisfies this constraint is root-mean-square deviation of atomic positions (RMSD), computed by the Kabsch alignment algorithm [Kabsch, 1976]. ",
380
+ "bbox": [
381
+ 174,
382
+ 498,
383
+ 826,
384
+ 540
385
+ ],
386
+ "page_idx": 3
387
+ },
388
+ {
389
+ "type": "text",
390
+ "text": "2.1 GEOMOL high-level overview ",
391
+ "text_level": 1,
392
+ "bbox": [
393
+ 176,
394
+ 556,
395
+ 419,
396
+ 570
397
+ ],
398
+ "page_idx": 3
399
+ },
400
+ {
401
+ "type": "text",
402
+ "text": "Our approach, shown in fig. $\\mathbb { Z } ,$ comprises three steps. First, we predict the local 3D structure of each non-terminal atom, which we deem local structure (LS), by combining self-attention layers and MPNNs with deterministic corrections for tetrahedral centers. Bond distances and bond angles are computed from the predicted LS. Next, we assemble all neighboring pairs of LSs by predicting the torsion angles and aligning them. Importantly, since LSs are fixed, it suffices to only predict a single value for the dihedral angle of each bond. Towards this goal, we develop a canonical representation of torsion angles via a local coordinate system defined SE(3)-equivariantly w.r.t. the full structure, which allows us to predict exactly the number of degrees of freedom. Finally, at test time, we assemble all predicted pairs of neighboring LSs to construct the full conformer, applying deterministic ring corrections. In order to generate diverse conformers, we append random Gaussian noise vectors to each initial node feature vector and use an optimal transport-based loss function for training. ",
403
+ "bbox": [
404
+ 173,
405
+ 580,
406
+ 826,
407
+ 734
408
+ ],
409
+ "page_idx": 3
410
+ },
411
+ {
412
+ "type": "text",
413
+ "text": "2.2 Message passing neural networks (MPNNs) ",
414
+ "text_level": 1,
415
+ "bbox": [
416
+ 173,
417
+ 750,
418
+ 516,
419
+ 765
420
+ ],
421
+ "page_idx": 3
422
+ },
423
+ {
424
+ "type": "text",
425
+ "text": "Given an input graph $\\mathbf { G }$ , an MPNN [Gilmer et al., 2017, Battaglia et al., 2018, Yang et al., 2019] computes node embeddings $\\mathbf { h } _ { v } \\in \\mathbb { R } ^ { d } , \\overline { { \\forall v \\in V } }$ using $\\overline { T }$ layers of iterative message passing: ",
426
+ "bbox": [
427
+ 174,
428
+ 773,
429
+ 821,
430
+ 804
431
+ ],
432
+ "page_idx": 3
433
+ },
434
+ {
435
+ "type": "equation",
436
+ "img_path": "images/8b6eb17b6401f1707f7ed182a8f487254f0d6cc9489c2c5d8e0cea2cba1d7cd0.jpg",
437
+ "text": "$$\n\\mathbf { h } _ { u } ^ { ( t + 1 ) } = \\psi \\left( \\mathbf { h } _ { u } ^ { ( t ) } , \\sum _ { v \\in \\mathcal { N } _ { u } } \\phi ( \\mathbf { h } _ { v } ^ { ( t ) } , \\mathbf { h } _ { u } ^ { ( t ) } , \\mathbf { e } _ { u , v } ) \\right) , \\quad \\mathrm { w h e r e ~ } \\mathbf { h } _ { v } ^ { ( 0 ) } \\overset { \\mathrm { d e f } } { = } c o n c a t [ \\mathbf { x } _ { v } , \\mathbf { z } _ { v } ] , \\mathbf { z } _ { v } \\sim \\mathcal { N } ( \\mathbf { 0 } , s \\mathbf { I } _ { d } )\n$$",
438
+ "text_format": "latex",
439
+ "bbox": [
440
+ 183,
441
+ 810,
442
+ 813,
443
+ 854
444
+ ],
445
+ "page_idx": 3
446
+ },
447
+ {
448
+ "type": "text",
449
+ "text": "for each $t \\in [ 0 \\dots T - 1 ]$ , where $\\mathcal { N } _ { u } = \\{ v \\in V | ( u , v ) \\in E \\}$ , while $\\psi$ and $\\phi$ are generic functions, e.g., implemented using multilayer perceptrons (MLP) or attention [Velickovi ˇ c et al.,´ $\\boxed { 2 0 1 7 }$ . Final node embeddings are obtained by the embedding of the last layer: $\\mathbf { h } _ { v } \\overline { { \\stackrel { \\mathrm { d e f } } { = } \\mathbf { h } _ { v } ^ { ( T ) } , \\forall v \\in V } }$ . Finally, we ",
450
+ "bbox": [
451
+ 174,
452
+ 864,
453
+ 825,
454
+ 912
455
+ ],
456
+ "page_idx": 3
457
+ },
458
+ {
459
+ "type": "text",
460
+ "text": "also compute a molecular embedding: $\\begin{array} { r } { \\mathbf { h } _ { m o l } \\overset { \\mathrm { d e f } } { = } M L P ( \\sum _ { v \\in V } \\mathbf { h } _ { v } ) } \\end{array}$ . We leave comparison with other 2 MPNN variants for future work, e.g., Kipf and Welling [2017], Velickovi ˇ c et al. [2017], Hamilton ´ et al. [2017], Xu et al. [2019]. ",
461
+ "bbox": [
462
+ 173,
463
+ 90,
464
+ 826,
465
+ 136
466
+ ],
467
+ "page_idx": 4
468
+ },
469
+ {
470
+ "type": "text",
471
+ "text": "2.3 Local structure (1-hop) prediction model ",
472
+ "text_level": 1,
473
+ "bbox": [
474
+ 173,
475
+ 155,
476
+ 496,
477
+ 170
478
+ ],
479
+ "page_idx": 4
480
+ },
481
+ {
482
+ "type": "text",
483
+ "text": "Following notations in fig. $^ { 3 , }$ , for each non-terminal graph vertex $X \\in V$ having $n$ graph neighbors $\\mathcal { N } _ { X } = \\{ T _ { i } \\} _ { i \\in [ 1 \\ldots n ] }$ , we predict its local $3 D$ structure (LS), i.e., the relative 3D positions of all $T _ { i }$ , when $\\mathbf { X }$ is centered in the origin. The generic model is a function $f ( \\mathbf { h } _ { T _ { 1 } } , \\dots , \\mathbf { h } _ { T _ { n } } ; \\mathbf { h } _ { X } ) =$ $( \\mathbf { p } _ { 1 } , \\ldots , \\mathbf { p } _ { n } ) \\in \\mathbb { R } ^ { 3 \\times n }$ that, additionally, should satisfy permutation equivariance w.r.t. $T _ { i }$ ’s, namely, the 3D position of each neighbor $T _ { i }$ should not change regardless of the ordering of the $X$ ’s neighbors: ",
484
+ "bbox": [
485
+ 173,
486
+ 181,
487
+ 825,
488
+ 253
489
+ ],
490
+ "page_idx": 4
491
+ },
492
+ {
493
+ "type": "equation",
494
+ "img_path": "images/f2f863e0433f93dcbc908753b46858bae086247fa907ff3ce1c92bef023739a4.jpg",
495
+ "text": "$$\nf ( \\mathbf { h } _ { T _ { \\pi ( 1 ) } } , \\ldots , \\mathbf { h } _ { T _ { \\pi ( n ) } } ; \\mathbf { h } _ { X } ) = ( \\mathbf { p } _ { \\pi ( 1 ) } , \\ldots , \\mathbf { p } _ { \\pi ( n ) } ) , \\forall \\pi \\in S _ { n }\n$$",
496
+ "text_format": "latex",
497
+ "bbox": [
498
+ 305,
499
+ 270,
500
+ 692,
501
+ 289
502
+ ],
503
+ "page_idx": 4
504
+ },
505
+ {
506
+ "type": "text",
507
+ "text": "Our choice is the encoder part of a transformer [Vaswani et al., $\\boxed { 2 0 1 7 }$ , without any positional encoding, thus satisfying permutation equivariance. This model takes as input the set $\\{ c o n c a t [ \\mathbf { h } _ { T _ { i } } , \\mathbf { h } _ { X } ] ; i \\in [ 1 . . n ] \\}$ in any order and synchronously updates the $n$ embeddings based on several transformer layers. The final layer projects the embeddings to 3 dimensions, resulting in a list $( \\mathbf { p } _ { 1 } , \\ldots , \\mathbf { p } _ { n } ) \\in \\mathbb { R } ^ { 3 \\times n }$ having the exact same node order as the input list. ",
508
+ "bbox": [
509
+ 173,
510
+ 295,
511
+ 583,
512
+ 406
513
+ ],
514
+ "page_idx": 4
515
+ },
516
+ {
517
+ "type": "image",
518
+ "img_path": "images/fd6b2182d6366014d199253b60ac5c409c547a8bfb3d5644b7494a34ad60941e.jpg",
519
+ "image_caption": [
520
+ "Figure 3: For each non-terminal atom X, we predict the relative 3D position of each of its graph neighbors, $\\{ T _ { i } \\} _ { i \\in [ 1 \\ldots n ] }$ , in a permutation equivariant manner. "
521
+ ],
522
+ "image_footnote": [],
523
+ "bbox": [
524
+ 656,
525
+ 300,
526
+ 753,
527
+ 381
528
+ ],
529
+ "page_idx": 4
530
+ },
531
+ {
532
+ "type": "text",
533
+ "text": "Enforcing local consistency. We desire the LS model $f ( )$ to be distance-consistent, i.e., any bond distance $d ( X , Y )$ is the same, no matter if it is computed from the LS of node $\\mathbf { X }$ or of node Y. To achieve this, we use the above transformer just to compute bond directions (which will be aligned using a separate approach described in section $\\underline { { \\widehat { | 2 . 4 ) } } }$ while we obtain the bond distances with a separate symmetric model. Concretely, let the above transformer $f ( )$ predict $( \\mathbf { p } _ { 1 } , \\ldots , \\mathbf { p } _ { n } ) \\in \\mathbb { R } ^ { 3 \\times n }$ , while the final local 3D coordinates are $\\mathbf { p } _ { i } ^ { \\prime } { \\stackrel { \\mathrm { d e f } } { = } } \\frac { \\mathbf { p } _ { i } } { \\| \\mathbf { p } _ { i } \\| } d _ { G N N } ( \\mathbf { h } _ { X } , \\mathbf { h } _ { T _ { i } } ) , \\forall i$ , where each bond distance is predicted with a symmetric model $d _ { G N N } ( \\mathbf { h } _ { X } , \\mathbf { h } _ { Y } ) \\overset { \\mathrm { d e f } } { = } \\mathrm { s o f t p l u s } ( \\psi ( \\mathbf { h } _ { X } , \\mathbf { h } _ { Y } ) + \\psi ( \\mathbf { h } _ { Y } , \\mathbf { h } _ { X } ) ) , \\forall ( X , Y ) \\in E$ , with the same shared $\\psi$ (e.g., an MLP). For notation simplicity, we will just use $\\mathbf { p } _ { i }$ instead of $\\mathbf { p } _ { i } ^ { \\prime }$ . ",
534
+ "bbox": [
535
+ 173,
536
+ 425,
537
+ 581,
538
+ 481
539
+ ],
540
+ "page_idx": 4
541
+ },
542
+ {
543
+ "type": "text",
544
+ "text": "",
545
+ "bbox": [
546
+ 173,
547
+ 481,
548
+ 826,
549
+ 577
550
+ ],
551
+ "page_idx": 4
552
+ },
553
+ {
554
+ "type": "text",
555
+ "text": "Regarding SE(3) invariance. The above model is not SE(3)-invariant per se, but it is used as such. Namely, on one hand we compute SE(3)-invariant quantities: 1- hop distances $d ( T _ { i } , X )$ , 2-hop distances $d ( T _ { i } , T _ { j } )$ , and bending angles $\\angle T _ { i } X T _ { j }$ . These will be compared to their ground-truth counterparts in the final loss, see section $2 . 5 .$ ",
556
+ "bbox": [
557
+ 173,
558
+ 594,
559
+ 826,
560
+ 651
561
+ ],
562
+ "page_idx": 4
563
+ },
564
+ {
565
+ "type": "text",
566
+ "text": "On the other hand, the LS of adjacent graph nodes are assembled together for computing torsion angles or for building the full conformer at test time. This process is explicitly defined to be SE(3)-invariant as described in section 2.4. ",
567
+ "bbox": [
568
+ 173,
569
+ 656,
570
+ 583,
571
+ 713
572
+ ],
573
+ "page_idx": 4
574
+ },
575
+ {
576
+ "type": "text",
577
+ "text": "Tetrahedral chiral corrections. When embedding the local neighborhood of a node in 3D space, one has to carefully account for tetrahedral stereocenters (fig. 4). Tetrahedral chirality is a common form of stereochemistry which restricts the 3D location of neighboring substituents of a central atom with four distinct neighbors; molecules which differ by a single tetrahedral stereocenter, i.e., enantiomers, are mirror images of each other. Chirality heavily impacts some properties of small molecules–e.g., bioactivity. Existing MPNNs using only the molecular graph cannot distinguish chiral centers (fig. 4), but solutions exist [Pattanaik et al., 2020a]. Mathematically, enantiomers can be differentiated based on the oriented volume around the tetrahedral center. That is, given the ordered set of neighbor 3D coordinates around the center, namely $\\mathbf { p } _ { 1 } , \\mathbf { p } _ { 2 } , \\mathbf { p } _ { 3 } , \\mathbf { p } _ { 4 } \\in \\mathbb { R } ^ { 3 }$ , the sign of the volume of the tetrahedron formed by the neighbors is ",
578
+ "bbox": [
579
+ 174,
580
+ 731,
581
+ 581,
582
+ 883
583
+ ],
584
+ "page_idx": 4
585
+ },
586
+ {
587
+ "type": "image",
588
+ "img_path": "images/c1d80bf941cbd5f7d6d32f0e8cd4203450cd3a11ba9c08b06b0d008f6c320863.jpg",
589
+ "image_caption": [
590
+ "Figure 4: Chirality: even if the two shown graphs are isomorphic, they have distinct 3D structures that can be distinguished by the order of the carbon center’s neighbors. "
591
+ ],
592
+ "image_footnote": [],
593
+ "bbox": [
594
+ 599,
595
+ 671,
596
+ 815,
597
+ 791
598
+ ],
599
+ "page_idx": 4
600
+ },
601
+ {
602
+ "type": "text",
603
+ "text": "",
604
+ "bbox": [
605
+ 173,
606
+ 883,
607
+ 825,
608
+ 911
609
+ ],
610
+ "page_idx": 4
611
+ },
612
+ {
613
+ "type": "text",
614
+ "text": "",
615
+ "bbox": [
616
+ 173,
617
+ 90,
618
+ 598,
619
+ 106
620
+ ],
621
+ "page_idx": 5
622
+ },
623
+ {
624
+ "type": "equation",
625
+ "img_path": "images/9de66cba516cb3fc063b30e4f40a5966805a142d8d40357d84c71487ebea65e1.jpg",
626
+ "text": "$$\nO V ( \\mathbf { p } _ { 1 } , \\mathbf { p } _ { 2 } , \\mathbf { p } _ { 3 } , \\mathbf { p } _ { 4 } ) \\stackrel { \\mathrm { d e f } } { = } s i g n \\left( \\left| \\begin{array} { c c c c } { 1 } & { 1 } & { 1 } & { 1 } \\\\ { x _ { 1 } } & { x _ { 2 } } & { x _ { 3 } } & { x _ { 4 } } \\\\ { y _ { 1 } } & { y _ { 2 } } & { y _ { 3 } } & { y _ { 4 } } \\\\ { z _ { 1 } } & { z _ { 2 } } & { z _ { 3 } } & { z _ { 4 } } \\end{array} \\right| \\right)\n$$",
627
+ "text_format": "latex",
628
+ "bbox": [
629
+ 325,
630
+ 114,
631
+ 671,
632
+ 174
633
+ ],
634
+ "page_idx": 5
635
+ },
636
+ {
637
+ "type": "text",
638
+ "text": "Enantiomeric structures always have opposite signs for the oriented volume $[ \\mathrm { C r i p p e n \\ e t a l . } ] , [ \\mathrm { 9 8 8 } ]$ Since we generate local 3D structures directly, we can also use local 3D chiral descriptors to ensure the correct generation of tetrahedral stereocenters. RDKit internally keeps track of these local chiral labels, denoted by CW/CCW labels (detailed in e.g., Pattanaik et al. $\\pm { \\overline { { [ 2 0 2 0 \\mathrm { a } ] } } } )$ . Importantly, each local chiral label corresponds to a certain oriented volume ( $\\boldsymbol { \\overline { { \\mathrm { C W } } } } = + 1$ and $\\overline { { \\mathrm { C C W } } } = - 1$ ). Thus, when generating an LS for a tetrahedral center, we calculate the oriented volume and check against the internal RDKit label. If it results in the incorrect oriented volume (i.e., the incorrect stereocenter was generated), we simply reflect the structure by flipping against the z-axis. This ensures that all tetrahedral stereocenters centers are generated exactly, and no iterative optimization is necessary as with traditional DG-based generators. ",
639
+ "bbox": [
640
+ 173,
641
+ 181,
642
+ 826,
643
+ 320
644
+ ],
645
+ "page_idx": 5
646
+ },
647
+ {
648
+ "type": "text",
649
+ "text": "2.4 Torsion angle representation and local structure (LS) assembly ",
650
+ "text_level": 1,
651
+ "bbox": [
652
+ 174,
653
+ 338,
654
+ 648,
655
+ 354
656
+ ],
657
+ "page_idx": 5
658
+ },
659
+ {
660
+ "type": "text",
661
+ "text": "Once the LS of each atom/vertex is predicted, we assemble them in pairs corresponding to each non-terminal bond in the molecular graph. We describe this process for a bond connecting atoms $\\mathrm { X }$ and Y, each having additional graph neighbors $\\{ T _ { i } \\} _ { i \\in [ 1 , . . n ] }$ and, resp., $\\{ Z _ { j } \\} _ { j \\in [ 1 . . m ] }$ . See fig. 5. ",
662
+ "bbox": [
663
+ 173,
664
+ 364,
665
+ 825,
666
+ 409
667
+ ],
668
+ "page_idx": 5
669
+ },
670
+ {
671
+ "type": "text",
672
+ "text": "Torsion angle over-parameterization. We first note that, for any assembled bond XY (fig. 5, right), and $\\forall i , k \\in [ 1 . . n ] , \\forall j , l \\in [ 1 . . m ]$ , the dihedral angles $\\angle ( X Y T _ { i } , \\dot { X } Y T _ { k } )$ and $\\angle ( X Y Z _ { l } , X { \\bar { Y Z } } _ { j } )$ are fully determined by the LS of nodes $\\mathrm { X }$ and Y, respectively, so they do not depend on the torsion angle of bond XY. Next, observe that there is exactly one torsion angle for any bond XY, given unique indexing of the neighbors. This happens because of the following constraint: ",
673
+ "bbox": [
674
+ 173,
675
+ 422,
676
+ 826,
677
+ 494
678
+ ],
679
+ "page_idx": 5
680
+ },
681
+ {
682
+ "type": "equation",
683
+ "img_path": "images/8f70fba6ee5ff78d65a71608fcecbcf954e51f1b85e9b1e8a79111d4ac66dc0a.jpg",
684
+ "text": "$$\n\\angle ( X Y T _ { i } , X Y Z _ { j } ) = [ \\angle ( X Y T _ { k } , X Y Z _ { l } ) + \\angle ( X Y T _ { i } , X Y T _ { k } ) + \\angle ( X Y Z _ { l } , X Y Z _ { j } ) ] ( \\mathrm { m o d } 2 \\pi )\n$$",
685
+ "text_format": "latex",
686
+ "bbox": [
687
+ 179,
688
+ 502,
689
+ 799,
690
+ 520
691
+ ],
692
+ "page_idx": 5
693
+ },
694
+ {
695
+ "type": "text",
696
+ "text": "Thus, in order to avoid unnecessary over-parameterization, we predict a single torsion angle $\\alpha$ per each bond $X Y$ connecting non-terminal atoms. ",
697
+ "bbox": [
698
+ 176,
699
+ 535,
700
+ 825,
701
+ 564
702
+ ],
703
+ "page_idx": 5
704
+ },
705
+ {
706
+ "type": "text",
707
+ "text": "Torsion angle formulation. However, it is still unclear at this point how to define this unique angle in a canonical way that is: i) permutation invariant w.r.t. the nodes in the set $\\{ T _ { i } \\} _ { i \\in [ 1 , . . n ] }$ and, respectively, in the set $\\{ Z _ { j } \\} _ { j \\in [ 1 . . m ] }$ , ii) SE(3)-invariant w.r.t. the full 3D conformer, and iii) agrees with eq. $( 3 )$ . ",
708
+ "bbox": [
709
+ 173,
710
+ 580,
711
+ 576,
712
+ 665
713
+ ],
714
+ "page_idx": 5
715
+ },
716
+ {
717
+ "type": "image",
718
+ "img_path": "images/5c02b628b31f1488776698de4c431238fc96a33db88df7c39e4cf8b3d231cfd8.jpg",
719
+ "image_caption": [
720
+ "Figure 5: Assembly of the local structures of bonded atoms $\\mathrm { X }$ and $\\mathrm { Y }$ based on the predicted torsion angle. "
721
+ ],
722
+ "image_footnote": [],
723
+ "bbox": [
724
+ 591,
725
+ 587,
726
+ 849,
727
+ 738
728
+ ],
729
+ "page_idx": 5
730
+ },
731
+ {
732
+ "type": "text",
733
+ "text": "Let $\\Delta _ { i j } \\ { \\stackrel { \\mathrm { d e f } } { = } } \\ \\angle ( X Y T _ { i } , X Y Z _ { j } )$ and $\\begin{array} { r } { \\mathbf { s } _ { i j } \\ \\stackrel { \\mathrm { d e f } } { = } \\ \\left[ \\stackrel { \\cos \\left( \\Delta _ { i j } \\right) } { \\sin \\left( \\Delta _ { i j } \\right) } \\right] } \\end{array}$ Let $c _ { i j } \\in \\mathbb { R }$ be real coefficients such that $\\begin{array} { r } { \\mathbf { s } \\triangleq \\sum _ { i , j } c _ { i j } \\mathbf { s } _ { i j } \\in \\mathbb { R } ^ { 2 } } \\end{array}$ is not the null vector. Then, we define the torsion angle as5: $\\begin{array} { r } { \\alpha \\stackrel { \\mathrm { d e f } } { = } a t a n 2 ( \\frac { \\mathbf { s } } { \\| \\mathbf { s } \\| } ) } \\end{array}$ . It is easy to see that this formulation satisfies both invariances claimed above. We further state (and prove in appendix $\\mathbf { A } )$ that our proposed formulation gives a torsion angle uniquely determined by all local angles $\\bar { \\angle } ( Y X T _ { i } , Y X T _ { k } )$ , $\\angle ( Y X Z _ { j } , Y X Z _ { l } )$ and by the true underlying torsion angle: ",
734
+ "bbox": [
735
+ 173,
736
+ 670,
737
+ 576,
738
+ 814
739
+ ],
740
+ "page_idx": 5
741
+ },
742
+ {
743
+ "type": "text",
744
+ "text": "Proposition 1. Given $3 D$ coordinates of nodes $X , Y , T _ { i } , Z _ { j }$ and fixed weights $c _ { i j } \\in \\mathbb { R }$ such that $\\textstyle \\sum _ { i , j } c _ { i j } \\mathbf { s } _ { i j } \\in \\mathbb { R } ^ { 2 }$ is not the null vector, then $\\alpha \\stackrel { \\mathrm { d e f } } { = } a t a n 2 ( \\frac { \\mathbf { s } } { \\| \\mathbf { s } \\| } )$ is unique, i.e., if we change the torsion angle of bond $X Y ,$ then $\\alpha$ will change. Formally, if we rotate the set of bonds $\\{ X T _ { i } \\} _ { i }$ jointly around the line $X Y$ with the same angle $\\gamma$ , then $\\alpha$ will be exactly shifted with $\\gamma$ . ",
745
+ "bbox": [
746
+ 173,
747
+ 818,
748
+ 826,
749
+ 883
750
+ ],
751
+ "page_idx": 5
752
+ },
753
+ {
754
+ "type": "text",
755
+ "text": "How to set $c _ { i j } \\mathbf { \\hat { \\theta } } ^ { } $ Breaking symmetries. A simple solution is to choose $c _ { i j } = 1 , \\forall i , j$ . However, in some important cases, local symmetries may result in $\\mathbf { s } = 0$ . For example, this happens if, for some betw $j$ , we have n the diffe $\\begin{array} { r } { \\Delta _ { i j } = \\frac { 2 i \\pi } { n } + \\dot { c } \\dot { t } . , \\forall i \\in [ 1 . . n ] } \\end{array}$ . Oneerent lution is to use dif(and similarly for ent ). $c _ { i j }$ to differentiates is reminiscent $T _ { i }$ $Z _ { j }$ of traditional group priorities used for distinguishing $\\mathrm { E } / \\mathrm { Z }$ isomers. We devise a flexible solution to distinguish these subgraphs: a differentiable real valued function computed from the MPNN node embeddings as $c _ { i j } = \\bar { M L P } ( \\mathbf { h } _ { T _ { i } } + \\mathbf { h } _ { Z _ { j } } ) \\in \\mathbb { R }$ , with MLP being a neural network shared across all bonds and molecules. Note that we constrain $c _ { i j } = c _ { j i }$ , thus guaranteeing that the same $\\alpha$ is obtained if we swap $\\mathrm { X }$ and $\\mathrm { Y }$ (and their neighbors, respectively). ",
756
+ "bbox": [
757
+ 173,
758
+ 90,
759
+ 826,
760
+ 217
761
+ ],
762
+ "page_idx": 6
763
+ },
764
+ {
765
+ "type": "text",
766
+ "text": "Final LS assembly for a single bond. We now describe the assembly process depicted in fig. $\\boxed { 5 }$ We first predict the LS of node $\\mathrm { X }$ as in section $\\boxed { 2 . 3 }$ obtaining several 3D coordinates: $\\mathbf { p } _ { X } = \\mathbf { 0 } , \\mathbf { p } _ { Y } , \\mathbf { \\overline { { \\mathbf { p } } } } _ { T _ { i } } \\in$ $\\mathbb { R } ^ { 3 } , \\dot { \\forall } i \\in [ 1 . . n ]$ , as well as the LS of node $\\mathrm { Y }$ : $\\mathbf { q } _ { Y } = \\bar { \\mathbf { 0 } _ { \\cdot } } \\mathbf { q } _ { X } , \\mathbf { q } _ { Z _ { j } } \\in \\mathbb { R } ^ { 3 } , \\forall j \\in [ 1 . . m ]$ . By design, we have that $\\| \\mathbf { q } _ { X } \\| = \\| \\mathbf { p } _ { Y } \\|$ . These two sets are currently not aligned. To achieve this, we first rotate the LS of $\\mathrm { X }$ such that $\\mathbf { p } _ { Y }$ becomes $\\left[ \\left. \\mathbf { p } _ { Y } \\right. \\quad 0 \\quad 0 \\right] ^ { \\intercal }$ , while $\\mathbf { p } _ { X }$ remains 0. Next, we rotate and translate the LS of $\\mathrm { Y }$ such that $\\mathbf { q } _ { Y }$ becomes $\\mathbf { p } _ { Y }$ and $\\mathbf { q } _ { X }$ becomes $\\mathbf { p } _ { X } = \\mathbf { 0 }$ . These two rotations have one degree of freedom each, which we set randomly. Exact formulas are in appendix B. Thus, the bond XY is now matched, but the torsional rotation is still arbitrary/random. The remaining step is to rotate the LS of $\\mathrm { X }$ with an angle $\\gamma$ such that all dihedrals $\\angle ( X Y T _ { i } , X Y Z _ { j } )$ match their true counterparts. This is done by applying to all vectors $\\mathbf { p } _ { T _ { i } }$ the same rotation of type: $\\mathbf { H } _ { \\gamma } : = \\left[ \\begin{array} { c c c } { 1 } & { 0 } & { 0 } \\\\ { 0 } & { \\cos ( \\gamma ) } & { - \\sin ( \\gamma ) } \\\\ { 0 } & { \\sin ( \\gamma ) } & { \\cos ( \\gamma ) } \\end{array} \\right] .$ ",
767
+ "bbox": [
768
+ 173,
769
+ 233,
770
+ 826,
771
+ 407
772
+ ],
773
+ "page_idx": 6
774
+ },
775
+ {
776
+ "type": "text",
777
+ "text": "How to compute $\\gamma$ ? The current dihedrals $\\Delta _ { i j } ^ { c u r } \\ \\stackrel { \\mathsf { d e f } } { = } \\ \\angle ^ { c u r } ( X Y T _ { i } , X Y Z _ { j } )$ depend on the random torsional rotations from the initial assembly step of LS of $\\mathbf { X }$ and of $\\mathrm { Y }$ . After applying the $\\mathbf { H } _ { \\gamma }$ rotation, we obtain the new dihedral angles: $[ \\Delta _ { i j } ^ { c u r } - \\gamma ]$ mod $2 \\pi$ that should match the ground truth dihedral angles $\\Delta _ { i j } ^ { * } \\ { \\stackrel { \\mathrm { d e f } } { = } } \\ \\angle ^ { * } ( X Y T _ { i } , X Y Z _ { j } )$ . This is equivalently written as $\\mathbf { s } _ { i j } ^ { * } = \\mathbf { A } _ { i j } ^ { c u r } \\mathbf { s } _ { \\gamma }$ , where $\\mathbf { s } _ { \\gamma } \\ { \\stackrel { \\mathrm { d e f } } { = } } \\ \\left[ \\cos ( \\gamma ) \\right]$ \u0000 and Acurij def=  $\\begin{array} { r } { \\mathbf { A } _ { i j } ^ { c u r } \\stackrel { \\mathrm { d e f } } { = } \\left[ \\begin{array} { c c } { \\cos ( \\Delta _ { i j } ^ { c u r } ) } & { \\sin ( \\Delta _ { i j } ^ { c u r } ) } \\\\ { \\sin ( \\Delta _ { i j } ^ { c u r } ) } & { - \\cos ( \\Delta _ { i j } ^ { c u r } ) } \\end{array} \\right] . } \\end{array}$ . Let $\\begin{array} { r } { \\mathbf { s } ^ { * } \\overset { \\mathrm { d e f } } { = } \\sum _ { i , j } c _ { i j } \\mathbf { s } _ { i j } ^ { * } } \\end{array}$ and $\\mathbf { A } ^ { c u r } \\ { \\stackrel { \\mathrm { d e } 1 } { = } }$ $\\begin{array} { r } { \\sum _ { i , j } c _ { i j } \\mathbf { A } _ { i j } ^ { c u r } } \\end{array}$ . The necessary condition for becomes $\\mathbf { s } _ { \\gamma } = \\left( \\mathbf { A } ^ { c u r } \\right) ^ { \\top } \\mathbf { s } ^ { * }$ , which is also sufficient due i,j to proposition $\\bigstar \\bigstar \\bigstar$ This implies it is enough to predict only the normalized $\\frac { \\mathbf { s } ^ { * } } { \\| \\mathbf { s } ^ { * } \\| }$ and, in practice, we do that by predicting $\\mathbf { s } _ { \\alpha } \\triangleq \\left[ \\cos ( \\alpha ) \\right]$ using a function commutative in $\\mathrm { X }$ and $\\mathrm { Y }$ (i.e., swapping $\\mathrm { X }$ and $\\mathrm { Y }$ does not change $\\alpha$ ): ",
778
+ "bbox": [
779
+ 173,
780
+ 415,
781
+ 826,
782
+ 597
783
+ ],
784
+ "page_idx": 6
785
+ },
786
+ {
787
+ "type": "equation",
788
+ "img_path": "images/dd984852d0152f72a9e5a56d5301eb5f4748b24ace2ffcb66b7f0df1b5a3c0ea.jpg",
789
+ "text": "$$\n\\alpha = [ \\phi ( \\mathbf { h } _ { X } , \\mathbf { h } _ { Y } , \\mathbf { h } _ { m o l } ) + \\phi ( \\mathbf { h } _ { Y } , \\mathbf { h } _ { X } , \\mathbf { h } _ { m o l } ) ] { \\bmod { 2 \\pi } }\n$$",
790
+ "text_format": "latex",
791
+ "bbox": [
792
+ 326,
793
+ 606,
794
+ 673,
795
+ 625
796
+ ],
797
+ "page_idx": 6
798
+ },
799
+ {
800
+ "type": "text",
801
+ "text": "where \u0000 is a neural network (e.g., MLP). Finally, s\u0000 = $\\begin{array} { r } { { \\bf s } _ { \\gamma } = \\left[ \\begin{array} { c c } { \\cos ( \\gamma ) } \\\\ { \\sin ( \\gamma ) } \\end{array} \\right] = \\frac { 1 } { \\Vert ( { \\bf A } ^ { c u r } ) ^ { \\top } { \\bf s } _ { \\alpha } \\Vert } \\left( { \\bf A } ^ { c u r } \\right) ^ { \\top } { \\bf s } _ { \\alpha } . } \\end{array}$ ",
802
+ "bbox": [
803
+ 173,
804
+ 633,
805
+ 789,
806
+ 667
807
+ ],
808
+ "page_idx": 6
809
+ },
810
+ {
811
+ "type": "text",
812
+ "text": "2.5 An optimal transport (OT) loss function for diverse conformer generation ",
813
+ "text_level": 1,
814
+ "bbox": [
815
+ 173,
816
+ 684,
817
+ 722,
818
+ 700
819
+ ],
820
+ "page_idx": 6
821
+ },
822
+ {
823
+ "type": "text",
824
+ "text": "Loss per single conformer. Assume first that we predict a single conformer $\\mathcal { C }$ . Based on all LS and torsion angle predictions, we deterministically compute all 1/2/3-hop distances and bond/torsion angles. If the corresponding ground truth conformer $\\mathcal { C } ^ { * }$ is known, we feed those quantities into a negative log-likelihood loss, denote by ${ \\mathcal { L } } ( { \\mathcal { C } } , { \\mathcal { C } } ^ { * } )$ and detailed in appendix $\\bigtriangledown$ Similar to Senior et al. $\\underline { { \\lVert 2 0 2 0 \\rVert } }$ , we fit distances using normal distributions and angles using von Mises distributions. This is a much faster approach compared to habitual RMSD losses that compare full conformers. ",
825
+ "bbox": [
826
+ 173,
827
+ 712,
828
+ 616,
829
+ 837
830
+ ],
831
+ "page_idx": 6
832
+ },
833
+ {
834
+ "type": "text",
835
+ "text": "Node symmetries. Our current formulation has difficulties distinguishing pairs of symmetric graph nodes that are less than 3 hops away, e.g., hydrogen groups. We address this using a tailored matching loss detailed in appendix D and exemplified in fig. 6. ",
836
+ "bbox": [
837
+ 173,
838
+ 856,
839
+ 614,
840
+ 912
841
+ ],
842
+ "page_idx": 6
843
+ },
844
+ {
845
+ "type": "image",
846
+ "img_path": "images/b8f60e2cfae1ae6d2c583056bd1f9e0ba44e45b7e9a7536d90c04af7fc900e39.jpg",
847
+ "image_caption": [
848
+ "Figure 6: Before (left) and after (right) introducing a matching loss to distinguish symmetric graph nodes. Hydrogen predictions in both groups are visibly improved. "
849
+ ],
850
+ "image_footnote": [],
851
+ "bbox": [
852
+ 625,
853
+ 719,
854
+ 825,
855
+ 780
856
+ ],
857
+ "page_idx": 6
858
+ },
859
+ {
860
+ "type": "table",
861
+ "img_path": "images/365844c74d8761f0506cd7ad1b9fb8c1bb0832b8fc8f4782c77a0a80284b6367.jpg",
862
+ "table_caption": [
863
+ "Table 1: Results on the GEOM-DRUGS dataset. All models are without FF fine-tuning. \"R\" and \"P\" denote Recall and Precision. Note: OMEGA is an established commercial (C) software. "
864
+ ],
865
+ "table_footnote": [],
866
+ "table_body": "<table><tr><td rowspan=2 colspan=1>Models</td><td rowspan=1 colspan=2>COV -R(%) ↑</td><td rowspan=1 colspan=2>AMR -R(A)↓</td><td rowspan=1 colspan=2>COV - P(%) ↑</td><td rowspan=1 colspan=2>AMR -P(A)↓</td></tr><tr><td rowspan=1 colspan=1>Mean</td><td rowspan=1 colspan=1>Median</td><td rowspan=1 colspan=1>Mean</td><td rowspan=1 colspan=1>Median</td><td rowspan=1 colspan=1>Mean</td><td rowspan=1 colspan=1>Median</td><td rowspan=1 colspan=1>Mean</td><td rowspan=1 colspan=1>Median</td></tr><tr><td rowspan=2 colspan=1>GraphDG (ML)CGCF (ML)</td><td rowspan=2 colspan=1>10.3754.35</td><td rowspan=1 colspan=1>0.00</td><td rowspan=2 colspan=1>1.9501.248</td><td rowspan=2 colspan=1>1.9331.224</td><td rowspan=2 colspan=1>3.9824.48</td><td rowspan=2 colspan=1>0.0015.00</td><td rowspan=2 colspan=1>2.4201.837</td><td rowspan=2 colspan=1>2.4201.829</td></tr><tr><td rowspan=1 colspan=1>56.74</td></tr><tr><td rowspan=1 colspan=1>RDKit/ETKDGOMEGA (C)</td><td rowspan=1 colspan=1>68.7881.64</td><td rowspan=1 colspan=1>76.0497.25</td><td rowspan=1 colspan=1>1.0420.851</td><td rowspan=1 colspan=1>0.9820.771</td><td rowspan=1 colspan=1>71.0677.18</td><td rowspan=1 colspan=1>88.2496.15</td><td rowspan=1 colspan=1>1.0360.951</td><td rowspan=1 colspan=1>0.9430.854</td></tr><tr><td rowspan=1 colspan=1>GEOMOL (s= 9.5)GEOMOL (s = 5)</td><td rowspan=1 colspan=1>86.0782.43</td><td rowspan=1 colspan=1>98.0695.10</td><td rowspan=1 colspan=1>0.8460.862</td><td rowspan=1 colspan=1>0.8200.837</td><td rowspan=1 colspan=1>71.7878.52</td><td rowspan=1 colspan=1>83.7794.40</td><td rowspan=1 colspan=1>1.0390.933</td><td rowspan=1 colspan=1>0.9820.856</td></tr></table>",
867
+ "bbox": [
868
+ 158,
869
+ 108,
870
+ 836,
871
+ 233
872
+ ],
873
+ "page_idx": 7
874
+ },
875
+ {
876
+ "type": "table",
877
+ "img_path": "images/788a58ad618135c90a4d72a1e6e1e12c6285493ae605ab8f96d05d9140678217.jpg",
878
+ "table_caption": [
879
+ "Table 2: Results on the GEOM-QM9 dataset. See caption of table 1. "
880
+ ],
881
+ "table_footnote": [],
882
+ "table_body": "<table><tr><td rowspan=2 colspan=1>Models</td><td rowspan=1 colspan=2>COV -R (%) ↑</td><td rowspan=1 colspan=2>AMR -R(A)↓</td><td rowspan=1 colspan=2>COV - P (%) ↑</td><td rowspan=1 colspan=2>AMR -P(A)↓</td></tr><tr><td rowspan=1 colspan=1>Mean</td><td rowspan=1 colspan=1>Median</td><td rowspan=1 colspan=1>Mean</td><td rowspan=1 colspan=1>Median</td><td rowspan=1 colspan=1>Mean</td><td rowspan=1 colspan=1>Median</td><td rowspan=1 colspan=1>Mean</td><td rowspan=1 colspan=1>Median</td></tr><tr><td rowspan=1 colspan=1>GraphDG (ML)CGCF (ML)</td><td rowspan=1 colspan=1>74.6669.47</td><td rowspan=1 colspan=1>100.0096.15</td><td rowspan=1 colspan=1>0.3730.425</td><td rowspan=1 colspan=1>0.3370.374</td><td rowspan=1 colspan=1>63.0338.20</td><td rowspan=1 colspan=1>77.6033.33</td><td rowspan=1 colspan=1>0.4500.711</td><td rowspan=1 colspan=1>0.4040.695</td></tr><tr><td rowspan=1 colspan=1>RDKit/ETKDGOMEGA (C)</td><td rowspan=1 colspan=1>85.1385.51</td><td rowspan=1 colspan=1>100.00100.00</td><td rowspan=1 colspan=1>0.2350.177</td><td rowspan=1 colspan=1>0.1990.126</td><td rowspan=1 colspan=1>86.8082.86</td><td rowspan=1 colspan=1>100.00100.00</td><td rowspan=1 colspan=1>0.2320.224</td><td rowspan=1 colspan=1>0.2050.186</td></tr><tr><td rowspan=1 colspan=1>GEOMOL (s = 5)</td><td rowspan=1 colspan=1>91.52</td><td rowspan=1 colspan=1>100.00</td><td rowspan=1 colspan=1>0.225</td><td rowspan=1 colspan=1>0.193</td><td rowspan=1 colspan=1>86.71</td><td rowspan=1 colspan=1>100.00</td><td rowspan=1 colspan=1>0.270</td><td rowspan=1 colspan=1>0.241</td></tr></table>",
883
+ "bbox": [
884
+ 160,
885
+ 265,
886
+ 825,
887
+ 375
888
+ ],
889
+ "page_idx": 7
890
+ },
891
+ {
892
+ "type": "text",
893
+ "text": "Total OT loss per ensemble of conformers. In practice, our model generates a set of conformers $\\{ \\mathcal { C } _ { k } \\} _ { k \\in [ 1 \\ldots K ] }$ that needs to match a variable sized set of low-energy ground truth conformers, $\\{ \\mathcal { C } _ { l } ^ { * } \\} _ { l \\in [ 1 , . . L ] }$ . However, we do not know a priori the number $L$ of true conformers or the matching between generated and true conformers. We also wish to avoid expensive and problematic adversarial training. Our solution is an OT-based, minimization-only, loss function: ",
894
+ "bbox": [
895
+ 173,
896
+ 400,
897
+ 826,
898
+ 472
899
+ ],
900
+ "page_idx": 7
901
+ },
902
+ {
903
+ "type": "equation",
904
+ "img_path": "images/809577d456ca17e0d46599166a87a3440c09048db48a6d822f2957661c9d05f4.jpg",
905
+ "text": "$$\n\\mathcal { L } ^ { e n s e m b l e } \\stackrel { \\mathrm { d e f } } { = } E M D _ { \\mathcal { L } ( \\cdot , \\cdot ) } ( \\{ \\mathcal { C } _ { k } \\} _ { k } , \\{ \\mathcal { C } _ { l } ^ { * } \\} _ { l } ) = \\operatorname* { m i n } _ { { \\bf T } \\in \\mathcal { Q } _ { K , L } } \\sum _ { k , l } T _ { k l } \\mathcal { L } ( \\mathcal { C } _ { k } , \\mathcal { C } _ { l } ^ { * } )\n$$",
906
+ "text_format": "latex",
907
+ "bbox": [
908
+ 269,
909
+ 488,
910
+ 725,
911
+ 525
912
+ ],
913
+ "page_idx": 7
914
+ },
915
+ {
916
+ "type": "text",
917
+ "text": "Distance, . The min $\\mathbf { T }$ is the transpization w.r.t. t plan satisfying is computed qui $\\mathcal { Q } _ { K , L } \\overset { \\mathtt { d e f } } { = } \\{ \\mathbf { T } \\in \\mathbb { R } _ { + } ^ { K \\times L }$ $\\begin{array} { r } { { \\bf T 1 } _ { L } = \\frac { 1 } { K } { \\bf 1 } _ { K } , { \\bf T } ^ { T } { \\bf 1 } _ { K } = \\frac { 1 } { L } { \\bf 1 } _ { L } \\Big \\} } \\end{array}$ $\\mathbf { T }$ Distance and the POT library [Flamary and Courty, 2017]. ",
918
+ "bbox": [
919
+ 173,
920
+ 531,
921
+ 826,
922
+ 579
923
+ ],
924
+ "page_idx": 7
925
+ },
926
+ {
927
+ "type": "text",
928
+ "text": "2.6 Full conformer assembly at test time ",
929
+ "text_level": 1,
930
+ "bbox": [
931
+ 176,
932
+ 594,
933
+ 467,
934
+ 611
935
+ ],
936
+ "page_idx": 7
937
+ },
938
+ {
939
+ "type": "text",
940
+ "text": "Knowing all true LSs and torsion angles is, in theory, enough for a deterministic unique SE(3)- invariant reconstruction of the full conformer. However, in practice, these predictions might have small errors that accumulate, e.g., in rings. To mitigate this issue, we deterministically build the full conformer (only at test time) by first predicting a smoothed structure of (fused) rings separately, and then assembling the full conformer following any graph traversal order (any order gives the same conformer, so this procedure does not break the non-autoregressive behavior). We detail this step in appendix E. ",
941
+ "bbox": [
942
+ 173,
943
+ 619,
944
+ 826,
945
+ 719
946
+ ],
947
+ "page_idx": 7
948
+ },
949
+ {
950
+ "type": "text",
951
+ "text": "3 Experiments ",
952
+ "text_level": 1,
953
+ "bbox": [
954
+ 174,
955
+ 738,
956
+ 312,
957
+ 756
958
+ ],
959
+ "page_idx": 7
960
+ },
961
+ {
962
+ "type": "text",
963
+ "text": "We empirically evaluate GEOMOL on the task of low-energy conformer ensemble generation for small and drug-like molecules. We largely follow the evaluation protocols of recent methods [Simm and Hernandez-Lobato, 2020, Xu et al., 2021], but also introduce new useful metrics. ",
964
+ "bbox": [
965
+ 173,
966
+ 770,
967
+ 825,
968
+ 813
969
+ ],
970
+ "page_idx": 7
971
+ },
972
+ {
973
+ "type": "text",
974
+ "text": "Datasets & splits. We use two popular datasets: GEOM-QM9 [Ramakrishnan et al., 2014] and GEOM-DRUGS [Axelrod and Gomez-Bombarelli, $\\textcircled { 2 0 2 0 2 }$ . Statistics and other details are in fig. 10 and in Mansimov et al. [2019]. Datasets are preprocessed as described in appendix $\\boxed { \\mathbf { G } }$ We split them randomly based on molecules into train/validation/test $( 8 0 \\% / 1 0 \\% / 1 0 \\% )$ ). At the end, for each dataset, we sample 1000 random test molecules as the final test set. Thus, the splits contain 106586/13323/1000 and 243473/30433/1000 molecules for GEOM-QM9 and GEOM-DRUGS, resp. ",
975
+ "bbox": [
976
+ 174,
977
+ 827,
978
+ 825,
979
+ 911
980
+ ],
981
+ "page_idx": 7
982
+ },
983
+ {
984
+ "type": "image",
985
+ "img_path": "images/d9a3a42a0435d2a5af6926bc026d2e53b2ef8602c5a945d51409bebd6826261f.jpg",
986
+ "image_caption": [
987
+ "Figure 7: Left: Examples of generated structures. For every model, we show the best generated conformer, i.e., with the smallest RMSD to the shown ground truth. More examples are in appendix $\\mathbb { N } .$ Right/top: Number of rotatable bonds per DRUGS test molecule versus COV Recall ( $9 5 \\%$ confidence intervals). Right/bottom: conformer generation times for each model. "
988
+ ],
989
+ "image_footnote": [],
990
+ "bbox": [
991
+ 155,
992
+ 85,
993
+ 825,
994
+ 361
995
+ ],
996
+ "page_idx": 8
997
+ },
998
+ {
999
+ "type": "text",
1000
+ "text": "Baselines. We compare to established or recent baselines (discussed in section 1). ETKDG/RDKit [Riniker and Landrum, $\\boxed { 2 0 1 5 } \\|$ is likely the most popular open-source software, a stochastic DG-based method developed in the RDKit package. OMEGA [Hawkins et al., 2010, Hawkins and Nicholls, 2012, Friedrich et al., 2017], a rule-based method, is one of the most established commercial software, with more than a decade of continuous development. OMEGA and ETKDG are some of the fastest and best scaling existing approaches. Finally, we compare with the recent ML models of highest reported quality: GraphDG [Simm and Hernandez-Lobato, $\\underline { 2 0 2 0 } \\|$ and CGCF [Xu et al., 2021]. ",
1001
+ "bbox": [
1002
+ 173,
1003
+ 458,
1004
+ 826,
1005
+ 559
1006
+ ],
1007
+ "page_idx": 8
1008
+ },
1009
+ {
1010
+ "type": "text",
1011
+ "text": "Evaluation metrics. We follow prior work [Simm and Hernandez-Lobato, 2020, Xu et al., 2021] and use root-mean-square deviation of atomic positions (RMSD) to compare any two conformers. This is defined as the normalized Frobenius norm of the two corresponding matrices of 3D coordinates after being SE(3)-aligned a priori (using the Kabsch alignment algorithm $\\pm \\pm \\mathrm { { \\mathbb { K } a b s c h } } \\mathrm { { \\mathbb { 1 9 7 6 } } } \\mathrm { { \\mathrm { I } } } .$ ). Next, we introduce four types of metrics to compare two conformer ensembles, generated by a method, $\\{ \\mathcal { C } _ { k } \\} _ { k \\in [ 1 \\ldots K ] }$ , and ground truth, $\\{ \\mathcal { C } _ { l } ^ { * } \\} _ { l \\in [ 1 , . . L ] }$ . These metrics follow the established classification metrics of Precision and Recall and are defined for a given threshold $\\delta > 0$ as: ",
1012
+ "bbox": [
1013
+ 176,
1014
+ 570,
1015
+ 825,
1016
+ 667
1017
+ ],
1018
+ "page_idx": 8
1019
+ },
1020
+ {
1021
+ "type": "equation",
1022
+ "img_path": "images/8035867125fcd0e90997c8e82d337307172cd6fbf1625bf9e0d0c20472572235.jpg",
1023
+ "text": "$$\n\\begin{array} { l } { \\displaystyle \\mathrm { C O V - R } ( \\mathrm { R e c a l l } ) \\stackrel { \\mathrm { d e f } } { = } \\frac { 1 } { L } | \\{ l \\in [ 1 . . L ] : \\exists k \\in [ 1 . . K ] , R M S D ( \\mathscr { C } _ { k } , \\mathscr { C } _ { l } ^ { * } ) < \\delta \\} | } \\\\ { \\displaystyle \\mathrm { A M R - R } ( \\mathrm { R e c a l l } ) \\stackrel { \\mathrm { d e f } } { = } \\frac { 1 } { L } \\sum _ { l \\in [ 1 . . L ] } \\underset { k \\in [ 1 . . K ] } { \\operatorname* { m i n } } R M S D ( \\mathscr { C } _ { k } , \\mathscr { C } _ { l } ^ { * } ) } \\end{array}\n$$",
1024
+ "text_format": "latex",
1025
+ "bbox": [
1026
+ 254,
1027
+ 669,
1028
+ 740,
1029
+ 739
1030
+ ],
1031
+ "page_idx": 8
1032
+ },
1033
+ {
1034
+ "type": "text",
1035
+ "text": "where AMR is \"Average Minimum RMSD\", COV is \"Coverage\", and $C O V - P$ (Precision) and AMR - $P$ (Precision) are defined as in eq. $\\textcircled{5}$ , but with the generated and ground truth conformer sets swapped. The recall metrics measure how many of the ground truth conformers are correctly predicted, while the precision metrics indicate how many generated structures are of high quality. Specifically, in terms of recall, COV measures the percentage of correct generated conformers from the ground truth set (where a correct conformer is defined as one within an RMSD threshold of the true conformer), while AMR measures the average RMSD of each generated conformer with its closest groun truth match. Depending on the application, either of the metrics might be of greater interest. We follow Xu et al. [2021] and set $\\delta = 0 . { \\overset { - } { 5 } } { \\overset { \\circ } { \\mathrm { A } } }$ for GEOM-QM9 and $\\delta = 1 . 2 \\bar { 5 } \\mathring \\mathrm { A }$ for GEOM-DRUGS. ",
1036
+ "bbox": [
1037
+ 173,
1038
+ 742,
1039
+ 826,
1040
+ 869
1041
+ ],
1042
+ "page_idx": 8
1043
+ },
1044
+ {
1045
+ "type": "text",
1046
+ "text": "Training and test details. For each input molecule having $K$ ground truth conformers, we generate exactly $2 K$ conformers using any of the considered methods. For GEOMOL, this is done by sampling different random noise vectors that are appended to node and edge features before the MPNN (eq. $\\mathbb { \\underline { { \\left( \\mathrm { 1 } \\right) } } }$ ). At train time, our model uses a standard deviation (std) $s$ (see eq. $( 1 )$ ) of 5 for both GEOM-QM9 and GEOM-DRUGS. At test time, GEOMOL can use the same or different $s$ values, depending on the downstream application, i.e., higher $s$ results in more diverse conformers, while lower $s$ gives more quality (better precision). For OMEGA, it is not possible to specify a desired number of conformers. So, we tune the RMSD threshold (which decides how many conformers to keep) such that the total generated conformers by OMEGA are approximately $2 K$ . For GEOM-QM9, this corresponds to no RMSD cutoff (i.e., OMEGA generates all possible conformers), and for GEOM-DRUGS, this corresponds to a cutoff of $0 . 7 \\mathring \\mathrm { A }$ (meaning no two generated conformers will have a distance smaller than this cutoff). We discuss hyper-parameters and additional training details in appendix H. ",
1047
+ "bbox": [
1048
+ 173,
1049
+ 882,
1050
+ 823,
1051
+ 911
1052
+ ],
1053
+ "page_idx": 8
1054
+ },
1055
+ {
1056
+ "type": "text",
1057
+ "text": "",
1058
+ "bbox": [
1059
+ 174,
1060
+ 90,
1061
+ 825,
1062
+ 231
1063
+ ],
1064
+ "page_idx": 9
1065
+ },
1066
+ {
1067
+ "type": "text",
1068
+ "text": "Results & discussion. Results are shown in table $^ 1$ and table $2 ,$ and confidence intervals are in appendix $\\mathbb { L }$ As noted above, GEOMOL can be run with different noise std at test time, depending on which metric the user is interested in. Even though OMEGA is an established commercial software with more than a decade of continuous development, our model remarkably frequently outperforms it. Note that OMEGA fails to generate any conformers for $7 \\%$ of the QM9 test set (many of which include fused rings). Moreover, we also outperform the popular RDKit/ETKDG open-source model (except for AMR-P on QM9) and very recent ML models such as GraphDG and CGCF, sometimes by a large margin. For a qualitative insight, we show generated examples in fig. 7 and appendix N. ",
1069
+ "bbox": [
1070
+ 174,
1071
+ 244,
1072
+ 825,
1073
+ 357
1074
+ ],
1075
+ "page_idx": 9
1076
+ },
1077
+ {
1078
+ "type": "text",
1079
+ "text": "Additionally, we show in fig. $\\perp$ how COV Recall results are affected by the increasing number of rotatable bonds in the test molecule. As expected, having more rotatable bonds makes the problem harder, and this affects all baselines, but GEOMOL maintains a reasonable coverage even for more difficult molecules. Moreover, in appendix K and table 8 we show energy calculations of the generated conformers to support their plausibility. Additionally, results with energy-based relaxations are given in appendix J. ",
1080
+ "bbox": [
1081
+ 174,
1082
+ 363,
1083
+ 825,
1084
+ 446
1085
+ ],
1086
+ "page_idx": 9
1087
+ },
1088
+ {
1089
+ "type": "text",
1090
+ "text": "Running time. Fig. 7 shows conformer generation test running times. Our model is the fastest method from the considered baselines, being much faster than CGCF or ETKDG/RDKit. Moreover, GEOMOL scales favorably for molecules with increasing number of rotatable bonds. ",
1091
+ "bbox": [
1092
+ 176,
1093
+ 460,
1094
+ 825,
1095
+ 503
1096
+ ],
1097
+ "page_idx": 9
1098
+ },
1099
+ {
1100
+ "type": "text",
1101
+ "text": "4 Conclusion ",
1102
+ "text_level": 1,
1103
+ "bbox": [
1104
+ 174,
1105
+ 522,
1106
+ 299,
1107
+ 539
1108
+ ],
1109
+ "page_idx": 9
1110
+ },
1111
+ {
1112
+ "type": "text",
1113
+ "text": "We proposed GEOMOL, an end-to-end generative approach for molecular 3D conformation ensembles that explicitly models various molecular geometric aspects such as torsion angles or chirality. We expect that such differentiable structure generators will significantly impact small molecule conformer generation along with many related applications (e.g., protein-ligand binding), thus speeding up areas such as drug discovery. GEOMOL’s full source code will be made publicly available. ",
1114
+ "bbox": [
1115
+ 174,
1116
+ 553,
1117
+ 825,
1118
+ 622
1119
+ ],
1120
+ "page_idx": 9
1121
+ },
1122
+ {
1123
+ "type": "text",
1124
+ "text": "Limitations & future work. A few current limitations are highlighted and left for future extensions (see also discussion in appendix $\\bigstar$ . First, our model does not currently support disconnected molecular graphs, e.g., ionic salts, but it can be applied to each connected component, followed by a 3D alignment. Next, our approach would benefit from explicit modeling of long distance interactions, especially for macrocycles or large molecules. This remains to be addressed in an efficient manner. Third, explicitly using ground truth energy values could further improve GEOMOL. Last, we look forward to fine-tune GEOMOL on applications such as generating molecular docking poses or descriptors for 4D QSAR. ",
1125
+ "bbox": [
1126
+ 174,
1127
+ 637,
1128
+ 825,
1129
+ 750
1130
+ ],
1131
+ "page_idx": 9
1132
+ },
1133
+ {
1134
+ "type": "text",
1135
+ "text": "Acknowledgments and Disclosure of Funding ",
1136
+ "text_level": 1,
1137
+ "bbox": [
1138
+ 174,
1139
+ 767,
1140
+ 553,
1141
+ 785
1142
+ ],
1143
+ "page_idx": 9
1144
+ },
1145
+ {
1146
+ "type": "text",
1147
+ "text": "OEG thanks Bracha Laufer, Tian Xie, Xiang Fu, Peter Mikhael, and the rest of the RB and TJ group members for their helpful comments and suggestions. LP thanks Camille Bilodeau and the rest of the WHG, KFJ, and CWC research groups for their useful discussions. We also thank Pat Walters, Simon Axelrod, and Rafael Gomez-Bombarelli for their insightful feedback as well as Minkai Xu and Shitong Luo for helping run the CGCF model. Both OEG and LP are funded by the Machine Learning for Pharmaceutical Discovery and Synthesis consortium. ",
1148
+ "bbox": [
1149
+ 174,
1150
+ 799,
1151
+ 825,
1152
+ 883
1153
+ ],
1154
+ "page_idx": 9
1155
+ },
1156
+ {
1157
+ "type": "text",
1158
+ "text": "References ",
1159
+ "text_level": 1,
1160
+ "bbox": [
1161
+ 174,
1162
+ 89,
1163
+ 267,
1164
+ 106
1165
+ ],
1166
+ "page_idx": 10
1167
+ },
1168
+ {
1169
+ "type": "text",
1170
+ "text": "Mohammed AlQuraishi. End-to-end differentiable learning of protein structure. Cell systems, 8(4): 292–301, 2019. ",
1171
+ "bbox": [
1172
+ 173,
1173
+ 113,
1174
+ 823,
1175
+ 142
1176
+ ],
1177
+ "page_idx": 10
1178
+ },
1179
+ {
1180
+ "type": "text",
1181
+ "text": "Simon Axelrod and Rafael Gomez-Bombarelli. Geom: Energy-annotated molecular conformations for property prediction and molecular generation. arXiv preprint arXiv:2006.05531, 2020a. ",
1182
+ "bbox": [
1183
+ 173,
1184
+ 150,
1185
+ 823,
1186
+ 179
1187
+ ],
1188
+ "page_idx": 10
1189
+ },
1190
+ {
1191
+ "type": "text",
1192
+ "text": "Simon Axelrod and Rafael Gomez-Bombarelli. Molecular machine learning with conformer ensembles. arXiv preprint arXiv:2012.08452, 2020b. ",
1193
+ "bbox": [
1194
+ 173,
1195
+ 188,
1196
+ 823,
1197
+ 217
1198
+ ],
1199
+ "page_idx": 10
1200
+ },
1201
+ {
1202
+ "type": "text",
1203
+ "text": "Andrew J Ballard, Stefano Martiniani, Jacob D Stevenson, Sandeep Somani, and David J Wales. Exploiting the potential energy landscape to sample free energy. Wiley Interdisciplinary Reviews: Computational Molecular Science, 5(3):273–289, 2015. ",
1204
+ "bbox": [
1205
+ 174,
1206
+ 224,
1207
+ 825,
1208
+ 267
1209
+ ],
1210
+ "page_idx": 10
1211
+ },
1212
+ {
1213
+ "type": "text",
1214
+ "text": "Arghya Barman, Bruce Batiste, and Donald Hamelberg. Pushing the limits of a molecular mechanics force field to probe weak ch··· $\\pi$ interactions in proteins. Journal of chemical theory and computation, 11(4):1854–1863, 2015. ",
1215
+ "bbox": [
1216
+ 176,
1217
+ 275,
1218
+ 823,
1219
+ 318
1220
+ ],
1221
+ "page_idx": 10
1222
+ },
1223
+ {
1224
+ "type": "text",
1225
+ "text": "Peter W Battaglia, Jessica B Hamrick, Victor Bapst, Alvaro Sanchez-Gonzalez, Vinicius Zambaldi, Mateusz Malinowski, Andrea Tacchetti, David Raposo, Adam Santoro, Ryan Faulkner, et al. Relational inductive biases, deep learning, and graph networks. arXiv preprint arXiv:1806.01261, 2018. ",
1226
+ "bbox": [
1227
+ 173,
1228
+ 325,
1229
+ 826,
1230
+ 382
1231
+ ],
1232
+ "page_idx": 10
1233
+ },
1234
+ {
1235
+ "type": "text",
1236
+ "text": "Lucian Chan, Garrett M Morris, and Geoffrey R Hutchison. Understanding conformational entropy in small molecules. Journal of Chemical Theory and Computation, 17(4):2099–2106, 2021. ",
1237
+ "bbox": [
1238
+ 169,
1239
+ 390,
1240
+ 825,
1241
+ 420
1242
+ ],
1243
+ "page_idx": 10
1244
+ },
1245
+ {
1246
+ "type": "text",
1247
+ "text": "Gordon M Crippen, Timothy F Havel, et al. Distance geometry and molecular conformation, volume 74. Research Studies Press Taunton, 1988. ",
1248
+ "bbox": [
1249
+ 171,
1250
+ 428,
1251
+ 825,
1252
+ 458
1253
+ ],
1254
+ "page_idx": 10
1255
+ },
1256
+ {
1257
+ "type": "text",
1258
+ "text": "Marco De Vivo, Matteo Masetti, Giovanni Bottegoni, and Andrea Cavalli. Role of molecular dynamics and related methods in drug discovery. Journal of medicinal chemistry, 59(9):4035–4061, 2016. ",
1259
+ "bbox": [
1260
+ 171,
1261
+ 465,
1262
+ 823,
1263
+ 496
1264
+ ],
1265
+ "page_idx": 10
1266
+ },
1267
+ {
1268
+ "type": "text",
1269
+ "text": "Rémi Flamary and Nicolas Courty. Pot python optimal transport library. GitHub: https://github. com/rflamary/POT, 2017. ",
1270
+ "bbox": [
1271
+ 169,
1272
+ 502,
1273
+ 825,
1274
+ 531
1275
+ ],
1276
+ "page_idx": 10
1277
+ },
1278
+ {
1279
+ "type": "text",
1280
+ "text": "Nils-Ole Friedrich, Christina de Bruyn Kops, Florian Flachsenberg, Kai Sommer, Matthias Rarey, and Johannes Kirchmair. Benchmarking commercial conformer ensemble generators. Journal of chemical information and modeling, 57(11):2719–2728, 2017. ",
1281
+ "bbox": [
1282
+ 173,
1283
+ 540,
1284
+ 825,
1285
+ 583
1286
+ ],
1287
+ "page_idx": 10
1288
+ },
1289
+ {
1290
+ "type": "text",
1291
+ "text": "Pablo Gainza, Freyr Sverrisson, Frederico Monti, Emanuele Rodola, D Boscaini, MM Bronstein, and BE Correia. Deciphering interaction fingerprints from protein molecular surfaces using geometric deep learning. Nature Methods, 17(2):184–192, 2020. ",
1292
+ "bbox": [
1293
+ 174,
1294
+ 590,
1295
+ 825,
1296
+ 633
1297
+ ],
1298
+ "page_idx": 10
1299
+ },
1300
+ {
1301
+ "type": "text",
1302
+ "text": "Vikas Garg, Stefanie Jegelka, and Tommi Jaakkola. Generalization and representational limits of graph neural networks. In International Conference on Machine Learning, pages 3419–3430. PMLR, 2020. ",
1303
+ "bbox": [
1304
+ 173,
1305
+ 641,
1306
+ 825,
1307
+ 684
1308
+ ],
1309
+ "page_idx": 10
1310
+ },
1311
+ {
1312
+ "type": "text",
1313
+ "text": "Justin Gilmer, Samuel S Schoenholz, Patrick F Riley, Oriol Vinyals, and George E Dahl. Neural message passing for quantum chemistry. In Proceedings of the 34th International Conference on Machine Learning-Volume 70, pages 1263–1272. JMLR. org, 2017. ",
1314
+ "bbox": [
1315
+ 171,
1316
+ 693,
1317
+ 823,
1318
+ 736
1319
+ ],
1320
+ "page_idx": 10
1321
+ },
1322
+ {
1323
+ "type": "text",
1324
+ "text": "Stefan Grimme. Exploration of chemical compound, conformer, and reaction space with metadynamics simulations based on tight-binding quantum chemical calculations. Journal of chemical theory and computation, 15(5):2847–2862, 2019. ",
1325
+ "bbox": [
1326
+ 173,
1327
+ 743,
1328
+ 823,
1329
+ 786
1330
+ ],
1331
+ "page_idx": 10
1332
+ },
1333
+ {
1334
+ "type": "text",
1335
+ "text": "Cristiano RW Guimaraes, Alan M Mathiowetz, Marina Shalaeva, Gilles Goetz, and Spiros Liras. Use of 3d properties to characterize beyond rule-of-5 property space for passive permeation. Journal of chemical information and modeling, 52(4):882–890, 2012. ",
1336
+ "bbox": [
1337
+ 173,
1338
+ 795,
1339
+ 826,
1340
+ 837
1341
+ ],
1342
+ "page_idx": 10
1343
+ },
1344
+ {
1345
+ "type": "text",
1346
+ "text": "Thomas A Halgren. Merck molecular force field. i. basis, form, scope, parameterization, and performance of mmff94. Journal of computational chemistry, 17(5-6):490–519, 1996. ",
1347
+ "bbox": [
1348
+ 173,
1349
+ 845,
1350
+ 823,
1351
+ 875
1352
+ ],
1353
+ "page_idx": 10
1354
+ },
1355
+ {
1356
+ "type": "text",
1357
+ "text": "Thomas A Halgren. Mmff vi. mmff94s option for energy minimization studies. Journal of Computational Chemistry, 20(7):720–729, 1999. ",
1358
+ "bbox": [
1359
+ 173,
1360
+ 882,
1361
+ 823,
1362
+ 911
1363
+ ],
1364
+ "page_idx": 10
1365
+ },
1366
+ {
1367
+ "type": "text",
1368
+ "text": "William L Hamilton, Rex Ying, and Jure Leskovec. Inductive representation learning on large graphs. In Proceedings of the 31st International Conference on Neural Information Processing Systems, pages 1025–1035, 2017. ",
1369
+ "bbox": [
1370
+ 173,
1371
+ 90,
1372
+ 825,
1373
+ 133
1374
+ ],
1375
+ "page_idx": 11
1376
+ },
1377
+ {
1378
+ "type": "text",
1379
+ "text": "Timothy F Havel. Distance geometry: Theory, algorithms, and chemical applications. Encyclopedia of Computational Chemistry, 120:723–742, 1998. ",
1380
+ "bbox": [
1381
+ 169,
1382
+ 143,
1383
+ 825,
1384
+ 172
1385
+ ],
1386
+ "page_idx": 11
1387
+ },
1388
+ {
1389
+ "type": "text",
1390
+ "text": "Timothy F Havel, Gordon M Crippen, Irwin D Kuntz, and Jeffrey M Blaney. The combinatorial distance geometry method for the calculation of molecular conformation ii. sample problems and computational statistics. Journal of theoretical biology, 104(3):383–400, 1983a. ",
1391
+ "bbox": [
1392
+ 174,
1393
+ 181,
1394
+ 826,
1395
+ 224
1396
+ ],
1397
+ "page_idx": 11
1398
+ },
1399
+ {
1400
+ "type": "text",
1401
+ "text": "Timothy F Havel, Irwin D Kuntz, and Gordon M Crippen. The combinatorial distance geometry method for the calculation of molecular conformation. i. a new approach to an old problem. Journal of theoretical biology, 104(3):359–381, 1983b. ",
1402
+ "bbox": [
1403
+ 174,
1404
+ 233,
1405
+ 825,
1406
+ 276
1407
+ ],
1408
+ "page_idx": 11
1409
+ },
1410
+ {
1411
+ "type": "text",
1412
+ "text": "Paul CD Hawkins. Conformation generation: the state of the art. Journal of Chemical Information and Modeling, 57(8):1747–1756, 2017. ",
1413
+ "bbox": [
1414
+ 173,
1415
+ 286,
1416
+ 825,
1417
+ 314
1418
+ ],
1419
+ "page_idx": 11
1420
+ },
1421
+ {
1422
+ "type": "text",
1423
+ "text": "Paul CD Hawkins and Anthony Nicholls. Conformer generation with omega: learning from the data set and the analysis of failures. Journal of chemical information and modeling, 52(11):2919–2936, 2012. ",
1424
+ "bbox": [
1425
+ 173,
1426
+ 324,
1427
+ 826,
1428
+ 366
1429
+ ],
1430
+ "page_idx": 11
1431
+ },
1432
+ {
1433
+ "type": "text",
1434
+ "text": "Paul CD Hawkins, A Geoffrey Skillman, Gregory L Warren, Benjamin A Ellingson, and Matthew T Stahl. Conformer generation with omega: algorithm and validation using high quality structures from the protein databank and cambridge structural database. Journal of chemical information and modeling, 50(4):572–584, 2010. ",
1435
+ "bbox": [
1436
+ 173,
1437
+ 376,
1438
+ 825,
1439
+ 433
1440
+ ],
1441
+ "page_idx": 11
1442
+ },
1443
+ {
1444
+ "type": "text",
1445
+ "text": "John Ingraham, Adam Riesselman, Chris Sander, and Debora Marks. Learning protein structure with a differentiable simulator. In International Conference on Learning Representations, 2018. ",
1446
+ "bbox": [
1447
+ 171,
1448
+ 443,
1449
+ 823,
1450
+ 472
1451
+ ],
1452
+ "page_idx": 11
1453
+ },
1454
+ {
1455
+ "type": "text",
1456
+ "text": "Wolfgang Kabsch. A solution for the best rotation to relate two sets of vectors. Acta Crystallographica Section A: Crystal Physics, Diffraction, Theoretical and General Crystallography, 32(5):922–923, 1976. ",
1457
+ "bbox": [
1458
+ 174,
1459
+ 481,
1460
+ 826,
1461
+ 523
1462
+ ],
1463
+ "page_idx": 11
1464
+ },
1465
+ {
1466
+ "type": "text",
1467
+ "text": "Ilana Y Kanal, John A Keith, and Geoffrey R Hutchison. A sobering assessment of small-molecule force field methods for low energy conformer predictions. International Journal of Quantum Chemistry, 118(5):e25512, 2018. ",
1468
+ "bbox": [
1469
+ 173,
1470
+ 534,
1471
+ 826,
1472
+ 577
1473
+ ],
1474
+ "page_idx": 11
1475
+ },
1476
+ {
1477
+ "type": "text",
1478
+ "text": "Thomas N Kipf and Max Welling. Semi-supervised classification with graph convolutional networks. International Conference on Learning Representations (ICLR), 2017. ",
1479
+ "bbox": [
1480
+ 174,
1481
+ 585,
1482
+ 823,
1483
+ 616
1484
+ ],
1485
+ "page_idx": 11
1486
+ },
1487
+ {
1488
+ "type": "text",
1489
+ "text": "Johannes Klicpera, Janek Groß, and Stephan Günnemann. Directional message passing for molecular graphs. In International Conference on Learning Representations, 2019. ",
1490
+ "bbox": [
1491
+ 173,
1492
+ 623,
1493
+ 823,
1494
+ 654
1495
+ ],
1496
+ "page_idx": 11
1497
+ },
1498
+ {
1499
+ "type": "text",
1500
+ "text": "Ashutosh Kumar and Kam YJ Zhang. Advances in the development of shape similarity methods and their application in drug discovery. Frontiers in chemistry, 6:315, 2018. ",
1501
+ "bbox": [
1502
+ 173,
1503
+ 662,
1504
+ 825,
1505
+ 691
1506
+ ],
1507
+ "page_idx": 11
1508
+ },
1509
+ {
1510
+ "type": "text",
1511
+ "text": "David Lagorce, Tania Pencheva, Bruno O Villoutreix, and Maria A Miteva. Dg-ammos: A new tool to generate 3d conformation of small molecules using d istance g eometry and a utomated m olecular m echanics o ptimization for in silico s creening. BMC Chemical Biology, 9(1):1–10, 2009. ",
1512
+ "bbox": [
1513
+ 173,
1514
+ 700,
1515
+ 826,
1516
+ 757
1517
+ ],
1518
+ "page_idx": 11
1519
+ },
1520
+ {
1521
+ "type": "text",
1522
+ "text": "Dominik Lemm, Guido Falk von Rudorff, and O Anatole von Lilienfeld. Energy-free machine learning predictions of ab initio structures. arXiv preprint arXiv:2102.02806, 2021. ",
1523
+ "bbox": [
1524
+ 171,
1525
+ 767,
1526
+ 823,
1527
+ 796
1528
+ ],
1529
+ "page_idx": 11
1530
+ },
1531
+ {
1532
+ "type": "text",
1533
+ "text": "Yi Liu, Limei Wang, Meng Liu, Xuan Zhang, Bora Oztekin, and Shuiwang Ji. Spherical message passing for 3d graph networks. arXiv preprint arXiv:2102.05013, 2021. ",
1534
+ "bbox": [
1535
+ 173,
1536
+ 805,
1537
+ 825,
1538
+ 835
1539
+ ],
1540
+ "page_idx": 11
1541
+ },
1542
+ {
1543
+ "type": "text",
1544
+ "text": "Elman Mansimov, Omar Mahmood, Seokho Kang, and Kyunghyun Cho. Molecular geometry prediction using a deep generative graph neural network. Scientific reports, 9(1):1–13, 2019. ",
1545
+ "bbox": [
1546
+ 173,
1547
+ 844,
1548
+ 823,
1549
+ 873
1550
+ ],
1551
+ "page_idx": 11
1552
+ },
1553
+ {
1554
+ "type": "text",
1555
+ "text": "Mark McGann. Fred pose prediction and virtual screening accuracy. Journal of chemical information and modeling, 51(3):578–596, 2011. ",
1556
+ "bbox": [
1557
+ 173,
1558
+ 883,
1559
+ 821,
1560
+ 911
1561
+ ],
1562
+ "page_idx": 11
1563
+ },
1564
+ {
1565
+ "type": "text",
1566
+ "text": "Frank Noé, Simon Olsson, Jonas Köhler, and Hao Wu. Boltzmann generators: Sampling equilibrium states of many-body systems with deep learning. Science, 365(6457), 2019. ",
1567
+ "bbox": [
1568
+ 171,
1569
+ 90,
1570
+ 823,
1571
+ 119
1572
+ ],
1573
+ "page_idx": 12
1574
+ },
1575
+ {
1576
+ "type": "text",
1577
+ "text": "Lagnajit Pattanaik, Octavian E Ganea, Ian Coley, Klavs F Jensen, William H Green, and Connor W Coley. Message passing networks for molecules with tetrahedral chirality. arXiv preprint arXiv:2012.00094, 2020a. ",
1578
+ "bbox": [
1579
+ 173,
1580
+ 126,
1581
+ 821,
1582
+ 169
1583
+ ],
1584
+ "page_idx": 12
1585
+ },
1586
+ {
1587
+ "type": "text",
1588
+ "text": "Lagnajit Pattanaik, John B Ingraham, Colin A Grambow, and William H Green. Generating transition states of isomerization reactions with deep learning. Physical Chemistry Chemical Physics, 22 (41):23618–23626, 2020b. ",
1589
+ "bbox": [
1590
+ 173,
1591
+ 175,
1592
+ 823,
1593
+ 218
1594
+ ],
1595
+ "page_idx": 12
1596
+ },
1597
+ {
1598
+ "type": "text",
1599
+ "text": "Raghunathan Ramakrishnan, Pavlo O Dral, Matthias Rupp, and O Anatole Von Lilienfeld. Quantum chemistry structures and properties of 134 kilo molecules. Scientific data, 1(1):1–7, 2014. ",
1600
+ "bbox": [
1601
+ 171,
1602
+ 224,
1603
+ 823,
1604
+ 255
1605
+ ],
1606
+ "page_idx": 12
1607
+ },
1608
+ {
1609
+ "type": "text",
1610
+ "text": "Anthony K Rappé, Carla J Casewit, KS Colwell, William A Goddard III, and W Mason Skiff. Uff, a full periodic table force field for molecular mechanics and molecular dynamics simulations. Journal of the American chemical society, 114(25):10024–10035, 1992. ",
1611
+ "bbox": [
1612
+ 173,
1613
+ 260,
1614
+ 826,
1615
+ 303
1616
+ ],
1617
+ "page_idx": 12
1618
+ },
1619
+ {
1620
+ "type": "text",
1621
+ "text": "Sereina Riniker and Gregory A Landrum. Better informed distance geometry: using what we know to improve conformation generation. Journal of chemical information and modeling, 55(12): 2562–2574, 2015. ",
1622
+ "bbox": [
1623
+ 173,
1624
+ 309,
1625
+ 826,
1626
+ 352
1627
+ ],
1628
+ "page_idx": 12
1629
+ },
1630
+ {
1631
+ "type": "text",
1632
+ "text": "Kristof T Schütt, Huziel E Sauceda, P-J Kindermans, Alexandre Tkatchenko, and K-R Müller. Schnet–a deep learning architecture for molecules and materials. The Journal of Chemical Physics, 148(24):241722, 2018. ",
1633
+ "bbox": [
1634
+ 173,
1635
+ 358,
1636
+ 826,
1637
+ 401
1638
+ ],
1639
+ "page_idx": 12
1640
+ },
1641
+ {
1642
+ "type": "text",
1643
+ "text": "Kristof T Schütt, Oliver T Unke, and Michael Gastegger. Equivariant message passing for the prediction of tensorial properties and molecular spectra. arXiv preprint arXiv:2102.03150, 2021. ",
1644
+ "bbox": [
1645
+ 173,
1646
+ 409,
1647
+ 823,
1648
+ 438
1649
+ ],
1650
+ "page_idx": 12
1651
+ },
1652
+ {
1653
+ "type": "text",
1654
+ "text": "Christof H Schwab. Conformations and 3d pharmacophore searching. Drug Discovery Today: Technologies, 7(4):e245–e253, 2010. ",
1655
+ "bbox": [
1656
+ 169,
1657
+ 444,
1658
+ 825,
1659
+ 473
1660
+ ],
1661
+ "page_idx": 12
1662
+ },
1663
+ {
1664
+ "type": "text",
1665
+ "text": "Andrew W Senior, Richard Evans, John Jumper, James Kirkpatrick, Laurent Sifre, Tim Green, Chongli Qin, Augustin Žídek, Alexander WR Nelson, Alex Bridgland, et al. Improved protein structure prediction using potentials from deep learning. Nature, 577(7792):706–710, 2020. ",
1666
+ "bbox": [
1667
+ 176,
1668
+ 478,
1669
+ 825,
1670
+ 523
1671
+ ],
1672
+ "page_idx": 12
1673
+ },
1674
+ {
1675
+ "type": "text",
1676
+ "text": "Jihyun Shim and Alexander D MacKerell Jr. Computational ligand-based rational design: role of conformational sampling and force fields in model development. MedChemComm, 2(5):356–370, 2011. ",
1677
+ "bbox": [
1678
+ 174,
1679
+ 530,
1680
+ 823,
1681
+ 571
1682
+ ],
1683
+ "page_idx": 12
1684
+ },
1685
+ {
1686
+ "type": "text",
1687
+ "text": "Gregor Simm and Jose Miguel Hernandez-Lobato. A generative model for molecular distance geometry. In International Conference on Machine Learning, pages 8949–8958. PMLR, 2020. ",
1688
+ "bbox": [
1689
+ 171,
1690
+ 579,
1691
+ 823,
1692
+ 608
1693
+ ],
1694
+ "page_idx": 12
1695
+ },
1696
+ {
1697
+ "type": "text",
1698
+ "text": "Freyr Sverrisson, Jean Feydy, Bruno Correia, and Michael Bronstein. Fast end-to-end learning on protein surfaces. bioRxiv, 2020. ",
1699
+ "bbox": [
1700
+ 171,
1701
+ 614,
1702
+ 823,
1703
+ 643
1704
+ ],
1705
+ "page_idx": 12
1706
+ },
1707
+ {
1708
+ "type": "text",
1709
+ "text": "Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Łukasz Kaiser, and Illia Polosukhin. Attention is all you need. In Proceedings of the 31st International Conference on Neural Information Processing Systems, pages 6000–6010, 2017. ",
1710
+ "bbox": [
1711
+ 174,
1712
+ 650,
1713
+ 823,
1714
+ 694
1715
+ ],
1716
+ "page_idx": 12
1717
+ },
1718
+ {
1719
+ "type": "text",
1720
+ "text": "Petar Velickovi ˇ c, Guillem Cucurull, Arantxa Casanova, Adriana Romero, Pietro Lio, and Yoshua ´ Bengio. Graph attention networks. arXiv preprint arXiv:1710.10903, 2017. ",
1721
+ "bbox": [
1722
+ 173,
1723
+ 699,
1724
+ 823,
1725
+ 729
1726
+ ],
1727
+ "page_idx": 12
1728
+ },
1729
+ {
1730
+ "type": "text",
1731
+ "text": "Jitender Verma, Vijay M Khedkar, and Evans C Coutinho. 3d-qsar in drug design-a review. Current topics in medicinal chemistry, 10(1):95–115, 2010. ",
1732
+ "bbox": [
1733
+ 174,
1734
+ 734,
1735
+ 823,
1736
+ 765
1737
+ ],
1738
+ "page_idx": 12
1739
+ },
1740
+ {
1741
+ "type": "text",
1742
+ "text": "Keyulu Xu, Weihua Hu, Jure Leskovec, and Stefanie Jegelka. How powerful are graph neural networks? International Conference on Learning Representations (ICLR), 2019. ",
1743
+ "bbox": [
1744
+ 174,
1745
+ 770,
1746
+ 821,
1747
+ 800
1748
+ ],
1749
+ "page_idx": 12
1750
+ },
1751
+ {
1752
+ "type": "text",
1753
+ "text": "Minkai Xu, Shitong Luo, Yoshua Bengio, Jian Peng, and Jian Tang. Learning neural generative dynamics for molecular conformation generation. International Conference on Learning Representations (ICLR), 2021. ",
1754
+ "bbox": [
1755
+ 173,
1756
+ 806,
1757
+ 823,
1758
+ 848
1759
+ ],
1760
+ "page_idx": 12
1761
+ },
1762
+ {
1763
+ "type": "text",
1764
+ "text": "Kevin Yang, Kyle Swanson, Wengong Jin, Connor Coley, Philipp Eiden, Hua Gao, Angel GuzmanPerez, Timothy Hopper, Brian Kelley, Miriam Mathea, et al. Analyzing learned molecular representations for property prediction. Journal of chemical information and modeling, 59(8): 3370–3388, 2019. ",
1765
+ "bbox": [
1766
+ 174,
1767
+ 854,
1768
+ 826,
1769
+ 911
1770
+ ],
1771
+ "page_idx": 12
1772
+ }
1773
+ ]
parse/train/af_hng9tuNj/af_hng9tuNj_middle.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/af_hng9tuNj/af_hng9tuNj_model.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/rJg_NjCqtX/rJg_NjCqtX.md ADDED
@@ -0,0 +1,180 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # CHEMICAL NAMES STANDARDIZATION USING NEURAL SEQUENCE TO SEQUENCE MODEL
2
+
3
+ Anonymous authors Paper under double-blind review
4
+
5
+ # ABSTRACT
6
+
7
+ Chemical information extraction is to convert chemical knowledge in text into true chemical database, which is a text processing task heavily relying on chemical compound name identification and standardization. Once a systematic name for a chemical compound is given, it will naturally and much simply convert the name into the eventually required molecular formula. However, for many chemical substances, they have been shown in many other names besides their systematic names which poses a great challenge for this task. In this paper, we propose a framework to do the auto standardization from the non-systematic names to the corresponding systematic names by using the spelling error correction, byte pair encoding tokenization and neural sequence to sequence model. Our framework is trained end to end and is fully data-driven. Our standardization accuracy on the test dataset achieves $5 4 . 0 4 \%$ which has a great improvement compared to previous state-of-the-art result.
8
+
9
+ # 1 INTRODUCTION
10
+
11
+ There are more than 100 million named chemical substances in the world. In order to uniquely identify every chemical substance, there are elaborate rules for assigning names to them on the basis of their structures. These names are called systematic names. The rules for these names are defined by International Union of Pure and Applied Chemistry (IUPAC) (Favre & Powell, 2013).
12
+
13
+ However, besides the systematic name, there can be also many other names for a chemical substance due to many reasons. Firstly, many chemical are so much a part of our life that we know them by their familiar names which we call them common names or trivial names for the sake of simplicity. For example, sucrose is a kind of sugar which we are very familiar with. Its systematic name is much more complicated, which is (2R,3R,4S,5S,6R)-2-[(2S,3S,4S,5R)-3,4-dihydroxy-2,5- bis(hydroxymethyl)oxolan-2-yl]oxy-6-(hydroxymethyl)oxane-3,4,5-triol.
14
+
15
+ Secondly, in chemistry industry, especially in pharmaceutical industry, many producers always generate new names to a chemical substance in order to distinguish their products from those of their competitors. We call these kind of names proprietary names. The most famous example is Aspirin. Its systematic name is 2-Acetoxybenzoic acid. So due to the history reasons and idiomatic usages, a chemical substance can have many other names.
16
+
17
+ Chemical information extraction is a research that extracts useful chemical knowledge in text and converts it into a database, which strongly relies on the unique standard chemical names. Nowadays, there are many chemical databases such as PubChem and SciFinder, which are designed to store chemical information including chemical names, chemical structures, molecular formulas and other relevant information. For these databases, it is still an ongoing work to extract chemical information from chemical papers to update the databases. If all the chemical substances are expressed by the systematic names, it is easy to generate other information. For example, we can nearly perfectly convert the systematic name to other representations such as Simplified Molecular-Input Line-Entry System (SMILES) (Weininger, 1988) and International Chemical Identifier (InCHI) (Mcnaught, 2006) and then generate the structural formulas. Some online systems are already well developed for converting automatically systematic names to SMILES string with a very high precision such as Open Parser for Systematic IUPAC Nomenclature (OPSIN) (Lowe et al., 2011) developed by
18
+
19
+ Table 1: Examples of different types of error
20
+
21
+ <table><tr><td>Error type</td><td>Non-systematic name</td><td>Systematic name</td></tr><tr><td>Spelling error</td><td>benzoil chloride 1,3-benzoxazoole</td><td>benzoyl chloride 1,3-benzoxazole</td></tr><tr><td>Ordering error</td><td>benzene,1,4-dibromo-2-methyl 4-pyrimidinecarbaldehyde</td><td>1,4-dibromo-2-methylbenzene pyrimidine-4-carbaldehyde</td></tr><tr><td>Common name error</td><td>adenine Aspirin</td><td>9H-purin-6-amine 2-Acetoxybenzoic acid</td></tr><tr><td>Synonym error</td><td>sodiumbutoxide 2-ethylfuroate</td><td>sodium;butan-l-olate ethyl furan-2-carboxylate</td></tr><tr><td>Mixed of synonym error and ordering error</td><td>2-hydroxy-8-iodonaphthalene 3-amino-l,2-benzisoxazole</td><td>8-iodonaphthalen-2-ol 1,2-benzoxazol-3-amine</td></tr></table>
22
+
23
+ University of Cambridge1. Unfortunately, nowadays a great number of the chemical substances are expressed by their non-systematic names in chemical papers, which increases significantly the difficulties for this task, so our work focuses on the standardization of non-systematic names. Examples of chemical information extraction are shown in Figure 1.
24
+
25
+ ![](images/c8c2987bdcca2664b996abe7c17830a23caad95dc08d2bad34893ed854c2e311.jpg)
26
+ Figure 1: Examples of chemical information extraction (the parts in the same color means the same chemical constituent name)
27
+
28
+ In the following passage, we consider the differences between non-systematic names and systematic names as ”error”2. In view of natural language processing, the error types of non-systematic names can be summarized by four types: 1. Spelling error. It means that non-systematic names just have slightly differences from systematic names in spelling; 2. Ordering error. It means that the groups in a non-systematic name are in wrong order; 3. Common name error. As mentioned above, many chemical substances have common names or proprietary names which look totally different from their systematic names; 4. Synonym error. It means that the words in the nonsystematic names are different from those in the systematic names but they share the same root of word. In fact, it is the error type which happens most often. For example, 2-(Acetyloxy)benzoic Acid has synonyms Acetylsalicylic Acid and Acetysal and these three words share the same root of word ”Acety”. Some examples of different types of errors are shown in Table 1. What is worth mentioning is that several types of error can appear at the same time in a single non-systematic name, especially for the ordering error and synonym error. The mixed types of error make this task very challenging.
29
+
30
+ Based on these four error types, we propose a framework to convert automatically the non-systematic names to systematic names. Our framework is structured as followed: 1. Spelling error correction. It aims to correct the spelling errors; 2. Byte pair encoding (BPE) tokenization. It aims to split a name into small parts; 3. Sequence to sequence model. It aims to fix all the remaining ordering errors, common name errors and synonym errors.
31
+
32
+ Actually, due to its great challenge, few work has been done on the chemical name standardization. To our best knowledge, Golebiewski et al. (2009) is the only work deserving a citation which developed an online system ChemHits to do the standardization basing on several transformation rules and the queries to online chemical databases. The work of Golebiewski et al. (2009) severely depends on chemical knowledge, limiting its application potential and effectiveness to some extent.
33
+
34
+ Differently, we adopt sequence to sequence model that has been widely used on neural machine translation. The reason why we apply the sequence to sequence model is that our task has some similarities with the machine translation problem. In machine translation, there are source language and target language which correspond to the non-systematic names and the systematic names in our task. Two different languages can be different in: 1. Vocabularies, which corresponds to the common name error and synonym error; 2. Word order, which corresponds to the ordering error. Our framework is trained end-to-end, fully data-driven and without using external chemical knowledge. With this approach, we achieve an accuracy of $5 4 . 0 4 \%$ in our test data set.
35
+
36
+ Our work will be done on a corpus containing chemical names extracted from report of Chemical Journals with High Impact factors $( \mathrm { C J H I F } ) ^ { 3 }$ . The corpus is collected and checked by paid manual work. It is a parallel corpus which includes non-systematic names and systematic names of chemical substances. In the following passage, we call a non-systematic name and the corresponding systematic name of a chemical substance data pair. In our corpus, there are 384816 data pairs. In Figure 2, we give an overview of the distribution of the Levenshtein distance between the non-systematic names and the systematic names to show how different the non-systematic names and the systematic names are. In the experiment, we use $80 \%$ , $19 \%$ and $1 \%$ data as training set, test set and development set respectively.
37
+
38
+ ![](images/145b0d281c8aec0ed89fd7e4549392abdba3398569b9c5d92e7160384dec1f5d.jpg)
39
+ Figure 2: Distribution of the Levenshtein distance between non-systematic names and systematic names
40
+
41
+ # 2 PROPOSED FRAMEWORKS
42
+
43
+ Our framework consists of spelling error correction, byte pair encoding tokenization and sequence to sequence model which can be summarized in Figure 3.
44
+
45
+ # 2.1 SPELLING ERROR CORRECTION
46
+
47
+ In this part, we aim to correct the spelling errors. Given a name of a chemical substance, we can separate it into different elemental words by all the non-alphabet characters. For example, 2-(chlorofluoro-methyl)-benzooxazole can be separated into chloro, fluoro, methyl and benzooxazole. To correct the spelling error, firstly we set up two vocabularies from the dataset: vocabulary of the systematic elemental words and of the non-systematic elemental words. For the systematic elemental words, we just split all the systematic names to build the vocabulary. For the non-systematic elemental words, firstly we use all the non-systematic names to build an elemental vocabulary, and then we just keep the elemental words which appear many times in the non-systematic names but outside the vocabulary of systematic elemental words and remove the rest. By this way, the vocabulary we build from the non-systematic names is the set of common names or synonyms. We then combine these two vocabularies together to get a final elemental vocabulary.
48
+
49
+ ![](images/ce08e0a9f8c1e8f8febfee2047a737719012252d708f089893b9dfd61b2bdc92.jpg)
50
+ Figure 3: Illustration of the framework
51
+
52
+ To do the correction search efficiently enough, we use BK-Tree (Burkhard & Keller, 1973) to structure the elemental vocabulary. BK-Tree is a tree structure which is widely used in spelling error correction. BK-Tree is defined in the following way. An arbitrary vocabulary item $a$ is selected as root node. The root node may have zero or more subtrees. The $k { \mathord { - } } t h$ subtree is recursively built of all vocabulary items $b$ such that $d ( a , b ) = k$ where $d ( a , b )$ is the Levenshtein distance between $a$ and $b$ . Given a word and a threshold, BK-Tree can return rapidly, if possible, the vocabulary item which have the smallest Levenshtein distance with the given word and the Levenshtein distance is smaller than the threshold by using the triangle rules: $| \bar { d } ( a , b ) - d ( b , c ) | \leq d ( a , c ) \leq d ( a , b ) + d ( b , c )$ . By using the BK-Tree, we can correct the spelling error of non-systematic names. Another advantage of using BK-Tree is that it is easy to insert new training data which makes it scalable. An example of BK-Tree built from a part of our dataset is shown in Figure 4.
53
+
54
+ At this stage, given a name of a chemical substance, we firstly separate it into elemental words and then input the elemental words one by one to the BK-Tree. After the correction, we combine the elemental words to get the full name. In this step, a few non-systematic names can be directly corrected and some non-systematic names can be partially corrected. It is also helpful in the training of the sequence to sequence model because it can reduce the noise of elemental words.
55
+
56
+ ![](images/1cd5e1cea66f03be81ad1aa1f7c37a61c30e477e5316cbb6231efad164e67836.jpg)
57
+ Figure 4: Example of BK-Tree built from a part of our dataset. Each node is an elemental word. The value on each edge is the Levenshtein distance between two nodes. All the nodes in the same subtree of a node have the same Levenshtein distance to this node. For instance, the Levenshtein distances from dimethyl, diethyl, methan to methyl are all 2.
58
+
59
+ Table 2: Examples of applying BPE to chemical names (subwords are separated by $@ \textcircled{ a }$ )
60
+
61
+ <table><tr><td>Original name</td><td>Split name</td></tr><tr><td>4-bromo-6-methoxyquinaldine</td><td>4-bromo@ @ -6-methoxy@ @ quinaldine</td></tr><tr><td>ethynyltris(propan-2-yl)silane methyltrioctylazaniumbromide</td><td>ethynyl@@ tris(propan-2-yl)@@ silane methyl@ @ trioctyl@ @ azanium bromide</td></tr></table>
62
+
63
+ # 2.2 TOKENIZATION BY BYTE PAIR ENCODING
64
+
65
+ To apply the sequence-to-sequence model, firstly we need to tokenize all the chemical names. In this paper, we use Byte Pair Encoding (BPE) (Sennrich et al., 2015) to do the tokenization. Firstly, we initialize a symbol set by split all the names into characters. At this moment, the symbol set contains only the single characters. Then we iteratively count all symbol pairs and replace each occurrence of the most frequent pair (X, Y) with a new symbol XY and add it to the symbol set. Each merge operation produces a new symbol. The size of final symbol set is equal to the size of initial character, plus the number of merge operations. We then use the trained symbol vocabulary set to do the tokenization.
66
+
67
+ The reasons why we choose BPE are as follow: Firstly, it can deal with out-of-vocabulary problem because the vocabulary set generated by BPE contains the vocabularies at character level. Secondly, it can separate a name into meaningful subwords because it can find the small molecules which appear frequently in the corpus and tokenize a chemical name into the names of the small molecules. Some examples of applying BPE to the chemical name are shown in Table 2. After the tokenization, we can use the split pairs to train the sequence to sequence model.
68
+
69
+ # 2.3 SEQUENCE TO SEQUENCE MODEL
70
+
71
+ Sequence to sequence model (Sutskever et al., 2014) is widely used in machine translation. In this work, we adapted an existing implementation OpenNMT (Klein et al., 2017) with a few modifications. The sequence to sequence model consists of two recurrent neural networks (RNN) working together: (1) an encoder that gets the source sequences (here are the non-systematic names separated by BPE) and generates a context vector $H$ , and (2) a decoder that uses this context vector to generate the target sequences (here are the corresponding systematic names). For the encoder, we use a multilayers bidirectional LSTM (BiLSTM) (Graves & Schmidhuber, 2005). BiLSTM consists of two LSTMs: one that processes the sequence forward and the other backward, with their forward and backward hidden states $\overrightarrow { h _ { t } }$ and $\left\{ { { \overline { { h _ { t } } } } } \right.$ at each time step. The hidden state at time step $t$ is just a concatenation of the two hidden states: $h _ { t } = \{ \overrightarrow { h _ { t } } ; \overleftarrow { h _ { t } } \}$ . At the final time step $T$ of the encoder, by combining all the hidden states, we get the context vector $H = \{ h _ { 1 } , . . . , h _ { T } \}$ . For the decoder, it gives the probability of an output sequence $\hat { y } = \left\{ \hat { y } _ { i } \right\}$ :
72
+
73
+ $$
74
+ P ( \hat { y } ) = \prod _ { t = 1 } ^ { M } p ( \hat { y } _ { t } | \{ \hat { y } _ { i < t } \} )
75
+ $$
76
+
77
+ and for a single token $\hat { y } _ { t }$ , the probability is calculated by
78
+
79
+ $$
80
+ \begin{array} { c } { \displaystyle s _ { t } = f \big ( s _ { t - 1 } , \hat { y } _ { t - 1 } \big ) } \\ { \displaystyle \alpha _ { j } = \frac { e x p \big ( s c o r e ( s _ { t } , h _ { j } ) \big ) } { \sum _ { j ^ { \prime } = 1 } ^ { T } e x p \big ( s c o r e ( s _ { t } , h _ { j ^ { \prime } } ) \big ) } } \\ { \displaystyle c _ { t } = \sum _ { j } \alpha _ { j } h _ { j } } \\ { \displaystyle a _ { t } = t a n h \big ( W _ { c } [ s _ { t } ; c _ { t } ] \big ) } \\ { \displaystyle p ( \hat { y } _ { t } \{ \hat { y } _ { i \le t } \} \big ) = s o f t m a x \big ( W _ { s } a _ { t } \big ) } \end{array}
81
+ $$
82
+
83
+ where $f$ is a multilayer LSTM; $s _ { t }$ is the decoder’s hidden state at time step $t$ ; and $W _ { c }$ , $W _ { s }$ are learned weights. For the score function, we use the attention mechanism proposed by Luong et al. (2015):
84
+
85
+ $$
86
+ s c o r e ( s _ { t } , h _ { j } ) = s _ { t } ^ { T } W _ { a } h _ { j }
87
+ $$
88
+
89
+ where $W _ { a }$ are also learned weights.
90
+
91
+ # 3 EXPERIMENTS
92
+
93
+ # 3.1 TRAINING DETAILS
94
+
95
+ In our framework, at the spelling error correction stage, the only parameter is the threshold of the BK-Tree. In the experiment, we have tried several threshold values: 1, 2 and 3. At the BPE stage, the only parameter is the number of the merge operations. In the experiments, we have tried several values: 2500, 5000, 10000, 20000. For the sequence to sequence model, the dimensions of word embeddings and hidden states are both 500. The vocabulary size is equal to the number of basic characters plus the number of merge operations of BPE. The numbers of layers in encoder and decoder are both 2. Before training the sequence to sequence model, we also do the spelling error correction for the non-systematic names in the training data.
96
+
97
+ During training, all parameters of the sequence to sequence model are trained jointly using stochastic gradient descent (SGD). The loss function is a cross-entropy function, expressed as
98
+
99
+ $$
100
+ L ( y , \hat { y } ) = - \sum _ { i } y _ { i } l o g ( \hat { y _ { i } } )
101
+ $$
102
+
103
+ The loss was computed over an entire minibatch of the size 64 and then normalized. The weights are initialized using a random uniform distribution ranging from -0.1 to 0.1. The initial learning rate is 1.0 and the decay will be applied with the factor 0.5 every epoch after and including epoch 8 or when the perplexity does not decrease on the validation set. The drop out rate is 0.3 and we train the model for 15 epochs. We set the beam size to 5 for the decoding.
104
+
105
+ For comparison, we also do another experiment by replacing sequence to sequence model with Statistical Machine Translation (SMT) model. In this experiment, we use implemented Moses system Koehn et al. (2007). In the training, we limit the length of training sequences to 80 and apply the 3-grams language model by using KenLM (Heafield, 2011). The tokenization for the pairs we use is BPE with 5000 merge operations.
106
+
107
+ Besides the spelling error correction, data augmentation is another technique for the neural model learning to deal with the noisy data (in this case, the noise is the spelling error). For comparison, we also do the experiment of data augmentation. For every non-systematic name, we insert an error into it for the probability of 0.025. The error insertion has four types: we insert randomly a character in a random position; we randomly delete a character in a random position; we randomly exchange two characters; we randomly replace a character by another random character. The four insertion methods are applied in an equal probability.
108
+
109
+ # 3.2 RESULTS
110
+
111
+ In the experiment, we measure the standardization quality with accuracy and BLEU score (Papineni et al., 2002). Accuracy is calculated by the number of non-systematic names which are successfully standardized divided by the total number of non-systematic names. Note the accuracy that we adopt here is a very strong performance metric, as it equally means that the entire translated sentence is exactly matched for a machine translation task. The experiment results for different models on test dataset are shown in Table 3. We can see that the combination of spelling error correction, BPE tokenization and sequence to sequence model achieves the best performance. Our framework has a great improvement compared to the SMT model and the ChemHits system. The latter is slightly better than just applying spelling error correction. The results for different numbers of BPE merge operation are shown in Table 4. 5000 is the best value for this parameter. 0 means a characterlevel sequence to sequence model. The results show the usefulness of BPE. The results for different Levenshtein distance thresholds for the spelling error correction and the result of data augmentation are shown in Table 5. We can see that spelling error correction is indeed helpful for our framework.
112
+
113
+ Table 3: Results of different models on test dataset
114
+
115
+ <table><tr><td>Models</td><td>Accuracy (%)</td><td>BLEU (%)</td></tr><tr><td></td><td></td><td></td></tr><tr><td>ChemHits (Golebiewski et al.)</td><td>6.14</td><td></td></tr><tr><td>Spelling error correction Spelling error correction + SMT</td><td>2.89 26.25</td><td>1 53.90</td></tr><tr><td></td><td>54.04</td><td>69.74</td></tr><tr><td>Spelling error correction + sequence to sequence</td><td></td><td></td></tr></table>
116
+
117
+ Table 4: Results for different numbers of BPE merge operation.
118
+
119
+ <table><tr><td>Number of merge operation</td><td>Accuracy (%)</td><td>BLEU (%)</td></tr><tr><td>20000</td><td>52.70</td><td>68.62</td></tr><tr><td>10000</td><td></td><td>69.22</td></tr><tr><td>5000</td><td>53.55 54.04</td><td>69.74</td></tr><tr><td>2500</td><td>53.90</td><td>70.19</td></tr><tr><td>0</td><td></td><td>64.25</td></tr><tr><td></td><td>23.60</td><td></td></tr></table>
120
+
121
+ Data augmentation also helps but does not perform as well as spelling error correction. Note that when the threshold is too large, the overcorrection might occur which reduces the standardization quality.
122
+
123
+ # 3.3 ANALYSIS
124
+
125
+ Some examples of the non-systematic names which are successfully standardized are shown in Table 6. These 4 examples show what the sequence to sequence model can do. In the first example, the parentheses in the non-systematic name are replaced by another parentheses and brackets. It means that the sequence to sequence model can fix also the non-alphabet spelling errors. The synonym error is also corrected: from 1-propanetriol to propane-1-thiol. In the second example, the wrong order ethane,1,2-dichloro is corrected to 1,2-dichloroethane. In the third example, the mixture of ordering error and synonym error are corrected. In the last example, $P$ -anise alcohol is a proprietary name which looks like totally different from its systematic name but it is also successfully standardized.
126
+
127
+ To better illustrate how the sequence to sequence model works, here we give the visualization of attentions of an example, which is shown in Figure 5. The non-systematic name is adenine,9- methyl- (7ci,8ci) and the corresponding systematic name is 9-methyl-9H-purin-6-amine. In the nonsystematic name, adenine itself is also a chemical substance whose systematic name is 9H-purin-6- amine. So it is a mixture of common name error and ordering error. From Figure 6, we can see that seq2seq model can find the relation between adenine and 9H-purin-6-amine and can find the right place for 9-methyl.
128
+
129
+ ![](images/08d064b61748e1ad920175089f0c20284c569e9435ce51785f4270e32ece46ea.jpg)
130
+ Figure 5: Visualization of attentions
131
+
132
+ ![](images/22df25e946337d45b4a3b0e21b5a4305fa414980e06ad4c8bfae091f44facbb6.jpg)
133
+ Figure 6: Accuracy for different lengths
134
+
135
+ Table 5: Results of different Levenshtein distance thresholds for the spelling error correction. For each threshold, the first line is the accuracy after just doing the spelling error correction. The second line is the accuracy after processing the non-systematic name by our whole framework. The numbers of BPE merge operation are all 5000.
136
+
137
+ <table><tr><td>Threshold</td><td>Accuracy (%)</td><td>BLEU (%)</td></tr><tr><td rowspan="3">Without spelling error correction</td><td></td><td></td></tr><tr><td>0</td><td></td></tr><tr><td>49.94 2.89</td><td>66.98</td></tr><tr><td>1</td><td>54.04</td><td>1 69.74</td></tr><tr><td>2</td><td>2.51 52.08</td><td>1 68.82</td></tr><tr><td>3</td><td>2.39 53.84</td><td>- 69.60</td></tr><tr><td>Data augmentation</td><td>52.95</td><td>69.00</td></tr></table>
138
+
139
+ Table 6: Examples of the non-systematic names which are successfully standardized. For each example, the first line is the name before standardization and the second line is the name after standardization.
140
+
141
+ <table><tr><td>Example 1</td><td>3-(dimethoxymethylsilyl)-l-propanetriol 3-[dimethoxy(methyl)silyllpropane-1-thiol</td></tr><tr><td>Example 2</td><td>ethane,l,2-dichloro 1,2-dichloroethane</td></tr><tr><td>Example 3</td><td>1-phenyl-3-methyl-4-benzoyl-1h-pyrazol-5(4h)-one 4-benzoyl-3-methyl-1-phenyl-4,5-dihydro-1H-pyrazol-5-one</td></tr><tr><td>Example 4</td><td>P-anisealcohol (4-methoxyphenyl)methanol</td></tr></table>
142
+
143
+ # 3.4 ERROR ANALYSIS
144
+
145
+ In this section, we will analyze the fail standardization attempts of our system. Firstly, we randomly select 100 samples of failed attempts and label their error types manually and carefully. The distribution over error types is shown in Table 7. We can see that synonym error is the most confusing error type and our system performs well at spelling error. As for the common error, since it is very hard to find a rule between an unseen common name and its systematic name, our system also perform poorly at this error type.
146
+
147
+ Among these 100 samples, there are 10 samples which are nearly correct (only one or two characters different from the systematic name), 7 examples are totally incorrect (none of the subwords of prediction match the systematic name) and the rest are partially correct. Some samples of failed attempts are shown in Table 8.
148
+
149
+ # 3.5 LIMITATIONS
150
+
151
+ We noticed that there are still nearly a half of the non-systematic names which are not successfully standardized. The accuracy for systematic names of different lengths are shown in Figure 6. We can see that our framework achieves the best performances for the systematic names of length between 20 and 40 while performing poorly for the systematic names of length bigger than 60 which account for $37 \%$ of our test dataset. Another limitation of our model is that we do not take into account chemical rules in our model. For this reason, a few names generated by our model disobey the chemical rules and at the tokenization stage, some subwords generated by BPE are not explicable as well.
152
+
153
+ Table 7: Distribution over error types of 100 failed attempts.
154
+
155
+ <table><tr><td>Error types</td><td>Number of failed attempts</td></tr><tr><td>Synonym error</td><td>59</td></tr><tr><td>Common name error</td><td>33</td></tr><tr><td>Synonym error+ ordering error</td><td>7</td></tr><tr><td>Spelling error</td><td>1</td></tr></table>
156
+
157
+ Table 8: Examples of failed attempts. For each example, the first line is the name before standardization and the second line is the systematic name and the third line is the prediction of our model.
158
+
159
+ <table><tr><td>Nearly correct</td><td>5-bromo-2-(chlorosulfanyl)toluene 4-bromo-2-methylbenzene-1-sulfonyl chloride</td></tr><tr><td>Totally incorrect</td><td>5-bromo-2-methylbenzene-l-sulfonylchloride cholinedicarbonate (2-hydroxyethyl)trimethylazanium hydrogen carbonate (carbamoylimino)urea</td></tr><tr><td>Partially correct</td><td>3,5-dichloro-4-nitrobenzotrifluoride 1,3-dichloro-2-iodo-5-(trifluoromethyl)benzene 4,5-dichloro-2-nitro-1-(trifluoromethyl)benzene</td></tr></table>
160
+
161
+ # 4 CONCLUSION
162
+
163
+ In this work, we propose a framework to automatically convert non-systematic names to systematic names . Our framework consists of spelling error correction, byte pair encoding tokenization and sequence to sequence model. Our framework achieves an accuracy of $5 4 . 0 4 \%$ on our dataset, which is far better than previous rule based system (nine times of accuracy) and thus enables the related chemical information extraction into more practical use stage. The advantage of our framework is that it is trained end to end, fully data-driven and independent of external chemical knowledge. This work starts a brand new research line for the related chemical information extraction as to our best knowledge.
164
+
165
+ # REFERENCES
166
+
167
+ W. A Burkhard and R. M Keller. Some approaches to best-match file searching. Communications of the Acm, 16(4):230–236, 1973.
168
+ Henry A. Favre and Warren H. Powell. Nomenclature of Organic Chemistry:IUPAC Recommendations and Preferred 224 Names 2013. Butterworths, 2013.
169
+ Martin Golebiewski, Jasmin Saric, Henriette Engelken, Meik Bittkowski, Ulrike Wittig, Wolfgang Mller, and Isabel Rojas. Normalization and matching of chemical compound names. Nature Precedings, 06 2009. doi: 10.1038/npre.2009.3322.1.
170
+ Alex Graves and Jrgen Schmidhuber. Framewise phoneme classification with bidirectional lstm and other neural network architectures. Neural Netw, 18(5):602–610, 2005.
171
+ Kenneth Heafield. Kenlm: faster and smaller language model queries. In The Workshop on Statistical Machine Translation, pp. 187–197, 2011.
172
+ Guillaume Klein, Yoon Kim, Yuntian Deng, Jean Senellart, and Alexander M Rush. Opennmt: Open-source toolkit for neural machine translation. 2017.
173
+ Philipp Koehn, Hieu Hoang, Alexandra Birch, Nicola Bertoldi, Nicola Bertoldi, Nicola Bertoldi, Brooke Cowan, Wade Shen, Christine Moran, and Richard Zens. Moses: open source toolkit for statistical machine translation. In Meeting of the ACL on Interactive Poster and Demonstration Sessions, pp. 177–180, 2007.
174
+ D. M. Lowe, P. T. Corbett, P Murray-Rust, and R. C. Glen. Chemical name to structure: Opsin, an open source solution. Journal of Chemical Information Modeling, 51(3):739–53, 2011.
175
+ Minh Thang Luong, Hieu Pham, and Christopher D Manning. Effective approaches to attentionbased neural machine translation. Computer Science, 2015.
176
+ Alan Mcnaught. The iupac international chemical identifier: Inchi - a new standard for molecular informatics. Chemistry International, 2006.
177
+ K. Papineni, S. Roukos, T. Ward, and W. J. Zhu. Ibm research report bleu: a method for automatic evaluation of machine translation. Acl Proceedings of Annual Meeting of the Association for Computational Linguistics, 30(2):311–318, 2002.
178
+ Rico Sennrich, Barry Haddow, and Alexandra Birch. Neural machine translation of rare words with subword units. Computer Science, 2015.
179
+ Ilya Sutskever, Oriol Vinyals, and Quoc V Le. Sequence to sequence learning with neural networks. 4:3104–3112, 2014.
180
+ David Weininger. Smiles, a chemical language and information system. 1. introduction to methodology and encoding rules. Journal of Chemical Information Computer Sciences, 28(1):31–36, 1988.
parse/train/rJg_NjCqtX/rJg_NjCqtX_content_list.json ADDED
@@ -0,0 +1,881 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [
2
+ {
3
+ "type": "text",
4
+ "text": "CHEMICAL NAMES STANDARDIZATION USING NEURAL SEQUENCE TO SEQUENCE MODEL ",
5
+ "text_level": 1,
6
+ "bbox": [
7
+ 176,
8
+ 99,
9
+ 727,
10
+ 147
11
+ ],
12
+ "page_idx": 0
13
+ },
14
+ {
15
+ "type": "text",
16
+ "text": "Anonymous authors Paper under double-blind review ",
17
+ "bbox": [
18
+ 184,
19
+ 174,
20
+ 398,
21
+ 200
22
+ ],
23
+ "page_idx": 0
24
+ },
25
+ {
26
+ "type": "text",
27
+ "text": "ABSTRACT ",
28
+ "text_level": 1,
29
+ "bbox": [
30
+ 454,
31
+ 238,
32
+ 544,
33
+ 253
34
+ ],
35
+ "page_idx": 0
36
+ },
37
+ {
38
+ "type": "text",
39
+ "text": "Chemical information extraction is to convert chemical knowledge in text into true chemical database, which is a text processing task heavily relying on chemical compound name identification and standardization. Once a systematic name for a chemical compound is given, it will naturally and much simply convert the name into the eventually required molecular formula. However, for many chemical substances, they have been shown in many other names besides their systematic names which poses a great challenge for this task. In this paper, we propose a framework to do the auto standardization from the non-systematic names to the corresponding systematic names by using the spelling error correction, byte pair encoding tokenization and neural sequence to sequence model. Our framework is trained end to end and is fully data-driven. Our standardization accuracy on the test dataset achieves $5 4 . 0 4 \\%$ which has a great improvement compared to previous state-of-the-art result. ",
40
+ "bbox": [
41
+ 233,
42
+ 273,
43
+ 764,
44
+ 454
45
+ ],
46
+ "page_idx": 0
47
+ },
48
+ {
49
+ "type": "text",
50
+ "text": "1 INTRODUCTION ",
51
+ "text_level": 1,
52
+ "bbox": [
53
+ 176,
54
+ 491,
55
+ 336,
56
+ 507
57
+ ],
58
+ "page_idx": 0
59
+ },
60
+ {
61
+ "type": "text",
62
+ "text": "There are more than 100 million named chemical substances in the world. In order to uniquely identify every chemical substance, there are elaborate rules for assigning names to them on the basis of their structures. These names are called systematic names. The rules for these names are defined by International Union of Pure and Applied Chemistry (IUPAC) (Favre & Powell, 2013). ",
63
+ "bbox": [
64
+ 174,
65
+ 526,
66
+ 823,
67
+ 582
68
+ ],
69
+ "page_idx": 0
70
+ },
71
+ {
72
+ "type": "text",
73
+ "text": "However, besides the systematic name, there can be also many other names for a chemical substance due to many reasons. Firstly, many chemical are so much a part of our life that we know them by their familiar names which we call them common names or trivial names for the sake of simplicity. For example, sucrose is a kind of sugar which we are very familiar with. Its systematic name is much more complicated, which is (2R,3R,4S,5S,6R)-2-[(2S,3S,4S,5R)-3,4-dihydroxy-2,5- bis(hydroxymethyl)oxolan-2-yl]oxy-6-(hydroxymethyl)oxane-3,4,5-triol. ",
74
+ "bbox": [
75
+ 174,
76
+ 589,
77
+ 825,
78
+ 674
79
+ ],
80
+ "page_idx": 0
81
+ },
82
+ {
83
+ "type": "text",
84
+ "text": "Secondly, in chemistry industry, especially in pharmaceutical industry, many producers always generate new names to a chemical substance in order to distinguish their products from those of their competitors. We call these kind of names proprietary names. The most famous example is Aspirin. Its systematic name is 2-Acetoxybenzoic acid. So due to the history reasons and idiomatic usages, a chemical substance can have many other names. ",
85
+ "bbox": [
86
+ 174,
87
+ 680,
88
+ 825,
89
+ 750
90
+ ],
91
+ "page_idx": 0
92
+ },
93
+ {
94
+ "type": "text",
95
+ "text": "Chemical information extraction is a research that extracts useful chemical knowledge in text and converts it into a database, which strongly relies on the unique standard chemical names. Nowadays, there are many chemical databases such as PubChem and SciFinder, which are designed to store chemical information including chemical names, chemical structures, molecular formulas and other relevant information. For these databases, it is still an ongoing work to extract chemical information from chemical papers to update the databases. If all the chemical substances are expressed by the systematic names, it is easy to generate other information. For example, we can nearly perfectly convert the systematic name to other representations such as Simplified Molecular-Input Line-Entry System (SMILES) (Weininger, 1988) and International Chemical Identifier (InCHI) (Mcnaught, 2006) and then generate the structural formulas. Some online systems are already well developed for converting automatically systematic names to SMILES string with a very high precision such as Open Parser for Systematic IUPAC Nomenclature (OPSIN) (Lowe et al., 2011) developed by ",
96
+ "bbox": [
97
+ 174,
98
+ 757,
99
+ 825,
100
+ 922
101
+ ],
102
+ "page_idx": 0
103
+ },
104
+ {
105
+ "type": "table",
106
+ "img_path": "images/4c0b8bf34c47d540260b251dfe5a4cce1b41adc44b536dc2323cd0852e0513be.jpg",
107
+ "table_caption": [
108
+ "Table 1: Examples of different types of error "
109
+ ],
110
+ "table_footnote": [],
111
+ "table_body": "<table><tr><td>Error type</td><td>Non-systematic name</td><td>Systematic name</td></tr><tr><td>Spelling error</td><td>benzoil chloride 1,3-benzoxazoole</td><td>benzoyl chloride 1,3-benzoxazole</td></tr><tr><td>Ordering error</td><td>benzene,1,4-dibromo-2-methyl 4-pyrimidinecarbaldehyde</td><td>1,4-dibromo-2-methylbenzene pyrimidine-4-carbaldehyde</td></tr><tr><td>Common name error</td><td>adenine Aspirin</td><td>9H-purin-6-amine 2-Acetoxybenzoic acid</td></tr><tr><td>Synonym error</td><td>sodiumbutoxide 2-ethylfuroate</td><td>sodium;butan-l-olate ethyl furan-2-carboxylate</td></tr><tr><td>Mixed of synonym error and ordering error</td><td>2-hydroxy-8-iodonaphthalene 3-amino-l,2-benzisoxazole</td><td>8-iodonaphthalen-2-ol 1,2-benzoxazol-3-amine</td></tr></table>",
112
+ "bbox": [
113
+ 187,
114
+ 131,
115
+ 810,
116
+ 304
117
+ ],
118
+ "page_idx": 1
119
+ },
120
+ {
121
+ "type": "text",
122
+ "text": "University of Cambridge1. Unfortunately, nowadays a great number of the chemical substances are expressed by their non-systematic names in chemical papers, which increases significantly the difficulties for this task, so our work focuses on the standardization of non-systematic names. Examples of chemical information extraction are shown in Figure 1. ",
123
+ "bbox": [
124
+ 174,
125
+ 335,
126
+ 825,
127
+ 392
128
+ ],
129
+ "page_idx": 1
130
+ },
131
+ {
132
+ "type": "image",
133
+ "img_path": "images/c8c2987bdcca2664b996abe7c17830a23caad95dc08d2bad34893ed854c2e311.jpg",
134
+ "image_caption": [
135
+ "Figure 1: Examples of chemical information extraction (the parts in the same color means the same chemical constituent name) "
136
+ ],
137
+ "image_footnote": [],
138
+ "bbox": [
139
+ 343,
140
+ 407,
141
+ 653,
142
+ 531
143
+ ],
144
+ "page_idx": 1
145
+ },
146
+ {
147
+ "type": "text",
148
+ "text": "In the following passage, we consider the differences between non-systematic names and systematic names as ”error”2. In view of natural language processing, the error types of non-systematic names can be summarized by four types: 1. Spelling error. It means that non-systematic names just have slightly differences from systematic names in spelling; 2. Ordering error. It means that the groups in a non-systematic name are in wrong order; 3. Common name error. As mentioned above, many chemical substances have common names or proprietary names which look totally different from their systematic names; 4. Synonym error. It means that the words in the nonsystematic names are different from those in the systematic names but they share the same root of word. In fact, it is the error type which happens most often. For example, 2-(Acetyloxy)benzoic Acid has synonyms Acetylsalicylic Acid and Acetysal and these three words share the same root of word ”Acety”. Some examples of different types of errors are shown in Table 1. What is worth mentioning is that several types of error can appear at the same time in a single non-systematic name, especially for the ordering error and synonym error. The mixed types of error make this task very challenging. ",
149
+ "bbox": [
150
+ 173,
151
+ 590,
152
+ 825,
153
+ 771
154
+ ],
155
+ "page_idx": 1
156
+ },
157
+ {
158
+ "type": "text",
159
+ "text": "Based on these four error types, we propose a framework to convert automatically the non-systematic names to systematic names. Our framework is structured as followed: 1. Spelling error correction. It aims to correct the spelling errors; 2. Byte pair encoding (BPE) tokenization. It aims to split a name into small parts; 3. Sequence to sequence model. It aims to fix all the remaining ordering errors, common name errors and synonym errors. ",
160
+ "bbox": [
161
+ 174,
162
+ 779,
163
+ 825,
164
+ 848
165
+ ],
166
+ "page_idx": 1
167
+ },
168
+ {
169
+ "type": "text",
170
+ "text": "Actually, due to its great challenge, few work has been done on the chemical name standardization. To our best knowledge, Golebiewski et al. (2009) is the only work deserving a citation which developed an online system ChemHits to do the standardization basing on several transformation rules and the queries to online chemical databases. The work of Golebiewski et al. (2009) severely depends on chemical knowledge, limiting its application potential and effectiveness to some extent. ",
171
+ "bbox": [
172
+ 173,
173
+ 854,
174
+ 823,
175
+ 883
176
+ ],
177
+ "page_idx": 1
178
+ },
179
+ {
180
+ "type": "text",
181
+ "text": "",
182
+ "bbox": [
183
+ 174,
184
+ 103,
185
+ 823,
186
+ 146
187
+ ],
188
+ "page_idx": 2
189
+ },
190
+ {
191
+ "type": "text",
192
+ "text": "Differently, we adopt sequence to sequence model that has been widely used on neural machine translation. The reason why we apply the sequence to sequence model is that our task has some similarities with the machine translation problem. In machine translation, there are source language and target language which correspond to the non-systematic names and the systematic names in our task. Two different languages can be different in: 1. Vocabularies, which corresponds to the common name error and synonym error; 2. Word order, which corresponds to the ordering error. Our framework is trained end-to-end, fully data-driven and without using external chemical knowledge. With this approach, we achieve an accuracy of $5 4 . 0 4 \\%$ in our test data set. ",
193
+ "bbox": [
194
+ 174,
195
+ 152,
196
+ 825,
197
+ 263
198
+ ],
199
+ "page_idx": 2
200
+ },
201
+ {
202
+ "type": "text",
203
+ "text": "Our work will be done on a corpus containing chemical names extracted from report of Chemical Journals with High Impact factors $( \\mathrm { C J H I F } ) ^ { 3 }$ . The corpus is collected and checked by paid manual work. It is a parallel corpus which includes non-systematic names and systematic names of chemical substances. In the following passage, we call a non-systematic name and the corresponding systematic name of a chemical substance data pair. In our corpus, there are 384816 data pairs. In Figure 2, we give an overview of the distribution of the Levenshtein distance between the non-systematic names and the systematic names to show how different the non-systematic names and the systematic names are. In the experiment, we use $80 \\%$ , $19 \\%$ and $1 \\%$ data as training set, test set and development set respectively. ",
204
+ "bbox": [
205
+ 173,
206
+ 270,
207
+ 825,
208
+ 396
209
+ ],
210
+ "page_idx": 2
211
+ },
212
+ {
213
+ "type": "image",
214
+ "img_path": "images/145b0d281c8aec0ed89fd7e4549392abdba3398569b9c5d92e7160384dec1f5d.jpg",
215
+ "image_caption": [
216
+ "Figure 2: Distribution of the Levenshtein distance between non-systematic names and systematic names "
217
+ ],
218
+ "image_footnote": [],
219
+ "bbox": [
220
+ 313,
221
+ 410,
222
+ 684,
223
+ 603
224
+ ],
225
+ "page_idx": 2
226
+ },
227
+ {
228
+ "type": "text",
229
+ "text": "2 PROPOSED FRAMEWORKS ",
230
+ "text_level": 1,
231
+ "bbox": [
232
+ 176,
233
+ 674,
234
+ 419,
235
+ 689
236
+ ],
237
+ "page_idx": 2
238
+ },
239
+ {
240
+ "type": "text",
241
+ "text": "Our framework consists of spelling error correction, byte pair encoding tokenization and sequence to sequence model which can be summarized in Figure 3. ",
242
+ "bbox": [
243
+ 173,
244
+ 704,
245
+ 823,
246
+ 733
247
+ ],
248
+ "page_idx": 2
249
+ },
250
+ {
251
+ "type": "text",
252
+ "text": "2.1 SPELLING ERROR CORRECTION ",
253
+ "text_level": 1,
254
+ "bbox": [
255
+ 176,
256
+ 750,
257
+ 429,
258
+ 763
259
+ ],
260
+ "page_idx": 2
261
+ },
262
+ {
263
+ "type": "text",
264
+ "text": "In this part, we aim to correct the spelling errors. Given a name of a chemical substance, we can separate it into different elemental words by all the non-alphabet characters. For example, 2-(chlorofluoro-methyl)-benzooxazole can be separated into chloro, fluoro, methyl and benzooxazole. To correct the spelling error, firstly we set up two vocabularies from the dataset: vocabulary of the systematic elemental words and of the non-systematic elemental words. For the systematic elemental words, we just split all the systematic names to build the vocabulary. For the non-systematic elemental words, firstly we use all the non-systematic names to build an elemental vocabulary, and then we just keep the elemental words which appear many times in the non-systematic names but outside the vocabulary of systematic elemental words and remove the rest. By this way, the vocabulary we build from the non-systematic names is the set of common names or synonyms. We then combine these two vocabularies together to get a final elemental vocabulary. ",
265
+ "bbox": [
266
+ 173,
267
+ 775,
268
+ 825,
269
+ 887
270
+ ],
271
+ "page_idx": 2
272
+ },
273
+ {
274
+ "type": "image",
275
+ "img_path": "images/ce08e0a9f8c1e8f8febfee2047a737719012252d708f089893b9dfd61b2bdc92.jpg",
276
+ "image_caption": [
277
+ "Figure 3: Illustration of the framework "
278
+ ],
279
+ "image_footnote": [],
280
+ "bbox": [
281
+ 292,
282
+ 99,
283
+ 704,
284
+ 316
285
+ ],
286
+ "page_idx": 3
287
+ },
288
+ {
289
+ "type": "text",
290
+ "text": "",
291
+ "bbox": [
292
+ 174,
293
+ 386,
294
+ 825,
295
+ 429
296
+ ],
297
+ "page_idx": 3
298
+ },
299
+ {
300
+ "type": "text",
301
+ "text": "To do the correction search efficiently enough, we use BK-Tree (Burkhard & Keller, 1973) to structure the elemental vocabulary. BK-Tree is a tree structure which is widely used in spelling error correction. BK-Tree is defined in the following way. An arbitrary vocabulary item $a$ is selected as root node. The root node may have zero or more subtrees. The $k { \\mathord { - } } t h$ subtree is recursively built of all vocabulary items $b$ such that $d ( a , b ) = k$ where $d ( a , b )$ is the Levenshtein distance between $a$ and $b$ . Given a word and a threshold, BK-Tree can return rapidly, if possible, the vocabulary item which have the smallest Levenshtein distance with the given word and the Levenshtein distance is smaller than the threshold by using the triangle rules: $| \\bar { d } ( a , b ) - d ( b , c ) | \\leq d ( a , c ) \\leq d ( a , b ) + d ( b , c )$ . By using the BK-Tree, we can correct the spelling error of non-systematic names. Another advantage of using BK-Tree is that it is easy to insert new training data which makes it scalable. An example of BK-Tree built from a part of our dataset is shown in Figure 4. ",
302
+ "bbox": [
303
+ 173,
304
+ 435,
305
+ 825,
306
+ 588
307
+ ],
308
+ "page_idx": 3
309
+ },
310
+ {
311
+ "type": "text",
312
+ "text": "At this stage, given a name of a chemical substance, we firstly separate it into elemental words and then input the elemental words one by one to the BK-Tree. After the correction, we combine the elemental words to get the full name. In this step, a few non-systematic names can be directly corrected and some non-systematic names can be partially corrected. It is also helpful in the training of the sequence to sequence model because it can reduce the noise of elemental words. ",
313
+ "bbox": [
314
+ 173,
315
+ 595,
316
+ 825,
317
+ 665
318
+ ],
319
+ "page_idx": 3
320
+ },
321
+ {
322
+ "type": "image",
323
+ "img_path": "images/1cd5e1cea66f03be81ad1aa1f7c37a61c30e477e5316cbb6231efad164e67836.jpg",
324
+ "image_caption": [
325
+ "Figure 4: Example of BK-Tree built from a part of our dataset. Each node is an elemental word. The value on each edge is the Levenshtein distance between two nodes. All the nodes in the same subtree of a node have the same Levenshtein distance to this node. For instance, the Levenshtein distances from dimethyl, diethyl, methan to methyl are all 2. "
326
+ ],
327
+ "image_footnote": [],
328
+ "bbox": [
329
+ 405,
330
+ 691,
331
+ 591,
332
+ 828
333
+ ],
334
+ "page_idx": 3
335
+ },
336
+ {
337
+ "type": "table",
338
+ "img_path": "images/c995a988dd0f98eb877824ddb512e3d24803ea6e860c83f91d7bddb2d1d6144d.jpg",
339
+ "table_caption": [
340
+ "Table 2: Examples of applying BPE to chemical names (subwords are separated by $@ \\textcircled{ a }$ ) "
341
+ ],
342
+ "table_footnote": [],
343
+ "table_body": "<table><tr><td>Original name</td><td>Split name</td></tr><tr><td>4-bromo-6-methoxyquinaldine</td><td>4-bromo@ @ -6-methoxy@ @ quinaldine</td></tr><tr><td>ethynyltris(propan-2-yl)silane methyltrioctylazaniumbromide</td><td>ethynyl@@ tris(propan-2-yl)@@ silane methyl@ @ trioctyl@ @ azanium bromide</td></tr></table>",
344
+ "bbox": [
345
+ 236,
346
+ 131,
347
+ 759,
348
+ 205
349
+ ],
350
+ "page_idx": 4
351
+ },
352
+ {
353
+ "type": "text",
354
+ "text": "2.2 TOKENIZATION BY BYTE PAIR ENCODING ",
355
+ "text_level": 1,
356
+ "bbox": [
357
+ 174,
358
+ 237,
359
+ 508,
360
+ 252
361
+ ],
362
+ "page_idx": 4
363
+ },
364
+ {
365
+ "type": "text",
366
+ "text": "To apply the sequence-to-sequence model, firstly we need to tokenize all the chemical names. In this paper, we use Byte Pair Encoding (BPE) (Sennrich et al., 2015) to do the tokenization. Firstly, we initialize a symbol set by split all the names into characters. At this moment, the symbol set contains only the single characters. Then we iteratively count all symbol pairs and replace each occurrence of the most frequent pair (X, Y) with a new symbol XY and add it to the symbol set. Each merge operation produces a new symbol. The size of final symbol set is equal to the size of initial character, plus the number of merge operations. We then use the trained symbol vocabulary set to do the tokenization. ",
367
+ "bbox": [
368
+ 173,
369
+ 263,
370
+ 825,
371
+ 375
372
+ ],
373
+ "page_idx": 4
374
+ },
375
+ {
376
+ "type": "text",
377
+ "text": "The reasons why we choose BPE are as follow: Firstly, it can deal with out-of-vocabulary problem because the vocabulary set generated by BPE contains the vocabularies at character level. Secondly, it can separate a name into meaningful subwords because it can find the small molecules which appear frequently in the corpus and tokenize a chemical name into the names of the small molecules. Some examples of applying BPE to the chemical name are shown in Table 2. After the tokenization, we can use the split pairs to train the sequence to sequence model. ",
378
+ "bbox": [
379
+ 174,
380
+ 381,
381
+ 825,
382
+ 465
383
+ ],
384
+ "page_idx": 4
385
+ },
386
+ {
387
+ "type": "text",
388
+ "text": "2.3 SEQUENCE TO SEQUENCE MODEL ",
389
+ "text_level": 1,
390
+ "bbox": [
391
+ 178,
392
+ 484,
393
+ 446,
394
+ 498
395
+ ],
396
+ "page_idx": 4
397
+ },
398
+ {
399
+ "type": "text",
400
+ "text": "Sequence to sequence model (Sutskever et al., 2014) is widely used in machine translation. In this work, we adapted an existing implementation OpenNMT (Klein et al., 2017) with a few modifications. The sequence to sequence model consists of two recurrent neural networks (RNN) working together: (1) an encoder that gets the source sequences (here are the non-systematic names separated by BPE) and generates a context vector $H$ , and (2) a decoder that uses this context vector to generate the target sequences (here are the corresponding systematic names). For the encoder, we use a multilayers bidirectional LSTM (BiLSTM) (Graves & Schmidhuber, 2005). BiLSTM consists of two LSTMs: one that processes the sequence forward and the other backward, with their forward and backward hidden states $\\overrightarrow { h _ { t } }$ and $\\left\\{ { { \\overline { { h _ { t } } } } } \\right.$ at each time step. The hidden state at time step $t$ is just a concatenation of the two hidden states: $h _ { t } = \\{ \\overrightarrow { h _ { t } } ; \\overleftarrow { h _ { t } } \\}$ . At the final time step $T$ of the encoder, by combining all the hidden states, we get the context vector $H = \\{ h _ { 1 } , . . . , h _ { T } \\}$ . For the decoder, it gives the probability of an output sequence $\\hat { y } = \\left\\{ \\hat { y } _ { i } \\right\\}$ : ",
401
+ "bbox": [
402
+ 173,
403
+ 510,
404
+ 825,
405
+ 685
406
+ ],
407
+ "page_idx": 4
408
+ },
409
+ {
410
+ "type": "equation",
411
+ "img_path": "images/9252b1ecba280fe6c75ca26232c479763e5ceebb97cc7a56586b505e6c3c5c4a.jpg",
412
+ "text": "$$\nP ( \\hat { y } ) = \\prod _ { t = 1 } ^ { M } p ( \\hat { y } _ { t } | \\{ \\hat { y } _ { i < t } \\} )\n$$",
413
+ "text_format": "latex",
414
+ "bbox": [
415
+ 415,
416
+ 693,
417
+ 583,
418
+ 736
419
+ ],
420
+ "page_idx": 4
421
+ },
422
+ {
423
+ "type": "text",
424
+ "text": "and for a single token $\\hat { y } _ { t }$ , the probability is calculated by ",
425
+ "bbox": [
426
+ 173,
427
+ 742,
428
+ 545,
429
+ 757
430
+ ],
431
+ "page_idx": 4
432
+ },
433
+ {
434
+ "type": "equation",
435
+ "img_path": "images/f1e0bef752c8c79c804250763f6827cce7c0b881e35af50b5d4db940de3c7d24.jpg",
436
+ "text": "$$\n\\begin{array} { c } { \\displaystyle s _ { t } = f \\big ( s _ { t - 1 } , \\hat { y } _ { t - 1 } \\big ) } \\\\ { \\displaystyle \\alpha _ { j } = \\frac { e x p \\big ( s c o r e ( s _ { t } , h _ { j } ) \\big ) } { \\sum _ { j ^ { \\prime } = 1 } ^ { T } e x p \\big ( s c o r e ( s _ { t } , h _ { j ^ { \\prime } } ) \\big ) } } \\\\ { \\displaystyle c _ { t } = \\sum _ { j } \\alpha _ { j } h _ { j } } \\\\ { \\displaystyle a _ { t } = t a n h \\big ( W _ { c } [ s _ { t } ; c _ { t } ] \\big ) } \\\\ { \\displaystyle p ( \\hat { y } _ { t } \\{ \\hat { y } _ { i \\le t } \\} \\big ) = s o f t m a x \\big ( W _ { s } a _ { t } \\big ) } \\end{array}\n$$",
437
+ "text_format": "latex",
438
+ "bbox": [
439
+ 383,
440
+ 776,
441
+ 612,
442
+ 928
443
+ ],
444
+ "page_idx": 4
445
+ },
446
+ {
447
+ "type": "text",
448
+ "text": "where $f$ is a multilayer LSTM; $s _ { t }$ is the decoder’s hidden state at time step $t$ ; and $W _ { c }$ , $W _ { s }$ are learned weights. For the score function, we use the attention mechanism proposed by Luong et al. (2015): ",
449
+ "bbox": [
450
+ 171,
451
+ 103,
452
+ 825,
453
+ 132
454
+ ],
455
+ "page_idx": 5
456
+ },
457
+ {
458
+ "type": "equation",
459
+ "img_path": "images/755e8c6d078410e558062e78b418f9dc4e1187f03870b924a1519510f53462f9.jpg",
460
+ "text": "$$\ns c o r e ( s _ { t } , h _ { j } ) = s _ { t } ^ { T } W _ { a } h _ { j }\n$$",
461
+ "text_format": "latex",
462
+ "bbox": [
463
+ 413,
464
+ 138,
465
+ 584,
466
+ 157
467
+ ],
468
+ "page_idx": 5
469
+ },
470
+ {
471
+ "type": "text",
472
+ "text": "where $W _ { a }$ are also learned weights. ",
473
+ "bbox": [
474
+ 174,
475
+ 164,
476
+ 408,
477
+ 179
478
+ ],
479
+ "page_idx": 5
480
+ },
481
+ {
482
+ "type": "text",
483
+ "text": "3 EXPERIMENTS ",
484
+ "text_level": 1,
485
+ "bbox": [
486
+ 176,
487
+ 198,
488
+ 326,
489
+ 215
490
+ ],
491
+ "page_idx": 5
492
+ },
493
+ {
494
+ "type": "text",
495
+ "text": "3.1 TRAINING DETAILS ",
496
+ "text_level": 1,
497
+ "bbox": [
498
+ 176,
499
+ 229,
500
+ 349,
501
+ 244
502
+ ],
503
+ "page_idx": 5
504
+ },
505
+ {
506
+ "type": "text",
507
+ "text": "In our framework, at the spelling error correction stage, the only parameter is the threshold of the BK-Tree. In the experiment, we have tried several threshold values: 1, 2 and 3. At the BPE stage, the only parameter is the number of the merge operations. In the experiments, we have tried several values: 2500, 5000, 10000, 20000. For the sequence to sequence model, the dimensions of word embeddings and hidden states are both 500. The vocabulary size is equal to the number of basic characters plus the number of merge operations of BPE. The numbers of layers in encoder and decoder are both 2. Before training the sequence to sequence model, we also do the spelling error correction for the non-systematic names in the training data. ",
508
+ "bbox": [
509
+ 173,
510
+ 256,
511
+ 825,
512
+ 368
513
+ ],
514
+ "page_idx": 5
515
+ },
516
+ {
517
+ "type": "text",
518
+ "text": "During training, all parameters of the sequence to sequence model are trained jointly using stochastic gradient descent (SGD). The loss function is a cross-entropy function, expressed as ",
519
+ "bbox": [
520
+ 173,
521
+ 375,
522
+ 820,
523
+ 404
524
+ ],
525
+ "page_idx": 5
526
+ },
527
+ {
528
+ "type": "equation",
529
+ "img_path": "images/0eb9e79bb7b155e1543ef1366d62104dc1dd321e6fc7c286184ca292aae8710f.jpg",
530
+ "text": "$$\nL ( y , \\hat { y } ) = - \\sum _ { i } y _ { i } l o g ( \\hat { y _ { i } } )\n$$",
531
+ "text_format": "latex",
532
+ "bbox": [
533
+ 410,
534
+ 410,
535
+ 588,
536
+ 443
537
+ ],
538
+ "page_idx": 5
539
+ },
540
+ {
541
+ "type": "text",
542
+ "text": "The loss was computed over an entire minibatch of the size 64 and then normalized. The weights are initialized using a random uniform distribution ranging from -0.1 to 0.1. The initial learning rate is 1.0 and the decay will be applied with the factor 0.5 every epoch after and including epoch 8 or when the perplexity does not decrease on the validation set. The drop out rate is 0.3 and we train the model for 15 epochs. We set the beam size to 5 for the decoding. ",
543
+ "bbox": [
544
+ 173,
545
+ 448,
546
+ 825,
547
+ 518
548
+ ],
549
+ "page_idx": 5
550
+ },
551
+ {
552
+ "type": "text",
553
+ "text": "For comparison, we also do another experiment by replacing sequence to sequence model with Statistical Machine Translation (SMT) model. In this experiment, we use implemented Moses system Koehn et al. (2007). In the training, we limit the length of training sequences to 80 and apply the 3-grams language model by using KenLM (Heafield, 2011). The tokenization for the pairs we use is BPE with 5000 merge operations. ",
554
+ "bbox": [
555
+ 173,
556
+ 525,
557
+ 825,
558
+ 595
559
+ ],
560
+ "page_idx": 5
561
+ },
562
+ {
563
+ "type": "text",
564
+ "text": "Besides the spelling error correction, data augmentation is another technique for the neural model learning to deal with the noisy data (in this case, the noise is the spelling error). For comparison, we also do the experiment of data augmentation. For every non-systematic name, we insert an error into it for the probability of 0.025. The error insertion has four types: we insert randomly a character in a random position; we randomly delete a character in a random position; we randomly exchange two characters; we randomly replace a character by another random character. The four insertion methods are applied in an equal probability. ",
565
+ "bbox": [
566
+ 174,
567
+ 602,
568
+ 825,
569
+ 700
570
+ ],
571
+ "page_idx": 5
572
+ },
573
+ {
574
+ "type": "text",
575
+ "text": "3.2 RESULTS ",
576
+ "text_level": 1,
577
+ "bbox": [
578
+ 174,
579
+ 717,
580
+ 277,
581
+ 731
582
+ ],
583
+ "page_idx": 5
584
+ },
585
+ {
586
+ "type": "text",
587
+ "text": "In the experiment, we measure the standardization quality with accuracy and BLEU score (Papineni et al., 2002). Accuracy is calculated by the number of non-systematic names which are successfully standardized divided by the total number of non-systematic names. Note the accuracy that we adopt here is a very strong performance metric, as it equally means that the entire translated sentence is exactly matched for a machine translation task. The experiment results for different models on test dataset are shown in Table 3. We can see that the combination of spelling error correction, BPE tokenization and sequence to sequence model achieves the best performance. Our framework has a great improvement compared to the SMT model and the ChemHits system. The latter is slightly better than just applying spelling error correction. The results for different numbers of BPE merge operation are shown in Table 4. 5000 is the best value for this parameter. 0 means a characterlevel sequence to sequence model. The results show the usefulness of BPE. The results for different Levenshtein distance thresholds for the spelling error correction and the result of data augmentation are shown in Table 5. We can see that spelling error correction is indeed helpful for our framework. ",
588
+ "bbox": [
589
+ 173,
590
+ 743,
591
+ 825,
592
+ 924
593
+ ],
594
+ "page_idx": 5
595
+ },
596
+ {
597
+ "type": "table",
598
+ "img_path": "images/9cb133e213f35463702080c3d13fdbdc22922fce074fb7cb903cd146568ce5b5.jpg",
599
+ "table_caption": [
600
+ "Table 3: Results of different models on test dataset "
601
+ ],
602
+ "table_footnote": [],
603
+ "table_body": "<table><tr><td>Models</td><td>Accuracy (%)</td><td>BLEU (%)</td></tr><tr><td></td><td></td><td></td></tr><tr><td>ChemHits (Golebiewski et al.)</td><td>6.14</td><td></td></tr><tr><td>Spelling error correction Spelling error correction + SMT</td><td>2.89 26.25</td><td>1 53.90</td></tr><tr><td></td><td>54.04</td><td>69.74</td></tr><tr><td>Spelling error correction + sequence to sequence</td><td></td><td></td></tr></table>",
604
+ "bbox": [
605
+ 214,
606
+ 127,
607
+ 784,
608
+ 217
609
+ ],
610
+ "page_idx": 6
611
+ },
612
+ {
613
+ "type": "table",
614
+ "img_path": "images/bc288e90223de19ea6726bf9c190205f8a1fe3c72e4d267fdd43849c83452e03.jpg",
615
+ "table_caption": [
616
+ "Table 4: Results for different numbers of BPE merge operation. "
617
+ ],
618
+ "table_footnote": [],
619
+ "table_body": "<table><tr><td>Number of merge operation</td><td>Accuracy (%)</td><td>BLEU (%)</td></tr><tr><td>20000</td><td>52.70</td><td>68.62</td></tr><tr><td>10000</td><td></td><td>69.22</td></tr><tr><td>5000</td><td>53.55 54.04</td><td>69.74</td></tr><tr><td>2500</td><td>53.90</td><td>70.19</td></tr><tr><td>0</td><td></td><td>64.25</td></tr><tr><td></td><td>23.60</td><td></td></tr></table>",
620
+ "bbox": [
621
+ 287,
622
+ 266,
623
+ 712,
624
+ 368
625
+ ],
626
+ "page_idx": 6
627
+ },
628
+ {
629
+ "type": "text",
630
+ "text": "Data augmentation also helps but does not perform as well as spelling error correction. Note that when the threshold is too large, the overcorrection might occur which reduces the standardization quality. ",
631
+ "bbox": [
632
+ 176,
633
+ 401,
634
+ 825,
635
+ 443
636
+ ],
637
+ "page_idx": 6
638
+ },
639
+ {
640
+ "type": "text",
641
+ "text": "3.3 ANALYSIS ",
642
+ "text_level": 1,
643
+ "bbox": [
644
+ 174,
645
+ 462,
646
+ 285,
647
+ 476
648
+ ],
649
+ "page_idx": 6
650
+ },
651
+ {
652
+ "type": "text",
653
+ "text": "Some examples of the non-systematic names which are successfully standardized are shown in Table 6. These 4 examples show what the sequence to sequence model can do. In the first example, the parentheses in the non-systematic name are replaced by another parentheses and brackets. It means that the sequence to sequence model can fix also the non-alphabet spelling errors. The synonym error is also corrected: from 1-propanetriol to propane-1-thiol. In the second example, the wrong order ethane,1,2-dichloro is corrected to 1,2-dichloroethane. In the third example, the mixture of ordering error and synonym error are corrected. In the last example, $P$ -anise alcohol is a proprietary name which looks like totally different from its systematic name but it is also successfully standardized. ",
654
+ "bbox": [
655
+ 174,
656
+ 488,
657
+ 825,
658
+ 613
659
+ ],
660
+ "page_idx": 6
661
+ },
662
+ {
663
+ "type": "text",
664
+ "text": "To better illustrate how the sequence to sequence model works, here we give the visualization of attentions of an example, which is shown in Figure 5. The non-systematic name is adenine,9- methyl- (7ci,8ci) and the corresponding systematic name is 9-methyl-9H-purin-6-amine. In the nonsystematic name, adenine itself is also a chemical substance whose systematic name is 9H-purin-6- amine. So it is a mixture of common name error and ordering error. From Figure 6, we can see that seq2seq model can find the relation between adenine and 9H-purin-6-amine and can find the right place for 9-methyl. ",
665
+ "bbox": [
666
+ 173,
667
+ 621,
668
+ 826,
669
+ 718
670
+ ],
671
+ "page_idx": 6
672
+ },
673
+ {
674
+ "type": "image",
675
+ "img_path": "images/08d064b61748e1ad920175089f0c20284c569e9435ce51785f4270e32ece46ea.jpg",
676
+ "image_caption": [
677
+ "Figure 5: Visualization of attentions "
678
+ ],
679
+ "image_footnote": [],
680
+ "bbox": [
681
+ 181,
682
+ 733,
683
+ 426,
684
+ 881
685
+ ],
686
+ "page_idx": 6
687
+ },
688
+ {
689
+ "type": "image",
690
+ "img_path": "images/22df25e946337d45b4a3b0e21b5a4305fa414980e06ad4c8bfae091f44facbb6.jpg",
691
+ "image_caption": [
692
+ "Figure 6: Accuracy for different lengths "
693
+ ],
694
+ "image_footnote": [],
695
+ "bbox": [
696
+ 446,
697
+ 739,
698
+ 810,
699
+ 881
700
+ ],
701
+ "page_idx": 6
702
+ },
703
+ {
704
+ "type": "table",
705
+ "img_path": "images/81223849b7ab40d072132e9cfe0ca32c7bf48d8abea401817092b73a9ed8ec21.jpg",
706
+ "table_caption": [
707
+ "Table 5: Results of different Levenshtein distance thresholds for the spelling error correction. For each threshold, the first line is the accuracy after just doing the spelling error correction. The second line is the accuracy after processing the non-systematic name by our whole framework. The numbers of BPE merge operation are all 5000. "
708
+ ],
709
+ "table_footnote": [],
710
+ "table_body": "<table><tr><td>Threshold</td><td>Accuracy (%)</td><td>BLEU (%)</td></tr><tr><td rowspan=\"3\">Without spelling error correction</td><td></td><td></td></tr><tr><td>0</td><td></td></tr><tr><td>49.94 2.89</td><td>66.98</td></tr><tr><td>1</td><td>54.04</td><td>1 69.74</td></tr><tr><td>2</td><td>2.51 52.08</td><td>1 68.82</td></tr><tr><td>3</td><td>2.39 53.84</td><td>- 69.60</td></tr><tr><td>Data augmentation</td><td>52.95</td><td>69.00</td></tr></table>",
711
+ "bbox": [
712
+ 308,
713
+ 172,
714
+ 687,
715
+ 330
716
+ ],
717
+ "page_idx": 7
718
+ },
719
+ {
720
+ "type": "table",
721
+ "img_path": "images/7c0e6edbdadcbd79e0b1b8f1875e4f9f361044c216525ab394992740ed07bd1d.jpg",
722
+ "table_caption": [
723
+ "Table 6: Examples of the non-systematic names which are successfully standardized. For each example, the first line is the name before standardization and the second line is the name after standardization. "
724
+ ],
725
+ "table_footnote": [],
726
+ "table_body": "<table><tr><td>Example 1</td><td>3-(dimethoxymethylsilyl)-l-propanetriol 3-[dimethoxy(methyl)silyllpropane-1-thiol</td></tr><tr><td>Example 2</td><td>ethane,l,2-dichloro 1,2-dichloroethane</td></tr><tr><td>Example 3</td><td>1-phenyl-3-methyl-4-benzoyl-1h-pyrazol-5(4h)-one 4-benzoyl-3-methyl-1-phenyl-4,5-dihydro-1H-pyrazol-5-one</td></tr><tr><td>Example 4</td><td>P-anisealcohol (4-methoxyphenyl)methanol</td></tr></table>",
727
+ "bbox": [
728
+ 245,
729
+ 424,
730
+ 751,
731
+ 554
732
+ ],
733
+ "page_idx": 7
734
+ },
735
+ {
736
+ "type": "text",
737
+ "text": "3.4 ERROR ANALYSIS ",
738
+ "text_level": 1,
739
+ "bbox": [
740
+ 174,
741
+ 589,
742
+ 338,
743
+ 603
744
+ ],
745
+ "page_idx": 7
746
+ },
747
+ {
748
+ "type": "text",
749
+ "text": "In this section, we will analyze the fail standardization attempts of our system. Firstly, we randomly select 100 samples of failed attempts and label their error types manually and carefully. The distribution over error types is shown in Table 7. We can see that synonym error is the most confusing error type and our system performs well at spelling error. As for the common error, since it is very hard to find a rule between an unseen common name and its systematic name, our system also perform poorly at this error type. ",
750
+ "bbox": [
751
+ 173,
752
+ 617,
753
+ 825,
754
+ 700
755
+ ],
756
+ "page_idx": 7
757
+ },
758
+ {
759
+ "type": "text",
760
+ "text": "Among these 100 samples, there are 10 samples which are nearly correct (only one or two characters different from the systematic name), 7 examples are totally incorrect (none of the subwords of prediction match the systematic name) and the rest are partially correct. Some samples of failed attempts are shown in Table 8. ",
761
+ "bbox": [
762
+ 174,
763
+ 707,
764
+ 825,
765
+ 762
766
+ ],
767
+ "page_idx": 7
768
+ },
769
+ {
770
+ "type": "text",
771
+ "text": "3.5 LIMITATIONS ",
772
+ "text_level": 1,
773
+ "bbox": [
774
+ 174,
775
+ 784,
776
+ 307,
777
+ 799
778
+ ],
779
+ "page_idx": 7
780
+ },
781
+ {
782
+ "type": "text",
783
+ "text": "We noticed that there are still nearly a half of the non-systematic names which are not successfully standardized. The accuracy for systematic names of different lengths are shown in Figure 6. We can see that our framework achieves the best performances for the systematic names of length between 20 and 40 while performing poorly for the systematic names of length bigger than 60 which account for $37 \\%$ of our test dataset. Another limitation of our model is that we do not take into account chemical rules in our model. For this reason, a few names generated by our model disobey the chemical rules and at the tokenization stage, some subwords generated by BPE are not explicable as well. ",
784
+ "bbox": [
785
+ 174,
786
+ 811,
787
+ 825,
788
+ 924
789
+ ],
790
+ "page_idx": 7
791
+ },
792
+ {
793
+ "type": "table",
794
+ "img_path": "images/d083c262c117fc8f894223d31b8f2e66167629455315b56682f0515e54f88a2f.jpg",
795
+ "table_caption": [
796
+ "Table 7: Distribution over error types of 100 failed attempts. "
797
+ ],
798
+ "table_footnote": [],
799
+ "table_body": "<table><tr><td>Error types</td><td>Number of failed attempts</td></tr><tr><td>Synonym error</td><td>59</td></tr><tr><td>Common name error</td><td>33</td></tr><tr><td>Synonym error+ ordering error</td><td>7</td></tr><tr><td>Spelling error</td><td>1</td></tr></table>",
800
+ "bbox": [
801
+ 282,
802
+ 131,
803
+ 715,
804
+ 218
805
+ ],
806
+ "page_idx": 8
807
+ },
808
+ {
809
+ "type": "table",
810
+ "img_path": "images/4fed76e0191a4f617dec0460f34cc2f1403af1bcd85b04cf28a5cc39a10a9496.jpg",
811
+ "table_caption": [
812
+ "Table 8: Examples of failed attempts. For each example, the first line is the name before standardization and the second line is the systematic name and the third line is the prediction of our model. "
813
+ ],
814
+ "table_footnote": [],
815
+ "table_body": "<table><tr><td>Nearly correct</td><td>5-bromo-2-(chlorosulfanyl)toluene 4-bromo-2-methylbenzene-1-sulfonyl chloride</td></tr><tr><td>Totally incorrect</td><td>5-bromo-2-methylbenzene-l-sulfonylchloride cholinedicarbonate (2-hydroxyethyl)trimethylazanium hydrogen carbonate (carbamoylimino)urea</td></tr><tr><td>Partially correct</td><td>3,5-dichloro-4-nitrobenzotrifluoride 1,3-dichloro-2-iodo-5-(trifluoromethyl)benzene 4,5-dichloro-2-nitro-1-(trifluoromethyl)benzene</td></tr></table>",
816
+ "bbox": [
817
+ 245,
818
+ 310,
819
+ 753,
820
+ 454
821
+ ],
822
+ "page_idx": 8
823
+ },
824
+ {
825
+ "type": "text",
826
+ "text": "4 CONCLUSION ",
827
+ "text_level": 1,
828
+ "bbox": [
829
+ 174,
830
+ 484,
831
+ 318,
832
+ 501
833
+ ],
834
+ "page_idx": 8
835
+ },
836
+ {
837
+ "type": "text",
838
+ "text": "In this work, we propose a framework to automatically convert non-systematic names to systematic names . Our framework consists of spelling error correction, byte pair encoding tokenization and sequence to sequence model. Our framework achieves an accuracy of $5 4 . 0 4 \\%$ on our dataset, which is far better than previous rule based system (nine times of accuracy) and thus enables the related chemical information extraction into more practical use stage. The advantage of our framework is that it is trained end to end, fully data-driven and independent of external chemical knowledge. This work starts a brand new research line for the related chemical information extraction as to our best knowledge. ",
839
+ "bbox": [
840
+ 173,
841
+ 517,
842
+ 825,
843
+ 630
844
+ ],
845
+ "page_idx": 8
846
+ },
847
+ {
848
+ "type": "text",
849
+ "text": "REFERENCES ",
850
+ "text_level": 1,
851
+ "bbox": [
852
+ 174,
853
+ 651,
854
+ 285,
855
+ 666
856
+ ],
857
+ "page_idx": 8
858
+ },
859
+ {
860
+ "type": "text",
861
+ "text": "W. A Burkhard and R. M Keller. Some approaches to best-match file searching. Communications of the Acm, 16(4):230–236, 1973. \nHenry A. Favre and Warren H. Powell. Nomenclature of Organic Chemistry:IUPAC Recommendations and Preferred 224 Names 2013. Butterworths, 2013. \nMartin Golebiewski, Jasmin Saric, Henriette Engelken, Meik Bittkowski, Ulrike Wittig, Wolfgang Mller, and Isabel Rojas. Normalization and matching of chemical compound names. Nature Precedings, 06 2009. doi: 10.1038/npre.2009.3322.1. \nAlex Graves and Jrgen Schmidhuber. Framewise phoneme classification with bidirectional lstm and other neural network architectures. Neural Netw, 18(5):602–610, 2005. \nKenneth Heafield. Kenlm: faster and smaller language model queries. In The Workshop on Statistical Machine Translation, pp. 187–197, 2011. \nGuillaume Klein, Yoon Kim, Yuntian Deng, Jean Senellart, and Alexander M Rush. Opennmt: Open-source toolkit for neural machine translation. 2017. \nPhilipp Koehn, Hieu Hoang, Alexandra Birch, Nicola Bertoldi, Nicola Bertoldi, Nicola Bertoldi, Brooke Cowan, Wade Shen, Christine Moran, and Richard Zens. Moses: open source toolkit for statistical machine translation. In Meeting of the ACL on Interactive Poster and Demonstration Sessions, pp. 177–180, 2007. \nD. M. Lowe, P. T. Corbett, P Murray-Rust, and R. C. Glen. Chemical name to structure: Opsin, an open source solution. Journal of Chemical Information Modeling, 51(3):739–53, 2011. \nMinh Thang Luong, Hieu Pham, and Christopher D Manning. Effective approaches to attentionbased neural machine translation. Computer Science, 2015. \nAlan Mcnaught. The iupac international chemical identifier: Inchi - a new standard for molecular informatics. Chemistry International, 2006. \nK. Papineni, S. Roukos, T. Ward, and W. J. Zhu. Ibm research report bleu: a method for automatic evaluation of machine translation. Acl Proceedings of Annual Meeting of the Association for Computational Linguistics, 30(2):311–318, 2002. \nRico Sennrich, Barry Haddow, and Alexandra Birch. Neural machine translation of rare words with subword units. Computer Science, 2015. \nIlya Sutskever, Oriol Vinyals, and Quoc V Le. Sequence to sequence learning with neural networks. 4:3104–3112, 2014. \nDavid Weininger. Smiles, a chemical language and information system. 1. introduction to methodology and encoding rules. Journal of Chemical Information Computer Sciences, 28(1):31–36, 1988. ",
862
+ "bbox": [
863
+ 171,
864
+ 675,
865
+ 828,
866
+ 924
867
+ ],
868
+ "page_idx": 8
869
+ },
870
+ {
871
+ "type": "text",
872
+ "text": "",
873
+ "bbox": [
874
+ 171,
875
+ 103,
876
+ 826,
877
+ 455
878
+ ],
879
+ "page_idx": 9
880
+ }
881
+ ]
parse/train/rJg_NjCqtX/rJg_NjCqtX_middle.json ADDED
The diff for this file is too large to render. See raw diff
 
parse/train/rJg_NjCqtX/rJg_NjCqtX_model.json ADDED
The diff for this file is too large to render. See raw diff