扩散模型零样本分类应用笔记

1 Title

Your Diffusion Model is Secretly a Zero-Shot Classifier(Alexander C. Li, Mihir Prabhudesai, Shivam Duggal, Ellis Brown, Deepak Pathak)【ICCV 2023】

2 Conclusion

This paper shows that the density estimates from large-scale text-to-image diffusion models like Stable Diffusion can be leveraged to perform zero-shot classifi-cation without any additional training.

3 Good Sentences

1、Obtaining a diffusion model classifier through Bayes' theorem consists of repeatedly adding noise and computing a Monte Carlo estimate of the expected noise reconstruction losses (also called -prediction loss) for every class. We call this approach Diffusion Classifier.(The theory of this study that use diffusion model to make classification)

2、Discriminative approaches directly learn tomodel the decision boundary of the underlying task, while generative approaches learn to model the distribution of the data and then address the underlying task as a maximum likelihood estimation problem. (The principle of the generate mode that used in discrimination)

3、We split our evaluation into a series of stages, where in each stage we try each remaining ci some number of times and then remove the ones that have the highest average error. This allows us to efficiently eliminate classes that are almost certainly not the final output and allocate more compute to reasonable classes.(The improvement of this study for Efficient Classification)


对于像 Stable Diffusion 这种类型的 diffusion models,主要的步骤有两个,其一是 sampling,其二是 density estimation。而第二点又分为两种,unconditional density estimation 和 conditional density estimation,前者估计,后者估计

本文认为类似stable diffusion这样的大规模text2img模型所计算出的密度估计,可以被用来进行"零样本分类" (zero-shot classification),而不需要额外的训练。 也就是在大规模Text2Img任务中density estimation 这件事情几乎等价于 zero-shot classification without training,于是作者们将这一分类机制单独提炼出来,形成了 Diffusion Classifier 模型,并展示了这一模型有着很强的 multi-modal reasoning 的能力,它可以从含分类的 diffusion models 中提取出标准的分类器。

如何将diffusion model应用到zero-shot classification,具体流程图如上图所示:

对于一个分类模型,给定输入x,模型输出类别的概率向量c,对于这个diffusion model,分类任务就是求解。具体推导过程请看论文,这里不多赘述。

作者对比同为zero-shot classifier的CLIP,zero-shot的能力以及接近了基于renset50的CLIP。但与openCLIP ViT-H/14还有较大差距

相关推荐
Hello_Embed22 分钟前
FreeRTOS 入门(四):堆的核心原理
数据结构·笔记·学习·链表·freertos·
烧冻鸡翅QAQ1 小时前
考研408笔记——数据结构
数据结构·笔记·考研
lkbhua莱克瓦242 小时前
集合进阶6——TreeMap底层原理
java·开发语言·笔记·学习方法·hashmap
im_AMBER3 小时前
算法笔记 13 BFS | 图
笔记·学习·算法·广度优先
01100001乄夵4 小时前
FPGA零基础入门:TestBench编写完全指南
经验分享·笔记·学习方法·fpga学习之路·fpga 0基础入门
未若君雅裁4 小时前
LeetCode 18 - 四数之和 详解笔记
java·数据结构·笔记·算法·leetcode
受之以蒙5 小时前
具身智能的“任督二脉”:用 Rust ndarray 打通数据闭环的最后一公里
人工智能·笔记·rust
chushiyunen5 小时前
django使用笔记
笔记·python·django
YJlio6 小时前
进程和诊断工具学习笔记(8.19):Hyper-V 来宾调试与符号配置 —— 在虚拟化场景下用 LiveKd 抓现场
网络·笔记·学习
星轨初途6 小时前
《数据结构二叉树之堆 —— 优先队列与排序的高效实现(2)(下)》
c语言·开发语言·数据结构·经验分享·笔记·性能优化