更具体的说,本文方法将一个主题(例如,一只特定的狗)和相应类名(例如,狗类别)的一些图像(通常 3 - 5 张图)作为输入,并返回一个经过微调 / 个性化的文本到图像模型,该模型编码了一个引用主题的唯一标识符。然后,在推理时,可以在不同的句子中植入唯一标识符来合成不同语境中的主题。

该研究的第一个任务是将主题实例植入到模型的输出域,并将主题与唯一标识符绑定。该研究提出了设计标识符的方法,此外还设计了一种监督模型微调过程的新方法。
为了解决图像过拟合以及语言漂移问题,该研究还提出了一种损失( Prior-Preservation Loss ),通过鼓励扩散模型不断生成与主题相同的类的不同实例,从而减轻模型过拟合、语言漂移等问题。
为了保留图像细节,该研究发现应该对模型的超分辨率(SR)组件进行微调,本文在经过预训练的 Imagen 模型的基础上来完成。具体过程如图 4 所示,给定同一主题的 3-5 张图像,之后通过两个步骤微调文本到图像的扩散模型:

稀有 token 标识符表示主题
该研究将主题的所有输入图像标记为「a [identifier] [class noun]」,其中 [identifier] 是链接到主题的唯一标识符,而 [class noun] 是主题的粗略类别描述符 (例如猫、狗、手表等)。该研究在句子中特别使用了类描述符,以便将类的先验与主题联系起来。
效果展示
下面是 Dreambooth 一个稳定扩散的实现(参考项目链接)。定性结果:训练图像来自「Textual Inversion」库:

训练完成后,在「photo of a sks container」提示下,模型生成的集装箱照片如下:

在提示中加个位置「photo of a sks container on the beach」,集装箱出现在沙滩上;

绿色的集装箱颜色太单一了,想加点红色,输入提示「photo of a red sks container」就能搞定:

输入提示「a dog on top of sks container」就能让小狗坐在箱子里:

下面是论文中展示的一些结果。生成不同画家风格的关于狗狗的艺术图:

该研究还可以合成输入图像中没有出现的各种表情,展示了模型的外推能力:

想要了解更多细节,请参考原论文。