An end-to-end YOLOv8-based system for detecting six types of PCB surface defects. It includes dataset conversion, automated train/val split, model training, and real-time inference, offering a fast and accurate solution for PCB quality inspection.
This project automates the detection of six common PCB surface defects using the YOLOv8 object detection model.
It includes:
- Data extraction and formatting
- XML to YOLO annotation conversion
- Dataset splitting (train/val)
- YOLOv8 model training
- Inference and result visualization
- Format: Pascal VOC (XML annotations + images)
- Size: ~1386 images
- Classes:
- Missing Hole
- Mouse Bite
- Open Circuit
- Short
- Spur
- Spurious Copper
.
├── pcbarchive.zip # Original dataset zip
├── dataset/ # Processed dataset in YOLO format
│ ├── images/
│ │ ├── train/
│ │ └── val/
│ ├── labels/
│ │ ├── train/
│ │ └── val/
├── pcb.yaml # YOLOv8 configuration file
├── runs/ # Training runs and model weights
├── test.jpg # Sample test image
├── result.jpg # Output image after detection
└── main.py # Full project script- Model Used: YOLOv8n (Nano Version)
- Epochs: 20
- Image Size: 640x640
- Optimization: Automatically handles missing labels and skipped annotations.
- High accuracy in detecting all six types of defects.
- Real-time detection enabled.
- Lightweight model suitable for deployment on edge devices.
- TBA
- Name: ABHINAV K R
- Contact: abhinavnowkr@gmail.com
- LinkedIn: abhinavkravi