Method and device for detecting sleep rhythm disorder based on long-range signal and multi-feature extraction
By using a method based on long-range signals and multi-feature extraction, using wearable devices to collect physiological signals and constructing a random forest algorithm model, the shortcomings of existing technologies in predicting sleep rhythm disorder risks are solved, and real-time, accurate and personalized risk warning and prevention are achieved.
Patent Information
- Application Number
- CN202411849683.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-16
- Publication Date
- 2025-10-21
- Estimated Expiration
- 2044-12-16
AI Technical Summary
Existing medical devices and wearable smart devices lack efficient data processing and analysis capabilities in predicting the risk of sleep rhythm disorders, are unable to provide real-time and accurate risk warnings, and fail to conduct personalized assessments based on individual sleep rhythm types, resulting in the inability to effectively predict and prevent health and safety issues caused by sleep disorders.
Through a method based on long-range signals and multi-feature extraction, wearable electronic devices are used to collect physiological signals, perform preprocessing and peak extraction, and combine multi-domain heart rate variability characteristics and individual MEQ types to construct a sleep rhythm state assessment model based on the random forest algorithm to detect potential sleep rhythm disorders.
It realizes real-time detection in long-term sleep state, improves the accuracy of rhythm disorder risk prediction, reduces the workload of physiological signal collection, and predicts individual potential disorders in life and work, optimizes work performance and improves safety.
Smart Images

Figure CN120000155B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of medical signal processing, and in particular to a sleep rhythm disorder detection method and device based on long-range signals and multi-feature extraction. Background Art
[0002] Human physiological activities follow a cyclical pattern, such as sleep, wakefulness, heart rate, mood, and cognition, and exhibit regular variations throughout the day and night cycle. This circadian rhythm is the body's adaptive response to its living environment, with sleep and wakefulness being the most fundamental rhythmic characteristics of all physiological fluctuations. However, with the development of society, the accelerated pace of life, and increasing competitive pressures, prolonged stress can lead to sleep rhythm disruptions. These disruptions manifest as sleep and wake times that are out of sync with the natural circadian rhythm, or as non-physiological sleep phenomena such as difficulty falling asleep, insufficient sleep, or sleep phase disturbances. Sleep rhythm disruptions can seriously impact physical and mental health, work performance, and quality of life, and are closely linked to the onset of many acute and chronic diseases. Long-term sleep disruptions can lead to emotional distress, physical and mental fatigue, weakened immunity, and decreased concentration and performance. In high-risk industries, this can lead to cognitive impairments such as impaired judgment and operational errors, resulting in accidents and fatalities.
[0003] Currently, most existing medical devices and wearable smart devices only provide a quantitative display of sleep rhythms for predicting sleep rhythm disorders. These devices often require manual estimation and analysis, lacking efficient data processing and analysis capabilities. Consequently, they are unable to provide real-time and more accurate warnings of sleep rhythm disorder risks. Furthermore, existing methods fail to personalize sleep rhythm assessments based on individual sleep patterns. Furthermore, the massive amount of physiological signal data collected continuously poses significant challenges to signal processing, necessitating an urgent need for a method to predict sleep rhythm disorder risks over long periods of time. Summary of the Invention
[0004] The purpose of the present invention is to provide a method and device for detecting sleep rhythm disorders based on long-range signals and multi-feature extraction.
[0005] The purpose of the present invention can be achieved by the following technical solutions:
[0006] A sleep rhythm disorder detection method based on long-range signals and multi-feature extraction, comprising:
[0007] Step S1: Obtaining physiological signals of a target user, wherein the physiological signals at least include a heart rate;
[0008] Step S2: preprocessing and peak extraction of the physiological signal;
[0009] Step S3: extracting multi-domain heart rate variability features based on the pre-processed physiological signal using a multi-domain feature extraction algorithm according to the processed signal;
[0010] Step S4: constructing a multi-domain feature set and classifying rhythm disorder risk categories based on the extracted multi-domain heart rate variability features;
[0011] Step S5: Use the random forest algorithm to build a sleep rhythm state assessment model to detect potential sleep rhythm disorder risks.
[0012] The physiological signals are collected through wearable electronic devices.
[0013] The preprocessing process in step S2 is to use a bandpass filter to remove high-frequency and low-frequency noise in the collected physiological signals.
[0014] The multi-domain heart rate variability features include HRV time domain features, HRV frequency domain features and HRV nonlinear features. The HRV nonlinear features include heart rate asymmetry features, Pompeii diagram features and multiple entropy complexities.
[0015] The Pompeii diagram features include the Pompeii diagram semi-major axis SD1, the semi-minor axis SD2, and the ratio of the major semi-axis to the minor semi-axis SD1 / SD2;
[0016] The multiple entropy complexities include approximate entropy ApEn, sample entropy SampE, fuzzy entropy FuzzyEn, fuzzy metric entropy FuzzyMEn and distribution entropy DistEn;
[0017] The heart rate asymmetry characteristics include: Porta index, Guzik index, slope index and area index.
[0018] The step S4 comprises:
[0019] The extracted multi-domain heart rate variability features and individual MEQ types are combined to construct a multi-domain feature set D, and the feature set is preprocessed, wherein the preprocessing process of the feature set includes processing missing values and normalizing features.
[0020] The MEQ type of the individual is a sleep rhythm type, including: an early bird type that tends to go to bed early, an owl type that tends to go to bed late, and an intermediate type.
[0021] The method for constructing the sleep rhythm state assessment model includes:
[0022] The Gini index is selected as the splitting criterion to construct a decision tree, where the Gini index Gini(D,a) of each feature of the data set is calculated as follows:
[0023]
[0024] Among them, p k is the probability of different rhythm disorder risk categories in the data set, n is the number of rhythm disorder risk categories, Gini (D v ) is the Gini coefficient for each feature, a represents the feature category, D v is the feature set segmented based on feature a;
[0025] Starting from the root node, the Gini index of all features is calculated, and the feature with the smallest Gini index and its corresponding value are selected as the optimal feature and optimal threshold; based on the selected optimal feature and optimal threshold, the data set is divided into two subsets, and then the above steps are recursively repeated for each subset, that is, another optimal feature and its threshold are selected for further division until the stopping condition is met, wherein the stopping condition includes: all samples belong to the same class, there are no available features for further division, the preset maximum tree depth is reached, or the number of samples in the subset is less than the preset threshold.
[0026] The method for constructing the sleep rhythm state assessment model further includes:
[0027] The feature set is randomly divided according to a preset ratio to obtain a training set and a test set. The test set is input into the trained sleep rhythm state assessment model for result prediction. The sleep rhythm state assessment model is constructed by an integrated decision tree, and the model accuracy is evaluated using accuracy, confusion matrix and ten-fold cross validation.
[0028] A sleep rhythm disorder detection device based on long-range signal and multi-feature extraction includes a memory, a processor, and a program stored in the memory, characterized in that the processor implements the above-mentioned method when executing the program.
[0029] Compared with the prior art, the present invention has the following beneficial effects:
[0030] 1. Monitoring and analyzing the target user's sleep rhythm based on long-range signals helps to capture potential rhythm disorders in real time during long-term sleep, reducing the workload of frequently collecting physiological signals.
[0031] 2. This method extracts multiple features from long-range signals and analyzes the risk of rhythm disorders from multiple perspectives. It combines multi-domain heart rate variability characteristics and individual MEQ types, especially the introduction of heart rate asymmetry features, Pompeii diagram features and multiple entropy complexities into multi-domain heart rate variability features, which greatly improves the accuracy of rhythm disorder risk prediction.
[0032] 3. Applied in daily life and work, it can help predict an individual's potential rhythm disorder. On the one hand, it can effectively discover an individual's potential rhythm disorder and reduce the physical and mental health problems caused by rhythm disorder; on the other hand, it can optimize the work performance of workers in production operations and improve safety, and reduce accidents caused by fatigue and inattention caused by rhythm disorder. BRIEF DESCRIPTION OF THE DRAWINGS
[0033] Figure 1 Schematic diagram of the main steps of the method of the present invention;
[0034] Figure 2 It is a scatter plot of RP interval. DETAILED DESCRIPTION
[0035] The present invention is described in detail below with reference to the accompanying drawings and specific embodiments. This embodiment is implemented based on the technical solution of the present invention, and provides a detailed implementation method and specific operation process, but the protection scope of the present invention is not limited to the following embodiments.
[0036] A sleep rhythm disorder detection method based on long-range signals and multi-feature extraction, such as Figure 1 Shown, including:
[0037] Step S1: Obtaining physiological signals of a target user, wherein the physiological signals at least include a heart rate;
[0038] Physiological signals are collected through wearable electronic devices. Generally, wearable electronic devices can use non-invasive electronic devices such as electrocardiogram patches and pulse sensors to collect physiological data of the target user in real time. Specifically, the physiological signal is mainly heart rate, which can also be combined with pulse data. Of course, in some embodiments, the pulse sensor can use a blood oxygen pulse sensor.
[0039] Step S2: preprocessing and peak extraction of physiological signals;
[0040] The preprocessing process is to use a bandpass filter to remove high-frequency and low-frequency noise in the collected physiological signals. The specific process includes: setting a bandpass filter with a frequency range of 0.5HZ to 4HZ to remove low-frequency and high-frequency noise in the collected physiological signals.
[0041] In addition, in this embodiment, peak feature extraction is performed on the processed data using the Pan-Tompkins algorithm;
[0042] Step S3: extracting multi-domain heart rate variability features based on the pre-processed physiological signal using a multi-domain feature extraction algorithm according to the processed signal;
[0043] Multi-domain heart rate variability features include HRV time domain features, HRV frequency domain features and HRV nonlinear features. HRV nonlinear features include heart rate asymmetry features, Pompeii diagram features and multiple entropy complexities.
[0044] HRV time domain features include the standard deviation of the normal sinus RR interval (SDNN), the root mean square value (RMSSD) of the difference between adjacent RR intervals, and the percentage (pNN) of the number of adjacent RR intervals with a difference greater than 50ms in the total number of RR intervals. 50 The specific calculation method is:
[0045]
[0046]
[0047] Where: N is the total number of normal heartbeats in the whole recording, meanRR is the average value of the RR interval of N heartbeats; RR i , RRi+1 is the length of two adjacent sinus cardiac cycles; NN 50 is the number of adjacent RR intervals with a difference greater than 50ms in the full record, and N is the total number of RR intervals.
[0048] HRV frequency domain characteristics include total power TP, low frequency power LF, high frequency power HF and low frequency / high frequency ratio LF / HF, etc. The specific calculation method is as follows;
[0049] The AR model power spectrum analysis of the RR interval series was performed, and the area within the range of 0-0.4 Hz was the total power TP. The area within the range of 0.04-0.15 Hz was the low-frequency power LF, and the area within the range of 0.15-0.4 Hz was the high-frequency power HF.
[0050] The characteristics of the Pompeii chart include the semi-major axis SD1, the semi-minor axis SD2, and the ratio of the major and minor axes SD1 / SD2. The specific calculation method is:
[0051]
[0052] Where: X={x i |i=1..N},Y={y i |i=1..N}, (xi,yi) are the coordinates of the points in the Pompey scatter plot;
[0053] Various entropy complexities include approximate entropy ApEn, sample entropy SampE, fuzzy entropy FuzzyEn, fuzzy metric entropy FuzzyMEn and distribution entropy DistEn;
[0054] Characteristics of heart rate asymmetry include: Porta index, Guzik index, slope index and area index.
[0055] For the RR interval (RR1, RR2, ..., RR i ,RR i+1 ,…,RR n-1 ,RR n ),like Figure 2 The figure shows the algorithm of the heart rate asymmetry index implemented by the following formula, where LI is the identification line y=x, P i is the i-th point, which can be expressed as (RR i ,RR i+1 ), ΔRR=RR i+1 -RR i , D i Represents P i The distance to LI, the angle between the origin and the horizontal coordinate is expressed as θ i , the phase angle between the horizontal axis and LI is θ LI :
[0056] For the Porta Index, or PI for short, the PI measurement is proportional to the number of points below the LI. The formula for calculating PI is:
[0057]
[0058] Where: b and m represent the number of points below L1 and not on L1 respectively;
[0059] For the Guzik index, abbreviated as GI, GI is the ratio of the cumulative distances corresponding to points, which can be calculated as follows:
[0060]
[0061] The slope index, abbreviated as SI, evaluates the percentage of the cumulative phase angle above LI and can be calculated as follows:
[0062]
[0063] Where: R θi =θ LI -θ i
[0064] For the area index, abbreviated as AI, the area of the i-th sector is expressed as:
[0065]
[0066] Where: r is the distance from Pi to the origin of the coordinate system
[0067] Then, AI is defined as the ratio of Si to LI. The formula for AI is:
[0068]
[0069] Step S4: constructing a multi-domain feature set and classifying rhythm disorder risk categories based on the extracted multi-domain heart rate variability features, including:
[0070] The extracted multi-domain heart rate variability features and individual MEQ types are combined to construct a multi-domain feature set D, and the feature set is preprocessed. The preprocessing process of the feature set includes handling missing values and normalizing features. In this embodiment, z-score standardization is used to normalize the data, and the data are all within the range of [-1, 1].
[0071] An individual's MEQ type is the sleep rhythm type, including: early bird type (who tends to go to bed early), owl type (who tends to go to bed late), and intermediate type.
[0072] In this example, individual rhythm disorder risk categories are divided according to their PSQI scores. PSQI scores above 8 indicate high rhythm disorder risk, and PSQI scores below 8 indicate low rhythm disorder risk.
[0073] Step S5: Use the random forest algorithm to build a sleep rhythm state assessment model to detect potential sleep rhythm disorder risks.
[0074] The methods for constructing the sleep rhythm state assessment model include:
[0075] The Gini index is selected as the splitting criterion to construct a decision tree, where the Gini index Gini(D,a) of each feature of the data set is calculated as follows:
[0076]
[0077]
[0078] Among them, p k is the probability of different rhythm disorder risk categories in the data set, n is the number of rhythm disorder risk categories, Gini (D v ) is the Gini coefficient for each feature, a represents the feature category, D v is the feature set segmented based on feature a;
[0079] Starting from the root node, calculate the Gini index of all features, select the feature with the smallest Gini index and its corresponding value as the optimal feature and optimal threshold; divide the data set into two subsets based on the selected optimal feature and optimal threshold, and then recursively repeat the above steps for each subset, that is, select another optimal feature and its threshold for further division until the stopping condition is met, where the stopping condition includes: all samples belong to the same class, there are no available features for further division, the preset maximum tree depth is reached, or the number of samples in the subset is less than the preset threshold.
[0080] The method for constructing the sleep rhythm state assessment model also includes:
[0081] The feature set is randomly divided into training and test sets according to a preset ratio. The test set is input into the trained sleep rhythm state assessment model for result prediction. The sleep rhythm state assessment model is constructed by integrating decision trees, and the model accuracy is evaluated using accuracy, confusion matrix and ten-fold cross validation.
[0082] The random forest model in this example repeats the above decision tree construction process 100 times to generate 100 decision trees. The 100 constructed decision trees form a random forest. The mode of the data predicted by the 100 decision trees is used as the final output of the random forest prediction model.
[0083] In this example, the multi-domain feature set is divided into a training set and a test set at a ratio of 7:3, the test set is substituted into the random forest model for result prediction, and the accuracy rate, confusion matrix and ten-fold cross validation are used to evaluate the model accuracy.
[0084] If the above functions are implemented in the form of software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, or the part that contributes to the prior art, or the part of the technical solution, can be embodied in the form of a software product. The computer software product is stored in a storage medium and includes several instructions for enabling a computer device (which can be a personal computer, server, or network device, etc.) to execute all or part of the steps of the method described in each embodiment of the present invention. The aforementioned storage medium includes: various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk.
Claims
1. A sleep rhythm disorder detection method based on long-range signal and multi-feature extraction, characterized in that: include: Step S1: Obtaining physiological signals of a target user, wherein the physiological signals at least include a heart rate; Step S2: preprocessing and peak extraction of the physiological signal; Step S3: extracting multi-domain heart rate variability features based on the pre-processed physiological signal using a multi-domain feature extraction algorithm according to the processed signal; Step S4: constructing a multi-domain feature set and classifying rhythm disorder risk categories based on the extracted multi-domain heart rate variability features; Step S5: Using the random forest algorithm to construct a sleep rhythm state assessment model to detect potential sleep rhythm disorder risks; The multi-domain heart rate variability features include HRV time domain features, HRV frequency domain features and HRV nonlinear features, and the HRV nonlinear features include heart rate asymmetry features, Pompeii diagram features and multiple entropy complexities; The Pompeii diagram features include the Pompeii diagram semi-major axis SD1, the semi-minor axis SD2, and the ratio of the major semi-axis to the minor semi-axis SD1 / SD2; The multiple entropy complexities include approximate entropy ApEn, sample entropy SampE, fuzzy entropy FuzzyEn, fuzzy metric entropy FuzzyMEn and distribution entropy DistEn; The heart rate asymmetry characteristics include Porta index, Guzik index, slope index and area index; The step S4 comprises: Combining the extracted multi-domain heart rate variability features and the individual MEQ type to construct a multi-domain feature set D, and preprocessing the feature set, wherein the preprocessing process of the feature set includes processing missing values and normalizing features; The MEQ type of the individual is the sleep rhythm type, including: early bird type (who tends to go to bed early), owl type (who tends to go to bed late), and intermediate type; The method for constructing the sleep rhythm state assessment model includes: The Gini index is selected as the splitting criterion to build a decision tree, where the Gini index of each feature of the data set is Gini ( D , a ) is calculated as follows: in, p k is the probability of different rhythm disorder risk categories in the data set, n is the number of categories of rhythm disturbance risk, Gini ( D v ) is the Gini coefficient under each feature, a Denotes the feature category, D v Feature-based a The next segmented feature set; Starting from the root node, calculate the Gini index of all features, select the feature with the smallest Gini index and its corresponding value as the optimal feature and optimal threshold; Based on the selected optimal feature and optimal threshold, the dataset is divided into two subsets, and then the above steps are recursively repeated for each subset, that is, another optimal feature and its threshold are selected for further division until the stopping condition is met, where the stopping condition includes: all samples belong to the same class, there are no available features for further division, the preset maximum tree depth is reached, or the number of samples in the subset is less than the preset threshold.
2. The sleep rhythm disorder detection method based on long-range signal and multi-feature extraction according to claim 1, characterized in that: The physiological signals are collected through wearable electronic devices.
3. The sleep rhythm disorder detection method based on long-range signal and multi-feature extraction according to claim 1, characterized in that: The preprocessing process in step S2 is to use a bandpass filter to remove high-frequency and low-frequency noise in the collected physiological signals.
4. The sleep rhythm disorder detection method based on long-range signal and multi-feature extraction according to claim 1, characterized in that: The method for constructing the sleep rhythm state assessment model further includes: The feature set is randomly divided according to a preset ratio to obtain a training set and a test set. The test set is input into the trained sleep rhythm state assessment model for result prediction. The sleep rhythm state assessment model is constructed by an integrated decision tree, and the model accuracy is evaluated using accuracy, confusion matrix and ten-fold cross validation.
5. A sleep rhythm disorder detection device based on long-range signal and multi-feature extraction, comprising a memory, a processor, and a program stored in the memory, characterized in that: When the processor executes the program, the method according to any one of claims 1 to 4 is implemented.
Citation Information
Patent Citations
Construction method and device of sleep state discrimination model, and portable intelligent device
CN109841284A
Sleep stage staging method and system based on feature overlapping and generalized decision forest
CN115844335A