Abstract: Conditional generative adversarial networks (cGANs) have shown superior results in class-conditional generation tasks. To simultaneously control multiple conditions, cGANs require multi-label training datasets, where multiple labels can be assigned to each data instance. Nevertheless, the tremendous annotation cost limits the accessibility of multi-label datasets in real-world scenarios. Therefore, in this study we explore the practical setting called the single positive setting, where each data instance is annotated by only one positive label with no explicit negative labels. To generate multi-label data in the single positive setting, we propose a novel sampling approach called single-to-multi-label (S2M) sampling, based on the Markov chain Monte Carlo method. As a widely applicable “add-on” method, our proposed S2M sampling method enables existing unconditional and conditional GANs to draw high-quality multi-label data with a minimal annotation cost. Extensive experiments on real image datasets verify the effectiveness and correctness of our method, even when compared to a model trained with fully annotated datasets.
Introduction
Training generative models to handle multiple attributes (e.g., "a smiling man with black hair") usually requires expensive, fully labeled datasets. This paper introduces Single-to-Multi-label (S2M) sampling, a plug-and-play Markov Chain Monte Carlo (MCMC) framework that enables existing GANs to generate complex multi-label images using only "single positive" labels—where each training image is tagged with just one attribute.
In the world of Conditional Generative Adversarial Networks (cGANs), "multi-label" generation is the gold standard for controlling several attributes simultaneously. However, annotating a dataset where every image is labeled for every possible attribute is incredibly labor-intensive and often impractical for large-scale real-world data.
To address this, the authors focus on the single positive setting: a weakly supervised scenario where each data instance has only one positive label, and the status of all other attributes is unknown. For example, an image might be labeled "Black-hair," but we don't know if the person is also "Smiling." Standard cGANs struggle here because they aren't explicitly shown the intersections of these classes during training. Existing weakly supervised methods often suffer from mode collapse or fail to accurately capture the overlapping regions between classes.
Methodology
The core of the paper is a novel sampling approach that works as an "add-on" to any pretrained GAN.
- Theoretical Formulation: The authors derive a theorem showing that the probability density of a "joint class" (like the intersection of attributes A and B) can be calculated using only the individual class densities and priors. This means you can mathematically define what a "Smiling + Black-hair" distribution should look like even if the model has never seen a multi-labeled example.
- S2M Sampling via MCMC: They use the Metropolis-Hastings (MH) algorithm. They treat a pretrained GAN as a "proposal distribution" and use simple classifiers (trained on the single positive labels) to calculate the acceptance probability for each generated sample.
- Latent Adaptation: MCMC can be slow if the target joint class is a tiny fraction of the GAN's total output. To fix this, they "pilot" sample a few successful images, fit a Gaussian Mixture Model (GMM) to those successful latent vectors, and then use that GMM to "steer" the GAN's latent space. This significantly speeds up the search for the desired attribute combination.
Key Insights and Ideas
- Density Ratios are Enough: You don't need to retrain your GAN to get multi-label outputs. By using the ratio of class probabilities from simple classifiers, you can "filter" the output of a standard GAN to find the exact intersection of attributes you want.
- Preserving Quality: Because S2M is a post-processing step, it doesn't interfere with the GAN's training objective. It preserves the high image quality of the original model while adding precise conditional control.
- The "Needle in the Haystack" Problem: If you want a very specific combination (e.g., 6 attributes at once), a random GAN might only produce it 0.1% of the time. The Latent Adaptation technique effectively warps the latent space so the GAN "aims" better, making the sampling process much more efficient.
Datasets and Key Results
The researchers evaluated S2M on several benchmarks, including (F)MNIST-Even, CIFAR-7to3, and subsets of the CelebA facial dataset focusing on complex attribute combinations.
- Superior Accuracy: On the MNIST-Even task, S2M achieved 96.37% accuracy in generating the target non-overlapping class, significantly beating the previous state-of-the-art CP-GAN (87.87%).
- Better Fidelity: S2M consistently produced lower FID scores (indicating higher image quality) than baselines. On CIFAR-7to3, S2M combined with a standard cGAN achieved an FID of 14.14, compared to 27.88 for CP-GAN.
- Comparable to "Oracle" Models: Surprisingly, S2M (using only single positive labels) performed nearly as well as "Oracle" models trained on the full, expensive multi-label datasets.
- Diversity: Unlike some previous methods that "collapse" to a single look to satisfy the label, S2M maintains the diversity of the original GAN.
Limitations and Future Work
The authors identify a clear scaling limit: as you add more attributes, the number of real training images that actually fit that specific "joint class" drops exponentially. If the underlying GAN hasn't seen enough data to learn a specific combination at all, no amount of smart sampling can "mine" it. Future work may involve extending this framework to even larger attribute sets or applying it to other generative architectures like Diffusion Models.
Summary updated