Personalized heart rate abnormity monitoring method based on LSTM
Through the personalized heart rate abnormality monitoring method based on LSTM, combined with the dynamic threshold adjustment module, the problem of failure to fully consider the individual heart rate change characteristics in the prior art is solved, and higher prediction accuracy and personalization are achieved, and the heart rate is detected in a timely manner. Abnormal and alert for potential health risks.
Patent Information
- Application Number
- CN202411233599.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-04
- Publication Date
- 2024-11-12
AI Technical Summary
The existing LSTM-based heart rate monitoring method fails to fully consider the individual's heart rate change characteristics, resulting in the improvement of prediction accuracy and personalization. It is difficult for traditional methods to accurately capture and predict the individual's heart rate change trend, resulting in the accuracy of heart rate abnormality monitoring. and lack of real-time.
Using a personalized heart rate abnormality monitoring method based on LSTM, the initial personalized prediction model is constructed by collecting user's heart rate data, and the model is continuously trained and optimized, combined with the dynamic threshold adjustment module, to adapt to the uncertainty of individual heart rate changes and improve monitoring sensitivity and accuracy.
It achieves higher accuracy and personalization of heart rate prediction, and can dynamically adjust the model to adapt to the user's heart rate change mode, improve the accuracy and sensitivity of heart rate abnormality monitoring, and promptly remind you of potential health risks.
Smart Images

Figure CN118924271A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to a method for monitoring abnormal heart rate, and in particular to a personalized method for monitoring abnormal heart rate based on LSTM. Background Art
[0002] As people's demand for health monitoring continues to increase, heart rate monitoring technology has received widespread attention as one of the important means of health management and disease prevention. Traditional heart rate monitoring methods mostly rely on monitoring equipment with fixed thresholds or simple data analysis algorithms, and cannot provide personalized and dynamic heart rate abnormality monitoring services. At the same time, there are differences in the heart rate change patterns of different groups of people. Traditional methods are difficult to accurately capture and predict the heart rate change trends of individuals, resulting in insufficient accuracy and real-time monitoring of heart rate abnormalities.
[0003] In recent years, with the rapid development of machine learning technology, especially the application of deep learning models such as long short-term memory network (LSTM), new solutions have been provided for abnormal heart rate monitoring. LSTM model has the ability to process time series data and can capture the time dependency and change trend in heart rate data, so as to predict heart rate data more accurately. However, most of the existing LSTM-based heart rate monitoring methods focus on general heart rate prediction models and fail to fully consider the individual heart rate change characteristics, resulting in the need to improve prediction accuracy and personalization. Summary of the invention
[0004] The purpose of the present invention is to solve the technical problem that the existing heart rate prediction model fails to fully consider the individual's heart rate change characteristics, and to provide a personalized heart rate abnormality monitoring method based on LSTM.
[0005] To solve the above technical problems, the technical solutions provided by the present invention are as follows:
[0006] A personalized heart rate abnormality monitoring method based on LSTM, applied to a heart rate monitoring instrument, comprises the following steps:
[0007] S1, collecting the user's heart rate data for a period of time through the data collection module, and converting it into historical time series heart rate data through the data preprocessing module;
[0008] S2, LSTM model identifies the heart rate change characteristics and heart rate change trends of historical time series heart rate data, and based on this training, obtains the initial personalized prediction model;
[0009] S3. The user's current heart rate data is collected through the data collection module, and converted into the current time series heart rate data through the data preprocessing module. The LSTM model identifies the heart rate change characteristics and the trend of the heart rate change of the current time series heart rate data, and trains the initial personalized prediction model based on this, so that the initial personalized prediction model evolves and obtains a personalized prediction model.
[0010] At the same time, the initial personalized prediction model outputs the predicted heart rate data corresponding to the current time based on the current time series heart rate data;
[0011] S4, the threshold dynamic adjustment module retrieves the historical heart rate data of the same time for multiple consecutive days, and arranges the historical heart rate data of the same time for multiple consecutive days from small to large;
[0012] Taking the median based on the arrangement, and finding the difference between the median and the remaining heart rate data, and taking the mode of the difference as the real-time threshold;
[0013] S5, the real-time monitoring module calculates the error between the user's current heart rate data and the predicted heart rate data, and determines whether the error exceeds the real-time threshold; if the error is within the real-time threshold, the real-time monitoring module determines that the current heart rate data is normal;
[0014] Otherwise, the real-time monitoring module determines that the current heart rate data is abnormal, and the abnormal alarm module issues an alarm.
[0015] Furthermore, step S1 is specifically as follows:
[0016] S1.1. Collect the user's heart rate data for a period of time through the data acquisition module, and transmit the heart rate data to the data preprocessing module;
[0017] S1.2. The heart rate data for a period of time is filtered and normalized through the data preprocessing module to generate historical time series heart rate data.
[0018] Furthermore, step S2 is specifically as follows:
[0019] S2.1, dividing the historical time series heart rate data into multiple segments of historical time series heart rate data according to time periods;
[0020] S2.2, input the segmented multiple historical time series heart rate data into the LSTM model;
[0021] S2.3, the LSTM model identifies the heart rate change characteristics of the historical time series heart rate data in each time period and captures the trend of heart rate change;
[0022] S2.4. Establishing an initial personalized prediction model corresponding to each time period according to the heart rate change trend and heart rate change characteristics of each time period;
[0023] S2.5. The initial personalized prediction model corresponding to each time period is combined to obtain an initial personalized prediction model;
[0024] S2.6. Repeat steps S2.1 to S2.5 multiple times, use the gradient descent method to optimize the initial personalized prediction model, and obtain the final initial personalized prediction model.
[0025] Furthermore, step S3 is specifically as follows:
[0026] S3.1. Collect the user's current heart rate data through the data acquisition module, and transmit the current heart rate data to the data preprocessing module;
[0027] S3.2, the data preprocessing module filters and normalizes the current heart rate data to generate the current time series heart rate data;
[0028] S3.3, the LSTM model identifies the heart rate change characteristics of the current time series heart rate data and captures the trend of heart rate change;
[0029] S3.4, the LSTM model trains the initial personalized prediction model according to the heart rate change characteristics and the trend of the heart rate change of the current time series heart rate data, realizes the evolution of the initial personalized prediction model and obtains the personalized prediction model;
[0030] At the same time, the initial personalized prediction model outputs the predicted heart rate data corresponding to the current time based on the current time series heart rate data.
[0031] Further, in steps S1 and S3, the data acquisition module includes a PPG sensor and a data transmission unit;
[0032] The PPG sensor collects the user's heart rate data for a period of time or current heart rate data, and transmits the heart rate data for a period of time or current heart rate data to the data preprocessing module through the data transmission unit.
[0033] Further, in steps S1 and S3, the data preprocessing module includes a low-pass filter and a normalization processing module;
[0034] The low-pass filter filters the heart rate data for a period of time or the current heart rate data; the filtered heart rate data for a period of time or the current heart rate data is normalized by the normalization processing module to obtain the historical time series heart rate data or the current time series heart rate data.
[0035] Further, in step S2, the time periods include 0:00-3:00 in the morning, 3:00-6:00 at dawn, 6:00-8:00 in the morning, 8:00-10:00 in the morning, 10:00-12:00 in the morning, 12:00-14:00 in the afternoon, 14:00-16:00 in the afternoon, 16:00-18:00 in the evening, 18:00-20:00 in the evening, 20:00-22:00 at night and 22:00-24:00 at night.
[0036] Compared with the prior art, the present invention has the following beneficial effects:
[0037] The LSTM-based personalized heart rate abnormality monitoring method provided by the present invention collects historical heart rate data of users and uses the LSTM model for training to build a personalized heart rate prediction model. The model can fully consider the individual's heart rate change characteristics and improve the accuracy and personalization of heart rate prediction; and can also continuously collect the user's current heart rate data and use these data to train and optimize the personalized prediction model in real time to achieve model evolution. This mechanism enables the model to be dynamically adjusted as the user's heart rate change pattern changes to maintain the stability of the prediction performance; a dynamic threshold adjustment module is used to calculate and adjust the real-time threshold according to the user's historical heart rate data at the same time for multiple consecutive days; this dynamic adjustment mechanism can better adapt to the uncertainty of individual heart rate changes and improve the sensitivity and accuracy of heart rate abnormality monitoring; the error between the user's current heart rate data and the predicted heart rate data is calculated by the real-time monitoring module, and whether the heart rate data is abnormal is judged based on the dynamic threshold. Once abnormal heart rate data is detected, an alarm mechanism is immediately triggered to promptly remind the user or medical personnel to pay attention to heart rate changes and avoid potential health risks. BRIEF DESCRIPTION OF THE DRAWINGS
[0038] Figure 1 This is a schematic diagram of a process of Embodiment 1 of the present invention;
[0039] Figure 2 This is a schematic diagram of the structure of the LSTM model in the first embodiment of the present invention;
[0040] Figure 3 This is a schematic diagram of comparison before and after preprocessing of historical heart rate data in the first embodiment of the present invention;
[0041] Figure 4 This is a schematic diagram of reducing the loss of the LSTM model using the gradient descent method in Embodiment 1 of the present invention;
[0042] Figure 5 This is a comparison chart of current heart rate data and predicted heart rate data in Example 1 of the present invention. DETAILED DESCRIPTION
[0043] The technical solutions in the present invention will be described clearly and completely below in conjunction with the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0044] Embodiment 1
[0045] like Figure 1 As shown in Figure 1, a personalized heart rate abnormality monitoring method based on LSTM is applied to a heart rate monitoring bracelet. Figure 2 As shown in the figure, the LSTM model includes an input layer, an LSTM layer, a fully connected layer and an output layer; wherein the input layer is used to receive the time series heart rate data preprocessed by the data preprocessing module and use it as input; the LSTM layer (long short-term memory layer) is composed of multiple LSTM units, which is used to learn the characteristics of the time series heart rate data and capture the trend of heart rate changes; the fully connected layer is used to linearly transform the features output by the LSTM layer to generate predicted heart rate data; the output layer is used to output the predicted heart rate data and the real-time threshold for real-time monitoring and abnormal alarm.
[0046] The specific steps are as follows:
[0047] (1) collecting the user's heart rate data for a period of time through the data collection module, and transmitting the user's heart rate data for a period of time to the data preprocessing module;
[0048] (2) Figure 3 As shown, the user's heart rate data for a period of time is filtered and normalized through the data preprocessing module to generate historical time series heart rate data;
[0049] (3) dividing the historical time series heart rate data into multiple segments of historical time series heart rate data according to time periods;
[0050] The time periods include 0:00-3:00 in the morning, 3:00-6:00 at dawn, 6:00-8:00 in the morning, 8:00-10:00 in the morning, 10:00-12:00 in the morning, 12:00-14:00 in the afternoon, 14:00-16:00 in the afternoon, 16:00-18:00 in the evening, 18:00-20:00 in the evening, 20:00-22:00 in the evening and 22:00-24:00 in the night;
[0051] The time period can also be refined to every minute or even every second. According to different application scenarios, different time periods can be selected for model training and prediction;
[0052] (4) Input the segmented multiple historical time series heart rate data into the LSTM model;
[0053] (5) The LSTM model identifies the heart rate change characteristics of the historical time series heart rate data in each time period and captures the trend of heart rate change;
[0054] (6) establishing an initial personalized prediction model corresponding to each time period according to the heart rate change trend and heart rate change characteristics of each time period;
[0055] (7) The initial personalized prediction models corresponding to each time period are combined to obtain a personalized prediction model;
[0056] (8) Figure 4 As shown, repeat steps S2.1 to S2.5 multiple times, use the gradient descent method to optimize the initial personalized prediction model, and obtain the final initial personalized prediction model;
[0057] (9) collecting the user's current heart rate data through the data collection module, and transmitting the current heart rate data to the data preprocessing module;
[0058] (10) The data preprocessing module filters and normalizes the current heart rate data to generate the current time series heart rate data;
[0059] (11) The LSTM model identifies the heart rate change characteristics of the current time series heart rate data and captures the trend of heart rate changes;
[0060] (12) The LSTM model trains the initial personalized prediction model according to the heart rate change characteristics and the trend of the heart rate change of the current time series heart rate data, realizes the evolution of the initial personalized prediction model, and obtains the personalized prediction model;
[0061] At the same time, the initial personalized prediction model outputs the predicted heart rate data corresponding to the current time based on the current time series heart rate data;
[0062] (13) The threshold dynamic adjustment module retrieves the historical heart rate data at the same time for multiple consecutive days, and arranges the historical heart rate data at the same time for multiple consecutive days from small to large;
[0063] Taking the median based on the arrangement, and finding the difference between the median and the remaining heart rate data, and taking the mode of the difference as the real-time threshold;
[0064] (14) Figure 5 As shown, the real-time monitoring module calculates the error between the user's current heart rate data and the predicted heart rate data, and determines whether the error exceeds the real-time threshold; if the error is within the real-time threshold, the real-time monitoring module determines that the current heart rate data is normal;
[0065] Otherwise, the real-time monitoring module determines that the current heart rate data is abnormal, and the abnormal alarm module issues an alarm.
[0066] In the first embodiment, the data acquisition module includes a PPG sensor and a data transmission unit; the PPG sensor collects the user's heart rate data for a period of time or the current heart rate data, and transmits the heart rate data for a period of time or the current heart rate data to the data preprocessing module through the data transmission unit.
[0067] The data preprocessing module includes a low-pass filter and a normalization processing module; the low-pass filter filters the heart rate data for a period of time or the current heart rate data; the filtered heart rate data for a period of time or the current heart rate data is normalized by the normalization processing module to obtain the historical time series heart rate data or the current time series heart rate data.
[0068] Embodiment 2
[0069] The difference between Example 2 and Example 1 is that GRU (Gated Recurrent Unit) is used instead of LSTM model; Gated Recurrent Unit (GRU) is an improved recurrent neural network (RNN) structure with similar memory capacity to LSTM model, but with relatively simple structure and higher computational efficiency.
[0070] GRU is used instead of LSTM model for personalized modeling and anomaly detection of heart rate data. The GRU model can learn the characteristics of time series data, capture the trend and pattern of heart rate changes, and generate prediction values and real-time thresholds for each time period.
[0071] By using GRU, the system can further improve computational efficiency and reduce hardware requirements while maintaining high accuracy, making it suitable for devices with limited resources.
[0072] Embodiment 3
[0073] Compared with Example 1, Example 3 differs in that: since a single LSTM model may have limitations in some cases, the robustness and detection performance of the system can be improved by combining multiple machine learning models; therefore, Example 3 combines multiple machine learning models such as LSTM, Random Forest, and Support Vector Machine (SVM) to perform personalized modeling and anomaly detection of heart rate data. Different models can analyze heart rate data from different angles and provide more comprehensive detection results.
[0074] Through model fusion, the system can combine the advantages of each model, improve the accuracy and reliability of abnormal heart rate detection, and reduce false positives and negative negatives.
[0075] Embodiment 4
[0076] The difference between Example 4 and Example 1 is that a hybrid architecture of cloud computing and edge computing is used to replace the data preprocessing module and the LSTM model, the preprocessing and preliminary detection of heart rate data are performed on the device side, and complex model training and data analysis are performed on the cloud. Real-time monitoring and anomaly detection results are quickly fed back to users through edge computing devices.
[0077] The hybrid architecture can fully leverage the advantages of cloud and edge computing to achieve efficient data processing and real-time detection, and improve user experience and system performance.
[0078] Embodiment 5
[0079] The difference between Example 5 and Example 1 is that a graph convolutional network (GCN) is used to replace the LSTM model; the graph convolutional network (GCN) is a neural network model for processing graph structured data, which can effectively capture the relationship and dependency between data.
[0080] The heart rate data is modeled using a graph convolutional network (GCN). By constructing the spatiotemporal graph structure of the heart rate data and learning the complex dependencies between the data, the accuracy of heart rate anomaly detection is improved.
[0081] By modeling with GCN, the system can capture more complex relationships and dependencies in heart rate data, improving detection performance and accuracy.
[0082] The above is only a specific embodiment of the present invention, but the protection scope of the present invention is not limited thereto. Any changes or substitutions within the technical scope disclosed by the present invention should be included in the protection scope of the present invention. Therefore, the protection scope of the present invention should be based on the protection scope of the claims.
Claims
1. A personalized heart rate abnormality monitoring method based on LSTM, applied to a heart rate monitoring instrument, characterized in that: The steps include: S1, collecting the user's heart rate data for a period of time through the data collection module, and converting it into historical time series heart rate data through the data preprocessing module; S2, LSTM model identifies the heart rate change characteristics and heart rate change trends of historical time series heart rate data, and based on this training, obtains the initial personalized prediction model; S3. The user's current heart rate data is collected through the data collection module, and converted into the current time series heart rate data through the data preprocessing module. The LSTM model identifies the heart rate change characteristics and the trend of the heart rate change of the current time series heart rate data, and trains the initial personalized prediction model based on this, so that the initial personalized prediction model evolves and obtains a personalized prediction model. At the same time, the initial personalized prediction model outputs the predicted heart rate data corresponding to the current time based on the current time series heart rate data; S4, the threshold dynamic adjustment module retrieves the historical heart rate data of the same time for multiple consecutive days, and arranges the historical heart rate data of the same time for multiple consecutive days from small to large; Based on the arrangement, the median is taken, and the difference between the median and the remaining heart rate data is calculated, and the mode of the difference is used as the real-time threshold; S5, the real-time monitoring module calculates the error between the user's current heart rate data and the predicted heart rate data, and determines whether the error exceeds the real-time threshold; if the error is within the real-time threshold, the real-time monitoring module determines that the current heart rate data is normal; Otherwise, the real-time monitoring module determines that the current heart rate data is abnormal, and the abnormal alarm module issues an alarm.
2. The LSTM-based personalized heart rate abnormality monitoring method according to claim 1, characterized in that: Step S1 is specifically as follows: S1.
1. Collect the user's heart rate data for a period of time through the data acquisition module, and transmit the heart rate data to the data preprocessing module; S1.
2. The heart rate data for a period of time is filtered and normalized through the data preprocessing module to generate historical time series heart rate data.
3. The LSTM-based personalized heart rate abnormality monitoring method according to claim 1, characterized in that: Step S2 is specifically as follows: S2.1, dividing the historical time series heart rate data into multiple segments of historical time series heart rate data according to time periods; S2.2, input the segmented multiple historical time series heart rate data into the LSTM model; S2.3, the LSTM model identifies the heart rate change characteristics of the historical time series heart rate data in each time period and captures the trend of heart rate change; S2.
4. Establishing an initial personalized prediction model corresponding to each time period according to the heart rate change trend and heart rate change characteristics of each time period; S2.
5. The initial personalized prediction model corresponding to each time period is combined to obtain an initial personalized prediction model; S2.
6. Repeat steps S2.1 to S2.5 multiple times, use the gradient descent method to optimize the initial personalized prediction model, and obtain the final initial personalized prediction model.
4. The personalized heart rate abnormality monitoring method based on LSTM according to claim 1 is characterized in that: Step S3 is specifically as follows: S3.
1. Collect the user's current heart rate data through the data acquisition module, and transmit the current heart rate data to the data preprocessing module; S3.2, the data preprocessing module filters and normalizes the current heart rate data to generate the current time series heart rate data; S3.3, the LSTM model identifies the heart rate change characteristics of the current time series heart rate data and captures the trend of heart rate change; S3.4, the LSTM model trains the initial personalized prediction model according to the heart rate change characteristics and the trend of the heart rate change of the current time series heart rate data, realizes the evolution of the initial personalized prediction model and obtains the personalized prediction model; At the same time, the initial personalized prediction model outputs the predicted heart rate data corresponding to the current time based on the current time series heart rate data.
5. The personalized heart rate abnormality monitoring method based on LSTM according to claim 1, characterized in that: In steps S1 and S3, the data acquisition module includes a PPG sensor and a data transmission unit; The PPG sensor collects the user's heart rate data for a period of time or current heart rate data, and transmits the heart rate data for a period of time or current heart rate data to the data preprocessing module through the data transmission unit.
6. The LSTM-based personalized heart rate abnormality monitoring method according to claim 5, characterized in that: In steps S1 and S3, the data preprocessing module includes a low-pass filter and a normalization processing module; The low-pass filter filters the heart rate data for a period of time or the current heart rate data; the filtered heart rate data for a period of time or the current heart rate data is normalized by the normalization processing module to obtain the historical time series heart rate data or the current time series heart rate data.
7. The personalized heart rate abnormality monitoring method based on LSTM according to claim 3 is characterized in that: In step S2, the time periods include 0:00-3:00 in the morning, 3:00-6:00 at dawn, 6:00-8:00 in the morning, 8:00-10:00 in the morning, 10:00-12:00 in the morning, 12:00-14:00 in the afternoon, 14:00-16:00 in the afternoon, 16:00-18:00 in the evening, 18:00-20:00 in the evening, 20:00-22:00 at night and 22:00-24:00 in the middle of the night.
Citation Information
Cited By
Online management platform for nursing data of patients with cardiovascular diseases
CN119993464A
