Skip to main content
QUICK REVIEW

[Paper Review] An end-to-end approach for the verification problem: learning the right distance

João Monteiro, Isabela Albuquerque|arXiv (Cornell University)|Feb 21, 2020
Machine Learning and Data ClassificationComputer Science5 citations
TL;DR

This paper proposes an end-to-end framework that jointly trains an encoder and a learnable pseudo-distance model for the verification problem, enabling direct prediction of whether two examples belong to the same class. The method outperforms standard baselines like cosine similarity and downstream classifiers, simplifies training by eliminating the need for negative pair mining, and empirically learns a distance that approximates a likelihood ratio and induces high divergence between positive and negative pair distributions.

ABSTRACT

In this contribution, we augment the metric learning setting by introducing a parametric pseudo-distance, trained jointly with the encoder. Several interpretations are thus drawn for the learned distance-like model's output. We first show it approximates a likelihood ratio which can be used for hypothesis tests, and that it further induces a large divergence across the joint distributions of pairs of examples from the same and from different classes. Evaluation is performed under the verification setting consisting of determining whether sets of examples belong to the same class, even if such classes are novel and were never presented to the model during training. Empirical evaluation shows such method defines an end-to-end approach for the verification problem, able to attain better performance than simple scorers such as those based on cosine similarity and further outperforming widely used downstream classifiers. We further observe training is much simplified under the proposed approach compared to metric learning with actual distances, requiring no complex scheme to harvest pairs of examples.

Motivation & Objective

  • To address the challenge of training metric learning models for verification tasks without requiring complex negative pair mining strategies.
  • To develop an end-to-end trainable framework where both the encoder and a learned pseudo-distance are optimized jointly for improved verification performance.
  • To show that the learned pseudo-distance approximates a likelihood ratio for hypothesis testing and induces high divergence between positive and negative pair distributions.
  • To simplify verification pipelines by replacing multi-component systems with a single forward pass scoring mechanism.
  • To evaluate the method on large-scale open-set verification benchmarks, including ImageNet, under realistic conditions with unseen classes at test time.

Proposed method

  • The method jointly trains a deep neural network encoder and a learnable pseudo-distance model, both parameterized as neural networks, in an end-to-end manner.
  • The pseudo-distance model is trained via a contrastive estimation objective that encourages small distances for same-class pairs and large distances for different-class pairs.
  • The loss function combines a contrastive estimation objective with a standard multi-class cross-entropy loss to stabilize training and improve generalization.
  • The architecture uses a ResNet-50 backbone for the encoder and a fully-connected stack with 256-unit hidden layers for the distance model, with 128-dimensional output embeddings.
  • Training employs mini-batches with at least five examples per class to ensure positive pair availability, using stochastic gradient descent with a cosine annealing learning rate schedule.
  • Inference is performed via a single forward pass using the output of the learned pseudo-distance model as a similarity score for test pairs.

Experimental results

Research questions

  • RQ1Can a jointly trained encoder and pseudo-distance model outperform standard metric learning baselines in verification tasks?
  • RQ2Does the learned pseudo-distance approximate a likelihood ratio for Neyman-Pearson hypothesis testing?
  • RQ3Can the method achieve strong performance without explicit negative pair mining, simplifying training?
  • RQ4Does the model generalize to open-set verification, where test classes are unseen during training?
  • RQ5How stable is performance across different architectures and hyperparameters of the distance model?

Key findings

  • The proposed method achieves better performance than baseline models using cosine similarity and downstream classifiers on the ImageNet verification benchmark.
  • The learned pseudo-distance induces a high Jensen-Shannon divergence between the joint distributions of positive and negative pairs, indicating strong discriminative capacity.
  • The pseudo-distance output approximates a likelihood ratio, enabling optimal decision rules under the Neyman-Pearson framework for hypothesis testing.
  • The method simplifies training by eliminating the need for complex negative pair mining strategies, as the contrastive objective naturally encourages proper separation.
  • Models with 3–4 fully-connected layers of 256 units each in the distance head achieve stable and strong performance across multiple datasets, suggesting a robust starting point for new applications.
  • The approach generalizes well to open-set verification, maintaining strong performance even when test classes are not seen during training.

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.