Sub-Pixel Edge Extraction: Algorithm Comparison and Repeatability Verification
Edge points must localize to 1/10-1/50 pixel for repeatability below 0.3 μm; algorithm choice and focus state set the ceiling.

Why sub-pixel matters
Vision machines typically run 2 to 10 μm per pixel. If edges were localized only to whole pixels, that scale would cap the accuracy, far from a machine specification of a few microns. Sub-pixel algorithms fit the true edge position from the grey transition band — an ideal step blurred by optics spans three to eight pixels — reaching 1/10 to 1/50 pixel and unlocking the optical resolution.
Algorithm comparison
| Algorithm | Principle | Accuracy | Character |
|---|---|---|---|
| Gaussian fit | Fit a Gaussian to the grey-level derivative and take the peak | 1/10-1/20 px | Fast, moderate noise immunity |
| Polynomial interpolation | Parabola through three points near the derivative peak | 1/10 px | Simplest, real-time capable |
| Zernike moments | Orthogonal moments solve the step-edge parameters | 1/20-1/50 px | High accuracy, heavy computation |
| Spatial moments | Grey-moment conservation gives edge position | 1/20-1/50 px | Robust to blur |
Accuracy drivers
Focus is the first variable: defocus broadens the transition band, lowers contrast and shifts the localized edge systematically, so autofocus repeatability should beat one fifth of the depth of field. Illumination uniformity governs threshold stability, and ring light versus transmitted light need separate calibration. The quality of the measured edge itself — burrs, chamfers, roughness — often exceeds algorithm error by an order of magnitude and is the real source of scatter.
Repeatability verification
Use a gauge block or master ring with clean edges. Fix illumination and focus, measure the same position 30 times, and take the standard deviation as single-point repeatability; it should be under 0.3 μm on a 5 μm/pixel system. Then move the stage and repeat ten times at several field positions to assess position dependence. Any claimed sub-pixel accuracy must be demonstrated this way, not quoted from algorithm papers.



