Resumen
The accurate localization of S1 and S2 is essential for heart sound segmentation and classification. However, current direct heart sound segmentation algorithms have poor noise immunity and low accuracy. Therefore, this paper proposes a new optimal heart sound segmentation algorithm based on K-means clustering and Haar wavelet transform. The algorithm includes three parts. Firstly, this method uses the Viola integral method and Shannon?s energy-based algorithm to extract the function of the envelope of the heart sound energy. Secondly, the time?frequency domain features of the acquired envelope are extracted from different dimensions and the optimal peak is searched adaptively based on a dynamic segmentation threshold. Finally, K-means clustering and Haar wavelet transform are implemented to localize S1 and S2 of heart sounds in the time domain. After validation, the recognition rate of S1 reached 98.02% and that of S2 reached 96.76%. The model outperforms other effective methods that have been implemented. The algorithm has high robustness and noise immunity. Therefore, it can provide a new method for feature extraction and analysis of heart sound signals collected in clinical settings.