Student eeg signal denoising method in online teaching
By constructing a network model for denoising EEG signals and utilizing extended residual blocks and information fusion technology, the problem of rapid and accurate denoising of EEG signals in online teaching was solved, achieving the effect of quickly removing noise and preserving the original signal.
Patent Information
- Application Number
- CN202310553515.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-05-17
- Publication Date
- 2026-11-27
- Estimated Expiration
- 2043-05-17
AI Technical Summary
Existing EEG signal denoising methods are not ideal for online teaching. Traditional methods suffer from severe distortion, while deep learning methods are incomplete in denoising and have slow fitting speeds, making it difficult to achieve real-time denoising.
A network model for denoising EEG signals was constructed, employing an encoder, multiple dilated residual blocks, and an information fusion block. Contextual information was aggregated through dilated convolution and layer normalization techniques to remove noise quickly and accurately.
Without increasing the number of parameters and computational load, this method can quickly and accurately remove interference noise from EEG signals, reduce overfitting, improve model convergence speed, and preserve the integrity of the original signal.
Smart Images

Figure CN116509418B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of EEG signal denoising technology, specifically to a method for denoising student EEG signals during online teaching. Background Technology
[0002] Online teaching presents a new opportunity for modern education through technological advancements, but it also brings new challenges to teaching efficiency. Teaching across geographical boundaries prevents teachers from receiving real-time feedback from students, thus reducing teaching effectiveness. Therefore, extracting feedback on student focus through electroencephalogram (EEG) signals has become an effective means for teachers to improve teaching efficiency. However, EEG signals extracted by EEG devices are easily affected by noise, impacting the model's judgment of student focus and making it difficult to provide effective feedback to teachers. Therefore, quickly and accurately removing noise while preserving the original EEG signals generated by neurons is a crucial task. The noise contained in EEG signals mainly includes myogenic artifacts (EMG) and ocular artifacts (EOG), so denoising aims to remove EMG and EOG from EEG signals mixed with noise.
[0003] Traditional machine learning methods have long been used in EEG denoising research, but their denoising effects are not ideal, with significant distortion of the output signal. In recent years, with the improvement of computing power, many researchers have introduced deep learning models. Deep learning methods can rival traditional machine learning methods in EEG denoising tasks. Some researchers have proposed a benchmark dataset (EEGdenoiseNet) for an end-to-end deep learning solution for EEG denoising, and evaluated the denoising performance of four common neural networks (fully connected networks, simple and complex convolutional neural networks, and recurrent neural networks) based on this dataset. However, current neural network algorithms in the field of EEG denoising still have drawbacks, including incomplete noise removal, distortion of the EEG signal, and slow fitting speed, which are not conducive to future real-time denoising applications. Summary of the Invention
[0004] The purpose of this invention is to provide a method for denoising student EEG signals in online teaching, which is beneficial for quickly and accurately removing interference noise from EEG signals.
[0005] To achieve the above objectives, the technical solution adopted by this invention is: a method for denoising student EEG signals in online teaching, comprising:
[0006] A network model for denoising EEG signals is constructed. The network model encodes the noisy input EEG signal through an encoder, then aggregates more contextual information through multiple extended residual blocks, then fuses features at different levels through an information fusion block, and finally restores the fused features to the magnitude of the input signal through a decoder to obtain the denoised EEG signal.
[0007] The EEG signal denoising network model was trained using the dataset to obtain the trained EEG signal denoising network model.
[0008] A trained EEG signal denoising network model is used to denoise the EEG signal to be processed.
[0009] Furthermore, the EEG signal denoising network model includes an encoder, four extended residual blocks, an information fusion block, and a decoder. For the input noisy EEG signal, it is first encoded by the encoder. The output of the encoder is simultaneously the input of the first extended residual block and the information fusion block. The output of the first extended residual block is the input of the second extended residual block. The output of the second extended residual block is simultaneously the input of the third extended residual block and the information fusion block. The output of the third extended residual block is the input of the fourth extended residual block. The output of the fourth extended residual block is the input of the information fusion block, thereby achieving the fusion of features at different levels through the information fusion block. Finally, the decoder restores the output of the information fusion block to the magnitude of the input signal.
[0010] Furthermore, each expanded residual block includes a dilated convolutional layer, a normalization layer, and a ReLU layer. The first three expanded residual blocks employ batch normalization to accelerate the fitting process and prevent overfitting, while the fourth expanded residual block employs layer normalization.
[0011] Furthermore, the EEG signal denoising network model utilizes features at different levels and obtains the fused feature input to the decoder through weighted summation. This process can be represented as:
[0012] (M l M m M h )=G(F l ,F m ,F h )
[0013] F0 = M l *F l +M m *F m +M h *F h
[0014] Among them, F l Fm F h These represent the outputs of the encoder, the second extended residual block, and the fourth extended residual block, respectively. G(,,) represents the gating function, and M... l M m M h These are dynamic masks, and their values depend on the input feature F each time. l F m F h F0 is the output feature.
[0015] Furthermore, the encoder uses three convolutional blocks and one pooling layer to encode the input noise-contaminated EEG signal into a feature map. Each convolutional block contains a convolutional layer, a normalization layer, and a ReLU layer.
[0016] Furthermore, the decoder comprises two convolutional layers, one pooling layer, and one fully connected layer.
[0017] Furthermore, the EEG signal denoising network model can be described by a nonlinear mapping function as follows:
[0018]
[0019]
[0020] in, Let F(,) represent the noise-free EEG signal predicted by the model, F(,) represent the mapping function used to describe the EEG signal denoising network model, y represent the noisy EEG signal, θ represent the learnable parameters of the model, and x represent the ground truth value of the clean EEG signal. i Let represent the true value of the i-th sample. Let N represent the model's predicted value for the i-th sample, and N represent the total number of samples. This represents the mean square error between the predicted noise-free EEG signal and the true value of the EEG signal.
[0021] The EEG signal denoising network model is Using the loss function, the EEG signal denoising network model is trained with the dataset to achieve the desired result. minimize.
[0022] Compared with the prior art, the present invention has the following beneficial effects: it provides a method for denoising EEG signals of students in online teaching. The EEG signal denoising network model constructed by this method aggregates more contextual information through multiple expanded residual blocks, increases the receptive field without increasing the number of parameters and computational load, and then fuses features at different levels through a feature fusion network, thereby reducing overfitting and accelerating model convergence. Therefore, this method can remove interference noise in EEG signals more quickly and accurately. Attached Figure Description
[0023] Figure 1 This is an architecture diagram of the EEG signal denoising network model in an embodiment of the present invention. Detailed Implementation
[0024] The present invention will be further described below with reference to the accompanying drawings and embodiments.
[0025] It should be noted that the following detailed descriptions are exemplary and intended to provide further explanation of this application. Unless otherwise specified, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application pertains.
[0026] It should be noted that the terminology used herein is for the purpose of describing particular embodiments only and is not intended to limit the exemplary embodiments according to this application. As used herein, the singular form is intended to include the plural form as well, unless the context clearly indicates otherwise. Furthermore, it should be understood that when the terms "comprising" and / or "including" are used in this specification, they indicate the presence of features, steps, operations, devices, components, and / or combinations thereof.
[0027] This embodiment provides a method for denoising student EEG signals in online teaching, including:
[0028] 1) Construct an EEG signal denoising network model. This model encodes the noisy input EEG signal using an encoder, then aggregates more contextual information using multiple dilated residual blocks, fuses features at different levels using an information fusion block, and finally restores the input signal's magnitude using a decoder to obtain the denoised EEG signal. The architecture of the EEG signal denoising network model in this embodiment is as follows: Figure 1 As shown.
[0029] 2) The EEG signal denoising network model is trained using the dataset to obtain the trained EEG signal denoising network model.
[0030] 3) Use the trained EEG signal denoising network model to denoise the EEG signal to be processed.
[0031] In this embodiment, the EEG signal denoising network model includes an encoder, four dilated residual blocks (residual blocks containing dilated convolutions), an information fusion block, and a decoder. For the input noisy EEG signal, it is first encoded by the encoder. The encoder's output is simultaneously the input to the first dilated residual block and the information fusion block. The output of the first dilated residual block is the input to the second dilated residual block, the output of the second dilated residual block is simultaneously the input to the third dilated residual block and the information fusion block, the output of the third dilated residual block is the input to the fourth dilated residual block, and the output of the fourth dilated residual block is the input to the information fusion block. This allows for the fusion of features at different levels through the information fusion block. Finally, the decoder restores the output of the information fusion block to the magnitude of the input signal.
[0032] This method targets dense prediction tasks, and its key challenge is addressing the loss of spatial resolution information during multi-scale contextual inference and downsampling. This method employs dilated residual blocks based on dilated convolution to aggregate more contextual information, thereby expanding the receptive field while maintaining resolution.
[0033] In this embodiment, each dilated residual block includes a dilated convolutional layer, a normalization layer, and a ReLU layer. The first three dilated residual blocks employ batch normalization to accelerate fitting and prevent overfitting, while the fourth dilated residual block employs layer normalization. Since layer normalization is frequently used in natural language processing, and considering that EEG signals are one-dimensional, we also use layer normalization here. The residual structure effectively prevents gradient vanishing and exploding, and the dilated convolutional layer aggregates more contextual information. The dilation coefficients of the four dilated residual blocks are set to 2, 4, 4, and 1, respectively, and features from different levels are fused to improve its learning ability.
[0034] The EEG signal denoising network model utilizes features at different levels and obtains fused features by weighted summation, which is then input into the decoder. This process can be represented as follows:
[0035] (M l M m M h )=G(F l ,F m ,F h )
[0036] F0 = M l *F l +M m*F m +M h *F h
[0037] Among them, F l F m F h These represent the outputs of the encoder, the second extended residual block, and the fourth extended residual block, respectively. G(,,) represents the gating function, and M... l M m M h These are dynamic masks, whose values depend on the input feature F each time. l F m F h F0 is the output feature.
[0038] In this embodiment, the encoder uses three convolutional blocks and one pooling layer to encode the input noisy EEG signal into a feature map. Each convolutional block contains a convolutional layer, a normalization layer, and a ReLU layer. The ReLU layer establishes the nonlinear relationship between the layers of the neural network. The convolutional kernels in the three convolutional blocks are (1, 3, 5) to extract features at different scales.
[0039] In this embodiment, the decoder comprises two convolutional layers, one pooling layer, and one fully connected layer. Convolutional layers can only capture local features, while fully connected layers can capture global features. To improve network performance, a fully connected layer is added at the end of the network.
[0040] The proposed EEG signal denoising network model is an end-to-end model, which can be described by a nonlinear mapping function as follows:
[0041]
[0042]
[0043] in, Let F(,) represent the noise-free EEG signal predicted by the model, F(,) represent the mapping function used to describe the EEG signal denoising network model, y represent the noisy EEG signal, θ represent the learnable parameters of the model, and x represent the ground truth value of the clean EEG signal. i Let represent the true value of the i-th sample. Let N represent the model's predicted value for the i-th sample, and N represent the total number of samples. This represents the mean square error (MSE) between the predicted noise-free EEG signal and the true EEG signal.
[0044] The EEG signal denoising network model is Using the loss function, the EEG signal denoising network model is trained with the dataset to achieve the desired result. minimize.
[0045] The following comparative experiments on the EEGdenoisenet dataset demonstrate that our method can more efficiently remove interference noise from EEG and preserve more complete original EEG signals.
[0046] 1. Experimental Environment and Setup
[0047] All experiments were conducted on an Ubuntu 20.04 system using Ten-sorFlow 2.2.0, with an NVIDIA RTX 3080Ti GPU to optimize training speed. All comparison algorithms were trained for 60 epochs, while this method was trained for only 5 epochs. By default, we used a batch size of 40 for Adam optimizer training and set the parameter α = 5e. -5 β1 = 0.5, β2 = 0.9. The default initial learning rate is set to 0.00005.
[0048] 2. Dataset
[0049] The dataset used in this embodiment is EEGdenoiseNet, a dataset suitable for EEG artifact attenuation based on deep networks. This dataset contains 4514 clean EEG segments as ground truth, 3400 pure EOG segments, and 5598 pure EMG segments as eye artifacts and myogenic artifacts, respectively. It also includes noisy EEG signals synthesized from clean EEG segments and artifacts. The process of degenerating a clean EEG signal into a noisy EEG signal can be represented as follows:
[0050] y = x + λn
[0051]
[0052]
[0053] Where y represents a one-dimensional mixed signal of EEG and artifacts; x represents the clean EEG signal as the true value; n represents the (ocular or myogenic) artifact; and λ is a hyperparameter controlling the signal-to-noise ratio (SNR) of the contaminated EEG signal y. A lower λ results in a higher SNR, meaning less noise is introduced; conversely, a higher λ results in a lower SNR, meaning more noticeable noise. In the calculation of the root mean square (RMS), a segment g contains N time samples, and the i-th sample in g is denoted as gi. i .
[0054] To quantitatively analyze the effectiveness of each method across different frequency bands, we calculated the power ratio of the signal in each band. Table 1 shows the power ratio of the signal in different frequency bands. It lists the outputs after denoising using six different methods, including five comparative algorithms and our own method, as well as the ground truth and noisy EEG. Each row of data corresponds to one method, and each column corresponds to one frequency band. The six frequency bands are: Delta (1-4Hz), Theta (4-8Hz), Alpha (8-12Hz), Beta (12-30Hz), and Gamma (30-100Hz). Overall, our method performs well, but its effectiveness may be compromised when dealing with different levels of noise.
[0055] Table 1 Power ratio of output signals from different methods in different frequency bands
[0056]
[0057] To quantitatively analyze the network performance of each method, we measure its convergence by analyzing the loss values corresponding to the validation set during network training. Table 2 shows the loss values of each method in the denoising task. The smaller the loss value, the better the denoising effect. Our method only underwent 5 epochs of training; the corresponding loss values in the table are the loss values at the 5th epoch. Other algorithms underwent 60 epochs of training; the corresponding loss values in the table are their loss values at the 60th epoch. Our method's loss values for removing EMG and EOG are 0.133 and 0.127 respectively, lower than other networks, indicating good robustness in the denoising task. From the perspective of fitting speed, our method has a faster fitting speed.
[0058] Table 2 Comparison of loss values for different methods in denoising tasks
[0059]
[0060] This embodiment also provides an online teaching system for denoising EEG signals of middle school students to implement the above method, including a memory, a processor, and computer program instructions stored in the memory and executable by the processor. When the processor executes the computer program instructions, it can implement the above method steps.
[0061] Those skilled in the art will understand that embodiments of this application can be provided as methods, systems, or computer program products. Therefore, this application can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, this application can take the form of a computer program product embodied on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0062] This application is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of this application. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart... Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.
[0063] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.
[0064] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.
[0065] The above description is merely a preferred embodiment of the present invention and is not intended to limit the invention in any other way. Any person skilled in the art may make changes or modifications to the above-disclosed technical content to create equivalent embodiments. However, any simple modifications, equivalent changes, and modifications made to the above embodiments based on the technical essence of the present invention without departing from the scope of the present invention shall still fall within the protection scope of the present invention.
Claims
1. A method for denoising student EEG signals during online teaching, characterized in that, include: A network model for denoising EEG signals is constructed. The network model encodes the noisy input EEG signal through an encoder, then aggregates more contextual information through multiple extended residual blocks, then fuses features at different levels through an information fusion block, and finally restores the fused features to the magnitude of the input signal through a decoder to obtain the denoised EEG signal. The EEG signal denoising network model was trained using the dataset to obtain the trained EEG signal denoising network model. A trained EEG signal denoising network model was used to denoise the EEG signal to be processed. The EEG signal denoising network model includes an encoder, four extended residual blocks, an information fusion block, and a decoder. For the input noisy EEG signal, it is first encoded by the encoder. The output of the encoder is simultaneously the input of the first extended residual block and the information fusion block. The output of the first extended residual block is the input of the second extended residual block. The output of the second extended residual block is simultaneously the input of the third extended residual block and the information fusion block. The output of the third extended residual block is the input of the fourth extended residual block. The output of the fourth extended residual block is the input of the information fusion block, thereby achieving the fusion of features at different levels through the information fusion block. Finally, the decoder restores the output of the information fusion block to the magnitude of the input signal.
2. The method for denoising student EEG signals in online teaching according to claim 1, characterized in that, Each dilated residual block consists of a dilated convolutional layer, a normalized layer, and a ReLU layer. The first three dilated residual blocks use batch normalization to speed up the fitting process and prevent overfitting, while the fourth dilated residual block uses layer normalization.
3. The method for denoising student EEG signals in online teaching according to claim 1, characterized in that, The EEG signal denoising network model utilizes features at different levels and obtains fused features by weighted summation, which is then input into the decoder. This process can be represented as: Among them, F l F m F h Let G( , , ) represent the outputs of the encoder, the second extended residual block, and the fourth extended residual block, respectively. Let G( , , ) represent the gating function, and M represent the outputs of the encoder, the second extended residual block, and the fourth extended residual block, respectively. l M m M h These are dynamic masks, whose values depend on the input feature F each time. l F m F h F0 is the output feature.
4. The method for denoising student EEG signals in online teaching according to claim 1, characterized in that, The encoder uses three convolutional blocks and one pooling layer to encode the input noisy EEG signal into a feature map. Each convolutional block contains a convolutional layer, a normalization layer, and a ReLU layer.
5. The method for denoising student EEG signals in online teaching according to claim 1, characterized in that, The decoder contains two convolutional blocks, one pooling layer, and one fully connected layer.
6. The method for denoising student EEG signals in online teaching according to claim 1, characterized in that, The EEG signal denoising network model can be described by a nonlinear mapping function as follows: in, Let F( , ) represent the noise-free EEG signal predicted by the model, F( , ) represent the mapping function used to describe the EEG signal denoising network model, y represent the noisy EEG signal, θ represent the learnable parameters of the model, and x represent the ground truth value of the clean EEG signal. i This represents the true value of the i-th sample. Let N represent the model's predicted value for the i-th sample, and N represent the total number of samples. This represents the mean square error between the predicted noise-free EEG signal and the true value of the EEG signal. The EEG signal denoising network model is Using the loss function, the EEG signal denoising network model is trained with the dataset to achieve the desired result. minimize.
Citation Information
Patent Citations
Method and device for removing artifacts of electroencephalogram signals and electronic equipment
CN113081002A
Underwater image enhancement method based on residual dual-attention network
CN113313644A
