On a foundry production line, two operators are inspecting the same metal part. Both identify a defect. Yet their conclusions differ. One believes the part can continue through the line, while the other believes it must be rejected. This situation is far from unusual in the industry.
Artificial intelligence applied to quality control refers to machine learning methods that detect, classify, and trigger the ejection of nonconforming parts on an industrial production line, without human intervention and without interrupting the production pace.
It relies primarily on convolutional neural networks (CNNs) trained to detect defects in images captured by industrial cameras. The machine vision system analyzes each part in a matter of tens of milliseconds and sends an ejection signal to the PLC as soon as the probability of a defect exceeds the set threshold.
Unlike human visual inspection, which is limited by fatigue and production rate, an AI system maintains consistent judgment 24 hours a day, whether it’s detecting a 0.3mm crack in a tray lid, a surface defect on a nuclear component, or an incorrect assembly on an automotive production line.
What is AI as applied to industrial quality control?
AI applied to quality control is a machine learning system that analyzes images in real time to identify any deviations from a conforming reference, and then automatically triggers the ejection of the defective part.
Two approaches coexist on current production lines. The traditional approach—using hand-coded rules and fixed light thresholds—has shown its limitations when dealing with variable defects: it causes excessive rejections when lighting conditions change, and allows atypical defects that were not anticipated during configuration to slip through.
Supervised AI changes this model. A neural network is trained on thousands of annotated images—both conforming and non-conforming—and learns to generalize. It recognizes a defect even if it does not exactly resemble those seen during training. That is why Psycle can deploy the same vision engine on a food production line at Babynov and on a nuclear process at Orano Melox, using different models trained on data specific to each context.
Detectable defects fall mainly into four categories: surface defects (scratches, stains, bubbles), shape defects (deformation, lack of material), presence or absence defects (missing component, missing cap), and assembly defects (poorly welded lid, misalignment).
How does AI detect manufacturing defects?
The AI detects defects in four sequential steps: image acquisition, preprocessing, CNN model inference, and sending the ejection signal. The entire process takes less than 20 milliseconds, making it compatible with production rates of several hundred parts per minute.
It all starts with the optics. An industrial camera, a matrix camera for a wide-angle view or a linear camera for continuous scanning, captures each part at the exact moment it passes under the lens, synchronized with the lighting trigger. The image quality at this stage determines everything that follows.
Preprocessing normalizes variations in lighting and crops the area of interest. The image is then processed by the CNN running on a GPU at the production line. The model calculates a defect probability for each known class: scratch, bubble, deformation, or missing lid.
If this probability exceeds the decision threshold, the system sends a digital signal to the PLC within the next few milliseconds. The ejection arm or pneumatic reject mechanism activates. The part leaves the line without interrupting production.
| Step | Action | Component | Typical duration |
| 1. Acquisition | Frame-rate-synchronized shooting | Industrial camera + dedicated lighting | Varies, depends largely on the sensor used |
| 2. Preprocessing | Luminance normalization, ROI cropping | Embedded CPU or GPU | 1 to 5 ms |
| 3. CNN inference | Calculation of the probability of failure by class | Embedded GPU | 5 to 15 ms |
| 4. Decision & ejection | Send a PLC signal if score > threshold | PLC / robot controller | < 2 ms |
How does AI detect manufacturing defects?
Three metrics quantify the performance of a quality AI system: precision measures the proportion of defects among the rejected parts, recall measures the proportion of actual defects that are successfully detected, and the F1 score combines the two. It is the confusion matrix that reveals any imbalances among them.
Choosing the wrong decision threshold has a direct cost. A threshold that is too low results in false positives: conforming parts that are incorrectly rejected. The line loses material yield. A threshold that is too high results in false negatives: defects that slip through and reach the customer. Both situations come at a measurable cost.
The F1 score requires striking a balance. It cannot be maximized by ignoring either of the two components. In practice, sectors with high regulatory stakes (food, nuclear, pharmaceutical) require a very high recall; it is preferable to over-reject rather than let anything slip through, with a target recall > 0.98 and an F1 score > 0.95.
Psycle includes a real-time monitoring dashboard that displays these metrics by team, by product, and by default. This feature allows you to adjust the decision threshold without retraining the model.
| Metric | What it measures | Simplified formula | Indicative industrial threshold |
| Precision | Rate of true defects among rejects | TP / (TP + FP) | > 0,95 |
| Recall | Actual defect detection rate | TP / (TP + FN) | > 0,98 (critical lines) |
| F1-score | Precision / recall balance | 2 × (P × R) / (P + R) | > 0,95 |
| Overall ejection rate | Process stability indicator | Ejections / Total parts | Variable, must be calibrated for each product |
In which industrial sectors does AI improve quality control?
Quality AI is used wherever a visual or dimensional defect has a measurable cost: in the food and beverage, nuclear, automotive, electronics, pharmaceutical, and metallurgy industries. Each sector has its own requirements regarding production rate, certification, and the definition of an acceptable defect.
| Sector | Main application | Psycle example or specific constraint |
| Agri-food | Inspection of lids, trays, and canned goods | Babynov (checking for ovality and dents in cans), natural variability in organic products |
| Nuclear | Process monitoring, surface inspection | Orano Melox, zero tolerance for false negatives; mandatory image archiving for regulatory audits |
| Automotive & mechanics | Inspection of machined parts, painted surfaces, and assemblies | Throughput > 100 pieces/min; inference must be performed at the edge (edge computing) |
| Electronics | PCB inspection, solder joints, components | High-resolution line scan camera, continuous scanning of each card |
| Pharmaceutical / cosmetic | Filling, cap, and label inspection | Strict regulatory compliance, mandatory batch traceability |
| Metallurgy & plastics processing | Surface defects in sheet metal, porosity in injection-molded parts | Coaxial lighting to reveal defects that are invisible under diffuse lighting |
What factors ensure the success of a high-quality AI project?
An AI quality project is successful if six conditions are met before deployment: representative training data, rigorous annotation, a compatible cycle time, a tested automation integration, an adjustable threshold that does not require retraining, and a model update plan.
Most failures aren’t caused by the model. They stem from data preparation and integration. Here are the six conditions that Psycle systematically checks before every deployment.
| Condition | What is required | What happens if absent |
| 1. Representative data | Images showing actual variations in defects: variable lighting, different batches, tool wear | The model deviates as soon as conditions change (e.g., winter vs. summer light) |
| 2. Rigorous annotation | An operator capable of distinguishing a real defect from a normal, acceptable variation | An approximately annotated model produces approximate results, regardless of the amount of data |
| 3. Cycle time compatibility | Inference + ejection signal within the available time window between two parts (e.g., 300 ms at 200 parts/min) | The system is one part behind; the ejector is hitting the wrong part |
| 4. Automated integration tested | OPC-UA protocol or qualified Digital I/O before go-live | Non-reproducible rejection signal, false positives on the live line |
| 5. Adjustable threshold without re-training | Interface displaying the decision threshold to the quality manager | Minor deviation = integrator intervention = unplanned shutdown |
| 6. Re-training plan | Procedure: annotation + retraining + documented validation | A new defect or a change in raw materials renders the model obsolete without an update procedure |
Frequently Asked Questions about AI for quality control
What is AI-powered quality control?
Artificial intelligence-based quality control involves using machine learning algorithms, particularly convolutional neural networks (CNNs), to analyze images or sensor data in real time and automatically detect any nonconformities on a production line. AI replaces or assists human inspectors with greater repeatability and speed.
What metrics can be used to evaluate an AI system for quality control?
Three metrics are essential: precision (the ratio of correctly detected defects to the total number of detections), recall (the ratio of actual defects correctly identified), and the F1-score (the harmonic mean of the previous two). The confusion matrix summarizes these results. An F1-score greater than 0.95 is generally required for deployment in industrial production.
How much training data is needed for a reliable AI system?
The minimum volume depends on the complexity of the defect and its variability. In practice, 500 to 5,000 images annotated by defect class constitute an initial training dataset. Data augmentation techniques (rotation, noise, lighting changes) can be used to enrich small datasets. The rarer the defects are in production, the more critical targeted annotation becomes.
Can AI completely replace human quality control?
No, in most current industrial applications. AI excels at detecting repetitive, visual, and measurable defects at high speeds. It is less effective at detecting subjective defects, new defects (not seen during training), or defects that require contextual reasoning. The hybrid approach combining AI and human supervision remains the recommended standard for production lines with high regulatory or safety stakes.