Personalized nerve population model optimization method and system for epilepsy regulation

Through the personalized neural group model optimization method and strong tracking adaptive UKF algorithm, combined with the closed-loop EEG regulation system, the problems of inaccurate regulation, poor model robustness and lack of closed-loop feedback control in the existing technology are solved, and the personalized regulation effect of epilepsy with high accuracy and strong robustness is achieved.

CN119607424AInactive Publication Date: 2025-03-14YANSHAN UNIV
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202411777152.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-05
Publication Date
2025-03-14
Estimated Expiration
Not applicable · inactive patent

AI Technical Summary

Technical Problem

The existing epilepsy regulation technology is inaccurate, the model is poorly robust, and the lack of closed-loop feedback control, resulting in large differences in regulatory effects, low model prediction accuracy and stability, and lack of real-time adjustments during the treatment process.

Method used

The personalized neural group model optimization method is adopted, combined with strong tracking adaptive UKF and closed-loop EEG regulation system, through real-time acquisition of EEG signals, preprocessing and analysis, the model parameter range is determined, the neural group model status and parameters are estimated in real time, the optimal controller is designed, and a personalized model is generated to realize the personalized regulation of epilepsy.

Benefits of technology

The accuracy and effect of epilepsy regulation are improved, the robustness and prediction accuracy of the model are enhanced, closed-loop feedback control is realized, model parameters are dynamically adjusted, and the electroencephalogram characteristics of individual patients are adapted to the dynamic characteristics of the brain, reducing side effects and patient discomfort.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119607424A_ABST
    Figure CN119607424A_ABST
Patent Text Reader

Abstract

The invention discloses a personalized neural population model optimization method and system for epilepsy regulation and control, and belongs to the field of biomedical engineering signal processing.The method comprises the following steps that frequency domain analysis is conducted on electroencephalogram signals to obtain frequency domain characteristics; a model parameter range is determined according to the frequency domain characteristics, the state and parameters of a neural population model are estimated in real time by using a strong tracking adaptive UKF, a personalized neural population model is constructed according to the parameters of the neural population model, and electroencephalogram dynamics of a patient are simulated; according to the personalized neural population model, a reasonable control scheme is set, and according to the designed control scheme, magnetic pulses are emitted to an experimental subject to perform epilepsy modulation, so that epilepsy suppression is realized. Model parameters can be dynamically adjusted according to electroencephalogram signals collected in real time, a personalized model is generated based on individualized features of a patient, the model can generate epileptic seizure prediction data, the collection work in the epileptic seizure process is greatly reduced, and finally epilepsy is regulated and controlled through a designed control scheme.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of biomedical engineering signal processing, and in particular to a personalized neural group model optimization method and system for epilepsy regulation. Background Art

[0002] In the field of neuroscience and medical health, EEG (EEG / SEEG) analysis and neuromodulation technology have become important means of regulating the nervous system such as epilepsy. Among them, transcranial magnetic stimulation, transcranial electrical stimulation, and modified deep brain stimulation have gradually replaced drugs and invasive surgery due to their advantages such as small side effects and accurate target control, and have become the focus of scholars in the field of neuroscience.

[0003] The existing technologies for nervous system regulation have the following problems:

[0004] 1. Imprecise control technology: Traditional epilepsy control methods are usually based on group statistical models for data analysis, lacking the ability to accurately identify and dynamically adjust the specific pathological characteristics of individual patients. This one-size-fits-all analysis model is often difficult to adapt to the unique EEG dynamic characteristics of each patient, resulting in large differences in control effects.

[0005] 2. Poor model robustness: Existing signal processing and analysis methods usually use simple linear models. These models show obvious limitations when faced with nonlinear, complex and changeable EEG signals. They are easily affected by noise and external environment, which reduces the prediction accuracy and stability of the model.

[0006] 3. Lack of closed-loop feedback control: Existing neuromodulation technologies, such as electrical stimulation and magnetic stimulation, are usually open-loop operations, that is, the stimulation parameters are fixed during the treatment process and will not be adjusted according to real-time EEG feedback. This fixed parameter approach is not targeted in terms of treatment effect and may increase side effects and patient discomfort. Summary of the invention

[0007] The technical problem to be solved by the present invention is to provide a personalized neural group model optimization method and system for epilepsy regulation, which combines a closed-loop EEG regulation system with a strong tracking adaptive UKF (Unscented Kalman Filter) and a personalized neural quality model, aiming to solve the problems existing in the prior art, such as inaccurate regulation technology, poor model robustness and lack of closed-loop feedback control.

[0008] In order to solve the above technical problems, the technical solution adopted by the present invention is:

[0009] A personalized neural group model optimization method for epilepsy regulation comprises the following steps:

[0010] S1, collect EEG signals of experimental subjects;

[0011] S2, preprocessing the EEG signal to obtain a preprocessed EEG signal;

[0012] S3, analyzing and processing the preprocessed EEG signal to obtain the time domain and frequency domain characteristics of the patient during the epileptic seizure;

[0013] S4, determine the model parameter range according to the time domain and frequency domain characteristics, and use the strong tracking adaptive UKF algorithm to estimate the state and parameters of the neural group model in real time;

[0014] S5. Designing a controller according to the personalized neural group model so that the error between the output of the personalized model and the expected output is minimized, thereby obtaining the control input required for regulating epilepsy;

[0015] S6. According to the control input, a magnetic pulse is emitted to the experimental subject to perform epilepsy regulation to achieve epilepsy suppression.

[0016] A further improvement of the technical solution of the present invention is that in S2, the EEG signal is downsampled, 60 Hz notch denoised and 1-80 Hz filtered to obtain a preprocessed EEG signal.

[0017] A further improvement of the technical solution of the present invention is that: S3 specifically includes the following steps:

[0018] S31, performing time domain analysis on the preprocessed EEG signal to obtain the EEG signal during the epileptic attack;

[0019] S32, calculating the power spectrum density of the EEG signal during the epileptic attack, and obtaining the frequency characteristics of different stages during the epileptic attack.

[0020] A further improvement of the technical solution of the present invention is that: S4 specifically includes the following steps:

[0021] S41, setting the neural group model parameter range according to the frequency characteristics, and using the strong tracking adaptive UKF algorithm to estimate the state and parameters of the neural group model in real time;

[0022] The nonlinear discrete-time dynamical system of a neural population model with unknown parameters and outputs perturbed by unknown measurement noise is described as:

[0023]

[0024] Where k represents the sampling point sequence number, f(·) represents the dynamics function of the neural group model, g(·) represents the measurement function, represents the augmented vector of the model state and the parameters to be identified, represents the known endogenous input vector of the model, represents the measured output vector of the model, Represents the system noise vector of the model, which has a mean of 0 and a variance of Q k A Gaussian white noise sequence, Represents the measurement noise vector of the model, which has a mean of 0 and a variance of R k Gaussian white noise sequence, n x 、n q 、n y 、n p are real numbers, representing the dimensions of the system vector, identification parameters, model output, and model internal input. In the task of identifying EEG signals, Q k remains constant and close to zero, while R k often unknown and time-varying;

[0025] Assuming that the measurement noise follows a Gaussian distribution with zero mean and unknown variance, the posterior state estimate vector at the initial sampling time point is and the posterior error covariance matrix P (0|0) It can be set according to experience, and through iteration, the posterior state estimation vector at the sampling time point k-1 can be obtained And the posterior error covariance matrix P (k-1|k-1) , then the kth iteration process of the strong tracking adaptive unscented Kalman algorithm specifically includes the following steps:

[0026] A1. Calculate the weight set w m and w c :

[0027]

[0028] Among them, λ, α, β are configurable parameters. According to the test results, when the noise obeys Gaussian distribution, β=2, 0≤α≤1, λ=3-n, n is the dimension of the augmented vector to be estimated: n=n x +n q ;

[0029] A2, according to the posterior state estimation vector at the sampling time point k-1 And the posterior error covariance matrix P (k-1|k-1) Generate sigma point set:

[0030]

[0031] in, is the square root matrix The i-th column of

[0032] A3. Calculate the prior state estimate vector And the prior error covariance matrix P (k|k-1) :

[0033] χ i =f(X i )(4)

[0034]

[0035] Where Q is the symmetric non-negative definite variance matrix of the system noise;

[0036] A4. Calculate the residual sequence γ k :

[0037] η i =g(χ i ) (7)

[0038]

[0039] Among them, Z k is the measured value of the signal to be identified at sampling time point k, is the estimated value of the prior output at sampling time point k;

[0040] A5. Calculate the fading factor ε k :

[0041] N k =V k -ζR k (10)

[0042]

[0043]

[0044] Where ζ is the weakening factor, ζ = 1; N k , V k , M k is the intermediate matrix of the calculation process, tr(·) represents the trace of the matrix, and ρ is the forgetting factor ρ = 0.95;

[0045] A6. Introduce the fading factor and make corrections:

[0046]

[0047] Where K is the Kalman gain matrix; and P (ZZ,k) and P (xZ,k) Respectively represent the cross-covariance matrix and auto-covariance matrix at the sampling point k, and P (k|k) Respectively represent the posterior state estimation vector and the posterior error covariance matrix at the sampling point k;

[0048] A7. Update the measurement noise matrix:

[0049]

[0050] Where b is the forgetting factor, b = 0.98;

[0051]

[0052] S42. Establish a personalized neural group model based on the estimated parameters, and use the output of the model to obtain the EEG dynamics of the patient with epileptic seizure.

[0053] A further improvement of the technical solution of the present invention is that: S5 specifically includes the following steps:

[0054] S51, locally linearize the neural group model at the working point;

[0055] Considering that the neural group model is a highly nonlinear system and has the following form:

[0056]

[0057] Among them, X(t) is the state vector of the system, U(t) is the control input vector, F(.) is the system dynamics function vector, and G(.) is the input matrix; the neural group model is locally linearized at the working point X0 to obtain:

[0058]

[0059] in, is the state transfer matrix, n is the dimension of the system, U0(t) represents the input vector at the operating point X0; B(t) is the input matrix; represents the i-th row of the matrix A(t); a i The final expression of is given by:

[0060]

[0061] Among them, F i (X(t)) represents the i-th row element of the matrix F(X(t)); Indicates the working point X0 at F i The gradient of (X(t));

[0062] S52, design controller;

[0063] Assume that the state equation and output equation of the linearized neural group model are:

[0064]

[0065] Where C(t) is the output matrix, Y(t) is the output vector; let the expected model output vector be O(t); the tracking error vector e(t) can be defined as:

[0066] e(t)=O(t)-Y(t) (27)

[0067] To determine the optimal control input U(t) that minimizes the control energy while keeping the tracking error close to zero in a finite time, the performance index is defined as:

[0068]

[0069] Among them, P and Q(t) are semi-positive definite matrices, R(t) is a positive definite matrix, t f Given; According to the minimum principle, the Hamiltonian function of the above problem is:

[0070]

[0071] Assuming U(t) is unconstrained, the control equation is:

[0072]

[0073] Co-state equation:

[0074]

[0075] Transversal conditions:

[0076]

[0077] Finally, after sorting out the calculations, we can get:

[0078] K(t f )=C T (t f )PC(t f ) (33)

[0079] g(t f )=C T (t f )PZ(t f ) (34)

[0080] By f Starting from time, the fourth-order Runge-Kutta method is used to integrate equations (33) and (34) inversely in time to obtain the values ​​of K(t) and g(t) at each time, and finally we can get:

[0081] U(t)=-R -1 (t)B T (t)[K(t)X(t)-g(t)] (35).

[0082] A further improvement of the technical solution of the present invention is that: S6 specifically includes the following steps:

[0083] S61, amplifying and processing the obtained control input required for regulating epilepsy to obtain a control waveform signal;

[0084] S62, converting the control waveform signal into a digital signal and an analog signal to obtain a digital signal;

[0085] S63, confining the digital signal in a set spatial range in the form of a magnetic pulse and transmitting it to the experimental object.

[0086] A personalized neural group model optimization system for epilepsy regulation, comprising:

[0087] A processing module, configured to receive and pre-process the EEG signal of the experimental subject to obtain a pre-processed EEG signal, and further configured to perform time domain analysis on the pre-processed EEG signal to obtain an EEG signal during an epileptic attack, calculate the power spectral density of the EEG signal during an epileptic attack, and obtain frequency characteristics of different stages during an epileptic attack;

[0088] a model parameter identification module configured to estimate the state and parameters of the neural group model and establish a personalized neural group model during an epileptic seizure;

[0089] a control module configured to set a control scheme to obtain a control input required to modulate epilepsy;

[0090] A signal processing module is configured to perform signal processing on the control input and send magnetic pulses to the experimental subject for epilepsy modulation.

[0091] A further improvement of the technical solution of the present invention is that the processing module comprises:

[0092] A preprocessing module is configured to receive the EEG signal, and perform downsampling, notch denoising and filtering on the EEG signal to obtain a preprocessed EEG signal;

[0093] A time domain analysis module configured to perform time domain analysis on the preprocessed EEG signal to obtain the EEG signal during the epileptic attack;

[0094] The frequency domain analysis module is configured to calculate the power spectrum density of the EEG signal during the epileptic attack to obtain the frequency characteristics of different stages during the epileptic attack.

[0095] A further improvement of the technical solution of the present invention is that the model parameter identification module includes:

[0096] A strong tracking adaptive UKF parameter identification module configured to set the model parameter range according to the frequency characteristics of different stages during an epileptic seizure, and estimate the state and parameters of the neural group model in real time;

[0097] A neural group model module is configured to construct a personalized neural group model using the estimated neural group model parameters to simulate the EEG dynamics of epileptic patients during seizures; the module is updated in real time through the action of a strong tracking adaptive UKF parameter identification module to reflect changes in EEG activity.

[0098] A further improvement of the technical solution of the present invention is that the signal processing module comprises:

[0099] A power amplification module, configured to amplify and process the control input to obtain a control waveform signal;

[0100] A digital-to-analog conversion module, configured to convert the control waveform into a digital signal;

[0101] The magnetic pulse module is configured to confine the digital signal in the form of magnetic pulses within a set spatial range and transmit it to the experimental subject, thereby suppressing the occurrence of epilepsy.

[0102] Due to the adoption of the above technical solution, the technical progress achieved by the present invention is:

[0103] 1. Considering that ordinary UKF still has low identification accuracy when performing parameter identification on EEG signals whose physiological state is unknown and may mutate, and whose output is affected by unknown noise, the present invention uses a strong tracking adaptive UKF algorithm to enhance the effect of parameter identification by using the strong tracking principle.

[0104] 2. The present invention uses an optimal controller, which can find the best control strategy and parameter optimization system performance indicators to achieve the best adjustment of system status and behavior. Compared with other control methods, this method can define performance indicators according to the actual use environment to minimize the performance indicators, thereby achieving optimal control.

[0105] 3. The present invention can customize the neural group model according to the actual EEG signal characteristics of different experimental subjects. Compared with the traditional "one-size-fits-all" model, this personalized modeling method can more accurately reflect the neural activity characteristics of each patient, and finally improve the effect and accuracy of epilepsy regulation through the set control scheme. BRIEF DESCRIPTION OF THE DRAWINGS

[0106] Figure 1 A schematic diagram of the structure of a personalized neural group model optimization system for epilepsy regulation provided in Example 1 of the present application;

[0107] Figure 2A flow chart of a personalized neural group model optimization method for epilepsy regulation provided in Example 2 of the present application;

[0108] Figure 3 for Figure 2 Specific flow chart of step S3;

[0109] Figure 4 for Figure 2 The specific flow chart of step S4 in FIG.

[0110] Figure 5 for Figure 2 Specific flow chart of step S6 in FIG. DETAILED DESCRIPTION

[0111] The present invention is further described in detail below with reference to the accompanying drawings and embodiments:

[0112] Example 1

[0113] like Figure 1 As shown, this embodiment provides a personalized neural group model optimization system for epilepsy regulation, and the system includes a data acquisition module, a processing module, a model parameter identification module, a control module and a signal processing module.

[0114] The data acquisition module is connected to the experimental subject and is used to collect the EEG signals of the experimental subject in real time; wherein the experimental subject is set as an epileptic patient; the acquisition module includes EEG electrodes and a neural signal processor; the EEG electrodes are generally divided into scalp electrodes and cortical electrodes, which are selected for use according to different needs. Scalp electrodes are suitable for routine monitoring and non-invasive diagnosis, and 19-25 electrodes are generally used to cover the entire scalp. Cortical EEG electrodes are suitable for patients who need to accurately locate epileptic lesions. The number of electrodes is large and invasive, and surgical implantation is required; the neural signal processor is connected to the EEG electrodes, and is configured to convert the EEG signals into corresponding digital signals, and send the converted digital signals to the EEG signal processing module.

[0115] In this embodiment, the neural signal processor may be an RZ2-8 neural signal processor from Tucker-Davis Technologies, with a sampling rate of 50 kHz, 30 kHz, and connected to a PC via optical fiber or Ethernet.

[0116] The processing module is connected to the acquisition module, and is used to receive the EEG signals of the experimental subject acquired by the acquisition module, and preprocess the EEG signals to obtain preprocessed EEG signals. It is also configured to extract features from the preprocessed EEG signals to obtain EEG signals during epileptic seizures, and calculate the power spectral density of the EEG signals during epileptic seizures to obtain frequency characteristics at different stages during epileptic seizures.

[0117] Specifically, the processing module includes: a preprocessing module, a time domain analysis module, and a frequency domain analysis module.

[0118] The preprocessing module is connected to the acquisition module, and is configured to receive the EEG signal, and to downsample, 60Hz notch denoising and 1-80Hz filtering the EEG signal to obtain a preprocessed EEG signal. It is also configured to perform time domain analysis on the preprocessed EEG signal to obtain the EEG signal during an epileptic attack, and to calculate the power spectral density of the EEG signal during an epileptic attack to obtain the frequency characteristics of different stages during an epileptic attack.

[0119] The time domain analysis module is configured to perform feature extraction on the preprocessed EEG signal to obtain the EEG signal during the epileptic attack.

[0120] The frequency domain analysis module is configured to calculate the power spectrum density of the EEG signal during the epileptic attack to obtain the frequency characteristics of different stages during the epileptic attack.

[0121] The model parameter identification module is configured to estimate the state and parameters of the neural group model and establish a personalized neural group model during an epileptic seizure.

[0122] Specifically, the model parameter identification module includes: a strong tracking adaptive UKF parameter identification module and a neural group model module.

[0123] The strong tracking adaptive UKF parameter identification module is connected to the frequency domain analysis module and is configured to set the model parameter range according to the frequency characteristics of different stages during an epileptic seizure, and estimate the state and parameters of the neural group model in real time.

[0124] The neural group model module is connected to the strong tracking adaptive UKF parameter identification module, and is configured to construct a personalized neural group model for the neural group model parameters to simulate the EEG dynamics of epileptic patients during seizures. The module is updated in real time through the action of the strong tracking adaptive UKF parameter identification module to reflect changes in EEG activity.

[0125] In this embodiment, the processing module and the model parameter identification module are implemented by a C++ program and a MATLAB program in a PC respectively, and the data transmission between the C++ program and the MATLAB program is implemented by a UDP data packet.

[0126] The control module is configured to set a control scheme and obtain epilepsy regulation control input.

[0127] Specifically, the control module includes: a design control module.

[0128] The design control module is configured to set a reasonable control scheme according to the estimated neural group model, such as proportional integral differential control, optimal control, etc. The external input required for control is obtained, and the obtained control input is used to stimulate the corresponding brain area of ​​the experimental subject in the form of an electrical signal. Inhibit the occurrence of epilepsy; in this embodiment, the design control module uses optimal control, which can be adjusted to minimize the error between the personalized model output and the expected output, thereby obtaining the required control input.

[0129] In this embodiment, the control module is implemented by a MATLAB program in a PC.

[0130] The signal processing module is configured to perform signal processing on the control input and send magnetic pulses to the experimental subject to perform epilepsy control;

[0131] Specifically, the signal processing module includes: a power amplification module, a digital-to-analog conversion module, and a magnetic pulse module.

[0132] The power amplification module is configured to amplify and process the control input to obtain a control waveform signal;

[0133] In this embodiment, the power amplifier module is implemented by a high-power operational amplifier. In this preferred embodiment, the power amplifier model is OPA541.

[0134] The digital-to-analog conversion module is configured to convert the control waveform into a digital signal;

[0135] In this embodiment, the digital-to-analog conversion module is implemented by a high-precision 20-bit digital-to-analog converter produced by Analog Devices. In this preferred embodiment, the model of the digital-to-analog converter is AD5791.

[0136] The magnetic pulse module is configured to confine the digital signal in the form of magnetic pulses within a set spatial range and transmit it to the experimental subject, thereby suppressing the occurrence of epilepsy;

[0137] In this embodiment, the magnetic pulse module is implemented by a transcranial magnetic stimulation device produced by Magstim. In this preferred embodiment, the transcranial magnetic stimulation device model is Magstim Rapid2.

[0138] Example 2

[0139] This embodiment provides a personalized neural group model optimization method for epilepsy regulation, such as Figure 2 As shown, the following steps are included:

[0140] S1, collect EEG signals of experimental subjects;

[0141] In this embodiment, the experimental subjects are epilepsy patients.

[0142] S2, preprocessing the EEG signal to obtain a preprocessed EEG signal;

[0143] This step specifically includes: performing downsampling, 60Hz notch denoising and 1-80Hz filtering on the EEG signal to obtain a preprocessed EEG signal.

[0144] S3, analyzing and processing the preprocessed EEG signal to obtain the time domain and frequency domain characteristics of the patient during the epileptic seizure;

[0145] like Figure 3 As shown, the specific steps include:

[0146] S31, performing time domain analysis on the preprocessed EEG signal to obtain the EEG signal during the epileptic attack;

[0147] S32, calculating the power spectrum density of the EEG signal during the epileptic attack, and obtaining the frequency characteristics of different stages during the epileptic attack.

[0148] S4. Determine the model parameter range according to the time domain and frequency domain characteristics, and use the strong tracking adaptive UKF algorithm to estimate the state and parameters of the neural group model in real time.

[0149] like Figure 4 As shown, the specific steps include:

[0150] S41, setting the neural group model parameter range according to the frequency characteristics, and using the strong tracking adaptive UKF algorithm to estimate the state and parameters of the neural group model in real time;

[0151] The nonlinear discrete-time dynamical system of a neural population model with unknown parameters and outputs perturbed by unknown measurement noise can be described as:

[0152]

[0153] Where k represents the sampling point sequence number, f(·) represents the dynamics function of the neural group model, g(·) represents the measurement function, represents the augmented vector of the model state and the parameters to be identified, represents the known endogenous input vector of the model, represents the measured output vector of the model, Represents the system noise vector of the model, which has a mean of 0 and a variance of Q k A Gaussian white noise sequence, Represents the measurement noise vector of the model, which has a mean of 0 and a variance of R k Gaussian white noise sequence, n x、n q 、n y 、n p are real numbers, representing the dimensions of the system vector, identification parameters, model output, and model internal input. In the task of identifying EEG signals, Q k remains constant and close to zero, while R k often unknown and time-varying;

[0154] Assuming that the measurement noise follows a Gaussian distribution with zero mean and unknown variance, the posterior state estimate vector at the initial sampling time point is and the posterior error covariance matrix P (0|0) It can be set according to experience, and through iteration, the posterior state estimation vector at the sampling time point k-1 can be obtained And the posterior error covariance matrix P (k-1|k-1) , then the kth iteration process of the strong tracking adaptive unscented Kalman algorithm specifically includes the following steps:

[0155] A1. Calculate the weight set w m and w c :

[0156]

[0157] Among them, λ, α, β are configurable parameters. According to the test results, when the noise obeys Gaussian distribution, β=2, 0≤α≤1, λ=3-n, n is the dimension of the augmented vector to be estimated: n=n x +n q ;

[0158] A2, according to the posterior state estimation vector at the sampling time point k-1 And the posterior error covariance matrix P (k-1|k-1) Generate sigma point set:

[0159]

[0160] in, is the square root matrix It should be noted that the larger the α value, the farther the sigma point set distribution is from the mean value;

[0161] A3. Calculate the prior state estimate vector And the prior error covariance matrix P (k|k-1) :

[0162] χ i =f(X i ) (4)

[0163]

[0164] Where Q is the symmetric non-negative definite variance matrix of the system noise;

[0165] A4. Calculate the residual sequence γ k :

[0166] η i =g(χ i ) (7)

[0167]

[0168] Among them, Z k is the measured value of the signal to be identified at sampling time point k, is the estimated value of the prior output at sampling time point k;

[0169] A5. Calculate the fading factor ε k :

[0170] N k =V k -ζR k (10)

[0171]

[0172] Where ζ is the weakening factor, ζ = 1; N k , V k , M k is the intermediate matrix of the calculation process, tr(·) represents the trace of the matrix, and ρ is the forgetting factor ρ = 0.95;

[0173] A6. Introduce the fading factor and make corrections:

[0174]

[0175]

[0176] Where K is the Kalman gain matrix; and P (ZZ,k) and P (xZ,k) Respectively represent the cross-covariance matrix and auto-covariance matrix at the sampling point k, and P (k|k) Respectively represent the posterior state estimation vector and the posterior error covariance matrix at the sampling point k;

[0177] A7. Update the measurement noise matrix:

[0178]

[0179] Where b is the forgetting factor, b = 0.98;

[0180]

[0181] S42. Establish a personalized neural group model based on the estimated parameters, and use the output of the model to obtain the EEG dynamics of the patient with epileptic seizure.

[0182] S5. Designing a controller according to the personalized neural group model so that the error between the output of the personalized model and the expected output is minimized, thereby obtaining the control input required for regulating epilepsy, specifically comprising the following steps:

[0183] S51, locally linearize the neural group model at the working point;

[0184] Considering that the neural group model is a highly nonlinear system and has the following form:

[0185]

[0186] Among them, X(t) is the state vector of the system, U(t) is the control input vector, F(.) is the system dynamics function vector, and G(.) is the input matrix; the neural group model is locally linearized at the working point X0 to obtain:

[0187]

[0188] in, is the state transfer matrix, n is the dimension of the system, U0(t) represents the input vector at the operating point X0; B(t) is the input matrix; represents the i-th row of the matrix A(t); a i The final expression of is given by:

[0189]

[0190] Among them, F i (X(t)) represents the i-th row element of the matrix F(X(t)); Indicates the working point X0 at F i The gradient of (X(t));

[0191] S52, design controller;

[0192] Assume that the state equation and output equation of the linearized neural group model are:

[0193]

[0194] Where C(t) is the output matrix, Y(t) is the output vector; let the expected model output vector be O(t); the tracking error vector e(t) can be defined as:

[0195] e(t)=O(t)-Y(t) (27)

[0196] To determine the optimal control input U(t) that minimizes the control energy while keeping the tracking error close to zero in a finite time, the performance index is defined as:

[0197]

[0198] Among them, P and Q(t) are semi-positive definite matrices, R(t) is a positive definite matrix, t f Given; According to the minimum principle, the Hamiltonian function of the above problem is:

[0199]

[0200] Assuming U(t) is unconstrained, the control equation is:

[0201]

[0202] Co-state equation:

[0203]

[0204] Transversal conditions:

[0205]

[0206] Finally, after sorting out the calculations, we can get:

[0207] K(t f )=C T (t f )PC(t f ) (33)

[0208] g(t f )=C T (t f )PZ(t f ) (34)

[0209] By f Starting from time, the fourth-order Runge-Kutta method is used to integrate equations (33) and (34) inversely in time to obtain the values ​​of K(t) and g(t) at each time, and finally we can get:

[0210] U(t)=-R -1 (t)B T (t)[K(t)X(t)-g(t)] (35)

[0211] S6. According to the control input, a magnetic pulse is emitted to the experimental subject to perform epilepsy regulation to achieve epilepsy suppression.

[0212] like Figure 5 As shown, the specific steps include:

[0213] S61, amplifying and processing the obtained control input required for regulating epilepsy to obtain a control waveform signal;

[0214] S62, converting the control waveform signal into a digital signal and an analog signal to obtain a digital signal;

[0215] S63, confining the digital signal in a set spatial range in the form of a magnetic pulse and transmitting it to the experimental object.

[0216] In summary, the present invention can dynamically adjust the model parameters according to the real-time collected EEG signals, and generate a personalized model based on the individual characteristics of the patient. The model can generate epileptic seizure prediction data, greatly reducing the collection work of the epileptic seizure process, and finally regulate epilepsy through the designed control scheme.

Claims

1. A personalized neural group model optimization method for epilepsy regulation, characterized by: The following steps are involved: S1, collect EEG signals of experimental subjects; S2, preprocessing the EEG signal to obtain a preprocessed EEG signal; S3, analyzing and processing the preprocessed EEG signal to obtain the time domain and frequency domain characteristics of the patient during the epileptic seizure; S4, determine the model parameter range according to the time domain and frequency domain characteristics, and use the strong tracking adaptive UKF algorithm to estimate the state and parameters of the neural group model in real time; S5. Designing a controller according to the personalized neural group model so that the error between the output of the personalized model and the expected output is minimized, thereby obtaining the control input required for regulating epilepsy; S6. According to the control input, a magnetic pulse is emitted to the experimental subject to perform epilepsy regulation to achieve epilepsy suppression.

2. The personalized neural group model optimization method for epilepsy regulation according to claim 1, characterized in that: In S2, the EEG signal is downsampled, 60 Hz notch denoised and 1-80 Hz filtered to obtain a preprocessed EEG signal.

3. The personalized neural group model optimization method for epilepsy regulation according to claim 1, characterized in that: S3 specifically includes the following steps: S31, performing time domain analysis on the preprocessed EEG signal to obtain the EEG signal during the epileptic attack; S32, calculating the power spectrum density of the EEG signal during the epileptic attack, and obtaining the frequency characteristics of different stages during the epileptic attack.

4. The personalized neural group model optimization method for epilepsy regulation according to claim 1, characterized in that: S4 specifically includes the following steps: S41, setting the neural group model parameter range according to the frequency characteristics, and using the strong tracking adaptive UKF algorithm to estimate the state and parameters of the neural group model in real time; The nonlinear discrete-time dynamical system of a neural population model with unknown parameters and outputs perturbed by unknown measurement noise is described as: Where k represents the sampling point sequence number, f(·) represents the dynamics function of the neural group model, g(·) represents the measurement function, represents the augmented vector of the model state and the parameters to be identified, represents the known endogenous input vector of the model, represents the measured output vector of the model, Represents the system noise vector of the model, which has a mean of 0 and a variance of Q k A Gaussian white noise sequence, Represents the measurement noise vector of the model, which has a mean of 0 and a variance of R k Gaussian white noise sequence, n x 、n q 、n y 、n p are real numbers, representing the dimensions of the system vector, identification parameters, model output, and model internal input. In the task of identifying EEG signals, Q k remains constant and close to zero, while R k often unknown and time-varying; Assuming that the measurement noise follows a Gaussian distribution with zero mean and unknown variance, the posterior state estimate vector at the initial sampling time point is and the posterior error covariance matrix P (0|0) It can be set according to experience, and through iteration, the posterior state estimation vector at the sampling time point k-1 can be obtained And the posterior error covariance matrix P (k-1|k-1) , then the kth iteration process of the strong tracking adaptive unscented Kalman algorithm specifically includes the following steps: A1. Calculate the weight set w m and w c : Among them, λ, α, β are configurable parameters. According to the test results, when the noise obeys Gaussian distribution, β=2, 0≤α≤1, λ=3-n, n is the dimension of the augmented vector to be estimated: n=n x +n q ; A2, according to the posterior state estimation vector at the sampling time point k-1 And the posterior error covariance matrix P (k-1|k-1) Generate sigma point set: in, is the square root matrix The i-th column of A3. Calculate the prior state estimate vector And the prior error covariance matrix P (k|k-1) : x i =f(X i ) (4) Where Q is the symmetric non-negative definite variance matrix of the system noise; A4. Calculate the residual sequence γ k : or i =g(x i ) (7) Among them, Z k is the measured value of the signal to be identified at sampling time point k, is the estimated value of the prior output at sampling time point k; A5. Calculate the fading factor ε k : N k =V k -ζR k (10) Where ζ is the weakening factor, ζ = 1; N k , V k , M k is the intermediate matrix of the calculation process, tr(·) represents the trace of the matrix, and ρ is the forgetting factor ρ = 0.95; A6. Introduce the fading factor and make corrections: Where K is the Kalman gain matrix; and P (ZZ,k) and P (xZ,k) Respectively represent the cross-covariance matrix and auto-covariance matrix at the sampling point k, and P (k|k) Respectively represent the posterior state estimation vector and the posterior error covariance matrix at the sampling point k; A7. Update the measurement noise matrix: Where b is the forgetting factor, b = 0.98; S42. Establish a personalized neural group model based on the estimated parameters, and use the output of the model to obtain the EEG dynamics of the patient with epileptic seizure.

5. The personalized neural group model optimization method for epilepsy regulation according to claim 1, characterized in that: S5 specifically includes the following steps: S51, locally linearize the neural group model at the working point; Considering that the neural group model is a highly nonlinear system and has the following form: Among them, X(t) is the state vector of the system, U(t) is the control input vector, F(.) is the system dynamics function vector, and G(.) is the input matrix; the neural group model is locally linearized at the working point X0 to obtain: in, is the state transfer matrix, n is the dimension of the system, U0(t) represents the input vector at the operating point X0; B(t) is the input matrix; represents the i-th row of the matrix A(t); a i The final expression of is given by: Among them, F i (X(t)) represents the i-th row element of the matrix F(X(t)); Indicates the working point X0 at F i The gradient of (X(t)); S52, design controller; Assume that the state equation and output equation of the linearized neural group model are: Where C(t) is the output matrix, Y(t) is the output vector; let the expected model output vector be O(t); the tracking error vector e(t) can be defined as: e(t)=O(t)-Y(t) (27) To determine the optimal control input U(t) that minimizes the control energy while keeping the tracking error close to zero in a finite time, the performance index is defined as: Among them, P and Q(t) are semi-positive definite matrices, R(t) is a positive definite matrix, t f Given; According to the minimum principle, the Hamiltonian function of the above problem is: Assuming U(t) is unconstrained, the control equation is: Co-state equation: Transversal conditions: Finally, after sorting out the calculations, we can get: K(t f )=C T (t f )PC(t f ) (33) g(t f )=C T (t f )PZ(t f ) (34) By f Starting from time, the fourth-order Runge-Kutta method is used to integrate equations (33) and (34) inversely in time to obtain the values ​​of K(t) and g(t) at each time, and finally we can get: U(t)=-R -1 (t)B T (t)[K(t)X(t)-g(t)] (35)。 6. The personalized neural group model optimization method for epilepsy regulation according to claim 1, characterized in that: S6 specifically includes the following steps: S61, amplifying and processing the obtained control input required for regulating epilepsy to obtain a control waveform signal; S62, converting the control waveform signal into a digital signal and an analog signal to obtain a digital signal; S63, confining the digital signal in a set spatial range in the form of a magnetic pulse and transmitting it to the experimental object.

7. A personalized neural group model optimization system for epilepsy regulation, characterized by: The personalized neural group model optimization method for epilepsy regulation according to any one of claims 1 to 6 comprises: A processing module, configured to receive and pre-process the EEG signal of the experimental subject to obtain a pre-processed EEG signal, and further configured to perform time domain analysis on the pre-processed EEG signal to obtain an EEG signal during an epileptic attack, calculate the power spectral density of the EEG signal during an epileptic attack, and obtain frequency characteristics of different stages during an epileptic attack; a model parameter identification module configured to estimate the state and parameters of the neural group model and establish a personalized neural group model during an epileptic seizure; a control module configured to set a control scheme to obtain a control input required to modulate epilepsy; A signal processing module is configured to perform signal processing on the control input and send magnetic pulses to the experimental subject for epilepsy modulation.

8. The personalized neural group model optimization method for epilepsy regulation according to claim 7, characterized in that: The processing module comprises: A preprocessing module is configured to receive the EEG signal, and perform downsampling, notch denoising and filtering on the EEG signal to obtain a preprocessed EEG signal; A time domain analysis module configured to perform time domain analysis on the preprocessed EEG signal to obtain the EEG signal during the epileptic attack; The frequency domain analysis module is configured to calculate the power spectrum density of the EEG signal during the epileptic attack to obtain the frequency characteristics of different stages during the epileptic attack.

9. The personalized neural group model optimization method for epilepsy regulation according to claim 7, characterized in that: The model parameter identification module includes: A strong tracking adaptive UKF parameter identification module configured to set the model parameter range according to the frequency characteristics of different stages during an epileptic seizure, and estimate the state and parameters of the neural group model in real time; A neural group model module is configured to construct a personalized neural group model using the estimated neural group model parameters to simulate the EEG dynamics of epileptic patients during seizures; the module is updated in real time through the action of a strong tracking adaptive UKF parameter identification module to reflect changes in EEG activity.

10. The personalized neural group model optimization method for epilepsy regulation according to claim 7, characterized in that: The signal processing module comprises: A power amplification module, configured to amplify and process the control input to obtain a control waveform signal; A digital-to-analog conversion module, configured to convert the control waveform into a digital signal; The magnetic pulse module is configured to confine the digital signal in the form of magnetic pulses within a set spatial range and transmit it to the experimental subject, thereby suppressing the occurrence of epilepsy.

Citation Information

Patent Citations

  • Epilepsy excitability and inhibitive ability balance calculation method based on hybrid dynamic causal model

    CN116439726A