CN112826512B - Automatic detection and peak positioning method for epileptic spike - Google Patents

Automatic detection and peak positioning method for epileptic spike Download PDF

Info

Publication number
CN112826512B
CN112826512B CN202110158807.8A CN202110158807A CN112826512B CN 112826512 B CN112826512 B CN 112826512B CN 202110158807 A CN202110158807 A CN 202110158807A CN 112826512 B CN112826512 B CN 112826512B
Authority
CN
China
Prior art keywords
data
peak
value
module
deep learning
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202110158807.8A
Other languages
Chinese (zh)
Other versions
CN112826512A (en
Inventor
汤俊贤
廖攀
许博岩
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Nanjing Huinao Cloud Computing Co ltd
Original Assignee
Nanjing Huinao Cloud Computing Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Nanjing Huinao Cloud Computing Co ltd filed Critical Nanjing Huinao Cloud Computing Co ltd
Priority to CN202110158807.8A priority Critical patent/CN112826512B/en
Publication of CN112826512A publication Critical patent/CN112826512A/en
Application granted granted Critical
Publication of CN112826512B publication Critical patent/CN112826512B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Measurement And Recording Of Electrical Phenomena And Electrical Characteristics Of The Living Body (AREA)

Abstract

The invention discloses an automatic detection and peak positioning method for epileptic spikes, which comprises the following steps: 1) Splitting each magnetoencephalogram data into a plurality of data segments of the same size; 2) Constructing a deep learning network model, wherein the deep learning network model comprises a single-channel coding module, a depth feature transfer module and a global decoding module; the single-channel coding module is used for carrying out depth feature extraction on single-channel data in the data fragment to obtain various depth features with different sizes and sending the depth features to the depth feature transmission module for carrying out data dimension reduction; the global coding module is used for performing convolution and up-sampling calculation on the depth features from the depth features with the minimum size, and splicing the obtained depth features with the corresponding consistency of the size until the depth features with the maximum size are processed; 3) Training a deep learning network model by using each data segment; 4) And inputting the magnetoencephalogram data to be processed into the trained deep learning network model for spike detection and peak positioning.

Description

Automatic detection and peak positioning method for epileptic spike
Technical Field
The invention belongs to the field of magnetoencephalogram signal identification in the field of biological feature identification, and particularly relates to an epilepsia spike automatic detection and peak positioning method based on deep learning.
Background
Epilepsy is a common neurological brain disease, and is characterized by central nervous system dysfunction mainly caused by abnormal over-discharge of cerebral neurons. For the diagnosis and treatment of epilepsy, the key point is to determine the brain area with abnormal discharge, i.e. the epileptogenic focus. The method is an effective mode for treating the epileptic diseases by carrying out targeted drug inhibition or surgical excision on epileptogenic focuses.
Magnetoencephalography (MEG) is a noninvasive technique for detecting neuronal firing activity in the brain by simultaneously recording neural activity in brain tissue with over 300 sensors. The magnetoencephalogram has a better signal-to-noise ratio than the electroencephalogram, and is resistant to signal distortion caused by complex brain tissue. The spike generated by epilepsy due to abnormal discharge has obvious specificity in a magnetoencephalogram, and is widely accepted as a biomarker. The method can be used for judging the abnormal discharge time of the epilepsy and identifying the seizure condition of the epilepsy, so that the magnetoencephalogram spike analysis of the epilepsy patient has very important clinical significance.
However, epileptic discharges are characterized by seizures, transients, and repetitions, which generally result in a magnetoencephalogram examination of an epileptic patient that lasts for 1.5 hours. In addition, in clinical practice, spike detection is generally performed by a clinician manually and subjectively, and because the magnetoencephalogram has the characteristics of high time resolution and high acquisition channel number, the subjective examination of the clinician is time-consuming and labor-consuming and highly depends on the experience of the clinician. A highly experienced clinician who performs a complete examination of the magnetoencephalogram data needs to observe a magnetoencephalogram signal over 300 channels at about a 6000s,1000hz sampling rate, which takes about 2 hours, and may take longer for a less qualified clinician. Under the combined influence of long acquisition time of magnetoencephalogram and high diagnosis professional requirement, a plurality of automatic and high-accuracy spike detection methods are promoted.
At present, there are many automatic spike detection algorithms, which perform time domain analysis, frequency domain analysis, time-frequency analysis on the magnetoencephalogram data, and extract relevant features, so as to detect whether spike exists or not in a fixed time segment. Some studies also use deep learning networks to directly start with the magnetoencephalogram data to perform spike detection. However, the existing algorithm can only detect whether spike waves are contained in a fixed time segment, and cannot accurately locate the time point with the highest spike wave energy, i.e. the spike wave peak point. The method is characterized in that a tracing algorithm is often used for positioning an epileptogenic focus, an accurate epileptogenic focus positioning cannot be obtained by using a spike data segment in a long time period, and if a spike peak time point is used, a small segment of data around a peak value is traced and positioned, so that the epileptogenic focus with more accurate positioning can be obtained. Thus, there is a greater realism that the location of the peak of the spike is significant compared to the detection of the spike over a period of time.
Disclosure of Invention
In order to overcome the defects of the existing algorithm in peak detection, the invention provides an epileptic spike detection and peak positioning method based on deep learning, which can effectively identify epileptic spike discharge events from the original data of a magnetoencephalogram and accurately position the time point of a spike peak.
The deep learning network provided by the invention respectively encodes the signal of each channel of the magnetoencephalogram to obtain the depth characteristic of the signal, and then performs characteristic fusion on the depth characteristic to jointly decode. In the decoding step, the coded data with the same size and the decoded data are connected, so that the multiplexing of the network on the characteristics is improved. Finally, the network outputs the probability of peak points of the magnetoencephalogram signal at each time point, and the spike is judged and the position of the spike peak point is accurately positioned through a subsequent threshold algorithm.
The technical scheme of the invention is as follows.
A method for detecting a magnetoencephalogram spike and positioning a spike peak point based on deep learning comprises the following steps:
the method comprises the following steps: carrying out data preprocessing on the magnetoencephalogram: removing a large amount of artifact signals in the magnetoencephalogram data, and splitting the data into data segments with the same size. Firstly, a band-pass filter and a power frequency notch filter are used for filtering, then ICA is used for removing artifacts from eye jump signals and heartbeat signals, and then data are standardized to be in accordance with standard normal distribution. And finally, splitting and dividing the data of the magnetoencephalogram, splitting the magnetoencephalogram data into 8 brain areas based on different brain areas of the brain, wherein 39 magnetoencephalogram channels are arranged on each brain area, and simultaneously, carrying out data division on the magnetoencephalogram data in a 296 millisecond time window and 148 millisecond overlapping mode in terms of time to obtain magnetoencephalogram data fragments. In step 1), a plurality of magnetoencephalogram data fragments of size [39 × 296] will be obtained.
Step two: constructing a deep learning network model: the model provided by the invention is divided into three algorithm modules which are respectively as follows: the device comprises a single-channel coding module, a depth feature transfer module and a global decoding module. The single-channel coding module is used for carrying out depth feature extraction on single-channel data in the input magnetoencephalogram data fragment, synchronously outputting depth features with different sizes after every pooling calculation in the single-channel coding module, and transmitting the depth features to the depth feature transmission module. The depth feature transfer module performs data dimension reduction on the depth features of each channel after passing through the single-channel coding module, averages the depth features on the magnetoencephalogram channel dimension, and outputs the depth features to the global decoding module. The global coding module firstly performs convolution and up-sampling calculation on the depth features with the minimum size, performs feature splicing on the obtained depth features and the depth features with the same size in the feature transmission module, repeats the calculation, and finally outputs a one-dimensional matrix with the data size being the same as that of the network input data in the time dimension. Each value in the network output matrix can correspond to each time point on the original signal (i.e., the input data segment) one-to-one, and each value in the matrix represents the probability that the network at the time point corresponding to the value predicts the spike peak point.
Step three: training a deep learning network: and inputting the data segments obtained in the step one into a deep learning network for training. During the training process, the invention uses the following three strategies: firstly, reconstructing a label, wherein according to the characteristics of spike waves and peak values, the invention provides a new label construction method, and the original binaryzation peak point label is subjected to smooth reconstruction through a dual normal distribution function; and secondly, data enhancement, namely, randomly translating the time window of each magnetoencephalogram data segment left and right for 9 times, wherein the translation time is not more than 50 milliseconds (the original data segment is a fixed time point, namely, data segment interception with the length of 296ms is carried out every 148 ms), and the data enhancement multiple is 9 times. Thirdly, selecting a loss function, wherein the method uses the following loss functions:
Figure 735811DEST_PATH_IMAGE001
wherein
Figure 79199DEST_PATH_IMAGE002
For the index value in the network output matrix to be
Figure 894708DEST_PATH_IMAGE003
I.e. the probability that each corresponding time instant is predicted to be a spike peak,
Figure 103973DEST_PATH_IMAGE004
for the index value in the reconstructed label matrix to be
Figure 663130DEST_PATH_IMAGE003
I.e. the reconstructed label value at each corresponding time point.
Step four: spike peak detection and peak location are carried out on magnetoencephalogram data to be processed. Inputting the preprocessed magnetoencephalogram data segments into a trained deep learning network to obtain a spike peak prediction matrix corresponding to the input magnetoencephalogram data segments, inputting the spike peak prediction matrix into a detection positioning module, calculating the kurtosis of output data, and judging whether the magnetoencephalogram segments contain spikes or not by using a threshold method aiming at the kurtosis of each magnetoencephalogram segment by the detection positioning module. Finally, the time point with the highest probability is selected from the segments containing the spike as the specific time point for predicting the spike peak value (
Figure 579133DEST_PATH_IMAGE005
In step four, the invention provides an evaluation index aiming at peak positioning, namely peak deviation b p The calculation formula is as follows:
Figure 50697DEST_PATH_IMAGE006
i.e. predicted peak point from sample i
Figure 747258DEST_PATH_IMAGE007
Actual peak point with sample i
Figure 47789DEST_PATH_IMAGE008
The absolute value of the error of (2) is calculated to obtain the peak deviation of the sample i
Figure 880616DEST_PATH_IMAGE009
In milliseconds.
The epilepsia spike detection and peak positioning method provided by the invention can effectively identify the spike in each data segment of the magnetoencephalogram and accurately position the time point of the spike peak point in the segment. The result shows that the spike detection method provided by the invention has the performance equivalent to that of the existing method. Meanwhile, an evaluation index of peak detection is provided for the first time, the time of a spike peak point can be accurately predicted, in a test set, the average value of peak deviation of peak prediction is 14 milliseconds, and the standard deviation is 17 milliseconds.
Compared with the prior art, the invention has the beneficial effects that.
1. The method starts from the data, can accurately predict the spike and the position of the spike peak point, and provides an accurate index for the source tracing and positioning of the subsequent epileptogenic focus of the epilepsy.
2. The invention uses the idea of target detection, combines spike detection and peak positioning into the same network task, and improves the practicability of the model.
3. The network used by the invention combines the information of the single channel and the global channel, and transfers the characteristics with different sizes from the decoder to the encoder, thereby improving the multiplexing of the characteristics and leading the network to be capable of more accurately predicting the spike peak time point.
Drawings
FIG. 1 is a flow chart of the method of the present invention.
FIG. 2 is a diagram of a pre-processing module in the method of the present invention.
FIG. 3 is a deep learning network framework in the method of the present invention.
FIG. 4 is a diagram of a single-channel convolution module in the deep learning network in the method of the present invention.
FIG. 5 is a convolution module in the deep learning network according to the method of the present invention.
FIG. 6 is a block diagram of the deep learning network deep feature transfer module of the present invention.
FIG. 7 is a block diagram of the global decoding module in the deep learning network according to the present invention.
Fig. 8 shows reconstructed tag values of the tag according to the method of the present invention.
Detailed Description
Embodiments of the method of the present invention will be further described with reference to the accompanying drawings.
As shown in fig. 1, a flowchart of spike automatic detection and peak location according to an embodiment of the present invention mainly includes the following steps.
The method comprises the following steps: and (4) preprocessing data.
The step is to preprocess the input original data of the magnetoencephalogram, filter the signal, remove the artifact, standardize and segment the signal, so that the data can be better put into a deep learning network for training.
As shown in fig. 2, the data preprocessing module preprocesses input magnetoencephalogram data in the following steps.
1) Low frequency, high frequency and power frequency noise on each channel is removed using a 1-100Hz bandpass filter and a 50Hz notch filter.
2) Artifacts in the signal related to the eye jump signal and the heartbeat signal are removed using Independent Component Analysis (ICA).
3) And (4) carrying out data standardization on signals on all channels, so that the data are subjected to standard normal distribution.
4) And splitting and dividing the magnetoencephalogram data, and splitting 306 magnetoencephalogram channels into 8 brain areas according to the positioning information of the magnetoencephalogram channels, wherein each brain area has 39 channels. For brain regions with fewer than 39 channels, the completion is performed using all-zero channel data.
5) And (3) splitting a training set and a test set of the magnetoencephalogram data, wherein the ratio of the training set to the test set is 8: 2.
Step two: and constructing a deep learning network.
The step is a deep learning network for training, and the probability that each time point in the magnetoencephalogram data segment is a spike peak value is predicted by inputting a training set magnetoencephalogram data segment for training.
As shown in fig. 3, the deep learning network framework of the present invention mainly comprises the following algorithm modules: a single channel encoding module 301, a depth feature delivery module 302 and a global decoding module 303. The details of each module will be described separately below.
1. A single channel encoding module 301.
As shown in fig. 4, it is a basic structure of a single channel coding module. The magnetoencephalography data processing system mainly comprises a magnetoencephalography data input layer, 4 convolution modules, 3 maximum pooling layers and 4 output layers.
Magnetoencephalogram data input layer 401: single channel data of input magnetoencephalogram fragment data has data size [1 × 296].
As shown in fig. 5, the basic structure of the convolution module (including the first convolution module 402, the second convolution module 405, the third convolution module 408, and the fourth convolution module 411) is that the data is convolved one-dimensionally by the convolution module to extract the depth feature. The convolution module includes a first convolution layer 501, a first activation function 502, a first plurality of normalization layers 503, a second convolution layer 504, a second activation function 505, and a second plurality of normalization layers 506.
The first convolution layer and the second convolution layer use one-dimensional convolution kernels to perform convolution calculation on input data, the filling mode is the same zero filling mode, namely the size of convolution calculation output data is consistent with that of the input data, and zero is used at two ends of the data for automatic filling. The size of the convolution kernel and the number of convolution kernels defined in each convolution module depends on the depth of the convolution module in the network. The convolution kernels of both convolution layers in the first convolution module 402 are both [1 × 20] in size, and the number of convolution kernels is both 16. The convolution kernels of both convolution layers in the second convolution module 405 are both [1 x 10] in size, and the number of convolution kernels is 32. The convolution kernels for both convolution layers in the third convolution module 408 are [1 x 5] in size and the number of convolution kernels is 64. The convolution kernels of both convolution layers in the fourth convolution module 411 are [1 × 3], and the number of convolution kernels is 128.
The first and second activation functions are Linear rectification functions (relus) for increasing the non-Linear fitting capability of the network. The first and second normalization layers make the input of each calculation obey the standard normal distribution, thereby improving the convergence rate of the network and preventing the gradient explosion phenomenon.
Max pooling layers (including first max pooling layer 404, second max pooling layer 407, third max pooling layer 410): to reduce the parameters of the network and to prevent the network from over-fitting, a maximum pooling layer of pooling size 2 and step size 2 is used. The output data size is only half of the input data size.
Output layers (including first output layer 403, second output layer 406, third output layer 409, fourth output layer 412): the single channel coding module has four data outputs with different sizes, and the size of the output matrix of the first output layer 403 is determined by the first convolution module 402 and is [16 × 296]. The size of the output matrix of the second output layer 406 is determined by the second convolution module 405 and is [32 × 148]. The size of the output matrix of the third output layer 409 is determined by the third convolution module 408 and is [64 × 74]. The output matrix size of the fourth output layer 412 is determined by the fourth convolution module 411 to be [128 × 37].
It should be noted that the single-channel encoding module performs the above calculation on all 39 channels in the segment of the magnetoencephalogram data, and finally obtains 39 channels, each of which has 4 depth feature outputs with different sizes.
2. A depth feature transfer module 302.
The depth feature transfer module transfers the output layer of the single channel coding module to the global decoding module 303 after global pooling averaging is performed on the magnetoencephalogram channel dimension.
As shown in fig. 6, a basic structure of the depth feature transfer module 302 includes 4 global pooling layers (a first global pooling layer 601, a second global pooling layer 603, a third global pooling layer 605, and a fourth global pooling layer 607) and 4 global output layers (a first global output layer 602, a second global output layer 604, a third global output layer 606, and a fourth global output layer 608).
First global pooling layer 601: the depth features of the first output layer 403 in the single-channel coding module are input for 39 channels, the input data size is [39 × 16 × 296], and global pooling calculations are performed on the magnetoencephalogram channel dimensions, and the output data size of the first global output layer 602 is [16 × 296].
Second global pooling layer 603: the input 39 channels are the depth features of the second output layer 406 in the single channel coding module, the input data size is [39 × 32 × 148], and the global pooling calculation is performed on the magnetoencephalogram channel dimension, and the output data size of the second global output layer 604 is [32 × 148].
Third global pooling layer 605: the depth characteristics of the 39 channels in the third output layer 409 in the single-channel coding module are input, the input data size is [39 × 64 × 74], global pooling calculation is performed on the magnetoencephalogram channel dimension, and the output data size of the third global output layer 606 is [64 × 74].
Global pooling layer 607: the depth characteristics of the 39 channels in the fourth output layer 412 in the single-channel coding module are input, the input data size is [39 × 128 × 37], global pooling calculations are performed in the magnetoencephalogram channel dimension, and the fourth global output layer 608 outputs the data size of [128 × 37].
3. A global decoding module 303.
The global decoding module 303 takes the 4 outputs of the depth feature transfer module 302 as inputs, and finally obtains data with the size of [1 × 296] through convolution calculation and upsampling, wherein each data point represents the probability that the corresponding time point on the original magnetoencephalogram data segment is the spike peak.
As shown in fig. 7, the basic structure of the global decoding module 303 includes 4 input layers, 3 convolution modules, 3 upsampling layers and 1 output layer.
Global input layer 701: the depth features output by the fourth global output layer 608 in the input depth feature transfer module 302.
Upsampling layers (first upsampling layer 702, second upsampling layer 705, third upsampling layer 708): in order to enable the data of each size in the depth feature transfer module to be spliced with the data of the global decoding module, the data calculated by the global input layer 701 and the convolution modules 704 and 707 is up-sampled by 2 times. The first upsampling layer 702 upsamples the depth feature data output by the fourth global output layer 608 to obtain a data size [128 × 74], the second upsampling layer 705 outputs a data size [64 × 148], and the third upsampling layer 708 outputs a data size [32 × 296].
Input layers (first input layer 703, second input layer 706, third input layer 709): and splicing the data output by the upper sampling layer and the depth characteristic transmission module to realize the multiplexing of the characteristics. The first input layer 703 splices the data output by the third global output layer 606 and the first upsampling layer 702, and the final data size is [192 × 74]. The second input layer 706 concatenates the data of the second global output layer 604 with the data of the second upsampling layer 705, with a final data size [96 × 148]. The third input layer 709 splices the data from the first global output layer 602 and the third upsampled layer 708 to a final data size [48 x 296].
Convolution modules (i.e., fifth convolution module 704, sixth convolution module 707, seventh convolution module 710): here the structure of the convolution module is similar to that of the convolution module in the single-pass encoding module 301. The convolution kernels of both convolution layers in the fifth convolution module 704 are [1 x 5] in size, and the number of convolution kernels is 64. The convolution kernels of both convolution layers in the sixth convolution module 707 are [1 × 10], and the number of convolution kernels is 32. Note that in the seventh convolution module 704, the convolution kernels of both convolutional layers have a size of [1 × 20], but the number of convolution kernels of the first convolutional layer is 16, and the number of convolution kernels of the second convolutional layer is 1.
Output layer 711: and calculating the output result of the seventh convolution module 710 through a Sigmoid activation function, and taking the calculated output result as the final output result of the whole network, wherein the size of the final output result is [1 × 296].
Step three: and training a deep learning network.
Before training the deep learning network, the invention provides a new label construction method, and the original binarization spike peak label is reconstructed by adopting a dual normal distribution function superposition method. Based on the labeled peak point location, a binary original label matrix can be generated, i.e., a [1 × 296] boolean data matrix with 1 at the time point of the peak and 0 at other time points. In order to improve the speed and robustness of the model during learning, the method carries out smooth reconstruction on the original label of the magnetoencephalogram data segment with the spike, and the main steps are as follows.
1. Representing the index of the time point of the peak in the label matrix by ipeak,
Figure 772349DEST_PATH_IMAGE010
is the index value in the tag matrix.
2. The standard deviation was calculated to be 0.01 and the mean was
Figure 435499DEST_PATH_IMAGE011
The normal distribution function of (1) is obtained by taking the maximum value of the function as 1, and the function expression is as follows:
Figure 867617DEST_PATH_IMAGE012
3. the standard deviation was calculated to be 0.10 and the mean was
Figure 554951DEST_PATH_IMAGE013
The maximum value of the normal distribution function is 0.5, and the function expression is as follows:
Figure 633896DEST_PATH_IMAGE014
4. get
Figure 977153DEST_PATH_IMAGE015
Comprises the following steps:
Figure 681804DEST_PATH_IMAGE016
as a new index value of
Figure 223643DEST_PATH_IMAGE010
The tag value of (1).
Fig. 8 shows the original label and the reconstructed label.
For a segment of magnetoencephalogram data without spikes, the tag values are all 0's, i.e., a zero matrix of size [1 x 296].
For each magnetoencephalogram data segment, a 9-fold data enhancement was achieved by random translation of the time window, with a maximum translation time of the time window of 50ms.
The method comprises the steps of inputting a magnetoencephalogram data fragment in a training set through a deep learning network, using a back propagation algorithm, using an Adam optimization function, setting a learning rate to be 0.0001, setting a training batch size (batch size) to be 128, and stopping training by using early stopping technology (early stopping) when errors on a verification machine are found to rise to a certain level so as to prevent overfitting of a model.
In the selection of the loss function, the following loss functions are used in the invention:
Figure 988337DEST_PATH_IMAGE017
the method aims to enable the model to output a predicted value which is closer to the reconstructed label. For a segment of magnetoencephalogram data where a spike exists, the predictions will exhibit a single peak, while for a segment of magnetoencephalogram data where no spike exists, the predictions all approach 0. Therefore, better judgment basis can be brought to subsequent spike wave prediction and peak positioning.
Step four: spike prediction and peak location
The step further processes the output result of the deep learning network, and outputs whether the data segment of the magnetoencephalogram contains spike waves and the time point of the spike wave peak value point.
The net output is [1 x 296]]Because the data labels are reconstructed in the training phase, ideally, the magnetoencephalogram data segments with spikes show a single-peak trend after network calculation, and the magnetoencephalogram data segments without spikes show a uniformly distributed trend after calculation. Therefore, the kurtosis is used as a judgment index to judge whether the current magnetoencephalogram data fragment has spike waves. For a mean value of
Figure 818890DEST_PATH_IMAGE018
Variance is
Figure 812385DEST_PATH_IMAGE019
The kurtosis is defined as the fourth order central moment of the sample, and the calculation formula is as follows:
Figure 474310DEST_PATH_IMAGE020
defining a sample T, making a network output matrix be a probability density function of the sample T, and taking the value of T
Figure 144326DEST_PATH_IMAGE003
For the index value of the network output matrix, sample T is taken
Figure 462175DEST_PATH_IMAGE003
Probability value of (2)
Figure 243049DEST_PATH_IMAGE021
For the index value in the network output matrix to be
Figure 775793DEST_PATH_IMAGE003
The matrix value of (a), so the mean of the samples T can be calculated:
Figure 616710DEST_PATH_IMAGE022
the kurtosis calculation for sample T is therefore:
Figure 218592DEST_PATH_IMAGE023
in the present invention, 2 is used as a threshold, and when the kurtosis is less than 2, it is determined that there is no spike, and when the kurtosis is greater than 2, it is determined that there is a spike. And selecting the prediction point with the highest probability as the spike peak point for the magnetoencephalogram data segment with the spike. By calculating the deviation of the predicted peak point from the actual peak point, the deviation b of the peak point p And judging the prediction performance of the model.
In summary, the above description is only a preferred embodiment of the present invention, and is not intended to limit the scope of the present invention. Any modification, equivalent replacement, or improvement made within the spirit and principle of the present invention should be included in the protection scope of the present invention.

Claims (7)

1. An automatic detection and peak location method for epileptic spikes comprises the following steps:
1-1, carrying out data preprocessing on the magnetoencephalogram: removing artifact signals in the magnetoencephalogram data, and then splitting each magnetoencephalogram data into a plurality of data segments with the same size;
1-2, constructing a deep learning network model, wherein the deep learning network model comprises a single-channel coding module, a depth feature transfer module and a global decoding module; the single-channel coding module is used for performing depth feature extraction on single-channel data in the data segmentation to obtain a plurality of depth features with different sizes and transmitting the depth features to the depth feature transmission module; the depth feature transfer module is used for performing data dimension reduction on the depth features output by each single-channel coding module, averaging the depth features on the magnetoencephalogram channel dimension, and outputting the depth features to the global decoding module; the global decoding module is used for performing convolution and up-sampling calculation on the depth features from the depth features with the minimum size, performing feature splicing on the obtained depth features and the depth features with the corresponding consistent size in the depth feature transmission module until the depth features with the maximum size are processed, and finally outputting a one-dimensional matrix with the data size being the same as that of the network input data in the time dimension; each value in the one-dimensional matrix corresponds to each time point on the input data segment one by one, and the size of each value represents the probability that the network prediction of the time point corresponding to the value is a spike peak point;
1-3, training the deep learning network model by utilizing each data segment;
1-4, splitting a magnetoencephalogram data to be processed into a plurality of data segments, and inputting the data segments into the trained deep learning network model to obtain a prediction matrix of each data segment; the detection positioning module calculates the kurtosis corresponding to each data segment according to the prediction matrix, judges the data segments with the kurtosis larger than a set threshold value as containing spike waves, and then selects the time point with the highest probability from the data segments containing the spike waves as a specific time point of the peak value of the predicted spike waves.
2. The method of claim 1, wherein the labels of the data segments for which the deep learning network model is trained are reconstructed by:
2-1, generating a binary label matrix according to the position of the peak point marked in the data segmentation; representing the index of the time point of the peak value in the label matrix by ipeak, wherein x is the index value in the label matrix;
2-2, calculating a normal distribution function f with a standard deviation of 0.01 and a mean value of ipeak/296 1 (x),f 1 (x) The maximum value of (a) is taken as 1;
2-3, calculating a normal distribution function f with standard deviation of 0.10 and mean value of peak/296 2 (x),f 2 (x) The maximum value of (a) is taken to be 0.5;
2-4, take f (x) = max (f) 1 (x),f 2 (x) As the label value for each point on the label matrix.
3. The method of claim 1 or 2, wherein training the deep learning network model is caused by training the deep learning network modelUsing a loss function of
Figure FDA0003869239680000011
Wherein p is t For the matrix value with index value t in the network output matrix, i.e. the probability of predicting the point t as the spike peak value, l t And the index value of the reconstructed label matrix is the matrix value with t, namely the reconstructed label value at the moment point t.
4. The method of claim 1 or 2, wherein the data enhancement is performed on the data segments for training the deep learning network model by: and for each data segment, carrying out multiple random left-right translation on the time window of the data segment, wherein the translation time does not exceed a plurality of milliseconds, and obtaining a plurality of data segments.
5. The method of claim 4, wherein the time window is 296 milliseconds and the translation time is no more than 50 milliseconds.
6. The method of claim 1, wherein the kurtosis corresponding to the network output of the data segments is calculated by: defining a sample T, and making a network output matrix be a probability density function of the sample T, wherein an index value T of the network output matrix is a value of the sample T, a matrix value p (T) with the index value T in the network output matrix is a probability value of the sample T to the T, and the kurtosis of the probability value is
Figure FDA0003869239680000021
7. The method of claim 1 wherein the deviation b between the predicted peak point and the actual peak point is calculated p Judging the prediction performance of the deep learning network model; wherein the peak deviation b p =abs(peak groundtruth -peak predict );peak predict Predicting peak points, peak, for data segments groundtruth Is the actual peak point of the data segment.
CN202110158807.8A 2021-02-05 2021-02-05 Automatic detection and peak positioning method for epileptic spike Active CN112826512B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110158807.8A CN112826512B (en) 2021-02-05 2021-02-05 Automatic detection and peak positioning method for epileptic spike

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110158807.8A CN112826512B (en) 2021-02-05 2021-02-05 Automatic detection and peak positioning method for epileptic spike

Publications (2)

Publication Number Publication Date
CN112826512A CN112826512A (en) 2021-05-25
CN112826512B true CN112826512B (en) 2022-11-25

Family

ID=75932244

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110158807.8A Active CN112826512B (en) 2021-02-05 2021-02-05 Automatic detection and peak positioning method for epileptic spike

Country Status (1)

Country Link
CN (1) CN112826512B (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116304558B (en) * 2023-01-19 2024-04-02 北京未磁科技有限公司 Epileptic brain magnetic map spike detection method and device
CN116340735B (en) * 2023-05-30 2023-08-11 合肥综合性国家科学中心人工智能研究院(安徽省人工智能实验室) Spike detection method and system based on long-field-of-view feature fusion
CN116350227B (en) * 2023-05-31 2023-09-22 合肥综合性国家科学中心人工智能研究院(安徽省人工智能实验室) Individualized detection method, system and storage medium for magnetoencephalography spike
CN117257312B (en) * 2023-11-20 2024-01-26 合肥综合性国家科学中心人工智能研究院(安徽省人工智能实验室) Method for augmenting magnetoencephalography data in machine learning

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH11137530A (en) * 1997-11-14 1999-05-25 Nec Corp Detector for characteristic brain electromagnetic-wave
CN108256629A (en) * 2018-01-17 2018-07-06 厦门大学 The unsupervised feature learning method of EEG signal based on convolutional network and own coding
CN110321783A (en) * 2019-05-07 2019-10-11 北京慧脑云计算有限公司 A kind of MEG spike detection method and system based on 1D convolutional neural networks
CN111340142A (en) * 2020-05-14 2020-06-26 南京慧脑云计算有限公司 Epilepsia magnetoencephalogram spike automatic detection method and tracing positioning system
CN111387974A (en) * 2020-02-19 2020-07-10 杭州电子科技大学 Electroencephalogram feature optimization and epileptic seizure detection method based on depth self-coding
CN112220485A (en) * 2020-09-03 2021-01-15 北京慧脑云计算有限公司 Epilepsia electroencephalogram/magnetoencephalogram abnormal wave automatic detection method and positioning system

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH11137530A (en) * 1997-11-14 1999-05-25 Nec Corp Detector for characteristic brain electromagnetic-wave
CN108256629A (en) * 2018-01-17 2018-07-06 厦门大学 The unsupervised feature learning method of EEG signal based on convolutional network and own coding
CN110321783A (en) * 2019-05-07 2019-10-11 北京慧脑云计算有限公司 A kind of MEG spike detection method and system based on 1D convolutional neural networks
CN111387974A (en) * 2020-02-19 2020-07-10 杭州电子科技大学 Electroencephalogram feature optimization and epileptic seizure detection method based on depth self-coding
CN111340142A (en) * 2020-05-14 2020-06-26 南京慧脑云计算有限公司 Epilepsia magnetoencephalogram spike automatic detection method and tracing positioning system
CN112220485A (en) * 2020-09-03 2021-01-15 北京慧脑云计算有限公司 Epilepsia electroencephalogram/magnetoencephalogram abnormal wave automatic detection method and positioning system

Non-Patent Citations (4)

* Cited by examiner, † Cited by third party
Title
Efficient Epileptic Seizure Prediction Based on Deep Learning;Hisham Daoud,et al;《IEEE TRANSACTIONS ON BIOMEDICAL CIRCUITS AND SYSTEMS》;20191031;第13卷(第5期);第804-812页 *
Epileptic Seizure Detection using Deep Convolutional Autoencoder;Ahmed M. Abdelhameed,et al;《IEEE Workshop on Signal Processing Systems》;20181231;第223-228页 *
Silk-Enabled Conformal Multifunctional Bioelectronics for Investigation of Spatiotemporal Epileptiform Activities and Multimodal Neural Encoding/Decoding;Zhifeng Shi,et al;《ADVANCED SCIENCE NEWS》;20191231;第1-11页 *
基于深度学习的癫痫脑电通道选择与发作检测;曹玉珍,等;《天津大学学报(自然科学与工程技术版)》;20200430;第53卷(第4期);第426-431页 *

Also Published As

Publication number Publication date
CN112826512A (en) 2021-05-25

Similar Documents

Publication Publication Date Title
CN112826512B (en) Automatic detection and peak positioning method for epileptic spike
CN113786204B (en) Epileptic intracranial brain electrical signal early warning method based on deep convolution attention network
CN111340142B (en) Epilepsia magnetoencephalogram spike automatic detection method and tracing positioning system
Sugeno et al. Simple methods for the lesion detection and severity grading of diabetic retinopathy by image processing and transfer learning
CN110693493A (en) Epilepsy electroencephalogram prediction method based on convolution and recurrent neural network combined time multiscale
CN113768519B (en) Method for analyzing consciousness level of patient based on deep learning and resting state electroencephalogram data
CN114366124B (en) Epileptic electroencephalogram identification method based on semi-supervised deep convolution channel attention list classification network
Singh et al. Retinal optic disc segmentation using conditional generative adversarial network
CN112220485A (en) Epilepsia electroencephalogram/magnetoencephalogram abnormal wave automatic detection method and positioning system
CN114549520B (en) Retina pathological section analysis system based on full convolution attention enhancement network
CN113662560B (en) Method for detecting seizure-like discharge between attacks, storage medium and device
Huang et al. Automatic epileptic seizure detection via attention-based CNN-BiRNN
CN114093501A (en) Intelligent auxiliary analysis method for children's motor epilepsy based on synchronous video and electroencephalogram
CN115363531A (en) Epilepsy detection system based on bimodal electroencephalogram signal information bottleneck
CN116784820A (en) Brain function network construction method and system based on seed point connection
CN117218453A (en) Incomplete multi-mode medical image learning method
Hu et al. Conv-Swinformer: Integration of CNN and shift window attention for Alzheimer’s disease classification
KR101640310B1 (en) Method and Apparatus for Estimation of Symptom Severity Scores for Patients with Schizophrenia using Electroencephalogram Analysis
Hsieh et al. Behavior score-embedded brain encoder network for improved classification of Alzheimer disease using resting state fMRI
CN116228731A (en) Multi-contrast learning coronary artery high-risk plaque detection method, system and terminal
CN116269436A (en) Knowledge distillation-based cross-patient unsupervised SEEG epilepsy early warning method
Xu et al. A Multi-scale Attention-based Convolutional Network for Identification of Alzheimer's Disease based on Hippocampal Subfields
Varghese et al. Discrimination between Alzheimer’s disease, mild cognitive impairment and normal aging using ANN based MR brain image segmentation
Ulhaq et al. Epilepsy seizures classification with EEG signals: A machine learning approach
Inthiyaz A pervasive health care device computing application for brain tumors with machine and deep learning techniques

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant