How Should Visual Inspection Accuracy Be Defined? Stop Treating the Pixel Equivalent as Accuracy
Visual inspection accuracy and pixel equivalent are not the same thing. This article explains the relationship between the smallest resolvable defect, pixel sampling, imaging contrast and judgement stability, and how to work backwards from the "minimum defect size" to an imaging solution.
Clarify One Thing First
Breaking down the word "accuracy": being able to capture ≠ being able to measure accurately ≠ being able to judge stably
Visual inspection accuracy is not pixel equivalent. Pixel equivalent only tells you how much physical size one pixel represents, whereas the defects that can actually be detected also depend on the contrast of the defect in the image, the number of pixels the defect spans and the judgement threshold. The correct approach is to first define the "minimum defect size" and the "inspection area", then work backward to the camera resolution and lens, and finally validate by measurement with physical samples.
In visual inspection projects, "what is the accuracy" is the question asked most often and the one most easily answered vaguely. Many people answer with the "pixel scale", for example "0.02 mm/pixel". This number is meaningful, but it does not equal inspection accuracy.
Where is the difference? For a defect to be reliably detected in the image, it must span several pixels (usually at least 3-5) and must have sufficient contrast with the background. If the defect is only 1 pixel in size, or its contrast is close to the noise level, it cannot be detected — no matter how fine the pixel scale is.
So any discussion of accuracy must state three things at the same time: minimum defect size, inspection area, and the imaging contrast between defect and background. Without any one of them, the discussion cannot lead anywhere practical.
selection Factors
Minimum Resolvable Defect Size
This is the starting point of the whole solution. It determines how much pixel scale is needed and thus the camera and lens. The quality department should first provide a quantitative standard.
inspection area
Together with the minimum defect size, this determines camera resolution. The larger the area and the smaller the defect, the higher the resolution required, and costs rise quickly.
Imaging Contrast
Whether a defect forms a clear image depends on the illumination solution. The same defect may be clear under one illumination and invisible under another. This is the most easily overlooked link.
Judgement Stability
The requirement is not only that defects "can be detected" but that they "are detected every time". Stability depends on pose consistency, illumination stability and threshold margin.
cycle time
Exposure time and inspection time are both constrained by cycle time. The higher the speed, the shorter the permitted exposure time and the higher the demands on the light source.
Field of View and Pixel Sampling
Do Not Mistake Pixel Scale for Inspection Accuracy
The pixel equivalent is calculated directly: field of view width ÷ camera horizontal resolution. For example, with a field of view of 150 mm and a horizontal resolution of 8192 pixels, the pixel equivalent is about 0.018 mm/pixel.
But this number cannot be taken directly as the inspection accuracy. To judge whether a defect of a given size can be detected, you also need to look at how many pixels it spans and how large its difference from the background is in the image.
| Concept | Meaning | Common Misconceptions |
|---|---|---|
| Pixel Equivalent | The physical size represented by one pixel | Mistaken for inspection accuracy |
| Smallest resolvable defect | The smallest defect that can be reliably detected under given imaging conditions | Equipment selection starts before quantified standards are defined |
| inspection accuracy | Deviation of the measured value from the true value (dimensional) | Often confused with pixel resolution |
| Detection Rate / Escape Rate | Statistical performance of defect detection | Using a single test result to represent overall capability |
Light Source and illumination
Why Illumination Matters More Than the Camera
The camera determines "how fine a detail can be resolved", and the light source determines "whether it can be seen". If the light source does not bring the defect into view, a better camera will not help.
Illumination Orientation for Common Defects
Diffused light suits color difference and stains; low-angle light suits scratches and indentations; transmitted light suits holes and damage; coaxial light suits reflective surfaces.
Illumination Stability
Light source brightness drift makes thresholds ineffective. The solution must account for light source stability and aging compensation, as well as the influence of ambient light.
Trade-offs When Contrast Is Insufficient
If the contrast of a certain defect type on the existing material is consistently insufficient, it should be clearly acknowledged that it cannot be detected reliably, rather than forcing the threshold — the latter only produces a large number of over-rejections.
algorithm Selection
The principle for algorithm selection is "choose by the form of the acceptance criteria", not "choose by how advanced it is". Where the geometric criteria are clear, use a rule-based algorithm; where the form varies widely, use deep learning. The two are often combined.
Positioning and Matching
Establishing a stable coordinate system first is the prerequisite for all judgements.
- Shape matching / gray-level matching
- Align first, then segment regions
Thresholding and Morphology
Suitable for defects with a stable gray-level difference from the background.
- Threshold segmentation + connected-component statistics
- Judge by area / length-to-width / circularity
Edge and Contour Measurement
Suited to dimension and contour judgement.
- Sub-pixel edge extraction
- Line / circle / arc fitting
deep learning
Suitable for defects whose forms vary widely and whose rules are hard to enumerate.
- Classification / detection / segmentation
- Requires a sufficient number of labeled samples
Communication and interlocking
The output of the inspection system must act on the production line, so the communication scheme must be decided early in the project, not added at the end. The brand of the site PLC and the available interfaces directly determine the implementation.
- 01 Camera image acquisition
- 02 Algorithm-Based Judgement
- 03 Combine results into a single OK / NG per piece
- 04 Results written to the communication interface
- 05 PLC reads and executes actions
- 06 Rejection / sorting / alarm
- 07 Data written back to the database
Common Question
Does a pixel size of 0.02 mm mean that 0.02 mm defects can be detected?
How do I determine what configuration my project needs?
Why Validate with Physical Samples?
Can inspection speed and accuracy be improved at the same time?
What escape rate can your equipment guarantee?
What is most easily overlooked during selection?
Submit sample testing
We recommend basing the selection conclusion on measured sample trials. Please provide samples containing known defects and quantitative defect criteria, and we will validate imaging and detection.
Submitted successfully
We have received your sample testing request. A solution engineer will contact you within 1 business day via contact you.
Need to assess imaging conditions, defect criteria and cycle time item by item? Go to the Full Requirement Assessment →
The Most Effective Step in Selection: Test Your Own Sample
For the same workpiece, the inspection result differs greatly with different lenses, light sources, mounting distances and algorithm combinations. Sending us samples for measurement is more reliable than extrapolating from a specification table.