AdjointDPM:用于扩散概率模型梯度反向传播的伴随敏感度方法
AdjointDPM: Adjoint Sensitivity Method for Gradient Backpropagation of Diffusion Probabilistic Models
AI总结:
提出AdjointDPM方法,通过伴随敏感度法和指数积分将概率流ODE重参数化为非刚性ODE,实现低内存消耗的梯度反向传播,有效解决基于可微度量监督的扩散模型定制化问题。
摘要:
现有的定制化方法需要访问多个参考样本,以将预训练的扩散概率模型(DPMs)与用户提供的概念对齐。本文旨在解决当唯一可用的监督信号是定义在生成内容上的可微度量时,DPM 定制化所面临的挑战。由于 DPM 的采样过程涉及对去噪 UNet 的递归调用,朴素的梯度反向传播需要存储所有迭代的中间状态,导致极高的内存消耗。为克服这一问题,我们提出了一种新方法 AdjointDPM,它首先通过求解相应的概率流 ODE 从扩散模型生成新样本。随后,它使用伴随敏感度方法,通过求解另一个增广 ODE,将损失的梯度反向传播到模型参数(包括条件信号、网络权重和初始噪声)。为了减少前向生成和梯度反向传播过程中的数值误差,我们进一步使用指数积分,将概率流 ODE 和增广 ODE 重新参数化为简单的非刚性 ODE。最后,我们在三个有趣的任务上展示了 AdjointDPM 的有效性:将视觉效转化为标识文本嵌入、针对特定风格化类型微调 DPM,以及优化初始噪声以生成用于安全审计的对抗样本。
英文摘要:
Existing customization methods require access to multiple reference examples to align pre-trained diffusion probabilistic models (DPMs) with user-provided concepts. This paper aims to address the challenge of DPM customization when the only available supervision is a differentiable metric defined on the generated contents. Since the sampling procedure of DPMs involves recursive calls to the denoising UNet, naïve gradient backpropagation requires storing the intermediate states of all iterations, resulting in extremely high memory consumption. To overcome this issue, we propose a novel method AdjointDPM, which first generates new samples from diffusion models by solving the corresponding probability-flow ODEs. It then uses the adjoint sensitivity method to backpropagate the gradients of the loss to the models' parameters (including conditioning signals, network weights, and initial noises) by solving another augmented ODE. To reduce numerical errors in both the forward generation and gradient backpropagation processes, we further reparameterize the probability-flow ODE and augmented ODE as simple non-stiff ODEs using exponential integration. Finally, we demonstrate the effectiveness of AdjointDPM on three interesting tasks: converting visual effects into identification text embeddings, finetuning DPMs for specific types of stylization, and optimizing initial noise to generate adversarial samples for security auditing.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。