Skip to main content
QUICK REVIEW

[Paper Review] One-Way Prototypical Networks

Anna Kruspe|arXiv (Cornell University)|Jan 1, 2019
Domain Adaptation and Few-Shot LearningComputer Science25 references4 citations
TL;DR

This paper proposes a one-way prototypical network for few-shot one-class classification, introducing a null class centered at zero via batch normalization to eliminate the need for negative examples. It further models class prototypes using full Gaussian distributions (mean and std) instead of just centroids, achieving 98% accuracy on Omniglot and 80% on unmatched MNIST, with training time halved compared to two-way models.

ABSTRACT

Few-shot models have become a popular topic of research in the past years. They offer the possibility to determine class belongings for unseen examples using just a handful of examples for each class. Such models are trained on a wide range of classes and their respective examples, learning a decision metric in the process. Types of few-shot models include matching networks and prototypical networks. We show a new way of training prototypical few-shot models for just a single class. These models have the ability to predict the likelihood of an unseen query belonging to a group of examples without any given counterexamples. The difficulty here lies in the fact that no relative distance to other classes can be calculated via softmax. We solve this problem by introducing a "null class" centered around zero, and enforcing centering with batch normalization. Trained on the commonly used Omniglot data set, we obtain a classification accuracy of .98 on the matched test set, and of .8 on unmatched MNIST data. On the more complex MiniImageNet data set, test accuracy is .8. In addition, we propose a novel Gaussian layer for distance calculation in a prototypical network, which takes the support examples' distribution rather than just their centroid into account. This extension shows promising results when a higher number of support examples is available.

Motivation & Objective

  • To address the challenge of one-class classification in few-shot learning where negative examples are hard to define or collect.
  • To eliminate the need for training on negative or counterexample classes by introducing a 'null' class with zero-centered distribution.
  • To improve few-shot generalization by modeling class prototypes not just as centroids but as full Gaussian distributions in latent space.
  • To reduce training time by processing only one class per episode instead of two, leveraging the one-way design.

Proposed method

  • Introduce a 'null' class with a fixed zero centroid in the latent space, enabled by batch normalization's zero-centering property.
  • Train the model using only support examples from the positive class and no negative examples, using cross-entropy loss with the null class as the negative reference.
  • Model class prototypes as multivariate Gaussian distributions (mean and standard deviation), not just centroids, to capture uncertainty and distributional spread.
  • Use a Gaussian layer in the prototypical network to compute distance based on both mean and variance of support examples.
  • Apply batch normalization after embedding layers to enforce zero centering, which stabilizes the null class representation.
  • Train on episodic few-shot learning setup with support sets and query examples, optimizing for classification accuracy on unseen queries.

Experimental results

Research questions

  • RQ1Can a prototypical network be effectively trained for one-class classification without requiring negative examples or counterclasses?
  • RQ2Does modeling class prototypes as full Gaussian distributions (mean and standard deviation) improve few-shot generalization compared to centroid-only modeling?
  • RQ3How does the one-way training setup (single positive class, null class) compare to two-way models in terms of accuracy and training efficiency?
  • RQ4Does the use of a Gaussian layer provide measurable performance gains when sufficient support examples are available?

Key findings

  • The one-way prototypical network achieved 98% accuracy on the matched Omniglot test set and 80% on unmatched MNIST data, demonstrating strong generalization to unseen domains.
  • On the more complex MiniImageNet dataset, the model reached 80% test accuracy, showing robustness to distribution shifts.
  • The Gaussian layer extension outperformed standard centroid-based prototypical networks when 15 or more support examples were available, indicating improved modeling of uncertainty.
  • Training time was reduced by nearly 50% compared to two-way models, as only one class's support examples needed processing per episode.
  • Allowing the model to adapt the standard deviation of the null distribution during training improved performance, despite batch normalization enforcing unit variance.
  • The model's performance surpassed standard prototypical networks for large support sets (≥15 examples) on Omniglot, suggesting potential for scalability with abundant support data.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.