Calibrated Dataset Condensation for Faster Hyperparameter Search

Mucong Ding, Yuancheng Xu, Tahseen Rabbani, Xiaoyu Liu, Brian J. Gravelle, Teresa M. Ranadive, Tai-Ching Tuan, Furong Huang · OpenReview

Abstract

Dataset condensation can be used to reduce the computational cost of training multiple models on a large dataset by condensing the training dataset into a small synthetic set. State-of-the-art approaches rely on matching the model gradients between the real and synthetic data. However, there is no theoretical guarantee of the generalizability of the condensed data: data condensation often generalizes poorly across hyperparameters/architectures in practice. This paper considers a different condensation objective specifically geared toward hyperparameter search. We aim to generate a synthetic validation dataset so that the validation-performance rankings of the models, with different hyperparameters, on the condensed and original datasets are comparable. We propose a novel hyperparameter-calibrated dataset condensation (HCDC) algorithm, which obtains the synthetic validation dataset by matching the hyperparameter gradients computed via implicit differentiation and efficient inverse Hessian approximation. Experiments demonstrate that the proposed framework effectively maintains the validation-performance rankings of models and speeds up hyperparameter/architecture search for tasks on both images and graphs.

Introduction

Training state-of-the-art neural networks is computationally expensive, particularly during Hyperparameter Optimization (HPO) or Neural Architecture Search (NAS), where models must be trained repeatedly. Dataset Condensation (DC) attempts to mitigate this by distilling massive datasets into small synthetic "proxy" sets. However, existing DC methods often overfit to a specific model architecture. When these synthetic sets are used to evaluate different architectures or hyperparameters, the performance rankings frequently collapse, sometimes even showing a negative correlation with results on the full dataset. This lack of generalizability makes standard DC unreliable for search tasks.

Methodology: Hyperparameter-Calibrated Dataset Condensation (HCDC)

To address the ranking preservation problem, the authors propose Hyperparameter-Calibrated Dataset Condensation (HCDC). Instead of matching model gradients, HCDC focuses on matching hypergradients.

Overview of the HCDC algorithm flow.

The core components of HCDC include:

  1. Hyperparameter Calibration (HC): A dataset is considered "calibrated" if it preserves the relative performance rankings of different models (e.g., if Model A outperforms Model B on the full dataset, it should also do so on the synthetic set).
  2. Hypergradient Alignment: HCDC optimizes a synthetic validation set by minimizing the distance between the hypergradients of the validation loss on the original set and the synthetic set.
  3. Efficient Optimization: Computing hypergradients involves the inverse Hessian of the training loss, which is computationally prohibitive. HCDC employs the Implicit Function Theorem (IFT) and Neumann series approximations to achieve efficient computation with constant memory overhead.
  4. Continuous Search Spaces: For discrete search spaces like NAS, the authors construct continuous HPO trajectories, enabling gradient-based optimization across the architecture space.

Experimental Evaluation

The HCDC framework was evaluated across image and graph domains:

  • Images: Using CIFAR-10 and CIFAR-100 within the NAS-Bench-201 search space (15,000+ architectures).
  • Graphs: Using Cora, Citeseer, Ogbn-arxiv, and Reddit to optimize convolution filters in Graph Neural Networks (GNNs).

Key Results

  • Rank Correlation: On CIFAR-10, HCDC achieved a Spearman’s rank correlation of 0.74, whereas standard DC methods often produced negative correlations (as low as -0.33), which would mislead search algorithms.
  • Search Acceleration:
    • NAS: HCDC reduced the search time on CIFAR-10 from 229 seconds to just 35 seconds with negligible accuracy loss.
  • GNNs: HCDC successfully identified optimal convolution filters while condensing graphs to as little as 0.1% of their original size.
  • Theoretical Foundation: The authors provide a proof that aligning hypergradients is equivalent to preserving performance rankings on a connected search space.

Conclusion and Future Work

HCDC demonstrates that aligning hypergradients is a powerful strategy for creating generalizable synthetic datasets for HPO and NAS. While highly effective, the method currently relies on a "proxy" model during condensation, and future work could explore the joint optimization of both synthetic training and validation sets. Additionally, extending HCDC to extremely high-dimensional or disjoint search spaces remains an open challenge.

Summary updated

BibTeX
@misc{ding2024calibrated,
  author = {Mucong Ding and Yuancheng Xu and Tahseen Rabbani and Xiaoyu Liu and Brian J. Gravelle and Teresa M. Ranadive and Tai-Ching Tuan and Furong Huang},
  title = {{Calibrated Dataset Condensation for Faster Hyperparameter Search}},
  year = {2024},
  eprint = {2405.17535},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2405.17535},
}
Figure