{"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/uni-3dar-unified-3d-generation-and","title":"Uni-3DAR: Unified 3D Generation and Understanding via Autoregression on Compressed Spatial Tokens","arxiv_id":"2503.16278","date":"2025-03-20","proceeding":null,"authors":["Shuqi Lu","Haowei Lin","Lin Yao","Zhifeng Gao","Xiaohong Ji","Weinan E","Linfeng Zhang","Guolin Ke"],"abstract":"Recent advancements in large language models and their multi-modal extensions have demonstrated the effectiveness of unifying generation and understanding through autoregressive next-token prediction. However, despite the critical role of 3D structural generation and understanding (3D GU) in AI for science, these tasks have largely evolved independently, with autoregressive methods remaining underexplored. To bridge this gap, we introduce Uni-3DAR, a unified framework that seamlessly integrates 3D GU tasks via autoregressive prediction. At its core, Uni-3DAR employs a novel hierarchical tokenization that compresses 3D space using an octree, leveraging the inherent sparsity of 3D structures. It then applies an additional tokenization for fine-grained structural details, capturing key attributes such as atom types and precise spatial coordinates in microscopic 3D structures. We further propose two optimizations to enhance efficiency and effectiveness. The first is a two-level subtree compression strategy, which reduces the octree token sequence by up to 8x. The second is a masked next-token prediction mechanism tailored for dynamically varying token positions, significantly boosting model performance. By combining these strategies, Uni-3DAR successfully unifies diverse 3D GU tasks within a single autoregressive framework. Extensive experiments across multiple microscopic 3D GU tasks, including molecules, proteins, polymers, and crystals, validate its effectiveness and versatility. Notably, Uni-3DAR surpasses previous state-of-the-art diffusion models by a substantial margin, achieving up to 256\\% relative improvement while delivering inference speeds up to 21.8x faster. The code is publicly available at https://github.com/dptech-corp/Uni-3DAR.","url_abs":"https://arxiv.org/abs/2503.16278v2","url_pdf":"https://arxiv.org/pdf/2503.16278v2.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":"uni-3dar-unified-3d-generation-and","repo_url":"https://github.com/dptech-corp/uni-3dar","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok","spdx":"MIT"}}],"tasks":[{"task_slug":"3d-generation","task_name":"3D Generation"}],"methods":[{"method_slug":"diffusion","method_name":"Diffusion"}],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=2503.16278","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2503.16278"}},"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/dptech-corp/uni-3dar","reach":{"status":"ok","spdx":"MIT"}}],"summary":{"ran_honours":1,"unverified":8},"by_repo_kind":{"official":{"samples":9,"ran":1,"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":"62fcb3912a967a50","entry":"modulate","repo":"dptech-corp/uni-3dar","repo_kind":"official","path":"uni3dar/models/diffusion_prediction_head.py","file_url":"https://github.com/dptech-corp/uni-3dar/blob/HEAD/uni3dar/models/diffusion_prediction_head.py","link_basis":"harvester_set","language":"python","status":"ran_honours","verification_level":1,"contract_check":"HONOURS","metamorphic_tier":"invariant","behaviour_fingerprint":true,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"62fcb3912a967a50"}},{"code_sha256_prefix":"c6550c26a0c0b895","entry":"check_files_count","repo":"dptech-corp/uni-3dar","repo_kind":"official","path":"uni3dar/inference.py","file_url":"https://github.com/dptech-corp/uni-3dar/blob/HEAD/uni3dar/inference.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":"c6550c26a0c0b895"}},{"code_sha256_prefix":"25d6d5385209908e","entry":"get_causal_mask","repo":"dptech-corp/uni-3dar","repo_kind":"official","path":"uni3dar/models/attention.py","file_url":"https://github.com/dptech-corp/uni-3dar/blob/HEAD/uni3dar/models/attention.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":"25d6d5385209908e"}},{"code_sha256_prefix":"e062cdaaece8f126","entry":"get_freqs","repo":"dptech-corp/uni-3dar","repo_kind":"official","path":"uni3dar/models/rope.py","file_url":"https://github.com/dptech-corp/uni-3dar/blob/HEAD/uni3dar/models/rope.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":"e062cdaaece8f126"}},{"code_sha256_prefix":"dc32c3de54b203ae","entry":"process_with_file_cache","repo":"dptech-corp/uni-3dar","repo_kind":"official","path":"evaluation_scripts/crystal/crystal_metrics.py","file_url":"https://github.com/dptech-corp/uni-3dar/blob/HEAD/evaluation_scripts/crystal/crystal_metrics.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":"dc32c3de54b203ae"}},{"code_sha256_prefix":"e5baea51cffad231","entry":"reduce_bi_classification","repo":"dptech-corp/uni-3dar","repo_kind":"official","path":"uni3dar/losses/metric_reduce.py","file_url":"https://github.com/dptech-corp/uni-3dar/blob/HEAD/uni3dar/losses/metric_reduce.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":"e5baea51cffad231"}},{"code_sha256_prefix":"85ed0d506cc1fee1","entry":"reduce_regression","repo":"dptech-corp/uni-3dar","repo_kind":"official","path":"uni3dar/losses/metric_reduce.py","file_url":"https://github.com/dptech-corp/uni-3dar/blob/HEAD/uni3dar/losses/metric_reduce.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":"85ed0d506cc1fee1"}},{"code_sha256_prefix":"d782e68b5c51ebad","entry":"reduce_regression_atom","repo":"dptech-corp/uni-3dar","repo_kind":"official","path":"uni3dar/losses/metric_reduce.py","file_url":"https://github.com/dptech-corp/uni-3dar/blob/HEAD/uni3dar/losses/metric_reduce.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":"d782e68b5c51ebad"}},{"code_sha256_prefix":"0e96e2a74a19fb14","entry":"softmax_sampling","repo":"dptech-corp/uni-3dar","repo_kind":"official","path":"uni3dar/models/uni3dar_sampler.py","file_url":"https://github.com/dptech-corp/uni-3dar/blob/HEAD/uni3dar/models/uni3dar_sampler.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":"0e96e2a74a19fb14"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}