[go: up one dir, main page]

CN115581459B - LevKov-based multichannel fixed frequency noise filtering method, computer equipment and program product - Google Patents

LevKov-based multichannel fixed frequency noise filtering method, computer equipment and program product Download PDF

Info

Publication number
CN115581459B
CN115581459B CN202211313034.7A CN202211313034A CN115581459B CN 115581459 B CN115581459 B CN 115581459B CN 202211313034 A CN202211313034 A CN 202211313034A CN 115581459 B CN115581459 B CN 115581459B
Authority
CN
China
Prior art keywords
data
noise
point
filtering
frequency noise
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.)
Active
Application number
CN202211313034.7A
Other languages
Chinese (zh)
Other versions
CN115581459A (en
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.)
Hangzhou Nuochi Life Science Co ltd
Original Assignee
Hangzhou Nuochi Life Science Co ltd
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 Hangzhou Nuochi Life Science Co ltd filed Critical Hangzhou Nuochi Life Science Co ltd
Priority to CN202211313034.7A priority Critical patent/CN115581459B/en
Publication of CN115581459A publication Critical patent/CN115581459A/en
Application granted granted Critical
Publication of CN115581459B publication Critical patent/CN115581459B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • AHUMAN NECESSITIES
    • A61MEDICAL OR VETERINARY SCIENCE; HYGIENE
    • A61BDIAGNOSIS; SURGERY; IDENTIFICATION
    • A61B5/00Measuring for diagnostic purposes; Identification of persons
    • A61B5/24Detecting, measuring or recording bioelectric or biomagnetic signals of the body or parts thereof
    • A61B5/242Detecting biomagnetic fields, e.g. magnetic fields produced by bioelectric currents
    • A61B5/243Detecting biomagnetic fields, e.g. magnetic fields produced by bioelectric currents specially adapted for magnetocardiographic [MCG] signals
    • AHUMAN NECESSITIES
    • A61MEDICAL OR VETERINARY SCIENCE; HYGIENE
    • A61BDIAGNOSIS; SURGERY; IDENTIFICATION
    • A61B5/00Measuring for diagnostic purposes; Identification of persons
    • A61B5/72Signal processing specially adapted for physiological signals or for diagnostic purposes
    • A61B5/7203Signal processing specially adapted for physiological signals or for diagnostic purposes for noise prevention, reduction or removal
    • AHUMAN NECESSITIES
    • A61MEDICAL OR VETERINARY SCIENCE; HYGIENE
    • A61BDIAGNOSIS; SURGERY; IDENTIFICATION
    • A61B5/00Measuring for diagnostic purposes; Identification of persons
    • A61B5/72Signal processing specially adapted for physiological signals or for diagnostic purposes
    • A61B5/7225Details of analogue 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)
  • Signal Processing (AREA)
  • Molecular Biology (AREA)
  • Animal Behavior & Ethology (AREA)
  • Veterinary Medicine (AREA)
  • Public Health (AREA)
  • Physics & Mathematics (AREA)
  • General Health & Medical Sciences (AREA)
  • Biophysics (AREA)
  • Pathology (AREA)
  • Biomedical Technology (AREA)
  • Heart & Thoracic Surgery (AREA)
  • Medical Informatics (AREA)
  • Surgery (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Artificial Intelligence (AREA)
  • Psychiatry (AREA)
  • Physiology (AREA)
  • Power Engineering (AREA)
  • Cardiology (AREA)
  • Measurement And Recording Of Electrical Phenomena And Electrical Characteristics Of The Living Body (AREA)

Abstract

The application discloses a LevKov-based multichannel fixed frequency noise filtering method, a computer device and a program product, wherein the LevKov-based multichannel fixed frequency noise filtering method comprises the following steps: obtaining a plurality of magnetocardiogram waveform data by using the multichannel leads; obtaining a peak point in a nonlinear region predicted in the magnetocardiogram waveform data; dividing the nonlinear region and the linear region, comprising: shifting the peak point by a specified threshold value along the front and back of the time axis to obtain two starting points, taking the connecting line between each starting point and the peak point as a reference line, traversing the data points between the peak point and each starting point, taking the data points with the peak point on two sides of the time axis and the maximum distance from the reference line on the corresponding side as end points, wherein a nonlinear region is arranged between the two end points, and the rest is a linear region; and filtering fixed frequency noise from the linear region and the nonlinear region of each magnetocardiogram waveform data one by one until all magnetocardiogram waveform data are processed.

Description

基于LevKov的多通道固定频率噪声滤除方法、计算机设备和 程序产品Multi-channel fixed frequency noise filtering method based on LevKov, computer equipment and program product

技术领域Technical Field

本申请涉及生物医学信号处理领域,特别是涉及一种基于LevKov的多通道固定频率噪声滤除方法、计算机设备和程序产品。The present application relates to the field of biomedical signal processing, and in particular to a multi-channel fixed-frequency noise filtering method based on LevKov, a computer device and a program product.

背景技术Background Art

目前临床上对于心脏疾病的检测手段种类繁多,包括冠状动脉造影、心内电生理等有创性检查和心电图、冠状动脉CT等各类无创性检查等。但是这些检测技术均有不足之处,比如有创伤性、对人体有放射辐射伤害,或费用较高等,因此在临床上的应用受到一定限制。At present, there are many clinical detection methods for heart diseases, including invasive tests such as coronary angiography and intracardiac electrophysiology, and non-invasive tests such as electrocardiogram and coronary artery CT. However, these detection technologies have shortcomings, such as being traumatic, causing radiation damage to the human body, or being expensive, so their clinical application is subject to certain restrictions.

常用的心电检查无创简便,但是存在灵敏度和准确度低等缺陷。心磁图(magnetocardiography,MCG)作为一种无创性、准确度较高的检测技术,近年来成为研究的热点。心脏活动产生微弱电流,这些微弱电流周围产生微弱的磁场,心磁图就是一种通过采集分析心脏兴奋时引起周围磁场变化的检测手段。Commonly used electrocardiograms are non-invasive and simple, but they have defects such as low sensitivity and accuracy. Magnetocardiography (MCG), as a non-invasive and highly accurate detection technology, has become a research hotspot in recent years. Cardiac activity generates weak currents, which generate weak magnetic fields around them. Magnetocardiography is a detection method that collects and analyzes the changes in the surrounding magnetic field caused by cardiac excitement.

1963年Baule和McFee首次在常温下非屏蔽的室内利用线圈式磁量计检测到心脏产生的磁场信号。1970年Cohen等发明了超导量子干涉仪(superconducting quantuminterference device,SQUID),为MCG的发展带来了革命性突破。SQUID传感器是利用低温超导技术。在低温零下269。C使金属铌的电阻变为零而成为超导体。将超导体做成超导环并把超导环对应部位做成两个极薄的绝缘层(Josephson结点),当偏置电流通过时,超导状态破坏并产生Josephson效应及信号,经振荡器取出及放大等处理后获得明显的磁场信息。In 1963, Baule and McFee first detected the magnetic field signal generated by the heart using a coil magnetometer in an unshielded room at room temperature. In 1970, Cohen and others invented the superconducting quantum interference device (SQUID), which brought a revolutionary breakthrough to the development of MCG. The SQUID sensor uses low-temperature superconducting technology. At a low temperature of minus 269. C, the resistance of metal niobium becomes zero and becomes a superconductor. The superconductor is made into a superconducting ring and the corresponding parts of the superconducting ring are made into two extremely thin insulating layers (Josephson nodes). When the bias current passes through, the superconducting state is destroyed and the Josephson effect and signal are generated. After being taken out by the oscillator and amplified, obvious magnetic field information is obtained.

心磁测量仪器近年来已获很大发展。从单通道发展到多通道,从单点测量到多点测量,还具有检测三维信号并实现心脏三维重构的功能。基于原子磁强计的心磁仪不受低温环境工作的条件限制,具有更高的灵敏度,可使其进一步小型化并降低成本,扩展了其应用范围。Magnetocardiographic instruments have made great progress in recent years. They have evolved from single-channel to multi-channel, from single-point measurement to multi-point measurement, and also have the function of detecting three-dimensional signals and realizing three-dimensional reconstruction of the heart. Magnetocardiographic instruments based on atomic magnetometers are not restricted by the conditions of working in low-temperature environments, have higher sensitivity, can be further miniaturized and cost-effective, and expand their scope of application.

然而心磁仪的高敏感性和高精确度导致其极易受到外界噪声的干扰,加之医院内环境嘈杂,各种设备开启经常会产生某些固定频率的噪声。当固定频率噪声与心磁信号有效频段有交集时,传统陷波器会滤除心磁数据中与噪声频段有重叠的部分,使QRS波产生变形;LevKov算法能有效保留QRS波中与噪声频段有重叠的部分的信号,但其只用于去除工频干扰这种频率较高的干扰,当信噪比特别差时,对于噪声模板范围的确定比较困难,无法准确的得到模板区域时;当去除噪声的频率较低时,不符合其模板区域呈线性的假设,滤波效果较差。However, the high sensitivity and high precision of the magnetocardiometer make it very susceptible to interference from external noise. In addition, the hospital environment is noisy, and various devices often generate certain fixed-frequency noise when turned on. When the fixed-frequency noise intersects with the effective frequency band of the magnetocardiogram signal, the traditional notch filter will filter out the part of the magnetocardiogram data that overlaps with the noise frequency band, causing the QRS wave to deform; the LevKov algorithm can effectively retain the signal of the part of the QRS wave that overlaps with the noise frequency band, but it is only used to remove high-frequency interference such as power frequency interference. When the signal-to-noise ratio is particularly poor, it is difficult to determine the noise template range and the template area cannot be accurately obtained; when the frequency of noise removal is low, it does not meet the assumption that its template area is linear, and the filtering effect is poor.

发明内容Summary of the invention

基于此,有必要针对上述技术问题,提供一种基于LEVKOV的多通道固定频率噪声滤除方法。Based on this, it is necessary to provide a multi-channel fixed-frequency noise filtering method based on LEVKOV to address the above technical problems.

本申请基于LEVKOV的多通道固定频率噪声滤除方法,包括:This application is based on LEVKOV's multi-channel fixed-frequency noise filtering method, including:

利用多通道导联获得多个心磁图波形数据;Using multi-channel leads to obtain multiple magnetocardiogram waveform data;

在所述心磁图波形数据中预判的非线性区域获得波峰点;Obtaining a peak point in a predicted nonlinear region in the magnetocardiogram waveform data;

划分非线性区域和线性区域,包括:将波峰点沿时间轴前后分别偏移指定阈值,得到两个起始点,各起始点与波峰点之间的连线作为参考线,遍历波峰点与各起始点之间的数据点,将波峰点在时间轴两侧且与相应侧参考线距离最大的数据点分别作为端点,两端点之间为非线性区域,其余为线性区域;The nonlinear region and the linear region are divided, including: offsetting the peak point forward and backward along the time axis by a specified threshold value to obtain two starting points, using the line between each starting point and the peak point as a reference line, traversing the data points between the peak point and each starting point, using the data points where the peak point is on both sides of the time axis and has the largest distance from the corresponding side reference line as endpoints, the area between the two end points is the nonlinear area, and the rest is the linear area;

逐一对各心磁图波形数据的线性区域、以及非线性区域进行固定频率噪声滤除,直至处理完所有的心磁图波形数据。Fixed frequency noise is filtered out in the linear region and the nonlinear region of each magnetocardiogram waveform data one by one until all magnetocardiogram waveform data are processed.

可选的,将波峰点沿时间轴前后分别偏移时,分别对应第一指定阈值和第二指定阈值,所述心磁图波形数据中包括连续的心拍信号,所述第一指定阈值和第二指定阈值之和大于心拍信号中QRS波的宽度。Optionally, when the peak point is offset forward and backward along the time axis, it corresponds to a first specified threshold and a second specified threshold respectively, the magnetocardiogram waveform data includes a continuous heartbeat signal, and the sum of the first specified threshold and the second specified threshold is greater than the width of the QRS wave in the heartbeat signal.

可选的,获得心磁图波形数据的波峰点,具体包括:Optionally, obtaining the peak point of the magnetocardiogram waveform data specifically includes:

获得波峰定位阈值,所述波峰定位阈值小于所述心磁图波形数据中各波峰的平均值;Obtaining a peak location threshold, wherein the peak location threshold is less than an average value of each peak in the magnetocardiogram waveform data;

根据与所述波峰定位阈值的相对关系,确定所述波峰点。The peak point is determined according to the relative relationship with the peak location threshold.

可选的,所述波峰定位阈值通过公式:Optionally, the peak location threshold is calculated by the formula:

获得,式中心磁图波形数据中包括多个统计周期,SecMax为所有统计周期最大值排序后的序列,a为小于1的阈值生成系数,n1为序列SecMax中选择的起始数据,n2为SecMax中选择的末尾数据。 The obtained formula is that the central magnetic image waveform data includes multiple statistical cycles, SecMax is a sequence after the maximum values of all statistical cycles are sorted, a is a threshold generation coefficient less than 1, n1 is the starting data selected in the sequence SecMax, and n2 is the ending data selected in SecMax.

可选的,针对线性区域进行固定频率噪声滤除时,包括:Optional, fixed frequency noise filtering for linear region, including:

针对其中一待处理的数据点,利用预定时间内的缓存数据对该数据点进行滤波;所述缓存数据是从待处理的心磁图波形数据中获得且长度为M,M=FS/FREnoise,其中FS为采样率,FREnoise为固定频率噪声的频率;For one of the data points to be processed, the data point is filtered using the buffered data within a predetermined time; the buffered data is obtained from the magnetocardiogram waveform data to be processed and has a length of M, where M=FS/FRE noise , where FS is the sampling rate and FRE noise is the frequency of the fixed frequency noise;

待处理的数据点为所述缓存数据后一时刻对应的数据点;The data point to be processed is the data point corresponding to the next moment of the cached data;

对该数据点进行滤波后得到第一数据datafilterAfter filtering the data point, the first data data filter is obtained:

Cachen为所述缓存数据;Cache n is the cache data;

datum为待处理的数据点。datum is the data point to be processed.

可选的,还包括利用所述缓存数据中位数位置的数据、与所述第一数据做差值,得到噪声数据,所述噪声数据的集合为噪声模板;Optionally, it also includes using the data at the median position of the cached data to make a difference with the first data to obtain noise data, and the set of the noise data is a noise template;

所述缓存数据和所述噪声模板均实时更新:The cache data and the noise template are updated in real time:

所述缓存数据的实时更新为利用所述缓存数据后一时刻对应的数据点置入所述缓存数据,并去除时间轴最早的数据点;The real-time updating of the cached data is to use the data point corresponding to the next moment of the cached data to be placed into the cached data, and remove the earliest data point on the time axis;

所述噪声模板的实时更新为将最新的噪声数据置入噪声模板中,并去除时间轴最早的数据点。The real-time updating of the noise template is to place the latest noise data into the noise template and remove the earliest data point on the time axis.

可选的,针对非线性区域进行固定频率噪声滤除时,具体包括:Optionally, when fixed frequency noise is filtered out in a nonlinear region, the following steps are specifically included:

将所述缓存数据中位数位置的数据点,与所述噪声模板中最老的噪声数据相减得到当前滤波数据;Subtracting the data point at the median position of the cached data from the oldest noise data in the noise template to obtain current filtered data;

所述缓存数据和所述噪声模板均实时更新:The cache data and the noise template are updated in real time:

所述缓存数据的实时更新为利用所述缓存数据后一时刻对应的数据点置入所述缓存数据,并去除时间轴最早的数据点;The real-time updating of the cached data is to use the data point corresponding to the next moment of the cached data to be placed into the cached data, and remove the earliest data point on the time axis;

所述噪声模板的实时更新为将最老的噪声数据置入噪声模板,并去除最老的噪声数据。The real-time updating of the noise template is to put the oldest noise data into the noise template and remove the oldest noise data.

可选的,针对非线性区域进行固定频率噪声滤除时,所述非线性区域后毗邻的数据长度为M的线性区域,按照非线性区域的滤波方式进行滤波。Optionally, when fixed-frequency noise is filtered out for a nonlinear region, a linear region with a data length of M adjacent to the nonlinear region is filtered in accordance with the filtering method of the nonlinear region.

本申请还提供一种计算机设备,包括存储器、处理器及存储在存储器上的计算机程序,所述处理器执行所述计算机程序以实现本申请所述的基于LEVKOV多通道固定频率噪声滤除方法的步骤。The present application also provides a computer device, including a memory, a processor, and a computer program stored in the memory, wherein the processor executes the computer program to implement the steps of the LEVKOV multi-channel fixed frequency noise filtering method described in the present application.

本申请还提供一种计算机程序产品,包括计算机指令,该计算机指令被处理器执行时实现本申请所述的基于LEVKOV多通道固定频率噪声滤除方法的步骤。The present application also provides a computer program product, including computer instructions, which, when executed by a processor, implement the steps of the LEVKOV multi-channel fixed frequency noise filtering method described in the present application.

本申请基于LEVKOV的多通道固定频率噪声滤除方法至少具有以下效果:The multi-channel fixed frequency noise filtering method based on LEVKOV in this application has at least the following effects:

本申请心磁图波形数据中获得的波峰点用于划分非线性区域和线性区域,由于用于划分的波峰点来自于心磁图波形数据,本申请能够针对不同的噪声环境自适应地、有针对性地完成对获得心磁图波形数据的划分。The peak points obtained in the magnetocardiogram waveform data of the present application are used to divide the nonlinear area and the linear area. Since the peak points used for division come from the magnetocardiogram waveform data, the present application can adaptively and specifically complete the division of the obtained magnetocardiogram waveform data according to different noise environments.

本申请在划分非线性区域和线性区域时,通过确认非线性区域的两个端点完成。在此基础上,基于划分结果对各心磁图波形数据的线性区域、以及非线性区域,逐一对各心磁图波形数据分别进行固定频率噪声滤除,从而提高滤波效果。The present application divides the nonlinear region and the linear region by confirming the two endpoints of the nonlinear region. On this basis, based on the division result, the linear region and the nonlinear region of each magnetocardiogram waveform data are respectively subjected to fixed frequency noise filtering, thereby improving the filtering effect.

附图说明BRIEF DESCRIPTION OF THE DRAWINGS

图1为本申请一实施例中基于LEVKOV的多通道固定频率噪声滤除方法的流程示意图;FIG1 is a schematic flow chart of a multi-channel fixed frequency noise filtering method based on LEVKOV in one embodiment of the present application;

图2为图1中步骤S200子步骤的流程示意图;FIG. 2 is a schematic diagram of the process of sub-steps of step S200 in FIG. 1 ;

图3为图1中步骤S400子步骤的流程示意图;FIG3 is a schematic diagram of the process of sub-steps of step S400 in FIG1 ;

图4为图1中步骤S400子步骤的流程示意图;FIG4 is a schematic diagram of the process of sub-steps of step S400 in FIG1 ;

图5为本申请一实施例中基于LEVKOV的多通道固定频率噪声滤除方法的流程框图;FIG5 is a flowchart of a multi-channel fixed frequency noise filtering method based on LEVKOV in one embodiment of the present application;

图6为一个实施例中计算机设备的内部结构图;FIG6 is a diagram showing the internal structure of a computer device in one embodiment;

图7本申请一实施例中提供的心磁图原始时域数据;FIG. 7 is original time domain data of magnetocardiogram provided in an embodiment of the present application;

图8为图7中叠加25Hz噪声后的时域数据;FIG8 is the time domain data after superimposing 25 Hz noise in FIG7;

图9为切比雪夫25Hz带阻滤波器针对图7滤波后的时域数据;FIG9 is the time domain data of FIG7 after filtering by Chebyshev 25Hz band-stop filter;

图10为整系数25Hz陷波器针对图7滤波后的时域数据;FIG10 is the time domain data of FIG7 after filtering by an integral coefficient 25 Hz notch filter;

图11为利用本申请基于LEVKOV的多通道固定频率噪声滤除方法针对图7滤波后时域数据;FIG11 is the time domain data after filtering of FIG7 using the multi-channel fixed frequency noise filtering method based on LEVKOV of the present application;

图12为本申请一实施例中提供的心磁图原始频域数据;FIG12 is the original frequency domain data of the magnetocardiogram provided in one embodiment of the present application;

图13为图12叠加25Hz噪声后的频域数据;FIG13 is the frequency domain data of FIG12 after superimposing 25 Hz noise;

图14为切比雪夫25Hz带阻滤波器针对图12滤波后的频域数据;FIG14 is the frequency domain data of FIG12 after filtering by Chebyshev 25 Hz band-stop filter;

图15为整系数25Hz陷波器针对图12滤波后的频域数据;FIG15 is the frequency domain data of FIG12 after filtering by an integral coefficient 25 Hz notch filter;

图16利用本申请基于LEVKOV的多通道固定频率噪声滤除方法针对图12滤波后的频域数据。FIG. 16 is the frequency domain data after filtering in FIG. 12 using the multi-channel fixed frequency noise filtering method based on LEVKOV of the present application.

具体实施方式DETAILED DESCRIPTION

为了使本申请的目的、技术方案及优点更加清楚明白,以下结合附图及实施例,对本申请进行进一步详细说明。应当理解,此处描述的具体实施例仅用以解释本申请,并不用于限定本申请。In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.

参见图1~图4,本申请一实施例中提供一种基于LevKov的多通道固定频率噪声滤除方法,包括下文中的步骤S100~步骤S400,各步骤中的子步骤作为技术方案的细化和延伸,作为可选方案。1 to 4 , a multi-channel fixed-frequency noise filtering method based on LevKov is provided in one embodiment of the present application, including steps S100 to S400 described below, and the sub-steps in each step are optional solutions as refinements and extensions of the technical solution.

步骤S100,利用多通道导联获得多个心磁图波形数据;Step S100, obtaining a plurality of magnetocardiogram waveform data using multi-channel leads;

在步骤S100中,多通道导联例如可以是36导联。步骤S100包括数据预处理(步骤S110)、以及导联选择(步骤S120)。In step S100, the multi-channel leads may be, for example, 36 leads. Step S100 includes data preprocessing (step S110) and lead selection (step S120).

在步骤S110中,数据预处理包括依次进行的差分处理和积分处理,其中:In step S110, data preprocessing includes differential processing and integral processing performed in sequence, wherein:

差分处理包括:间隔N做差分处理,具体公式如下:The differential processing includes: performing differential processing at intervals of N. The specific formula is as follows:

Xdev(i)=X(i+N)-X(i) 公式(3.1)X dev (i)=X(i+N)-X(i) Formula (3.1)

上式中,Xdev为差分处理后的数据,X为原始心磁数据,N为差分间隔系数,例如在采样率是1000hz时,N取5-15,如10。In the above formula, X dev is the data after differential processing, X is the original magnetocardiographic data, and N is the differential interval coefficient. For example, when the sampling rate is 1000 Hz, N is 5-15, such as 10.

积分处理包括:差分后数做绝对值后据进行m点窗口积分,具体公式如下:The integral processing includes: taking the absolute value of the difference and performing m-point window integration. The specific formula is as follows:

上式中,Xwin为预处理最终数据,Xdev为差分处理后的数据,m为窗口积分长度,例如在采样率是1000hz时,m取140-150,如145。In the above formula, Xwin is the final data after preprocessing, Xdev is the data after differential processing, and m is the window integration length. For example, when the sampling rate is 1000hz, m is 140-150, such as 145.

在步骤S120中,导联选择包括:In step S120, lead selection includes:

当数据初始化时,选择多通道导联中心区域20%~40%的整数个导联作为噪声模板范围定位导联,When the data is initialized, an integer number of leads in the central area of 20% to 40% of the multi-channel leads is selected as the noise template range positioning leads.

和/或选择心拍模板中R波幅值最高的20%~40%的整数个导联作为用于噪声模板范围定位导联。And/or selecting an integer number of leads with the highest 20% to 40% R wave amplitude in the heart beat template as leads for locating the noise template range.

数据初始化为缓存数据的时长至少包括一个心跳周期,例如缓存的数据时长为4s。导联选择例如可以是在36导联中选择8个定位导联。The duration of data initialization as cached data includes at least one heartbeat cycle, for example, the duration of cached data is 4 seconds. The lead selection may be, for example, selecting 8 positioning leads from 36 leads.

步骤S200,在心磁图波形数据中预判的非线性区域获得波峰点;Step S200, obtaining a peak point in a predicted nonlinear region in the magnetocardiogram waveform data;

在步骤S200中,获得心磁图波形数据的波峰点,具体包括步骤S210和步骤S220。In step S200, the peak point of the magnetocardiogram waveform data is obtained, which specifically includes step S210 and step S220.

步骤S210,获得波峰定位阈值,波峰定位阈值小于心磁图波形数据中各波峰的平均值。Step S210, obtaining a peak location threshold, where the peak location threshold is less than an average value of each peak in the magnetocardiogram waveform data.

进一步地,波峰定位阈值例如可以通过公式(3.3):Furthermore, the peak location threshold can be, for example, calculated by formula (3.3):

获得,式中心磁图波形数据中包括多个统计周期,SecMax为所有统计周期最大值排序后的序列,a为小于1的阈值生成系数,n1为序列SecMax中选择的起始数据,n2为SecMax中选择的末尾数据。优选的,通过选择序列中中部的数据来排除数据异常的干扰,如SecMax序列共计有20个最大值排序数据,n1是排序第5的数据,n2为排序第16的数据,共计12个。 The central magnetic waveform data in the formula includes multiple statistical cycles, SecMax is the sequence after the maximum values of all statistical cycles are sorted, a is the threshold generation coefficient less than 1, n1 is the starting data selected in the sequence SecMax, and n2 is the end data selected in SecMax. Preferably, the interference of data anomalies is eliminated by selecting the data in the middle of the sequence, such as the SecMax sequence has a total of 20 maximum value sorted data, n1 is the data ranked 5th, n2 is the data ranked 16th, and a total of 12.

具体地,获得定位导联每个统计周期(例如可以是每秒)的最大值,缓存一定时间后(例如可以是20s),将缓存数据排序(对数据大小进行排序筛选)后取预定时间段(例如可以是12s)的数据最大值做平均后乘系数a(a例如可以是0.5~0.8,如为0.7),得到波峰定位阈值thr。Specifically, the maximum value of each statistical period of the positioning lead is obtained, and after caching for a certain period of time (for example, it can be 20 seconds), the cached data is sorted (the data size is sorted and screened), and the maximum value of the data in a predetermined time period (for example, it can be 12 seconds) is taken as the average and then multiplied by a coefficient a (a can be, for example, 0.5 to 0.8, such as 0.7) to obtain the peak positioning threshold thr.

步骤S220,根据与波峰定位阈值的相对关系,确定波峰点。Step S220, determining the peak point according to the relative relationship with the peak location threshold.

由于心磁图波形数据中可能存在噪声干扰,本步骤获得波峰定位阈值后,凡大于波峰定位阈值的区域,均认定为该区域属于非线性区域,该区域的波峰为确定的波峰点。Since there may be noise interference in the magnetocardiogram waveform data, after obtaining the peak location threshold in this step, any area greater than the peak location threshold is identified as belonging to the nonlinear area, and the peak of the area is the determined peak point.

步骤S300,划分非线性区域和线性区域,包括:将波峰点沿时间轴前后分别偏移指定阈值,得到两个起始点,各起始点与波峰点之间的连线作为参考线,遍历波峰点与各起始点之间的数据点,将波峰点在时间轴两侧且与相应侧参考线距离最大的数据点分别作为端点,两端点之间为非线性区域,其余为线性区域;Step S300, dividing the nonlinear region and the linear region, including: offsetting the peak point by a specified threshold value along the time axis to obtain two starting points, using the line between each starting point and the peak point as a reference line, traversing the data points between the peak point and each starting point, using the data points where the peak point is on both sides of the time axis and has the largest distance from the corresponding side reference line as endpoints, the area between the two end points is the nonlinear region, and the rest is the linear region;

进一步地,各起始点为心磁图波形数据上时间轴不变、且数据值置零的数据零点。心磁图波形数据通过x-y坐标系体现,其中,时间轴为x轴,数据值为y轴。数据零点是指在x轴位置不变的情况下,将数据值置零。通过这种方式,避免非线性区域附近可能产生的尖峰,影响非线性区域的左、右端点确认。Furthermore, each starting point is a data zero point on the magnetocardiogram waveform data where the time axis is unchanged and the data value is set to zero. The magnetocardiogram waveform data is represented by an x-y coordinate system, where the time axis is the x axis and the data value is the y axis. The data zero point refers to setting the data value to zero when the x-axis position remains unchanged. In this way, possible spikes near the nonlinear region are avoided, which may affect the confirmation of the left and right endpoints of the nonlinear region.

在步骤S300中,将波峰点沿时间轴前后分别偏移时,分别对应第一指定阈值和第二指定阈值,心磁图波形数据中包括连续的心拍信号,第一指定阈值和第二指定阈值之和大于心拍信号中QRS波(R所在的非线性区域)的宽度。例如第一指定阈值和第二指定阈值均为80ms。In step S300, when the peak point is shifted forward and backward along the time axis, the first specified threshold and the second specified threshold are respectively corresponding, the magnetocardiogram waveform data includes a continuous heartbeat signal, and the sum of the first specified threshold and the second specified threshold is greater than the width of the QRS wave (the nonlinear region where R is located) in the heartbeat signal. For example, the first specified threshold and the second specified threshold are both 80ms.

在步骤S300中,获得非线性区域和线性区域,具体包括:利用局部距离法获得非线性区域的端点,端点包括左端点和右端点;In step S300, the nonlinear region and the linear region are obtained, specifically including: obtaining the endpoints of the nonlinear region using a local distance method, the endpoints including a left endpoint and a right endpoint;

局部距离法包括,公式(3.4):The local distance method includes formula (3.4):

distance=(ystart-yend)*x+(xend-xstart)*y+xstart*yend-xend*ystart,其中,(x,y)为心磁图波形数据的搜索坐标,x为心磁图波形数据的时间轴,y为心磁图波形数据的数据值;(xstart,ystart)为搜索范围起点,(xend,yend)为搜索范围终点,distance为(x,y)到(xstart,ystart)和(xend,yend)两点连线的局部距离;distance=(y start -y end )*x+(x end -x start )*y+x start *y end -x end *y start , wherein (x, y) are the search coordinates of the magnetocardiogram waveform data, x is the time axis of the magnetocardiogram waveform data, and y is the data value of the magnetocardiogram waveform data; (x start , y start ) is the starting point of the search range, (x end , y end ) is the end point of the search range, and distance is the local distance from (x, y) to the line connecting the two points (x start , y start ) and (x end , y end );

获得非线性区域的左端点,包括:令波峰点时间轴前第一指定阈值的数据零点作为搜索范围起点,令波峰点为搜索范围终点,当局部距离最大时,搜索坐标为非线性区域的左端点;Obtaining the left endpoint of the nonlinear region includes: setting the data zero point of the first specified threshold before the wave peak point time axis as the starting point of the search range, setting the wave peak point as the end point of the search range, and when the local distance is the maximum, the search coordinate is the left endpoint of the nonlinear region;

获得非线性区域的右端点,包括:令波峰点为搜索范围起点,令在波峰点时间轴后第二指定阈值的数据零点作为搜索范围终点,当局部距离最大时,搜索坐标为非线性区域的右端点。获得非线性区域的左、右端点即获得非线性区域,在心磁图波形数据除非线性区域的其余部分即为线性区域。Obtaining the right endpoint of the nonlinear region includes: setting the peak point as the starting point of the search range, setting the data zero point of the second specified threshold after the peak point time axis as the end point of the search range, and when the local distance is the maximum, the search coordinate is the right endpoint of the nonlinear region. Obtaining the left and right endpoints of the nonlinear region means obtaining the nonlinear region, and the rest of the magnetocardiogram waveform data except the linear region is the linear region.

进一步地,步骤S300还包括,在超过50%的定位导联中,各个导联的非线性区域相同,视为获得非线性区域。具体地,8个定位导联中超过4个以上都确定为是非模板区域(非线性区域)则将其定位最终的非模板区域,其余部分数据为噪声模板提取区域(线性区域)。Furthermore, step S300 also includes that, in more than 50% of the positioning leads, the nonlinear regions of the leads are the same, and the nonlinear regions are considered to be obtained. Specifically, if more than 4 of the 8 positioning leads are determined to be non-template regions (non-linear regions), they are positioned as the final non-template regions, and the remaining data are noise template extraction regions (linear regions).

步骤S400,逐一对各心磁图波形数据的线性区域、以及非线性区域进行固定频率噪声滤除,直至处理完所有的心磁图波形数据。Step S400 , filtering out fixed frequency noise in the linear region and the nonlinear region of each magnetocardiogram waveform data one by one until all magnetocardiogram waveform data are processed.

步骤S400包括步骤S410~步骤S440。Step S400 includes steps S410 to S440.

步骤S410,针对线性区域进行固定频率噪声滤除时,包括:Step S410, when filtering fixed frequency noise in the linear region, includes:

步骤S411,针对其中一待处理的数据点,利用预定时间内的缓存数据对该数据点进行滤波;缓存数据是从待处理的心磁图波形数据中获得且长度为M,M=FS/FREnoise,其中FS为采样率,FREnoise为固定频率噪声的频率,待处理的数据点为缓存数据后一时刻对应的数据点;Step S411, for one of the data points to be processed, the data point is filtered using the buffered data within a predetermined time; the buffered data is obtained from the magnetocardiogram waveform data to be processed and has a length of M, M=FS/FRE noise , where FS is the sampling rate, FRE noise is the frequency of fixed frequency noise, and the data point to be processed is the data point corresponding to the next moment after the buffered data;

步骤S412,对该数据点进行滤波后得到第一数据datafilter, 公式(3.5):Step S412, filtering the data point to obtain first data data filter , formula (3.5):

Cachen为缓存数据,datum为待处理的数据点。Cache n is the cached data, and datum is the data point to be processed.

步骤S410中,滤波的方式是针对每一数据点进行的,其具体通过公式M=FS/FREnoise实现。“待处理的数据点”是指即将缓存但尚未缓存的数据点。In step S410, filtering is performed for each data point, which is specifically implemented by the formula M=FS/FRE noise . "Data points to be processed" refer to data points that are about to be cached but have not yet been cached.

可以理解,针对线性区域进行固定频率噪声滤除时,最开始进入线性区域时,初始的缓存长度为M的缓存数据不进行滤波,这一点通过公式(3.5)也有所体现,即实现了使用缓存的数据得到滤除固定频率噪声后的数据。It can be understood that when fixed-frequency noise is filtered out in the linear region, the cache data with an initial cache length of M is not filtered when the linear region is first entered. This is also reflected in formula (3.5), which means that the cached data is used to obtain the data after the fixed-frequency noise is filtered out.

步骤S420,还包括利用缓存数据中位数位置的数据、与第一数据做差值,得到噪声数据,噪声数据的集合为噪声模板,缓存数据和噪声模板均实时更新。Step S420 also includes using the data at the median position of the cached data to make a difference with the first data to obtain noise data. The set of noise data is a noise template. The cached data and the noise template are both updated in real time.

噪声数据具体通过以下公式获得:The noise data is obtained by the following formula:

temp=Cachen/2-datafilter 公式(3.6)temp=Cache n/2 -data filter formula (3.6)

式中,Cachen/2为缓存数据中位数位置的数据,datafilter为滤除固定频率噪声后的数据(第一数据),temp为得到的噪声数据。Wherein, Cache n/2 is the data at the median position of the cache data, data filter is the data after the fixed frequency noise is filtered out (first data), and temp is the obtained noise data.

缓存数据和噪声模板均实时更新,具体包括步骤S421和步骤S422。其中:The cache data and the noise template are updated in real time, specifically including step S421 and step S422.

步骤S421,缓存数据的实时更新为利用缓存数据后一时刻对应的数据点置入缓存数据,并去除时间轴最早的数据点(即去除最老的数据点);Step S421, real-time updating of cached data is to use the data point corresponding to the next moment of the cached data to be placed into the cached data, and remove the earliest data point on the time axis (i.e., remove the oldest data point);

步骤S422,噪声模板的实时更新为将最新的噪声数据置入噪声模板中,并去除时间轴最早的数据点(即去除最老的数据点)。Step S422 , real-time updating of the noise template is to place the latest noise data into the noise template and remove the earliest data point on the time axis (ie, remove the oldest data point).

在步骤S420中,噪声数据是针对数据点的点位数据,噪声模板是缓存长度为M的若干噪声数据的集合。In step S420, the noise data is point data for the data point, and the noise template is a set of a plurality of noise data with a buffer length of M.

步骤S430,针对非线性区域进行固定频率噪声滤除时,具体包括:将缓存数据的中位数位置的数据点,与噪声模板中最老的噪声数据相减得到当前滤波数据,缓存数据和噪声模板均实时更新。Step S430, when performing fixed frequency noise filtering for the nonlinear region, specifically includes: subtracting the data point at the median position of the cached data from the oldest noise data in the noise template to obtain the current filtered data, and both the cached data and the noise template are updated in real time.

缓存数据和噪声模板均实时更新,具体包括步骤S431和步骤S432。其中:The cache data and the noise template are updated in real time, specifically including step S431 and step S432. Among them:

步骤S431,缓存数据的实时更新为利用缓存数据后一时刻对应的数据点置入缓存数据,并去除时间轴最早的数据点(最老的数据点);Step S431, real-time updating of cached data is to use the data point corresponding to the next moment of the cached data to be placed into the cached data, and remove the earliest data point (oldest data point) on the time axis;

步骤S432,噪声模板的实时更新为将最老的噪声数据置入噪声模板,并去除最老的噪声数据。Step S432 : Real-time updating of the noise template is to place the oldest noise data into the noise template and remove the oldest noise data.

在针对非线性区域进行固定频率噪声滤除时,缓存数据的实时更新与线性区域的实时更新相同,但噪声模板的实时更新不同。在非线性区域中,得到第一数据datafilter的公式(3.5)不再适用,也就不能够通过公式(3.6)得到新的噪声数据,此时噪声模板中的噪声数据进行循环使用。When fixed frequency noise is filtered out in the nonlinear region, the real-time update of the cache data is the same as that in the linear region, but the real-time update of the noise template is different. In the nonlinear region, the formula (3.5) for obtaining the first data data filter is no longer applicable, and new noise data cannot be obtained through formula (3.6). At this time, the noise data in the noise template is recycled.

在步骤S432中,通过循环使用噪声模板中的噪声数据完成滤波。举例来说,例如噪声模板包括abcd共四个噪声数据,其中a为最老的噪声数据。将a置入噪声模板,并将最老的噪声数据a去除。更新后的噪声模板中四个噪声数据为bcda,此时b为最老的噪声数据。In step S432, filtering is completed by cyclically using the noise data in the noise template. For example, the noise template includes four noise data abcd, where a is the oldest noise data. a is placed in the noise template, and the oldest noise data a is removed. The four noise data in the updated noise template are bcda, and b is the oldest noise data.

步骤S440,针对非线性区域进行固定频率噪声滤除时,非线性区域后毗邻的数据长度为M的线性区域,按照非线性区域的滤波方式进行滤波。In step S440, when fixed frequency noise is filtered out for the nonlinear region, a linear region with a data length of M adjacent to the nonlinear region is filtered according to the filtering method of the nonlinear region.

可以理解,步骤S430和步骤S440相互配合,能够使固定频率噪声滤除后的心磁图波形数据保持连续。It can be understood that step S430 and step S440 cooperate with each other to keep the magnetocardiogram waveform data continuous after the fixed frequency noise is filtered out.

本申请各实施例中,借助心磁多通道的优点,选择信噪比最高的通道作为定位导联,用于确定线性区域和非线性区域(步骤S120)。借助心磁图波形数据中的心拍信号,动态生成波峰定位阈值thr,从而初步获得非线性区域所在位置(步骤S210和步骤S220)。结合局部距离法,精确定位非线性区域的的范围(步骤S300)。In each embodiment of the present application, by taking advantage of the magnetocardiogram multi-channel, the channel with the highest signal-to-noise ratio is selected as the positioning lead to determine the linear region and the nonlinear region (step S120). By means of the heartbeat signal in the magnetocardiogram waveform data, the peak positioning threshold thr is dynamically generated to preliminarily obtain the location of the nonlinear region (steps S210 and S220). Combined with the local distance method, the range of the nonlinear region is accurately located (step S300).

本申请各实施例中分别对线性区域和非线性区域进行滤波,能在保留QRS波信号的同时达到较好的滤波效果(步骤S400)。其中,针对线性区域进行固定频率噪声滤除时,还获得了噪声模板(步骤S420~步骤S422)。使用噪声模板去除非线性区域噪声(步骤S430~步骤S432),保证在去除噪声的同时,保留与噪声频段重叠的有效信号。In each embodiment of the present application, the linear region and the nonlinear region are filtered respectively, and a good filtering effect can be achieved while retaining the QRS wave signal (step S400). Among them, when the fixed frequency noise is filtered out for the linear region, a noise template is also obtained (step S420 to step S422). The noise template is used to remove the noise in the nonlinear region (step S430 to step S432), ensuring that while removing the noise, the valid signal overlapping with the noise frequency band is retained.

应该理解的是,虽然图1~图4的流程图中的各个步骤按照箭头的指示依次显示,但是这些步骤并不是必然按照箭头指示的顺序依次执行。除非本文中有明确的说明,这些步骤的执行并没有严格的顺序限制,这些步骤可以以其它的顺序执行。而且,图1~图4中的至少一部分步骤可以包括多个子步骤或者多个阶段,这些子步骤或者阶段并不必然是在同一时刻执行完成,而是可以在不同的时刻执行,这些子步骤或者阶段的执行顺序也不必然是依次进行,而是可以与其它步骤或者其它步骤的子步骤或者阶段的至少一部分轮流或者交替地执行。It should be understood that, although the steps in the flowcharts of Figures 1 to 4 are displayed in sequence as indicated by the arrows, these steps are not necessarily executed in sequence in the order indicated by the arrows. Unless otherwise specified herein, there is no strict order restriction on the execution of these steps, and these steps can be executed in other orders. Moreover, at least a portion of the steps in Figures 1 to 4 may include multiple sub-steps or multiple stages, and these sub-steps or stages are not necessarily executed at the same time, but can be executed at different times, and the execution order of these sub-steps or stages is not necessarily sequential, but can be executed in turn or alternately with other steps or at least a portion of the sub-steps or stages of other steps.

参见图5,本申请各实施例中基于LEVKOV的多通道固定频率噪声滤除方法的流程框图简述如下,获得数据(即心磁图波形数据)后(步骤S100):一方面依次进行数据预处理(步骤S110)、定位导联选择(步骤S120)、模板范围定位(步骤S300划分非线性区域和线性区域)。完成后,逐一对各心磁图波形数据进行线性区域滤波(即固定频率噪声滤除)和模板提取(即噪声模板提取),以及非模板区域(即非线性区域)滤波(步骤S400)。Referring to FIG5 , the flowchart of the multi-channel fixed frequency noise filtering method based on LEVKOV in each embodiment of the present application is briefly described as follows: after obtaining the data (i.e., magnetocardiogram waveform data) (step S100): on the one hand, data preprocessing (step S110), positioning lead selection (step S120), and template range positioning (step S300 dividing the nonlinear region and the linear region) are sequentially performed. After completion, linear region filtering (i.e., fixed frequency noise filtering) and template extraction (i.e., noise template extraction) are performed on each magnetocardiogram waveform data one by one, as well as non-template region (i.e., nonlinear region) filtering (step S400).

参见图6,在一个实施例中,提供了一种计算机设备,该计算机设备可以是服务器,其内部结构图可以如图6所示。该计算机设备包括通过系统总线连接的处理器、存储器、网络接口和数据库。其中,该计算机设备的处理器用于提供计算和控制能力。该计算机设备的存储器包括非易失性存储介质、内存储器。该非易失性存储介质存储有操作系统、计算机程序和数据库。该内存储器为非易失性存储介质中的操作系统和计算机程序的运行提供环境。该计算机设备的数据库用于存储以下四者中的至少一者:滤波前的心磁图波形数据、缓存数据、噪声数据、以及滤波后的心磁图波形数据。该计算机设备的网络接口用于与外部的终端通过网络连接通信。该计算机程序被处理器执行时以实现一种基于LEVKOV的多通道固定频率噪声滤除方法。Referring to FIG6 , in one embodiment, a computer device is provided, which may be a server, and its internal structure diagram may be shown in FIG6 . The computer device includes a processor, a memory, a network interface, and a database connected via a system bus. The processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program, and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The database of the computer device is used to store at least one of the following four: magnetocardiogram waveform data before filtering, cache data, noise data, and magnetocardiogram waveform data after filtering. The network interface of the computer device is used to communicate with an external terminal via a network connection. When the computer program is executed by the processor, a multi-channel fixed-frequency noise filtering method based on LEVKOV is implemented.

在一个实施例中,提供了一种计算机设备,包括存储器和处理器,存储器中存储有计算机程序,该处理器执行计算机程序时实现以下步骤:In one embodiment, a computer device is provided, including a memory and a processor, wherein a computer program is stored in the memory, and when the processor executes the computer program, the following steps are implemented:

步骤S100,利用多通道导联获得多个心磁图波形数据;Step S100, obtaining a plurality of magnetocardiogram waveform data using multi-channel leads;

步骤S200,在心磁图波形数据中预判的非线性区域获得波峰点;Step S200, obtaining a peak point in a predicted nonlinear region in the magnetocardiogram waveform data;

步骤S300,划分非线性区域和线性区域,包括:将波峰点沿时间轴前后分别偏移指定阈值,得到两个起始点,各起始点与波峰点之间的连线作为参考线,遍历波峰点与各起始点之间的数据点,将波峰点在时间轴两侧且与相应侧参考线距离最大的数据点分别作为端点,两端点之间为非线性区域,其余为线性区域;Step S300, dividing the nonlinear region and the linear region, including: offsetting the peak point by a specified threshold value along the time axis to obtain two starting points, using the line between each starting point and the peak point as a reference line, traversing the data points between the peak point and each starting point, using the data points where the peak point is on both sides of the time axis and has the largest distance from the corresponding side reference line as endpoints, the area between the two end points is the nonlinear region, and the rest is the linear region;

步骤S400,逐一对各心磁图波形数据的线性区域、以及非线性区域进行固定频率噪声滤除,直至处理完所有的心磁图波形数据。Step S400 , filtering out fixed frequency noise in the linear region and the nonlinear region of each magnetocardiogram waveform data one by one until all magnetocardiogram waveform data are processed.

在一个实施例中,提供了一种计算机可读存储介质,其上存储有计算机程序,计算机程序被处理器执行时实现以下步骤:In one embodiment, a computer readable storage medium is provided, on which a computer program is stored, and when the computer program is executed by a processor, the following steps are implemented:

步骤S100,利用多通道导联获得多个心磁图波形数据;Step S100, obtaining a plurality of magnetocardiogram waveform data using multi-channel leads;

步骤S200,在心磁图波形数据中预判的非线性区域获得波峰点;Step S200, obtaining a peak point in a predicted nonlinear region in the magnetocardiogram waveform data;

步骤S300,划分非线性区域和线性区域,包括:将波峰点沿时间轴前后分别偏移指定阈值,得到两个起始点,各起始点与波峰点之间的连线作为参考线,遍历波峰点与各起始点之间的数据点,将波峰点在时间轴两侧且与相应侧参考线距离最大的数据点分别作为端点,两端点之间为非线性区域,其余为线性区域;Step S300, dividing the nonlinear region and the linear region, including: offsetting the peak point by a specified threshold value along the time axis to obtain two starting points, using the line between each starting point and the peak point as a reference line, traversing the data points between the peak point and each starting point, using the data points where the peak point is on both sides of the time axis and has the largest distance from the corresponding side reference line as endpoints, the area between the two end points is the nonlinear region, and the rest is the linear region;

步骤S400,逐一对各心磁图波形数据的线性区域、以及非线性区域进行固定频率噪声滤除,直至处理完所有的心磁图波形数据。Step S400 , filtering out fixed frequency noise in the linear region and the nonlinear region of each magnetocardiogram waveform data one by one until all magnetocardiogram waveform data are processed.

在一个实施例中,提供了一种计算机程序产品,包括计算机指令,该计算机指令被处理器执行时实现以下步骤:In one embodiment, a computer program product is provided, comprising computer instructions, which when executed by a processor implement the following steps:

步骤S100,利用多通道导联获得多个心磁图波形数据;Step S100, obtaining a plurality of magnetocardiogram waveform data using multi-channel leads;

步骤S200,在心磁图波形数据中预判的非线性区域获得波峰点;Step S200, obtaining a peak point in a predicted nonlinear region in the magnetocardiogram waveform data;

步骤S300,划分非线性区域和线性区域,包括:将波峰点沿时间轴前后分别偏移指定阈值,得到两个起始点,各起始点与波峰点之间的连线作为参考线,遍历波峰点与各起始点之间的数据点,将波峰点在时间轴两侧且与相应侧参考线距离最大的数据点分别作为端点,两端点之间为非线性区域,其余为线性区域;Step S300, dividing the nonlinear region and the linear region, including: offsetting the peak point by a specified threshold value along the time axis to obtain two starting points, using the line between each starting point and the peak point as a reference line, traversing the data points between the peak point and each starting point, using the data points where the peak point is on both sides of the time axis and has the largest distance from the corresponding side reference line as endpoints, the area between the two end points is the nonlinear region, and the rest is the linear region;

步骤S400,逐一对各心磁图波形数据的线性区域、以及非线性区域进行固定频率噪声滤除,直至处理完所有的心磁图波形数据。Step S400 , filtering out fixed frequency noise in the linear region and the nonlinear region of each magnetocardiogram waveform data one by one until all magnetocardiogram waveform data are processed.

本实施例中,计算机程序产品包括程序代码部分,以用于当计算机程序产品由一个或多个计算装置执行时,执行本申请各实施例中基于LEVKOV的多通道固定频率噪声滤除方法的步骤。计算机程序产品可被存储在计算机可读记录介质上。还可经由数据网络(例如,通过RAN、经由因特网和/或通过RBS)提供计算机程序产品以便下载。备选地或附加地,该方法可被编码在现场可编程门阵列(FPGA)和/或专用集成电路(ASIC)中,或者功能性可借助于硬件描述语言被提供以便下载。In this embodiment, the computer program product includes a program code portion for executing the steps of the multi-channel fixed frequency noise filtering method based on LEVKOV in each embodiment of the present application when the computer program product is executed by one or more computing devices. The computer program product can be stored on a computer-readable recording medium. The computer program product can also be provided for download via a data network (e.g., via a RAN, via the Internet and/or via an RBS). Alternatively or additionally, the method can be encoded in a field programmable gate array (FPGA) and/or an application specific integrated circuit (ASIC), or the functionality can be provided for download with the aid of a hardware description language.

本领域普通技术人员可以理解实现上述实施例方法中的全部或部分流程,是可以通过计算机程序来指令相关的硬件来完成,所述的计算机程序可存储于一非易失性计算机可读取存储介质中,该计算机程序在执行时,可包括如上述各方法的实施例的流程。其中,本申请所提供的各实施例中所使用的对存储器、存储、数据库或其它介质的任何引用,均可包括非易失性和/或易失性存储器。非易失性存储器可包括只读存储器(ROM)、可编程ROM(PROM)、电可编程ROM(EPROM)、电可擦除可编程ROM(EEPROM)或闪存。易失性存储器可包括随机存取存储器(RAM)或者外部高速缓冲存储器。作为说明而非局限,RAM以多种形式可得,诸如静态RAM(SRAM)、动态RAM(DRAM)、同步DRAM(SDRAM)、双数据率SDRAM(DDRSDRAM)、增强型SDRAM(ESDRAM)、同步链路(Synchlink)DRAM(SLDRAM)、存储器总线(Rambus)直接RAM(RDRAM)、直接存储器总线动态RAM(DRDRAM)、以及存储器总线动态RAM(RDRAM)等。Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application can include non-volatile and/or volatile memory. Non-volatile memory can include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory can include random access memory (RAM) or external cache memory. As an illustration and not limitation, RAM is available in many forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).

此外,针对本申请各实施例提供的的技术方案,申请人通过实验验证了技术方案的可行性和有效性。具体地,在干净的心磁信号上叠加25Hz正弦波模拟的噪声,使用切比雪夫25Hz带阻滤波器、整系数25Hz陷波器和本申请各实施例提供的基于LEVKOV的多通道固定频率噪声滤除方法,对比三者时域和频域的结果。In addition, the applicant has verified the feasibility and effectiveness of the technical solutions provided in each embodiment of the present application through experiments. Specifically, a 25Hz sine wave simulated noise is superimposed on the clean magnetic cardiology signal, and the Chebyshev 25Hz band-stop filter, the integer coefficient 25Hz notch filter and the LEVKOV-based multi-channel fixed frequency noise filtering method provided in each embodiment of the present application are used to compare the time domain and frequency domain results of the three.

参见图7~图16,由各图数据可以看出,切比雪夫25HZ带阻滤波器和整系数25Hz陷波器都会衰减心磁信号中与干扰频段重叠部分的信号,导致心磁波形变形。本申请各实施例提供的基于LEVKOV的多通道固定频率噪声滤除方法,能够有效避免心磁波形变形,在保留有效信号的同时能够去除噪声干扰。Referring to Figures 7 to 16, it can be seen from the data in each figure that the Chebyshev 25HZ band-stop filter and the integer coefficient 25Hz notch filter will attenuate the signal in the part of the magnetocardiographic signal that overlaps with the interference frequency band, resulting in deformation of the magnetocardiographic waveform. The multi-channel fixed-frequency noise filtering method based on LEVKOV provided in each embodiment of the present application can effectively avoid deformation of the magnetocardiographic waveform and remove noise interference while retaining the effective signal.

以上实施例的各技术特征可以进行任意的组合,为使描述简洁,未对上述实施例中的各个技术特征所有可能的组合都进行描述,然而,只要这些技术特征的组合不存在矛盾,都应当认为是本说明书记载的范围。不同实施例中的技术特征体现在同一附图中时,可视为该附图也同时披露了所涉及的各个实施例的组合例。The technical features of the above embodiments can be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification. When the technical features in different embodiments are embodied in the same figure, it can be regarded that the figure also discloses the combination examples of the various embodiments involved.

以上所述实施例仅表达了本申请的几种实施方式,其描述较为具体和详细,但并不能因此而理解为对发明专利范围的限制。应当指出的是,对于本领域的普通技术人员来说,在不脱离本申请构思的前提下,还可以做出若干变形和改进,这些都属于本申请的保护范围。因此,本申请专利的保护范围应以所附权利要求为准。The above-mentioned embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the invention patent. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the patent of the present application shall be subject to the attached claims.

Claims (7)

1. The LevKov-based multichannel fixed frequency noise filtering method is characterized by comprising the following steps of:
Obtaining a plurality of magnetocardiogram waveform data by using the multichannel leads;
Obtaining peak points in a nonlinear region predicted in the magnetocardiogram waveform data comprises the following steps: the peak location threshold is obtained by: the waveform data of the central magnetic diagram comprises a plurality of statistical periods, For sequences ordered by the maximum of all statistical periods,Generating coefficients for threshold values less than 1, n1 being the start data selected in the sequence SecMax and n2 being the end data selected in SecMax; all areas larger than the peak positioning threshold value are considered to belong to a nonlinear area; the peak positioning threshold value is smaller than the average value of each peak in the magnetocardiogram waveform data, and the peak point is determined according to the relative relation with the peak positioning threshold value;
Dividing the nonlinear region and the linear region, comprising: when the peak point is respectively shifted along the front and back of the time axis, a first designated threshold value and a second designated threshold value are respectively shifted to obtain two starting points, wherein the magnetocardiogram waveform data comprise continuous heart beat signals, and the sum of the first designated threshold value and the second designated threshold value is larger than the width of a QRS wave in the heart beat signals; traversing data points between the peak points and the starting points by taking a connecting line between each starting point and the peak point as a reference line, taking data points with the peak points on two sides of a time axis and the maximum distance from the corresponding side reference line as end points respectively, wherein a nonlinear region is arranged between the two end points, and the rest is a linear region;
and filtering fixed frequency noise from the linear region and the nonlinear region of each magnetocardiogram waveform data one by one until all magnetocardiogram waveform data are processed.
2. The LevKov-based multichannel fixed frequency noise filtering method according to claim 1, wherein when the fixed frequency noise filtering is performed for a linear region, the method includes:
For one data point to be processed, filtering the data point by utilizing cache data in a preset time; the buffer data is obtained from the magnetocardiogram waveform data to be processed, the length is M, m=fs/FRE noise, wherein FS is the sampling rate, FRE noise is the frequency of fixed frequency noise;
The data points to be processed are the data points corresponding to the time after the data are cached;
Filtering the data point to obtain first data
Caching data for the data;
Is the data point to be processed.
3. The LevKov-based multichannel fixed frequency noise filtering method according to claim 2, further comprising obtaining noise data by using the data of the median position of the buffered data and the first data as a difference value, wherein the set of noise data is a noise template;
the cache data and the noise template are updated in real time:
The real-time updating of the cache data is that the data point corresponding to the later time of the cache data is put into the cache data, and the earliest data point of a time axis is removed;
the real-time updating of the noise template is to put the latest noise data into the noise template and remove the earliest data point of the time axis.
4. The method for filtering multi-channel fixed frequency noise based on LevKov as set forth in claim 3, wherein the filtering of fixed frequency noise for a nonlinear region specifically includes:
subtracting the data point of the median position of the cache data from the oldest noise data in the noise template to obtain current filtering data;
the cache data and the noise template are updated in real time:
The real-time updating of the cache data is that the data point corresponding to the later time of the cache data is put into the cache data, and the earliest data point of a time axis is removed;
the real-time updating of the noise template is to put the oldest noise data into the noise template and remove the oldest noise data.
5. The method for filtering multi-channel fixed frequency noise based on LevKov as claimed in claim 4, wherein when the fixed frequency noise filtering is performed on a nonlinear region, filtering is performed on a linear region with a data length M adjacent to the nonlinear region according to a filtering mode of the nonlinear region.
6. Computer device comprising a memory, a processor and a computer program stored on the memory, characterized in that the processor executes the computer program to implement the steps of the LevKov-based multichannel fixed-frequency noise filtering method of any one of claims 1 to 5.
7. Computer program product comprising computer instructions which, when executed by a processor, implement the steps of the LevKov-based multichannel fixed-frequency noise filtering method according to any one of claims 1 to 5.
CN202211313034.7A 2022-10-25 2022-10-25 LevKov-based multichannel fixed frequency noise filtering method, computer equipment and program product Active CN115581459B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202211313034.7A CN115581459B (en) 2022-10-25 2022-10-25 LevKov-based multichannel fixed frequency noise filtering method, computer equipment and program product

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202211313034.7A CN115581459B (en) 2022-10-25 2022-10-25 LevKov-based multichannel fixed frequency noise filtering method, computer equipment and program product

Publications (2)

Publication Number Publication Date
CN115581459A CN115581459A (en) 2023-01-10
CN115581459B true CN115581459B (en) 2024-10-29

Family

ID=84781304

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202211313034.7A Active CN115581459B (en) 2022-10-25 2022-10-25 LevKov-based multichannel fixed frequency noise filtering method, computer equipment and program product

Country Status (1)

Country Link
CN (1) CN115581459B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN118986358B (en) * 2024-08-09 2025-07-18 漫迪医疗仪器(上海)有限公司 A magnetocardiogram analysis method, device, equipment and medium based on spatiotemporal information

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107080527A (en) * 2017-02-23 2017-08-22 东南大学 A kind of wearable life physical sign monitoring device and state of mind monitoring method
KR102451623B1 (en) * 2021-08-20 2022-10-06 인하대학교 산학협력단 Method and Apparatus for Comparing Features of ECG Signal with Difference Sampling Frequency and Filter Methods for Real-Time Measurement

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2008085179A1 (en) * 2006-01-18 2008-07-17 Newcardio, Inc. Quantitative assessment of cardiac electrical events
US7869864B2 (en) * 2007-07-09 2011-01-11 Dynacardia, Inc. Methods, systems and devices for detecting and diagnosing heart diseases and disorders
WO2009017820A2 (en) * 2007-08-01 2009-02-05 Newcardio, Inc. Method and apparatus for quantitative assessment of cardiac electrical events

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107080527A (en) * 2017-02-23 2017-08-22 东南大学 A kind of wearable life physical sign monitoring device and state of mind monitoring method
KR102451623B1 (en) * 2021-08-20 2022-10-06 인하대학교 산학협력단 Method and Apparatus for Comparing Features of ECG Signal with Difference Sampling Frequency and Filter Methods for Real-Time Measurement

Also Published As

Publication number Publication date
CN115581459A (en) 2023-01-10

Similar Documents

Publication Publication Date Title
Sameni et al. A nonlinear Bayesian filtering framework for ECG denoising
EP1241983B1 (en) Method and device for analyzing a periodic or semi-periodic signal
JP4759115B2 (en) System and method for quantifying ECG signal alternation
US9888862B2 (en) Electroanatomical mapping
US6421557B1 (en) Method for determining the baroreflex latent period and baroreflex sensitivity
CN101065058B (en) Monitoring Physiological Activity Using Partial State-Space Reconstruction
US20220061731A1 (en) Identifying ecg signals having the same morphology
García et al. ECG-based detection of body position changes in ischemia monitoring
CN115581459B (en) LevKov-based multichannel fixed frequency noise filtering method, computer equipment and program product
CN111956203B (en) Electrocardiosignal parameterization method, model training method, device, equipment and medium
CN116135147A (en) Method and device for processing electrocardiographic signal, electronic equipment and storage medium
Lee et al. A real time QRS detection using delay-coordinate mapping for the microcontroller implementation
Nayak et al. Efficient design of zero-phase Riesz fractional order digital differentiator using manta-ray foraging optimisation for precise electrocardiogram QRS detection
JP7490339B2 (en) Identifying excitation in atrial fibrillation electrograms
Jegan et al. High-performance ECG signal acquisition for heart rate measurement
Kumar et al. Performance comparison of windowing techniques for ECG signal enhancement
JP7163058B2 (en) ECG machine including filters for feature detection
CN115886834B (en) ECG (electrocardiogram) data peak detection method and device and computer equipment
Kaur et al. High frequency noise removal from electrocardiogram using FIR low pass filter based on window technique
Malhotra et al. A real time wavelet filtering for ECG baseline wandering removal
Brown et al. Real-time TP knot algorithm for baseline wander noise removal from the electrocardiogram
CN109567794B (en) A kind of abnormal P-wave anti-aliasing method and device based on P-wave superposition
McSharry et al. A comparison of nonlinear noise reduction and independent component analysis using a realistic dynamical model of the electrocardiogram
Ganassin et al. Patient-independent, MHD-robust R-peak detection for retrospective gating in cardiac MRI imaging
JP2022531304A (en) Action potential duration recovery method and device to generate a heart model that reflects the recovery characteristics

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