Papers › Local Mechanisms of Compositional Generalization in Conditional Diffusion

Local Mechanisms of Compositional Generalization in Conditional Diffusion

19 Sep 2025ICMLarXiv:2509.16447added by Syntology

Arwen Bradley

Title, abstract, authors and date from arXiv's metadata (CC0); this paper is not in the Papers with Code archive (frozen 2025-07-28).

Conditional diffusion models appear capable of compositional generalization, i.e., generating convincing samples for out-of-distribution combinations of conditioners, but the mechanisms underlying this ability remain unclear. To make this concrete, we study length generalization, the ability to generate images with more objects than seen during training. In a controlled CLEVR setting (Johnson et al., 2017), we find that length generalization is achievable in some cases but not others, suggesting that models only sometimes learn the underlying compositional structure. We then investigate locality as a structural mechanism for compositional generalization. Prior works proposed score locality as a mechanism for creativity in unconditional diffusion models (Kamb & Ganguli, 2024; Niedoba et al., 2024), but did not address flexible conditioning or compositional generalization. In this paper, we prove an exact equivalence between a specific compositional structure ("conditional projective composition") (Bradley et al., 2025) and scores with sparse dependencies on both pixels and conditioners ("local conditional scores"). This theory also extends to feature-space compositionality. We validate our theory empirically: CLEVR models that succeed at length generalization exhibit local conditional scores, while those that fail do not. Furthermore, we show that a causal intervention explicitly enforcing local conditional scores restores length generalization in a previously failing model. Finally, we investigate SDXL and find that in pixel-space, spatial locality is present but conditional-locality is mostly absent; however, we find quantitative evidence of local conditional scores in the network's learned feature-space.

PaperPDFCode Syntology ran

In Syntology Open this paper in Syntology's Atlas, the map of the papers in Syntology's graph and their citations.

For agents, Syntology's MCP tool lists every function and class Syntology harvested from this paper and whether it ran (how to connect): get_harvested_code_for_paper(arxiv_id="2509.16447")

Code

Syntology Ran 15 of 17 code samples harvested from 1 repository linked to this paper; 2 have no recorded run. Of those that ran: 2 ran · honoured contract; 2 ran · our draft was wrong; 11 ran with no contract checked.

By repository: found in paper text by Syntology: 17 samples from 1 repository, 15 ran. The run record, sample by sample. “Ran” means executed on a synthesized input, not that the code is correct or reproduces the paper.

NVlabs/edm2 found in paper text by SyntologyNOASSERTION report

Reachability, where shown, is from one Syntology probe window (2026-09-16 to 2026-09-18); repositories not probed show nothing. GitHub stars are not tracked.

Code Syntology ran Syntology

17 samples harvested; 15 ran; 2 honoured the contract we drafted; 2 have no recorded run. Read from Syntology's graph 2026-09-24; that is when this build read the record, not when the samples ran.

2ran · honoured contract
2ran · our draft was wrong
11ran
2unverified

Licence: 17 of the 17 samples are pointer only, meaning Syntology does not serve that copy's text. This page shows no code text for any sample; each one links to its file in the repository.

Harvested from NVlabs/edm2. “Ran” means the sample executed on a synthesized input. It does not mean the output is correct, and nothing here reproduces the paper's results. “Honoured” and “violated” refer to a contract Syntology drafted from the code itself; “our draft was wrong” and “fixture could not drive it” are failures of Syntology's instrument, not of the code.

Each sample ends with its code_sha256, Syntology's identity for that exact code. An agent fetches the stored sample with Syntology's MCP tool get_code(code_sha256="…") (how to connect); click an identity to copy that call.

Repository labels, per sample. official repository: The archive marks this repository official for the paper. named in the paper: The archive records that the paper mentions this repository; it is not marked official. community (archive-listed): In the archive's code links for this paper, not marked official and not recorded as mentioned in the paper. found in paper text by Syntology: 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. Samples from a repository marked official are listed first. Licence labels name the repository's licence as recorded at harvest. “Pointer only” means Syntology does not serve that copy's text, for one of four reasons: no licence file was found; the licence was not identified; the licence is recorded as permissive but that copy's record is not marked cleared; or the licence is outside the permissive list Syntology serves text under (MIT, Apache-2.0, BSD and similar). Some licences outside that list permit redistribution, such as WTFPL, and GPL-3.0 under its conditions; they are simply not on the list. Hover a licence label for the reason. File links open the file on GitHub at the default branch, which may have changed since the harvest.

const_like NVlabs/edm2/torch_utils/misc.py found in paper text by Syntology ran no licence file found · pointer only · f2514403e004d82b · report
constant NVlabs/edm2/torch_utils/misc.py found in paper text by Syntology ran no licence file found · pointer only · 6d32f9cf6f29b386 · report
do_sample NVlabs/edm2/toy_example.py found in paper text by Syntology ran no licence file found · pointer only · d885af9905e22f98 · report
edm_sampler NVlabs/edm2/generate_images.py found in paper text by Syntology ran · our draft was wrong no licence file found · pointer only · a14db9805bf41197 · report
file_ext NVlabs/edm2/dataset_tool.py found in paper text by Syntology ran · our draft was wrong fingerprinted no licence file found · pointer only · a2b45afa097b55b6 · report
format_time NVlabs/edm2/dnnlib/util.py found in paper text by Syntology ran fingerprinted no licence file found · pointer only · 863886ae28872158 · report
format_time_brief NVlabs/edm2/dnnlib/util.py found in paper text by Syntology ran fingerprinted no licence file found · pointer only · cf4282fe49551c8c · report
kimg_to_nimg NVlabs/edm2/reconstruct_phema.py found in paper text by Syntology ran fingerprinted no licence file found · pointer only · b454b0c7002712e3 · report
maybe_min NVlabs/edm2/dataset_tool.py found in paper text by Syntology ran · honoured contract no licence file found · pointer only · dd1dc700e87f36cc · report
mp_silu NVlabs/edm2/training/networks_edm2.py found in paper text by Syntology ran fingerprinted no licence file found · pointer only · 49d89884be5dc515 · report
normalize NVlabs/edm2/training/networks_edm2.py found in paper text by Syntology ran no licence file found · pointer only · ebfd171dc25ba0ce · report
parse_int_list NVlabs/edm2/generate_images.py found in paper text by Syntology ran · honoured contract no licence file found · pointer only · cacd4f6ec202d9b4 · report
parse_nimg NVlabs/edm2/train_edm2.py found in paper text by Syntology ran no licence file found · pointer only · fcf68d736821de45 · report
parse_tuple NVlabs/edm2/dataset_tool.py found in paper text by Syntology ran no licence file found · pointer only · 07b21b35ecb4815c · report
tuple_product NVlabs/edm2/dnnlib/util.py found in paper text by Syntology ran fingerprinted no licence file found · pointer only · d0955d86500b69a3 · report
is_persistent NVlabs/edm2/torch_utils/persistence.py found in paper text by Syntology unverified no licence file found · pointer only · e8b31ffccfa05efc · report
pinned_buf NVlabs/edm2/torch_utils/misc.py found in paper text by Syntology unverified no licence file found · pointer only · 3e8b4a53ca71135e · report

Results from the paper

The Papers with Code archive ends with its 2025-07-28 snapshot. This paper's arXiv identifier, 2509.16447, was issued in September 2025, after that date, so the archive has no leaderboard rows for it.

Report a problem or propose a change · a person checks every report against the paper or source before anything changes; decisions are listed on /corrections