Synthetic Defect Training Data for Pharmaceutical Visual Inspection

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Existing visual inspection methods for pharmaceutical products face challenges in generating sufficient and high-quality training data for machine learning models, leading to high false reject rates and inadequate representation of defect properties, which is crucial for GMP compliance.

Innovation Solution

A method of generating training data by combining defect images with good product images to create a diverse set of combined images, using techniques like image segmentation and GANs to enhance the variety and coverage of defect characteristics.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Quantity of substance

If artificial defects are created by introducing foreign particles or deliberately damaging products, then training data for defective products can be generated, but the process becomes time-consuming and costly

Engineering Contradiction:
Improvetraining dataVSAvoidtime to create artificial defects
Core Design Contradiction:
Quantity of substanceVSLoss of time

Solution Approach 1:

The patent uses generative adversarial networks (GANs) to create synthetic defect images that copy the visual characteristics of real defects without requiring physical manipulation of products. The GAN generates realistic defect images through computational processes, replacing the time-consuming manual creation of artificial defects while maintaining the quality and variety needed for training data

Inventive Principle:
Principle #26Copying

Solution Approach 2:

The patent replaces the mechanical process of physically introducing foreign particles or damaging products with a computational image generation system. Instead of manually creating defects through mechanical means, the system uses algorithms to synthesize defect images, significantly reducing time and resource requirements while maintaining defect diversity

Inventive Principle:
Principle #28Mechanics substitution (Replace mechanical system)

2Measurement precision

If the full range of defect variations is mapped in training data, then classification accuracy improves, but the complexity and cost of creating training data increases

Engineering Contradiction:
Improveclassification accuracyVSAvoidtraining data creation complexity
Core Design Contradiction:
Measurement precisionVSDevice complexity

Solution Approach 1:

The patent employs a dynamic training data generation approach where defect images are generated with varying parameters such as size, shape, position, and type. The GAN system can adaptively generate defects across the full range of possible variations by adjusting generation parameters, ensuring comprehensive coverage of defect space without manually designing each variation

Inventive Principle:
Principle #15Dynamics

Solution Approach 2:

The patent systematically varies defect parameters (size, shape, position, color) in the generated training data to ensure comprehensive coverage of defect variations. By controlling and adjusting these parameters during image generation, the system creates diverse training examples that improve classification accuracy without requiring complex manual intervention for each defect type

Inventive Principle:
Principle #35Parameter changes

3Reliability

If GMP compliance requirements are met by ensuring wide defect detection coverage, then product safety improves, but false reject rates increase

Engineering Contradiction:
Improvedefect detection coverageVSAvoidfalse reject rate
Core Design Contradiction:
ReliabilityVSMeasurement precision

Solution Approach 1:

The patent applies local quality by generating defect images with specific characteristics in specific regions of the product. The system can target particular areas and defect types with appropriate visual features, allowing the ML model to learn nuanced distinctions between actual defects and normal product variations in different regions, thereby reducing false rejects while maintaining comprehensive detection coverage

Inventive Principle:
Principle #3Local quality

4Measurement precision

If physically existing artificial defects are used for training, then real defect representation is achieved, but the representation is inadequate for regulated areas

Engineering Contradiction:
Improvedefect representation accuracyVSAvoiddefect distribution coverage
Core Design Contradiction:
Measurement precisionVSAdaptability or versatility

Solution Approach 1:

The patent creates a universal training data generation system that can produce defects across all required categories and distributions specified by regulatory guidelines. The GAN-based system is configured to generate defects matching various reference images and statistical distributions, making the training data adaptable to different product types, defect types, and regulatory requirements without requiring separate physical defect creation processes for each case

Inventive Principle:
Principle #6Universality (Multi-functionality)

Data Source

PatentEP4645219A1Method of generating training data for training a machine learning model for visual inspection of products
Publication Date: 2025.11.05 INSPECTIFAI GMBH
  • EP4645219A1 patent drawingFigure 1
  • EP4645219A1 patent drawingFigure 2
  • EP4645219A1 patent drawingFigure 3~4

AI summary

A method (200) of generating training data for training a machine learning model for visual product inspection is provided, wherein the training data are generated to comprise a plurality of first product images associated with a first class and a plurality of second product images associated with a second class. The method comprises obtaining a plurality of defect images (303), each representing at least one defect (305) that can occur in the product (300), wherein the plurality of defect images (303) is obtained in such a way to represent a plurality of different defects (305) that can occur in the product (300), and creating a plurality of combined images (304). The creating of the plurality of combined images (304) comprises obtaining a product image (302) representing a product (300) without a defect, combining the product image (302) with at least one defect image (303) of the plurality of defect images (303) to obtain a combined image (304) representing the product (300) with at least one defect (305), and associating the obtained combined image with the second class. The plurality of combined images (304) is added to the plurality of second product images.