{"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/generating-radiology-reports-via-memory","title":"Generating Radiology Reports via Memory-driven Transformer","arxiv_id":"2010.16056","date":"2020-10-30","proceeding":"EMNLP 2020 11","authors":["Zhihong Chen","Yan Song","Tsung-Hui Chang","Xiang Wan"],"abstract":"Medical imaging is frequently used in clinical practice and trials for diagnosis and treatment. Writing imaging reports is time-consuming and can be error-prone for inexperienced radiologists. Therefore, automatically generating radiology reports is highly desired to lighten the workload of radiologists and accordingly promote clinical automation, which is an essential task to apply artificial intelligence to the medical domain. In this paper, we propose to generate radiology reports with memory-driven Transformer, where a relational memory is designed to record key information of the generation process and a memory-driven conditional layer normalization is applied to incorporating the memory into the decoder of Transformer. Experimental results on two prevailing radiology report datasets, IU X-Ray and MIMIC-CXR, show that our proposed approach outperforms previous models with respect to both language generation metrics and clinical evaluations. Particularly, this is the first work reporting the generation results on MIMIC-CXR to the best of our knowledge. Further analyses also demonstrate that our approach is able to generate long reports with necessary medical terms as well as meaningful image-text attention mappings.","url_abs":"https://arxiv.org/abs/2010.16056v2","url_pdf":"https://arxiv.org/pdf/2010.16056v2.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":"generating-radiology-reports-via-memory","repo_url":"https://github.com/zhjohnchan/R2Gen","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok"}},{"paper_slug":"generating-radiology-reports-via-memory","repo_url":"https://github.com/jbdel/vilmedic","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"pytorch","reach":null}],"tasks":[{"task_slug":"decoder","task_name":"Decoder"},{"task_slug":"text-generation","task_name":"Text Generation"}],"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":"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":[],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=2010.16056","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2010.16056"}},"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/zhjohnchan/R2Gen","reach":{"status":"ok"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/jbdel/vilmedic","reach":null},{"provenance":"deterministic:regex_extraction","url":"https://github.com/cuhksz-nlp/R2Gen","reach":null}],"summary":{"ran":16,"ran_draft_wrong":5,"ran_violates":3,"ran_honours":2,"unverified":5},"by_repo_kind":{"official":{"samples":1,"ran":1,"repositories":1},"listed":{"samples":6,"ran":4,"repositories":1},"found_in_text":{"samples":24,"ran":21,"repositories":1}},"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":25,"samples":[{"code_sha256_prefix":"83685e82672f8403","entry":"ConditionalLayerNorm","repo":"cuhksz-nlp/R2Gen","repo_kind":"found_in_text","path":"modules/encoder_decoder.py","file_url":"https://github.com/cuhksz-nlp/R2Gen/blob/HEAD/modules/encoder_decoder.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"83685e82672f8403"}},{"code_sha256_prefix":"66e1facaefcc74bf","entry":"ConditionalSublayerConnection","repo":"cuhksz-nlp/R2Gen","repo_kind":"found_in_text","path":"modules/encoder_decoder.py","file_url":"https://github.com/cuhksz-nlp/R2Gen/blob/HEAD/modules/encoder_decoder.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"66e1facaefcc74bf"}},{"code_sha256_prefix":"5dd90b8f3465a5d4","entry":"Decoder","repo":"cuhksz-nlp/R2Gen","repo_kind":"found_in_text","path":"modules/encoder_decoder.py","file_url":"https://github.com/cuhksz-nlp/R2Gen/blob/HEAD/modules/encoder_decoder.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"5dd90b8f3465a5d4"}},{"code_sha256_prefix":"4d87926b21da466a","entry":"DecoderLayer","repo":"cuhksz-nlp/R2Gen","repo_kind":"found_in_text","path":"modules/encoder_decoder.py","file_url":"https://github.com/cuhksz-nlp/R2Gen/blob/HEAD/modules/encoder_decoder.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"4d87926b21da466a"}},{"code_sha256_prefix":"f573a122811ee3d9","entry":"Embeddings","repo":"cuhksz-nlp/R2Gen","repo_kind":"found_in_text","path":"modules/encoder_decoder.py","file_url":"https://github.com/cuhksz-nlp/R2Gen/blob/HEAD/modules/encoder_decoder.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"f573a122811ee3d9"}},{"code_sha256_prefix":"c7161e97934abeef","entry":"Encoder","repo":"cuhksz-nlp/R2Gen","repo_kind":"found_in_text","path":"modules/encoder_decoder.py","file_url":"https://github.com/cuhksz-nlp/R2Gen/blob/HEAD/modules/encoder_decoder.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":"deterministic","behaviour_fingerprint":true,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"c7161e97934abeef"}},{"code_sha256_prefix":"bc4566e8723dd002","entry":"EncoderLayer","repo":"cuhksz-nlp/R2Gen","repo_kind":"found_in_text","path":"modules/encoder_decoder.py","file_url":"https://github.com/cuhksz-nlp/R2Gen/blob/HEAD/modules/encoder_decoder.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"bc4566e8723dd002"}},{"code_sha256_prefix":"f3db48bfa8d0418c","entry":"LayerNorm","repo":"cuhksz-nlp/R2Gen","repo_kind":"found_in_text","path":"modules/encoder_decoder.py","file_url":"https://github.com/cuhksz-nlp/R2Gen/blob/HEAD/modules/encoder_decoder.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":"deterministic","behaviour_fingerprint":true,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"f3db48bfa8d0418c"}},{"code_sha256_prefix":"b79314b6538aca28","entry":"MultiHeadedAttention","repo":"cuhksz-nlp/R2Gen","repo_kind":"found_in_text","path":"modules/encoder_decoder.py","file_url":"https://github.com/cuhksz-nlp/R2Gen/blob/HEAD/modules/encoder_decoder.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"b79314b6538aca28"}},{"code_sha256_prefix":"94ae2b884db29276","entry":"PositionalEncoding","repo":"cuhksz-nlp/R2Gen","repo_kind":"found_in_text","path":"modules/encoder_decoder.py","file_url":"https://github.com/cuhksz-nlp/R2Gen/blob/HEAD/modules/encoder_decoder.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"94ae2b884db29276"}},{"code_sha256_prefix":"31ac554b956f2c39","entry":"PositionwiseFeedForward","repo":"cuhksz-nlp/R2Gen","repo_kind":"found_in_text","path":"modules/encoder_decoder.py","file_url":"https://github.com/cuhksz-nlp/R2Gen/blob/HEAD/modules/encoder_decoder.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"31ac554b956f2c39"}},{"code_sha256_prefix":"c72b4b36f72a8b7f","entry":"RelationalMemory","repo":"cuhksz-nlp/R2Gen","repo_kind":"found_in_text","path":"modules/encoder_decoder.py","file_url":"https://github.com/cuhksz-nlp/R2Gen/blob/HEAD/modules/encoder_decoder.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"c72b4b36f72a8b7f"}},{"code_sha256_prefix":"777d5cf5b297d69f","entry":"SublayerConnection","repo":"cuhksz-nlp/R2Gen","repo_kind":"found_in_text","path":"modules/encoder_decoder.py","file_url":"https://github.com/cuhksz-nlp/R2Gen/blob/HEAD/modules/encoder_decoder.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"777d5cf5b297d69f"}},{"code_sha256_prefix":"e0bad05390dca30a","entry":"Transformer","repo":"cuhksz-nlp/R2Gen","repo_kind":"found_in_text","path":"modules/encoder_decoder.py","file_url":"https://github.com/cuhksz-nlp/R2Gen/blob/HEAD/modules/encoder_decoder.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"e0bad05390dca30a"}},{"code_sha256_prefix":"83045338e170467c","entry":"attention","repo":"cuhksz-nlp/R2Gen","repo_kind":"found_in_text","path":"modules/encoder_decoder.py","file_url":"https://github.com/cuhksz-nlp/R2Gen/blob/HEAD/modules/encoder_decoder.py","link_basis":"first_harvest_node","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"MISDECLARED","metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"83045338e170467c"}},{"code_sha256_prefix":"6cdff690e29fd5e2","entry":"clones","repo":"zhjohnchan/R2Gen","repo_kind":"official","path":"modules/encoder_decoder.py","file_url":"https://github.com/zhjohnchan/R2Gen/blob/HEAD/modules/encoder_decoder.py","link_basis":"plan_row","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"OUTPUT_MISDECLARED","metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"6cdff690e29fd5e2"}},{"code_sha256_prefix":"90a7d4b65fda9753","entry":"evaluation","repo":"jbdel/vilmedic","repo_kind":"listed","path":"vilmedic/models/rrg/RRG.py","file_url":"https://github.com/jbdel/vilmedic/blob/HEAD/vilmedic/models/rrg/RRG.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":"90a7d4b65fda9753"}},{"code_sha256_prefix":"2ce55e4c4a74c7fe","entry":"get_n_params","repo":"jbdel/vilmedic","repo_kind":"listed","path":"vilmedic/models/rrg/RRG.py","file_url":"https://github.com/jbdel/vilmedic/blob/HEAD/vilmedic/models/rrg/RRG.py","link_basis":"first_harvest_node","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"OUTPUT_MISDECLARED","metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"2ce55e4c4a74c7fe"}},{"code_sha256_prefix":"9b96271c0ebfc544","entry":"get_special_token_ids","repo":"jbdel/vilmedic","repo_kind":"listed","path":"vilmedic/models/rrg/RRG.py","file_url":"https://github.com/jbdel/vilmedic/blob/HEAD/vilmedic/models/rrg/RRG.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":"9b96271c0ebfc544"}},{"code_sha256_prefix":"506f510e45fc90c3","entry":"length_average","repo":"cuhksz-nlp/R2Gen","repo_kind":"found_in_text","path":"modules/encoder_decoder.py","file_url":"https://github.com/cuhksz-nlp/R2Gen/blob/HEAD/modules/encoder_decoder.py","link_basis":"first_harvest_node","language":"python","status":"ran_violates","verification_level":1,"contract_check":"VIOLATES","metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"506f510e45fc90c3"}},{"code_sha256_prefix":"1b78d09288063680","entry":"length_wu","repo":"cuhksz-nlp/R2Gen","repo_kind":"found_in_text","path":"modules/encoder_decoder.py","file_url":"https://github.com/cuhksz-nlp/R2Gen/blob/HEAD/modules/encoder_decoder.py","link_basis":"first_harvest_node","language":"python","status":"ran_honours","verification_level":1,"contract_check":"HONOURS","metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"1b78d09288063680"}},{"code_sha256_prefix":"8345317ad8bce91f","entry":"penalty_builder","repo":"cuhksz-nlp/R2Gen","repo_kind":"found_in_text","path":"modules/encoder_decoder.py","file_url":"https://github.com/cuhksz-nlp/R2Gen/blob/HEAD/modules/encoder_decoder.py","link_basis":"first_harvest_node","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"OUTPUT_MISDECLARED","metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"8345317ad8bce91f"}},{"code_sha256_prefix":"38f8d7385c92b38e","entry":"readable_size","repo":"jbdel/vilmedic","repo_kind":"listed","path":"vilmedic/models/rrg/RRG.py","file_url":"https://github.com/jbdel/vilmedic/blob/HEAD/vilmedic/models/rrg/RRG.py","link_basis":"first_harvest_node","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"OUTPUT_MISDECLARED","metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"38f8d7385c92b38e"}},{"code_sha256_prefix":"b317109a6e9a36e3","entry":"repeat_tensors","repo":"cuhksz-nlp/R2Gen","repo_kind":"found_in_text","path":"modules/encoder_decoder.py","file_url":"https://github.com/cuhksz-nlp/R2Gen/blob/HEAD/modules/encoder_decoder.py","link_basis":"first_harvest_node","language":"python","status":"ran_honours","verification_level":1,"contract_check":"HONOURS","metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"b317109a6e9a36e3"}},{"code_sha256_prefix":"936178513bc7b9d7","entry":"split_tensors","repo":"cuhksz-nlp/R2Gen","repo_kind":"found_in_text","path":"modules/encoder_decoder.py","file_url":"https://github.com/cuhksz-nlp/R2Gen/blob/HEAD/modules/encoder_decoder.py","link_basis":"first_harvest_node","language":"python","status":"ran_violates","verification_level":1,"contract_check":"VIOLATES","metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"936178513bc7b9d7"}},{"code_sha256_prefix":"66fbf162663d4cff","entry":"subsequent_mask","repo":"cuhksz-nlp/R2Gen","repo_kind":"found_in_text","path":"modules/encoder_decoder.py","file_url":"https://github.com/cuhksz-nlp/R2Gen/blob/HEAD/modules/encoder_decoder.py","link_basis":"first_harvest_node","language":"python","status":"ran_violates","verification_level":1,"contract_check":"VIOLATES","metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"66fbf162663d4cff"}},{"code_sha256_prefix":"a5dc837f604a531e","entry":"AttModel","repo":"cuhksz-nlp/R2Gen","repo_kind":"found_in_text","path":"modules/encoder_decoder.py","file_url":"https://github.com/cuhksz-nlp/R2Gen/blob/HEAD/modules/encoder_decoder.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"a5dc837f604a531e"}},{"code_sha256_prefix":"929610ebb467db68","entry":"CaptionModel","repo":"cuhksz-nlp/R2Gen","repo_kind":"found_in_text","path":"modules/encoder_decoder.py","file_url":"https://github.com/cuhksz-nlp/R2Gen/blob/HEAD/modules/encoder_decoder.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"929610ebb467db68"}},{"code_sha256_prefix":"f582c3015724586c","entry":"DecoderModel","repo":"jbdel/vilmedic","repo_kind":"listed","path":"vilmedic/models/rrg/RRG.py","file_url":"https://github.com/jbdel/vilmedic/blob/HEAD/vilmedic/models/rrg/RRG.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"f582c3015724586c"}},{"code_sha256_prefix":"fe63f5b4d1609641","entry":"EncoderDecoder","repo":"cuhksz-nlp/R2Gen","repo_kind":"found_in_text","path":"modules/encoder_decoder.py","file_url":"https://github.com/cuhksz-nlp/R2Gen/blob/HEAD/modules/encoder_decoder.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"fe63f5b4d1609641"}},{"code_sha256_prefix":"0832ed0f66780e17","entry":"RRG","repo":"jbdel/vilmedic","repo_kind":"listed","path":"vilmedic/models/rrg/RRG.py","file_url":"https://github.com/jbdel/vilmedic/blob/HEAD/vilmedic/models/rrg/RRG.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"0832ed0f66780e17"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}