Electrocardiosignal R wave identification method, device and equipment based on double neural networks

By dynamically adjusting the parameters of the traditional algorithm using a dual neural network hybrid system, the problems of accuracy and real-time performance in ECG R-wave detection are solved, achieving efficient and adaptive ECG R-wave recognition, which is suitable for embedded devices.

CN121543643APending Publication Date: 2026-02-17NANJING NOVLEAD BIOTECHNOLOGY CO LTD +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202511771479.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-11-28
Publication Date
2026-02-17

AI Technical Summary

Technical Problem

In existing technologies, the detection schemes for the R wave of electrocardiogram signals suffer from problems such as unstable accuracy or high computational complexity, making it difficult to simultaneously meet the requirements of real-time performance and accuracy on embedded platforms.

Method used

A hybrid system based on dual neural networks is adopted, combining a high-performance R-wave detection network and a lightweight identifier parameter prediction network. By listening to the start conditions, the parameters of the traditional algorithm are dynamically adjusted to form a closed-loop feedback control system.

Benefits of technology

It achieves high-precision and high-efficiency R-wave detection of ECG signals on embedded platforms, can adapt to different environmental changes, reduce hardware costs and improve user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121543643A_ABST
    Figure CN121543643A_ABST
Patent Text Reader

Abstract

The invention provides an electrocardiosignal R wave recognition method, device and equipment based on double neural networks, and relates to the technical field of electrocardiosignal analysis. In the process of generating an R-wave position recognition result based on the to-be-recognized electrocardiosignal through the R-wave recognition subsystem, whether the starting condition of the parameter correction subsystem based on the double neural networks is met or not is monitored; if yes, a monitoring conclusion corresponding to the R-wave recognition subsystem is generated based on the to-be-recognized electrocardiosignal through a parameter correction subsystem based on the double neural networks, and the monitoring conclusion is converted into executable parameters of the R-wave recognition subsystem; and endowing the executable parameters to the R-wave recognition subsystem, and generating a new R-wave position recognition result based on the electrocardiosignal to be recognized through the R-wave recognition subsystem. The advantages of high precision of the neural network and high efficiency of the traditional algorithm can be simultaneously exerted.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of electrocardiosignal analysis, and in particular to a dual neural network-based electrocardiosignal R wave recognition method, device and equipment. BACKGROUND

[0002] In the field of electrocardiogram (ECG) signal analysis, accurate detection and recognition of R waves is the basis for almost all advanced applications such as heart rate calculation, arrhythmia diagnosis, heart rate variability (HRV) analysis, etc. Currently, two main technical routes are generally adopted in the industry: (1) Traditional template matching algorithm: such as Pan-Tompkins algorithm, etc. This kind of algorithm is based on pre-defined rules and thresholds (such as slope, amplitude, waveform width) for R wave recognition. Its advantages are small calculation amount and high real-time performance, which are very suitable for embedded devices (such as dynamic electrocardiogram recorder Holter, wearable device) that need continuous and real-time monitoring. However, its core disadvantage is: parameter sensitivity: the key parameters such as threshold and refractory period in the algorithm are usually fixed or semi-fixed. When the ECG signal morphology of the subject changes dramatically due to motion noise, respiratory interference, body position change or pathological characteristics (such as tachycardia, premature beat, atrial fibrillation), the template matching algorithm with fixed parameters is prone to false detection or missed detection, resulting in serious distortion of subsequent analysis.

[0003] (2) Deep learning neural network: end-to-end models based on convolutional neural network (CNN), recurrent neural network (RNN) or Transformer can learn complex R wave features from massive data, and are extremely robust to noise and morphological changes, with extremely high accuracy. However, its core disadvantage is: high computational complexity: the inference process of the model requires a large number of multiplication and addition operations, which has a high requirement for the computing power and memory of the processor, resulting in high power consumption and poor real-time performance, making it difficult to be directly deployed on resource-constrained embedded terminal devices.

[0004] Therefore, there is a clear contradiction in the current technical situation: high-accuracy neural network solutions cannot meet real-time requirements, while template matching solutions that can meet real-time requirements are not stable in accuracy. For some life-supporting medical devices, such as aortic counterpulsation devices, the accurate triggering control of counterpulsation in some scenarios depends on the accurate and efficient detection of electrocardiosignal R waves, therefore, an innovative solution that can balance accuracy and real-time performance on embedded platforms is urgently needed. SUMMARY

[0005] In view of this, the purpose of the present invention is to provide a method, device and equipment for recognizing R waves of electrocardiogram signals based on dual neural networks, which can simultaneously leverage the advantages of high precision of neural networks and high efficiency of traditional algorithms.

[0006] In a first aspect, the present invention provides a method for recognizing R-waves in electrocardiogram signals based on a dual neural network. The method is applied to a system comprising an R-wave recognition subsystem and a parameter correction subsystem based on a dual neural network. The method includes: Receive the ECG signal to be identified; During the process of generating R-wave position recognition results based on the ECG signal to be recognized by the R-wave recognition subsystem, it is monitored whether the start-up conditions of the parameter correction subsystem based on the dual neural network are met. If so, the parameter correction subsystem based on dual neural networks generates the supervision conclusion corresponding to the R-wave recognition subsystem based on the ECG signal to be identified, and converts the supervision conclusion into the executable parameters of the R-wave recognition subsystem. The executable parameters are assigned to the R-wave recognition subsystem, which then generates a new R-wave position recognition result based on the ECG signal to be recognized.

[0007] In one implementation, the R-wave recognition subsystem has a built-in R-wave fast recognizer; monitoring whether the activation conditions of the parameter correction subsystem based on a dual neural network are met includes: Based on the runtime information of the R-wave fast identifier and / or the R-wave position identification results generated by it, determine whether the start-up conditions of the parameter correction subsystem based on the dual neural network are met.

[0008] In one implementation, based on the runtime information of the R-wave fast identifier and / or the R-wave position identification results generated by it, it is determined whether the activation conditions of the parameter correction subsystem based on the dual neural network are met, including: When the running time information of the R-wave fast identifier reaches the preset composite period, and / or when the evaluation index corresponding to the R-wave position identification result does not reach the preset index threshold, the start-up conditions of the parameter correction subsystem based on the dual neural network are determined to be met.

[0009] In one implementation, the parameter correction subsystem based on a dual neural network incorporates an R-wave detection network. Through the dual neural network-based parameter correction subsystem, a supervisory conclusion corresponding to the R-wave recognition subsystem is generated based on the ECG signal to be identified, and the supervisory conclusion is converted into executable parameters for the R-wave recognition subsystem, including: An R-wave location sequence is generated based on the ECG signal to be identified using an R-wave detection network. Based on the R-wave position sequence and R-wave position identification results, determine whether to calibrate the R-wave fast identifyer; If so, construct the supervision conclusion corresponding to the R-wave fast identifier based on the R-wave position sequence, and convert the supervision conclusion into the executable parameters of the R-wave fast identifier.

[0010] In one implementation, based on the R-wave location sequence and R-wave location identification results, a determination is made as to whether to calibrate the R-wave fast identifier, including: If there is a deviation between the R-wave location sequence and the R-wave location identification result, and the duration of the deviation is greater than a preset duration threshold, then the R-wave fast identifier is to be corrected.

[0011] In one implementation, the supervisory conclusions corresponding to the R-wave fast identifier are constructed based on the R-wave location sequence, including: Determine the R-wave attribute information corresponding to the R-wave location sequence. The R-wave attribute information includes the number of R-waves, the start time of the R-waves, and the end time of the R-waves. Based on R-wave attribute information, ECG signals during abnormal periods are extracted from the ECG signals to be identified. The R-wave attribute information and the ECG signal during abnormal periods are used as the supervisory conclusions corresponding to the R-wave rapid identifier.

[0012] In one implementation, the parameter correction subsystem based on a dual neural network also incorporates a recognizer parameter prediction network; converting the supervisory conclusions into executable parameters for the R-wave fast recognizer includes: The executable parameters of a fast R-wave recognizer are generated by predicting the recognizer parameters through a network based on supervised conclusions.

[0013] Secondly, the present invention also provides a device for recognizing R-waves in electrocardiogram signals based on a dual neural network. The device is applied to a system comprising an R-wave recognition subsystem and a parameter correction subsystem based on a dual neural network. The device includes: The signal receiving module is used to receive the electrocardiogram signal to be identified. The monitoring module is used to monitor whether the start-up conditions of the parameter correction subsystem based on the dual neural network are met during the process of generating R-wave position recognition results based on the ECG signal to be recognized by the R-wave recognition subsystem. The correction module is used to generate the supervision conclusion corresponding to the R-wave recognition subsystem based on the ECG signal to be identified through the parameter correction subsystem based on the dual neural network when the judgment result of the monitoring module is yes, and convert the supervision conclusion into the executable parameters of the R-wave recognition subsystem. The recognition module is used to assign executable parameters to the R-wave recognition subsystem, and through the R-wave recognition subsystem, generate a new R-wave position recognition result based on the ECG signal to be recognized.

[0014] Thirdly, the present invention also provides an electronic device including a processor and a memory, the memory storing computer-executable instructions executable by the processor, the processor executing the computer-executable instructions to implement any of the methods provided in the first aspect.

[0015] Fourthly, the present invention also provides a computer-readable storage medium storing computer-executable instructions, which, when invoked and executed by a processor, cause the processor to implement any of the methods provided in the first aspect.

[0016] This invention provides a method, apparatus, and device for R-wave recognition of electrocardiogram (ECG) signals based on a dual neural network. Applied to a system, the system includes an R-wave recognition subsystem and a parameter correction subsystem based on a dual neural network. First, the system receives the ECG signal to be recognized. During the process of generating an R-wave position recognition result based on the ECG signal through the R-wave recognition subsystem, it monitors whether the activation conditions of the parameter correction subsystem based on the dual neural network are met. If the monitoring result is yes, the parameter correction subsystem based on the dual neural network generates a supervision conclusion corresponding to the R-wave recognition subsystem based on the ECG signal to be recognized, and converts the supervision conclusion into executable parameters for the R-wave recognition subsystem. Finally, the executable parameters are assigned to the R-wave recognition subsystem, which then generates a new R-wave position recognition result based on the ECG signal to be recognized. The above method empowers the R-wave recognition subsystem by utilizing a parameter correction subsystem based on a dual neural network. That is, when the activation conditions of the parameter correction subsystem are met, the parameter correction subsystem is used to supervise the R-wave recognition subsystem, and the supervision results are converted into executable parameters of the R-wave recognition subsystem, thereby empowering the R-wave recognition subsystem to perform R-wave recognition tasks more accurately. This invention can simultaneously leverage the advantages of high precision of neural networks and high efficiency of traditional algorithms.

[0017] Other features and advantages of the invention will be set forth in the description which follows, and will be apparent in part from the description, or may be learned by practicing the invention. The objects and other advantages of the invention are realized and obtained in accordance with the structures particularly pointed out in the description, claims and drawings.

[0018] To make the above-mentioned objects, features and advantages of the present invention more apparent and understandable, preferred embodiments are described below in detail with reference to the accompanying drawings. Attached Figure Description

[0019] To more clearly illustrate the specific embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the specific embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of the present invention. For those skilled in the art, other drawings can be obtained from these drawings without creative effort.

[0020] Figure 1 A flowchart illustrating a method for recognizing R-waves in electrocardiogram signals based on a dual neural network, provided in an embodiment of the present invention; Figure 2 A schematic diagram of a system architecture provided for an embodiment of the present invention; Figure 3 A flowchart illustrating the process of determining executable parameters of an R-wave fast identifier, provided for an embodiment of the present invention; Figure 4 A schematic diagram of the structure of an ECG signal R-wave recognition device based on a dual neural network provided in an embodiment of the present invention; Figure 5 This is a schematic diagram of the structure of an electronic device provided in an embodiment of the present invention. Detailed Implementation

[0021] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the present invention will be clearly and completely described below in conjunction with the embodiments. Obviously, the described embodiments are only some embodiments of the present invention, not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0022] Currently, there is a significant contradiction in the existing technological landscape: highly accurate solutions (neural networks) cannot meet real-time requirements, while solutions that can meet real-time requirements (template matching) have unstable accuracy. Based on this, this invention provides a method, device, and equipment for recognizing R-waves in electrocardiogram signals based on dual neural networks. The core idea is to construct a hybrid system where two neural networks work collaboratively, allowing the neural network (NN) to empower traditional algorithms rather than simply replace them. In this embodiment, the system operates with division of labor and cooperation, simultaneously leveraging the high accuracy of neural networks and the high efficiency of traditional algorithms.

[0023] To facilitate understanding of this embodiment, a detailed description of the ECG signal R-wave recognition method based on a dual neural network disclosed in this embodiment of the invention will be provided first. This method is applied to a system, which includes an R-wave recognition subsystem and a parameter correction subsystem based on a dual neural network. See [link to documentation]. Figure 1The diagram shows a flowchart of a method for recognizing R-waves in electrocardiogram signals based on a dual neural network. This method mainly includes the following steps S102 to S108: Step S102: Receive the ECG signal to be identified (i.e., the original ECG signal).

[0024] Step S104: During the process of generating R-wave position recognition results based on the ECG signal to be recognized by the R-wave recognition subsystem, monitor whether the start-up conditions of the parameter correction subsystem based on the dual neural network are met.

[0025] The R-wave recognition subsystem includes a built-in R-wave fast recognizer, which can be a processor that uses traditional algorithms such as adaptive threshold, filter coefficients, integrator weights, and refractory period to recognize R-waves.

[0026] In one implementation, the startup conditions of the parameter correction subsystem can be determined based on the evaluation index of the R-wave recognition results generated by the R-wave recognition subsystem or the runtime of the R-wave recognition subsystem.

[0027] Step S106: If yes, the supervisory conclusion corresponding to the R-wave recognition subsystem is generated based on the ECG signal to be recognized by the parameter correction subsystem based on the dual neural network, and the supervisory conclusion is converted into executable parameters of the R-wave recognition subsystem.

[0028] The parameter correction subsystem based on dual neural networks incorporates a high-performance R-wave detection network and a lightweight recognizer parameter prediction network. The R-wave detection network, denoted as Network A, is used to generate an R-wave position sequence based on the ECG signal to be identified. The supervision conclusion is constructed based on the R-wave position sequence and the ECG signal to be identified. The recognizer parameter prediction network, denoted as Network B, is used to convert the supervision conclusion into executable parameters of the R-wave recognition subsystem.

[0029] Step S108: Assign executable parameters to the R-wave recognition subsystem, and generate a new R-wave position recognition result based on the ECG signal to be recognized through the R-wave recognition subsystem.

[0030] The method provided in this invention empowers the R-wave recognition subsystem by utilizing a parameter correction subsystem based on a dual neural network. That is, when the activation conditions of the parameter correction subsystem are met, the parameter correction subsystem is used to supervise the R-wave recognition subsystem, and the supervision results are converted into executable parameters of the R-wave recognition subsystem, thereby empowering the R-wave recognition subsystem to perform R-wave recognition tasks more accurately. This invention can simultaneously leverage the advantages of high precision of neural networks and high efficiency of traditional algorithms.

[0031] For ease of understanding, the embodiments of the present invention first explain the system architecture, see [link to relevant documentation]. Figure 2The diagram illustrates a system architecture including an R-wave recognition subsystem (System A) and a parameter correction subsystem (System B). The R-wave recognition subsystem incorporates a fast R-wave recognizer, while the parameter correction subsystem, based on a dual neural network, incorporates a high-performance R-wave detection network (Network A) and a lightweight recognizer parameter prediction network (Network B). In one implementation, System A receives the raw ECG signal and sends the raw ECG signal along with the R-wave position recognition result generated by System A based on the raw ECG signal to System B. System B then feeds back the corresponding executable parameters to System A.

[0032] Based on this, this invention provides a specific implementation of a method for recognizing R-waves in electrocardiogram signals based on a dual neural network. It includes: (a) Receive the ECG signal to be identified (i.e., the original ECG signal).

[0033] (ii) During the process of generating R-wave position recognition results based on the ECG signal to be recognized by the R-wave recognition subsystem, monitor whether the start-up conditions of the parameter correction subsystem based on the dual neural network are met.

[0034] In one implementation, the R-wave fast identifier uses a template matching algorithm to process the ECG signal to be identified and generates the corresponding R-wave position identification result. Considering that the parameter correction subsystem has a built-in high-performance R-wave detection network, and due to its high computational load, the parameter correction subsystem does not operate in a continuous manner. Instead, it operates only when the startup conditions of the parameter correction subsystem are met during processing. These startup conditions can be periodic or triggered.

[0035] Specifically, based on the runtime information of the R-wave fast identifier and / or the R-wave position recognition results it generates, it is determined whether the activation conditions of the parameter correction subsystem based on the dual neural network are met. The method of determining whether the activation conditions are met based on runtime information is periodic activation. Specifically, when the runtime information of the R-wave fast identifier reaches a preset composite period, it is determined that the activation conditions of the parameter correction subsystem based on the dual neural network are met. For example, after running the traditional template matching algorithm for N seconds, the parameter correction subsystem is activated to verify this signal. The method of determining whether the activation conditions are met based on the R-wave position recognition results is triggered activation. Specifically, when the evaluation index corresponding to the R-wave position recognition result does not reach a preset index threshold, it is determined that the activation conditions of the parameter correction subsystem based on the dual neural network are met. For example, when the signal-to-noise ratio or confidence level of the template matching algorithm itself decreases, the parameter correction subsystem is triggered to verify this signal.

[0036] (iii) Through the parameter correction subsystem based on dual neural networks, the supervision conclusion corresponding to the R-wave recognition subsystem is generated based on the ECG signal to be identified, and the supervision conclusion is converted into the executable parameters of the R-wave recognition subsystem.

[0037] First, the high-performance R-wave detection network (Network A) and the lightweight recognizer parameter prediction network (Network B) will be explained.

[0038] A high-performance R-wave detection network (Network A) acts as a high-precision "teacher" or "referee." Network A receives the raw ECG signal stream and outputs the sequence of R-wave positions it identifies. Network A has a complex design and may employ deep CNN+BiLSTM or Transformer structures to ensure extremely high detection accuracy. Its output is implicitly considered as a near-gold standard reference value within the system. For example, in this embodiment, Network A may have the following structure: the input layer receives a standardized single-lead ECG signal, with the input parameter being a 5-second signal segment at a sampling rate of 250Hz, corresponding to an input dimension of 1250 sampling points; the input data undergoes zero-mean unit variance normalization to eliminate individual differences and baseline drift interference. It also includes a multi-scale feature extraction module, a temporal modeling module, and a position regression module. The multi-scale feature extraction module consists of three parallel one-dimensional convolutional branches: the first branch uses 64 convolutional kernels of size 21 with a stride of 1 to capture the wide morphological features of the R-wave; the second branch uses 64 convolutional kernels of size 11 to extract medium-scale features of the R-wave; and the third branch uses 64 convolutional kernels of size 5 to focus on the sharp edge details of the R-wave. The outputs of each branch are concatenated along the channel dimension and then compressed using a max-pooling layer (pooling size 4, stride 4). The temporal modeling module uses two layers of bidirectional gated recurrent units, each with 128 hidden units, for bidirectional processing in the sequence direction. This module is followed by a multi-head self-attention mechanism, setting four attention heads, each with 32-dimensional features, adaptively weighting to highlight key segments of the R-wave. The location regression module comprises a two-layer dilated convolutional network. The first layer uses 64 dilated kernels of size 3 with a dilation rate of 2; the second layer uses 32 dilated kernels of size 3 with a dilation rate of 4, thus expanding the receptive field while maintaining sequence resolution. Finally, a fully connected layer outputs the R-wave presence probability at each sampling point, and a sigmoid activation function is used to generate a confidence score in the [0,1] interval. The entire network A employs an end-to-end training strategy, using a weighted binary cross-entropy loss function with a positive-to-negative sample weight ratio of 1:10 to address the imbalance of positive and negative samples at R-wave locations. This network structure, through multi-scale convolutional kernel configuration, dilated convolution to expand the receptive field, and attention mechanism to weight important features, significantly improves detection accuracy and robustness under noisy environments and pathological signal conditions while maintaining high temporal resolution.

[0039] The lightweight recognizer parameter prediction network (Network B) is a carefully designed lightweight network (such as SqueezeNet, MobileNet, or a small CNN) whose input is the supervised conclusion and whose output is a set of optimized executable parameters. For example, assuming system A uses a template matching algorithm, Network B will output the executable parameters of the template matching algorithm. For example, in this embodiment, Network B can have the following structure: Input: A segment of ECG signal with a fixed length of L (e.g., containing at least 2-3 heartbeats, such as 2 seconds, with a sampling rate of 250Hz, then L=500). Output: 30-dimensional template, 1-dimensional threshold, and 1-dimensional periodicity. The network architecture uses a 1D convolutional network + fully connected layers. The specific structure is as follows: 1D convolutional layer (kernel size = 7, number of channels = 32, stride = 1, activation function = ReLU); max pooling (pooling size = 2); 1D convolutional layer (kernel size = 5, number of channels = 64, stride = 1, activation function = ReLU); max pooling (pooling size = 2); 1D convolutional layer (kernel size = 3, number of channels = 128, stride = 1, activation function = ReLU); global average pooling (pooling away the time dimension) or using Flatten followed by a fully connected layer; fully connected layer (256 units, ReLU); fully connected layer (128 units, ReLU); output layer: 30 (template) + 1 (threshold) + 1 (refractory period). The template value should be within the amplitude range of the ECG signal, the threshold is a number between 0 and 1, and the refractory period is a positive integer. This is a deep neural network specifically designed to optimize the template matching algorithm for R-wave detection. The network employs a multi-branch architecture, enabling it to automatically learn optimal template matching parameters from the original ECG signal and R-wave marker positions. For the template matching algorithm of system A, if the current signal is outside the refractory period, the current ECG signal and 30-dimensional template parameters are used for calculation. The output value is compared with a threshold; if it exceeds the threshold, the current signal is considered an R-wave.

[0040] Based on this, see Figure 3 The flowchart shown illustrates a process for determining the executable parameters of a fast R-wave identifier. It includes network A identifying the ECG signal to be identified sent by system A, comparing the identification results of network A with those of system A to determine if system A needs improvement. If so, network B is used to optimize the parameters of system A. Specifically, the executable parameters of the fast R-wave identifier can be determined according to the following steps: (a) An R-wave position sequence is generated based on the ECG signal to be identified using an R-wave detection network. For example, the input of the R-wave detection network is the ECG signal to be identified, and the output is the R-wave position sequence.

[0041] (b) Based on the R-wave position sequence and R-wave position identification results, determine whether to calibrate the R-wave fast identifier. In one embodiment, if there is a deviation between the R-wave position sequence and the R-wave position identification results, and the duration of the deviation exceeds a preset duration threshold, it is determined that the R-wave fast identifier should be calibrated. Specifically, in this embodiment of the invention, the output results of network A (i.e., the R-wave position sequence) are continuously compared with the output results of the current template matching algorithm (i.e., the R-wave position identification results). When a significant and continuous deviation occurs between the two within a certain time window (e.g., a missed ventricular premature beat or a false high T wave), it is determined that the template matching algorithm has malfunctioned or its performance has degraded due to parameter mismatch, and at this time, it is determined that the R-wave fast identifier should be calibrated.

[0042] (c) If so, construct the supervision conclusions corresponding to the R-wave fast identifyer based on the R-wave location sequence, and convert the supervision conclusions into executable parameters of the R-wave fast identifyer. Specifically, this includes the following steps: Step 1: Determine the R-wave attribute information corresponding to the R-wave location sequence. The R-wave attribute information includes the number of R-waves, the start time of the R-waves, and the end time of the R-waves. For an R-wave location sequence, the number of R-waves, start time, and end time can be directly extracted.

[0043] Step 2: Based on R-wave attribute information, extract ECG signals from abnormal time periods from the ECG signals to be identified. The ECG signals from abnormal time periods can be understood as ECG signals that match the R-wave position sequence corresponding to the R-wave position identification results that have deviated.

[0044] Step 3: Use the R-wave attribute information and the ECG signal during the abnormal period as the supervision conclusion corresponding to the R-wave rapid identifier.

[0045] Step 4: Based on the supervised conclusions, the executable parameters of the R-wave fast recognizer are generated through the recognizer parameter prediction network. In specific implementation, the progress conclusions of the ECG signal, including the number of R waves, R-wave start time, R-wave end time, and abnormal period, are input into the lightweight recognizer parameter prediction network B. Network B predicts a set of executable parameters most suitable for the current signal morphology in real time based on the specific morphological characteristics of this signal.

[0046] (iv) The executable parameters are assigned to the R-wave recognition subsystem, which generates a new R-wave position recognition result based on the ECG signal to be recognized. In specific implementation, after the recognizer parameter prediction network outputs the optimal executable parameters, these new parameters are immediately assigned to the template matching algorithm. The template matching algorithm uses the new parameters to continue processing subsequent ECG signals, thereby improving its output accuracy in real time and realigning it with the result of network A.

[0047] In summary, the working logic of this invention is as follows: For the vast majority of the time, the system relies on a low-power template matching algorithm for real-time R-wave detection, ensuring real-time performance. Simultaneously, intermittent supervision is performed through a high-performance R-wave detection network A, and the supervision conclusions of the R-wave detection network A are transformed into executable parameters through a lightweight identifier parameter prediction network B, forming an efficient closed loop of monitoring, diagnosis, and optimization. This dynamically maintains the template matching algorithm at its optimal performance state, achieving a balance between accuracy and real-time performance. Compared to existing technologies, this invention offers the following technical advantages: (1) Compared to purely traditional algorithm schemes, such as Pan-Tompkins and its various improved variants mentioned above, this is currently the most widely used scheme. As mentioned above, its shortcomings are that it cannot adapt to dynamically changing environments, and its accuracy cannot meet the requirements of high-reliability medical diagnosis. The embodiments of this invention overcome this shortcoming by dynamically optimizing its core parameters through neural networks.

[0048] (2) Compared to pure end-to-end deep learning solutions: In recent years, a large number of studies have proposed various complex neural network models, achieving an accuracy of nearly 99% on public datasets (such as MIT-BIH). However, these solutions have extremely high computational complexity, making them difficult to deploy on embedded terminals. They usually require uploading data to the cloud for computation, introducing latency, network dependence, and poor privacy. The embodiments of this invention separate the computation of the neural network from the continuous detection task, using it only for intermittent guidance and parameter prediction, thus isolating the complexity and accuracy of the system.

[0049] (3) Compared to simple hybrid solutions: There are some attempts to combine the two approaches, such as using traditional algorithms for coarse detection first, and then using neural networks to filter the results. However, these solutions are usually serial or post-processing modes, failing to form an effective feedback loop. The parameters of traditional algorithms are still static or adjusted by simple rules, and their performance upper limit is locked. The innovation of this embodiment lies in the introduction of a second lightweight network B, which is specifically used to generate optimization parameters, thereby forming an intelligent and adaptive feedback control system, which is the key difference from all simple hybrid solutions.

[0050] Based on this, the embodiments of the present invention have at least the following characteristics: The technical advantages include: (1) High accuracy: Through the supervision and correction of high-performance neural network A, the overall R-wave detection accuracy of the system approaches or even reaches the level of pure deep learning models, which is far superior to traditional fixed-parameter algorithms. (2) High efficiency in real-time performance: Detection is performed by a highly optimized template matching algorithm 99% of the time, with extremely low computational overhead, meeting the stringent requirements of devices such as IABP that have extremely high requirements for the real-time performance and accuracy of R-wave recognition. (3) Strong adaptive capability: The system can automatically adapt to changes in ECG signal morphology under different activity states and different pathological conditions, and has extremely strong robustness. (4) Modularity and flexibility: Network A and Network B can be upgraded and optimized independently. For example, when there is a more advanced R-wave detection model, only Network A needs to be updated without changing the entire system architecture.

[0051] The commercial advantages include: (1) Reduced hardware costs: This solution does not require a high-end GPU (Graphics Processing Unit) or NPU (Neural Network Processing Unit), but only a regular MCU (Microcontroller Unit) or a low-power DSP (Digital Signal Processor), which significantly reduces the hardware cost per unit. (2) Improved user experience: Fewer false alarms and false negatives mean more reliable health data and lower user anxiety, thus enhancing the user experience.

[0052] Based on the foregoing embodiments, this invention provides a dual-neural network-based ECG signal R-wave recognition device. This device is applied to a system comprising an R-wave recognition subsystem and a parameter correction subsystem based on a dual-neural network. (See [link to relevant documentation]). Figure 4 The diagram shows a structural schematic of an ECG signal R-wave recognition device based on a dual neural network. The device includes: Signal receiving module 402 is used to receive the electrocardiogram signal to be identified; The monitoring module 404 is used to monitor whether the start-up conditions of the parameter correction subsystem based on the dual neural network are met during the process of generating the R-wave position recognition result based on the ECG signal to be recognized by the R-wave recognition subsystem. The correction module 406 is used to generate a supervision conclusion corresponding to the R-wave recognition subsystem based on the ECG signal to be identified through a parameter correction subsystem based on a dual neural network when the judgment result of the monitoring module is yes, and to convert the supervision conclusion into executable parameters of the R-wave recognition subsystem. The recognition module 408 is used to assign executable parameters to the R-wave recognition subsystem, and through the R-wave recognition subsystem, generate a new R-wave position recognition result based on the ECG signal to be recognized.

[0053] The device provided in this invention empowers the R-wave recognition subsystem by utilizing a parameter correction subsystem based on a dual neural network. That is, when the activation conditions of the parameter correction subsystem are met, the parameter correction subsystem is used to supervise the R-wave recognition subsystem, and the supervision conclusion is converted into executable parameters of the R-wave recognition subsystem, thereby empowering the R-wave recognition subsystem to perform R-wave recognition tasks more accurately. This invention can simultaneously leverage the advantages of high precision of neural networks and high efficiency of traditional algorithms.

[0054] The device provided in this embodiment of the invention has the same implementation principle and technical effect as the aforementioned method embodiment. For the sake of brevity, any parts not mentioned in the device embodiment can be referred to the corresponding content in the aforementioned method embodiment.

[0055] This invention provides an electronic device, specifically, the electronic device includes a processor and a memory; the memory stores a computer program, which, when run by the processor, executes the method described in any of the above embodiments.

[0056] Figure 5 The present invention provides a schematic diagram of the structure of an electronic device 100, which includes a processor 50, a memory 51, a bus 52 and a communication interface 53. The processor 50, the communication interface 53 and the memory 51 are connected through the bus 52. The processor 50 is used to execute executable modules, such as computer programs, stored in the memory 51.

[0057] The memory 51 may include high-speed random access memory (RAM) or non-volatile memory, such as at least one disk storage device. Communication between this system network element and at least one other network element is achieved through at least one communication interface 53 (which can be wired or wireless), such as the Internet, wide area network, local area network, metropolitan area network, etc.

[0058] Bus 52 can be an ISA bus, PCI bus, or EISA bus, etc. The bus can be divided into address bus, data bus, control bus, etc. For ease of representation, Figure 5 The symbol is represented by a single double-headed arrow, but this does not mean that there is only one bus or one type of bus.

[0059] The memory 51 is used to store programs. After receiving an execution instruction, the processor 50 executes the programs. The method executed by the device for defining the flow process disclosed in any of the foregoing embodiments of the present invention can be applied to the processor 50 or implemented by the processor 50.

[0060] Processor 50 may be an integrated circuit chip with signal processing capabilities. In implementation, each step of the above method can be completed by the integrated logic circuitry in the hardware of processor 50 or by instructions in software form. Processor 50 can be a general-purpose processor, including a Central Processing Unit (CPU), a Network Processor (NP), etc.; it can also be a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), a Field-Programmable Gate Array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components. It can implement or execute the methods, steps, and logic block diagrams disclosed in the embodiments of this invention. The general-purpose processor can be a microprocessor or any conventional processor. The steps of the methods disclosed in the embodiments of this invention can be directly embodied in the execution of a hardware decoding processor, or executed by a combination of hardware and software modules in the decoding processor. The software modules can reside in random access memory, flash memory, read-only memory, programmable read-only memory, electrically erasable programmable memory, registers, or other mature storage media in the art. The storage medium is located in memory 51. The processor 50 reads the information in memory 51 and, in conjunction with its hardware, completes the steps of the above method.

[0061] The computer program product of the readable storage medium provided in the embodiments of the present invention includes a computer-readable storage medium storing program code. The instructions included in the program code can be used to execute the methods described in the foregoing method embodiments. For specific implementation, please refer to the foregoing method embodiments, which will not be repeated here.

[0062] If the aforementioned functions are implemented as software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, or the part that contributes to the prior art, or a portion of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present invention. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0063] Finally, it should be noted that the above-described embodiments are merely specific implementations of the present invention, used to illustrate the technical solutions of the present invention, and not to limit it. The scope of protection of the present invention is not limited thereto. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that any person skilled in the art can still modify or easily conceive of changes to the technical solutions described in the foregoing embodiments within the technical scope disclosed in the present invention, or make equivalent substitutions for some of the technical features; and these modifications, changes, or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention, and should all be covered within the scope of protection of the present invention. Therefore, the scope of protection of the present invention should be determined by the scope of the claims.

Claims

1. A dual neural network based R-wave identification method for electrocardiogram signals, characterized in that, The method is applied to a system comprising an R-wave identification subsystem and a double neural network-based parameter correction subsystem, and the method comprises: receiving an electrocardio signal to be identified; during the process of generating an R-wave position identification result based on the electrocardio signal to be identified by the R-wave identification subsystem, listening to whether a starting condition of the double neural network-based parameter correction subsystem is met; if yes, generating a supervision conclusion corresponding to the R-wave identification subsystem based on the electrocardio signal to be identified by the double neural network-based parameter correction subsystem, and converting the supervision conclusion into executable parameters of the R-wave identification subsystem; assigning the executable parameters to the R-wave identification subsystem, and generating a new R-wave position identification result based on the electrocardio signal to be identified by the R-wave identification subsystem. 2.The dual neural network-based electrocardiosignal R-wave identification method according to claim 1, characterized in that, The R-wave identification subsystem is built-in with an R-wave fast identifier; listening to whether the starting condition of the double neural network-based parameter correction subsystem is met comprises: judging whether the starting condition of the double neural network-based parameter correction subsystem is met based on running time information of the R-wave fast identifier and / or an R-wave position identification result generated by the R-wave fast identifier. 3.The dual neural network based ECG R-wave detection method of claim 2, wherein, Judging whether the starting condition of the double neural network-based parameter correction subsystem is met based on the running time information of the R-wave fast identifier and / or the R-wave position identification result generated by the R-wave fast identifier comprises: in the case that the running time information of the R-wave fast identifier reaches a preset composite period, and / or in the case that an evaluation index corresponding to the R-wave position identification result does not reach a preset index threshold, it is determined that the starting condition of the double neural network-based parameter correction subsystem is met.

4. The dual neural network-based ECG R-wave detection method of claim 2, wherein, The double neural network-based parameter correction subsystem is built-in with an R-wave detection network; generating a supervision conclusion corresponding to the R-wave identification subsystem based on the electrocardio signal to be identified by the double neural network-based parameter correction subsystem, and converting the supervision conclusion into executable parameters of the R-wave identification subsystem comprises: generating an R-wave position sequence based on the electrocardio signal to be identified by the R-wave detection network, judging whether to correct the R-wave fast identifier based on the R-wave position sequence and the R-wave position identification result; if yes, constructing a supervision conclusion corresponding to the R-wave fast identifier based on the R-wave position sequence, and converting the supervision conclusion into executable parameters of the R-wave fast identifier.

5. The dual neural network-based ECG R-wave detection method of claim 4, wherein, Judging whether to correct the R-wave fast identifier based on the R-wave position sequence and the R-wave position identification result comprises: in the case that there is a deviation between the R-wave position sequence and the R-wave position identification result, and a duration of the deviation is greater than a preset duration threshold, it is determined that the R-wave fast identifier is to be corrected.

6. The dual neural network-based ECG R-wave detection method of claim 4, wherein, Constructing a supervision conclusion corresponding to the R-wave fast identifier based on the R-wave position sequence comprises: determining R-wave attribute information corresponding to the R-wave position sequence, the R-wave attribute information comprising an R-wave number, an R-wave start time and an R-wave end time; extract an abnormal period electrocardio signal from the electrocardio signal to be identified based on the R wave attribute information; take the R wave attribute information and the abnormal period electrocardio signal as a supervision conclusion corresponding to the R wave fast identifier.

7. The dual neural network-based ECG R-wave detection method of claim 4, wherein, The parameter correction subsystem based on the double neural network further has an identifier parameter prediction network built-in; and the supervision conclusion is converted into executable parameters of the R wave fast identifier, including: The executable parameters of the R wave fast identifier are generated based on the supervision conclusion through the identifier parameter prediction network.

8. A dual neural network-based electrocardiosignal R-wave recognition device, characterized by, The device is applied to a system including an R wave identification subsystem and a parameter correction subsystem, and the device includes: a signal receiving module configured to receive an electrocardio signal to be identified; a monitoring module configured to monitor whether a starting condition of the parameter correction subsystem based on the double neural network is met in a process of generating an R wave position identification result based on the electrocardio signal to be identified by the R wave identification subsystem; a correction module configured to, when the determination result of the monitoring module is yes, generate a supervision conclusion corresponding to the R wave identification subsystem based on the electrocardio signal to be identified by the parameter correction subsystem based on the double neural network, and convert the supervision conclusion into executable parameters of the R wave identification subsystem; an identification module configured to assign the executable parameters to the R wave identification subsystem, and generate a new R wave position identification result based on the electrocardio signal to be identified by the R wave identification subsystem.

9. An electronic device, comprising: The computer readable storage medium stores computer executable instructions, and the computer executable instructions, when called and executed by the processor, cause the processor to implement the method in any one of claims 1 to 7.

10. A computer-readable storage medium, characterized in that, The computer readable storage medium stores computer executable instructions, and the computer executable instructions, when called and executed by the processor, cause the processor to implement the method in any one of claims 1 to 7.