Effective heart sound fragment automatic extraction method

By performing distortion region repair, bandpass filtering, and low-frequency envelope extraction on the heart sound signal, combined with extreme point clustering and similarity measurement, the problem of inaccurate heart sound signal extraction in existing technologies is solved, achieving efficient and accurate automatic extraction of heart sound segments, which is suitable for environments with limited resources.

CN121400867APending Publication Date: 2026-01-27HUZHOU ENMEIDI ARTIFICIAL INTELLIGENCE TECHNOLOGY CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202511330407.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-09-17
Publication Date
2026-01-27

AI Technical Summary

Technical Problem

Existing intelligent analysis methods for heart sound signals struggle to accurately extract effective heart sound segments from heart sound signals, resulting in large errors in the analysis results and a reliance on high-performance computing resources.

Method used

By employing a method based on extreme point clustering and low-frequency envelope similarity measurement, effective heart sound segments are accurately extracted by performing distortion region repair, bandpass filtering, low-frequency envelope extraction, and candidate heart sound cycle signal aggregation on the heart sound signal.

Benefits of technology

It improves the automation and accuracy of heart sound signal analysis, reduces the computational resource requirements, is suitable for resource-constrained environments, and is applicable to large-scale heart sound signal screening and analysis.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121400867A_ABST
    Figure CN121400867A_ABST
Patent Text Reader

Abstract

The invention relates to heart sound signal processing, in particular to a method for automatically extracting effective heart sound fragments, which comprises the following steps of: repairing a distorted region in a heart sound signal collected by an electronic stethoscope; carrying out band-pass filtering processing on the repaired heart sound signal, and reserving main frequency components of the human heart sound; extracting a low-frequency envelope of the heart sound signal after band-pass filtering to obtain a heart sound envelope diagram; identifying and clustering local peak values and local valley values in the heart sound envelope diagram, and extracting key points for defining periods and boundaries of heart sounds to form a series of candidate heart sound period signals; comparing the candidate heart sound period signals, and aggregating the highly similar candidate heart sound period signals into a fragment to extract continuous effective heart sound fragments; according to the technical scheme provided by the invention, the defect that effective heart sound fragments are difficult to accurately extract from heart sound signals in the prior art can be effectively overcome.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to heart sound signal processing, and more specifically to a method for automatically extracting effective heart sound segments. Background Technology

[0002] Heart sounds are biosound signals generated by the mechanical activity of the heart, and their specific characteristics can reflect the functional state of the cardiovascular system. Using heart sounds for cardiac health monitoring and disease screening has advantages such as being non-invasive, low-cost, and convenient, thus holding significant application value in the rapid examination of cardiovascular diseases.

[0003] Traditional heart sound analysis relies on the auscultation experience and subjective judgment of professional physicians. This approach is inefficient, highly subjective, and difficult to meet the needs of large-scale applications. In recent years, the combination of electronic stethoscopes and artificial intelligence technology has provided a new approach for intelligent analysis of heart sound signals. However, current intelligent heart sound signal analysis methods still face significant challenges in practical applications.

[0004] Existing intelligent heart sound signal analysis methods are mainly divided into traditional pattern analysis methods based on signal processing and artificial intelligence analysis methods based on deep learning. The application of these methods highly relies on high-quality, valid heart sound data. However, in practical applications, not all signals picked up by electronic stethoscopes are valid heart sound data. For example, invalid heart sound data may be collected when the probe is not placed in the correct auscultation area, when the probe pressure is uneven / excessive causing truncation, or when the probe quickly sweeps across clothing. If invalid heart sound data is input into the intelligent heart sound signal analysis system without proper identification, it will lead to serious errors in the analysis results.

[0005] To address the above issues, this invention proposes an automatic extraction method for effective heart sound segments based on extreme point clustering and low-frequency envelope similarity measurement, thereby achieving accurate segmentation and extraction of effective heart sound signals and providing high-quality input data for intelligent heart sound signal analysis systems. Summary of the Invention

[0006] (a) Technical problems to be solved In view of the above-mentioned shortcomings of the existing technology, the present invention provides an effective automatic extraction method for heart sound segments, which can effectively overcome the defect of the existing technology that makes it difficult to accurately extract effective heart sound segments from heart sound signals.

[0007] (II) Technical Solution To achieve the above objectives, the present invention provides the following technical solution: The method for automatic extraction of effective heart sound fragments includes the following steps: S1. Repair the distorted areas in the heart sound signals collected by the electronic stethoscope; S2. Bandpass filtering is applied to the repaired heart sound signal to preserve the main frequency components of human heart sounds; S3. Extract the low-frequency envelope of the bandpass filtered heart sound signal to obtain the heart sound envelope diagram; S4. Identify and cluster local peaks and local valleys in the heart sound envelope map, extract key points for defining the period and boundary of heart sounds, and form a series of candidate heart sound period signals; S5. Compare the candidate heart sound cycle signals and aggregate highly similar candidate heart sound cycle signals into a segment to extract continuous valid heart sound segments.

[0008] Preferably, in S1, the distortion region in the heart sound signal acquired by the electronic stethoscope is repaired, including: S11. Locate the amplitude distortion region in the heart sound signal collected by the electronic stethoscope; S12. The distorted region is reconstructed using cubic spline interpolation to repair the distorted region in the heart sound signal and restore the true waveform of the heart sound signal.

[0009] Preferably, in S12, cubic spline interpolation is used to reconstruct the distorted region to repair the distorted region in the heart sound signal and restore the true waveform of the heart sound signal, including: S121. Taking the heart sound signal collected by the electronic stethoscope as the whole input, denoted as s(n), where n is the discrete-time index, and dividing it into several frame signals according to the frame length N, the l-th frame signal is represented as: ; S122. Calculate the short-time mean of each frame signal at each sampling point of the heart sound signal s(n) in time sequence. and short-term standard deviation : ; ; Where s(j) is the heart sound signal at sampling point j, and w is the short-time window length; S123. Set an amplitude change threshold. If detected If an amplitude anomaly is detected here, n is recorded as the distortion point index, and the sampling point here is added to the distortion point set D. Then, adjacent distortion points in the distortion point set D are merged into a larger distortion interval [i]. start i end ]; S124, in the distortion interval [i start i endCubic spline interpolation is performed within the frame signal to replace distorted or missing points. The sampled points within the frame signal are treated as known nodes, and interpolation is performed at adjacent nodes x. i x i+1 Construct a cubic spline function S between them i (x): ; Among them, a i b i c i d i All of these are coefficients to be determined. ; S125. Based on the following conditions, the cubic spline function S... i Solve for the coefficients to be determined in (x): 1) The magnitude is consistent with that of the known node, i.e.: S i (x i )=s(x i ), S i (x i+1 )=s(x i+1 ); 2) Ensure that within the interval [x] i ,x i+1 The first and second derivatives at the endpoints are continuous, i.e.: S i '(x i )=s'(x i ), S i ''(x i+1 )=s''(x i+1 ); S126. After obtaining all the coefficients to be determined, calculate the reconstructed values ​​of the distorted or missing points. : ; Where i represents the distortion point or missing point. , This represents the cubic spline function corresponding to the interval containing the distorted or missing points.

[0010] Preferably, in step S2, the repaired heart sound signal undergoes bandpass filtering to retain the main frequency components of the human heart sound, including: The repaired heart sound signal is processed using a bandpass filter to remove noise in frequencies outside the heart sound signal range, while retaining the main frequency components of the human heart sound. Specifically, this includes: S21. Treating the repaired heart sound signal as the whole input, denoted as s'(n), where n is the discrete-time index, and dividing it into several frame signals according to frame length N', the l'th frame signal is represented as: ; S22. A bandpass filter with upper and lower cutoff frequencies of 25Hz and 400Hz is preset to ensure that the first and second heart sounds in the heart sound signal are effectively captured. The bandpass filter is used to remove frequency components in each segment of the heart sound signal s'(n) that are outside the frequency range of 25Hz~400Hz, resulting in the bandpass-filtered frame signal. ; Where n = 0, 1, ..., N-1; S23. Concatenate all the bandpass-filtered frame signals to obtain the bandpass-filtered heart sound signal. .

[0011] Preferably, in step S3, the low-frequency envelope of the bandpass-filtered heart sound signal is extracted to obtain a heart sound envelope map, including: S31. The bandpass filtered heart sound signal The magnitude is mapped to the logarithmic domain and a small positive number is applied. To avoid numerical overflow or negative infinity, obtain additively varying heart sound signals. : ; Among them, heart sound signals Transform the multiplicative change of the signal into an additive change; S32. Extract additively varied heart sound signals using a low-pass Butterworth filter. The low-frequency envelope is used to obtain the intermediate low-frequency envelope signal. : ; Where LPF represents a low-pass Butterworth filter; S33, For intermediate low-frequency envelope signals An exponential operation is applied to restore it to its original amplitude level, yielding the final low-frequency envelope signal. : .

[0012] Preferably, in S4, local peaks and local valleys in the heart sound envelope are identified and clustered to extract key points for defining the period and boundaries of heart sounds, forming a series of candidate heart sound period signals, including: S41. Identify the final low-frequency envelope signal using peak detection technology. If n0 is an extreme point in the peak value, then n0 is considered a local peak if it meets the following peak value judgment condition: & ; If n1 satisfies the following valley value judgment condition, then n1 is considered a local valley value: & ; S42. Collect all extreme points and perform K-means clustering. Cluster the extreme points into a set of peaks K1 and a set of valleys K2 respectively, and determine the cluster center C1 of the set of peaks K1 and the cluster center C2 of the set of valleys K2. S43. Construct peak thresholds based on cluster centers C1 and C2 respectively. Valley threshold : ; ; Where var(K1) is the variance of the peak set K1, used to approximate the peak distribution; S44. Filtering for values ​​greater than the peak threshold. Local peak values, and values ​​below the valley threshold. The local troughs are identified, and these extreme points are used as key points to define the period and boundaries of heart sounds; S45. Connect the key points according to the preset rules to form a series of candidate heart sound cycle signals.

[0013] Preferably, in step S45, key points are connected according to preset rules to form a series of candidate heart sound cycle signals, including: If a local valley is detected followed by a local peak, then the local valley is considered as the starting point of a candidate heart sound cycle signal. If a local peak is subsequently detected followed by a local valley, and the time interval between the two local valleys is less than the first preset time interval, then the latter local valley is regarded as the end point of the candidate heart sound cycle signal. A complete candidate heart sound cycle signal is formed by the start point and the end point.

[0014] Preferably, in step S5, candidate heart sound cycle signals are compared, and highly similar candidate heart sound cycle signals are aggregated into a segment to extract continuous valid heart sound segments, including: S51. Reverse the first and last parts of the previous candidate heart sound cycle signal and use it as the vector template h of the next candidate heart sound cycle signal. t And calculate the heart sound cycle signal h for each candidate heart sound cycle. c Its corresponding vector template h t The similarity between S(h) t ,h c This is used to measure the degree of matching in shape and features between the homomorphic envelopes of two candidate heart sound cycle signals. ; in, For candidate heart sound cycle signal h c The mean vector, This indicates the calculation of the L2 norm, flipud represents the flipud function, and * represents the convolution operation; S52. Filter highly similar candidate heart sound cycle signals. If the candidate heart sound cycle signal h c Its corresponding vector template h t The similarity between S(h) t ,h c The similarity is greater than the preset similarity threshold S. T If so, then the two candidate heart sound cycle signals are considered to be highly similar; S53. Aggregate all candidate heart sound period signals that are highly similar and whose time interval between adjacent periods is less than the second preset time interval into a segment to extract continuous valid heart sound segments.

[0015] (III) Beneficial Effects Compared with existing technologies, the automatic extraction method for effective heart sound segments provided by this invention not only reduces the burden on medical personnel, but also greatly improves the automation and accuracy of heart sound signal analysis through precise identification and extraction of heart sound cycle signals. At the same time, this method does not rely on high-performance computing resources for processing heart sound signals, making it feasible and practical even in resource-limited environments. It has important application value for large-scale screening and analysis of heart sound signals. Using the technical solution provided by this invention, effective heart sound segments can be accurately extracted, redundant calculations can be reduced, and high-precision diagnostic results can be obtained in heart sound signal analysis, thereby providing accurate and reliable reference information for clinical practice. Attached Figure Description

[0016] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the accompanying drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are merely some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without any creative effort.

[0017] Figure 1 This is a schematic diagram of the process of the present invention; Figure 2 This is a comparison diagram showing how the cubic spline interpolation method is used in this invention to repair distorted regions in heart sound signals acquired by an electronic stethoscope. Figure 3 The heart sound envelope diagram is obtained by extracting the low-frequency envelope of the bandpass filtered heart sound signal in this invention. Figure 4 This is a schematic diagram illustrating the process of extracting key points from the heart sound envelope to form a series of candidate heart sound cycle signals in this invention. Figure 5 This is a schematic diagram illustrating how highly similar candidate heart sound cycle signals are aggregated into a single segment to extract continuous valid heart sound segments in this invention. Detailed Implementation

[0018] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of the present invention. All other embodiments obtained by those skilled in the art based on the embodiments of the present invention without creative effort are within the scope of protection of the present invention.

[0019] The following describes the specific process of the effective automatic heart sound fragment extraction method provided by this invention, using specific examples (e.g.) Figure 1 (as shown) and technical effects.

[0020] I. Repairing the heart sound signals collected by the electronic stethoscope (i.e. Figure 2 The distortion region (i.e., the original waveform represented by the gray line) in the middle gray area Figure 2 The area where the amplitude differs between the original waveform (represented by the gray line) and the repaired waveform (represented by the black line).

[0021] 1) Locate the region of amplitude distortion in the heart sound signal acquired by the electronic stethoscope; 2) Cubic spline interpolation is used to reconstruct the distorted region in the heart sound signal to repair the distorted region and restore the true waveform of the heart sound signal (i.e., Figure 2 The waveform after repair (represented by the black line) specifically includes: Taking the heart sound signal acquired by the electronic stethoscope at a sampling rate of 8Hz as the overall input, denoted as s(n), where n is the discrete-time index, and dividing it into several frame signals according to the frame length N, the l-th frame signal is represented as: ; Among them, the frame length N is set to 800 based on the heart sound and algorithm processing characteristics; For each frame signal, calculate the short-time mean at each sampling point of the heart sound signal s(n) in time sequence. and short-term standard deviation : ; ; Where s(j) is the heart sound signal at sampling point j, and w is the short-time window length, which is determined to be 100 sampling points based on the sampling frequency and the beat characteristics of the heart sound; Set an amplitude change threshold If detected If an amplitude anomaly is detected here, n is recorded as the distortion point index, and the sampling point here is added to the distortion point set D. Then, adjacent distortion points in the distortion point set D are merged into a larger distortion interval [i]. start i end ]; In the distortion interval [i start i end Cubic spline interpolation is performed within the frame signal to replace distorted or missing points. The sampled points within the frame signal are treated as known nodes, and interpolation is performed at adjacent nodes x. i x i+1 Construct a cubic spline function S between them i (x): ; Among them, a i b i c i d i All of these are coefficients to be determined. ; The cubic spline function S is subject to the following conditions. i Solve for the coefficients to be determined in (x): 1) The magnitude is consistent with that of the known node, i.e.: S i (x i )=s(x i ), S i (x i+1 )=s(x i+1 ); 2) Ensure that within the interval [x] i ,x i+1 The first and second derivatives at the endpoints are continuous, i.e.: S i '(x i )=s'(x i ), S i ''(x i+1 )=s''(x i+1 ); After obtaining all the coefficients to be determined, calculate the reconstructed values ​​of the distorted or missing points. : ; Where i represents the distortion point or missing point. , This represents the cubic spline function corresponding to the interval containing the distorted or missing points.

[0022] II. The bandpass filtering process restores the heart sound signal, preserving the main frequency components of the human heart sound, specifically including: The repaired heart sound signal is processed by bandpass filtering to filter out noise in the frequency range of non-heart sound signals and retain the main frequency components of human heart sounds.

[0023] The reason for the above process settings is that the repaired heart sound signal needs to be bandpass filtered. This is because the information contained in the heart sound signal is mainly concentrated in a specific frequency range. Bandpass filtering can remove irrelevant frequency components and retain the main sound wave information generated by heart activity.

[0024] The above process specifically includes: 1) Treating the repaired heart sound signal as the overall input, denoted as s'(n), where n is the discrete-time index, and dividing it into several frame signals according to frame length N', the l'th frame signal is represented as: ; 2) A bandpass filter with upper and lower cutoff frequencies of 25Hz and 400Hz is preset to ensure that the first and second heart sounds in the heart sound signal are effectively captured. The bandpass filter is used to remove frequency components in each segment of the heart sound signal s'(n) that are outside the frequency range of 25Hz~400Hz, resulting in the bandpass-filtered frame signal: ; Where n = 0, 1, ..., N-1; 3) Concatenate all the bandpass-filtered frame signals to obtain the bandpass-filtered heart sound signal. .

[0025] III. Extracting the bandpass filtered heart sound signal (i.e. Figure 3 The low-frequency envelope of the original signal (represented by the solid line in the middle) is used to obtain the heart sound envelope map (i.e., Figure 3 The low-frequency envelope is represented by the dashed line.

[0026] The reason for the above process is that, after bandpass filtering, in order to better present the energy changes of the heart sound signal on the time axis, this invention extracts the low-frequency envelope to transform the amplitude change characteristics of the heart sound signal into a smoother form.

[0027] The above process specifically includes: 1) Bandpass filtered heart sound signal The magnitude is mapped to the logarithmic domain and a small positive number is applied. To avoid numerical overflow or negative infinity, obtain additively varying heart sound signals. : ; Among them, heart sound signals Transform the multiplicative change of the signal into an additive change; 2) Extract additively varied heart sound signals using a low-pass Butterworth filter with a cutoff frequency below 8Hz. The low-frequency envelope is used to obtain the intermediate low-frequency envelope signal. : ; Where LPF represents a low-pass Butterworth filter; 3) For intermediate low-frequency envelope signals An exponential operation is applied to restore it to its original amplitude level, yielding the final low-frequency envelope signal. : .

[0028] After completing the low-frequency envelope extraction, it is necessary to accurately identify and extract key points in the heart sound envelope map in order to further analyze the systolic and diastolic phases of the heart.

[0029] IV. Identifying and clustering heart sound envelope maps (i.e.) Figure 4 Local peaks in the homomorphic envelope (represented by the black line) (i.e. Figure 4 The points shown in the middle circle) and local valleys (i.e. Figure 4 The points shown in the rhombus are used to extract key points for defining the period and boundaries of heart sounds, forming a series of candidate heart sound period signals (i.e., Figure 4 The candidate PCG periods represented by the gray line specifically include: 1) Identify the final low-frequency envelope signal using peak detection technology. If n0 is an extreme point in the peak value, then n0 is considered a local peak if it meets the following peak value judgment condition: & ; If n1 satisfies the following valley value judgment condition, then n1 is considered a local valley value: & ; 2) Collect all extreme points and perform K-means clustering. Cluster the extreme points into a set of peaks K1 and a set of valleys K2 respectively, and determine the cluster center C1 of the set of peaks K1 and the cluster center C2 of the set of valleys K2. 3) Construct peak thresholds based on cluster centers C1 and C2 respectively. Valley threshold : ; ; Where var(K1) is the variance of the peak set K1, used to approximate the peak distribution; 4) Filtering peak values ​​greater than the threshold Local peak values, and values ​​below the valley threshold. The local troughs are identified, and these extreme points are used as key points to define the period and boundaries of heart sounds; 5) Connect the key points according to preset rules to form a series of candidate heart sound cycle signals, specifically including: If a local valley is detected followed by a local peak, then the local valley is considered as the starting point of a candidate heart sound cycle signal. If a local peak is subsequently detected followed by a local trough, and the time interval between the two local troughs is less than 1 second, then the latter local trough is considered the end point of the candidate heart sound cycle signal. A complete candidate heart sound cycle signal is formed by the start point and the end point.

[0030] 5. Compare the candidate heart sound cycle signals and aggregate highly similar candidate heart sound cycle signals into a segment to extract continuous valid heart sound segments (i.e., Figure 5 The extracted segment is indicated by the dashed line.

[0031] The purpose of the above process is to: after obtaining candidate heart sound cycle signals, aggregate highly similar candidate heart sound cycle signals into effective heart sound segments by utilizing the approximate periodic repetition of H heart sounds, and achieve this by using a sliding template matching method.

[0032] The above process specifically includes: 1) Reverse the first and last parts of the previous candidate heart sound cycle signal and use it as the vector template h of the next candidate heart sound cycle signal. t And calculate the heart sound cycle signal h for each candidate heart sound cycle. c Its corresponding vector template h t The similarity between S(h) t ,h c This is used to measure the degree of matching in shape and features between the homomorphic envelopes of two candidate heart sound cycle signals. ; in, For candidate heart sound cycle signal h c The mean vector, This indicates the calculation of the L2 norm, flipud represents the flipud function, and * represents the convolution operation; 2) Filter highly similar candidate heart sound cycle signals. If the candidate heart sound cycle signal h c Its corresponding vector template h t The similarity between S(h) t ,h c The similarity is greater than the preset similarity threshold S. T If so, then the two candidate heart sound cycle signals are considered to be highly similar; 3) Aggregate all candidate heart sound cycle signals that are highly similar and have an interval of less than 0.6s between adjacent cycles into a single segment to extract continuous and valid heart sound segments.

[0033] The above embodiments are only used to illustrate the technical solutions of the present invention, and are not intended to limit it. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions will not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims

1. A method for automatic extraction of effective heart sound fragments, characterized in that: Includes the following steps: S1. Repair the distorted areas in the heart sound signals collected by the electronic stethoscope; S2. Bandpass filtering is applied to the repaired heart sound signal to preserve the main frequency components of human heart sounds; S3. Extract the low-frequency envelope of the bandpass filtered heart sound signal to obtain the heart sound envelope diagram; S4. Identify and cluster local peaks and local valleys in the heart sound envelope map, extract key points for defining the period and boundary of heart sounds, and form a series of candidate heart sound period signals; S5. Compare the candidate heart sound cycle signals and aggregate highly similar candidate heart sound cycle signals into a segment to extract continuous valid heart sound segments.

2. The method for automatic extraction of effective heart sound segments according to claim 1, characterized in that: S1 repairs distorted areas in the heart sound signals acquired by the electronic stethoscope, including: S11. Locate the amplitude distortion region in the heart sound signal collected by the electronic stethoscope; S12. The distorted region is reconstructed using cubic spline interpolation to repair the distorted region in the heart sound signal and restore the true waveform of the heart sound signal.

3. The method for automatic extraction of effective heart sound segments according to claim 2, characterized in that: S12 uses cubic spline interpolation to reconstruct the distorted region, thereby repairing the distorted area in the heart sound signal and restoring the true waveform of the heart sound signal, including: S121. Taking the heart sound signal collected by the electronic stethoscope as the whole input, denoted as s(n), where n is the discrete-time index, and dividing it into several frame signals according to the frame length N, the l-th frame signal is represented as: ; S122. Calculate the short-time mean of each frame signal at each sampling point of the heart sound signal s(n) in time sequence. and short-term standard deviation : ; ; Where s(j) is the heart sound signal at sampling point j, and w is the short-time window length; S123. Set an amplitude change threshold. If detected If an amplitude anomaly is detected here, n is recorded as the distortion point index, and the sampling point here is added to the distortion point set D. Then, adjacent distortion points in the distortion point set D are merged into a larger distortion interval [i]. start i end ]; S124, in the distortion interval [i start i end Cubic spline interpolation is performed within the frame signal to replace distorted or missing points. The sampled points within the frame signal are treated as known nodes, and interpolation is performed at adjacent nodes x. i x i+1 Construct a cubic spline function S between them i (x): ; Among them, a i b i c i d i All of these are coefficients to be determined. ; S125. Based on the following conditions, the cubic spline function S... i Solve for the coefficients to be determined in (x): 1) The magnitude is consistent with that of the known node, i.e.: S i (x i )=s(x i ), S i (x i+1 )=s(x i+1 ); 2) Ensure that within the interval [x] i ,x i+1 The first and second derivatives at the endpoints are continuous, i.e.: S i '(x i )=s'(x i ), S i ''(x i+1 )=s''(x i+1 ); S126. After obtaining all the coefficients to be determined, calculate the reconstructed values ​​of the distorted or missing points. : ; Where i represents the distortion point or missing point. , This represents the cubic spline function corresponding to the interval containing the distorted or missing points.

4. The method for automatic extraction of effective heart sound segments according to claim 2, characterized in that: In S2, the repaired heart sound signal undergoes bandpass filtering to preserve the main frequency components of the human heart sound, including: The repaired heart sound signal is processed using a bandpass filter to remove noise in frequencies outside the heart sound signal range, while retaining the main frequency components of the human heart sound. Specifically, this includes: S21. Treating the repaired heart sound signal as the whole input, denoted as s'(n), where n is the discrete-time index, and dividing it into several frame signals according to frame length N', the l'th frame signal is represented as: ; S22. A bandpass filter with upper and lower cutoff frequencies of 25Hz and 400Hz is preset to ensure that the first and second heart sounds in the heart sound signal are effectively captured. The bandpass filter is used to remove frequency components in each segment of the heart sound signal s'(n) that are outside the frequency range of 25Hz~400Hz, resulting in the bandpass-filtered frame signal. ; Where n = 0, 1, ..., N-1; S23. Concatenate all the bandpass-filtered frame signals to obtain the bandpass-filtered heart sound signal. .

5. The method for automatic extraction of effective heart sound segments according to claim 4, characterized in that: S3 extracts the low-frequency envelope of the bandpass-filtered heart sound signal to obtain the heart sound envelope map, including: S31. The bandpass filtered heart sound signal The magnitude is mapped to the logarithmic domain and a small positive number is applied. To avoid numerical overflow or negative infinity, obtain additively varying heart sound signals. : ; Among them, heart sound signals Transform the multiplicative change of the signal into an additive change; S32. Extract additively varied heart sound signals using a low-pass Butterworth filter. The low-frequency envelope is used to obtain the intermediate low-frequency envelope signal. : ; Where LPF represents a low-pass Butterworth filter; S33, For intermediate low-frequency envelope signals An exponential operation is applied to restore it to its original amplitude level, yielding the final low-frequency envelope signal. : 。 6. The method for automatic extraction of effective heart sound segments according to claim 5, characterized in that: In S4, local peaks and valleys in the heart sound envelope are identified and clustered to extract key points for defining the period and boundaries of heart sounds, forming a series of candidate heart sound period signals, including: S41. Identify the final low-frequency envelope signal using peak detection technology. If n0 is an extreme point in the peak value, then n0 is considered a local peak if it meets the following peak value judgment condition: & ; If n1 satisfies the following valley value judgment condition, then n1 is considered a local valley value: & ; S42. Collect all extreme points and perform K-means clustering. Cluster the extreme points into a set of peaks K1 and a set of valleys K2 respectively, and determine the cluster center C1 of the set of peaks K1 and the cluster center C2 of the set of valleys K2. S43. Construct peak thresholds based on cluster centers C1 and C2 respectively. Valley threshold : ; ; Where var(K1) is the variance of the peak set K1, used to approximate the peak distribution; S44. Filtering for values ​​greater than the peak threshold. Local peak values, and values ​​below the valley threshold. The local troughs are identified, and these extreme points are used as key points to define the period and boundaries of heart sounds; S45. Connect the key points according to the preset rules to form a series of candidate heart sound cycle signals.

7. The method for automatic extraction of effective heart sound segments according to claim 6, characterized in that: In S45, key points are connected according to preset rules to form a series of candidate heart sound cycle signals, including: If a local valley is detected followed by a local peak, then the local valley is considered as the starting point of a candidate heart sound cycle signal. If a local peak is subsequently detected followed by a local valley, and the time interval between the two local valleys is less than the first preset time interval, then the latter local valley is regarded as the end point of the candidate heart sound cycle signal. A complete candidate heart sound cycle signal is formed by the start point and the end point.

8. The method for automatic extraction of effective heart sound segments according to claim 6, characterized in that: In S5, candidate heart sound cycle signals are compared, and highly similar candidate heart sound cycle signals are aggregated into a segment to extract continuous valid heart sound segments, including: S51. Reverse the first and last parts of the previous candidate heart sound cycle signal and use it as the vector template h of the next candidate heart sound cycle signal. t And calculate the heart sound cycle signal h for each candidate heart sound cycle. c Its corresponding vector template h t The similarity between S(h) t ,h c This is used to measure the degree of matching in shape and features between the homomorphic envelopes of two candidate heart sound cycle signals. ; in, For candidate heart sound cycle signal h c The mean vector, This indicates the calculation of the L2 norm, flipud represents the flipud function, and * represents the convolution operation; S52. Filter highly similar candidate heart sound cycle signals. If the candidate heart sound cycle signal h c Its corresponding vector template h t The similarity between S(h) t ,h c The similarity is greater than the preset similarity threshold S. T If so, then the two candidate heart sound cycle signals are considered to be highly similar; S53. Aggregate all candidate heart sound period signals that are highly similar and whose time interval between adjacent periods is less than the second preset time interval into a segment to extract continuous valid heart sound segments.