{"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/autoregressive-image-generation-with","title":"Autoregressive Image Generation with Randomized Parallel Decoding","arxiv_id":"2503.10568","date":"2025-03-13","proceeding":null,"authors":["Haopeng Li","Jinyue Yang","Guoqi Li","Huan Wang"],"abstract":"We introduce ARPG, a novel visual autoregressive model that enables randomized parallel generation, addressing the inherent limitations of conventional raster-order approaches, which hinder inference efficiency and zero-shot generalization due to their sequential, predefined token generation order. Our key insight is that effective random-order modeling necessitates explicit guidance for determining the position of the next predicted token. To this end, we propose a novel guided decoding framework that decouples positional guidance from content representation, encoding them separately as queries and key-value pairs. By directly incorporating this guidance into the causal attention mechanism, our approach enables fully random-order training and generation, eliminating the need for bidirectional attention. Consequently, ARPG readily generalizes to zero-shot tasks such as image inpainting, outpainting, and resolution expansion. Furthermore, it supports parallel inference by concurrently processing multiple queries using a shared KV cache. On the ImageNet-1K 256 benchmark, our approach attains an FID of 1.94 with only 64 sampling steps, achieving over a 20-fold increase in throughput while reducing memory consumption by over 75% compared to representative recent autoregressive models at a similar scale.","url_abs":"https://arxiv.org/abs/2503.10568v1","url_pdf":"https://arxiv.org/pdf/2503.10568v1.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":"autoregressive-image-generation-with","repo_url":"https://github.com/hp-l33/ARPG","is_official":1,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok","spdx":"MIT"}}],"tasks":[{"task_slug":"conditional-image-generation","task_name":"Conditional Image Generation"},{"task_slug":"image-generation","task_name":"Image Generation"},{"task_slug":"image-inpainting","task_name":"Image Inpainting"},{"task_slug":"zero-shot-generalization","task_name":"Zero-shot Generalization"}],"methods":[{"method_slug":"attention","method_name":"Attention"},{"method_slug":"softmax","method_name":"Softmax"}],"datasets_introduced":[],"methods_introduced":[],"results":[{"leaderboard":"/sota/image-generation-on-imagenet-256x256","task":"Image Generation","dataset":"ImageNet 256x256","model":"ARPG-XXL","rank_in_archive_order":44,"of":94,"metrics":{"FID":"1.94"},"uses_additional_data":false},{"leaderboard":"/sota/image-generation-on-imagenet-256x256","task":"Image Generation","dataset":"ImageNet 256x256","model":"ARPG-XL","rank_in_archive_order":51,"of":94,"metrics":{"FID":"2.1"},"uses_additional_data":false},{"leaderboard":"/sota/image-generation-on-imagenet-256x256","task":"Image Generation","dataset":"ImageNet 256x256","model":"ARPG-L","rank_in_archive_order":59,"of":94,"metrics":{"FID":"2.44"},"uses_additional_data":false}],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=2503.10568","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2503.10568"}},"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/hp-l33/ARPG","reach":{"status":"ok","spdx":"MIT"}}],"summary":{"ran_draft_wrong":5,"ran":4,"ran_fixture":1,"ran_honours":1,"unverified":7},"by_repo_kind":{"official":{"samples":18,"ran":11,"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":"01b5cf639b6bac89","entry":"Normalize","repo":"hp-l33/ARPG","repo_kind":"official","path":"models/vq_model.py","file_url":"https://github.com/hp-l33/ARPG/blob/HEAD/models/vq_model.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":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"01b5cf639b6bac89"}},{"code_sha256_prefix":"3a774664bfc712ec","entry":"adjust_learning_rate","repo":"hp-l33/ARPG","repo_kind":"official","path":"train_c2i.py","file_url":"https://github.com/hp-l33/ARPG/blob/HEAD/train_c2i.py","link_basis":"harvester_set","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":"3a774664bfc712ec"}},{"code_sha256_prefix":"02cb09299c18ee5d","entry":"build_t2i","repo":"hp-l33/ARPG","repo_kind":"official","path":"dataset/t2i.py","file_url":"https://github.com/hp-l33/ARPG/blob/HEAD/dataset/t2i.py","link_basis":"harvester_set","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":"02cb09299c18ee5d"}},{"code_sha256_prefix":"ff9ed4675cb307aa","entry":"build_t2i_code","repo":"hp-l33/ARPG","repo_kind":"official","path":"dataset/t2i.py","file_url":"https://github.com/hp-l33/ARPG/blob/HEAD/dataset/t2i.py","link_basis":"harvester_set","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":"ff9ed4675cb307aa"}},{"code_sha256_prefix":"090d7b6b1260114e","entry":"build_t2i_image","repo":"hp-l33/ARPG","repo_kind":"official","path":"dataset/t2i.py","file_url":"https://github.com/hp-l33/ARPG/blob/HEAD/dataset/t2i.py","link_basis":"harvester_set","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":"090d7b6b1260114e"}},{"code_sha256_prefix":"1712a07966b542ee","entry":"center_crop_arr","repo":"hp-l33/ARPG","repo_kind":"official","path":"dataset/augmentation.py","file_url":"https://github.com/hp-l33/ARPG/blob/HEAD/dataset/augmentation.py","link_basis":"harvester_set","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"MISDECLARED","metamorphic_tier":"well_formed","behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"1712a07966b542ee"}},{"code_sha256_prefix":"774c95b77d7621f3","entry":"compute_entropy_loss","repo":"hp-l33/ARPG","repo_kind":"official","path":"models/vq_model.py","file_url":"https://github.com/hp-l33/ARPG/blob/HEAD/models/vq_model.py","link_basis":"harvester_set","language":"python","status":"ran_fixture","verification_level":1,"contract_check":"RAISES","metamorphic_tier":"invariant","behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"774c95b77d7621f3"}},{"code_sha256_prefix":"ba65976c1d96a7cb","entry":"creat_optimizer","repo":"hp-l33/ARPG","repo_kind":"official","path":"train_c2i.py","file_url":"https://github.com/hp-l33/ARPG/blob/HEAD/train_c2i.py","link_basis":"harvester_set","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"MISDECLARED","metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"ba65976c1d96a7cb"}},{"code_sha256_prefix":"7b21a01ae77703a3","entry":"create_npz_from_sample_folder","repo":"hp-l33/ARPG","repo_kind":"official","path":"sample_c2i_ddp.py","file_url":"https://github.com/hp-l33/ARPG/blob/HEAD/sample_c2i_ddp.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":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"7b21a01ae77703a3"}},{"code_sha256_prefix":"f6ff7671338c9c92","entry":"find_multiple","repo":"hp-l33/ARPG","repo_kind":"official","path":"models/arpg.py","file_url":"https://github.com/hp-l33/ARPG/blob/HEAD/models/arpg.py","link_basis":"harvester_set","language":"python","status":"ran_honours","verification_level":1,"contract_check":"HONOURS","metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"f6ff7671338c9c92"}},{"code_sha256_prefix":"3137073275f8c21a","entry":"nonlinearity","repo":"hp-l33/ARPG","repo_kind":"official","path":"models/vq_model.py","file_url":"https://github.com/hp-l33/ARPG/blob/HEAD/models/vq_model.py","link_basis":"harvester_set","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"MISDECLARED","metamorphic_tier":"invariant","behaviour_fingerprint":true,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"3137073275f8c21a"}},{"code_sha256_prefix":"69acd83901569c6a","entry":"batch_seq_shuffle","repo":"hp-l33/ARPG","repo_kind":"official","path":"models/arpg.py","file_url":"https://github.com/hp-l33/ARPG/blob/HEAD/models/arpg.py","link_basis":"harvester_set","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":"69acd83901569c6a"}},{"code_sha256_prefix":"a5dc3fcd09ebc843","entry":"build_coco","repo":"hp-l33/ARPG","repo_kind":"official","path":"dataset/coco.py","file_url":"https://github.com/hp-l33/ARPG/blob/HEAD/dataset/coco.py","link_basis":"harvester_set","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":"a5dc3fcd09ebc843"}},{"code_sha256_prefix":"c5aec8b86d5fb5f7","entry":"build_imagenet_code","repo":"hp-l33/ARPG","repo_kind":"official","path":"dataset/imagenet.py","file_url":"https://github.com/hp-l33/ARPG/blob/HEAD/dataset/imagenet.py","link_basis":"harvester_set","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":"c5aec8b86d5fb5f7"}},{"code_sha256_prefix":"0a65aaf586d4f90b","entry":"build_openimage","repo":"hp-l33/ARPG","repo_kind":"official","path":"dataset/openimage.py","file_url":"https://github.com/hp-l33/ARPG/blob/HEAD/dataset/openimage.py","link_basis":"harvester_set","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":"0a65aaf586d4f90b"}},{"code_sha256_prefix":"a2c47fee1f9960c8","entry":"create_deepspeed_config","repo":"hp-l33/ARPG","repo_kind":"official","path":"utils/deepspeed.py","file_url":"https://github.com/hp-l33/ARPG/blob/HEAD/utils/deepspeed.py","link_basis":"harvester_set","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":"a2c47fee1f9960c8"}},{"code_sha256_prefix":"0f0ff4e443413018","entry":"precompute_freqs_cis","repo":"hp-l33/ARPG","repo_kind":"official","path":"models/arpg.py","file_url":"https://github.com/hp-l33/ARPG/blob/HEAD/models/arpg.py","link_basis":"harvester_set","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":"0f0ff4e443413018"}},{"code_sha256_prefix":"980fb099f82d8b84","entry":"random_crop_arr","repo":"hp-l33/ARPG","repo_kind":"official","path":"dataset/augmentation.py","file_url":"https://github.com/hp-l33/ARPG/blob/HEAD/dataset/augmentation.py","link_basis":"harvester_set","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":"980fb099f82d8b84"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}