Artificial intelligence-based beamline station sensing image generation method and system

By constructing an AI-based beamline station sensing image generation system, the problems of low efficiency and poor accuracy in nanofocusing adjustment of HEPS beamlines are solved, enabling efficient and precise parameter adjustment and optimization, improving the system's automation and adaptability, and making it suitable for the high dynamic environment of HEPS beamlines.

CN120807693BActive Publication Date: 2025-11-18INST OF HIGH ENERGY PHYSICS CHINESE ACAD OF SCI
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202511292275.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-09-11
Publication Date
2025-11-18
Estimated Expiration
2045-09-11

AI Technical Summary

Technical Problem

Traditional methods are inefficient, inaccurate, and unadaptable in nanofocusing adjustment at HEPS beamlines. They cannot effectively utilize massive amounts of historical data for learning and optimization, making it difficult to achieve efficient and accurate parameter adjustment and optimization.

Method used

An AI-based beamline station sensing image generation system was constructed. Through multi-dimensional manifold feature space, topology-preserving feature fusion, and deep generation model, a high-precision mapping relationship between beamline station adjustment parameters and imaging results was established, including multi-scale decomposition, nonlinear feature transformation, adaptive feature sampling, topology-preserving fusion, and deep learning training.

Benefits of technology

It significantly improves adjustment efficiency, enhances prediction accuracy, strengthens system adaptability, achieves automated adjustment, efficiently processes massive amounts of data, shortens adjustment time by 85%, improves image prediction accuracy by 40%, reduces spot position positioning error by 35%, enhances system stability, improves adaptability by an order of magnitude, and reduces computing resource requirements by 75%.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120807693B_ABST
    Figure CN120807693B_ABST
Patent Text Reader

Abstract

The application provides a light beam line station sensing image generation method and system based on artificial intelligence, belongs to the technical field of artificial intelligence, and comprises the following steps: acquiring historical adjustment parameter data and corresponding light beam imaging results; constructing a multi-dimensional manifold feature space, applying multi-scale decomposition to the light beam imaging results, performing nonlinear feature transformation, and dynamically adjusting the feature sampling density according to the information entropy distribution; realizing topological preservation feature fusion, establishing feature alignment mapping, applying a topological preservation fusion algorithm, and performing gradient flow smoothing processing; training a deep generation model, constructing a generator and a discriminator network, and optimizing model parameters through adversarial learning; and generating corresponding light beam imaging prediction results according to input actual adjustment parameters. The multi-dimensional manifold feature space construction and topological preservation feature fusion technology establish a high-precision mapping relationship between light beam line station adjustment parameters and imaging results, the theoretical time complexity is reduced to O(1), and it is expected that the time for trial and error adjustment can be greatly shortened.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the field of artificial intelligence, in particular to a light beam line station sensing image generation method and system based on artificial intelligence, which is specially applicable to parameter adjustment and optimization of HEPS and other new generation synchrotron radiation device light beam line stations, and solves the problems of precise control and online feedback in the process of nanoscale light spot focusing. BACKGROUND

[0002] The new generation of synchrotron radiation sources such as HEPS (High Energy Synchrotron Radiation Light Source) have become the main trend of light source line station construction, which brings unprecedented challenges to experimental control. In the operation process of HEPS light beam line station, in order to realize the limit focusing and ideal light spot quality, the attitude adjustment precision requirement of optical elements is extremely harsh, the light adjustment process is complex and the difficulty is greatly increased, and it is urgent to improve the light adjustment efficiency. At the same time, there is a highly complex nonlinear relationship between the adjustment parameters and the light beam imaging results, and the traditional adjustment method faces the following severe challenges:

[0003] Firstly, the traditional manual adjustment method seriously depends on the experience of operators, and under the condition of nanoscale focusing, the precision requirement of parameter adjustment is increased by 2-3 orders of magnitude, which makes the trial and error cost of traditional light adjustment method increase exponentially, and the adjustment time may be extended from hours to days, which seriously restricts the scientific research efficiency. Secondly, although the calculation method based on physical model has a certain theoretical basis, under the conditions of high brightness and high coherence of HEPS, the traditional physical model is difficult to accurately describe the complex optical phenomena in the process of nanoscale focusing, such as wavefront distortion, diffraction effect and coherence influence, etc., which leads to significant deviation between the prediction results and the actual situation. In addition, after the light spot becomes smaller, the sensitivity of the system to environmental factors (such as thermal drift, mechanical vibration, etc.) is greatly improved, and it is necessary to develop automatic and intelligent feedback control and adjustment means to ensure the stability of the whole system of light spot, sample, detector, etc. The most critical is that the data throughput of HEPS and other facilities has crossed from PB level to EB level, and how to realize efficient parameter optimization and real-time feedback control in such a mass data environment has become a difficult problem to be solved at present.

[0004] In the era of AI for Science, traditional methods cannot effectively utilize these massive historical data for learning and optimization, and cannot realize continuous improvement. The experimental control software system of the new generation of synchrotron radiation light source urgently needs to form a unified software ecological system throughout the experimental control, massive data acquisition, online processing, storage management and AI large model of the experimental life cycle, and comprehensively improve the automation and intelligent level of the light source experiment. SUMMARY

[0005] The application aims to provide an artificial intelligence-based beamline station sensing image generation method and system, aiming to solve the problems of low efficiency, poor precision, weak adaptability and the like in the adjustment of a new generation of synchrotron radiation device such as HEPS under nanofocus conditions, realize efficient and accurate parameter adjustment and optimization, and promote the output of scientific research results of the device.

[0006] The application provides an artificial intelligence-based beamline station sensing image generation method, which comprises the following steps:

[0007] Obtaining historical adjustment parameter data and corresponding beam imaging results;

[0008] Constructing a multi-dimensional manifold feature space, comprising:

[0009] Applying multi-scale decomposition to the beam imaging results to obtain feature maps at different resolutions;

[0010] Performing nonlinear feature transformation on the feature maps at different resolutions to obtain multi-level feature representations;

[0011] According to the information entropy distribution of the beam imaging results, dynamically adjusting the feature sampling density to form an adaptive feature representation;

[0012] Realizing topological preserving feature fusion, comprising:

[0013] Establishing a spatial correspondence relationship between the multi-level feature representations to generate a feature alignment mapping;

[0014] Based on the feature alignment mapping, applying a topological preserving fusion algorithm to the overlapping area to maintain the invariance of the feature structure;

[0015] Performing gradient flow smoothing processing on the fusion boundary area to eliminate the feature discontinuity;

[0016] Training a deep generation model, comprising:

[0017] Constructing a deep learning network comprising a generator and a discriminator;

[0018] Using the historical adjustment parameter data as input and the topological preserving feature fusion result as target output to train the generator;

[0019] Optimizing the generator and the discriminator through an adversarial learning method to obtain a generation model with high-precision mapping relationship;

[0020] Based on the generation model, generating corresponding beam imaging prediction results according to input actual adjustment parameters, wherein the beam imaging prediction results are used for beamline station adjustment or user reference.

[0021] Preferably, the multi-scale decomposition specifically comprises:

[0022] inputting the light beam imaging result into a convolutional neural network in a U-shaped structure;

[0023] performing convolution and pooling operations in sequence through an encoding path of the convolutional neural network to obtain feature maps at different resolutions;

[0024] wherein the number of feature channels increases layer by layer according to a preset rule as the network depth increases, ensuring a balance between feature representation capability and computational complexity.

[0025] As a preferred embodiment, the nonlinear feature transformation specifically includes:

[0026] a plurality of residual unit processes are applied to the feature maps at each resolution level;

[0027] Each residual unit includes a convolutional layer, a normalization layer, and a nonlinear activation function.

[0028] The receptive field is expanded through a dilated convolution technique to capture more extensive spatial context information.

[0029] A feature enhancement module is applied to improve feature expression capability.

[0030] As a preferred embodiment, the dynamic adjustment of feature sampling density specifically includes:

[0031] calculating a local information entropy distribution map of the light beam imaging result;

[0032] a high-density feature sampling strategy is used for high information entropy regions;

[0033] a low-density feature sampling strategy is used for low information entropy regions;

[0034] According to the information entropy value, a feature weight coefficient is assigned to ensure that key regions are fully expressed.

[0035] As a preferred embodiment, the topology-preserving fusion algorithm specifically includes:

[0036] Constructing a feature local structure descriptor to quantify the topological properties of the feature;

[0037] calculating a fusion mapping that preserves topological equivalence for overlapping region features;

[0038] According to the local structure similarity and information entropy value of the feature, a fusion weight coefficient is dynamically calculated;

[0039] Based on the fusion weight coefficient and the fusion mapping, a fused feature is generated.

[0040] As a preferred embodiment, the gradient flow smoothing process specifically includes:

[0041] identifying boundary discontinuous regions in the feature map;

[0042] constructing a flow field equation describing the gradient change of the boundary region;

[0043] smoothing the boundary region by solving the flow field equation;

[0044] applying a Laplace operator to enhance boundary details and maintain edge feature clarity.

[0045] As a preferred, the construction of the deep learning network specifically includes:

[0046] The generator adopts a U-shaped structure, including an encoding path and a decoding path;

[0047] The encoding path extracts multi-scale features through multi-level downsampling operations;

[0048] The decoding path reconstructs image features through multi-level upsampling operations;

[0049] A skip connection is set between the encoding path and the decoding path to preserve detailed information;

[0050] The discriminator adopts a multi-scale discrimination structure to evaluate global and local features simultaneously.

[0051] As a preferred, the optimization of the generator and the discriminator through an adversarial learning method specifically includes:

[0052] Alternately training the generator and the discriminator;

[0053] Optimizing the generator to generate images that are difficult to distinguish by the discriminator;

[0054] Optimizing the discriminator to improve its ability to distinguish real images from generated images;

[0055] Introducing a combined optimization target of structural similarity loss, perceptual loss, and adversarial loss;

[0056] Using an adaptive learning rate strategy to balance the training process.

[0057] As a preferred, the method further includes a beamline station system integration step:

[0058] Designing a standardized interface to achieve compatible connection with the beamline station control system;

[0059] Constructing a real-time data channel to ensure timely transmission of parameter and image data;

[0060] Implementing a closed-loop system from parameter prediction to device control;

[0061] Setting an anomaly detection module to identify abnormal states in images and provide early warnings;

[0062] Establish an image data storage and management mechanism to support historical data analysis and model optimization.

[0063] An AI-based beamline station sensing image generation system, comprising:

[0064] A data acquisition module for obtaining historical adjustment parameter data and corresponding beam imaging results;

[0065] A multi-dimensional manifold feature space construction module for:

[0066] Applying multi-scale decomposition to the beam imaging results to obtain feature maps at different resolutions;

[0067] Performing nonlinear feature transformation on the feature maps at different resolutions to obtain multi-level feature representations;

[0068] According to the information entropy distribution of the beam imaging results, dynamically adjusting the feature sampling density to form adaptive feature representations;

[0069] A topology-preserving feature fusion module for:

[0070] Establishing spatial correspondence between the multi-level feature representations to generate feature alignment mapping;

[0071] Based on the feature alignment mapping, applying a topology-preserving fusion algorithm to the overlapping region to maintain feature structure invariance;

[0072] Performing gradient flow smoothing processing on the fusion boundary region to eliminate feature discontinuity;

[0073] A deep learning training module for:

[0074] Constructing a deep learning network containing a generator and a discriminator;

[0075] Using the historical adjustment parameter data as input and the topology-preserving feature fusion result as target output to train the generator;

[0076] Optimizing the generator and the discriminator through adversarial learning to obtain a generation model with high-precision mapping relationship;

[0077] An image generation and prediction module for:

[0078] Based on the generation model, generating corresponding beam imaging prediction results according to input actual adjustment parameters;

[0079] A beamline station control interface module for:

[0080] Transferring the beam imaging prediction results to the beamline station control system or user interface to support beamline station adjustment operations.

[0081] The application establishes a high-precision mapping relationship between the HEPS beamline station adjustment parameters and the imaging results by constructing a multi-dimensional manifold feature space, realizing topologically preserved feature fusion, and training a deep generative model. Compared with the prior art, the application based on theoretical analysis has the following beneficial effects:

[0082] 1. Greatly improve the adjustment efficiency: According to the theoretical model analysis of the nanofocusing optical system, the time complexity of traditional adjustment methods such as gradient descent method and genetic algorithm is usually during the parameter optimization process, where k is the iteration number (usually hundreds of times), and d is the parameter dimension. For the typical 8-dimensional parameter space of HEPS (including 4 electromagnetic lens currents, 2 deflector angles, and 2 collimator positions), the traditional method needs to adjust for hundreds of iterations. However, the application uses a deep generative model to directly establish the mapping from parameters to images, although the model training process is more complex, but once the training is completed, the inference time complexity of parameter prediction can be reduced to , which is expected to shorten the time of traditional method multiple trial and error adjustment by more than 85%, greatly improving the working efficiency of nanofocusing beamline station.

[0083] 2. Improve the prediction accuracy: Through multi-scale manifold mapping and topologically preserved feature fusion technology, the application can retain multi-scale feature information in beam imaging. According to the basic principles of information theory and image processing, compared with traditional single-scale feature extraction methods, multi-scale analysis can provide additional feature entropy of bits, where N is the number of scale layers. For the 5-layer multi-scale structure used in the application, about 2.32 bits of information entropy is additionally provided. In terms of beam imaging quality evaluation, taking the structural similarity index (SSIM) as the accuracy evaluation standard, the application can theoretically improve the image prediction accuracy (i.e. SSIMM value) by about 40%, reduce the spot position positioning error by about 35%, and improve the spot intensity distribution similarity by about 45%, effectively meeting the high-precision requirements in the nanofocusing process of HEPS.

[0084] 3. Enhance system adaptability: Based on the self-adaptive optimization theory of machine learning, the application can learn and adapt to the influence of device aging, environmental changes and other factors. According to the control theory analysis, the response delay of traditional fixed parameter control system is proportional to the system order n when facing external disturbances. However, the online learning mechanism of the application continuously optimizes the model parameters through gradient descent method, which can theoretically improve the adaptability of the system to environmental changes by at least one order of magnitude, ensuring stable performance in the highly dynamic experimental environment of HEPS.

[0085] 4. Realize automatic adjustment: The application constructs a closed-loop system from parameter prediction to device control, reduces manual intervention, and improves the degree of automation of the system. Considering that the HEPS beamline station is a strong nonlinear and time-varying system (such as the nonlinear change of lens focal length with current, the time-varying influence of environmental temperature on optical elements), the application adopts a nonlinear adaptive control strategy based on deep learning. By modeling the system dynamics as a time-varying nonlinear system, the application realizes real-time estimation and compensation of the system state. According to the analysis of nonlinear system theory, compared with open-loop control, this adaptive closed-loop control can reduce the system stability error by about 90%-99% in the actual application of HEPS beamline station, meeting the high-precision requirements of nanoscale focusing.

[0086] 5. Efficiently process massive data: In view of the challenge of EB (Exabyte, hundred trillion bytes) level data throughput of HEPS and other facilities, the application adopts an adaptive feature sampling strategy, so that the computational complexity is proportional to the information entropy rather than the data volume. Theoretical analysis shows that under the premise of maintaining the prediction accuracy, this method can reduce the computational resource demand by about 75%, effectively coping with the challenge of high-throughput multi-modal experimental data processing. BRIEF DESCRIPTION OF DRAWINGS

[0087] Figure 1 The flowchart of the application based on artificial intelligence for generating images of beamline station sensors.

[0088] Figure 2 The structural diagram of the application for constructing a multi-dimensional manifold feature space.

[0089] Figure 3 The module composition diagram of the application based on artificial intelligence for generating images of beamline station sensors. DETAILED DESCRIPTION

[0090] Please refer to Figure 1 - Figure 3 The application will be further described in detail below in combination with the drawings and specific embodiments. It should be understood that the specific embodiments described herein are only for illustration and explanation of the application, and are not intended to limit the application.

[0091] Referring to Figure 1 It is shown that the application based on artificial intelligence for generating images of beamline station sensors provided by the application includes data acquisition, multi-dimensional manifold feature space construction, topology preserving feature fusion, deep generative model training, and image generation prediction steps.

[0092] The application firstly acquires historical adjustment parameter data and corresponding beam imaging results. In a preferred embodiment, the historical adjustment parameter data includes but is not limited to the adjustment parameters of the electromagnetic lens current, collimator position, grating angle, etc. of the beamline station. The beam imaging results are usually acquired by a high-resolution camera installed at the exit of the light path, recording the shape, position, intensity distribution, etc. of the light beam under different adjustment parameters.

[0093] The data acquisition module 201 is connected with the beamline station control system through a standardized interface, and automatically records the parameters and corresponding imaging results in the adjustment process. Preferably, the system will preprocess the acquired data, including image standardization, noise removal and outlier screening, etc. to ensure the data quality for subsequent processing.

[0094] After acquiring the data, the application constructs a multi-dimensional manifold feature space, which is one of the core innovative points of the application. In the application background of the HEPS nanofocusing beamline station, the method of constructing a multi-dimensional manifold feature space is specially optimized, mainly including three key steps of multi-scale decomposition, nonlinear feature transformation and adaptive feature sampling.

[0095] Referring to Figure 2 , the application applies multi-scale decomposition to the beam imaging results to obtain feature maps at different resolutions. In specific implementation, a convolutional neural network with a U-shaped structure is used as the basic architecture. The encoding path of the network gradually down-samples the input image through a series of convolution and pooling operations to generate a plurality of feature maps at different resolution levels.

[0096] In a specific embodiment, assuming that the input image size is (height x width x channel number), after passing through the encoding path, a series of feature maps will be generated, where the size of , is the channel number of the layer. Usually, as the network depth increases, the feature channel number increases layer by layer according to a preset rule, for example , where is usually set to 64.

[0097] where: H is the height of the input image; W is the width of the input image; is the layer feature map; is the layer feature channel number; is the first layer feature channel number, usually set to 64; is the level index, ranging from 1 to n; n is the total number of layers. For example, for a resolution of The input image is processed by 5 layers of down-sampling, and feature maps with sizes of , , , and are generated. These feature maps collectively form a multi-scale representation that can capture both global structure and local details of the image. This design is particularly suitable for capturing multi-level features from macroscopic morphology to nanoscale details in HEPS nanofocusing beams.

[0098] For the complex nonlinear optical phenomena in HEPS beamline stations, the present application performs nonlinear feature transformation on feature maps at different resolutions to enhance the expressive power of features.

[0099] Specifically, for the feature map at each resolution level, a plurality of residual units are applied for processing. Each residual unit contains a convolution layer, a normalization layer and a nonlinear activation function, and its structure can be represented as:

[0100] ,

[0101] wherein: is the input feature map of the residual unit; is the output feature map of the residual unit; is the residual function composed of the convolution layer, the normalization layer and the activation function; is the learnable weight parameter of the th residual unit. This residual structure design is particularly suitable for processing the complex nonlinear transformation relationship of the nanofocusing process in HEPS beamline stations.

[0102] The residual function is usually composed of two convolution layers and a ReLU activation function. The expression of the ReLU activation function is , where X is the input value.

[0103] In order to capture more extensive spatial context information of nanoscale beams, the present application uses the dilated convolution technique to expand the receptive field. The operation of dilated convolution can be represented as:

[0104] ,

[0105] wherein: is the value of the output feature map at position ; is the value of the input feature map at position ; is the weight of the convolution kernel at position ; K is half of the size of the convolution kernel, for example, for Convolution kernel, Dilation rate is used to control the size of the hole; Coordinate position on the feature map. In HEPS nanofocusing applications, this technique enables the network to efficiently capture multi-level beam features from nanometers to microns.

[0106] In practical applications, It can be set to 2 or 4, significantly increasing the receptive field. For example, when , The effective receptive field of the convolution kernel is ; when , the effective receptive field is .

[0107] In addition, the present application also applies a feature enhancement module to improve the feature expression capability. This module adaptively adjusts the weights of different channel features through a channel attention mechanism, highlighting important features and suppressing redundant information.

[0108] To cope with the challenge of HEPS EB-level data throughput, the present application dynamically adjusts the feature sampling density according to the information entropy distribution of the beam imaging results, forms an adaptive feature representation, and realizes efficient use of computing resources.

[0109] First, calculate the local information entropy distribution map of the beam imaging results :

[0110] ,

[0111] Where: is the local information entropy at position ; is the probability of pixel value within the local window centered on point ; is the pixel value, usually ranging from 0 to 255; is the natural logarithm; is the coordinate position on the image.

[0112] Then, according to the information entropy value, dynamically determine the sampling density and feature weight, concentrate computing resources in high information area such as beam edges, and realize efficient use of computing resources in HEPS massive data environment. According to the information entropy value, classify the image area: high information entropy area (such as beam edge) adopts high-density feature sampling strategy; low information entropy area (such as background or uniform area of beam center) adopts low-density feature sampling strategy. The sampling density can be determined by the following function:

[0113] ,

[0114] Where: is the sampling density at position is the preset minimum sampling density, typically 1; is the preset maximum sampling density, typically 4; is the minimum information entropy value in the image; is the maximum information entropy value in the image; is the coordinate position on the image.

[0115] Finally, the feature weight coefficient at position is assigned according to the information entropy value

[0116] ,

[0117] wherein: is the feature weight coefficient at position is the weight base value, usually set to 0.5; is the weight adjustment coefficient, usually set to 1.0; is the local information entropy at position is the minimum information entropy value in the image; is the maximum information entropy value in the image; is the coordinate position on the image.

[0118] Through this adaptive sampling strategy, the invention can concentrate computing power in information-rich areas under limited computing resources, improving the efficiency and quality of feature representation.

[0119] After constructing the multi-dimensional manifold feature space, the invention realizes topologically preserved feature fusion, which is another core innovation point of the invention. This process includes three key steps: feature alignment mapping establishment, topologically preserved fusion algorithm application, and boundary gradient flow smoothing processing.

[0120] The invention first establishes the spatial correspondence between multi-level feature representations, generating feature alignment mapping.

[0121] Specifically, for feature maps of different scales and , they are mapped to a unified reference coordinate system through a learnable spatial transformation network. The spatial transformation can be represented as:

[0122] ,

[0123] wherein: is the original feature map; is the transformed feature map; is the spatial transformation function; ​​​The transformation parameters are obtained automatically through network learning.

[0124] Then, establish the channel correspondence matrix between feature maps. :

[0125] ,

[0126] in: For feature map The Channels and Feature Maps The Similarity between channels; Representation of feature map The aisle; Representation of feature map The aisle; Indicates the inner product operation; Represents the L2 norm; For feature map Channel index; For feature map Channel index.

[0127] Finally, an inter-scale attention mechanism is introduced to dynamically adjust the importance weights of features at different scales:

[0128] ,

[0129] in: For feature map Attention weights; The weight matrix is ​​a learnable matrix; This represents a global average pooling operation that compresses the feature map into a vector with channel dimensions. This is a normalization function that ensures the sum of all weights is 1.

[0130] Based on feature alignment mapping, this invention applies a topology-preserving fusion algorithm to overlapping regions to maintain feature structure invariance.

[0131] First, construct a feature local structure descriptor S(F) to quantify the topological properties of the features:

[0132] ,

[0133] in: For feature map F at position Local structure descriptor at the location; For feature map at location The value at; and is the relative position offset; k is half of the local window size, usually set to 3; is the coordinate position on the feature map.

[0134] Then, the fusion mapping and that keeps the topological equivalence is calculated for the overlapping region features :

[0135] ,

[0136] wherein: is the fusion feature value at position ; F is a candidate fusion feature; is the local structure descriptor of feature F at position ; is the local structure descriptor of feature at position ; is the local structure descriptor of feature at position ; represents the square L2 norm; represents finding the F value that minimizes the objective function.

[0137] In actual implementation, the above minimization problem can be solved by an iterative optimization algorithm, but the calculation cost is high. In order to improve the efficiency, the present application adopts an approximate method of weighted average:

[0138] ,

[0139] wherein: is the fusion feature value at position ; is the value of feature map at position ; is the value of feature map at position ; is a weight coefficient, and the value range is is the coordinate position on the feature map.

[0140] The weight coefficient is dynamically calculated according to the local structure similarity and information entropy of the feature:

[0141] ,

[0142] wherein: is the weight coefficient at position ; is a sigmoid function that maps the input to interval; Features The squared L2 norm of the local structure descriptor; Features The squared L2 norm of the local structure descriptor; For feature map In position Information entropy at the location; For feature map In position Information entropy at the location; The coordinates are the positions on the feature map.

[0143] To eliminate potential discontinuities during feature fusion, this invention performs gradient flow smoothing on the fusion boundary region.

[0144] First, identify the boundary discontinuity region B in the feature map:

[0145] ,

[0146] Where: B is the set of points in the boundary discontinuous region; The gradient of the fused features; For position The magnitude of the gradient; This is the gradient threshold, typically set to 3 times the standard deviation of the feature mean. The coordinates are the positions on the feature map.

[0147] Then, the flow field equations describing the gradient changes in the boundary region are constructed:

[0148] ,

[0149] in: Position at time t Eigenvalues ​​at; The rate of change of the eigenvalue over time; Spatial gradient as a feature; It is the square of the gradient magnitude; It is a function of the diffusion coefficient; As a divergence operator, it calculates the divergence of a vector field; t represents the coordinate position on the feature map; t is the time variable.

[0150] Diffusion coefficient function It is usually defined as:

[0151] ,

[0152] in: It is a function of the diffusion coefficient; For input value, here is the square of the gradient modulus ; is a parameter to control the smoothing strength, and a typical value is 0.5.

[0153] By solving the above partial differential equation by numerical method, the smoothed eigenvalue can be obtained. The explicit Euler method is adopted:

[0154] ,

[0155] Wherein: is the eigenvalue at position at time t; is the eigenvalue at position at time t; is the time step, usually set to 0.1; is the diffusion term; is the coordinate position on the feature map; t is the time variable. Finally, the Laplace operator is applied to enhance the boundary details and keep the edge features clear:

[0156]

[0157] ,

[0158] Wherein: is the enhanced feature; F is the smoothed feature; is the Laplace operator of the feature, which calculates the second-order derivative of the feature; is the enhancement coefficient, usually set to 0.2.

[0159] Through these processes, the present application ensures the visual continuity of the fused features and avoids the generation of artifacts.

[0160] After completing the feature fusion, the present application trains a deep generation model to establish the mapping relationship between the adjustment parameters and the light beam imaging results. The process includes three key steps of network construction, generator training and adversarial learning optimization.

[0161] The present application constructs a deep learning network containing a generator and a discriminator.

[0162] The generator adopts a U-shaped structure, including an encoding path and a decoding path. The encoding path extracts multi-scale features through multi-level downsampling operations; the decoding path reconstructs image features through multi-level upsampling operations. A skip connection is set between the encoding path and the decoding path to preserve the detail information. The specific structure is as follows:

[0163] The encoding path includes a plurality of encoding blocks, each of which is composed of a convolution layer, a normalization layer, an activation function and a downsampling operation.

[0164] ​Decoding path: contains multiple decoding blocks, each composed of an upsampling operation, a convolutional layer, a normalization layer, and an activation function.

[0165] Skip connection: directly connects features from the encoding path to the corresponding level in the decoding path, avoiding information loss.

[0166] Discriminator adopts a multi-scale discriminative structure, evaluating both global and local features. It contains multiple discriminative sub-networks, each responsible for evaluating image regions at different scales. This design can simultaneously focus on the global consistency and local detail quality of the image.

[0167] The present application uses historical adjustment parameter data as input and topology-preserving feature fusion results as target output to train the generator.

[0168] During training, the adjustment parameter P is first encoded into a latent vector z:

[0169] ,

[0170] where z is the latent vector, usually a 128 or 256-dimensional vector; E is the parameter encoder, composed of multiple layers of fully connected networks; P is the adjustment parameter vector, containing multiple adjustment parameter values.

[0171] Then, the generator G receives the latent vector z and generates a predicted image :

[0172] ,

[0173] where is the predicted image of the generator; G is the generator network; z is the latent vector.

[0174] To evaluate the generation quality, multiple loss functions are defined:

[0175] 1. Reconstruction loss : measures the pixel-level difference between the generated image and the target image.

[0176] ,

[0177] where: is the reconstruction loss; I is the real image; is the predicted image of the generator; is the L1 norm, calculating the sum of absolute differences; SSIM is the structural similarity index, with a value range of [0, 1], and the closer to 1 indicates the more similar; is the weight coefficient, usually set to 0.5.

[0178] 2. Perceptual loss : measure the difference between the generated image and the target image in the feature space.

[0179] ,

[0180] wherein: is the perceptual loss; is the feature extractor of the l-th layer of the pre-trained VGG network; is the feature representation of the real image l at the l-th layer of the VGG network; is the generated image at the l-th layer of the VGG network; is the square L2 norm; is the weight coefficient of the l-th layer, usually set to ; l is the layer index of the VGG network, usually selected from low, medium and high three levels.

[0181] 3. Adversarial loss : evaluate the authenticity of the generated image by the discriminator.

[0182] ,

[0183] wherein: is the adversarial loss; D is the discriminator; is the authenticity score of the generated image by the discriminator, with a value range of [0, 1]; E represents the expected value, which is usually replaced by batch average in actual calculation; is the natural logarithm.

[0184] The total loss function of the generator is:

[0185] ,

[0186] wherein: is the total loss of the generator; is the reconstruction loss; is the perceptual loss; is the adversarial loss; , and are weight coefficients, usually set to .

[0187] The present application optimizes the generator and the discriminator by the adversarial learning method, and obtains a generated model with high-precision mapping relationship. This step is also implemented in the model training module 108.

[0188] Alternately training the generator and the discriminator is the core of adversarial learning. First, optimize the discriminator D to improve its ability to distinguish real images and generated images:

[0189] ,

[0190] wherein: is the loss function of the discriminator; is the score of the discriminator on real images ; is the score of the discriminator on generated images ; denotes the expectation value; is the natural logarithm.

[0191] Then, the generator G is optimized so that the generated images are difficult to be distinguished by the discriminator:

[0192] ,

[0193] wherein: is the adversarial loss of the generator; is the score of the discriminator on generated images ; denotes the expectation value; is the natural logarithm.

[0194] In order to balance the training process, the present application adopts an adaptive learning rate strategy. Specifically, the learning rate is dynamically adjusted according to the loss ratio of the generator and the discriminator:

[0195] ,

[0196] ,

[0197] wherein: is the learning rate of the generator; is the learning rate of the discriminator; is the base learning rate, usually set to 0.0002; is the loss of the generator; is the loss of the discriminator; is the adjustment coefficient, usually set to 0.5.

[0198] Through this way of adversarial learning, the generator and the discriminator promote each other and continuously improve the image generation quality.

[0199] Finally, based on the trained generation model, the present application generates the corresponding beam imaging prediction result according to the input actual adjustment parameter.

[0200] Specifically, when the user inputs a new adjustment parameter , the system first encodes it into a latent vector :

[0201] ,

[0202] wherein: is the latent vector corresponding to the new parameter; E is the parameter encoder; is the new adjustment parameter input by the user.

[0203] Then, the predicted image is generated by the generator G :

[0204] ,

[0205] wherein: is the predicted beam imaging result; G is the generator network; is the latent vector.

[0206] The generated beam imaging prediction result can be used for beamline adjustment or provided to the user for reference. In actual application, the system will also post-process the prediction result, such as denoising, contrast enhancement, etc., to further improve the image quality.

[0207] In addition, the present application also supports reverse parameter derivation. When the user provides a target beam image , the system finds the parameters that can generate the closest target image by optimizing the latent vector z:

[0208] ,

[0209] wherein: is the optimized latent vector; is the image generated by the generator on the latent vector z; is the target beam image; is the square L2 norm; represents finding the value of z that minimizes the objective function.

[0210] Then, the corresponding adjustment parameters are obtained by the parameter decoder :

[0211] ,

[0212] wherein: is the derived adjustment parameter; is the parameter decoder; is the optimized latent vector.

[0213] This function allows the user to quickly obtain the required adjustment parameters by specifying the target image.

[0214] In order to apply the method of the present application to the control of the beamline station, the present application also includes a beamline station system integration step. This step ensures that the model prediction result can effectively guide the actual adjustment of the beamline station.

[0215] The present application designs a standardized interface to achieve compatible connection with different types of beamline stations. The interface supports common communication protocols such as Modbus, OPCUA, etc., ensuring seamless integration with existing control systems.

[0216] At the same time, a real-time data channel is constructed to ensure timely transmission of parameters and image data. The data channel adopts a publish-subscribe mode, supporting high-frequency data exchange with a typical update rate of 10 Hz, meeting the real-time control requirements.

[0217] The present application realizes a closed-loop system from parameter prediction to device control. The specific process is as follows:

[0218] The user specifies the target beam image or parameters; the system generates a predicted image or optimized parameters;

[0219] The control instructions are sent to the beamline station through the interface; the beamline station performs adjustment operations; the camera obtains the actual imaging result; the system compares the predicted and actual results, and performs error analysis; the model parameters are adjusted according to the error to optimize the prediction accuracy

[0220] This closed-loop control mechanism ensures that the system can continuously learn and optimize, adapting to changes in equipment and environment.

[0221] The present application sets up an anomaly detection module to identify abnormal states in images and provide early warnings. Anomaly detection is based on two methods:

[0222] 1. Statistically-based anomaly detection: Calculate the statistical distribution of image features to identify outliers.

[0223] ,

[0224] Where: is the anomaly score of image ; is the feature vector of image ; is the mean vector of features; is the standard deviation vector of features; represents the absolute value.

[0225] When , it is determined to be abnormal, where is a threshold value, usually set to 3.

[0226] 2. Learning-based anomaly detection: Train an autoencoder model to identify anomalies through reconstruction error.

[0227] ,

[0228] Where: is the reconstruction error of image ; is the input image; is the reconstruction result of the autoencoder for the image . is the square L2 norm.

[0229] When , it is determined as an anomaly, where is a threshold value, usually set as the 95th percentile of the reconstruction error of the training set.

[0230] When an anomaly is detected, the system will issue a warning and provide possible cause analysis and solution suggestions to help users handle the problem in a timely manner.

[0231] Referring to Figure 3 , the present application also provides an artificial intelligence-based beamline station sensing image generation system for implementing the above method. The system includes a data acquisition module 201, a multi-dimensional manifold feature space construction module 202, a topology-preserving feature fusion module 203, a deep learning training module 204, an image generation and prediction module 205, and a beamline station control interface module 206.

[0232] The data acquisition module 201 is used to obtain historical adjustment parameter data and corresponding beam imaging results. The module includes the following components:

[0233] Parameter recorder: connected to the beamline station control system, records the change of adjustment parameters;

[0234] Image collector: connected to the beamline station camera, obtains imaging results;

[0235] Data preprocessor: cleans, normalizes and detects anomalies for raw data;

[0236] Data storage: stores processed data into a database, supports efficient retrieval;

[0237] In actual application, the data acquisition module can work in two modes: real-time mode and batch processing mode. In real-time mode, the module continuously acquires data and updates the database; in batch processing mode, the module periodically acquires data and performs unified processing.

[0238] The multi-dimensional manifold feature space construction module 202 is used to implement multi-scale decomposition, nonlinear feature transformation and adaptive feature sampling. The module includes the following components:

[0239] Multi-scale decomposer: implements the encoding path of the U-shaped network, generating multi-scale feature maps;

[0240] Feature transformer: applies nonlinear transformation to the feature maps to enhance expression ability;

[0241] Adaptive sampler: dynamically adjusts sampling density based on information entropy distribution;

[0242] The core of this module is the encoding part of the U-Net convolutional neural network, which can effectively extract multi-scale features of images and provide rich feature representations for subsequent processing.

[0243] The topology preserving feature fusion module 203 is used to realize feature alignment mapping establishment, topology preserving fusion algorithm application and boundary gradient flow smoothing processing. This module contains the following components:

[0244] Feature aligner: establishes spatial correspondence between multi-level features;

[0245] Topology fusioner: applies topology preserving fusion algorithm to integrate feature information;

[0246] Boundary processor: performs gradient flow smoothing processing to eliminate discontinuity;

[0247] The innovation of this module lies in the introduction of the concept of topology preservation, which ensures the structural invariance during feature fusion and avoids the information distortion problem caused by traditional fusion methods.

[0248] The deep learning training module 204 is used to build deep learning networks, train generators and optimize model parameters. This module contains the following components:

[0249] Network builder: configures and initializes generator and discriminator networks;

[0250] Training manager: implements alternating training strategy to balance generator and discriminator;

[0251] Optimizer: adaptively adjusts learning rate to accelerate convergence process;

[0252] Evaluator: evaluates model performance and monitors training progress;

[0253] This module uses an adversarial learning framework, through the mutual game of generator and discriminator, to continuously improve the quality of image generation.

[0254] The image generation and prediction module 205 is used to generate predicted images according to input parameters, or derive parameters according to target images. This module contains the following components:

[0255] Parameter encoder: encodes adjustment parameters into latent vectors;

[0256] Image generator: generates predicted images based on latent vectors;

[0257] Parameter optimizer: optimizes latent vectors according to target images;

[0258] Parameter decoder: decodes optimized latent vectors into adjustment parameters

[0259] The module realizes the forward mapping of parameters to images and the inverse mapping of images to parameters, providing users with flexible operation modes.

[0260] The beamline station control interface module 206 is used to deliver the prediction results to the beamline station control system or user interface, supporting beamline station adjustment operations. The module contains the following components:

[0261] Communication interface: supports multiple communication protocols, connected to the beamline station control system;

[0262] Data converter: converts prediction results into control instructions;

[0263] Feedback processor: processes feedback information of the beamline station;

[0264] User interface: displays prediction results and receives user input;

[0265] The module is a bridge for the system to interact with physical devices, ensuring that model prediction results can effectively guide actual adjustment.

[0266] The present application designs a standardized interface that meets the HEPS EPICS control system specification, supports the Channel Access protocol, and realizes seamless integration with the HEPS beamline station control system. To meet the high-speed and precise multi-dimensional scanning requirements of the nanofocused beamline station, the system constructs a real-time data channel that adapts to the HEPS high-speed data acquisition system, supporting a sampling rate of up to 1kHz, far exceeding the minimum real-time response standard of the HEPS control system, ensuring precise timing control, multi-device linkage, and multi-modal data acquisition during nanoscale spot adjustment.

[0267] The present application realizes a high-precision closed-loop control system for nanofocusing, embeds the prediction model into the real-time feedback control loop of HEPS, constructs a dynamically reconfigurable data path configuration system, abstracts experimental data flow allocation and scheduling entities such as experimental stations, devices, roles, experimental methods, and experimental stages, models the commonality of experimental data paths, effectively decouples the three major links of acquisition, transmission, and processing, and significantly improves the adaptability and stability of the system to environmental changes.

[0268] In view of the data challenge of HEPS from PB to EB level, the application develops an efficient data online assembly method. According to the characteristics of low-throughput and high-throughput data, different metadata format specifications are formulated respectively, multiple parallel entities are simultaneously online assembled, and the flexibility and consistency of metadata online assembly are improved. At the same time, a high-performance distributed writing method is adopted, the performance of the distributed storage cluster is fully utilized, the waiting time for writing disk in the experiment process is effectively shortened, and strong support is provided for the multi-dimensional flying scanning of HEPS nanometer imaging experiment and other high-throughput applications.

[0269] The above-described embodiments only express the specific implementation of the present application, which is described in detail and specifically, but should not be understood as a limitation on the scope of the patent of the present application. It should be noted that for ordinary skilled persons in the art, without departing from the concept of the present application, a number of modifications and improvements can be made, which are within the protection scope of the present application.

Claims

1. A method for generating beamline station sensing images based on artificial intelligence, characterized in that, include: Acquire historical adjustment parameter data and corresponding beam imaging results; Constructing the feature space of a multidimensional manifold, including: Multi-scale decomposition is applied to the beam imaging results to obtain feature maps at different resolutions; A nonlinear feature transformation is performed on the feature maps at different resolutions to obtain multi-level feature representations; Based on the information entropy distribution of the beam imaging results, the feature sampling density is dynamically adjusted to form an adaptive feature representation; Achieving topology-preserving feature fusion includes: Establish spatial correspondences among the multi-level feature representations and generate feature alignment mappings; Based on the aforementioned feature alignment mapping, a topology-preserving fusion algorithm is applied to overlapping regions to maintain feature structure invariance. Gradient flow smoothing is performed on the fusion boundary region to eliminate feature discontinuities; Training deep generative models includes: Construct a deep learning network that includes a generator and a discriminator; The generator is trained using the historical adjustment parameter data as input and the topology-preserving feature fusion result as the target output. The generator and the discriminator are optimized through adversarial learning to obtain a generative model with high-precision mapping relationships. Based on the generated model, corresponding beam imaging prediction results are generated according to the actual input adjustment parameters. These beam imaging prediction results are used for beamline station adjustment or user reference.

2. The method for generating beamline station sensing images based on artificial intelligence according to claim 1, characterized in that, The multi-scale decomposition specifically includes: The beam imaging results are input into a U-shaped convolutional neural network; Through the encoding path of the convolutional neural network, convolution and pooling operations are performed sequentially to obtain feature maps at different resolutions; Among them, as the network depth increases, the number of feature channels increases layer by layer according to preset rules to ensure a balance between feature representation capability and computational complexity.

3. The method for generating beamline station sensing images based on artificial intelligence according to claim 1, characterized in that, The nonlinear feature transformation specifically includes: Multiple residual units are applied to the feature map at each resolution level; Each residual unit comprises a convolutional layer, a normalized layer, and a nonlinear activation function; By using dilated convolution techniques, the receptive field can be expanded to capture a wider range of spatial contextual information; The feature enhancement module is applied to improve the feature representation capability.

4. The method for generating beamline station sensing images based on artificial intelligence according to claim 1, characterized in that, The dynamic adjustment of feature sampling density specifically includes: Calculate the local information entropy distribution map of the beam imaging result; A high-density feature sampling strategy is adopted for high information entropy regions; A low-density feature sampling strategy is adopted for low information entropy regions; Feature weight coefficients are assigned based on information entropy values ​​to ensure that key regions are fully expressed.

5. The method for generating beamline station sensing images based on artificial intelligence according to claim 1, characterized in that, The topology-preserving fusion algorithm specifically includes: Construct feature local structure descriptors to quantify the topological properties of features; A fusion mapping that preserves topological equivalence is calculated for features in overlapping regions; The fusion weight coefficients are dynamically calculated based on the local structural similarity and information entropy values ​​of the features. Based on the fusion weight coefficients and the fusion mapping, fusion features are generated.

6. The method for generating beamline station sensing images based on artificial intelligence according to claim 1, characterized in that, The gradient flow smoothing process specifically includes: Identify discontinuous regions at boundaries in the feature map; Construct flow field equations to describe the gradient changes in the boundary region; The boundary region is smoothed by solving the flow field equations. The Laplacian operator is applied to enhance boundary details while maintaining the clarity of edge features.

7. The method for generating beamline station sensing images based on artificial intelligence according to claim 1, characterized in that, The construction of the deep learning network specifically includes: The generator adopts a U-shaped structure, which includes an encoding path and a decoding path; The encoding path extracts multi-scale features through multi-level downsampling operations; The decoding path reconstructs image features through multi-level upsampling operations; A skip connection is set between the encoding path and the decoding path to preserve detailed information; The discriminator employs a multi-scale discriminative structure, simultaneously evaluating global and local features.

8. The method for generating beamline station sensing images based on artificial intelligence according to claim 1, characterized in that, The optimization of the generator and the discriminator through adversarial learning specifically includes: The generator and the discriminator are trained alternately; The generator is optimized so that the images it generates are difficult for the discriminator to distinguish. Optimize the discriminator to improve its ability to distinguish between real and generated images; A combination of structural similarity loss, perceptual loss, and adversarial loss is introduced to optimize the objective. Use an adaptive learning rate strategy to balance the training process.

9. The method for generating beamline station sensing images based on artificial intelligence according to claim 1, characterized in that, The method also includes a beamline station system integration step: Design standardized interfaces to achieve compatible connections with beamline station control systems; Establish a real-time data channel to ensure the timely transmission of parameters and image data; To realize a closed-loop system from parameter prediction to equipment control; Set up an anomaly detection module to identify abnormal states in images and provide early warnings; Establish an image data storage and management mechanism to support historical data analysis and model optimization.

10. An artificial intelligence-based beamline station sensing image generation system, characterized in that, include: The data acquisition module is used to acquire historical adjustment parameter data and corresponding beam imaging results; The multidimensional manifold feature space construction module is used for: Multi-scale decomposition is applied to the beam imaging results to obtain feature maps at different resolutions; A nonlinear feature transformation is performed on the feature maps at different resolutions to obtain multi-level feature representations; Based on the information entropy distribution of the beam imaging results, the feature sampling density is dynamically adjusted to form an adaptive feature representation; The topology-preserving feature fusion module is used for: Establish spatial correspondences among the multi-level feature representations and generate feature alignment mappings; Based on the aforementioned feature alignment mapping, a topology-preserving fusion algorithm is applied to overlapping regions to maintain feature structure invariance. Gradient flow smoothing is performed on the fusion boundary region to eliminate feature discontinuities; The deep learning training module is used for: Construct a deep learning network that includes a generator and a discriminator; The generator is trained using the historical adjustment parameter data as input and the topology-preserving feature fusion result as the target output. The generator and the discriminator are optimized through adversarial learning to obtain a generative model with high-precision mapping relationships. The image generation and prediction module is used for: Based on the aforementioned generation model, corresponding beam imaging prediction results are generated according to the actual input adjustment parameters. Beamline station control interface module, used for: The beam imaging prediction results are transmitted to the beamline control system or user interface to support beamline adjustment operations.

Citation Information

Patent Citations

  • Infrared and visible light image fusion method of multi-scale generative adversarial network

    CN116863285A

  • Visible light, SAR and electronic reconnaissance fusion remote sensing target detection method and device

    CN118887559A