思路:
为每个类别构造一个原型表示(prototypical representation)embedding。 原型表示就是每个类一个向量。
构造的方法:
取support set中每个点的embeddings, 取平均(mean)
点embedding:
Regular embedding methods,GoogLenet embedding for images, etc. LSTM + attention embedding for texts.
Query and prototypical distance:
It is empirically better to use squared Euclid distance than to use cosine distance.
It is vital to select proper distance.
其他经验:
使用mini-episode的训练方式,subsampling classes and points,
每次采样的class 类别数Nc比实际测试的类别数多,实验结果比较好(validation选择超参)
每class采样的point数(slot数)Ns与测试时的slot数一致,效果比较好
扩展:
将few-shot的原型模型概念扩展到zero-shot,可以使用***嵌入zero-shot的meta-data(对类别特点的描述性内容),来获得类别的embedding向量作为原型的另一种形式***。不过因为这个向量和query的embedding向量不在一个空间,所以需要一定的变化。论文中,做了一个对向量的空间压缩【fix the prototype embedding g to have unit length】。这个起到避免分布过于稀疏的情况。估计也可以通过空间变换来实现,不过那样可能更复杂。