Skip to main content
QUICK REVIEW

[Paper Review] Rethinking Feature Distribution for Loss Functions in Image Classification

Weitao Wan, Yuanyi Zhong|arXiv (Cornell University)|Mar 8, 2018
Adversarial Robustness in Machine LearningComputer Science31 references24 citations
TL;DR

This paper proposes the Large-margin Gaussian Mixture (L-GM) loss, which models deep features as a Gaussian Mixture distribution to improve classification and anomaly detection. By incorporating a classification margin and likelihood regularization, the L-GM loss enhances model robustness, achieving state-of-the-art performance in classifying adversarial examples with an equal error rate (EER) of 3.1%, significantly outperforming softmax and center loss.

ABSTRACT

We propose a large-margin Gaussian Mixture (L-GM) loss for deep neural networks in classification tasks. Different from the softmax cross-entropy loss, our proposal is established on the assumption that the deep features of the training set follow a Gaussian Mixture distribution. By involving a classification margin and a likelihood regularization, the L-GM loss facilitates both a high classification performance and an accurate modeling of the training feature distribution. As such, the L-GM loss is superior to the softmax loss and its major variants in the sense that besides classification, it can be readily used to distinguish abnormal inputs, such as the adversarial examples, based on their features' likelihood to the training feature distribution. Extensive experiments on various recognition benchmarks like MNIST, CIFAR, ImageNet and LFW, as well as on adversarial examples demonstrate the effectiveness of our proposal.

Motivation & Objective

  • To address the lack of explicit probabilistic modeling of training feature distributions in standard deep learning loss functions.
  • To improve model generalization by enforcing intra-class compactness and inter-class separability through a principled distribution assumption.
  • To enable effective detection of out-of-distribution inputs, such as adversarial examples, using feature likelihood under the learned distribution.
  • To unify classification loss and feature regularization under a single probabilistic framework based on Gaussian Mixture modeling.

Proposed method

  • Assumes that deep features of the training set follow a Gaussian Mixture (GM) distribution, with each class corresponding to one component.
  • Derives the classification loss as cross-entropy between predicted class probabilities and true labels under the GM assumption.
  • Introduces a likelihood regularization term to encourage training features to conform to the assumed GM distribution.
  • Incorporates a classification margin directly into the GM loss formulation, simplifying margin enforcement compared to prior methods.
  • Uses Bayes' rule to compute posterior probabilities and likelihoods, enabling likelihood-based anomaly detection.
  • Employs a simplified GM model with identity covariance and equal priors for tractable computation and analysis.

Experimental results

Research questions

  • RQ1Can modeling deep features as a Gaussian Mixture distribution lead to better classification performance and improved generalization?
  • RQ2How does the L-GM loss compare to softmax and center loss in detecting adversarial examples using feature likelihood?
  • RQ3Can a unified loss function simultaneously optimize classification accuracy and feature distribution modeling?
  • RQ4Does incorporating a margin into the GM loss formulation improve model robustness without introducing complex auxiliary distance metrics?
  • RQ5To what extent can likelihood scores from the L-GM loss distinguish normal inputs from adversarial examples?

Key findings

  • The L-GM loss achieves an equal error rate (EER) of 3.1% in adversarial example detection, significantly lower than the 10.2% EER of center loss and 37.7% of softmax loss.
  • The L-GM loss enables effective distinction of adversarial examples based on their low likelihood under the learned training feature distribution, as shown in likelihood histograms and ROC curves.
  • The center loss is formally equivalent to a special case of the likelihood regularization in the L-GM loss, unifying it under a common probabilistic framework.
  • The L-GM loss outperforms softmax and its variants across multiple benchmarks, including MNIST, CIFAR, ImageNet, and LFW, in both classification and anomaly detection tasks.
  • Even when adversarial examples are crafted to increase likelihood under the L-GM loss using targeted FGSM, most remain detectable, with an EER of 4.3%, demonstrating robustness to such attacks.

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.