Method for obtaining preset window number threshold value

By classifying missed detection results and combining the number of false alarms and correct warnings in the time-domain data monitoring system, the optimal window number threshold is obtained, which solves the problem of inaccurate monitoring results caused by unreasonable threshold settings and achieves higher monitoring accuracy and robustness.

CN115295138BActive Publication Date: 2026-02-10NEURACLE TECHNOLOGY (SHANGHAI) CO LTD
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202210748899.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-05-09
Publication Date
2026-02-10
Estimated Expiration
2042-05-09

AI Technical Summary

Technical Problem

In existing technologies, the threshold settings of time-domain data monitoring systems are unreasonable, resulting in inaccurate monitoring results, failure to detect problems in a timely manner, or an increase in the probability of false alarms. They also fail to effectively distinguish between missed detections and false alarms.

Method used

A method for obtaining a preset window number threshold is provided. By classifying the missed detection results and combining the number of false alarms and the number of correct warnings, the optimal window number threshold is selected to improve the performance and accuracy of the stimulation system.

Benefits of technology

By selecting appropriate preset window number thresholds, the sensitivity and specificity of the stimulation system are improved, ensuring the accuracy and robustness of monitoring results, and making it suitable for different clinical application scenarios.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115295138B_ABST
    Figure CN115295138B_ABST
Patent Text Reader

Abstract

The application discloses a preset window number threshold acquisition method. The preset window number threshold is acquired based on a missed detection result classification. When the missed detection result is determined as no missed detection, a turning point of a change rate of false alarm times decreasing with the increase of the window number or a minimum point of the false alarm times is selected to acquire a first window number threshold; and / or a window number corresponding to the maximum correct early warning times is taken as a second window number threshold; when the missed detection result is determined as missed detection, window numbers corresponding to different missed detection times are acquired; window numbers corresponding to different false alarm times are acquired; window numbers corresponding to different correct early warning times are acquired; and an overlapping area of any two or all of the window numbers is selected as a third window number threshold. The application combines missed detection, false alarm and correct early warning to obtain a corresponding optimal preset window number threshold, different preset window number thresholds can be selected according to different situations, and thus a better stimulation effect is realized.
Need to check novelty before this filing date? Find Prior Art

Description

[0001] This application is a divisional application of Chinese patent application No. 2022104959727, filed on May 9, 2022, entitled "System Regulation Method and Closed-Loop Stimulation System Based on Offline Signal Detection Results". Technical Field

[0002] This invention relates to the field of signal processing technology, and in particular to a method for obtaining a preset window number threshold. Background Technology

[0003] During the normal operation of monitoring equipment, its performance is closely related to the parameter thresholds set by the equipment itself. If the parameter thresholds are set improperly, the monitoring results may be inaccurate, and staff may be unable to detect problems in a timely manner or take appropriate measures.

[0004] For example, taking a time-domain data monitoring system as an example, such a system can monitor changes in time-domain data in real time and promptly detect potential risks. However, the effectiveness of time-domain data signal monitoring mainly relies on thresholds set by the user in advance. When the number of abnormal times in time-domain data exceeds the threshold, the system can issue an alarm. However, if the threshold is set too high, although it can reduce the number of false alarms, it increases the probability of missed detections; if the threshold is set too low, although it is less likely to miss detections, it will increase the probability of false alarms. Summary of the Invention

[0005] The present invention aims to solve at least one of the technical problems existing in the prior art.

[0006] Therefore, the present invention provides a method for obtaining a preset window number threshold, which can assist users in making better parameter adjustments and improve the performance of the stimulation system.

[0007] Firstly, the technical solution adopted by this invention to solve its technical problem is: a method for obtaining a preset window number threshold, comprising: obtaining the preset window number threshold based on the classification of missed detection results, i.e.

[0008] When the missed detection result is determined to be no missed detection, the method for obtaining the preset window number threshold includes:

[0009] The base number of windows is the number of windows that do not miss any detections;

[0010] Select the inflection point or the lowest point of the rate at which the number of false alarms decreases with increasing window number to obtain the first window number threshold; and / or

[0011] The number of windows corresponding to the maximum number of correct warnings is used as the threshold for the second window number.

[0012] When a missed detection result indicates a missed detection, the method for obtaining the preset window number threshold includes:

[0013] Obtain the number of windows corresponding to different numbers of missed detections;

[0014] Obtain the number of windows corresponding to different false alarm counts;

[0015] Obtain the number of windows corresponding to different numbers of correct alerts;

[0016] Select any two or all of the overlapping areas of the above window numbers as the threshold for the third window number;

[0017] The preset window number threshold is any one of the first window number threshold, the second window number threshold, and the third window number threshold.

[0018] Furthermore, by combining the number of no missed detections, the number of false alarms, and the number of correct warnings, the optimal window number threshold is obtained as the second window number threshold.

[0019] Furthermore, the detection criteria for the missed detection results include: if the early warning algorithm outputs an early warning at least once within a preset time period, it is determined that there is no missed detection; otherwise, it is determined that there is a missed detection.

[0020] The detection criteria for false alarms include: if the warning algorithm outputs a warning within a preset time period before and after the onset period, it is determined to be a false alarm;

[0021] The detection criteria for a correct early warning include: if the early warning algorithm outputs an early warning within a preset time period, it is determined to be a correct early warning.

[0022] Furthermore, the method for obtaining the preset window number threshold combines the number of missed detections, the number of false alarms, and the number of correct warnings to cover a variety of clinical application scenarios.

[0023] Furthermore, the combination of missed detections and false alarms: the two indicators, missed detections and false alarms, show opposite performance trends with the window number threshold, and are used for parameter tuning throughout the patient's process;

[0024] Based on the principle of not missing any detections, the third window threshold of 12 is automatically calculated by combining the number of missed detections and the number of false alarms. This is used for patients with severe conditions or in the early stages of intervention.

[0025] Based on the principle of balancing missed detections and false alarms, the third window threshold of 14 is automatically calculated by combining the number of missed detections and false alarms, and is used for patients with good prognoses.

[0026] Furthermore, the combination of missed detections and correct alerts: the performance trends of both missed detections and correct alerts are the same with the window number threshold, which can be used for parameter tuning in the early stages of patient intervention;

[0027] Based on the principle of balancing missed detections and correct early warnings, the threshold for the third window number is automatically calculated by combining the number of missed detections and the number of correct early warnings, and is set to 5.

[0028] Furthermore, a combination of false alarm count and correct warning count: the two indicators, false alarm count and correct warning count, show opposite performance trends with the window number threshold, and are used for parameter tuning for non-severe patients;

[0029] Based on the principle of prioritizing the suppression of false alarms, the threshold for the third window number is automatically calculated by combining the number of false alarms and the number of correct warnings, and is set to 19.

[0030] Based on the principle of requiring more correct early warnings, the threshold for the third window number is automatically calculated by combining the number of false alarms and the number of correct early warnings, and is set to 6.

[0031] Furthermore, the combination of missed detections, false alarms, and correct alerts: based on the principle of balancing missed detections, false alarms, and correct alerts, the decision on whether to accept missed detections and whether more correct alerts are needed is determined according to the severity of the patient's condition, for use in parameter tuning for a wider range of patients throughout the process;

[0032] The number of missed detections, false alarms, and correct warnings are combined to automatically calculate the third window threshold of 12, which is used to adjust the tolerance for false alarms as the regulatory intervention progresses.

[0033] Furthermore, the preset duration may include recorded values ​​or calculated values;

[0034] Methods for obtaining numerical values ​​include:

[0035] The preset duration is set to a period of time before the onset time. The number of warnings output by the warning algorithm for the current subject within the alternative time period before the onset time is counted.

[0036] If the number of warnings is greater than or equal to the warning number threshold, then a sliding window is used for the candidate time period to calculate the warning density for each window;

[0037] If the warning density of the window is greater than or equal to the warning density threshold, the preset duration is equal to the difference between the time of onset and the start time of the window, which is the calculated value.

[0038] If the number of warnings is less than the warning number threshold, the preset duration is equal to the difference between the time of the outbreak and the time of the most recent warning, which is the calculated value.

[0039] The beneficial effects of this invention are that it selects a suitable preset window number threshold based on missed detection results, false alarm results, and correct warning results. Different preset window number thresholds can be applied to different usage scenarios, thereby improving the stimulation sensitivity and specificity of the stimulation system, making the stimulation system's performance both accurate and robust. This invention is simple to operate, easy for users to understand, and has high market value. Attached Figure Description

[0040] The present invention will be further described below with reference to the accompanying drawings and embodiments.

[0041] Figure 1 This is a flowchart of the stimulation system modulation method based on offline signal detection results of the present invention.

[0042] Figure 2 This is a schematic diagram of the interictal period and preictal period of the present invention.

[0043] Figure 3 This is the first scenario of the method for obtaining the preset duration calculation value of the present invention.

[0044] Figure 4 This is the second scenario of the method for obtaining the preset duration calculation value of the present invention.

[0045] Figure 5 This is a schematic diagram illustrating the changes in the window number threshold, preset duration, and number of missed detections in this invention.

[0046] Figure 6 This is a schematic diagram illustrating the changes in the window number threshold, preset duration, and number of false alarms of the present invention.

[0047] Figure 7 This is a schematic diagram illustrating the changes in the window number threshold, preset duration, and number of correct warnings according to the present invention.

[0048] Figure 8 This is a curve showing the change in the number of missed detections and the number of false alarms per hour as a function of the window number threshold.

[0049] Figure 9 This is a curve showing the change of the number of missed detections and the number of correct early warnings as a function of the window number threshold in this invention.

[0050] Figure 10 This is a curve showing the change in the number of correct early warnings and the number of false alarms per hour as a function of the window number threshold.

[0051] Figure 11 This is a curve showing the changes in the number of missed detections, the number of correct early warnings, and the number of false alarms per hour as a function of the window number threshold.

[0052] Figure 12 This is a flowchart of the method for establishing a regulation model according to the present invention. Detailed Implementation

[0053] The present invention will now be described in further detail with reference to the accompanying drawings. These drawings are simplified schematic diagrams, illustrating only the basic structure of the invention, and therefore only show the components relevant to the invention.

[0054] In the description of this invention, it should be understood that the terms "center," "longitudinal," "lateral," "length," "width," "thickness," "upper," "lower," "front," "rear," "left," "right," "vertical," "horizontal," "top," "bottom," "inner," "outer," "clockwise," "counterclockwise," "axial," "radial," and "circumferential," etc., indicating orientation or positional relationships, are based on the orientation or positional relationships shown in the accompanying drawings and are only for the convenience of describing the invention and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation, and therefore should not be construed as a limitation of the invention. Furthermore, features defined with "first" or "second" may explicitly or implicitly include one or more of that feature. In the description of this invention, unless otherwise stated, "a plurality of" means two or more.

[0055] In the description of this invention, it should be noted that, unless otherwise explicitly specified and limited, the terms "installation," "connection," and "linking" should be interpreted broadly. For example, they can refer to a fixed connection, a detachable connection, or an integral connection; they can refer to a mechanical connection or an electrical connection; they can refer to a direct connection or an indirect connection through an intermediate medium; and they can refer to the internal connection of two components. Those skilled in the art can understand the specific meaning of the above terms in this invention based on the specific circumstances.

[0056] like Figures 1 to 2 As shown, the stimulation system regulation method based on offline signal detection results of the present invention mainly includes the following steps: S1, detecting offline data of the signal to obtain detection results corresponding to different preset durations and preset window numbers, including missed detection results, false alarm results, and / or correct warning results; S2, classifying the missed detection results, and filtering out the corresponding preset durations and preset window numbers according to the false alarm results and / or correct warning results as setting parameters; S3, establishing a regulation model based on the setting parameters to regulate the stimulation system.

[0057] The control method of this invention combines missed detection results, false alarm results, and / or correct warning results from the detection results to adjust the parameters of the stimulation system. The control method is designed from both sensitivity and specificity perspectives, achieving both stimulation accuracy and robustness. For closed-loop stimulation systems targeting neurological disorders such as epilepsy, missed detection is the most critical performance indicator. Taking the most severe absence epilepsy as an example, patients experience symptoms such as impaired consciousness and generalized convulsions during seizures, and in severe cases, complete loss of consciousness. If the patient is in an unsafe state (such as walking on the road or driving a motor vehicle), the tolerance for missed detection is extremely low, even unacceptable. However, for patients with milder symptoms or good prognoses, the tolerance for missed detection can be appropriately increased in exchange for suppressing false positives. Therefore, this invention is a control method designed based on missed detection results. It can be matched with the type of disease or the symptoms of epilepsy, first classifying according to missed detection requirements, and then adjusting parameters accordingly, resulting in stronger accuracy and systematicity in parameter adjustment.

[0058] In step S1, the signal can be an electroencephalogram (EEG) signal. Offline data refers to historical data of the subject's EEG signals that have already been collected. EEG signals are generally time-domain data, such as a sequence of voltage values ​​and time, where the voltage values ​​change over time. Offline data can include normal EEG data and pre-seizure data. Experts can label the offline data into normal EEG data and pre-seizure data. After acquiring the offline data, it can be preprocessed (e.g., noise reduction, downsampling) to improve the signal-to-noise ratio and reduce the number of samples. The preprocessed offline data is then divided into multiple task windows, with some windows overlapping and others not overlapping. Offline data is processed to obtain multiple normal EEG signal data segments and multiple pre-onset EEG signal data segments. The zero-crossing coefficients of each normal EEG signal data segment are calculated, resulting in a normal zero-crossing coefficient group. Similarly, the zero-crossing coefficients of each pre-onset EEG signal data segment are calculated, resulting in a pre-onset zero-crossing coefficient group. The normal and pre-onset zero-crossing coefficient groups form a first zero-crossing coefficient set. A classifier is trained using this first zero-crossing coefficient set to obtain a first classification model. Next, real-time EEG signal data of the target object is collected and processed to obtain a real-time EEG signal dataset. This real-time dataset is then divided into multiple windows to obtain multiple real-time EEG signal data segments. The zero-crossing coefficients of each real-time EEG signal data segment are calculated, resulting in a second zero-crossing coefficient set. The zero-crossing coefficients from the second set are input into the first classification model to obtain the classification result for each real-time EEG signal data segment, thus achieving the classification of the EEG data. The classification results include normal and pre-onset categories. The zero-crossing coefficients used here are mappings of the zero-crossing rate or the number of zero-crossings. These mappings are performed using mapping functions with positive or negative correlations, and these functions can be linear or non-linear, to reflect the frequency of zero-crossings of data values ​​within a segment of EEG data. For example, the formula for calculating the zero-crossing coefficients is: Where N represents the number of points in the data segment to be processed, x(1:N-1) represents the array of the first N-1 points in the data segment, and x(2:N) represents the array of the last N-1 points in the data segment. This indicates a point-to-point multiplication between two arrays. This represents the ratio of the result of point-to-point multiplication to being less than 0, i.e., the zero-crossing rate; then through... The zero-crossing rate is mapped to a zero-crossing coefficient ranging from 0 to 1. For details on the offline data processing, please refer to patent publication number CN114010207A. When using the first classification model to classify and detect real-time EEG signals, a judgment threshold (i.e., a preset window number) needs to be set. For example, if M consecutive segments (each segment can be considered a window) in the real-time EEG signal are judged by the classifier to be pre-seizure, the subject is likely in the pre-seizure stage and requires stimulation therapy. M is the judgment threshold. The value of M will have different effects on the warning judgment result; therefore, the preset window number needs to be selected according to different situations.

[0059] Specifically, the preset window number includes a preset window number threshold or an abnormal window percentage threshold. It can be understood that when the warning algorithm classifies real-time EEG signals, it can divide the raw EEG signals into windows. Each window can obtain a data segment. The warning algorithm can obtain two results: 0 - interictal period (no warning) and 1 - preictal period (warning). That is, each data segment can obtain a corresponding classification result. In this case, when determining whether to implement stimulation, it can be determined by either the preset window number threshold or the abnormal window percentage threshold. For example, if M consecutive data segments are classified as "1" within a certain period, then stimulation is initiated, i.e., the preset window number threshold is M; or, if the proportion of data segments classified as "1" exceeds N% within a certain period, then stimulation is initiated, i.e., the abnormal window percentage threshold is N%. Therefore, the preset window number threshold or its abnormal window percentage threshold within a certain preset time period can also be used as a trigger condition for initiating stimulation.

[0060] It should be noted that in this case, the detection criteria for missed detections include: if the warning algorithm outputs a warning at least once within a preset time period, it is considered a successful detection; otherwise, it is considered a missed detection. The detection criteria for false alarms include: if the warning algorithm outputs a warning before and after the preset time period, it is considered a false alarm. The detection criteria for correct warnings include: if the warning algorithm outputs a warning within a preset time period, it is considered a correct warning.

[0061] Specifically, the preset duration can include recorded values ​​or calculated values. Recorded values ​​are the average duration of the pre-ictal period in history. For example, the duration of multiple interictal periods during previous episodes of the subject's illness can be collected, and the average of these interictal periods can be used as the preset duration. Calculated values ​​are obtained by: setting the preset duration to a period preceding the onset time; counting the number of warnings output by the warning algorithm within the candidate time period preceding the onset time for the current subject; if the number of warnings is greater than or equal to a warning frequency threshold, then a sliding window is applied to the candidate time period, and the warning density of each window is calculated; if the warning density of the window is greater than or equal to a warning density threshold, then the preset duration is equal to the difference between the onset time and the start time of that window, which is the calculated value; if the number of warnings is less than the warning frequency threshold, then the preset duration is equal to the difference between the onset time and the most recent warning time preceding the onset time, which is the calculated value.

[0062] Specifically, the seizure times in the offline data have been labeled by experts. When obtaining the calculated values, a candidate time period needs to be selected first. This candidate time period can be a period preceding the subject's seizure time, such as the time between the last seizure and the current seizure. The specific length of the candidate time period can be chosen by experts based on experience, and the length of the candidate time period must be greater than the preset duration. The warning algorithm can process and analyze the EEG data within the candidate time period, outputting a warning result (warning or no warning), and counting the number of warnings Z within that candidate time period. The calculation of the preset duration can be divided into the following two scenarios:

[0063] For the first option, please refer to... Figure 3 If the number of warnings Z is greater than or equal to the warning number threshold Z0, it indicates that the number of warnings output by the warning algorithm is densely distributed within the candidate time period. In this case, it is necessary to perform sliding window processing on the candidate time period and calculate the warning density Z of each window. m Early warning density Z m = Number of warnings per window ÷ Window width. If the warning density Z of a certain window... m Greater than or equal to the warning density threshold Z m0 If the number of warnings within the window is relatively high, it can be considered as being in the pre-attack phase. In this case, the preset duration = attack time - window start time. For example, if the attack time is t0 and the window width is t1 to t2, then the preset duration = t0 - t1. In other words, the above judgment process can eliminate some false alarms and improve the accuracy of the stimulus.

[0064] The second option, please refer to Figure 4If the number of warnings Z is less than the warning number threshold Z0, it indicates that the number of warnings output by the warning algorithm within the candidate time period is relatively scattered. In this case, the warning closest to the onset time is considered a correct warning, and the preset duration is equal to the onset time minus the time of the most recent warning. For example, if the onset time is t0 and the time of the most recent warning is t3, then the preset duration = t0 - t3.

[0065] If the current subject has multiple episodes, then the preset duration is the average of all preset durations.

[0066] It should be noted that, based on the missed detection results, the method for obtaining the preset window number threshold can be divided into two cases:

[0067] The first method, when the missed detection result is no missed detection, is to obtain the preset window number threshold by: using the window number corresponding to no missed detection as the base window; selecting the inflection point of the rate of change of the number of false alarms decreasing as the number of windows increases or the lowest point of the number of false alarms to obtain the first window number threshold; and / or using the window number corresponding to the maximum number of correct warnings as the second window number threshold.

[0068] For details, please refer to Figure 5 , Figure 5 The horizontal axis represents the window number threshold, the left vertical axis represents the preset duration (in minutes), and the right vertical axis represents the number of missed detections. Figure 5 It can be observed that when the preset duration is greater than or equal to 2 minutes and the window number threshold range R1 is 1–16, the result is no missed detections. In this case, the base window size is 1–16. Please refer to [the documentation / reference]. Figure 6 The horizontal axis of the graph represents the window number threshold, the left vertical axis represents the preset duration, and the right vertical axis represents the number of false alarms. Figure 6 As can be seen, the number of false alarms gradually decreases with the increase of the window number threshold. Furthermore, the rate of decrease is relatively fast within the window number threshold range of 1-7, while the rate of decrease slows down within the window number threshold range of 7-16. This means that window number threshold 7 is the inflection point where the rate of decrease in the number of false alarms with increasing window number is at its lowest point, which is at window number threshold 15 or 16. Therefore, the first window number threshold can be 7, 15, or 16. Please refer to [reference needed]. Figure 7 , Figure 7 The horizontal axis represents the window number threshold, the left vertical axis represents the preset duration, and the right vertical axis represents the number of correct warnings. Figure 7 It can be observed that the number of correct alerts corresponds to different thresholds for different window sizes. For example, in... Figure 7 In this context, a window number threshold of 9 corresponds to the highest number of correct alerts. In other words, setting the window number threshold to 9 results in the highest alert accuracy, meaning the second window number threshold can be 9. Furthermore, in... Figure 7In this example, when the window count threshold is 9, the number of correct alerts within the preset duration of 19-30 minutes exceeds 50. Therefore, the choice of preset duration is also related to the number of correct alerts. It should be noted that... Figures 5 to 7 This is merely an illustrative example. Assuming no missed detections, the preset window number threshold can be either a first window number threshold or a second window number threshold, which can be categorized into three cases. The first case combines the optimal window number threshold obtained by ensuring no missed detections and the number of false alarms as the first window number threshold. The second case combines the optimal window number threshold obtained by combining the optimal window number ...

[0069] The second method, when the missed detection result is a missed detection, is to obtain the preset window number threshold by: obtaining the window number corresponding to different missed detection times, obtaining the window number corresponding to different false alarm times, obtaining the window number corresponding to different correct warning times, and selecting any two or all of the above window numbers as the third window number threshold.

[0070] For details, please refer to Figure 8 The horizontal axis represents the window size threshold, and the vertical axis represents the number of false alarms and missed detections per hour. The graph shows the number of missed detections and the number of false alarms per hour (*). As can be seen from the graph, when the window number threshold is greater than or equal to 14, the number of missed detections increases with the increase of the window number threshold; the number of false alarms per hour gradually decreases with the increase of the window number threshold, and when the window number threshold is greater than or equal to 12, the decrease in the number of false alarms per hour tends to level off. It can be understood that a lower number of false alarms per hour indicates a higher warning accuracy. Figure 8In this context, if the premise is "no missed detections," then the optimal window size threshold is 12, which minimizes the number of false alarms per hour. If the premise is to balance the number of missed detections and false alarms, then the optimal window size threshold is 14, which is the overlapping area of ​​the missed detection curve and the hourly false alarm curve (i.e., the intersection of the two curves). In practical applications, for patients with severe conditions (such as those experiencing absence seizures), a missed detection could lead to missed treatment opportunities and irreversible harm. In this case, the window size threshold prioritizing no missed detections should be selected. For patients with milder conditions or those whose conditions have improved after treatment, to prevent false stimulation (i.e., false positives, false alarms), a very small number of missed detections can be tolerated. In this case, the window size threshold prioritizing a balance between the number of missed detections and false alarms can be selected.

[0071] Please refer to Figure 9 The horizontal axis represents the window number threshold, and the vertical axis represents the number of correct alerts and the number of missed alerts. This indicates the number of missed detections, with "+" indicating the number of correct alerts. Figure 9 As can be seen from this, the threshold for the maximum number of windows with the most correct warnings is 5. This means that the fewer the number of missed detections and the more correct warnings, the better the performance of the warning algorithm. Therefore, based on... Figure 9 For example, when the window number threshold is less than or equal to 10, the early warning algorithm does not miss any detections. Within this range, the window number threshold of 5 results in the highest number of correct early warnings. In other words, a window number threshold of 5 is the optimal window number threshold that can balance the number of missed detections and the number of positive early warnings.

[0072] Please refer to Figure 10 The horizontal axis represents the window number threshold, and the vertical axis represents the number of correct alerts and the number of false alarms per hour. "*" indicates the number of false alarms per hour, and "+" indicates the number of correct alerts. Figure 10 In this model, the number of correct alerts decreases as the window number threshold increases, as does the number of false alarms per hour. Furthermore, the rate of decrease for both approaches slows down after the window number threshold exceeds 15. Therefore, under specific requirements, the optimal window number threshold can be automatically calculated by combining the number of correct alerts and the number of false alarms per hour. For example, prioritizing the suppression of false alarms, a larger window number threshold results in fewer false alarms, but also a decrease in the number of correct alerts. In this case, prioritizing the suppression of false alarms while ensuring the number of correct alerts is not zero, the optimal window number threshold could be 19. Conversely, if the goal is to require more correct alerts and tolerate a higher number of false alarms, then the optimal window number threshold could be 6.

[0073] Please refer to Figure 11The horizontal axis represents the window number threshold, and the vertical axis represents the number of correct alerts, the number of false alarms per hour, and the number of missed detections. "+" indicates the number of correct alerts, and "*" indicates the number of false alarms per hour. This indicates the number of missed detections. For example, to achieve a balance between missed detections, false alarms, and correct alerts, the number of false alarms should be low, the number of correct alerts should be high, and the number of missed detections should be low. Figure 11 In this study, a window number threshold of 11-14 is a viable range. However, when the window number threshold is 13, the number of missed detections exceeds the number of correct alerts, so 13 can be ruled out. Similarly, when the window number threshold is 11, the number of false alarms remains high, so 11 can also be ruled out. Compared to window number thresholds of 12 and 14, a window number threshold of 12 results in zero missed detections and a higher number of correct alerts. Considering all factors, the optimal window number threshold is 12.

[0074] In other words, the above embodiments illustrate how to select the optimal window number threshold under different requirements. For example, based on the principle of avoiding missed detections, the third window number threshold of 12 can be automatically calculated by combining the number of missed detections and the number of false alarms; based on the principle of balancing missed detections and false alarms, the third window number threshold of 14 can be automatically calculated by combining the number of missed detections and the number of false alarms; based on the principle of balancing missed detections and correct warnings, the third window number threshold of 5 can be automatically calculated by combining the number of missed detections and the number of correct warnings; based on the principle of prioritizing the suppression of false alarms, the third window number threshold of 19 can be automatically calculated by combining the number of false alarms and the number of correct warnings; based on the principle of requiring more correct warnings, the third window number threshold of 6 can be automatically calculated by combining the number of false alarms and the number of correct warnings; and based on the principle of balancing all three, the third window number threshold of 12 can be automatically calculated by combining the number of missed detections, the number of false alarms, and the number of correct warnings.

[0075] Unlike the first and second window number thresholds, the third window number threshold does not mandate that there should be no missed detections. Instead, it combines the number of missed detections, the number of false alarms, and the number of correct warnings into four scenarios to create a more flexible control mechanism that can cover more clinical application scenarios.

[0076] 1) Combination of missed detections and false alarms: These two metrics show opposite trends in performance with the window number threshold; that is, the larger the window number threshold, the more missed detections (worse performance) and the fewer false alarms (better performance). For patients with severe conditions or in the early stages of intervention, prioritizing no missed detections is preferable, thus a smaller window number threshold of 12 is chosen. For patients with good prognoses, prioritizing the suppression of false alarms and increasing tolerance for missed detections is preferable, thus a larger window number threshold of 14 is chosen. This embodiment is applicable to the entire parameter tuning process for patients.

[0077] 2) Combination of missed detections and correct alerts: These two metrics show the same performance trend with the window number threshold, i.e., the smaller the window number threshold, the fewer missed detections (better performance) and the more correct alerts (better performance). This embodiment provides relatively limited parameter tuning information to users. It can only select a window number threshold of 5 corresponding to a higher number of correct alerts after determining whether a missed detection has occurred. It cannot adjust the tolerance for false alarms as the intervention progresses, making it suitable for parameter tuning in the initial stages of patient intervention.

[0078] 3) Combination of false alarm count and correct alert count: These two metrics show opposite performance trends with the window number threshold; that is, the smaller the window number threshold, the more correct alerts (better performance) and the more false alarms (worse performance). This embodiment cannot provide information on missed detections and can only favor one of the correct alert count and false alarm count based on the actual situation (e.g., Figure 10 For optimal early warning performance, select 6; for optimal false alarm suppression performance, select 19, or a balance between the two. This is suitable for parameter adjustment for non-severe patients.

[0079] 4) Combination of missed detections, false alarms, and correct alerts: This combination provides users with more comprehensive information. It allows them to determine whether to accept missed detections or require more correct alerts based on the severity of the patient's condition, and also adjust the tolerance for false alarms as intervention progresses (e.g., ...). Figure 11 After weighing the three factors, the window number threshold converged to 12, making it suitable for parameter tuning across a wider range of patients.

[0080] Therefore, in this case, the preset window number threshold can be selected from any one of the first window number threshold, the second window number threshold, and the third window number threshold according to the requirements or symptoms.

[0081] It should be noted that the process of obtaining the abnormal window percentage threshold is the same as the process of obtaining the preset window number threshold, and will not be repeated here.

[0082] Furthermore, the method for establishing the control model includes: obtaining the optimal preset duration and preset window number as setting parameters, namely the optimal preset window number threshold or the optimal abnormal window ratio threshold and preset duration; displaying the number of missed detections, false alarms, and correct warnings at a single point; and actively changing any value in the setting parameters to automatically update the number of missed detections, false alarms, and correct warnings, so as to realize the setting of control parameters, that is, to control the stimulus system.

[0083] For details, please refer to Figure 12The optimal preset window count can be calculated using the method described above. After inputting the optimal preset window count in the background (e.g., a window count threshold of 9 and a preset duration of 5 minutes), the display interface will automatically show the number of false alarms and correct warnings under the condition of no missed detections (i.e., single-point display). If the user is not satisfied with the automatic display results, they can manually change the window count threshold and / or preset duration on the display interface. The background algorithm will automatically update the number of false alarms and correct warnings under the condition of no missed detections based on the changed data. If the user is satisfied with the manually adjusted results, they can use the manually set parameters to adjust the stimulation system. If the user is satisfied with the automatic display results, they can directly use the parameters calculated by the algorithm to adjust the stimulation system.

[0084] Based on the above, the present invention also provides a closed-loop stimulation system employing the above-described control method, comprising: a calculation module for detecting offline data of the signal; a judgment module for determining whether the signal meets the requirements of set parameters; a control module for setting the set parameters in the control model; and a stimulation module for stimulating the signal when the signal meets the requirements of the set parameters. The stimulation system may further include a display module; the display module is adapted to display the detection results and set parameters in multiple ways, including at least one of one-dimensional display, two-dimensional display, and single-point display.

[0085] For example, the window count threshold and preset duration can be used as the X and Y axes respectively, with the number of missed detections, false alarms, or correct warnings as the Z axis for a two-dimensional display; alternatively, the window count threshold or preset duration can be used as the X-axis, with the number of missed detections, false alarms, or correct warnings as the Y-axis for a one-dimensional display; or, the single-point values ​​of parameters such as the window count threshold, preset duration, number of missed detections, false alarms, and correct warnings can be directly displayed on the interface. Different display methods can be selected according to user needs, providing users with more flexibility.

[0086] Based on the above, this invention also provides a method for obtaining a preset window number threshold. The preset window number threshold is suitable for acquisition based on the classification of missed detection results. Specifically, when the missed detection result is determined to be no missed detection, the method for obtaining the preset window number threshold includes: using the number of windows corresponding to no missed detection as the base window; selecting the inflection point of the rate of decrease in the number of false alarms as the number of windows increases, or the lowest point of the number of false alarms, to obtain a first window number threshold; and / or using the number of windows corresponding to the maximum number of correct warnings as a second window number threshold. When the missed detection result is determined to be a missed detection, the method for obtaining the preset window number threshold includes: obtaining the number of windows corresponding to different missed detection counts; obtaining the number of windows corresponding to different false alarm counts; obtaining the number of windows corresponding to different number of correct warnings; selecting the overlapping area of ​​any two or all of the above window counts as a third window number threshold. The preset window number threshold is any one of the first window number threshold, the second window number threshold, and the third window number threshold. For a detailed explanation of the method for obtaining the preset window number threshold, please refer to the corresponding section of the control method; it will not be repeated here.

[0087] Based on the above, this invention also provides a method for obtaining a preset duration of a preset window number threshold. The preset duration includes: recording a value or calculating a value; wherein the recorded value is the average duration of the pre-onset period in history; the method for obtaining the calculated value includes: setting the preset duration to a period of time before the onset time; counting the number of warnings output by the warning algorithm for the current subject within the candidate time period between the onset time; if the number of warnings is greater than or equal to the warning number threshold, then sliding windows are applied to the candidate time period, and the warning density of each window is calculated; if the warning density of the window is greater than or equal to the warning density threshold, then the preset duration is equal to the difference between the onset time and the start time of the window, which is the calculated value; or if the number of warnings is less than the warning number threshold, then the preset duration is equal to the difference between the onset time and the warning time most recent to the onset time, which is the calculated value. For a detailed explanation of the method for obtaining the preset duration, please refer to the corresponding section of the control method, which will not be repeated here.

[0088] Furthermore, in this case, the results of missed detections include, but are not limited to, the number of missed detections, the missed detection rate, and other combinations and their derivative variations; the results of false alarms include, but are not limited to, the number of false alarms, the false alarm rate, and other combinations and their derivative variations; the results of correct early warnings include, but are not limited to, the number of correct alarms, the correct alarm rate, and other combinations and their derivative variations; and the preset window number situation includes, but is not limited to, the preset window number threshold or its abnormal window ratio threshold, and other combinations and their derivative variations. This case only uses the number of missed detections, the number of false alarms, the number of correct alarms, and the preset window number threshold as specific parameters to more intuitively demonstrate the control model and its control method. As for other variations, their application principles and control methods are basically the same, and will not be elaborated here, but should also be included within the scope of protection of this case.

[0089] In summary, this invention can be used to evaluate algorithm performance, assist users in optimizing stimulation system parameters, and provides multiple display options for users. The stimulation system control method and stimulation system based on offline signal detection results of this invention use preset durations and preset window numbers obtained from missed detection results, false alarm results, and / or correct warning results as setting parameters to regulate the stimulation system from both stimulation sensitivity and specificity aspects, enabling the stimulation system to achieve both accuracy and robustness. This invention is simple to operate, easy for users to understand, and has high market value.

[0090] Based on the above-described preferred embodiments of the present invention, and through the foregoing description, those skilled in the art can make various changes and modifications without departing from the inventive concept. The technical scope of this invention is not limited to the contents of the specification, but must be determined by the scope of the claims.

Claims

1. A method for obtaining a preset window number threshold, characterized in that, The preset window number threshold is used as the trigger condition for stimulating in the closed-loop stimulation system for epilepsy and neurological disorders. In this closed-loop stimulation system, when classifying real-time EEG signals, the early warning algorithm divides the raw EEG signals into windows, with each window obtaining a data segment. The early warning algorithm obtains two classification results: If 0 represents the interictal period, no warning will be issued; 1 indicates the early stage of an attack, thus serving as a warning; Each data segment yields a corresponding classification result. If M consecutive data segments are classified as 1 within a preset time period, then the stimulus is activated. The preset window number threshold at this time is M. The preset window number threshold is obtained based on the classification of missed detection results, that is... When the missed detection result is determined to be no missed detection, the method for obtaining the preset window number threshold includes: The base number of windows is the number of windows that do not miss any detections; Select the inflection point or the lowest point of the rate at which the number of false alarms decreases with increasing window number to obtain the first window number threshold; and / or The number of windows corresponding to the maximum number of correct warnings is used as the threshold for the second window number. Alternatively, the optimal window number threshold can be obtained by combining the number of no missed detections, the number of false alarms, and the number of correct warnings. When a missed detection result indicates a missed detection, the method for obtaining the preset window number threshold includes: Obtain the number of windows corresponding to different numbers of missed detections; Obtain the number of windows corresponding to different false alarm counts; Obtain the number of windows corresponding to different numbers of correct alerts; Select any two or all of the overlapping areas of the above window numbers as the threshold for the third window number; The preset window number threshold is any one of the first window number threshold, the second window number threshold, and the third window number threshold; The detection criteria for the missed detection results include: if multiple data segments exist within a preset time period, and the early warning algorithm outputs an early warning at least once, indicating that an abnormal data segment has been detected, then it is determined that there is no missed detection; otherwise, it is determined that there is a missed detection. The detection criteria for false alarms include: if the warning algorithm outputs a warning within a preset time period before and after the onset period, it is determined to be a false alarm.

2. The method for obtaining the preset window number threshold as described in claim 1, characterized in that, The detection criteria for a correct early warning include: if the early warning algorithm outputs an early warning within a preset time period, it is determined to be a correct early warning; The preset duration includes recorded or calculated values; The recorded value is the average duration of the pre-ictal period in history. That is, the duration of multiple interictal periods during the subject's previous disease attacks is collected, and the average of the duration of these multiple interictal periods is taken as the preset duration. The method for obtaining the calculated values ​​includes: The preset duration is set to a period of time before the onset time. The number of warnings output by the warning algorithm for the current subject within the alternative time period before the onset time is counted. If the number of warnings is greater than or equal to the warning number threshold, then a sliding window is used for the candidate time period to calculate the warning density for each window; If the warning density of the window is greater than or equal to the warning density threshold, the preset duration is equal to the difference between the time of onset and the start time of the window, which is the calculated value. If the number of warnings is less than the warning number threshold, the preset duration is equal to the difference between the time of the outbreak and the time of the most recent warning, which is the calculated value.

3. The method for obtaining the preset window number threshold as described in claim 1, characterized in that, The method for obtaining the preset window number threshold combines the number of missed detections, the number of false alarms, and the number of correct warnings to cover a variety of clinical application scenarios.

4. The method for obtaining the preset window number threshold as described in claim 3, characterized in that, Combination of missed detections and false alarms: The performance trends of the two indicators, missed detections and false alarms, are opposite as they change with the window number threshold, and are used for parameter tuning throughout the patient's process; Based on the principle of not missing any detections, the third window threshold of 12 is automatically calculated by combining the number of missed detections and the number of false alarms. This is used for patients with severe conditions or in the early stages of intervention. Based on the principle of balancing missed detections and false alarms, the third window threshold of 14 is automatically calculated by combining the number of missed detections and false alarms, and is used for patients with good prognoses.

5. The method for obtaining the preset window number threshold as described in claim 3, characterized in that, The combination of missed detections and correct alerts: The performance trends of both the missed detections and correct alerts are the same with the window number threshold, and they are used for parameter tuning in the early stages of patient intervention; Based on the principle of balancing missed detections and correct early warnings, the threshold for the third window number is automatically calculated by combining the number of missed detections and the number of correct early warnings, and is set to 5.

6. The method for obtaining the preset window number threshold as described in claim 3, characterized in that, The combination of false alarm count and correct warning count: The performance trends of the two indicators, false alarm count and correct warning count, are opposite as they change with the window number threshold. This is used for parameter tuning in non-severe patients. Based on the principle of prioritizing the suppression of false alarms, the threshold for the third window number is automatically calculated by combining the number of false alarms and the number of correct warnings, and is set to 19. Based on the principle of requiring more correct early warnings, the threshold for the third window number is automatically calculated by combining the number of false alarms and the number of correct early warnings, and is set to 6.

7. The method for obtaining the preset window number threshold as described in claim 3, characterized in that, The combination of missed detections, false alarms, and correct alerts: Based on the principle of balancing missed detections, false alarms, and correct alerts, the decision on whether to accept missed detections and whether more correct alerts are needed is determined according to the severity of the patient's condition, for use in parameter tuning for a wider range of patients throughout the process; The number of missed detections, false alarms, and correct warnings are combined to automatically calculate the third window threshold of 12, which is used to adjust the tolerance for false alarms as the regulatory intervention progresses.

Citation Information

Patent Citations

  • Time domain data classification method based on zero crossing point coefficient and implantable stimulation system

    CN114010207A

  • Electroencephalogram spike wave frequency based early-alarming method and device

    CN102393874A

  • Method for detecting self-adaptive brain wave signal abnormity based on time-domain analysis

    CN107095668A