Dual Attention-Based Industrial Surface Defect Detection with Consistency Loss
<p>Industrial product samples with surface defects: each sub-figure represents a different industrial product (four in total) and each picture represents a different defect. The area in the red box contains the surface defect of each product.</p> "> Figure 2
<p>The network architecture of the proposed method.</p> "> Figure 3
<p>The dual attention block: the parallel fusion of multi-scale channel attention and pixel attention. ⊕ denotes the broadcasting addition and ⊗ denotes the element-wise multiplication.</p> "> Figure 4
<p>The defect-free and defect samples in the Magnetic Tile dataset.</p> "> Figure 5
<p>The Random Erasing data enhancement processing.</p> "> Figure 6
<p>The AUC of our proposed method and five other GAN-based methods, which were tested using the MVTec AD dataset.</p> "> Figure 7
<p>The first four rows of images show the test results from the partial MVTec AD dataset and the fifth row shows the test results from the Magnetic Tile dataset. Def. represents the defect image, Rec. represents the reconstructed image and Res. represents the residual image.</p> "> Figure 8
<p>The heat maps of an image of a defective metal nut using the different attention structures.</p> ">
Abstract
:1. Introduction
- An encoder–decoder generative adversarial network is proposed that directly maps image spaces on to latent spaces;
- A novel dual attention block is proposed within the encoder network;
- A consistency loss function is proposed to enhance the ability of the network to reconstruct defect-free images.
2. Related Work
2.1. Surface Defect Detection
2.2. Anomaly Detection
3. Proposed Method
3.1. Network Architecture
3.1.1. Generative Network
3.1.2. Dual Attention Block
3.1.3. Discriminative Network
3.2. Training Strategy
- First, the generative network weights and the discriminative network weights were initialized, then the generative network weights were fixed and the discriminative network weights were updated. The discriminative loss adopted the binary classification cross-entropy loss within the classical GAN;
- After the discriminative network weights were updated, the discriminative network weights were fixed and the generative network weights were updated. Adversarial loss and consistency loss were introduced when updating the generative network weights.
3.3. Anomaly Score
4. Experiments
4.1. Datasets
4.2. Training Details
4.3. Evaluation Indicators
4.4. Experimental Results
4.5. Ablation Studies
4.5.1. Effectiveness of the Dual Attention Block
4.5.2. Effectiveness of the Consistency Loss
5. Conclusions
Author Contributions
Funding
Institutional Review Board Statement
Informed Consent Statement
Data Availability Statement
Acknowledgments
Conflicts of Interest
References
- Kang, G.; Gao, S.; Yu, L.; Zhang, D. Deep architecture for high-speed railway insulator surface defect detection: Denoising autoencoder with multitask learning. IEEE Trans. Instrum. Meas. 2018, 68, 2679–2690. [Google Scholar] [CrossRef]
- Yu, H.; Li, Q.; Tan, Y.; Gan, J.; Wang, J.; Geng, Y.A.; Jia, L. A coarse-to-fine model for rail surface defect detection. IEEE Trans. Instrum. Meas. 2018, 68, 656–666. [Google Scholar] [CrossRef]
- Chen, X.; Lv, J.; Fang, Y.; Du, S. Online Detection of Surface Defects Based on Improved YOLOV3. Sensors 2022, 22, 817. [Google Scholar] [CrossRef] [PubMed]
- Wang, C.; Xiao, Z. Lychee surface defect detection based on deep convolutional neural networks with gan-based data augmentation. Agronomy 2021, 11, 1500. [Google Scholar] [CrossRef]
- Huang, T.; Zheng, B.; Zhang, J.; Yi, C.; Jiang, Y.; Shui, Q.; Jian, H. Mango Surface Defect Detection Based on HALCON. In Proceedings of the 2021 IEEE 5th Advanced Information Technology, Electronic and Automation Control Conference, Chongqing, China, 12–14 March 2021; pp. 2627–2631. [Google Scholar]
- Ding, F.; Yang, G.; Ding, D.; Cheng, G. Retinal Nerve Fiber Layer Defect Detection with Position Guidance. In Proceedings of the International Conference on Medical Image Computing and Computer-Assisted Intervention, Lima, Peru, 4–8 October 2020; pp. 745–754. [Google Scholar]
- Panda, R.; Puhan, N.B.; Rao, A.; Mandal, B.; Padhy, D.; Panda, G. Deep convolutional neural network-based patch classification for retinal nerve fiber layer defect detection in early glaucoma. J. Med. Imaging 2018, 5, 044003. [Google Scholar] [CrossRef]
- Rudolph, M.; Wandt, B.; Rosenhahn, B. Same same but differnet: Semi-supervised defect detection with normalizing flows. In Proceedings of the IEEE/CVF Winter Conference on Applications of Computer Vision, Waikoloa, HI, USA, 5–9 January 2021; pp. 1907–1916. [Google Scholar]
- Su, B.; Chen, H.; Zhou, Z. BAF-Detector: An Efficient CNN-Based Detector for Photovoltaic Cell Defect Detection. IEEE Trans. Ind. Electron. 2021, 69, 3161–3171. [Google Scholar] [CrossRef]
- Xu, X.; Chen, J.; Zhang, H.; Ng, W.W. D4Net: De-deformation defect detection network for non-rigid products with large patterns. Inf. Sci. 2021, 547, 763–776. [Google Scholar] [CrossRef]
- Alvarenga, T.A.; Carvalho, A.L.; Honorio, L.M.; Cerqueira, A.S.; Filho, L.M.; Nobrega, R.A. Detection and classification system for rail surface defects based on Eddy current. Sensors 2021, 21, 7937. [Google Scholar] [CrossRef]
- Ho, C.C.; Chou, W.C.; Su, E. Deep Convolutional Neural Network Optimization for Defect Detection in Fabric Inspection. Sensors 2021, 21, 7074. [Google Scholar] [CrossRef]
- Bakhshi, T.; Ghita, B. Anomaly Detection in Encrypted Internet Traffic Using Hybrid Deep Learning. Secur. Commun. Netw. 2021, 2021, 5363750. [Google Scholar] [CrossRef]
- Qu, Y.; Uddin, M.P.; Gan, C.; Xiang, Y.; Gao, L.; Yearwood, J. Blockchain-Enabled Federated Learning: A Survey. In Proceedings of the 2021 IEEE 1st International Conference on Digital Twins and Parallel Intelligence (DTPI), Beijing, China, 15 July–15 August 2022. [Google Scholar]
- Feng, B.; Zhou, H.; Li, G.; Zhang, Y.; Sood, K.; Yu, S. Enabling Machine Learning with Service Function Chaining for Security Enhancement at 5G Edges. IEEE Netw. 2021, 35, 196–201. [Google Scholar] [CrossRef]
- Li, G.; Zhou, H.; Feng, B.; Zhang, Y.; Yu, S. Efficient provision of service function chains in overlay networks using reinforcement learning. IEEE Trans. Cloud Comput. 2019, 10, 383–395. [Google Scholar] [CrossRef]
- Feng, B.; Li, G.; Li, G.; Zhang, Y.; Zhou, H.; Yu, S. Enabling efficient service function chains at terrestrial-satellite hybrid cloud networks. IEEE Netw. 2019, 33, 94–99. [Google Scholar] [CrossRef]
- Vu, L.; Nguyen, Q.U.; Nguyen, D.N.; Hoang, D.T.; Dutkiewicz, E. Learning latent representation for iot anomaly detection. IEEE Trans. Cybern. 2020, 52, 3769–3782. [Google Scholar] [CrossRef]
- Bhatia, R.; Benno, S.; Esteban, J.; Lakshman, T.; Grogan, J. Unsupervised machine learning for network-centric anomaly detection in IoT. In Proceedings of the 3rd Acm Conext Workshop on Big Data, Machine Learning and Artificial Intelligence for Data Communication Networks, Orlando, FL, USA, 9 December 2019; pp. 42–48. [Google Scholar]
- Feng, B.; Tian, A.; Yu, S.; Li, J.; Zhou, H.; Zhang, H. Efficient Cache Consistency Management for Transient IoT Data in Content-Centric Networking. IEEE Internet Things J. 2022. [Google Scholar] [CrossRef]
- Liu, W.; Luo, W.; Lian, D.; Gao, S. Future frame prediction for anomaly detection–a new baseline. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, Salt Lake City, UT, USA, 18–22 June 2018; pp. 6536–6545. [Google Scholar]
- Sultani, W.; Chen, C.; Shah, M. Real-world anomaly detection in surveillance videos. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, Salt Lake City, UT, USA, 18–22 June 2018; pp. 6479–6488. [Google Scholar]
- Chalapathy, R.; Menon, A.K.; Chawla, S. Anomaly detection using one-class neural networks. arXiv 2018, arXiv:1802.06360. [Google Scholar]
- Yang, C.; Liu, P.; Yin, G.; Jiang, H.; Li, X. Defect detection in magnetic tile images based on stationary wavelet transform. Ndt E Int. 2016, 83, 78–87. [Google Scholar] [CrossRef]
- Ahn, E.; Kumar, A.; Feng, D.; Fulham, M.; Kim, J. Unsupervised deep transfer feature learning for medical image classification. In Proceedings of the 2019 IEEE 16th International Symposium on Biomedical Imaging, Venice, Italy, 8–11 April 2019; pp. 1915–1918. [Google Scholar]
- Li, H.; Boulanger, P. Structural Anomalies Detection from Electrocardiogram (ECG) with Spectrogram and Handcrafted Features. Sensors 2022, 22, 2467. [Google Scholar] [CrossRef]
- Cheng, H.; Liu, H.; Gao, F.; Chen, Z. Adgan: A scalable gan-based architecture for image anomaly detection. In Proceedings of the 2020 IEEE 4th Information Technology, Networking, Electronic and Automation Control Conference, Chongqing, China, 12–14 June 2020; pp. 987–993. [Google Scholar]
- Akcay, S.; Atapour-Abarghouei, A.; Breckon, T.P. Ganomaly: Semi-supervised anomaly detection via adversarial training. In Proceedings of the Asian Conference on Computer Vision, Perth, WA, Australia, 2–6 December 2018; pp. 622–637. [Google Scholar]
- Schlegl, T.; Seeböck, P.; Waldstein, S.M.; Schmidt-Erfurth, U.; Langs, G. Unsupervised anomaly detection with generative adversarial networks to guide marker discovery. In Proceedings of the International Conference on Information Processing in Medical Imaging, Boone, NC, USA, 25–30 June 2017; pp. 146–157. [Google Scholar]
- Soukup, D.; Pinetz, T. Reliably Decoding Autoencoders’ Latent Spaces for One-Class Learning Image Inspection Scenarios. In Proceedings of the OAGM Workshop, Hall/Tyrol, Austria, 15–16 May 2018. [Google Scholar]
- Zhang, H.; Jin, X.; Wu, Q.J.; Wang, Y.; He, Z.; Yang, Y. Automatic visual detection system of railway surface defects with curvature filter and improved Gaussian mixture model. IEEE Trans. Instrum. Meas. 2018, 67, 1593–1608. [Google Scholar] [CrossRef]
- Li, J.; Levine, M.D.; An, X.; Xu, X.; He, H. Visual saliency based on scale-space analysis in the frequency domain. IEEE Trans. Pattern Anal. Mach. Intell. 2012, 35, 996–1010. [Google Scholar] [CrossRef] [Green Version]
- Chao, S.M.; Tsai, D.M. Anisotropic diffusion with generalized diffusion coefficient function for defect detection in low-contrast surface images. Pattern Recognit. 2010, 43, 1917–1931. [Google Scholar] [CrossRef]
- Zenati, H.; Romain, M.; Foo, C.S.; Lecouat, B.; Chandrasekhar, V. Adversarially learned anomaly detection. In Proceedings of the 2018 IEEE International Conference on Data Mining, Singapore, 17–20 November 2018; pp. 727–736. [Google Scholar]
- Wang, J.; Yi, G.; Zhang, S.; Wang, Y. An Unsupervised Generative Adversarial Network-Based Method for Defect Inspection of Texture Surfaces. Appl. Sci. 2021, 11, 283. [Google Scholar] [CrossRef]
- Choi, J.; Kim, C. Unsupervised detection of surface defects: A two-step approach. In Proceedings of the 2012 19th IEEE International Conference on Image Processing, Orlando, FL, USA, 30 September–3 October 2012; pp. 1037–1040. [Google Scholar]
- Kim, M.S.; Park, T.; Park, P. Classification of steel surface defect using convolutional neural network with few images. In Proceedings of the 2019 12th Asian Control Conference, Kitakyushu, Japan, 9–12 June 2019; pp. 1398–1401. [Google Scholar]
- Bergmann, P.; Fauser, M.; Sattlegger, D.; Steger, C. Uninformed students: Student-teacher anomaly detection with discriminative latent embeddings. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, Seattle, WA, USA, 4–19 June 2020; pp. 4183–4192. [Google Scholar]
- Wang, Y.; Zhang, Y.; Zheng, L.; Yin, L.; Chen, J.; Lu, J. Unsupervised Learning with Generative Adversarial Network for Automatic Tire Defect Detection from X-ray Images. Sensors 2021, 21, 6773. [Google Scholar] [CrossRef] [PubMed]
- Youkachen, S.; Ruchanurucks, M.; Phatrapomnant, T.; Kaneko, H. Defect segmentation of hot-rolled steel strip surface by using convolutional auto-encoder and conventional image processing. In Proceedings of the 2019 10th International Conference of Information and Communication Technology for Embedded Systems, Bangkok, Thailand, 25–27 March 2019; pp. 1–5. [Google Scholar]
- Bergmann, P.; Löwe, S.; Fauser, M.; Sattlegger, D.; Steger, C. Improving unsupervised defect segmentation by applying structural similarity to autoencoders. arXiv 2018, arXiv:1807.02011. [Google Scholar]
- Pang, G.; Shen, C.; Cao, L.; Hengel, A.V.D. Deep learning for anomaly detection: A review. ACM Comput. Surv. 2021, 54, 1–38. [Google Scholar] [CrossRef]
- Nakanishi, M.; Sato, K.; Terada, H. Anomaly Detection By Autoencoder Based On Weighted Frequency Domain Loss. arXiv 2021, arXiv:2105.10214. [Google Scholar]
- Schlegl, T.; Seeböck, P.; Waldstein, S.M.; Langs, G.; Schmidt-Erfurth, U. f-AnoGAN: Fast unsupervised anomaly detection with generative adversarial networks. Med. Image Anal. 2019, 54, 30–44. [Google Scholar] [CrossRef]
- Ronneberger, O.; Fischer, P.; Brox, T. U-net: Convolutional networks for biomedical image segmentation. In Proceedings of the International Conference on Medical Image Computing and Computer-Assisted Intervention, Munich, Germany, 5–9 October 2015; pp. 234–241. [Google Scholar]
- Akçay, S.; Atapour-Abarghouei, A.; Breckon, T.P. Skip-ganomaly: Skip connected and adversarially trained encoder-decoder anomaly detection. In Proceedings of the 2019 International Joint Conference on Neural Networks, Budapest, Hungary, 14–19 July 2019; pp. 1–8. [Google Scholar]
- Tang, T.W.; Kuo, W.H.; Lan, J.H.; Ding, C.F.; Hsu, H.; Young, H.T. Anomaly detection neural network with dual auto-encoders GAN and its industrial inspection applications. Sensors 2020, 20, 3336. [Google Scholar] [CrossRef]
- Berthelot, D.; Schumm, T.; Metz, L. Began: Boundary equilibrium generative adversarial networks. arXiv 2017, arXiv:1703.10717. [Google Scholar]
- Carrara, F.; Amato, G.; Brombin, L.; Falchi, F.; Gennaro, C. Combining gans and autoencoders for efficient anomaly detection. In Proceedings of the 2020 25th International Conference on Pattern Recognition, Milan, Italy, 10–15 January 2021; pp. 3939–3946. [Google Scholar]
- Donahue, J.; Krähenbühl, P.; Darrell, T. Adversarial feature learning. arXiv 2016, arXiv:1605.09782. [Google Scholar]
- Zhao, H.; Kong, X.; He, J.; Qiao, Y.; Dong, C. Efficient image super-resolution using pixel attention. In Proceedings of the European Conference on Computer Vision, Glasgow, UK, 23–28 August 2020; pp. 56–72. [Google Scholar]
- Dai, Y.; Gieseke, F.; Oehmcke, S.; Wu, Y.; Barnard, K. Attentional feature fusion. In Proceedings of the IEEE/CVF Winter Conference on Applications of Computer Vision, Waikoloa, HI, USA, 3–8 January 2021; pp. 3560–3569. [Google Scholar]
- Goodfellow, I.; Pouget-Abadie, J.; Mirza, M.; Xu, B.; Warde-Farley, D.; Ozair, S.; Courville, A.; Bengio, Y. Generative adversarial nets. In Proceedings of the Advances in Neural Information Processing Systems 27: Annual Conference on Neural Information Processing Systems 2014, Montreal, QC, Canada, 8–13 December 2014. [Google Scholar]
- Bergmann, P.; Batzner, K.; Fauser, M.; Sattlegger, D.; Steger, C. The MVTec anomaly detection dataset: A comprehensive real-world dataset for unsupervised anomaly detection. Int. J. Comput. Vis. 2021, 129, 1038–1059. [Google Scholar] [CrossRef]
- Huang, Y.; Qiu, C.; Yuan, K. Surface defect saliency of magnetic tile. Vis. Comput. 2020, 36, 85–96. [Google Scholar] [CrossRef]
- Zhong, Z.; Zheng, L.; Kang, G.; Li, S.; Yang, Y. Random erasing data augmentation. In Proceedings of the AAAI Conference on Artificial Intelligence, New York, NY, USA, 7–12 February 2020; pp. 13001–13008. [Google Scholar]
- Kingma, D.P.; Ba, J. Adam: A method for stochastic optimization. arXiv 2014, arXiv:1412.6980. [Google Scholar]
- Ling, C.X.; Huang, J.; Zhang, H. AUC: A statistically consistent and more discriminating measure than accuracy. In Proceedings of the International Joint Conference on Artificial Intelligence, Acapulco, Mexico, 9–15 August 2003; pp. 519–524. [Google Scholar]
Category | Training Set (N) | Testing Set (N) | Testing Set (P) | Resolution |
---|---|---|---|---|
Bottle | 209 | 20 | 63 | |
Cable | 224 | 58 | 92 | |
Capsule | 219 | 23 | 109 | |
Carpet | 280 | 28 | 89 | |
Grid | 264 | 21 | 57 | |
Hazelnut | 391 | 40 | 70 | |
Leather | 245 | 32 | 92 | |
Metal Nut | 220 | 22 | 93 | |
Pill | 267 | 26 | 141 | |
Screw | 320 | 41 | 119 | |
Tile | 230 | 33 | 84 | |
Toothbrush | 60 | 12 | 30 | |
Transistor | 213 | 60 | 40 | |
Wood | 247 | 19 | 60 | |
Zipper | 240 | 32 | 119 |
Category | AnoGAN | GANomaly | Skip-GANomaly | DAGAN | CBiGAN | Ours |
---|---|---|---|---|---|---|
Bottle | 0.80 | 0.79 | 0.93 | 0.98 | 0.87 | 0.94 |
Cable | 0.47 | 0.71 | 0.67 | 0.66 | 0.81 | 0.88 |
Capsule | 0.44 | 0.72 | 0.71 | 0.68 | 0.56 | 0.85 |
Carpet | 0.33 | 0.82 | 0.79 | 0.90 | 0.55 | 0.91 |
Grid | 0.87 | 0.74 | 0.65 | 0.86 | 0.99 | 0.94 |
Hazelnut | 0.25 | 0.87 | 0.90 | 1.00 | 0.77 | 0.95 |
Leather | 0.45 | 0.80 | 0.90 | 0.94 | 0.83 | 0.95 |
Metal Nut | 0.28 | 0.69 | 0.79 | 0.81 | 0.63 | 0.69 |
Pill | 0.71 | 0.67 | 0.75 | 0.76 | 0.81 | 0.89 |
Screw | 0.10 | 1.00 | 1.00 | 1.00 | 0.58 | 1.00 |
Tile | 0.40 | 0.72 | 0.85 | 0.96 | 0.91 | 0.80 |
Toothbrush | 0.43 | 0.70 | 0.68 | 0.95 | 0.94 | 1.00 |
Transistor | 0.69 | 0.80 | 0.81 | 0.79 | 0.77 | 0.88 |
Wood | 0.56 | 0.92 | 0.91 | 0.97 | 0.95 | 0.94 |
Zipper | 0.71 | 0.74 | 0.66 | 0.78 | 0.53 | 0.91 |
Mean | 0.499 | 0.779 | 0.800 | 0.869 | 0.766 | 0.902 |
Method | GANomaly | Adgan | Ours |
---|---|---|---|
AUC | 0.76 | 0.46 | 0.84 |
Category | Struc1 | Struc2 | Struc3 | Struc4 |
---|---|---|---|---|
Bottle | 0.95 | 0.94 | 0.96 | 0.95 |
Cable | 0.90 | 0.87 | 0.87 | 0.88 |
Capsule | 0.79 | 0.85 | 0.85 | 0.85 |
Carpet | 0.83 | 0.91 | 0.88 | 0.91 |
Grid | 0.87 | 0.87 | 0.92 | 0.94 |
Hazelnut | 0.94 | 0.97 | 0.92 | 0.95 |
Leather | 0.89 | 0.89 | 0.95 | 0.95 |
Metal Nut | 0.63 | 0.64 | 0.62 | 0.69 |
Pill | 0.86 | 0.87 | 0.89 | 0.89 |
Screw | 1.00 | 1.00 | 1.00 | 1.00 |
Tile | 0.71 | 0.70 | 0.71 | 0.80 |
Toothbrush | 1.00 | 1.00 | 0.99 | 1.00 |
Transistor | 0.86 | 0.87 | 0.86 | 0.88 |
Wood | 0.94 | 0.93 | 0.94 | 0.94 |
Zipper | 0.91 | 0.88 | 0.89 | 0.91 |
Mean | 0.872 | 0.879 | 0.884 | 0.902 |
Method | Struc1 | Struc2 | Struc3 | Struc4 |
---|---|---|---|---|
AUC | 0.75 | 0.82 | 0.79 | 0.84 |
Training Speed (s) | 0.0931 | 0.1550 | 0.1026 | 0.1557 |
Testing Speed (s) | 0.0276 | 0.0487 | 0.0413 | 0.0511 |
Category | |||
---|---|---|---|
Bottle | 0.95 | 0.94 | 0.94 |
Cable | 0.82 | 0.86 | 0.88 |
Capsule | 0.85 | 0.85 | 0.85 |
Carpet | 0.88 | 0.92 | 0.91 |
Grid | 0.87 | 0.86 | 0.94 |
Hazelnut | 0.96 | 0.94 | 0.95 |
Leather | 0.91 | 0.88 | 0.95 |
Metal Nut | 0.62 | 0.62 | 0.69 |
Pill | 0.86 | 0.90 | 0.89 |
Screw | 1.00 | 1.00 | 1.00 |
Tile | 0.73 | 0.72 | 0.80 |
Toothbrush | 1.00 | 1.00 | 1.00 |
Transistor | 0.87 | 0.87 | 0.88 |
Wood | 0.94 | 0.93 | 0.94 |
Zipper | 0.89 | 0.90 | 0.91 |
Mean | 0.876 | 0.879 | 0.902 |
Method | |||
---|---|---|---|
AUC | 0.82 | 0.83 | 0.84 |
Publisher’s Note: MDPI stays neutral with regard to jurisdictional claims in published maps and institutional affiliations. |
© 2022 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (https://creativecommons.org/licenses/by/4.0/).
Share and Cite
Li, X.; Zheng, Y.; Chen, B.; Zheng, E. Dual Attention-Based Industrial Surface Defect Detection with Consistency Loss. Sensors 2022, 22, 5141. https://doi.org/10.3390/s22145141
Li X, Zheng Y, Chen B, Zheng E. Dual Attention-Based Industrial Surface Defect Detection with Consistency Loss. Sensors. 2022; 22(14):5141. https://doi.org/10.3390/s22145141
Chicago/Turabian StyleLi, Xuyang, Yu Zheng, Bei Chen, and Enrang Zheng. 2022. "Dual Attention-Based Industrial Surface Defect Detection with Consistency Loss" Sensors 22, no. 14: 5141. https://doi.org/10.3390/s22145141
APA StyleLi, X., Zheng, Y., Chen, B., & Zheng, E. (2022). Dual Attention-Based Industrial Surface Defect Detection with Consistency Loss. Sensors, 22(14), 5141. https://doi.org/10.3390/s22145141