Key Takeaways
- It learns from images instead of hand-written rules, so it handles textured surfaces and cosmetic defects that rule-based vision struggles with.
- Start with anomaly detection, which trains on good parts only. Add supervised defect classes as real defect images accumulate.
- Judge any system on two numbers measured on your own parts: the escape rate and the false-reject rate. A single “accuracy %” hides the trade-off.
- Most failures come from imaging (lighting, glare, resolution) and labelling, not from the model.
- Buy a packaged camera for standard checks. Build a custom model for unusual defects, multi-line rollouts, on-premises data or MES/ERP integration.
- At SoluLab, a prototype on your own images takes about two weeks and costs $15,000. A single live station takes three to five weeks and costs $10,000 to $20,000.
AI defect detection uses computer-vision models, usually deep neural networks, to inspect product images on the line and flag scratches, cracks, missing parts or misalignment in milliseconds. Unlike rule-based machine vision, it learns what “good” and “bad” look like from examples, so it copes with natural variation in parts, lighting and surfaces.
The global machine vision market size was valued at USD 22.6 billion in 2025 and is projected to grow from USD 25.3 billion in 2026 to USD 61.0 billion by 2033, at a CAGR of 13.4% from 2026 to 2033.
This guide to AI defect detection in manufacturing is written from the builder’s side. SoluLab builds custom inspection software rather than selling cameras, so we can be direct about what AI inspection does well, where it fails, which tools lead, what it costs, and when a custom model beats an off-the-shelf system.
What is AI defect detection?
Definition: AI defect detection is the automated identification of product flaws by a machine learning model trained on images of good and defective parts. It is the core of AI visual inspection, which also covers checks such as label reading and assembly verification.
Traditional machine vision works on rules. An engineer writes them: a brightness threshold, a blob size, a measured edge. AI replaces the rules with a trained model.
| Rule-based machine vision | AI-based inspection | |
|---|---|---|
| How it decides | Hand-written thresholds and measurements | A model learned from example images |
| Natural variation (texture, grain, reflections) | Struggles; causes false rejects | Handles it once trained |
| New part or defect type | Re-program the rules | Add images and retrain |
| Best for | Simple, consistent, measurable checks | Cosmetic and variable defects |
Rules still win for precise measurement on consistent parts. AI wins where “acceptable” is hard to write down.
Why are plants moving away from manual inspection?
People are not a perfect baseline. In a Sandia National Laboratories study, 82 trained inspectors examined 140 precision parts for eight defect types. They caught about 85% of defective parts and wrongly rejected about 35% of good ones. Fatigue, shift changes and inspector-to-inspector disagreement add to that. Rule-based vision is fast and consistent, but every new supplier, coating or lighting change means an engineer has to re-tune it. AI inspection keeps the speed of machine vision without needing a rule for every case.
How does AI defect detection work?

How AI inspection works on a production line
A camera with controlled lighting captures each part when the PLC triggers it. An edge device next to the line (an industrial PC, a GPU box, or a smart camera) runs the model and returns pass, fail or “send to review,” plus the defect class. The PLC fires the reject. The result and image are logged to the MES. Confirmed mistakes go back into training, which keeps accuracy from drifting.
Two choices shape the model.
Supervised learning vs anomaly detection. Supervised models train on labelled examples of each defect and can name what they find. Anomaly detection trains on good parts only and flags anything unusual. It’s the practical start when defects are rare, because a high-yield line may not produce enough bad parts to label. On the public MVTec AD benchmark, the PatchCore anomaly method reached up to 99.6% image-level AUROC while training on defect-free images only. Benchmarks don’t transfer directly to your parts, but they show why “start with good images” is now a credible plan.
Classification vs object detection vs segmentation.
- Classification labels the whole image (good, scratch, dent). It’s the simplest and fastest.
- Object detection draws a box around each defect, so you know where it is and how many there are.
- Segmentation outlines the defect pixel by pixel. Use it when the spec depends on defect size or area.
A common production pattern is a hybrid. Anomaly detection acts as the safety net, and a supervised detector names the frequent defect types so the quality team gets a usable Pareto chart.
Have a defect your current vision system misses? SoluLab builds and trains custom inspection models on your own parts.
Which defects can AI detect, and which does it struggle with?

What AI inspection catches and where it struggles
AI inspection handles four broad families well:
- Surface defects: scratches, dents, cracks, porosity, stains, paint runs, weld spatter.
- Dimensional defects: warping, wrong hole position, out-of-tolerance edges (often paired with classic measurement tools).
- Assembly defects: missing, misaligned or wrong components, reversed polarity, missing screws or clips.
- Foreign objects: debris, contamination, particles in packaging or food.
Where it’s already used most:
- Electronics and PCBs: solder bridges, missing components, polarity.
- Automotive and metal parts: paint, weld and casting defects.
- Semiconductors: wafer and die surface defects.
- Pharma and packaging: cracked tablets, fill levels, seals and labels.
- Textiles, film and coil: holes, stains and coating streaks, usually inspected with line-scan cameras.
It struggles in four situations, and it pays to know them before a vendor demo:
- Defects it has never seen. A supervised model only knows the classes it was trained on. Anomaly detection helps, but it can’t tell you what the new defect is.
- Reflective or transparent surfaces. Polished metal, glass and clear film create glare and reflections that look like flaws. This is an optics problem first.
- Sub-pixel defects. If a hairline crack spans less than a few pixels, no model will find it reliably. The fix is resolution, optics or magnification, not a better network.
- Lighting drift. Ageing lamps, daylight through a window or a dirty lens shift the images slowly until accuracy drops. Enclosing the station and fixing the lighting usually removes more false rejects than any amount of model tuning.
Not sure AI can see your defect? Book a free discovery workshop. Bring sample images of good and defective parts, and our engineers will assess whether the defect is detectable and what camera and lighting it needs.
What do you need: data, hardware and accuracy targets?
Data. How many images you need depends on the approach. Anomaly detection can start from a modest set of good parts. Siemens, for example, says its Inspekto system trains on 20–30 good samples. Supervised models need far more. Ultralytics’ training guidance says about 50–200 images per class can give a useful first signal from a pretrained model, but reliable results across lighting and viewpoints usually need 500–2,000+ images per class. Labels must be consistent. If two inspectors disagree on what counts as a scratch, the model learns their disagreement, so write a defect catalogue with example images before labelling starts.
Hardware. Choose the camera from the smallest defect you must catch and the line speed. Area-scan cameras suit discrete parts. Line-scan cameras suit continuous material such as coil, film or textile. Lighting is chosen per defect: low-angle light for scratches and dents, diffuse dome light for shiny parts, backlight for holes and edges.
Edge or cloud? The pass/fail decision should run at the edge, next to the line, so it lands within the cycle time and doesn’t depend on the network. The cloud is useful for what happens around it: storing images, training and retraining, and managing model versions across plants. Most production systems use both.
Accuracy. A single “accuracy %” hides the trade-off that matters. Ask for two numbers instead:
- Escape rate: the share of defective parts the system passes. This is your quality and recall risk.
- False-reject rate: the share of good parts it rejects. This is your scrap and rework cost.
Moving the decision threshold trades one for the other. That makes it a business decision for quality and production to make together, not a setting for the data scientist. Treat headline claims such as “99.7% accuracy” as vendor marketing until you’ve seen escape and false-reject rates on your own parts. Track a third number too: the review rate, meaning the share of parts sent to a human. It tells you how much manual effort the system still needs.
Which AI defect detection tools lead in 2026?
We compared the tools buyers most often shortlist, using each vendor’s own website and documentation. Where a vendor doesn’t publish prices, the table says “Quote-based.”
| Tool | Type | Best for | Training approach | Deployment | Pricing |
|---|---|---|---|---|---|
| Cognex (In-Sight / Deep Learning) | Smart camera + PC software | Plants standardised on Cognex | Labelled samples, trained on a PC, deployed to the camera | Edge (camera or PC) | Quote-based |
| Keyence (VS-G / IV4) | AI vision system and sensor | Fast setup, high-speed simple checks | Highlight the defect on setup images; self-tunes on production images | Edge (controller) | Quote-based |
| UnitX (OptiX, CorteX, DeteX) | Imaging + AI software + smart camera | Variable cosmetic defects needing tuned optics | Model training and management in CorteX | Edge, inline | Quote-based |
| LandingAI LandingLens | No-code software platform | Teams who want to own labelling and training | No-code labelling and one-button training | Cloud and edge | Free to start; paid plans quote-based |
| Overview.ai | AI smart camera | Plants that want no external compute | Training and inference on the camera; anomaly detection | 100% on-device | $4,450 (OV10i) to $13,450 (OV80i) per camera |
| Instrumental | Data and AI platform for electronics assembly | Electronics NPI and yield analysis | Works with existing AOI and cobot cameras | Cloud platform + line stations | Quote-based |
| Elementary | Edge AI + cloud quality platform | Multi-line plants wanting autonomous setup | Edge controller learns “good” from live production | Edge + cloud (QualityOS) | Quote-based |
What each one is best at, and where it falls short:
- Cognex: deep, proven hardware ecosystem. Limitation: you’re tied to Cognex hardware and licensing.
- Keyence: quick setup by line staff. Limitation: a closed system with little control over the model.
- UnitX: pairs software-defined 2D/2.5D imaging with model management. Limitation: it’s an end-to-end stack, so it fits best when you adopt all of it.
- LandingLens: strong data-centric labelling tools. Limitation: you still supply and integrate the cameras and lighting.
- Overview.ai: keeps production data on the factory floor, with published per-camera prices. Limitation: the camera-centric design suits per-station checks more than plant-wide analytics.
- Instrumental: links defects to yield across stations. Limitation: focused on electronics assembly.
- Elementary: auto-training at the edge plus a cloud traceability layer. Limitation: its accuracy figures are vendor-stated, so validate them on your own parts.
Not listed: Amazon Lookout for Vision. AWS ended support on 31 October 2025 and points customers to SageMaker. If a proposal still relies on it, ask for the migration plan.
Shortlisting inspection tools? Get a second opinion from engineers who don’t sell cameras. We’ll review your shortlist against your parts, line speed and integration needs.
How much does AI defect detection cost, and how long does it take?

Rollout steps and typical cost and timeline
Cost depends on scope more than on the model. SoluLab publishes its AI development pricing on its AI development services page. Here’s how those published tiers apply to an inspection project:
| SoluLab tier (published) | What it covers for inspection | Timeline | Cost |
|---|---|---|---|
| AI prototype (14-Day AI Launch) | One use case proven on your sample images | ~2 weeks | $15,000 |
| Basic AI application / MVP | One core workflow live, with a UI and 1–2 integrations | 3–5 weeks | $10,000–$20,000 |
| Mid-complexity AI system | Enterprise integrations, such as MES or ERP | 5–8 weeks | $20,000–$35,000 |
| Enterprise-grade AI platform | Several integrations and compliance requirements | 8+ weeks | $35,000+ |
These figures cover software, model work and integration. Three things sit outside them:
- Hardware: cameras, lenses, lighting, enclosures and edge devices, priced per station. Published smart-camera prices, such as Overview.ai’s $4,450 to $13,450 per unit, give a sense of scale.
- Labelling effort: this grows with the number of defect classes and how often they occur.
- Running costs: edge hardware upkeep, image storage, monitoring and periodic retraining.
What stretches the timeline is almost never model training. It’s imaging (getting a stable, glare-free picture) and data (collecting and labelling enough real defects). Fix those first, and the schedule holds.
Prove it on one line first. SoluLab’s 14-Day AI Launch tests AI inspection on your own sample images, so you see real escape and false-reject rates before committing to a rollout.
Should you build a custom model or buy an inspection system?

Build a custom model or buy an inspection system
Buy when the parts are standard, the defects are common, and you have an in-house vision team to own the system. A packaged camera or platform from the table above is the fastest route.
Build a custom model, or have a partner build it, when:
- your materials or defects are unusual and packaged models plateau
- you’re rolling out across many lines with mixed equipment
- the data must stay on-premises under your own control
- results must flow into an existing MES or ERP, not just fire a reject gate
Many plants end up with a hybrid: packaged cameras on standard stations and a custom model where the product is hard. Building also means you own the model and the training data, which matters when you want one system across several plants rather than a different vendor per line.
From our work: for an automotive components manufacturer, SoluLab built a real-time inspection system on edge AI devices using YOLOv8, OpenCV and NVIDIA TensorRT, with a FastAPI service, PostgreSQL and a React dashboard for factory managers. It classifies anomalies, triggers production alerts and reports quality analytics. The client reported 96% defect-detection accuracy, 42% less inspection time and 26% less production waste.
Read more: AI quality control in manufacturing.
How do you roll out AI defect detection?
A five-step pilot keeps the risk small:
- Pick one line and one defect class. Choose the defect that costs the most or escapes most often, and measure today’s escape and false-reject rates as the baseline.
- Collect and label. Fix the lighting and part position first, then gather images and label them against a written defect catalogue.
- Run in shadow mode. The model inspects alongside human inspectors without rejecting anything. Keep it there until its calls match or beat the inspectors’ on an agreed sample.
- Set the threshold with quality. Agree the acceptable escape and false-reject rates, then set the threshold and the “send to review” band to match.
- Scale and retrain. Add defect classes and lines, and feed confirmed mistakes back into training.
Most pilots that stall do so for operational reasons, not technical ones. Nobody owns the review queue, retraining isn’t scheduled, or the MES integration was left until after the pilot. Name an owner for each of these before step 3.
For related reading, see AI in visual quality control, AI for predictive maintenance, generative AI in manufacturing and AI in production planning. If you’d rather extend your own team, you can also hire computer vision developers.

Ready to test AI on your own parts? SoluLab builds and trains custom inspection models for defects that off-the-shelf systems miss, and integrates them with your PLC and MES.
FAQs
Chintan leads SoluLab's highest-level AI consulting conversations, assessing whether a client's business problem actually justifies an AI investment before any solutioning begins.