摘要
1. 本文提出一种适用于Zero-Shot Learnning (ZSL)和Open-Set Recognition (OSR)任务的反事实框架。这两个任务的共同挑战:仅在seen-classes上训练的情况下,如何提高在unseen-classes上的泛化能力。
2. 当前方法存在的问题:在seen-classes和unseen-classes上的识别率不均衡。根因在:Generation is not Counterfactual Faithful (保真)。
3. 假设每个sample = class attribute + sample attribute。将class attribute替换为其他类别的,用于生成新样本,这样生成的样本,我们认为是保真的。
4. 在保真的情况下,可以用Consistency Rule。判断新样本和已知class attribution的样本是否像,如果像那么sample is from a certain class,否则是otherwise。
Introduction
1. ZSL可以用于标注数据;OSR可以屏蔽异常值
2. 假设:attributes (or features) learned from the training seen-classes are transferable to the testing unseen-classes. 因此,如果我们有ground-truth class attributes可以描述seen和unseen-classes,ZSL,OSR:比较预测的属性,或者是以ground-truth attributes生成的样本训练一个分类器。
3. 学习解耦特征是十分困难的
4. Counterfactual Faithfulness:保真
5. Consistency Rule:在保真的情况下,可以用已知class attributeion的样本去帮助判断未知样本的class attribution。
6. 从X中解耦Z和Y的质量是问题关键。
Approach
Counterfactual Generation and Inference
Three steps of computing counterfacutal
Abduction:计算sample attribute z(x)
Action:设置Y=y,而不是原来的class attribute y(x)
Prediction:P(X|Z=z(x), Y=y)生成新的样本
我们希望上述counterfactual sample是seen或unseen samples的真实分布
Definition (Counterfacutal Faithfulness). 当x ∈ X,那么基于x生成的x_hat ∈ X。
前人方法失败就是因为counterfacutal faithfulness不成立。但是这在本文是成立的。这使得X中的距离度量,不仅可以用在x也可以用在基于x生成的x_hat。 通过应用Consistency Rule我们可以建立一个二元分类器:
其中y*(x)是(unobserved) ground-truth calss attribute of x. 是基于此生成的counterfactual。
我们二元分类策略是基于此的换质换位法
因为有些属性是没有解耦的,这导致使用sample-agnostic Z,无法弥补Y中纠缠的属性。
Inference in ZSL
测试时,unseen-classes的属性是已知的。如果x和unseen-classes中反事实生成的不像,那么x属于seen。具体来说,我们生成了一系列基于unseen-classes的counterfactual features
。使用
和seen-classes的D训练一个multi-label classes。 Denote the mean-pooling of the tok-K classifier probabilities among seen and unseen-classes as
and
Inference in OSR
如果x和反事实生成的seen-classes不像的话,那么它属于unseen。我们计算至于x和中每个样本的最小欧式距离。如果
大于某个阈值,则认为它是unseen的。
Two-Stage Inference
在stage-one的二元分类后,预测为seen-classes的样本使用有监督方法去分类。Unseen classes样本则送入任意ZSL中的传统算法,或是在OSR中视作异常值拒绝掉。
Counterfactua-Faithful Training
本文的核心在保真,如何保真:
定理:反事实生成是保真的,当且仅当sample attribute Z和class attribute Y是group disentangled。
通过下列损失实现:
(1) 从Y中解耦Z,最小化-VAE loss:
相当于,从X中解耦出来的Z的分布要尽可能是isotropic Gaussian distribution。同时保证,解耦出来的Z和样本的Y能够重建X。
(2)从Z中解耦Y。
Y中的信息可能被Z全部包括。
使得x和的距离尽可能接近,和远离除了
之外的其他x'。
(3)Further Disentangling by Faithfulness
进一步用WGAN loss来约束。具体来说,本文训练了一个鉴别器D(X, Y),用于表示输入图片是否为真,数值越大代表越真。用feature x和属性y,以及z(x)和y生成的unreal x'