Epileptic seizure early warning method and system
Through deep learning-based methods, the EEG signal and motion data are denoised and feature extraction, and cross-modal aggregation analysis is carried out, which solves the problem of insufficient warning accuracy and credibility in the prior art, and achieves a more accurate and flexible early warning of epilepsy.
Patent Information
- Application Number
- CN202510127913.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-02-05
- Publication Date
- 2025-03-04
- Estimated Expiration
- 2045-02-05
AI Technical Summary
Existing early warning methods for epilepsy are insufficient in capturing subtle patterns in complex data and considering the relationship between features, resulting in low accuracy and credibility of early warnings, especially when faced with significant individual differences.
Using a deep learning-based method, noise reduction processing and feature extraction are performed by obtaining the time queue of EEG signals and motion data, combined with the cross-modal aggregation analysis of the motion state-EEG signals, identification results are generated for representing the risk of epilepsy, and corresponding warning prompts are generated.
A more accurate early warning of epilepsy is achieved. By comprehensively capturing subtle patterns in user data and fully considering the interrelationships between characteristics, the accuracy and credibility of early warning are improved, and the unique physiological characteristics and dynamic changes of different patients are adapted to different patients.
Smart Images

Figure CN119548106A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of intelligent health management, and more specifically, to an epileptic seizure warning method and system. Background Art
[0002] Epilepsy is a chronic disease caused by abnormal discharges of brain neurons, which manifests as repeated short-term brain dysfunction, affecting consciousness, movement, etc., and in severe cases, it is life-threatening. Its onset is difficult to predict, which brings great inconvenience to patients' lives. Existing home monitoring equipment has limited functions and can only perform simple EEG signal recording or motion detection based on a single sensor, resulting in insufficient accuracy and timeliness of early warning.
[0003] In this regard, the invention with publication number CN118383730B proposes an epileptic seizure warning method, system, electronic device and storage medium. First, the real-time collected data is filtered and standardized to reduce noise and unify the order. Then, multiple features are extracted from the processed EEG and ECG signals, and the movement pattern is analyzed. These features are quantified into scores, and the predicted score is obtained by weighted summation. When this score reaches or exceeds the set threshold, the system determines that there is a risk of epileptic seizure and triggers a warning. This method solves the defects of the existing single data collection and aims to improve the prediction accuracy.
[0004] In this patent, the collected data is standardized and predefined features are extracted, the scores of each data are calculated, and then these scores are combined and compared with the warning threshold to determine the risk of epileptic seizures. Although predefined features (such as statistical, frequency domain and nonlinear features) are effective in specific situations, they may not be able to fully capture subtle patterns in complex data and fail to fully consider the relationship between features. In addition, the risk assessment method with fixed thresholds is prone to high false positives or negatives, especially when faced with significant individual differences, which affects the accuracy and credibility of the warning. This static method is difficult to adapt to the unique physiological characteristics and dynamic changes of different patients, limiting the flexibility and adaptability of the system.
[0005] Therefore, an optimized early warning scheme for epileptic seizures is desired. Summary of the invention
[0006] In view of the shortcomings of the prior art, the present application provides an epileptic seizure warning method and system.
[0007] According to one aspect of the present application, a method for early warning of epileptic seizures is provided, comprising: Obtaining a time queue of electroencephalogram signals and motion data of the user to be monitored in a predetermined time period; Performing noise reduction processing on the electroencephalogram signal to obtain a noise-reduced electroencephalogram signal; Extracting electroencephalogram signal features from the denoised electroencephalogram signal to obtain an electroencephalogram signal feature encoding map; Extracting running state features from the time queue of the motion data to obtain a motion state time series encoding feature vector; The motion state time series coding feature vector and the electroencephalogram signal feature coding map are subjected to motion state-EEG cross-modal aggregation analysis to obtain a motion state-EEG cross-modal fine-grained aggregation coding vector, including: performing feature decoupling and feature flattening on the electroencephalogram signal feature coding map to obtain a set of electroencephalogram signal local feature coding vectors; calculating the kernel features of the set of electroencephalogram signal local feature coding vectors; based on the kernel features, performing fine-grained prior fusion on the motion state time series coding feature vector and the set of electroencephalogram signal local feature coding vectors to obtain the motion state-EEG cross-modal fine-grained aggregation coding vector; Based on the movement state-EEG cross-modal fine-grained aggregate coding vector, an identification result is obtained to indicate whether the user to be monitored has an epileptic seizure risk, and based on the identification result, an epileptic seizure warning prompt is generated.
[0008] Furthermore, extracting EEG signal features from the denoised EEG signal to obtain an EEG signal feature coding map includes: inputting the denoised EEG signal into a signal extractor based on a fully convolutional neural network to obtain the EEG signal feature coding map.
[0009] Furthermore, the time queue of the motion data is subjected to running state feature extraction to obtain a motion state time series coding feature vector, including: inputting the time queue of the motion data into a running state feature extractor based on a forward LSTM model to obtain the motion state time series coding feature vector.
[0010] Furthermore, the feature decoupling and feature flattening of the electroencephalogram signal feature coding map are performed to obtain a set of local feature coding vectors of the electroencephalogram signal, including: expanding each feature matrix of the electroencephalogram signal feature coding map along the channel dimension into a feature vector to obtain a set of local feature coding vectors of the electroencephalogram signal.
[0011] Further, calculating the kernel features of the set of local feature encoding vectors of the electroencephalogram signal includes: Calculating the semantic difference value between each electroencephalogram signal local feature coding vector and all other electroencephalogram signal local feature coding vectors in the set of electroencephalogram signal local feature coding vectors to obtain a set of electroencephalogram signal semantic difference values; Performing a normalization process based on a softmax function on the set of semantic difference values of the electroencephalogram signal to obtain a set of normalized semantic difference values of the electroencephalogram signal; The set of normalized electroencephalogram signal semantic difference values is used as a set of weights, and the weighted sum of the set of electroencephalogram signal local feature encoding vectors is calculated to obtain an electroencephalogram signal kernel feature vector as the kernel feature.
[0012] Further, based on the kernel feature, a fine-grained prior fusion is performed on the set of the motion state temporal coding feature vector and the electroencephalogram signal local feature coding vector to obtain the motion state-electroencephalogram cross-modal fine-grained aggregated coding vector, including: Determining a motion state-EEG signal priori clustering center encoding vector based on the motion state temporal encoding feature vector and the EEG signal kernel feature vector; A cross-domain fine-grained clustering description is performed on the set of the motion state-EEG signal prior clustering center encoding vector and the EEG signal local feature encoding vector to obtain the motion state-EEG cross-modal fine-grained aggregation encoding vector.
[0013] Further, based on the motion state-EEG cross-modal fine-grained aggregated coding vector, an identification result is obtained to indicate whether the user to be monitored has an epileptic seizure risk, and based on the identification result, an epileptic seizure warning prompt is generated, including: Inputting the movement state-EEG cross-modal fine-grained aggregated encoding vector into a classifier-based epilepsy seizure identifier to obtain the recognition result, wherein the recognition result is used to indicate whether the user to be monitored has an epileptic seizure risk; In response to the identification result that the user to be monitored is at risk of epileptic seizure, the epileptic seizure warning prompt is generated.
[0014] Further, the movement state-EEG cross-modal fine-grained aggregated encoding vector is input into a classifier-based epilepsy seizure identifier to obtain the recognition result, and the recognition result is used to indicate whether the user to be monitored has an epileptic seizure risk, including: Using the fully connected layer of the classifier, the motion state-EEG cross-modal fine-grained aggregated coding vector is fully connected to obtain a motion state-EEG cross-modal fine-grained aggregated fully connected coding feature vector; Inputting the motion state-EEG cross-modal fine-grained aggregated fully connected encoding feature vector into the Softmax classification function of the classifier to obtain probability values of the motion state-EEG cross-modal fine-grained aggregated encoding vector belonging to each classification label, wherein the classification label includes a value for indicating that the user to be monitored has an epileptic seizure risk and a value for indicating that the user to be monitored does not have an epileptic seizure risk; The classification label corresponding to the largest probability value among the probability values is determined as the recognition result.
[0015] According to another aspect of the present application, there is provided an epileptic seizure warning system, comprising: A user monitoring data acquisition module, used to obtain a time queue of the EEG signal and motion data of the user to be monitored in a predetermined time period; An EEG signal noise reduction module, used for performing noise reduction processing on the EEG signal to obtain a noise-reduced EEG signal; An EEG signal feature extraction module, used to extract EEG signal features from the denoised EEG signal to obtain an EEG signal feature coding map; A running state feature extraction module, used for extracting running state features from the time queue of the motion data to obtain a motion state time series coding feature vector; The running state EEG signal aggregation analysis module is used to perform motion state-EEG signal cross-modal aggregation analysis on the motion state time series coding feature vector and the EEG signal feature coding map to obtain a motion state-EEG cross-modal fine-grained aggregation coding vector, wherein the running state EEG signal aggregation analysis module includes: an EEG signal feature decoupling and flattening unit, used to perform feature decoupling and feature flattening on the EEG signal feature coding map to obtain a set of EEG signal local feature coding vectors; an EEG signal kernel feature calculation unit, used to calculate the kernel feature of the set of EEG signal local feature coding vectors; a cross-modal fine-grained coding fusion unit, used to perform fine-grained prior fusion on the motion state time series coding feature vector and the set of EEG signal local feature coding vectors based on the kernel feature to obtain the motion state-EEG cross-modal fine-grained aggregation coding vector; An epileptic seizure warning prompt generation module is used to obtain an identification result indicating whether the monitored user has an epileptic seizure risk based on the movement state-EEG cross-modal fine-grained aggregate coding vector, and generate an epileptic seizure warning prompt based on the identification result.
[0016] Furthermore, the EEG signal denoising module is used to: input the denoised EEG signal into a signal extractor based on a fully convolutional neural network to obtain the EEG signal feature coding map.
[0017] This application has significant technical effects due to the adoption of the above technical solutions: The epilepsy attack warning method and system provided by the present application uses data processing technology based on deep learning to perform noise reduction and feature extraction on the EEG signal of the monitored user in a predetermined time period, and extracts the running state feature of the time queue of the motion data, so as to intelligently identify whether the monitored user has an epileptic seizure risk based on the cross-modal aggregation representation between the motion state temporal coding feature and the EEG signal feature, and generate corresponding epileptic seizure warning prompts. In this way, by comprehensively capturing the subtle patterns in the data of different users and fully considering the relationship between the features, a more accurate epileptic seizure warning can be achieved. BRIEF DESCRIPTION OF THE DRAWINGS
[0018] By describing the embodiments of the present application in more detail in conjunction with the accompanying drawings, the above and other purposes, features and advantages of the present application will become more apparent. The accompanying drawings are used to provide a further understanding of the embodiments of the present application and constitute a part of the specification. Together with the embodiments of the present application, they are used to explain the present application and do not constitute a limitation of the present application. In the accompanying drawings, the same reference numerals generally represent the same components or steps.
[0019] Figure 1 Flow chart of an epileptic seizure warning method according to an embodiment of the present application.
[0020] Figure 2 Schematic diagram of data flow of an epileptic seizure warning method according to an embodiment of the present application.
[0021] Figure 3 Flow chart of step S5 in the epilepsy attack warning method according to an embodiment of the present application.
[0022] Figure 4 Flow chart of step S6 in the epilepsy attack warning method according to an embodiment of the present application.
[0023] Figure 5 4 is a system block diagram of an epileptic seizure warning system according to an embodiment of the present application. DETAILED DESCRIPTION
[0024] Below, the exemplary embodiments according to the present application will be described in detail with reference to the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present application, rather than all the embodiments of the present application, and it should be understood that the present application is not limited to the exemplary embodiments described here.
[0025] Epilepsy is a chronic disease caused by abnormal discharges of brain neurons, characterized by recurring transient brain dysfunction that may affect the patient's consciousness and motor abilities and, in severe cases, pose a threat to life. Since epileptic seizures are difficult to predict, they cause many inconveniences in patients' daily lives. Currently, home monitoring devices have functional limitations and can only perform simple EEG signal recording or motion detection based on a single sensor, resulting in poor accuracy and timeliness of early warnings.
[0026] In response to this situation, the invention with publication number CN118383730B proposes an epileptic seizure warning, system, electronic device and storage medium. It first filters and standardizes the real-time collected data to reduce noise interference and unify the data level. Subsequently, multiple features are extracted from the processed electroencephalogram (EEG) and electrocardiogram (ECG) signals, and the movement patterns are analyzed. These features are quantified into scores, and the predicted score is obtained by weighted summation. When the score reaches or exceeds the set threshold, the system determines that there is a risk of epileptic seizure and triggers a warning. This method aims to solve the drawbacks of the existing collection of only single data to improve the prediction accuracy.
[0027] However, this patented technology has certain limitations in practical applications. It standardizes the collected data and extracts predefined features to calculate the score, and then compares the comprehensive score with the warning threshold to determine the risk. Although predefined features (such as statistical, frequency domain, and nonlinear features) are effective in specific scenarios, they may not be able to fully capture subtle patterns in complex data, and fail to fully consider the relationship between features. At the same time, the risk assessment method with fixed thresholds is prone to high false positives or negative negatives, especially when facing a patient group with large individual differences, which has a negative impact on the accuracy and credibility of the warning. This static method is difficult to adapt to the unique physiological characteristics and dynamic changes of different patients, limiting the flexibility and adaptability of the system.
[0028] Based on the above technical problems, this application proposes an epileptic seizure warning method, the technical concept of which is to obtain the time queue of the EEG signal and motion data of the monitored user in a predetermined time period, use deep learning-based signal processing and data analysis technology to perform noise reduction and feature extraction on the EEG signal, and extract the running state feature of the time queue of the motion data, so as to intelligently identify whether the monitored user has an epileptic seizure risk based on the cross-modal aggregation representation between the motion state timing coding feature and the EEG signal feature, and generate corresponding epileptic seizure warning prompts. This application can automatically mine the complex detail patterns in the original data, break through the traditional preset feature limitations, grasp the correlation between features, and realize the comprehensive presentation of data. At the same time, the warning threshold is dynamically adjusted according to the individual condition of the user to improve the accuracy of the system, providing an accurate, flexible and reliable solution for the health management of epilepsy patients.
[0029] Figure 1 Flow chart of an epileptic seizure warning method according to an embodiment of the present application. Figure 2 Schematic diagram of data flow of the epilepsy attack warning method according to an embodiment of the present application. Figure 1 and Figure 2 As shown, according to the embodiment of the present application, the epilepsy attack warning method includes: S1, obtaining a time queue of the electroencephalogram (EEG) signal and motion data of the user to be monitored in a predetermined time period; S2, performing denoising processing on the EEG signal to obtain a denoised EEG signal; S3, extracting EEG signal features from the denoised EEG signal to obtain an EEG signal feature coding map; S4, performing running state feature extraction on the time queue of the motion data to obtain a motion state timing coding feature vector; S5, performing motion state-EEG cross-modal aggregation analysis on the motion state timing coding feature vector and the EEG signal feature coding map to obtain a motion state-EEG cross-modal fine-grained aggregation coding vector; S6, based on the motion state-EEG cross-modal fine-grained aggregation coding vector, obtaining an identification result for indicating whether the user to be monitored has an epileptic seizure risk, and based on the identification result, generating an epileptic seizure warning prompt.
[0030] In step S1, a time queue of electroencephalogram signals and motion data of the user to be monitored in a predetermined time period is obtained. It should be understood that the electroencephalogram (EEG) signal is a record of the electrical activity of brain neurons, reflecting the physiological and pathological state of the brain. It contains frequency information, amplitude information, etc. of neuronal discharge. In detail, brain waves of different frequencies represent different brain states. For example, delta waves (0.5-4Hz) usually appear in deep sleep or certain pathological states, theta waves (4-8Hz) are common in children and drowsy states, alpha waves (8-13Hz) usually appear in a relaxed and awake state, beta waves (13-30Hz) are related to the active state of the brain and concentration, and gamma waves (above 30Hz) involve higher-level cognitive functions such as perception, learning, and consciousness. During an epileptic seizure, the frequency of brain waves may be abnormal, such as spikes or sharp waves. These abnormal waveforms are typical characteristics of epileptic seizures. In addition, during an epileptic seizure, the amplitude of brain waves may suddenly increase or decrease, showing abnormal high or low amplitude changes. That is, by analyzing the changing trend of the acquired EEG signal's frequency, amplitude and other characteristics, the potential risk of epileptic seizures can be predicted. The time queue of motion data collected here is a continuous record of the user's motion state over a period of time, including the user's limb movement information, the frequency and duration of the movement, the movement pattern information, etc. Specifically, the limb movement information includes the movement speed, acceleration, displacement and other information of the limbs such as arms, legs, and head. During an epileptic seizure, the patient may experience limb twitching, tremors, muscle spasms and other movements, which can be monitored and recorded by sensors such as accelerometers and gyroscopes. During an epileptic seizure, there may also be short and frequent abnormal movements or long-term abnormal movements, such as continuous twitching. By analyzing the time queue of motion data, it is possible to capture whether the user's motion state changes are abnormal. In addition, normal movements often have certain regularity, while movements caused by epileptic seizures may be irregular. For example, periodic twitching or rapid, involuntary movement sequences may occur. These abnormal patterns can be captured by analyzing the time series of motion data. That is, by analyzing the changing trends of movement frequency and intensity in the time queue of motion data, it is also possible to determine whether an epileptic seizure is about to occur. In general, EEG signals mainly reflect the electrophysiological state of the brain and are a direct physiological indicator of epileptic seizures, while motion data reflects the external manifestations of the body. By monitoring these two types of data at the same time, the risk of epileptic seizures can be more comprehensively assessed from both internal and external aspects.
[0031] The following is a detailed description of a specific implementation process of "obtaining a time queue of EEG signals and motion data of a user to be monitored in a predetermined time period": The acquisition of EEG signals requires the help of professional EEG acquisition equipment, which is usually based on advanced electronic technology and bioelectric detection principles. Taking the medical EEG as an example, its core components include multiple carefully designed electrodes, which must strictly follow the international standard 10-20 electrode system when placed on the patient's scalp. This system ensures that the electrodes can accurately cover various key areas of the brain, thereby fully and accurately capturing the brain's electrical activity. Each electrode is connected to the amplifier module of the EEG through high-quality wires, and the amplifier plays a vital role in this process. It can amplify the weak electrical signals generated by the brain to a level of intensity that can be subsequently analyzed and recorded. At the same time, in order to eliminate the influence of external interference on EEG signals, the amplifier also has a powerful filtering function. Common interference sources such as 50Hz or 60Hz power frequency interference can be effectively removed after filtering by the amplifier, thereby ensuring the purity and accuracy of the collected EEG signals.
[0032] In actual operation, the parameter setting of the equipment is crucial to obtain high-quality EEG signals. Among them, the sampling frequency is a key parameter, which is usually set to 256Hz or even higher according to the monitoring needs and the characteristics of the EEG signal. A higher sampling frequency can ensure that subtle changes and rapid fluctuations in EEG signals are captured, which may contain important physiological information or abnormal signals related to epileptic seizures. The recording time varies according to different monitoring purposes. For long-term tracking of the condition of epilepsy patients, it may be necessary to continuously record EEG signals for several hours or even days. Such long-term recording can fully reflect the patient's brain electrical activity in different living states and time periods, and help to discover potential patterns of epileptic seizures. In some short-term diagnostic monitoring scenarios, the recording time may be relatively short, generally between 30 minutes and 1 hour. During the entire recording process, the EEG will convert the analog EEG signals collected from the scalp electrodes into digital signals for storage and subsequent computer analysis. These digital signals will be stored in a local storage device in an orderly manner. Common storage devices include hard disks or memory cards, which provide a stable data source for subsequent data processing and analysis.
[0033] The collection of motion data mainly relies on wearable motion sensors, among which accelerometers and gyroscopes are two commonly used core sensors. Based on the principle of mechanics, accelerometers can accurately measure the acceleration changes of users in three axes (X, Y, and Z). By analyzing these acceleration data, the user's limb movements can be effectively detected, such as arm swings, leg walking or running movements, and changes in body posture, such as standing, sitting, and bending. Gyroscopes focus on measuring the rotation angle and angular velocity of objects. They perform well in capturing motion information such as the user's head rotation and body twisting. These sensors are usually integrated into miniaturized and portable devices, such as smart bracelets, smart patches, or specially designed sports monitoring chest straps. These wearable devices are not only easy to wear and do not cause obvious obstacles to the user's daily activities, but also can realize continuous monitoring of the user's motion status.
[0034] When working, the motion sensor will collect data at a certain frequency, which is generally between 10Hz and 100Hz. The choice of frequency depends on the requirements for the accuracy of motion details. A higher frequency can capture more subtle motion changes, but it will also increase the amount of data and the energy consumption of the device. The collected motion data will be transmitted in real time to the paired data receiving device via Bluetooth or other advanced wireless communication technologies. On the receiving device, special software applications are installed, which will perform preliminary processing and sorting of the motion data. They will arrange the data collected at each time point in chronological order to form a complete time queue of motion data, ensuring that the time sequence of the data is accurate so that it can be effectively associated with the EEG signal for subsequent analysis.
[0035] Taking the epilepsy monitoring ward of the hospital as an example, after the patient is admitted to the hospital, the medical staff will put on the EEG electrode cap and wearable motion sensor for him. During the wearing process, the medical staff will strictly follow the operating procedures to ensure that the electrodes of the electrode cap are in close contact with the patient's scalp to ensure the good signal transmission, and adjust the position of the motion sensor so that it can accurately detect the patient's movement. Subsequently, the medical staff will turn on the EEG and motion data acquisition equipment, and carefully set the relevant parameters according to the patient's specific situation and monitoring purpose. During the next monitoring period, such as 24 hours of continuous monitoring, the EEG will continuously record the patient's brain electrical activity, and the motion sensor will also synchronously collect the patient's movement information. These data will be stored in their respective devices, and the data will be transmitted to the server of the hospital's central monitoring system through a dedicated data transmission interface. In the server, the time queues of the integrated EEG signals and motion data will be deeply analyzed and processed, and the potential laws and abnormal characteristics in the data will be mined to provide comprehensive and accurate data support for the early warning and diagnosis of epileptic seizures, thereby helping doctors better understand the patient's condition and formulate more effective treatment plans.
[0036] In step S2, the EEG signal is subjected to noise reduction processing to obtain a noise-reduced EEG signal. Accordingly, it is considered that during the EEG signal acquisition process, there are various electromagnetic interference sources in the surrounding environment, such as electronic equipment, power lines, etc. These interferences will be superimposed on the EEG signal in the form of noise, making the original signal messy, and the interference signal and the EEG signal characteristics are confused with each other, which greatly affects the subsequent analysis and processing of the EEG signal. Therefore, in order to remove a large amount of irrelevant interference information, make the features related to epileptic seizures more prominent, and make the EEG signal clearer, in the technical solution of the present application, the EEG signal is subjected to noise reduction processing to obtain a noise-reduced EEG signal, which can facilitate the subsequent more accurate extraction of key features in the EEG signal, such as the waveform of a specific frequency, the amplitude change of the signal, etc.
[0037] In a specific embodiment of the present application, a self-encoder-decoder is used to perform noise reduction processing on the EEG signal. The self-encoder-decoder is an unsupervised learning model, which consists of two parts: an encoder and a decoder. The core idea is to compress the input data into a low-dimensional representation (encoding) by training a neural network, and then reconstruct the data as close to the original input as possible from this low-dimensional representation (decoding). In this process, the network learns to capture the essential characteristics of the input data, and those components that are considered to be "noise" are filtered out. This method can effectively remove irrelevant interference information in the original data. The following is a detailed explanation of a specific implementation process of "using a self-encoder-decoder to perform noise reduction processing on the EEG signal to obtain a noise-reduced EEG signal": The first is the careful design of the model architecture, which is the core part of the entire noise reduction process. For the encoder, when it receives the original EEG signal, it usually faces the complex characteristics of the signal, especially when it is assumed that the original signal is a single-channel signal, and its format may be [number of samples, time series length]. In order to extract more valuable feature information, the first convolution layer will come into play. It will use a specific convolution kernel, such as a convolution kernel of size 3, and a certain step size (such as a step size of 1) to convolve the signal. In this process, the dimension of the signal will change from the original format to a representation with more feature channels, for example, it will become [number of samples, number of feature channels, time series length]. At the same time, in order to introduce nonlinear characteristics so that it can better fit the complex EEG signal characteristics, activation functions are used, such as the common ReLU function. The introduction of this nonlinearity is crucial for the model to learn complex patterns in the signal, because the EEG signal is not a simple linear relationship, but contains rich physiological information and possible noise interference.
[0038] After the first layer of convolution operation, the pooling layer will start to work in order to further refine and compress the features. Usually, the maximum pooling layer is used, and its pooling kernel size can be set to 2, with a step size of 2, to downsample the features. The downsampling process can help the model focus on more important feature information and reduce the dimension of the data. This is an effective means of dimensionality reduction. At the same time, it can also enable the model to pay more attention to the main features of the signal in subsequent processing, avoiding interference from some minor noise or unimportant information. After a combination of multiple such convolution and pooling operations, the encoder will gradually compress the original EEG signal into a low-dimensional feature representation. This low-dimensional feature representation contains the core information of the signal, but has been abstracted and refined, removing some surface noise and redundant information.
[0039] The decoder is the inverse process of the encoder, but it is not just a simple inverse operation. It consists of multiple deconvolution layers (also called transposed convolution layers) that receive low-dimensional feature representations from the encoder output. These deconvolution layers use appropriate convolution kernels and strides to perform upsampling operations, aiming to gradually restore the original dimension of the signal. In this process, the activation function also plays an important role. Each deconvolution layer usually uses activation functions such as ReLU to process data to maintain the nonlinear characteristics of signal processing. In the last deconvolution layer, its task is to restore the signal to the same dimensional format as the original EEG signal, that is, to [number of samples, time series length]. In order to ensure that the output signal is within a reasonable range, a suitable activation function, such as Sigmoid or Tanh function, is used to map the output value to a suitable range, which can ensure the rationality and effectiveness of the reconstructed signal, prevent unreasonable signal values, and also conform to the physiological range characteristics of the EEG signal.
[0040] Next is the training process, which is a critical stage for the model to learn noise reduction capabilities. At this stage, sufficient data preparation is required, which is the basis of the entire training. A large amount of EEG signal data needs to be collected. These data should cover different noise levels and different physiological states as much as possible, because EEG signals are affected by many factors, and the signal performance of different individuals in different states will vary. Therefore, a rich source of data can improve the generalization ability of the model. The collected data will be divided into training sets, validation sets, and test sets. In the training set, it is necessary to prepare both noisy EEG signals and corresponding clean EEG signals. These clean signals can be collected by professional high-precision equipment, or obtained by fine data cleaning and labeling of the original data. The quality and integrity of these data directly affect the effect of model training.
[0041] When choosing a loss function, mean square error (MSE) is a common choice. The principle is to input the noisy EEG signal into the encoder-decoder model, obtain the reconstructed signal after processing by the model, and then calculate the MSE loss between the reconstructed signal and the corresponding clean EEG signal. The goal of model training is to minimize this difference. This means that the model needs to constantly adjust its own parameters to make this difference as small as possible, so that the reconstructed signal is closer to the clean signal and achieve the purpose of removing noise. There are many options for optimizing, such as stochastic gradient descent (SGD), Adagrad, Adadelta, RMSProp or Adam. Among them, taking the Adam optimizer as an example, it has good performance and will adaptively adjust the gradient of the model parameters according to the loss function. In each training iteration, the optimizer will update the parameters according to the current parameter value and the calculated gradient, according to the set learning rate and its own optimization algorithm rules. For example, in each round of training, the convolution kernel weights, biases and other parameters of the encoder and decoder will be reasonably adjusted according to the size and direction of the gradient, so that the model develops in the direction of minimizing the loss function. During the training process, a number of training rounds will be set, which may be 100 rounds or even more. During this long training cycle, the training will be cyclically performed according to the set training process. In each round of training, noisy EEG signals and corresponding clean signals will be loaded from the training set in a certain batch size, and the noisy signals will be input into the model for forward propagation to obtain the reconstructed signal, and then the loss function value will be calculated. After the loss is calculated, a backpropagation operation will be performed to update the model parameters according to the rules of the optimizer. At the same time, in order to ensure the performance of the model and prevent overfitting, the performance of the model will be regularly evaluated on the validation set to observe the changes in the loss function value. If it is found that the performance of the model on the validation set is no longer improving, for example, the loss function value no longer decreases, or even begins to increase, this means that the model may have begun to overfit. At this time, the training can be stopped in advance to avoid the model overfitting the training data, resulting in performance degradation in actual applications.
[0042] Finally, it is the application stage. After a long period of training, when the model reaches a relatively ideal state and completes the training task, it can be applied to actual EEG signal processing. For the newly collected EEG signal, it is directly input into the trained self-encoder decoder model. The model will process the input signal according to the noise reduction mode learned in the training phase. This processing is automatic and efficient. It will identify and remove the noise in the signal, and the final output is the noise-reduced EEG signal. The quality of these noise-reduced signals has been significantly improved, which can more clearly reflect the physiological state of the brain and provide a better data basis for subsequent epileptic seizure analysis and early warning.
[0043] In step S3, the EEG signal features are extracted from the denoised EEG signal to obtain an EEG signal feature coding map. Specifically, in an embodiment of the present application, step S3 includes: inputting the denoised EEG signal into a signal extractor based on a fully convolutional neural network to obtain the EEG signal feature coding map. It should be understood that the EEG signal itself is an extremely complex bioelectric signal, which contains various information of the brain in different states. Therefore, in order to mine and refine key and important EEG signal features, the present application extracts EEG signal features from the denoised EEG signal to capture these subtle but critical changes, and obtains an EEG signal feature coding map, thereby discovering patterns closely related to epileptic seizures. In particular, in a specific embodiment of the present application, the denoised EEG signal can be processed by a signal extractor based on a fully convolutional neural network to obtain an EEG signal feature coding map. It can be understood that the fully convolutional neural network has a powerful feature extraction capability in the fields of image processing and signal processing. The EEG signal can be regarded as a time series signal, similar to a pixel sequence in an image. The fully convolutional neural network can automatically learn local features in the signal through convolutional layers and pooling layers, and by stacking multi-layer network structures, it can gradually extract more abstract and advanced features. That is, for EEG signals, it can start with the extraction of local features such as the basic waveform of the signal, and through multi-layer networks, it can mine complex feature patterns related to epileptic seizures. In addition, since EEG signals have a complex time-frequency structure. The convolution layer of the network can handle this structure well, and through convolution kernels of different sizes, it can capture signal features on different time scales and frequency scales. For example, smaller convolution kernels can be used to capture rapidly changing high-frequency signal features, while larger convolution kernels can be used to extract more macroscopic, slowly changing low-frequency signal features, which helps to comprehensively extract various features in EEG signals.
[0044] In step S4, the time queue of the motion data is subjected to running state feature extraction to obtain a motion state time series encoding feature vector. Specifically, in an embodiment of the present application, the step S4 includes: inputting the time queue of the motion data into a running state feature extractor based on a forward LSTM model to obtain the motion state time series encoding feature vector. It should be understood that the time queue of the motion data is a sequence data that changes over time, and there is a close time dependency between the data of the previous and next time points. For example, the motion state of the user before an epileptic seizure may gradually change, and the movement amplitude, speed, etc. at a certain moment may be related to the previous state. Based on this, in order to effectively capture the correlation and dynamic changes between these time points, in the technical solution of the present application, the time queue of the motion data is input into a running state feature extractor based on a forward LSTM model to dig out the potential feature pattern of the motion data in the time dimension, and obtain the motion state time series encoding feature vector. In particular, the forward LSTM model has a gating mechanism, including an input gate, a forget gate, and an output gate, and these gating structures can dynamically control the inflow, retention, and output of information. Through the forget gate, the forward LSTM model can decide to discard unimportant information from the past, and through the input gate and output gate, it can choose to retain and output information that is important for current feature extraction, thereby adapting to the dynamic changing characteristics of motion data and accurately extracting features that reflect the dynamic changes in motion status.
[0045] In step S5, the motion state temporal coding feature vector and the electroencephalogram signal feature coding map are subjected to motion state-electroencephalogram cross-modal aggregation analysis to obtain a motion state-electroencephalogram cross-modal fine-grained aggregation coding vector. Specifically, Figure 3 FIG. 5 is a flow chart of step S5 in the epilepsy attack warning method according to an embodiment of the present application. Figure 3 As shown, the step S5 includes: S51, performing feature decoupling and feature flattening on the EEG signal feature coding map to obtain a set of EEG signal local feature coding vectors; S52, calculating the kernel features of the set of EEG signal local feature coding vectors; S53, based on the kernel features, performing fine-grained prior fusion on the motion state temporal coding feature vector and the set of EEG signal local feature coding vectors to obtain the motion state-EEG cross-modal fine-grained aggregated coding vector.
[0046] It should be understood that the motion state time-series coding feature vector reflects the changing characteristics of the user's motion state over time, while the EEG signal feature coding diagram reflects the characteristics related to brain electrical activity. Epileptic seizures are often accompanied by abnormal brain electrical activity and changes in body motion state. The two modal data provide information related to epileptic seizures from different angles, and there is an intrinsic connection between brain activity and body movement, especially in epileptic seizure scenarios. Based on this, in order to deeply explore the potential cross-modal associations between motion state and EEG signals, so as to effectively capture the subtle but critical connection between the two modal data, so as to accurately judge the situation of epileptic seizures, this application performs motion state-EEG cross-modal aggregation analysis on the motion state time-series coding feature vector and the EEG signal feature coding diagram to obtain a motion state-EEG cross-modal fine-grained aggregation coding vector. In particular, this analysis method uses the pseudo-clustering center between cross-modal data as a link to deeply fuse data, mine high-level information and feature expressions, and finely integrate and converge at multiple feature levels, thereby providing strong support for epileptic seizure risk judgment.
[0047] Specifically, in the embodiment of the present application, the step S51 includes: expanding each feature matrix along the channel dimension of the EEG signal feature coding map into a feature vector to obtain a set of local feature coding vectors of the EEG signal. The above process can be expressed as: ; in, is the electroencephalogram signal characteristic coding diagram, It is a feature decoupling and feature flattening operation. is the set of local feature encoding vectors of EEG signals, , , , and are the first, second, and third local feature encoding vectors of the electroencephalogram signal. , and The local feature encoding vector of the EEG signal.
[0048] It should be understood that there may be a lot of redundant information in the original EEG signal feature coding map, which not only increases the amount of calculation, but also may cover up the key features that are truly related to epileptic seizures, leading to misjudgment or omission of the model. By performing feature decoupling and feature flattening operations on the original feature map, this redundant information can be effectively removed, allowing the model to focus on those features that are of great value to epileptic seizure judgment, thereby improving the accuracy and reliability of the model.
[0049] Specifically, in the embodiment of the present application, the step S52 includes: calculating the semantic difference value between each EEG signal local feature coding vector and all other EEG signal local feature coding vectors in the set of EEG signal local feature coding vectors to obtain a set of EEG signal semantic difference values; performing normalization processing based on the softmax function on the set of EEG signal semantic difference values to obtain a set of normalized EEG signal semantic difference values; using the set of normalized EEG signal semantic difference values as a set of weights, calculating the weighted sum of the set of EEG signal local feature coding vectors to obtain an EEG signal kernel feature vector as the kernel feature. The above process can be expressed by the formula: ; in, , are respectively the first , EEG signal local feature encoding vector, For Perform kernel feature extraction, represents the one-norm of the eigenvector, represents the number of vectors in the set of local feature encoding vectors of the electroencephalogram signal minus one, yes The corresponding EEG signal semantic difference value, Indicated by natural constant The exponential function with base , is the number of vectors in the set of local feature encoding vectors of the EEG signal, is the EEG signal kernel feature vector.
[0050] It should be understood that EEG signals and motion data are information sources from different modalities. In order to effectively fuse the data of these two modalities and explore the potential connections between them, so as to better determine whether the user is at risk of epileptic seizures, it is necessary to determine a key element that can serve as a bridge between the two, namely, a cross-modal data interaction anchoring bridge. This application helps to identify the core part of the EEG signal that is most semantically and functionally related to the motion data by calculating the kernel features of a set of local feature encoding vectors of the EEG signal. For example, the kernel features of certain EEG signals may have a close correspondence with the initiation, intensity, and duration of body movements during epileptic seizures. By extracting these kernel features, the foundation can be laid for the subsequent establishment of an accurate correlation between the two.
[0051] Specifically, in the embodiment of the present application, the step S53 includes: determining the motion state-EEG signal prior clustering center encoding vector based on the motion state temporal encoding feature vector and the EEG signal kernel feature vector. The process can be expressed as: ; in, is the EEG signal kernel feature vector, is the motion state temporal encoding feature vector, For cascade operation, is the weight transformation matrix, is the bias vector, is the motor state-EEG signal prior cluster center encoding vector; The set of the motion state-EEG signal prior cluster center encoding vector and the EEG signal local feature encoding vector is subjected to cross-domain fine-grained clustering description to obtain the motion state-EEG cross-modal fine-grained aggregate encoding vector. The process can be expressed as: ; ; ; in, is the first in the set of local feature encoding vectors of the EEG signal EEG signal local feature encoding vector, is the motion state-EEG signal prior cluster center encoding vector, is the square of the Euclidean norm of the vector, is the inverse hyperbolic cosine function, for and The motion state between the EEG signals semantic metric, yes The corresponding movement state-EEG signal feature clustering coefficient, is the preset threshold, is the number of vectors in the set of local feature encoding vectors of the EEG signal, is the motor state-EEG cross-modal fine-grained aggregate encoding vector.
[0052] Accordingly, since the EEG signal and motion data represent different aspects of information respectively, the data structures and feature expressions of these two modalities are different, and direct fusion and analysis may lead to information loss or misunderstanding. In this application, by determining the motion state-EEG signal prior clustering center encoding vector, a common reference point can be found based on the key features of these two modalities, so that the correlation between them can be more targeted in subsequent analysis. In other words, the motion state-EEG signal prior clustering center encoding vector serves as a cross-modal data interaction anchoring bridge, providing an orderly guiding structure for cross-modal fine-grained interaction between motion data and EEG signals. It enables the information of the two modalities to interact and fuse within a more reasonable framework, avoiding confusion and mismatching of information, so that the model can more keenly capture subtle changes and abnormal patterns before epileptic seizures.
[0053] It should be understood that both EEG signals and motion state data contain important information related to epileptic seizures, but this information is in different modal spaces and has different feature representations and semantic connotations. In this application, by performing cross-domain fine-grained clustering description on the motion state-EEG signal prior clustering center encoding vector and the set of EEG signal local feature encoding vectors, the information in the set of EEG signal local feature encoding vectors can be deeply fused with the motion state information. This fusion is not a simple splicing, but rather excavating the intrinsic connection and synergy between the two modalities at a fine-grained level, thereby generating a new feature representation that can comprehensively reflect multiple modal information, namely, the motion state-EEG cross-modal fine-grained aggregate encoding vector. The generated vector integrates the associated information in the EEG signal and motion data, which can provide a comprehensive basis for more accurate judgment of epileptic seizures.
[0054] In step S6, based on the motion state-EEG cross-modal fine-grained aggregated coding vector, an identification result is obtained to indicate whether the monitored user has an epileptic seizure risk, and based on the identification result, an epileptic seizure warning prompt is generated. Specifically, Figure 4 FIG. 6 is a flow chart of step S6 in the epilepsy attack warning method according to an embodiment of the present application. Figure 4 As shown, the step S6 includes: S61, inputting the motion state-EEG cross-modal fine-grained aggregate coding vector into the classifier-based epilepsy seizure identifier to obtain the recognition result, and the recognition result is used to indicate whether the user to be monitored is at risk of epilepsy; S62, in response to the recognition result that the user to be monitored is at risk of epilepsy, generating the epilepsy seizure warning prompt.
[0055] In step S61, the motion state-EEG cross-modal fine-grained aggregated coding vector is input into the classifier-based epilepsy seizure identifier to obtain the recognition result, and the recognition result is used to indicate whether the user to be monitored is at risk of epilepsy seizure. Specifically, in an embodiment of the present application, the step S61 includes: using the fully connected layer of the classifier to fully connect the motion state-EEG cross-modal fine-grained aggregated coding vector to obtain a motion state-EEG cross-modal fine-grained aggregated fully connected coding feature vector; inputting the motion state-EEG cross-modal fine-grained aggregated fully connected coding feature vector into the Softmax classification function of the classifier to obtain the probability value of the motion state-EEG cross-modal fine-grained aggregated coding vector belonging to each classification label, and the classification labels include those for indicating that the user to be monitored is at risk of epilepsy seizure and those for indicating that the user to be monitored is not at risk of epilepsy seizure; the classification label corresponding to the largest of the probability values is determined as the recognition result. That is, by using the motion state temporal coding feature vector and the EEG signal feature coding map for classification processing, the classifier can learn the relationship between different feature patterns and the risk of epileptic seizures. By training on a large number of known epileptic seizure and non-seizure samples, the classifier can establish an effective discriminant model to classify the input cross-modal aggregate coding vector, thereby identifying whether the user is at risk of epileptic seizures.
[0056] In particular, when the motion state temporal encoding feature vector and the electroencephalogram signal feature encoding map represent the short-range-long-range bidirectional temporal correlation features of motion data and the encoded signal features of electroencephalogram signals respectively, when performing cross-domain fine-grained aggregation analysis based on modality prior, insufficient correspondence of the prior cross-domain correlation of data of different modalities will cause sparse fine-grained association aggregation of the motion state-electroencephalogram cross-modal fine-grained aggregation encoding vector, thereby reducing the accuracy of the recognition result obtained by the input classifier-based epileptic seizure identifier due to the lack of classification reasoning degree.
[0057] In a preferred example, inputting the movement state-EEG cross-modal fine-grained aggregated encoding vector into a classifier-based epileptic seizure identifier to obtain a recognition result includes: Based on the feature value relationship between the motor state and EEG cross-modal fine-grained aggregated encoding vector Distance and Distance to obtain motion state-EEG cross-modal fine-grained aggregation-distance matrix and motor state-EEG cross-modality fine-grained aggregation of two distance matrices ; The weighted sum of the motion state-EEG cross-modal fine-grained aggregation distance matrix 1 and the motion state-EEG cross-modal fine-grained aggregation distance matrix 2 is calculated to obtain the motion state-EEG cross-modal fine-grained aggregation joint distance matrix. The process can be expressed as: ; in, represents the motor state-EEG cross-modal fine-grained aggregation distance matrix, represents the motor state-EEG cross-modal fine-grained aggregation distance matrix, It means point multiplication by position. Indicates adding by position point. and represents the weighted hyperparameter, Representing the motor state-EEG cross-modality fine-grained aggregated joint distance matrix; Determine the eigenvalues of the joint distance matrix of the motor state-EEG cross-modal fine-grained aggregation , and compose the motor state-EEG cross-modal fine-grained aggregated joint distance eigenvector ; The motion state-EEG cross-modal fine-grained aggregation encoding vector as a row vector is matrix-multiplied with the motion state-EEG cross-modal fine-grained aggregation-distance matrix to obtain the motion state-EEG cross-modal fine-grained aggregation-distance query vector. The process can be expressed as: ; in, represents the motor state-EEG cross-modal fine-grained aggregation distance matrix, represents matrix multiplication, represents the motor state-EEG cross-modal fine-grained aggregated encoding vector, and is a row vector, Representing the motion state-EEG cross-modal fine-grained aggregation-distance query vector; The motion state-EEG cross-modal fine-grained aggregation two-distance matrix is matrix-multiplied with the auto-correlation matrix of the motion state-EEG cross-modal fine-grained aggregation encoding vector to obtain the motion state-EEG cross-modal fine-grained aggregation two-distance correlation matrix. The process can be expressed as: ; in, represents the motor state-EEG cross-modal fine-grained aggregation distance matrix, represents matrix multiplication, represents the motor state-EEG cross-modal fine-grained aggregated encoding vector, and is a row vector, express The transposed vector of Representing the motor state-EEG cross-modal fine-grained aggregated two-distance association matrix; After matrix multiplication of the motion state-EEG cross-modal fine-grained aggregation distance query vector and the motion state-EEG cross-modal fine-grained aggregation distance association matrix, it is further dot-multiplied with the motion state-EEG cross-modal fine-grained aggregation joint distance eigenvector to obtain the optimized motion state-EEG cross-modal fine-grained aggregation encoding vector. This process can be expressed as: ; in, represents the motion state-EEG cross-modal fine-grained aggregation-distance query vector, represents the motor state-EEG cross-modal fine-grained aggregation distance association matrix, It means point multiplication by position. represents matrix multiplication, represents the motor state-EEG cross-modal fine-grained aggregated joint distance eigenvector, Representing the optimized motor state-EEG cross-modal fine-grained aggregated encoding vector; The optimized movement state-EEG cross-modal fine-grained aggregated encoding vector is input into the classifier-based epileptic seizure identifier to obtain the identification result.
[0058] That is, the first distance matrix and the second distance matrix of the movement state-EEG cross-modal fine-grained aggregate coding vector are used as the fine-grained metric association cluster representation of the movement state-EEG cross-modal fine-grained aggregate coding vector, and the dynamic programming of the relationship between association clusters of different association clusters is performed on the movement state-EEG cross-modal fine-grained aggregate coding vector and the self-association representation of the movement state-EEG cross-modal fine-grained aggregate coding vector respectively to simulate the sparse activation based on neuron clusters of the association system, and the fine-grained predictable sparsity of the movement state-EEG cross-modal fine-grained aggregate coding vector is coordinated with the intrinsic representation of the metric association cluster of the first distance matrix and the second distance matrix of the movement state-EEG cross-modal fine-grained aggregate coding vector, so as to avoid the lack of classification reasoning degree affected by insufficient association caused by sparsity, and improve the accuracy of the recognition result obtained by inputting the movement state-EEG cross-modal fine-grained aggregate coding vector into the classifier-based epileptic seizure identifier.
[0059] In step S62, in response to the recognition result that the user to be monitored has an epileptic seizure risk, the epileptic seizure warning prompt is generated. That is, an epileptic seizure may cause the patient to suddenly lose consciousness, fall, or be injured. Generating a warning prompt can allow the patient or the people around him to know the risk in advance, and help the patient to be in a relatively safe environment before the attack, such as guiding the patient away from dangerous areas such as high places, fire sources, and waters, reducing the possibility of accidental injuries, and maximizing the personal safety of the patient. In detail, when the epileptic seizure identifier determines that there is an epileptic seizure risk, the system starts the warning prompt according to a pre-set program. For example, when the probability value of the risk of an epileptic seizure exceeds a specific threshold (such as 0.8), multiple warning forms are immediately triggered to ensure the timeliness and accuracy of the prompt. The warning prompt form includes but is not limited to a sound alarm form such as a sharp beep and a beep of a specific frequency; for patients wearing wearable devices, the device sends a strong vibration reminder, and the indicator light on the device flashes quickly; the warning information is pushed to the patient or guardian's mobile phone application, displaying "Epileptic seizure warning, please pay attention to the patient's status" and related suggestions.
[0060] In summary, the epilepsy attack warning method based on the embodiment of the present application is explained, which uses data processing technology based on deep learning to perform noise reduction and feature extraction on the EEG signal of the monitored user in a predetermined time period, and extracts the running state feature of the time queue of the motion data, so as to intelligently identify whether the user to be monitored is at risk of epilepsy attack based on the cross-modal aggregation representation between the motion state temporal coding feature and the EEG signal feature, and generate corresponding epilepsy attack warning prompts. In this way, by comprehensively capturing the subtle patterns in the data of different users and fully considering the relationship between the features, a more accurate epilepsy attack warning can be achieved.
[0061] Figure 5 FIG. 1 is a system block diagram of an epilepsy attack warning system according to an embodiment of the present application. Figure 5As shown, according to the embodiment of the present application, the epilepsy attack warning system 100 includes: a user monitoring data acquisition module 110, which is used to obtain the time queue of the EEG signal and motion data of the user to be monitored in a predetermined time period; an EEG signal noise reduction module 120, which is used to perform noise reduction processing on the EEG signal to obtain a noise-reduced EEG signal; an EEG signal feature extraction module 130, which is used to extract EEG signal features from the noise-reduced EEG signal to obtain an EEG signal feature encoding map; an operation state feature extraction module 140, which is used to perform operation state feature processing on the time queue of the motion data Extraction to obtain a motion state time-series coding feature vector; an operation state EEG signal aggregation analysis module 150, used to perform motion state-EEG signal cross-modal aggregation analysis on the motion state time-series coding feature vector and the EEG signal feature coding map to obtain a motion state-EEG cross-modal fine-grained aggregation coding vector; an epileptic seizure warning prompt generation module 160, used to obtain an identification result indicating whether the user to be monitored has an epileptic seizure risk based on the motion state-EEG cross-modal fine-grained aggregation coding vector, and generate an epileptic seizure warning prompt based on the identification result.
[0062] Here, those skilled in the art will appreciate that the specific functions and operations of the various units and modules in the epilepsy attack warning system 100 have been described in detail above. Figures 1 to 4 The description of the epileptic seizure warning method has been described in detail, and therefore, its repeated description will be omitted.
[0063] In summary, the epilepsy attack warning system 100 based on the embodiment of the present application is explained, which uses data processing technology based on deep learning to perform noise reduction and feature extraction on the EEG signal of the monitored user in a predetermined time period, and extracts the running state feature of the time queue of the motion data, so as to intelligently identify whether the user to be monitored has an epileptic seizure risk based on the cross-modal aggregation representation between the motion state temporal coding feature and the EEG signal feature, and generate corresponding epileptic seizure warning prompts. In this way, by comprehensively capturing the subtle patterns in the data of different users and fully considering the relationship between the features, a more accurate epilepsy attack warning can be achieved.
Claims
1. An epileptic seizure early warning method, characterized in that: include: Obtaining a time queue of electroencephalogram signals and motion data of the user to be monitored in a predetermined time period; Performing noise reduction processing on the electroencephalogram signal to obtain a noise-reduced electroencephalogram signal; Extracting electroencephalogram signal features from the denoised electroencephalogram signal to obtain an electroencephalogram signal feature encoding map; Extracting running state features from the time queue of the motion data to obtain a motion state time series encoding feature vector; The motion state time series coding feature vector and the electroencephalogram signal feature coding map are subjected to motion state-EEG cross-modal aggregation analysis to obtain a motion state-EEG cross-modal fine-grained aggregation coding vector, including: performing feature decoupling and feature flattening on the electroencephalogram signal feature coding map to obtain a set of electroencephalogram signal local feature coding vectors; calculating the kernel features of the set of electroencephalogram signal local feature coding vectors; based on the kernel features, performing fine-grained prior fusion on the motion state time series coding feature vector and the set of electroencephalogram signal local feature coding vectors to obtain the motion state-EEG cross-modal fine-grained aggregation coding vector; Based on the movement state-EEG cross-modal fine-grained aggregate coding vector, an identification result is obtained to indicate whether the user to be monitored has an epileptic seizure risk, and based on the identification result, an epileptic seizure warning prompt is generated.
2. The epileptic seizure early warning method according to claim 1, characterized in that: Extracting electroencephalogram signal features from the denoised electroencephalogram signal to obtain an electroencephalogram signal feature coding map includes: inputting the denoised electroencephalogram signal into a signal extractor based on a fully convolutional neural network to obtain the electroencephalogram signal feature coding map.
3. The epilepsy attack early warning method according to claim 2, characterized in that: The operation state feature extraction is performed on the time queue of the motion data to obtain the motion state time series coding feature vector, including: inputting the time queue of the motion data into the operation state feature extractor based on the forward LSTM model to obtain the motion state time series coding feature vector.
4. The epilepsy attack early warning method according to claim 3, characterized in that: Feature decoupling and feature flattening are performed on the electroencephalogram signal feature coding map to obtain a set of local feature coding vectors of the electroencephalogram signal, including: each feature matrix of the electroencephalogram signal feature coding map along the channel dimension is expanded into a feature vector to obtain a set of local feature coding vectors of the electroencephalogram signal.
5. The epileptic seizure early warning method according to claim 4, characterized in that: Calculating the kernel features of the set of local feature encoding vectors of the electroencephalogram signal includes: Calculating the semantic difference value between each electroencephalogram signal local feature coding vector and all other electroencephalogram signal local feature coding vectors in the set of electroencephalogram signal local feature coding vectors to obtain a set of electroencephalogram signal semantic difference values; Performing a normalization process based on a softmax function on the set of semantic difference values of the electroencephalogram signal to obtain a set of normalized semantic difference values of the electroencephalogram signal; The set of normalized electroencephalogram signal semantic difference values is used as a set of weights, and the weighted sum of the set of electroencephalogram signal local feature encoding vectors is calculated to obtain an electroencephalogram signal kernel feature vector as the kernel feature.
6. The epilepsy attack early warning method according to claim 5, characterized in that: Based on the kernel feature, a fine-grained prior fusion is performed on the set of the motion state temporal coding feature vector and the electroencephalogram signal local feature coding vector to obtain the motion state-electroencephalogram cross-modal fine-grained aggregated coding vector, including: Determining a motion state-EEG signal priori cluster center encoding vector based on the motion state temporal encoding feature vector and the EEG signal kernel feature vector; A cross-domain fine-grained clustering description is performed on the set of the motion state-EEG signal prior clustering center encoding vector and the EEG signal local feature encoding vector to obtain the motion state-EEG cross-modal fine-grained aggregation encoding vector.
7. The epileptic seizure early warning method according to claim 6, characterized in that: Based on the motion state-EEG cross-modal fine-grained aggregated coding vector, a recognition result for indicating whether the user to be monitored has an epileptic seizure risk is obtained, and based on the recognition result, an epileptic seizure warning prompt is generated, including: Inputting the movement state-EEG cross-modal fine-grained aggregated encoding vector into a classifier-based epilepsy seizure identifier to obtain the recognition result, wherein the recognition result is used to indicate whether the user to be monitored has an epileptic seizure risk; In response to the identification result that the user to be monitored is at risk of epileptic seizure, the epileptic seizure warning prompt is generated.
8. The epilepsy attack early warning method according to claim 7, characterized in that: Inputting the motion state-EEG cross-modal fine-grained aggregated encoding vector into a classifier-based epilepsy seizure identifier to obtain the recognition result, which is used to indicate whether the user to be monitored has an epileptic seizure risk, including: Using the fully connected layer of the classifier, the motion state-EEG cross-modal fine-grained aggregated coding vector is fully connected to obtain a motion state-EEG cross-modal fine-grained aggregated fully connected coding feature vector; Inputting the motion state-EEG cross-modal fine-grained aggregated fully connected encoding feature vector into the Softmax classification function of the classifier to obtain probability values of the motion state-EEG cross-modal fine-grained aggregated encoding vector belonging to each classification label, wherein the classification label includes a value for indicating that the user to be monitored has an epileptic seizure risk and a value for indicating that the user to be monitored does not have an epileptic seizure risk; The classification label corresponding to the largest probability value among the probability values is determined as the recognition result.
9. An epileptic seizure warning system, characterized in that: include: A user monitoring data acquisition module, used to obtain a time queue of the EEG signal and motion data of the user to be monitored in a predetermined time period; An EEG signal noise reduction module, used for performing noise reduction processing on the EEG signal to obtain a noise-reduced EEG signal; An EEG signal feature extraction module, used to extract EEG signal features from the denoised EEG signal to obtain an EEG signal feature coding map; A running state feature extraction module, used for extracting running state features from the time queue of the motion data to obtain a motion state time series coding feature vector; The running state EEG signal aggregation analysis module is used to perform motion state-EEG signal cross-modal aggregation analysis on the motion state time series coding feature vector and the EEG signal feature coding map to obtain a motion state-EEG cross-modal fine-grained aggregation coding vector, wherein the running state EEG signal aggregation analysis module includes: an EEG signal feature decoupling and flattening unit, used to perform feature decoupling and feature flattening on the EEG signal feature coding map to obtain a set of EEG signal local feature coding vectors; an EEG signal kernel feature calculation unit, used to calculate the kernel feature of the set of EEG signal local feature coding vectors; a cross-modal fine-grained coding fusion unit, used to perform fine-grained prior fusion on the motion state time series coding feature vector and the set of EEG signal local feature coding vectors based on the kernel feature to obtain the motion state-EEG cross-modal fine-grained aggregation coding vector; An epileptic seizure warning prompt generation module is used to obtain an identification result indicating whether the monitored user has an epileptic seizure risk based on the movement state-EEG cross-modal fine-grained aggregate coding vector, and generate an epileptic seizure warning prompt based on the identification result.
10. The epilepsy attack warning system according to claim 9, characterized in that: The EEG signal denoising module is used to: input the denoised EEG signal into a signal extractor based on a fully convolutional neural network to obtain the EEG signal feature coding map.
Citation Information
Patent Citations
Epileptic seizure warning method, system, electronic device and storage medium
CN118383730B
Device for dynamically prewarning epileptic seizure
CN106491126A
Intelligent auxiliary analysis method for children exercise epilepsy based on synchronous video and electroencephalogram
CN114093501A
Epilepsy type detection method combining eye movement and electroencephalogram
CN116019461A
Epileptic seizure early warning method and system, electronic equipment and storage medium
CN118383730A
Cited By
Recommendation method for AIDS prevention and control knowledge propaganda and education
CN120086448A
Real-time epilepsy behavior detection and analysis method and system
CN121015145A
A real-time seizure behavior detection and analysis method and system
CN121015145B