CN118078234A - PPG signal processing method, device and storage medium - Google Patents
PPG signal processing method, device and storage medium Download PDFInfo
- Publication number
- CN118078234A CN118078234A CN202410516782.8A CN202410516782A CN118078234A CN 118078234 A CN118078234 A CN 118078234A CN 202410516782 A CN202410516782 A CN 202410516782A CN 118078234 A CN118078234 A CN 118078234A
- Authority
- CN
- China
- Prior art keywords
- signal
- ppg
- cycle
- template
- preset
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Granted
Links
- 238000003672 processing method Methods 0.000 title claims abstract description 23
- 238000000034 method Methods 0.000 claims abstract description 61
- 238000001514 detection method Methods 0.000 claims abstract description 59
- 230000001133 acceleration Effects 0.000 claims description 85
- 238000004422 calculation algorithm Methods 0.000 claims description 35
- 230000006870 function Effects 0.000 claims description 33
- 238000012545 processing Methods 0.000 claims description 33
- 238000004364 calculation method Methods 0.000 claims description 27
- 230000035772 mutation Effects 0.000 claims description 16
- 238000001914 filtration Methods 0.000 claims description 15
- 238000007781 pre-processing Methods 0.000 claims description 14
- 238000004590 computer program Methods 0.000 claims description 9
- 230000033001 locomotion Effects 0.000 abstract description 16
- 238000000354 decomposition reaction Methods 0.000 abstract description 10
- 238000013441 quality evaluation Methods 0.000 abstract description 3
- 238000010606 normalization Methods 0.000 abstract 1
- 238000013186 photoplethysmography Methods 0.000 description 311
- 238000010586 diagram Methods 0.000 description 18
- 230000008569 process Effects 0.000 description 16
- 230000006438 vascular health Effects 0.000 description 14
- 238000000605 extraction Methods 0.000 description 12
- 238000013480 data collection Methods 0.000 description 9
- 238000010801 machine learning Methods 0.000 description 9
- 238000007726 management method Methods 0.000 description 9
- 239000008280 blood Substances 0.000 description 8
- 210000004369 blood Anatomy 0.000 description 8
- 238000003066 decision tree Methods 0.000 description 6
- 230000003068 static effect Effects 0.000 description 6
- 238000004891 communication Methods 0.000 description 5
- 230000001360 synchronised effect Effects 0.000 description 5
- 238000012549 training Methods 0.000 description 5
- 206010003210 Arteriosclerosis Diseases 0.000 description 4
- 101000827703 Homo sapiens Polyphosphoinositide phosphatase Proteins 0.000 description 4
- 102100023591 Polyphosphoinositide phosphatase Human genes 0.000 description 4
- 101100233916 Saccharomyces cerevisiae (strain ATCC 204508 / S288c) KAR5 gene Proteins 0.000 description 4
- 208000011775 arteriosclerosis disease Diseases 0.000 description 4
- QVGXLLKOCUKJST-UHFFFAOYSA-N atomic oxygen Chemical compound [O] QVGXLLKOCUKJST-UHFFFAOYSA-N 0.000 description 4
- 230000036772 blood pressure Effects 0.000 description 4
- 238000005259 measurement Methods 0.000 description 4
- 229910052760 oxygen Inorganic materials 0.000 description 4
- 239000001301 oxygen Substances 0.000 description 4
- 238000012216 screening Methods 0.000 description 4
- 238000012360 testing method Methods 0.000 description 4
- 238000013500 data storage Methods 0.000 description 3
- 238000013461 design Methods 0.000 description 3
- 238000007477 logistic regression Methods 0.000 description 3
- 238000007637 random forest analysis Methods 0.000 description 3
- 238000005070 sampling Methods 0.000 description 3
- 210000001519 tissue Anatomy 0.000 description 3
- 238000012935 Averaging Methods 0.000 description 2
- 101100012902 Saccharomyces cerevisiae (strain ATCC 204508 / S288c) FIG2 gene Proteins 0.000 description 2
- 230000005856 abnormality Effects 0.000 description 2
- 238000004458 analytical method Methods 0.000 description 2
- 230000006793 arrhythmia Effects 0.000 description 2
- 206010003119 arrhythmia Diseases 0.000 description 2
- 230000009286 beneficial effect Effects 0.000 description 2
- 230000017531 blood circulation Effects 0.000 description 2
- 230000001186 cumulative effect Effects 0.000 description 2
- 230000036541 health Effects 0.000 description 2
- 238000012417 linear regression Methods 0.000 description 2
- 238000010295 mobile communication Methods 0.000 description 2
- 238000012544 monitoring process Methods 0.000 description 2
- 230000003863 physical function Effects 0.000 description 2
- 238000012502 risk assessment Methods 0.000 description 2
- 230000002792 vascular Effects 0.000 description 2
- 101001121408 Homo sapiens L-amino-acid oxidase Proteins 0.000 description 1
- 102100026388 L-amino-acid oxidase Human genes 0.000 description 1
- 238000010220 Pearson correlation analysis Methods 0.000 description 1
- 229910003798 SPO2 Inorganic materials 0.000 description 1
- 101100478210 Schizosaccharomyces pombe (strain 972 / ATCC 24843) spo2 gene Proteins 0.000 description 1
- 210000003423 ankle Anatomy 0.000 description 1
- 210000001367 artery Anatomy 0.000 description 1
- 210000004204 blood vessel Anatomy 0.000 description 1
- 210000000988 bone and bone Anatomy 0.000 description 1
- 230000008859 change Effects 0.000 description 1
- 210000000038 chest Anatomy 0.000 description 1
- 238000010835 comparative analysis Methods 0.000 description 1
- 238000011161 development Methods 0.000 description 1
- 230000018109 developmental process Effects 0.000 description 1
- 230000004069 differentiation Effects 0.000 description 1
- 230000000694 effects Effects 0.000 description 1
- 230000003993 interaction Effects 0.000 description 1
- 230000001788 irregular Effects 0.000 description 1
- 230000031700 light absorption Effects 0.000 description 1
- 230000005055 memory storage Effects 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 230000000737 periodic effect Effects 0.000 description 1
- 230000010349 pulsation Effects 0.000 description 1
- 238000001303 quality assessment method Methods 0.000 description 1
- 238000013102 re-test Methods 0.000 description 1
- 238000011160 research Methods 0.000 description 1
- 238000012552 review Methods 0.000 description 1
- 230000011218 segmentation Effects 0.000 description 1
- 239000013589 supplement Substances 0.000 description 1
- 239000000725 suspension Substances 0.000 description 1
- 210000000115 thoracic cavity Anatomy 0.000 description 1
- 238000012795 verification Methods 0.000 description 1
- 230000000007 visual effect Effects 0.000 description 1
- 210000000707 wrist Anatomy 0.000 description 1
Classifications
-
- A—HUMAN NECESSITIES
- A61—MEDICAL OR VETERINARY SCIENCE; HYGIENE
- A61B—DIAGNOSIS; SURGERY; IDENTIFICATION
- A61B5/00—Measuring for diagnostic purposes; Identification of persons
- A61B5/02—Detecting, measuring or recording for evaluating the cardiovascular system, e.g. pulse, heart rate, blood pressure or blood flow
- A61B5/021—Measuring pressure in heart or blood vessels
- A61B5/02108—Measuring pressure in heart or blood vessels from analysis of pulse wave characteristics
-
- A—HUMAN NECESSITIES
- A61—MEDICAL OR VETERINARY SCIENCE; HYGIENE
- A61B—DIAGNOSIS; SURGERY; IDENTIFICATION
- A61B5/00—Measuring for diagnostic purposes; Identification of persons
- A61B5/02—Detecting, measuring or recording for evaluating the cardiovascular system, e.g. pulse, heart rate, blood pressure or blood flow
- A61B5/021—Measuring pressure in heart or blood vessels
- A61B5/02141—Details of apparatus construction, e.g. pump units or housings therefor, cuff pressurising systems, arrangements of fluid conduits or circuits
-
- A—HUMAN NECESSITIES
- A61—MEDICAL OR VETERINARY SCIENCE; HYGIENE
- A61B—DIAGNOSIS; SURGERY; IDENTIFICATION
- A61B5/00—Measuring for diagnostic purposes; Identification of persons
- A61B5/02—Detecting, measuring or recording for evaluating the cardiovascular system, e.g. pulse, heart rate, blood pressure or blood flow
- A61B5/026—Measuring blood flow
- A61B5/0261—Measuring blood flow using optical means, e.g. infrared light
-
- A—HUMAN NECESSITIES
- A61—MEDICAL OR VETERINARY SCIENCE; HYGIENE
- A61B—DIAGNOSIS; SURGERY; IDENTIFICATION
- A61B5/00—Measuring for diagnostic purposes; Identification of persons
- A61B5/02—Detecting, measuring or recording for evaluating the cardiovascular system, e.g. pulse, heart rate, blood pressure or blood flow
- A61B5/026—Measuring blood flow
- A61B5/0295—Measuring blood flow using plethysmography, i.e. measuring the variations in the volume of a body part as modified by the circulation of blood therethrough, e.g. impedance plethysmography
-
- A—HUMAN NECESSITIES
- A61—MEDICAL OR VETERINARY SCIENCE; HYGIENE
- A61B—DIAGNOSIS; SURGERY; IDENTIFICATION
- A61B5/00—Measuring for diagnostic purposes; Identification of persons
- A61B5/68—Arrangements of detecting, measuring or recording means, e.g. sensors, in relation to patient
- A61B5/6801—Arrangements of detecting, measuring or recording means, e.g. sensors, in relation to patient specially adapted to be attached to or worn on the body surface
- A61B5/6802—Sensor mounted on worn items
-
- A—HUMAN NECESSITIES
- A61—MEDICAL OR VETERINARY SCIENCE; HYGIENE
- A61B—DIAGNOSIS; SURGERY; IDENTIFICATION
- A61B5/00—Measuring for diagnostic purposes; Identification of persons
- A61B5/72—Signal processing specially adapted for physiological signals or for diagnostic purposes
- A61B5/7225—Details of analog processing, e.g. isolation amplifier, gain or sensitivity adjustment, filtering, baseline or drift compensation
Landscapes
- Health & Medical Sciences (AREA)
- Life Sciences & Earth Sciences (AREA)
- Engineering & Computer Science (AREA)
- General Health & Medical Sciences (AREA)
- Veterinary Medicine (AREA)
- Biophysics (AREA)
- Biomedical Technology (AREA)
- Heart & Thoracic Surgery (AREA)
- Medical Informatics (AREA)
- Molecular Biology (AREA)
- Surgery (AREA)
- Animal Behavior & Ethology (AREA)
- Physics & Mathematics (AREA)
- Public Health (AREA)
- Pathology (AREA)
- Cardiology (AREA)
- Physiology (AREA)
- Signal Processing (AREA)
- Hematology (AREA)
- Vascular Medicine (AREA)
- Artificial Intelligence (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Psychiatry (AREA)
- Power Engineering (AREA)
- Measurement And Recording Of Electrical Phenomena And Electrical Characteristics Of The Living Body (AREA)
Abstract
本申请提供了一种PPG信号处理方法、设备及存储介质。该方法通过将ACC信号的信号质量评估结果作为PPG信号是否中止采集的条件,降低运动状态对PPG信号的影响,再通过对PPG信号依次进行峰谷检测、相邻谷值截取、起止点拉齐以及幅值归一化,得到单周期信号集合,并对单周期信号集合中元素与模板信号进行匹配,得到单周期PPG主信号,对PPG主信号进行分解以及拟合,得到PPG信号的主波和重搏波,从而简化了PPG信号分解的运算复杂度,提升了PPG信号分解的准确性。
The present application provides a PPG signal processing method, device and storage medium. The method uses the signal quality evaluation result of the ACC signal as the condition for whether to terminate the acquisition of the PPG signal, reduces the influence of the motion state on the PPG signal, and then obtains a single-cycle signal set by performing peak-valley detection, adjacent valley value interception, start-end point alignment and amplitude normalization on the PPG signal in sequence, and matches the elements in the single-cycle signal set with the template signal to obtain a single-cycle PPG main signal, decomposes and fits the PPG main signal to obtain the main wave and dicrotic wave of the PPG signal, thereby simplifying the computational complexity of the PPG signal decomposition and improving the accuracy of the PPG signal decomposition.
Description
技术领域Technical Field
本申请涉及终端设备领域,尤其涉及一种PPG信号处理方法、设备及存储介质。The present application relates to the field of terminal devices, and in particular to a PPG signal processing method, device and storage medium.
背景技术Background technique
光电容积脉搏波描记法(photoplethysmography,PPG)是一种借助光电手段,在活体组织中检测血液容积变化的无创检测方法。由于反射光的强度与血流速度相关,同时血流速度受周期性的心率影响。因此,基于PPG信号可以实现血氧饱和度(SPO2)、心率、血压等的测量。Photoplethysmography (PPG) is a non-invasive detection method that uses photoelectric means to detect changes in blood volume in living tissue. Since the intensity of reflected light is related to blood flow velocity, and blood flow velocity is affected by periodic heart rate, blood oxygen saturation (SPO2), heart rate, blood pressure, etc. can be measured based on PPG signals.
然而,在穿戴设备场景下,通常采集到的PPG信号较弱,并且干扰较大,导致一部分人群的PPG信号无法直接用于相关指标预测。However, in the wearable device scenario, the PPG signals collected are usually weak and have greater interference, resulting in the PPG signals of a part of the population being unable to be directly used for the prediction of relevant indicators.
发明内容Summary of the invention
本申请实施例提供一种PPG信号处理方法、设备及存储介质,旨在提升PPG信号分解的精度,从而在将分解后的PPG信号用于后续的PWV计算中提升PWV值预测的准确性。The embodiments of the present application provide a PPG signal processing method, device and storage medium, which aim to improve the accuracy of PPG signal decomposition, thereby improving the accuracy of PWV value prediction when the decomposed PPG signal is used for subsequent PWV calculation.
第一方面,本申请实施例提供一种PPG信号处理方法,方法包括:获取可穿戴设备采集的光电容积脉搏波PPG信号和加速度ACC信号;对所述PPG信号进行预处理得到滤波信号,所述预处理包括基于所述ACC信号对所述PPG信号进行时间戳同步校验、基于所述PPG信号的相邻数据包的时间戳进行丢包检测,以及对所述PPG信号进行滤波;对所述滤波信号进行峰谷检测,基于检测结果对所述滤波信号进行二次处理得到单周期PPG信号集合,所述二次处理包括基于所述检测结果对所述滤波信号进行单周期信号截取,对截取得到的信号集合进行起止点拉齐以及幅值归一化;将所述单周期PPG信号集合中每一个单周期PPG信号与预设模板信号集合中的每一个模板信号进行匹配,将匹配成功次数最高的模板信号设置为单周期PPG主信号,所述预设模板信号集合中包含至少一个模板信号;基于双高斯函数模型对所述单周期PPG主信号进行分解,得到参数集合;基于线性最小二乘回归迭代算法对所述参数集合进行拟合,得到第一高斯波和第二高斯波,所述第一高斯波为所述PPG信号的主波,所述第二高斯波为所述PPG信号的重搏波。In a first aspect, an embodiment of the present application provides a PPG signal processing method, the method comprising: acquiring a photoplethysmogram (PPG) signal and an acceleration (ACC) signal collected by a wearable device; preprocessing the PPG signal to obtain a filtered signal, the preprocessing comprising performing a timestamp synchronization check on the PPG signal based on the ACC signal, performing packet loss detection based on the timestamps of adjacent data packets of the PPG signal, and filtering the PPG signal; performing peak and valley detection on the filtered signal, performing secondary processing on the filtered signal based on the detection result to obtain a single-cycle PPG signal set, the secondary processing comprising performing a single-cycle signal interception on the filtered signal based on the detection result. , align the start and end points of the intercepted signal set and normalize the amplitude; match each single-cycle PPG signal in the single-cycle PPG signal set with each template signal in the preset template signal set, and set the template signal with the highest number of successful matches as the single-cycle PPG main signal, and the preset template signal set contains at least one template signal; decompose the single-cycle PPG main signal based on a double Gaussian function model to obtain a parameter set; fit the parameter set based on a linear least squares regression iterative algorithm to obtain a first Gaussian wave and a second Gaussian wave, wherein the first Gaussian wave is the main wave of the PPG signal, and the second Gaussian wave is the dicrotic wave of the PPG signal.
示例性的,PPG信号和ACC信号的采样频率均可以设置为100Hz,并按照100ms数据包进行组包上传。Exemplarily, the sampling frequencies of the PPG signal and the ACC signal can both be set to 100 Hz, and the signals can be grouped and uploaded in 100 ms data packets.
其中,对PPG信号进行滤波可以是通过滤波器对其进行滤波。示例性的,滤波器可以是0.5~4Hz的二阶巴特沃斯(Butterworth)滤波器。The filtering of the PPG signal may be filtering the PPG signal through a filter. Exemplarily, the filter may be a second-order Butterworth filter of 0.5-4 Hz.
其中,通过基于ACC信号对PPG信号进行时间戳同步校验,即将两者进行时间对齐校验,可以防止PPG信号与ACC信号错位,从而降低对用户状态误判的风险。Among them, by performing a timestamp synchronization check on the PPG signal based on the ACC signal, that is, performing a time alignment check on the two, it is possible to prevent the PPG signal and the ACC signal from being misaligned, thereby reducing the risk of misjudgment of the user status.
其中,将PPG信号相邻数据包的时间戳用于对PPG信号进行丢包检测,从而防止出现PPG信号丢失,进而影响后续分析结果的准确性。Among them, the timestamps of adjacent data packets of the PPG signal are used to detect packet loss of the PPG signal, thereby preventing the loss of the PPG signal and affecting the accuracy of subsequent analysis results.
由此,通过基于ACC信号及PPG信号进行时间戳同步校验及丢包检测。若ACC信号及PPG信号未同步,则返回PPG及ACC信号未同步错误码;若PPG信号相邻数据包的时间戳大于指定阈值,则认为发生PPG信号数据包丢包,返回PPG丢包错误码。在PPG信号未出现丢包的情况下,对PPG信号进行带通滤波得到滤波信号。对滤波信号进行峰谷检测,并基于检测结果对滤波信号进行二次处理,得到单周期PPG信号集合;将单周期PPG信号与预设模板信号进行匹配,得到单周期PPG主信号;再基于双高斯函数模型和最小二乘回归迭代算法对单周期PPG主信号进行分解以及拟合,得到第一高斯波和第二高斯波,简化了PPG信号分解的运算复杂度,提升了PPG信号分解的准确性。Therefore, timestamp synchronization check and packet loss detection are performed based on the ACC signal and the PPG signal. If the ACC signal and the PPG signal are not synchronized, the PPG and ACC signal unsynchronized error code is returned; if the timestamps of adjacent data packets of the PPG signal are greater than the specified threshold, it is considered that the PPG signal data packet has been lost, and the PPG packet loss error code is returned. In the case that there is no packet loss in the PPG signal, the PPG signal is band-pass filtered to obtain a filtered signal. Peak and valley detection is performed on the filtered signal, and the filtered signal is secondary processed based on the detection result to obtain a single-cycle PPG signal set; the single-cycle PPG signal is matched with the preset template signal to obtain a single-cycle PPG main signal; then the single-cycle PPG main signal is decomposed and fitted based on the double Gaussian function model and the least squares regression iterative algorithm to obtain the first Gaussian wave and the second Gaussian wave, which simplifies the computational complexity of the PPG signal decomposition and improves the accuracy of the PPG signal decomposition.
根据第一方面,所述获取可穿戴设备采集的光电容积脉搏波PPG信号和加速度ACC信号,包括:获取所述可穿戴设备在同一状态、同一周期内采集的所述PPG信号和所述ACC信号。According to the first aspect, the acquiring of the photoplethysmogram (PPG) signal and the acceleration (ACC) signal acquired by the wearable device includes: acquiring the PPG signal and the ACC signal acquired by the wearable device in the same state and the same period.
由此,通过将ACC信号与PPG信号设定在同一状态和同一周期内进行数据采集的,从而可以实现通过ACC信号进行运动状态检测,进而判断PPG信号是否出现运动伪影的情况。Therefore, by setting the ACC signal and the PPG signal to be in the same state and in the same period for data collection, it is possible to detect the motion state through the ACC signal, and then determine whether the PPG signal has motion artifacts.
根据第一方面,或者以上第一方面的任意一种实现方式,所述ACC信号包括沿X轴的AccX信号、沿Y轴的AccY信号和沿Z轴的AccZ信号;所述获取可穿戴设备采集的光电容积脉搏波PPG信号和加速度ACC信号之后,所述方法还包括:对所述AccX信号、所述AccY信号和所述AccZ信号依次进行模值计算、差分和绝对化处理,得到差分模值AccSDiff;基于所述AccX信号、所述AccY信号和所述AccZ信号,计算预设周期内三轴朝向不达标次数和斜率突变次数;基于所述差分模值AccSDiff,计算所述预设周期内平均值、最大值和方差;在所述三轴朝向不达标次数、所述斜率突变次数、所述平均值、所述最大值和所述方差满足预设中止条件时,重新获取所述PPG信号和所述ACC信号。According to the first aspect, or any implementation of the first aspect above, the ACC signal includes an AccX signal along the X-axis, an AccY signal along the Y-axis, and an AccZ signal along the Z-axis; after acquiring the photoelectric volumetric pulse wave (PPG) signal and the acceleration ACC signal collected by the wearable device, the method further includes: performing modulus calculation, differential and absolute processing on the AccX signal, the AccY signal, and the AccZ signal in sequence to obtain a differential modulus AccSDiff; based on the AccX signal, the AccY signal, and the AccZ signal, calculating the number of non-standard three-axis orientations and the number of slope mutations within a preset period; based on the differential modulus AccSDiff, calculating the average value, maximum value, and variance within the preset period; when the number of non-standard three-axis orientations, the number of slope mutations, the average value, the maximum value, and the variance meet a preset termination condition, reacquiring the PPG signal and the ACC signal.
其中,上述预设周期可以是根据实际需求设定的,通常情况下可以设定为1秒。The preset period may be set according to actual needs, and may usually be set to 1 second.
示例性的,基于所述差分模值AccSDiff,计算预设预设周期内平均值、最大值和方差的步骤可以是采用不重叠滑窗在差分模值上进行滑动,对窗口内的数据计算每秒平均值AccSMean i,每秒最大值AccSMaxVal i和每秒方差值AccSVar i,直至计算完成得到连续N秒的特征值数组。其中,滑动窗口大小为1秒。Exemplarily, based on the differential modulus value AccSDiff, the step of calculating the average value, maximum value and variance within a preset period may be to slide a non-overlapping sliding window on the differential modulus value, and calculate the average value AccSMean i per second, the maximum value AccSMaxVal i per second and the variance value AccSVar i per second for the data in the window, until the calculation is completed to obtain an array of eigenvalues for N consecutive seconds, wherein the sliding window size is 1 second.
根据第一方面,或者以上第一方面的任意一种实现方式,所述预设中止条件包括:在所述三轴朝向不达标次数大于预设朝向不达标阈值的情况下,重新获取所述PPG信号和所述ACC信号;在斜率突变次数大于预设突变阈值的情况下,重新获取所述PPG信号和所述ACC信号;获取所述平均值大于第一预设阈值的第一个数,所述最大值大于第二预设阈值的第二个数和所述方差大于第三预设阈值的第三个数;在所述第一个数大于第一个数阈值,且第二个数大于第二个数阈值的情况下,重新获取所述PPG信号和所述ACC信号;在所述第一个数大于第三个数阈值,且第三个数大于第四个数阈值的情况下,重新获取所述PPG信号和所述ACC信号。According to the first aspect, or any implementation manner of the first aspect above, the preset termination condition includes: when the number of times the three-axis orientation fails to meet the standard is greater than a preset orientation failure threshold, reacquiring the PPG signal and the ACC signal; when the number of slope mutations is greater than a preset mutation threshold, reacquiring the PPG signal and the ACC signal; acquiring a first number whose average value is greater than a first preset threshold, a second number whose maximum value is greater than a second preset threshold, and a third number whose variance is greater than a third preset threshold; when the first number is greater than a first number threshold and the second number is greater than a second number threshold, reacquiring the PPG signal and the ACC signal; when the first number is greater than a third number threshold and the third number is greater than a fourth number threshold, reacquiring the PPG signal and the ACC signal.
示例性的,若累计的三轴朝向不达标次数DirectCount>5,则判断当前可穿戴设备佩戴姿态不满足佩戴要求,中止本次检测,并通过可穿戴设备或手机提示用户正确佩戴。For example, if the cumulative number of times the three-axis orientation fails to meet the standard DirectCount >5, it is determined that the current wearing posture of the wearable device does not meet the wearing requirements, the current detection is terminated, and the user is prompted to wear the device correctly through the wearable device or the mobile phone.
示例性的,若累计的斜率突变次数MaxSlopeCount>8,则判定用户当前身体状态不满足静止状态,中止本次检测,并通过可穿戴设备或手机提示用户保持静止。For example, if the accumulated number of slope mutations MaxSlopeCount >8, it is determined that the user's current physical state does not meet the static state, the current detection is terminated, and the user is prompted to remain still through the wearable device or mobile phone.
示例性的,获取上特征值数组中AccSMean i>0.01G的个数C1,AccSMaxVal i>0.04G的个数C2,AccSVar i>0.5G个数C3。在C1>3且C2>5,或C1>5且C3>4的情况下,判定用户当前身体状态不满足静止状态,中止本次检测,并通过可穿戴设备或手机提示用户保持静止。Exemplarily, the number C1 of AccSMean i > 0.01G, the number C2 of AccSMaxVal i > 0.04G, and the number C3 of AccSVar i > 0.5G in the upper eigenvalue array are obtained. In the case of C1>3 and C2>5, or C1>5 and C3>4, it is determined that the user's current physical state does not meet the static state, the current detection is terminated, and the user is prompted to remain still through the wearable device or mobile phone.
根据第一方面,或者以上第一方面的任意一种实现方式,所述基于所述检测结果对所述滤波信号进行单周期信号截取得到单周期信号集合S1,包括:基于所述滤波信号中相邻的两个谷值点,对所述滤波信号进行单周期信号截取,得到所述单周期信号集合S1。According to the first aspect, or any one of the implementations of the first aspect above, the single-cycle signal interception of the filtered signal based on the detection result to obtain the single-cycle signal set S1 includes: based on two adjacent valley points in the filtered signal, the single-cycle signal interception of the filtered signal to obtain the single-cycle signal set S1.
示例性的,对滤波信号进行峰谷值检测,得到每个心拍周期对应的峰谷值,并将相邻的两个谷值点作为起始点,对滤波信号进行单周期信号截取,得到单周期信号集合S1。其截图的示意图参见下图9。Exemplarily, the peak-valley value detection is performed on the filtered signal to obtain the peak-valley value corresponding to each heartbeat cycle, and two adjacent valley value points are used as starting points to perform single-cycle signal interception on the filtered signal to obtain a single-cycle signal set S1. The schematic diagram of the interception is shown in Figure 9 below.
根据第一方面,或者以上第一方面的任意一种实现方式,在所述将所述单周期PPG信号集合中每一个单周期PPG信号与预设模板信号集合中的每一个模板信号进行匹配,将匹配成功次数最高的模板信号设置为单周期PPG主信号,所述预设模板信号集合中包含至少一个模板信号之前,所述方法还包括:依次计算所述单周期PPG信号集合中每一个单周期PPG信号的偏度指数和峰度指数;基于每一个单周期PPG信号的所述偏度指数和所述峰度指数对所述单周期PPG信号集合进行过滤,得到过滤后的所述单周期PPG信号集合;基于过滤后的所述单周期PPG信号集合对所述预设模板信号集合进行创建或更新。According to the first aspect, or any implementation manner of the first aspect above, before matching each single-cycle PPG signal in the single-cycle PPG signal set with each template signal in the preset template signal set, setting the template signal with the highest number of successful matches as the single-cycle PPG main signal, and including at least one template signal in the preset template signal set, the method also includes: sequentially calculating the skewness index and the kurtosis index of each single-cycle PPG signal in the single-cycle PPG signal set; filtering the single-cycle PPG signal set based on the skewness index and the kurtosis index of each single-cycle PPG signal to obtain the filtered single-cycle PPG signal set; and creating or updating the preset template signal set based on the filtered single-cycle PPG signal set.
根据第一方面,或者以上第一方面的任意一种实现方式,所述基于过滤后的所述单周期PPG信号集合对所述预设模板信号集合进行创建,包括:获取所述预设模板信号集合中的模板数量;在所述模板数量等于0的情况下,将过滤后的所述单周期PPG信号集合中的第一个单周期PPG信号设定为第一模板信号,并将其添加至所述预设模板信号集合中;在所述模板数量小于预设模板数量阈值时,依次计算过滤后的所述单周期PPG信号集合中每个单周期PPG信号与所述预设模板信号集合中各个模板信号的相似度,在任一所述相似度大于第一相似度阈值的情况下,将其对应的单周期PPG信号设定为第二模板信号,并将其添加至所述预设模板信号集合中。According to the first aspect, or any implementation manner of the first aspect above, the creating the preset template signal set based on the filtered single-cycle PPG signal set includes: obtaining the number of templates in the preset template signal set; when the number of templates is equal to 0, setting the first single-cycle PPG signal in the filtered single-cycle PPG signal set as the first template signal, and adding it to the preset template signal set; when the number of templates is less than a preset template number threshold, sequentially calculating the similarity between each single-cycle PPG signal in the filtered single-cycle PPG signal set and each template signal in the preset template signal set, and when any of the similarities is greater than the first similarity threshold, setting the corresponding single-cycle PPG signal as the second template signal, and adding it to the preset template signal set.
示例性的,上述相似度计算采用DTW距离来进行评价,该距离越小表示信号越相似。Exemplarily, the similarity calculation is evaluated using DTW distance, and the smaller the distance is, the more similar the signals are.
示例性的,上述预设模板数量阈值可以是根据实际需求设定的,通常可以设定为3。Exemplarily, the above-mentioned preset template quantity threshold can be set according to actual needs, and can usually be set to 3.
示例性的,上述第一相似度可以是根据实际需求设定的,通常可以设定为0.3。Exemplarily, the first similarity may be set according to actual needs, and may generally be set to 0.3.
具体的,当上述相似度大于第一相似度阈值的情况下,将其对应的单周期PPG信号设定为模板信号,并添加至预设模板信号集合中。Specifically, when the above similarity is greater than the first similarity threshold, the corresponding single-cycle PPG signal is set as the template signal and added to the preset template signal set.
根据第一方面,或者以上第一方面的任意一种实现方式,所述基于过滤后的所述单周期PPG信号集合对所述预设模板信号集合进行创建,还包括:在所述模板数量大于等于所述预设模板数量阈值,且全部的所述相似度均大于所述第一相似度阈值的情况下,将其对应的单周期PPG信号设定为潜在模板信号,将所述潜在模板信号添加至所述预设模板信号集合;其中,过滤后的所述单周期PPG信号集合中每一个单周期PPG信号与所述预设模板信号集合中每一个模板信号进行匹配,在所述潜在模板信号的匹配成功次数大于任一所述预设模板信号集合中其它的模板信号的情况下,将其对应的模板信号替换为潜在模板信号,并清除所述预设模板信号集合中的潜在模板信号。According to the first aspect, or any implementation manner of the first aspect above, the creating the preset template signal set based on the filtered single-cycle PPG signal set further includes: when the number of templates is greater than or equal to the preset template number threshold, and all of the similarities are greater than the first similarity threshold, setting the corresponding single-cycle PPG signal as a potential template signal, and adding the potential template signal to the preset template signal set; wherein each single-cycle PPG signal in the filtered single-cycle PPG signal set is matched with each template signal in the preset template signal set, and when the number of successful matches of the potential template signal is greater than any other template signal in the preset template signal set, replacing its corresponding template signal with the potential template signal, and clearing the potential template signals in the preset template signal set.
具体的,潜在模板信号为一类特殊的预设模板信号,其个数一般不超过1个,用于在单周期PPG信号形态多变情况下补检可能的模板信号。Specifically, the potential template signal is a special type of preset template signal, the number of which generally does not exceed 1, and is used to supplement the detection of possible template signals when the single-cycle PPG signal morphology is changeable.
根据第一方面,或者以上第一方面的任意一种实现方式,所述基于过滤后的所述单周期PPG信号集合对所述预设模板信号集合进行更新,包括:依次计算过滤后的所述单周期PPG信号集合中每一个单周期PPG信号与所述预设模板信号集合中的每一个模板信号的相似度;在所述相似度小于所述第一相似度阈值的情况下,将当前的所述模板信号匹配成功次数加1;在所述相似度小于第二相似度阈值的情况下,使用其对应的单周期PPG信号对当前的所述模板信号进行更新,直至过滤后的所述单周期PPG信号集合中的单周期PPG信号全部完成匹配。According to the first aspect, or any implementation manner of the first aspect above, the updating of the preset template signal set based on the filtered single-cycle PPG signal set includes: sequentially calculating the similarity between each single-cycle PPG signal in the filtered single-cycle PPG signal set and each template signal in the preset template signal set; when the similarity is less than the first similarity threshold, adding 1 to the number of successful matches of the current template signal; when the similarity is less than the second similarity threshold, using its corresponding single-cycle PPG signal to update the current template signal until all single-cycle PPG signals in the filtered single-cycle PPG signal set are matched.
示例性的,上述使用单周期PPG信号对模板信号进行更新可以是,基于均值法对单周期PPG信号与模板信号进行合并,并将合并后的信号作为新的模板信号对原来的模板信号进行更新。Exemplarily, the above-mentioned use of the single-cycle PPG signal to update the template signal may be to merge the single-cycle PPG signal and the template signal based on the mean method, and use the merged signal as a new template signal to update the original template signal.
示例性的,上述均值法可以是参考下图11中(3)的数据对应规则,将单周期PPG信号与模板信号进行逐点平均的方法。Exemplarily, the above-mentioned averaging method may be a method of averaging the single-cycle PPG signal and the template signal point by point with reference to the data correspondence rule (3) in FIG. 11 below.
具体的,上述第一相似度阈值大于上述第二相似度阈值。上述第二相似度阈值可以设定为0.1。Specifically, the first similarity threshold is greater than the second similarity threshold. The second similarity threshold can be set to 0.1.
根据第一方面,或者以上第一方面的任意一种实现方式,所述在所述相似度小于第二相似度阈值的情况下,使用其对应的单周期PPG信号对当前的所述模板信号进行更新之后,还包括:计算更新后的所述模板信号与预设模板信号集合中其它的模板信号的相似度,在任一所述相似度小于所述第二相似度阈值的情况下,将其对应的两个所述模板信号进行合并,将两个所述模板信号的匹配成功次数合并,删除更新后的所述模板信号。According to the first aspect, or any implementation manner of the first aspect above, when the similarity is less than a second similarity threshold, after using its corresponding single-cycle PPG signal to update the current template signal, it also includes: calculating the similarity between the updated template signal and other template signals in a preset template signal set, and when any of the similarities is less than the second similarity threshold, merging the two corresponding template signals, merging the number of successful matches of the two template signals, and deleting the updated template signal.
根据第一方面,或者以上第一方面的任意一种实现方式,所述基于双高斯函数模型对所述单周期PPG主信号进行分解,得到参数集合,包括:基于所述单周期PPG主信号的最大值S4Max和第一位置S4MaxLoc,获取所述第一位置右侧幅度为S4Max/5的第二位置S4MaxEndLoc;对所述单周期PPG主信号进行差分得到差分信号,获取所述差分信号的过零点位置S5ZeroLoc;基于所述最大值S4Max、所述第一位置S4MaxLoc、所述第二位置S4MaxEndLoc和所述过零点位置S5ZeroLoc,计算所述单周期PPG主信号在所述双高斯函数模型中的初始参数;基于所述初始参数和所述双高斯函数模型对所述单周期PPG主信号进行分解,得到参数集合。According to the first aspect, or any implementation manner of the first aspect above, the decomposing the single-cycle PPG main signal based on the double Gaussian function model to obtain a parameter set includes: based on the maximum value S4Max and the first position S4MaxLoc of the single-cycle PPG main signal, obtaining the second position S4MaxEndLoc with an amplitude of S4Max/5 on the right side of the first position; differentiating the single-cycle PPG main signal to obtain a differential signal, and obtaining the zero-crossing position S5ZeroLoc of the differential signal; based on the maximum value S4Max, the first position S4MaxLoc, the second position S4MaxEndLoc and the zero-crossing position S5ZeroLoc, calculating the initial parameters of the single-cycle PPG main signal in the double Gaussian function model; decomposing the single-cycle PPG main signal based on the initial parameters and the double Gaussian function model to obtain a parameter set.
根据第一方面,或者以上第一方面的任意一种实现方式,所述基于线性最小二乘回归迭代算法对所述参数集合进行拟合,得到第一高斯波和第二高斯波之后,包括:对所述单周期PPG主信号、所述第一高斯波和所述第二高斯波进行特征计算,将得到的特征集合对预设PWV回归模型进行训练。According to the first aspect, or any implementation of the first aspect above, after fitting the parameter set based on the linear least squares regression iterative algorithm to obtain the first Gaussian wave and the second Gaussian wave, it includes: performing feature calculations on the single-cycle PPG main signal, the first Gaussian wave and the second Gaussian wave, and training a preset PWV regression model with the obtained feature set.
示例性的,上述得到的特征集合包括S4总时长T、第一高斯波上升时间T1、双波间隔∆T、反射指数RI、增强指数AI、心率间隔RR、K值(mean(PPG)/max(PPG))。以及引申特征集合第一高斯波上线时间占比T1/T、硬化指数SI=Height/∆T、归一化硬化指数SI/RR、BMI指数Weight/Height2等。Exemplarily, the feature set obtained above includes S4 total duration T, first Gaussian wave rise time T1, double wave interval ∆T, reflection index RI, enhancement index AI, heart rate interval RR, K value (mean(PPG)/max(PPG)). And the extended feature set includes the first Gaussian wave online time ratio T1/T, hardening index SI=Height/∆T, normalized hardening index SI/RR, BMI index Weight/Height 2 , etc.
具体的,上述预设PWV回归模型可以是基于机器学习算法或多元回归算法训练得到的。Specifically, the preset PWV regression model may be obtained by training based on a machine learning algorithm or a multivariate regression algorithm.
示例性的,上述机器学习算法可以包括SVM、逻辑回归、或主流的决策树模型。例如随机森林算法、迭代算法(AdaBoost)、优化的分布式梯度增强库(XGBoost)、梯度提升机器学习算法(CatBoost)、梯度提升决策树模型(LightGBM)等。Exemplarily, the above machine learning algorithms may include SVM, logistic regression, or mainstream decision tree models, such as random forest algorithm, iterative algorithm (AdaBoost), optimized distributed gradient boosting library (XGBoost), gradient boosting machine learning algorithm (CatBoost), gradient boosting decision tree model (LightGBM), etc.
第二方面,本申请实施例提供了一种电子设备。该电子设备包括:存储器和处理器,存储器和处理器耦合;存储器存储有程序指令,程序指令由处理器执行时,使得所述电子设备执行第一方面或第一方面的任意可能的实现方式中的方法的指令。In a second aspect, an embodiment of the present application provides an electronic device. The electronic device includes: a memory and a processor, the memory and the processor are coupled; the memory stores program instructions, and when the program instructions are executed by the processor, the electronic device executes instructions of the method in the first aspect or any possible implementation of the first aspect.
第三方面,本申请实施例提供了一种计算机可读介质,用于存储计算机程序,该计算机程序包括用于执行第一方面或第一方面的任意可能的实现方式中的方法的指令。In a third aspect, an embodiment of the present application provides a computer-readable medium for storing a computer program, wherein the computer program includes instructions for executing the method in the first aspect or any possible implementation of the first aspect.
第四方面,本申请实施例提供了一种计算机程序,该计算机程序包括用于执行第一方面或第一方面的任意可能的实现方式中的方法的指令。In a fourth aspect, an embodiment of the present application provides a computer program, which includes instructions for executing the method in the first aspect or any possible implementation of the first aspect.
第五方面,本申请实施例提供了一种芯片,该芯片包括处理电路、收发管脚。其中,该收发管脚、和该处理电路通过内部连接通路互相通信,该处理电路执行第一方面或第一方面的任一种可能的实现方式中的方法,以控制接收管脚接收信号,以控制发送管脚发送信号。In a fifth aspect, an embodiment of the present application provides a chip, the chip comprising a processing circuit and a transceiver pin, wherein the transceiver pin and the processing circuit communicate with each other through an internal connection path, and the processing circuit executes the method in the first aspect or any possible implementation of the first aspect to control the receiving pin to receive a signal and control the sending pin to send a signal.
附图说明BRIEF DESCRIPTION OF THE DRAWINGS
图1为示例性示出的多点法测量PWV示意图;FIG1 is a schematic diagram showing an exemplary multi-point method for measuring PWV;
图2为示例性示出的不同年龄段PPG信号对比示意图;FIG2 is a schematic diagram showing an exemplary comparison of PPG signals for different age groups;
图3为示例性示出的穿戴式设备示意图;FIG3 is a schematic diagram of an exemplary wearable device;
图4为示例性示出的穿戴式设备PWV测量场景示意图;FIG4 is a schematic diagram of an exemplary wearable device PWV measurement scenario;
图5为示例性示出的用户界面示意图;FIG5 is a schematic diagram of an exemplary user interface;
图6为示例性示出的PPG信号处理流程示意图;FIG6 is a schematic diagram of an exemplary PPG signal processing flow chart;
图7为示例性示出的ACC信号质量评估示意图;FIG7 is a schematic diagram showing an exemplary ACC signal quality assessment;
图8为示例性示出的PPG信号峰谷识别示意图;FIG8 is a schematic diagram showing an exemplary PPG signal peak and valley identification;
图9为示例性示出的PPG信号分割示意图;FIG9 is a schematic diagram of an exemplary PPG signal segmentation;
图10为示例性示出的PPG信号二次处理示意图;FIG10 is a schematic diagram of an exemplary PPG signal secondary processing;
图11为示例性示出的DTW法相似性计算示意图;FIG11 is a schematic diagram showing an exemplary similarity calculation using the DTW method;
图12为示例性示出的PPG信号处理结果示意图;FIG12 is a schematic diagram showing an exemplary PPG signal processing result;
图13为示例性示出的电子设备的软件结构示意图;FIG13 is a schematic diagram showing an exemplary software structure of an electronic device;
图14为示例性示出的电子设备的硬件结构示意图。FIG. 14 is a schematic diagram showing a hardware structure of an exemplary electronic device.
具体实施方式Detailed ways
下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例是本申请一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有作出创造性劳动前提下所获得的所有其他实施例,都属于本申请保护的范围。The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.
本文中术语“和/或”,仅仅是一种描述关联对象的关联关系,表示可以存在三种关系,例如,A和/或B,可以表示:单独存在A,同时存在A和B,单独存在B这三种情况。The term "and/or" in this article is merely a description of the association relationship of associated objects, indicating that three relationships may exist. For example, A and/or B can mean: A exists alone, A and B exist at the same time, and B exists alone.
本申请实施例的说明书和权利要求书中的术语“第一”和“第二”等是用于区别不同的对象,而不是用于描述对象的特定顺序。例如,第一目标对象和第二目标对象等是用于区别不同的目标对象,而不是用于描述目标对象的特定顺序。The terms "first" and "second" in the description and claims of the embodiments of the present application are used to distinguish different objects rather than to describe a specific order of objects. For example, a first target object and a second target object are used to distinguish different target objects rather than to describe a specific order of target objects.
在本申请实施例中,“示例性的”或者“例如”等词用于表示作例子、例证或说明。本申请实施例中被描述为“示例性的”或者“例如”的任何实施例或设计方案不应被解释为比其他实施例或设计方案更优选或更具优势。确切而言,使用“示例性的”或者“例如”等词旨在以具体方式呈现相关概念。In the embodiments of the present application, words such as "exemplary" or "for example" are used to indicate examples, illustrations or descriptions. Any embodiment or design described as "exemplary" or "for example" in the embodiments of the present application should not be interpreted as being more preferred or more advantageous than other embodiments or designs. Specifically, the use of words such as "exemplary" or "for example" is intended to present related concepts in a specific way.
在本申请实施例的描述中,除非另有说明,“多个”的含义是指两个或两个以上。例如,多个处理单元是指两个或两个以上的处理单元;多个系统是指两个或两个以上的系统。In the description of the embodiments of the present application, unless otherwise specified, the meaning of "multiple" refers to two or more than two. For example, multiple processing units refer to two or more processing units; multiple systems refer to two or more systems.
脉搏波传导速度(PWV)是评价血管健康的重要指标,基于PWV可以对动脉硬化风险进行评估和等级划分。在穿戴健康监测领域,PWV检测是热点之一。Pulse wave velocity (PWV) is an important indicator for evaluating vascular health. Based on PWV, the risk of arteriosclerosis can be assessed and graded. In the field of wearable health monitoring, PWV detection is one of the hot topics.
目前,业界主要采用心电图(ECG)+PPG方案进行PWV计算,从而得到动脉硬化风险评估结果。其中,ECG是一种经胸腔以时间为单位记录心脏的电生理活动,检测时需要在人体心脏部位的皮肤表面贴上电极;PPG是借助光电手段,在活体组织中检测血液容积变化的无创检测方法,检测时需要在被检测部位设置相应的传感器。At present, the industry mainly uses electrocardiogram (ECG) + PPG scheme to calculate PWV, thereby obtaining the results of arteriosclerosis risk assessment. Among them, ECG is a method of recording the electrophysiological activity of the heart in units of time through the chest cavity. When testing, electrodes need to be attached to the skin surface of the human heart; PPG is a non-invasive detection method that uses photoelectric means to detect changes in blood volume in living tissues. When testing, corresponding sensors need to be set at the detected site.
示例性的,参见图1,图1为ECG+PPG方案进行PWV检测的示意图。在图1中分别对人体手腕、手臂以及心脏位置的信号进行采集,得到ECG信号以及PPG信号,进而根据ECG信号以及PPG信号计算PWV指标。For example, see Figure 1, which is a schematic diagram of PWV detection using the ECG+PPG scheme. In Figure 1, signals from the wrist, arm, and heart of the human body are collected to obtain ECG signals and PPG signals, and then the PWV index is calculated based on the ECG signals and PPG signals.
然而,ECG测量需要在用户胸腔的皮肤表面设置电极,以及需要用户主动进行触发,导致该方案在实现上较为不便。However, ECG measurement requires electrodes to be placed on the skin surface of the user's chest and requires the user to actively trigger it, making this solution inconvenient to implement.
因此,在一些可能的实现方式中,还提供了纯PPG方案的PWV检测。其中,纯PPG方案中又分为多点PPG方案,以及单点PPG方案。Therefore, in some possible implementations, a pure PPG solution for PWV detection is also provided, wherein the pure PPG solution is further divided into a multi-point PPG solution and a single-point PPG solution.
示例性的,多点PPG方案通常是在被检测人体的颈股或臂踝两点设置传感器,从而进行多点的PPG信号采集。由于需要在距离较远的两处及以上的检测点进行数据采集,该方案实现上也较为复杂。For example, the multi-point PPG solution usually sets sensors at two points of the neck or ankle of the detected human body to collect PPG signals at multiple points. Since data collection needs to be performed at two or more detection points that are far apart, the implementation of this solution is also relatively complex.
因此,单点PPG方案成为了当前研究的主流方向。可以理解的是,单点PPG方案是基于PPG信号中主波和重搏波检测以及相关特征分析进行PWV计算,从而得到人体动脉硬化风险评估结果。Therefore, the single-point PPG scheme has become the mainstream direction of current research. It is understandable that the single-point PPG scheme is based on the detection of the main wave and dicrotic wave in the PPG signal and the analysis of related features to calculate PWV, thereby obtaining the risk assessment results of human arteriosclerosis.
示例性的,参见图2,图2为通过穿戴设备采集到的不同年龄段的典型PPG信号对比分析示意图。For example, see FIG2 , which is a schematic diagram of comparative analysis of typical PPG signals of different age groups collected by wearable devices.
从图2中可以看出,年轻人身体机能优秀,每次心跳时血管的收缩和扩张明显,穿戴设备可以明显采集到PPG信号,并能区分出PPG信号中的主波以及重搏波,因此可以准确对PWV指标进行计算。而老年人身体机能较差,穿戴设备采集到的PPG信号弱、干扰大,甚至PPG信号中无明显重搏波,导致PWV指标计算误差大。As can be seen from Figure 2, young people have excellent physical functions, and their blood vessels contract and expand significantly with each heartbeat. Wearable devices can clearly collect PPG signals and distinguish the main wave and dicrotic wave in the PPG signal, so the PWV index can be accurately calculated. However, the physical functions of the elderly are poor, and the PPG signals collected by wearable devices are weak and have great interference, or even there is no obvious dicrotic wave in the PPG signal, resulting in large errors in the calculation of the PWV index.
有鉴于此,本申请实施例提供了一种PPG信号处理方法,通过穿戴设备采集人体的PPG信号,并对PPG信号进行数据处理以及特征计算,将计算得到的特征用于对PWV指标进行预测,从而提升PWV指标计算精度。In view of this, an embodiment of the present application provides a PPG signal processing method, which collects the PPG signal of the human body through a wearable device, performs data processing and feature calculation on the PPG signal, and uses the calculated features to predict the PWV index, thereby improving the calculation accuracy of the PWV index.
目前,可穿戴设备(以智能手表为例)为了实现对人体的PWV、心率、血氧浓度、血压等进行精准地实时监测,通常会在与用户皮肤接触的一面,如图3中示出的背面设置PPG传感器,进而基于PPG传感器采集到的信息,利用PWV算法、心率算法、血氧浓度算法、血压算法等对人体的PWV、心率、血氧浓度、血压等进行精准地实时监测。At present, in order to realize accurate real-time monitoring of human body's PWV, heart rate, blood oxygen concentration, blood pressure, etc., wearable devices (taking smart watches as an example) usually set a PPG sensor on the side in contact with the user's skin, such as the back side as shown in FIG3 . Then, based on the information collected by the PPG sensor, the PWV algorithm, heart rate algorithm, blood oxygen concentration algorithm, blood pressure algorithm, etc. are used to accurately monitor the human body's PWV, heart rate, blood oxygen concentration, blood pressure, etc. in real time.
其中,PPG传感器包括发光二极管(light emitting diode,LED)和接收器。为了便于说明,以测量PWV为例。参见图4,示例性的,在用户将图3示出的包括PPG传感器的智能手表佩戴在手臂上,并且开启了血管健康检测功能。在一种可能的实现方式中,为了提升用户体验,可以在智能手表的用户界面显示血管检测图片,以及“正在测量”的文字信息,如图4中(1)所示。The PPG sensor includes a light emitting diode (LED) and a receiver. For ease of explanation, take the measurement of PWV as an example. Referring to FIG4 , illustratively, the user wears the smart watch including the PPG sensor shown in FIG3 on the arm and turns on the vascular health detection function. In a possible implementation, in order to improve the user experience, a vascular detection picture and a text message of "measuring" can be displayed on the user interface of the smart watch, as shown in FIG4 (1).
示例性的,在智能手表的用户界面处于图4中(1)所示的样式时,智能手表中PPG传感器内的LED将不断向皮肤投射光线,光透过皮肤组织被血液吸收,同时接收器接收反射回来的光信号。当将反射回来的光信号转换成电信号时,由于动脉里有血液的脉动,那么对光线的吸收也会有变化,因此可以得到交流AC信号,提取AC信号即可得到PPG信号。通过分析PPG特征,便可以确定用户的PWV。最后,便可以在智能手表的用户界面显示出测量出的PWV指标,如图4中(2)所示。Exemplarily, when the user interface of the smart watch is in the style shown in (1) of FIG. 4 , the LED in the PPG sensor of the smart watch will continuously project light onto the skin, and the light will be absorbed by the blood through the skin tissue, while the receiver will receive the reflected light signal. When the reflected light signal is converted into an electrical signal, the absorption of light will also change due to the pulsation of blood in the artery, so an alternating current (AC) signal can be obtained, and the PPG signal can be obtained by extracting the AC signal. By analyzing the PPG characteristics, the user's PWV can be determined. Finally, the measured PWV index can be displayed on the user interface of the smart watch, as shown in (2) of FIG. 4 .
需要说明的是,在理想情况下,采集到的PPG信号可以准确的检测出人体各时刻的PWV指标。然而,由于硬件、温度、运动等复杂场景,导致PPG的真实信号失真,使得PWV计算的准确率受到极大的制约。由于PPG信号对运动特别敏感,即PPG信号易存在运动伪影,导致PPG信号出现干扰的情况并难以处理,导致预测结果不准。因此,本申请实施例中提供了一种PPG信号处理方法对PPG信号进行处理,将处理后的PPG信号用于后续的PWV指标预测,从而得到精确的PWV指标。It should be noted that, under ideal conditions, the collected PPG signal can accurately detect the PWV index of the human body at each moment. However, due to complex scenarios such as hardware, temperature, and motion, the real signal of the PPG is distorted, which greatly restricts the accuracy of the PWV calculation. Since the PPG signal is particularly sensitive to motion, that is, the PPG signal is prone to motion artifacts, the PPG signal is interfered and difficult to process, resulting in inaccurate prediction results. Therefore, a PPG signal processing method is provided in an embodiment of the present application to process the PPG signal, and the processed PPG signal is used for subsequent PWV index prediction, so as to obtain an accurate PWV index.
在一种可能的实现方式中,为了进一步提高用户的使用体验,本申请实施例中还可以将智能手表检测得到的PPG数据以及计算得到的PWV指数发送至用户的手机上,以供用户查阅。In one possible implementation, in order to further improve the user experience, the PPG data detected by the smart watch and the calculated PWV index can also be sent to the user's mobile phone in the embodiment of the present application for the user to review.
示例性的,用户点击手机上的血管健康应用时,手机响应于该操作,显示血管健康检测界面,如图5中(1)的界面10a。界面10a中包括脉搏波显示区域10a-1和检测倒计时显示区域10a-2。此时,智能手表开始血管检测,显示界面如图4中(1)所示的界面时。智能手表将采集到的PPG数据实时发送至手机上,手机在界面10a中接收到的PPG数据对脉搏波显示区域10a-1进行更新,以及根据检测剩余时间对显示区域10a-2进行更新。Exemplarily, when a user clicks on the vascular health application on the mobile phone, the mobile phone responds to the operation and displays a vascular health detection interface, such as interface 10a in (1) of FIG5 . Interface 10a includes a pulse wave display area 10a-1 and a detection countdown display area 10a-2. At this time, the smart watch starts vascular detection, and the display interface is the interface shown in (1) of FIG4 . The smart watch sends the collected PPG data to the mobile phone in real time, and the mobile phone updates the pulse wave display area 10a-1 with the PPG data received in interface 10a, and updates the display area 10a-2 according to the remaining detection time.
在智能手表完成PPG数据采集以及得到PWV指标,并将PWV指标发送至手机后,手机显示血管健康检测结果界面10b,如图5中(2)所示。界面10b中包括动脉硬化风险等级控件10b-1和PWV指数控件10b-2。After the smart watch completes PPG data collection and obtains the PWV index, and sends the PWV index to the mobile phone, the mobile phone displays the vascular health test result interface 10b, as shown in (2) of Figure 5. The interface 10b includes an arteriosclerosis risk level control 10b-1 and a PWV index control 10b-2.
示例性的,手机在接收到PWV指标后,根据PWV指标对控件10b-2更新,以及根据PWV指标对应风险等级对控件10b-1进行更新。Exemplarily, after receiving the PWV indicator, the mobile phone updates the control 10b-2 according to the PWV indicator, and updates the control 10b-1 according to the risk level corresponding to the PWV indicator.
至此,本申请实施例通过PPG传感器采集人体中的PPG信号,并基于本申请实施例提供的PPG信号处理方法对PPG信号进行处理,将处理后的PPG信号用于PWV指标预测,从而得到准确的PWV指标,提升了PWV指标的计算精度。At this point, the embodiment of the present application collects the PPG signal in the human body through the PPG sensor, and processes the PPG signal based on the PPG signal processing method provided in the embodiment of the present application, and uses the processed PPG signal for PWV index prediction, thereby obtaining an accurate PWV index and improving the calculation accuracy of the PWV index.
为了更好地理解本申请实施例提供的PPG信号处理方法对PPG信号的处理流程,下述实施例仍以智能手表100为例,结合图6至图12对PPG信号处理流程进行说明。In order to better understand the processing flow of the PPG signal by the PPG signal processing method provided in the embodiment of the present application, the following embodiment still takes the smart watch 100 as an example, and illustrates the PPG signal processing flow in combination with Figures 6 to 12.
示例性的,如图6所示,本申请实施例中的PPG信号处理方法,在实现过程中可以分为4个阶段(如数据采集阶段、数据预处理阶段、数据处理阶段和特征计算阶段),以及对应5个模块(如信号采集模块、信号预处理模块、峰谷检测模块、单周期信号提取模块、单周期信号分解模块和特征提取模块)。Exemplarily, as shown in FIG6 , the PPG signal processing method in the embodiment of the present application can be divided into four stages (such as data acquisition stage, data preprocessing stage, data processing stage and feature calculation stage) during the implementation process, and corresponding five modules (such as signal acquisition module, signal preprocessing module, peak and valley detection module, single-cycle signal extraction module, single-cycle signal decomposition module and feature extraction module).
参见图6,示例性的,在数据采集阶段,通过穿戴设备中的数据采集模块对人体进行数据采集,采集到的数据包括但不限于加速度计(ACC)信号和PPG信号。6 , illustratively, in the data collection stage, data of the human body is collected through the data collection module in the wearable device, and the collected data includes but is not limited to accelerometer (ACC) signals and PPG signals.
在穿戴设备进行数据采集的过程中,由于人体存在运动或晃动的可能,导致产生运动伪影。运动伪影将导致后续数据使用过程中无法准确确定单周期PPG信号,因此需要识别此类干扰信号并中止数据采集。During the data collection process of the wearable device, motion artifacts may be generated due to the possibility of human body movement or shaking. Motion artifacts will make it impossible to accurately determine the single-cycle PPG signal during the subsequent data use process, so it is necessary to identify such interference signals and terminate data collection.
示例性的,若穿戴设备佩戴状态不佳,例如松佩戴或表盘朝下产生空隙,PPG信号也会出现干扰情况。For example, if the wearable device is not worn properly, such as being worn loosely or with the dial facing downward resulting in a gap, the PPG signal may also be interfered.
示例性的,参见图7,在图7中当用户处于运动状态时,三轴ACC信号和PPG信号出现明显无规律波动;而在用户结束运动状态进入静止状态时,ACC信号与PPG信号呈现规律波动。因此,在用户处于运动状态时,PPG信号无法用于后续的PWV指标计算,需要中止检测;在用户进入静止状态后,PPG信号才能真实反应出用户的PWV指标,可以进行检测。For example, see Figure 7. In Figure 7, when the user is in motion, the three-axis ACC signal and PPG signal show obvious irregular fluctuations; when the user ends the motion state and enters the static state, the ACC signal and PPG signal show regular fluctuations. Therefore, when the user is in motion, the PPG signal cannot be used for subsequent PWV index calculations, and the detection needs to be terminated; after the user enters the static state, the PPG signal can truly reflect the user's PWV index and can be detected.
本申请实施例中通过在进行PPG信号采集的过程中对ACC信号同步进行采集,将得到的ACC信号用于对人体进行运动状态检测,从而根据检测结果作为PPG信号是否中止的条件。In the embodiment of the present application, the ACC signal is synchronously collected during the PPG signal collection process, and the obtained ACC signal is used to detect the motion state of the human body, so that the detection result is used as the condition for whether to terminate the PPG signal.
关于数据采集阶段就介绍到此,关于数据采集阶段中未详细记载的技术细节,可以参见现有对传感器信号的采集的实现方案,此处不再赘述。This is the end of the introduction to the data collection stage. For technical details not recorded in detail in the data collection stage, please refer to the existing implementation plan for collecting sensor signals, which will not be repeated here.
继续参见图6,示例性的,在数据预处理阶段的操作包括,通过穿戴设备中的信号预处理模块对PPG信号进行丢包检测,以及对原始PPG信号进行带通滤波得到滤波信号S1。Continuing to refer to FIG. 6 , illustratively, the operations in the data preprocessing stage include performing packet loss detection on the PPG signal through a signal preprocessing module in the wearable device, and performing bandpass filtering on the original PPG signal to obtain a filtered signal S1.
在一种可能的实现方式中,ACC信号以及PPG信号的采样频率均设置为100赫兹(Hz),并按照100毫秒(ms)数据包进行组包上传。在ACC信号的运动状态检测通过后,还需要对PPG信号进行预处理,预处理方式包括时间戳校验以及带通滤波。In a possible implementation, the sampling frequency of the ACC signal and the PPG signal are both set to 100 Hz, and are uploaded in 100 ms packets. After the motion state detection of the ACC signal is passed, the PPG signal needs to be preprocessed, including timestamp verification and bandpass filtering.
其中,时间戳校验是用于:1. 判断PPG信号和ACC信号是否同步,2. 判断PPG数据是否丢包。Among them, the timestamp check is used to: 1. Determine whether the PPG signal and ACC signal are synchronized, 2. Determine whether the PPG data is lost.
示例性的,若PPG信号数据包与ACC信号数据包的时间戳差异大于一个预设阈值(该预设阈值可以是根据经验设定的,其值可以设定为200ms),则认定PPG信号与ACC信号不同步,并通过图4中(1)和图5中(1)的界面提示用户,重新进行检测。Exemplarily, if the timestamp difference between the PPG signal data packet and the ACC signal data packet is greater than a preset threshold (the preset threshold may be set based on experience, and its value may be set to 200ms), it is determined that the PPG signal is not synchronized with the ACC signal, and the user is prompted to re-test through the interfaces of (1) in FIG. 4 and (1) in FIG. 5 .
示例性的,若当前的PPG信号数据包与上一个PPG信号数据包的时间戳差异大于另一个预设阈值(该预设阈值可以是根据经验设定的,其值可以设定为150ms),则认定PPG信号存在丢包情况,并通过图4中(1)和图5中(1)的界面提示用户,重新进行检测。Exemplarily, if the timestamp difference between the current PPG signal data packet and the previous PPG signal data packet is greater than another preset threshold (the preset threshold may be set based on experience, and its value may be set to 150ms), it is determined that there is packet loss in the PPG signal, and the user is prompted through the interfaces of (1) in FIG. 4 and (1) in FIG. 5 to re-perform the test.
在PPG信号不存在丢包情况下,采用滤波器进行其进行带通滤波,最终得到滤波信号PPGFilt。上述滤波器可以是0.5~4Hz的二阶巴特沃斯(Butterworth)滤波器。When there is no packet loss in the PPG signal, a filter is used to perform bandpass filtering on it, and finally a filtered signal PPGFilt is obtained. The filter can be a second-order Butterworth filter with a frequency of 0.5-4 Hz.
关于数据预处理阶段就介绍到此,关于数据预处理阶段中带通滤波阶段的详细技术细节,可以参考现有滤波器的滤波实现方案,此处不再赘述。This is the end of the introduction to the data preprocessing stage. For detailed technical details of the bandpass filtering stage in the data preprocessing stage, please refer to the filtering implementation scheme of the existing filter, which will not be repeated here.
继续参见图6,示例性的,在数据处理阶段的操作包括,通过穿戴设备中的峰谷检测模块进行峰谷检测,单周期信号提取模块进行单周期信号提取以及单周期信号分解模块进行单周期信号分解。Continuing to refer to FIG. 6 , illustratively, the operations in the data processing stage include performing peak-valley detection by a peak-valley detection module in the wearable device, performing single-cycle signal extraction by a single-cycle signal extraction module, and performing single-cycle signal decomposition by a single-cycle signal decomposition module.
在PPG信号完成滤波后,本申请实施例通过对滤波信号PPGFilt进行峰谷检测,从而得到每个心拍周期对应的峰谷值。基于相邻的谷值点对PPGFilt进行单周期信号截取,得到对应的多个单周期PPG信号集合S1。After the PPG signal is filtered, the embodiment of the present application performs peak-valley detection on the filtered signal PPGFilt to obtain the peak-valley value corresponding to each heartbeat cycle. Based on the adjacent valley value points, single-cycle signal interception is performed on PPGFilt to obtain a corresponding set of multiple single-cycle PPG signals S1.
示例性的,参见图8和图9,对PPGFilt进行峰谷检测后,可以得到每个心拍周期的峰谷值。根据相邻的两个谷值对PPGFilt进行单周期信号截取,得到多个单周期PPG信号集合S1。其中,单周期PPG信号集合S1的形态参见图10中(1)。For example, referring to FIG8 and FIG9, after performing peak-valley detection on PPGFilt, the peak-valley value of each heartbeat cycle can be obtained. According to two adjacent valley values, a single-cycle signal of PPGFilt is intercepted to obtain a plurality of single-cycle PPG signal sets S1. The shape of the single-cycle PPG signal set S1 is shown in FIG10 (1).
由于穿戴设备检测过程中PPG幅值存在波动,还需要对每个单周期PPG信号进行起止点拉齐处理得到信号集合S2(参见图10中(2)),以及归一化处理得到信号集合S3(参见图10中(3))。Since the PPG amplitude fluctuates during the wearable device detection process, it is also necessary to align the start and end points of each single-cycle PPG signal to obtain signal set S2 (see (2) in Figure 10), and normalize it to obtain signal set S3 (see (3) in Figure 10).
在穿戴设备检测的场景中,即使用户无明显的运动或晃动,PPG信号同样容易受佩戴位置、佩戴松紧度、心律不齐或人体微动等因素影响,从而导致不同周期下PPG信号出现较大差异,甚至可能出现单周期PPG信号识别错误的情况。In the scenario of wearable device detection, even if the user has no obvious movement or shaking, the PPG signal is still easily affected by factors such as wearing position, wearing tightness, arrhythmia or human body micro-movement, resulting in large differences in PPG signals in different cycles, and even single-cycle PPG signal recognition errors may occur.
因此,本申请实施例通过单周期信号提取模块基于信号集合S3进行主信号提取,得到单周期PPG主信号S4。Therefore, in the embodiment of the present application, a single-cycle signal extraction module is used to extract the main signal based on the signal set S3 to obtain a single-cycle PPG main signal S4.
在得到主信号S4后,还需要对主信号S4进行分解,从而得到如图2中(1)所示的主波和重搏波。After obtaining the main signal S4, it is necessary to decompose the main signal S4 to obtain the main wave and the dicrotic wave as shown in (1) in FIG. 2 .
示例性的,在得到主信号S4后,使用双高斯函数模型对主信号S4进行分解,然后使用最小二乘法(LM算法)对其进行拟合,得到第一高斯波S6和第二高斯波S7,其中第一高斯波为主波,第二高斯波为重搏波。Exemplarily, after obtaining the main signal S4, the main signal S4 is decomposed using a double Gaussian function model, and then fitted using a least squares method (LM algorithm) to obtain a first Gaussian wave S6 and a second Gaussian wave S7, wherein the first Gaussian wave is the main wave and the second Gaussian wave is the dicrotic wave.
继续参见图6,示例性的,在特征提取阶段的操作为根据得到的主信号S4、第一高斯波、第二高斯波以及用户的基础信息在穿戴设备中特征提取模块中进行特征计算。Continuing to refer to FIG. 6 , illustratively, the operation in the feature extraction stage is to perform feature calculation in the feature extraction module in the wearable device according to the obtained main signal S4 , the first Gaussian wave, the second Gaussian wave and the basic information of the user.
示例性的,根据主信号S4、第一高斯波和第二高斯波进行特征计算,得到第一特征;第一特征包括但不限于S4总时长T、第一高斯波上升时间T1、双波间隔∆T、反射指数RI、增强指数AI、心率间隔RR、K值。Exemplarily, feature calculation is performed based on the main signal S4, the first Gaussian wave and the second Gaussian wave to obtain the first feature; the first feature includes but is not limited to the total duration T of S4, the rise time T1 of the first Gaussian wave, the double-wave interval ∆T, the reflection index RI, the enhancement index AI, the heart rate interval RR, and the K value.
示例性的,根据基础信息得到基础特征,基础特征包括但不限于身高Height、年龄Age、体重Weight。Exemplarily, basic features are obtained according to the basic information, and the basic features include but are not limited to height, age, and weight.
示例性的,根据第一特征和基础特征得到引申的组合特征(后续称之为第二特征),第二特征包括但不限于第一高斯波上线时间占比、硬化指数SI、归一化硬化指数、BMI指数等。Exemplarily, a combined feature (hereinafter referred to as the second feature) is derived from the first feature and the basic feature. The second feature includes but is not limited to the proportion of the first Gaussian wave online time, the hardening index SI, the normalized hardening index, the BMI index, etc.
继续参见图6,示例性的,将对不同的用户采集到的PPG信号基于本申请实施例的PPG信号处理方法后,构成PPG特征集合,再对PPG特征集合进行特征筛选,将筛选得到的特征集合利用机器学习算法或多元线性回归算法作为PWV回归模型进行训练,即可得到用于预测PWV指标的PWV回归模型。PWV回归模型可以下发至各个智能穿戴设备上,从而使得智能穿戴设备基于PWV回归模型进行PWV指标检测,提高PWV的精确度。Continuing to refer to FIG. 6, illustratively, the PPG signals collected from different users are processed based on the PPG signal processing method of the embodiment of the present application to form a PPG feature set, and then the PPG feature set is subjected to feature screening, and the screened feature set is trained as a PWV regression model using a machine learning algorithm or a multivariate linear regression algorithm to obtain a PWV regression model for predicting the PWV index. The PWV regression model can be sent to each smart wearable device, so that the smart wearable device performs PWV index detection based on the PWV regression model to improve the accuracy of PWV.
示例性的,上述进行特征筛选的步骤,可以是采用基于Pearson相关性分析筛选出参考PWV与计算特征的相关系数大于0.1的特征集合。Exemplarily, the step of performing feature screening may be to screen out a feature set having a correlation coefficient between the reference PWV and the calculated feature greater than 0.1 based on Pearson correlation analysis.
示例性的,上述机器学习算法可以包括SVM、逻辑回归、或主流的决策树模型。例如随机森林算法、迭代算法(AdaBoost)、优化的分布式梯度增强库(XGBoost)、梯度提升机器学习算法(CatBoost)、梯度提升决策树模型(LightGBM)等。Exemplarily, the above machine learning algorithms may include SVM, logistic regression, or mainstream decision tree models, such as random forest algorithm, iterative algorithm (AdaBoost), optimized distributed gradient boosting library (XGBoost), gradient boosting machine learning algorithm (CatBoost), gradient boosting decision tree model (LightGBM), etc.
由此,通过不断的迭代训练,最终得到PWV回归模型。基于本申请实施例中的PWV回归模型可以降低因个体差异或佩戴位置,导致的脉搏波特征无法计算的问题,大大提升了PWV指标的精确度。Thus, through continuous iterative training, a PWV regression model is finally obtained. The PWV regression model in the embodiment of the present application can reduce the problem of pulse wave characteristics being unable to be calculated due to individual differences or wearing positions, and greatly improves the accuracy of the PWV index.
基于图6示出的PPG信号处理的4个阶段的描述,本申请实施例提供的PPG信号处理方法的实现流程,可包括:Based on the description of the four stages of PPG signal processing shown in FIG6 , the implementation process of the PPG signal processing method provided in the embodiment of the present application may include:
S101,获取可穿戴设备采集的光电容积脉搏波PPG信号和加速度ACC信号。S101, obtaining a photoplethysmogram (PPG) signal and an acceleration (ACC) signal collected by a wearable device.
其中,ACC信号为三轴ACC信号,具体包括沿X轴的AccX信号、沿Y轴的AccY信号和沿Z轴的AccZ信号。示例性的,参见图7中(1),曲线Accx、曲线Accy和曲线Accz为采集到的三轴ACC信号。The ACC signal is a three-axis ACC signal, specifically including an AccX signal along the X axis, an AccY signal along the Y axis, and an AccZ signal along the Z axis. For example, referring to (1) in FIG. 7 , curves Accx, Accy, and Accz are the collected three-axis ACC signals.
示例性的,PPG信号和ACC信号的采样频率均可以设置为100Hz,并按照100ms数据包进行组包上传。Exemplarily, the sampling frequencies of the PPG signal and the ACC signal can both be set to 100 Hz, and the signals can be grouped and uploaded in 100 ms data packets.
示例性的,PPG信号可以是由可穿戴设备中的PPG传感器采集到的。关于PPG传感器的位置,可以是位于与用户皮肤接触的一面,如图3示出的智能手表的背面。Exemplarily, the PPG signal may be collected by a PPG sensor in a wearable device. Regarding the location of the PPG sensor, it may be located on the side in contact with the user's skin, such as the back of the smart watch shown in FIG3 .
示例性的,ACC信号可以是由集成在可穿戴设备中的ACC传感器采集到的。Exemplarily, the ACC signal may be collected by an ACC sensor integrated in the wearable device.
需要说明的是,由可穿戴设备采集到的PPG信号和ACC信号,为可穿戴设备在相同状态、相同周期内采集的。It should be noted that the PPG signal and ACC signal collected by the wearable device are collected by the wearable device in the same state and the same period.
在一种可能的实现方式中,由于ACC信号与PPG信号是同一状态和同一周期内采集的信号,因此还可以将ACC信号的信号质量用于对PPG信号的信号质量进行评估。In a possible implementation, since the ACC signal and the PPG signal are signals collected in the same state and the same period, the signal quality of the ACC signal can also be used to evaluate the signal quality of the PPG signal.
其中,ACC信号的质量评价过程可以包括:The quality evaluation process of the ACC signal may include:
S001,对所述AccX信号、所述AccY信号和所述AccZ信号依次进行模值计算、差分和绝对化处理,得到差分模值AccSDiff;S001, performing modulus calculation, differential and absolutization processing on the AccX signal, the AccY signal and the AccZ signal in sequence to obtain a differential modulus value AccSDiff;
其中,ACC信号模值AccS为:Among them, the ACC signal modulus AccS is:
; ;
其中,差分模值AccSDiff为:Among them, the differential modulus value AccSDiff is:
; ;
其中,,N为ACC信号模值的个数。in, , N is the number of ACC signal module values.
示例性的,参见图7中(2)和(3),曲线AccSDiff为计算得到的差分模值信号,曲线PPG信号为采集得到的PPG信号。对比差分模值信号与PPG信号可知,不同的ACC信号状态下PPG信号出现显著差别,因此可以通过基于ACC信号对可穿戴设备进行运动检测,并基于检测结果对PPG信号进行质量评估。For example, see (2) and (3) in Figure 7, where the curve AccSDiff is the calculated differential mode signal, and the curve PPG signal is the collected PPG signal. By comparing the differential mode signal with the PPG signal, it can be seen that the PPG signal shows significant differences under different ACC signal states. Therefore, the wearable device can be used for motion detection based on the ACC signal, and the quality of the PPG signal can be evaluated based on the detection results.
S002,基于所述AccX信号、所述AccY信号和所述AccZ信号,计算预设周期内三轴朝向不达标次数和斜率突变次数;S002, calculating the number of non-standard orientations of the three axes and the number of slope mutations within a preset period based on the AccX signal, the AccY signal and the AccZ signal;
其中,三轴朝向不达标次数DirectCount和斜率突变次数MaxSlopeCount用于识别用户佩戴手表时,是否表盘朝上,满足紧佩戴要求,从而降低由于佩戴姿态不正确导致的PPG信号质量降低的情况。Among them, DirectCount , the number of times the three-axis orientation does not meet the standard, and MaxSlopeCount , the number of slope mutations, are used to identify whether the dial is facing upward when the user wears the watch, meeting the tight wearing requirements, thereby reducing the situation where the PPG signal quality is reduced due to incorrect wearing posture.
示例性的,预设周期内三轴朝向不达标次数可以是每秒内三轴朝向不达标次数,其中不达标的判断条件可以是Abs(mean(AccXj))<0.5G,且Abs(mean(AccYj))<0.5G,且Abs(mean(AccZj))>0.8G,j为第i秒对应的各轴ACC数据索引。在AccX信号、AccY信号和AccZ信号同时不满足上述条件时,则判定当前时间内三轴ACC信号不满足正向佩戴条件,将每秒内三轴朝向不达标次数加1。其中,G表示1个重力加速度,G=9.8m/s2。Exemplarily, the number of times the three-axis orientation fails to meet the standard within the preset period may be the number of times the three-axis orientation fails to meet the standard within each second, wherein the judgment condition for failure to meet the standard may be Abs(mean(AccX j ))<0.5G, and Abs(mean(AccY j ))<0.5G, and Abs(mean(AccZ j ))>0.8G, where j is the index of the ACC data of each axis corresponding to the i-th second. When the AccX signal, the AccY signal, and the AccZ signal do not meet the above conditions at the same time, it is determined that the three-axis ACC signal does not meet the forward wearing condition within the current time, and the number of times the three-axis orientation fails to meet the standard within each second is increased by 1. Wherein, G represents 1 gravitational acceleration, G=9.8m/s 2 .
示例性的,预设周期内斜率突变次数可以是每秒内三轴ACC信号任一最大或最小斜率值大于预设斜率阈值,则判定ACC信号发生在当前时间内发生突变,将每秒内斜率突变次数加1。其中,预设斜率阈值可以设定为0.05G。For example, the number of slope mutations within the preset period can be that if any maximum or minimum slope value of the three-axis ACC signal within one second is greater than a preset slope threshold, it is determined that the ACC signal has a mutation within the current time, and the number of slope mutations within one second is increased by 1. The preset slope threshold can be set to 0.05G.
S003,基于所述差分模值AccSDiff,计算所述预设周期内平均值、最大值和方差;S003, based on the differential modulus value AccSDiff , calculating the average value, maximum value and variance within the preset period;
具体的,采用不重叠滑动窗在差分模值AccSDiff进行滑动,对窗口内的数据计算每秒平均值AccSMean i,每秒最大值AccSMaxVal i和每秒方差值AccSVar i,直至计算完成得到连续N秒的特征值数组。其中,滑动窗口大小为1秒。Specifically, a non-overlapping sliding window is used to slide on the differential modulus value AccSDiff, and the average value AccSMean i per second, the maximum value AccSMaxVal i per second, and the variance value AccSVar i per second are calculated for the data in the window until the calculation is completed to obtain an array of eigenvalues for N consecutive seconds. The sliding window size is 1 second.
S004,在所述三轴朝向不达标次数、所述斜率突变次数、所述平均值、所述最大值和所述方差满足预设中止条件时,重新获取所述PPG信号和所述ACC信号。S004, when the number of non-standard changes in the three-axis orientations, the number of slope mutations, the average value, the maximum value, and the variance meet preset termination conditions, reacquiring the PPG signal and the ACC signal.
具体的,上述中止条件包括:Specifically, the above-mentioned suspension conditions include:
条件1:若累计的三轴朝向不达标次数DirectCount>5,则判断当前可穿戴设备佩戴姿态不满足佩戴要求,中止本次检测,并通过可穿戴设备或手机提示用户正确佩戴。Condition 1: If the cumulative number of times the three-axis orientation fails to meet the standard DirectCount > 5, it is determined that the current wearing posture of the wearable device does not meet the wearing requirements, the current detection is terminated, and the user is prompted to wear the device correctly through the wearable device or mobile phone.
条件2,若累计的斜率突变次数MaxSlopeCount>8,则判定用户当前身体状态不满足静止状态,中止本次检测,并通过可穿戴设备或手机提示用户保持静止。Condition 2: If the accumulated number of slope mutations MaxSlopeCount > 8, it is determined that the user's current physical state does not meet the static state, the detection is terminated, and the user is prompted to remain still through the wearable device or mobile phone.
条件3,获取上特征值数组中AccSMean i>0.01G的个数C1,AccSMaxVal i>0.04G的个数C2,AccSVar i>0.5G个数C3。在C1>3且C2>5,或C1>5且C3>4的情况下,判定用户当前身体状态不满足静止状态,中止本次检测,并通过可穿戴设备或手机提示用户保持静止。Condition 3: Get the number of AccSMean i > 0.01G C1, the number of AccSMaxVal i > 0.04G C2, and the number of AccSVar i > 0.5G C3 in the upper eigenvalue array. When C1 > 3 and C2 > 5, or C1 > 5 and C3 > 4, it is determined that the user's current physical state does not meet the static state, the detection is terminated, and the user is prompted to remain still through the wearable device or mobile phone.
本申请实施例中通过基于ACC信号的质量评估结果,对PPG信号的质量进行预测,从而避免了后续计算过程中无法准确定位单周期PPG信号的问题。In the embodiment of the present application, the quality of the PPG signal is predicted based on the quality evaluation result of the ACC signal, thereby avoiding the problem of being unable to accurately locate the single-cycle PPG signal in the subsequent calculation process.
S102,对所述PPG信号进行预处理得到滤波信号,所述预处理包括基于所述ACC信号对所述PPG信号进行时间戳同步校验、基于所述PPG信号的相邻数据包的时间戳进行丢包检测和对所述PPG信号进行滤波。S102, preprocessing the PPG signal to obtain a filtered signal, wherein the preprocessing includes performing a timestamp synchronization check on the PPG signal based on the ACC signal, performing packet loss detection based on timestamps of adjacent data packets of the PPG signal, and filtering the PPG signal.
具体的,将PPG信号的时间戳与ACC信号的时间戳进行校验,判断PPG信号与ACC数据是否同步,以及根据PPG信号的项链数据包的时间戳判断PPG信号是否丢包。Specifically, the timestamp of the PPG signal is verified with the timestamp of the ACC signal to determine whether the PPG signal is synchronized with the ACC data, and whether the PPG signal is lost is determined according to the timestamp of the necklace data packet of the PPG signal.
示例性的,若PPG信号与ACC信号的时间戳差异>200ms的情况,则认为PPG信号与ACC信号不同步,返回数据异常提示,并重新采集PPG信号和ACC信号。Exemplarily, if the timestamp difference between the PPG signal and the ACC signal is greater than 200 ms, it is considered that the PPG signal and the ACC signal are not synchronized, a data abnormality prompt is returned, and the PPG signal and the ACC signal are re-collected.
示例性的,若相邻的PPG信号数据包的时间戳差异>150ms,则认为PPG数据存在丢包,返回数据异常提示,并重新采集PPG信号和ACC信号。Exemplarily, if the timestamp difference between adjacent PPG signal data packets is greater than 150 ms, it is considered that there is packet loss in the PPG data, a data abnormality prompt is returned, and the PPG signal and ACC signal are re-collected.
在判定PPG信号不存在丢包情况时,采用0.5~4Hz的二阶巴特沃斯滤波器进行带通滤波,最终得到滤波信号PPGFilt。When it is determined that there is no packet loss in the PPG signal, a second-order Butterworth filter with a frequency of 0.5-4 Hz is used for band-pass filtering, and finally a filtered signal PPGFilt is obtained.
S103,对所述滤波信号进行峰谷检测,基于检测结果对所述滤波信号进行二次处理得到单周期PPG信号集合,所述二次处理包括基于所述检测结果对所述滤波信号进行单周期信号截取,对截取得到的信号集合进行起止点拉齐以及幅值归一化。S103, performing peak and valley detection on the filtered signal, and performing secondary processing on the filtered signal based on the detection result to obtain a single-cycle PPG signal set, wherein the secondary processing includes performing single-cycle signal interception on the filtered signal based on the detection result, aligning the start and end points of the intercepted signal set, and normalizing the amplitude.
示例性的,对上述滤波信号PPGFilt进行峰谷检测,从而得到每个心拍周期对应的峰谷值,如图8所示。Exemplarily, peak-valley detection is performed on the filtered signal PPGFilt to obtain peak-valley values corresponding to each heartbeat cycle, as shown in FIG8 .
示例性的,根据检测得到上述滤波信号PPGFilt的每个心拍周期对应的峰谷值,将相邻的两个谷值点作为起始点进行单周期信号截取(其示例参见图9),得到多个单周期PPG信号集合S1,其示例参见图10中(1)。Exemplarily, according to the peak-to-valley values corresponding to each heartbeat cycle of the above-mentioned filtered signal PPGFilt obtained by detection, two adjacent valley points are used as starting points for single-cycle signal interception (see Figure 9 for an example), and multiple single-cycle PPG signal sets S1 are obtained, and an example is seen in (1) of Figure 10.
由于在穿戴设备的佩戴过程中,PPG幅值存在波动,因此还需要分别对每个单周期PPG信号S1进行起止点拉齐处理,得到信号S2,其中S2的波形参见图10中(2)所示。Since the PPG amplitude fluctuates during the wearing of the wearable device, it is also necessary to align the start and end points of each single-cycle PPG signal S1 to obtain signal S2, where the waveform of S2 is shown in (2) in Figure 10.
示例性的,拉齐处理方法为:取长度为N的单周期信号S:Exemplarily, the alignment processing method is: take a single-cycle signal S with a length of N:
。 .
设置:set up:
, ,
然后逐点修改S1中信号得到信号S2,其中S2中每项元素分别为:Then modify the signal in S1 point by point to obtain signal S2, where each element in S2 is:
。 .
示例性的,N可以是信号S1中信号点个数。Exemplarily, N may be the number of signal points in signal S1.
再将拉齐处理后的信号S2进行幅度归一化,归一化到[0,1],得到单周期PPG信号集合S3,其中S3的波形参见图10中(3)。The amplitude of the signal S2 after the alignment processing is then normalized to [0, 1] to obtain a single-cycle PPG signal set S3, where the waveform of S3 is shown in (3) in Figure 10.
其中,信号集合S3中每项元素分别为:Among them, each element in the signal set S3 is:
。 .
其中,,N为单周期信号的长度,data Min为信号集合S3中最小值,data Max为信号集合S3中最大值。in, , N is the length of a single-cycle signal, data Min is the minimum value in signal set S3, and data Max is the maximum value in signal set S3.
S104,将所述单周期PPG信号集合中每一个单周期PPG信号与预设模板信号集合中的每一个模板信号进行匹配,将匹配成功次数最高的模板信号设置为单周期PPG主信号,所述预设模板信号集合中包含至少一个模板信号。S104, matching each single-cycle PPG signal in the single-cycle PPG signal set with each template signal in a preset template signal set, setting the template signal with the highest number of successful matches as the single-cycle PPG main signal, wherein the preset template signal set includes at least one template signal.
具体的,上述预设模板信号集合中的模板信号可以是预先设置的,也可以是根据上述单周期PPG信号S3进行设置的。Specifically, the template signal in the preset template signal set may be pre-set, or may be set according to the single-cycle PPG signal S3.
在穿戴设备进行信号采集的过程中,即使用户无较大的运动或晃动,PPG信号同样容易受到佩戴位置、佩戴松紧度、心律不齐或人体微动等因素的影响,导致不同周期下PPG信号出现较大差异,甚至可能出现单周期PPG信号识别错误的情况。因此,本申请实施例还提供了一套单周期PPG主信号提取流程,具体实现步骤如下:During the signal acquisition process of the wearable device, even if the user does not move or shake significantly, the PPG signal is still easily affected by factors such as the wearing position, tightness, arrhythmia or micro-movement of the human body, resulting in large differences in PPG signals in different cycles, and even single-cycle PPG signal recognition errors. Therefore, the embodiment of the present application also provides a single-cycle PPG main signal extraction process, and the specific implementation steps are as follows:
S401,依次计算所述单周期PPG信号集合中每一个单周期PPG信号的偏度指数和峰度指数。S401, sequentially calculating the skewness index and the kurtosis index of each single-cycle PPG signal in the single-cycle PPG signal set.
其中,偏度指数Skew的计算公式如下:Among them, the calculation formula of the skew index Skew is as follows:
。 .
其中,峰度指数Kur的计算公式如下:Among them, the calculation formula of the kurtosis index Kur is as follows:
。 .
其中,μ和σ分别表示单周期PPG信号的均值和方差,N为单周期PPG信号集合中元素个数,PPG i为序号为i的单周期PPG信号。Wherein, μ and σ represent the mean and variance of a single-cycle PPG signal, respectively, N is the number of elements in the single-cycle PPG signal set, and PPG i is the single-cycle PPG signal with sequence number i .
S402,基于每一个单周期PPG信号的所述偏度指数和所述峰度指数对所述单周期PPG信号集合进行过滤,得到过滤后的所述单周期PPG信号集合。S402, filtering the single-cycle PPG signal set based on the skewness index and the kurtosis index of each single-cycle PPG signal to obtain a filtered single-cycle PPG signal set.
其中,上述过滤条件为当偏度指数和峰度指数同时满足预设阈值组合时,判定当前单周期PPG信号不是噪声信号,否则,将其设定为噪声信号并滤除。Among them, the above filtering condition is that when the skewness index and the kurtosis index simultaneously meet the preset threshold combination, it is determined that the current single-cycle PPG signal is not a noise signal, otherwise, it is set as a noise signal and filtered out.
示例性的,上述预设阈值组合为0.28≥Skew≥-0.13,且2.23≥Kur≥0.15。Exemplarily, the above preset threshold combination is 0.28≥ Skew ≥-0.13, and 2.23≥ Kur ≥0.15.
S403,基于过滤后的所述单周期PPG信号集合对所述预设模板信号集合进行创建或更新。S403: Create or update the preset template signal set based on the filtered single-cycle PPG signal set.
其中,基于过滤后的单周期PPG信号集合对预设模板信号集合中模板信号进行创建的步骤,包括:The step of creating a template signal in a preset template signal set based on the filtered single-cycle PPG signal set includes:
S4031,获取所述预设模板信号集合中的模板数量;S4031, obtaining the number of templates in the preset template signal set;
示例性的,预设模板信号集合中在更新完成后可以包含4个模板信号,分别是3个单周期模板信号和1个潜在模板信号。Exemplarily, after the update is completed, the preset template signal set may include 4 template signals, which are 3 single-cycle template signals and 1 potential template signal.
S4032,在所述模板数量等于0的情况下,将过滤后的所述单周期PPG信号集合中的第一个单周期PPG信号设定为第一模板信号,并将其添加至所述预设模板信号集合中。S4032: When the number of templates is equal to 0, the first single-cycle PPG signal in the filtered single-cycle PPG signal set is set as the first template signal, and is added to the preset template signal set.
具体的,在上述预设模板信号集合中没有模板信号的情况下,将过滤后的单周期PPG信号集合中的第一个元素设置为第一个模板信号,并添加至预设模板信号集合中。Specifically, when there is no template signal in the above preset template signal set, the first element in the filtered single-cycle PPG signal set is set as the first template signal and added to the preset template signal set.
S4033,在所述模板数量小于预设模板数量阈值时,依次计算过滤后的所述单周期PPG信号集合中每个单周期PPG信号与所述预设模板信号集合中各个的模板信号的相似度,在任一所述相似度大于第一相似度阈值的情况下,将其对应的单周期PPG信号设定为第二模板信号,并将其添加至所述预设模板信号集合中。S4033, when the number of templates is less than the preset template number threshold, the similarity between each single-cycle PPG signal in the filtered single-cycle PPG signal set and each template signal in the preset template signal set is calculated in sequence, and when any of the similarities is greater than the first similarity threshold, the corresponding single-cycle PPG signal is set as the second template signal, and it is added to the preset template signal set.
具体的,若此时预设模板信号集合中存在一个或多个模板信号,且模板信号数量小于3,则计算过滤后的单周期PPG信号集合中每个单周期PPG信号与预设模板信号集合中各个的模板信号的相似度,并在相似度均大于第一预设相似度阈值的情况下,将其对应单周期PPG信号设定为一个新的模板信号,添加至预设模板信号集合中。Specifically, if there are one or more template signals in the preset template signal set at this time, and the number of template signals is less than 3, the similarity between each single-cycle PPG signal in the filtered single-cycle PPG signal set and each template signal in the preset template signal set is calculated, and when the similarities are all greater than a first preset similarity threshold, the corresponding single-cycle PPG signal is set as a new template signal and added to the preset template signal set.
示例性的,由于不同周期下PPG信号峰谷点并不完全对齐,且不同周期下PPG信号长度不完全一致,因此本申请实施例中采用动态时间规整算法(Dynamic Time Warping,DTW)对单周期PPG信号与模板信号进行相似度计算。For example, since the peak and valley points of the PPG signal in different periods are not completely aligned, and the lengths of the PPG signals in different periods are not completely consistent, a dynamic time warping algorithm (DTW) is used in an embodiment of the present application to calculate the similarity between the single-period PPG signal and the template signal.
示例性的,为了进一步简化相似度计算的复杂性,本申请实施例在DTW距离计算的过程中采用绝对距离法进行计算两点的距离,其示例参见图11,其中,{Bi}与{Tj}分别为两个PPG序列的样本点(也即是对应上述单周期PPG信号与模板信号的样本点)。那么两点间距D(Bi ,Tj)=|Bi-Tj|,得到两组信号的DTW距离。Exemplarily, in order to further simplify the complexity of similarity calculation, the embodiment of the present application adopts the absolute distance method to calculate the distance between two points during the DTW distance calculation process, and its example is shown in FIG11, wherein {B i } and {T j } are sample points of two PPG sequences (that is, sample points corresponding to the above-mentioned single-cycle PPG signal and template signal). Then the distance between the two points D(B i , T j )=|B i -T j |, and the DTW distance of the two groups of signals is obtained.
示例性的,第一预设相似度阈值可以是根据需求设定的,其大小可以设定为0.3。Exemplarily, the first preset similarity threshold may be set according to demand, and its value may be set to 0.3.
进一步地,基于过滤后的单周期PPG信号集合对预设模板信号集合中模板信号进行创建的步骤,还包括:Furthermore, the step of creating a template signal in a preset template signal set based on the filtered single-cycle PPG signal set further includes:
S4034,在所述模板数量大于等于所述预设模板数量阈值,且全部的所述相似度均大于所述第一相似度阈值的情况下,将其对应的单周期PPG信号设定为潜在模板信号,将所述潜在模板信号添加至所述预设模板信号集合。S4034, when the number of templates is greater than or equal to the preset template number threshold, and all the similarities are greater than the first similarity threshold, setting the corresponding single-cycle PPG signal as a potential template signal, and adding the potential template signal to the preset template signal set.
具体的,在模板数量大于等于3,且相似度大于0.3的情况下,将其对应的单周期PPG信号设定为潜在模板信号,并将其添加至预设模板信号集合中参与相似度计算。Specifically, when the number of templates is greater than or equal to 3 and the similarity is greater than 0.3, the corresponding single-cycle PPG signal is set as a potential template signal and added to the preset template signal set to participate in the similarity calculation.
示例性的,过滤后的所述单周期PPG信号集合中每一个单周期PPG信号与所述预设模板信号集合中每一个模板信号进行匹配,所述潜在模板信号的匹配次数大于任一所述预设模板信号集合中其它的模板信号的情况下,将其对应的模板信号替换为潜在模板信号,并清除所述预设模板信号集合中的潜在模板信号。Exemplarily, each single-cycle PPG signal in the filtered single-cycle PPG signal set is matched with each template signal in the preset template signal set. When the number of matches of the potential template signal is greater than that of any other template signal in the preset template signal set, its corresponding template signal is replaced by the potential template signal, and the potential template signals in the preset template signal set are cleared.
本申请实施例中,在完成预设模板信号集合的构建后,还包括将单周期PPG信号集合中的元素与预设模板信号集合中元素进行更新以及匹配的步骤,包括:In the embodiment of the present application, after the preset template signal set is constructed, the step of updating and matching the elements in the single-cycle PPG signal set with the elements in the preset template signal set is also included, including:
S404,依次计算过滤后的所述单周期PPG信号集合中每一个单周期PPG信号与所述预设模板信号集合中的每一个模板信号的相似度。S404, sequentially calculating the similarity between each single-cycle PPG signal in the filtered single-cycle PPG signal set and each template signal in the preset template signal set.
S405,在所述相似度小于所述第一相似度阈值的情况下,将当前的所述模板信号匹配成功次数加1。S405: When the similarity is less than the first similarity threshold, the number of successful matches of the current template signal is increased by 1.
S406,在所述相似度小于第二相似度阈值的情况下,使用其对应的单周期PPG信号对当前的所述模板信号进行更新,直至过滤后的所述单周期PPG信号集合中的单周期PPG信号全部完成匹配。S406, when the similarity is less than the second similarity threshold, use the corresponding single-cycle PPG signal to update the current template signal until all the single-cycle PPG signals in the filtered single-cycle PPG signal set are matched.
具体的,上述使用单周期PPG信号对模板信号进行更新的步骤,可以是采用均值法对单周期PPG信号与模板信号进行计算。示例性的,参见图11中(3)的数据对应规则,将单周期PPG信号与模板信号进行逐点平均,将计算得到的信号设定为新的模板信号,并替换上述模板信号。Specifically, the step of updating the template signal using the single-cycle PPG signal may be to calculate the single-cycle PPG signal and the template signal using the mean method. For example, referring to the data correspondence rule (3) in FIG. 11 , the single-cycle PPG signal and the template signal are averaged point by point, the calculated signal is set as the new template signal, and the template signal is replaced.
示例性的,上述第一相似度阈值大于上述第二相似度阈值。Exemplarily, the first similarity threshold is greater than the second similarity threshold.
示例性的,上述第二相似度阈值可以是根据需求设定的,其值的大小可以设定为0.1。Exemplarily, the second similarity threshold may be set according to requirements, and its value may be set to 0.1.
进一步地,在上述基于单周期PPG信号对模板信号更新的步骤之后,还包括:Furthermore, after the above step of updating the template signal based on the single-cycle PPG signal, the method further includes:
S407,计算更新后的所述模板信号与预设模板信号集合中其它的模板信号的相似度,在任一所述相似度小于所述第二相似度阈值的情况下,将其对应的两个所述模板信号进行合并,将两个所述模板信号的匹配成功次数合并,删除更新后的所述模板信号。S407, calculating the similarity between the updated template signal and other template signals in the preset template signal set, and when any of the similarities is less than the second similarity threshold, merging the two corresponding template signals, merging the number of successful matches of the two template signals, and deleting the updated template signal.
具体地,将更新后的模板信号与预设模板信号集合中的其它的模板信号进行相似度比较。在任一相似度都小于第二相似度阈值时,说明此时更新后的模板信号和该相似度对应的其它的模板信号,两个模板信号可认定为相同的模板信号,使用均值法对两者进行合并,并将两者的匹配成功次数也进行合并,删除更新后的模板信号。Specifically, the updated template signal is compared with other template signals in the preset template signal set for similarity. When any similarity is less than the second similarity threshold, it means that the updated template signal and the other template signals corresponding to the similarity can be identified as the same template signal, and the two are merged using the mean method, and the number of successful matches of the two are also merged, and the updated template signal is deleted.
进一步地,在完成两个集合中全部元素的匹配后,将匹配次数最大的模板信号设置为本次检测的单周期PPG主信号S4。Furthermore, after completing the matching of all elements in the two sets, the template signal with the largest number of matches is set as the single-cycle PPG main signal S4 for this detection.
本申请实施例采用模板法联合DTW法提取单周期PPG主信号,相较于传统的Pearson相关系数法,减少了PPG主信号提取的复杂性,提升在不等长信号的相似性判断中的适应性。The embodiment of the present application adopts the template method combined with the DTW method to extract the single-cycle PPG main signal. Compared with the traditional Pearson correlation coefficient method, it reduces the complexity of PPG main signal extraction and improves the adaptability in the similarity judgment of unequal length signals.
S105,基于双高斯函数模型对所述单周期PPG主信号进行分解,得到参数集合。S105, decomposing the single-cycle PPG main signal based on a double Gaussian function model to obtain a parameter set.
具体的,在得到PPG主信号S4后,本申请实施例使用双高斯函数模型对PPG主信号S4进行分解,得到参数集合,其双高斯函数模型定义如下:Specifically, after obtaining the PPG main signal S4, the embodiment of the present application uses a double Gaussian function model to decompose the PPG main signal S4 to obtain a parameter set, and the double Gaussian function model is defined as follows:
。 .
其中,A1,A2分别为单个高斯函数曲线的高度,µ1和µ2分别为单个高斯函数曲线的波峰位置,σ1和σ2分别为单个高斯函数曲线的宽度。Among them, A1 and A2 are the heights of a single Gaussian function curve, µ1 and µ2 are the peak positions of a single Gaussian function curve, and σ1 and σ2 are the widths of a single Gaussian function curve.
为了进一步减少后续环节的寻参计算量,还可以为单周期PPG信号设定初始参数值,其具体流程为:In order to further reduce the amount of parameter search calculations in subsequent links, the initial parameter values can also be set for the single-cycle PPG signal. The specific process is as follows:
S501,识别PPG主信号S4的最大值S4Max和第一位置S4MaxLoc,获取所述第一位置右侧幅度为S4Max/5的第二位置S4MaxEndLoc;S501, identifying the maximum value S4Max and the first position S4MaxLoc of the PPG main signal S4, and obtaining a second position S4MaxEndLoc with an amplitude of S4Max/5 to the right of the first position;
S502,对所述单周期PPG主信号进行差分得到差分信号,获取所述差分信号的过零点位置S5ZeroLoc;S502, performing differentiation on the single-cycle PPG main signal to obtain a differential signal, and obtaining a zero-crossing position S5ZeroLoc of the differential signal;
S503,基于所述最大值S4Max、所述第一位置S4MaxLoc、所述第二位置S4MaxEndLoc和所述过零点位置S5ZeroLoc,计算所述单周期PPG主信号在所述双高斯函数模型中的初始参数;S503, calculating initial parameters of the single-cycle PPG main signal in the double Gaussian function model based on the maximum value S4Max, the first position S4MaxLoc, the second position S4MaxEndLoc and the zero-crossing position S5ZeroLoc;
具体的,设置[A1,µ1,σ1]的起始值为[S4Max/2,S4MaxLoc/3,S4MaxLoc-2*S5ZeroLoc]。设置[A2,µ1,σ2]的起始值为[0,S4MaxLoc/2,2*(S4MaxLoc-2*S5ZeroLoc)]。Specifically, set the starting value of [A1, µ1, σ1] to [S4Max/2, S4MaxLoc/3, S4MaxLoc-2*S5ZeroLoc]. Set the starting value of [A2, µ1, σ2] to [0, S4MaxLoc/2, 2*(S4MaxLoc-2*S5ZeroLoc)].
在基于初始参数和双高斯函数模型对PPG主信号S4进行分解,得到参数集合。The PPG main signal S4 is decomposed based on the initial parameters and the double Gaussian function model to obtain a parameter set.
S106,基于线性最小二乘回归迭代算法对所述参数集合进行拟合,得到第一高斯波和第二高斯波,所述第一高斯波为所述PPG信号的主波,所述第二高斯波为所述PPG信号的重搏波。S106, fitting the parameter set based on a linear least squares regression iterative algorithm to obtain a first Gaussian wave and a second Gaussian wave, wherein the first Gaussian wave is the main wave of the PPG signal, and the second Gaussian wave is the dicrotic wave of the PPG signal.
具体的,基于LM(Levenberg-Marquardt)算法在上述参数集合中寻找最佳参数集合。其中,LM算法是一种非线性最小二乘拟合算法,它通过最小化残差平方和来拟合数据。拟合完毕后得到第一高斯波S6和第二高斯波S7,在一定偏差范围内S4=S6+S7。Specifically, the best parameter set is found in the above parameter set based on the LM (Levenberg-Marquardt) algorithm. The LM algorithm is a nonlinear least squares fitting algorithm that fits the data by minimizing the residual square sum. After fitting, the first Gaussian wave S6 and the second Gaussian wave S7 are obtained, and within a certain deviation range, S4=S6+S7.
示例性的,拟合后的第一高斯波S6和第二高斯波S7,其示例参见图12中(1)和(2)。从图12中可以看出,即使在PPG信号中无明显重搏波的情况下,本申请实施例仍然可以将其进行分解得到准确的主波(第一高斯波S6)和重搏波(第二高斯波S7)。For example, the fitted first Gaussian wave S6 and second Gaussian wave S7 are shown in (1) and (2) in Figure 12. As can be seen from Figure 12, even when there is no obvious dicrotic wave in the PPG signal, the embodiment of the present application can still decompose it to obtain an accurate main wave (first Gaussian wave S6) and dicrotic wave (second Gaussian wave S7).
在一种可能的实现方式中,在得到了第一高斯波S6和第二高斯波S7之后,本申请实施例还提供了一种特征提取方法以及PWV回归模型训练方法,包括:In a possible implementation, after obtaining the first Gaussian wave S6 and the second Gaussian wave S7, the embodiment of the present application further provides a feature extraction method and a PWV regression model training method, including:
步骤S107,对所述单周期PPG主信号、所述第一高斯波和所述第二高斯波进行特征计算,将得到的特征集合对预设PWV回归模型进行训练。Step S107, performing feature calculation on the single-cycle PPG main signal, the first Gaussian wave, and the second Gaussian wave, and using the obtained feature set to train a preset PWV regression model.
具体的,根据PPG主信号S4、第一高斯波S6和第二高斯波S7进行特征计算,得到特征集合,其包括但不限于S4总时长T、第一高斯波上升时间T1、双波间隔∆T、反射指数RI、增强指数AI、心率间隔RR、K值(mean(PPG)/max(PPG))。Specifically, feature calculation is performed based on the PPG main signal S4, the first Gaussian wave S6 and the second Gaussian wave S7 to obtain a feature set, which includes but is not limited to the total duration T of S4, the rise time T1 of the first Gaussian wave, the double-wave interval ∆T, the reflection index RI, the enhancement index AI, the heart rate interval RR, and the K value (mean(PPG)/max(PPG)).
同时,在根据获取到用户的基础特征身高Height、年龄Age和体重Weight,计算引申组合特征第一高斯波上线时间占比T1/T、硬化指数SI=Height/∆T、归一化硬化指数SI/RR、BMI指数Weight/Height2等。At the same time, based on the user's basic features of height, age and weight, the derived combined features such as the first Gaussian wave online time proportion T1/T, hardening index SI=Height/∆T, normalized hardening index SI/RR, BMI index Weight/Height 2 , etc. are calculated.
将计算得到的特征构成特征结合,然后进行特征筛选,将筛选得到的特征集合,利用机器学习算法或多元线性回归算法进行训练得到PWV回归模型。使用训练好的PWV回归模型对用户的PWV值进行预测。The calculated feature components are combined, and then feature screening is performed, and the screened feature set is trained using a machine learning algorithm or a multivariate linear regression algorithm to obtain a PWV regression model. The trained PWV regression model is used to predict the user's PWV value.
示例性的,上述特征筛选可以是采用方案为基于Pearson相关系数法,筛选出出参考PWV与计算特征的相关系数大于0.1的特征集合。Exemplarily, the feature screening may be based on the Pearson correlation coefficient method to screen out a feature set whose correlation coefficient between the reference PWV and the calculated feature is greater than 0.1.
示例性的,上述机器学习算法可以包括SVM、逻辑回归、或主流的决策树模型。例如随机森林算法、迭代算法(AdaBoost)、优化的分布式梯度增强库(XGBoost)、梯度提升机器学习算法(CatBoost)、梯度提升决策树模型(LightGBM)等。Exemplarily, the above machine learning algorithms may include SVM, logistic regression, or mainstream decision tree models, such as random forest algorithm, iterative algorithm (AdaBoost), optimized distributed gradient boosting library (XGBoost), gradient boosting machine learning algorithm (CatBoost), gradient boosting decision tree model (LightGBM), etc.
由此,通过不断的迭代训练,最终得到PWV回归模型。基于本申请实施例中的PWV回归模型可以降低因个体差异或佩戴位置,导致的脉搏波特征无法计算的问题,大大提升了PWV指标的精确度。相较于传统的逐波PPG分解,本申请实施例利用单周期PPG主信号通过设置有初始值的LM算法得到PPG分解波形,进一步简化了运算的复杂性,同时分解得到的波形也更加接近真实的生理波形。Thus, through continuous iterative training, the PWV regression model is finally obtained. Based on the PWV regression model in the embodiment of the present application, the problem of pulse wave characteristics being unable to be calculated due to individual differences or wearing positions can be reduced, greatly improving the accuracy of the PWV index. Compared with the traditional wave-by-wave PPG decomposition, the embodiment of the present application uses a single-cycle PPG main signal to obtain a PPG decomposition waveform through an LM algorithm with an initial value, further simplifying the complexity of the operation, and the decomposed waveform is also closer to the real physiological waveform.
此外,为了更好地理解本申请实施例提供的技术方案,以可穿戴设备为智能手表为例,基于智能手表的软件结构和硬件的关系,对实现本申请实施例提供的PPG信号处理方法所涉及的功能模块、硬件,以及功能模块、硬件之间的交互进行说明。In addition, in order to better understand the technical solution provided by the embodiments of the present application, taking a wearable device as a smart watch as an example, based on the relationship between the software structure and hardware of the smart watch, the functional modules, hardware, and the interaction between the functional modules and hardware involved in implementing the PPG signal processing method provided by the embodiments of the present application are explained.
在对可穿戴设备的软件结构进行说明之前,首先对可穿戴设备的软件系统可以采用的架构进行说明。Before describing the software structure of the wearable device, the architecture that can be adopted by the software system of the wearable device is described first.
具体地,在实际应用中,可穿戴设备的软件系统可以采用分层架构,事件驱动架构,微核架构,微服务架构,或云架构。Specifically, in practical applications, the software system of wearable devices can adopt a layered architecture, an event-driven architecture, a microkernel architecture, a microservice architecture, or a cloud architecture.
此外,可理解地,目前主流的可穿戴设备使用的软件系统包括但不限于Windows系统、Android系统和iOS系统。为了便于说明,本申请实施例以分层架构的Android系统为例,示例性说明可穿戴设备的软件结构。In addition, it is understandable that the software systems used by the current mainstream wearable devices include but are not limited to Windows systems, Android systems and iOS systems. For ease of explanation, the embodiment of the present application takes the Android system of layered architecture as an example to exemplify the software structure of the wearable device.
此外,应当理解地是,后续关于本申请实施例提供的PPG信号处理方法,在具体实现中同样适用于其它系统。In addition, it should be understood that the subsequent PPG signal processing method provided in the embodiments of the present application is also applicable to other systems in specific implementations.
参见图13,为本申请实施例的可穿戴设备的软件结构和硬件结构的框图。See Figure 13, which is a block diagram of the software structure and hardware structure of the wearable device according to an embodiment of the present application.
如图13所示,可穿戴设备的分层架构将软件分成若干个层,每一层都有清晰的角色和分工。层与层之间通过软件接口通信。在一些实现方式中,将Android系统可分为五层,从上至下分别为属于应用部分的应用层/应用程序层(Applications),属于核心部分的框架层/应用程序框架层(Application Framework,FWK)、运行时(Runtime)和系统库,属于底层部分的硬件抽象层(Hardware Abstract Layer,HAL)、Linux内核(Linux Kernel)层。As shown in Figure 13, the layered architecture of wearable devices divides the software into several layers, each with clear roles and division of labor. The layers communicate with each other through software interfaces. In some implementations, the Android system can be divided into five layers, from top to bottom, namely the application layer/application layer (Applications) belonging to the application part, the framework layer/application framework layer (Application Framework, FWK) belonging to the core part, the runtime (Runtime) and the system library, and the hardware abstraction layer (HAL) and Linux kernel (Linux Kernel) layer belonging to the bottom layer.
其中,应用层可以包括一系列应用程序包。如图13所示,应用程序包可以包括相机、游戏、血管健康、设置等应用程序,此处不再一一列举,本申请对此不作限制。The application layer may include a series of application packages. As shown in FIG13 , the application package may include applications such as camera, game, vascular health, and settings, which are not listed here one by one and are not limited in this application.
其中,血管健康应用可以是专门提供的,用于开启血管健康检测功能的应用。Among them, the vascular health application can be an application specially provided for enabling the vascular health detection function.
可理解地,在实际应用中,血管健康应用实现的功能也可以集成到管理各种运动信息的运动健康应用中,或者也可以集成在设置应用中,本申请对此不作限制。It is understandable that, in actual applications, the functions implemented by the vascular health application can also be integrated into a sports health application that manages various sports information, or can also be integrated into a setting application, and this application does not impose any restrictions on this.
其中,框架层可以为应用层的应用程序提供应用编程接口(applicationprogramming interface,API)和编程框架。在一些实现方式中,这些编程接口和编程框架可以描述为函数。如图13所示,框架层可以包括内容提供器、窗口管理器、视图系统、资源管理器等函数,此处不再一一列举,本申请对此不作限制。Among them, the framework layer can provide application programming interfaces (APIs) and programming frameworks for the application programs of the application layer. In some implementations, these programming interfaces and programming frameworks can be described as functions. As shown in FIG13 , the framework layer may include functions such as content providers, window managers, view systems, and resource managers, which are not listed here one by one and are not limited in this application.
需要说明的,上述位于框架层中的窗口管理器用于管理窗口程序。窗口管理器可以获取显示屏大小,判断是否有状态栏,锁定屏幕,截取屏幕等。It should be noted that the window manager located in the framework layer is used to manage window programs. The window manager can obtain the size of the display screen, determine whether there is a status bar, lock the screen, capture the screen, etc.
此外,还需要说明的,上述位于框架层中的视图系统包括可视控件,例如显示文字的控件,显示图片的控件等。视图系统可用于构建应用程序。显示界面可以由一个或多个视图组成的。例如,图4中(1)和(2)中示出的包括血管健康检测图片/图标的显示界面,可以包括显示文字的视图以及显示图片的视图。In addition, it should be noted that the view system located in the framework layer includes visual controls, such as controls for displaying text, controls for displaying pictures, etc. The view system can be used to build applications. The display interface can be composed of one or more views. For example, the display interface including vascular health detection pictures/icons shown in (1) and (2) in Figure 4 can include a view for displaying text and a view for displaying pictures.
继续参见图13,示例性的,运行时,具体为安卓运行时(Android Runtime)可包括核心库和虚拟机,主要负责安卓系统的调度和管理。Continuing to refer to FIG. 13 , illustratively, the runtime, specifically the Android runtime (Android Runtime), may include a core library and a virtual machine, which are mainly responsible for scheduling and management of the Android system.
其中,核心库包含两部分:一部分是java语言需要调用的功能函数,另一部分是安卓的核心库。应用层和框架层运行在虚拟机中。虚拟机将应用层和框架层的java文件执行为二进制文件。虚拟机用于执行对象生命周期的管理,堆栈管理,线程管理,安全和异常的管理,以及垃圾回收等功能。The core library consists of two parts: one is the function that the Java language needs to call, and the other is the Android core library. The application layer and the framework layer run in the virtual machine. The virtual machine executes the Java files of the application layer and the framework layer as binary files. The virtual machine is used to perform object life cycle management, stack management, thread management, security and exception management, and garbage collection.
继续参见图13,示例性的,系统库可以包括多个功能模块。例如:表面管理器(surface manager),媒体库(Media Libraries),三维(3D)图形处理库(例如:OpenGL ES),二维(2D)图形引擎(例如:SGL)等。Continuing to refer to FIG. 13 , illustratively, the system library may include multiple functional modules, such as a surface manager, a media library, a three-dimensional (3D) graphics processing library (eg, OpenGL ES), a two-dimensional (2D) graphics engine (eg, SGL), and the like.
继续参见图13,示例性的,HAL层是位于操作系统内核(内核层)与硬件电路之间的接口层,其目的在于将FWK与内核隔离,以使Android不至于过度依赖内核,从而使得FWK的开发可在不考虑驱动程序的前提下进行。Continuing to refer to FIG. 13 , illustratively, the HAL layer is an interface layer located between the operating system kernel (kernel layer) and the hardware circuit, and its purpose is to isolate the FWK from the kernel so that Android does not rely too much on the kernel, thereby allowing the development of the FWK to be carried out without considering the driver.
继续参见图13,示例性的,HAL层中可以包括各种接口,如音视频接口、GPS接口、通话接口、WiFi接口等,此处不再一一列举,本申请对此不作限制。Continuing to refer to FIG. 13 , illustratively, the HAL layer may include various interfaces, such as an audio and video interface, a GPS interface, a call interface, a WiFi interface, etc., which are not listed one by one here and are not limited in this application.
继续参见图13,示例性的,Android系统中的内核层是硬件和软件之间的层。内核层可包括各种进程/线程,电源管理、各种驱动,如WiFi驱动等。Continuing to refer to Figure 13, illustratively, the kernel layer in the Android system is a layer between hardware and software. The kernel layer may include various processes/threads, power management, various drivers, such as WiFi drivers, etc.
关于可穿戴设备的软件结构就介绍到此,可以理解地是,图13示出的软件结构中的层以及各层中包含的部件,并不构成对可穿戴设备的具体限定。在本申请另一些实施例中,可穿戴设备可以包括比图示更多或更少的层,以及每个层中可以包括更多或更少的部件,本申请不作限定。This is the end of the introduction to the software structure of the wearable device. It is understandable that the layers in the software structure shown in FIG. 13 and the components contained in each layer do not constitute a specific limitation on the wearable device. In other embodiments of the present application, the wearable device may include more or fewer layers than shown in the figure, and each layer may include more or fewer components, which is not limited in the present application.
基于图13示出的可穿戴设备的软件结构,当用户通过应用层中安装的血管健康应用/设置应用,触发血管健康检测操作时,可穿戴设备响应于该操作欣慰,硬件部分的PPG传感器和ACC传感器将同步采集PPG信号和ACC信号,进而交给处理器,由处理器根据内部存储器中存储的程序指令,如对采集到的传感器信号进行预处理和特征提取的程序指令,根据预定的算法程序,对传感器信号进行预处理和特征提取,进而将提取到的传感器信号的特征信息,输入内存存储器中存储的PWV回归模型(程序)进行PWV预测,便可以得到精确的PWV值。最终,基于PWV值实现对用户血管健康的检测。Based on the software structure of the wearable device shown in FIG13 , when the user triggers the vascular health detection operation through the vascular health application/setting application installed in the application layer, the wearable device responds to the operation, and the PPG sensor and ACC sensor of the hardware part will synchronously collect PPG signals and ACC signals, and then hand them over to the processor, which will perform preprocessing and feature extraction on the sensor signals according to the program instructions stored in the internal memory, such as program instructions for preprocessing and feature extraction of the collected sensor signals, and then input the feature information of the extracted sensor signals into the PWV regression model (program) stored in the memory storage for PWV prediction, so that an accurate PWV value can be obtained. Finally, the user's vascular health is detected based on the PWV value.
关于本申请实施例提供的PPG信号处理方法的具体逻辑,可以参见图6,此处不再赘述。For the specific logic of the PPG signal processing method provided in the embodiment of the present application, please refer to Figure 6, which will not be repeated here.
为了更好地理解本申请实施例提供的技术方案,仍以可穿戴设备为智能手表为例,参见图14,对智能手表的具体结构,以及实现本申请实施例所涉及的器件进行具体说明。In order to better understand the technical solution provided by the embodiments of the present application, taking the wearable device as a smart watch as an example, refer to Figure 14 to specifically describe the specific structure of the smart watch and the devices involved in implementing the embodiments of the present application.
参见图14,可穿戴设备100可以包括:处理器110,外部存储器接口120,内部存储器121,通用串行总线(universal serial bus,USB)接口130,充电管理模块140,电源管理模块141,电池142,天线1,天线2,移动通信模块150,无线通信模块160,音频模块170,扬声器170A,受话器170B,麦克风170C,耳机接口170D,传感器模块180,按键190,马达191,指示器192,摄像头193,显示屏194,以及用户标识模块(subscriber identification module,SIM)卡接口195等。14 , the wearable device 100 may include a processor 110, an external memory interface 120, an internal memory 121, a universal serial bus (USB) interface 130, a charging management module 140, a power management module 141, a battery 142, an antenna 1, an antenna 2, a mobile communication module 150, a wireless communication module 160, an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, an earphone interface 170D, a sensor module 180, a button 190, a motor 191, an indicator 192, a camera 193, a display screen 194, and a subscriber identification module (SIM) card interface 195, etc.
具体到本申请实施例提供的技术方案中,为了实现PPG信号处理,传感器模块180需包括PPG传感器180A和ACC传感器180B。其中,PPG传感器可用于采集PPG信号,ACC传感器可用于采集ACC信号。Specifically, in the technical solution provided in the embodiment of the present application, in order to realize PPG signal processing, the sensor module 180 needs to include a PPG sensor 180A and an ACC sensor 180B. Among them, the PPG sensor can be used to collect PPG signals, and the ACC sensor can be used to collect ACC signals.
继续参见图14,示例性的,由于PPG传感器180A和ACC传感器180B均与处理器110通信连接。因此,PPG传感器180A和ACC传感器180B采集到的PPG信号和ACC信号将交由处理器110按照图6所示实施例中示出的处理流程进行处理,进而得到单周期PPG信号的特征集合,实现血管健康的精准测量。Continuing to refer to FIG14 , illustratively, since both the PPG sensor 180A and the ACC sensor 180B are in communication connection with the processor 110, the PPG signal and the ACC signal collected by the PPG sensor 180A and the ACC sensor 180B will be processed by the processor 110 according to the processing flow shown in the embodiment shown in FIG6 , thereby obtaining a feature set of a single-cycle PPG signal, and realizing accurate measurement of vascular health.
此外,需要说明的是,在实际应用中,根据业务需要和可穿戴设备适用于的场景,传感器180还可以包括压力传感器,陀螺仪传感器,气压传感器,磁传感器,距离传感器,接近光传感器,指纹传感器,温度传感器,触摸传感器,环境光传感器,骨传导传感器等,此处不再一一列举,本申请对此不作限制。In addition, it should be noted that in actual applications, according to business needs and the scenarios in which the wearable device is applicable, the sensor 180 may also include a pressure sensor, a gyroscope sensor, an air pressure sensor, a magnetic sensor, a distance sensor, a proximity light sensor, a fingerprint sensor, a temperature sensor, a touch sensor, an ambient light sensor, a bone conduction sensor, etc., which are not listed one by one here and the present application does not impose any restrictions on this.
此外,还需要说明的是,处理器110可以包括一个或多个接口。接口可以包括集成电路(inter-integrated circuit,I2C)接口,集成电路内置音频(inter-integratedcircuit sound,I2S)接口,脉冲编码调制(pulse code modulation,PCM)接口,通用异步收发传输器(universal asynchronous receiver/transmitter,UART)接口,移动产业处理器接口(mobile industry processor interface,MIPI),通用输入输出(general-purposeinput/output,GPIO)接口,用户标识模块(subscriber identity module,SIM)接口,和/或通用串行总线(universal serial bus,USB)接口等。In addition, it should be noted that the processor 110 may include one or more interfaces. The interface may include an inter-integrated circuit (I2C) interface, an inter-integrated circuit sound (I2S) interface, a pulse code modulation (PCM) interface, a universal asynchronous receiver/transmitter (UART) interface, a mobile industry processor interface (MIPI), a general-purpose input/output (GPIO) interface, a subscriber identity module (SIM) interface, and/or a universal serial bus (USB) interface, etc.
继续参见图14,示例性的,充电管理模块140用于从充电器接收充电输入。其中,充电器可以是无线充电器,也可以是有线充电器。Continuing to refer to Fig. 14, illustratively, the charging management module 140 is used to receive charging input from a charger, wherein the charger may be a wireless charger or a wired charger.
继续参见图14,示例性的,可穿戴设备100的无线通信功能可以通过天线1,天线2,移动通信模块150,无线通信模块160,调制解调处理器以及基带处理器等实现。Continuing to refer to FIG. 14 , illustratively, the wireless communication function of the wearable device 100 can be implemented through antenna 1, antenna 2, mobile communication module 150, wireless communication module 160, a modem processor, and a baseband processor.
具体到本申请实施例提供的技术方案中,可穿戴设备中对PPG信号处理后得到的特征信息可以发送到云端服务器,由PC等处理能力强大的电子设备根据特征信息对PWV回归模型进行训练,并将训练好的PWV回归模型下发至可穿戴设备100。这样,可穿戴设备100就可以通过移动模块150或无线通信模块160与云端服务器进行通信,进而获得PWV回归模型。Specifically, in the technical solution provided in the embodiment of the present application, the characteristic information obtained after the wearable device processes the PPG signal can be sent to the cloud server, and the PWV regression model is trained by an electronic device with powerful processing capabilities such as a PC according to the characteristic information, and the trained PWV regression model is sent to the wearable device 100. In this way, the wearable device 100 can communicate with the cloud server through the mobile module 150 or the wireless communication module 160, and then obtain the PWV regression model.
示例性的,在另一些可能的实现方式中,由PC等电子设备构建好的PWV回归模型,也可以通过USB接口130,传输至可穿戴设备100。Exemplarily, in some other possible implementations, the PWV regression model constructed by an electronic device such as a PC may also be transmitted to the wearable device 100 via the USB interface 130 .
应当理解地是,上述说明仅是为了更好地理解本实施例的技术方案而列举的示例,不作为对本实施例的唯一限制。It should be understood that the above description is merely an example listed for a better understanding of the technical solution of this embodiment, and is not intended to be the sole limitation to this embodiment.
继续参见图14,示例性的,显示屏194用于显示图像,视频等。在一些实现方式中,可穿戴设备100可以包括1个或N个显示屏194,N为大于1的正整数。14 , illustratively, the display screen 194 is used to display images, videos, etc. In some implementations, the wearable device 100 may include 1 or N display screens 194 , where N is a positive integer greater than 1.
继续参见图14,示例性的,摄像头193用于捕获静态图像或视频。Continuing to refer to FIG. 14 , illustratively, the camera 193 is used to capture still images or videos.
继续参见图14,示例性的,外部存储器接口120可以用于连接外部存储卡,例如Micro SD卡,实现扩展可穿戴设备100的存储能力。外部存储卡通过外部存储器接口120与处理器110通信,实现数据存储功能。例如将音乐,视频等文件保存在外部存储卡中。Continuing to refer to FIG. 14 , illustratively, the external memory interface 120 can be used to connect an external memory card, such as a Micro SD card, to expand the storage capacity of the wearable device 100. The external memory card communicates with the processor 110 through the external memory interface 120 to implement a data storage function. For example, files such as music and videos are stored in the external memory card.
继续参见图14,示例性的,内部存储器121可以用于存储计算机可执行程序代码,所述可执行程序代码包括指令。这样,处理器110通过运行存储在内部存储器121的指令,从而执行可穿戴设备100的各种功能应用以及数据处理。内部存储器121可以包括存储程序区和存储数据区。其中,存储程序区可存储操作系统,至少一个功能所需的应用程序(比如声音播放功能,图像播放功能等)等。存储数据区可存储可穿戴设备100使用过程中所创建的数据(比如音频数据,电话本等)等。此外,内部存储器121可以包括高速随机存取存储器,还可以包括非易失性存储器,例如至少一个磁盘存储器件,闪存器件,通用闪存存储器(universal flash storage,UFS)等。Continuing to refer to FIG. 14, illustratively, the internal memory 121 can be used to store computer executable program codes, which include instructions. In this way, the processor 110 executes various functional applications and data processing of the wearable device 100 by running the instructions stored in the internal memory 121. The internal memory 121 may include a program storage area and a data storage area. Among them, the program storage area may store an operating system, an application required for at least one function (such as a sound playback function, an image playback function, etc.), etc. The data storage area may store data created during the use of the wearable device 100 (such as audio data, a phone book, etc.), etc. In addition, the internal memory 121 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one disk storage device, a flash memory device, a universal flash storage (UFS), etc.
具体到本申请实施例提供的技术方案中,PWV回归模型可以预先下载到内部存储器121中。Specifically in the technical solution provided in the embodiment of the present application, the PWV regression model can be pre-downloaded into the internal memory 121.
关于可穿戴设备100的硬件结构就介绍到此,应当理解地是,图14所示可穿戴设备100仅是一个范例,在具体实现中,可穿戴设备100可以具有比图中所示的更多的或者更少的部件,可以组合两个或多个的部件,或者可以具有不同的部件配置。图14中所示出的各种部件可以在包括一个或多个信号处理和/或专用集成电路在内的硬件、软件、或硬件和软件的组合中实现。The hardware structure of the wearable device 100 is introduced here. It should be understood that the wearable device 100 shown in Figure 14 is only an example. In a specific implementation, the wearable device 100 may have more or fewer components than those shown in the figure, may combine two or more components, or may have different component configurations. The various components shown in Figure 14 can be implemented in hardware, software, or a combination of hardware and software including one or more signal processing and/or application-specific integrated circuits.
此外,可以理解地是,电子设备为了实现上述功能,其包含了执行各个功能相应的硬件和/或软件模块。结合本文中所公开的实施例描述的各示例的算法步骤,本申请能够以硬件或硬件和计算机软件的结合形式来实现。某个功能究竟以硬件还是计算机软件驱动硬件的方式来执行,取决于技术方案的特定应用和设计约束条件。本领域技术人员可以结合实施例对每个特定的应用来使用不同方法来实现所描述的功能,但是这种实现不应认为超出本申请的范围。In addition, it is understandable that, in order to implement the above functions, the electronic device includes hardware and/or software modules corresponding to the execution of each function. In combination with the algorithm steps of each example described in the embodiments disclosed herein, the present application can be implemented in the form of hardware or a combination of hardware and computer software. Whether a function is executed in the form of hardware or computer software driving hardware depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application in combination with the embodiments, but such implementation should not be considered to be beyond the scope of the present application.
此外,需要说明的是,在实际的应用场景中由电子设备实现的上述各实施例提供的PPG信号处理方法,也可以由电子设备中包括的一种芯片系统来执行,其中,该芯片系统可以包括处理器。该芯片系统可以与存储器耦合,使得该芯片系统运行时调用该存储器中存储的计算机程序,实现上述电子设备执行的步骤。其中,该芯片系统中的处理器可以是应用处理器也可以是非应用处理器的处理器。In addition, it should be noted that the PPG signal processing method provided by the above embodiments implemented by the electronic device in the actual application scenario can also be performed by a chip system included in the electronic device, wherein the chip system may include a processor. The chip system can be coupled to the memory so that the chip system calls the computer program stored in the memory when it is running to implement the steps performed by the above electronic device. The processor in the chip system can be an application processor or a processor other than an application processor.
另外,本申请实施例还提供一种计算机可读存储介质,该计算机存储介质中存储有计算机指令,当该计算机指令在电子设备上运行时,使得电子设备执行上述相关方法步骤实现上述实施例中的PPG信号处理方法。In addition, an embodiment of the present application also provides a computer-readable storage medium, which stores computer instructions. When the computer instructions are executed on an electronic device, the electronic device executes the above-mentioned related method steps to implement the PPG signal processing method in the above-mentioned embodiment.
另外,本申请实施例还提供了一种计算机程序产品,当该计算机程序产品在电子设备上运行时,使得电子设备执行上述相关步骤,以实现上述实施例中的PPG信号处理方法。In addition, an embodiment of the present application further provides a computer program product. When the computer program product is run on an electronic device, the electronic device executes the above-mentioned related steps to implement the PPG signal processing method in the above-mentioned embodiment.
另外,本申请的实施例还提供一种芯片(也可以是组件或模块),该芯片可包括一个或多个处理电路和一个或多个收发管脚;其中,所述收发管脚和所述处理电路通过内部连接通路互相通信,所述处理电路执行上述相关方法步骤实现上述实施例中的PPG信号处理方法,以控制接收管脚接收信号,以控制发送管脚发送信号。In addition, an embodiment of the present application also provides a chip (which may also be a component or module), which may include one or more processing circuits and one or more transceiver pins; wherein the transceiver pins and the processing circuit communicate with each other through an internal connection path, and the processing circuit executes the above-mentioned related method steps to implement the PPG signal processing method in the above-mentioned embodiment, so as to control the receiving pin to receive the signal, so as to control the transmitting pin to send the signal.
此外,通过上述描述可知,本申请实施例提供的电子设备、计算机可读存储介质、计算机程序产品或芯片均用于执行上文所提供的对应的方法,因此,其所能达到的有益效果可参考上文所提供的对应的方法中的有益效果,此处不再赘述。In addition, it can be seen from the above description that the electronic device, computer-readable storage medium, computer program product or chip provided in the embodiments of the present application are all used to execute the corresponding methods provided above. Therefore, the beneficial effects that can be achieved can refer to the beneficial effects in the corresponding methods provided above, and will not be repeated here.
以上所述,以上实施例仅用以说明本申请的技术方案,而非对其限制;尽管参照前述实施例对本申请进行了详细地说明,本领域的普通技术人员应当理解:其依然可以对前述各实施例所记载的技术方案进行修改,或者对其中部分技术特征进行等同替换;而这些修改或者替换,并不使相应技术方案的本质脱离本申请各实施例技术方案的范围。As described above, the above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of the present application.
Claims (14)
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202410516782.8A CN118078234B (en) | 2024-04-28 | 2024-04-28 | PPG signal processing method, device and storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202410516782.8A CN118078234B (en) | 2024-04-28 | 2024-04-28 | PPG signal processing method, device and storage medium |
Publications (2)
Publication Number | Publication Date |
---|---|
CN118078234A true CN118078234A (en) | 2024-05-28 |
CN118078234B CN118078234B (en) | 2024-08-27 |
Family
ID=91165628
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202410516782.8A Active CN118078234B (en) | 2024-04-28 | 2024-04-28 | PPG signal processing method, device and storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN118078234B (en) |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20100082302A1 (en) * | 2008-09-26 | 2010-04-01 | Qualcomm Incorporated | Method and apparatus for under-sampled acquisition and transmission of photoplethysmograph (ppg) data and reconstruction of full band ppg data at the receiver |
US20170209055A1 (en) * | 2016-01-22 | 2017-07-27 | Fitbit, Inc. | Photoplethysmography-based pulse wave analysis using a wearable device |
CN112545472A (en) * | 2020-12-02 | 2021-03-26 | 成都心吉康科技有限公司 | PPG signal quality evaluation method, device, equipment and storage medium |
CN115120236A (en) * | 2022-04-28 | 2022-09-30 | 广东小天才科技有限公司 | Emotion recognition method and device, wearable device and storage medium |
-
2024
- 2024-04-28 CN CN202410516782.8A patent/CN118078234B/en active Active
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20100082302A1 (en) * | 2008-09-26 | 2010-04-01 | Qualcomm Incorporated | Method and apparatus for under-sampled acquisition and transmission of photoplethysmograph (ppg) data and reconstruction of full band ppg data at the receiver |
US20170209055A1 (en) * | 2016-01-22 | 2017-07-27 | Fitbit, Inc. | Photoplethysmography-based pulse wave analysis using a wearable device |
CN112545472A (en) * | 2020-12-02 | 2021-03-26 | 成都心吉康科技有限公司 | PPG signal quality evaluation method, device, equipment and storage medium |
CN115120236A (en) * | 2022-04-28 | 2022-09-30 | 广东小天才科技有限公司 | Emotion recognition method and device, wearable device and storage medium |
Non-Patent Citations (1)
Title |
---|
孙斌;王成超;陈建飞;张永芳;陈小惠;: "受运动伪影干扰PPG序列的优质信号提取算法", 仪器仪表学报, no. 09, 15 September 2018 (2018-09-15) * |
Also Published As
Publication number | Publication date |
---|---|
CN118078234B (en) | 2024-08-27 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US11445970B2 (en) | System and method for neural-network-based atrial fibrillation detection with the aid of a digital computer | |
US11672436B2 (en) | Pulse detection from head motions in video | |
US10849531B2 (en) | Systematic apparatus for motion sensor and optical sensor based cardiac arrhythmia triage | |
Smital et al. | Real-time quality assessment of long-term ECG signals recorded by wearables in free-living conditions | |
Parate et al. | Risq: Recognizing smoking gestures with inertial sensors on a wristband | |
JP2021519168A (en) | Systems and methods for non-invasive determination of blood pressure drop based on trained predictive models | |
EP2772828B1 (en) | Individual body discrimination device and individual body discrimination method | |
Liaqat et al. | WearBreathing: Real world respiratory rate monitoring using smartwatches | |
CN107106028B (en) | System and method for cardiopulmonary sleep stage classification | |
CN109674456B (en) | Blood pressure estimation device and method and wearable device | |
JPWO2017179696A1 (en) | Biological information analyzer, system, and program | |
KR20200041831A (en) | Reliable acquisition of light pulse data | |
CN109452935A (en) | The non-invasive methods and system from photoplethysmogram estimated blood pressure are post-processed using statistics | |
US11617545B2 (en) | Methods and systems for adaptable presentation of sensor data | |
US11844594B2 (en) | Method, an apparatus and a computer program product for estimating the quality of a signal | |
US20210030353A1 (en) | Method and a system for detecting a respiratory event of a subject and a method for forming a model for detecting a respiratory event | |
CN106456030A (en) | Device and method for removing artifacts in physiological measurements | |
US20240321455A1 (en) | Cardiac arrhythmia detection | |
CN111317484A (en) | Apparatus and method for estimating blood glucose | |
US20210378585A1 (en) | Fetal health monitoring system and method for using the same | |
Fedorin et al. | Consumer smartwatches as a portable PSG: LSTM based neural networks for a sleep-related physiological parameters estimation | |
KR20190117100A (en) | Method and apparatus for measuring biometric information in electronic device | |
EP3488771B1 (en) | System and method for machine-learning-based atrial fibrillation detection | |
CN118078234B (en) | PPG signal processing method, device and storage medium | |
US20220000374A1 (en) | Multi-modal body sensor monitoring and recording system based secured health-care infrastructure |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant | ||
CP03 | Change of name, title or address |
Address after: Unit 3401, unit a, building 6, Shenye Zhongcheng, No. 8089, Hongli West Road, Donghai community, Xiangmihu street, Futian District, Shenzhen, Guangdong 518040 Patentee after: Honor Terminal Co.,Ltd. Country or region after: China Address before: 3401, unit a, building 6, Shenye Zhongcheng, No. 8089, Hongli West Road, Donghai community, Xiangmihu street, Futian District, Shenzhen, Guangdong Patentee before: Honor Device Co.,Ltd. Country or region before: China |