Quantum neural network-based seizure prediction method
Patent Information
- Application Number
- CN202611041711.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-07-14
- Publication Date
- 2026-10-09
AI Technical Summary
(1)模型复杂性与计算成本高:为了达到较高的预测精度,模型往往需要非常深和复杂,导致训练和推理的计算成本高昂,难以在可穿戴设备等资源受限的终端上实现实时预测
[0015]本发明的有益效果:利用量子并行性,VQC能用远少于经典模型的参数和计算步骤完成复杂计算,显著降低模型复杂性和功耗,为未来在便携设备上部署奠定基础。
Smart Images

Figure CN122874012A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the fields of medical information and quantum computing technology, specifically to a method for predicting epileptic seizures based on quantum neural networks. Background Technology
[0002] Epilepsy is a common and serious central nervous system disorder, affecting tens of millions of people worldwide. Approximately one-third of these patients suffer from drug-resistant epilepsy, constantly facing the threat of sudden, uncontrollable seizures. This not only increases the risk of physical injury and accidents but also causes immense psychological stress, social stigma, and a decline in quality of life. Therefore, "predictive intervention"—providing early warning minutes to hours before a seizure—is crucial, enabling patients to take safety precautions or receive preventative treatment.
[0003] Currently, research on epilepsy seizure prediction based on electroencephalography (EEG) mainly relies on classic artificial intelligence (AI) and deep learning (DL) models. While these methods have made some progress, their development faces significant bottlenecks. For example, achieving high accuracy requires models that are exceptionally large and complex, leading to enormous computational energy consumption during training and inference. This makes them difficult to integrate into low-power, wearable medical devices, limiting their clinical adoption and real-time application. Furthermore, the high cost of acquiring medical data, the need for annotation by experienced experts, and the existence of individual patient differences result in insufficient model generalization ability, making it difficult to build a general and robust prediction system.
[0004] Existing technologies are typically based on classical deep learning methods for predicting epileptic seizures. While classical deep learning methods have made some progress, they generally face the following limitations: (1) High model complexity and computational cost: In order to achieve high prediction accuracy, the model often needs to be very deep and complex, resulting in high computational costs for training and inference, making it difficult to achieve real-time prediction on resource-constrained terminals such as wearable devices.
[0005] (2) Limitations of processing high-dimensional, nonlinear EEG signals: When processing high-dimensional, strongly nonlinear signals with complex noise backgrounds, such as EEG signals, the representation ability and optimization efficiency of classical neural networks may reach a bottleneck, which limits the further improvement of prediction sensitivity and specificity.
[0006] (3) Strong dependence on training data: The performance of the model depends heavily on large-scale, high-quality labeled data, but the cost of acquiring and labeling medical data is extremely high and difficult to obtain, which limits the generalization ability of the model. Summary of the Invention
[0007] The purpose of this invention is to provide a method for predicting epileptic seizures based on quantum neural networks, so as to solve the above-mentioned technical problems.
[0008] The objective of this invention can be achieved through the following technical solutions: A method for predicting epileptic seizures based on quantum neural networks includes the following steps: Step S1: Obtain the raw multi-channel EEG time sequence signal and preprocess the raw EEG signal; Step S2: Perform feature extraction and dimensionality compression on the preprocessed high-dimensional EEG data output from Step S1; Step S3: By combining base encoding with amplitude encoding, the classical feature vector compressed in step S2 is mapped to the qubits of the quantum processor to construct the initial quantum state carrying EEG feature information; Step S4: Input the initial quantum state into a variable quantum circuit VQC composed of adjustable parameter quantum logic gates and fixed CNOT entanglement gates. Perform evolution operations on the initial quantum state through adjustable parameter quantum gates and entanglement gates, and output the evolved target quantum state; wherein the gate parameter θ of the variable quantum circuit is a trainable weight. Step S5: Perform quantum measurement on the target quantum state output in step S4, collapse the quantum information into classical values, and obtain the probability output value of the sample belonging to the epilepsy pre-seizure category.
[0009] As a further aspect of the present invention, it also includes: Step S6: Compare the quantum measurement output probability with the sample's true attack label and calculate the loss function; use the Adam classical optimization algorithm to solve the gradient of the variable quantum circuit parameter θ in reverse and update the parameter θ to form a hybrid training loop and iteratively complete the model training; Step S7: Collect new EEG signals from the patient to be tested, and execute the complete processing flow from steps S1 to S5 in sequence. The model outputs the discrimination results, distinguishing the sample as either the epileptic pre-seizure period or the non-seizure interictal period, and completing the epileptic seizure early warning prediction.
[0010] As a further aspect of the present invention: the preprocessing in step S1 specifically includes: Bandpass filtering is performed to remove high-frequency noise, DC drift, power frequency interference and electromyography artifacts, and signal normalization is performed to eliminate signal amplitude scale differences, resulting in regular and clean preprocessed EEG data; Furthermore, the bandpass filter is adapted to the EEG signal frequency band, filtering out environmental power frequency noise, electromyographic artifacts generated by muscle movement, and DC drift noise caused by electrode contact.
[0011] As a further aspect of the present invention: step S2 specifically includes: Principal component analysis (PCA) is used to extract features and compress the dimensionality of the preprocessed high-dimensional EEG data output from step S1, compressing the data dimensionality to match the number of qubits in the subsequent quantum encoding.
[0012] As a further aspect of the present invention: the quantum encoding in step S3 can simultaneously characterize 2 using an n-qubit system. n The exponential information-carrying characteristics of each state enable efficient quantum state mapping of high-dimensional EEG features.
[0013] As a further aspect of the present invention: the variable quantum circuit described in step S4 utilizes the physical properties of quantum superposition and quantum entanglement to fit the complex correlation characteristics of the EE signal, which is characterized by high-dimensionality, strong nonlinearity, and multi-channel coupling.
[0014] As a further aspect of the present invention: in the hybrid training loop described in step S6, the quantum processor is only responsible for the quantum state evolution calculation of the variable quantum circuit, while all loss calculation, gradient solving, parameter update and optimization operations are completed by the classical computer, thus adapting to the classical quantum hardware architecture.
[0015] The beneficial effects of this invention are: by utilizing quantum parallelism, VQC can complete complex calculations with far fewer parameters and computational steps than classical models, significantly reducing model complexity and power consumption, and laying the foundation for future deployment on portable devices.
[0016] The quantum entanglement and superposition properties enable the model to capture and characterize the inherent high-dimensional non-classical correlations in EEG signals more naturally, exhibiting better characterization capabilities. This breaks through the performance bottleneck of classical models and is expected to achieve higher prediction accuracy and earlier prediction lead.
[0017] QNNs theoretically have the potential to learn essential features from smaller datasets, reducing the model's dependence on large-scale labeled data, improving data efficiency, and making them more suitable for small-data scenarios common in clinical settings.
[0018] This invention combines forward-thinking and practicality, employing a hybrid architecture that fully leverages the maturity of current classical computers and the specialization of quantum processors, making the solution feasible and practical in the noisy medium-sized quantum era. Attached Figure Description
[0019] The invention will now be further described with reference to the accompanying drawings.
[0020] Figure 1 This is a flowchart illustrating the epileptic seizure prediction method based on quantum neural networks of the present invention. Detailed Implementation
[0021] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0022] In recent years, quantum computing, especially in the era of noisy medium-scale quantum (NISQ), has demonstrated its potential to surpass classical computers in solving specific problems. Quantum neural networks (QNNs) and variational quantum algorithms (VQA) combine the unique properties of quantum computing—such as superposition, entanglement, and interference—with machine learning frameworks. This emerging technology provides entirely new ideas and tools for overcoming the bottlenecks of classical AI mentioned above.
[0023] The purpose of this invention is to provide a method for predicting epileptic seizures that can effectively reduce computational costs, improve the ability to process complex signals, and reduce dependence on data volume. By introducing a hybrid classical-quantum computing paradigm, an end-to-end quantum neural network (QNN) model is constructed. Utilizing the properties of quantum state superposition and entanglement, more efficient and powerful feature extraction and classification of high-dimensional EEG signals can be achieved with fewer computational resources and parameters.
[0024] like Figure 1 As shown, a method for predicting epileptic seizures based on quantum neural networks is provided, including the following steps: Data preprocessing: Input raw, multi-channel EEG timing signals. This module receives the raw EEG signals and performs standard preprocessing operations, including but not limited to: bandpass filtering to remove high-frequency noise and DC drift, and signal normalization to eliminate amplitude scale differences. This step is performed on a computer to prepare clean, well-ordered data for subsequent quantum processing.
[0025] Classic feature extraction and compression: Given the limited number of qubits in current quantum processors, this step serves as an efficient interface. This invention employs a lightweight classical method—Principal Component Analysis (PCA)—to perform preliminary feature extraction and dimensionality reduction on the preprocessed high-dimensional EEG data. The goal is to compress the data to a dimension matching the number of qubits in subsequent quantum encoding modules. This significantly improves feasibility on current noisy, medium-scale quantum (NISQ) devices.
[0026] Quantum encoding: The classical eigenvectors output in step two are mapped onto the qubits of the quantum processor using specific encoding methods—basis encoding and amplitude encoding—forming an initial quantum state. At this point, the EEG data has been transformed into a form that the quantum computer can directly manipulate. This step utilizes the exponential information-carrying capacity of quantum states; an n-qubit system can simultaneously represent 2^n qubits. n This state forms the basis for the physical processing of high-dimensional data.
[0027] Variable quantum circuits: Variable quantum circuits (VQCs) consist of a series of parameterized quantum logic gates and fixed entanglement gates (CNOT gates), functioning analogously to neural network layers in classical deep learning. They operate on an initial quantum state |x>, and through the manipulation of the quantum gates, output a complex quantum state. The gate parameters (θ) in this process are adjustable, similar to the weights in a neural network. The existence of quantum entanglement allows VQCs to construct complex functions that are difficult for classical networks to express efficiently with an exponentially smaller number of parameters, directly addressing the strong nonlinearity and complex correlations in EEG signals. This solves the problems of high model complexity and computational cost, as well as the limitations in processing high-dimensional, nonlinear EEG signals.
[0028] Quantum measurement: The final quantum state of the VQC output is measured, collapsing the quantum information back into classical information. The measurement result is then converted into one or more classical numerical outputs. This output can represent the probability of belonging to the "precursor" category.
[0029] Classic optimizer: The output obtained from quantum measurement is compared with the true label (whether it is a pre-emptive strike) to calculate the loss function. Then, using the classical optimization algorithm—Adam's algorithm—backpropagation is performed based on the loss value to calculate the gradient of the VQC parameters (θ) and update these parameters. This forms a hybrid training loop: the classical computer is responsible for guidance and optimization, while the quantum computer is responsible for performing the core computational tasks. QNNs may have a faster convergence speed when searching for optimal solutions to complex functions, thereby indirectly reducing the need for massive amounts of training data and addressing the problem of strong dependence on training data.
[0030] Episode risk prediction: For the trained model, the new EEG data is processed through the above process, and a prediction result is finally output, namely "pre-seizure period" or "non-seizure period (interval period)", thus completing the prediction of epileptic seizures.
[0031] This invention utilizes a traditional (i.e., classical computer) deep neural network model to analyze and predict electroencephalogram (EEG) signals from patients. Through data preprocessing, the acquired raw multi-channel EEG signals are filtered (e.g., to remove power line interference, electromyography artifacts, etc.) and normalized to improve signal quality. Features are extracted from the time-frequency domain to form feature vectors. The preprocessed EEG time-series signal or time-frequency plot is directly input into the deep learning model, which automatically learns deep, highly discriminative features. This includes: a convolutional neural network (CNN) to extract spatial and spectral features from the two-dimensional (time-channel) representation or time-frequency plot of the EEG signal; and a recurrent neural network (RNN) to capture the long-term dependencies and dynamic change patterns of the EEG signal in the time dimension. The extracted features are input into a classifier to classify the input EEG segments into "pre-seizure period" or "non-seizure period (interictal period)," thereby achieving prediction of epileptic seizures.
[0032] The foregoing has provided a detailed description of one embodiment of the present invention, but this description is merely a preferred embodiment and should not be construed as limiting the scope of the invention. All equivalent variations and modifications made within the scope of the present invention should still fall within the scope of the present invention.
Claims
1. A method for predicting epileptic seizures based on quantum neural networks, characterized in that, Includes the following steps: Step S1: Obtain the raw multi-channel EEG time sequence signal and preprocess the raw EEG signal; Step S2: Perform feature extraction and dimensionality compression on the preprocessed high-dimensional EEG data output from Step S1; Step S3: By combining base encoding with amplitude encoding, the classical feature vector compressed in step S2 is mapped to the qubits of the quantum processor to construct the initial quantum state carrying EEG feature information; Step S4: Input the initial quantum state into a variable quantum circuit VQC composed of adjustable parameter quantum logic gates and fixed CNOT entanglement gates. Perform evolution operations on the initial quantum state through adjustable parameter quantum gates and entanglement gates, and output the evolved target quantum state; wherein the gate parameter θ of the variable quantum circuit is a trainable weight. Step S5: Perform quantum measurement on the target quantum state output in step S4, collapse the quantum information into classical values, and obtain the probability output value of the sample belonging to the epilepsy pre-seizure category.
2. The method for predicting epileptic seizures based on quantum neural networks according to claim 1, characterized in that, Also includes: Step S6: Compare the quantum measurement output probability with the sample's true attack label and calculate the loss function; use the Adam classical optimization algorithm to solve the gradient of the variable quantum circuit parameter θ in reverse and update the parameter θ to form a hybrid training loop and iteratively complete the model training; Step S7: Collect new EEG signals from the patient to be tested, and execute the complete processing flow from steps S1 to S5 in sequence. The model outputs the discrimination results, distinguishing the sample as either the epileptic pre-seizure period or the non-seizure interictal period, and completing the epileptic seizure early warning prediction.
3. The method for predicting epileptic seizures based on quantum neural networks according to claim 1, characterized in that, The preprocessing in step S1 specifically includes: Bandpass filtering is performed to remove high-frequency noise, DC drift, power frequency interference and electromyography artifacts, and signal normalization is performed to eliminate signal amplitude scale differences, resulting in regular and clean preprocessed EEG data; Furthermore, the bandpass filter is adapted to the EEG signal frequency band, filtering out environmental power frequency noise, electromyographic artifacts generated by muscle movement, and DC drift noise caused by electrode contact.
4. The method for predicting epileptic seizures based on quantum neural networks according to claim 1, characterized in that, Step S2 specifically includes: Principal component analysis (PCA) is used to extract features and compress the dimensionality of the preprocessed high-dimensional EEG data output from step S1, compressing the data dimensionality to match the number of qubits in the subsequent quantum encoding.
5. The method for predicting epileptic seizures based on quantum neural networks according to claim 1, characterized in that, In step S3, the quantum encoding can simultaneously characterize 2 using an n-qubit system. n The exponential information-carrying characteristics of each state enable efficient quantum state mapping of high-dimensional EEG features.
6. The method for predicting epileptic seizures based on quantum neural networks according to claim 1, characterized in that, The variable quantum circuit described in step S4 uses the physical properties of quantum superposition and quantum entanglement to fit the complex correlation characteristics of the EE signal, which is characterized by high dimension, strong nonlinearity, and multi-channel coupling.
7. The method for predicting epileptic seizures based on quantum neural networks according to claim 2, characterized in that, In the hybrid training loop described in step S6, the quantum processor is only responsible for calculating the quantum state evolution of the variable quantum circuit, while all loss calculations, gradient solving, and parameter update optimization operations are performed by the classical computer, adapting to the classical quantum hardware architecture.