Dilated Involutional Pyramid Network (DInPNet): A Novel Model for Printed Circuit Board (PCB) Components Classification
This repository contains the source code of our paper, DInPNet (published in ISQED-23).
We introduce a novel light-weight PCB component classification network, named DInPNet. We introduce the dilated involutional pyramid (DInP) block, which consists of an involution for transforming the input feature map into a low-dimensional space for reduced computational cost, followed by a pairwise pyramidal fusion of dilated involutions that resample back the feature map. This enables learning representations for a large effective receptive field while bringing down the number of parameters considerably.
βββ LICENSE <- The LICENSE for developers using this project.
βββ README.md <- The top-level README for developers using this project.
βββ 3A5_DInPNet.pdf <- Presentation PDF file of the project.
βββ requirements.txt <- The requirements file for reproducing the analysis environment, e.g. generated with `pip freeze > requirements.txt`.
|ββ reports <- The directory containing metadata used for repo.
βββ checkpoints <- Directory where best models will be saved.
βββ src <- Source code for use in this project.
βΒ Β βββ dataloader.py <- Source code for generating data loader.
| βββ config.py <- basic configurations for classification training of DInPNet model.
βΒ Β βββ network.py <- Source code for the DInPNet network.
βΒ Β βββ utils.py <- Source code for utilities and helper functions.
βΒ Β βββ train.py <- Source code for training and validation of DInPNet
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
Figure 1. (A) DInPNet (B) Dilated Involutional Pyramid Block
Dependencies:
pip install -r requirements.txtFirst, create a conda environment
conda create -n va python=3.8
conda activate va
conda install pip
pip install -r requirements.txtWe have used FICS-PCB dataset which can be downloaded from here. Components data needs to placed under data/ directory.
βββ Train
β ββββcapacitors
βΒ Β β βββ image_0.png
βΒ Β β βββ image_1.png
βΒ Β β βββ ...
β ββββdiodes
βΒ Β β βββ image_0.png
βΒ Β β βββ image_1.png
βΒ Β β βββ ...
| βββ ...
βββ Test
β ββββcapacitors
βΒ Β β βββ image_0.png
βΒ Β β βββ image_1.png
βΒ Β β βββ ...
β ββββdiodes
βΒ Β β βββ image_0.png
βΒ Β β βββ image_1.png
βΒ Β β βββ ...
| βββ ...
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
Change the hyperparameters and configuration parameters according to need in src/config.py.
To train DInPNet, Run following command from /src directory.
python train.pyAbove command will train model for 100 epochs with given configuration.
The trained checkpoint for model training will be saved in /weights/best.pt
@inproceedings {mantravadi2023Dilated,
title = {{Dilated Involutional Pyramid Network (DInPNet): A Novel Model for Printed Circuit Board (PCB) Components Classification}},
year = "2023",
author = "Ananya Mantravadi and Dhruv Makwana and R Sai Chandra Teja and Sparsh Mittal and Rekha Singhal",
booktitle = {{24th International Symposium on Quality Electronic Design (ISQED)}},
address = "California, USA",
}
CC BY-NC-ND 4.0
