Epileptic seizure prediction method based on dynamic multi-scale space-time attention network
Through dynamic multi-scale spatiotemporal attention network, combining dynamic time and multi-scale spatial characteristics, the problem of existing models failing to effectively combine global channel interactions and long-term dependence, and improve the accuracy and interpretability of epilepsy prediction. Provides valuable prediction time to reduce the number and severity of seizures.
Patent Information
- Application Number
- CN202411460796.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-18
- Publication Date
- 2024-12-03
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
Existing neural network models fail to effectively combine global channel interactions and long-term dependence in epilepsy prediction, resulting in a lack of interpretability and insufficient prediction accuracy of model results.
Using a dynamic multi-scale space-time attention network method, the dynamic time-space attention model, multi-scale space-time attention model and cross-attention feature fusion model are used to capture the complex spatiotemporal and space-time relationship of EEG signals and obtain long-range space-time characteristics to improve prediction Accuracy.
It improves the accuracy of epilepsy prediction, enhances the recognition of data and interpretability of deep learning algorithms, provides valuable prediction time to reduce the number and severity of epilepsy, and improves the quality of life of patients.
Smart Images

Figure CN119055256A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of epileptic seizure prediction, and in particular to an epileptic seizure prediction method based on a dynamic multi-scale spatiotemporal attention network. Background Art
[0002] Epilepsy is a common disease of the nervous system, characterized by high incidence, suddenness, and recurrence. Because brain nerves have a dynamic transmission mechanism for electrophysiological activity information at different time and space scales, and epileptic EEG data are collected by multiple electrodes targeting different brain regions. Therefore, epileptic seizures not only involve the epileptic seizure area and its surroundings, but also involve brain regions far away from the epileptic seizure area.
[0003] Nowadays, most neural network models for epilepsy prediction only consider capturing local channel interactions in short-term dependencies, but do not consider global channel interactions and long-term dependencies together. They are unable to take into account a variety of information intervals and amounts at the same time, resulting in a lack of interpretability of the models and general results.
[0004] Therefore, it is worthy of in-depth study to introduce a cross-attention mechanism to better integrate spatiotemporal complementary features, and then learn new long-range spatiotemporal correlation features that are helpful in predicting epileptic seizures and exploring the dynamic propagation mechanism that exists during the occurrence of epileptic seizures. Summary of the invention
[0005] The purpose of the present invention is to provide an epileptic seizure prediction method based on a dynamic multi-scale spatiotemporal attention network, explore the complex spatiotemporal synergistic relationship of epileptic EEG, obtain the long-range spatiotemporal characteristics of EEG, and thus improve the accuracy of epileptic seizure prediction; in addition, the present invention also enhances the recognition of original data and increases the interpretability and applicability in deep learning algorithms.
[0006] To achieve the above object, the present invention provides an epileptic seizure prediction method based on a dynamic multi-scale spatiotemporal attention network, comprising the following steps:
[0007] S1. Based on the data collection module, obtain the electrical signals before and during the epileptic seizure;
[0008] S2, based on the data processing module, filtering, purifying and segmenting the EEG signal to obtain time window signal segments;
[0009] S3. Based on the model building and training module, a dynamic multi-scale spatiotemporal attention network is constructed, which includes a dynamic temporal attention model, a multi-scale spatial attention model and a cross-attention feature fusion model.
[0010] Preferably, in step S3, a dynamic multi-scale spatiotemporal attention network is constructed based on the model construction and training module, and the specific process is as follows:
[0011] S31, constructing a dynamic time attention model to obtain global dynamic time features; wherein the dynamic time attention model is composed of a dynamic time excitation module and an attention feedforward module;
[0012] S32. Construct a multi-scale spatial attention model to obtain global multi-scale spatial features; wherein the multi-scale spatial attention model is composed of a channel enhancement convolution module and an attention feedforward module;
[0013] S33. Construct a cross-attention feature fusion model to fuse global dynamic time features and global multi-scale spatial features to obtain long-range spatiotemporal features.
[0014] Preferably, in step S31, a dynamic time attention model is constructed to obtain global dynamic time features, and the specific process is as follows:
[0015] S311, through the dynamic time excitation module, convolution calculation is performed on the time window signal segment to obtain the time step difference and obtain the dynamic time feature; wherein the dynamic time output feature of the dynamic time excitation module is as follows:
[0016]
[0017] Among them, X dw represents the dynamic time output feature, Split represents the segmentation operation based on the time step, and is the input signal segment, conv is a 1×1 2D convolutional layer;
[0018] S312, after the dynamic time excitation module, add an attention feedforward module to obtain global dynamic time features; wherein the attention feedforward module is as follows:
[0019] Q 1 =K 1 =V 1 =Conv 2d (X dw )
[0020] Z 1 =LayerNorm(X dw +Attention(Q 1 ,K 1 ,V 1 ))
[0021] Y 1 =LayerNorm(Z 1 +MLP(Z 1 ))
[0022] Among them, Conv2d Represented as a 1×1 2D convolution; the attention feedforward module includes a self-attention layer and a multi-layer perceptron layer; Z 1 is the output of the self-attention layer with residual connection; Y 1 The global dynamic time feature is obtained through the output of the multi-layer perceptron layer with residual connections; Q 1 , K 1 and V 1 Represents the vectors of query, key, and value in the dynamic temporal attention model; LayerNorm represents layer normalization; Attention represents the output of the attention mechanism; MLP represents the multi-layer perception mechanism;
[0023] The attention mechanism in the self-attention layer is as follows:
[0024]
[0025] Among them, Q 1 K 1 T represents the obtained attention score matrix, d k Represents the dimension of the key vector, used to scale the attention scores.
[0026] Preferably, in step S32, a multi-scale spatial attention model is constructed to obtain global multi-scale spatial features, and the specific process is as follows:
[0027] S321, by inserting a channel excitation module after the three convolution modules, constructing a channel enhancement convolution module, multi-scale analysis of the spatial features of the time window signal fragments, and obtaining multi-scale spatial features; wherein the channel enhancement convolution module is composed of a convolution module and a channel excitation module; the convolution output of the convolution module is as follows:
[0028] u i =Pool i,j+1 (Conv i,j+1 (Pool i,j (Conv i,j (X))))
[0029] U c =(u 1 +u 2 +u 3 )
[0030] Among them, U c is the total output of the three convolutions, u i is the output of a single convolution; Conv i,j+1 Represented as 1D convolution with different kernel sizes, Pool i,j+1 Represented as a one-dimensional maximum pooling layer with different windows;
[0031] The output multi-scale spatial features of the channel excitation module are as follows:
[0032]
[0033] Among them, N is the output multi-scale spatial feature of the channel excitation module, is the average pooling layer, W 1 and W 2 is the fully connected layer, δ is the Relu activation function, and σ is the sigmoid activation function;
[0034] S322, adding a convolutional mapping component to the self-attention layer of the attention feedforward module to obtain global multi-scale spatial features; wherein the attention feedforward module is composed of a self-attention layer and a multi-layer perceptron layer; the self-attention layer includes an attention mechanism and a convolutional mapping component;
[0035] The convolutional map component looks like this:
[0036] Q 2 =K 2 =V 2 =Conv 2d (N)
[0037] Q'=Squeeze(Q 2 )
[0038] K'=Squeeze(K 2 )
[0039] V'=V 2 =Conv 2d (N)
[0040] Among them, Q 2 , K 2 and V 2 Represents the vectors of query, key, and value in the multi-scale spatial attention model; Q', K', and V' are represented as the vectors of reshaped query, key, and value; Conv 2d It is represented by 1×1 2D convolution, and Squeeze represents 3×3 2D convolution;
[0041] The attention mechanism in the self-attention layer is as follows:
[0042]
[0043] Among them, Q'K' T represents the obtained attention score matrix, d k Represents the dimension of the key vector, used to scale the attention scores;
[0044] S323. Based on the above convolutional mapping component and attention mechanism, the attention feedforward module is as follows:
[0045] Z 2 =LayerNorm(V'+Attention(Q',K',V'))
[0046] Y 2 =LayerNorm(Z 2 +MLP(Z 2 ))
[0047] Among them, Z 2 is the output of the self-attention layer with residual connection; Y 2 The global multi-scale spatial features are obtained through the output of the multi-layer perceptron layer with residual connections.
[0048] Preferably, in step S33, a cross-attention feature fusion model is first constructed to fuse the global dynamic time features and the global multi-scale spatial features to obtain long-range spatiotemporal features;
[0049] Then, the long-range spatiotemporal features are trained and updated by using the softmax layer as the classification layer and the cross entropy loss function to achieve epileptic seizure prediction;
[0050] Among them, the output features of the cross-attention feature fusion model are as follows:
[0051] K 3 =V 3 =Conv 2d (Y 1 )
[0052] Q 3 =Conv 2d (Y 2 )
[0053]
[0054] Among them, Q 3 , K 3 and V 3 Y represents the vector of query, key, and value in the cross-attention feature fusion model; 1 is the global dynamic time feature, Y 2 is the global multi-scale spatial feature, Y 3 It is the long-range spatiotemporal characteristics of fusion.
[0055] Therefore, the present invention adopts the above-mentioned epileptic seizure prediction method based on the dynamic multi-scale spatiotemporal attention network, and predicts in advance before the epileptic seizure by real-time monitoring and analysis of EEG signals, providing patients and doctors with valuable preparation time; accurate prediction helps doctors adjust treatment plans in time, reduce the number and severity of epileptic seizures, and improve the quality of life of patients, providing new ideas and technical means for the field of epileptic seizure prediction, and helping to promote scientific research progress and clinical applications in this field.
[0056] The technical solution of the present invention is further described in detail below through the accompanying drawings and embodiments. BRIEF DESCRIPTION OF THE DRAWINGS
[0057] Figure 1 It is a flow chart of an epileptic seizure prediction method based on a dynamic multi-scale spatiotemporal attention network of the present invention;
[0058] Figure 2 It is a flowchart of the implementation of the present invention to construct a dynamic multi-scale spatiotemporal attention network;
[0059] Figure 3 : is a diagram of a dynamic time attention model of the present invention; wherein (a) is a dynamic time excitation module; (b) is an attention feedforward module;
[0060] Figure 4 is a multi-scale spatial attention model diagram of the present invention; wherein, (a) is a channel enhancement convolution module; and (b) is an attention feedforward module. DETAILED DESCRIPTION
[0061] The technical solution of the present invention is further described below through the accompanying drawings and embodiments.
[0062] like Figure 1 As shown, the present invention provides an epileptic seizure prediction method based on a dynamic multi-scale spatiotemporal attention network, comprising the following steps:
[0063] S1, obtaining the electrical signals before and during the epileptic seizure based on the data collection module;
[0064] S2, based on the data processing module, filtering, purifying and segmenting the EEG signal to obtain time window signal segments;
[0065] S3. Based on the model building and training module, a dynamic multi-scale spatiotemporal attention network is constructed, which includes a dynamic temporal attention model, a multi-scale spatial attention model and a cross-attention feature fusion model.
[0066] Example
[0067] The epileptic seizure prediction system based on the dynamic multi-scale spatiotemporal attention network of this embodiment includes: a data collection module, a data processing module, a model building and training module, and a prediction and evaluation module.
[0068] Data collection module: Use multi-channel electroencephalogram (EEG) equipment to monitor and record the EEG signals of epileptic patients for a long time. According to the marker information of epileptic seizures, the signals are divided into pre-ictal and interictal periods.
[0069] Data processing module: including data preprocessing, noise filtering, signal segmentation and other steps. The original EEG signal is denoised and filtered to reduce the impact of external interference on signal quality.
[0070] Model building and training module: By building a dynamic multi-scale spatiotemporal attention network, the pre-processed signal is extracted and learned to distinguish the pre-ictal and interictal signals. The model is trained using labeled EEG data, and the model parameters are adjusted through the back propagation algorithm to minimize the prediction error.
[0071] Prediction and evaluation module: predict the input real-time EEG signal, determine whether it is in the pre-epilepsy stage, and evaluate the prediction performance of the model. Use indicators such as accuracy, recall, and F1 score to evaluate the prediction performance of the model. At the same time, the performance of the model can be further analyzed through ROC curves and AUC values.
[0072] Based on this, a method for predicting epileptic seizures based on a dynamic multi-scale spatiotemporal attention network is proposed, comprising the following steps:
[0073] S1. Acquire the pre- and interictal electrical signals of epileptic seizures based on the data collection module; wherein the EEG signals are non-invasive scalp EEG signals rather than intracranial EEG signals, which can reduce the pain and burden of patients.
[0074] S2. Based on the data processing module, the EEG signal is filtered and purified by using a suitable filter, and the EEG signal is segmented by using a time window of a certain time length and an overlap rate to obtain the time window signal fragments.
[0075] S3. Based on the model building and training module, a dynamic multi-scale spatiotemporal attention network is constructed, which includes a dynamic temporal attention model, a multi-scale spatial attention model, and a cross-attention feature fusion model, such as Figure 2 shown.
[0076] S31, such as Figure 3 As shown, a dynamic time attention model is constructed to obtain global dynamic time features; wherein the dynamic time attention model is composed of a dynamic time excitation module and an attention feedforward module.
[0077] S311, through the dynamic time excitation module, convolution calculation is performed on the time window signal segment to obtain the time step difference and obtain the dynamic time feature; wherein the dynamic time output feature of the dynamic time excitation module is as follows:
[0078]
[0079] Among them, X dw represents the dynamic time output feature, Split represents the segmentation operation based on the time step, and is the input signal segment, and conv is a 1×1 2D convolutional layer.
[0080] S312. In order to further explore and capture the dynamic time features related to epileptic seizures, an attention feedforward module is added after the dynamic time excitation module to obtain global dynamic time features; wherein the attention feedforward module is as follows:
[0081] Q 1 =K 1 =V 1 =Conv 2d (X dw )
[0082] Z 1 =LayerNorm(X dw +Attention(Q 1 ,K 1 ,V 1 ))
[0083] Y 1 =LayerNorm(Z 1 +MLP(Z 1 ))
[0084] Among them, Conv 2d Represented as a 1×1 2D convolution; the attention feedforward module includes a self-attention layer and a multi-layer perceptron layer; Z 1 is the output of the self-attention layer with residual connection; Y 1 The global dynamic time feature is obtained through the output of the multi-layer perceptron layer with residual connections; Q 1 , K 1 and V 1 Represents the vectors of query, key, and value in the dynamic temporal attention model; LayerNorm represents layer normalization; Attention represents the output of the attention mechanism; MLP represents the multi-layer perception mechanism;
[0085] The attention mechanism in the self-attention layer is as follows:
[0086]
[0087] Among them, Q 1 K 1 T represents the obtained attention score matrix, d k Represents the dimension of the key vector, used to scale the attention scores.
[0088] S32, such as Figure 4 As shown in the figure, a multi-scale spatial attention model is constructed to obtain global multi-scale spatial features; wherein the multi-scale spatial attention model is composed of a channel enhanced convolution module and an attention feedforward module.
[0089] S321, by inserting a channel excitation module after the three convolution modules, constructing a channel enhancement convolution module, multi-scale analysis of the spatial features of the time window signal fragments, and obtaining multi-scale spatial features; wherein the channel enhancement convolution module is composed of a convolution module and a channel excitation module; the convolution output of the convolution module is as follows:
[0090] u i =Pool i,j+1 (Conv i,j+1 (Pool i,j (Conv i,j (X))))
[0091] U c =(u 1 +u 2 +u 3 )
[0092] Among them, U c is the total output of the three convolutions, u i is the output of a single convolution; Conv i,j+1 Represented as 1D convolution with different kernel sizes, Pool i,j+1 Represented as a one-dimensional max pooling layer with different windows.
[0093] The output multi-scale spatial features of the channel excitation module are as follows:
[0094]
[0095] Among them, N is the output multi-scale spatial feature of the channel excitation module, is the average pooling layer, W 1 and W 2 is a fully connected layer, δ is the Relu activation function, and σ is the sigmoid activation function.
[0096] S322. In order to pay more attention to multi-scale spatial features and context dependencies, a convolutional mapping component is added to the self-attention layer of the above-mentioned attention feedforward module to obtain global multi-scale spatial features; wherein the attention feedforward module is composed of a self-attention layer and a multi-layer perceptron layer; the self-attention layer includes an attention mechanism and a convolutional mapping component;
[0097] The convolutional map component looks like this:
[0098] Q 2 =K 2 =V 2 =Conv 2d (N)
[0099] Q'=Squeeze(Q 2 )
[0100] K'=Squeeze(K 2 )
[0101] V'=V 2 =Conv 2d (N)
[0102] Among them, Q 2 , K 2 and V 2 Represents the vectors of query, key, and value in the multi-scale spatial attention model; Q', K', and V' are represented as the vectors of reshaped query, key, and value; Conv 2d It is represented as a 1×1 2D convolution, and Squeeze represents a 3×3 2D convolution.
[0103] The attention mechanism in the self-attention layer is as follows:
[0104]
[0105] Among them, Q'K' T represents the obtained attention score matrix, d k Represents the dimension of the key vector, used to scale the dot-product attention to prevent vanishing or exploding gradients.
[0106] S323. Based on the above convolutional mapping component and the attention mechanism, the attention feedforward module is as follows:
[0107] Z 2 =LayerNorm(V'+Attention(Q',K',V'))
[0108] Y 2 =LayerNorm(Z 2 +MLP(Z 2 ))
[0109] Among them, Z 2 is the output of the self-attention layer with residual connection; Y 2 The global multi-scale spatial features are obtained through the output of the multi-layer perceptron layer with residual connections.
[0110] S33. Construct a cross-attention feature fusion model to fuse global dynamic time features and global multi-scale spatial features to obtain long-range spatiotemporal features.
[0111] The global dynamic temporal features and global multi-scale spatial features captured by the dynamic temporal attention model and the multi-scale spatial attention model are input into the cross-attention mechanism to fuse the complementary spatiotemporal features and obtain the long-range spatiotemporal features.
[0112] By using the softmax layer as the classification layer and the cross entropy loss function, the long-range spatiotemporal features are trained and updated to achieve epileptic seizure prediction; among them, the output features of the cross-attention feature fusion model are as follows:
[0113] K 3 =V 3 =Conv 2d (Y 1 )
[0114] Q 3 =Conv 2d (Y 2 )
[0115]
[0116] Among them, Q 3 , K 3 and V 3 Y represents the vector of query, key, and value in the cross-attention feature fusion model; 1 is the global dynamic time feature, Y 2 is the global multi-scale spatial feature, Y 3 It is the long-range spatiotemporal characteristics of fusion.
[0117] Therefore, the present invention adopts the above-mentioned epileptic seizure prediction method based on the dynamic multi-scale spatiotemporal attention network, and predicts in advance before the epileptic seizure by real-time monitoring and analysis of EEG signals, providing patients and doctors with valuable preparation time; accurate prediction helps doctors adjust treatment plans in time, reduce the number and severity of epileptic seizures, and improve the quality of life of patients, providing new ideas and technical means for the field of epileptic seizure prediction, and helping to promote scientific research progress and clinical applications in this field.
[0118] Finally, it should be noted that the above embodiments are only used to illustrate the technical solution of the present invention rather than to limit it. Although the present invention has been described in detail with reference to the preferred embodiments, those skilled in the art should understand that they can still modify or replace the technical solution of the present invention with equivalents, and these modifications or equivalent replacements cannot cause the modified technical solution to deviate from the spirit and scope of the technical solution of the present invention.
Claims
1. A method for predicting epileptic seizures based on a dynamic multi-scale spatiotemporal attention network, characterized in that: The following steps are involved: S1. Based on the data collection module, obtain the electrical signals before and during the epileptic seizure; S2, based on the data processing module, filtering, purifying and segmenting the EEG signal to obtain time window signal segments; S3. Based on the model building and training module, a dynamic multi-scale spatiotemporal attention network is constructed, which includes a dynamic temporal attention model, a multi-scale spatial attention model and a cross-attention feature fusion model.
2. The epileptic seizure prediction method based on a dynamic multi-scale spatiotemporal attention network according to claim 1, characterized in that: In step S3, a dynamic multi-scale spatiotemporal attention network is constructed based on the model building and training module. The specific process is as follows: S31, constructing a dynamic time attention model to obtain global dynamic time features; wherein the dynamic time attention model is composed of a dynamic time excitation module and an attention feedforward module; S32. Construct a multi-scale spatial attention model to obtain global multi-scale spatial features; wherein the multi-scale spatial attention model is composed of a channel enhancement convolution module and an attention feedforward module; S33. Construct a cross-attention feature fusion model to fuse global dynamic time features and global multi-scale spatial features to obtain long-range spatiotemporal features.
3. The epileptic seizure prediction method based on a dynamic multi-scale spatiotemporal attention network according to claim 2, characterized in that: In step S31, a dynamic time attention model is constructed to obtain global dynamic time features. The specific process is as follows: S311, through the dynamic time excitation module, convolution calculation is performed on the time window signal segment to obtain the time step difference and obtain the dynamic time feature; wherein the dynamic time output feature of the dynamic time excitation module is as follows: Among them, X dw represents the dynamic time output feature, Split represents the segmentation operation based on the time step, and is the input signal segment, conv is a 1×1 2D convolutional layer; S312, after the dynamic time excitation module, add an attention feedforward module to obtain global dynamic time features; wherein the attention feedforward module is as follows: Q1=K1=V1=Conv 2d (X dw ) Z1=LayerNorm(X dw +Attention(Q1,K1,V1)) Y1=LayerNorm(Z1+MLP(Z1)) Among them, Conv 2d It is represented as a 1×1 2D convolution; the attention feedforward module includes a self-attention layer and a multi-layer perceptron layer; Z1 is the output of the self-attention layer with residual connections; Y1 is the output of the multi-layer perceptron layer with residual connections to obtain the global dynamic time feature; Q1, K1 and V1 represent the query, key and value vectors in the dynamic time attention model; LayerNorm represents layer normalization; Attention represents the output of the attention mechanism; MLP represents the multi-layer perceptron mechanism; The attention mechanism in the self-attention layer is as follows: Among them, Q1K1 T represents the obtained attention score matrix, d k Represents the dimension of the key vector, used to scale the attention scores.
4. The epileptic seizure prediction method based on a dynamic multi-scale spatiotemporal attention network according to claim 2, characterized in that: In step S32, a multi-scale spatial attention model is constructed to obtain global multi-scale spatial features. The specific process is as follows: S321, by inserting a channel excitation module after the three convolution modules, constructing a channel enhancement convolution module, multi-scale analysis of the spatial features of the time window signal fragments, and obtaining multi-scale spatial features; wherein the channel enhancement convolution module is composed of a convolution module and a channel excitation module; the convolution output of the convolution module is as follows: u i =Pool i,j+1 (Conv i,j+1 (Pool i,j (Conv i,j (X)))) U c =(u1+u2+u3) Among them, U c is the total output of the three convolutions, u i is the output of a single convolution; Conv i,j+1 Represented as 1D convolution with different kernel sizes, Pool i,j+1 Represented as a one-dimensional maximum pooling layer with different windows; The output multi-scale spatial features of the channel excitation module are as follows: Among them, N is the output multi-scale spatial feature of the channel excitation module, is the average pooling layer, W1 and W2 are fully connected layers, δ is the Relu activation function, and σ is the sigmoid activation function; S322, adding a convolutional mapping component to the self-attention layer of the attention feedforward module to obtain global multi-scale spatial features; wherein the attention feedforward module is composed of a self-attention layer and a multi-layer perceptron layer; the self-attention layer includes an attention mechanism and a convolutional mapping component; The convolutional map component looks like this: <h2 style=";text-align:left;direction:ltr">Q2 = K2 = V2 = Conv<h2 style=";text-align:left;direction:ltr"> 2d <h2 style=";text-align:left;direction:ltr"> (N) Q'=Squeeze(Q2) K'=Squeeze(K2) V'=V2=Conv 2d (N) Among them, Q2, K2 and V2 represent the vectors of query, key and value in the multi-scale spatial attention model; Q', K' and V' represent the vectors of query, key and value after reshaping; Conv 2d It is represented by 1×1 2D convolution, and Squeeze represents 3×3 2D convolution; The attention mechanism in the self-attention layer is as follows: Among them, Q'K' T represents the obtained attention score matrix, d k Represents the dimension of the key vector, used to scale the attention scores; S323. Based on the above convolutional mapping component and attention mechanism, the attention feedforward module is as follows: Z2=LayerNorm(V'+Attention(Q',K',V')) Y2=LayerNorm(Z2+MLP(Z2)) Among them, Z2 is the output of the self-attention layer with residual connection; Y2 is the output of the multi-layer perceptron layer with residual connection to obtain the global multi-scale spatial features.
5. The epileptic seizure prediction method based on a dynamic multi-scale spatiotemporal attention network according to claim 2, characterized in that: In step S33, a cross-attention feature fusion model is first constructed to fuse the global dynamic time features and the global multi-scale spatial features to obtain long-range spatiotemporal features; Then, the long-range spatiotemporal features are trained and updated by using the softmax layer as the classification layer and the cross entropy loss function to achieve epileptic seizure prediction; Among them, the output features of the cross-attention feature fusion model are as follows: K3=V3=Conv 2d (Y1) Q3=Conv 2d (Y2) Among them, Q3, K3 and V3 represent the vectors of query, key and value in the cross-attention feature fusion model; Y1 is the global dynamic temporal feature, Y2 is the global multi-scale spatial feature, and Y3 is the fused long-range spatiotemporal feature.
Citation Information
Cited By
Intracranial electroencephalogram epileptic seizure early warning method based on multipath map brain network modeling
CN119856911A
Epilepsy detection method based on Riemannian manifold
CN119939355A
Depression assessment system based on brain-computer interface technology
CN119949834A
Big data fused overseas public opinion security situation intelligent perception method and system
CN120429400A
Epileptic seizure prediction method fusing multi-frequency coupling and multiple attention mechanisms
CN120678390A
