An electrocardiosignal processing device for smart wearables
Patent Information
- Application Number
- CN202610975860.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-07-02
- Publication Date
- 2026-09-25
AI Technical Summary
[0005]本发明旨在解决现有心电信号处理装置采用一刀切计算模式导致的算力浪费和无效能耗问题,提供一种具备高计算效率、低能耗及动态算力调度能力的用于智能穿戴设备的心电信号处理装置
(一)通过使一阶分类判别网络基于浅层次特征判断心电信号是否正常,如果正常,则直接根据浅层次特征得到一阶分类结果(即心律类别)输出,并控制二阶分类网络不工作,此时,一阶分类结果就是最终预测结果,如果不正常,则将浅层次特征输出至二阶分类网络,并控制二阶分类网络工作,二阶分类网络基于浅层次特征提取深层次特征,根据深层次特征得到二阶分类结果输出,此时二阶分类结果就是最终预测结果;由此,使一阶分类判别网络和二阶分类网络形成动态级联分诊检测架构。
Smart Images

Figure CN122818017A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of intelligent network model data processing technology, and in particular to an electrocardiogram signal processing device for intelligent wearable devices. Background Technology
[0002] Myocardial infarction and arrhythmia are considered among the most common and deadliest cardiovascular diseases in the world, posing a significant threat to human health. The incidence of cardiovascular diseases is rising annually with an aging population. After onset, they can lead to serious complications such as heart failure and sudden cardiac death, severely impacting patients' quality of life and even endangering their lives. Early diagnosis and real-time intervention are crucial for improving the prognosis of cardiovascular disease patients and reducing mortality. However, traditional cardiovascular disease screening methods largely rely on standard hospital electrocardiographs or Holter monitors. This not only incurs high economic and time costs for patients but also makes long-term, comfortable daily monitoring difficult, limiting the widespread adoption of early screening and warning systems for cardiovascular diseases.
[0003] Cardiovascular abnormalities are often transient and insidious. With the development of smart wearable devices, long-term continuous monitoring using these devices has become possible.
[0004] Currently, ECG monitoring systems for smart wearable devices typically include an ECG signal detection device for acquiring ECG signals and an ECG signal processing device for processing the ECG signals. In current commercially available ECG monitoring systems for smart wearable devices, the ECG signal processing device generally uses a static inference neural network model to infer the ECG signals and predict whether the heart rhythm is normal or abnormal. Abnormal heart rhythms include supraventricular premature beats, ventricular premature beats, fusion beats, and noisy beats. This approach has significant technical bottlenecks, particularly in the conflict between power consumption control and computational resource allocation: the static inference neural network model lacks the ability to discern the semantic complexity of the signals. Regardless of whether the input ECG signal is abnormal, all data flows are driven through a complete deep network algorithm for full computation. In actual long-term clinical monitoring, normal ECG signals constitute the vast majority. Existing ECG signal processing devices use this one-size-fits-all computational model, allocating the same computational resources to these highly prevalent normal ECG signals as to abnormal ECG signals. This indiscriminate computation of the complete algorithm not only wastes computing power and energy, but also triggers additional memory access operations, affecting the battery life of wearable ECG monitoring systems and making it difficult to meet the actual needs of long-term non-invasive screening. Summary of the Invention
[0005] The present invention aims to solve the problem of wasted computing power and ineffective energy consumption caused by the one-size-fits-all computing mode of existing electrocardiogram (ECG) signal processing devices, and provides an ECG signal processing device for smart wearable devices with high computing efficiency, low energy consumption and dynamic computing power scheduling capabilities.
[0006] The technical solution adopted by the present invention to solve the above-mentioned technical problems is as follows: an electrocardiogram (ECG) signal processing device for smart wearable devices, comprising a first-order classification discriminant network and a second-order classification network. The first-order classification discriminant network is used to extract shallow features from the ECG signal and determine whether the ECG signal is normal based on the shallow features. If normal, the first-order classification result is directly output based on the shallow features, and the second-order classification network is controlled to not work. If abnormal, the shallow features are output to the second-order classification network, and the second-order classification network is controlled to work. The second-order classification network is used to extract deep features based on the shallow features and obtain a second-order classification result, i.e., heart rhythm category output, based on the deep features.
[0007] Compared with the prior art, the advantages of the present invention are as follows: (i) By enabling the first-order classification discriminant network to determine whether the electrocardiogram signal is normal based on shallow features, if it is normal, the first-order classification result (i.e., heart rhythm category) is directly output based on the shallow features, and the second-order classification network is controlled not to work. At this time, the first-order classification result is the final prediction result. If it is abnormal, the shallow features are output to the second-order classification network, and the second-order classification network is controlled to work. The second-order classification network extracts deep features based on the shallow features and outputs the second-order classification result based on the deep features. At this time, the second-order classification result is the final prediction result. Thus, the first-order classification discriminant network and the second-order classification network form a dynamic cascaded triage detection architecture.
[0008] (ii) When the electrocardiogram signal is normal, this dynamic cascaded triage detection architecture only needs to trigger the local network processing flow to meet the processing accuracy requirements. At this time, only the first-order classification and discrimination network participates in the inference calculation, thereby significantly reducing redundant computational overhead while ensuring classification accuracy.
[0009] (III) When the electrocardiogram (ECG) signal is abnormal, the dynamic cascaded triage detection architecture triggers the complete network processing flow to avoid insufficient processing accuracy. At this time, both the first-order classification discriminant network and the second-order classification network participate in the inference calculation; the first-order classification discriminant network performs shallow feature extraction on the ECG signal, and the second-order classification network extracts deep features based on the shallow features, and outputs the second-order classification result (i.e., heart rhythm category) based on the deep features.
[0010] (iv) Since most ECG signals are normal and abnormalities are rare, this invention can adaptively configure the computing power of the dynamic cascaded triage detection architecture according to whether the current ECG signal is normal or not, breaking the technical bottleneck of fixed computing power overhead of existing ECG signal processing devices. While ensuring classification accuracy, it significantly reduces redundant computing overhead and has high computing efficiency, low energy consumption and dynamic computing power scheduling capabilities.
[0011] In summary, this invention offers strong scalability, dynamically invoking its internal network based on the normality of ECG signals. It rapidly processes large amounts of normal ECG signal data through a first-order classification network, activating a second-order classification network only when necessary to effectively extract deep features. This low-power optimization for continuous ECG signal monitoring alleviates the dynamic power consumption of storage on edge devices, resulting in minimal resource consumption. It is suitable for embedding in portable smart wearable devices such as smartwatches, meeting the long-term monitoring needs in primary and routine medical scenarios, and thus has high potential for widespread adoption. Furthermore, by equipping portable smart wearable devices with an ECG monitoring system using this invention's ECG signal processing device, accurate preliminary screening of heart rhythm categories can be performed locally with low power consumption. This reduces reliance on cardiologists and provides reliable data for clinical diagnosis. Therefore, this invention's ECG signal processing device not only provides technical support for remote areas, home health management, and resource-scarce medical scenarios but also balances the "high precision and long battery life" of edge medical devices, potentially improving the early prediction of cardiovascular diseases.
[0012] In a further technical solution, the first-order classification and discrimination network includes a first-order network, a first-order classification judgment module, and a first-order classification result output module. The first-order network receives electrocardiogram (ECG) signals and performs lightweight shallow feature extraction and fast forward convolution calculation, extracting shallow features and outputting them to the first-order classification judgment module. The first-order classification judgment module determines whether the ECG signal is normal based on the shallow features. If normal, the shallow features are output to the first-order classification result output module, and the computation flow and memory access operations of the second-order classification network are simultaneously truncated. If abnormal, an activation command is output to the second-order classification network to control its operation, and the shallow features are output to the second-order classification network. The first-order classification result output module performs classification reasoning on the shallow features to obtain the first-order classification result output.
[0013] As a preferred technical solution, the first-order network includes a one-dimensional convolutional layer, a first residual module, a second residual module, a third residual module, a first max pooling layer, a second max pooling layer, a third max pooling layer, and a first fully connected layer; the one-dimensional convolutional layer, the first residual module, the first max pooling layer, the second residual module, the second max pooling layer, the third residual module, the third max pooling layer, and the first fully connected layer are connected sequentially.
[0014] Specifically, the one-dimensional convolutional layer is used to input the electrocardiogram (ECG) signal and perform one-dimensional convolutional filtering and feature mapping on the ECG signal to obtain an initial feature signal output containing basic waveform features; the first residual module is used to input the initial feature signal and perform residual connection and deep feature extraction processing on the initial feature signal to obtain a first residual feature signal output; the first max pooling layer is used to input the first residual feature signal and perform spatial dimensionality reduction and local saliency preservation downsampling processing on the first residual feature signal to obtain a first pooled feature signal output; the second residual module is used to input the first pooled feature signal and perform residual calculation and mid-layer semantic feature extraction processing on the first pooled feature signal to obtain a second residual feature signal output; the second max pooling layer is used to input the first pooled feature signal and perform residual calculation and mid-layer semantic feature extraction processing on the first pooled feature signal to obtain a second residual feature signal output; the second max pooling layer is used to input the first pooled feature signal and perform residual calculation and mid-layer semantic feature extraction processing on the first pooled feature signal to obtain a second residual feature signal output; the second max pooling layer is used to input the first pooled feature signal and perform residual connection and deep ... deep feature extraction processing on the first pooled feature signal to obtain a first residual feature signal output; the second max pooling layer is used to input the first pooled feature signal and perform deep feature extraction processing on the first pooled feature signal to obtain a first residual feature signal output; the second max The max pooling layer is used to receive the second residual feature signal and perform downsampling processing on the second residual feature signal through secondary spatial dimensionality reduction and feature compression to obtain the second pooled feature signal output. The third residual module is used to receive the second pooled feature signal and perform deep residual calculation and high-level semantic feature extraction processing on the second pooled feature signal to obtain the third residual feature signal output. The third max pooling layer is used to receive the third residual feature signal and perform final spatial dimensionality reduction and feature-intensive downsampling processing on the third residual feature signal to obtain the third pooled feature signal output. The first fully connected layer is used to receive the third pooled feature signal and perform feature flattening and global linear mapping processing on the third pooled feature signal to obtain the shallow feature output.
[0015] In a further technical solution, the second-order classification network includes a second-order network, a second-order classification judgment module, and a second-order classification result output module; the second-order network is connected to the first-order classification judgment module; the second-order classification judgment module is connected to the second-order network, and the second-order classification result output module is connected to the second-order classification judgment module.
[0016] Specifically, when the first-order classification module outputs an activation command, the second-order network receives the activation command, is dynamically activated, and enters the working state. At this time, the second-order network uses a high-efficiency convolution operator to perform deep feature mining and derivation on the shallow features, extracts deep features, and outputs them to the second-order classification module. The second-order classification module performs inference calculations on the deep features to obtain a second-order classification result, which is then output to the second-order classification result output module, which outputs the second-order classification result.
[0017] As a preferred technical solution, the second-order network includes a first Ghost module, a second Ghost module, a fourth max-pooling layer, a second fully connected layer, and a third fully connected layer; the first Ghost module is connected to the second Ghost module, the second Ghost module is connected to the fourth max-pooling layer, the fourth max-pooling layer is connected to the second fully connected layer, and the second fully connected layer is connected to the third fully connected layer in sequence.
[0018] Specifically, the first Ghost module is used to access the shallow features and perform combined convolution processing of the shallow features with a main convolutional layer and a depthwise separable convolutional layer to obtain a first Ghost feature signal output; the second Ghost module is used to access the first Ghost feature signal and perform combined convolution calculation on the first Ghost feature signal to extract deep semantic information to obtain a second Ghost feature signal output; the fourth max pooling layer is used to access the second Ghost feature signal and perform spatial dimensionality reduction downsampling processing on the second Ghost feature signal to obtain a pooled feature signal output; the second fully connected layer is used to access the pooled feature signal and perform feature flattening and nonlinear mapping processing on the pooled feature signal to obtain an initial deep feature signal output; the third fully connected layer is used to access the initial deep feature signal and perform global classification mapping processing on the initial deep feature signal to obtain a deep feature signal output.
[0019] As a preferred technical solution, the ECG signal processing device for smart wearable devices further includes a filtering module. The filtering module is used to perform bandpass filtering preprocessing on the original ECG signal to effectively filter out power frequency interference noise and electromyography artifact noise in the original ECG signal, and output the preprocessed ECG signal to the first-order classification and discrimination network.
[0020] Furthermore, the aforementioned ECG signal processing device for smart wearable devices can be integrated into electronic devices, enabling long-term, comfortable, real-time monitoring of the user's heart rhythm type, providing an effective means for early screening and warning of cardiovascular diseases. In specific application scenarios, this electronic device is specifically the edge hardware of smart wearable devices such as smartwatches and portable ECG monitoring patches. The electronic device mainly includes: a processor, a memory, a transceiver port, a communication port, and a communication bus. The memory, the transceiver port, and the communication port are all electrically connected to the processor and enable high-speed data communication through the communication bus. Specifically, the memory stores computer program instructions executable by the processor and model data of cascaded neural networks. To accommodate the limited storage resources at the edge, the memory internally stores the parameters of a quantized and compressed first-order classification network and a second-order classification network. Simultaneously, the memory also caches real-time acquired ECG signal segments and intermediate feature maps during runtime.
[0021] Furthermore, the processor, as the core computing and logic control unit of the electronic device, is used to read and execute the computer program stored in the memory to implement all the steps of ECG signal processing performed by the ECG signal processing device of the present invention. In actual operation, during most routine monitoring periods, only the basic computing logic is invoked, and clock gating or power-off sleep is implemented on the hardware computing unit corresponding to the second-order classification network; only when a difficult sample with ambiguous features is detected, i.e., the ECG signal is abnormal, is additional computing power awakened as needed for high-precision inference. The transceiver port, as the signal sensing and input front end, is used to directly interact with external electrodes or internal ECG sensor modules to collect the user's original ECG waveform signal in real time, and transmit the collected signal to the processor or memory through the communication bus. The communication port, as the output interaction interface of the detection results, is used to send the final high-precision classification results, abnormal warning signals, and other data obtained by the processor to an external display terminal or cloud medical system through wired or wireless networks. Attached Figure Description
[0022] Figure 1 This is a schematic diagram of the electrocardiogram signal processing device for smart wearable devices according to the present invention; Figure 2 This is a structural diagram of a first-order network for the electrocardiogram signal processing device for smart wearable devices according to the present invention; Figure 3 This is a structural diagram of a second-order network for the electrocardiogram signal processing device for smart wearable devices according to the present invention; Figure 4 This is a structural diagram of the Ghost module of the electrocardiogram signal processing device for smart wearable devices according to the present invention; Figure 5This is a structural diagram of the residual module of the electrocardiogram signal processing device for smart wearable devices according to the present invention; Figure 6 This is a flowchart illustrating the training process of the classification model consisting of a first-order classification discriminant network and a second-order classification network in the electrocardiogram signal processing device for smart wearable devices according to the present invention. Figure 7 This is a functional test diagram of the detection and recognition rate and wake-up rate of the electrocardiogram signal processing device for smart wearable devices according to the present invention; Figure 8 This is a schematic diagram of the electronic device hardware architecture for the electrocardiogram signal processing device of the present invention used in a smart wearable device. Detailed Implementation
[0023] The electrocardiogram (ECG) signal processing device of the present invention is designed for intelligent ECG signal monitoring and processing tasks. By judging whether the ECG signal is normal or not, dynamic computing power scheduling is achieved. For ECG signals judged to be normal, only a local network processing flow is executed; for ECG signals judged to be abnormal, a complete network processing flow is triggered. Thus, while ensuring the accuracy of ECG signal detection, redundant computing overhead is significantly reduced, computing efficiency is improved, energy consumption is reduced, and the battery life of the wearable ECG monitoring system is guaranteed.
[0024] To make the objectives, technical solutions, and advantages of this invention clearer, the technical solutions of this invention will be described in detail and completely below with reference to the accompanying drawings and specific embodiments, so that those skilled in the art can understand and implement them. The embodiments described in this section are only used to illustrate the technical solutions of this invention and are not intended to limit the scope of protection of this invention.
[0025] Example 1: This example provides an electrocardiogram signal processing device for smart wearable devices.
[0026] like Figure 1 and Figure 2 As shown, the ECG signal processing device includes: a filtering module, a first-order classification discriminant network, and a second-order classification network.
[0027] The first-order classification network includes a first-order network, a first-order classification decision module, and a first-order classification result output module. The first-order network and the first-order classification decision module are connected, and the first-order classification decision module and the first-order classification result output module are connected.
[0028] Specifically, the first-order network includes a one-dimensional convolutional layer, a first residual module, a first max pooling layer, a second residual module, a second max pooling layer, a third residual module, a third max pooling layer, and a first fully connected layer. The one-dimensional convolutional layer, the first residual module, the first max pooling layer, the second residual module, the second max pooling layer, the third residual module, the third max pooling layer, and the first fully connected layer are connected in sequence. The first-order classification and judgment module is connected to the first fully connected layer, and the first-order classification result output module is connected to the first-order classification and judgment module.
[0029] To achieve efficient computing on resource-constrained edge devices, this embodiment employs a lightweight design for the residual modules (first residual module, second residual module, and third residual module). For example... Figure 5 As shown, the residual module includes a first pointwise convolutional layer, a first ReLU activation layer, a first depthwise separable convolutional layer, a second ReLU activation layer, a second pointwise convolutional layer, a third ReLU activation layer, and a first addition unit connected in sequence. The first addition unit and the first pointwise convolutional layer serve as two input branches. When an external feature signal is input to the residual module, both the first addition unit and the first pointwise convolutional layer receive the external feature signal. At this time, the first pointwise convolutional layer, the first ReLU activation layer, the first depthwise separable convolutional layer, the second ReLU activation layer, the second pointwise convolutional layer, and the third ReLU activation layer sequentially extract features from the external feature signal to obtain the corresponding feature signal output. The first addition unit adds the external feature signal element-wise with the feature signal output by the third ReLU activation layer to obtain the feature signal output, thereby effectively avoiding the gradient vanishing problem in first-order network training.
[0030] In this embodiment, the second-order classification network includes a second-order network, a second-order classification judgment module, and a second-order classification result output module; the second-order network is connected to the first-order classification judgment module; the second-order classification judgment module is connected to the second-order network, and the second-order classification result output module is connected to the second-order classification judgment module.
[0031] Specifically, such as Figure 3 As shown, the second-order network includes a first Ghost module, a second Ghost module, a fourth max pooling layer, a second fully connected layer, and a third fully connected layer; the first Ghost module is connected to the second Ghost module, the second Ghost module is connected to the fourth max pooling layer, the fourth max pooling layer is connected to the second fully connected layer, and the second fully connected layer is connected to the third fully connected layer in sequence.
[0032] In this embodiment, the Ghost modules (first Ghost module and second Ghost module) are specially designed to reduce computational redundancy. For example... Figure 4As shown, the Ghost module comprises a main convolutional layer, a fourth ReLU activation layer, a second depthwise separable convolutional layer, a fifth ReLU activation layer, and a second addition unit connected in sequence. The main convolutional layer and the second addition unit serve as two input branches. When an external feature signal is input to the Ghost module, both the main convolutional layer and the second addition unit receive this external feature signal. The main convolutional layer, the fourth ReLU activation layer, the second depthwise separable convolutional layer, and the fifth ReLU activation layer sequentially extract features from the external feature signal, obtaining the corresponding feature signal output. The second addition unit then performs element-wise addition and fusion of the external feature signal with the feature signal output from the fifth ReLU activation layer to obtain the feature signal output. This design generates partial feature maps through a small number of native convolutions and then utilizes inexpensive linear operations to generate redundant feature maps, thus significantly reducing computational load and parameter size while maintaining feature representation capabilities.
[0033] Therefore, this embodiment combines the high efficiency of the residual module in the first-order classification discriminant network with the low computational redundancy of the Ghost module in the second-order classification network, making it suitable for real-time ECG inference in the hardware of smart wearable devices with limited power consumption and computing power.
[0034] The specific working process of the electrocardiogram signal processing device in this embodiment is as follows: When the original ECG signal is output to the filtering module, the filtering module performs bandpass filtering preprocessing on the original ECG signal to effectively filter out power frequency interference noise and electromyography artifact noise in the original ECG signal, and the preprocessed ECG signal is output to the one-dimensional convolutional layer.
[0035] A one-dimensional convolutional layer performs one-dimensional convolutional filtering and feature mapping on the ECG signal to obtain an initial feature signal output containing basic waveform features. A first residual module receives the initial feature signal and performs residual concatenation and deep feature extraction processing to obtain a first residual feature signal output. A first max-pooling layer receives the first residual feature signal and performs spatial dimensionality reduction and local saliency preservation downsampling processing to obtain a first pooled feature signal output. A second residual module receives the first pooled feature signal and performs residual calculation and mid-layer semantic feature extraction processing to obtain a second residual feature signal output. A second max-pooling layer receives the second residual feature signal. The second residual feature signal is processed by a second spatial dimensionality reduction and feature compression downsampling to obtain the second pooling feature signal output. The third residual module receives the second pooling feature signal and performs deep residual calculation and high-level semantic feature extraction on the second pooling feature signal to obtain the third residual feature signal output. The third max pooling layer receives the third residual feature signal and performs final spatial dimensionality reduction and highly condensed feature downsampling on the third residual feature signal to obtain the third pooling feature signal output. The first fully connected layer receives the third pooling feature signal and performs feature flattening and global linear mapping on the third pooling feature signal to obtain shallow feature output to the first-order classification judgment module.
[0036] The first-order classification judgment module determines whether the ECG signal is normal based on the shallow features output by the first-order classification judgment module. If normal, the shallow features are output to the first-order classification result output module, and the second-order network computation flow and memory access operations are simultaneously truncated. At this time, the first-order classification result output module performs classification reasoning on the shallow features to obtain the first-order classification result output. If abnormal, an activation command is output to the first Ghost module, and the shallow features are output to the first Ghost module.
[0037] The first Ghost module performs combined convolution processing on shallow features using a main convolutional layer and a depthwise separable convolutional layer to obtain the first Ghost feature signal output. The second Ghost module takes the first Ghost feature signal and performs combined convolution calculations on it to extract deep semantic information, obtaining the second Ghost feature signal output. The fourth max pooling layer takes the second Ghost feature signal and performs spatial dimensionality reduction downsampling processing on it, obtaining the pooled feature signal output. The second fully connected layer takes the pooled feature signal and performs feature flattening and nonlinear mapping processing on it, obtaining the initial deep feature signal output. The third fully connected layer takes the initial deep feature signal and performs global classification mapping processing on it, obtaining the deep feature signal output to the second-order classification judgment module. The second-order classification judgment module performs inference calculations on the deep features and obtains the second-order classification result output to the second-order classification result output module, which then outputs the second-order classification result.
[0038] Example 2: In the ECG signal processing device for smart wearable devices in Example 1, a first-order classification discriminant network and a second-order classification network constitute a classification model.
[0039] It should be noted that this classification model needs to be trained before it can be used, so that it has the ability to predict heart rhythm categories from electrocardiogram signals.
[0040] This embodiment trains the above classification model based on the internationally standardized MIT-BIH Arrhythmia Database. The MIT-BIH Arrhythmia Database is jointly released by the Massachusetts Institute of Technology (MIT) and Beth Israel Hospital (BIH).
[0041] like Figure 6 As shown, the training method for the above classification model specifically includes the following steps: Step 1, Initialization: Randomly initialize the parameters (network connection weights, biases, etc.) of the first-order classification network and the second-order classification network; at the same time, set the relevant training hyperparameters: learning rate of 0.001, batch size of 128, maximum number of iterations of 200, initial value of triage threshold of 0.8, step size of 0.005, and upper limit of triage threshold of 0.95.
[0042] Step 2: Signal Preprocessing: The raw ECG signals from the MIT-BIH arrhythmia database are preprocessed to obtain filtered ECG signals. The preprocessing operation is bandpass filtering to eliminate electromyographic interference and power line interference. All filtered ECG signals are divided into training and test sets in a 7:3 ratio. Each filtered ECG signal in the training set and its corresponding ground truth label constitutes a training sample, and all training samples are used to construct the training sample set. Each filtered ECG signal in the test set and its corresponding ground truth label constitutes a validation sample, and all validation samples are used to construct the validation set.
[0043] Step 3, Model Training: Select training samples from the training sample set according to the set batch size, and train until the maximum number of loop iterations of 200 is reached, then stop training.
[0044] In each training epoch, the training samples are first input into the first-order classification network under the current parameter state for forward computation to obtain the first-order classification result. The first-order classification result is then quantitatively evaluated using the confidence evaluation function G(x) to obtain the corresponding confidence value. Based on the current triage threshold, training samples with a confidence value greater than or equal to the current triage threshold are classified as simple samples (normal ECG signal), and the parameters of the first-order classification network are updated based on the difference between the first-order classification result and the true label. Training samples with a confidence value lower than the current triage threshold are classified as fuzzy samples (abnormal ECG signal), and the shallow features corresponding to the fuzzy samples are input into the second-order classification network. The second-order classification network extracts deep features from the shallow features, obtains the second-order classification result based on the deep features, and updates the parameters of the second-order classification network based on the difference between the second-order classification result and the true label.
[0045] After each training epoch, two core performance metrics of the current classification model are evaluated using a validation set: the classification accuracy of the first-order classification network and the dynamic wake-up rate that triggers the second-order classification network. The classification accuracy of the first-order classification network and the dynamic wake-up rate that triggers the second-order classification network are calculated and recorded. Then, based on the calculated classification accuracy, the triage threshold is increased by a preset step size, allowing more training samples to enter the second-order classification network in the next training epoch.
[0046] Step 4: Traverse the optimal wake-up rate: On the classification model after the cyclic training is completed, execute the parameter optimization strategy. Scan and test the dynamic triage threshold recorded at the end of each training round, along with the classification accuracy of the corresponding first-order classification network and the dynamic wake-up rate that triggers the second-order classification network. Find the triage threshold and the corresponding optimal dynamic wake-up rate node that minimizes the dynamic wake-up rate of the classification model or reaches the optimal inflection point of marginal benefit.
[0047] Step 5: Update the optimal weights (i.e., parameters): Lock the found optimal triage threshold and its corresponding dynamic wake-up rate, and update and solidify the parameters of the classification model in this optimal state accordingly. Deploy the saved parameters to the hardware of the smart wearable device in actual application, and the training process ends.
[0048] Steps 3 to 5 above constitute a complete training and parameter optimization closed loop. To clearly define the specific execution logic of feature routing, performance evaluation, and parameter optimization within this closed loop, further details are provided below: First, corresponding to the sample classification logic in step 3 above and the forward inference stage after actual deployment, the ECG signal processing device performs triage decisions based on the current triage threshold. Let G(x) be the confidence assessment score (i.e., confidence value) calculated by the first-order classification discriminant network; when G(x) is greater than or equal to the current triage threshold, it is determined to be a simple sample with clear features (i.e., normal ECG signal), and the first-order classification result is directly output; when G(x) is less than the current triage threshold, it is determined to be a fuzzy sample with indistinguishable features (i.e., abnormal ECG signal), and a wake-up signal is generated to activate the second-order classification network for further classification judgment.
[0049] Secondly, corresponding to the parameter optimization strategy in step 4 above, its core objective is to minimize the energy consumption of smart wearable devices while ensuring high classification reliability. To accurately pinpoint marginal returns, this embodiment introduces a marginal accuracy return index. During the feasible region optimization scan, the inflection point where this marginal accuracy return index rapidly decays is used for determination. When the increase in the second-order classification network wake-up rate leads to a minimal improvement in the accuracy of the second-order classification network, approaching the inflection point, the parameters in this state are locked, thereby optimizing the marginal utility of computing resources and classification accuracy.
[0050] After detailing the key classification logic and parameter optimization mechanism, to intuitively demonstrate the effectiveness of the training method and triage strategy proposed in this embodiment, this embodiment provides a graph showing the relationship between the accuracy and dynamic awakening rate of the ECG signal processing device under different triage thresholds, as shown below. Figure 7 As shown.
[0051] like Figure 7 As shown, the horizontal axis represents the dynamic wake-up rate of the second-order classification network, which directly reflects the additional computing power and hardware power consumption overhead of the ECG signal processing device due to triggering the second-order classification network; the vertical axis represents the classification accuracy of the second-order classification network. Furthermore, the figure also compares the performance evolution of the ECG signal processing device under two different confidence assessment strategies: one is an assessment strategy based on the conventional SOFTMAX function, and the other is the dynamic triage threshold assessment strategy proposed in this invention.
[0052] from Figure 7 The overall curve trend shows that the ECG signal processing device of this invention has a certain basic classification capability, with an accuracy of approximately 97.65%. As the awakening rate gradually increases, meaning the ECG signal processing device of this invention allows more abnormal ECG samples judged as having ambiguous features to enter the second-order classification network for calculation, the classification accuracy shows a gradual saturation trend, first rising sharply and then leveling off. The curve trends of the two different strategies are highly consistent, which fully confirms that this invention can effectively intercept the vast majority of simple samples, while the timely intervention of the second-order network can accurately compensate for the classification accuracy of difficult samples.
[0053] Figure 7 The embedded magnified subplot details the evolution of the awakening rate within the critical performance range of 8% to 17%. It is clearly observed that within this specific range, accuracy steadily climbs from approximately 99.30% and easily surpasses the high-precision clinical baseline of 99.50%. Particularly noteworthy is the achievement of approximately 99.43% prediction accuracy when the awakening rate is controlled at around 10%. Further relaxing the threshold to increase the awakening rate significantly slows the upward trend of the curve, indicating a sharp drop in the marginal accuracy gain per unit increase in awakening rate, and a clear inflection point in the curve's utility.
[0054] The experimental data results show that the ECG signal processing device of this invention can accurately pinpoint the optimal inflection point as the best deployment point. Under ideal operating conditions, it achieves a classification accuracy of over 99.4% with only about 10% of the extremely low dynamic wake-up cost (i.e., avoiding about 90% of the additional deep computational load and memory access power consumption). This result indicates that this invention helps alleviate the problem of balancing high accuracy and low power consumption in traditional edge medical testing equipment, and optimizes the allocation of computing resources.
[0055] Example 3: To comprehensively verify the performance of the ECG signal processing device of the present invention, this example establishes a complete simulation and testing environment on a standard hardware and software platform. The entire verification process covers two stages: algorithm-level software training and system-level hardware deployment verification.
[0056] First, on a deep learning workstation equipped with an NVIDIA RTX 3060 GPU, a first-order classification and discriminant network and a second-order classification network were built using the PyCharm integrated development environment and the TensorFlow deep learning framework. Parameter initialization, loss function calculation, and backpropagation training of the first-order and second-order classification networks were completed. After obtaining the optimal network weights, they were fixed-point processed, and a corresponding RTL hardware simulation model was built in electronic design automation software using a hardware description language. Finally, it was deployed to a Xilinx XCZ7100 FPGA development platform for physical-level verification to realistically reflect the performance of the ECG signal processing device of this invention.
[0057] This embodiment uses the internationally standardized MIT-BIH arrhythmia database for evaluation. To fully verify the classification performance of the ECG signal processing device of this invention, all extracted ECG signals were divided into training and test sets in a 7:3 ratio based on patient-to-patient relationship. 70% of the data was used for training to construct the feature space, and the remaining 30% served as an independent test set for verifying the ECG signal processing device. In the preprocessing stage, after filtering and denoising the original ECG signals, a 256-bit ECG signal segment was extracted as the input signal for the first-order classification network.
[0058] The constructed ECG signal processing device was deployed and verified on the XCZ7100 FPGA platform. After capturing a segment of the ECG signal to be tested, the signal is fed into a first-order classification network to quickly extract local features and output the confidence value of the current ECG signal. If the confidence value is greater than or equal to the set triage threshold, it is determined to be a simple sample with well-defined features (i.e., a normal ECG signal), and the corresponding first-order classification result is directly output. At this time, the gating circuit remains locked, and the second-order classification network remains in a deep sleep state; conversely, if the confidence value is lower than the triage threshold, a wake-up signal is immediately triggered, activating the second-order classification network.
[0059] The trained classification model was validated using a validation set. The results show that the ECG signal processing device of this invention not only achieved a classification accuracy of 99.3% in a 7:3 data partitioning scenario, but also that the clock activation records measured on the FPGA confirmed that the overall dynamic wake-up rate was successfully suppressed to around 10%. This fully demonstrates that the ECG signal processing device of this invention achieves a physical-level reduction in power consumption at the edge while ensuring classification accuracy.
[0060] Example 4: This example provides a hardware structure for implementing a physical deployment device for an electrocardiogram (ECG) signal processing device. This device can be an edge-wearable device such as a smartwatch, a portable ECG patch, or a miniature medical monitoring terminal.
[0061] like Figure 8 As shown, the hardware structure mainly includes: a processor, a memory, a transceiver port, a communication port, and a communication bus. These hardware components are electrically connected and communicate with each other via the communication bus.
[0062] Memory: Used to store computer program instructions and classification network data for executing the classification process of the ECG signal processing device of this invention. To accommodate limited storage resources at the edge, the memory internally stores quantized and compressed first-order and second-order classification network weight files, as well as the optimal dynamic triage threshold determined through dual-constraint optimization. Simultaneously, the memory also caches ECG signals and intermediate feature maps acquired during runtime.
[0063] Processor: As the core computing and logic control unit of this hardware structure, the processor reads and executes the computer program in memory to implement the aforementioned classification method of this invention. In actual operation, the processor performs extremely low-power computing power scheduling based on the calculation results. That is, during most regular monitoring time, it only calls the basic computing logic (i.e., the first-order classification and discrimination network) and implements clock gating or sleep on the computing units corresponding to the second-order classification network; only when abnormal ECG signals are detected is the additional computing resources (second-order classification network) dynamically woke up to perform high-precision inference.
[0064] Transceiver Port: As a signal sensing and input interface, it is used to directly interact with external dry / wet electrodes or internal ECG sensor front-end modules, to collect and receive the user's single-channel or multi-channel raw ECG signals in real time, and to transmit the collected analog / digital signals to the communication bus.
[0065] Communication port: As the output and interaction interface for detection results, it is used to send the final high-precision ECG classification results, abnormal warning signals or device status information obtained by the processor to an external display terminal, user's smartphone or cloud medical system via wired or wireless network, so as to facilitate daily health management or further diagnosis by doctors.
[0066] Communication bus: Responsible for establishing a high-speed and stable data transmission channel between the processor, memory and various ports, ensuring the efficient and delay-free flow of high-frequency ECG signal data and underlying control instructions.
[0067] In summary, the hardware architecture design provided by this invention supports the dynamic routing and on-demand wake-up mechanism of the algorithm at the physical level, successfully overcoming the hardware bottleneck of short battery life in traditional portable ECG monitoring devices, and possessing industrial practical value and potential for large-scale promotion.
Claims
1. An electrocardiogram (ECG) signal processing device for a smart wearable device, comprising a first-order classification discriminant network and a second-order classification network, wherein the first-order classification discriminant network is used to extract shallow features from the ECG signal, and the second-order classification network is used to extract deep features based on the shallow features, and outputs a second-order classification result based on the deep features; characterized in that, The first-order classification network is also used to determine whether the electrocardiogram signal is normal based on the shallow features. If it is normal, the first-order classification result is directly output based on the shallow features, and the second-order classification network is controlled to not work. If it is abnormal, the shallow features are output to the second-order classification network, and the second-order classification network is controlled to work.
2. The electrocardiogram signal processing device for a smart wearable device according to claim 1, characterized in that, The first-order classification and discrimination network includes a first-order network, a first-order classification judgment module, and a first-order classification result output module. The first-order network is used to receive electrocardiogram (ECG) signals and perform lightweight shallow feature extraction and fast forward convolution calculation, extracting shallow features and outputting them to the first-order classification judgment module. The first-order classification judgment module is used to determine whether the ECG signal is normal based on the shallow features. If it is normal, the shallow features are output to the first-order classification result output module, and the computation flow and memory access operations of the second-order classification network are simultaneously truncated. If it is not normal, an activation command is output to the second-order classification network to control the operation of the second-order classification network and output the shallow features to the second-order classification network; the first-order classification result output module is used to perform classification reasoning on the shallow features to obtain the first-order classification result output.
3. The electrocardiogram signal processing device for a smart wearable device according to claim 2, characterized in that, The first-order network includes a one-dimensional convolutional layer, a first residual module, a first max pooling layer, a second residual module, a second max pooling layer, a third residual module, a third max pooling layer, and a first fully connected layer connected in sequence.
4. The electrocardiogram signal processing device for a smart wearable device according to claim 2, characterized in that, The second-order classification network includes a second-order network, a second-order classification judgment module, and a second-order classification result output module connected in sequence.
5. The electrocardiogram signal processing device for a smart wearable device according to claim 4, characterized in that, The second-order network includes a first Ghost module, a second Ghost module, a fourth max-pooling layer, a second fully connected layer, and a third fully connected layer connected in sequence.
6. The electrocardiogram signal processing device for a smart wearable device according to claim 1, characterized in that, It also includes a filtering module, which is connected to the first-order classification and discrimination network.