平滑化エネルギーガイダンス:アテンションのエネルギー曲率を低減した拡散モデルのガイダンス
Smoothed Energy Guidance: Guiding Diffusion Models with Reduced Energy Curvature of Attention
August 1, 2024
著者: Susung Hong
cs.AI
要旨
条件付き拡散モデルは、主に分類器不要ガイダンス(CFG)の導入により、視覚コンテンツ生成において顕著な成功を収め、様々な領域で高品質なサンプルを生成してきました。最近では、無条件モデルへのガイダンス拡張の試みがヒューリスティックな手法に依存しており、生成品質の低下や意図しない効果が生じていました。本研究では、自己注意機構のエネルギーに基づく視点を活用し、画像生成を向上させる新しいトレーニング不要かつ条件不要のアプローチであるSmoothed Energy Guidance(SEG)を提案します。自己注意のエネルギーを定義することで、注意のエネルギーランドスケープの曲率を低減する手法を導入し、その出力を無条件予測として使用します。実践的には、ガイダンススケールパラメータを固定したまま、ガウシアンカーネルパラメータを調整することでエネルギーランドスケープの曲率を制御します。さらに、トークン数の二次的な複雑さを伴わずに、全体の注意重みをぼかすことに等しいクエリぼかし手法を提示します。実験では、SEGが品質と副作用の低減の両方においてパレート改善を達成しました。コードはhttps://github.com/SusungHong/SEG-SDXLで公開されています。
English
Conditional diffusion models have shown remarkable success in visual content
generation, producing high-quality samples across various domains, largely due
to classifier-free guidance (CFG). Recent attempts to extend guidance to
unconditional models have relied on heuristic techniques, resulting in
suboptimal generation quality and unintended effects. In this work, we propose
Smoothed Energy Guidance (SEG), a novel training- and condition-free approach
that leverages the energy-based perspective of the self-attention mechanism to
enhance image generation. By defining the energy of self-attention, we
introduce a method to reduce the curvature of the energy landscape of attention
and use the output as the unconditional prediction. Practically, we control the
curvature of the energy landscape by adjusting the Gaussian kernel parameter
while keeping the guidance scale parameter fixed. Additionally, we present a
query blurring method that is equivalent to blurring the entire attention
weights without incurring quadratic complexity in the number of tokens. In our
experiments, SEG achieves a Pareto improvement in both quality and the
reduction of side effects. The code is available at
https://github.com/SusungHong/SEG-SDXL.Summary
AI-Generated Summary