Evaluates a model's ability to classify six specific types of PCB manufacturing defects from cropped defect images. It probes the model's feature extraction and categorization capabilities on a specialized industrial computer vision dataset. Use when the user wants to benchmark on PCB Defect Dataset, or asks about evaluating this task. Reports average_precision_rate.
Scanned 9/11/2026
Install to Claude Code
npx -y skills add qhjqhj00/research-skills-pool --skill pcb-defect-classification-eval --agent claude-codeInstalls into .claude/skills of the current project.
Are you the author of Pcb Defect Classification Eval?
Add the live security badge to your README — it updates automatically with every re-scan.
[](https://www.skillsdirectory.com/skills/qhjqhj00-pcb-defect-classification-eval)More formats (shields.io, HTML) on the badges page.
---
name: pcb-defect-classification-eval
description: Evaluates a model's ability to classify six specific types of PCB manufacturing defects from cropped defect images. It probes the model's feature extraction and categorization capabilities on a specialized industrial computer vision dataset. Use when the user wants to benchmark on PCB Defect Dataset, or asks about evaluating this task. Reports average_precision_rate.
metadata:
skill_kind: dataset_eval
source_arxiv: 1901.08204
bibtex_key: huang2019pcb
confidence: high
---
# pcb-defect-classification-eval
> A PCB Dataset for Defects Detection and Classification — Huang et al. (2019) (arXiv:1901.08204, 2019)
## What this evaluates
Evaluates a model's ability to classify six specific types of PCB manufacturing defects from cropped defect images. It probes the model's feature extraction and categorization capabilities on a specialized industrial computer vision dataset.
## Datasets
- **PCB Defect Dataset** — total 5906; splits: train (3597), val (1161), test (1148)
## Metrics
- `classification_precision_rate` — range: percent
- The ratio of correctly predicted defects of a specific type to the actual number of that defect type, multiplied by 100. Formula: $P_c = (c / a) \times 100\%$, where $c$ is correctly predicted count and $a$ is actual count.
- `average_precision_rate` **(primary)** — range: percent
- The mean of the classification precision rates across all 6 defect types. Formula: $AP_c = (1/N) \sum_{i=1}^{N} P_c^i$, where $N=6$.
## Input / output format
**Input**: Cropped 64x64 images of individual PCB defects, extracted using bounding box coordinates and optionally augmented with 5-10 pixel random offsets.
**Output**: A single class label from 6 categories: missing hole, mouse bite, open circuit, short, spur, spurious copper.
## Scoring recipe
```python
def compute_metrics(predictions, gold):
classes = ['missing_hole', 'mouse_bite', 'open_circuit', 'short', 'spur', 'spurious_copper']
precisions = []
for cls in classes:
actual = sum(1 for g in gold if g == cls)
if actual == 0: continue
correct = sum(1 for p, g in zip(predictions, gold) if p == cls and g == cls)
precisions.append(correct / actual * 100)
avg_prec = sum(precisions) / len(precisions)
return {'classification_precision_rate': precisions, 'average_precision_rate': avg_prec}
```
## Common pitfalls
- Images are resized to 64x64 before classification, which may distort aspect ratios and affect feature extraction.
- Data augmentation applies random 5-10 pixel offsets to bounding boxes, meaning test images are not exact crops of the original dataset.
- The dataset contains synthesized/annotated defects, so performance may not generalize to real-world AOI images without domain adaptation.
## Evidence (verbatim from paper)
> The metrics of defect classification are the classification precision rate ($P_{c}$) of each type of defect and the average precision rate ($AP_{c}$). $P_{c}$ is defined in the following equation: $P_{c}=\frac{c}{a}\times 100\%$ in which $c$ is the correctly predicted number of a defect type, and $a$ is the actual number of defects of this type. And the average precision rate ($AP_{c}$) is defined as: $AP_{c}=\frac{1}{N}\sum_{i=1}^{N}P_{c}^{i}$ where $P_{c}^{i}$ is the precision rate of $i^{th}$ defect, $N$ denotes the number of types of defects, which is 6 in this paper.
## Citation
```bibtex
@misc{huang2019pcb,
title={A PCB Dataset for Defects Detection and Classification},
author={Huang et al. (2019)},
year={2019},
note={arXiv:1901.08204}
}
```
- arXiv: 1901.08204
Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.
No comments yet. Be the first to comment!