Electroencephalogram artifact removal method, device and equipment and storage medium

By constructing a artifact noise training set and training the target model, the problem of insufficient accuracy of EEG artifact noise removal in the prior art is solved, and efficient and accurate artifact removal effect is achieved.

CN119867784APending Publication Date: 2025-04-25ZHIKONG (HANGZHOU) INTELLIGENT TECHNOLOGY CO LTD
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202411322990.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-09-23
Publication Date
2025-04-25

AI Technical Summary

Technical Problem

The prior art, when removing artifact noise in EEG, is not accurate enough in decomposing and selecting interfering components, resulting in unclear artifact removal or loss of useful data.

Method used

By constructing a widget noise training set, the target model is trained to remove widget noise. The specific steps include collecting the EEG signal, building the training set, training the initial model and optimizing its parameters until the preset removal accuracy is achieved.

Benefits of technology

The precise removal of artifact noise is achieved, which reduces the training sample production time and model training cost, and improves processing efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119867784A_ABST
    Figure CN119867784A_ABST
Patent Text Reader

Abstract

The invention provides an electroencephalogram artifact removing method and device, equipment and a storage medium. The electroencephalogram artifact removing method comprises the steps that EEG signals containing artifact noise are collected; inputting the collected EEG signal containing the artifact noise into a target model for processing; wherein the target model is obtained through training of a pre-constructed artifact noise training set, and data in the artifact noise training set comprises a sequence signal formed after multiple iterations of artifact noise on the basis of a clean EEG signal; and outputting a clean EEG signal of which the artifact noise is removed by the trained target model. Therefore, the adding process of the artifact noise can be learned, the whole learning process does not need labels, the time for making training samples can be shortened, the training cost of the target model can be reduced, the artifact noise can be accurately removed from the target model obtained through training, and the processing efficiency is high.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of signal processing technology, and in particular to an electroencephalogram (EEG) artifact removal method, device, equipment and storage medium. Background Art

[0002] Since EEG has a millisecond time resolution, it can distinguish different or related cognitive processes on the time scale of neuronal discharge in the study of brain cognition and function. Therefore, single-modality EEG research is still widely used. In the process of single-modality EEG acquisition, since the human body has a variety of electrophysiological signals such as electrocardiogram signals, electromyography signals, and electrooculogram signals, and the amplitudes of these electrophysiological signals are several orders of magnitude of EEG signals, when the signal is transmitted through human tissue, these electrophysiological signals will seriously interfere with the collected EEG signals, causing EEG signal defects.

[0003] At present, the more common method to solve the above problem is: signal decomposition methods such as principal component analysis and independent component analysis, that is, decomposing the collected EEG signals into unrelated or independent EOG components and EEG components, and then removing EOG artifacts by selecting components.

[0004] However, the key to the above method lies in the accurate decomposition and selection of the interference components. If the decomposition and selection are not accurate enough, it will easily cause the electrooculogram artifacts to be not removed cleanly or lose useful data. Summary of the invention

[0005] In view of the defects in the prior art, the object of the present invention is to provide a method, device, equipment and storage medium for removing electroencephalogram artifacts.

[0006] In a first aspect, an embodiment of the present application provides a method for removing electroencephalogram artifacts, comprising:

[0007] Collect EEG signals containing artifact noise;

[0008] The collected EEG signal containing artifact noise is input into the target model for processing; wherein the target model is trained by a pre-constructed artifact noise training set, and the data in the artifact noise training set includes: a sequence signal formed by multiple iterations of artifact noise on the basis of a clean EEG signal;

[0009] The trained target model outputs a clean EEG signal with artifact noise removed.

[0010] Optionally, before inputting the collected EEG signal containing artifact noise into the target model for processing, the method further includes:

[0011] Construct an artifact noise training set;

[0012] Build an initial model;

[0013] The initial model is trained using an artifact noise training set until the accuracy of the trained initial model in removing artifact noise reaches a preset requirement, thereby obtaining a target model.

[0014] Optionally, constructing an artifact noise training set includes:

[0015] Collect raw EEG signals;

[0016] Segmenting the original EEG signal through a time window of a preset duration to obtain EEG signal segments of a preset duration;

[0017] Preprocessing the EEG signal segment of the preset time length by using a filter to obtain a preprocessed EEG signal, wherein the preprocessing includes: removing low-frequency drift noise and high-frequency noise in the EEG signal segment of the preset time length by using a bandpass filter, and removing a linear trend in the signal;

[0018] Extracting several types of artifact noises less than a preset time threshold from the original EEG signal, and combining them into an artifact noise set containing different artifact categories; wherein the artifact noises in the artifact noise set include: heartbeat artifact signal segments, eye movement artifact signal segments, and electromyography artifact signal segments;

[0019] Selecting m clean EEG signal segments from the preprocessed EEG signal; wherein m is a natural number greater than 1;

[0020] Selecting a number of artifact noises from the artifact noise set and superimposing them on a selected clean EEG signal segment to generate an EEG signal segment with artifacts;

[0021] Determine whether a preset number of iterations n is reached. If not, continue to select a number of artifact noises from the artifact noise set and superimpose them on the latest generated EEG signal segment with artifacts until the preset number of iterations n is reached, thereby forming a sequence signal containing n signal segments; wherein n is a natural number greater than 1; and m clean EEG signal segments correspond to generating m sequence signals;

[0022] An artifact noise training set is constructed based on the generated m sequence signals.

[0023] Optionally, the initial model includes: a TransUNet model.

[0024] Optionally, the initial model is trained by using an artifact noise training set until the accuracy of removing artifact noise by the trained initial model reaches a preset requirement, thereby obtaining a target model, including:

[0025] Select a sequence signal from the artifact noise training set;

[0026] In reverse order, starting from the nth signal segment in the sequence signal, the signals are sequentially input into the initial model for training, wherein when the i-th signal segment is input into the initial model, the i-1th signal segment is used as the target label to adjust the model parameters of the initial model, i=n, ​​n-1, n-3, …, 2;

[0027] After completing the training of m sequence signals, the target model is obtained.

[0028] Optionally, after completing the training of the m sequence signals, the method further includes:

[0029] Performing an artifact removal accuracy test on the trained initial model, and if the accuracy requirement is met, saving the model parameters of the initial model to obtain the target model;

[0030] If the accuracy requirement is not met, the artifact noise training set is retrieved to retrain the initial model until the artifact removal accuracy of the trained initial model meets the accuracy requirement.

[0031] In a second aspect, an embodiment of the present application provides an electroencephalogram artifact removal device, comprising:

[0032] An acquisition module, used for acquiring EEG signals containing artifact noise;

[0033] A processing module, used for inputting the collected EEG signal containing artifact noise into a target model for processing; wherein the target model is obtained by training a pre-constructed artifact noise training set, and the data in the artifact noise training set includes: a sequence signal formed after multiple iterations of artifact noise on the basis of a clean EEG signal;

[0034] The output module is used to output a clean EEG signal with artifact noise removed through the trained target model.

[0035] Optionally, the device further comprises:

[0036] A training set construction module, used to construct an artifact noise training set;

[0037] Model building module, used to build the initial model;

[0038] The training module is used to train the initial model through the artifact noise training set until the accuracy of removing artifact noise by the trained initial model reaches a preset requirement, thereby obtaining a target model.

[0039] Optionally, the training set construction module is specifically used to:

[0040] Collect raw EEG signals;

[0041] Segmenting the original EEG signal through a time window of a preset duration to obtain EEG signal segments of a preset duration;

[0042] Preprocessing the EEG signal segment of the preset time length by using a filter to obtain a preprocessed EEG signal, wherein the preprocessing includes: removing low-frequency drift noise and high-frequency noise in the EEG signal segment of the preset time length by using a bandpass filter, and removing a linear trend in the signal;

[0043] Extracting several types of artifact noises less than a preset time threshold from the original EEG signal, and combining them into an artifact noise set containing different artifact categories; wherein the artifact noises in the artifact noise set include: heartbeat artifact signal segments, eye movement artifact signal segments, and electromyography artifact signal segments;

[0044] Selecting m clean EEG signal segments from the preprocessed EEG signal; wherein m is a natural number greater than 1;

[0045] Selecting a number of artifact noises from the artifact noise set and superimposing them on a selected clean EEG signal segment to generate an EEG signal segment with artifacts;

[0046] Determine whether a preset number of iterations n is reached. If not, continue to select a number of artifact noises from the artifact noise set and superimpose them on the latest generated EEG signal segment with artifacts until the preset number of iterations n is reached, thereby forming a sequence signal containing n signal segments; wherein n is a natural number greater than 1; and m clean EEG signal segments correspond to generating m sequence signals;

[0047] An artifact noise training set is constructed based on the generated m sequence signals.

[0048] Optionally, the initial model includes: a TransUNet model.

[0049] Optionally, the training module is specifically used to:

[0050] Select a sequence signal from the artifact noise training set;

[0051] In reverse order, starting from the nth signal segment in the sequence signal, the signals are sequentially input into the initial model for training, wherein when the i-th signal segment is input into the initial model, the i-1th signal segment is used as the target label to adjust the model parameters of the initial model, i=n, ​​n-1, n-3, …, 2;

[0052] After completing the training of m sequence signals, the target model is obtained.

[0053] Optionally, the device further comprises: a verification module, configured to perform an artifact removal accuracy test on the trained initial model after completing the training of the m sequence signals, and if the accuracy requirement is met, save the model parameters of the initial model to obtain the target model;

[0054] If the accuracy requirement is not met, the initial model is retrained through the training module until the artifact removal accuracy of the trained initial model meets the accuracy requirement.

[0055] In a third aspect, an embodiment of the present application provides an electroencephalogram artifact removal device, comprising: a processor and a memory, wherein the memory stores executable program instructions, and when the processor calls the program instructions in the memory, the processor is used to:

[0056] Perform the steps of the electroencephalogram artifact removal method as described in any one of the first aspects.

[0057] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium for storing a program, which, when executed, implements the steps of the electroencephalogram artifact removal method as described in any one of the first aspects.

[0058] Compared with the prior art, the present invention has the following beneficial effects:

[0059] In the present application, an EEG signal containing artifact noise is collected; the collected EEG signal containing artifact noise is input into a target model for processing; wherein the target model is trained by a pre-constructed artifact noise training set, and the data in the artifact noise training set includes: a sequence signal formed after multiple iterations of artifact noise on the basis of a clean EEG signal; the trained target model outputs a clean EEG signal with artifact noise removed. Thus, the process of adding artifact noise can be learned, and the entire learning process does not require labels, so the time for making training samples can be reduced, and the training cost of the target model can be reduced, and the trained target model can accurately remove artifact noise, and the processing efficiency is high. BRIEF DESCRIPTION OF THE DRAWINGS

[0060] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the following will briefly introduce the drawings required for use in the embodiments or the prior art descriptions. Obviously, the drawings in the following descriptions are only embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on the provided drawings without creative work. By reading the detailed description of the non-limiting embodiments with reference to the following drawings, other features, purposes and advantages of the present invention will become more obvious:

[0061] Figure 1 A flowchart of a method for removing electroencephalogram artifacts provided in an embodiment of the present application;

[0062] Figure 2 A flowchart of another method for removing electroencephalogram artifacts provided in an embodiment of the present application;

[0063] Figure 3 A flowchart of another method for removing electroencephalogram artifacts provided in an embodiment of the present application;

[0064] Figure 4 This is a structural block diagram of an electroencephalogram artifact removal device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0065] In order to make the purpose, technical solution and advantages of the embodiments of the present application clearer, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.

[0066] It should be noted that when a component is said to be "fixed to" another component, it can be directly on the other component or there can be a central component. When a component is said to be "connected to" another component, it can be directly connected to the other component or there can be a central component at the same time.

[0067] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by those skilled in the art to which this application belongs. The terms used herein in the specification of this application are only for the purpose of describing specific embodiments and are not intended to limit this application. The term "and / or" used herein includes any and all combinations of one or more of the related listed items.

[0068] The terms "first", "second", "third", "fourth", etc. (if any) in the specification and claims of the present invention and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged where appropriate, so that the embodiments of the present invention described herein, for example, can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units that are clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.

[0069] The following specific embodiments are used to describe in detail the technical solution of the present invention and how the technical solution of the present application solves the above technical problems. The following specific embodiments can be combined with each other, and the same or similar concepts or processes may not be repeated in some embodiments.

[0070] In conjunction with the accompanying drawings, some embodiments of the present application are described in detail below. In the absence of conflict, the following embodiments and features in the embodiments can be combined with each other.

[0071] For example, Figure 1 A flowchart of a method for removing electroencephalogram artifacts provided in an embodiment of the present application is shown in FIG. Figure 1 As shown, the method in this embodiment may include the following steps:

[0072] Step S101, collecting EEG signals containing artifact noise.

[0073] In this embodiment, the EEG signal refers to an electroencephalogram signal. The EEG signal is easily interfered by non-physiological signals such as human physiological signals and spatial electromagnetic noise. Therefore, the collected EEG signal generally contains artifact noise.

[0074] Step S102: input the collected EEG signal containing artifact noise into the target model for processing.

[0075] The target model is obtained by training a pre-constructed artifact noise training set, and the data in the artifact noise training set includes: a sequence signal formed after multiple iterations of artifact noise on the basis of a clean EEG signal.

[0076] In this embodiment, an initial model may be established by using a TransUNet model, and then a target model may be obtained after training based on a pre-constructed artifact noise training set.

[0077] It should be noted that this embodiment does not limit the specific type of the model. For example, other learning models may also be used to learn artifact removal.

[0078] Step S103: The trained target model outputs a clean EEG signal with artifact noise removed.

[0079] In this embodiment, the collected original EEG signal only needs to be input into the trained target model, and a clean EEG signal can be directly obtained.

[0080] For example, the trained target model can be used in practical applications. By inputting an EEG signal with artifacts, the target model can gradually remove the noise and generate a clean EEG signal.

[0081] For example, in order to ensure the robustness and performance of the target model, loss function optimization, data enhancement and model hyperparameter tuning can also be added to the model training process. When actually applied, the obtained target model will be integrated into the real-time EEG analysis system to achieve artifact noise removal.

[0082] In this embodiment, an EEG signal containing artifact noise is collected; the collected EEG signal containing artifact noise is input into a target model for processing; wherein the target model is trained by a pre-constructed artifact noise training set, and the data in the artifact noise training set includes: a sequence signal formed after multiple iterations of artifact noise on the basis of a clean EEG signal; the trained target model outputs a clean EEG signal with artifact noise removed. Thus, the process of adding artifact noise can be learned, and the entire learning process does not require labels, so the time for making training samples can be reduced, and the training cost of the target model can be reduced, and the trained target model can accurately remove artifact noise, and the processing efficiency is high.

[0083] For example, Figure 2 A flowchart of another method for removing electroencephalogram artifacts provided in an embodiment of the present application is shown in FIG. Figure 2 As shown, the method in this embodiment may include the following steps:

[0084] Step S201, collecting EEG signals containing artifact noise.

[0085] Step S202: construct an artifact noise training set.

[0086] In an optional embodiment, an original EEG signal can be collected; the original EEG signal is segmented through a time window of a preset time length to obtain an EEG signal segment of a preset time length; a filter is used to preprocess the EEG signal segment of the preset time length to obtain a preprocessed EEG signal, wherein the preprocessing includes: removing low-frequency drift noise and high-frequency noise in the EEG signal segment of the preset time length through a bandpass filter, and removing the linear trend in the signal; extracting several types of artifact noises less than a preset time threshold from the original EEG signal, and combining them into an artifact noise set containing different artifact categories; wherein the artifact noises in the artifact noise set include: heartbeat artifact signal segments, eye movement artifact signal segments, muscle electrical artifact signal segment; selecting m clean EEG signal segments from the preprocessed EEG signal; wherein m is a natural number greater than 1; selecting a number of artifact noises from the artifact noise set, and superimposing them on a selected clean EEG signal segment to generate an EEG signal segment with artifacts; judging whether a preset number of iterations n has been reached, if not, continuing to select a number of artifact noises from the artifact noise set and superimposing them on the latest generated EEG signal segment with artifacts, until the preset number of iterations n is reached, forming a sequence signal containing n signal segments; wherein n is a natural number greater than 1; m clean EEG signal segments correspond to generating m sequence signals; constructing an artifact noise training set based on the generated m sequence signals.

[0087] Exemplarily, after collecting the original EEG signal, the EEG signal is first divided into EEG signal segments of a 4-second time window (the specific time window length is not limited in this embodiment). Further, experts extract several artifact signals less than 100ms from the collected original EEG signal. These signals are extracted separately and form an artifact signal set, which mainly includes artifact signal segments such as heartbeat artifacts, eye movement artifacts, and electromyographic artifacts. A segment of the signal (numbered 1) is selected from the m segments of EEG signals that are considered by experts to be clean and artifact-free after preprocessing, and a number of noise signals are randomly selected from the noise set formed in step 2 and superimposed on the signal to generate an EEG signal with artifacts (numbered 2). This process of superimposing noise is iterated multiple times to gradually generate more EEG signals with different noise levels until the noise level of the signal numbered n reaches a predetermined threshold, and all the artifact EEG signals generated by the segment of the EEG signal are regarded as a sequence as a whole, and a total of m sequences are generated.

[0088] Exemplarily, the initial preprocessing of the raw EEG signal includes: removing low-frequency drift and high-frequency noise by bandpass filtering (e.g., 0.5-40 Hz) to retain the main frequency band of brain activity. Removing the linear trend in the signal to eliminate slow drift during EEG recording. Subsequently, constructing an artifact noise set based on common artifact types (e.g., eye movement artifacts, muscle activity artifacts, power supply noise, etc.).

[0089] Step S203, constructing an initial model.

[0090] Step S204, training the initial model using an artifact noise training set until the accuracy of the trained initial model in removing artifact noise reaches a preset requirement, thereby obtaining a target model.

[0091] Exemplarily, a sequence signal is selected from an artifact noise training set; starting from the nth signal segment in the sequence signal, the signals are input into the initial model in reverse order for training, wherein when the i-th signal segment is input into the initial model, the model parameters of the initial model are adjusted using the i-1th signal segment as the target label, i=n, ​​n-1, n-3,…,2; after completing the training of m sequence signals, the target model is obtained.

[0092] In the present embodiment, the constructed EEG signal sequence with artifact noise is used for the initial model (such as TransUNet model), and its training process is: take a sequence EEG signal to start training each time, starting from the EEG signal numbered n of the sequence signal, the initial model uses this as input, and trains with the EEG signal numbered n-1 as the target label. The initial model uses its own output as the input of the next iteration in each step, and decrements the number of the EEG signal of the artifact noise of the sequence as a label (if the training label in the previous step is n-1, then the training label in this step is n-2), so that the initial model gradually learns how to restore the signal with artifacts to a signal closer to clean. With the advancement of training, the initial model can eventually use the clean EEG signal numbered 1 as the final output target to achieve the restoration of the artifact signal. The model eventually uses the clean EEG signal numbered 1 as a label, and then the sequence training is completed. When all m sequences are applied for training, it is considered that the model completes an epoch training. The output of the target model is the clean EEG signal after removing the artifacts.

[0093] Step S205: input the collected EEG signal containing artifact noise into the target model for processing.

[0094] Step S206: The trained target model outputs a clean EEG signal with artifact noise removed.

[0095] For the specific implementation process and technical effects of step S201, step S205 to step S206 in this embodiment, please refer to Figure 1 The descriptions of steps S101 to S103 in the illustrated embodiment are not repeated here.

[0096] For example, Figure 3 A flowchart of another method for removing electroencephalogram artifacts provided in an embodiment of the present application; Figure 3 As shown, the method in this embodiment may include the following steps:

[0097] Step S301, collecting EEG signals containing artifact noise.

[0098] Step S302: input the collected EEG signal containing artifact noise into the target model for processing.

[0099] The target model is obtained by training a pre-constructed artifact noise training set, and the data in the artifact noise training set includes: a sequence signal formed by multiple iterations of artifact noise on the basis of a clean EEG signal;

[0100] Step S303: The trained target model outputs a clean EEG signal with artifact noise removed.

[0101] For the specific implementation process and technical effects of steps S301 to S303 in this embodiment, please refer to Figure 1 The descriptions of steps S101 to S103 in the illustrated method embodiment are not repeated here.

[0102] Step S304, performing an artifact removal accuracy test on the trained initial model, and if the accuracy requirement is met, saving the model parameters of the initial model to obtain the target model.

[0103] Step S305: If the accuracy requirement is not met, the artifact noise training set is retrieved to retrain the initial model until the artifact removal accuracy of the trained initial model meets the accuracy requirement.

[0104] In this embodiment, if the artifact removal accuracy of the initial model after training reaches the requirement, the model parameters of the initial model after training are stored. If the artifact removal accuracy of the initial model after training does not reach the requirement, the training is repeated. Figure 2 The training process of step S204 is shown.

[0105] For example, Figure 4 A structural block diagram of an electroencephalogram artifact removal device provided in an embodiment of the present application is shown in FIG. Figure 4 As shown, the device in this embodiment may include: a collection module 401, a processing module 402 and an output module 403, wherein:

[0106] An acquisition module 401 is used to acquire EEG signals containing artifact noise;

[0107] The processing module 402 is used to input the collected EEG signal containing artifact noise into the target model for processing; wherein the target model is obtained by training a pre-constructed artifact noise training set, and the data in the artifact noise training set includes: a sequence signal formed after multiple iterations of artifact noise on the basis of a clean EEG signal;

[0108] The output module 403 is used to output a clean EEG signal with artifact noise removed through the trained target model.

[0109] Exemplarily, the above device further includes:

[0110] A training set construction module 404 is used to construct an artifact noise training set;

[0111] A model building module 405 is used to build an initial model;

[0112] The training module 406 is used to train the initial model using an artifact noise training set until the accuracy of the trained initial model in removing artifact noise reaches a preset requirement, thereby obtaining a target model.

[0113] Optionally, the training set construction module 404 is specifically used to: collect original EEG signals; segment the original EEG signals through time windows of preset duration to obtain EEG signal segments of preset duration; use filters to preprocess the EEG signal segments of preset duration to obtain preprocessed EEG signals, wherein the preprocessing includes: removing low-frequency drift noise and high-frequency noise in the EEG signal segments of preset duration through bandpass filters, and removing linear trends in the signals; extracting several types of artifact noises less than a preset time threshold from the preprocessed EEG signals, and combining them into an artifact noise set containing different artifact categories; wherein the artifact noises in the artifact noise set include: heartbeat artifact signal segments, eye movement artifact segments, Artifact signal segment, electromyography artifact signal segment; select m clean EEG signal segments from the preprocessed EEG signal; wherein m is a natural number greater than 1; select a number of artifact noises from the artifact noise set, and superimpose them on a selected clean EEG signal segment to generate an EEG signal segment with artifacts; determine whether a preset number of iterations n has been reached, if not, continue to select a number of artifact noises from the artifact noise set and superimpose them on the latest generated EEG signal segment with artifacts, until the preset number of iterations n is reached, to form a sequence signal containing n signal segments; wherein n is a natural number greater than 1; m clean EEG signal segments correspond to generating m sequence signals; construct an artifact noise training set based on the generated m sequence signals.

[0114] Exemplarily, the initial model includes: a TransUNet model.

[0115] Exemplarily, the training module 406 is specifically used to: select a sequence signal from an artifact noise training set; start from the nth signal segment in the sequence signal and input them into the initial model in reverse order for training, wherein when the i-th signal segment is input into the initial model, the model parameters of the initial model are adjusted using the i-1th signal segment as the target label, i=n, ​​n-1, n-3,…,2; after completing the training of m sequence signals, the target model is obtained.

[0116] Exemplarily, the device also includes: a verification module 407, which is used to: after completing the training of m sequence signals, perform an artifact removal accuracy test on the trained initial model; if the accuracy requirement is met, save the model parameters of the initial model to obtain the target model; if the accuracy requirement is not met, re-train the initial model through the training module 406 until the artifact removal accuracy of the trained initial model meets the accuracy requirement.

[0117] An embodiment of the present application provides an electroencephalogram (EEG) artifact removal device (system), comprising: a processor and a memory, wherein the memory stores executable program instructions, and when the processor calls the program instructions in the memory, the processor is used to: execute the steps of the EEG artifact removal method in the above-mentioned embodiments.

[0118] It should be noted that those skilled in the art will appreciate that various aspects of the present invention may be implemented as systems, methods or program products. Therefore, various aspects of the present invention may be specifically implemented in the following forms, namely: complete hardware implementation, complete software implementation (including firmware, microcode, etc.), or a combination of hardware and software, which may be collectively referred to as "circuit", "module" or "platform" herein.

[0119] In addition, an embodiment of the present application further provides a computer-readable storage medium, in which computer-executable instructions are stored. When at least one processor of a user device executes the computer-executable instructions, the user device executes the above-mentioned various possible methods. Among them, the computer-readable medium includes a computer storage medium and a communication medium, wherein the communication medium includes any medium that facilitates the transmission of a computer program from one place to another. The storage medium can be any available medium that can be accessed by a general-purpose or special-purpose computer. An exemplary storage medium is coupled to a processor so that the processor can read information from the storage medium and write information to the storage medium. Of course, the storage medium can also be a component of the processor. The processor and the storage medium can be located in an ASIC. In addition, the ASIC can be located in a user device. Of course, the processor and the storage medium can also exist in a communication device as discrete components.

[0120] The present application also provides a program product, which includes a computer program. The computer program is stored in a readable storage medium. At least one processor of the server can read the computer program from the readable storage medium. At least one processor executes the computer program so that the server implements any method of the above-mentioned embodiments of the present invention.

[0121] The program product may use any combination of one or more readable media. The readable medium may be a readable signal medium or a readable storage medium. The readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples of readable storage media (a non-exhaustive list) include: an electrical connection with one or more wires, a portable disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above.

[0122] The above describes the specific embodiments of the present invention. It should be understood that the present invention is not limited to the above specific embodiments, and those skilled in the art may make various modifications or variations within the scope of the claims, which do not affect the essence of the present invention.

Claims

1. A method for removing electroencephalogram artifacts, characterized in that: include: Collect EEG signals containing artifact noise; Inputting the collected EEG signal containing artifact noise into the target model for processing; wherein the target model is trained by a pre-constructed artifact noise training set, and the data in the artifact noise training set includes: a sequence signal formed by multiple iterations of artifact noise on the basis of a clean EEG signal; The trained target model outputs a clean EEG signal with artifact noise removed.

2. The method for removing electroencephalogram artifacts according to claim 1, characterized in that: Before inputting the collected EEG signal containing artifact noise into the target model for processing, the method further includes: Construct an artifact noise training set; Build an initial model; The initial model is trained using an artifact noise training set until the accuracy of the trained initial model in removing artifact noise reaches a preset requirement, thereby obtaining a target model.

3. The method for removing electroencephalogram artifacts according to claim 2, characterized in that: The constructing of the artifact noise training set comprises: Collect raw EEG signals; Segmenting the original EEG signal through a time window of a preset duration to obtain EEG signal segments of a preset duration; Preprocessing the EEG signal segment of the preset time length by using a filter to obtain a preprocessed EEG signal, wherein the preprocessing includes: removing low-frequency drift noise and high-frequency noise in the EEG signal segment of the preset time length by using a bandpass filter, and removing a linear trend in the signal; Extracting several types of artifact noises less than a preset time threshold from the original EEG signal, and combining them into an artifact noise set containing different artifact categories; wherein the artifact noises in the artifact noise set include: heartbeat artifact signal segments, eye movement artifact signal segments, and electromyography artifact signal segments; Selecting m clean EEG signal segments from the preprocessed EEG signal; wherein m is a natural number greater than 1; Selecting a number of artifact noises from the artifact noise set and superimposing them on a selected clean EEG signal segment to generate an EEG signal segment with artifacts; Determine whether a preset number of iterations n is reached. If not, continue to select a number of artifact noises from the artifact noise set and superimpose them on the latest generated EEG signal segment with artifacts until the preset number of iterations n is reached, thereby forming a sequence signal containing n signal segments; wherein n is a natural number greater than 1; and m clean EEG signal segments correspond to generating m sequence signals; An artifact noise training set is constructed based on the generated m sequence signals.

4. The method for removing electroencephalogram artifacts according to claim 2, characterized in that: The initial model includes: a TransUNet model.

5. The method for removing electroencephalogram artifacts according to claim 3, characterized in that: The initial model is trained by using the artifact noise training set until the accuracy of removing artifact noise by the trained initial model reaches a preset requirement, thereby obtaining a target model, including: Select a sequence signal from the artifact noise training set; In reverse order, starting from the nth signal segment in the sequence signal, the signals are sequentially input into the initial model for training, wherein when the i-th signal segment is input into the initial model, the i-1th signal segment is used as the target label to adjust the model parameters of the initial model, i=n, ​​n-1, n-3, …, 2; After completing the training of m sequence signals, the target model is obtained.

6. The method for removing electroencephalogram artifacts according to claim 5, characterized in that: After completing the training of the m sequence signals, the method further includes: Performing an artifact removal accuracy test on the trained initial model, and if the accuracy requirement is met, saving the model parameters of the initial model to obtain the target model; If the accuracy requirement is not met, the artifact noise training set is retrieved to retrain the initial model until the artifact removal accuracy of the trained initial model meets the accuracy requirement.

7. An electroencephalogram artifact removal device, characterized in that: include: An acquisition module, used for acquiring EEG signals containing artifact noise; A processing module, used for inputting the collected EEG signal containing artifact noise into a target model for processing; wherein the target model is obtained by training a pre-constructed artifact noise training set, and the data in the artifact noise training set includes: a sequence signal formed after multiple iterations of artifact noise on the basis of a clean EEG signal; The output module is used to output a clean EEG signal with artifact noise removed through the trained target model.

8. The electroencephalogram artifact removal device according to claim 7, characterized in that: The device also includes: A training set construction module, used to construct an artifact noise training set; Model building module, used to build the initial model; The training module is used to train the initial model through the artifact noise training set until the accuracy of removing artifact noise by the trained initial model reaches a preset requirement, thereby obtaining a target model.

9. An electroencephalogram artifact removal device, characterized in that: include: A processor and a memory, wherein the memory stores executable program instructions, and when the processor calls the program instructions in the memory, the processor is used to: Execute the steps of the method for removing electroencephalogram artifacts as described in any one of claims 1 to 6.

10. A computer-readable storage medium for storing a program, characterized in that: When the program is executed, the steps of the electroencephalogram artifact removal method according to any one of claims 1 to 6 are implemented.

Citation Information

Cited By

  • Method and system for removing artifacts of mixed signal, terminal and storage medium

    CN120859516A