# Defect-Intent Ambiguity Addressing for Training-Free Deterministic PCB Defect Localization via Template Selection and Dissimilarity Mapping

**Authors:** Saiyan Saiyod, Woottichai Nonsakhoo, Zhengping Li, Piyanat Sirisawat

PMC · DOI: 10.3390/s26051541 · Sensors (Basel, Switzerland) · 2026-02-28

## TL;DR

This paper introduces a training-free method for detecting defects in PCBs using reference images and image processing techniques, achieving high precision and recall.

## Contribution

A novel, training-free deterministic framework for PCB defect localization using template selection and dissimilarity mapping.

## Key findings

- The method achieves high precision (0.9663) and recall (0.9987) with minimal false positives.
- Average precision reaches 0.984 under the box-matching protocol.
- The framework uses interpretable parameters and avoids machine learning models.

## Abstract

Automated optical inspection (AOI) for printed circuit boards (PCBs) requires localizing small, sparse defects under illumination drift and minor placement misalignment, while supporting fast, auditable pass/fail decisions. This paper presents a training-free, reference-based digital image processing framework with no learning/training stage that compares each defective query image with a small library of defect-free reference templates (for the same PCB layout/revision) using a small set of interpretable control parameters. A reference is selected by coarse-to-fine matching (fast pre-screening followed by SSIM refinement on a central region), and an optional global alignment is applied only when it increases SSIM to limit defect-driven over-correction. Defects are highlighted by a defect-likelihood field that fuses an SSIM-derived structural dissimilarity map with a normalized absolute-difference map, followed by connected-component extraction to produce confidence-ranked bounding boxes. The method achieves Precision = 0.9663, Recall = 0.9987, and F1 = 0.9822 at the best-F1 operating point (0.149 false positives per image). Under the adopted box-matching protocol, average precision reaches 0.984. Precision–recall and FROC curves are reported to support threshold selection under different false-alarm budgets.

## Full-text entities

- **Diseases:** Defects (MESH:D000013)
- **Chemicals:** PCB Defect (-)

## Full text

_Full body text omitted from this summary view._ Fetch the complete paper as Markdown: https://tomesphere.com/paper/PMC12987289/full.md

## Figures

8 figures with captions in the complete paper: https://tomesphere.com/paper/PMC12987289/full.md

## References

73 references — full list in the complete paper: https://tomesphere.com/paper/PMC12987289/full.md

---
Source: https://tomesphere.com/paper/PMC12987289