File size: 2,158 Bytes
4828975
 
 
 
 
 
 
 
 
 
 
 
 
 
2e7b979
 
4828975
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2e7b979
 
 
 
 
 
 
 
4828975
 
2e7b979
 
4828975
 
2e7b979
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
---
library_name: anomalib
tags:
  - anomaly-detection
  - computer-vision
  - pcb
  - efficientad
  - anomalib
datasets:
  - VisA
---

# VisionQC EfficientAD-medium for VisA/pcb1

[![GitHub](https://img.shields.io/badge/GitHub-VisionQC-181717?logo=github)](https://github.com/pnthang04/VisionQC)

EfficientAD-medium anomaly detection checkpoint trained with Anomalib 2.6.0
on the `pcb1` category of VisA.

## Results

The reported test split is independent from the validation split used for
early stopping and checkpoint selection.

| Metric | Value |
|---|---:|
| Validation image AUROC | 0.8936 |
| Test image AUROC | 0.9364 |
| Test image F1 | 0.8785 |
| Test pixel AUROC | 0.9883 |
| Test pixel F1 | 0.6095 |
| Test pixel AUPRO | 0.8686 |

## Training configuration

- Model: EfficientAD-medium
- Dataset: VisA/pcb1
- Training images: 904 normal
- Validation: 100 images
- Test: 50 normal and 50 anomalous images
- Batch size: 32 per GPU
- Devices: 2 Tesla T4 GPUs
- Effective batch size: 64
- Precision: FP16 mixed precision
- Early stopping: validation image AUROC, patience 20, minimum delta 0.001
- Best epoch: 30
- Best global step: 465

This uses a local `BatchedEfficientAd` wrapper to permit batched DDP training
without modifying Anomalib core. The architecture itself remains
EfficientAD-medium. Results are not directly comparable to the official
batch-size-1 EfficientAD baseline.

## Files

- `model-best.ckpt`: best Lightning checkpoint selected by validation image AUROC
- `config.yaml`: complete VisionQC training configuration
- `metrics.json`: test metrics generated after restoring the best checkpoint

## Loading

Download the checkpoint:

```bash
hf download thangkt/visionqc-efficientad-medium-pcb1 model-best.ckpt \
  --local-dir weights/efficientad-medium-pcb1
```

Use it with the VisionQC project and Anomalib 2.6.0:

```bash
visionqc evaluate \
  --checkpoint weights/efficientad-medium-pcb1/model-best.ckpt
```

## Links

- Source: https://github.com/pnthang04/VisionQC
- Multi-GPU training PR: https://github.com/pnthang04/VisionQC/pull/1
- Model repository: https://huggingface.co/thangkt/visionqc-efficientad-medium-pcb1