Ecg identification method and device, electronic equipment and storage medium
Patent Information
- Application Number
- CN202211165700.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-09-23
- Publication Date
- 2026-09-18
- Estimated Expiration
- 2042-09-23
AI Technical Summary
目前国内外研究者在实现ECG身份识别这一任务上,大多数都是使用经典的交叉熵损失函数作为目标函数,而交叉熵损失函数并不具备鼓励模型学习区分特征的能力,提取的特征不满足缺乏类内聚类间散的特性,仅能满足分类任务,面对匹配任务ECG身份识别系统的性能不佳
[0052] Additional aspects and advantages of the invention will be set forth in part in the description which follows, and in part will be obvious from the description, or may be learned by practice of the invention.
Smart Images

Figure CN115544476B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of computer technology, and in particular to an ECG identification method, apparatus, electronic device, and storage medium. Background Technology
[0002] With the development of the Internet and the continuous increase in information, in the era of the Internet of Everything, traditional identity verification methods such as ID keys and account passwords can no longer meet the ever-growing application scenarios and pose certain security risks.
[0003] Biometrics, as a supplementary means of identity verification, has been widely used. For example, facial recognition, fingerprint recognition, DNA testing, and iris recognition have all proven effective in specific application scenarios. However, all biometric identification methods have certain limitations; for instance, faces and fingerprints are easily forged, and DNA testing is difficult, limiting their applicability to certain scenarios. Electrocardiogram (ECG) signals, on the other hand, offer unique advantages.
[0004] As an intrinsic physiological signal capable of detecting biometric activity, electrocardiogram (ECG) signals offer higher security than external features such as fingerprints and faces, making them less susceptible to theft, copying, and cracking. ECG signals contain health information and can be used in certain medical fields. With the advancement of acquisition technology, mobile devices can easily acquire ECG signals, and prolonged acquisition does not require explicit user action, facilitating periodic re-authentication. ECG signals possess the universality, uniqueness, stability, and collectability essential for biometric identification. Therefore, they hold promising application prospects and significant research value as a supplementary method for biometric authentication.
[0005] ECG-based biometric authentication methods typically involve four processes: data collection, preprocessing, feature extraction, and recognition, with feature extraction and recognition being two crucial steps. ECG feature extraction methods can be categorized into baseline methods, non-baseline methods, and methods with a partial baseline approach. Recognition methods can be divided into classification tasks and matching tasks.
[0006] Baseline methods extract features based on the morphological characteristics of ECG signals, such as the amplitude, width, angle, or slope of wavelets. However, these morphological features are derived from reference points (P, Q, R, S, T, and U), making these methods heavily reliant on the quality of the heartbeat segments and the accuracy of the reference point detection techniques, lacking sufficient noise robustness and generalization. To reduce the complexity of reference point detection, some researchers have proposed non-reference point detection methods. Non-reference methods typically transform the ECG signal from the time domain to other domains, such as the frequency domain, to extract features. Some baseline methods combine baseline and non-reference methods. Searching for the R point is generally easier than searching for other points because it represents the highest and sharpest peak in a heartbeat. Therefore, some baseline methods typically segment the heartbeat by locating the R point and then extracting time-domain or frequency-domain information as features. However, R-point-based segmentation suffers from the problem of losing effective information within the ECG signal segment.
[0007] To extract deeper levels of verification, recent research has begun to use deep learning models as feature learners to extract individual ECG differential features. The objective loss function serves as the training objective of the deep learning model, guiding its iterative optimization during training. Currently, most researchers, both domestically and internationally, use the classic cross-entropy loss function as the objective function for ECG identification. However, the cross-entropy loss function does not encourage the model to learn distinguishing features, and the extracted features lack the characteristics of intra-class clustering and inter-class dispersion, only satisfying classification tasks. For matching tasks, the performance of ECG identification systems is poor. Summary of the Invention
[0008] The main objective of this invention is to provide an ECG identity recognition method, device, electronic device, and storage medium to improve the accuracy of ECG identity recognition.
[0009] One aspect of the present invention provides an ECG identity recognition method, characterized in that it includes:
[0010] In response to an ECG identification request, a dataset of ECG signal samples to be processed is obtained, which is used to characterize the raw signal data for feature extraction.
[0011] The ECG signal sample dataset was processed to remove baseline drift, power line interference, and electromyographic noise using a bandpass filter and a wavelet lifting-based denoising algorithm.
[0012] The stationary wavelet transform algorithm is used to perform R-point localization, heartbeat segmentation and reconstruction and normalization on the denoised ECG signal to obtain a fixed-length heartbeat dataset, which is used as the input of the deep learning model.
[0013] A multi-scale residual convolutional neural network and an additive angular edge loss function method are used to extract features from a fixed-length electrocardiogram (ECG) signal to obtain the feature vector of the ECG signal.
[0014] The feature vectors are mapped to fixed-dimensional embedding vectors, and similarity measurements are performed to complete identity recognition.
[0015] According to the ECG identification method, a stationary wavelet transform algorithm is used to perform R-point localization, heartbeat segmentation and reconstruction, and normalization on the denoised ECG signal sample dataset to obtain a fixed-length heartbeat dataset. This heartbeat dataset is used as input to a deep learning model and includes:
[0016] The ECG signal after noise removal is subjected to reference point detection, and the R-wave vertex of the ECG signal is located using a stationary wavelet transform algorithm to obtain the R-point position information of the ECG signal segment.
[0017] The ECG signal segments are segmented and reconstructed based on the reference point. The location information of the R point is used to determine whether the ECG signal segments have sufficient identity information. The number of complete heartbeats and complete QRS complexes within the signal segments is counted. The complete heartbeats within the signal segments are segmented based on the R point, and the partial ECG signal segments containing complete QRS complexes are segmented. Zeros are padded to the partial ECG signal segments containing complete QRS complexes to obtain a QRS reconstructed heartbeat signal segment with a fixed dimension T. The segmented complete heartbeat signal segments and QRS reconstructed heartbeat signal segments are spliced together to obtain all the complete heartbeat signal segments and QRS reconstructed heartbeat signal segments, resulting in an ECG signal segment with a fixed dimension of 2T.
[0018] The segmented and reconstructed signal segments are normalized using Min-Max normalization.
[0019] According to the ECG identity recognition method, the signal segment obtained by the segmentation and reconstruction algorithm includes the QRS band within the original signal segment, and the QRS band is used to identify individual identity differences.
[0020] Filtering is performed based on the predicted object position. Depending on the usage scenario, the object will generally appear in the middle of the image, and unreasonable results can be filtered out based on the position.
[0021] According to the ECG identification method, a multi-scale residual convolutional neural network and an additive angular edge loss function are used to extract features from a fixed-length ECG signal to obtain a feature vector of the ECG signal, including:
[0022] A multi-scale residual convolutional network was built as a deep learning model. The model was pre-trained on a database and used as a deep feature extractor to extract the identity difference features of ECG.
[0023] An additive angular edge loss function is created, and the deep learning model is trained using the additive angular edge loss function as the objective function.
[0024] According to the ECG identity recognition method, the deep learning model is trained using the additive angle edge loss function as the objective function, including:
[0025] Create a softmax loss function, expressed as:
[0026]
[0027] Where N is the batch size, n is the number of categories, and x is the word embedding of the neural network;
[0028] The output ||x is achieved using an L2 normalized neural network. i ||and weight Make another bias term b j If it is zero, then The weight vector W is calculated using the inverse cosine trigonometric function. j and the feature vector x of the sample i The angle between Multiply by a fixed scaling factor s to obtain the output, at which point:
[0029]
[0030] Where θ j Weight vector W j and eigenvector x i The included angle between them, j∈[1,…,y] i [,…,n],y i Let i be the true category corresponding to sample i;
[0031] In x i and W j An interval m is added to the angle between the depth features and their corresponding weights to impose an additive penalty on the angle between them.
[0032]
[0033] The softmax function is used to generate a loss function based on additive angle edge loss.
[0034]
[0035] Among them, hyperparameter s is a scaling factor used to help the model converge quickly, and hyperparameter m is an additional angle penalty term to guide the model to train in a direction that is more dense for similar samples and more dispersed for dissimilar samples.
[0036] A deep learning model is trained using an additive angle edge loss function as the objective function.
[0037] According to the ECG identity recognition method, feature vectors are mapped to fixed-dimensional embedding vectors, and identity recognition is completed by performing similarity measurement, including:
[0038] The features of the ECG signal to be processed and the features of the ECG signal with known identity category labels are mapped to obtain new features of the ECG signal to be processed in the semantic projection space and template feature vectors of ECG signals with known identity category labels.
[0039] The Euclidean distance between the feature vector of the ECG signal to be processed and the template vector of the ECG signal with each known identity category label is calculated as the similarity. The known identity category label with the highest similarity is output as the identity recognition result of the ECG signal to be processed, thus completing the matching and recognition.
[0040] According to the ECG identity recognition method, the method further includes:
[0041] By mapping the features learned by training the model with ArcFace as the objective function, a fixed-dimensional feature vector is obtained.
[0042] Another aspect of the present invention provides an ECG identification device, comprising:
[0043] The data acquisition module is used to acquire a dataset of ECG signal samples to be processed based on the ECG identification request. The ECG signal sample dataset is used to represent the original signal data for feature extraction.
[0044] The denoising module is used to perform baseline drift, power line interference, and electromyographic noise removal processing on the ECG signal sample dataset using a bandpass filter and a wavelet lifting-based denoising algorithm.
[0045] The normalization module is used to perform R-point localization, heartbeat segmentation and reconstruction and normalization processing on the denoised ECG signal using the stationary wavelet transform algorithm to obtain a fixed-length heartbeat dataset, which is used as the input of the deep learning model.
[0046] The feature extraction module is used to extract features from a fixed-length electrocardiogram (ECG) signal using a multi-scale residual convolutional neural network and an additive angular edge loss function, thereby obtaining the feature vector of the ECG signal.
[0047] The identity recognition module is used to map feature vectors to fixed-dimensional embedding vectors and to perform similarity measurements to complete identity recognition.
[0048] Another aspect of the present invention provides an electronic device, including a processor and a memory;
[0049] The memory is used to store programs;
[0050] The processor executes the program to implement the method as described above.
[0051] This invention also discloses a computer program product or computer program, which includes computer instructions stored in a computer-readable storage medium. A processor of a computer device can read the computer instructions from the computer-readable storage medium and execute the computer instructions, causing the computer device to perform the methods described above.
[0052] Additional aspects and advantages of the invention will be set forth in part in the description which follows, and in part will be obvious from the description, or may be learned by practice of the invention. Attached Figure Description
[0053] The above and / or additional aspects and advantages of the present invention will become apparent and readily understood from the description of the embodiments taken in conjunction with the following drawings, in which:
[0054] Figure 1 This is a flowchart illustrating the ECG identity recognition method according to an embodiment of the present invention.
[0055] Figure 2 This is a flowchart illustrating the electrocardiogram signal denoising method according to an embodiment of the present invention.
[0056] Figure 3 This is a flowchart illustrating a segmentation and reconstruction method according to an embodiment of the present invention.
[0057] Figure 4 This is a schematic diagram of the electrocardiogram signal segment processing flow according to an embodiment of the present invention.
[0058] Figure 5 This is a schematic diagram of the electrocardiogram signal segmentation and reconstruction process according to an embodiment of the present invention.
[0059] Figure 6 This is a training framework diagram of the ECG identity recognition method based on MSResNet and ArcFace according to an embodiment of the present invention.
[0060] Figure 7 This is a flowchart illustrating the ECG identity recognition method based on MSResNet and ArcFace according to an embodiment of the present invention.
[0061] Figure 8 This is a schematic diagram illustrating the process of training a deep learning model using the additive angular edge loss function as the objective function, according to an embodiment of the present invention.
[0062] Figure 9 This is a schematic diagram of the electrocardiogram signal matching and recognition process according to an embodiment of the present invention.
[0063] Figure 10 This is a diagram of the multi-scale residual convolutional neural network structure according to an embodiment of the present invention.
[0064] Figure 11 This is the block structure used in the residual network of this invention.
[0065] Figure 12 This is a schematic diagram of the heartbeat segmentation and reconstruction effect according to an embodiment of the present invention.
[0066] Figure 13 This is a diagram of an ECG identity recognition device according to an embodiment of the present invention. Detailed Implementation
[0067] The embodiments of the present invention are described in detail below, examples of which are shown in the accompanying drawings. Throughout the description, the same or similar reference numerals denote the same or similar elements or elements having the same or similar functions. In the following description, suffixes such as "module," "part," or "unit" used to denote elements are used only for the purpose of illustrative purposes and have no inherent meaning. Therefore, "module," "part," or "unit" can be used interchangeably. Terms such as "first," "second," etc., are used only to distinguish technical features and should not be construed as indicating or implying relative importance, or implicitly indicating the number of indicated technical features, or implicitly indicating the sequential relationship of the indicated technical features. In this subsequent description, the consecutive reference numerals for method steps are for ease of review and understanding. Adjusting the implementation order of steps, in conjunction with the overall technical solution of the present invention and the logical relationship between the various steps, will not affect the technical effect achieved by the technical solution of the present invention. The embodiments described below with reference to the accompanying drawings are exemplary and are only used to explain the present invention, and should not be construed as limiting the present invention.
[0068] For example, refer to Figure 1 It discloses a flowchart of the ECG identification method, which includes, but is not limited to, steps S100 to S500:
[0069] S100, in response to the ECG identification request, obtains the ECG signal sample dataset to be processed. The ECG signal sample dataset is used to characterize the raw signal data for feature extraction.
[0070] The S200 uses a bandpass filter and a wavelet lifting-based denoising algorithm to remove baseline drift, power line interference, and electromyographic noise from the ECG signal sample dataset.
[0071] In some embodiments, reference Figure 2 It illustrates a flowchart of an electrocardiogram signal denoising method, including but not limited to steps S210 to S240:
[0072] The S210 uses a Butterworth bandpass filter with a cutoff frequency of 1-40Hz for noise reduction, eliminating baseline drift and some high-frequency noise interference. The frequency of its center electrical signal will be concentrated within 0.5Hz or 1Hz to 40Hz.
[0073] S220 uses the wavelet denoising algorithm to select Db3 from the Daubechies series of wavelets as the basis function to perform 8-level wavelet decomposition on the electrocardiogram signal and obtain the wavelet coefficients of the electrocardiogram signal.
[0074] S230 uses a hard threshold function to perform nonlinear processing, reducing the noise wavelet coefficients to zero;
[0075] S240 performs inverse wavelet transform on the processed ECG signal to reconstruct the signal, thereby achieving signal denoising.
[0076] For example, refer to Figure 3 It illustrates a flow of a segmentation and reconstruction method, to adopt, as Figure 2 The method shown in the flowchart completes the signal denoising.
[0077] The S300 uses a stationary wavelet transform algorithm to perform R-point localization, heartbeat segmentation and reconstruction, and normalization on the denoised ECG signal to obtain a fixed-length heartbeat dataset, which is used as input to a deep learning model.
[0078] In some embodiments, reference Figure 4 It illustrates a schematic diagram of the processing flow within an electrocardiogram signal segment, including but not limited to steps S310 to S330:
[0079] S310 performs reference point detection on the noise-removed ECG signal, uses a stationary wavelet transform algorithm to locate the R-wave vertex of the ECG signal, and uses the R-wave vertex as the reference point of the ECG signal to obtain the R-point position information within the heartbeat signal segment.
[0080] S320, segmentation and reconstruction of ECG signal based on reference points.
[0081] In some embodiments, the reference for segmentation and reconstruction of electrocardiogram signal segments Figure 5 Including but not limited to steps S321 to S325:
[0082] S321, based on the location information of point R, count the number of complete heartbeats and complete QRS bands within the signal segment. Specifically, this includes determining the segmented signal length and effective QRS length according to the sampling frequency; determining whether the location of point R can be segmented to obtain a complete heartbeat and a complete QRS band; counting the number of R points that meet the conditions, and thus obtaining the number of complete heartbeats and complete QRS bands within the signal segment.
[0083] S322, determine whether the ECG signal segment has sufficient identification information. Specifically, the QRS complex in the ECG signal segment is the key information for ECG identification. If the ECG signal segment contains two or more QRS complexes or a complete heartbeat, the ECG signal segment is considered to have sufficient identification information.
[0084] S323, based on the segmentation of the complete heartbeat within the signal segment at point R, and the partial ECG signal segment including the complete QRS complex; for point R that can be segmented to obtain a preset signal segment length, a segmentation strategy of 1 / 3T sampling points before point R and 2 / 3T sampling points after point R is adopted to obtain a complete heartbeat signal segment of length T. For point R that can only be segmented to obtain a complete QRS complex, a segmentation strategy of satisfying as much as possible the sampling points before point R and 2 / 3T sampling points after point R is adopted to obtain a partial ECG signal segment of length less than T.
[0085] S324, zero-padding is performed on a portion of the ECG signal segment including the complete QRS band. The fixed R point position will be filled with meaningless zero values for the sampling points 1 / 3T before R point and 2 / 3T after R point, resulting in a fixed-dimensional T reconstructed QRS beat signal segment.
[0086] S325, by splicing and reconstructing the signal segment, all complete heartbeat signal segments and QRS-reconstructed heartbeat signal segments are obtained, resulting in a fixed-dimensional 2T ECG signal segment. Specifically, for a signal segment containing only a single complete heartbeat, this complete heartbeat signal segment is copied to obtain an ECG signal segment of length 2T.
[0087] S330 normalizes the reconstructed signal segment by using min-max normalization to constrain all values of the segmented ECG cycle signal to the range of [0,1].
[0088] S400 uses a multi-scale residual convolutional neural network and an additive angular edge loss function to extract features from a fixed-length electrocardiogram (ECG) signal, thus obtaining the ECG signal's feature vector.
[0089] In some embodiments, reference Figure 6 The diagram shown illustrates the training framework for the ECG identity recognition method based on MSResNet and ArcFace, while also referencing... Figure 7The flowchart shown below illustrates the ECG identity recognition method based on MSResNet and ArcFace, which includes, but is not limited to, steps S410 to S420:
[0090] S410, a multi-scale residual convolutional network was built as a deep learning model to extract the identity difference features of ECG.
[0091] S420, Design an additive angular edge loss function as the objective function to train the deep learning model. For example, design an additive angular edge loss function as the objective function to train the deep learning model.
[0092] In some embodiments, reference Figure 8 As shown, it includes, but is not limited to, steps S421 to 424:
[0093] S421, Create a softmax loss, represented as:
[0094]
[0095] Where N is the batch size, n is the number of categories, and x is the embedding of the neural network;
[0096] S422, outputs ||x through an L2 normalized neural network. i ||and weight Make another bias term b j If it is zero. The weight vector W is calculated using the inverse cosine trigonometric function. j and the feature vector x of the sample i The angle between Multiply by a fixed scaling factor s to get the output.
[0097] at this time:
[0098]
[0099] Where θ j Weight vector W j and eigenvector x i The included angle between them, j∈[1,…,y] i [,…,n],y i Let i be the true category corresponding to the i-th sample;
[0100] S423, in x i and W j An interval m is added to the angle between them to penalize the angle between the depth feature and its corresponding weight in an additive manner.
[0101]
[0102] The softmax function is used to generate a loss function based on additive angle edge loss.
[0103]
[0104] The hyperparameter s is a scaling factor used to help the model converge quickly; the hyperparameter m is an additional angle penalty term that guides the model to train in a direction where similar samples are more densely packed and dissimilar samples are more dispersed.
[0105] S424. Train a deep learning model using an additive angle edge loss function as the objective function.
[0106] The S500 maps feature vectors to fixed-dimensional embedding vectors and performs similarity measurements to complete identity recognition.
[0107] In some embodiments, reference Figure 9 It illustrates a schematic diagram of the electrocardiogram signal matching and identification process, which includes, but is not limited to, steps S510 to S520:
[0108] S510, Map the features of the ECG signal to be processed and the features of ECG signals with several known identity category labels to obtain the feature vector of the ECG signal and the template feature vector of the ECG signal with several known identity category labels;
[0109] S520, calculate the Euclidean distance between the feature vector of the ECG signal to be processed and the template feature vector of the ECG signal for each known identity category label as the similarity:
[0110]
[0111] The known identity category label corresponding to the highest similarity is output as the identity recognition result of the ECG signal to be processed.
[0112] In this embodiment, step S500 uses a multi-scale residual convolutional neural network pre-trained on the PhysioNet / Cinc Challenge 2017 database. This multi-scale residual convolutional neural network combines the Inception block of GoogleNet and the residual block of ResNet as its backbone network, integrating multiple convolutional kernels and multiple receptive fields to make the model wider and deeper. The final specific network structure is as follows: Figure 10 and Figure 11The diagram shows the multi-scale residual convolutional neural network architecture and the block structure used in the residual network. The three Inception blocks are composed of 3, 5, and 7 cores connected in parallel. All convolutional operations are actually batch normalization-ReLU activation-convolution structures. The initial learning rate is 0.0001, and the length of all embedding vectors is set to 200.
[0113] For example, refer to Figure 12 The schematic diagram of the heartbeat segmentation and reconstruction effect is shown. In the four databases ECG-ID, MIT-BIH STChange, MIT-AHA, and PTB, Table 1 shows the identity recognition accuracy of different backbone networks of the ECG identity recognition method based on MSResNet and ArcFace in this embodiment. Table 2 shows the identity recognition accuracy of different embedding vectors of the ECG identity recognition method based on MSResNet and ArcFace in this embodiment. Except for the comparison parameters, all other configurations are kept consistent, and all methods are the results under the optimal hyperparameters. The identity recognition accuracy calculation method is as follows: steps (1) to (6):
[0114] (1) Using the idea of K-fold cross-validation, all the validation signals are divided into K groups. Each time, one group is selected as the test data to determine the optimal threshold, and the remaining K-1 groups are used as evaluation data.
[0115] (2) Set the traversal range of the threshold, such as traversing the range from 0 to 4 with a step size of 0.1, and determine the accuracy of the test data under a certain threshold.
[0116] (3) Determine the optimal threshold based on the accuracy of each threshold on the test dataset;
[0117] (4) Calculate the accuracy of the evaluation data at the optimal threshold;
[0118] (5) Select one of the data from another K-1 groups as test data, and use the rest as evaluation data. Repeat steps (1) to (4) to obtain another K-1 accuracy.
[0119] (6) Calculate the mean of the K accuracy values as the final accuracy.
[0120]
[0121]
[0122] Table 1
[0123] MITBIH ST Change 92.6% 95.2% 96.1% 96.3% MITBIH Arrhythmia 89.3% 90.5% 92.5% 92.2% ECG-ID 90.8% 91.5% 93.4% 93.5% PTB 95.6% 95.9% 96.8% 96.6%
[0124] Table 2
[0125] According to the embodiments shown in this invention, the technical solution of this invention has at least the following beneficial effects: it can maximize the use of effective information within the ECG signal segment and improve the accuracy of ECG identity recognition; by using transfer learning combined with additive angle edge loss function to train the feature extraction model, the versatility of the identity recognition method is enhanced, and the effect of the method on open set ECG identity recognition is improved.
[0126] like Figure 13 As shown, this embodiment of the invention also provides an ECG identity recognition device, which includes a data acquisition module 1301, a noise reduction module 1302, a normalization module 1303, a feature extraction module 1304, and an identity recognition module 1305.
[0127] The system comprises the following modules: a data acquisition module, which acquires a dataset of ECG signal samples to be processed based on the ECG identity verification request. This dataset represents the original signal data for feature extraction. A denoising module uses a bandpass filter and a wavelet lifting-based denoising algorithm to remove baseline drift, power line interference, and electromyographic noise from the ECG signal sample dataset. A normalization module uses a stationary wavelet transform algorithm to perform R-point localization, heartbeat segmentation and reconstruction, and normalization on the denoised ECG signal to obtain a fixed-length heartbeat dataset, which serves as input to a deep learning model. A feature extraction module uses a multi-scale residual convolutional neural network and an additive angular edge loss function to extract features from the fixed-length ECG signal, obtaining a feature vector. An identity verification module maps the feature vector to a fixed-dimensional embedding vector and performs similarity measurement to complete identity verification.
[0128] For example, with the collaboration of the data acquisition module, denoising module, normalization module, feature extraction module, and identity recognition module in the device, the embodiment device can implement any of the aforementioned ECG identity recognition methods. Specifically, in response to an ECG identity recognition request, it acquires a dataset of ECG signal samples to be processed, which is used to represent the original signal data for feature extraction. A bandpass filter and a wavelet-based denoising algorithm are used to remove baseline drift, power line interference, and electromyographic noise from the ECG signal sample dataset. A stationary wavelet transform algorithm is used to perform R-point localization, heartbeat segmentation and reconstruction, and normalization on the denoised ECG signal to obtain a fixed-length heartbeat dataset, which is used as input to a deep learning model. A multi-scale residual convolutional neural network and additive angular edge loss function are used to extract features from the fixed-length ECG signal to obtain a feature vector. The feature vector is mapped to a fixed-dimensional embedding vector, and a similarity measurement is performed to complete identity recognition. The beneficial effects of this invention are: it can maximize the use of effective information within the ECG signal segment and improve the accuracy of ECG identity recognition; by using transfer learning combined with additive angle edge loss function to train the feature extraction model, the versatility of the identity recognition method is enhanced, and the effect of this method on open set ECG identity recognition is improved.
[0129] This invention also provides an electronic device, which includes a processor and a memory;
[0130] The memory stores the program;
[0131] The processor executes a program to perform the aforementioned ECG identity recognition method; the electronic device has the function of carrying and running the interface switching software system provided in the embodiments of the present invention, such as a personal computer (PC), mobile phone, smartphone, personal digital assistant (PDA), wearable device, handheld computer (PPC), tablet computer, etc.
[0132] This invention also provides a computer-readable storage medium storing a program that is executed by a processor to implement the ECG identification method described above.
[0133] In some alternative embodiments, the functions / operations mentioned in the block diagrams may not occur in the order shown in the operation diagrams. For example, depending on the functions / operations involved, two consecutively shown blocks may actually be executed substantially simultaneously, or the blocks may sometimes be executed in reverse order. Furthermore, the embodiments presented and described in the flowcharts of this invention are provided by way of example to provide a more comprehensive understanding of the technology. The disclosed methods are not limited to the operations and logic flows presented herein. Alternative embodiments are contemplated in which the order of various operations is altered and sub-operations described as part of a larger operation are executed independently.
[0134] This invention also discloses a computer program product or computer program, which includes computer instructions stored in a computer-readable storage medium. A processor of a computer device can read the computer instructions from the computer-readable storage medium and execute the computer instructions, causing the computer device to perform the aforementioned ECG identification method.
[0135] Furthermore, although the invention has been described in the context of functional modules, it should be understood that, unless otherwise stated, one or more of the described functions and / or features may be integrated into a single physical device and / or software module, or one or more functions and / or features may be implemented in a separate physical device or software module. It is also understood that a detailed discussion of the actual implementation of each module is unnecessary for understanding the invention. Rather, given the properties, functions, and internal relationships of the various functional modules in the apparatus disclosed herein, the actual implementation of the module will be understood within the scope of conventional skill of an engineer. Therefore, those skilled in the art can implement the invention as set forth in the claims using ordinary techniques without excessive experimentation. It is also understood that the specific concepts disclosed are merely illustrative and not intended to limit the scope of the invention, which is determined by the full scope of the appended claims and their equivalents.
[0136] 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 this invention, essentially, 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 this 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.
[0137] The logic and / or steps represented in the flowchart or otherwise described herein, for example, can be considered as a sequenced list of executable instructions for implementing logical functions, and can be embodied in any computer-readable medium for use by, or in conjunction with, an instruction execution system, apparatus, or device (such as a computer-based system, a processor-included system, or other system that can fetch and execute instructions from, an instruction execution system, apparatus, or device). For the purposes of this specification, "computer-readable medium" can be any means that can contain, store, communicate, propagate, or transmit programs for use by, or in conjunction with, an instruction execution system, apparatus, or device.
[0138] More specific examples of computer-readable media (a non-exhaustive list) include: electrical connections (electronic devices) having one or more wires, portable computer disk drives (magnetic devices), random access memory (RAM), read-only memory (ROM), erasable and editable read-only memory (EPROM or flash memory), fiber optic devices, and portable optical disc read-only memory (CDROM). Furthermore, computer-readable media can even be paper or other suitable media on which the program can be printed, since the program can be obtained electronically, for example, by optically scanning the paper or other medium, followed by editing, interpreting, or otherwise processing as necessary, and then stored in computer memory.
[0139] It should be understood that various parts of the present invention can be implemented in hardware, software, firmware, or a combination thereof. In the above embodiments, multiple steps or methods can be implemented in software or firmware stored in memory and executed by a suitable instruction execution system. For example, if implemented in hardware, as in another embodiment, it can be implemented using any one or a combination of the following techniques known in the art: discrete logic circuits having logic gates for implementing logical functions on data signals, application-specific integrated circuits (ASICs) having suitable combinational logic gates, programmable gate arrays (PGAs), field-programmable gate arrays (FPGAs), etc.
[0140] In the description of this specification, references to terms such as "one embodiment," "some embodiments," "example," "specific example," or "some examples," etc., indicate that a specific feature, structure, material, or characteristic described in connection with that embodiment or example is included in at least one embodiment or example of the invention. In this specification, the illustrative expressions of the above terms do not necessarily refer to the same embodiment or example. Furthermore, the specific features, structures, materials, or characteristics described may be combined in any suitable manner in one or more embodiments or examples.
[0141] Although embodiments of the invention have been shown and described, those skilled in the art will understand that various changes, modifications, substitutions and alterations can be made to these embodiments without departing from the principles and spirit of the invention, the scope of which is defined by the claims and their equivalents.
[0142] The above is a detailed description of the preferred embodiments of the present invention, but the present invention is not limited to the embodiments described. Those skilled in the art can make various equivalent modifications or substitutions without departing from the spirit of the present invention, and these equivalent modifications or substitutions are all included within the scope defined by the claims of this application.
Claims
1. An ECG identification method, characterized in that, include: In response to an ECG identification request, a dataset of ECG signal samples to be processed is obtained, which is used to characterize the raw signal data for feature extraction. The ECG signal sample dataset was processed to remove baseline drift, power line interference, and electromyographic noise using a bandpass filter and a wavelet lifting-based denoising algorithm. The stationary wavelet transform algorithm is used to perform R-point localization, heartbeat segmentation and reconstruction and normalization on the denoised ECG signal to obtain a fixed-length heartbeat dataset, which is used as the input of the deep learning model. A multi-scale residual convolutional neural network and an additive angular edge loss function method are used to extract features from a fixed-length electrocardiogram (ECG) signal to obtain the feature vector of the ECG signal. The feature vectors are mapped to fixed-dimensional embedding vectors, and similarity measurements are performed to complete identity recognition.
2. The ECG identification method according to claim 1, characterized in that, The stationary wavelet transform algorithm is used to perform R-point localization, heartbeat segmentation and reconstruction, and normalization on the denoised ECG signal sample dataset to obtain a fixed-length heartbeat dataset. This heartbeat dataset is used as input to a deep learning model and includes: The ECG signal after noise removal is subjected to reference point detection, and the R-wave vertex of the ECG signal is located using a stationary wavelet transform algorithm to obtain the R-point position information of the ECG signal segment. The ECG signal segments are segmented and reconstructed based on the reference point. The location information of the R point is used to determine whether the ECG signal segments have sufficient identity information. The number of complete heartbeats and complete QRS complexes within the signal segments is counted. The complete heartbeats within the signal segments are segmented based on the R point, and the partial ECG signal segments containing complete QRS complexes are segmented. Zeros are padded to the partial ECG signal segments containing complete QRS complexes to obtain a QRS reconstructed heartbeat signal segment with a fixed dimension T. The segmented complete heartbeat signal segments and QRS reconstructed heartbeat signal segments are spliced together to obtain all the complete heartbeat signal segments and QRS reconstructed heartbeat signal segments, resulting in an ECG signal segment with a fixed dimension of 2T. The segmented and reconstructed signal segments are normalized using Min-Max normalization.
3. The ECG identity recognition method according to claim 1, characterized in that, The method employs a multi-scale residual convolutional neural network and an additive angular edge loss function to extract features from a fixed-length electrocardiogram (ECG) signal, obtaining a feature vector of the ECG signal, including: A multi-scale residual convolutional network was built as a deep learning model. The model was pre-trained on a database and used as a deep feature extractor to extract the identity difference features of ECG. An additive angular edge loss function is created, and the deep learning model is trained using the additive angular edge loss function as the objective function.
4. The ECG identity recognition method according to claim 3, characterized in that, The step of training the deep learning model using the additive angle edge loss function as the objective function includes: Create a softmax loss function, expressed as: Where N is the batch size and n is the number of categories. Word embeddings for neural networks; L2 normalized neural network output and weight This causes another bias term to be applied. If it is zero, then The weight vector is calculated using the inverse cosine trigonometric function. and the feature vector of the sample The angle between : Multiplying by a fixed scaling factor s yields the output, at which point: in Weight vector and eigenvectors The included angle between them, j∈[1,…, [,…,n], Let i be the true category corresponding to sample i; exist and An interval m is added to the angle between the depth features and their corresponding weights to impose an additive penalty on the angle between them. The softmax function is used to generate a loss function based on additive angle edge loss. Among them, hyperparameter s is a scaling factor used to help the model converge quickly, and hyperparameter m is an additional angle penalty term to guide the model to train in a direction that is more dense for similar samples and more dispersed for dissimilar samples. A deep learning model is trained using an additive angle edge loss function as the objective function.
5. The ECG identity recognition method according to claim 1, characterized in that, The process of mapping feature vectors to fixed-dimensional embedding vectors and performing similarity measurements to complete identity recognition includes: The features of the ECG signal to be processed and the features of the ECG signal with known identity category labels are mapped to obtain new features of the ECG signal to be processed in the semantic projection space and template feature vectors of ECG signals with known identity category labels. The Euclidean distance between the feature vector of the ECG signal to be processed and the template vector of the ECG signal with each known identity category label is calculated as the similarity. The known identity category label with the highest similarity is output as the identity recognition result of the ECG signal to be processed, thus completing the matching and recognition.
6. The ECG identity recognition method according to claim 5, characterized in that, The method further includes: By mapping the features learned by training the model with ArcFace as the objective function, a fixed-dimensional feature vector is obtained.
7. An ECG identification device, characterized in that, include: The data acquisition module is used to acquire a dataset of ECG signal samples to be processed based on the ECG identification request. The ECG signal sample dataset is used to represent the original signal data for feature extraction. The denoising module is used to perform baseline drift, power line interference, and electromyographic noise removal processing on the ECG signal sample dataset using a bandpass filter and a wavelet lifting-based denoising algorithm. The normalization module is used to perform R-point localization, heartbeat segmentation and reconstruction and normalization processing on the denoised ECG signal using the stationary wavelet transform algorithm to obtain a fixed-length heartbeat dataset, which is used as the input of the deep learning model. The feature extraction module is used to extract features from a fixed-length electrocardiogram (ECG) signal using a multi-scale residual convolutional neural network and an additive angular edge loss function, thereby obtaining the feature vector of the ECG signal. The identity recognition module is used to map feature vectors to fixed-dimensional embedding vectors and to perform similarity measurements to complete identity recognition.
8. An electronic device, characterized in that, Including the processor and memory; The memory is used to store programs; The processor executes the program to implement the ECG identification method as described in any one of claims 1-6.
9. A computer-readable storage medium, characterized in that, The storage medium stores a program that is executed by a processor to implement the ECG identification method as described in any one of claims 1-6.
Citation Information
Patent Citations
High-generalization electrocardiosignal identity authentication method
CN110008674A
Electrocardiogram (ECG) authentication method and apparatus
US20170188971A1