Accelerator anomaly detection method and system based on density and multi-scale LOF fusion

The accelerator anomaly detection method, which integrates density and multi-scale LOF, collects and processes key accelerator parameters in real time, calculates global and local anomaly scores, and solves the problem of insufficient accuracy in existing accelerator anomaly detection technologies. This method achieves efficient anomaly monitoring and interpretable judgment results.

CN121579505BActive Publication Date: 2026-06-09CHENGDU METROLOGY TESTING INST
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
CHENGDU METROLOGY TESTING INST
Filing Date
2025-11-28
Publication Date
2026-06-09

AI Technical Summary

Technical Problem

Existing methods for detecting anomalies in medical linear accelerators are not accurate enough when adapting to complex operating conditions, and they are unable to take into account both global and local anomalies, resulting in high false alarm or false negative rates. Furthermore, machine learning algorithms lack interpretability.

Method used

An accelerator anomaly detection method based on density and multi-scale LOF fusion is adopted. By collecting key operating parameters in real time, noise reduction, normalization and dimensionality reduction are performed to calculate the normalized global anomaly score and multi-scale LOF score. Anomaly judgment is made by combining the preset anomaly discrimination threshold, so as to achieve comprehensive monitoring of the accelerator's operating status.

Benefits of technology

It improves the comprehensiveness and accuracy of accelerator anomaly detection, reduces the false negative rate, provides interpretable anomaly judgment results, and enhances the traceability capability of anomaly detection.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121579505B_ABST
    Figure CN121579505B_ABST
Patent Text Reader

Abstract

The application discloses an accelerator anomaly detection method and system based on density and multi-scale LOF fusion, relates to the technical field of intelligent monitoring of medical equipment, and comprises the following steps: collecting key operation parameters of a linear accelerator in real time; performing noise reduction, normalization and dimension reduction processing on the key operation parameters to obtain a dimension reduction feature matrix; calculating the normalized global anomaly score and the normalized multi-scale LOF score of each sample point in the dimension reduction feature matrix; calculating the final anomaly score of each sample point in the dimension reduction feature matrix, and combining a preset anomaly discrimination threshold to determine whether the linear accelerator is abnormal; the method is based on the global anomaly score and the multi-scale LOF score, realizes synchronous capture of global trend anomalies and local subtle anomalies of the accelerator, performs anomaly discrimination based on the final anomaly score calculated by fusion of the two types of scores, reduces the one-sidedness problem of the traditional anomaly detection method, and improves the comprehensiveness and accuracy of accelerator anomaly detection.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of intelligent monitoring of medical devices, specifically to an accelerator anomaly detection method and system based on density and multi-scale LOF fusion. Background Technology

[0002] Medical linear accelerators are core equipment in radiotherapy, and their operational accuracy directly affects dose coverage of the tumor target area and radiation safety of normal tissues. In clinical practice, abnormalities in linear accelerators, such as dose rate drift, beam instability, and gantry / collimator angle deviations, can lead to insufficient or excessive treatment doses, seriously threatening patient safety. Therefore, achieving real-time and accurate detection of abnormalities in the linear accelerator's operational status is crucial for radiotherapy quality control.

[0003] Current methods for anomaly detection in medical linear accelerators primarily rely on traditional quality control and fixed threshold judgment, supplemented by mechanical calibration and radiation protection testing. These methods are gradually moving towards intelligent algorithm-based detection. Commonly used methods include: parameter monitoring based on fixed thresholds, anomaly detection based on sensor and hardware interlocks, image-guided anomaly detection, and fault detection based on machine learning algorithms. However, parameter monitoring based on fixed thresholds focuses only on the absolute value changes of individual parameters (e.g., dose rate deviation ±2%), making it difficult to adapt to normal parameter fluctuations and capture global trend anomalies involving multiple parameters. Anomaly detection based on sensor and hardware interlocks only monitors the explicit faults of individual components (e.g., vibration or temperature anomalies), ignoring the coupling relationships between parameters of different components and making it difficult to identify global anomalies at the parameter distribution level. Image-guided anomaly detection often focuses on positional accuracy (e.g., target area offset), failing to cover multi-dimensional anomalies such as radiation output and mechanical coordination faults, resulting in insufficient adaptability to the complex operating conditions of accelerators. Therefore, it is evident that traditional methods generally suffer from insufficient adaptability to the complex operating states of linear accelerators and difficulty in simultaneously addressing global and local anomalies, leading to high false alarm or false negative rates. While machine learning-based intelligent algorithms (such as single LOF, LSTM, and CNN) overcome the limitations of static judgment in traditional methods, their core objective is often focused on fault prediction, with outputs primarily representing fault occurrence probabilities. This fails to meet the core requirement of anomaly detection—whether the equipment's real-time operating status is abnormal. Furthermore, the black-box nature of machine learning algorithms makes their decision-making logic difficult to trace, resulting in a lack of interpretability in the decision-making results that aligns with clinical maintenance or troubleshooting needs. Summary of the Invention

[0004] The purpose of this invention is to provide an accelerator anomaly detection method and system based on density and multi-scale LOF fusion, so as to solve the problem of insufficient accuracy of traditional anomaly detection methods for linear accelerator anomaly detection mentioned in the background art.

[0005] To achieve the above objectives, the present invention provides the following technical solution:

[0006] An accelerator anomaly detection method based on density and multi-scale LOF fusion includes the following steps:

[0007] Real-time acquisition of key operating parameters of the linear accelerator;

[0008] The key operating parameters are denoised and normalized to obtain a standardized parameter matrix;

[0009] The standardized parameter matrix is ​​dimensionality-reduced to obtain the dimensionality-reduced feature matrix.

[0010] Calculate the normalized global anomaly score and the normalized multi-scale LOF score for each sample point in the reduced-dimensional feature matrix;

[0011] Based on the normalized global anomaly score and the normalized multi-scale LOF score, the final anomaly score of each sample point in the dimensionality-reduced feature matrix is ​​calculated. Based on the final anomaly score and the preset anomaly discrimination threshold, it is determined whether the linear accelerator has an anomaly.

[0012] The principle of this invention's accelerator anomaly detection method based on density and multi-scale LOF fusion is as follows: Key operating parameters of the linear accelerator are acquired in real time, and these parameters are progressively denoised, normalized, and dimensionality-reduced to obtain a dimensionality-reduced feature matrix that reflects the core operating characteristics of the linear accelerator. Based on this, two types of key anomaly indicators are simultaneously calculated for each sample point in the dimensionality-reduced feature matrix: First, a normalized global anomaly score reflecting the degree of anomaly of each sample point in the overall data distribution. This score quantifies the deviation trend of the sample point from the global data, capturing overall anomalies in accelerator operation. Second, a normalized multi-scale LOF score reflecting the anomaly characteristics of each sample point in a local data cluster. The LOF score, achieved by normalizing the multi-scale LOF score to adapt to data distribution scenarios with different local data densities, accurately identifies subtle local anomalies in different components of the accelerator. By weighted fusion of the normalized global anomaly score and the normalized multi-scale LOF score, a final anomaly score is obtained that comprehensively reflects the global and local anomaly features of each sample point. Combined with a preset anomaly discrimination threshold, this enables the discrimination of anomalies in the linear accelerator's operating state. This invention's accelerator anomaly detection method, through the collaborative analysis of the global and local features of accelerator operating parameters, can cover both overall trend anomalies and subtle local anomalies in accelerator operation, thereby improving the comprehensiveness and accuracy of accelerator anomaly detection.

[0013] Preferably, to improve the comprehensiveness of the anomaly detection method in covering the core operating parameters of the accelerator, the key operating parameters include: the dose rate of the linear accelerator, the beam intensity of the electron gun, and the position of the mechanical components of the linear accelerator. The position of the mechanical components includes: the gantry rotation angle and the collimator rotation angle. The dose rate and beam intensity cover the operation of the linear accelerator's X-ray output system, while the gantry rotation angle and collimator rotation angle reflect the accuracy of the mechanical motion system, thereby achieving comprehensive monitoring of the core operating status of the accelerator.

[0014] Preferably, the normalized global anomaly score is obtained in the following ways:

[0015] Based on the average Euclidean distance between each sample point in the dimensionality-reduced feature matrix and a preset number of nearest neighbor sample points, and a preset average Euclidean distance threshold, the number of nearest neighbor samples for each sample point is determined. The global density of each sample point is then calculated based on the number of nearest neighbor samples. By dynamically determining the number of nearest neighbor samples for each sample point through the average Euclidean distance between the sample point and the preset number of nearest neighbor sample points, combined with the preset average Euclidean distance threshold, the matching degree between the number of nearest neighbor samples and the data density of the local area where the sample point is located is enhanced, thereby making the global density calculation result more realistically reflect the global distribution characteristics of the sample points.

[0016] Based on the global density of each sample point, calculate the global anomaly score of each sample point in the dimensionality-reduced feature matrix;

[0017] The global anomaly score is normalized to obtain the normalized global anomaly score for each sample point. The normalization process eliminates the scale difference between different sample points, making the global anomaly scores of each sample point comparable within a unified dimension.

[0018] Preferably, to achieve quantization of the global density, the formula for calculating the global density is as follows:

[0019] ;

[0020] In the formula, i is the sample point index, and j is the sample point. Nearest neighbor sample point index, For sample points The global density in the reduced-dimensional feature matrix, For sample points The number of nearest neighbor samples, For sample points The The nearest neighbor sample points, For sample points and The Euclidean distance; by using a defined global density calculation formula, the impact of inconsistent data distribution density scales near different sample points is mitigated, enabling direct comparison of global densities of different sample points;

[0021] The formula for calculating the global anomaly score is as follows:

[0022] ;

[0023] In the formula, For sample points The global anomaly score in the reduced-dimensional feature matrix, The global density of all sample points in the reduced feature matrix is ​​the maximum value. The global anomaly score is given by a mathematical expression, which makes the global anomaly score a clear and consistent representation of the anomaly degree of the sample points. That is, the higher the density of the sample points, the smaller the anomaly degree and the smaller the corresponding global anomaly score. The lower the density of the sample points, the greater the anomaly degree and the larger the corresponding global anomaly score.

[0024] Preferably, the normalized multi-scale LOF score is obtained by means of:

[0025] Based on the density of sample data in the dimensionality-reduced feature matrix, m local nearest neighbor scales are set. , ,…and ;

[0026] At each local nearest neighbor scale, the local reachability distance and local reachability density of each sample point in the dimensionality-reduced feature matrix are calculated. Based on the local reachability density, the single-scale local anomaly factor (LOF) value of each sample point in the dimensionality-reduced feature matrix is ​​calculated. By calculating the single-scale LOF value of each sample point at different scales, the ability of LOF-based local anomaly detection to capture diverse local anomalies caused by different data distribution scenarios is improved.

[0027] Based on the single-scale local anomaly factor LOF value of each sample point at each local nearest neighbor scale, the multi-scale LOF score of each sample point in the dimensionality-reduced feature matrix is ​​calculated. By fusing the different local anomaly features of each sample point at multiple scales into a multi-scale LOF score, the one-sidedness problem caused by single-scale quantization is avoided, and the comprehensiveness of the characterization of the local anomaly degree of the sample point is enhanced.

[0028] The multi-scale LOF scores are normalized to obtain the normalized multi-scale LOF score for each sample point. The normalization process eliminates the scale differences between different sample points, ensuring that the normalized multi-scale LOF score and the normalized global outlier score have a unified quantization dimension, thus avoiding fusion distortion caused by scale inconsistency when the two are subsequently fused into the final outlier score.

[0029] Preferably, the formula for calculating the multi-scale LOF score is as follows:

[0030] ;

[0031] ;

[0032] In the formula, i is the index of the sample point. For sample points The multi-scale LOF score in the reduced-dimensional feature matrix, where n is the local nearest neighbor scale index and m is the total number of local nearest neighbor scales. For the nth local nearest neighbor scale Scale weights, To the nth local nearest neighbor scale Below, sample points The single-scale local anomaly factor (LOF) value in the reduced-dimensional feature matrix. To the nth local nearest neighbor scale The standard deviation of the local reachability density of all sample points is calculated by scaling the scale. Introduced in China This approach assigns higher weights to scales with more stable data distributions, while reducing the interference of unstable scales on the fusion calculation results of multi-scale LOF scores. ϵ is a smoothing constant used to prevent the denominator from being zero. By defining a weighted summation formula for multi-scale LOF scores, the scientific integration of single-scale LOF values ​​under different local nearest neighbor scales is achieved, thereby improving the accuracy of multi-scale LOF scores in quantifying the degree of local anomalies.

[0033] Preferably, the formula for calculating the final abnormal score is:

[0034] ;

[0035] ;

[0036] In the formula, i is the index of the sample point. For sample points The final anomaly score in the reduced-dimensional feature matrix, where α is the adaptive fusion weight. For sample points The normalized global outlier score, For sample points The normalized multiscale LOF score, where h is the adjustment coefficient. For sample points of Locally achievable density in the vicinity For sample points The number of nearest neighbor samples, A preset density threshold is used; by introducing an adaptive fusion weight that can be dynamically adjusted according to the linear accelerator's operating status, the global anomaly score and the multi-scale LOF score are fused into the final anomaly score, and the influence of global anomalies and local anomalies on the final anomaly result is balanced according to the data distribution characteristics, thereby improving the accuracy of anomaly detection.

[0037] Preferably, to adapt the local nearest neighbor scale settings to the data distribution characteristics, thereby improving the ability of multi-scale LOF scores to capture subtle local anomalies, and simultaneously ensuring logical consistency between local and global anomaly detection, the following... Local nearest neighbor scale , ,…and This includes the number of neighboring samples for each sample point.

[0038] Preferably, to improve the objectivity of the preset anomaly detection threshold setting and its adaptability to the actual operating characteristics of the linear accelerator, the method for setting the preset anomaly detection threshold is as follows: based on the historical operating data of the linear accelerator, calculate the maximum value of the final anomaly score during normal operation of the linear accelerator. And the minimum value of the final abnormal score when the linear accelerator is running abnormally. Set a preset anomaly detection threshold. for .

[0039] This invention also provides an accelerator anomaly detection system based on density and multi-scale LOF fusion, comprising:

[0040] The data acquisition module is used to collect key operating parameters of the linear accelerator in real time.

[0041] The standardization processing module is used to reduce noise and normalize the key operating parameters to obtain a standardized parameter matrix;

[0042] The feature dimensionality reduction module is used to reduce the dimensionality of the standardized parameter matrix to obtain the dimensionality-reduced feature matrix.

[0043] The global outlier density estimation module is used to calculate the global density and global outlier score of each sample point in the dimensionality-reduced feature matrix;

[0044] The multi-scale local anomaly factor LOF calculation module is used to calculate the local reachability distance, local reachability density, single-scale local anomaly factor LOF value, and multi-scale LOF score for each sample point in the dimensionality-reduced feature matrix.

[0045] The anomaly detection module is used to calculate the normalized global anomaly score and normalized multi-scale LOF score for each sample point based on the global anomaly score and the multi-scale LOF score. Based on the normalized global anomaly score and the normalized multi-scale LOF score, it calculates the final anomaly score for each sample point in the dimensionality-reduced feature matrix. Based on the final anomaly score and a preset anomaly detection threshold, it determines whether the linear accelerator is abnormal. If the final anomaly score of a sample point is less than the preset anomaly detection threshold, the linear accelerator is determined not to be abnormal. If the final anomaly score of a sample point falls within the threshold range of the preset anomaly detection threshold, the linear accelerator is determined to be potentially abnormal, and the global anomaly score and multi-scale LOF score of the potentially abnormal sample point are output. If the final anomaly score of a sample point is greater than the preset anomaly detection threshold, the linear accelerator is determined to be abnormal, and the global anomaly score and multi-scale LOF score of the abnormal sample point are output. By classifying and outputting the global anomaly score and multi-scale LOF score, quantitative evidence is provided for clinical maintenance and anomaly tracing, thereby improving the interpretability and traceability of anomaly detection.

[0046] One or more technical solutions provided by this invention have at least the following technical effects or advantages:

[0047] 1. Based on the key operating parameters of the accelerator, normalized global anomaly scores and normalized multi-scale LOF scores are calculated to achieve simultaneous capture of global trend anomalies and local subtle anomalies in accelerator operation. The final anomaly score calculated by fusing the two types of normalized scores reduces the one-sidedness of traditional anomaly detection methods and improves the comprehensiveness and accuracy of accelerator anomaly detection.

[0048] 2. The key operating parameters collected cover the X-ray output system and mechanical motion system of the linear accelerator, which improves the completeness of the anomaly detection data and reduces the missed detection rate of anomalies caused by a single monitoring parameter;

[0049] 3. By dynamically determining the number of nearest neighbors of a sample point based on the local data distribution characteristics of the sample point, the global anomaly score is adaptively calculated for non-uniform data distribution, thereby improving the accuracy and reliability of global anomaly detection.

[0050] 4. The global anomaly score quantifies the degree of global anomaly of the sample points, which intuitively reflects the degree of deviation of the sample points from the overall data distribution;

[0051] 5. By constructing a quantization mechanism for multi-scale LOF scores, the ability of local anomaly detection to capture subtle anomalies of sample points under different local data distribution scenarios is improved, overcoming the problem that the traditional single-scale LOF algorithm cannot adapt to non-uniform data distribution.

[0052] 6. By weighted fusion of multiple single-scale LOF values, a multi-scale LOF score is calculated to quantify the degree of local anomalies of sample points and enhance the reliability of the multi-scale LOF score in scenarios with non-uniform data distribution.

[0053] 7. By introducing adaptive fusion weights that can be dynamically adjusted according to the linear accelerator's operating status, the final anomaly score takes into account both global and local anomalies, providing a more comprehensive and reliable quantitative basis for subsequent anomaly detection.

[0054] 8. By incorporating the dynamically determined number of nearest neighbor samples in global anomaly detection into the local nearest neighbor scale set, the computational complexity of the local nearest neighbor scale is reduced, while maintaining logical consistency between local and global detection, thereby improving the consistency of anomaly detection and the reliability of the judgment results.

[0055] 9. Set anomaly detection threshold based on historical data of confirmed abnormal states of the linear accelerator to improve the objectivity of the preset anomaly detection threshold setting and its compatibility with the linear accelerator;

[0056] 10. Provide a modular anomaly detection system for anomaly detection methods to achieve the engineering transformation of anomaly detection methods; provide interpretable quantitative results of anomaly judgment through hierarchical early warning and anomaly score output to improve the traceability capability of the anomaly detection system. Attached Figure Description

[0057] The accompanying drawings, which are provided to further illustrate embodiments of the invention and constitute a part of this invention, are not intended to limit the scope of the invention.

[0058] Figure 1 This is a flowchart illustrating the accelerator anomaly detection method based on density and multi-scale LOF fusion in this invention.

[0059] Figure 2 This is a schematic diagram of the final abnormal score fusion;

[0060] Figure 3 This is a schematic diagram of the accelerator anomaly detection system based on density and multi-scale LOF fusion in this invention. Detailed Implementation

[0061] To better understand the above-mentioned objectives, features, and advantages of the present invention, the present invention will be further described in detail below with reference to the accompanying drawings and specific embodiments. It should be noted that, where there is no conflict, the embodiments of the present invention and the features thereof can be combined with each other.

[0062] Many specific details are set forth in the following description in order to provide a full understanding of the invention. However, the invention may also be practiced in other ways different from those described herein, and therefore the scope of protection of the invention is not limited to the specific embodiments disclosed below.

[0063] Example 1

[0064] Please refer to Figure 1-2 This invention provides an accelerator anomaly detection method based on density and multi-scale LOF fusion, comprising the following steps:

[0065] Key operating parameters of the linear accelerator are acquired in real time. These parameters include the dose rate, electron gun beam intensity, and mechanical component positions, including gantry rotation angle and collimator rotation angle. The dose rate and electron gun beam intensity can be obtained through data interfaces provided by the linear accelerator manufacturer, while the mechanical component positions can be obtained through manufacturer-provided data interfaces or external encoders. The acquired dose rate, beam intensity, and mechanical component position data must be timestamped to ensure that each sample point in the subsequent dimensionality reduction feature matrix represents the operating state of different components of the linear accelerator at the same time.

[0066] The key operating parameters are denoised and normalized to obtain a standardized parameter matrix; wherein, the key operating parameters are denoised using exponential moving average and normalized using Z-score standardization to obtain a standardized parameter matrix; wherein, exponential moving average and Z-score standardization are existing technologies and will not be described in detail in this invention.

[0067] The standardized parameter matrix is ​​dimensionality reduced to obtain a dimensionality-reduced feature matrix; wherein, principal component analysis is used to reduce the dimensionality of the standardized parameter matrix; wherein, principal component analysis is a prior art, and will not be described in detail in this invention;

[0068] Calculate the normalized global anomaly score and the normalized multi-scale LOF score for each sample point in the reduced-dimensional feature matrix;

[0069] Based on the normalized global anomaly score and the normalized multi-scale LOF score, the final anomaly score of each sample point in the dimensionality-reduced feature matrix is ​​calculated. Based on the final anomaly score and the preset anomaly discrimination threshold, it is determined whether the linear accelerator has an anomaly, and the hierarchical anomaly judgment result, as well as the global anomaly score and multi-scale LOF score of the sample point that has an anomaly, are output.

[0070] The normalized global anomaly score is obtained through the following methods:

[0071] Based on the average Euclidean distance between each sample point in the dimensionality reduction feature matrix and a preset number of neighboring sample points, and a preset average Euclidean distance threshold, the number of neighboring samples for each sample point is determined, and the global density of each sample point is calculated based on the number of neighboring samples.

[0072] Based on the global density of each sample point, calculate the global anomaly score of each sample point in the dimensionality-reduced feature matrix;

[0073] The global anomaly score is normalized to obtain the normalized global anomaly score for each sample point; wherein, min-max normalization is used to normalize the global anomaly score.

[0074] The preset number of nearest neighbors is set based on the total number of sample points in the dimensionality-reduced feature matrix; the preset average Euclidean distance threshold is set based on the statistical patterns of historical normal operation data of the linear accelerator, specifically:

[0075] ;

[0076] In the formula, T is the preset average Euclidean distance threshold, μ0 and σ0 are the mean and standard deviation of the average Euclidean distance T0 of all sample points in the k0 nearest neighbors in the historical normal operation data of the linear accelerator, respectively, and k0 is the preset number of nearest neighbors;

[0077] Wherein, if a certain sample point x in the dimensionality reduction feature matrix i The mean Euclidean distance among the nearest neighbors of k0 If the distance is less than the preset average Euclidean distance threshold, adjust the sample point x. i The number of nearest neighbor samples is N is the total number of sample points in the reduced-dimensionality feature matrix; if If the sample point x falls within the preset average Euclidean distance threshold range, then keep the sample point x. i The number of nearest neighbor samples is ;like If the distance is greater than the preset average Euclidean distance threshold, then adjust the sample point x. i The number of nearest neighbor samples is ;

[0078] The formula for calculating the global density is as follows:

[0079] ;

[0080] In the formula, i is the sample point index, and j is the sample point. Nearest neighbor sample point index, For sample points The global density in the reduced-dimensional feature matrix, For sample points The number of nearest neighbor samples, For sample points The The nearest neighbor sample points, For sample points and Euclidean distance;

[0081] The formula for calculating the global anomaly score is as follows:

[0082] ;

[0083] In the formula, For sample points The global anomaly score in the reduced-dimensional feature matrix, It represents the maximum global density of all sample points in the reduced-dimensional feature matrix.

[0084] The normalized multi-scale LOF score is obtained through the following methods:

[0085] Based on the density of sample data in the dimensionality-reduced feature matrix, m local nearest neighbor scales are set. , ,…and Wherein, the m local nearest neighbor scales , ,…and This includes the number of nearest neighbor samples for each sample point;

[0086] At each local nearest neighbor scale, calculate the local reachability distance and local reachability density of each sample point in the dimensionality-reduced feature matrix, and calculate the single-scale local anomaly factor (LOF) value of each sample point in the dimensionality-reduced feature matrix based on the local reachability density.

[0087] Based on the single-scale local anomaly factor LOF value of each sample point at each local nearest neighbor scale, calculate the multi-scale LOF score of each sample point in the dimensionality-reduced feature matrix.

[0088] The multi-scale LOF scores are normalized to obtain the normalized multi-scale LOF score for each sample point; wherein, min-max normalization is used to normalize the multi-scale LOF scores.

[0089] The formulas for calculating the local reachability distance and the local reachability density are as follows:

[0090] ;

[0091] ;

[0092] In the formula, n is the local nearest neighbor scale index. For the nth local nearest neighbor scale, In order to be in Sample points at the local nearest neighbor scale To its nearest neighbor sample points Locally accessible distance, For sample points Its nearest neighbor sample points European distance, For sample points of Proximity distance For sample points of Locally accessible density in the vicinity;

[0093] The formula for calculating the single-scale local anomaly factor LOF value is as follows:

[0094] ;

[0095] In the formula, For sample points exist LOF value of single-scale local anomaly factor at the local nearest neighbor scale. Nearest neighbor sample points of Locally accessible density in the vicinity;

[0096] The formula for calculating the multi-scale LOF score is as follows:

[0097] ;

[0098] ;

[0099] In the formula, i is the index of the sample point. For sample points The multi-scale LOF score in the reduced-dimensional feature matrix, where n is the local nearest neighbor scale index and m is the total number of local nearest neighbor scales. For the nth local nearest neighbor scale Scale weights, For all sample points The standard deviation of the nearest locally reachable density, ϵ is a smoothing constant used to prevent the denominator from being zero, ϵ=1×10 -8 .

[0100] The formula for calculating the final anomaly score is as follows:

[0101] ;

[0102] ;

[0103] In the formula, For sample points The final anomaly score in the reduced-dimensional feature matrix, where α is the adaptive fusion weight. For sample points The normalized global outlier score, For sample points The normalized multiscale LOF score, where h is the adjustment coefficient, h=2. For sample points of Locally achievable density in the vicinity For sample points The number of nearest neighbor samples, For the preset density threshold, The settings are based on statistical patterns from historical normal operating data of the linear accelerator, specifically:

[0104] ;

[0105] In the formula, and These are the mean and standard deviation of the k0 nearest neighbor local reachability density for all sample points in the historical normal operation data of the linear accelerator, where k0 is the preset number of nearest neighbors. Intervals are used to define the statistical range of normally locally accessible densities. In actual calculations, The midpoint of the interval can be selected, i.e. As a benchmark value, to enhance Stability and accuracy of calculations.

[0106] The method for setting the preset anomaly detection threshold is as follows: based on the historical operating data of the linear accelerator, calculate the maximum value of the final anomaly score during normal operation of the linear accelerator. And the minimum value of the final abnormal score when the linear accelerator is running abnormally. Set a preset anomaly detection threshold. for .

[0107] Please refer to Figure 3 The accelerator anomaly detection system based on density and multi-scale LOF fusion provided by this invention includes:

[0108] The data acquisition module is used to collect key operating parameters of the linear accelerator in real time. The data acquisition module includes a data interface and an absolute encoder provided by the linear accelerator manufacturer. It collects the key operating parameters of the linear accelerator at a frequency of 100Hz and timestamps the collected dose rate, electron gun beam intensity, and mechanical component position data. The dose rate, beam intensity, and mechanical component position at each time point after tamping are considered as a set of original sample points. After collecting 500 sets of original sample points, the data acquisition module combines these 500 sets of original sample points in chronological order into a 500×4-dimensional key operating parameter matrix and transmits the key operating parameter matrix to the standardization processing module.

[0109] The standardization processing module is used to denoise and normalize the key operating parameters to obtain a standardized parameter matrix. The standardization processing module uses exponential moving average to denoise each type of parameter in the key operating parameter matrix, and uses Z-score standardization to normalize each type of key operating parameter after denoising to obtain a standardized parameter matrix with the same dimension as the key operating parameter matrix.

[0110] The feature dimensionality reduction module is used to reduce the dimensionality of the standardized parameter matrix to obtain a dimensionality-reduced feature matrix. Specifically, the feature dimensionality reduction module uses principal component analysis to reduce the dimensionality of the standardized parameter matrix, resulting in a 500×p-dimensional dimensionality-reduced feature matrix, where 1... <p≤4;

[0111] The global outlier density estimation module is used to calculate the global density and global outlier score of each sample point in the dimensionality-reduced feature matrix;

[0112] The multi-scale local anomaly factor LOF calculation module is used to calculate the local reachability distance, local reachability density, single-scale local anomaly factor LOF value, and multi-scale LOF score for each sample point in the dimensionality-reduced feature matrix.

[0113] The anomaly detection module is used to calculate the normalized global anomaly score and the normalized multi-scale LOF score for each sample point based on the global anomaly score and the multi-scale LOF score. Based on the normalized global anomaly score and the normalized multi-scale LOF score, it calculates the final anomaly score for each sample point in the dimensionality-reduced feature matrix. Based on the final anomaly score and a preset anomaly detection threshold, it determines whether the linear accelerator is abnormal. If the final anomaly score of a sample point is less than the preset anomaly detection threshold, it is determined that the linear accelerator is not abnormal. If the final anomaly score of a sample point falls within the threshold range of the preset anomaly detection threshold, it is determined that the linear accelerator may be abnormal, and the global anomaly score and multi-scale LOF score of the potentially abnormal sample point are output. If the final anomaly score of a sample point is greater than the preset anomaly detection threshold, it is determined that the linear accelerator is abnormal, and the global anomaly score and multi-scale LOF score of the abnormal sample point are output. The anomaly detection module uses min-max normalization to normalize the global anomaly score and the multi-scale LOF score respectively.

[0114] Although preferred embodiments of the invention have been described, those skilled in the art, upon learning the basic inventive concept, can make other changes and modifications to these embodiments. Therefore, the appended claims are intended to be interpreted as including both the preferred embodiments and all changes and modifications falling within the scope of the invention.

[0115] Obviously, those skilled in the art can make various modifications and variations to this invention without departing from its spirit and scope. Therefore, if these modifications and variations fall within the scope of the claims of this invention and their equivalents, this invention also intends to include these modifications and variations.

Claims

1. An accelerator anomaly detection method based on density and multi-scale LOF fusion, characterized in that, Includes the following steps: Real-time acquisition of key operating parameters of the linear accelerator, including: dose rate of the linear accelerator, beam intensity of the electron gun, and position of mechanical components of the linear accelerator, including: gantry rotation angle and collimator rotation angle; The key operating parameters are denoised and normalized to obtain a standardized parameter matrix; The standardized parameter matrix is ​​dimensionality-reduced to obtain the dimensionality-reduced feature matrix. Calculate the normalized global anomaly score and normalized multi-scale LOF score for each sample point in the dimensionality-reduced feature matrix. The normalized global anomaly score is obtained by: determining the number of neighboring samples for each sample point based on the average Euclidean distance between each sample point and a preset number of neighboring sample points in the dimensionality-reduced feature matrix, and a preset average Euclidean distance threshold; calculating the global density of each sample point based on the number of neighboring samples; calculating the global anomaly score for each sample point in the dimensionality-reduced feature matrix based on the global density of each sample point; and normalizing the global anomaly score to obtain the normalized global anomaly score for each sample point. The normalized multi-scale LOF score is obtained by: setting m local nearest neighbor scales based on the sample data density in the dimensionality-reduced feature matrix. , ,…and At each local nearest neighbor scale, the local reachability distance and local reachability density of each sample point in the dimensionality-reduced feature matrix are calculated. Based on the local reachability density, the single-scale local anomaly factor (LOF) value of each sample point in the dimensionality-reduced feature matrix is ​​calculated. Based on the single-scale LOF value of each sample point at each local nearest neighbor scale, the multi-scale LOF score of each sample point in the dimensionality-reduced feature matrix is ​​calculated. The multi-scale LOF score is normalized to obtain the normalized multi-scale LOF score of each sample point. The formula for calculating the global density is: ; In the formula, i is the sample point index, and j is the sample point. Nearest neighbor sample point index, For sample points The global density in the reduced-dimensional feature matrix, For sample points The number of nearest neighbor samples, For sample points The The nearest neighbor sample points, For sample points and Euclidean distance; The formula for calculating the global anomaly score is as follows: ; In the formula, For sample points The global anomaly score in the reduced-dimensional feature matrix, This represents the maximum global density of all sample points in the reduced-dimensional feature matrix; Based on the normalized global anomaly score and the normalized multi-scale LOF score, the final anomaly score of each sample point in the dimensionality-reduced feature matrix is ​​calculated. Based on the final anomaly score and the preset anomaly discrimination threshold, it is determined whether the linear accelerator has an anomaly.

2. The accelerator anomaly detection method based on density and multi-scale LOF fusion according to claim 1, characterized in that, The formula for calculating the multi-scale LOF score is as follows: ; ; In the formula, i is the index of the sample point. For sample points The multi-scale LOF score in the reduced-dimensional feature matrix, where n is the local nearest neighbor scale index and m is the total number of local nearest neighbor scales. For the nth local nearest neighbor scale Scale weights, To the nth local nearest neighbor scale Below, sample points The single-scale local anomaly factor (LOF) value in the reduced-dimensional feature matrix. To the nth local nearest neighbor scale The standard deviation of the local reachability density of all sample points is given by ϵ, where ϵ is the smoothing constant.

3. The accelerator anomaly detection method based on density and multi-scale LOF fusion according to claim 1, characterized in that, The formula for calculating the final anomaly score is as follows: ; ; In the formula, i is the index of the sample point. For sample points The final anomaly score in the reduced-dimensional feature matrix, where α is the adaptive fusion weight. For sample points The normalized global outlier score, For sample points The normalized multiscale LOF score, where h is the adjustment coefficient. For sample points of Locally achievable density in the vicinity For sample points The number of nearest neighbor samples, This is a preset density threshold.

4. The accelerator anomaly detection method based on density and multi-scale LOF fusion according to claim 1, characterized in that, The m local nearest neighbor scales , ,…and This includes the number of neighboring samples for each sample point.

5. The accelerator anomaly detection method based on density and multi-scale LOF fusion according to claim 1, characterized in that, The method for setting the preset anomaly detection threshold is as follows: based on the historical operating data of the linear accelerator, calculate the maximum value of the final anomaly score when the linear accelerator is operating normally. And the minimum value of the final abnormal score when the linear accelerator is running abnormally. Set a preset anomaly detection threshold. for .

6. An accelerator anomaly detection system based on density and multi-scale LOF fusion, used to implement the accelerator anomaly detection method based on density and multi-scale LOF fusion as described in claim 1, characterized in that, include: The data acquisition module is used to collect key operating parameters of the linear accelerator in real time. The standardization processing module is used to reduce noise and normalize the key operating parameters to obtain a standardized parameter matrix; The feature dimensionality reduction module is used to reduce the dimensionality of the standardized parameter matrix to obtain the dimensionality-reduced feature matrix. The global outlier density estimation module is used to calculate the global density and global outlier score of each sample point in the dimensionality-reduced feature matrix; The multi-scale local anomaly factor LOF calculation module is used to calculate the local reachability distance, local reachability density, single-scale local anomaly factor LOF value, and multi-scale LOF score for each sample point in the dimensionality-reduced feature matrix. The anomaly detection module is used to calculate the normalized global anomaly score and the normalized multi-scale LOF score of each sample point based on the global anomaly score and the multi-scale LOF score of each sample point; calculate the final anomaly score of each sample point in the dimensionality reduction feature matrix based on the normalized global anomaly score and the normalized multi-scale LOF score; and determine whether the linear accelerator has an anomaly based on the final anomaly score and a preset anomaly detection threshold. If the final anomaly score of a sample point is less than the preset anomaly detection threshold, then it is determined that the linear accelerator has not experienced any anomalies. If the final anomaly score of a sample point falls within the threshold range of the preset anomaly discrimination threshold, it is determined that the linear accelerator may be malfunctioning, and the global anomaly score and multi-scale LOF score of the sample point that may be malfunctioning are output. If the final anomaly score of a sample point is greater than the preset anomaly discrimination threshold, the linear accelerator is determined to be abnormal, and the global anomaly score and multi-scale LOF score of the abnormal sample point are output.

Citation Information

Patent Citations

  • Cavity leakage monitoring method of medical cyclotron vacuum chamber

    CN119622218A

  • Subspace projection of multi-dimensional unsupervised machine learning models

    US20170147941A1