Heart sound feature extraction, decomposition, reconstruction and quantification method

Through wavelet denoising and Fourier transform technologies, the heart sound signal is analyzed, which solves the problem of quantitative analysis of heart sound signal, realizes the visualization and quantification of heart sound signal, and improves the accuracy of heart disease diagnosis.

CN119181387APending Publication Date: 2024-12-24NANJING CHILDRENS HOSPITAL
View PDF 0 Cites 3 Cited by

Patent Information

Application Number
CN202411296833.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-09-18
Publication Date
2024-12-24

AI Technical Summary

Technical Problem

The lack of effective methods for quantitative analysis of heart sound signals in the prior art has led to challenges in evaluating heart disease, affecting the screening, diagnosis and treatment of congenital heart disease.

Method used

The wavelet denoising algorithm is used to preprocess the heart sound signal. The characteristic information is extracted through wavelet decomposition and reconstruction, the power spectral density and energy entropy value of the signal are calculated, the correlation between energy entropy and defect size is analyzed, and the Fourier transform and Mel are combined. Frequency filter realizes the digital visualization and quantization of heart sound signals.

Benefits of technology

It realizes the visualization and quantification of heart sound signals, improves the accuracy and reliability of diagnosis, can effectively distinguish different types of congenital heart disease, and provides reliable diagnostic basis.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119181387A_ABST
    Figure CN119181387A_ABST
Patent Text Reader

Abstract

The invention discloses a heart sound feature extraction, decomposition, reconstruction and quantification method which is characterized by comprising the following steps: S1, collecting heart sound signals; s2, carrying out noise reduction pretreatment; s3, carrying out wavelet decomposition and reconstruction on the heart sound signals; s4, calculating signal power spectral density and normalizing an energy spectrum; s5, calculating a signal energy entropy value; and S6, analyzing the correlation between the energy entropy and the defect size. According to the method, visualization of the heart sound digitized signals is achieved through multiple steps, the heart sound digitized signal decomposition and reconstruction method is provided, the waveform distribution condition of the recombined heart sound is visualized, the accuracy is high, and the reliability is high.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of signal processing, and in particular to a method for extracting, decomposing, reconstructing and quantifying heart sound features. Background Art

[0002] Heart sounds are complex sounds produced by a series of activities, including the opening and closing of heart valves, the relaxation and contraction of heart tendons and muscles, the impact of blood flow, and the vibration of cardiovascular walls. Clinically, auscultation of heart sounds is used as a basic decision-making method to judge heart distortion and evaluate the grade of heart function based on relevant information such as the intensity of heart sounds and murmurs.

[0003] Wavelet Transform (WT) denoising is a signal conversion from time domain to frequency domain. It is a multi-scale analysis method of signals. By converting the signal from time domain to frequency domain, it also provides multi-scale analysis capabilities of the signal, so it is also called a multi-resolution analysis method. WT technology has better local properties and can better capture the local characteristics and time-frequency characteristics of the signal, which makes WT have obvious advantages in processing non-stationary signals, signals with mutations and discontinuities, and signals that require high time-frequency resolution. Therefore, WT technology has been widely used in signal processing, image processing, data compression, pattern recognition and other fields.

[0004] In recent years, with the development of modern information technology and the widespread application of non-invasive tests such as cardiac Doppler color ultrasound and electrocardiogram, combined with AI technologies such as machine learning (ML), artificial neural network (ANN), and DL, the digital collection, storage, and analysis of heart sound signals have made it possible to develop intelligent auscultation technology for congenital heart disease. AI technology, which uses intelligent systems to simulate the brain's thinking mode to obtain memory and decision-making capabilities, has become a hot topic in the medical field of modern science and technology. However, there is currently a lack of effective methods for quantitative analysis of heart sounds, which makes it challenging for grassroots clinicians to assess heart disease in the absence of cardiac color ultrasound. Therefore, the development of a reliable method for quantifying heart sound is crucial to improving the screening, diagnosis, and treatment of congenital heart disease. Summary of the invention

[0005] Based on this, the purpose of the present invention is to provide a method for extracting, decomposing, reconstructing and quantifying heart sound features. The specific scheme is as follows:

[0006] A method for extracting, decomposing, reconstructing and quantifying heart sound features comprises the following steps:

[0007] S1. Collecting heart sound signals: placing the sensor on the patient's chest to be collected and recording the heart sound signals;

[0008] S2, noise reduction preprocessing: use wavelet denoising algorithm to remove high-frequency noise;

[0009] S3. Wavelet decomposition and reconstruction of heart sound signals: Use wavelet functions to perform multi-scale wavelet decomposition on the preprocessed signals to obtain several detail coefficients and approximation coefficients; reconstruct the signals of the required frequency bands to enhance feature information;

[0010] S4. Calculate the signal power spectrum density and normalize the energy spectrum: Use Fourier transform to calculate the power spectrum density PSD of the heart sound signal, square the amplitude of the wavelet coefficients of each scale and frequency to obtain the energy spectrum EM, normalize EM to obtain the normalized energy spectrum;

[0011] S5. Calculate the energy entropy value of the signal: Calculate the energy entropy value of the signal. The calculation formula of the energy entropy value is:

[0012]

[0013] Among them, P i represents the i-th component of the normalized energy spectrum, and N is the total number of frequency components.

[0014] S6. Analyze the correlation between energy entropy and defect size: collect heart sound signals and corresponding clinical defect size data from several patients with congenital heart disease (CHD), analyze the correlation between energy entropy value and clinical defect size, and verify the accuracy and reliability of the algorithm.

[0015] Preferably, the parts to be collected in step S1 include: the second intercostal space, the right sternal border; the second intercostal space, the left sternal border; the third intercostal space, the left sternal border; the left lower sternal border; and the fifth intercostal space.

[0016] Preferably, the wavelet function in step S3 is any one of Morlet wavelet, Haar wavelet, Daubechies wavelet and symleta wavelet.

[0017] Beneficial effects:

[0018] 1. The present invention realizes the visualization of digitized heart sound signals through multiple steps.

[0019] 2. The present invention proposes a method for decomposing and reconstructing digital heart sound signals, so as to visualize the waveform distribution of the reconstructed heart sounds.

[0020] 3. The present invention explores a quantization method for digitized heart sound signals with high accuracy and strong reliability. BRIEF DESCRIPTION OF THE DRAWINGS

[0021] Figure 1This is a flow chart of the CHD cardiac volume quantification method based on WESE;

[0022] Figure 2 It is a schematic diagram of the auscultation area in the anterior chest area;

[0023] Figure 3 This is the linear energy spectrum, Mel energy spectrum and logarithmic Mel energy spectrum of the heart sound of a normal child;

[0024] Figure 4 is the energy spectrum of heart sounds of some CHD patients; a is the energy spectrum of heart sounds of ASD patients; b is the energy spectrum of heart sounds of VSD patients; c is the energy spectrum of heart sounds of PDA patients; d is the energy spectrum of heart sounds of TOF patients; e is the energy spectrum of heart sounds of patients with hypertrophic obstructive cardiomyopathy;

[0025] Figure 5 is a heart sound decomposition waveform diagram; wherein a is a heart sound decomposition waveform diagram of a normal person; b is a heart sound decomposition waveform diagram of a PDA patient; c is a heart sound decomposition waveform diagram of a VSD patient;

[0026] Figure 6 : is the waveform diagram of the decomposition and reconstruction of the heart sounds of VSD patients; a is the waveform diagram after the decomposition of the heart sounds; b is the waveform diagram after the reconstruction of the heart sounds. DETAILED DESCRIPTION

[0027] The present invention will be further explained below in conjunction with the accompanying drawings and embodiments.

[0028] The present invention can be better understood according to the following examples. However, it is easy for those skilled in the art to understand that the specific material ratios, process conditions and results described in the examples are only used to illustrate the present invention.

[0029] Example 1: Feature extraction of digitized heart sound signals based on MFCC

[0030] Mel-Frequency Cepstral Coefficients (MFCC) are a feature representation method commonly used in speech and audio signal processing. MFCC is a cepstral coefficient extracted on the Mel frequency scale. By simulating the way the human auditory system perceives sound, it converts the audio signal into a set of feature vectors with strong discriminant ability, so as to better represent and analyze the characteristics of the audio signal. It is usually used for tasks such as speech recognition, voiceprint feature recognition and audio classification. MFCC can effectively extract the key features of the audio digitized signal (such as the resonance peak of the speech, the length of the vocal tract, etc.), while reducing the dimension of the feature, making it more efficient and accurate in subsequent model training and classification tasks.

[0031] To obtain the spectrum characteristics of the digitized heart sound signal after noise reduction preprocessing, the following three steps are required:

[0032] 1.1 Obtain the linear energy spectrum:

[0033] Perform Fourier Transform (FT): Convert the signal from the time domain to the frequency domain, which is then used to analyze the spectral characteristics of the signal. Perform FT on each frame of the heart sound data that has been pre-processed for noise reduction to obtain the linear spectrum X(k). The specific conversion formula (Formula 1) is as follows:

[0034]

[0035] Where k = 0, 1, 2, ..., N-1 represents the discrete frequency index in the frequency domain; j is an imaginary unit, full

[0036] Foot 2 = -1; X(k) represents the discrete Fourier transform (DFT) coefficient at frequency k in the frequency domain; x

[0037] (n) represents the input signal of sequence n in the time domain; N represents the total number of sampling points in the signal; n represents the time

[0038] The sampling point index in the time domain ranges from 0 to N-1; k represents the frequency index, ranging from 0 to N-1; e

[0039] Represents the base of the natural logarithm; -2πnk / N represents the phase shift of each frequency component.

[0040] 1.2 Obtain Mel energy spectrum:

[0041] The obtained spectrum X(k) is passed through a set of Mel frequency filter banks to output the Mel spectrum energy: Mel filter banks are usually used to convert linear spectrum into Mel spectrum to better conform to the perceptual characteristics of the human auditory system. Mel filter banks are a set of filters evenly distributed on the Mel frequency axis, which are used to filter the linear spectrum to obtain Mel spectrum energy.

[0042] 1.3 Obtain the logarithmic Mel energy spectrum:

[0043] Take the logarithm of the frequency energy obtained in step 1.2 to obtain the logarithmic Mel energy spectrum S m ; S m It reflects the energy distribution of the heart sound audio signal on the Mel frequency axis and can be used to represent the spectral characteristics of the audio signal. The Mel frequency axis converts the frequencies on the frequency axis according to the human auditory perception to simulate the human auditory system's perception of sound, which is more in line with the human perception characteristics of audio signals. By extracting the logarithmic Mel energy spectrum, we can more effectively capture the spectral characteristics of the audio digitization signal and visualize the heart sound digitization data.

[0044] The present invention explores a congenital heart disease (CHD) quantification method based on wavelet spectrum entropy to quantify the size of CHD defects. The system flow is as follows: Figure 1 As shown, the method includes:

[0045] Step 101: Collect heart sound signals

[0046] The sensor is placed at a specific position on the patient's chest, and the heart sound signal is recorded and saved as a digital format file (such as WAV format).

[0047] The heart sound signal collection site is:

[0048] Figure 2 ① Area I of the aortic valve shown in the region: second intercostal space, right sternal border;

[0049] Figure 2 ②The pulmonary valve area shown in the region: the second intercostal space, the left sternal border;

[0050] Figure 2 ③Aortic valve zone II shown in the area: third intercostal space, left sternal border;

[0051] Figure 2 ④Tricuspid valve area shown in the region: left lower sternal border;

[0052] Figure 2 ⑤ Mitral valve area shown in area: fifth intercostal space.

[0053] Step 102: Noise Reduction Preprocessing

[0054] Use wavelet denoising algorithm (soft threshold or hard threshold method) to remove high frequency noise.

[0055] Step 103: Wavelet decomposition and reconstruction of heart sound signals

[0056] Wavelet decomposition: Perform multi-scale wavelet decomposition on the preprocessed signal to obtain several detail coefficients and approximation coefficients.

[0057] Wavelet reconstruction: According to the analysis needs, select and reconstruct the signals of certain frequency bands to enhance the characteristic information.

[0058] The present invention performs preprocessing analysis of heart sound signals based on Matlab R2021a software. In the Wavelet Analyzer toolbox in MATLAB R2021a software, a series of wavelet function packages are provided for signal processing: Morlet wavelet, Haar wavelet, Daubechies wavelet, symleta wavelet, etc. In order to better obtain the results of noise reduction and , the present invention adopts the Daubechies (dbN) wavelet system, where N represents its order. These wavelet functions have standard orthogonal wavelets with compact support and finite length. Its appearance makes discrete wavelet analysis possible and is widely used in image processing, speech processing, biomedical signal analysis and other fields.

[0059] The denoising principle of the dbN wavelet function package is based on the sparsity of the wavelet coefficients of the signal. Noise usually appears as high-frequency components or wavelet coefficients with weaker energy. After WT transformation, the wavelet coefficients of the noise signal will be easier to distinguish and suppress, thereby achieving the denoising effect of the signal.

[0060] Step 104: Calculate the signal power spectrum density and normalize the energy spectrum

[0061] The power spectral density (PSD) of the heart sound signal is calculated using FT. The amplitude of the wavelet coefficients of each scale and frequency is squared to obtain the energy spectrum (EM). The EM is normalized to make the total energy equal to 1 to obtain the normalized energy spectrum.

[0062] Step 105: Calculate the signal energy entropy value;

[0063] Write an algorithm to calculate the energy entropy value of the signal. The calculation formula of the energy entropy value is:

[0064]

[0065] Among them, P i represents the i-th component of the normalized energy spectrum, and N is the total number of frequency components.

[0066] Step 106: Analyze the correlation between energy entropy and defect size

[0067] Heart sound signals and corresponding clinical defect size data of multiple CHD patients were collected, and statistical methods (such as Pearson correlation coefficient or Spearman correlation coefficient) were used to analyze the correlation between energy entropy value and defect size. Based on the correlation analysis results, the relationship between energy entropy value and CHD defect size was established to verify the accuracy and reliability of the algorithm.

[0068] Example 2: Digitization of normal children's heart sound data

[0069] 2.1 Visualization of the audio energy of heart sounds

[0070] The present invention visualizes the CHD heart sound audio data to express the features contained in the digitized signal, which more intuitively explains the significant differences between the heart sounds of patients with different types of CHD and provides a more accurate reference for clinical diagnosis. The digitized heart sound signal undergoes the above three steps to obtain the linear energy spectrum, Mel energy spectrum and logarithmic Mel energy spectrum. The algorithm is designed based on MATLAB R2021A software to obtain the corresponding spectrum. Figure 3 As shown, Figure 3 It shows that the cardiac sound signal can be visualized through the method proposed by the research.

[0071] Figure 3 a is the linear energy spectrum, which shows the linear energy spectrum of the heart sound signal, that is, the energy distribution of the signal at different frequencies. The horizontal axis represents frequency (Frequency in Hz) and the vertical axis represents amplitude (Amplitude). It can be seen from the figure that the main frequency components of the heart sound signal are concentrated in the lower frequency band (0 to 200 Hz), and the energy exceeding this frequency range decays rapidly. Figure 3 b is the Mel energy spectrum, which shows the energy distribution of the heart sound signal after being processed by the Mel filter bank. The horizontal axis represents the number of frames (Frame), and the vertical axis represents the amplitude (Amplitude); the Mel energy spectrum shows the energy distribution on the Mel frequency scale, which is consistent with the human ear's perception of frequency. Most of the energy is still concentrated in the low frequency band, and the energy gradually decreases as the frequency increases. Figure 3 c is the logarithmic Mel energy spectrum: This figure shows the logarithmic form of the Mel energy spectrum. By taking the logarithm of the Mel energy spectrum, smaller energy changes are made more obvious. The horizontal axis represents the number of frames (Frame) and the vertical axis represents the logarithmic amplitude (Log Amplitude); the logarithmic Mel energy spectrum can highlight smaller energy changes in the signal, provide more detailed information, and facilitate more detailed signal analysis.

[0072] 2.2 Result analysis:

[0073] (1) Frequency component analysis: From the linear energy spectrum (Figure a), it can be seen that the main frequency components of the heart sound signal are concentrated between 0 and 200 Hz, indicating that the heart sound signal is mainly composed of low-frequency components. This is consistent with the physiological characteristics of heart sounds, because heart sounds are mainly composed of low-frequency vibrations generated by the closure of heart valves and blood flow.

[0074] (2) Energy distribution analysis: The Mel energy spectrum (Figure b) further reveals the energy distribution of the signal on the Mel frequency scale. Since the Mel frequency scale is more consistent with the auditory characteristics of the human ear, it can better reflect the perceptual characteristics of the signal. The figure shows that the energy is concentrated in the low frequency band, while the energy in the high frequency band gradually decreases.

[0075] (3) Detailed information analysis: Logarithmic Mel energy spectrum (Figure c) By taking the logarithm of the Mel energy spectrum, smaller energy changes are more obvious, providing more detailed information. This helps to extract more detailed features in signal processing, such as subtle abnormalities in heart sounds, which may provide important basis for the diagnosis and analysis of heart disease.

[0076] In summary, through Figure 3 The comprehensive analysis can provide a more comprehensive understanding of the spectral characteristics of heart sound signals and provide strong support for feature extraction and classification of heart sound signals. These analysis results can be used in the automatic diagnosis system of heart disease to help doctors make more accurate and effective diagnoses.

[0077] Example 3: Energy spectrum analysis of heart sounds in some CHD cases:

[0078] 3.1 Analysis of heart sound energy spectrum

[0079] Based on MATLAB R2021A software, the present invention analyzes the energy spectrum of heart sounds of common CHD, and the results are as follows: Figure 4 As shown in the figure, the heart sound energy spectra of patients with atrial septal defect (ASD), ventricular septal defect (VSD), patent ductus arteriosus (PDA), tetralogy of Fallot (TOF) and hypertrophic obstructive cardiomyopathy were recorded respectively. The results showed that there were great differences in the heart sound energy of different CHDs.

[0080] Figure 4 a is the heart sound energy spectrum of ASD patients. The main frequency components are concentrated between 0-200Hz, with high amplitude and multi-peak distribution. The Mel energy spectrum shows that the energy in the low-frequency band is higher, and the energy gradually decreases with the increase of frequency. The logarithmic Mel energy spectrum shows that the energy in the low-frequency band changes significantly, the energy in the high-frequency band is smaller, and the details are more obvious. Figure 4b is the heart sound energy spectrum of VSD patients. The frequency components are mainly concentrated in the range of 0-200Hz. The amplitude is significantly higher than that of ASD, and the energy is concentrated in a narrower frequency range. The Mel energy spectrum shows that the energy concentration in the low-frequency band is high, and the energy in the high-frequency band decays rapidly. The logarithmic Mel energy spectrum shows that the energy changes greatly in the low-frequency band, and the energy changes less in the high-frequency band, but the details are more obvious. Figure 4 c is the energy spectrum of heart sounds of PDA patients. The frequency components are distributed relatively widely, from 0-400Hz, the amplitude is relatively low, and the energy distribution is relatively uniform. The Mel energy spectrum shows that the energy in the low-frequency band is relatively high, and the energy distribution in the high-frequency band is relatively uniform. The logarithmic Mel energy spectrum shows that the energy changes significantly in the low-frequency band, the energy changes slightly in the high-frequency band, and the overall energy distribution is relatively uniform. Figure 4 d is the energy spectrum of the heart sound of a TOF patient. The frequency components are concentrated in the range of 0-200Hz, with a high amplitude and relatively concentrated energy distribution. The Mel energy spectrum shows that the energy in the low-frequency band is high, the energy in the high-frequency band decays rapidly, and the energy is concentrated in the low-frequency part. The logarithmic Mel energy spectrum shows that the energy in the low-frequency band changes significantly, the energy in the high-frequency band changes less, and the details are obvious. Figure 4 e is the energy spectrum of heart sounds in patients with hypertrophic obstructive cardiomyopathy. Linear energy spectrum: the frequency components are mainly concentrated in 0-200Hz, with a high amplitude, but lower than TOF and VSD. Mel energy spectrum shows: the energy in the low frequency band is high, the energy in the high frequency band decays rapidly, and the energy concentration is high. Logarithmic Mel energy spectrum shows: the energy in the low frequency band changes greatly, and the energy in the high frequency band changes less, but the details are more obvious.

[0081] 3.2 Result analysis:

[0082] (1) Frequency component differences: There are significant differences in the frequency components of heart sound signals of different CHD types. For example, the energy concentration of heart sound signals of VSD and TOF is higher, and the frequency components are more concentrated, while the frequency components of PDA are more extensive and the energy distribution is more uniform.

[0083] (2) Differences in energy distribution: The low-frequency energy of ASD and VSD is higher, and the energy distribution of PDA is relatively uniform. However, the low-frequency energy of TOF and HOCM varies significantly, and the high-frequency energy decays rapidly.

[0084] (3) Logarithmic Mel energy spectrum details: Through the logarithmic Mel energy spectrum, the detailed changes of heart sound signals of different CHD types can be observed more clearly, especially the energy changes in the low-frequency band, which provides important information for the diagnosis and analysis of CHD.

[0085] In summary, the heart sound signals of different CHD types have significant differences in frequency components and energy distribution, and these differences can serve as an important basis for diagnosing and analyzing different CHD types. Through spectral analysis of heart sound signals, different CHD types can be more accurately identified and classified, which helps to improve the accuracy and reliability of diagnosis.

[0086] 3.3 The codes used in this section are as follows:

[0087] %The research code in this section is implemented based on MATLAB R2021a, and the following is the code comment content.

[0088] %The linear energy spectrum, Mel energy spectrum and logarithmic Mel energy spectrum of the heart sound obtained through this step are as follows:

[0089] %1. Import audio data

[0090] [y,Fs] = audioread('C:\Users\Dr.WY\Desktop\11-14-01-P.wav'); %Replace with your audio file path

[0091] % 2. Calculate the linear energy spectrum of the audio signal

[0092] NFFT = 2^nextpow2(length(y)); % Use the power of 2 closest to the length of the audio signal as the number of FFT points

[0093] linear_spectrum = abs(fft(y,NFFT)); % Calculate the linear spectrum

[0094] frequencies=Fs / 2*linspace(0,1,NFFT / 2+1); %Calculate frequency axis

[0095] %3. Calculate the Mel filter bank

[0096] numFilters=20;%Number of Mel filters

[0097] minFreq=0;%Minimum frequency

[0098] maxFreq=Fs / 2;% Maximum frequency

[0099] minMel=1127*log(1+minFreq / 700); %Minimum Mel frequency

[0100] maxMel=1127*log(1+maxFreq / 700); % Maximum Mel frequency

[0101] melPoints = linspace (minMel, maxMel, numFilters + 2); % points evenly distributed on the Mel frequency axis

[0102] linearPoints = 700 * (exp (melPoints / 1127) - 1); % Convert Mel frequency to linear frequency

[0103] fftPoints = ceil((NFFT+1).*linearPoints / Fs); %Convert linear frequency to FFT point index

[0104] melFilterBank = zeros(numFilters, NFFT / 2+1); % Create a Mel filter bank

[0105] for i=1:numFilters

[0106] leftIndex=max(1,round(fftPoints(i)));

[0107] rightIndex=min(round(fftPoints(i+1)),NFFT / 2+1);

[0108] melFilterBank(i,leftIndex:rightIndex)=(rightIndex-(leftIndex:rightIndex)) / (rightIndex-leftIndex);

[0109] leftIndex=max(1,round(fftPoints(i+1)));

[0110] rightIndex=min(round(fftPoints(i+2)),NFFT / 2+1);

[0111] melFilterBank(i,leftIndex:rightIndex)=((leftIndex:rightIndex)-rightIndex) / (rightIndex-leftIndex);

[0112] end

[0113] %4. Calculate Mel energy spectrum

[0114] mel_spectrum = abs(melFilterBank.*linear_spectrum(1:NFFT / 2+1)'); % Calculate the Mel energy spectrum and take the absolute value

[0115] mel_spectrum=mel_spectrum';

[0116] %5. Calculate the logarithmic Mel energy spectrum

[0117] log_spectrum = log10(1+mel_spectrum); % Calculate the logarithmic Mel energy spectrum

[0118] %6. Draw the results

[0119] figure;

[0120] subplot(3,1,1);

[0121] plot(frequencies,linear_spectrum(1:NFFT / 2+1));

[0122] title('Linear Spectrum');

[0123] xlabel('Frequency(Hz)');

[0124] ylabel('Amplitude');

[0125] subplot(3,1,2);

[0126] plot(mel_spectrum);

[0127] title('Mel Spectrum');

[0128] xlabel('Frame');

[0129] ylabel('Amplitude');

[0130] subplot(3,1,3);

[0131] plot(log_spectrum);

[0132] title('Log Mel Spectrum');

[0133] xlabel('Frame');

[0134] ylabel('Log Amplitude');

[0135] Embodiment 4: Quantification method based on WESE heart sound digital signal

[0136] 4.1 Heart sound signal decomposition and resampling:

[0137] Wavelet Energy Spectrum Entropy (WESE) is a feature representation method for signal analysis. It is used to describe the signal spectrum information and energy distribution based on the energy spectrum characteristics of WT. It is often used in fields such as audio and biological signals. WESE is an indicator that quantifies the energy distribution of signals at different scales. The wavelet energy spectrum entropy at each scale is calculated independently. When the energy distribution of the signal at a certain scale is relatively uniform or smooth, the corresponding wavelet energy spectrum entropy will be lower; and when the energy distribution of the signal at a certain scale is relatively dispersed or irregular, the corresponding WESE value will be higher. Therefore, WESE can be used to describe the spectral complexity and information richness of the signal, and has characteristic significance for distinguishing different digitized audio signals.

[0138] The sampling frequency of the heart sound signal adopted in the present invention is 4000.00 Hz. The heart sound signal is decomposed and resampled before and after preprocessing (the resampling frequency is usually lower than the original sampling rate for ease of calculation), and it is made to reach 2000.00 Hz. Then, the resampled heart sound signal is subjected to wavelet decomposition using the mother function of wavelet decomposition, and then different frequency segments d1-d6 are reconstructed (the reconstructed signal frequency range is approximately 31.25 to 2000.00 Hz).

[0139] 4.2 Division of heart rate bands:

[0140] The frequency bands corresponding to the wavelet coefficients of each layer in step 2.1 of Example 2 of the present invention are roughly as follows: d1: 1000.00~2000.00Hz; d2: 500.00~1000.00Hz; d3: 250.00~500.00Hz; d4: 125.00~250.00Hz; d5: 62.50~125.00Hz; d6: 31.25~62.5Hz. In general, the frequency range of the basic heart sound components S1 and S2 is about 50.00-200.00 Hz, while the frequency range of the decomposed d6+d5+d4 detail layer is 31.25-250.00 Hz, which contains most of the energy of S1 and S2 under normal conditions. The frequency of the noise component is relatively high and is mainly distributed in the high-frequency wavelet coefficient layer. Therefore, the present invention selects d1-d6 for statistics, and re-marks and divides the frequency bands according to the frequency range to construct four frequency bands: Low Frequency Band (LFB), Medium Frequency Band (MFB), High Frequency Band (HFB), and Extremely High Frequency Band (EHFB). The specific distribution is shown in Table 1.

[0141] Table 1 Division of heart rate bands

[0142] Frequency band Frequency band Detail layer Frequency range Band 1: LFB d6 31.25~62.50Hz Band 2: MFB d4+d5 62.50~250.00Hz Band 3: HFB d3 250.00~500.00Hz Band 4: EHF d1+d2 500.00~2000.00Hz

[0143] 4.3 Heart sound waveform decomposition and processing:

[0144] Based on the processing method of the digital heart sound signal proposed in Example 1, the present invention decomposes and resamples the 4000.00 Hz digital heart sound signal, and makes the resampling frequency 2000.00 Hz, uses the mother function of wavelet decomposition to perform wavelet decomposition on the resampled heart sound signal, and then reconstructs d1-d6. The specific situation is as follows Figure 5 shown. Figure 5 a is a normal heart sound signal diagram. Its decomposition results show that the normal heart sound signal is evenly distributed in each component (d1-d6), the signal amplitude is small, and the change is stable. The reconstruction results show that the reconstructed signal has a low amplitude in each component, the signal shape is smooth, and no obvious abnormal waveform is observed. Figure 5 b is the heart sound decomposition waveform of a PDA patient. The decomposition results show that the PDA heart sound signal has higher energy in the low-frequency component (d1-d3) and the signal amplitude varies greatly, while the energy of the high-frequency component (d4-d6) is relatively low. The reconstruction results show that the reconstructed signal exhibits obvious fluctuations in the low-frequency component and has a large signal amplitude, which reflects the characteristics of the PDA heart sound signal. Figure 5c is the heart sound decomposition waveform of a VSD patient. The decomposition results show that the energy of the VSD heart sound signal is concentrated on the low-frequency component (d1-d3), the signal amplitude varies greatly, the energy of the high-frequency component (d4-d6) is low, and the amplitude is relatively stable. The reconstruction results show that the reconstructed signal shows large fluctuations in the low-frequency component and the signal morphology is irregular, which is clearly distinguished from the normal heart sound signal.

[0145] 4.4 Result analysis:

[0146] 4.4.1 Signal distribution differences: By decomposing different types of heart sound signals, it can be observed that there are significant differences in the distribution of normal heart sound signals and pathological heart sound signals in each component. The energy distribution of normal heart sound signals in each component is relatively uniform, while the energy of PDA and VSD heart sound signals is more concentrated in the low-frequency components and the energy of high-frequency components is lower.

[0147] 4.4.2 Reconstructed signal characteristics: The shape and amplitude changes of the reconstructed signal further reflect the characteristics of the heart sound signal. The reconstruction results of normal heart sound signals are stable and have a small amplitude, while the reconstruction results of PDA and VSD heart sound signals show obvious fluctuations and irregular shapes, reflecting the characteristics of pathological heart sound signals.

[0148] 4.4.3 Diagnostic basis: Through wavelet decomposition and reconstruction, the characteristics of different types of heart sound signals can be effectively extracted, which is of great significance for the diagnosis of congenital heart disease. The signal characteristics of different types of CHD heart sound signals after wavelet decomposition and reconstruction are obvious, providing doctors with a strong auxiliary diagnosis basis.

[0149] In summary, the heart sound signal processing method based on wavelet decomposition can effectively distinguish normal heart sound signals from pathological heart sound signals, extract characteristic signals of different types of CHD, and provide reliable data support for clinical diagnosis.

[0150] 4.5 Decomposition and reconstruction of cardiac sound waveforms in patients with VSD:

[0151] Based on the method for decomposing and reconstructing the digitized heart sound signal proposed in Example 1, the present invention re-divides the heart sound frequency band, studies the re-combination of detail functions d1-d6, and reconstructs the LFB, MFB, HFB and EHFB frequency bands. The specific situation is as follows: Figure 6 As shown, the waveform distribution comparison of the decomposed and reconstructed heart sound signals of VSD patients is shown. Figure 6 a is a waveform diagram after heart sound decomposition, showing the reconstructed signals of detail functions d1-d6 obtained by wavelet transform decomposition. These detail functions correspond to heart sound signal components in different frequency ranges, namely d1, d2, d3, d4, d5 and d6. The reconstructed signal of each detail function is displayed in the figure by time axis (Sample) and amplitude (Amplitude). Figure 6 b is the waveform diagram after reconstruction of the heart sound, showing the reconstructed signals of the low frequency band (LFB), mid frequency band (MFB), high frequency band (HFB) and ultra-high frequency band (EHFB) after recombining these detail functions. These reconstructed signals are also displayed according to the time axis (Sample) and amplitude (Amplitude), respectively representing the components of the heart sound signals in different frequency bands.

[0152] 4.6 Result analysis:

[0153] 4.6.1 Differences in signal characteristics: Figure 6 The detail signals (d1-d6) in a are the result of decomposing the different frequency components of the original heart sound signal. Each detail signal represents a heart sound signal with different frequency components, where d1 is the highest frequency component and d6 is the lowest frequency component. As the frequency decreases, the amplitude and details of the signal also change, showing the characteristics of different frequency bands. Figure 6 The reconstructed signals in b are LFB (low frequency band), MFB (mid frequency band), and HFB

[0154] (High Frequency Band) and EHFB (Extreme High Frequency Band) are combined reconstructed signals based on d1-d6. LFB signals mainly contain basic heart sound features, such as S1 and S2 sounds, with large amplitudes and relatively simple waveforms; MFB and HFB signals contain higher frequency details and murmurs, which help identify heart murmurs and abnormal heart sounds; EHFB signals contain the highest frequency details and important high-frequency components, which help more detailed heart sound analysis.

[0155] 4.6.2 Diagnostic Basis: Low frequency band signal (LFB) is mainly used to detect and analyze basic heart sound components, and is suitable for identifying normal heart sounds and some low-frequency lesions. Mid-frequency band signal (MFB) and high-frequency band signal (HFB) are more likely to reflect heart murmurs and other abnormal high-frequency components, and are particularly important for the diagnosis of heart disease. Extra-high frequency band signal (EHFB) contains the highest frequency details, which is helpful for early detection of small lesions and fine diagnosis.

[0156] By analyzing the signal characteristics of these frequency bands, we can have a more comprehensive understanding of the changes in heart sounds in VSD patients, thereby providing a more accurate basis for diagnosis. This decomposition and reconstruction method improves the signal resolution and diagnostic accuracy, and helps to detect and diagnose heart disease at an early stage.

[0157] 4.7 The codes used in this section are as follows:

[0158] %The research code in this section is implemented based on MATLAB R2021a, and the following is the code comment content

[0159] %2. This code imports a heart sound signal, performs a 6th-order wavelet decomposition on it, reconstructs each wavelet coefficient, and finally visualizes the decomposed signal

[0160] %Import original heart sound signal

[0161] [y,Fs]=audioread('C:\Users\Dr.WY\Desktop\11-14-01-P.wav');

[0162] %Resample the heart sound signal

[0163] new_Fs=2000;% The new sampling rate is 2000Hz

[0164] resampled_signal=resample(y,new_Fs,Fs);

[0165] %Wavelet decomposition

[0166] level=6; %Set the number of layers of wavelet decomposition

[0167] wavelet = 'db6'; % Select Daubechies 6th order wavelet as the mother function

[0168] [c,l]=wavedec(resampled_signal,level,wavelet);

[0169] %Reconstruct part d1~d6

[0170] reconstructed_d = cell (1, level); % Initialize the variables of reconstructed wavelet coefficients

[0171] for i=1:level

[0172] reconstructed_d{i}=wrcoef('d',c,l,wavelet,i); %Reconstruct the wavelet coefficients of the i-th layer

[0173] end

[0174] % Visualize the decomposed signal

[0175] figure;

[0176] for i=1:length(reconstructed_d)

[0177] subplot(length(reconstructed_d),1,i);

[0178] plot(reconstructed_d{i});

[0179] title(['Reconstructed Signal for d',num2str(i)]);

[0180] xlabel('Sample');

[0181] ylabel('Amplitude');

[0182] End

[0183] Example 5: Analysis of the correlation between energy entropy and defect size

[0184] 5.1 Calculation of signal spectrum characteristics

[0185] The wavelet spectrum entropy value in each frequency band is calculated by dividing the frequency bands in step 4.2 of Example 4, and the correlation analysis is completed with the size of the CHD defect / abnormal channel. The wavelet spectrum entropy is the weighted average of the information entropy of each frequency band. By weighted averaging the entropy values ​​of all frequency bands, a comprehensive measure of the spectrum characteristics of the entire signal can be obtained, which helps analyze the spectrum characteristics, frequency component distribution, spectrum smoothness and peak value of the signal. The calculation includes the following steps:

[0186] (1) WT transform decomposition: Perform WT decomposition on the signal to decompose it into wavelet coefficients of different scales and frequencies;

[0187] (2) Calculate EM: Square the amplitude of the wavelet coefficients at each scale and frequency to obtain EM;

[0188] (3) Normalization: Normalize the energy spectrum so that its sum is 1 to eliminate the influence of signal energy.

[0189] (4) Calculation of information entropy: The information entropy is calculated using the normalized energy spectrum to measure the uncertainty and complexity of energy distribution.

[0190] 5.2 Digital signal quantization processing

[0191] The present invention includes digitized heart sound data collected from 88 children with VSD (46 males and 42 females) (general conditions are detailed in Table 2), collects heart sound data, selects the most obvious part of the murmur, extracts the signal WESE value after noise reduction processing and decomposition and reconstruction, and realizes digital signal quantization processing.

[0192] Table 2 General information of 88 cases of VSD

[0193]

[0194] As shown in Table 2, a total of 88 VSD patients were included in the present invention. According to their pathophysiological characteristics and echocardiographic diagnosis results, they were classified into simple VSD, combined VSD (VSD+ASD / PFO / PDA), complex VSD (VSD+ASD, PFO, PDA, etc.) and others (VSD+left ventricular outflow tract fibrous ridge / left aortic arch with right subclavian artery / right aortic arch with left subclavian artery / coronary artery-pulmonary artery fistula). At the same time, in view of the fact that there is no unified VSD size classification internationally, based on the classification scheme of ventricular septal defect in the 11th revised edition of the International Classification of Diseases of the International Society for Pediatric and Congenital Heart Disease Nomenclature in 2017, the study redefined the size of VSD defects, among which small defects were ≤5.00mm, medium defects were 5.00-10.00mm, and large defects were ≥10.00mm. The specific distribution is shown in Table 3.

[0195] Table 3 Classification of 88 cases of VSD

[0196]

[0197] Based on the WESE heart sound digital signal quantization method, the present invention realizes the wavelet spectrum entropy value of the heart sound digital signal. Considering that the frequency of murmurs is usually higher than that of normal heart sounds, the high-frequency band HFB value and EHFB value are subsequently included in the correlation analysis. The specific situation is shown in Table 4.

[0198] Table 4 VSD defect size and cardiac volume quantification results

[0199]

[0200]

[0201]

[0202]

[0203] 5.3 Correlation analysis of samples

[0204] The present invention uses the Spearman correlation coefficient for correlation analysis. The results show that the correlation coefficient between the HFB value and the sample defect size is 0.74 (P < 0.05), and the correlation coefficient between the EHFB value and the sample defect size is 0.88 (P < 0.05), indicating that the energy spectrum entropy curve under the EHFB band is more correlated with the sample defect aperture size curve.

[0205] Due to the medium-sized defect HFB, EHFB band wavelet spectrum entropy quantization boundary values ​​are 6.62 ~ 7.40, 8.89 ~ 10.17. Comparing the degree of "defect type" in Table 3, the accuracy of the wavelet spectrum entropy value level judgment calculated for each sample under the HFB and EHFB frequency bands is statistically analyzed. The accuracy of judging the defect type based on the wavelet spectrum entropy value of the HFB and EHFB bands is 68.18% and 75.00%, respectively. That is to say, by calculating the wavelet spectrum entropy value of the VSD heart sound digitized data in the HFB and EHFB bands proposed in this chapter, the degree of defect of the heart sound sample can be preliminarily determined: in the HFB band, values ​​below ≤6.62 can be considered as a small aperture defect, values ​​between 6.62 and 7.40 can be considered as a moderate aperture defect, and values ​​≥7.40 can be considered as a large aperture defect; in the EHFB band, values ​​≤8.90 can be considered as a small aperture defect, values ​​between 8.89 and 10.17 can be considered as a moderate aperture defect, and values ​​≥10.17 can be considered as a large aperture defect. Based on the quantification and defect type determination method proposed in this embodiment, the goal of quantifying the aperture size of the VSD defect is achieved to a certain extent.

[0206] 5.4 The codes used in this section are as follows:

[0207] %The research code in this section is implemented based on MATLAB R2021a, and the following is the code comment content

[0208] %2. This code imports a heart sound signal, resamples it to 2000Hz, and performs 6-layer wavelet decomposition. The energy and information entropy of each layer are calculated respectively. Each layer is re-divided into frequency bands according to frequency, and the energy value and information entropy of each frequency band are calculated to realize the quantization method of WESE heart sound digital signal.

[0209] level=6; %Set the number of layers of wavelet decomposition

[0210] %Import the original heart sound signal, assuming the sampling frequency is 4000Hz

[0211] [y,Fs]=audioread('C:\Users\Dr.WY\Desktop\11-14-01-P.wav');

[0212] %Resample the heart sound signal to 2000Hz

[0213] new_Fs=2000;% The new sampling rate is 2000Hz

[0214] resampled_signal=resample(y,new_Fs,Fs);

[0215] % Initialize frequency range

[0216] freq_ranges=zeros(level,2);

[0217] %Wavelet decomposition

[0218] wavelet = 'db6'; % Select Daubechies 6th order wavelet as mother function [c, l] = wavedec (resampled_signal, level, wavelet);

[0219] %Reconstruct d1~d6 and calculate energy and information entropy

[0220] energy_d=zeros(1,level); % Initialize the energy values ​​of each layer

[0221] entropy_d = zeros(1, level); % Initialize the information entropy of each layer

[0222] for i=1:level

[0223] %Reconstruct the wavelet coefficients of the current layer

[0224] reconstructed_d=wrcoef('d',c,l,wavelet,i);

[0225] %Redefine according to the given frequency range

[0226] switch i

[0227] Case 1

[0228] freq_ranges(i,:)=[1000,2000];

[0229] Case 2

[0230] freq_ranges(i,:)=[500,1000];

[0231] Case 3

[0232] freq_ranges(i,:)=[250,500];

[0233] Case 4

[0234] freq_ranges(i,:)=[125,250];

[0235] Case 5

[0236] freq_ranges(i,:)=[62.5,125];

[0237] Case 6

[0238] freq_ranges(i,:)=[31.25,62.5];

[0239] end

[0240] % Calculate the power spectral density of the reconstructed signal of the current layer

[0241] [Pxx,f]=pwelch(reconstructed_d,[],[],[],new_Fs);

[0242] %Intercept the power spectral density of the current layer

[0243] Pxx_subband=Pxx(f>=freq_ranges(i,1)&f<=freq_ranges(i,2));

[0244] % Calculate the energy of the current layer

[0245] energy_d(i)=sum(Pxx_subband);

[0246] % Normalized energy spectrum

[0247] normalized_Pxx=Pxx_subband / sum(Pxx_subband);

[0248] % Calculate information entropy

[0249] entropy_d(i)=-sum(normalized_Pxx.*log2(normalized_Pxx+eps));

[0250] % Output the energy value, information entropy and frequency range of the current layer

[0251] disp(['d',num2str(i),'Frequency range:',num2str(freq_ranges(i,1)),'Hz to',num2str(freq_ranges(i,2)),'Hz,Energy value:',num2str(energy_d(i)),',Information entropy:',num2str(entropy_d(i))]);

[0252] end

[0253] % Redefine frequency band boundaries

[0254] LFB_lower=31.25;%LFB lower limit

[0255] LFB_upper=62.5; %LFB upper limit

[0256] MFB_lower=62.5; %MFB lower limit

[0257] MFB_upper=250; %MFB upper limit

[0258] HFB_lower=250; %HFB lower limit

[0259] HFB_upper=500; %HFB upper limit

[0260] EHFB_lower=500; %EHFB lower limit

[0261] EHFB_upper=2000;%EHFB upper limit

[0262] % Find the index of the frequency band in the spectrum

[0263] LFB_index=find(f>=LFB_lower&f <LFB_upper);

[0264] MFB_index=find(f>=MFB_lower&f <MFB_upper);

[0265] HFB_index=find(f>=HFB_lower&f <HFB_upper);

[0266] EHFB_index=find(f>=EHFB_lower&f<=EHFB_upper);

[0267] % Calculate the energy of each frequency band

[0268] LFB_energy=sum(Pxx(LFB_index));

[0269] MFB_energy=sum(Pxx(MFB_index));

[0270] HFB_energy=sum(Pxx(HFB_index));

[0271] EHFB_energy=sum(Pxx(EHFB_index));

[0272] % Normalized energy spectrum

[0273] normalized_Pxx_LFB=Pxx(LFB_index) / sum(Pxx(LFB_index));

[0274] normalized_Pxx_MFB=Pxx(MFB_index) / sum(Pxx(MFB_index));

[0275] normalized_Pxx_HFB=Pxx(HFB_index) / sum(Pxx(HFB_index));

[0276] normalized_Pxx_EHFB=Pxx(EHFB_index) / sum(Pxx(EHFB_index));

[0277] % Calculate information entropy

[0278] entropy_LFB=-sum(normalized_Pxx_LFB.*log2(normalized_Pxx_LFB+eps));

[0279] entropy_MFB=-sum(normalized_Pxx_MFB.*log2(normalized_Pxx_MFB+eps));

[0280] entropy_HFB=-sum(normalized_Pxx_HFB.*log2(normalized_Pxx_HFB+eps));

[0281] entropy_EHFB=-sum(normalized_Pxx_EHFB.*log2(normalized_Pxx_EHFB+eps));

[0282] % Output the energy value and information entropy of each frequency band

[0283] disp(['Low frequency energy:',num2str(LFB_energy),',Information entropy:',num2str(entropy_LFB)]);

[0284] disp(['MFB_energy', num2str(MFB_energy),', information entropy', num2str(entropy_MFB)]);

[0285] disp(['High frequency energy:',num2str(HFB_energy),',Information entropy:',num2str(entropy_HFB)]);

[0286] disp(['Extremely high frequency energy:',num2str(EHFB_energy),',Information entropy:',num2str(entropy_EHFB)]);

[0287] The embodiments of the present invention are only to introduce the specific implementation methods thereof, and are not intended to limit the protection scope thereof. The technicians in the industry may make some modifications inspired by the embodiments, so any equivalent changes or modifications made according to the scope of the present invention are within the scope of the patent claims of the present invention.

Claims

1. A method for extracting, decomposing, reconstructing and quantifying heart sound features, characterized in that: The following steps are involved: S1. Collecting heart sound signals: placing the sensor on the patient's chest to be collected and recording the heart sound signals; S2, noise reduction preprocessing: use wavelet denoising algorithm to remove high-frequency noise; S3. Wavelet decomposition and reconstruction of heart sound signals: Use wavelet functions to perform multi-scale wavelet decomposition on the pre-processed heart sound signals to obtain several detail coefficients and approximation coefficients; reconstruct the signals of the required frequency bands to enhance feature information; S4. Calculate the signal power spectrum density and normalize the energy spectrum: Use Fourier transform to calculate the power spectrum density PSD of the heart sound signal, square the amplitude of the wavelet coefficients of each scale and frequency to obtain the energy spectrum EM, normalize EM to obtain the normalized energy spectrum; S5. Calculate signal energy entropy value: calculate the energy entropy value of the signal; S6. Analyze the correlation between energy entropy and defect size: collect heart sound signals and corresponding clinical defect size data of several patients, analyze the correlation between energy entropy value and clinical defect size, and verify the accuracy and reliability of the algorithm.

2. A method for extracting, decomposing, reconstructing and quantifying heart sound features according to claim 1, characterized in that: The parts to be collected in step S1 include: the second intercostal space, the right sternal border; the second intercostal space, the left sternal border; the third intercostal space, the left sternal border; the left lower sternal border; and the fifth intercostal space.

3. A method for extracting, decomposing, reconstructing and quantifying heart sound features according to claim 1, characterized in that: The wavelet denoising algorithm in step S2 is any one of a soft threshold method and a hard threshold method.

4. A method for extracting, decomposing, reconstructing and quantifying heart sound features according to claim 1, characterized in that: The wavelet function in step S3 is any one of Morlet wavelet, Haar wavelet, Daubechies wavelet and symleta wavelet.

5. A method for extracting, decomposing, reconstructing and quantifying heart sound features according to claim 1, characterized in that: The conversion formula of Fourier transform in step S4 is as follows: Where k = 0, 1, 2, ..., N-1 represents the discrete frequency index in the frequency domain; j is an imaginary unit, satisfying j 2 = -1; X(k) represents the discrete Fourier transform (DFT) coefficient at frequency k in the frequency domain; x (n) represents the input signal of sequence n in the time domain; N represents the total number of sampling points in the signal; n represents the sampling point index in the time domain, ranging from 0 to N-1; k represents the frequency index, ranging from 0 to N-1; e Represents the base of the natural logarithm; -2πnk / N represents the phase shift of each frequency component.

6. A method for extracting, decomposing, reconstructing and quantifying heart sound features according to claim 1, characterized in that: The calculation formula of the energy entropy value in step S5 is: Among them, P i represents the i-th component of the normalized energy spectrum, and N is the total number of frequency components.

Citation Information

Cited By

  • Prognosis prediction method and system for chronic Doc patient

    CN120048519A

  • Patient sign data verification and restoration method, device and equipment

    CN121789874A

  • A patient sign data verification and repair method, device and equipment

    CN121789874B