You Only Condense Once: Two Rules for Pruning Condensed Datasets

Yang He, Lingao Xiao, Joey Tianyi Zhou · DOI

Abstract

Dataset Condensation (DC) has emerged as a critical technique for reducing massive training sets into small, synthetic representations suitable for edge computing and resource-constrained environments. However, traditional DC methods lack flexibility, requiring expensive re-optimization for every target size. This paper introduces You Only Condense Once (YOCO), a framework that enables the "elastic" resizing of condensed datasets. By prioritizing low-error "easy" samples and enforcing strict class balance, YOCO allows a single condensed dataset to be pruned to any size without additional optimization, significantly outperforming existing pruning and condensation baselines.

Introduction

As deep learning models move toward edge deployment, the need for efficient data representation is paramount. Dataset Condensation (DC) addresses this by synthesizing a tiny number of "representative" images (e.g., 10 or 50 images per class) that retain the performance of the full dataset. Despite its success, DC suffers from a "flexibility gap": a dataset condensed for 50 images per class (IPC) cannot be easily reduced to 10 IPC without starting the computationally intensive condensation process from scratch.

Furthermore, standard dataset pruning techniques—designed for full-sized, natural datasets—often fail when applied to these tiny synthetic sets. YOCO bridges this gap by providing a simple, effective strategy to prune condensed datasets on the fly, ensuring they remain robust across varying hardware constraints.

The YOCO Methodology

YOCO is built upon two "embarrassingly simple" rules derived from the unique characteristics of the tiny-data regime.

1. The "Easy Sample" Rule: Low LBPE Scores

In traditional dataset pruning, researchers often prioritize "hard" samples—those the model struggles to classify—because they define the decision boundaries of large datasets. However, YOCO flips this logic. The authors introduce the Logit-Based Prediction Error (LBPE), a metric derived from the gradient of the loss function.

In the context of condensed datasets, "hard" samples often act as outliers that trigger rapid overfitting due to the extreme scarcity of data. YOCO instead retains samples with low LBPE scores. These "easy" samples provide stable, prevalent patterns that allow a model to learn a reliable baseline representation even when the total number of images is extremely limited.

2. The Balanced Construction Rule

Small datasets are hyper-sensitive to class imbalance. Using Rademacher Complexity analysis, the authors demonstrate that the negative impact of imbalance is magnified as the dataset size shrinks. A single missing or underrepresented class in a tiny dataset can lead to a total failure in generalization for that category. Consequently, YOCO mandates that any pruning process must result in a perfectly equal number of samples across all classes to minimize generalization error.

Workflow

The YOCO workflow is highly efficient: a dataset is condensed once at a high IPC. LBPE scores are calculated during the final stages of this initial condensation. When a smaller dataset is required for a specific device, the high-IPC set is simply pruned based on these pre-calculated scores and the balance rule, requiring no further optimization.

Experimental Results

The researchers evaluated YOCO across standard benchmarks, including CIFAR-10, CIFAR-100, and ImageNet-10 (224x224 resolution), using architectures such as ConvNet, ResNet, and DenseNet.

Performance Gains

YOCO consistently outperformed both random selection and state-of-the-art pruning metrics like EL2N or AUM. On CIFAR-10, when pruning a dataset from 10 IPC down to 1 IPC, YOCO achieved 42.28% accuracy. This represents a massive improvement over the baseline IDC method, which achieved only 28.23%. Across various settings, YOCO showed accuracy gains ranging from 6.31% to 23.92% over standard pruning methods.

Cross-Architecture Robustness

A key strength of YOCO is its portability. Even when a dataset was condensed using a ConvNet architecture but tested on a ResNet, the YOCO-pruned sets maintained a significant performance lead. This suggests that the "easy samples" identified by LBPE capture universal features that are useful across different model types.

Discussion and Future Work

YOCO challenges the conventional wisdom of dataset pruning by demonstrating that in the synthetic, tiny-data regime, simplicity and stability (easy samples and balance) outperform complexity and boundary-pushing (hard samples).

While highly effective, the authors note that the current study assumes "clean" source data. Future research is needed to determine how the "Low LBPE" rule performs on noisy or real-world "dirty" datasets. Additionally, there is potential to integrate LBPE with other importance metrics or to determine sample importance even earlier in the condensation process to further reduce the initial computational overhead.

By making condensed datasets elastic, YOCO provides a practical path forward for deploying high-performance models on a diverse array of edge devices.

Summary updated

BibTeX
@inproceedings{he2023you,
  author = {Yang He and Lingao Xiao and Joey Tianyi Zhou},
  title = {{You Only Condense Once: Two Rules for Pruning Condensed Datasets}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2023},
  url = {https://openreview.net/forum?id=AlTyimRsLf},
}
Figure