NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Active Generation for Image Classification

Tao Huang, Jiaqi Liu, Shan You, Chang Xu

Abstract

Modern image classification models benefit significantly from synthetic data augmentation, but current "brute force" methods generate millions of redundant images, leading to high computational and environmental costs. We present ActGen (Active Generation), a framework that treats data generation as an active learning problem. By identifying misclassified "hard" samples and using them to guide a diffusion model with attentive and gradient-based constraints, ActGen achieves superior performance on ImageNet while requiring 90% less synthetic data than previous state-of-the-art baselines.

Introduction

While deep generative models like Stable Diffusion can create high-fidelity images, their application in data augmentation has largely been an exercise in volume over precision. Previous methods typically generate millions of random synthetic images to achieve marginal gains in accuracy. The authors of ActGen argue that this inefficiency stems from redundancy: most randomly generated images are "easy" for a classifier and do not provide new information. ActGen addresses this by identifying specific "blind spots" in a classifier's knowledge and generating targeted samples to fill those gaps.

The ActGen Framework

ActGen operates in a closed-loop system designed to iteratively improve a classifier by focusing on what it does not yet know.

The ActGen framework loop: identifying hard samples from a validation set to guide targeted synthetic image generation.

The process follows three core steps:

  1. Identify Weaknesses: The classifier is evaluated on a validation set. Images that the model misclassifies are flagged as "hard samples."
  2. Attentive Image Guidance (AIG): These hard samples serve as visual guides. To prevent the model from simply duplicating the guide image, ActGen uses cross-attention maps to isolate the foreground object. Guidance is applied strictly to the foreground, allowing the diffusion model to diversify the background context.
  3. Gradient-based Guidance: During the denoising process, the text embedding is updated via two specific losses: a Contrastive Loss to ensure diversity among generated samples, and a Classification (Adversarial) Loss that encourages the generator to create images that are intentionally difficult for the current model to recognize.

Targeted Diversity and Key Insights

The primary insight of ActGen is that targeted data is far more valuable than massive data. By using attention masks and adversarial losses, the framework solves the common problem of how to preserve the "essence" of an object (e.g., a specific pose or breed) while changing the environment to help the model generalize.

Ablation of guidance components showing how attention masks and contrastive loss improve diversity and relevance compared to random generation.

As shown in the ablation study above, adding attention masks and contrastive loss allows the model to generate a variety of realistic scenarios for a single class (e.g., a Beagle) that are more informative for training than simple random generations.

Experimental Results

The authors evaluated ActGen across standard benchmarks including ImageNet-1K, CIFAR, and EuroSAT. Key findings include:

  • ImageNet Efficiency: On a ResNet-50 architecture, ActGen achieved a 2.26% accuracy improvement over the baseline. Crucially, it outperformed previous methods while using only 10% of the synthetic data (0.13M images vs. 1.2M images).
  • Architecture Consistency: Gains were consistent across traditional CNNs (ResNet-152) and modern Vision Transformers (ViT-S, DeiT-B).
  • Few-Shot Success: On the EuroSAT satellite imagery dataset, ActGen outperformed existing guidance methods in scenarios with as few as 1 to 16 training samples.

Conclusion and Future Work

ActGen demonstrates that active generation is a more sustainable and effective path for data augmentation than massive random sampling. While the per-image computational cost is higher due to gradient calculations, the overall efficiency gain and reduction in total required images are substantial. Future research may explore applying this active framework to more complex tasks such as object detection and semantic segmentation.

Summary updated

BibTeX
@inproceedings{huang2024active,
  author = {Tao Huang and Jiaqi Liu and Shan You and Chang Xu},
  title = {{Active Generation for Image Classification}},
  booktitle = {European Conference on Computer Vision},
  year = {2024},
  doi = {10.1007/978-3-031-73195-2\_16},
}
Figure