Decouple-Then-Merge: Towards Better Training for Diffusion Models

Qianli Ma, Xuefei Ning, Dongrui Liu, Li Niu, Linfeng Zhang · DOI

Introduction

Diffusion models have revolutionized generative AI by iteratively denoising images from pure noise. However, these models are essentially multi-task learners. A single set of parameters must handle a sequence of distinct denoising tasks: early timesteps focus on global structure (low-frequency content), while later timesteps refine fine details (high-frequency content). This paper introduces Decouple-then-Merge (DeMe), a framework that addresses the inherent conflicts in this multi-task setup to improve image quality without increasing inference costs.

The Gradient Tug-of-War

The industry standard for training diffusion models involves sharing all model parameters across all timesteps. While efficient, this approach suffers from a fundamental flaw: gradient conflict.

Analysis of gradient similarity showing low similarity across different timestep ranges in traditional training vs. high similarity within decoupled ranges.

As shown in Figure 1, the optimization directions for different generation stages often clash. When a model attempts to learn global "mountain shapes" and local "snowflake textures" simultaneously using the same weights, the resulting gradients pull the parameters in opposing directions. This "tug-of-war" prevents the model from reaching its full potential, leading to a plateau in generation quality. Analysis of the loss landscape reveals that standard models often get stuck at "critical points" where the average gradient is zero, masking useful local gradients.

The DeMe Framework

To resolve these conflicts, the authors propose the Decouple-then-Merge (DeMe) framework, which operates in three distinct phases:

  1. Decoupling: The total timestep range (e.g., 0 to 1000) is divided into $N$ non-overlapping sub-ranges.
  2. Specialized Finetuning: A pretrained model is used to create $N$ separate versions, each finetuned specifically on one timestep range.
  3. Parameter Merging: The specialized models are merged back into a single set of weights using "task arithmetic."
The DeMe training paradigm: specialized finetuning of i-th diffusion models followed by model merging via task vectors.

As illustrated in Figure 5, the finetuning process incorporates several key techniques. A Consistency Loss ensures specialized models retain original knowledge, while Probabilistic Sampling prevents catastrophic forgetting by occasionally exposing the model to timesteps outside its specialty. Crucially, the authors introduce Channel-wise Projection layers—tiny learnable additions (comprising only 1.06% of parameters)—to capture timestep-specific features in the channel dimension, where most variation occurs.

Finally, "task vectors" (the difference between finetuned and pretrained weights) are computed for each range. Because these vectors are nearly orthogonal, they can be merged additively. The optimal merging weights are determined via a grid search, resulting in a single high-performance model that retains the "expertise" of all specialized versions.

Key Insights and Results

The researchers found that the expertise required for different timesteps is largely orthogonal. Improvements in "coarse structure" do not interfere with improvements in "fine detail," making them ideal for additive merging. Furthermore, they discovered that timestep-specific differences are primarily captured in the channel dimension rather than the spatial dimension.

DeMe consistently outperforms standard training across various benchmarks:

  • LSUN-Church: Achieved a significant FID reduction of 3.42 (from 10.69 to 7.27).
  • CIFAR10: Improved FID by 0.91 compared to the base DDPM.
  • Stable Diffusion: On MS-COCO, DeMe improved the CLIP score by 0.23 and reduced FID, indicating superior text-to-image alignment and visual quality.

Qualitatively, DeMe-finetuned models generate complex details—such as specific animal features or intricate architectural elements—where original models often fail to align with the prompt.

Conclusion

Decouple-then-Merge offers a powerful paradigm shift for diffusion training. By acknowledging and resolving gradient conflicts through specialized finetuning and subsequent merging, DeMe unlocks higher performance from existing architectures. Importantly, because the final result is a single merged model, these gains come with zero additional inference overhead, making it a highly practical solution for state-of-the-art image generation.

Summary updated

BibTeX
@inproceedings{ma2025decouple,
  author = {Qianli Ma and Xuefei Ning and Dongrui Liu and Li Niu and Linfeng Zhang},
  title = {{Decouple-Then-Merge: Towards Better Training for Diffusion Models}},
  booktitle = {IEEE/CVF Conference on Computer Vision and Pattern Recognition},
  year = {2025},
  doi = {10.1109/cvpr52734.2025.02168},
}
Figure