The surface flaws detection of objects has always been an important application direction of deep learning,and tile defect detection is one of them.There are not only some large size striped flaws such as edge anomalies,but also some tiny flaws such as dark dot flaws since the surface flaws scale of tiles varies greatly.Furthermore,the spatial location of flaws varies greatly,such as some flaws with different directions,and some flaws are also interfered by the background pattern.This thesis solves this problem by adding three attention modules to the detection head of the YOLOv3,the scale perception layer is used to identify flaws with large scale variation,so that the network can detect both large and small flaws well;the spatial perception layer is used to identify flaws with large spatial location variations,so that the network can extract not only flaws with regular shapes but also those with irregular shapes and those with rotations in location well;the task perception layer is used to handle the regression task for different labeled datasets.By conducting ablation experiments on the tile detection dataset(2021 Alibaba Cloud TIANCHI Competition),this study demonstrates the effectiveness of this Dynamic Detection Head Network(DNHN).In addition,since some flaws are interspersed with some complex background patterns,the DNHN feature extraction module cannot identify these flaws well if ordinary convolution is used.Therefore,this thesis uses the self-attentive module instead of the convolution module in the feature extraction part of the network to extract these flaws features.Then,we add deformable convolution to the feature extraction module to further enhance the network’s ability to detect narrow and long types and large spatially varying flaws.A Flaws Detection network with DCN and Transformer(FDTR)based on attention mechanism and deformable convolution is constructed.The FDTR can learn the connection between the pixel points in the images,which not only improves the detection ability of the network for tiny types of flaws,but also can remove the interference of background patterns and successfully detect flaws located in complex backgrounds.Finally,microstructure flaw images are mostly taken with highdefinition cameras,such as the images of the tile flaw dataset used in this thesis are high-resolution images of 8000*6000.In order to process such high-resolution images,slicing,stitching and sample balancing techniques for the input images are added to the network to improve its ability to adapt to various complex production environments.Therefore,the network achieved positive results on the tile flaws detection dataset. |