Inducing a hierarchy for multi-class classification problems

Hayden S. Helm, Weiwei Yang, Sujeeth Bharadwaj, Kate Lytvynets, Oriana Riva, Christopher M. White, Ali Geisa, Carey E. PriebearXiv 2021

Introduction

In standard multi-class machine learning, problems are often treated as "flat." This means a model views the difference between a "Tabby Cat" and a "Tiger" as equivalent to the difference between a "Tabby Cat" and a "Toaster." However, real-world labels frequently possess inherent, latent relationships that flat classifiers ignore. While hierarchical classifiers exist to exploit known taxonomies (like biological structures), most datasets lack such predefined "cheat sheets." This paper investigates whether a useful hierarchy can be automatically discovered from data to improve model performance and data efficiency.

Methodology: From Flat to Hierarchical

The authors propose a two-step pipeline to transform flat classification tasks into hierarchical ones. The core idea is to group similar classes together even when no formal relationship is provided.

1. Inducing the Hierarchy

The first step involves clustering the conditional distributions of the classes. The authors explore two primary methods:

  • Conditional Means (CM): This method estimates the average feature vector for each class and clusters them using Gaussian Mixture Models (GMM). It is computationally efficient but relies on simple first-order statistics.
  • Task Similarity (TS): This more sophisticated approach measures how "similar" two classification tasks are. By introducing a reference distribution and evaluating how well a model distinguishes between pairs of classes, the method creates a similarity matrix. These similarities are then embedded into a lower-dimensional space and clustered to form the hierarchy.

2. Hierarchical Classification

Once the classes are grouped into "coarse" (parent) and "fine" (leaf) labels, the authors employ a sequence of Uncertainty Forests. A top-level forest is trained to predict the coarse group. Subsequent forests are then trained to predict the specific leaf class within that group. The final prediction is determined using the chain rule of probability to identify the most likely leaf label across the entire structure.

Comparison of standard hierarchical classification and the induction of a hierarchy from a flat observed structure.

Experimental Setup

The approach was evaluated across four diverse settings to test its robustness:

  • Gaussian Simulations: Controlled environments used to analyze how the variance of "parent" labels versus "child" labels affects classification performance.
  • CIFAR-100: A benchmark image dataset with 100 classes and a pre-existing human-defined semantic hierarchy.
  • CheXpert: A medical imaging dataset consisting of chest X-rays categorized into 11 classes.
  • Icons: A dataset of 95 different mobile app icon classes, representing a high-cardinality task with visual similarities.

Key Results and Insights

The study reveals that inducing a hierarchy can significantly enhance performance, particularly in high-cardinality datasets where the "divide and conquer" strategy of hierarchical decision-making is most effective.

The "Better than Truth" Phenomenon

A striking finding on the CIFAR-100 dataset was that the hierarchy induced by the Task Similarity method actually led to higher accuracy than the "true" semantic hierarchy provided by humans. This suggests that what makes sense semantically (e.g., biological categories) isn't always what makes sense visually for a machine learning model. By discovering visual similarities that humans might overlook, the induced hierarchy creates a more effective decision path for the classifier.

Quantitative Gains and Learning Efficiency

Performance was measured using Learning Efficiency (LE), which compares the risk of the hierarchical approach to a standard flat classifier.

  • CIFAR-100: Inducing a hierarchy resulted in a 26.7% absolute increase in accuracy (from 27.1% to 53.8%) when trained on just 10% of the data.
  • Icons Dataset: The improvement was even more dramatic, with a 37.6% absolute increase in accuracy over the flat baseline.
  • General Efficiency: Across real-world datasets, the Task Similarity method achieved an average LE of 1.72, indicating that the hierarchical approach was significantly more effective at utilizing limited training data than the flat approach.
Simulation results showing Adjusted Rand Index (ARI) and Learning Efficiency across different coordinate variances in Gaussian distributions.

Discussion and Future Work

The benefits of hierarchy induction are most pronounced when the number of classes is large. For datasets with few classes, like CheXpert (11 classes), the overhead of hierarchical modeling did not yield significant gains over flat classifiers. This suggests that hierarchy induction is best viewed as a scaling strategy for high-cardinality problems.

Future research will focus on scaling these methods to massive benchmarks like ImageNet (1,000+ classes) and developing a more robust theoretical framework to explain why induced hierarchies often surpass semantic ones. Ultimately, hierarchy induction appears to be a powerful, universal pre-processing step for complex multi-class problems.

Summary updated

BibTeX
@misc{helm2021inducing,
  author = {Hayden S. Helm and Weiwei Yang and Sujeeth Bharadwaj and Kate Lytvynets and Oriana Riva and Christopher M. White and Ali Geisa and Carey E. Priebe},
  title = {{Inducing a hierarchy for multi-class classification problems}},
  year = {2021},
  eprint = {2102.10263},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2102.10263},
}
Figure