论文解析 | 不确定性校准的化学反应预测模型
編者按
論文《A Model for Uncertainty-Calibrated Chemical Reaction Prediction》對模型的不確定性進行了估計,提升了泛化能力。本文從實驗背景、參數(shù)設(shè)置、結(jié)果與影響等方面進行了詳細的解析,以供讀者更好的理解文獻。
今天講一下一篇關(guān)于小分子生成的文章,產(chǎn)物Predicted by the given reactants and reagents.反應(yīng)預(yù)測被認為是試劑和產(chǎn)物的微笑輸入和反應(yīng)物的Machine translation problem of smile output。并且該實驗的方案可以準確估計分類預(yù)測Uncertainty of correctness。此外,該模型不需要人工規(guī)則,還可以處理無需分離反應(yīng)試劑的輸入,And data with stereochemistry,準確預(yù)測有效的合理的化學(xué)反應(yīng)。
1.1 使用數(shù)據(jù)
The author uses the USPTO_STEREO dataset and the USPTO_MIT dataset respectively. Two data processing methods are used, separated and mixed. Seperated divides the reactants and reagents with >, but mixed does not distinguish between molecules that provide products and atoms that do not provide products. Let the network learn automatically, so more molecules are needed to determine the reaction center. This improves accuracy.
數(shù)據(jù)集形式如圖1所示。
圖1 數(shù)據(jù)集劃分
1.2 基于opennmt模型參數(shù)設(shè)置
其中對transformer進行參數(shù)調(diào)優(yōu),束搜索大小為5,transformer的層數(shù)為4層,[1] embed的size為256,注意力頭為8。并且在訓(xùn)練過程中使用了ADAM優(yōu)化器,將batchsize擴充到4096,梯度每累計四次就回傳一次。
1.3 消融實驗
盡管融合模型集合可以獲得Higher precision and very good的不確定性估計,但是需要額外的訓(xùn)練或測試時間。[2]在不同數(shù)據(jù)集上,最好的top5個單一The second best model accuracy is obvious高于最好的精度,達到>93%,如圖2所示。
圖2 分離試劑對USPTO_MIT數(shù)據(jù)集的消融實驗
同時也和之前的單一模型通過將反應(yīng)類型流行區(qū)域進行分類做了比較,如圖3所示,發(fā)現(xiàn)了Molecular ?Transformer的潛在優(yōu)勢[3],當(dāng)bin的數(shù)量大于2000時,top1的ACC都在90以上。并且對MIT和STEREO數(shù)據(jù)集進行比較,如圖4所示。它不僅可以記憶數(shù)據(jù),而且可以利用從更常見的反應(yīng)中推斷出的信息,對更罕見的反應(yīng)做出預(yù)測。可以看出top1的指標上的separated數(shù)據(jù)集還是比mixed效果更好,在MIT中精度可以達到百分之90以上,以及top2到top5均大于90。
圖3 USPTO_MIT單一模型與USPTO_MIT測試集上的模型相比的最高精度
圖4 Molecular ?Transformer的topk精度
1.4 精準度策略與反應(yīng)路徑評分
Because organic synthesis is a multi-step process, for a reaction predictor to be useful, it must be able to estimate its own uncertainty. The Molecular Transformer model provides an implementation method: the product of the probabilities of all predicted tokens can be used as a confidence score, and the threshold of the confidence score is used to determine whether a response is predicted incorrectly to determine the ROC curve. Indicators true positive (TP), true negative (TN) and false positive rate (FP/ (FP + TN)) and true positive rate (TP/(TP + FN)). As shown in Figure 5, it can be found that the change of the threshold versus the roc curve increases and decreases, but the change of ACC is not particularly significant.
圖5 評估時,在MIT數(shù)據(jù)集上訓(xùn)練的模型的不同標簽平滑值的roc曲線
不難看出平滑對精度的影響相對較小,但對不確定性量化有顯著影響。在訓(xùn)練期間沒有給出目標產(chǎn)品的 one-hot 編碼的時間步長,Label smoothing reduces the quality of correct labels in the target vector,并將平滑質(zhì)量分配給詞匯表中的所有其他標簽。它有助于產(chǎn)生Higher translation accuracy and human language BLEU score,也有助于在響應(yīng)預(yù)測中獲得更高的最好的 準確度。此外,不確定性估計度量還可以用作對響應(yīng)路徑進行排序的分數(shù),該分數(shù)基于所有預(yù)測token的概率的乘積,可以看出smiles的長度是一個比較大的偏差,一個大分子不應(yīng)該意味著“困難”的預(yù)測。并且置信度分數(shù)與smiles的長度之間并沒有相關(guān)性。
1.5 結(jié)論與影響
First of all, the innovation of this article is the use of a multi-head attention mechanism, which can be regarded as an ensemble inside the model. It achieved 90.4% of Top1 on a public benchmark data set (Top2 was 93.7%), and more importantly, the model did not use any hand-made rules. It can accurately predict the chemical change of selectivity and obtain the correct chemical selectivity, regioselectivity and stereoselectivity. In addition, our model can also estimate the uncertainty in whether it correctly predicts the classification of a response. The ROC?AUC of the uncertainty score predicted by the model is 0.89. This model has been used in the back-end of IBM Chemical RXN since August 2018. So far, thousands of organic chemists around the world have used it to make more than 40,000 predictions.
參考文獻
[1]?? Vaswani, A.; Shazeer, N.; Parmar, N.; Uszkoreit, J.; Jones, L.;Gomez, A. N.; Kaiser, ?.; Polosukhin, I. Attention Is All You Need.Advances in Neural Information Processing Systems 2017, 6000?6010
[2]?? Coley, C. W.; Jin, W.; Rogers, L.; Jamison, T. F.; Jaakkola, T. S.;Green, W. H.; Barzilay, R.; Jensen, K. F. A Graph-ConvolutionalNeural Network Model for the Prediction of Chemical Reactivity.Chemical science 2019, 10, 370?377.
[3]?? Schwaller, P.; Gaudin, T.; Lanyi, D.; Bekas, C.; Laino, T. Foundin Translation”: Predicting Outcomes of Complex Organic ChemistryReactions Using Neural Sequence-To-Sequence Models. Chemical Science
[4]?? Segler, M. H.; Preuss, M.; Waller, M. P. Planning Chemical Syntheses with Deep Neural Networks and Symbolic AI. Nature 2018,555, 604.
極鏈AI云平臺現(xiàn)上傳了Opennmt的模型庫,大家可以點擊閱讀全文,去官網(wǎng)康一康哦~
總結(jié)
以上是生活随笔為你收集整理的论文解析 | 不确定性校准的化学反应预测模型的全部內(nèi)容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: Android侧滑返回手机工具,Vivo
- 下一篇: 查询2021年甘肃高考成绩位次,2021