Guided-crop image augmentation for small defect classification

Conference Article


International Conference on Pattern Recognition (ICPR)





Doc link


Download the digital copy of the doc pdf document


As processing power becomes more affordable, com- puter vision tends to push towards controlling complex processes in the industry. Surface inspection, with changing environmental conditions and the usual lack of homogeneity of the inspected parts, makes it a real challenge to overcome even for a skilled specialist. In addition, the scarcity of positive samples and the extremely small size of the defects, makes it even harder to cluster them in different classes. In this work, we propose a novel train- ing strategy tailored to handle these challenges for the problem of image defect segmentation and classification. First, we propose a Context Aggregation Network with different dilation factors, in order to keep as much information as possible from every feature map, especially for the smallest defects. By splitting the loss in classification and segmentation and positively weighing both terms, we accomplish an optimal learning process counteracting possible imbalances in the dataset. Additionally, we introduce a novel guided-crop image augmentation method, which generates new images by cropping real defects from existing images, pasting them in real non-defective ones and finally tweaking their configuration. This augmentation strategically performed, guided by the evolution of each class loss, allows the model to identify better the least common and complicated to identify defects. We validate our solution with the Magnetic Tile and the Severstal Steel Defect Detection dataset, demonstrating that our approach consistently outperforms models such as ResNet-50, DenseNet- 121, HRNet or UPerNet.


pattern recognition.

Author keywords

Segmentation, Deep Learning, Industry

Scientific reference

J. Orti, F. Moreno-Noguer and V. Puig. Guided-crop image augmentation for small defect classification, 26th International Conference on Pattern Recognition, 2022, Montreal, Canada, pp. 104-110.