{"about":{"site":"https://codewithpapers.app","non_affiliation":"Code with Papers and Syntology are not affiliated with, endorsed by, or sponsored by Papers with Code, Meta, or the pwc-archive mirror.","licence":"CC BY-SA 4.0","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","attribution":"https://codewithpapers.app/attribution","modified":"archive material modified by Syntology; see the attribution page"},"url":"/paper/r-drop-regularized-dropout-for-neural","title":"R-Drop: Regularized Dropout for Neural Networks","arxiv_id":"2106.14448","date":"2021-06-28","proceeding":"NeurIPS 2021 12","authors":["Xiaobo Liang","Lijun Wu","Juntao Li","Yue Wang","Qi Meng","Tao Qin","Wei Chen","Min Zhang","Tie-Yan Liu"],"abstract":"Dropout is a powerful and widely used technique to regularize the training of deep neural networks. In this paper, we introduce a simple regularization strategy upon dropout in model training, namely R-Drop, which forces the output distributions of different sub models generated by dropout to be consistent with each other. Specifically, for each training sample, R-Drop minimizes the bidirectional KL-divergence between the output distributions of two sub models sampled by dropout. Theoretical analysis reveals that R-Drop reduces the freedom of the model parameters and complements dropout. Experiments on $\\bf{5}$ widely used deep learning tasks ($\\bf{18}$ datasets in total), including neural machine translation, abstractive summarization, language understanding, language modeling, and image classification, show that R-Drop is universally effective. In particular, it yields substantial improvements when applied to fine-tune large-scale pre-trained models, e.g., ViT, RoBERTa-large, and BART, and achieves state-of-the-art (SOTA) performances with the vanilla Transformer model on WMT14 English$\\to$German translation ($\\bf{30.91}$ BLEU) and WMT14 English$\\to$French translation ($\\bf{43.95}$ BLEU), even surpassing models trained with extra large-scale data and expert-designed advanced variants of Transformer models. Our code is available at GitHub{\\url{https://github.com/dropreg/R-Drop}}.","url_abs":"https://arxiv.org/abs/2106.14448v2","url_pdf":"https://arxiv.org/pdf/2106.14448v2.pdf","source":{"archive":"pwc-archive (Hugging Face), CC BY-SA 4.0","snapshot":"2025-07-28","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","row_kind":"abstracts"},"code_links":[{"paper_slug":"r-drop-regularized-dropout-for-neural","repo_url":"https://github.com/dropreg/R-Drop","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":1,"framework":"jax","reach":{"status":"ok"}},{"paper_slug":"r-drop-regularized-dropout-for-neural","repo_url":"https://github.com/bojone/r-drop","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"tf","reach":{"status":"ok"}},{"paper_slug":"r-drop-regularized-dropout-for-neural","repo_url":"https://github.com/btobab/R-Drop","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"paddle","reach":{"status":"ok","spdx":"Apache-2.0"}},{"paper_slug":"r-drop-regularized-dropout-for-neural","repo_url":"https://github.com/cosmoquester/2021-dialogue-summary-competition","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"pytorch","reach":null},{"paper_slug":"r-drop-regularized-dropout-for-neural","repo_url":"https://github.com/fushengwuyu/R-Drop","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok"}},{"paper_slug":"r-drop-regularized-dropout-for-neural","repo_url":"https://github.com/zpc-666/Paddle-R-Drop","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"paddle","reach":{"status":"ok","spdx":"Apache-2.0"}},{"paper_slug":"r-drop-regularized-dropout-for-neural","repo_url":"https://github.com/wzh326/R-Drop","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":0,"framework":"paddle","reach":{"status":"ok"}},{"paper_slug":"r-drop-regularized-dropout-for-neural","repo_url":"https://github.com/zbp-xxxp/R-Drop-Paddle","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":0,"framework":"paddle","reach":{"status":"ok","spdx":"Apache-2.0"}}],"tasks":[{"task_slug":"abstractive-text-summarization","task_name":"Abstractive Text Summarization"},{"task_slug":"image-classification","task_name":"Image Classification"},{"task_slug":"language-modeling","task_name":"Language Modeling"},{"task_slug":"language-modelling","task_name":"Language Modelling"},{"task_slug":"machine-translation","task_name":"Machine Translation"},{"task_slug":"translation","task_name":"Translation"},{"task_slug":"image-classification","task_name":"image-classification"}],"methods":[{"method_slug":"absolute-position-encodings","method_name":"Absolute Position Encodings"},{"method_slug":"adam","method_name":"Adam"},{"method_slug":"attention","method_name":"Attention"},{"method_slug":"bart","method_name":"BART"},{"method_slug":"bpe","method_name":"BPE"},{"method_slug":"dense-connections","method_name":"Dense Connections"},{"method_slug":"dropout","method_name":"Dropout"},{"method_slug":"label-smoothing","method_name":"Label Smoothing"},{"method_slug":"layer-normalization","method_name":"Layer Normalization"},{"method_slug":"linear-layer","method_name":"Linear Layer"},{"method_slug":"multi-head-attention","method_name":"Multi-Head Attention"},{"method_slug":"position-wise-feed-forward-layer","method_name":"Position-Wise Feed-Forward Layer"},{"method_slug":"residual-connection","method_name":"Residual Connection"},{"method_slug":"softmax","method_name":"Softmax"},{"method_slug":"transformer","method_name":"Transformer"}],"datasets_introduced":[],"methods_introduced":[],"results":[{"leaderboard":"/sota/abstractive-text-summarization-on-cnn-daily","task":"Abstractive Text Summarization","dataset":"CNN / Daily Mail","model":"BART + R-Drop","rank_in_archive_order":10,"of":53,"metrics":{"ROUGE-1":"44.51","ROUGE-2":"21.58","ROUGE-L":"41.24"},"uses_additional_data":false},{"leaderboard":"/sota/machine-translation-on-iwslt2014-german","task":"Machine Translation","dataset":"IWSLT2014 German-English","model":"Transformer + R-Drop + Cutoff","rank_in_archive_order":6,"of":34,"metrics":{"BLEU score":"37.90"},"uses_additional_data":false},{"leaderboard":"/sota/machine-translation-on-iwslt2014-german","task":"Machine Translation","dataset":"IWSLT2014 German-English","model":"Transformer + R-Drop","rank_in_archive_order":11,"of":34,"metrics":{"BLEU score":"37.25"},"uses_additional_data":false},{"leaderboard":"/sota/machine-translation-on-wmt2014-english-french","task":"Machine Translation","dataset":"WMT2014 English-French","model":"Transformer + R-Drop","rank_in_archive_order":4,"of":57,"metrics":{"BLEU score":"43.95"},"uses_additional_data":false},{"leaderboard":"/sota/machine-translation-on-wmt2014-english-german","task":"Machine Translation","dataset":"WMT2014 English-German","model":"Transformer + R-Drop","rank_in_archive_order":6,"of":91,"metrics":{"BLEU score":"30.91","Hardware Burden":"49G"},"uses_additional_data":false}],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=2106.14448","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2106.14448"}},"developers":"https://syntology.ai/developers","read_at":"2026-09-24T18:15:14+00:00","read_at_is":"when the build read Syntology's graph, not when any sample ran","claim":"Per-sample execution status on synthesized fixtures; not a correctness claim about the paper. Samples come from repositories linked to the paper, official or community; repo_kind says which.","repos":[{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/fushengwuyu/R-Drop","reach":{"status":"ok"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/btobab/R-Drop","reach":{"status":"ok","spdx":"Apache-2.0"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/wzh326/R-Drop","reach":{"status":"ok"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/cosmoquester/2021-dialogue-summary-competition","reach":null},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/dropreg/R-Drop","reach":{"status":"ok"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/bojone/r-drop","reach":{"status":"ok"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/zpc-666/Paddle-R-Drop","reach":{"status":"ok","spdx":"Apache-2.0"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/zbp-xxxp/R-Drop-Paddle","reach":{"status":"ok","spdx":"Apache-2.0"}}],"summary":{"ran":2,"unverified":4},"by_repo_kind":{"listed":{"samples":6,"ran":2,"repositories":3}},"repo_kind_vocabulary":{"official":"The archive marks this repository official for the paper","named_in_paper":"The archive records that the paper mentions this repository; it is not marked official","listed":"In the archive's code links for this paper, not marked official and not recorded as mentioned in the paper","found_in_text":"Syntology found this repository in the paper's own text; whether it is the authors' implementation is not asserted","community":"Not in the archive's code links for this paper; a community repository Syntology harvested"},"n_pointer_only_for_licence":0,"samples":[{"code_sha256_prefix":"0089735efb90328b","entry":"LinearWarmupLR","repo":"cosmoquester/2021-dialogue-summary-competition","repo_kind":"listed","path":"summarizer/method/rdrop.py","file_url":"https://github.com/cosmoquester/2021-dialogue-summary-competition/blob/HEAD/summarizer/method/rdrop.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"0089735efb90328b"}},{"code_sha256_prefix":"586548b80b045cfd","entry":"RDropModule","repo":"cosmoquester/2021-dialogue-summary-competition","repo_kind":"listed","path":"summarizer/method/rdrop.py","file_url":"https://github.com/cosmoquester/2021-dialogue-summary-competition/blob/HEAD/summarizer/method/rdrop.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"586548b80b045cfd"}},{"code_sha256_prefix":"0632534b7fda246f","entry":"count_parameters","repo":"zpc-666/Paddle-R-Drop","repo_kind":"listed","path":"R_Drop/utils/utils.py","file_url":"https://github.com/zpc-666/Paddle-R-Drop/blob/HEAD/R_Drop/utils/utils.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"0632534b7fda246f"}},{"code_sha256_prefix":"3c241ecfe3749a6d","entry":"simple_accuracy","repo":"zpc-666/Paddle-R-Drop","repo_kind":"listed","path":"R_Drop/utils/utils.py","file_url":"https://github.com/zpc-666/Paddle-R-Drop/blob/HEAD/R_Drop/utils/utils.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"3c241ecfe3749a6d"}},{"code_sha256_prefix":"90c67ad49626180a","entry":"to_2tuple","repo":"zbp-xxxp/R-Drop-Paddle","repo_kind":"listed","path":"models/modeling.py","file_url":"https://github.com/zbp-xxxp/R-Drop-Paddle/blob/HEAD/models/modeling.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"90c67ad49626180a"}},{"code_sha256_prefix":"0d39c035f6237733","entry":"to_2tuple","repo":"zpc-666/Paddle-R-Drop","repo_kind":"listed","path":"R_Drop/models/modeling.py","file_url":"https://github.com/zpc-666/Paddle-R-Drop/blob/HEAD/R_Drop/models/modeling.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"0d39c035f6237733"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}