Weld Defect Detection in Laser Beam Welding Using Multispectral Emission Sensor Features and Machine Learning
Abstract
Highlights
- Developed a data-driven framework integrating supervised and unsupervised machine learning techniques for interpreting multispectral emission sensor data in laser welding.
- Enhanced the LSTM network with an attention mechanism to identify features related to one defect (pore—supervised learning).
- Anomaly detection in sensor signals based on features using the Isolation Forest algorithm (unsupervised learning)
- Demonstrated correlations between spectral emissions and weld defects.
- Data-driven framework enabling quantitative monitoring using the multispectral emission.
- Machine learning to find the correlation between spectral emissions and weld defects.
- Improve the in situ monitoring in weld applications.
- Explain the multispectral emission data, which make it easier to use in a decision-making system.
Abstract
1. Introduction
2. Experimental Setup
Multispectral Data Acquisition
3. Methodology
3.1. Data Processing
3.1.1. Feature Extraction
3.1.2. PCA for Dimensionality Reduction and Feature Analysis
3.1.3. Analyzing the Influence of Weld Parameters on Sensor Data
3.2. Modeling
3.2.1. Supervised Learning
Data Labeling–Defect Definition (Pore Segmentation)
Deep Learning (LSTM with Attention Mechanism) to Analyze Feature Time Step Importance in Predicting Pore Volume
3.2.2. Unsupervised Learning
4. Results
5. Conclusions
Author Contributions
Funding
Institutional Review Board Statement
Informed Consent Statement
Data Availability Statement
Acknowledgments
Conflicts of Interest
Abbreviations
LBW | Laser Beam Welding |
VIS | Visible Spectrum (approx. 317–900 nm) |
NIR | Near-Infrared Spectrum (approx. 900–1934 nm) |
CT | Computed Tomography, used for pore volume analysis |
PFO | Programmable Focusing Optics |
ϕ | Inclination Angles |
ΔY | PFO Y Translation |
DoE | Design of Experiments |
FFT | Fast Fourier Transform |
PCA | Principal Component Analysis |
LSTM | Long Short-Term Memory, a type of RNN used for time-series data |
MSE | Mean Squared Error |
Set0 | Dataset collected at 5000 Hz with 200 μs integration time (VIS and NIR channels) |
Set1 | Dataset collected at 100,000 Hz with 10 μs integration time (back-reflection channels) |
Wk | Window number k in a channel |
D(Wi) | Signal data in window Wi |
σ | Sigmoid activation function |
⊙ | Element-wise multiplication |
PSD | Power Spectral Density (from FFT) |
FRESH | Feature Extraction based on Scalable Hypothesis tests (Python package) |
CNN | Convolutional Neural Network |
SVM | Support Vector Machine |
RMS | Root Mean Square |
Ti | Time step index |
Eigenvector (w) | Direction of maximum variance |
Eigenvalue (Λ) | Variance explained by a principal component (in PCA) |
Appendix A
Channel | Anomaly Count in (Set0) | Anomaly Count in (Set1) |
---|---|---|
chan11 | - | 136 |
chan12 | - | 129 |
chan13 | - | 59 |
chan14 | - | 58 |
chan15 | - | 59 |
chan18 | 2 | - |
chan19 | 14 | - |
chan20 | 128 | - |
chan21 | 211 | - |
chan22 | 65 | - |
chan23 | 2 | - |
chan26 | 4 | - |
chan27 | 25 | - |
chan28 | 24 | - |
chan29 | 12 | - |
chan30 | 6 | - |
chan31 | 2 | - |
chan46 | - | 13 |
chan6 | - | 4 |
chan8 | - | 47 |
Sample No. | Anomaly Count | Ground Truth | Model Prediction * | ||||
---|---|---|---|---|---|---|---|
(Set0) | (Set1) | Cross-Section or Longitude Cut | Defect Observed | Defect? | Weld Parameters | ||
23 | 24 | 3 | The cross-section shows excessive penetration with a keyhole shape extending below the joint Keyhole length = 1571.6 μm | Yes | Power: 4000 Feed Rate: 200 Defocus: 0 PFO Y: 25 | TP | |
67 | 24 | 2 | The penetration depth varies along the weld line, with areas of insufficient fusion between the weld metal and the base material | Yes | Power: 4000 Feed Rate: 200 Defocus: 0.2 PFO Y: 45 | TP | |
71 | 22 | 11 | The penetration depth varies along the weld line, with areas of insufficient fusion between the weld metal and the base material | Yes | Power: 3500 Feed Rate: 200 Defocus: −0.2 PFO Y: 25 | TP | |
80 | 22 | 10 | Small pores, but accepted weld | No | Power: 3500 Feed Rate: 150 Defocus: −0.2 PFO Y: 45 | FP | |
15 | 20 | 12 | Undercut and lack of penetration | Yes | Power: 4000 Feed Rate: 200 Defocus: −0.2 PFO Y: 45 | TP | |
12 | 20 | 10 | Pores | Yes | Power: 3500 Feed Rate: 150 Defocus: −0.2 PFO Y: 45 | TP | |
79 | 18 | 10 | Lack of penetration | Yes | Power: 3500 Feed Rate: 150 Defocus: −0.2 PFO Y: 45 | TP | |
1 | 0 | 18 | Accepted weld | No | Power: 4000 Feed Rate: 200 Defocus: 0 PFO Y: 65 | TN | |
5 | 0 | 13 | Accepted weld | No | Power: 3000 Feed Rate: 200 Defocus: 0.2 PFO Y: 45 | TN | |
18 | 0 | 3 | Accepted weld | No | Power: 3000 Feed Rate: 200 Defocus: 0 PFO Y: 65 | TN | |
28 | 0 | 3 | The penetration depth varies along the weld line, with areas of insufficient fusion between the weld metal and the base material | Yes | Power: 3500 Feed Rate: 150 Defocus: 0 PFO Y: 65 | FN | |
29 | 0 | 3 | Accepted weld | No | Power: 3500 Feed Rate: 200 Defocus: −0.2 PFO Y: 65 | TN | |
30 | 7 | 3 | Accepted weld | No | Power: 4000 Feed Rate: 150 Defocus: 0 PFO Y: 45 | TN | |
35 | 5 | 2 | The penetration depth varies along the weld line, with areas of insufficient fusion between the weld metal and the base material | Yes | Power: 3500 Feed Rate: 150 Defocus: 0.2 PFO Y: 45 | FN | |
36 | 1 | 3 | Accepted weld | No | Power: 3500 Feed Rate: 200 Defocus: 0.2 PFO Y: 65 | TN | |
45 | 0 | 4 | Accepted weld | No | Power: 3500 Feed Rate: 250 Defocus: 0 PFO Y: 25 | TN | |
73 | 5 | 11 | Accepted weld | No | Power: 3500 Feed Rate: 250 Defocus: 0 PFO Y: 25 | TN | |
81 | 0 | 11 | Accepted weld | No | Power: 3500 Feed Rate: 200 Defocus: 0 PFO Y: 45 | TN | |
57 | 0 | 2 | Lack of penetration | Yes | Power: 3500 Feed Rate: 200 Defocus: 0.2 PFO Y: 65 | FN | |
25 | 6 | 4 | Accepted weld | No | Power: 4000 Feed Rate: 200 Defocus: 0.2 PFO Y: 45 | TN |
References
- SaediArdahaei, S.; Pham, X.-T. Toward Stabilizing the Keyhole in Laser Spot Welding of Aluminum: Numerical Analysis. Materials 2024, 17, 4741. [Google Scholar] [CrossRef]
- Ma, D.; Wang, Y.; Zhang, J.; Li, X. DBN-based online identification of porosity regions during laser welding of aluminum alloys using coherent optical diagnosis. Opt. Laser Technol. 2023, 165, 109597. [Google Scholar] [CrossRef]
- Cai, W.; Jiang, P.; Shu, L.; Geng, S.; Zhou, Q. Real-time monitoring of laser keyhole welding penetration state based on deep belief network. J. Manuf. Process. 2021, 72, 203–214. [Google Scholar] [CrossRef]
- Cao, L.; Li, J.; Zhang, L.; Luo, S.; Li, M.; Huang, X. Cross-attention-based multi-sensing signals fusion for penetration state monitoring during laser welding of aluminum alloy. Knowl.-Based Syst. 2023, 261, 110212. [Google Scholar] [CrossRef]
- Dong, H.; Li, W.; Mu, W.; Cai, Y. Instability monitoring of molten pool in pure copper laser welding based on a multi-scale cascade model and spatial optical signals. J. Mater. Process. Technol. 2024, 118581. [Google Scholar] [CrossRef]
- She, K.; Li, D.; Yang, K.; Li, M.; Wu, B.; Yang, L.; Huang, Y. Online Detection of Laser Welding Penetration Depth Based on Multi-Sensor Features. Materials 2024, 17, 1580. [Google Scholar] [CrossRef]
- Liu, T.; Zheng, P.; Bao, J. Deep learning-based welding image recognition: A comprehensive review. J. Manuf. Syst. 2023, 68, 601–625. [Google Scholar] [CrossRef]
- Lee, J.; Choi, H.; Kim, J. Welding Bead Inspection Using Image and Multi-Sensor Fusion. Appl. Sci. 2023, 13, 11497. [Google Scholar] [CrossRef]
- Eriksson, I.; Powell, J.; Kaplan, A.F.H. Signal overlap in the monitoring of laser welding. Meas. Sci. Technol. 2010, 21, 105705. [Google Scholar] [CrossRef]
- Olsson, R.; Eriksson, I.; Powell, J.; Langtry, A.V.; Kaplan, A.F. Challenges to the interpretation of the electromagnetic feedback from laser welding. Opt. Lasers Eng. 2011, 49, 188–194. [Google Scholar] [CrossRef]
- Brüggenjürgen, J.; Spurk, C.; Hummel, M.; Franz, C.; Häusler, A.; Olowinsky, A.; Moosmann, J. Analyzing multispectral emission and synchrotron data to evaluate the quality of laser welds on copper. J. Laser Appl. 2024, 36, 032032. [Google Scholar] [CrossRef]
- Zhang, Y.; You, D.; Gao, X.; Zhang, N.; Gao, P.P. Welding defects detection based on deep learning with multiple optical sensors during disk laser welding of thick plates. J. Manuf. Syst. 2019, 51, 87–94. [Google Scholar] [CrossRef]
- Harati, E.; Kah, P. Laser welding of aluminum battery tab to variable Al/Cu busbars in Li-ion battery joint. AIMS Mater. Sci. 2022, 9, 884–918. [Google Scholar] [CrossRef]
- Pastor, M.; Zhao, H.; Debroy, T. Pore formation during continuous wave Nd:YAG laser welding of aluminium for automotive applications. Weld. Int. 2001, 15, 275–281. [Google Scholar] [CrossRef]
- Seto, N.; Katayama, S.; Matsunawa, A. Porosity formation mechanism and suppression procedure in laser welding of aluminium alloys. Weld. Int. 2001, 15, 191–202. [Google Scholar] [CrossRef]
- Meena, A.; Lassila, A.A.; Lonn, D.; Salomonsson, K.; Wang, W.; Nielsen, C.V.; Bayat, M. The effect of laser off-axis angle on the formation of porosities, fluid flow and keyhole formation of an aluminum alloy (AA1050) in the laser welding process. Opt. Laser Technol. 2025, 184, 112534. [Google Scholar] [CrossRef]
- Will, T.; Schwarzkopf, K.; Hölbling, C.; Müller, L.; Schmidt, M. Feature extraction based on scalable hypothesis tests from photodiode data in laser welding processes. Procedia CIRP 2022, 111, 527–531. [Google Scholar] [CrossRef]
- Lee, K.; Kang, S.; Kang, M.; Yi, S.; Kim, C. Estimation of Al/Cu laser weld penetration in photodiode signals using deep neural network classification. J. Laser Appl. 2021, 33, 032032. [Google Scholar] [CrossRef]
- Ozkat, E.C. Photodiode Signal Patterns: Unsupervised Learning for Laser Weld Defect Analysis. Processes 2025, 13, 121. [Google Scholar] [CrossRef]
- Shannon, C.E. A mathematical theory of communication. Bell Syst. Tech. J. 1948, 27, 379–423. [Google Scholar] [CrossRef]
- Lei, T.; Gu, S.; Yu, H. Keyhole morphology monitoring of laser welding based on image processing and principal component analysis. Appl. Opt. 2022, 61, 1492–1499. [Google Scholar] [CrossRef]
- You, D.; Gao, X.; Katayama, S. WPD-PCA-based laser welding process monitoring and defects diagnosis by using FNN and SVM. IEEE Trans. Ind. Electron. 2015, 62, 628–636. [Google Scholar] [CrossRef]
- Shin, J.; Kang, S.; Kim, C.; Hong, S.; Kang, M. Identification of solidification cracking using multiple sensors and deep learning in laser overlap welded Al 6000 alloy. J. Laser Appl. 2023, 35, 042019. [Google Scholar] [CrossRef]
- ISO 13919-2; Welding—Electron and Laser-Beam Welded Joints—Guidance on Quality Levels for Imperfections—Part 2: Aluminium and Its Weldable Alloys. International Organization for Standardization: Geneva, Switzerland, 2011. Available online: https://www.iso.org/standard/75515.html (accessed on 10 August 2025).
- Yan, S.; Chen, B.; Tan, C.; Song, X.; Wang, G. A data-driven time-sequence feature-based composite network of time-distributed CNN-LSTM for detecting pore defects in laser penetration welding. J. Intell. Manuf. 2025, 36, 3509–3526. [Google Scholar] [CrossRef]
- Peng, P.; Fan, K.; Fan, X.; Zhou, H.; Guo, Z. Real-time defect detection scheme based on deep learning for laser welding systems. IEEE Sens. J. 2023, 23, 17301–17309. [Google Scholar] [CrossRef]
- Vaswani, A.; Shazeer, N.; Parmar, N.; Uszkoreit, J.; Jones, L.; Gomez, A.N.; Polosukhin, I. Attention is all you need. In Proceedings of the 31st Conference on Neural Information Processing Systems (NIPS 2017), Long Beach, CA, USA, 4–9 December 2017; Volume 30, pp. 6000–6010. [Google Scholar]
- Wen, X.; Li, W. Time series prediction based on the LSTM-Attention-LSTM model. IEEE Access 2023, 11, 48322–48331. [Google Scholar] [CrossRef]
- Zhang, X.; Liang, X.; Zhiyuli, A.; Zhang, S.; Xu, R.; Wu, B. AT-LSTM: An attention-based LSTM model for financial time series prediction. IOP Conf. Ser. Mater. Sci. Eng. 2019, 569, 052037. [Google Scholar] [CrossRef]
- Lu, Y.; Huang, Q. DRST-Net: A Dual-Branch Feature Fusion Network Combining ResNet50 and Swin Transformer for Welding Light Strip Recognition. Appl. Sci. 2025, 15, 2016. [Google Scholar] [CrossRef]
- Xu, J.; Liu, Q.; Xu, Y.; Xiao, R.; Hou, Z.; Chen, S. Review on the Application of the Attention Mechanism in Sensing Information Processing for Dynamic Welding Processes. J. Manuf. Mater. Process. 2024, 8, 22. [Google Scholar] [CrossRef]
- Cao, Y.; Xiang, H.; Zhang, H.; Zhu, Y.; Ting, K.M. Anomaly Detection Based on Isolation Mechanisms: A Survey. arXiv 2024, arXiv:2403.10802. [Google Scholar] [CrossRef]
- Al Farizi, W.S.; Hidayah, I.; Rizal, M.N. Isolation forest based anomaly detection: A systematic literature review. In Proceedings of the 2021 8th International Conference on Information Technology, Computer and Electrical Engineering (ICITACEE), Semarang, Indonesia, 23–24 September 2021; pp. 118–122. [Google Scholar] [CrossRef]
- Liu, F.T.; Ting, K.M.; Zhou, Z.H. Isolation forest. In Proceedings of the 2008 Eighth IEEE International Conference on Data Mining, Pisa, Italy, 15–19 December 2008; pp. 413–422. [Google Scholar] [CrossRef]
- Liu, F.T.; Ting, K.M.; Zhou, Z.H. Isolation-based anomaly detection. ACM Trans. Knowl. Discov. Data (TKDD) 2012, 6, 1–39. [Google Scholar] [CrossRef]
Parameter | |
---|---|
Power [W] | [3000, 3500, 4000] |
Feed Rate [mm/s] | [150, 200, 250] |
Focus Depth [mm] | [−0.2, 0, 0.2] |
PFO Translation Y [mm] | [25, 45, 65] |
Inclination Angle [deg] | [2.74, 4.92, 7.09] |
Feature | Equation | PCA1 | PCA2 | PCA3 | PCA4 |
---|---|---|---|---|---|
RMS | 5 | 0.263 | 0.079 | 0.035 | −0.068 |
max | 3 | 0.261 | 0.020 | 0.043 | −0.122 |
peak | 9 | 0.261 | 0.020 | 0.043 | −0.122 |
std | 7 | 0.261 | 0.013 | −0.076 | −0.058 |
p2p | 10 | 0.259 | 0.000 | −0.002 | −0.112 |
mean | 4 | 0.257 | 0.103 | 0.069 | −0.068 |
sum_f | 16 | 0.250 | 0.143 | −0.082 | 0.119 |
mean_f | 18 | 0.250 | 0.143 | −0.082 | 0.119 |
power | 8 | 0.250 | 0.143 | −0.082 | 0.119 |
max_f | 17 | 0.244 | 0.162 | −0.049 | 0.126 |
peak_f | 20 | 0.244 | 0.162 | −0.049 | 0.126 |
var | 6 | 0.233 | 0.057 | −0.186 | 0.078 |
min | 2 | 0.198 | 0.111 | 0.251 | −0.139 |
var_f | 19 | 0.192 | 0.173 | −0.150 | 0.306 |
crestfactor | 11 | 0.176 | −0.272 | 0.169 | −0.150 |
pulseindicator | 13 | 0.152 | −0.334 | 0.009 | −0.049 |
autocorr | 24 | 0.144 | −0.141 | 0.330 | −0.048 |
entropy | 25 | −0.133 | 0.345 | 0.228 | 0.034 |
formfactor | 12 | 0.132 | −0.352 | −0.191 | 0.007 |
skew | 14 | 0.106 | −0.208 | 0.430 | 0.123 |
skew_f | 21 | −0.085 | 0.361 | 0.282 | −0.019 |
kurtosis_f | 22 | −0.085 | 0.359 | 0.285 | −0.007 |
kurtosis | 15 | 0.037 | −0.167 | 0.416 | 0.415 |
fundamental_f | 23 | 0.013 | −0.189 | 0.110 | 0.620 |
Fold | MSE | MAE | ||
---|---|---|---|---|
Training | Testing | Training | Testing | |
1 | 0.0024 | 0.0045 | 0.0226 | 0.0375 |
2 | 0.0014 | 0.0083 | 0.0226 | 0.0461 |
3 | 0.0034 | 0.0003 | 0.0268 | 0.0151 |
4 | 0.0033 | 0.0005 | 0.0295 | 0.0178 |
5 | 0.0032 | 0.0010 | 0.0299 | 0.0273 |
Average | 0.0028 | 0.0029 | 0.0263 | 0.0288 |
Sample No.: 79 | Sample No.: 67 | |
---|---|---|
Longitudinal cut, Sample No. 79 | Longitudinal cut, Sample No. 67 | |
Power: 3500; Feed Rate: 150; Defocus: −0.2; PFO Y: 45 | Power: 4000; Feed Rate: 200; Defocus: 0.2; PFO Y: 45 | |
Chan18 VIS channel 393–410 nm | ||
Chan23 | ||
Chan24 | ||
Chan63 | ||
Samples 79 and 67 show unstable signals. For example, in Sample 67, Channel 24 displays sharp high-energy peaks at segment 40, with an amplitude that exceeds the values for the same channel in the normal signals. This correlates with the visible defect in the cross-section showing lack of fusion and inconsistent penetration depth. Similarly, Sample 79 shows multiple high-amplitude peaks in Channel 24, indicating instability and sudden changes in emission intensity, which aligns with the observed keyhole-shaped excessive penetration in the weld cut. |
Sample No.: 33 | Sample No.: 51 | |
---|---|---|
Longitudinal cut, Sample No. 33 Power: 3000; Feed Rate: 200; Defocus: −0.2; PFO Y: 45 | Longitudinal cut, Sample No. 51 Power: 4000; Feed Rate: 200; Defocus: 0.2; PFO Y: 45 | |
Chan18 | ||
Chan23 | ||
Chan24 | ||
Chan63 | ||
In contrast, Samples 33 and 51 demonstrate stable and smoother signal patterns, with no extreme spikes across the same channels. For example, Channel 24 in Sample 51 maintains a low-amplitude profile throughout the sequence. This consistent behavior aligns with the clean, well-formed weld cross-sections, supporting the interpretation that stable signal patterns are indicative of good welding quality. A similar observation applies to Channel 63, which shows stable signals with only minor fluctuations in these samples—especially when compared to Channel 63 in the defective samples listed in Table 4. As previously discussed, it is not only about individual spikes but about the overall behavior of the signal, which is why the extracted features are essential—they provide deeper insights into signal distribution and variability over time. |
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content. |
© 2025 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
Darwish, A.; Persson, M.; Ericson, S.; Ghasemi, R.; Salomonsson, K. Weld Defect Detection in Laser Beam Welding Using Multispectral Emission Sensor Features and Machine Learning. Sensors 2025, 25, 5120. https://doi.org/10.3390/s25165120
Darwish A, Persson M, Ericson S, Ghasemi R, Salomonsson K. Weld Defect Detection in Laser Beam Welding Using Multispectral Emission Sensor Features and Machine Learning. Sensors. 2025; 25(16):5120. https://doi.org/10.3390/s25165120
Chicago/Turabian StyleDarwish, Amena, Manfred Persson, Stefan Ericson, Rohollah Ghasemi, and Kent Salomonsson. 2025. "Weld Defect Detection in Laser Beam Welding Using Multispectral Emission Sensor Features and Machine Learning" Sensors 25, no. 16: 5120. https://doi.org/10.3390/s25165120
APA StyleDarwish, A., Persson, M., Ericson, S., Ghasemi, R., & Salomonsson, K. (2025). Weld Defect Detection in Laser Beam Welding Using Multispectral Emission Sensor Features and Machine Learning. Sensors, 25(16), 5120. https://doi.org/10.3390/s25165120