{"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/recursive-generalization-transformer-for","title":"Recursive Generalization Transformer for Image Super-Resolution","arxiv_id":"2303.06373","date":"2023-03-11","proceeding":null,"authors":["Zheng Chen","Yulun Zhang","Jinjin Gu","Linghe Kong","Xiaokang Yang"],"abstract":"Transformer architectures have exhibited remarkable performance in image super-resolution (SR). Since the quadratic computational complexity of the self-attention (SA) in Transformer, existing methods tend to adopt SA in a local region to reduce overheads. However, the local design restricts the global context exploitation, which is crucial for accurate image reconstruction. In this work, we propose the Recursive Generalization Transformer (RGT) for image SR, which can capture global spatial information and is suitable for high-resolution images. Specifically, we propose the recursive-generalization self-attention (RG-SA). It recursively aggregates input features into representative feature maps, and then utilizes cross-attention to extract global information. Meanwhile, the channel dimensions of attention matrices (query, key, and value) are further scaled to mitigate the redundancy in the channel domain. Furthermore, we combine the RG-SA with local self-attention to enhance the exploitation of the global context, and propose the hybrid adaptive integration (HAI) for module integration. The HAI allows the direct and effective fusion between features at different levels (local or global). Extensive experiments demonstrate that our RGT outperforms recent state-of-the-art methods quantitatively and qualitatively. Code and pre-trained models are available at https://github.com/zhengchen1999/RGT.","url_abs":"https://arxiv.org/abs/2303.06373v4","url_pdf":"https://arxiv.org/pdf/2303.06373v4.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":"recursive-generalization-transformer-for","repo_url":"https://github.com/zhengchen1999/rgt","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok","spdx":"Apache-2.0"}}],"tasks":[{"task_slug":"image-reconstruction","task_name":"Image Reconstruction"},{"task_slug":"image-super-resolution","task_name":"Image Super-Resolution"},{"task_slug":"super-resolution","task_name":"Super-Resolution"}],"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":[{"leaderboard":"/sota/image-super-resolution-on-manga109-4x","task":"Image Super-Resolution","dataset":"Manga109 - 4x upscaling","model":"RGT+","rank_in_archive_order":10,"of":50,"metrics":{"PSNR":"32.68","SSIM":"0.9303"},"uses_additional_data":false},{"leaderboard":"/sota/image-super-resolution-on-manga109-4x","task":"Image Super-Resolution","dataset":"Manga109 - 4x upscaling","model":"RGT","rank_in_archive_order":14,"of":50,"metrics":{"PSNR":"32.50","SSIM":"0.9291"},"uses_additional_data":false},{"leaderboard":"/sota/image-super-resolution-on-set14-4x-upscaling","task":"Image Super-Resolution","dataset":"Set14 - 4x upscaling","model":"RGT+","rank_in_archive_order":14,"of":104,"metrics":{"PSNR":"29.28","SSIM":"0.7979"},"uses_additional_data":false},{"leaderboard":"/sota/image-super-resolution-on-set14-4x-upscaling","task":"Image Super-Resolution","dataset":"Set14 - 4x upscaling","model":"RGT","rank_in_archive_order":18,"of":104,"metrics":{"PSNR":"29.23","SSIM":"0.7972"},"uses_additional_data":false}],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=2303.06373","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2303.06373"}},"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":"deterministic:regex_extraction","url":"https://github.com/zhengchen1999/RGT","reach":{"status":"ok","spdx":"Apache-2.0"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/zhengchen1999/rgt","reach":{"status":"ok","spdx":"Apache-2.0"}}],"summary":{"ran_draft_wrong":4,"ran":4,"ran_fixture":1,"unverified":3},"by_repo_kind":{"official":{"samples":12,"ran":9,"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":0,"samples":[{"code_sha256_prefix":"ef9faf68f492a375","entry":"flow_warp","repo":"zhengchen1999/RGT","repo_kind":"official","path":"basicsr/archs/arch_util.py","file_url":"https://github.com/zhengchen1999/RGT/blob/HEAD/basicsr/archs/arch_util.py","link_basis":"harvester_set","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"MISDECLARED","metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"ef9faf68f492a375"}},{"code_sha256_prefix":"cd569444547de84f","entry":"get_position_from_periods","repo":"zhengchen1999/RGT","repo_kind":"official","path":"basicsr/models/lr_scheduler.py","file_url":"https://github.com/zhengchen1999/RGT/blob/HEAD/basicsr/models/lr_scheduler.py","link_basis":"harvester_set","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"cd569444547de84f"}},{"code_sha256_prefix":"15c613ecceb6aa71","entry":"img2windows","repo":"zhengchen1999/RGT","repo_kind":"official","path":"basicsr/archs/rgt_arch.py","file_url":"https://github.com/zhengchen1999/RGT/blob/HEAD/basicsr/archs/rgt_arch.py","link_basis":"harvester_set","language":"python","status":"ran_fixture","verification_level":1,"contract_check":"RAISES","metamorphic_tier":"invariant","behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"15c613ecceb6aa71"}},{"code_sha256_prefix":"5360d45b71ae2bb1","entry":"insert_bn","repo":"zhengchen1999/RGT","repo_kind":"official","path":"basicsr/archs/vgg_arch.py","file_url":"https://github.com/zhengchen1999/RGT/blob/HEAD/basicsr/archs/vgg_arch.py","link_basis":"harvester_set","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"OUTPUT_MISDECLARED","metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"5360d45b71ae2bb1"}},{"code_sha256_prefix":"96ad5dc9ca239aec","entry":"make_layer","repo":"zhengchen1999/RGT","repo_kind":"official","path":"basicsr/archs/arch_util.py","file_url":"https://github.com/zhengchen1999/RGT/blob/HEAD/basicsr/archs/arch_util.py","link_basis":"harvester_set","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"OUTPUT_MISDECLARED","metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"96ad5dc9ca239aec"}},{"code_sha256_prefix":"f6b0e1eb5b7df3e3","entry":"master_only","repo":"zhengchen1999/RGT","repo_kind":"official","path":"basicsr/utils/dist_util.py","file_url":"https://github.com/zhengchen1999/RGT/blob/HEAD/basicsr/utils/dist_util.py","link_basis":"harvester_set","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"f6b0e1eb5b7df3e3"}},{"code_sha256_prefix":"95067518dc16b3e5","entry":"reorder_image","repo":"zhengchen1999/RGT","repo_kind":"official","path":"basicsr/metrics/metric_util.py","file_url":"https://github.com/zhengchen1999/RGT/blob/HEAD/basicsr/metrics/metric_util.py","link_basis":"harvester_set","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"95067518dc16b3e5"}},{"code_sha256_prefix":"5a1d8458dc7077a6","entry":"resize_flow","repo":"zhengchen1999/RGT","repo_kind":"official","path":"basicsr/archs/arch_util.py","file_url":"https://github.com/zhengchen1999/RGT/blob/HEAD/basicsr/archs/arch_util.py","link_basis":"harvester_set","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"5a1d8458dc7077a6"}},{"code_sha256_prefix":"8cb23a62748d3b1c","entry":"windows2img","repo":"zhengchen1999/RGT","repo_kind":"official","path":"basicsr/archs/rgt_arch.py","file_url":"https://github.com/zhengchen1999/RGT/blob/HEAD/basicsr/archs/rgt_arch.py","link_basis":"harvester_set","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"MISDECLARED","metamorphic_tier":"invariant","behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"8cb23a62748d3b1c"}},{"code_sha256_prefix":"a648a03a952822c0","entry":"reduce_loss","repo":"zhengchen1999/RGT","repo_kind":"official","path":"basicsr/losses/loss_util.py","file_url":"https://github.com/zhengchen1999/RGT/blob/HEAD/basicsr/losses/loss_util.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":"a648a03a952822c0"}},{"code_sha256_prefix":"1ba39317ea81871a","entry":"weight_reduce_loss","repo":"zhengchen1999/RGT","repo_kind":"official","path":"basicsr/losses/loss_util.py","file_url":"https://github.com/zhengchen1999/RGT/blob/HEAD/basicsr/losses/loss_util.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":"1ba39317ea81871a"}},{"code_sha256_prefix":"cf63f8afc13f62a7","entry":"weighted_loss","repo":"zhengchen1999/RGT","repo_kind":"official","path":"basicsr/losses/loss_util.py","file_url":"https://github.com/zhengchen1999/RGT/blob/HEAD/basicsr/losses/loss_util.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":"cf63f8afc13f62a7"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}