Modeling method and using method of proxy model

Through the method of sampling data based on errors and building proxy models, the high sampling cost and computational amount caused by large sample data in the prior art is solved, and an efficient modeling process and an accurate proxy model are realized.

CN120069101AActive Publication Date: 2025-05-30ZHUHAI SHUZHOU TECH CO LTD

Patent Information

Application Number
CN202510535541.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-04-27
Publication Date
2025-05-30
Estimated Expiration
2045-04-27

AI Technical Summary

Technical Problem

The prior art requires a large amount of sample data when modeling a proxy model of polynomial chaotic expansion, resulting in high sampling time and cost, and large calculation amount, which affects modeling efficiency.

Method used

By obtaining the initial sample data and its observations, the initial proxy model is determined, and data sampling is performed based on the error between the model and the real model, new sample data is obtained, and the target proxy model is gradually built.

Benefits of technology

Accurate sampling is realized, and important sample data is quickly captured, which reduces sampling time and cost, reduces the amount of calculation in subsequent modeling, improves modeling efficiency, and maintains the accuracy of the proxy model.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120069101A_ABST
    Figure CN120069101A_ABST
Patent Text Reader

Abstract

The invention discloses a modeling method and a using method of an agent model. The modeling method comprises the following steps: acquiring first sample data and a first observation value corresponding to the first sample data; determining an initial agent model corresponding to the to-be-fitted model problem based on the first sample data and the first observation value; taking the first sample data as model input, determining a first output value by using the initial agent model, and determining a first true value by using a true model matched with the to-be-fitted model problem; determining a first error between the first output value and the first true value; performing data sampling based on the first error to obtain second sample data, and determining a second observation value corresponding to the second sample data by using the real model; according to the method, the target agent model is constructed based on the first sample data, the first observation value, the second sample data and the second observation value, so that accurate sampling can be realized, important sample data can be quickly captured, the sampling time and cost are reduced, and then the calculation amount in the subsequent modeling process is reduced to improve the modeling efficiency.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the technical field of data processing, and particularly relates to a method for modeling and using a surrogate model. Background Art

[0002] Polynomial Chaos Expansion (PCE) is an interdisciplinary method and a powerful tool that combines probability theory, orthogonal polynomial theory, and uncertainty quantification. It is mainly used for modeling and analyzing the uncertainty of systems, such as for simulation analysis in fields such as engineering, physics, and finance. In particular, its application prospects in uncertainty quantification and simulation analysis of complex system modeling are very broad. A surrogate model is a class of simplified mathematical representations designed to replace the original computational model or simulator. In some cases, PCE can be regarded as a specially designed surrogate model.

[0003] In related technologies, usually for specific problems (such as engineering problems, physical problems, financial problems, etc.), existing sample data is used for fitting to model the corresponding surrogate model of polynomial chaos expansion. At this time, to ensure the accuracy of modeling, it is required that the amount of sampled data is large enough. However, requiring a large amount of sample data not only increases the sampling time and cost, but also greatly increases the computational amount in the modeling process because a large amount of sample data needs to be simulated and calculated after sampling is completed, affecting the modeling efficiency. Summary of the Invention

[0004] To solve the above technical problems, embodiments of this application propose a method for modeling and using a surrogate model, which can accurately sample to quickly capture important sample data, reduce the sampling time and cost, and then reduce the computational amount in the subsequent modeling process to improve the modeling efficiency, while taking into account the accuracy of the constructed surrogate model.

[0005] In a first aspect, embodiments of this application provide a method for modeling a surrogate model, including: Obtain first sample data and its corresponding first observation value; Based on the first sample data and the first observation value, determine an initial surrogate model corresponding to the problem of the model to be fitted; Use the first sample data as the model input, use the initial surrogate model to determine a first output value, and use the true model matching the problem of the model to be fitted to determine a first true value; Determine a first error between the first output value and the first true value; Based on the first error, perform data sampling to obtain second sample data, and use the true model to determine a second observation value corresponding to the second sample data; Construct a target surrogate model based on the first sample data, the first observation value, the second sample data, and the second observation value.

[0006] Optionally, the data sampling based on the first error to obtain the second sample data includes: Determine a sampling region according to the first error, where the geometric center of the sampling region is the maximum error sample point, and the maximum error sample point is the sample point corresponding to the maximum absolute value of the first error among the sample points included in the first sample data; Perform data sampling on the sampling region to obtain the second sample data.

[0007] Optionally, the sampling region is a circular region, where the center of the circular region is the maximum error sample point, and the radius of the circular region is determined based on a set ratio and the maximum absolute value of the first error, and the set ratio is less than 1 and greater than 0; The performing data sampling on the sampling region to obtain the second sample data includes: Perform uniform sampling on the circular region to obtain the second sample data.

[0008] Optionally, the data sampling based on the first error to obtain the second sample data includes: Generate a corresponding first probability distribution based on the first error; Perform data sampling based on the first probability distribution to obtain the second sample data.

[0009] Optionally, the first probability distribution includes a third probability distribution, and the generating a corresponding first probability distribution based on the first error includes: Normalize the absolute value of the first error to generate a second probability distribution based on the absolute error; Calculate Gaussian distribution parameters through maximum likelihood estimation according to the second probability distribution; Take the Gaussian distribution determined by the Gaussian distribution parameters as the third probability distribution.

[0010] Optionally, the first probability distribution includes a fourth probability distribution, and the generating a corresponding first probability distribution based on the first error includes: Normalize the absolute value of the first error to generate a second probability distribution based on the absolute error; Use a neural network-based probability generation model to simulate the fourth probability distribution according to the second probability distribution.

[0011] Optionally, determining an initial surrogate model corresponding to the problem of the model to be fitted based on the first sample data and the first observation value includes: Determine the polynomial corresponding to the problem of the model to be fitted, and determine the matrix corresponding to the polynomial; Based on the first sample data and the first observation value, use the least squares method to solve the matrix corresponding to the polynomial to obtain undetermined coefficients, and construct an initial surrogate model of polynomial chaos expansion according to the undetermined coefficients.

[0012] Optionally, constructing a target surrogate model based on the first sample data, the first observation value, the second sample data, and the second observation value includes: Merge the first sample data and the second sample data to obtain new first sample data, and merge the first observation value and the second observation value to obtain new first observation values, and thus repeat the steps of determining the initial surrogate model corresponding to the problem of the model to be fitted based on the first sample data and the first observation value and subsequent steps until the set conditions are met, and use the initial surrogate model determined last time as the target surrogate model.

[0013] Optionally, the error between the second sample data and the second observation value is the second error, where the set conditions include at least one of the following: The number of repeated executions reaches the adaptive number of times, where the adaptive number of times is preset, or the adaptive number of times is determined by at least one of the following: the maximum absolute value of the first error obtained for the first time, the maximum absolute value of the second error obtained for the first time; The accuracy of the initial surrogate model obtained most recently reaches the preset accuracy requirement.

[0014] In a second aspect, an embodiment of the present application provides a method for using a surrogate model, including: Obtain data to be processed and a target surrogate model, where the target surrogate model is constructed based on the modeling method described in any one of the above; Input the data to be processed into the target surrogate model, so that the target surrogate model performs corresponding target operations according to the data to be processed, where the target operations include at least one of the following: uncertainty quantification analysis, simulation.

[0015] In summary, the embodiments of the present application at least have the following beneficial effects: By adopting the embodiment of the present application, first sample data and its corresponding first observation value are obtained; based on the first sample data and the first observation value, an initial surrogate model corresponding to the problem of the model to be fitted is determined; using the first sample data as the model input, a first output value is determined by using the initial surrogate model, and a first true value is determined by using the true model that matches the problem of the model to be fitted; a first error between the first output value and the first true value is determined; data sampling is performed based on the first error to obtain second sample data, and the second observation value corresponding to the second sample data is determined by using the true model; based on the first sample data, the first observation value, the second sample data and the second observation value, a target surrogate model is constructed, so that accurate sampling can be performed to quickly capture important sample data, reduce the sampling time and cost, and then reduce the calculation amount in the subsequent modeling process to improve the modeling efficiency, while taking into account the accuracy of the constructed surrogate model. Description of the Drawings

[0016] Figure 1 is a schematic flowchart of a method for modeling a surrogate model provided by an embodiment of the present application; Figure 2 is a schematic diagram of the input and output of the true model provided by an embodiment of the present application; Figure 3 is a schematic diagram of the data distribution of the first sample data and its corresponding first observation value provided by an embodiment of the present application; Figure 4 is a schematic diagram of the initial surrogate model provided by an embodiment of the present application; Figure 5 is a schematic diagram of the absolute value of the first error provided by an embodiment of the present application; Figure 6 is a schematic diagram of all sample points finally obtained by sampling according to the probability distribution obtained from the error provided by an embodiment of the present application; Figure 7 is a schematic diagram of the target surrogate model provided by an embodiment of the present application; Figure 8 is another schematic diagram of the absolute value of the first error provided by an embodiment of the present application; Figure 9 is a schematic diagram of a sample point obtained after uniform sampling provided by an embodiment of the present application; Figure 10 is a schematic diagram of the true model of a two-dimensional problem provided by an embodiment of the present application; Figure 11 is a schematic diagram of all sample points finally obtained by sampling according to the probability distribution obtained from the error of a two-dimensional problem provided by an embodiment of the present application. Detailed Embodiment

[0017] Next, the technical solutions in the embodiments of the present application will be clearly and completely described in conjunction with the accompanying drawings in the embodiments of the present application. Obviously, the described embodiments are only a part of the embodiments of the present application, rather than all the embodiments. All other embodiments obtained by those of ordinary skill in the art based on the embodiments in the present application without creative efforts shall fall within the protection scope of the present application.

[0018] In the description of the present application, the terms "first", "second", "third", etc. are only used for descriptive purposes and cannot be understood as indicating or implying relative importance or implicitly specifying the quantity of the indicated technical features. Thus, features defined with "first", "second", "third", etc. may explicitly or implicitly include one or more of such features. In the description of the present application, unless otherwise specified, the meaning of "a plurality" is two or more. In the description of the present application, the term "comprising" and its variants are open-ended, that is, "including but not limited to". The term "based on" means "at least partially based on". The term "according to" means "at least partially according to". The term "one embodiment" means "at least one embodiment"; the term "another embodiment" means "at least one additional embodiment"; the term "some embodiments" means "at least some embodiments".

[0019] In the description of the present application, it should be noted that, unless otherwise clearly defined and limited, the terms "installed", "connected", "coupled" should be understood in a broad sense. For example, it may be a fixed connection, a detachable connection, or an integral connection; it may be a mechanical connection or an electrical connection; it may be directly connected or indirectly connected through an intermediate medium, and it may be the communication inside two elements. For those of ordinary skill in the art, the specific meanings of the above terms in the present application can be understood according to specific situations.

[0020] In the description of the present application, it should be noted that, unless otherwise defined, all the technical and scientific terms used in the present application have the same meanings as those commonly understood by those skilled in the technical field to which the present application belongs. The terms used in the specification of the present application are only for the purpose of describing specific embodiments and are not intended to limit the present application. For those of ordinary skill in the art, the specific meanings of the above terms in the present application can be understood according to specific situations.

[0021] In a first aspect, referring to Figure 1 , a flowchart of a method for modeling an agent model provided by an embodiment of the present application is shown. The method includes steps S101-S106, specifically as follows: S101, obtain first sample data and its corresponding first observation value.

[0022] In one example, the first sample data and the first observation values can be a small amount of initial sample data obtained by uniform distribution or Latin hypercube sampling and the corresponding observation values , where , is the number of sample points (i.e., initial samples) in the first sample data. It can be understood that both the first sample data and the first observation values correspond to the model fitting problem to be solved. Among them, the first sample data can be pre-sampled from each sample corresponding to the model fitting problem to be solved.

[0023] S102. Based on the first sample data and the first observation values, determine an initial surrogate model corresponding to the model fitting problem to be solved.

[0024] In one example, the model fitting problem to be solved can include at least one of engineering problems, physical problems, and financial problems. For example, the engineering problems can include at least one of the following: problems related to artificial intelligence models, problems related to fluid mechanics, problems related to structural engineering, problems related to environmental science, problems related to control systems, etc.

[0025] In one example, polynomial chaos expansion can be regarded as a specially designed surrogate model, which can construct a description of the uncertainty in the system corresponding to the model fitting problem to be solved through a set of orthogonal polynomials. Here, the set of orthogonal polynomials can be fitted by using the first sample data and the first observation values as input data, so as to construct the corresponding initial surrogate model.

[0026] S103. Use the first sample data as the model input, use the initial surrogate model to determine the first output value, and use the true model matching the model fitting problem to be solved to determine the first true value.

[0027] In one example, the true model can refer to a related function constructed based on the model fitting problem to be solved, such as a response function, etc.

[0028] S104. Determine the first error between the first output value and the first true value.

[0029] S105. Based on the first error, perform data sampling to obtain second sample data, and use the true model to determine the second observation value corresponding to the second sample data.

[0030] It can be understood that data sampling refers to sampling from the sample data corresponding to the model fitting problem to be solved. In this way, both the first sample data and the second sample data are samples for the model fitting problem to be solved.

[0031] S106. Based on the first sample data, the first observation value, the second sample data, and the second observation value, construct a target surrogate model.

[0032] In one example, the initial surrogate model can be updated using the first sample data, the first observation value, the second sample data, and the second observation value to construct the target surrogate model. Alternatively, after merging the first and second sample data and the first and second observation values, the relevant embodiments of step S102 can be used to construct the target surrogate model.

[0033] In some cases, the target surrogate model is a surrogate model based on polynomial chaos expansion and can be used for at least one of the following: 1. Computational fluid dynamics for simulation analysis corresponding to nonlinear and complex systems, thereby improving the efficiency and accuracy of simulation analysis in related fields.

[0034] 2. Numerical method research / numerical method calculation for simulation analysis corresponding to the engineering field, thereby improving the efficiency and accuracy of simulation analysis in related fields.

[0035] 3. Artificial intelligence, for example, for combination with machine learning and / or for combination with deep learning, thereby improving the accuracy and efficiency of applying artificial intelligence models.

[0036] For example, aircraft design data can be obtained and input into the target surrogate model for simulation to obtain the simulation results of the aircraft. The simulation results can include the uncertainties of the airfoil of the aircraft under different aerodynamic conditions. In addition, when ship / vehicle data is input into the target surrogate model for simulation, the obtained simulation results of the ship / vehicle can include the possible deviations during the manufacturing process corresponding to the design scheme of the ship / vehicle.

[0037] In an alternative embodiment, the obtaining the second sample data by sampling data based on the first error includes: Determine a sampling region according to the first error, where the geometric center of the sampling region is the maximum error sample point, and the maximum error sample point is the sample point corresponding to the maximum absolute value of the first error among the sample points included in the first sample data.

[0038] Perform data sampling on the sampling region to obtain the second sample data.

[0039] In one example, the sampling region may be a regular region with symmetry. For example, it may be a rectangular region with the maximum error sample point as the geometric center, preferably a square region, or an elliptical region with the maximum error sample point as the geometric center. In this way, the corresponding data sampling method can be obtained according to the specific shape of the sampling region for data sampling of the sampling region.

[0040] It should be noted that in this embodiment, one sample point corresponds to one first observation value. Using each sample point as the model input, a corresponding first output value and a first true value are obtained. The difference between each first output value and its corresponding first true value is the first error corresponding to the corresponding sample point.

[0041] In an alternative embodiment, the sampling region is a circular region, where the center of the circular region is the maximum error sample point, and the radius of the circular region is determined based on a set ratio and the maximum absolute value of the first error, and the set ratio is less than 1 and greater than 0.

[0042] The data sampling of the sampling region to obtain the second sample data includes: Uniformly sampling the circular region to obtain the second sample data.

[0043] In one example, the set ratio is 0.5. Here, assume that the maximum absolute value of the first error is , and the corresponding sample point is , then, find the sample point nearby with an absolute error of or so, the nearest sample point , then the radius can be defined.

[0044] The following is explained in conjunction with Figures 2 to 5 See Figure 2 , which shows the input and output of a true model ( Figure 2 the horizontal axis is the input of the true model, and the vertical axis is the output of the true model). For such a true model, obviously, the slope is particularly large at the input variable equal to 0.5, and more sampling points are required to obtain a good fitting polynomial chaos expansion surrogate model. At this time, see Figure 3 , which shows the data distribution of the first sample data (horizontal axis) obtained by pre-initial sampling and its corresponding first observation value (vertical axis). It can be seen that the sampling on the horizontal axis is uniform at this time. First, an initial surrogate model is constructed accordingly as shown in Figure 4 . Here, see Figure 4 , it can be known that this initial surrogate model ( Figure 4(The horizontal axis is the input of the model, and the vertical axis is the output of the model) has a relatively large variation and jitter at the point where the input variable is equal to 0.5. After that, refer to Figure 5 to calculate the absolute error between the sample data of the initial surrogate model and the true model (i.e., the absolute value of the first error, Figure 5 with the horizontal axis being the input of the two models and the vertical axis being the absolute value of the first error), and it can be seen that the error is exactly at the point where the input variable is 0.5. Thus, it can be known that the resampling should be concentrated near the input variable 0.5.

[0045] Refer to Figure 6 and Figure 9 , Figure 6 are the sample points obtained by uniformly sampling the circular region ( Figure 6 with the horizontal axis being the first sample data or the second sample data obtained from the current sampling, and the vertical axis being the first observation value or the second observation value), where the blue points are Figure 3 the sample points of the first sample data shown in Figure 7 is the initial surrogate model constructed based on the first sample data and the second sample data obtained currently ( Figure 7 with the horizontal axis being the input of the model and the vertical axis being the output of the model), and its variation and jitter have been significantly improved compared to Figure 4 . Correspondingly, Figure 8 is the absolute error between the current initial surrogate model and the sample data of the true model ( Figure 8 with the horizontal axis being the input of the two models and the vertical axis being the value of this absolute error), Figure 9 are the sample points obtained by uniformly sampling the circular region again ( Figure 9 with the horizontal axis being the first sample data or the second sample data obtained from the re - uniform sampling, and the vertical axis being the first observation value or the second observation value regenerated from the re - uniform sampling).

[0046] Refer to Figure 10 and Figure 11 , which corresponds to an example of extending this embodiment to a two - dimensional problem. Among them, Figure 10 represents the true model, Figure 11 represents the target surrogate model, x represents the horizontal axis of this two - dimensional problem, and y represents the vertical axis of this two - dimensional problem. It can be seen that Figure 11 has formed aggregated sampling points, that is, it has well captured the part with a larger slope in the true model (i.e., Figure 10 the green - colored part in

[0047] In an alternative implementation, the data sampling based on the first error to obtain the second sample data includes: Generate a corresponding first probability distribution based on the first error.

[0048] Perform data sampling based on the first probability distribution to obtain the second sample data.

[0049] In some cases, the various embodiments related to obtaining the second sample data by data sampling in the present application can be combined. That is, all the second sample data can include: the second sample data obtained by performing data sampling on the sampling area, and the second sample data obtained by performing data sampling based on the first probability distribution. In other words, at this time, the second sample data obtained by performing data sampling on the sampling area is part of the second sample data, and the second sample data obtained by performing data sampling based on the first probability distribution is part of the second sample data.

[0050] Furthermore, for all the second sample data, it can be obtained by weighted combination of "partial second sample data obtained according to the sampling area (hereinafter referred to as the first part of the data)" and "partial second sample data obtained according to the first probability distribution (hereinafter referred to as the second part of the data)". The weights of the first part of the data and the second part of the data can be determined according to the problem of the model to be fitted.

[0051] In an alternative embodiment, the first probability distribution includes a third probability distribution. The generating of the corresponding first probability distribution based on the first error includes: Normalize the absolute value of the first error to generate a second probability distribution based on the absolute error.

[0052] It should be noted that for the second probability distribution in this embodiment, if all the "absolute values of the first error" (i.e., absolute errors) corresponding to the sample points are normalized, the obtained values are probabilities. The sample points corresponding to larger absolute errors have relatively larger probabilities. Therefore, there is a second probability distribution based on the absolute error at this time. This second probability distribution is used to represent that the larger the absolute error, the higher the probability, and the smaller the absolute error, the lower the probability. Therefore, if sampling can be performed from this second probability distribution, the probability of sampling the sample points in the area with a large absolute error is relatively high.

[0053] Calculate the Gaussian distribution parameters through maximum likelihood estimation according to the second probability distribution.

[0054] Take the Gaussian distribution determined by the Gaussian distribution parameters as the third probability distribution.

[0055] In an example, after obtaining the third probability distribution, the performing of data sampling based on the first probability distribution to obtain the second sample data may include: determining an important area according to the third probability distribution, and drawing a corresponding circle with the important area as the geometric center, such that the drawn circle corresponds to the Gaussian distribution Confidence intervals are then used to sample data within the drawn circles, i.e., the selected confidence intervals, preferably with uniform sampling. In the two-dimensional case, the important regions can be represented by drawing contour plots for different confidence levels. Generally, in a contour plot, each closed curve represents the region within a given confidence level, that is, the set of all points inside the curve satisfies the probability coverage of the selected confidence level.

[0056] In one example, a Gaussian distribution can be considered to model the probability distribution represented by the absolute error, and then sampling from this Gaussian distribution can obtain the required sample points near the regions with large absolute errors. The mathematical description is as follows.

[0057] Assume the initial sample points are , where the probability values obtained by normalizing the absolute error corresponding to each point are , where is the probability or weight of the point appearing. Thus, the goal of this embodiment is to find a Gaussian distribution to fit these data points. The probability density function of the Gaussian distribution is:

[0058] where is the mean (expectation), is the variance. Here, the parameters and of the Gaussian distribution can be determined by maximum likelihood estimation such that the likelihood function of the given points is maximized.

[0059] For a given set of points and the corresponding probabilities , the likelihood function is:

[0060] where is the weight of each point , and the log-likelihood function is:

[0061] Substituting the probability density function of the Gaussian distribution, we get:

[0062] Simplifying gives:

[0063] Finally, the parameters of the Gaussian distribution obtained by maximum likelihood estimation are:

[0064]

[0065] Thus, the final Gaussian distribution is obtained.

[0066] In an alternative embodiment, the first probability distribution includes a fourth probability distribution, and generating the corresponding first probability distribution based on the first error includes: Normalizing the absolute value of the first error to generate a second probability distribution based on the absolute error.

[0067] According to the second probability distribution, use a probability generation model based on a neural network to simulate the fourth probability distribution.

[0068] In some cases, the first probability distribution may include a third probability distribution and a fourth probability distribution. At this time, sampling data based on the first probability distribution to obtain the second sample data may include: sampling data according to the third probability distribution to obtain part of the second sample data, and sampling data according to the fourth probability distribution to obtain part of the second sample data. In other words, at this time, the second sample data obtained based on the first probability distribution includes the second sample data obtained according to the third probability distribution and the second sample data obtained according to the fourth probability distribution.

[0069] In an example, the probability generation model can be constructed based on Normalizing Flow. Normalizing Flow is a framework for probability density modeling and generative modeling. It maps a simple probability distribution (such as the standard normal distribution) to a complex target through a series of reversible transformations. The core goal of this model is to be able to model complex data distributions, estimate the probability density of the data distribution, and generate samples that conform to the data distribution, that is, samples in places with large absolute errors, by learning this series of reversible transformations. Among them, the probability generation model can be the KRnet model, which is a model further extended based on the Knothe-Rosenblatt rearrangement for real-valued volume-non-preserving. The mathematical description is as follows.

[0070] First, define the initial distribution as .

[0071] Then define the multi-layer reversible transformation as .

[0072] Furthermore, derive the density formula:

[0073] After optimizing the objective, common optimization methods used in neural networks, such as the adaptive moment estimation method, can be used to maximize the log-likelihood:

[0074] Thus, a suitable model can be obtained by training only a relatively small number of iterative steps. Then, it is possible to directly sample from and then generate samples of the target distribution through to obtain new sample points, which are used to form at least part of the second sample data.

[0075] In an alternative embodiment, determining the initial surrogate model corresponding to the model fitting problem based on the first sample data and the first observation values includes: Determine the polynomial corresponding to the model fitting problem and determine the matrix corresponding to the polynomial.

[0076] Based on the first sample data and the first observation values, use the least squares method to solve the matrix corresponding to the polynomial to obtain undetermined coefficients, and construct the initial surrogate model of the polynomial chaos expansion according to the undetermined coefficients.

[0077] In an example, the polynomial can be a Legendre polynomial or a Hermite polynomial. In this case, the order of the polynomial can also be determined. The mathematical description is as follows.

[0078] The polynomial can be represented by the following formula:

[0079] where, is the output, are the coefficients to be solved, is the selected orthogonal polynomial basis, is the input random variable.

[0080] At this time, the matrix corresponding to the polynomial can be represented by the following formula:

[0081] where, is the observation value vector of. is the matrix of, and the matrix element is . is the coefficient vector corresponding to the coefficients to be solved of. To minimize the sum of squared residuals, the least squares method can be used to solve for the undetermined coefficients:

[0082] Thus, an initial surrogate model of polynomial chaos expansion with general accuracy can be obtained.

[0083] In one example, the method for obtaining the real model may include: obtaining text suitable for indicating a preset sample problem and polynomial guidance information corresponding to the text, where the text is suitable for indicating a preset polynomial; using the text and the polynomial guidance information as the root node for decision tree operation; inputting the text and the polynomial guidance information into a large model, so that the large model generates a polynomial for the text according to the target polynomial features indicated by the polynomial guidance information, and obtaining the polynomial generated by the large model; determining the similarity between the polynomial generated by the large model and the preset polynomial; in the case where the similarity is less than a preset threshold, feeding back the preset polynomial to the large model, so that the large model performs function structure analysis on the generated polynomial and the preset polynomial to modify the polynomial guidance information according to the function structure analysis result; using the text and the modified polynomial guidance information as split nodes for the decision tree operation, where the split nodes are used for operation after the root node (i.e., in the process of decision tree operation, the root node and the split nodes perform operations in sequence); after the decision tree operation is completed, obtaining decision parameters corresponding to each branch in the decision tree, determining a target branch from the branches according to the decision parameters, and determining the real model according to the target branch in the decision tree. Since in practical applications, the mathematical expressions corresponding to many engineering problems are not obtained through strict mathematical derivation and proof, but are empirical formulas, or even the relevant mathematical expressions have not been summarized yet. At this time, in this embodiment, the decision tree model can be optimized so that the optimized decision tree model can fit a real model with higher accuracy according to the text description of the engineering problem and its corresponding polynomial guidance information (such as polynomial guidance information generated by corresponding empirical formulas).

[0084] Continuing with the above example, the parameter value of the decision parameter corresponding to the target branch can be higher than the set parameter threshold.

[0085] Continuing with the above example, determining the real model according to the target branch in the decision tree may include: determining the branch with the highest parameter value of the decision parameter in the target branch as the real model.

[0086] In an alternative embodiment, constructing the target surrogate model based on the first sample data, the first observation value, the second sample data, and the second observation value includes: Merge the first sample data and the second sample data to obtain new first sample data, and merge the first observation value and the second observation value to obtain new first observation value, so as to repeatedly execute the steps of determining the initial surrogate model corresponding to the problem of the model to be fitted based on the first sample data and the first observation value and subsequent steps until the set condition is met, and use the initially determined surrogate model obtained last time as the target surrogate model.

[0087] In an alternative embodiment, the error between the second sample data and the second observation value is the second error, where the set condition includes at least one of the following: The number of repeated executions reaches the adaptive number of times, where the adaptive number of times is preset, or the adaptive number of times is determined by at least one of the following: the maximum absolute value of the first error obtained for the first time, the maximum absolute value of the second error obtained for the first time; The accuracy of the initially determined surrogate model obtained most recently reaches the preset accuracy requirement.

[0088] Combined with the above related embodiments, the present application has the following technical effects: 1. By calculating the absolute error through sample evaluation to adaptively iterate and generate sample points, no additional computational cost is introduced, especially for problems with difficult sample acquisition, it has great advantages. And it is simple and clear, easy to implement, efficient, and has good versatility.

[0089] 2. According to the absolute error of sample evaluation, the most important singular part of the true model, or the part that is difficult to fit, can be quickly captured.

[0090] 3. The sampling used for sample evaluation can also be used to calculate the undetermined coefficients of the surrogate model for polynomial chaos expansion, without any waste of computational effort.

[0091] In a second aspect, an embodiment of the present application provides a method for using a surrogate model, including: Obtain the data to be processed and the target surrogate model, where the target surrogate model is constructed based on the modeling method described in any one of the above; Input the data to be processed into the target surrogate model, so that the target surrogate model performs corresponding target operations according to the data to be processed, where the target operations include at least one of the following: uncertainty quantification analysis, simulation.

[0092] In one example, the data to be processed may include material strength data and / or temperature data. It should be understood that the material strength data and temperature data are often not fixed but subject to variations, which can be represented by random variables. A random variable is a quantity with a probability distribution. For example, a certain parameter in the material strength data and temperature data may randomly vary within a range. At this time, the target operation includes uncertainty quantification analysis, enabling the target surrogate model to perform corresponding uncertainty quantification analysis on the material strength data and / or temperature data, so as to accurately predict the output corresponding to the material strength data and / or temperature data based on the analysis results. In addition, the analysis results can also be used to characterize the impact of the uncertainty of the data to be processed on the model output.

[0093] In one example, the data to be processed may include engineering data, such as fluid dynamics data, structural engineering data, geotechnical engineering data, data related to aircraft (such as airfoil structure data of an airplane), data related to ships (such as hull structure data), data related to vehicles (such as body structure data), etc. At this time, the target operation includes simulation. That is, the target surrogate model can perform corresponding simulation according to the data to be processed. For example, the target surrogate model can perform aircraft design simulation based on the data related to the aircraft, ship design simulation based on the data related to the ship, and vehicle design simulation based on the data related to the vehicle.

[0094] In summary, the embodiments of the present application at least have the following beneficial effects: By adopting the embodiments of the present application, first sample data and its corresponding first observation value are obtained; based on the first sample data and the first observation value, an initial surrogate model corresponding to the problem of the model to be fitted is determined; using the first sample data as the model input, the first output value is determined using the initial surrogate model, and the first true value is determined using the true model matching the problem of the model to be fitted; the first error between the first output value and the first true value is determined; data sampling is performed based on the first error to obtain second sample data, and the second observation value corresponding to the second sample data is determined using the true model; based on the first sample data, the first observation value, the second sample data, and the second observation value, a target surrogate model is constructed, thereby enabling accurate sampling, quickly capturing important sample data, reducing sampling time and cost, and then reducing the computational amount in the subsequent modeling process to improve the modeling efficiency, while taking into account the accuracy of the constructed surrogate model.

[0095] Through the description of the above embodiments, those skilled in the art can clearly understand that this application can be implemented by means of software plus a necessary hardware platform. Of course, it can also be implemented entirely through hardware. Based on such an understanding, all or part of the technical solution of this application that contributes to the background art can be embodied in the form of a software product. This computer software product can be stored in a storage medium, such as ROM (Read-Only Memory), RAM (Random Access Memory), magnetic disk, optical disk, etc., and includes several instructions for causing a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in various embodiments or some parts of the embodiments of this application.

[0096] The above is the preferred embodiment of this application. It should be noted that for those of ordinary skill in the art, without departing from the principle of this application, several improvements and refinements can be made, and these improvements and refinements are also regarded as the protection scope of this application.

Claims

1. A modeling method of an agent model, characterized in that: include: Obtaining first sample data and its corresponding first observation value; Determine an initial proxy model corresponding to the model problem to be fitted based on the first sample data and the first observation value; Using the first sample data as a model input, determining a first output value using the initial proxy model, and determining a first real value using a real model that matches the model problem to be fitted; determining a first error between the first output value and the first true value; Performing data sampling based on the first error to obtain second sample data, and determining a second observation value corresponding to the second sample data using the true model; A target proxy model is constructed based on the first sample data, the first observation value, the second sample data, and the second observation value.

2. The modeling method of the proxy model according to claim 1, characterized in that: The performing data sampling based on the first error to obtain second sample data includes: Determine a sampling area according to the first error, wherein the geometric center of the sampling area is a maximum error sample point, and the maximum error sample point is a sample point corresponding to the maximum absolute value of the first error among the sample points included in the first sample data; Data sampling is performed on the sampling area to obtain the second sample data.

3. The modeling method of the proxy model according to claim 2, characterized in that: The sampling area is a circular area, wherein the center of the circular area is the maximum error sample point, and the radius of the circular area is determined based on a set ratio and a maximum absolute value of the first error, and the set ratio is less than 1 and greater than 0; The step of sampling the sampling area to obtain the second sample data includes: The circular area is uniformly sampled to obtain the second sample data.

4. The modeling method of the proxy model according to claim 1, characterized in that: The performing data sampling based on the first error to obtain second sample data includes: Based on the first error, generating a corresponding first probability distribution; Data sampling is performed based on the first probability distribution to obtain the second sample data.

5. The modeling method of the proxy model according to claim 4, characterized in that: The first probability distribution includes a third probability distribution, and generating the corresponding first probability distribution based on the first error includes: Normalizing the absolute value of the first error to generate a second probability distribution based on absolute error; According to the second probability distribution, calculating by maximum likelihood estimation to obtain Gaussian distribution parameters; The Gaussian distribution determined by the Gaussian distribution parameters is used as the third probability distribution.

6. The modeling method of the proxy model according to claim 4, characterized in that: The first probability distribution includes a fourth probability distribution, and generating the corresponding first probability distribution based on the first error includes: Normalizing the absolute value of the first error to generate a second probability distribution based on absolute error; According to the second probability distribution, the fourth probability distribution is simulated using a probability generation model based on a neural network.

7. The modeling method of the proxy model according to claim 1, characterized in that: The determining, based on the first sample data and the first observation value, an initial proxy model corresponding to the model problem to be fitted includes: Determine a polynomial corresponding to the model problem to be fitted, and determine a matrix corresponding to the polynomial; Based on the first sample data and the first observation value, the matrix corresponding to the polynomial is solved using the least square method to obtain undetermined coefficients, so as to construct an initial proxy model of the polynomial chaotic expansion according to the undetermined coefficients.

8. The method for modeling a proxy model according to any one of claims 1 to 7, characterized in that: The constructing a target proxy model based on the first sample data, the first observation value, the second sample data and the second observation value includes: The first sample data and the second sample data are merged to obtain new first sample data, and the first observation value and the second observation value are merged to obtain new first observation value, thereby repeatedly executing the steps of determining the initial proxy model corresponding to the model problem to be fitted based on the first sample data and the first observation value and subsequent steps until the set conditions are met, and the initial proxy model determined last time is used as the target proxy model.

9. The method for modeling a proxy model according to claim 8, characterized in that: The error between the second sample data and the second observation value is a second error, wherein the setting condition includes at least one of the following: The number of repeated executions reaches an adaptive number, wherein the adaptive number is preset, or the adaptive number is determined by at least one of the following: a maximum absolute value of the first error obtained for the first time, and a maximum absolute value of the second error obtained for the first time; The accuracy of the most recently obtained initial proxy model meets the preset accuracy requirements.

10. A method for using a proxy model, characterized in that: include: Obtaining data to be processed and a target proxy model, wherein the target proxy model is constructed based on the modeling method according to any one of claims 1 to 9; The data to be processed is input into the target proxy model, so that the target proxy model performs a corresponding target operation according to the data to be processed, wherein the target operation includes at least one of the following: uncertainty quantification analysis and simulation.

Citation Information

Patent Citations

  • Learning function and kriging model combined adaptive structure reliability analysis method

    CN111783209A

  • Structural reliability analysis self-adaptive point adding method for multiple agent models

    CN111797535A

  • Method for rapidly evaluating safety of driving on bridge based on mapping relation agent model

    CN114861458A

  • Ray method-based geometric model particle generation method, device, equipment and medium

    CN116702506A

  • Proxy model generation method and device, equipment, storage medium and program product

    CN117744312A

Cited By

  • Data processing method and device based on polynomial chaos expansion, medium and product

    CN120387524A