Body movement artifact detection method, device and equipment
By sliding window segmentation and energy threshold division of the original sign signal, body movement artifacts are identified and marked, the problem of inaccurate body movement artifacts in the prior art is solved, and higher adaptability and accuracy are achieved.
Patent Information
- Application Number
- CN202510171809.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-02-17
- Publication Date
- 2025-06-06
AI Technical Summary
The prior art is difficult to effectively identify and mark body artifacts, resulting in interference in the analysis of heartbeat or respiratory activity, and methods based on fixed thresholds are difficult to adapt to changing environments.
By collecting the original sign signal, performing sliding window segments, dividing the sign signal segments based on the energy threshold, determining whether there is a target body movement signal, obtaining the duration and generating a signal spectrum to improve detection accuracy.
The adaptability and accuracy of body movement artifact detection is improved, the calculation amount of subsequent detection is reduced, and the starting and ending positions of body movement artifacts can be more accurately identified.
Smart Images

Figure CN120093323A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of signal processing, and in particular to a method, device and equipment for detecting body motion artifacts. Background Art
[0002] At present, non-intrusive devices are usually used to monitor users' long-term sleep vital signs. However, the vital sign signals collected by non-intrusive devices appear in the form of aliased signals, which include ballistocardiogram (BCG), respiratory signals, and body motion artifacts. When analyzing heartbeat or respiratory activity, the presence of body motion artifacts will mask the morphology of the above two vital sign signals, so it is necessary to identify and mark the body motion artifacts.
[0003] In the related art, the signal is usually classified into two categories, normal signal or body motion artifact, based on the statistical index threshold judgment method. However, it is difficult to adapt to the changing environment based on the fixed threshold.
[0004] In view of this, a body motion artifact detection method with strong adaptability and high accuracy is needed. Summary of the invention
[0005] In view of this, the present invention provides a body motion artifact detection method, which can improve the adaptability and accuracy of body motion artifact recognition.
[0006] In a first aspect, the present invention provides a method for detecting body motion artifacts, the method comprising: collecting original vital sign signals, and performing sliding window segmentation on the original vital sign signals to obtain a vital sign signal sequence, the vital sign signal sequence comprising a plurality of vital sign signal segments; dividing the vital sign signal segments in the vital sign signal sequence based on an energy threshold to obtain a division result, and based on the division result, judging whether there is a target body motion signal in the vital sign signal segment; in the case that there is a target body motion signal in the vital sign signal segment, obtaining the duration of the target body motion signal; in the case that the duration is greater than a first target time period, obtaining a signal spectrum of the target body motion signal to generate a detection result of the target body motion signal.
[0007] In this embodiment, the original vital sign signal is collected, and the original vital sign signal is segmented by sliding window to obtain a vital sign signal sequence; then, based on the energy threshold, the vital sign signal segment in the vital sign signal sequence is divided to determine whether there is a target body motion signal in the vital sign signal segment. In the case where the target body motion signal exists in the vital sign signal segment, the duration of the target body motion signal is obtained; in the case where the duration is greater than the first target time period, the signal spectrum of the target body motion signal is obtained to generate a detection result of the target body motion signal. Through the above scheme, by performing sliding window segmentation on the original vital sign signal, the computational memory required by the method can be reduced. Based on the energy threshold, the vital sign signal segment in the vital sign signal sequence is divided to obtain the division result, and the vital sign signal segment with the target body motion signal can be quickly screened out. Then, the target body motion signal is screened based on the duration, which can reduce the amount of calculation for subsequent detection. Finally, the signal spectrum of the target body motion signal whose duration is greater than the first target time period is obtained to generate the detection result of the target body motion signal, which can improve the accuracy of body motion artifact detection.
[0008] In an optional embodiment, the original vital sign signal is subjected to sliding window segmentation to obtain a vital sign signal sequence, including: determining the size of the sliding window and the sliding step; placing the sliding window at the target position of the original vital sign signal, and segmenting the original vital sign signal based on the sliding step; and constructing a vital sign signal sequence based on the segmentation result.
[0009] In this embodiment, the original vital sign signal is segmented by determining the size of the sliding window and the sliding step length, and a vital sign signal sequence is constructed based on the segmentation result, which can improve the pertinence and efficiency of data processing.
[0010] In an optional embodiment, based on an energy threshold, the vital sign signal segments in the vital sign signal sequence are divided to obtain a division result, and based on the division result, it is judged whether there is a target body motion signal in the vital sign signal segment, including: dividing the vital sign signal segment into a number of first vital sign sub-signals of a first target time length to construct a first vital sign sub-signal sequence; obtaining the energy value of each first vital sign sub-signal in the first vital sign sub-signal sequence to calculate the average energy value of the first vital sign sub-signal; when the average energy value of the first vital sign sub-signal is greater than the first energy threshold, then there is a target body motion signal in the vital sign signal segment.
[0011] In this embodiment, the vital sign signal segment is divided twice, and the first vital sign sub-signal sequence is obtained. Then, by comparing the relationship between the average energy value of the first vital sign sub-signal sequence and the first energy threshold, it is determined whether there is a target body motion signal in the vital sign signal segment, so that the vital sign signal segments with target body motion signals can be quickly screened out.
[0012] In an optional embodiment, obtaining the duration of the target body motion signal includes: obtaining the energy value of each first sign sub-signal in the first sign sub-signal sequence of the sign signal segment; marking the first sign sub-signal whose energy value is greater than the first amplitude as a mutation signal; based on the time sequence, splicing adjacent mutation signals to obtain the target body motion signal; based on the first target time length, obtaining the duration of the target body motion signal.
[0013] In this embodiment, by obtaining the first body sign sub-signal whose energy value is greater than the first amplitude and marking it as a mutation signal, and then splicing adjacent mutation signals based on the time sequence, the target body motion signal and the duration of the target body motion signal can be obtained. The start and end positions of the target body motion signal can be accurately obtained, thereby improving the accuracy of body motion artifact detection.
[0014] In an optional embodiment, based on an energy threshold, the vital sign signal segments in the vital sign signal sequence are divided to obtain a division result, and based on the division result, it is judged whether there is a target body motion signal in the vital sign signal segment, which also includes: dividing the vital sign signal segment into a number of second vital sign sub-signals of a second target time length to construct a second vital sign sub-signal sequence; obtaining the energy value of each second vital sign sub-signal in the second vital sign sub-signal sequence to calculate the average energy value and the maximum energy value of the second vital sign sub-signal; when the ratio of the maximum energy value of the second vital sign sub-signal to the average energy value of the second vital sign sub-signal is greater than the second energy threshold, there is a target body motion signal in the vital sign signal segment.
[0015] In this embodiment, the vital sign signal segment is divided twice to obtain a second vital sign sub-signal sequence, and then by comparing the ratio of the maximum energy value of the second vital sign sub-signal to the average energy value of the second vital sign sub-signal and the relationship with the second energy threshold, it is determined whether there is a target body motion signal in the vital sign signal segment, so that the vital sign signal segments with target body motion signals can be quickly screened out.
[0016] In an optional embodiment, obtaining the duration of the target body motion signal includes: obtaining the average energy value of the second sign sub-signal in the second sign sub-signal sequence of the sign signal segment; when the average energy value of the second sign sub-signal is greater than the first energy average threshold, marking the second sign sub-signal with an energy value greater than the second amplitude as a mutation signal; when the average energy value of the second sign sub-signal is greater than the second energy average threshold and less than or equal to the first energy average threshold, marking the second sign sub-signal with an energy value greater than the third amplitude as a mutation signal; when the average energy value of the second sign sub-signal is less than the second energy average threshold, marking the second sign sub-signal with an energy value greater than the fourth amplitude as a mutation signal; based on the time sequence, splicing adjacent mutation signals to obtain the target body motion signal; based on the second target time length, obtaining the duration of the target body motion signal.
[0017] In this embodiment, based on the average energy value of the second body sign sub-signal, the second body sign sub-signal that meets the amplitude condition is determined and marked as a mutation signal. Based on the time sequence, adjacent mutation signals are spliced to obtain the target body motion signal and the duration of the target body motion signal. The start and end positions of the target body motion signal can be accurately obtained, thereby improving the accuracy of body motion artifact detection.
[0018] In an optional embodiment, a signal spectrum of a target body motion signal is obtained to generate a detection result of the target body motion signal, including: obtaining the signal spectrum of the target body motion signal; determining and comparing the low-frequency energy and high-frequency energy of the target body motion signal based on the signal spectrum; and generating a detection result of the target body motion signal based on the comparison result.
[0019] In this embodiment, the accuracy of body motion artifact detection can be improved by acquiring the signal spectrum of the target body motion signal, determining and comparing the low-frequency energy and high-frequency energy of the target body motion signal based on the signal spectrum, and then generating the detection result of the target body motion signal based on the comparison result.
[0020] In an optional implementation, the method further includes: when the duration is less than or equal to the first target time period, the target body motion signal is a body motion artifact event.
[0021] In this implementation, when the duration is less than or equal to the first target time period, the target body motion signal is directly marked as a body motion artifact event, which can improve the efficiency of body motion artifact detection.
[0022] In a second aspect, the present invention provides a body motion artifact detection device, which includes: a segmentation module, which is used to collect original vital sign signals and perform sliding window segmentation on the original vital sign signals to obtain a vital sign signal sequence, which includes a plurality of vital sign signal segments; a judgment module, which is used to divide the vital sign signal segments in the vital sign signal sequence based on an energy threshold, obtain a division result, and judge whether there is a target body motion signal in the vital sign signal segment based on the division result; an acquisition module, which is used to obtain the duration of the target body motion signal when there is a target body motion signal in the vital sign signal segment; and a generation module, which is used to obtain the signal spectrum of the target body motion signal when the duration is greater than a first target time period, so as to generate a detection result of the target body motion signal.
[0023] In a third aspect, the present invention provides a computer device, comprising: a memory and a processor, the memory and the processor being communicatively connected to each other, the memory storing computer instructions, and the processor executing the body motion artifact detection method of the first aspect or any corresponding embodiment thereof by executing the computer instructions. BRIEF DESCRIPTION OF THE DRAWINGS
[0024] In order to more clearly illustrate the specific implementation methods of the present invention or the technical solutions in the prior art, the drawings required for use in the specific implementation methods or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are some implementation methods of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0025] Figure 1 is a flow chart of a method for detecting body motion artifacts according to an embodiment of the present invention;
[0026] Figure 2 is a flow chart of another method for detecting body motion artifacts according to an embodiment of the present invention;
[0027] Figure 3 is a schematic diagram of a process for distinguishing body motion artifacts and deep breathing events according to an embodiment of the present invention;
[0028] Figure 4 is a schematic diagram of a body motion event signal segment and its power spectrum according to an embodiment of the present invention;
[0029] Figure 5 is a structural block diagram of a body motion artifact detection device according to an embodiment of the present invention;
[0030] Figure 6 It is a schematic diagram of the hardware structure of a computer device according to an embodiment of the present invention. DETAILED DESCRIPTION
[0031] In order to make the purpose, technical solution and advantages of the embodiments of the present invention clearer, the technical solution in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are 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 those skilled in the art without creative work are within the scope of protection of the present invention.
[0032] At present, polysomnography (PSG) is a standardized program for monitoring sleep quality and cardiac function in patients with sleep apnea syndrome. It can obtain physiological information of the human body through the bioelectricity of different parts of the human body or with the help of different sensors, such as electroencephalogram (EEG), electrocardiogram (ECG), electromyogram (EMG), electrooculogram (EOG), blood oxygen saturation (SaO 2), nasal airflow temperature / pressure (Flow-T / P), etc. Among them, electrocardiogram is the gold standard for clinical detection and diagnosis of cardiovascular diseases.
[0033] However, polysomnography has many disadvantages that cannot be ignored, such as strong restraint, high price, high monitoring environment requirements, and a large amount of human resources. In addition, subjects may have allergic reactions if the electrodes are attached to their body surface for a long time. These disadvantages greatly limit its wide application in the monitoring, diagnosis and treatment of sleep apnea syndrome and cardiovascular diseases.
[0034] In recent years, one of the focuses of the biomedical engineering field is to develop a low-cost, easy-to-use device that can monitor the user's sleep signs for a long time without disturbance. This new device has significant advantages over the shortcomings of polysomnography, such as strong restraint, high price, high monitoring environment requirements, huge human resource consumption, and the possibility of allergic reactions caused by long-term sticking of electrodes on the body surface of the subjects.
[0035] When using non-intrusive equipment to collect vital signs, the signals are usually presented in the form of aliased signals, which include components such as cardiac impact signals, respiratory signals, and body motion artifacts. When analyzing heartbeat or respiratory activities, the presence of body motion artifacts will mask the morphology of these two vital signs signals. Therefore, it is necessary to accurately identify and mark body motion artifacts.
[0036] In respiratory analysis, body motion artifacts are often removed as interference signals. By identifying deep breathing signals, the signal coverage can be effectively improved, the proportion of effective signals can be increased, and the credibility of signal analysis and disease diagnosis can be ensured. It can be seen that the identification of body motion artifacts and deep breathing is of great significance in vital sign signal analysis.
[0037] In the related art, body motion recognition is mainly performed using methods based on statistical indicator threshold discrimination, signal template comparison, and machine learning models.
[0038] Among them, the body motion artifact detection method based on statistical indicator threshold discrimination collects the whole night signal, performs preprocessing and structuring on a scale of 1 second, extracts the variance of each 1-second segment, and then performs a binary hypothesis test based on the NP (Neyman-Pearson) detection criterion to classify each 1-second segment into a normal signal or a body motion artifact. However, based on the fixed threshold, it is still difficult to adapt to the changing clinical conditions. In the whole night sleep monitoring, the adaptability of the threshold will be reduced due to changes in sleeping posture or other physiological changes.
[0039] Body motion artifact detection is performed based on the signal template comparison method. ECG and BCG signals are first collected synchronously. Then, through the visual confirmation method, the ECG signal is used to segment the BCG one by one, and then averaged to obtain the template signal of the BCG. The obtained template is then used to perform signal-to-noise ratio analysis on the BCG to obtain the noise estimation value of each BCG for further body motion artifact threshold judgment. This method can improve the BCG signal-to-noise ratio to a certain extent, but when the overall signal quality collected is poor, it will lead to poor template extraction, which will seriously affect the subsequent noise estimation and thus affect the effective discrimination of body motion artifacts.
[0040] The machine learning model method can combine different features of the signal for body movement recognition. By extracting 53 features such as standard deviation (STD), median absolute deviation (MAD), 75% quantile, skewness, kurtosis and Shannon entropy, support vector machine (SVM) and RUSBoost (Random Under-Sampling adaptive Boosting) are selected for model training and classification. Although the model classification accuracy is high, it needs to extract a large number of features and has certain requirements on computing power.
[0041] In the related technology, there is also a body movement detection method that combines deep learning model judgment and signal standard deviation threshold judgment. The two judgment results are fused by OR operation to obtain the signal that is initially judged as body movement, and then the standard deviation of the signal that is initially judged as body movement is calculated. It is corrected with the help of secondary threshold judgment, and finally a label of body movement is obtained. The label includes the start and end time points with an accuracy of 1s.
[0042] In summary, the statistical standards used for identification are difficult to adapt to the complex changes of clinical signals; the detection results of signal template comparison depend on the quality of the signal; the recognition based on machine learning classification methods requires a large workload for feature extraction and higher computing resources, and the segmented fragments need to be labeled to indicate the sample category.
[0043] Therefore, using non-intrusive devices for sleep monitoring can improve the user's sleep experience and reduce interference with daily sleep conditions. However, most of the signals obtained are aliased signals. A simple and efficient body motion artifact detection method can improve the efficiency of preprocessing aliased signals, improve the efficiency of subsequent signal processing, and provide effective information for subsequent signal analysis.
[0044] In view of this, the present invention proposes a body motion artifact detection method, which can use a non-intrusive piezoelectric sensor system to detect vital signs during sleep and perform body motion detection based on signal energy and spectrum analysis. It can achieve the purpose of identifying and distinguishing body motion and deep breathing with less computing resources without the need for template extraction and feature calculation in advance.
[0045] According to an embodiment of the present invention, an embodiment of a method for detecting body motion artifacts is provided. It should be noted that the steps shown in the flowchart of the accompanying drawings can be executed in a computer system such as a set of computer executable instructions, and although a logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in an order different from that shown here.
[0046] In this embodiment, a method for detecting body motion artifacts is provided. Figure 1 FIG. 4 is a flow chart of a method for detecting body motion artifacts according to an embodiment of the present invention. Figure 1 As shown, the process includes the following steps:
[0047] Step S101 , collecting original vital sign signals, and performing sliding window segmentation on the original vital sign signals to obtain a vital sign signal sequence, wherein the vital sign signal sequence includes a plurality of vital sign signal segments.
[0048] Among them, a non-contact piezoelectric vital sign monitoring device can be used to collect original vital sign signals. Among them, the original vital sign signals can be obtained by collecting the vital sign signals of the person to be tested when he is sleeping. After collecting the original vital sign signals, the original vital sign signals can be preprocessed to improve the quality of the original vital sign signals. After preprocessing the original vital sign signals, it is necessary to perform sliding window segmentation on the original vital sign signals to obtain several individual sign signal segments and obtain a vital sign signal sequence. Among them, when performing sliding window segmentation on the original vital sign signals, the window size must be determined first. Among them, the window size can be determined according to actual conditions. Then determine the step size, which represents the interval of window movement. A smaller step size can make the window overlap high and obtain more detailed information, but it will increase the computational complexity of the method to a certain extent.
[0049] After determining the window size and sliding step, starting from the start position of the signal, a section of the signal is intercepted as the current window data according to the set window size, and then the window is moved according to the step size, and the interception operation is repeated until the window moves to the end of the signal, and a sign signal sequence including several sign signal segments can be obtained. Sliding window segmentation divides the original sign signal into fixed-scale segments by moving the window, unifies the signal scale of subsequent energy analysis, and helps to improve the operation speed.
[0050] In a specific implementation, the portion of the original vital sign signal that needs to be subjected to artifact detection may be first selected to determine the start position and the end position of the window.
[0051] In a specific implementation, the original vital sign signal can be collected by a non-contact piezoelectric vital sign monitoring device, which can be composed of a piezoelectric sensor module and a data processor. The sampling frequency can be determined according to the actual situation and can be 1000 Hz. During the collection, the piezoelectric sensor module can be placed under the pillow. Since the human body is a micro-vibration body, the piezoelectric sensor module can pick up the micro-vibration force caused by the impact of the aortic arch by the contraction and relaxation of the heart and the chest expansion movement during the breathing process, that is, the heart impact and breathing effort. At the same time, body motion events generated by the movement of the limbs and trunk, as well as deep breathing events that also show a sudden increase in amplitude, will also be collected. The mixed analog signal collected by the piezoelectric sensor module is amplified and noise-removed, and then converted into a digital signal by a 12-bit analog-to-digital converter (ADC). The generated digital signal is transmitted and processed in a personal computer for further analysis.
[0052] After the original vital sign signal is collected, the original vital sign signal can be subjected to structured preprocessing, wherein the structured preprocessing may include downsampling, power frequency removal, DC removal, and the like.
[0053] When structured preprocessing includes downsampling, after collecting the original vital signs signal, the signal with a lower sampling rate can be obtained by sampling at alternate points. Lowering the sampling rate can increase the signal calculation and processing speed and improve the efficiency of program execution. In specific implementations, the sampling rate can be reduced by ten times according to the sampling theorem. That is, when the sampling frequency is 1000 Hz, setting the signal frequency after downsampling to 100 Hz can effectively retain the vital signs information and power frequency information of concern, such as heartbeat, breathing, and body movement. By downsampling, the amount of calculation of the model can be reduced.
[0054] When structured preprocessing includes power frequency removal, this can be achieved by designing a Butterworth low-pass filter. The power frequency can be set to 50 Hz. In a practical application, a 4th-order Butterworth low-pass filter with a cutoff frequency of 20 Hz is used to remove the power frequency noise. Since the original signal collected by the non-contact piezoelectric vital sign monitoring device is an aliased signal, it includes BCG signals, respiratory signals, body motion signals, and power frequency noise. By removing power frequency interference, only BCG signals, respiratory signals, and body motion artifacts can be retained.
[0055] When the structured preprocessing includes DC removal, the DC removal method can be determined according to the actual situation and can be implemented by a high-pass filter. In a practical application, considering the need to calculate the signal energy and analyze its spectrum distribution in the future, DC removal is performed by subtracting the signal mean. DC removal can make the signal fluctuate around the 0 baseline.
[0056] Step S102 , based on the energy threshold, the vital sign signal segments in the vital sign signal sequence are divided to obtain a division result, and based on the division result, it is determined whether there is a target body motion signal in the vital sign signal segment.
[0057] Both body movement and deep breathing events will show the characteristic of a sudden and significant increase in signal amplitude. The signal energy is related to the signal amplitude, and the energy of the corresponding signal segment will be significantly greater than that of the non-body movement part. The deep breathing signal will also show the characteristic of increased energy. Based on the energy threshold, the physical sign signal segments in the physical sign signal sequence are divided to quickly identify the target body movement signal.
[0058] Among them, the energy threshold can be determined according to the actual situation. In some optional embodiments, several division conditions can be set to divide all vital sign signal segments with target body motion signals. Among them, the division conditions can include energy hard thresholds and energy relative thresholds to avoid omissions as much as possible. The energy hard threshold can be a threshold for the energy value of the vital sign signal segment. When the energy value of the vital sign signal segment is greater than the energy hard threshold, it can be directly determined that there is a target body motion signal in the vital sign signal segment; the energy relative threshold can be set based on the ratio of the maximum energy value to the average energy value in the vital sign signal segment.
[0059] In the specific implementation, considering that when acquiring signals in a non-contact manner, the amplitude is related to the sensing distance, and the signal mutation is relative to the previous and next signals, the division conditions include energy hard threshold and energy relative threshold. As long as the energy of the vital sign signal segment can meet one of the threshold conditions, it is judged that the vital sign signal segment has the target body motion signal.
[0060] Step S103: when there is a target body motion signal in the vital sign signal segment, obtain the duration of the target body motion signal.
[0061] When there is a target body motion signal in the vital sign signal segment, the duration of the target body motion signal may be acquired according to the starting position of the target body motion signal.
[0062] The target body motion signal may be a deep breathing event and a body motion artifact. Normal breathing generally does not exceed 24 times per minute, that is, one breathing cycle is 2.5 seconds. It can be inferred that the target body motion signal with a longer duration may be a deep breathing event and a body motion artifact event, and the target body motion signal with a shorter duration may be a body motion artifact event.
[0063] Step S104: when the duration is greater than the first target time period, acquiring a signal spectrum of the target body motion signal to generate a detection result of the target body motion signal.
[0064] Among them, the first target time period can be determined according to actual conditions. In a specific implementation, since a respiratory cycle is generally not less than 2.5 seconds, it can be considered that there is no complete breath within 2.5 seconds, that is, a signal mutation lasting 2.5 seconds will not be a deep breath. That is, the first target time period is 2.5 seconds. In some optional implementations, a floating threshold can be set to avoid missed detection. In a practical application, the first target time period is 2 seconds. When the duration does not exceed 2s, the event is considered to be a body motion artifact event, and there is no need to obtain the signal spectrum for re-examination; when it exceeds 2s, it is likely to be a deep breathing event.
[0065] Therefore, when the duration of the event is greater than the first target event segment, it can be determined that the target body motion signal may be a body motion artifact event or a deep breathing event. The target body motion signal can be Fourier transformed to obtain the corresponding signal spectrum, and based on the signal spectrum, it can be determined whether the target body motion signal is a body motion artifact event. In a specific implementation, after obtaining the signal spectrum of the target body motion signal, a frequency domain threshold can be set to divide the low-frequency range and high-frequency range of the target body motion signal. Then, the low-frequency energy of the target body motion signal in the low-frequency range and the high-frequency energy in the high-frequency range are calculated respectively. Comparing the low-frequency energy and the high-frequency energy, when the low-frequency energy is high, the target body motion signal is mainly low-frequency changes, and the target body motion signal is a deep breathing event. When the high-frequency energy is high, the target body motion signal is a body motion artifact event.
[0066] In the specific implementation, the first target time period is one breathing cycle. Events with a duration of not less than one breathing cycle are screened out to enter the signal spectrum detection to distinguish body motion artifacts from deep breathing; events with a duration of less than one breathing cycle are directly marked as body motion artifacts. Through this screening, the amount of calculation and the effectiveness of calculation of subsequent signal spectrum detection can be reduced.
[0067] In a specific implementation, after generating the detection result of the target body motion signal, the body motion artifact sequence and deep breathing sequence in the original vital sign signal can be obtained. According to the target body motion signal and vital sign signal segments corresponding to the sequence, the start and end time of the time can be determined, and the original vital sign signal can be indexed back to mark the body motion artifact and deep breathing events of the original vital sign signal.
[0068] The body motion artifact detection method provided in this embodiment collects the original body sign signal, and performs sliding window segmentation on the original body sign signal to obtain a body sign signal sequence; then, based on the energy threshold, the body sign signal segment in the body sign signal sequence is divided to determine whether there is a target body motion signal in the body sign signal segment. In the case where the target body motion signal exists in the body sign signal segment, the duration of the target body motion signal is obtained; in the case where the duration is greater than the first target time period, the signal spectrum of the target body motion signal is obtained to generate a detection result of the target body motion signal. Through the above scheme, by performing sliding window segmentation on the original body sign signal, the calculation memory required by the method can be reduced. The body sign signal segments in the body sign signal sequence are divided based on the energy threshold to obtain the division result, and the body sign signal segments with the target body motion signal can be quickly screened out. Then, the target body motion signal is screened based on the duration, which can reduce the amount of calculation for subsequent detection. Finally, the signal spectrum of the target body motion signal whose duration is greater than the first target time period is obtained to generate the detection result of the target body motion signal, which can improve the accuracy of body motion artifact detection.
[0069] In this embodiment, a method for detecting body motion artifacts is provided. Figure 2 FIG. 4 is a flow chart of a method for detecting body motion artifacts according to an embodiment of the present invention. Figure 2 As shown, the process includes the following steps:
[0070] Step S201 , collecting original vital sign signals, and performing sliding window segmentation on the original vital sign signals to obtain a vital sign signal sequence, wherein the vital sign signal sequence includes a plurality of vital sign signal segments.
[0071] Specifically, the above step S201 includes:
[0072] Step S2011, determine the size of the sliding window and the sliding step.
[0073] Among them, the size of the sliding window and the sliding step can be determined according to the actual situation. In the specific implementation, large body movements such as turning over during sleep at night usually do not exceed 30 seconds, and in sleep monitoring, the minimum observation window of the electrocardiogram is 30 seconds, combined with the duration of actual body movements and the parameter compatibility of subsequent studies. The sliding window overlap can be set to prevent missed detection. Therefore, in actual applications, 30 seconds can be selected as the sliding window to segment the original vital sign signal, and the sliding window overlap is set to 50%, that is, the sliding window size is 30 seconds and the sliding step is 15 seconds.
[0074] Step S2012: placing the sliding window at the target position of the original vital sign signal, and segmenting the original vital sign signal based on the sliding step size.
[0075] The target position can determine the valid signal in the original vital sign signal according to the actual situation. In the specific implementation, the sliding window can be placed at the starting point of the original vital sign signal to prevent missed detection. Based on the sliding step length, the original vital sign signal is initially segmented, and several 30s vital sign signal segments are obtained after the segmentation is completed.
[0076] Step S2013: construct a vital sign signal sequence based on the segmentation result.
[0077] The vital sign signal sequence includes a number of segmented vital sign signal segments.
[0078] Step S202: based on the energy threshold, the vital sign signal segments in the vital sign signal sequence are divided to obtain a division result, and based on the division result, it is determined whether there is a target body motion signal in the vital sign signal segment.
[0079] For details, please see Figure 1 Step S102 of the illustrated embodiment will not be described in detail here.
[0080] Step S203: when there is a target body motion signal in the vital sign signal segment, obtain the duration of the target body motion signal.
[0081] For details, please see Figure 1 Step S103 of the illustrated embodiment will not be described in detail here.
[0082] In some optional implementations, the above step S202 includes:
[0083] Step a1: divide a vital sign signal segment into a plurality of first vital sign sub-signals of a first target time length to construct a first vital sign sub-signal sequence.
[0084] The first target time length can be determined according to actual conditions. In a specific implementation, it can be set to 1 second to facilitate parameter compatibility in subsequent studies.
[0085] Step a2: acquiring the energy value of each first sign sub-signal in the first sign sub-signal sequence to calculate the average energy value of the first sign sub-signals.
[0086] Step a3: When the average energy value of the first vital sign sub-signal is greater than the first energy threshold, there is a target body motion signal in the vital sign signal segment.
[0087] The first energy threshold can be determined according to actual conditions. In a specific implementation, the first energy threshold can be set to 200 joules.
[0088] In some optional implementations, when it is determined through steps a1 to a3 that there is a target body motion signal in the vital sign signal segment, the above step S203 includes:
[0089] Step a4: acquiring the energy value of each first vital sign sub-signal in the first vital sign sub-signal sequence of the vital sign signal segment.
[0090] The energy value of each first sign sub-signal in the first sign sub-signal sequence can be obtained by calculation.
[0091] Step a5: marking the first sign sub-signal whose energy value is greater than the first amplitude as a mutation signal.
[0092] The first amplitude may be determined according to actual conditions. In some optional implementations, the first sign sub-signal with an energy value greater than 20 joules is marked as a mutation signal.
[0093] Step a6, based on the time sequence, splice adjacent mutation signals to obtain the target body motion signal.
[0094] According to the order of the first body sign sub-signal in the first body sign sub-signal sequence, its corresponding time can be obtained, and the adjacent mutation signals are spliced to obtain the target body motion signal, which is convenient for subsequent body motion artifact detection.
[0095] In a specific implementation, after all mutation signals in the first sign sub-signal sequence are marked, the positions of all mutation signals are first obtained; if the interval between two mutation signals is no more than two first sign sub-signals of non-mutation signals, the non-mutation signal between the two mutation signals is also marked as a mutation signal and spliced, which can prevent missed detection.
[0096] Step a7: acquiring the duration of the target body motion signal based on the first target time length.
[0097] Among them, according to the first target time length, the length of each first vital sign sub-signal can be determined, and according to the number of first vital sign sub-signals included in the target body motion signal, the duration of the target body motion signal can be obtained.
[0098] In the specific implementation, the length of the vital sign signal segment is 30 seconds, denoted as S(n), which is divided into 30 segments of 1s small-granularity signals X without overlap. n (k), k = 1, 2, 3, ..., 30, the subscript n represents the nth sliding window segment S(n) obtained in the sliding window segmentation of the original vital sign signal corresponding to the small-grained sequence; correspondingly, 30 small-grained energy value sequences E are calculated n (k), k = 1, 2, 3, ..., K; and correspondingly set the signal state label sequence L with the initial label 0 n (k), k = 1, 2, 3, ..., K; where K = 30. The initial label is 0, indicating no motion artifact or deep breathing.
[0099] X for each 1sn (k) The signal segment is represented by the number of sampling points of a 1s signal with a sampling rate of 100 Hz. The average value of these 30 small-grained energy sequences is taken as the average energy E of the 30s segment. mean (n), E mean (n) and E n The method of obtaining (k) is as follows:
[0100]
[0101] Where k is an integer between 1 and 30; l is X n (k) is the sampling point sequence number. For each second of signal, l is an integer in the range [1,100]. l This step obtains the small-grained energy sequence E of the S(n) segment. n (k), and the average energy E corresponding to the vital sign signal segment mean (n).
[0102] At the average energy E mean If (n) is greater than the first energy threshold, it indicates that there is an amplitude mutation event in the vital sign signal segment, that is, there is a target body motion signal in the vital sign signal segment. Then, the vital sign signal segment S(n) with the target body motion signal is further analyzed. n (k) In each segment of the small-size signal, based on the first amplitude, it is judged whether it is a sudden amplitude change signal, and the judgment result is recorded in L n (k), the kth small-size signal X n The signal state of (k) is represented by L n (k). In practical applications, L can be set n (k) The value 0 indicates that the signal has no amplitude mutation, and 1 indicates that the signal has an amplitude mutation.
[0103] The first amplitude can be set to 20. That is, small-size signals with energy values greater than 20 can be marked as amplitude mutation events, and the corresponding L n (k) is marked as 1.
[0104] According to the order of the 30s vital sign signal segment S(n) in the original vital sign signal, the L corresponding to each S(n) is n (k) The sequences are arranged in order and restored to the whole night sequence, denoted as L, with a label value of 0 or 1. Each label value represents whether there is an amplitude mutation event in the current 1s, that is, the labeling accuracy of the L label is 1s.
[0105] In some optional implementations, when performing duration statistics on small-granularity signals of amplitude mutation events, adjacent events of less than 2 seconds are merged into one event. Specifically, first obtain the positions of all labels "1" in L. When there are no more than two 0s between two labels 1, the "0" between the two "1" labels is also changed to "1". The continuous "1" in L is regarded as one event, and the position of the first "1" of each event is taken as the starting time t 1 , taking the last "1" of the event as the end time t 2 , and calculate the difference between the two as the duration D of this event:
[0106] D=t 2 -t 1 +1
[0107] The unit of D is seconds, and its value is the same as the number of labels “1” in this amplitude mutation event.
[0108] In some optional implementations, the above step S203 includes:
[0109] Step b1, dividing the vital sign signal segment into a plurality of second vital sign sub-signals of a second target time length to construct a second vital sign sub-signal sequence.
[0110] The first target time length can be determined according to actual conditions. In a specific implementation, it can be set to 1 second to facilitate parameter compatibility in subsequent studies.
[0111] Step b2: acquiring the energy value of each second sign sub-signal in the second sign sub-signal sequence to calculate the average energy value and the maximum energy value of the second sign sub-signal.
[0112] Step b3: When the ratio of the maximum energy value of the second vital sign sub-signal to the average energy value of the second vital sign sub-signal is greater than the second energy threshold, there is a target body motion signal in the vital sign signal segment.
[0113] The second energy threshold can be determined according to actual conditions. When the maximum energy value of the second vital sign sub-signal and the average energy value of the second vital sign sub-signal are greater than the second energy threshold, the energy value of the second vital sign sub-signal in the vital sign signal segment is greater than that of other second vital sign sub-signals to a certain extent. An amplitude mutation event occurs, that is, a target body motion signal exists in the corresponding vital sign signal segment.
[0114] In some optional implementations, when it is determined through steps b1 to b3 that there is a target body motion signal in the vital sign signal segment, the above step S203 includes:
[0115] Step b4, obtaining the average energy value of the second vital sign sub-signal in the second vital sign sub-signal sequence of the vital sign signal segment.
[0116] Step b5: When the average energy value of the second sign sub-signal is greater than the first energy average threshold, mark the second sign sub-signal with an energy value greater than the second amplitude as a mutation signal.
[0117] Step b6: When the average energy value of the second sign sub-signal is greater than the second energy average threshold and less than or equal to the first energy average threshold, mark the second sign sub-signal with an energy value greater than the third amplitude as a mutation signal.
[0118] Step b7: When the average energy value of the second sign sub-signal is less than the second energy average threshold, mark the second sign sub-signal with an energy value greater than the fourth amplitude as a mutation signal.
[0119] The first energy average threshold, the second energy average threshold, the second amplitude, the third amplitude and the fourth amplitude can be determined according to actual conditions. When the average energy value of the second vital sign sub-signal is large, the corresponding amplitude also needs to be large.
[0120] In a specific implementation, the first energy average threshold is greater than the second energy average threshold, the second amplitude is greater than the third amplitude, and the third amplitude is greater than the fourth amplitude.
[0121] In a practical application, the second energy threshold is 5. When the ratio of the maximum energy value of the second body sign sub-signal to the average energy value of the second body sign sub-signal is greater than 5, the body sign signal segment contains a target body motion signal. That is, when the body sign signal segment S(n) contains a target body motion signal, the corresponding small granularity signal sequence X n (k) Each small-size signal is judged to determine whether it is a sudden change signal, and the judgment result is recorded in L n (k), the kth small-size signal X n The signal state of (k) is represented by L n (k).
[0122] The first energy average threshold is set to 10, the second energy average threshold is set to 1.5, the second amplitude is 20, the third amplitude is 10, and the fourth amplitude is 5. That is, when the average energy E of the segment S(n) is mean (n) Mark the 1s small-size signal sequence X that is body movement or deep breathing n (k): When E mean If (n)>10, then the small-size signal with En(k)>20 is marked as the amplitude mutation event, corresponding to L n (k) is recorded as 1; when E mean (n)<1.5, then the small-size signal with En(k)>5 is marked as the amplitude mutation event, corresponding to L n (k) is recorded as 1; when 10>Emean (n)>1.5, then the small-size signal with En(k)>10 is marked as the amplitude mutation event, corresponding to L n (k) is recorded as 1.
[0123] Step b8, based on the time sequence, splice adjacent mutation signals to obtain the target body motion signal.
[0124] Please refer to the above step a6 for details and will not be repeated here.
[0125] Step b9: acquiring the duration of the target body motion signal based on the second target time length.
[0126] Among them, according to the second target time length, the length of each second sign sub-signal can be determined, and according to the number of second sign sub-signals included in the target body motion signal, the duration of the target body motion signal can be obtained.
[0127] By performing sliding window detection on the original vital sign signal and performing secondary segmentation on the signal within the sliding window to calculate the energy, the dual-scale threshold division can accurately obtain the time label of deep breathing or body movement artifacts in the original vital sign signal.
[0128] Step S204: when the duration is greater than the first target time period, acquiring a signal spectrum of the target body motion signal to generate a detection result of the target body motion signal.
[0129] For details, please see Figure 1 Step S104 of the illustrated embodiment will not be described in detail here.
[0130] In some optional implementations, the above step S204 includes:
[0131] Step S2041, obtaining the signal spectrum of the target body motion signal.
[0132] Among them, deep breathing events and body motion artifact events will have differences in signal spectra. Therefore, by acquiring the signal spectrum of the target body motion signal, the target body motion signal can be secondary detected to determine whether the target body motion signal is a body motion artifact event.
[0133] In some optional implementations, there are several target body motion signals, the i-th target body motion signal is recorded as M(i), and the sampling rate of the target body motion signal is the same as the sampling rate of the vital sign signal segment. In practical applications, the signal lengths of different target body motion signals may be inconsistent. M(i) = {m 1 ,m 2 ,m 3 ,…,m p},m prepresents the sampling point of the event signal segment M(i), and the signal length of M(i) is the product of p=100 and D(i). D(i) represents the duration of the i-th target body motion signal.
[0134] The target body motion signal can be subjected to Fourier transform to obtain the signal spectrum of the target body motion signal. As shown in the following formula:
[0135]
[0136] Where F(ω) represents the frequency spectrum of the target body motion signal, M(m) represents the mth target body motion signal, n represents the sampling point of the target body motion signal, and e -jωn The weighted sum of all possible values of the target body motion signal in the frequency domain can be obtained by the Fourier transform formula.
[0137] Step S2042: determine and compare the low-frequency energy and high-frequency energy of the target body motion signal based on the signal spectrum.
[0138] Based on the signal characteristics of the target body motion signal, the high and low frequency ranges of the signal are divided. The high and low frequency boundaries can be determined according to actual conditions. After determining the high and low frequency boundaries, the high frequency energy and low frequency energy of the target body motion signal are calculated respectively.
[0139] In the specific implementation, since most of the breathing is distributed within 0.5 Hz, the high and low frequency limits can be set to 0.5 Hz. In the specific implementation, the low frequency range is 0-0.5 Hz and the high frequency range is 0.5-1 Hz. Then, according to the energy calculation formula, the energy of the selected frequency domain interval is calculated. The high frequency energy calculation method is shown as follows:
[0140]
[0141] Among them, E high (i) represents high frequency energy, and F(ω) represents the signal spectrum.
[0142] The low-frequency energy is calculated as follows:
[0143]
[0144] Among them, E low (i) represents the low-frequency energy, and F(ω) represents the signal spectrum.
[0145] Step S2043: generating a detection result of the target body motion signal based on the comparison result.
[0146] Among them, the ratio of low-frequency energy to high-frequency energy can be calculated, and based on the size of the ratio, it can be determined whether the target body motion signal is a deep breathing event or a body motion artifact.
[0147] The setting of the ratio threshold can be determined according to the actual situation. In a specific implementation, the ratio threshold can be set to 1.5. That is, when the ratio of low-frequency energy to high-frequency energy is greater than or equal to 1.5, it indicates that the target body motion signal is a deep breathing event. When the ratio is less than 1.5, it indicates that the target body motion event is a body motion artifact event caused by the movement of the trunk and limbs.
[0148] In some optional implementations, when the duration is less than or equal to the first target time period, the target body motion signal is a body motion artifact event.
[0149] The first target time period is determined based on a person's breathing cycle. When the duration is less than or equal to the first target time period, it can be determined that the target body motion signal is not a deep breathing event, but a body motion artifact event. In a specific implementation, since a person's breathing cycle is not less than 2.5 seconds, the first target time period can be set to 2.5 seconds, which means that if there is no complete breath within 2.5 seconds, then a duration of less than 2.5 seconds will not be a deep breath.
[0150] The body motion artifact detection method provided in this embodiment segments the original vital sign signal by determining the size of the sliding window and the sliding step length, and constructs a vital sign signal sequence based on the segmentation result, which can improve the pertinence and efficiency of data processing.
[0151] In this embodiment, a method for distinguishing body motion artifacts and deep breathing events is provided. Figure 3 is a flow chart of a method for distinguishing body motion artifacts and deep breathing events according to an embodiment of the present invention. Figure 3 As shown:
[0152] The piezoelectric aliasing signal is collected first, and then the signal is preprocessed and segmented.
[0153] Among them, the non-disturbance piezoelectric sensor placed under the pillow can be used as a signal acquisition device to collect the original vital sign signal, that is, the piezoelectric aliasing signal, in real time. The non-disturbance piezoelectric sensor signal acquisition device mainly consists of two parts: a signal acquisition module and a data storage module. The signal acquisition module can be placed under the pillow. The tester uses the pillow and bedding normally. Due to the tester's heart activity, breathing activity, etc., the body vibrates slightly, the center of gravity shifts, and a force signal is generated. The signal acquisition module can convert the force signal into an analog electrical signal, and then filter, amplify, and A / D convert the analog electrical signal through the built-in filtering circuit, amplifying circuit, and A / D conversion circuit to convert it into a digital signal with a preset sampling rate, that is, a piezoelectric aliasing signal. In actual applications, after collecting the signal through the non-disturbance piezoelectric sensor, the original piezoelectric aliasing signal S of the tester for a whole night can be obtained. raw , the number of sampling points of the piezoelectric aliasing signal is f s The product of t, where fs is the sampling rate 1000 Hz, and t is the length of the signal over the entire night in seconds.
[0154] Signal preprocessing mainly includes ten-fold downsampling, power frequency filtering and DC removal. Among them, ten-fold downsampling of the signal includes: converting the original signal S raw Interval sampling, sampling one out of every ten signal points in the original signal to generate a new downsampled signal set S down .
[0155] The signal is processed to remove the power frequency and DC. down The DC is removed by subtracting the mean value, and the signal after DC removal is input into a fourth-order Butterworth low-pass filter with a cutoff frequency of 20 Hz to remove power frequency interference and obtain a signal S for window detection.
[0156] The signal segmentation uses a 30-second sliding window segmentation, and the sliding window segmentation scale is set to 30s, that is, the segmented segment length is 30s. The sliding window segmentation step is set to 15s (50% of the window length), that is, the starting points of adjacent segments differ by 15s. The whole night signal segmentation obtains a 30s segment set S(n), where n = 1, 2, 3, ..., N, that is, the whole night signal is segmented into N 30s signal segments.
[0157] After the signal is segmented, several sliding segments are obtained, and the initial inspection stage of the signal is entered. The initial inspection stage includes determining whether the sliding segment has a sudden change in amplitude, and if so, identifying the specific location of the sudden change in amplitude. Figure 4 As shown in the figure, the blue line part represents the collected piezoelectric aliasing signal, and the red part represents the body motion signal with a sudden change in amplitude in the collected piezoelectric aliasing signal. In the spectrum distribution diagram of the body motion signal segment, it can be seen that when body motion occurs, the signal is yellow in a wide frequency band and has higher energy.
[0158] Among them, to determine whether a sliding segment has an amplitude mutation, the sliding segment can be segmented into small granularity, and then the small-granularity signal energy in the segment and the overall signal energy of the segment are calculated and compared. Through energy discrimination, it is preliminarily identified whether the sliding segment may contain a body motion signal segment or a deep breathing signal segment. In a specific implementation, a secondary threshold for small-granularity signals can be set based on the average energy of the sliding segment. By comparing the secondary threshold with the small-granularity signal energy, the amplitude mutation event is discriminated to determine whether the small-granularity signal belongs to an amplitude mutation event. Among them, amplitude mutation events include body motion artifacts and deep breathing caused by body limb movements.
[0159] After the initial inspection phase, the positions of the entire night's data are restored for event fusion.
[0160] After the initial inspection, the start and end positions of the amplitude mutation event are accurately obtained. Then, combined with the actual situation, the respiratory cycle is estimated, the amplitude mutation events obtained in the initial inspection are time-fused, and the event duration is estimated.
[0161] After the event fusion, the recheck phase begins. Potential deep breathing events are screened out based on the event duration. Events other than deep breathing events are body motion artifacts. Among them, signals with an event duration greater than one breath may be deep breathing events. Potential deep breathing events are amplitude mutation signal segments with a duration greater than one breath. The amplitude and duration of different potential deep breathing events are not uniform.
[0162] After screening out potential deep breathing events, the event signal is Fourier transformed, and based on the Fourier transform results, the signal low-high frequency energy ratio is calculated. Based on the energy ratio results, deep breathing events and body motion artifact events are distinguished.
[0163] In a specific implementation, after the re-examination stage, a body motion artifact sequence and a deep breathing sequence can be obtained. Corresponding to the start and end times obtained in the initial examination stage, they can be indexed back into the complete signal to mark the body motion artifact events and deep breathing events of the complete signal.
[0164] This embodiment uses a method for detecting body motion artifacts and deep breathing signal segments of non-contact vital sign signals. Signal segment detection with amplitude mutation is performed based on signal energy, and then combined with the difference in its spectrum distribution, it is determined whether the measured signal with amplitude mutation is caused by trunk and body motion artifacts or deep breathing activities. In practical applications, it is helpful for subsequent application research based on features such as respiratory components or body motion frequency, such as sleep staging and sleep breathing disorders. At the same time, the recognition of body motion is conducive to the subsequent research based on non-contact acquisition to obtain clean signal segments without body motion. Therefore, the detection of body motion artifacts and deep breathing is an important basis for subsequent application research and is of great significance.
[0165] In this embodiment, a body motion artifact detection device is also provided, which is used to implement the above-mentioned embodiments and preferred implementation modes, and the descriptions that have been made will not be repeated. As used below, the term "module" can be a combination of software and / or hardware that implements a predetermined function. Although the device described in the following embodiments is preferably implemented in software, the implementation of hardware, or a combination of software and hardware, is also possible and conceivable.
[0166] This embodiment provides a body motion artifact detection device, such as Figure 5 As shown, including:
[0167] The segmentation module 501 is used to collect original vital sign signals and perform sliding window segmentation on the original vital sign signals to obtain a vital sign signal sequence, which includes a plurality of vital sign signal segments.
[0168] The judgment module 502 is used to divide the vital sign signal segments in the vital sign signal sequence based on the energy threshold, obtain the division result, and judge whether there is a target body motion signal in the vital sign signal segment based on the division result.
[0169] The acquisition module 503 is used to acquire the duration of the target body motion signal when there is a target body motion signal in the vital sign signal segment.
[0170] The generating module 504 is used to obtain the signal spectrum of the target body motion signal when the duration is greater than the first target time period, so as to generate a detection result of the target body motion signal.
[0171] In some optional implementations, the segmentation module 501 includes:
[0172] A parameter determination unit, used to determine the size of the sliding window and the sliding step size;
[0173] A segmentation unit, used for placing the sliding window at a target position of the original vital sign signal and segmenting the original vital sign signal based on the sliding step size;
[0174] The construction unit is used to construct a vital sign signal sequence based on the segmentation result.
[0175] In some optional implementations, the determination module 502 includes:
[0176] a first vital sign sub-signal sequence constructing unit, configured to divide a vital sign signal segment into a plurality of first vital sign sub-signals of a first target time length to construct a first vital sign sub-signal sequence;
[0177] a first energy value calculation unit, configured to obtain an energy value of each first sign sub-signal in the first sign sub-signal sequence to calculate an average energy value of the first sign sub-signals;
[0178] The first judgment unit is used to determine that there is a target body motion signal in the vital sign signal segment when the average energy value of the first vital sign sub-signal is greater than a first energy threshold.
[0179] In some optional implementations, the determination module 502 further includes:
[0180] The second vital sign sub-signal sequence constructing unit is used to divide the vital sign signal segment into a plurality of second vital sign sub-signals of a second target time length to construct a second vital sign sub-signal sequence.
[0181] The second energy value calculation unit is used to obtain the energy value of each second sign sub-signal in the second sign sub-signal sequence to calculate the average energy value and the maximum energy value of the second sign sub-signal.
[0182] The second judgment unit is used to determine that there is a target body motion signal in the physical sign signal segment when the ratio of the maximum energy value of the second physical sign sub-signal to the average energy value of the second physical sign sub-signal is greater than a second energy threshold.
[0183] In some optional implementations, the acquisition module 503 includes:
[0184] The first energy acquisition unit is used to acquire the energy value of each first vital sign sub-signal in the first vital sign sub-signal sequence of the vital sign signal segment.
[0185] The first marking unit is used to mark a first sign sub-signal whose energy value is greater than a first amplitude as a mutation signal.
[0186] The first splicing unit is used to splice adjacent mutation signals based on time sequence to obtain the target body motion signal.
[0187] The first duration acquisition unit is used to acquire the duration of the target body motion signal based on the first target time length.
[0188] In some optional implementations, the acquisition module 503 further includes:
[0189] The second energy acquisition unit is used to acquire the average energy value of the second vital sign sub-signal in the second vital sign sub-signal sequence of the vital sign signal segment.
[0190] The second marking unit is used to mark the second sign sub-signal with an energy value greater than the second amplitude as a mutation signal when the average energy value of the second sign sub-signal is greater than the first energy average threshold.
[0191] The third marking unit is used to mark the second sign sub-signal with an energy value greater than the third amplitude as a mutation signal when the average energy value of the second sign sub-signal is greater than the second energy average threshold and less than or equal to the first energy average threshold.
[0192] a fourth marking unit, configured to mark the second sign sub-signal with an energy value greater than a fourth amplitude as a mutation signal when the average energy value of the second sign sub-signal is less than a second energy average threshold;
[0193] The second splicing unit is used to splice adjacent mutation signals based on time sequence to obtain the target body motion signal.
[0194] The second duration acquisition unit is used to acquire the duration of the target body motion signal based on the second target time length.
[0195] In some optional implementations, the generating module 504 includes:
[0196] The signal spectrum acquisition unit is used to acquire the signal spectrum of the target body motion signal.
[0197] The high- and low-frequency energy acquisition unit is used to determine and compare the low-frequency energy and high-frequency energy of the target body motion signal based on the signal spectrum.
[0198] The generating unit is used to generate the detection result of the target body motion signal based on the comparison result.
[0199] In some optional embodiments, the body motion artifact detection device includes:
[0200] The duration judgment module is used to determine that the target body motion signal is a body motion artifact event when the duration is less than or equal to the first target time period.
[0201] The further functional description of each of the above modules and units is the same as that of the above corresponding embodiments and will not be repeated here.
[0202] The body motion artifact detection device in this embodiment is presented in the form of a functional unit, where the unit refers to an ASIC (Application Specific Integrated Circuit) circuit, a processor and memory that executes one or more software or fixed programs, and / or other devices that can provide the above functions.
[0203] The embodiment of the present invention also provides a computer device having the above Figure 5 The body motion artifact detection device shown.
[0204] See also Figure 6 , Figure 6 is a schematic diagram of the structure of a computer device provided by an optional embodiment of the present invention, such as Figure 6 As shown, the computer device includes: one or more processors 10, a memory 20, and interfaces for connecting various components, including high-speed interfaces and low-speed interfaces. Various components are connected to each other using different buses for communication, and can be installed on a common mainboard or installed in other ways as needed. The processor can process the instructions executed in the computer device, including instructions stored in or on the memory to display the graphical information of the GUI on an external input / output device (such as, a display device coupled to the interface). In some optional embodiments, if necessary, multiple processors and / or multiple buses can be used together with multiple memories and multiple memories. Similarly, multiple computer devices can be connected, and each device provides some necessary operations (for example, as a server array, a group of blade servers, or a multi-processor system). Figure 6 A processor 10 is taken as an example.
[0205] The processor 10 may be a central processing unit, a network processor or a combination thereof. The processor 10 may further include a hardware chip. The hardware chip may be a dedicated integrated circuit, a programmable logic device or a combination thereof. The programmable logic device may be a complex programmable logic device, a field programmable gate array, a general purpose array logic or any combination thereof.
[0206] The memory 20 stores instructions executable by at least one processor 10, so that at least one processor 10 executes the method shown in the above embodiment.
[0207] The memory 20 may include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application required for at least one function; the data storage area may store data created according to the use of the computer device, etc. In addition, the memory 20 may include a high-speed random access memory, and may also include a non-transient memory, such as at least one disk storage device, a flash memory device, or other non-transient solid-state storage device. In some optional embodiments, the memory 20 may optionally include a memory remotely arranged relative to the processor 10, and these remote memories may be connected to the computer device via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.
[0208] The memory 20 may include a volatile memory, such as a random access memory; the memory may also include a non-volatile memory, such as a flash memory, a hard disk or a solid state drive; the memory 20 may also include a combination of the above types of memory.
[0209] The computer device also includes an input device 30 and an output device 40. The processor 10, the memory 20, the input device 30 and the output device 40 may be connected via a bus or other means. Figure 6 The example of connecting through bus is taken in the following.
[0210] The input device 30 can receive input digital or character information, and generate key signal input related to the user settings and function control of the computer device, such as a touch screen, a keypad, a mouse, a track pad, a touch pad, an indicator bar, one or more mouse buttons, a trackball, a joystick, etc. The output device 40 may include a display device, an auxiliary lighting device (e.g., an LED) and a tactile feedback device (e.g., a vibration motor), etc. The above-mentioned display device includes but is not limited to a liquid crystal display, a light emitting diode, a display and a plasma display. In some optional embodiments, the display device can be a touch screen.
[0211] The embodiment of the present invention also provides a computer-readable storage medium. The method according to the embodiment of the present invention can be implemented in hardware, firmware, or can be implemented as a computer code that can be recorded in a storage medium, or can be implemented as a computer code that is originally stored in a remote storage medium or a non-temporary machine-readable storage medium and will be stored in a local storage medium through a network download, so that the method described herein can be stored in such software processing on a storage medium using a general-purpose computer, a dedicated processor, or programmable or dedicated hardware. Among them, the storage medium can be a magnetic disk, an optical disk, a read-only storage memory, a random access memory, a flash memory, a hard disk or a solid-state hard disk, etc.; further, the storage medium can also include a combination of the above types of memories. It can be understood that a computer, a processor, a microprocessor controller, or programmable hardware includes a storage component that can store or receive software or computer code. When the software or computer code is accessed and executed by a computer, a processor, or hardware, the method shown in the above embodiment is implemented.
[0212] A part of the present invention may be applied as a computer program product, such as a computer program instruction, which, when executed by a computer, can call or provide the method and / or technical solution according to the present invention through the operation of the computer. Those skilled in the art should understand that the existence of the computer program instruction in a computer-readable medium includes, but is not limited to, a source file, an executable file, an installation package file, etc., and accordingly, the way in which the computer program instruction is executed by the computer includes, but is not limited to: the computer directly executes the instruction, or the computer compiles the instruction and then executes the corresponding compiled program, or the computer reads and executes the instruction, or the computer reads and installs the instruction and then executes the corresponding installed program. Here, the computer-readable medium may be any available computer-readable storage medium or communication medium accessible to the computer.
[0213] Although the embodiments of the present invention have been described in conjunction with the accompanying drawings, those skilled in the art may make various modifications and variations without departing from the spirit and scope of the present invention, and such modifications and variations are all within the scope defined by the appended claims.
Claims
1. A method for detecting body motion artifacts, characterized in that: The method comprises: Collecting original vital sign signals, and performing sliding window segmentation on the original vital sign signals to obtain a vital sign signal sequence, wherein the vital sign signal sequence includes a plurality of vital sign signal segments; Based on the energy threshold, the vital sign signal segments in the vital sign signal sequence are divided to obtain a division result, and based on the division result, it is determined whether there is a target body motion signal in the vital sign signal segment; When there is a target body motion signal in the vital sign signal segment, acquiring the duration of the target body motion signal; In a case where the duration is greater than the first target time period, a signal spectrum of the target body motion signal is acquired to generate a detection result of the target body motion signal.
2. The method according to claim 1, characterized in that The performing sliding window segmentation on the original vital sign signal to obtain a vital sign signal sequence includes: Determine the size of the sliding window and the sliding step size; Placing the sliding window at a target position of the original vital sign signal, and segmenting the original vital sign signal based on the sliding step size; Based on the segmentation results, a vital sign signal sequence is constructed.
3. The method according to claim 1, characterized in that The step of dividing the vital sign signal segments in the vital sign signal sequence based on the energy threshold to obtain a division result, and judging whether there is a target body motion signal in the vital sign signal segment based on the division result, comprises: Dividing the vital sign signal segment into a plurality of first vital sign sub-signals of a first target time length to construct a first vital sign sub-signal sequence; acquiring energy values of each first sign sub-signal in the first sign sub-signal sequence to calculate an average energy value of the first sign sub-signals; When the average energy value of the first vital sign sub-signal is greater than the first energy threshold, a target body motion signal exists in the vital sign signal segment.
4. The method according to claim 3, characterized in that The acquiring the duration of the target body motion signal comprises: Acquire the energy value of each first vital sign sub-signal in the first vital sign sub-signal sequence of the vital sign signal segment; marking a first sign sub-signal whose energy value is greater than a first amplitude as a mutation signal; Based on the time sequence, adjacent mutation signals are spliced to obtain the target body movement signal; Based on the first target time length, a duration of the target body motion signal is acquired.
5. The method according to claim 1, characterized in that The method further comprises dividing the vital sign signal segments in the vital sign signal sequence based on the energy threshold to obtain a division result, and judging whether there is a target body motion signal in the vital sign signal segment based on the division result. Dividing the vital sign signal segment into a plurality of second vital sign sub-signals of a second target time length to construct a second vital sign sub-signal sequence; Acquiring energy values of each second sign sub-signal in the second sign sub-signal sequence to calculate an average energy value and a maximum energy value of the second sign sub-signal; When the ratio of the maximum energy value of the second vital sign sub-signal to the average energy value of the second vital sign sub-signal is greater than a second energy threshold, a target body motion signal exists in the vital sign signal segment.
6. The method according to claim 5, characterized in that The acquiring the duration of the target body motion signal comprises: Acquire an average energy value of a second sign sub-signal in a second sign sub-signal sequence of the sign signal segment; When the average energy value of the second sign sub-signal is greater than the first energy average threshold, marking the second sign sub-signal with an energy value greater than the second amplitude as a mutation signal; When the average energy value of the second sign sub-signal is greater than the second energy average threshold and less than or equal to the first energy average threshold, marking the second sign sub-signal with an energy value greater than the third amplitude as a mutation signal; When the average energy value of the second sign sub-signal is less than the second energy average threshold, marking the second sign sub-signal with an energy value greater than the fourth amplitude as a mutation signal; Based on the time sequence, adjacent mutation signals are spliced to obtain the target body movement signal; Based on the second target time length, the duration of the target body motion signal is acquired.
7. The method according to claim 1, characterized in that The acquiring the signal spectrum of the target body motion signal to generate the detection result of the target body motion signal includes: Acquire a signal spectrum of the target body motion signal; Based on the signal spectrum, determining and comparing low-frequency energy and high-frequency energy of the target body motion signal; Based on the comparison result, a detection result of the target body motion signal is generated.
8. The method according to claim 1, characterized in that The method further comprises: When the duration is less than or equal to the first target time period, the target body motion signal is a body motion artifact event.
9. A body motion artifact detection device, characterized in that: The device comprises: A segmentation module is used to collect original vital sign signals and perform sliding window segmentation on the original vital sign signals to obtain a vital sign signal sequence, wherein the vital sign signal sequence includes a plurality of vital sign signal segments; A judgment module, configured to divide the vital sign signal segments in the vital sign signal sequence based on an energy threshold, obtain a division result, and judge whether there is a target body motion signal in the vital sign signal segment based on the division result; an acquisition module, configured to acquire the duration of the target body motion signal when there is a target body motion signal in the vital sign signal segment; A generating module is used to obtain a signal spectrum of the target body motion signal when the duration is greater than a first target time period, so as to generate a detection result of the target body motion signal.
10. A computer device, characterized in that: include: A memory and a processor, wherein the memory and the processor are communicatively connected to each other, the memory stores computer instructions, and the processor executes the body motion artifact detection method according to any one of claims 1 to 8 by executing the computer instructions.