Assessing Open-world Forgetting in Generative Image Model Customization

Héctor Laria Mantecon, Alex Gomez-Villa, Imad Eddine Marouf, Kai Wang, Bogdan Raducanu, Joost van de Weijer · DOI

TL;DR

Fine-tuning diffusion models for customization, like adding new concepts, can cause "open-world forgetting," where the model's understanding of existing concepts degrades significantly, impacting both semantic meaning and visual appearance. This paper introduces methods to measure this forgetting and proposes a functional regularization technique to mitigate it, preserving original capabilities while allowing for successful customization.

What Problem Does This Paper Address?

Recent diffusion models are incredibly powerful for image generation, but adapting them to new tasks or concepts (e.g., teaching a model to generate a specific person or object) often leads to unintended side effects. This phenomenon, termed "open-world forgetting," is distinct from the more studied "closed-world forgetting" where performance is only evaluated on a fixed set of known classes. Open-world forgetting is harder to measure because foundation models have vast, unconstrained knowledge. The authors highlight that even minor adaptations, like fine-tuning on just a few images, can drastically alter the model's understanding of unrelated concepts, leading to unreliable and unpredictable outputs. This is particularly concerning for safety-critical applications.

Methods

The paper introduces a systematic investigation into open-world forgetting by analyzing two key types of "drift":

  • Semantic Drift: This is measured using the diffusion model's emergent zero-shot classification capabilities. By comparing a model's performance on a diverse set of classification tasks before and after customization, the authors quantify how much its understanding of existing concepts has degraded.
  • Appearance Drift: This is assessed by analyzing changes in texture, color, and overall visual attributes of generated images. A novel metric, the Color Drift Index (CDI), is introduced, which measures the difference in color distributions between images generated by the base model and the customized model. This is complemented by traditional metrics like Kernel Inception Distance (KID).

To combat this forgetting, the authors propose a functional regularization strategy called "drift correction." This method adds a penalty during training that constrains the difference between the outputs of the pre-trained and fine-tuned models when the new concept is not present in the prompt, effectively encouraging the model to retain its original knowledge.

Datasets

  • DiffusionDB (2M prompts): Used for evaluating open-world forgetting across various prompts.
  • CustomConcept101: A dataset of 10 concepts used for training and evaluating customized models (e.g., 'lamp', 'vase', 'person', 'cat', 'dog', 'lighthouse', 'waterfall', 'bike', 'car').
  • Image Classification Datasets: CIFAR10, STL10, Flowers, Pets, ObjectNet, Food, and Aircraft were used for evaluating semantic drift via zero-shot classification.
  • Torralba & Oliva (2003) dataset: Used for appearance drift experiments.

Key Insights and Ideas

  • Open-world forgetting is pervasive: Even minor fine-tuning on a few images can cause significant degradation in a diffusion model's understanding of previously learned concepts, affecting areas far beyond the new concept.
  • Semantic drift is severe: Zero-shot classification accuracy can drop by as much as 60% for some classes after customization, indicating a fundamental shift in the model's internal representations.
  • Appearance drift is also significant: Customization alters texture, color, and intra-class variations, making generated images less consistent with the original model's output.
  • Drift Correction is effective: The proposed functional regularization method significantly reduces both semantic and appearance drift, preserving original capabilities while allowing for successful customization.
  • Forgetting is inherent to weight modification: The study suggests that open-world forgetting is a general phenomenon that occurs across various model modification approaches (customization, unlearning, quantization), not just specific to diffusion models or customization tasks.

Key Results

  • Semantic Drift: Adapting a diffusion model to just five images of a new concept led to average zero-shot performance drops of over 4% on datasets like CIFAR10, with worst-class drops exceeding 60%.
  • Drift Correction Efficacy: The proposed Drift Correction method reduced average zero-shot classification accuracy drops to within 1% of the base model.
  • Appearance Drift: The Color Drift Index (CDI) and Kernel Inception Distance (KID) showed significant increases for customized models compared to the base model, indicating substantial appearance drift. Drift Correction significantly reduced these values.
  • User Study: Participants preferred drift-corrected outputs 66% of the time over baseline customization, validating the quantitative findings with human perception.
  • Scale-Invariance: The findings suggest that semantic drift is scale-invariant, meaning insights from small-scale evaluations generalize to larger concept sets.

Limitations and Future Work

  • Computational Constraints: For the Diffusion Classifier, some parameters were modified due to computational constraints, though the authors state this resulted in minimal percentual score uncertainty.
  • Future Research: The authors suggest exploring optimization methods to identify the most affected areas in the latent space during adaptation. They also note that their metrics could be useful for studying other operations like unlearning and quantization. The paper also mentions that while their method significantly reduces drift, some level of drift may still persist, especially for appearance drift.

Summary updated

BibTeX
@misc{mantecon2024assessing,
  author = {Héctor Laria Mantecon and Alex Gomez-Villa and Imad Eddine Marouf and Kai Wang and Bogdan Raducanu and Joost van de Weijer},
  title = {{Assessing Open-world Forgetting in Generative Image Model Customization}},
  year = {2024},
  eprint = {2410.14159},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2410.14159},
}
Figure