Skip to content

fromabhinavkr/DETECTION-OF-SURFACE-DEFECTS-IN-PRINTED-CIRCUIT-BOARDS-USING-YOLOv8

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 

Repository files navigation

DETECTION OF SURFACE DEFECTS IN PRINTED CIRCUIT BOARDS USING YOLOv8

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.


📋 Table of Contents


🚀 Overview

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

📦 Dataset

  • Format: Pascal VOC (XML annotations + images)
  • Size: ~1386 images
  • Classes:
    • Missing Hole
    • Mouse Bite
    • Open Circuit
    • Short
    • Spur
    • Spurious Copper

🏗️ Project Structure

.
├── 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 Details

  • Model Used: YOLOv8n (Nano Version)
  • Epochs: 20
  • Image Size: 640x640
  • Optimization: Automatically handles missing labels and skipped annotations.

📊 Results

  • High accuracy in detecting all six types of defects.
  • Real-time detection enabled.
  • Lightweight model suitable for deployment on edge devices.

📄 License

  • TBA

🙏 Acknowledgements


👨‍💻 Author

About

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.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages