Imbalance in Balance: Online Concept Balancing in Generation Models

Yukai Shi, Jiarong Ou, Rui Chen, Haotian Yang, Jiahao Wang, Xin Tao, Pengfei Wan, Di Zhang, Kun Gai

TL;DR

This paper tackles the challenge of accurately generating images with multiple concepts by introducing a novel "IMBA loss" that dynamically balances concept frequencies during training. This approach significantly improves concept composition, addressing issues like missing objects and attribute leakage, and is compatible with existing diffusion models.

What Problem Does This Paper Address?

Modern text-to-image generation models are incredibly powerful, capable of creating realistic and imaginative visuals. However, they often struggle with a crucial aspect: accurately combining multiple concepts described in a text prompt. This can manifest as missing objects (e.g., a prompt mentioning "twins" but only showing one person), attribute leakage (e.g., an object having the wrong color or texture), or concept entanglement (where concepts are mixed in unintended ways). While previous research has explored this, the authors argue that the underlying causes and effective solutions for this "concept composition" problem remain under-explored, especially in the context of large-scale, real-world datasets. They aim to bridge the gap between simplified synthetic experiments and the complexities of practical text-to-image generation.

Methods

The core contribution of this paper is the IMBA loss, an online concept-wise equalization strategy. Instead of relying on offline dataset processing, IMBA loss dynamically adjusts the training process to better balance the representation of different concepts.

Here's a breakdown of their approach:

  • Causal Analysis: They first conduct extensive experiments to identify the key factors influencing concept composition. Their findings suggest that once models and datasets reach a certain scale, the data distribution becomes the primary bottleneck, more so than model size.
  • IMBA Distance: To quantify data imbalance, they introduce the "IMBA distance." This metric, derived from the difference between conditional and unconditional distributions of concepts, effectively captures the frequency proportion of concepts in the dataset.
  • IMBA Loss: This is the practical implementation of their idea. It's a modification to the standard diffusion model training loss. The IMBA loss uses the calculated IMBA distance to dynamically re-weight the loss for different concepts during training. This ensures that under-represented (tail) concepts receive more attention, leading to better composition. The loss is designed to be "online," meaning it integrates seamlessly into the existing training loop with minimal code changes and without requiring offline dataset manipulation.
  • Inert-CompBench: To better evaluate concept composition, especially for challenging combinations, they introduce a new benchmark. This benchmark focuses on "inert concepts" – low-frequency concepts that are difficult to combine with others.

Datasets

  • Training: The authors use a re-captioned and filtered version of an open-source dataset, resulting in 31 million text-image pairs.
  • Evaluation: They evaluate their method on three benchmarks:
  • LC-Mis benchmark [60]
    • T2I-CompBench [18]
    • Inert-CompBench (newly introduced): This benchmark is specifically designed to test the model's ability to compose challenging, low-frequency concept pairs, which are often overlooked in existing benchmarks. It's constructed by extracting head and tail concepts, forming Cartesian products, and filtering for statistically weak combinations.

Key Insights and Ideas

  • Data Distribution is King (at Scale): For large-scale text-to-image models, the distribution of concepts in the training data is a more critical factor for concept composition than simply increasing model size beyond a certain point.
  • Online Balancing is Efficient: Dynamically adjusting loss weights during training (IMBA loss) is more effective and efficient than offline dataset balancing, especially for complex text-image tasks where defining precise class labels is difficult.
  • Tail Concepts are the Bottleneck: Low-frequency concepts ("tail concepts") are significantly harder for models to compose accurately, leading to higher failure rates. This highlights the need for specialized benchmarks and training strategies that focus on these challenging cases.
  • IMBA Distance as a Metric: The proposed IMBA distance provides a self-equilibrated and effective way to measure data distribution imbalance within the training process itself.

Key Results

  • Improved Concept Composition: Their IMBA loss significantly enhances concept composition ability across multiple benchmarks, outperforming baseline diffusion models and even a training-free method (A&E [5]).
  • Quantitative Gains: On the LC-Mis benchmark, their method achieved a VQA score of 62.89%, a substantial improvement over the baseline's 46.21%. Similar improvements were observed on T2I-CompBench and their new Inert-CompBench.
  • Addressing Specific Failures: They effectively address object missing and attribute leakage issues.
  • Inert-CompBench Performance: Their method shows significant advantages on the Inert-CompBench, demonstrating its ability to handle difficult concept combinations.
  • Training-from-Scratch Advantage: Training from scratch with IMBA loss yielded better results than fine-tuning a pre-trained model, suggesting the importance of balanced data distribution from the outset.

Limitations and Future Work

  • Computational Cost: While the IMBA loss is "online," it still adds computational overhead during training compared to standard diffusion loss.
  • Hyperparameter Tuning: The paper mentions ablation studies on hyper-parameters (e.g., $\gamma$, $\lambda$), indicating that optimal settings might require careful tuning.
  • Future Work: The authors suggest that their method is orthogonal to training-free methods and can be combined to further enhance concept composition. They also implicitly point towards the need for more sophisticated benchmarks like Inert-CompBench to push the boundaries of generative model evaluation.

Summary updated

BibTeX
@inproceedings{shi2025imbalance,
  author = {Yukai Shi and Jiarong Ou and Rui Chen and Haotian Yang and Jiahao Wang and Xin Tao and Pengfei Wan and Di Zhang and Kun Gai},
  title = {{Imbalance in Balance: Online Concept Balancing in Generation Models}},
  booktitle = {IEEE/CVF International Conference on Computer Vision},
  year = {2025},
}
Figure