[go: up one dir, main page]

CN116327155A - Remote heart rate measurement method, device and equipment based on adaptive ROI selection - Google Patents

Remote heart rate measurement method, device and equipment based on adaptive ROI selection Download PDF

Info

Publication number
CN116327155A
CN116327155A CN202310335761.1A CN202310335761A CN116327155A CN 116327155 A CN116327155 A CN 116327155A CN 202310335761 A CN202310335761 A CN 202310335761A CN 116327155 A CN116327155 A CN 116327155A
Authority
CN
China
Prior art keywords
signal
noise ratio
frame
heart rate
reflection angle
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.)
Pending
Application number
CN202310335761.1A
Other languages
Chinese (zh)
Inventor
范烜赫
张晶晶
黄智杰
高童
樊子阳
贺予柯
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
China University of Geosciences
Original Assignee
China University of Geosciences
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by China University of Geosciences filed Critical China University of Geosciences
Priority to CN202310335761.1A priority Critical patent/CN116327155A/en
Publication of CN116327155A publication Critical patent/CN116327155A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • AHUMAN NECESSITIES
    • A61MEDICAL OR VETERINARY SCIENCE; HYGIENE
    • A61BDIAGNOSIS; SURGERY; IDENTIFICATION
    • A61B5/00Measuring for diagnostic purposes; Identification of persons
    • A61B5/02Detecting, measuring or recording for evaluating the cardiovascular system, e.g. pulse, heart rate, blood pressure or blood flow
    • A61B5/024Measuring pulse rate or heart rate
    • A61B5/02416Measuring pulse rate or heart rate using photoplethysmograph signals, e.g. generated by infrared radiation
    • AHUMAN NECESSITIES
    • A61MEDICAL OR VETERINARY SCIENCE; HYGIENE
    • A61BDIAGNOSIS; SURGERY; IDENTIFICATION
    • A61B5/00Measuring for diagnostic purposes; Identification of persons
    • A61B5/0033Features or image-related aspects of imaging apparatus, e.g. for MRI, optical tomography or impedance tomography apparatus; Arrangements of imaging apparatus in a room
    • AHUMAN NECESSITIES
    • A61MEDICAL OR VETERINARY SCIENCE; HYGIENE
    • A61BDIAGNOSIS; SURGERY; IDENTIFICATION
    • A61B5/00Measuring for diagnostic purposes; Identification of persons
    • A61B5/0059Measuring for diagnostic purposes; Identification of persons using light, e.g. diagnosis by transillumination, diascopy, fluorescence
    • A61B5/0077Devices for viewing the surface of the body, e.g. camera, magnifying lens
    • AHUMAN NECESSITIES
    • A61MEDICAL OR VETERINARY SCIENCE; HYGIENE
    • A61BDIAGNOSIS; SURGERY; IDENTIFICATION
    • A61B5/00Measuring for diagnostic purposes; Identification of persons
    • A61B5/02Detecting, measuring or recording for evaluating the cardiovascular system, e.g. pulse, heart rate, blood pressure or blood flow
    • A61B5/024Measuring pulse rate or heart rate
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F17/00Digital computing or data processing equipment or methods, specially adapted for specific functions
    • G06F17/10Complex mathematical operations
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02ATECHNOLOGIES FOR ADAPTATION TO CLIMATE CHANGE
    • Y02A90/00Technologies having an indirect contribution to adaptation to climate change
    • Y02A90/10Information and communication technologies [ICT] supporting adaptation to climate change, e.g. for weather forecasting or climate simulation

Landscapes

  • Health & Medical Sciences (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Veterinary Medicine (AREA)
  • Animal Behavior & Ethology (AREA)
  • Pathology (AREA)
  • Biophysics (AREA)
  • Biomedical Technology (AREA)
  • Heart & Thoracic Surgery (AREA)
  • Medical Informatics (AREA)
  • Molecular Biology (AREA)
  • Surgery (AREA)
  • Cardiology (AREA)
  • General Health & Medical Sciences (AREA)
  • Public Health (AREA)
  • Data Mining & Analysis (AREA)
  • Physiology (AREA)
  • Theoretical Computer Science (AREA)
  • Mathematical Physics (AREA)
  • General Physics & Mathematics (AREA)
  • Nuclear Medicine, Radiotherapy & Molecular Imaging (AREA)
  • Computational Mathematics (AREA)
  • Mathematical Analysis (AREA)
  • Mathematical Optimization (AREA)
  • Algebra (AREA)
  • Pure & Applied Mathematics (AREA)
  • Databases & Information Systems (AREA)
  • Software Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Radiology & Medical Imaging (AREA)
  • Measuring And Recording Apparatus For Diagnosis (AREA)

Abstract

本发明公开了一种基于自适应ROI选择的远程心率测量方法、装置及设备,该方法通过对每一帧面部图像进行分割得到多个区域;通过计算各区域的反射角、G通道值以及信噪比,构建信噪比估计模型,根据信噪比估计模型可以找出一帧图像中最适合进行iPPG心率提取的区域(ROI),从而合成信号进行心率的估算。该方法主要解决了面部运动造成目标区域跟踪丢失的情况,该方法为iPPG技术人脸面部ROI区域的动态识别提供了一个新的思路。实验结果表明,在考虑到面部运动和光照明暗变化的情况下,在处理前后使用本发明方法,可以将信噪比提高0.3152db,PET6(误差心率的绝对值小于等于6)提高0.5651%。

Figure 202310335761

The invention discloses a remote heart rate measurement method, device and equipment based on self-adaptive ROI selection. The method obtains multiple regions by segmenting each frame of facial images; calculates the reflection angle, G channel value and signal Noise ratio, build a signal-to-noise ratio estimation model, according to the signal-to-noise ratio estimation model, you can find out the region (ROI) that is most suitable for iPPG heart rate extraction in a frame of image, and then synthesize the signal to estimate the heart rate. This method mainly solves the situation that the tracking of the target area is lost due to facial movement, and this method provides a new idea for the dynamic recognition of the ROI area of the face with iPPG technology. Experimental results show that, in consideration of facial movement and light and dark changes, using the method of the present invention before and after processing can increase the signal-to-noise ratio by 0.3152db, and PET6 (the absolute value of error heart rate is less than or equal to 6) by 0.5651%.

Figure 202310335761

Description

基于自适应ROI选择的远程心率测量方法、装置及设备Remote heart rate measurement method, device and equipment based on adaptive ROI selection

技术领域technical field

本发明涉及心率测量技术领域,特别涉及一种基于自适应ROI选择的远程心率测量方法、装置及设备。The invention relates to the technical field of heart rate measurement, in particular to a remote heart rate measurement method, device and equipment based on adaptive ROI selection.

背景技术Background technique

随着传染病大流行和心脏疾病致死率的提高,人们对于心脏健康的关注逐渐增加。iPPG技术是一种无接触的和无侵入的技术,可以在传感器不接触皮肤的情况下测量和监视我们的心率。通过对人体进行长时间、准确和及时的检测,再结合医生进行诊断可以很大的降低心脏疾病的致死率。iPPG的原理是它们是来自于皮肤区域的微弱强度变化每一个心动周期,由不同的血量造成的随着时间的推移。目前已有很多远程测量技术雷达、光学深度测量,已经被用来测量心率(HR)、血压、呼吸频率(RR)和心率变化率(HRV)。特别是由于其不与皮肤接触的特性可以很好的适用于驾驶员、新生儿与皮肤病患者,因此引起了许多研究人员的兴趣。With the epidemic of infectious diseases and the increase in the death rate of heart disease, people's attention to heart health has gradually increased. iPPG technology is a contactless and non-invasive technology that measures and monitors our heart rate without the sensor touching the skin. Through long-term, accurate and timely detection of the human body, combined with doctors' diagnosis, the fatality rate of heart disease can be greatly reduced. The principle of iPPGs is that they are derived from the faint intensity changes in the skin area each cardiac cycle, caused by different blood volumes over time. There are many remote measurement technologies radar, optical depth measurement, which have been used to measure heart rate (HR), blood pressure, respiratory rate (RR) and heart rate variability (HRV). Especially because of its non-skin contact characteristics, it can be well applied to drivers, newborns and patients with skin diseases, so it has attracted the interest of many researchers.

iPPG心率测量的重要步骤之一是选择ROI。iPPG信号是通过提取所选ROI在一段时期内的图像平均值产生的;这是研究人员最常使用的方法。一个ROI帧的图像平均值将给出ROI中所有G通道值的平均G通道值。因此,ROI中G通道值本身就微弱的变化也被平均;这使得面部视频中iPPG的信号不够强烈。在过去的十年中,已经提出了大量关于选择ROI的方法。One of the important steps in iPPG heart rate measurement is the selection of ROI. The iPPG signal is generated by extracting image averages over a period of time for selected ROIs; this is the method most commonly used by researchers. Image averaging of one ROI frame will give the average G channel value of all G channel values in the ROI. Therefore, the inherently weak variation of the G channel value in the ROI is also averaged; this makes the signal of iPPG in the facial video not strong enough. Over the past decade, a large number of methods for selecting ROIs have been proposed.

自Poh等人最初提出修改ROI的选择,从选择全脸到选择全脸宽度和全高的60%的ROI。脸颊、额头和眼睛以下的面部区域相继被提议作为ROI。然后提出了一种更准确的通过面部分割的ROI选择方法。Lam等人也提出了一个使用面部地标的ROI选择标准,该标准使用眼睛以下和嘴唇以内的面部区域的地标的随机斑块。这些方法在第一帧就选择了这些ROI,不会随着视频的变化而变化。因此,这些方法不适用于头部旋转和不稳定的照度。Since Poh et. Cheeks, forehead, and facial regions below the eyes are successively proposed as ROIs. Then a more accurate ROI selection method via face segmentation is proposed. A ROI selection criterion using facial landmarks is also proposed by Lam et al., which uses random patches of landmarks in the facial region below the eyes and inside the lips. These methods select these ROIs at the first frame and do not change as the video changes. Therefore, these methods are not suitable for head rotation and unstable illumination.

为了克服不稳定的照度,人们提出了通过权重来选择ROI的方法。Kumar等人提出用20×20像素的区块从整个面部选择ROI,并使用权重来估计ROI的最佳组合。EwaM.Nowara等人。使用面部地标将面部分割成许多区域,评估每个区域的信号质量来选择ROI,并选择五个背景区域来消除光照变化的干扰。这种方法有很好的效果,经常被用来选择ROI。In order to overcome the unstable illumination, a method of selecting ROI by weight is proposed. Kumar et al. proposed to select ROIs from the whole face with 20×20 pixel patches and use weights to estimate the best combination of ROIs. Ewa M. Nowara et al. The face is segmented into many regions using facial landmarks, the signal quality of each region is evaluated to select an ROI, and five background regions are selected to remove the distraction of illumination changes. This method has good results and is often used to select ROIs.

然而,通过权重选择ROI的方法通常需要选择一个时间窗口来计算选择结果,衡量该时间段的最佳ROI。另一方面,这个时间窗口的长度从5秒到几十秒不等,而且这个方法会失败,因为受试者的面部区域并不总是随着头部的转动而被摄像机获取,当受试者面部运动时,会造成目标区域跟踪丢失的情况,故无法选择最佳的ROI,导致心率测量失败。However, the method of selecting ROIs by weight usually needs to select a time window to calculate the selection result, and measure the best ROI in this time period. On the other hand, the length of this time window varies from 5 seconds to tens of seconds, and this method will fail because the subject's facial region is not always captured by the camera with the head rotation, when the subject When the face moves, the tracking of the target area will be lost, so the best ROI cannot be selected, resulting in heart rate measurement failure.

因此,当受试者面部运动时,提高远程心率测量过程中ROI的鲁棒性是本领域亟待解决的技术问题。Therefore, when the subject's face moves, improving the robustness of the ROI in the process of remote heart rate measurement is a technical problem to be solved urgently in this field.

发明内容Contents of the invention

本发明要解决的主要技术问题在于,当受试者面部运动时提高远程心率测量过程中ROI的鲁棒性,进而提高远程心率测量的准确性,为了解决该技术问题,本发明提供了一种基于自适应ROI选择的远程心率测量方法、装置及设备,结合一种新的ROI选择方式,来测量在头部旋转情况下的心率。The main technical problem to be solved by the present invention is to improve the robustness of the ROI in the remote heart rate measurement process when the subject’s face moves, thereby improving the accuracy of the remote heart rate measurement. In order to solve this technical problem, the present invention provides a The remote heart rate measurement method, device and equipment based on adaptive ROI selection are combined with a new ROI selection method to measure the heart rate under the condition of head rotation.

根据本发明的第一方面,本发明提供了一种基于自适应ROI选择的远程心率测量方法,包括以下步骤:According to a first aspect of the present invention, the present invention provides a remote heart rate measurement method based on adaptive ROI selection, comprising the following steps:

连续获取受试者头部静止状态下的多帧面部图像;Continuously acquire multiple frames of facial images with the subject's head still;

将每一帧面部图像分割成多个区域,并计算各区域的反射角;Divide each frame of facial image into multiple regions, and calculate the reflection angle of each region;

计算每一帧面部图像各区域的信噪比;Calculate the signal-to-noise ratio of each region of each frame of facial image;

通过每一帧面部图像各区域的反射角、G通道值以及信噪比构建信噪比估计模型;Construct a signal-to-noise ratio estimation model through the reflection angle, G channel value and signal-to-noise ratio of each area of each frame of facial image;

根据信噪比估计模型对每一帧面部图像选择ROI;Select ROI for each frame of facial image according to the signal-to-noise ratio estimation model;

将多帧面部图像的ROI进行信号合成,得到iPPG信号;Combining the ROIs of multiple frames of facial images to obtain iPPG signals;

根据iPPG信号计算受试者的心率。The subject's heart rate was calculated from the iPPG signal.

进一步地,所述将每一帧面部图像分割成多个区域,并计算各区域的反射角的步骤之前,还包括:Further, before the step of dividing each frame of facial image into multiple regions and calculating the reflection angle of each region, it also includes:

对获取的每一帧面部图像应用MediaPipeFaceMesh来检测受试者面部的468个三维地标;Apply MediaPipeFaceMesh to each frame of facial image acquired to detect 468 3D landmarks on the subject's face;

将面部的三维地标作为计算面部像素的表面法向量和反射角的参考点,将三维地标j处可能的表面法向量集合定义为:Taking the 3D landmark of the face as the reference point to calculate the surface normal vector and reflection angle of the face pixel, the set of possible surface normal vectors at the 3D landmark j is defined as:

Figure BDA0004156394280000031
Figure BDA0004156394280000031

式中,

Figure BDA0004156394280000032
表示从地标j到邻近地标i的矢量,/>
Figure BDA0004156394280000033
表示从地标j到另一邻近地标k的矢量,m是一个正整数,代表用于估计地标j可能的表面法线向量集合Pj的相邻地标的数量;In the formula,
Figure BDA0004156394280000032
represents a vector from landmark j to neighboring landmark i, />
Figure BDA0004156394280000033
Represents the vector from landmark j to another neighboring landmark k, m is a positive integer representing the number of neighboring landmarks used to estimate the possible surface normal vector set Pj of landmark j ;

使用协方差分析法从表面法线向量集合Pj中选择地标j处最具代表性的表面法线

Figure BDA0004156394280000034
The most representative surface normal at landmark j is selected from the set of surface normal vectors Pj using analysis of covariance
Figure BDA0004156394280000034

根据表面法线计算地标j的反射角θjCompute the reflection angle θ j of landmark j from the surface normal:

Figure BDA0004156394280000035
Figure BDA0004156394280000035

其中,

Figure BDA0004156394280000036
是地标j的表面法线,/>
Figure BDA0004156394280000037
是相机轴的单位矢量。in,
Figure BDA0004156394280000036
is the surface normal of landmark j, />
Figure BDA0004156394280000037
is the unit vector of the camera axis.

进一步地,所述将每一帧面部图像分割成多个区域,并计算各区域的反射角的步骤,包括,Further, the step of dividing each frame of facial image into multiple regions and calculating the reflection angle of each region includes,

将受试者的面部图像分三步进行分割,分割成N个四边形的ROI部分;Segment the subject's facial image in three steps, and divide it into N quadrilateral ROI parts;

分割后的区域的反射角θm通过以下方式给出:The reflection angle θm of the segmented region is given by:

Figure BDA0004156394280000038
Figure BDA0004156394280000038

其中,m是N个分割区域的序号,θm,n是第n个区域的四个顶点的法向角,每个区域的反射角用灰度表示。Among them, m is the sequence number of the N segmented regions, θ m, n are the normal angles of the four vertices of the nth region, and the reflection angle of each region is represented by gray scale.

进一步地,所述将受试者的面部图像分三步进行分割的步骤,包括:Further, the step of segmenting the subject's facial image in three steps includes:

去除眼睛、眉毛和嘴上的地标;Remove eye, eyebrow and mouth landmarks;

去除由面部表情运动引起的地标,包括眼角、嘴唇和鼻子周围;Remove landmarks caused by facial expression movements, including around the corners of the eyes, lips and nose;

直线连接其余地标。Connect the remaining landmarks with straight lines.

进一步地,所述通过每一帧面部图像各区域的反射角、G通道值以及信噪比构建信噪比估计模型的步骤,包括:Further, the step of constructing a signal-to-noise ratio estimation model through reflection angles, G channel values and signal-to-noise ratios of each region of each frame facial image includes:

对于采集到的每一帧面部图像,分别记录N个区域平均的G通道值GN与平均的反射角度值θN,再记录当前面部图像的帧数t∈{1,…,T*FPS},将记录的数据信息存放在一个N×t×2的矩阵中,其中T为采集视频的秒数,FPS为相机采集的帧率;For each frame of facial image collected , record the average G channel value G N and the average reflection angle value θ N of N regions, and then record the frame number t∈{1,...,T*FPS} of the current facial image , store the recorded data information in an N×t×2 matrix, where T is the number of seconds of video capture, and FPS is the frame rate of camera capture;

将预设时间窗口内的平均的G通道值、平均的反射角度值与信噪比记录为一组数据;Record the average G channel value, average reflection angle value and signal-to-noise ratio within the preset time window as a set of data;

对平均的G通道值GN与平均的反射角度值两个影响因素单独进行集中趋势检验,去除数据中的离群点;The average G channel value G N and the average reflection angle value of the two influencing factors are separately tested for central tendency to remove outliers in the data;

将去除离群点后的数据进行非线性曲线拟合,获取输入量为反射角与G通道值,输出量为信噪比的信噪比估计模型。Non-linear curve fitting is performed on the data after removing outliers, and the signal-to-noise ratio estimation model whose input is the reflection angle and G channel value and the output is the signal-to-noise ratio is obtained.

进一步地,所述根据信噪比估计模型对每一帧面部图像选择ROI的步骤,包括:Further, the step of selecting the ROI for each frame of facial images according to the signal-to-noise ratio estimation model includes:

根据相机频率与人体心率计算出能够计算出人体心率的最小帧数;Calculate the minimum number of frames that can calculate the human heart rate according to the camera frequency and the human heart rate;

当信噪比模型估计的信噪比最高区域连续出现的次数大于等于最小帧数时,进行ROI的选取。When the number of consecutive occurrences of the highest SNR area estimated by the SNR model is greater than or equal to the minimum number of frames, ROI selection is performed.

优选地,分割区域的个数N=91。Preferably, the number of divided regions is N=91.

根据本发明的第二方面,本发明提供了一种基于自适应ROI选择的远程心率测量装置,包括以下模块:According to a second aspect of the present invention, the present invention provides a remote heart rate measurement device based on adaptive ROI selection, comprising the following modules:

获取模块,用于连续获取受试者头部静止状态下的多帧面部图像;An acquisition module, configured to continuously acquire multiple frames of facial images of the subject's head at rest;

分割模块,用于将每一帧面部图像分割成多个区域;Segmentation module, is used for dividing each frame face image into a plurality of regions;

计算模块,用于计算各区域的反射角;Calculation module, for calculating the reflection angle of each area;

所述计算模块,还用于计算每一帧面部图像各区域的信噪比;The calculation module is also used to calculate the signal-to-noise ratio of each region of each frame of facial image;

构建模块,用于通过每一帧面部图像各区域的反射角、G通道值以及信噪比构建信噪比估计模型;A building block for constructing a signal-to-noise ratio estimation model through reflection angles, G channel values and signal-to-noise ratios of each region of each frame of facial images;

选择模块,用于根据信噪比估计模型对每一帧面部图像选择ROI;A selection module is used to select the ROI for each frame of facial images according to the signal-to-noise ratio estimation model;

合成模块,用于将多帧面部图像的ROI进行信号合成,得到iPPG信号;Synthesis module, for carrying out signal synthesis to the ROI of multi-frame face image, obtains iPPG signal;

所述计算模块,还用于根据iPPG信号计算受试者的心率。The calculation module is also used to calculate the subject's heart rate according to the iPPG signal.

根据本发明的第三方面,本发明提供了一种电子设备,包括存储器、处理器及存储在存储器上并可在处理器上运行的计算机程序,所述处理器执行所述程序时实现所述的远程心率测量方法的步骤。According to a third aspect of the present invention, the present invention provides an electronic device, including a memory, a processor, and a computer program stored in the memory and operable on the processor, and the processor implements the described program when executing the program. The steps of the remote heart rate measurement method.

根据本发明的又一方面,本发明还提供了一种存储介质,其上存储有计算机程序,该计算机程序被处理器执行时实现所述的远程心率测量方法的步骤。According to still another aspect of the present invention, the present invention also provides a storage medium on which a computer program is stored, and when the computer program is executed by a processor, the steps of the remote heart rate measurement method are implemented.

本发明提供的技术方案具有以下有益效果:The technical solution provided by the invention has the following beneficial effects:

本发明主要提出了一种基于自适应ROI选择的远程心率测量方法,该方法通过对每一帧面部图像进行分割得到多个区域,通过计算各区域的反射角、G通道值以及信噪比,构建信噪比估计模型,根据信噪比估计模型可以找出一帧图像中最适合进行iPPG心率提取的区域(ROI),从而合成信号进行心率的估算。该方法主要解决了面部运动造成目标区域跟踪丢失的情况,该方法为iPPG技术人脸面部ROI区域的动态识别提供了一个新的思路。实验结果表明,在考虑到面部运动和光照明暗变化的情况下,在处理前后使用本发明方法,将SNR(信噪比)提高了0.3152db,PET6(误差心率的绝对值小于等于6)提高了0.5651%。The present invention mainly proposes a remote heart rate measurement method based on adaptive ROI selection. The method obtains multiple regions by segmenting each frame of facial images, and calculates the reflection angle, G channel value and signal-to-noise ratio of each region. A signal-to-noise ratio estimation model is constructed. According to the signal-to-noise ratio estimation model, the most suitable region (ROI) for iPPG heart rate extraction in a frame of image can be found, so as to synthesize signals for heart rate estimation. This method mainly solves the situation that the tracking of the target area is lost due to facial movement, and this method provides a new idea for the dynamic recognition of the ROI area of the face with iPPG technology. Experimental results show that, in the case of considering facial movement and light and dark changes, using the method of the present invention before and after processing, SNR (signal-to-noise ratio) is improved by 0.3152db, and PET6 (absolute value of error heart rate is less than or equal to 6) improves 0.5651%.

附图说明Description of drawings

下面将结合附图及实施例对本发明作进一步说明,附图中:The present invention will be further described below in conjunction with accompanying drawing and embodiment, in the accompanying drawing:

图1为本发明一种基于自适应ROI选择的远程心率测量方法的总体流程图;Fig. 1 is the overall flowchart of a kind of remote heart rate measurement method based on self-adaptive ROI selection of the present invention;

图2为本发明自适应ROI选择的过程示意图;Fig. 2 is a schematic diagram of the process of adaptive ROI selection in the present invention;

图3为本发明从图像中生成角度图的整体管道,其中(a)为表面反射角计算,(b)为SNR估计方法,(c)为SNR估计模型建立,(d)为ROI鲁棒性选择;Figure 3 is the overall pipeline of the present invention to generate an angle map from an image, where (a) is the calculation of the surface reflection angle, (b) is the SNR estimation method, (c) is the establishment of the SNR estimation model, and (d) is the ROI robustness choose;

图4为本发明数据示意图;Fig. 4 is the data schematic diagram of the present invention;

图5为本发明窗口滑动示意图;Fig. 5 is a schematic diagram of window sliding in the present invention;

图6为本发明Ut(f)度量信号模板(a)以及IPPG信号的频谱(b);Fig. 6 is the frequency spectrum (b) of U t (f) measurement signal template (a) and IPPG signal of the present invention;

图7为本发明G通道值与信噪比箱线图,实线为中位数值,用来观察结果整体趋势;Fig. 7 is a box plot of the G channel value and the signal-to-noise ratio of the present invention, and the solid line is the median value, which is used to observe the overall trend of the results;

图8为ROI在连续几帧图像中频繁变化;Figure 8 shows that the ROI changes frequently in several consecutive frames of images;

图9为ROI鲁棒性选择方法示意图;Fig. 9 is a schematic diagram of ROI robustness selection method;

图10为本发明一种基于自适应ROI选择的远程心率测量装置的结构示意图;10 is a schematic structural diagram of a remote heart rate measurement device based on adaptive ROI selection in the present invention;

图11为本发明一种电子设备的结构示意图;Fig. 11 is a schematic structural diagram of an electronic device of the present invention;

图12为本发明ROI选择方法使用前后的SNR和PET6结果对比图。Fig. 12 is a comparison chart of SNR and PET6 results before and after the ROI selection method of the present invention is used.

具体实施方式Detailed ways

为了对本发明的技术特征、目的和效果有更加清楚的理解,现对照附图详细说明本发明的具体实施方式。In order to have a clearer understanding of the technical features, purposes and effects of the present invention, the specific implementation manners of the present invention will now be described in detail with reference to the accompanying drawings.

请参考图1,本发明提供了一种基于自适应ROI选择的远程心率测量方法,该方法包括以下步骤:Please refer to Fig. 1, the present invention provides a kind of remote heart rate measurement method based on adaptive ROI selection, and this method comprises the following steps:

S1:连续获取受试者头部静止状态下的多帧面部图像;S1: Continuously acquire multiple frames of facial images with the subject's head still;

S2:将每一帧面部图像分割成多个区域,并计算各区域的反射角;S2: Divide each frame of facial image into multiple regions, and calculate the reflection angle of each region;

S3:计算每一帧面部图像各区域的信噪比;S3: Calculate the signal-to-noise ratio of each area of each frame of facial image;

S4:通过每一帧面部图像各区域的反射角、G通道值以及信噪比构建信噪比估计模型;S4: Construct a signal-to-noise ratio estimation model through reflection angles, G channel values, and signal-to-noise ratios of each region of each frame of facial images;

S5:根据信噪比估计模型对每一帧面部图像选择ROI;S5: Select an ROI for each frame of facial images according to the SNR estimation model;

S6:将多帧面部图像的ROI进行信号合成,得到iPPG信号;S6: performing signal synthesis on ROIs of multiple frames of facial images to obtain iPPG signals;

S7:根据iPPG信号计算受试者的心率。S7: Calculate the heart rate of the subject according to the iPPG signal.

其中,自适应ROI的选择过程具体如图2所示,主要包括四个步骤:Among them, the selection process of adaptive ROI is shown in Figure 2, which mainly includes four steps:

1)将面部分割成91个区域,并计算每个区域的反射角。2)计算每个区域的信噪比;3)通过反射角和G通道值与计算的信噪比构建信噪比估计模型。4)根据信噪比估计模型,鲁棒性地选择ROI。1) Segment the face into 91 regions and calculate the reflection angle of each region. 2) Calculate the SNR of each region; 3) Construct the SNR estimation model through the reflection angle and G channel value and the calculated SNR. 4) Robustly select the ROI according to the SNR estimation model.

接下来,结合具体的附图详细说明本发明实施过程中的关键点:Next, the key points in the implementation process of the present invention will be described in detail in conjunction with specific drawings:

(1)面部分割与反射角计算:(1) Face segmentation and reflection angle calculation:

如图3所示,显示了从图像中生成角度图的整体管道。对每一帧图像应用MediaPipeFaceMesh来检测受试者面部的468个三维地标,如图3(a)所示。三维面部地标作为后续计算面部像素的表面法向量和反射角的参考点(图2)。将地标j处可能的表面法向量集合定义为Pj,即As shown in Figure 3, the overall pipeline for generating angle maps from images is shown. We apply MediaPipeFaceMesh to each image frame to detect 468 3D landmarks on the subject's face, as shown in Figure 3(a). The 3D facial landmarks serve as reference points for the subsequent computation of surface normal vectors and reflection angles of face pixels (Fig. 2). Define the set of possible surface normal vectors at landmark j as P j , namely

Figure BDA0004156394280000061
Figure BDA0004156394280000061

式中,

Figure BDA0004156394280000062
表示从地标j到邻近地标i的矢量,/>
Figure BDA0004156394280000063
表示从地标j到另一邻近地标k的矢量,m是一个正整数,代表用于估计地标j可能的表面法线向量集合Pj的相邻地标的数量;In the formula,
Figure BDA0004156394280000062
represents a vector from landmark j to neighboring landmark i, />
Figure BDA0004156394280000063
Represents the vector from landmark j to another neighboring landmark k, m is a positive integer representing the number of neighboring landmarks used to estimate the possible surface normal vector set Pj of landmark j ;

然后,使用协方差分析(ANCOVA)法从表面法线向量集合Pj中选择地标j处最具代表性的表面法线。地标j的反射角θj被估计为:Then, the most representative surface normal at landmark j is selected from the set of surface normal vectors Pj using the analysis of covariance (ANCOVA) method. The reflection angle θj of landmark j is estimated as:

Figure BDA0004156394280000071
Figure BDA0004156394280000071

其中,

Figure BDA0004156394280000072
是地标j的表面法线,/>
Figure BDA0004156394280000073
是相机轴的单位矢量。估计的坐标点的法向量如图3(b)所示。in,
Figure BDA0004156394280000072
is the surface normal of landmark j, />
Figure BDA0004156394280000073
is the unit vector of the camera axis. The normal vectors of the estimated coordinate points are shown in Fig. 3(b).

接下来,受试者的面部分三步进行分割。1)去除眼睛、眉毛和嘴上的地标,这些地标对BVP信号无用。2)去除由面部表情运动引起的地标,包括眼角、嘴唇和鼻子周围。3)直线连接其余地标。因此,受试者的脸被分割成91个四边形的ROI部分,如图3(c)所示。最后,分割后的区域的反射角可以通过以下方式给出:Next, the subject's face is segmented in three steps. 1) Remove eye, eyebrow and mouth landmarks, which are useless for BVP signal. 2) Remove landmarks caused by facial expression movements, including around eye corners, lips and nose. 3) Connect the remaining landmarks with straight lines. Therefore, the subject's face is segmented into 91 quadrilateral ROI parts, as shown in Fig. 3(c). Finally, the reflection angles of the segmented regions can be given by:

Figure BDA0004156394280000074
Figure BDA0004156394280000074

其中m是91个分割区域的序号,θm,n是第n个区域的四个顶点的法向角。每个区域的反射角用灰度表示,如图3(d)所示。Where m is the serial number of the 91 segmented regions, θ m, n is the normal angle of the four vertices of the nth region. The reflection angle of each region is expressed in gray scale, as shown in Fig. 3(d).

在划分出的91个区域中,需要用信噪比来度量不同反射角度与不同光照强度对信号质量的影响。在之前的研究当中,已经证明了彩色相机的RGB三个通道里,G通道包含与BVP信号相关性最高的心率信息。因此在这里使用G通道信号强度来度量信噪比。In the divided 91 areas, the signal-to-noise ratio needs to be used to measure the influence of different reflection angles and different light intensities on the signal quality. In the previous research, it has been proved that among the RGB three channels of the color camera, the G channel contains the heart rate information with the highest correlation with the BVP signal. Therefore, the signal strength of the G channel is used here to measure the signal-to-noise ratio.

对于采集到的每一帧图像,分别记录N=91个区域的平均的G通道值GN与平均的反射角度值θN,其中N∈{1,…,91},再记录当前图像的帧数t∈{1,…,T*FPS},因此可以将数据信息存放在一个N×t×2的矩阵中,其中T为采集视频的秒数,FPS为相机采集的帧率。For each frame of image collected, record the average G channel value G N and the average reflection angle value θ N of N=91 regions respectively, where N∈{1,...,91}, and then record the frame of the current image The number t∈{1,...,T*FPS}, so the data information can be stored in an N×t×2 matrix, where T is the number of seconds of video capture, and FPS is the frame rate of camera capture.

(2)信噪比估计:(2) SNR estimation:

将获取到的G通道信号进行简要的时频分析,为了保证该研究方法在短时内的有效性,如图5所示,采用10秒为一个窗口进行滑动分析,将10秒内获取的脉冲信号频谱进行归一化作为估计心率信号,再将接触脉搏血氧仪10秒内的测量结果均值作为真实心率信号,由于要求受试者的面部保持静止,因此可以用10秒内的反射角度的平均值来代表该时间段信号的反射角度。A brief time-frequency analysis is performed on the acquired G channel signal. In order to ensure the effectiveness of the research method in a short period of time, as shown in Figure 5, 10 seconds is used as a window for sliding analysis, and the pulses acquired within 10 seconds The signal spectrum is normalized as the estimated heart rate signal, and then the average value of the measurement results within 10 seconds of contact with the pulse oximeter is used as the real heart rate signal. Since the face of the subject is required to remain still, the reflection angle within 10 seconds can be used The average value represents the reflection angle of the signal in this time period.

采用了DeHaan等人的信噪比(SNR)评价方法来评估rPPG信号的可用性和质量。对10秒滤波内的时域数据集进行频域评估。该方法计算谐波周围的能量和功率谱中的剩余部分;然后将两者的比值表示为信噪比,单位为dB。信号、噪声和信噪比计算公式如下:The signal-to-noise ratio (SNR) evaluation method of DeHaan et al. was used to assess the availability and quality of rPPG signals. Frequency-domain evaluation of the time-domain dataset within 10 seconds of filtering. This method calculates the energy around the harmonics and the remainder in the power spectrum; the ratio of the two is then expressed as the signal-to-noise ratio in dB. The formulas for calculating signal, noise and signal-to-noise ratio are as follows:

Figure BDA0004156394280000081
Figure BDA0004156394280000081

Figure BDA0004156394280000082
Figure BDA0004156394280000082

Figure BDA0004156394280000083
Figure BDA0004156394280000083

其中

Figure BDA0004156394280000084
为iPPG信号的频谱,f为频率,单位为节拍/分钟(bpm)。所需的信号波段在一般人体脉搏频率范围内,即30bpm至240bpm。in
Figure BDA0004156394280000084
is the spectrum of the iPPG signal, f is the frequency, and the unit is beat/minute (bpm). The required signal band is within the general human pulse frequency range, ie 30bpm to 240bpm.

如图6所示,其中虚线部分为Ut(f)度量信号模板,实线部分为iPPG信号的频谱。信噪比计算使用一个度量信号模板,在估计的心率信号频谱中,以信号峰值为中心,上下2.5个频率单位为范围,和以接触传感器脉冲速率为中心,上下5个频率为范围,以考虑心率可变性。信噪比由模板内外分量的能量比来衡量。As shown in FIG. 6 , the dotted line part is the U t (f) metric signal template, and the solid line part is the spectrum of the iPPG signal. The signal-to-noise ratio calculation uses a metric signal template, in the estimated heart rate signal spectrum, centered on the signal peak, with a range of 2.5 frequency units above and below, and centered on the pulse rate of the contact sensor, with a range of 5 frequencies above and below, to take into account Heart rate variability. The signal-to-noise ratio is measured by the energy ratio of the components inside and outside the template.

(3)信噪比估计模型建立(3) SNR estimation model establishment

将10秒时间窗口中的数据进行记录,由于面部静止且光源恒定的情况下,面部固定区域的反射角度和G通道均值不会发生较大的变化,因此可以将10秒内的平均的G通道值、平均的反射角角度值与信噪比记录为一组数据,为了建立它们之间的数学关系,分别对这两个影响因素做箱线图来单独进行集中趋势检验,去除数据中的离群点以达到对数据初步筛选的目的,减小异常值对数据模型的干扰。如图7所示G通道与SNR的数据结果,图中“+”即为离群点,通过观察中位值的趋势,将处理后的数据进行非线性曲线拟合。同理处理反射角度与SNR的数据,最终获取输入量为反射角度与G通道值,输出量为信噪比估计模型。Record the data in the 10-second time window. Since the reflection angle and the average value of the G channel in the fixed area of the face will not change greatly when the face is still and the light source is constant, the average G channel within 10 seconds can be recorded. In order to establish the mathematical relationship between them, the box plots are made for these two influencing factors to test the central tendency separately, and the deviation in the data is removed. Group points to achieve the purpose of preliminary screening of data and reduce the interference of outliers on the data model. The data results of the G channel and SNR are shown in Figure 7. The "+" in the figure is an outlier point. By observing the trend of the median value, the processed data is fitted with a nonlinear curve. The reflection angle and SNR data are processed in the same way, and the final input is the reflection angle and G channel value, and the output is the signal-to-noise ratio estimation model.

(4)ROI鲁棒性选择(4) ROI Robust Selection

将获取的到的信噪比估计模型直接应用于所采集的模拟驾驶数据集当中。在每一帧图像中,都会估计出一个信噪比最高的区域,将每帧中的最佳区域的信号逐帧合成即可得到原始的iPPG信号,但是在对选取区域进行信号合成时,会发生如图8所示的情况,即在连续几帧图像中选取不同区域作为ROI,这会导致这几帧图像合成的iPPG信号失效,从而造成信号信噪比的降低,因为ROI区域改变而采集到的值,是非生理现象带来的光照强度的改变,并不能从中获取到期望的生理信息,因此,在这里需要对ROI区域的选取增加鲁棒性。The obtained signal-to-noise ratio estimation model is directly applied to the collected simulated driving data set. In each frame of image, an area with the highest signal-to-noise ratio will be estimated, and the signal of the best area in each frame will be synthesized frame by frame to obtain the original iPPG signal, but when the signal is synthesized for the selected area, it will be The situation shown in Figure 8 occurs, that is, selecting different regions as ROIs in several consecutive frames of images, which will cause the failure of the iPPG signal synthesized by these frames of images, resulting in a decrease in the signal-to-noise ratio. The obtained value is the change of light intensity caused by non-physiological phenomena, and the expected physiological information cannot be obtained from it. Therefore, it is necessary to increase the robustness of the selection of the ROI area here.

在这里心率正常的最高频率为4Hz,周期为0.25秒,当采用频率为30Hz的相机采集时,至少需要7.5帧图像,才可以还原计算出人体的心率。如图9所示,在这里设置一个阈值F来限制ROI区域的转变,先将1秒内的最佳区域ID储存起来,当最佳区域连续相同且数量大于阈值F(F≥8)时,进行ROI的转变。Here, the highest frequency of the normal heart rate is 4Hz, and the period is 0.25 seconds. When a camera with a frequency of 30Hz is used to collect, at least 7.5 frames of images are needed to restore and calculate the heart rate of the human body. As shown in Figure 9, a threshold F is set here to limit the transformation of the ROI region. First, the best region ID within 1 second is stored. When the best region is continuously the same and the number is greater than the threshold F (F≥8), Make ROI shifts.

下面对本发明提供的一种基于自适应ROI选择的远程心率测量装置进行描述,下文描述的远程心率测量装置与上文描述的远程心率测量方法可相互对应参照。A remote heart rate measurement device based on adaptive ROI selection provided by the present invention is described below, and the remote heart rate measurement device described below and the remote heart rate measurement method described above can be referred to in correspondence.

如图10所示,一种基于自适应ROI选择的远程心率测量装置,包括以下模块:As shown in Figure 10, a remote heart rate measurement device based on adaptive ROI selection includes the following modules:

获取模块001,用于连续获取受试者头部静止状态下的多帧面部图像;The acquisition module 001 is used to continuously acquire multiple frames of facial images of the subject in a state where the subject's head is still;

分割模块002,用于将每一帧面部图像分割成多个区域;Segmentation module 002, for dividing each frame of face image into a plurality of regions;

计算模块003,用于计算各区域的反射角;Calculation module 003, for calculating the reflection angle of each area;

所述计算模块003,还用于计算每一帧面部图像各区域的信噪比;The calculation module 003 is also used to calculate the signal-to-noise ratio of each region of each frame of facial image;

构建模块004,用于通过每一帧面部图像各区域的反射角、G通道值以及信噪比构建信噪比估计模型;Building block 004, for constructing the signal-to-noise ratio estimation model by the reflection angle, G channel value and signal-to-noise ratio of each region of each frame facial image;

选择模块005,用于根据信噪比估计模型对每一帧面部图像选择ROI;Selection module 005, for selecting ROI for each frame of face image according to the signal-to-noise ratio estimation model;

合成模块006,用于将多帧面部图像的ROI进行信号合成,得到iPPG信号;Synthesis module 006, for carrying out signal synthesis to the ROI of multi-frame face image, obtains iPPG signal;

所述计算模块003,还用于根据iPPG信号计算受试者的心率。The calculation module 003 is also used to calculate the subject's heart rate according to the iPPG signal.

基于但不限于上述装置,所述计算模块003,还用于:Based on but not limited to the above-mentioned device, the calculation module 003 is also used for:

对获取的每一帧面部图像应用MediaPipeFaceMesh来检测受试者面部的468个三维地标;Apply MediaPipeFaceMesh to each frame of facial image acquired to detect 468 3D landmarks on the subject's face;

将面部的三维地标作为计算面部像素的表面法向量和反射角的参考点,将三维地标j处可能的表面法向量集合定义为:Taking the 3D landmark of the face as the reference point to calculate the surface normal vector and reflection angle of the face pixel, the set of possible surface normal vectors at the 3D landmark j is defined as:

Figure BDA0004156394280000101
Figure BDA0004156394280000101

式中,

Figure BDA0004156394280000102
表示从地标j到邻近地标i的矢量,/>
Figure BDA0004156394280000103
表示从地标j到另一邻近地标k的矢量,m是一个正整数,代表用于估计地标j可能的表面法线向量集合Pj的相邻地标的数量;In the formula,
Figure BDA0004156394280000102
represents a vector from landmark j to neighboring landmark i, />
Figure BDA0004156394280000103
Represents the vector from landmark j to another neighboring landmark k, m is a positive integer representing the number of neighboring landmarks used to estimate the possible surface normal vector set Pj of landmark j ;

使用协方差分析法从表面法线向量集合Pj中选择地标j处最具代表性的表面法线

Figure BDA0004156394280000104
The most representative surface normal at landmark j is selected from the set of surface normal vectors Pj using analysis of covariance
Figure BDA0004156394280000104

根据表面法线计算地标j的反射角θjCompute the reflection angle θ j of landmark j from the surface normal:

Figure BDA0004156394280000105
Figure BDA0004156394280000105

其中,

Figure BDA0004156394280000106
是地标j的表面法线,/>
Figure BDA0004156394280000107
是相机轴的单位矢量。in,
Figure BDA0004156394280000106
is the surface normal of landmark j, />
Figure BDA0004156394280000107
is the unit vector of the camera axis.

基于但不限于上述装置,所述分割模块002,具体用于:Based on but not limited to the above devices, the segmentation module 002 is specifically used for:

将受试者的面部图像分三步进行分割:去除眼睛、眉毛和嘴上的地标;去除由面部表情运动引起的地标,包括眼角、嘴唇和鼻子周围;直线连接其余地标,最终分割成N=91个四边形的ROI部分;Segment the subject's facial image in three steps: remove the landmarks on the eyes, eyebrows and mouth; remove the landmarks caused by facial expression movements, including the corners of the eyes, lips and around the nose; connect the remaining landmarks with straight lines, and finally segment into N= 91 quadrilateral ROI sections;

分割后的区域的反射角θm通过以下方式给出:The reflection angle θm of the segmented region is given by:

Figure BDA0004156394280000108
Figure BDA0004156394280000108

其中,m是N个分割区域的序号,θm,n是第n个区域的四个顶点的法向角,每个区域的反射角用灰度表示。Among them, m is the sequence number of the N segmented regions, θ m, n are the normal angles of the four vertices of the nth region, and the reflection angle of each region is represented by gray scale.

基于但不限于上述装置,所述构建模块004,具体用于:Based on but not limited to the above-mentioned device, the building block 004 is specifically used for:

对于采集到的每一帧面部图像,分别记录N个区域平均的G通道值GN与平均的反射角度值θN,再记录当前面部图像的帧数t∈{1,…,T*FPS},将记录的数据信息存放在一个N×t×2的矩阵中,其中T为采集视频的秒数,FPS为相机采集的帧率;For each frame of facial image collected , record the average G channel value G N and the average reflection angle value θ N of N regions, and then record the frame number t∈{1,...,T*FPS} of the current facial image , store the recorded data information in an N×t×2 matrix, where T is the number of seconds of video capture, and FPS is the frame rate of camera capture;

将预设时间窗口内的平均的G通道值、平均的反射角度值与信噪比记录为一组数据;Record the average G channel value, average reflection angle value and signal-to-noise ratio within the preset time window as a set of data;

对平均的G通道值、平均的反射角度值两个影响因素单独进行集中趋势检验,去除数据中的离群点;The two influencing factors of the average G channel value and the average reflection angle value are separately tested for central tendency to remove outliers in the data;

将去除离群点后的数据进行非线性曲线拟合,获取输入量为反射角与G通道值,输出量为信噪比的信噪比估计模型。Non-linear curve fitting is performed on the data after removing outliers, and the signal-to-noise ratio estimation model whose input is the reflection angle and G channel value and the output is the signal-to-noise ratio is obtained.

基于但不限于上述装置,所述选择模块005,具体用于:Based on but not limited to the above devices, the selection module 005 is specifically used for:

根据相机频率与人体心率计算出能够计算出人体心率的最小帧数;Calculate the minimum number of frames that can calculate the human heart rate according to the camera frequency and the human heart rate;

当信噪比模型估计的信噪比最高区域连续出现的次数大于等于最小帧数时,进行ROI的选取。When the number of consecutive occurrences of the highest SNR area estimated by the SNR model is greater than or equal to the minimum number of frames, ROI selection is performed.

如图11所示,示例了一种电子设备的实体结构示意图,该电子设备可以包括:处理器(processor)610、通信接口(Communications Interface)620、存储器(memory)630和通信总线640,其中,处理器610、通信接口620、存储器630通过通信总线640完成相互间的通信。处理器610可以调用存储器630中的逻辑指令,以执行远程心率测量方法的步骤,具体包括:连续获取受试者头部静止状态下的多帧面部图像;将每一帧面部图像分割成多个区域,并计算各区域的反射角;计算每一帧面部图像各区域的信噪比;通过每一帧面部图像各区域的反射角、G通道值以及信噪比构建信噪比估计模型;根据信噪比估计模型对每一帧面部图像选择ROI;将多帧面部图像的ROI进行信号合成,得到iPPG信号;根据iPPG信号计算受试者的心率。As shown in FIG. 11 , a schematic diagram of the physical structure of an electronic device is illustrated, and the electronic device may include: a processor (processor) 610, a communication interface (Communications Interface) 620, a memory (memory) 630, and a communication bus 640, wherein, The processor 610 , the communication interface 620 , and the memory 630 communicate with each other through the communication bus 640 . The processor 610 can call the logic instructions in the memory 630 to execute the steps of the remote heart rate measurement method, which specifically includes: continuously acquiring multiple frames of facial images in a still state of the subject's head; dividing each frame of facial images into multiple region, and calculate the reflection angle of each region; calculate the signal-to-noise ratio of each region of each frame of facial image; construct the signal-to-noise ratio estimation model by the reflection angle, G channel value and signal-to-noise ratio of each region of each frame of facial image; The signal-to-noise ratio estimation model selects the ROI for each frame of facial images; combines the ROIs of multiple frames of facial images to obtain iPPG signals; calculates the subject's heart rate according to the iPPG signals.

此外,上述的存储器630中的逻辑指令可以通过软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储介质中。基于这样的理解,本发明的技术方案本质上或者说对现有技术做出贡献的部分或者该技术方案的部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质中,包括若干指令用以使得一台计算机设备(可以是个人计算机,服务器,或者网络设备等)执行本发明各个实施例所述方法的全部或部分步骤。而前述的存储介质包括:U盘、移动硬盘、只读存储器(ROM,Read-Only Memory)、随机存取存储器(RAM,Random15 Access Memory)、磁碟或者光盘等各种可以存储程序代码的介质。In addition, the logic instructions in the above-mentioned memory 630 may be implemented in the form of software functional units and when sold or used as an independent product, may be stored in a computer-readable storage medium. Based on this understanding, the essence of the technical solution of the present invention or the part that contributes to the prior art or the part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including Several instructions are used to make a computer device (which may be a personal computer, a server, or a network device, etc.) execute all or part of the steps of the methods described in various embodiments of the present invention. And aforementioned storage medium comprises: U disk, removable hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random15 Access Memory), magnetic disk or optical disk etc. various mediums that can store program codes .

又一方面,本发明实施例还提供了一种存储介质,其上存储有计算机程序,该计算机程序被处理器执行时实现上述远程心率测量方法的步骤,具体包括:连续获取受试者头部静止状态下的多帧面部图像;将每一帧面部图像分割成多个区域,并计算各区域的反射角;计算每一帧面部图像各区域的信噪比;通过每一帧面部图像各区域的反射角、G通道值以及信噪比构建信噪比估计模型;根据信噪比估计模型对每一帧面部图像选择ROI;将多帧面部图像的ROI进行信号合成,得到iPPG信号;根据iPPG信号计算受试者的心率。In yet another aspect, the embodiment of the present invention also provides a storage medium, on which a computer program is stored, and when the computer program is executed by a processor, the steps of the above-mentioned remote heart rate measurement method are implemented, specifically including: continuously acquiring the subject's head Multi-frame facial images in a static state; divide each frame of facial images into multiple regions, and calculate the reflection angle of each region; calculate the signal-to-noise ratio of each region of each frame of facial images; pass each frame of facial images through each region The reflection angle, G channel value and signal-to-noise ratio construct the signal-to-noise ratio estimation model; select the ROI for each frame of facial image according to the signal-to-noise ratio estimation model; perform signal synthesis on the ROI of multiple frames of facial images to obtain the iPPG signal; according to the iPPG The signal calculates the subject's heart rate.

本发明通过实施上述的基于自适应ROI选择的远程心率测量方法、装置及设备,以及对应的存储介质,可以找出一帧图像中最适合进行iPPG心率提取的区域作为ROI,对多帧图像进行信号合成得到iPPG信号,对iPPG信号使用傅里叶变换进行频域分析,选取幅值最大的点所对应的频率即为心跳频率。该方法主要解决的是面部运动造成目标区域跟踪丢失的情况,该方法为iPPG技术人脸面部ROI区域的动态识别提供了一个新的思路。实验结果如图12所示,图12表明,在考虑到面部运动和光照明暗变化的情况下,在处理前后使用本发明的方法,可以将信噪比SNR(信噪比)提高0.3152db,PET6(误差心率的绝对值小于等于6)提高0.5651%。In the present invention, by implementing the above-mentioned remote heart rate measurement method, device and equipment based on adaptive ROI selection, and the corresponding storage medium, it is possible to find out the most suitable area for iPPG heart rate extraction in a frame of image as the ROI, and perform multi-frame images. The iPPG signal is obtained by signal synthesis, and the iPPG signal is analyzed in the frequency domain using Fourier transform, and the frequency corresponding to the point with the largest amplitude is selected as the heartbeat frequency. This method mainly solves the situation that the tracking of the target area is lost due to facial movement, and this method provides a new idea for the dynamic recognition of the ROI area of the face with iPPG technology. The experimental results are shown in Figure 12, and Figure 12 shows that, in consideration of facial movement and light and dark changes, using the method of the present invention before and after processing can improve the signal-to-noise ratio SNR (signal-to-noise ratio) by 0.3152db, PET6 (The absolute value of the heart rate error is less than or equal to 6) increased by 0.5651%.

需要说明的是,在本文中,术语“包括”、“包含”或者其任何其他变体意在涵盖非排他性的包含,从而使得包括一系列要素的过程、方法、物品或者系统不仅包括那些要素,而且还包括没有明确列出的其他要素,或者是还包括为这种过程、方法、物品或者系统所固有的要素。在没有更多限制的情况下,由语句“包括一个……”限定的要素,并不排除在包括该要素的过程、方法、物品或者系统中还存在另外的相同要素。It should be noted that, as used herein, the term "comprises", "comprises" or any other variation thereof is intended to cover a non-exclusive inclusion such that a process, method, article or system comprising a set of elements includes not only those elements, It also includes other elements not expressly listed, or elements inherent in the process, method, article, or system. Without further limitations, an element defined by the phrase "comprising a..." does not preclude the presence of additional identical elements in the process, method, article or system comprising that element.

上述本发明实施例序号仅仅为了描述,不代表实施例的优劣。在列举了若干装置的单元权利要求中,这些装置中的若干个可以是通过同一个硬件项来具体体现。词语第一、第二、以及第三等的使用不表示任何顺序,可将这些词语解释为标识。The serial numbers of the above embodiments of the present invention are for description only, and do not represent the advantages and disadvantages of the embodiments. In a unit claim enumerating several means, several of these means can be embodied by one and the same item of hardware. The use of the words first, second, and third etc. does not indicate any order and these words may be construed as designations.

以上仅为本发明的优选实施例,并非因此限制本发明的专利范围,凡是利用本发明说明书及附图内容所作的等效结构或等效流程变换,或直接或间接运用在其他相关的技术领域,均同理包括在本发明的专利保护范围内。The above are only preferred embodiments of the present invention, and are not intended to limit the patent scope of the present invention. Any equivalent structure or equivalent process conversion made by using the description of the present invention and the contents of the accompanying drawings, or directly or indirectly used in other related technical fields , are all included in the scope of patent protection of the present invention in the same way.

Claims (10)

1. A remote heart rate measurement method based on adaptive ROI selection, comprising the steps of:
continuously acquiring multi-frame facial images of a subject in a head static state;
dividing each frame face image into a plurality of areas, and calculating reflection angles of the areas;
calculating the signal-to-noise ratio of each region of each frame face image;
constructing a signal-to-noise ratio estimation model through the reflection angle, the G channel value and the signal-to-noise ratio of each region of each frame surface image;
selecting the ROI for each frame of facial image according to the signal-to-noise ratio estimation model;
performing signal synthesis on the ROI of the multi-frame facial image to obtain an iPG signal;
the heart rate of the subject was calculated from the iPPG signal.
2. The method of claim 1, wherein before the step of dividing each frame image into a plurality of regions and calculating the reflection angle of each region, further comprising:
applying MediaPipe FaceMesh to each acquired frame of facial images to detect 468 three-dimensional landmarks of the subject's face;
taking a three-dimensional landmark of a face as a reference point for calculating a surface normal vector and a reflection angle of a face pixel, and defining a set of possible surface normal vectors at the three-dimensional landmark j as:
Figure FDA0004156394270000011
in the method, in the process of the invention,
Figure FDA0004156394270000012
represents a vector from landmark j to adjacent landmark i, ">
Figure FDA0004156394270000013
Representing a vector from landmark j to another adjacent landmark k, m being a positive integer representing a set of possible surface normal vectors P for estimating landmark j j Is a number of adjacent landmarks;
from a set of surface normal vectors P using covariance analysis j Is the most representative surface normal at the selected landmark j
Figure FDA0004156394270000014
Calculating the reflection angle θ of landmark j from the surface normal j
Figure FDA0004156394270000015
Wherein,,
Figure FDA0004156394270000016
is the surface normal of landmark j, +.>
Figure FDA0004156394270000017
Is the unit vector of the camera axis.
3. The method of claim 2, wherein the step of dividing each frame image into a plurality of regions and calculating the reflection angle of each region comprises,
dividing the facial image of the subject into three steps of segmentation into N quadrilateral ROI parts;
reflection angle θ of the divided region m The method is given by the following steps:
Figure FDA0004156394270000021
where m is the number of N divided regions, θ m,n Is the normal angle of the four vertices of the nth region, and the reflection angle of each region is represented in gray scale.
4. A remote heart rate measurement method according to claim 3, wherein the step of dividing the facial image of the subject in three steps comprises:
removing landmarks on the eyes, eyebrows, and mouth;
removing landmarks caused by facial expression movements, including corners of the eyes, lips, and surrounding the nose;
the straight line connects the remaining landmarks.
5. The method according to claim 1, wherein the step of constructing a signal-to-noise ratio estimation model from the reflection angle, the G-channel value, and the signal-to-noise ratio of each region of each frame image comprises:
for each acquired frame image, recording average G channel values G of N areas N And the average reflection angle value theta N The number of frames T e {1,..once again, T x FPS } of the current face image is recorded, the recorded data information is stored in an N x T x 2 matrix, wherein T is the number of seconds of video acquisition, and FPS is the frame rate of camera acquisition;
recording an average G channel value, an average reflection angle value and a signal to noise ratio in a preset time window as a group of data;
carrying out concentration trend test on two influence factors of the average G channel value and the average reflection angle value independently, and removing outliers in the data;
and performing nonlinear curve fitting on the data with the outliers removed, and obtaining a signal-to-noise ratio estimation model with the input quantity being the reflection angle and the G channel value and the output quantity being the signal-to-noise ratio.
6. The method of claim 1, wherein the step of selecting an ROI for each frame image based on a signal-to-noise ratio estimation model comprises:
calculating the minimum frame number capable of calculating the heart rate of the human body according to the frequency of the camera and the heart rate of the human body;
and when the number of times of continuous occurrence of the signal-to-noise ratio highest region estimated by the signal-to-noise ratio model is larger than or equal to the minimum frame number, selecting the ROI.
7. A remote heart rate measurement method according to claim 3 or 5, characterized in that the number of zones N = 91.
8. A remote heart rate measurement device based on adaptive ROI selection, comprising the following modules:
the acquisition module is used for continuously acquiring a plurality of frames of facial images of the head of the subject in a static state;
a segmentation module for segmenting each frame face image into a plurality of areas;
the calculation module is used for calculating the reflection angle of each region;
the calculating module is also used for calculating the signal-to-noise ratio of each region of each frame face image;
the construction module is used for constructing a signal-to-noise ratio estimation model through the reflection angle, the G channel value and the signal-to-noise ratio of each region of each frame of the image;
the selection module is used for selecting the ROI for each frame of the facial image according to the signal-to-noise ratio estimation model;
the synthesis module is used for carrying out signal synthesis on the ROI of the multi-frame facial image to obtain an iPG signal;
the calculation module is also used for calculating the heart rate of the subject according to the iPG signal.
9. An electronic device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, wherein the processor implements the steps of the remote heart rate measurement method of any one of claims 1-7 when the program is executed.
10. A storage medium having stored thereon a computer program which, when executed by a processor, implements the steps of the remote heart rate measurement method as claimed in any one of claims 1 to 7.
CN202310335761.1A 2023-03-28 2023-03-28 Remote heart rate measurement method, device and equipment based on adaptive ROI selection Pending CN116327155A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310335761.1A CN116327155A (en) 2023-03-28 2023-03-28 Remote heart rate measurement method, device and equipment based on adaptive ROI selection

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310335761.1A CN116327155A (en) 2023-03-28 2023-03-28 Remote heart rate measurement method, device and equipment based on adaptive ROI selection

Publications (1)

Publication Number Publication Date
CN116327155A true CN116327155A (en) 2023-06-27

Family

ID=86892811

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202310335761.1A Pending CN116327155A (en) 2023-03-28 2023-03-28 Remote heart rate measurement method, device and equipment based on adaptive ROI selection

Country Status (1)

Country Link
CN (1) CN116327155A (en)

Similar Documents

Publication Publication Date Title
Bobbia et al. Unsupervised skin tissue segmentation for remote photoplethysmography
CN107529646B (en) Non-contact heart rate measurement method and device based on Euler image amplification
McDuff et al. Remote detection of photoplethysmographic systolic and diastolic peaks using a digital camera
Sikdar et al. Computer-vision-guided human pulse rate estimation: a review
Gudi et al. Efficient real-time camera based estimation of heart rate and its variability
Alnaggar et al. Video-based real-time monitoring for heart rate and respiration rate
CN111938622B (en) Heart rate detection method, device and system and readable storage medium
JP6717424B2 (en) Heart rate estimation device
JP6957929B2 (en) Pulse wave detector, pulse wave detection method, and program
Bobbia et al. Remote photoplethysmography based on implicit living skin tissue segmentation
US20210186346A1 (en) Information processing device, non-transitory computer-readable medium, and information processing method
Qiao et al. Revise: Remote vital signs measurement using smartphone camera
Fiedler et al. Fusion-based approach for respiratory rate recognition from facial video images
Moya-Albor et al. A non-contact heart rate estimation method using video magnification and neural networks
Cho et al. Reduction of motion artifacts from remote photoplethysmography using adaptive noise cancellation and modified HSI model
Gao et al. Region of interest analysis using delaunay triangulation for facial video-based heart rate estimation
Benezeth et al. Probabilistic signal quality metric for reduced complexity unsupervised remote photoplethysmography
Arppana et al. Real time heart beat monitoring using computer vision
Suriani et al. Non-contact facial based vital sign estimation using convolutional neural network approach
Ben Salah et al. Contactless heart rate estimation from facial video using skin detection and multi-resolution analysis
US20240041334A1 (en) Systems and methods for measuring physiologic vital signs and biomarkers using optical data
Karmuse et al. A robust rppg approach for continuous heart rate measurement based on face
Nagamatsu et al. PPG3D: Does 3D head tracking improve camera-based PPG estimation?
Cheng et al. Motion-robust anterior–posterior imaging ballistocardiography for non-contact heart rate measurements
CN116327155A (en) Remote heart rate measurement method, device and equipment based on adaptive ROI selection

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