Skip to main content
QUICK REVIEW

[Paper Review] Defect Transfer GAN: Diverse Defect Synthesis for Data Augmentation

Ruyu Wang, Sabrina Hoppe|arXiv (Cornell University)|Feb 16, 2023
Industrial Vision Systems and Defect DetectionEngineering7 citations
TL;DR

This paper proposes Defect Transfer GAN (DT-GAN), a GAN-based framework that disentangles defect styles and shapes from background products to synthesize diverse, realistic defective images for data augmentation. By leveraging shared defect characteristics across multiple products, DT-GAN achieves high-fidelity, semantically meaningful data augmentation, reducing error rates by up to 51% in defect classification tasks—even with only 20 real defective samples per class.

ABSTRACT

Data-hunger and data-imbalance are two major pitfalls in many deep learning approaches. For example, on highly optimized production lines, defective samples are hardly acquired while non-defective samples come almost for free. The defects however often seem to resemble each other, e.g., scratches on different products may only differ in a few characteristics. In this work, we introduce a framework, Defect Transfer GAN (DT-GAN), which learns to represent defect types independent of and across various background products and yet can apply defect-specific styles to generate realistic defective images. An empirical study on the MVTec AD and two additional datasets showcase DT-GAN outperforms state-of-the-art image synthesis methods w.r.t. sample fidelity and diversity in defect generation. We further demonstrate benefits for a critical downstream task in manufacturing -- defect classification. Results show that the augmented data from DT-GAN provides consistent gains even in the few samples regime and reduces the error rate up to 51% compared to both traditional and advanced data augmentation methods.

Motivation & Objective

  • Address data scarcity and class imbalance in industrial defect detection, where defective samples are rare and costly to collect.
  • Overcome limitations of traditional data augmentation and existing GANs that fail to generate diverse, semantically meaningful defects.
  • Enable effective data augmentation by transferring defect patterns across different background products while preserving style and shape variability.
  • Stabilize GAN training on small datasets by jointly modeling defect manifolds from multiple products with similar defect patterns.
  • Demonstrate the practical utility of synthetic data in improving downstream defect classification performance under real-world data constraints.

Proposed method

  • Employ a weakly supervised disentangling mechanism to separate foreground defects (shape and style) from background products in input images.
  • Explicitly model defect styles (e.g., light or heavy strokes) and shapes as learnable, disentangled components for controlled generation.
  • Use a Gradient Reversal Layer (GRL) with an auxiliary classifier to enforce domain-invariant features across real and synthetic samples, improving robustness.
  • Train the GAN on a combination of defective images from multiple products to learn shared defect characteristics, enhancing generalization and reducing overfitting.
  • Enable controlled image synthesis by sampling or transferring style and shape from reference images while combining with any background product.
  • Integrate traditional data augmentations (e.g., flipping, jittering) with synthetic samples to further improve classifier generalization.

Experimental results

Research questions

  • RQ1Can a GAN-based method generate diverse, realistic defective images by disentangling defect styles and shapes from background products?
  • RQ2Does transferring shared defect characteristics across multiple products improve data augmentation performance on limited real data?
  • RQ3Can DT-GAN outperform state-of-the-art image synthesis and data augmentation methods in downstream defect classification tasks?
  • RQ4How does the combination of GAN-generated synthetic data with traditional augmentation affect model generalization and error rates?
  • RQ5To what extent does cross-product defect transfer mitigate overfitting and improve performance in low-data regimes?

Key findings

  • DT-GAN reduces error rates in defect classification by up to 51% compared to traditional and advanced data augmentation methods, even when only 20 real defective samples per class are available.
  • The method achieves consistent performance gains across all tested datasets, including MVTec AD and two additional industrial datasets, demonstrating robustness and generalization.
  • Cross-product defect transfer (using defects from multiple products) leads to better classifier performance than using defects from a single product, validating the benefit of shared defect learning.
  • DT-GAN outperforms state-of-the-art GANs in downstream classification despite sometimes lower FID scores, indicating that diversity and semantic relevance are more critical than raw image fidelity.
  • The combination of DT-GAN with traditional augmentations like CutMix further improves performance, suggesting complementary benefits.
  • Nearest neighbor and LPIPS analyses confirm that DT-GAN generates diverse defects with meaningful variation, unlike methods that produce overly similar samples.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.