A method for identifying abnormal heart sounds in patients with early acute heart failure
By using different types of sliding windows and hidden Markov models in the heart sound signal, the feature vectors of short sliding windows and long sliding windows are fused, and the problem that fixed windows are difficult to take into account the characteristics of different components of the heart sound signal is solved, and the precise division and abnormal recognition of the heart sound signal are achieved.
Patent Information
- Application Number
- CN202510551880.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-29
- Publication Date
- 2025-07-29
- Estimated Expiration
- 2045-04-29
AI Technical Summary
In the prior art, fixed-length sliding windows are difficult to take into account the characteristics of different components of the heart sound signal, resulting in inaccurate division of the heart sound signal and reducing the accuracy of heart sound abnormality recognition in patients with acute heart failure.
Different types of sliding windows are used to traverse the heart sound signals, extract the feature vectors, and build a hidden Markov model to accurately divide the heart sound segments by fusing the feature vectors of the short sliding window and the long sliding window.
The precise division of heart sound signals is achieved, and the accuracy of heart sound abnormality recognition in patients with acute heart failure is improved.
Smart Images

Figure CN120071973B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of heart sound health detection, and particularly relates to a method for identifying abnormal heart sounds in patients with early acute heart failure. Background Art
[0002] Since acute heart failure has a sudden onset and a critical condition, it is crucial to determine it early to quickly initiate a targeted treatment plan for acute heart failure. In the case of acute heart failure, both the function and structure of the heart are affected, resulting in abnormal changes in heart sounds. To accurately analyze and identify the abnormal manifestations of heart sound signals, it is necessary to segment the heart sound signals.
[0003] When segmenting heart sound signals using the traditional Hidden Markov Model, the features of the heart sound signals are extracted by using a sliding window with a fixed length to generate an observation value sequence, thereby realizing the segmentation of the heart sound signals. However, since the heart sound signals of heart failure patients contain various abnormal components and the overall heart sound signals are more complex, it is difficult for the sliding window with a fixed length to take into account the features of different components of the heart sound signals. A shorter sliding window may not contain enough information to judge the overall state of the heart sound, and a longer sliding window is prone to losing abnormally occurring heart sounds that appear briefly or features that change rapidly, thus making the division of the heart sound segments of the heart sound signals inaccurate and reducing the accuracy of identifying abnormal heart sounds in patients with acute heart failure. Summary of the Invention
[0004] In order to solve the technical problem that the sliding window with a fixed length in the Hidden Markov Model is difficult to take into account the features of different components of the heart sound signals, resulting in inaccurate division of the heart sound segments of the heart sound signals, the purpose of the present invention is to provide a method for identifying abnormal heart sounds in patients with early acute heart failure, and the specific technical solution adopted is as follows:
[0005] The present invention proposes a method for identifying abnormal heart sounds in patients with early acute heart failure, and the method includes:
[0006] Obtain the heart sound signal of the patient to be tested and the sample heart sound signal, and the sample heart sound signal is divided into four heart sound segments;
[0007] Use different types of sliding windows to traverse each sample heart sound signal, and extract the feature vectors of each sliding window on the sample heart sound signal; according to the amplitude distribution and duration of different heart sound segments of each sample heart sound signal, obtain the first heart sound moment and the second heart sound moment of each sample heart sound signal;
[0008] The time period between two adjacent first heart sound moments of each sample heart sound signal is denoted as the cardiac cycle; window combinations are determined based on the position distributions of two types of sliding windows on each sample heart sound signal; according to the amplitude similarity between the cardiac cycle in which the short sliding window in each window combination of each sample heart sound signal is located and its neighboring cardiac cycles, and the distance between the short sliding window and the cardiac cycle in which it is located, the feature vectors of the two sliding windows in each window combination are fused to obtain the fusion vector of each window combination of each sample heart sound signal;
[0009] An implicit Markov model is constructed based on the fusion vectors of the window combinations of the sample heart sound signals, and the heart sound signal of the patient to be measured is divided into different types of heart sound segments by using the implicit Markov model; heart sound abnormality detection is performed on the patient to be measured based on the heart sound segments of the heart sound signal.
[0010] Further, the obtaining of the first heart sound moment and the second heart sound moment of each sample heart sound signal includes:
[0011] The types of heart sound segments include the first heart sound segment, the second heart sound segment, the third heart sound segment, and the fourth heart sound segment;
[0012] A target sliding window is set, and the length of the target sliding window is the minimum value of the durations of the first heart sound segment and the second heart sound segment of all sample heart sound signals; each sample heart sound signal is traversed by using the target sliding window, and the peaks of the signals within all target sliding windows on each sample heart sound signal are arranged in time sequence to obtain an amplitude sequence;
[0013] For the remaining elements in the amplitude sequence except for a continuous number of elements less than the judgment threshold, if each element is greater than its adjacent previous element, then each element is denoted as a target element; the judgment threshold is equal to the amplitude mean value of all sample points of the third heart sound segment and the fourth heart sound segment of all sample heart sound signals;
[0014] According to the amplitude difference of the data points within the preset neighborhood range of the data points corresponding to the adjacent target elements in the amplitude sequence of each sample heart sound signal, the moments corresponding to the target elements in the amplitude sequence are divided into the first heart sound time period and the second heart sound moment.
[0015] Further, the dividing of the moments corresponding to the target elements in the amplitude sequence into the first heart sound time period and the second heart sound moment includes:
[0016] The target elements in the amplitude sequence of each sample heart sound signal are arranged in order to obtain a target sequence;
[0017] The amplitude mean value of all data points within the preset neighborhood range of the data points corresponding to each element in the target sequence in each sample heart sound signal is calculated as the neighborhood amplitude of the corresponding element;
[0018] Divide the target sequence into subsequences of length 2. If the neighborhood amplitude of the first element in a subsequence is greater than that of the second element, mark the subsequence as a target subsequence. Determine whether the number of target subsequences in each sample heart sound signal is greater than the number of non-target subsequences. If so, mark the time corresponding to the first element in the subsequences of the target sequence as the first heart sound time; if not, mark the time corresponding to the second element in the subsequences of the target sequence as the second heart sound time.
[0019] Further, the method for obtaining the fusion vector of each window combination of each sample heart sound signal includes:
[0020] Obtain the distance sensitivity of the sliding window within the corresponding cardiac cycle according to the amplitude similarity between each cardiac cycle of each sample heart sound signal and its neighboring cardiac cycles.
[0021] Denote the time interval between the middle moment in the short sliding window and the start moment within the cardiac cycle where the short sliding window is located in each window combination of each sample heart sound signal as the judgment distance corresponding to the window combination. Use the distance sensitivity of the cardiac cycle where the short sliding window is located in each window combination of each sample heart sound signal to adjust the judgment distance of each window combination, and obtain the fusion coefficient of the short sliding window in the corresponding window combination.
[0022] Use the fusion coefficient to fuse the feature vectors of the two sliding windows in each window combination of each sample heart sound signal, and obtain the fusion vector of each window combination of each sample heart sound signal.
[0023] Further, the method for obtaining the distance sensitivity includes:
[0024] Take the sum of the absolute values of the amplitude differences between each cardiac cycle of each sample heart sound signal and the start moment of its neighboring cardiac cycles and the absolute value of the amplitude difference at the second heart sound time as the overall neighborhood difference degree of each cardiac cycle of each sample heart sound signal.
[0025] Take the ratio of the neighborhood amplitude of the amplitude from the start moment of the cardiac cycle to the second heart sound time as the neighborhood ratio. Denote the variance of the difference between each cardiac cycle of each sample heart sound signal and the neighborhood ratio of its neighboring cardiac cycles as the neighborhood discrete value of each cardiac cycle.
[0026] Obtain the distance sensitivity of the sliding window within each cardiac cycle of each sample heart sound signal according to the overall neighborhood difference degree and the neighborhood discrete value.
[0027] Further, the method for obtaining the fusion coefficient includes:
[0028] Using the distance sensitivity of the short sliding window in each window combination of each sample heart sound signal in the cardiac cycle, the judgment distance is weighted, and the weighted result is negatively correlated and normalized to obtain the fusion coefficient of the short sliding window in the corresponding window combination.
[0029] Further, the fusion vector of each window combination of each sample heart sound signal includes:
[0030] For each window combination of each sample heart sound signal, the fusion coefficient is respectively used as the weight of the feature vector of the short sliding window in the window combination, and the difference between the constant 1 and the fusion coefficient is used as the weight of the feature vector of the long sliding window in the window combination. One half of the result of weighted summation of the feature vectors of the short sliding window and the long sliding window in the window combination is used as the fusion vector of the window combination.
[0031] Further, constructing a hidden Markov model based on the fusion vector of the window combination of the sample heart sound signal includes:
[0032] The fusion vectors of all window combinations of each sample heart sound signal are arranged in sequence to obtain the feature sequence of each sample heart sound signal; the feature sequences of all sample heart sound signals are input into the hidden Markov model to construct the hidden Markov model.
[0033] Further, determining the window combination based on the position distribution of the two sliding windows on each sample heart sound signal includes:
[0034] For each sample heart sound signal, calculate the time interval between each short sliding window on the sample heart sound signal and the middle moment of all long sliding windows respectively, and a window combination is formed by the long sliding window corresponding to the smallest time interval and each short sliding window.
[0035] Further, the types of the sliding windows include: long sliding windows and short sliding windows.
[0036] The present invention has the following beneficial effects:
[0037] In the embodiments of the present invention, the functional state of the heart in the case of heart failure will significantly affect the intensity and characteristics of heart sounds. The first heart sound and the second heart sound are significantly affected by heart failure. The abnormal heart sound conditions can be accurately analyzed to determine the first heart sound moment and the second heart sound moment of the sample heart sound signal. In order to avoid that a sliding window with a fixed length is difficult to take into account the characteristics of different components of the heart sound signal, a multi-scale window is used to process the sample heart sound signal. The amplitude similarity between a cardiac cycle and its neighboring cardiac cycles presents the sensitivity of the sliding window pair of the window combination within the cardiac cycle to the distance. Combining the distance between the short sliding window in the window combination and the cardiac cycle it is in, the feature vectors of the sliding windows of the window combination are adaptively fused, so that the fused vector can better reflect the dynamic change process of the heart sound signal, which helps to more accurately identify the positions of various heart sounds in the cardiac cycle during the subsequent segmentation of the heart sound signal. Thus, the accurate division of the heart sound segments of the heart sound signal is realized, and the accuracy of identifying abnormal heart sounds in patients with acute heart failure is improved. BRIEF DESCRIPTION OF THE DRAWINGS
[0038] In order to more clearly illustrate the technical solutions and advantages in the embodiments of the present invention or the prior art, the accompanying drawings required for the description of the embodiments or the prior art will be briefly introduced below. Obviously, the accompanying drawings in the following description are only some embodiments of the present invention. For those of ordinary skill in the art, other drawings can be obtained based on these drawings without creative efforts.
[0039] Figure 1 It is a flowchart of the steps of a method for identifying abnormal heart sounds in patients with early acute heart failure provided by an embodiment of the present invention;
[0040] Figure 2 It is a flowchart of the steps of a method for obtaining a fused vector provided by an embodiment of the present invention;
[0041] Figure 3 It is a schematic diagram of a computer device of a device for identifying abnormal heart sounds in patients with early acute heart failure provided by an embodiment of the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS
[0042] In order to further elaborate on the technical means and effects adopted by the present invention to achieve the predetermined invention purpose, the following combines the accompanying drawings and preferred embodiments to detail the specific implementation manners, structures, features and effects of a method for identifying abnormal heart sounds in patients with early acute heart failure proposed according to the present invention. In the following description, different "one embodiment" or "another embodiment" do not necessarily refer to the same embodiment. In addition, the specific features, structures or characteristics in one or more embodiments can be combined in any suitable form.
[0043] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the technical field to which this invention belongs.
[0044] The following specifically describes the specific solution of a method for identifying abnormal heart sounds in patients with early acute heart failure provided by the present invention in conjunction with the accompanying drawings.
[0045] Example 1:
[0046] The present invention proposes a method for identifying abnormal heart sounds in patients with early acute heart failure. Please refer to Figure 1 , which shows a flowchart of the steps of a method for identifying abnormal heart sounds in patients with early acute heart failure provided by an embodiment of the present invention. The method includes:
[0047] Step S1: Obtain the heart sound signal of the patient to be tested and the sample heart sound signal. The sample heart sound signal is divided into four heart sound segments.
[0048] Specifically, a doctor uses a heart sound stethoscope with a built-in Bluetooth system to collect the heart sound signal of a heart failure patient and uploads the heart sound signal of the heart failure patient to the cloud database. Select the heart sound signals uploaded within the past month from the cloud database. To reduce the amount of calculation, use Adobe Audition audio processing software to randomly intercept the signal of each heart sound signal for 1 minute continuously, denoted as the sample heart sound signal. At the same time, use a heart sound stethoscope to collect the heart sound signal of the patient to be tested for 20 minutes.
[0049] The heart sound signal of one cardiac cycle includes four heart sounds, which are, in order of appearance, the first heart sound, the third heart sound, the second heart sound, and the fourth heart sound. By the method of manual calibration, that is, the doctor calibrates the segmentation of the sample heart sound signal, and each sample heart sound signal is divided into four heart sound segments, including: the first heart sound segment, the second heart sound segment, the third heart sound segment, and the fourth heart sound segment. Among them, the first heart sound segment refers to the signal corresponding to the first heart sound of the sample voice signal, and the meanings of other heart sound segments are similar to that of the first heart sound segment.
[0050] In a specific implementation manner of the embodiment of the present invention, the signal sampling frequency is set to 10,000 Hertz.
[0051] Step S2: Use different types of sliding windows to traverse each sample heart sound signal, extract the feature vectors of each sliding window on the sample heart sound signal; according to the amplitude distribution and duration of different heart sound segments of each sample heart sound signal, obtain the first heart sound moment and the second heart sound moment of each sample heart sound signal.
[0052] In the process of segmenting heart sound signals using a hidden Markov model, it is difficult to take into account the characteristics of different components when extracting the characteristics of heart sound signals with a fixed-length window. In this solution, different types of sliding windows are used to traverse each sample heart sound signal, the feature vectors of the sliding windows are extracted, and the feature vectors extracted by sliding windows of different scales are fused to construct a hidden Markov model, so as to improve the accuracy of the model in segmenting heart sound signals.
[0053] In a specific implementation manner of the embodiment of the present invention, the types of sliding windows include: long sliding windows and short sliding windows, and the lengths of the long sliding windows and short sliding windows are set to 19 and 9 in sequence, and the implementer can set them according to specific situations. It should be noted that all windows in this solution refer to time windows.
[0054] In the embodiment of the present invention, the method for obtaining the feature vector of the sliding window is as follows: the signal in each sliding window of each type on the sample heart sound signal is recorded as the window analysis signal, all component signals obtained by decomposing the window analysis signal are arranged in the corresponding frequency order to obtain a frequency sequence; the sum of the squares of the amplitudes of the data points on the window analysis signal is calculated as the energy; the peak value, energy and frequency sequence of the window analysis signal are arranged in order to obtain the feature vector of the sliding window corresponding to the window analysis signal.
[0055] In a specific implementation manner of the embodiment of the present invention, the wavelet transform algorithm is used to decompose the window analysis signal to obtain component signals of different frequencies.
[0056] In the case of heart failure, the functional state of the heart will significantly affect the intensity and characteristics of heart sounds. Since the amplitudes of the first heart sound and the second heart sound are relatively large and are more significantly affected by heart failure, the correlation between the first heart sound, the second heart sound and heart failure is relatively large. In order to analyze the abnormal heart sound conditions of heart failure patients, it is necessary to determine the first heart sound moment and the second heart sound moment of the sample heart sound signal.
[0057] Preferably, in some possible implementation manners of the embodiments of the present invention, the method for obtaining the first heart sound period and the second heart sound moment includes: the types of heart sound segments include the first heart sound segment, the second heart sound segment, the third heart sound segment, and the fourth heart sound segment; a target sliding window is set, and the length of the target sliding window is the minimum value of the durations of the first heart sound segment and the second heart sound segment of all sample heart sound signals; the target sliding window is used to traverse each sample heart sound signal, and the peaks of the signals within all target sliding windows on each sample heart sound signal are arranged in time sequence to obtain an amplitude sequence; for the remaining elements in the amplitude sequence except for a continuous number of elements smaller than the judgment threshold, if each element is greater than its adjacent previous element, then each element is recorded as a target element; the judgment threshold is equal to the average amplitude of all sample points of the third heart sound segment and the fourth heart sound segment of all sample heart sound signals; according to the amplitude difference of the data points within the preset neighborhood range of the data points corresponding to the adjacent target elements in the amplitude sequence of each sample heart sound signal, the moments corresponding to the target elements in the amplitude sequence are divided into the first heart sound period and the second heart sound moment.
[0058] To more accurately analyze the first heart sound segment and the second heart sound segment, it is necessary to ensure that the target sliding window contains the first heart sound segment or the second heart sound segment, but does not entirely contain the third heart sound segment or the fourth heart sound segment. Since the durations of the first heart sound and the second heart sound are shorter than those of the third heart sound and the fourth heart sound, the length of the target sliding window is the minimum value of the durations of the first heart sound segment and the second heart sound segment of all sample heart sound signals. The amplitudes of the first heart sound and the second heart sound are greater than those of the third heart sound and the fourth heart sound. At the same time, the order of heart sounds in one cardiac cycle is the first heart sound, the third heart sound, the second heart sound, and the fourth heart sound in sequence. If the signal peaks within a continuous preset number of target sliding windows are all smaller than the judgment threshold, it indicates that these target sliding windows may be located in the third heart sound segment or the fourth heart sound segment. Among the remaining target sliding windows, if the signal peak within a target sliding window is greater than the signal peak within its previous target sliding window, then this target sliding window is in the first heart sound segment or the second heart sound segment.
[0059] The target sliding window corresponding to the target element is in the first heart sound segment or the second heart sound segment of the sample heart sound signal. Under normal physiological conditions, the signal amplitude of the first heart sound segment is higher than that of the second heart sound segment. Based on the neighborhood amplitude difference between adjacent target elements, it is determined whether the target element is in the first heart sound segment or the second heart sound segment. The specific method is as follows:
[0060] Arrange the target elements in the amplitude sequence of each sample heart sound signal in order to obtain a target sequence; calculate the amplitude mean of all data points within the preset neighborhood range of the corresponding data points of each element in the target sequence in each sample heart sound signal as the neighborhood amplitude of the corresponding element; divide the target sequence into subsequences of length 2. If the neighborhood amplitude of the first element in the subsequence is greater than that of the second element, then mark the subsequence as a target subsequence; determine whether the number of target subsequences of each sample heart sound signal is greater than the number of non-target subsequences. If so, mark the corresponding moment of the first element in the subsequences of the target sequence as the first heart sound moment, and if not, mark the corresponding moment of the second element in the subsequences of the target sequence as the second heart sound moment.
[0061] The amplitude of the first heart sound segment is significantly positively correlated with myocardial contractility. In the case of decreased myocardial contractility in heart failure patients, the amplitude of the first heart sound segment may be lower than that of the second heart sound segment. It is impossible to accurately judge the first heart sound moment and the second heart sound moment only by the amplitude sizes of the first heart sound segment and the second heart sound segment. Although the signal peak within the second heart sound segment may be greater than that of the first signal segment, overall, due to the strong blood movement during the systolic phase of the heart and the relatively stable blood during the diastolic phase, the surrounding amplitude at the first heart sound moment is greater than that at the second heart sound moment.
[0062] In a specific implementation manner of the embodiment of the present invention, take the minimum value of the durations of the third heart sound segment and the fourth heart sound segment of all sample heart sound signals as the numerator, and take the result of rounding down the ratio obtained by dividing the length of the target sliding window as the denominator as the preset quantity.
[0063] In a specific implementation manner of the embodiment of the present invention, the data point is located at the middle position within its preset neighborhood range, and there are 11 data points within the preset neighborhood range of the data point.
[0064] Step S3: Denote the time period between two adjacent first heart sound moments of each sample heart sound signal as a cardiac cycle; determine the window combination based on the position distribution of two types of sliding windows on each sample heart sound signal; fuse the feature vectors of the two sliding windows in each window combination of each sample heart sound signal according to the amplitude similarity between the short sliding window in the cardiac cycle where the short sliding window is located and its neighboring cardiac cycles and the distance between the short sliding window and the cardiac cycle where it is located to obtain the fusion vector of each window combination of each sample heart sound signal.
[0065] In order to perform multi-scale feature analysis on the sample heart sound signal, window combinations of different scales are constructed from the short sliding window and the long sliding window of the sample heart sound signal. The specific method includes: for each sample heart sound signal, calculate the time interval between the middle moment of each short sliding window on the sample heart sound signal and all long sliding windows respectively, and a window combination is formed by the long sliding window corresponding to the smallest time interval and each short sliding window.
[0066] The amplitude similarity between the cardiac cycle and its neighboring cardiac cycles presents the sensitivity of the sliding window pair distance within the cardiac cycle of the window combination. Combining the distance between the short sliding window in the window combination and the cardiac cycle it is in, the feature vectors of the sliding windows of the window combination are adaptively fused, so that the fused vector can better reflect the dynamic change process of the heart sound signal, which helps to more accurately identify the positions of various heart sounds in the cardiac cycle during the subsequent heart sound signal segmentation process.
[0067] Please refer to Figure 2 , which shows a flowchart of the steps of a method for obtaining a fused vector provided by an embodiment of the present invention. The method includes:
[0068] Step S310: Obtain the distance sensitivity of the sliding window within the corresponding cardiac cycle according to the amplitude similarity between each cardiac cycle of each sample heart sound signal and its neighboring cardiac cycles.
[0069] Preferably, in some possible implementation manners of the embodiment of the present invention, the method for obtaining the distance sensitivity includes: taking the sum of the absolute values of the amplitude differences between each sample heart sound signal at the start moment of each cardiac cycle and its neighboring cardiac cycles and the absolute value of the amplitude difference at the second heart sound moment as the overall neighborhood difference degree of each sample heart sound signal at each cardiac cycle; taking the ratio of the neighborhood amplitudes of the amplitudes at the start moment and the second heart sound moment of the cardiac cycle as the neighborhood ratio; taking the variance of the differences between the neighborhood ratios of each cardiac cycle of each sample heart sound signal and its neighboring cardiac cycles as the neighborhood discrete value of each cardiac cycle; and obtaining the distance sensitivity of the sliding window within each cardiac cycle of each sample heart sound signal according to the overall neighborhood difference degree and the neighborhood discrete value.
[0070] In patients with heart failure, the heart function is impaired, and there may be situations such as cardiac cycle disorders and changes in the characteristics of heart sound signals, resulting in different sensitivities of the sliding window to the distance of the first heart sound period in different cardiac cycles. If the amplitudes of each cardiac cycle of the sample heart sound signal are more similar to those of its neighboring cardiac cycles, it indicates that the characteristics of the sample heart sound are more stable in different cardiac cycles, and there is no need to capture the subtle differences caused by distance changes too acutely. Then, the sensitivity of the sliding window to the amplitude change at the first heart sound moment in each cardiac cycle is smaller. Since the first heart sound moment and the second heart sound moment have unique and relatively stable physiological characteristics, the amplitude similarity between each cardiac cycle and its neighboring cardiac cycles can be measured by the amplitude similarity within the neighborhood range of the first cardiac moment and the second cardiac moment of each sample heart sound signal and its neighboring cardiac cycles. That is, if the overall neighborhood difference degree and the neighborhood discrete value are smaller, the amplitude similarity between the cardiac cycle and its neighboring cardiac cycles is larger, and the distance sensitivity of the sliding window within the cardiac cycle is smaller.
[0071] In a specific implementation manner of the embodiment of the present invention, the distance sensitivity is expressed by the formula:
[0072] ;
[0073] In the formula, is the distance sensitivity of the sliding window within each cardiac cycle of each sample heart sound signal; is the neighborhood discrete value of each cardiac cycle of each sample heart sound signal; N is the total number of neighboring cardiac cycles of each cardiac cycle of each sample heart sound signal; F1 is the amplitude at the start moment of each cardiac cycle of each sample heart sound signal: is the amplitude at the start moment of the nth neighboring cardiac cycle of each cardiac cycle of each sample heart sound signal; is the amplitude at the second heart sound moment of each cardiac cycle of each sample heart sound signal; is the amplitude at the second heart sound moment of the nth neighboring cardiac cycle of each cardiac cycle of each sample heart sound signal; is the overall neighborhood difference degree of each cardiac cycle of each sample heart sound signal; is the absolute value function; Norm is the normalization function. It should be noted that there is only one second heart sound moment between each cardiac cycle.
[0074] In a specific implementation manner of the embodiment of the present invention, the 5 neighboring cardiac cycles before and the 5 neighboring cardiac cycles after each cardiac cycle of the sample heart sound signal are used as the neighboring cardiac cycles of each cardiac cycle.
[0075] Step S320: Denote the time interval between the middle moment within the short sliding window and the start moment within the cardiac cycle where the short sliding window is located in each window combination of each sample heart sound signal as the judgment distance of the corresponding window combination; adjust the judgment distance of each window combination by using the distance sensitivity of the cardiac cycle where the short sliding window is located in each window combination of each sample heart sound signal to obtain the fusion coefficient of the short sliding window in the corresponding window combination.
[0076] Preferably, in some possible implementation manners of the embodiments of the present invention, the method for obtaining the fusion coefficient includes: performing a weighting process on the judgment distance by using the distance sensitivity of the cardiac cycle where the short sliding window is located in each window combination of each sample heart sound signal, and performing a negative correlation and normalization process on the weighting result to obtain the fusion coefficient of the short sliding window in the corresponding window combination.
[0077] The first heart sound moment is generated due to the sudden closure of the valve. The signal within the first heart sound segment changes rapidly, and the short sliding window has a high time resolution and can keenly capture the rapidly changing features in the heart sound signal. Then, within the cardiac cycle, the short sliding window closer to the first heart sound moment can better capture the key time point within the first heart sound segment, that is, the detailed information of the first heart sound moment, and a greater weight needs to be given to the short sliding window in the window combination. Although the long sliding window has a low time resolution, it can cover the heart sound signal for a longer time period. In the diastolic phase far from the first heart sound segment, the heart sound signal is relatively stable, and the long sliding window more shows the overall rhythm and low-frequency changes. Therefore, when the middle moment within the short sliding window in the window combination is closer to the start moment within its cardiac cycle, during the feature fusion process of the sliding window in the window combination, the weight of the short sliding window is greater, that is, the fusion coefficient is greater, and the weight of the long sliding window is smaller.
[0078] Adjust the judgment distance of the window combination by using the sensitivity of the short sliding period in the window combination to the distance, so that the adjusted distance can more accurately measure the detailed information of the cardiac cycle. In a specific implementation manner of the embodiments of the present invention, the fusion coefficient is expressed by the formula:
[0079] ;
[0080] In the formula, is the fusion coefficient of the a-th combined window of each sample heart sound signal; is the distance sensitivity of the sliding window within the cardiac cycle where the short sliding window is located in the a-th combined window of each sample heart sound signal; is the middle moment of the short sliding window in the a-th combined window of each sample heart sound signal; is the start moment of the cardiac cycle where the short sliding window is located in the a-th combined window of each sample heart sound signal; is the judgment distance of the a-th combined window of each sample heart sound signal; is the absolute value function; exp is the exponential function with the natural constant as the base.
[0081] Step S330: Using the fusion coefficient, fuse the feature vectors of the two sliding windows in each window combination of each sample heart sound signal to obtain the fusion vector of each window combination of each sample heart sound signal.
[0082] Preferably, the method for obtaining the fusion vector is: for each window combination of each sample heart sound signal, respectively take the fusion coefficient as the weight of the feature vector of the short sliding window in the window combination, and the difference between the constant 1 and the fusion coefficient as the weight of the feature vector of the long sliding window in the window combination. Half of the result of the weighted sum of the feature vectors of the short sliding window and the long sliding window in the window combination is used as the fusion vector of the window combination.
[0083] ;
[0084] In the formula, is the fusion vector of the a-th combined window of each sample heart sound signal; is the fusion coefficient of the a-th combined window of each sample heart sound signal; is the feature vector of the short sliding window in the a-th combined window of each sample heart sound signal; is the feature vector of the long sliding window in the a-th combined window of each sample heart sound signal. It should be noted that adding two vectors is equivalent to adding the elements of the same dimension in the two vectors respectively.
[0085] Step S4: Construct a hidden Markov model based on the fusion vectors of the window combinations of the sample heart sound signals, and use the hidden Markov model to divide the heart sound signal of the patient to be tested into different types of heart sound segments; perform heart sound abnormality detection on the patient to be tested based on the heart sound segments of the heart sound signal.
[0086] Arrange the fusion vectors of all window combinations of each sample heart sound signal in sequence to obtain the feature sequence of each sample heart sound signal; input the feature sequences of all sample heart sound signals into the hidden Markov model to construct the hidden Markov model, and the hidden Markov model divides the sample heart sound signal into four types of heart sound segments. Among them, the parameters in the model are estimated by the expectation maximization algorithm such as the forward-backward algorithm. The construction and training methods of the hidden Markov model are well-known techniques to those skilled in the art and will not be elaborated here.
[0087] The present invention labels the disease types of heart failure patients through a long short-term memory network. The input of the neural network is the sample heart sound signal with segmented heart sound segments, and the output is the digital label of the disease type corresponding to the patient of the sample heart sound signal. The disease types in the embodiments of the present invention include acute heart failure and chronic heart failure, and the implementer can set them according to the actual situation. Among them, the relevant content of the long short-term memory network includes: the data set of the neural network is divided into a training set and a validation set; the training process of the neural network is the labeling process of the disease type, and the specific labeling process is: labeling the sample heart sound signal of the patient with acute heart failure as 0, and labeling the sample heart sound signal of the patient with chronic heart failure as 1; the loss function of the neural network is the cross-entropy function. Among them, the long short-term memory network is a well-known technology to those skilled in the art and will not be elaborated here.
[0088] First, input the heart sound signal of the patient to be tested into the hidden Markov model, and output the heart sound signal with segmented heart sound segments; then, input the heart sound signal of the patient to be tested into the trained neural network, and output the disease type of the patient to be tested; finally, initiate a targeted treatment plan for the patient with acute heart failure.
[0089] It should be noted that the acquisition methods of the characteristic sequences of the sample heart sound signal and the heart sound signal of the patient to be tested are the same.
[0090] So far, the present invention is completed.
[0091] Embodiment 2:
[0092] The present invention also provides a schematic diagram of a computer device for identifying abnormal heart sounds in patients with early acute heart failure. Please refer to Figure 3 . The computer device includes a memory 501, a processor 502, and a computer program 503 stored in the memory 501 and running on the processor 502. Among them, when the processor 502 executes the computer program 503, the computer device can execute any one of the methods for identifying abnormal heart sounds in patients with early acute heart failure introduced above.
[0093] In addition, the embodiments of the present application also protect a device, which may include a memory and a processor. Among them, the memory stores executable program code, and the processor is used to call and execute the executable program code to execute a method for identifying abnormal heart sounds in patients with early acute heart failure provided by the embodiments of the present application.
[0094] In this embodiment, the device can be divided into functional modules according to the above method examples. For example, it can correspond to each functional module, or two or more functions can be integrated into one processing module. The above integrated module can be implemented in the form of hardware. It should be noted that the division of modules in this embodiment is illustrative, only a logical function division, and there can be other division methods in actual implementation.
[0095] In the case of dividing each module according to each function, the device can further include a communication module, a signal analysis module, a complexity analysis module, a positioning module, etc. It should be noted that all relevant contents of each step involved in the above method embodiment can be cited in the function description of the corresponding functional module, and will not be elaborated here.
[0096] It should be understood that the device provided in this embodiment is used to execute the above method for identifying abnormal heart sounds in patients with early acute heart failure, so it can achieve the same effect as the above implementation method.
[0097] In the case of adopting an integrated unit, the device can include a processing module and a storage module. Among them, when the device is applied to a device, the processing module can be used to control and manage the actions of the device. The storage module can be used to support the device to execute mutual program codes, etc.
[0098] Among them, the processing module can be a processor or a controller, which can implement or execute various exemplary logical blocks, modules, and circuits included in the disclosure of this application. The processor can also be a combination that realizes computing functions, such as including a combination of one or more microprocessors, a combination of digital signal processing (DSP) and a microprocessor, etc. The storage module can be a memory.
[0099] Embodiment 3:
[0100] This embodiment also provides a computer-readable storage medium, in which computer program code is stored. When the computer program code runs on a computer, the computer is enabled to execute the above relevant method steps to implement the method for identifying abnormal heart sounds in patients with early acute heart failure provided in the above embodiment.
[0101] Embodiment 4:
[0102] This embodiment also provides a computer program product. When the computer program product runs on a computer, the computer is enabled to execute the above relevant steps to implement the method for identifying abnormal heart sounds in patients with early acute heart failure provided in the above embodiment.
[0103] Among them, the device, computer-readable storage medium, computer program product or chip provided in this embodiment are all used to execute the corresponding methods provided above. Therefore, the beneficial effects that can be achieved can refer to the beneficial effects in the corresponding methods provided above, and will not be elaborated here.
[0104] In the embodiments provided in this application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are merely illustrative. For example, the division of modules or units is only a logical function division. In actual implementation, there may be other division methods. For example, multiple units or components can be combined or integrated into another device, or some features can be ignored or not executed. Another point is that the displayed or discussed coupling or direct coupling or communication connection between each other can be through some interfaces. The indirect coupling or communication connection of devices or units can be in electrical, mechanical or other forms.
[0105] It should be noted that the above-mentioned order of the embodiments of the present invention is only for description and does not represent the superiority or inferiority of the embodiments. The processes depicted in the drawings do not necessarily require the particular order or sequential order shown to achieve the desired result. In some embodiments, multitasking and parallel processing are also possible or may be advantageous.
[0106] Each embodiment in this specification is described in a progressive manner. The same or similar parts among the embodiments can be referred to each other, and the key points of each embodiment are the differences from other embodiments.
Claims
1. A method for identifying abnormal heart sounds in patients with early acute heart failure, characterized in that, The method includes: acquiring a heart sound signal of a patient to be measured and a sample heart sound signal, wherein the sample heart sound signal is divided into four heart sound segments; traversing each sample heart sound signal by using different types of sliding windows, and extracting feature vectors of each sliding window on the sample heart sound signal; obtaining a first heart sound moment and a second heart sound moment of each sample heart sound signal according to the amplitude distribution and duration of different heart sound segments of each sample heart sound signal; recording the time period between two adjacent first heart sound moments of each sample heart sound signal as a cardiac cycle; determining a window combination based on the position distribution of two types of sliding windows on each sample heart sound signal; fusing the feature vectors of the two sliding windows in each window combination of each sample heart sound signal according to the amplitude similarity between the short sliding window in each window combination of each sample heart sound signal and its neighboring cardiac cycles and the distance between the short sliding window and its cardiac cycle to obtain a fusion vector of each window combination of each sample heart sound signal; constructing a hidden Markov model based on the fusion vectors of the window combinations of the sample heart sound signal, and using the hidden Markov model to divide the heart sound signal of the patient to be measured into different heart sound segments; performing heart sound abnormality detection on the patient to be measured based on the heart sound segments of the heart sound signal.
2. The method for identifying abnormal heart sounds in patients with early acute heart failure according to claim 1, wherein, The obtaining of the first heart sound moment and the second heart sound moment of each sample heart sound signal includes: The types of heart sound segments include a first heart sound segment, a second heart sound segment, a third heart sound segment, and a fourth heart sound segment; setting a target sliding window, wherein the length of the target sliding window is the minimum value of the durations of the first heart sound segment and the second heart sound segment of all sample heart sound signals; traversing each sample heart sound signal by using the target sliding window, and arranging the peaks of the signals in all target sliding windows on each sample heart sound signal in time sequence to obtain an amplitude sequence; for the remaining elements in the amplitude sequence except for a continuous number of elements less than a judgment threshold, if each element is greater than its adjacent previous element, then each element is recorded as a target element; the judgment threshold is equal to the amplitude mean value of all sample points of the third heart sound segment and the fourth heart sound segment of all sample heart sound signals; dividing the moments corresponding to the target elements in the amplitude sequence of each sample heart sound signal into a first heart sound time period and a second heart sound moment according to the amplitude difference of the data points within a preset neighborhood range of the data points corresponding to the adjacent target elements in the amplitude sequence of each sample heart sound signal.
3. The method for identifying abnormal heart sounds in patients with early acute heart failure according to claim 2, wherein, The dividing of the moments corresponding to the target elements in the amplitude sequence into a first heart sound time period and a second heart sound moment includes: sequentially arranging the target elements in the amplitude sequence of each sample heart sound signal to obtain a target sequence; calculating the amplitude mean value of all data points within a preset neighborhood range of the data points corresponding to each element in the target sequence in each sample heart sound signal as the neighborhood amplitude of the corresponding element; Divide the target sequence into subsequences of length 2. If the neighborhood amplitude of the first element in a subsequence is greater than that of the second element, mark the subsequence as a target subsequence; determine whether the number of target subsequences in each sample heart sound signal is greater than the number of non-target subsequences. If so, mark the time corresponding to the first element in the subsequences of the target sequence as the first heart sound time, and if not, mark the time corresponding to the second element in the subsequences of the target sequence as the second heart sound time.
4. The method for identifying abnormal heart sounds in patients with early acute heart failure according to claim 3, characterized in that, The method for obtaining the fusion vector of each window combination of each sample heart sound signal includes: Obtain the distance sensitivity of the sliding window within the corresponding cardiac cycle according to the amplitude similarity between each cardiac cycle of each sample heart sound signal and its neighboring cardiac cycles. Record the time interval between the middle moment within the short sliding window and the start moment within the cardiac cycle where the short sliding window is located in each window combination of each sample heart sound signal as the judgment distance corresponding to the window combination; use the distance sensitivity of the cardiac cycle where the short sliding window is located in each window combination of each sample heart sound signal to adjust the judgment distance of each window combination to obtain the fusion coefficient of the short sliding window in the corresponding window combination. Use the fusion coefficient to fuse the feature vectors of the two sliding windows in each window combination of each sample heart sound signal to obtain the fusion vector of each window combination of each sample heart sound signal.
5. The method for identifying abnormal heart sounds in patients with early acute heart failure according to claim 4, characterized in that The method for obtaining the distance sensitivity includes: Take the cumulative sum of the sum of the absolute value of the amplitude difference between each cardiac cycle of each sample heart sound signal and the start moment of its neighboring cardiac cycle and the absolute value of the amplitude difference at the second heart sound moment as the overall neighborhood difference degree of each cardiac cycle of each sample heart sound signal. Take the ratio of the neighborhood amplitude of the amplitude from the start moment to the second heart sound moment of the cardiac cycle as the neighborhood ratio; record the variance of the difference between each cardiac cycle of each sample heart sound signal and the neighborhood ratio of its neighboring cardiac cycles as the neighborhood discrete value of each cardiac cycle. Obtain the distance sensitivity of the sliding window within each cardiac cycle of each sample heart sound signal according to the overall neighborhood difference degree and the neighborhood discrete value.
6. The method for identifying abnormal heart sounds in patients with early acute heart failure according to claim 4, wherein The method for obtaining the fusion coefficient includes: Use the distance sensitivity of the cardiac cycle where the short sliding window is located in each window combination of each sample heart sound signal to perform weighted processing on the judgment distance, perform negative correlation and normalization processing on the weighted result to obtain the fusion coefficient of the short sliding window in the corresponding window combination.
7. An abnormal heart sound recognition method for early acute heart failure patients according to claim 4, characterized in that, The fusion vector of each window combination of each sample heart sound signal includes: For each window combination of each sample heart sound signal, respectively take the fusion coefficient as the weight of the feature vector of the short sliding window in the window combination, and the difference between the constant 1 and the fusion coefficient as the weight of the feature vector of the long sliding window in the window combination. Take half of the result of weighted summation of the feature vectors of the short sliding window and the long sliding window in the window combination as the fusion vector of the window combination.
8. An abnormal heart sound recognition method for early acute heart failure patients according to claim 1, characterized in that, Constructing a hidden Markov model based on the fusion vector of the window combination of the sample heart sound signal includes: Arrange the fusion vectors of all window combinations of each sample heart sound signal in sequence to obtain the feature sequence of each sample heart sound signal; input the feature sequences of all sample heart sound signals into a hidden Markov model to construct the hidden Markov model.
9. An abnormal heart sound recognition method for early acute heart failure patients according to claim 1, characterized in that, Determining window combinations based on the position distributions of two types of sliding windows on each sample heart sound signal includes: For each sample heart sound signal, calculate the time intervals between the middle moments of each short sliding window on the sample heart sound signal and all long sliding windows respectively, and form a window combination by the long sliding window corresponding to the smallest of the time intervals and each short sliding window.
10. The method for identifying abnormal heart sounds in patients with early acute heart failure according to claim 1, characterized in that, The types of the sliding windows include: long sliding windows and short sliding windows.
Citation Information
Patent Citations
Self-adaptive high-efficiency storage method of dynamic electrocardiogram (ECG) data
CN101773392A
System and method for detecting worsening of heart failure based on rapid shallow breathing index
CN105451648A