Skip to main content
QUICK REVIEW

[Paper Review] Extreme Classification via Adversarial Softmax Approximation

Robert Bamler, Stephan Mandt|ArXiv.org|Feb 15, 2020
Adversarial Robustness in Machine LearningComputer Science32 references7 citations
TL;DR

This paper proposes adversarial negative sampling for extreme classification, using a learned auxiliary model to generate informative negative samples that reduce gradient variance and accelerate training. By sampling from a model that mimics the data distribution, the method achieves up to 10x faster convergence than baselines while maintaining high accuracy, with bias corrected at test time via exact quantification.

ABSTRACT

Training a classifier over a large number of classes, known as 'extreme classification', has become a topic of major interest with applications in technology, science, and e-commerce. Traditional softmax regression induces a gradient cost proportional to the number of classes $C$, which often is prohibitively expensive. A popular scalable softmax approximation relies on uniform negative sampling, which suffers from slow convergence due a poor signal-to-noise ratio. In this paper, we propose a simple training method for drastically enhancing the gradient signal by drawing negative samples from an adversarial model that mimics the data distribution. Our contributions are three-fold: (i) an adversarial sampling mechanism that produces negative samples at a cost only logarithmic in $C$, thus still resulting in cheap gradient updates; (ii) a mathematical proof that this adversarial sampling minimizes the gradient variance while any bias due to non-uniform sampling can be removed; (iii) experimental results on large scale data sets that show a reduction of the training time by an order of magnitude relative to several competitive baselines.

Motivation & Objective

  • Address the high computational cost of softmax regression in extreme classification, where training scales linearly with the number of classes C.
  • Improve the signal-to-noise ratio in negative sampling, which suffers from poor gradient quality due to uniform sampling.
  • Develop a scalable method to generate high-quality negative samples at logarithmic cost in C, enabling fast training.
  • Design an auxiliary model that learns to generate realistic, hard-to-distinguish negative samples from input features.
  • Provide a mathematical framework to quantify and remove the bias introduced by non-uniform sampling, ensuring consistent test-time performance.

Proposed method

  • Propose a generalized negative sampling framework where negative samples are drawn from a conditional distribution p(y| x) instead of a uniform prior.
  • Introduce an adversarial auxiliary model that learns to generate negative labels that are statistically similar to true labels given input features, minimizing gradient variance.
  • Use a probabilistic decision tree as the auxiliary model, enabling efficient O(log C) sampling and pre-training with minimal hyperparameter tuning.
  • Derive theoretical conditions under which the gradient variance is minimized, showing optimality when the auxiliary model perfectly matches the data distribution.
  • Introduce a bias correction mechanism at test time that exactly removes the approximation error introduced by non-uniform sampling.
  • Formulate the training objective as a stochastic approximation to the full softmax loss, with gradient updates computed using only a small number of adversarial negatives.

Experimental results

Research questions

  • RQ1Can non-uniform negative sampling based on a learned model improve the signal-to-noise ratio of stochastic gradients in extreme classification?
  • RQ2What is the optimal distribution for negative samples that minimizes gradient variance in the context of softmax approximation?
  • RQ3How can an auxiliary model be designed to generate high-quality negative samples efficiently, with sublinear cost in C?
  • RQ4Can the bias introduced by non-uniform sampling be exactly quantified and removed at test time without retraining?
  • RQ5Does adversarial negative sampling lead to faster convergence and better generalization compared to uniform or frequency-based baselines?

Key findings

  • The proposed adversarial negative sampling method reduces training time by an order of magnitude compared to multiple competitive baselines on large-scale datasets.
  • On both Wikipedia-500K and Amazon-670K datasets, the method achieves significantly faster convergence in terms of predictive log likelihood and accuracy.
  • The method outperforms uniform and frequency-based negative sampling in predictive accuracy, despite slightly lower log likelihood on one dataset, due to better ranking of top-class scores.
  • The auxiliary model, based on a probabilistic decision tree, enables O(log C) sampling and can be efficiently pre-trained with minimal hyperparameter tuning.
  • Theoretical analysis proves that gradient variance is minimized when the auxiliary model perfectly mimics the data distribution, and bias from non-uniform sampling can be exactly corrected at test time.
  • Empirical results confirm that the method maintains high test accuracy while drastically reducing training time, demonstrating practical scalability for real-world extreme classification tasks.

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.