Heart rate signal tracking methods, tracking devices, electronic devices, and storage media
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-03-29
- Publication Date
- 2026-08-11
AI Technical Summary
通常,心率追踪算法是在前一时刻的心率附近(如+-6BPM(Beat PerMinute,每分钟心跳个数))搜索当前时刻的心率值,但是这种算法的缺点是:如果去除运动干扰后的PPG信号质量不好,则会将预测的心率值带到一个错误的区间,而没有办法得到真实的心率值
[0026]本申请实施例的非临时性计算机可读存储介质,通过执行上述的心率信号的追踪方法,可以用在心率追踪的跳转之中,能够大大提升心率追踪的精度。
Smart Images

Figure CN116919370B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of electronic equipment technology, and in particular to a method, tracking device, electronic device, and storage medium for tracking heart rate signals. Background Technology
[0002] As people's living standards continue to improve, wearable devices are becoming increasingly popular among consumers. Heart rate tracking algorithms based on PPG (Photo Pethysmo Graphic) signals are essential for wearable devices. Typically, heart rate tracking algorithms search for the current heart rate value within the range of the previous moment's heart rate (e.g., ±6 BPM). However, this algorithm has a drawback: if the quality of the PPG signal after removing motion interference is poor, it will lead the predicted heart rate value into an incorrect range, failing to obtain the true heart rate value.
[0003] Therefore, improving the accuracy of heart rate tracking by wearable devices is an urgent problem to be solved. Summary of the Invention
[0004] This application aims to at least partially solve one of the technical problems in the aforementioned technologies.
[0005] This application proposes a method for tracking heart rate signals, comprising: acquiring an original photoplethysmography (PPG) signal and a filtered PPG signal; performing short-time Fourier transforms on the original PPG signal and the filtered PPG signal respectively to obtain the corresponding spectra of the original PPG signal and the filtered PPG signal; generating corresponding first curve clusters and second curve clusters based on the spectra of the original PPG signal and the filtered PPG signal respectively; searching for coordinate points from all two-dimensional coordinate points on all curves in the first curve cluster that satisfy a first preset condition with each two-dimensional coordinate point on each curve in the second curve cluster, and using these as pairing points; wherein the two-dimensional coordinate points are used to represent time and frequency; detecting each curve in the second curve cluster, and if the parameters of the pairing points in the second curve cluster satisfy the second preset condition, then obtaining the jump heart rate value based on the curves in the second curve cluster whose parameters satisfy the second preset condition, so as to track the heart rate signal.
[0006] According to the heart rate signal tracking method of this application embodiment, the original photoplethysmography (PPG) signal and the filtered PPG signal are first acquired. Then, short-time Fourier transforms are performed on the original PPG signal and the filtered PPG signal respectively to obtain the corresponding spectra of the original PPG signal and the filtered PPG signal. Based on the spectra of the original PPG signal and the filtered PPG signal respectively, corresponding first curve clusters and second curve clusters are generated. From the two-dimensional coordinate points representing time and frequency on all curves in the first curve cluster, coordinate points that satisfy a first preset condition are found to be paired with the two-dimensional coordinate points on each curve in the second curve cluster. Further detection is performed on each curve in the second curve cluster. If the parameters of the paired points on the curves in the second curve cluster satisfy the second preset condition, the jump heart rate value is obtained based on the parameters of the paired points in the second curve cluster that satisfy the second preset condition, so as to track the heart rate signal. Therefore, this method can be used in the jump of heart rate tracking, which can greatly improve the accuracy of heart rate tracking.
[0007] In some embodiments, obtaining the jump heart rate value based on the curve in the second curve cluster that satisfies the second preset condition at the pairing point includes: obtaining the frequency corresponding to the pairing point as the jump heart rate value based on the time of the pairing point when the parameters of the pairing point satisfy the second preset condition at the pairing point.
[0008] In some embodiments, generating corresponding first curve clusters and second curve clusters based on the spectrum of the original PPG signal and the spectrum of the filtered PPG signal respectively includes: performing amplitude normalization processing on the spectrum of the original PPG signal and the spectrum of the filtered PPG signal respectively; obtaining corresponding multiple first point pairs and multiple second point pairs by finding local peaks on the spectrum of the amplitude-normalized original PPG signal and the spectrum of the amplitude-normalized filtered PPG signal respectively; wherein the first point pairs and the second point pairs are used to characterize point pairs of frequency and amplitude respectively; and generating corresponding first curve clusters and second curve clusters based on the multiple first point pairs and the multiple second point pairs respectively.
[0009] In some embodiments, generating the first curve cluster based on a plurality of first point pairs includes: when the current time is greater than zero, pairing the first point pair at the current time with the first point pair at the previous time according to a third preset condition; if the first point pair at the current time and the first point pair at the previous time are successfully paired according to the third preset condition, then determining whether the first point pair at the previous time is in a first curve; wherein, if the first point pair at the previous time is in the first curve, then adding the first point pair at the current time to the first curve; or, if the first point pair at the previous time is not in the first curve, then generating a second curve based on the first point pair at the current time and the first point pair at the previous time; and generating the first curve cluster based on the first curve and the second curve.
[0010] In some embodiments, after obtaining multiple first point pairs by finding local peaks in the spectrum of the original PPG signal after amplitude normalization, the method further includes: determining whether the amplitude of the first point pair is less than a first preset amplitude; if the amplitude of the first point pair is less than the first preset amplitude, then deleting the first point pair whose amplitude is less than the first preset amplitude.
[0011] In some embodiments, generating the second curve cluster based on a plurality of second point pairs includes: when the current time is greater than zero, pairing the second point pair at the current time with the second point pair at the previous time according to a fourth preset condition; if the second point pair at the current time and the second point pair at the previous time are successfully paired according to the fourth preset condition, then determining whether the second point pair at the previous time is in a third curve; wherein, if the second point pair at the previous time is in the third curve, then adding the second point pair at the current time to the third curve; or, if the second point pair at the previous time is not in the third curve, then generating a fourth curve based on the second point pair at the current time and the second point pair at the previous time; and generating the second curve cluster based on the third curve and the fourth curve.
[0012] In some embodiments, after obtaining multiple second point pairs by finding local peaks in the spectrum of the filtered PPG signal after amplitude normalization, the method further includes: determining whether the amplitude of the second point pair is less than a second preset amplitude; if the amplitude of the second point pair is less than the second preset amplitude, deleting the second point pair whose amplitude is less than the second preset amplitude; wherein the second preset amplitude is greater than a first preset amplitude.
[0013] In some embodiments, obtaining the filtered PPG signal includes: using a filtering algorithm to filter the acceleration signal from the original PPG signal to obtain the filtered PPG signal.
[0014] This application proposes a heart rate signal tracking device, comprising: a first acquisition module for acquiring an original photoplethysmography (PPG) signal and a filtered PPG signal; a processing module for performing short-time Fourier transforms on the original PPG signal and the filtered PPG signal respectively to obtain the corresponding spectra of the original PPG signal and the filtered PPG signal; a generation module for generating corresponding first curve clusters and second curve clusters based on the spectra of the original PPG signal and the filtered PPG signal respectively; a search module for searching from all two-dimensional coordinate points on all curves in the first curve cluster that satisfy a first preset condition with each two-dimensional coordinate point on each curve in the second curve cluster, as a pairing point; wherein the two-dimensional coordinate points are used to represent time and frequency; and a second acquisition module for detecting each curve in the second curve cluster, and if there are pairing points in the second curve cluster whose parameters satisfy the second preset condition, then acquiring the jump heart rate value based on the curves in the second curve cluster whose parameters satisfy the second preset condition, so as to track the heart rate signal.
[0015] The heart rate signal tracking device according to an embodiment of this application acquires the original photoplethysmography (PPG) signal and the filtered PPG signal through a first acquisition module. A processing module performs short-time Fourier transforms on the original and filtered PPG signals respectively to obtain the corresponding spectra of the original and filtered PPG signals. A generation module generates corresponding first and second curve clusters based on the spectra of the original and filtered PPG signals respectively. A search module searches for coordinate points in the first curve cluster that satisfy a first preset condition from the two-dimensional coordinate points representing time and frequency on each curve, using these as pairing points. A second acquisition module detects each curve in the second curve cluster. If a pairing point in the second curve cluster satisfies the second preset condition, the jump heart rate value is obtained from the curve in the second curve cluster whose parameters satisfy the second preset condition, thus enabling heart rate signal tracking. Therefore, this device can be used in heart rate tracking jumps, significantly improving the accuracy of heart rate tracking.
[0016] In some embodiments, the second acquisition module is configured to: acquire the frequency corresponding to the pairing point as the jump heart rate value based on the time of the pairing point when the parameters of the pairing point meet the second preset condition.
[0017] In some embodiments, the generation module is configured to: perform amplitude normalization processing on the spectrum of the original PPG signal and the spectrum of the filtered PPG signal respectively; and obtain a plurality of first point pairs and a plurality of second point pairs by finding local peaks in the spectrum of the amplitude-normalized original PPG signal and the spectrum of the amplitude-normalized filtered PPG signal respectively; and generate a corresponding first curve cluster and a second curve cluster based on the plurality of first point pairs and the plurality of second point pairs respectively; wherein the first point pairs and the second point pairs are used to represent point pairs of frequency and amplitude respectively.
[0018] In some embodiments, when the generation module generates the first curve cluster based on multiple first point pairs, it is configured to: when the current time is greater than zero, pair the first point pair at the current time with the first point pair at the previous time according to a third preset condition; when the first point pair at the current time and the first point pair at the previous time are successfully paired according to the third preset condition, determine whether the first point pair at the previous time is in the first curve; wherein, if the first point pair at the previous time is in the first curve, then add the first point pair at the current time to the first curve; or, if the first point pair at the previous time is not in the first curve, then generate a second curve based on the first point pair at the current time and the first point pair at the previous time, and further generate the first curve cluster based on the first curve and the second curve.
[0019] In some embodiments, the generation module is configured to: after finding local peaks in the spectrum of the original PPG signal after amplitude normalization to obtain multiple first point pairs, determine whether the amplitude of the first point pair is less than a first preset amplitude; if the amplitude of the first point pair is less than the first preset amplitude, delete the first point pair whose amplitude is less than the first preset amplitude.
[0020] In some embodiments, when the generation module generates the second curve cluster based on multiple second point pairs, it is configured to: when the current time is greater than zero, pair the second point pair at the current time with the second point pair at the previous time according to a fourth preset condition, and when the second point pair at the current time and the second point pair at the previous time are successfully paired according to the fourth preset condition, determine whether the second point pair at the previous time is in the third curve; wherein, if the second point pair at the previous time is in the third curve, then add the second point pair at the current time to the third curve; or, if the second point pair at the previous time is not in the third curve, then generate a fourth curve based on the second point pair at the current time and the second point pair at the previous time, and further generate the second curve cluster based on the third curve and the fourth curve.
[0021] In some embodiments, the generation module is configured to: after finding local peaks in the spectrum of the filtered PPG signal after amplitude normalization to obtain multiple second point pairs, determine whether the amplitude of the second point pair is less than a second preset amplitude; if the amplitude of the second point pair is less than the second preset amplitude, delete the second point pair whose amplitude is less than the second preset amplitude; wherein the second preset amplitude is greater than a first preset amplitude.
[0022] In some embodiments, after acquiring the filtered PPG signal, the first acquisition module is configured to: use a filtering algorithm to filter the acceleration signal from the original PPG signal to obtain the filtered PPG signal.
[0023] This application also proposes an electronic device, including: a processor; a memory for storing processor-executable instructions; wherein the processor is configured to execute the instructions to implement the above-described heart rate signal tracking method.
[0024] The electronic device of this application embodiment, by executing the above-described heart rate signal tracking method, can be used in the transition of heart rate tracking, which can greatly improve the accuracy of heart rate tracking.
[0025] This application also proposes a non-transitory computer-readable storage medium that, when the instructions in the storage medium are executed by the processor of an electronic device, enables the electronic device to perform the above-described heart rate signal tracking method.
[0026] The non-transitory computer-readable storage medium of this application embodiment, by executing the above-described heart rate signal tracking method, can be used in the transition of heart rate tracking, which can greatly improve the accuracy of heart rate tracking. Attached Figure Description
[0027] Figure 1 This is a flowchart of a heart rate signal tracking method according to an embodiment of this application;
[0028] Figure 2 This is a spectrum diagram of the original PPG signal and the filtered PPG signal according to an embodiment of this application;
[0029] Figure 3 This is a block diagram of a heart rate signal tracking device according to an embodiment of this application;
[0030] Figure 4 This is a structural block diagram of an electronic device according to an embodiment of this application. Detailed Implementation
[0031] The embodiments of this application are described in detail below. Examples of these embodiments are shown in the accompanying drawings, wherein the same or similar reference numerals denote the same or similar elements or elements having the same or similar functions throughout. The embodiments described below with reference to the accompanying drawings are exemplary and intended to explain this application, and should not be construed as limiting this application.
[0032] The following description, in conjunction with the accompanying drawings, describes a method for tracking heart rate signals, a device for tracking heart rate signals, an electronic device, and a non-transitory computer-readable storage medium.
[0033] With the continuous improvement of people's living standards, wearable devices are becoming increasingly popular among consumers. Heart rate tracking algorithms based on PPG signals are essential for wearable devices. PPG is a method that uses light to illuminate the skin and measures light scattering caused by blood flow. The principle is as follows: green light emitted by an LED (Light Emitting Diode) in an optical sensor passes through the tissues and arteries / veins in the skin, and is absorbed and reflected back to the photosensor. When reflected back to the photosensor, the green light undergoes some attenuation. The absorption of green light by muscles, bones, veins, and other connecting tissues remains relatively constant (provided there is no significant movement at the measurement site). However, blood is different; due to the flow of blood in arteries, its absorption of light naturally changes. Then, the green light is converted into an electrical signal. Because the absorption of green light by arteries changes while the absorption by other tissues remains relatively constant, the resulting signal can be divided into a direct current (DC) signal and an alternating current (AC) signal. Finally, extracting the AC signal reveals the characteristics of blood flow.
[0034] Typically, heart rate tracking algorithms search for the current heart rate value within the range of the previous heart rate (e.g., ±6 BPM). However, this algorithm has a drawback: if the quality of the PPG signal after removing motion interference is poor, it can lead the predicted heart rate value into an incorrect range, failing to obtain the true heart rate value. Therefore, when it is determined that the heart rate signal in the range of the current heart rate value is poor, and a better quality heart rate value is available, the heart rate should jump to the better quality heart rate value. However, the better quality heart rate value that jumps to may also be a noisy signal, leading to even greater errors.
[0035] Therefore, this application proposes a novel method for tracking heart rate signals, which can measure the quality of heart rate signals in real time and improve the tracking accuracy of heart rate signals.
[0036] Figure 1 This is a flowchart of a heart rate signal tracking method according to an embodiment of this application.
[0037] In the embodiments of this application, the heart rate signal tracking method is applied in a wearable device, which may be a smartwatch or a smart bracelet, etc.
[0038] like Figure 1 As shown in the figure, the heart rate tracking method of the wearable device in this application includes the following steps:
[0039] S101, acquire the original photoplethysmography (PPG) signal and the filtered PPG signal.
[0040] As an optional implementation, obtaining the filtered PPG signal includes: using a filtering algorithm to filter the acceleration signal from the original PPG signal to obtain the filtered PPG signal.
[0041] In this step, the raw PPG signal is acquired using an optical sensor, such as a PPG optical module. This raw PPG signal contains motion signals, such as acceleration signals. After acquiring the raw PPG signal, relevant filtering algorithms, such as RLS (Recursive Least Squares), can be used to filter out the motion signals, such as acceleration signals, from the raw PPG signal. The raw PPG signal and the filtered PPG signal are then stored until a certain amount of time is reached (e.g., 8 seconds).
[0042] S102 performs short-time Fourier transform on the original PPG signal and the filtered PPG signal respectively to obtain the spectrum of the original PPG signal and the spectrum of the filtered PPG signal.
[0043] In this step, after acquiring a certain amount of the original PPG signal, a short-time Fourier transform is performed on the original PPG signal to obtain the amplitude value of a certain spectral interval at time T, which is the spectrum of the original PPG signal; and, after acquiring a certain amount of the original PPG signal, a short-time Fourier transform is performed on the original PPG signal to obtain the amplitude value of a certain spectral interval at time T, which is the spectrum of the filtered PPG signal.
[0044] S103 generates the corresponding first curve cluster and second curve cluster based on the spectrum of the original PPG signal and the spectrum of the filtered PPG signal, respectively.
[0045] As an optional implementation, step S103 includes: performing amplitude normalization processing on the spectrum of the original PPG signal and the spectrum of the filtered PPG signal respectively; finding local peaks in the spectrum of the original PPG signal after amplitude normalization and the spectrum of the filtered PPG signal after amplitude normalization to obtain corresponding first point pairs and multiple second point pairs; wherein the first point pairs and the second point pairs are used to characterize point pairs of frequency and amplitude respectively; and generating corresponding first curve clusters and second curve clusters based on the multiple first point pairs and the multiple second point pairs respectively.
[0046] In this step, the original PPG signal is processed as follows: the amplitude of the original PPG signal's spectrum is normalized to the maximum and minimum values, normalized to the range of 0-1. For example, the amplitude can be normalized by dividing the current amplitude by the maximum amplitude. Then, the spectrum of the original PPG signal after amplitude normalization is analyzed by finding local peaks to obtain frequency-amplitude pairs, thus obtaining multiple first point pairs. Finally, based on the multiple first point pairs, a first curve cluster is generated.
[0047] The filtered PPG signal is processed as follows: The amplitude of the filtered PPG signal's spectrum is normalized to the maximum and minimum values, normalized to a range of 0-1. For example, the current amplitude can be divided by the maximum amplitude. Then, the spectrum of the normalized filtered PPG signal is analyzed by finding local peaks to obtain frequency-amplitude pairs, thus generating multiple second pairings. Finally, a second set of curves is generated based on these second pairings.
[0048] As an optional implementation for generating the first curve cluster, when the current time is greater than zero, the first point pair at the current time and the first point pair at the previous time are paired according to a third preset condition; if the first point pair at the current time and the first point pair at the previous time are successfully paired according to the third preset condition, it is determined whether the first point pair at the previous time is in the first curve; if the first point pair at the previous time is in the first curve, the first point pair at the current time is added to the first curve; or, if the first point pair at the previous time is not in the first curve, a second curve is generated based on the first point pair at the current time and the first point pair at the previous time; the first curve cluster is generated based on the first curve and the second curve.
[0049] In this step, if the current time is zero, no processing is performed; if the current time is greater than zero, the first point pair of the current time is paired with the first point pair of the previous time according to a third preset condition. One implementation of the third preset condition is that the frequency of the first point pair of the current time differs from the frequency of the first point pair of the previous time by within 6 BPM. If the first point pair of the current time and the first point pair of the previous time satisfy the third preset condition, it is determined whether the first point pair of the previous time is already in the first curve. If the first point pair of the previous time is already in the first curve, the first point pair of the current time is added to the first curve, thus increasing the length of the first curve; if the first point pair of the current time is not in a curve, a new curve is generated from the first point pair of the previous time and the first point pair of the current time, serving as the second curve.
[0050] As time increases, steps S101-S103 are executed cyclically, resulting in a curve cluster composed of multiple first curves and multiple second curves, which serves as the first curve cluster.
[0051] To further improve the accuracy of heart rate signal tracking, after finding local peaks in the spectrum of the original PPG signal after amplitude normalization to obtain multiple first point pairs, the method further includes: determining whether the amplitude of the first point pair is less than a first preset amplitude; if the amplitude of the first point pair is less than the first preset amplitude, then deleting the first point pair with an amplitude less than the first preset amplitude. The first preset amplitude can be set according to actual needs, for example, it can be 0.1.
[0052] In other words, after finding local peaks in the spectrum of the original PPG signal after amplitude normalization, multiple first point pairs are obtained. In order to further improve the accuracy of heart rate signal tracking, it is necessary to determine whether the amplitude of each first point pair is less than a first preset amplitude (such as 0.1). If the amplitude of the first point pair is less than the first preset amplitude, the first point pair is deleted. This way, multiple first point pairs can be filtered.
[0053] As an optional implementation for generating the second curve cluster, when the current time is greater than zero, the second point pair at the current time and the second point pair at the previous time are paired according to the fourth preset condition; if the second point pair at the current time and the second point pair at the previous time are successfully paired according to the fourth preset condition, it is determined whether the second point pair at the previous time is in the third curve; if the second point pair at the previous time is in the third curve, the second point pair at the current time is added to the third curve; or, if the second point pair at the previous time is not in the third curve, a fourth curve is generated based on the second point pair at the current time and the second point pair at the previous time; and a second curve cluster is generated based on the third curve and the fourth curve.
[0054] In this step, if the current time is zero, no processing is performed; if the current time is greater than zero, the second point pair at the current time is paired with the second point pair at the previous time according to the fourth preset condition. The fourth preset condition can be the same as the third preset condition, implemented by ensuring that the frequency of the second point pair at the current time differs from the frequency of the second point pair at the previous time by within 6 BPM. If the second point pair at the current time and the second point pair at the previous time satisfy the fourth preset condition, it is determined whether the second point pair at the previous time is already in the third curve. If the second point pair at the previous time is already in the third curve, the second point pair at the current time is added to the third curve, thus increasing the length of the third curve; if the second point pair at the current time is not in a curve, a new curve is generated from the second point pair at the previous time and the second point pair at the current time, serving as the fourth curve.
[0055] As time increases, steps S101-S103 are executed cyclically, resulting in a curve cluster composed of multiple third curves and multiple fourth curves, which serves as the second curve cluster.
[0056] To further improve the accuracy of heart rate signal tracking, after finding local peaks in the spectrum of the filtered PPG signal with normalized amplitude, the method further includes: determining whether the amplitude of the second point pair is less than a second preset amplitude; if the amplitude of the second point pair is less than the second preset amplitude, deleting the second point pair with an amplitude less than the second preset amplitude; wherein the second preset amplitude is greater than a first preset amplitude. The second preset amplitude can be set according to actual needs, for example, it can be 0.6.
[0057] In other words, after finding local peaks in the spectrum of the filtered PPG signal after amplitude normalization, multiple second point pairs are obtained. In order to further improve the accuracy of heart rate signal tracking, it is necessary to determine whether the amplitude of each second point pair is less than a second preset amplitude (such as 0.6). If the amplitude of the second point pair is less than the second preset amplitude, the second point pair is deleted. This way, multiple second point pairs can be filtered.
[0058] S104. From all the two-dimensional coordinate points on all the curves in the first curve cluster, find the coordinate points that satisfy the first preset condition with the two-dimensional coordinate points on each curve in the second curve cluster, and use them as pairing points; wherein, the two-dimensional coordinate points are used to represent time and frequency.
[0059] In other words, the second curve cluster is projected onto the first curve cluster to find paired points. Specifically, for each point on each curve in the second curve cluster, it is checked whether there are points in the first curve cluster with similar two-dimensional coordinates (i.e., whether they meet the first preset condition, such as the difference between the two two-dimensional coordinates being within a certain range). If such points exist, they are used as paired points.
[0060] S105, each curve in the second curve cluster is detected. If the parameters of the paired points of the curves in the second curve cluster meet the second preset condition, the jump heart rate value is obtained according to the curves in the second curve cluster whose parameters of the paired points meet the second preset condition, so as to track the heart rate signal.
[0061] As an optional implementation, step S105 includes: obtaining the frequency corresponding to the pairing point as the jump heart rate value based on the time when the parameters of the pairing point meet the second preset condition.
[0062] In this step, each curve in the second curve cluster is detected. If the number of paired points on a curve L is greater than a set number (which can be set according to actual needs), and the percentage of paired points is greater than a set percentage (which can be set according to actual needs), then the parameters of the paired points on curve L meet the second preset condition, and a jump point can be found on curve L. This jump point is the frequency of the paired points corresponding to the time when the parameters of the paired points meet the second preset condition. At this time, if the currently tracked heart rate value is different from (e.g., significantly different from) the jump heart rate of curve L, a heart rate jump can be performed.
[0063] Typically, heart rate tracking algorithms operate as follows:
[0064] First, the heart rate from the previous moment is obtained. For the current moment, the new heart rate is searched for at 6 BPM above the previous heart rate. However, when the heart rate signal is weak, the tracking error is amplified. Conversely, when the heart rate signal is strong, the algorithm cannot accurately track the heart rate. Figure 2 As shown.
[0065] Therefore, this application proposes an improved algorithm:
[0066] After obtaining the first and second curve clusters, each curve in the second curve cluster is checked. If the number of paired points on a curve L is greater than a set number, and the percentage of paired points is greater than a set percentage, a jump point can be found on curve L. This jump point is the time of the two-dimensional coordinates of the paired point at the current moment, corresponding to the frequency of the paired point. At this time, if the currently tracked heart rate value is different from the jump heart rate of curve L, a heart rate jump can be performed, such as... Figure 2 As shown.
[0067] In summary, the heart rate signal tracking method according to the embodiments of this application first acquires the original photoplethysmography (PPG) signal and the filtered PPG signal. Then, it performs short-time Fourier transform on the original PPG signal and the filtered PPG signal respectively to obtain the corresponding spectra of the original PPG signal and the filtered PPG signal. Based on the spectra of the original PPG signal and the filtered PPG signal respectively, it generates corresponding first and second curve clusters. From the two-dimensional coordinate points representing time and frequency on all curves in the first curve cluster, it searches for coordinate points that satisfy a first preset condition with the two-dimensional coordinate points on each curve in the second curve cluster, and uses these as pairing points. Further, it detects each curve in the second curve cluster. If the parameters of the pairing points on the curves in the second curve cluster satisfy the second preset condition, it obtains the jump heart rate value based on the parameters of the pairing points in the second curve cluster that satisfy the second preset condition, in order to track the heart rate signal. Therefore, this method can be used in heart rate tracking jumps, improving the quality of the jump point signal, greatly enhancing the accuracy of heart rate tracking, and improving the competitiveness of wearable devices.
[0068] Figure 3 This is a block diagram of a heart rate signal tracking device according to an embodiment of this application.
[0069] like Figure 3 The heart rate signal tracking device 300 described in this application embodiment includes: a first acquisition module 301, a processing module 302, a generation module 303, a search module 304, and a second acquisition module 305.
[0070] The first acquisition module 301 acquires the original photoplethysmography (PPG) signal and the filtered PPG signal. The processing module 302 performs short-time Fourier transforms on the original PPG signal and the filtered PPG signal respectively to obtain the corresponding spectra of the original PPG signal and the filtered PPG signal. The generation module 303 generates a first curve cluster and a second curve cluster based on the spectra of the original PPG signal and the filtered PPG signal respectively. The search module 304 searches for coordinate points from all two-dimensional coordinate points on all curves in the first curve cluster that satisfy a first preset condition with each two-dimensional coordinate point on each curve in the second curve cluster, and uses these as pairing points, where the two-dimensional coordinate points represent time and frequency. The second acquisition module 305 detects each curve in the second curve cluster. If there are pairing points in the second curve cluster whose parameters satisfy the second preset condition, the jump heart rate value is acquired based on the curves in the second curve cluster whose parameters satisfy the second preset condition, so as to track the heart rate signal.
[0071] In some embodiments, the second acquisition module 305 is used to: acquire the frequency corresponding to the pairing point as the jump heart rate value based on the time of the pairing point when the parameters of the pairing point meet the second preset condition.
[0072] In some embodiments, the generation module 303 is configured to: perform amplitude normalization processing on the spectrum of the original PPG signal and the spectrum of the filtered PPG signal respectively, and obtain a plurality of first point pairs and a plurality of second point pairs by finding local peaks in the spectrum of the amplitude-normalized original PPG signal and the spectrum of the amplitude-normalized filtered PPG signal respectively, and generate a corresponding first curve cluster and a second curve cluster based on the plurality of first point pairs and the plurality of second point pairs respectively; wherein the first point pairs and the second point pairs are used to characterize point pairs of frequency and amplitude respectively.
[0073] In some embodiments, when the generation module 303 generates the first curve cluster based on a plurality of first point pairs, it is configured to: when the current time is greater than zero, pair the first point pair at the current time with the first point pair at the previous time according to a third preset condition; when the first point pair at the current time and the first point pair at the previous time are successfully paired according to the third preset condition, determine whether the first point pair at the previous time is in the first curve; wherein, if the first point pair at the previous time is in the first curve, then add the first point pair at the current time to the first curve; or, if the first point pair at the previous time is not in the first curve, then generate a second curve based on the first point pair at the current time and the first point pair at the previous time, and further generate the first curve cluster based on the first curve and the second curve.
[0074] In some embodiments, the generation module 303 is configured to: after finding local peaks in the spectrum of the original PPG signal after amplitude normalization to obtain multiple first point pairs, determine whether the amplitude of the first point pair is less than a first preset amplitude; if the amplitude of the first point pair is less than the first preset amplitude, delete the first point pair whose amplitude is less than the first preset amplitude.
[0075] In some embodiments, when the generation module 303 generates the second curve cluster based on a plurality of second point pairs, it is configured to: when the current time is greater than zero, pair the second point pair at the current time with the second point pair at the previous time according to a fourth preset condition, and when the second point pair at the current time and the second point pair at the previous time are successfully paired according to the fourth preset condition, determine whether the second point pair at the previous time is in the third curve; wherein, if the second point pair at the previous time is in the third curve, then add the second point pair at the current time to the third curve; or, if the second point pair at the previous time is not in the third curve, then generate a fourth curve based on the second point pair at the current time and the second point pair at the previous time, and further generate the second curve cluster based on the third curve and the fourth curve.
[0076] In some embodiments, the generation module 303 is configured to: after finding local peaks in the spectrum of the filtered PPG signal after amplitude normalization to obtain multiple second point pairs, determine whether the amplitude of the second point pair is less than a second preset amplitude; if the amplitude of the second point pair is less than the second preset amplitude, delete the second point pair whose amplitude is less than the second preset amplitude; wherein the second preset amplitude is greater than a first preset amplitude.
[0077] In some embodiments, after acquiring the filtered PPG signal, the first acquisition module 301 is configured to: use a filtering algorithm to filter the acceleration signal from the original PPG signal to obtain the filtered PPG signal.
[0078] It should be noted that the implementation process of the heart rate signal tracking device in this embodiment of the present disclosure is explained in the foregoing description of the method in this embodiment of the present disclosure, and will not be repeated here.
[0079] According to the heart rate signal tracking device of this application embodiment, the first acquisition module acquires the original photoplethysmography (PPG) signal and the filtered PPG signal. The processing module performs short-time Fourier transform on the original PPG signal and the filtered PPG signal respectively to obtain the corresponding spectra of the original PPG signal and the filtered PPG signal. The generation module generates corresponding first curve clusters and second curve clusters based on the spectra of the original PPG signal and the filtered PPG signal respectively. The search module searches for coordinate points that satisfy a first preset condition from the two-dimensional coordinate points representing time and frequency on all curves in the first curve cluster, and uses these coordinate points as pairing points. The second acquisition module detects each curve in the second curve cluster. If there are pairing points in the second curve cluster whose parameters satisfy the second preset condition, the jump heart rate value is obtained based on the parameters of the pairing points in the second curve cluster that satisfy the second preset condition, so as to track the heart rate signal. Therefore, this device can be used in heart rate tracking jumps, which can improve the quality of the jump point signal, greatly improve the accuracy of heart rate tracking, and enhance the competitiveness of wearable devices.
[0080] Based on the above embodiments, this application also proposes an electronic device, including: a processor; a memory for storing processor-executable instructions; wherein the processor is configured to execute the instructions to implement the above-described heart rate tracking method for wearable devices.
[0081] Figure 4 This is a structural block diagram of an electronic device according to an embodiment of the present disclosure.
[0082] like Figure 4 The electronic device 400 includes a memory 410 and a processor 420, and a bus 430 connecting the different components (including the memory 410 and the processor 420).
[0083] The memory 410 is used to store executable instructions of the processor 420; the processor 401 is configured to call and execute the executable instructions stored in the memory 402 to implement the heart rate signal tracking method proposed in the above embodiments of this disclosure.
[0084] Bus 430 represents one or more of several bus architectures, including a memory bus or memory controller, a peripheral bus, a graphics acceleration port, a processor, or a local bus using any of the various bus architectures. Examples of these architectures include, but are not limited to, the Industry Standard Architecture (ISA) bus, the Micro Channel Architecture (MAC) bus, the Enhanced ISA bus, the Video Electronics Standards Association (VESA) local bus, and the Peripheral Component Interconnect (PCI) bus.
[0085] Electronic device 400 typically includes a variety of electronic device readable media. These media can be any available media that can be accessed by electronic device 800, including volatile and non-volatile media, removable and non-removable media.
[0086] Memory 410 may also include computer system readable media in the form of volatile memory, such as random access memory (RAM) 440 and / or cache memory 450. Electronic device 400 may further include other removable / non-removable, volatile / non-volatile computer system storage media. By way of example only, storage system 460 may be used to read and write non-removable, non-volatile magnetic media (… Figure 4 Not shown; usually referred to as a "hard drive"). Although Figure 4 Not shown, a disk drive for reading and writing to a removable non-volatile disk (e.g., a "floppy disk") and an optical disk drive for reading and writing to a removable non-volatile optical disk (e.g., a CD-ROM, DVD-ROM, or other optical media) may be provided. In these cases, each drive may be connected to bus 430 via one or more data media interfaces. Memory 410 may include at least one program product having a set (e.g., at least one) of program modules configured to perform the functions of the embodiments of this disclosure.
[0087] A program / utility 480 having a set (at least one) of program modules 470 may be stored, for example, in memory 410. Such program modules 470 include—but are not limited to—an operating system, one or more functions, other program modules, and program data. Each or some combination of these examples may include an implementation of a network environment. Program modules 470 typically perform the functions and / or methods described in the embodiments of this disclosure.
[0088] Electronic device 400 can also communicate with one or more external devices 490 (e.g., keyboard, pointing device, display 491, etc.), and with one or more devices that enable a user to interact with the electronic device 400, and / or with any device that enables the electronic device 400 to communicate with one or more other computing devices (e.g., network card, modem, etc.). This communication can be performed via input / output (I / O) interface 492. Furthermore, electronic device 400 can also communicate with one or more networks (e.g., local area network (LAN), wide area network (WAN), and / or public networks, such as the Internet) via network adapter 493. As shown, network adapter 493 communicates with other modules of electronic device 400 via bus 430. It should be understood that, although not shown in the figures, other hardware and / or software modules can be used in conjunction with electronic device 400, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data backup storage systems.
[0089] The processor 420 performs various functional applications and data processing by running programs stored in the memory 410.
[0090] It should be noted that the implementation process of the electronic device in the embodiments of this disclosure is described in the foregoing explanation of the method in the embodiments of this disclosure, and will not be repeated here.
[0091] The electronic device of this application embodiment can improve the quality of the jump point signal by executing the above-described heart rate signal tracking method, greatly improve the accuracy of heart rate tracking, and enhance the competitiveness of wearable devices.
[0092] Based on the above embodiments, this application also proposes a non-transitory computer-readable storage medium, which, when the instructions in the storage medium are executed by the processor of an electronic device, enables the electronic device to perform the above-described heart rate signal tracking method.
[0093] The non-transitory computer-readable storage medium of this application embodiment can improve the quality of the jump point signal by executing the above-described heart rate signal tracking method, greatly improve the accuracy of heart rate tracking, and enhance the competitiveness of wearable devices.
[0094] Based on the above embodiments, this application also proposes a computer program product that, when executed by the processor of an electronic device, enables the electronic device to perform the heart rate signal tracking method as described above.
[0095] The computer program product of this application embodiment, by executing the above-described heart rate tracking method for wearable devices, can improve the quality of the jump point signal, greatly enhance the accuracy of heart rate tracking, and improve the competitiveness of wearable devices.
[0096] In the description of this application, it should be understood that the terms "center", "longitudinal", "lateral", "length", "width", "thickness", "upper", "lower", "front", "rear", "left", "right", "vertical", "horizontal", "top", "bottom", "inner", "outer", "clockwise", "counterclockwise", "axial", "radial", "circumferential", etc., indicate the orientation or positional relationship based on the orientation or positional relationship shown in the accompanying drawings. They are used only for the convenience of describing this application and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation. Therefore, they should not be construed as limitations on this application.
[0097] Furthermore, the terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of that feature. In the description of this application, "multiple" means two or more, unless otherwise explicitly specified.
[0098] In this application, unless otherwise expressly specified and limited, the terms "installation," "connection," "linking," and "fixing," etc., should be interpreted broadly. For example, they can refer to a fixed connection, a detachable connection, or an integral part; they can refer to a mechanical connection or an electrical connection; they can refer to a direct connection or an indirect connection through an intermediate medium; they can refer to the internal communication of two components or the interaction between two components. Those skilled in the art can understand the specific meaning of the above terms in this application according to the specific circumstances.
[0099] In this application, unless otherwise expressly specified and limited, "above" or "below" the second feature can mean that the first feature is in direct contact with the second feature, or that the first feature is in indirect contact with the second feature through an intermediate medium. Furthermore, "above," "on top of," and "over" the second feature can mean that the first feature is directly above or diagonally above the second feature, or simply that the first feature is at a higher horizontal level than the second feature. "Below," "below," and "under" the second feature can mean that the first feature is directly below or diagonally below the second feature, or simply that the first feature is at a lower horizontal level than the second feature.
[0100] In the description of this specification, the references to terms such as "one embodiment," "some embodiments," "example," "specific example," or "some examples," etc., refer to specific features, structures, materials, or characteristics described in connection with that embodiment or example, which are included in at least one embodiment or example of this application. In this specification, the illustrative expressions of the above terms do not necessarily refer to the same embodiment or example. Furthermore, the specific features, structures, materials, or characteristics described may be combined in any suitable manner in one or more embodiments or examples. Moreover, without contradiction, those skilled in the art can combine and integrate the different embodiments or examples described in this specification, as well as the features of different embodiments or examples.
[0101] Although embodiments of this application have been shown and described above, it is understood that the above embodiments are exemplary and should not be construed as limiting this application. Those skilled in the art can make changes, modifications, substitutions and variations to the above embodiments within the scope of this application.
Claims
1. A method for tracking heart rate signals, characterized in that, include: Acquire the original photoplethysmography (PPG) signal and the filtered PPG signal; Short-time Fourier transforms are performed on the original PPG signal and the filtered PPG signal respectively to obtain the corresponding spectra of the original PPG signal and the spectrum of the filtered PPG signal. Based on the spectrum of the original PPG signal and the spectrum of the filtered PPG signal, a first curve cluster and a second curve cluster are generated respectively. The first curve cluster includes at least one curve, and the second curve cluster includes at least one curve. From all time-frequency coordinate points on all curves in the first curve cluster, find coordinate points whose differences from each time-frequency coordinate point on each curve in the second curve cluster are within a certain range, and use them as pairing points. The pairing points of each curve in the second curve cluster are detected to determine whether the curve meets the preset conditions. The preset conditions include: the number of pairing points is greater than a set number, and the ratio of pairing points is greater than a set ratio. In response to the existence of a curve in the second curve cluster that satisfies the preset condition, the jump heart rate value is obtained based on the curve that satisfies the preset condition.
2. The heart rate signal tracking method as described in claim 1, characterized in that, The step of obtaining the jump heart rate value based on the curve that satisfies the preset conditions includes: Based on the time of the pairing point of the curve that meets the preset conditions, the corresponding frequency is obtained, and the corresponding frequency is used as the jump heart rate value.
3. The heart rate signal tracking method as described in claim 1, characterized in that, The step of generating corresponding first curve clusters and second curve clusters based on the spectrum of the original PPG signal and the spectrum of the filtered PPG signal, respectively, includes: The amplitude normalization process is performed on the spectrum of the original PPG signal and the spectrum of the filtered PPG signal, respectively. By finding local peaks in the spectrum of the original PPG signal after amplitude normalization and the spectrum of the filtered PPG signal after amplitude normalization, multiple first frequency-amplitude point pairs and multiple second frequency-amplitude point pairs are obtained. The first curve cluster is generated based on multiple first frequency-amplitude point pairs, and the second curve cluster is generated based on multiple second frequency-amplitude point pairs.
4. The heart rate signal tracking method as described in claim 3, characterized in that, The step of generating the first curve cluster based on multiple first frequency-amplitude point pairs includes: When the current time is greater than zero, the first frequency-amplitude point pair at the current time is paired with the first frequency-amplitude point pair at the previous time. In response to the successful pairing of the first frequency-amplitude point pair at the current moment and the first frequency-amplitude point pair at the previous moment, a curve including the first frequency-amplitude point pair at the current moment and the first frequency-amplitude point pair at the previous moment is obtained.
5. The heart rate signal tracking method as described in claim 4, characterized in that, The process of obtaining the curve, which includes the first frequency-amplitude point pair at the current moment and the first frequency-amplitude point pair at the previous moment, includes: In response to the first frequency-amplitude point pair at the previous moment being in the first curve of the first curve family, the first frequency-amplitude point pair at the current moment is added to the first curve; or, In response to the fact that the first frequency-amplitude point pair at the previous moment is not in the first curve of the first curve cluster, a second curve is generated that includes the first frequency-amplitude point pair at the current moment and the first frequency-amplitude point pair at the previous moment.
6. The method for tracking heart rate signals as described in any one of claims 3 to 5, characterized in that, After obtaining multiple first frequency-amplitude point pairs by finding local peaks in the spectrum of the original PPG signal after amplitude normalization, the method further includes: Determine whether the amplitude of each of the plurality of first frequency-amplitude point pairs is less than a first preset amplitude; In response to the fact that the plurality of first frequency-amplitude point pairs include a first frequency-amplitude point pair with an amplitude less than the first preset amplitude, the first frequency-amplitude point pair with an amplitude less than the first preset amplitude is deleted from the plurality of first frequency-amplitude point pairs.
7. The method for tracking heart rate signals as described in any one of claims 1 to 5, characterized in that, The step of generating corresponding first curve clusters and second curve clusters based on the spectrum of the original PPG signal and the spectrum of the filtered PPG signal, respectively, includes: The frequencies of the original PPG signal and the filtered PPG signal are subjected to amplitude normalization and local peak detection to generate corresponding first and second curve clusters.
8. The method for tracking heart rate signals as described in any one of claims 1 to 5, characterized in that, Acquiring the filtered PPG signal includes: An acceleration signal is filtered from the original PPG signal using a filtering algorithm to obtain the filtered PPG signal.
9. A heart rate signal tracking device, characterized in that, include: The first acquisition module is used to acquire the original photoplethysmography (PPG) signal and the filtered PPG signal. The processing module is used to perform short-time Fourier transform on the original PPG signal and the filtered PPG signal respectively to obtain the spectrum of the original PPG signal and the spectrum of the filtered PPG signal. The generation module is used to generate a first curve cluster and a second curve cluster based on the spectrum of the original PPG signal and the spectrum of the filtered PPG signal, respectively. The first curve cluster includes at least one curve, and the second curve cluster includes at least one curve. The search module is used to find coordinate points from all time-frequency coordinate points on all curves in the first curve cluster that have a difference within a certain range from the time-frequency coordinate points on each curve in the second curve cluster, and use them as pairing points. The second acquisition module is used to detect the pairing points of each curve in the second curve cluster to determine whether the curve meets the preset conditions. The preset conditions include: the number of pairing points is greater than a set number, and the ratio of pairing points is greater than a set ratio. The second acquisition module is further configured to, in response to the existence of a curve in the second curve cluster that satisfies the preset conditions, acquire the jump heart rate value based on the curve that satisfies the preset conditions.
10. The heart rate signal tracking device as described in claim 9, characterized in that, The second acquisition module is used for: Based on the time of the pairing point of the curve that meets the preset conditions, the corresponding frequency is obtained, and the corresponding frequency is used as the jump heart rate value.
11. The heart rate signal tracking device as described in claim 9, characterized in that, The generation module is configured to: perform amplitude normalization processing on the spectrum of the original PPG signal and the spectrum of the filtered PPG signal respectively; and, by finding local peaks, obtain a plurality of first frequency-amplitude point pairs and a plurality of second frequency-amplitude point pairs on the spectrum of the amplitude-normalized original PPG signal and the spectrum of the amplitude-normalized filtered PPG signal respectively; and generate a corresponding first curve cluster and a second curve cluster based on the plurality of first frequency-amplitude point pairs and the plurality of second frequency-amplitude point pairs respectively.
12. The heart rate signal tracking device as described in claim 11, characterized in that, The generation module is configured to: after finding local peaks in the spectrum of the original PPG signal after amplitude normalization to obtain multiple first frequency-amplitude point pairs, determine whether the amplitude of each of the multiple first frequency-amplitude point pairs is less than a first preset amplitude; and in response to the existence of a first frequency-amplitude point pair with an amplitude less than the first preset amplitude among the multiple first frequency-amplitude point pairs, delete the first frequency-amplitude point pair with an amplitude less than the first preset amplitude from the multiple first frequency-amplitude point pairs.
13. The heart rate signal tracking device as described in claim 11 or 12, characterized in that, The generation module is used to: perform amplitude normalization processing and local peak finding processing on the frequency of the original PPG signal and the frequency of the filtered PPG signal to generate corresponding first curve clusters and second curve clusters.
14. An electronic device, characterized in that, include: processor; Memory used to store the processor's executable instructions; The processor is configured to execute the instructions to implement the heart rate signal tracking method as described in any one of claims 1-8.
15. A non-transitory computer-readable storage medium, characterized in that, When the instructions in the storage medium are executed by the processor of the electronic device, the electronic device is able to perform the heart rate signal tracking method as described in any one of claims 1-8.
Citation Information
Patent Citations
Method for detecting movement offset in pulse wave heart rate calculation
CN104739399A
Heart rate acquiring method, device and system and medium
CN111616695A