Citation: | WEI Jinyang, YUAN Mingzhe, CAO Feidao, BAI Haijun, WANG Wenhong. Defect Detection Based on Attention Mechanism and Atrous Pyramid Pooling[J]. INFORMATION AND CONTROL, 2024, 53(5): 662-672. DOI: 10.13976/j.cnki.xk.2024.3148 |
To solve the problem of low feature reconstruction accuracy in industrial product surface defect detection, which leads to high false positive rates at the image, pixel, and region levels, we propose an unsupervised defect detection method with improved deep feature reconstruction (DFR). First, we introduce jump connections into the feature reconstruction process to improve the feature reconstruction accuracy and the ability of the model to reconstruct positive sample features. Second, we introduce an attention mechanism to improve the attention of the algorithm to defect regions and explore the effect of spatial attention on defect detection for different targets. Third, we introduce atrous pyramid pooling into the feature reconstruction module to capture context at multiple scales without increasing the number of parameters to improve the ability of the model to detect defects at different scales. Finally, we use the L2-SSIM loss function to constrain feature reconstruction to preserve the feature structure while maintaining pixel similarity. The proposed algorithm achieves 97.5%, 97.2%, and 93.1% detection accuracy at the image, pixel, and region levels, respectively, outperforming the comparison algorithm.
[1] |
KUANG H L, DING Y R, LI R F, et al. Defect detection of bamboo strips based on LBP and GLCM features by using SVM classifier[C]//Chinese Control and Decision Conference. Piscataway, USA: IEEE, 2018: 3341-3345.
|
[2] |
包从望, 胡才梦, 张彩红, 等. 基于改进Canny算子的齿轮缺陷检测边缘检测算法[J]. 组合机床与自动化加工技术, 2023, 587(1): 83-86, 91.
BAO C W, HU C M, ZHANG C H, et al. Edge detection algorithm of gear defect detection based on improved Canny operator[J]. Modular Machine Tool & Automatic Manufacturing Technique, 2023, 587(1): 83-86, 91.
|
[3] |
黄梦涛, 连一鑫. 基于改进Canny算子的锂电池极片表面缺陷检测[J]. 仪器仪表学报, 2021, 42(10): 199-209.
HUANG M T, LIAN Y X. Lithium battery electrode plate surface defect detection based on improved Canny operator[J]. Chinese Journal of Scientific Instrument, 2021, 42(10): 199-209.
|
[4] |
GE Q C, FANG M, XU J. Defect detection of industrial products based on improved Hough transform[C]//IEEE International Conference on Mechatronics and Automation. Piscataway, USA: IEEE, 2018: 832-836.
|
[5] |
ZHOU Q Q, SITU Z X, TENG S, et al. Automatic sewer defect detection and severity quantification based on pixel-level semantic segmentation[J/OL]. Tunnelling and Underground Space Technology, 2022, 123[2023-05-01]. https://www.sciencedirect.com/science/article/pii/S0886779822000438. DOI: 10.1016/j.tust.2022.104403.
|
[6] |
RONNEBERGER O, FISCHER P, BROX T. U-Net: Convolutional networks for biomedical image segmentation[C]//International Conference on Medical Image Computing and Computer-assisted Intervention. Berlin, Germany: Springer, 2015: 234-241.
|
[7] |
HE K M, GKIOXARI G, DOLLáR P, et al. Mask R-CNN[C]//IEEE International Conference on Computer Vision. Piscataway, USA: IEEE, 2017: 2980-2988.
|
[8] |
LI C L, SOHN K, YOON J, et al. CutPaste: Self-supervised learning for anomaly detection and localization[C]//IEEE/CVF Conference on Computer Vision and Pattern Recognition. Piscataway, USA: IEEE, 2021: 9664-9674.
|
[9] |
YANG H, CHEN Y, SONG K, et al. Multiscale feature-clustering-based fully convolutional autoencoder for fast accurate visual inspection of texture surface defects[J]. IEEE Transactions on Automation Science and Engineering, 2019, 16(3): 1450-1467. doi: 10.1109/TASE.2018.2886031
|
[10] |
MEI H Y Z. An unsupervised-learning-based approach for automated defect inspection on textured surfaces[J]. IEEE Transactions on Instrumentation and Measurement, 2018, 67(6): 1266-1277. doi: 10.1109/TIM.2018.2795178
|
[11] |
GONG D, LIU L, LE V, et al. Memorizing normality to detect anomaly: Memory-augmented deep autoencoder for unsupervised anomaly detection[C/OL]//IEEE/CVF International Conference on Computer Vision. Piscataway, USA: IEEE, 2019[2023-04-26]. https://ieeexplore.ieee.org/document/9010977. DOI: 10.1109/ICCV.2019.00179.
|
[12] |
AKAY S, ATAPOUR-ABARGHOUEI A, BRECKON T P. Skip-GANomaly: Skip connected and adversarially trained encoder-decoder anomaly detection[C/OL]//International Joint Conference on Neural Networks. Piscataway, USA: IEEE, 2019[2023-04-20]. https://ieeexplore.ieee.org/document/8851808. DOI: 10.1109/IJCNN.2019.8851808.
|
[13] |
BAUR C, WIESTLER B, Albarqouni S, et al. Deep autoencoding models for unsupervised anomaly segmentation in brain MR images[M]//Lecture Notes in Computer Science: vol. 11383. Berlin, Germany: Springer-Verlag, 2019: 161-169.
|
[14] |
YANG J, SHI Y, QI Z Q. Unsupervised anomaly segmentation via deep feature reconstruction[J]. Neurocomputing, 2021, 424(1): 9-22.
|
[15] |
SIMONYAN K, ZISSERMAN A. Very deep convolutional networks for large-scale image recognition[EB/OL]. (2015-04-10)[2023-04-15]. https://arxiv.org/abs/1409.1556. DOI: 10.48550/arXiv.1409.1556
|
[16] |
蒋羽. 面向工业应用场景的深度学习缺陷检测方法研究[D]. 杭州: 浙江大学, 2022.
JIANG Y. Research on deep learning defect detection methods for industrial application scenarios[D]. Hangzhou: Zhejiang University, 2022.
|
[17] |
杨胜雄, 陈莹. 基于残差池化自编码机的无监督异常分割[J/OL]. 计算机集成制造系统[2023-04-10]. http://kns.cnki.net/kcms/detail/11.5946.TP.20220328.1632.011.html.
YANG S H, CHEN Y. Unsupervised anomaly segmentation based on residual max-pooling autoencoder[J/OL]. Computer Integrated Manufacturing Systems[2023-04-10]. http://kns.cnki.net/kcms/detail/11.5946.TP.20220328.1632.011.html.
|
[18] |
LIN T Y, DOLLAR P, GIRSHICK R, et al. Feature pyramid networks for object detection[C]//IEEE Conference on Computer Vision and Pattern Recognition. Piscataway, USA: IEEE, 2017[2023-03-29]. https://ieeexplore.ieee.org/document/8099589. DOI: 10.1109/CVPR.2017.106.
|
[19] |
CHEN L C, MURPHY K, KOKKINOS I, et al. DeepLab: Semantic image segmentation with deep convolutional nets, atrous convolution, and fully Connected CRFs[J]. IEEE Transactions on Pattern Analysis and Machine Intelligence, 2017, 40(4): 834-848.
|
[20] |
WOO S, PARK J, LEE J Y, et al. CBAM: Convolutional block attention module[C]//European Conference on Computer Vision. Berlin, Germany: Springer, 2018: 3-19.
|
[21] |
JIE H, LI S, GANG S. Squeeze-and-excitation networks[C/OL]//IEEE/CVF Conference on Computer Vision and Pattern Recognition. Piscataway, USA: IEEE, 2018[2023-04-15]. https://ieeexplore.ieee.org/document/8578843. DOI: 10.1109/CVPR.2018.00745.
|
[22] |
BERGMANN P, FAUSER M, SATTLEGGER D, et al. MVTec AD — A comprehensive real-world dataset for unsupervised anomaly detection[C/OL]//IEEE/CVF Conference on Computer Vision and Pattern Recognition. Piscataway, USA: IEEE, 2020[2023-04-08]. https://ieeexplore.ieee.org/document/8954181. DOI: 10.1109/CVPR.2019.00982.
|
[23] |
BERGMANN P, FAUSER M, SATTLEGGER D, et al. Uninformed students: Student-teacher anomaly detection with discriminative latent embeddings[C]//IEEE/CVF Conference on Computer Vision and Pattern Recognition. Piscataway, USA: IEEE, 2020: 4183-4192
|
[24] |
COHEN N, HOSHEN Y. Sub-Image anomaly detection with deep pyramid correspondences[EB/OL]. (2021-02-03)[2023-03-27]. https://arxiv.org/abs/2005.02357. DOI: 10.48550/arXiv.2005.02357.
|
[25] |
YI J, YOON S. Patch SVDD: Patch-level SVDD for anomaly detection and segmentation[C]//Asian Conference on Computer Vision. Berlin, Germany: Springer, 2021: 375-390.
|
[26] |
MVTec. The MVTec anomaly detection dataset[DS/OL]. [2023-03-05]. https://www.mvtec.com/company/research/datasets/mvtec-ad.
|