Anomaly-Preference Image Generation
Abstract
Synthesizing realistic and diverse anomalous samples from limited data is vital for robust model generalization. However, existing methods struggle to reconcile fidelity and diversity, often hampered by distribution misalignment and overfitting, respectively. To mitigate this, we introduce Anomaly Preference Optimization (APO), a novel paradigm that reformulates anomaly generation as a preference learning problem. Central to our approach is an implicit preference alignment mechanism that leverages real anomalies as positive references, deriving optimization signals directly from denoising trajectory deviations without requiring costly human annotation. Furthermore, we propose a Time-Aware Capacity Allocation module that dynamically distributes model capacity along the diffusion timeline— prioritizing structural diversity during highnoise phases while enhancing fine-grained fidelity in low-noise stages. During inference, a hierarchical sampling strategy modulates the coherencealignment trade-off, enabling precise control over generation. Extensive experiments demonstrate that significantly outperforms existing baselines, achieving state-of-the-art performance in both realism and diversity.
Lay Summary
Automated inspection systems rely on examples of defective items to learn how to identify manufacturing flaws or medical abnormalities. However, real defects are naturally rare. While current models attempt to artificially generate these examples to expand training data, they struggle to balance realism with variety—producing simulated defects that either look highly artificial or completely lack diversity. Our research introduces a new framework that generates high-quality defect examples by treating the synthesis process as a preference-matching task. Instead of relying on expensive human feedback, our method uses a very small number of real defects as direct guides. It dynamically adjusts its focus during the generation process: prioritizing broad structural variety initially, and refining intricate, realistic details in the final steps. This approach creates highly realistic and diverse examples, significantly improving the accuracy of automated anomaly detection systems.