# Dancing Diffusion: Learning Continuous Programs for Image Generation and Editing

DevFeed: [Dancing Diffusion: Learning Continuous Programs for Image Generation and Editing](<https://devfeed.tech/articles/dancing-diffusion-learning-continuous-programs-for-image-generation-and-editing-98009.md>)

Original publisher: [Read original article](<https://arxiv.org/abs/2610.28003>)

Author: Cui Enhe, Jinyue Yang, Bojian Yin, Guoqi Li

Published: 2026-10-23T04:00:00Z

Content type: article

Language: en

Sources: [arXiv: Artificial Intelligence](<https://devfeed.tech/sources/arxiv-artificial-intelligence.md>)

Topics: [ai-image-generator](<https://devfeed.tech/topics/ai-image-generator.md>), [image editing](<https://devfeed.tech/topics/image-editing.md>), [Image](<https://devfeed.tech/topics/image.md>)

Tags: [change](<https://devfeed.tech/tags/change.md>), [continuous](<https://devfeed.tech/tags/continuous.md>), [cs-ai](<https://devfeed.tech/tags/cs-ai.md>), [cs-gr](<https://devfeed.tech/tags/cs-gr.md>), [diffusion](<https://devfeed.tech/tags/diffusion.md>), [image-generation](<https://devfeed.tech/tags/image-generation.md>), [learning](<https://devfeed.tech/tags/learning.md>), [operations](<https://devfeed.tech/tags/operations.md>), [program](<https://devfeed.tech/tags/program.md>)

## AI overview

Dancing Diffusion turns diffusion conditioning into a latent program: a compiler maps text features to continuous condition blocks, which a fixed pretrained generator executes over successive timestep spans. The method reuses an executed prefix so later operations can be redirected while preserving content established earlier; the compiler is trained using visual feedback on both requested changes and retained content. On SANA, prefix reuse preserves more of the scene than regenerating from noise at similar edit strength, learned conditions preserve more background than native prompt switching from the same saved state, and the learned program improves generation quality over native SANA. Later branches weaken the edit, limiting semantic control over individual operations.

## Source excerpt

arXiv:2610.28003v2 Announce Type: replace Abstract: Diffusion models generate samples through a multi-step denoising trajectory, yet condition every step on the same instruction, so the trajectory cannot be addressed at the level of individual operations. We introduce Dancing Diffusion, which assigns each span of timesteps a dedicated continuous condition block and thereby turns conditioning into a latent program. A compiler maps text features into this program, and a fixed pretrained generator executes its blocks over successive sampling intervals. The trajectory can then dance, keeping its executed history while its continuation is redirected. A shared prefix is executed once and reused, and a later operation is rewritten while content fixed by earlier operations is preserved. The compiler is trained through the images it produces, with visual feedback on both the requested change and the retained content. On SANA, reusing an executed prefix preserves markedly more of the scene than regenerating from noise at a similar strength of edit, learned conditions preserve more background than native prompt switching from the same saved state, and the learned program improves generation quality over native SANA. Later branches weaken the edit, which leaves semantic control over individual operations limited. By converting a single-instruction trajectory into a program of addressable operations, Dancing Diffusion lays a foundation for structured intermediate computation in diffusion models.