Short answer: It depends on the method, not the industry. Anomaly-detection tools can start with 5 to 50 photos of good parts, classifiers typically want 50 to 1,000 per category, and custom object detectors often ask for 1,500 or more. But variety, label quality and the size of your test set matter more than the raw count.
Ask five AI inspection vendors how many photos you need and you’ll hear anything from 5 to 1,500. That’s a 300-fold spread, and here’s the odd part: nobody is lying.
They’re answering different questions. One is describing a tool that learns what “normal” looks like. Another is describing a detector that must learn every defect from scratch. A third is quietly assuming a lab with perfect lighting. And almost nobody mentions the two other photo budgets that decide whether your system survives a real production line: the photos you need to prove it works, and the photos each inspection needs to capture.
This guide untangles all three, using vendor documentation, peer-reviewed benchmarks and 2026 research, so you can plan a pilot instead of guessing.
Why every vendor gives a different number
Think about training an apprentice inspector. You wouldn’t count how many parts they glance at. You’d ask whether they’ve seen the dull parts, the dusty parts, the batch from the new supplier, and the borderline ones even you argue about.
Models work the same way. Photo counts matter only because they’re a rough stand-in for how many situations the model has seen. Here’s how published guidance stacks up:
- Edge-learning tools. Cognex says its edge learning can be trained with as few as five to ten images, versus hundreds or thousands for conventional deep learning (Cognex).
- Anomaly detection (good parts only). On the MVTec AD benchmark, the PatchCore method reportedly scored above 90% AUROC with just five normal images and above 95% with fifteen (IMV Europe). AUROC is a score for how well a model separates good from bad, where 100% is perfect.
- Managed platforms. Microsoft’s Custom Vision lists a minimum of 5 labeled images per tag for classification and 15 for object detection, with 50+ recommended (Microsoft). Amazon suggests at least 15–20 per label for Rekognition Custom Labels (AWS). Google’s Vertex AI sets a minimum of 10 but recommends about 1,000 per label (Google).
- Open-source detectors. The Ultralytics YOLO guide recommends 1,500+ images and 10,000+ labeled instances per class (Ultralytics).
Notice the pattern. Minimums describe what a tool will accept. Recommendations describe what tends to work. Treat the first as a prototype budget and the second as a production-grade starting point.
Budget 1: Training photos (teaching the model)
The benchmark trap: 5 photos, 99% scores, rude awakening
Many “few photos” claims trace back to MVTec AD, a benchmark of parts shot under controlled, consistent conditions. Top methods have pushed it so close to perfect that researchers say it has stopped separating good models from great ones. So its creators built MVTec AD 2: more than 8,000 high-resolution images across eight harder scenarios, including transparent and overlapping objects, back-light illumination, very small defects, and test sets with changed lighting. State-of-the-art methods stayed below 60% average AU-PRO (arXiv). The paper was accepted by the International Journal of Computer Vision in January 2026 (IJCV).
The lesson isn’t that five photos is a myth. It’s that five photos can be enough to start when conditions are tightly controlled, and nowhere near enough when your lighting drifts, your parts vary and someone bumps the camera. The fix usually isn’t more photos of the same thing. It’s photos of the right variety.
Photograph the variation, not the part
Before you shoot anything, list the ways real production will differ from your first sample, then make sure each one appears in the training set:
- Lighting: shift changes, daylight through a door, aging lamps.
- Position: the real tolerance in how parts sit or rotate on the line.
- Variants: suppliers, materials, colors, surface finishes, new product revisions.
- Harmless marks: dust, oil, fingerprints and anything the model must learn to ignore.
- Hardware drift: lens focus, camera angle, different stations.
- Borderline parts: the ones your own inspectors disagree about.
A few hundred near-identical frames from one calm Tuesday morning often teach less than fifty well-chosen photos spread across a month.
Label quality is a hidden multiplier
Landing AI’s steel project is the textbook case. The customer’s model sat near 76% accuracy against a 90% goal. Instead of tinkering with the architecture, the team found where human labelers contradicted each other (for example, on what counted as a foreign-particle defect), wrote clear definitions in a “defect book” and relabeled. Accuracy on critical defects reached about 93% (Landing AI case study). Andrew Ng told an industry audience that roughly 80% of the effort in these projects goes into data (IMV Europe).
Google’s documentation makes the same point bluntly: models generally can’t predict labels that people can’t assign (Google). If your two best inspectors disagree on a borderline scratch, the model has no ground truth to learn from.
A quick fix: have two experts label the same 100 images, count the disagreements, and rewrite your defect definitions until the disagreement shrinks.
Rare defects: the real bottleneck
Production lines are tuned to make good parts, which is exactly why defects are scarce. A 2026 paper from a team working with Philips on print defects in shaver housings says so plainly: when a process is optimized for good output, learning-based inspectors starve for examples (arXiv). Your options:
- Learn from good parts only. Anomaly detection needs no defect photos to train, just a few dozen to a few hundred good ones. One vendor’s guidance suggests about 10 defect examples per category, used only for calibration and testing (Clarifai).
- Pool defect photos over time. Log every defect your inspectors catch, across shifts, lines and months, and keep a shelf of physical defective samples to re-shoot later.
- Generate synthetic defects. The Philips team started with only 50 real defect images and generated 500 synthetic images per defect class with a diffusion model. A separate 2026 study found that in a few-shot setting, synthetic scratches raised mAP from 78.8% to 83.3% on a private industrial dataset (arXiv). Both are early results with stated limits, so keep your test set 100% real.
- Start from a foundation model. A 2026 study found a vision-language detector (YOLO-World) beat standard YOLO baselines in 12 of 15 MVTec categories when limited to about 10 training instances (MDPI). Promising for a cold start, but still something to validate on your parts.
Do the pixel math before you buy cameras
No number of photos can rescue a defect the camera can’t see. A common machine-vision rule of thumb is that a feature should span about three to four pixels before it can be reliably detected (Enao Vision). Keyence suggests aiming for two to four (Keyence).
Here’s the arithmetic. To catch a 0.2 mm flaw across a 150 mm field of view at three pixels per flaw, you need about 150 × (3 ÷ 0.2) = 2,250 pixels across the frame (The Imaging Source). If your camera can’t deliver that, shoot closer, use more cameras or split the part into zones.
Budget 2: Validation photos (proving it works)
This is the budget people forget, and it’s often bigger than the training set.
“98% accurate” means little without knowing how many photos produced it. And if only 2% of your parts are defective, a model that calls everything good is already 98% accurate. Overall accuracy hides the number you care about: how many real defects does it miss?
A handy statistical shortcut is the rule of three. If you test n defective samples and the system misses none, you can say with 95% confidence that its true miss rate is no higher than about 3 ÷ n (Quality Digest). That turns into a planning table:
- 30 defective samples, zero misses: true miss rate could still be up to 10%.
- 300 samples, zero misses: up to 1%.
- 1,000 samples, zero misses: up to 0.3%.
Small test sets can fool you in real research too. In the Philips study, the classifier scored a perfect 1.000 on its binary task, but the test set held just 16 real images, and the authors warned that a single misclassification would change the result (arXiv). A 2025 reproducibility study on the NEU steel dataset, which has only 1,800 images, found detection scores shifted dramatically depending on how the data was split between training and testing (Journal of Intelligent Manufacturing).
How to build a trustworthy test set:
- Use real defects only, collected on different days and from different lots than your training photos.
- Lock it. Never train on it, tune on it or peek at it. Ultralytics gives the same advice: validation and test images should never appear in training, and class distributions should match across splits (Ultralytics).
- Beware near-duplicates. Frames from the same video or the same part, split across train and test, inflate scores.
- Report recall per defect type, not one overall number.
- Price the two errors differently. A false reject wastes a good part. A false accept lets a defect escape. The Philips team’s answer is to defer uncertain cases to a human instead of forcing a verdict.
Budget 3: Capture photos (what each inspection takes)
This is the “how many photos” question hiding inside the title. Even a perfect model fails if the camera never sees the defect.
Single views miss things. The Real-IAD dataset, presented at CVPR 2024, contains 150,000 images of 30 objects, each shot from five angles. Its creators note that real parts are structurally complex and a single view cannot cover all defects (arXiv). In their multi-view setup, an object counts as defective if any one view shows a flaw, even when the other views look clean.
What vendors report for vehicles. One smartphone-based inspection vendor describes 8–10 photos per vehicle, or a guided 360° video taking 30–45 seconds versus around two minutes for the photo set (Inspektlabs). Another lists 12 guided captures for rental check-ins (Chex.AI). Fixed drive-through camera tunnels capture all sides at once and are pitched at volumes up to 120 vehicles an hour (Inspektlabs). These are vendor claims, so ask for accuracy numbers on your fleet.
What practitioners recommend for buildings. Roof inspection guidance leans on a simple pattern: a wide shot, a mid-range shot and a close-up for every damaged area, so a reviewer can trace each close-up back to the roof plane and the property (Timemark).
A simple planning heuristic (mine, not a standard): photos per item ≈ the number of zones you must clear × the views each zone needs, plus one context shot. A flat painted panel might need one view per zone. A shiny, curved or three-dimensional surface may need two or three angles to catch glare and hidden faces.
Two more habits pay off. Guide the shooter: on-screen prompts keep a new hire and a 15-year veteran producing the same set of photos. And reject bad images at the door: a blur, exposure or framing check before upload is cheaper than a missed defect.
A starting plan you can adapt
These are starting budgets pulled together from the sources above. They are not guarantees.
- Weeks 1–2: define the job. Write a defect book with examples. Collect 50–100 good parts and 10–20 examples per defect type, and run an anomaly-detection or few-shot baseline.
- Weeks 3–6: widen the variety. Capture across shifts, lots and lighting. Read the model’s misses, then collect more of exactly what it gets wrong. If you move to a supervised detector, plan for at least the platform minimum (often 15–50 per defect) and expect to want several hundred.
- Weeks 7–10: prove it. Lock a real-defect test set sized with the rule of three. Run the system in shadow mode next to human inspectors before it makes any decisions.
- After launch: watch for drift. Retrain or re-validate when lighting, suppliers, products or cameras change.
Six mistakes that waste photos
- Thousands of near-identical images from one shift.
- Training on phone photos and deploying on a line camera at a different distance and angle.
- Leaking test data by splitting frames of the same part across train and test.
- Labeling without written rules, so every annotator draws the line somewhere different.
- Skipping borderline cases, which are where the model will be tested hardest.
- Treating one headline accuracy number as the finish line instead of per-defect recall.
The question to ask instead
Stop asking “how many photos?” and start asking “how many situations has my model seen, and how many defects has it been tested on?” Five good photos can start a pilot. A thousand identical ones can fail on day two. Variety, clear labels, a defensible test set and a camera that actually sees the flaw are what turn photos into a working inspection system.
If you’re choosing a vendor, ask them four things: what variation does your training data cover, how many real defects were in your test set, what is the miss rate per defect type, and what happens when lighting or product changes?
Sources and further reading