Power grid material detection sampling method based on HC-Bayesian-MCMC

Through the HC-Bayesian-MCMC sampling method, different sampling ratios are formulated according to the different manufacturing levels of suppliers, which solves the problem of inconsistency between the detection results and the actual product quality in the traditional power grid material detection method, and improves the accuracy and safety of detection. Adapted to the nonlinear distribution of supplier material qualification rate.

CN118657281APending Publication Date: 2024-09-17STATE GRID HUBEI ELECTRIC POWER RES INST
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410717375.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-06-04
Publication Date
2024-09-17

AI Technical Summary

Technical Problem

The traditional power grid material testing method uses a unified 5% sampling ratio, which cannot accurately reflect the manufacturing level of the supplier, causing the detection results to be inconsistent with the actual product quality, which may lead to poor quality materials being connected to the power grid, affecting the security and economy of the power grid. .

Method used

Using the sampling method based on HC-Bayesian-MCMC, the weighted average non-conformity rate of each supplier is calculated to form a non-conformity rate density distribution curve, and the overall non-conformity rate curve is drawn. Given the suggestion function G(x) for sampling, use Monte The Carlo method and Metropolis-Hastings accept rejection criteria for sample selection to determine the sampling proportions of different suppliers.

Benefits of technology

It effectively improves the control over the product qualification rate of equipment suppliers, improves the safety and reliability of network equipment, adapts to the non-linear characteristics of the material qualification rate distribution of each supplier, and reduces the detection of products from suppliers with better quality. cost.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118657281A
    Figure CN118657281A
Patent Text Reader

Abstract

The invention discloses an HC-Bayesian-MCMC-based power grid material detection sampling method, and the method comprises the steps: carrying out the statistics of the weighted average reject ratio of each equipment supplier according to historical detection data, and enabling the weighted average reject ratio of each supplier to form a reject ratio density distribution curve; drawing an overall unqualified rate curve of the suppliers according to the counted unqualified rate density curve, and giving a suggestion function G (x) according to the drawn overall unqualified rate curve of the suppliers; sampling on the basis of the suggested function G (x); selecting a sample by using a Monte Carlo method; and by counting the number ratio of the sampling points in each reject ratio range, the sampling ratio of supplier equipment with different qualities is determined. According to the invention, different sampling standards can be formulated for suppliers with different manufacturing levels, and the sampling detection result is ensured to better conform to the actual manufacturing levels of material suppliers, so that the correct control of the product qualification rate of equipment suppliers is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of power grid material detection, and in particular to a power grid material detection sampling method based on HC-Bayesian-MCMC (Heuristic Chaos Algorithm-Bayesian-Markov Chain Monte Carlo). Background Art

[0002] With the rapid development of the power industry, the quality inspection and management of power grid materials are crucial to ensure the stable operation of the power system. Power grid material inspection refers to the process of quality inspection, evaluation and management of various equipment, materials, components, etc. used in the power system. The quality of power grid materials is directly related to the safe and stable operation of the power system. Therefore, power grid material inspection is of great significance to the development of the power industry, and the control of the safety and economy of grid-connected equipment is an important guarantee to ensure the stable operation of the power system.

[0003] Traditional sampling uses a 5% sampling ratio to sample and test materials, but this testing method does not take into account the quality of each material supplier, and does not differentiate between suppliers with good manufacturing processes and suppliers with poor manufacturing processes. When purchasing a batch of materials, if 5% sampling is used for both good and bad material suppliers, for manufacturers with poor manufacturing processes, the qualified rate detected may be higher than the actual product qualified rate, while for suppliers with good manufacturing quality, the qualified rate detected may be lower than the actual product qualified rate. Therefore, it is possible that the purchased materials come from suppliers with poor manufacturing quality, thereby connecting power equipment with low quality levels to the power grid, thereby reducing the economy and safety of power grid operation. Moreover, since the material qualified rate distribution curve of each material supplier is different from the classical probability density distribution function, it is difficult to use an effective classical sampling method to reasonably design the material detection sampling plan. Summary of the invention

[0004] Aiming at the problem that the quality of detected products may not match the actual manufacturing level of suppliers due to the use of a unified 5% standard sampling test in power grid material testing, resulting in a large degree of randomness in material procurement, the present invention adopts a Markov chain Monte Carlo method for sampling to formulate different sampling standards for suppliers with different manufacturing levels, thereby ensuring that the sampling test results are more in line with the actual manufacturing level of material suppliers, thereby improving the correct control of the qualified rate of equipment suppliers' products and improving the safety and reliability of network-connected equipment.

[0005] The HC-Bayesian-MCMC (Heuristic Chaos Algorithm-Bayesian-Markov Chain Monte Carlo) sampling method provided by the present invention comprises the following steps:

[0006] The weighted average failure rate of each equipment supplier is calculated based on historical test data, and the weighted average failure rate of each supplier constitutes a failure rate density distribution curve;

[0007] Based on the statistically obtained non-conforming rate density curve, the non-conforming rate curve of the overall supplier is drawn, and the recommended function G(x) is given based on the non-conforming rate curve of the overall supplier;

[0008] Sampling is performed based on the proposed function G(x);

[0009] Monte Carlo method was used to select samples;

[0010] By counting the percentage of sampling points within each unqualified rate range, the sampling ratio for equipment from suppliers with different quality levels can be determined.

[0011] Furthermore, the weighted average failure rate of each equipment supplier is calculated based on the historical test data, and the weighted average failure rate of each supplier constitutes a failure rate density distribution curve, which specifically includes:

[0012] The weighted average non-conforming rate of each supplier is calculated by collecting the results of nearly ten material inspections. The formula is as follows:

[0013]

[0014] where x i is the weight parameter:

[0015] x i =ζ i +t i

[0016] where ζ i is the chaotic increment parameter, satisfying the insect population model:

[0017] ζ i+1 =μζ i (1-ζ i )

[0018] Where μ is the control parameter, and 1<μ≤4, ζ∈(0,1);

[0019] Calculate the weighted average failure rate of each supplier, where f1 represents the failure rate of the first test in the last ten material tests. The proportion of each failure rate in the overall failure rate is determined by multiplying the failure rate of each material test by a different factor. The failure rate of the tenth material test represents the latest material test situation.

[0020] Furthermore, the above method draws the overall supplier failure rate curve based on the statistical failure rate density curve, and gives the suggestion function G(x) based on the overall supplier failure rate curve, which specifically includes:

[0021] First, plot the number of suppliers with qualified rates from low to high to generate the objective function curve for sampling;

[0022] Then, the recommended function G(x) is given by the measured distribution curve of the overall supplier failure rate. 4. The HC-Bayesian-MCMC-based power grid material detection sampling method according to claim 4 is characterized in that the sampling is performed based on the recommended function G(x), specifically based on the Metropolis-Hastings acceptance and rejection criteria, and the steps include:

[0023] a) Starting from any given model parameter θ0, set it to the current model parameter θ * =θ0, the model parameter θ0 is the proposed function G(x);

[0024] b) Select a certain step size for random walk, generate a new model parameter θ', and find the prior probability p(θ') of the new model parameter. The generation of this new model does not depend on the current model θ * ;

[0025] c) For the newly generated model parameter θ', apply the existing geological knowledge to calculate the likelihood function p(y|θ′) of the new model;

[0026] d) Calculate the posterior probability under given geological knowledge and model parameters, and perform a ratio operation on the posterior probability of the new model parameters and the posterior probability of the current model parameters:

[0027]

[0028] If the ratio α is greater than 1, the newly generated model is accepted; if α is less than 1, whether to accept it depends on whether the ratio is greater than the random value U of the uniform distribution U(0,1) a , avoiding the Markov chain always forcing to move to a higher probability density, thereby better exploring the posterior probability space with multiple local extreme values;

[0029] e) If accepted, the Markov chain moves to the newly generated model position θ* = θ'; if rejected, the current model θ* is maintained;

[0030] f) Repeat the above steps b to e continuously to obtain the realization of the series model parameters θ.

[0031] Furthermore, the sample selection using the Monte Carlo method specifically includes:

[0032] The acceptance probability is calculated, which is the ratio of the probability of transferring from the current state to the candidate state to the probability of transferring from the candidate state to the current state. When the ratio is greater than 1, the candidate state is used as the initial value of the next sampling within the range of G(x), and the Metropolis-Hastings acceptance-rejection rule is applied to determine the sampling sample.

[0033] Furthermore, the sampling ratio for equipment of different suppliers with different qualities is determined by counting the proportion of the number of sampling points within each unqualified rate range, which specifically includes:

[0034] The unqualified rate sampling ratio is the proportion of the number of sampling points within the unqualified rate range.

[0035] The present invention has the following beneficial effects:

[0036] (1) In view of the problem that a uniform 5% sampling ratio is used in the detection of power grid materials, which cannot accurately reflect the product quality of each supplier according to the different manufacturing levels of the suppliers, the present invention adopts the MCMC sampling method and adopts different sampling ratios for material suppliers with different manufacturing levels, which can effectively reflect the product quality of each supplier and achieve the effect of improving the material quality detection;

[0037] (2) The unqualified rate curve composed of the unqualified rates of products of various suppliers of power grid materials procurement is not an accurate mathematical function model, but an irregular nonlinear function. To solve the problem that the sampling of such nonlinear functions cannot be fitted by the existing function model, the present invention adopts the MCMC method for random sampling. By selecting the recommended function for random sampling, the shape of the function is continuously changed to approximate the fitting curve, so as to achieve an ideal sampling effect;

[0038] (3) In the process of calculating the weighted average failure rate of each equipment supplier, it is difficult to simply and directly select the weight value, and the independence between two adjacent sampling results cannot be proved. Therefore, the HC algorithm is used to perform chaotic processing on the weight value of each failure rate, so as to achieve the effect of reasonably selecting the weight of each failure rate and increase the reliability of the data. BRIEF DESCRIPTION OF THE DRAWINGS

[0039] Figure 1 This is a flow chart of a power grid material detection sampling method based on HC-Bayesian-MCMC according to an embodiment of the present invention;

[0040] Figure 2 Flow chart of Metropolis Hasting acceptance-rejection sampling algorithm according to an embodiment of the present invention;

[0041] Figure 3Schematic diagram of supplier failure rate curve and recommended function G(x) according to an embodiment of the present invention. DETAILED DESCRIPTION

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

[0043] See also Figure 1 The embodiment of the present invention provides a power grid material detection sampling method based on HC-Bayesian-MCMC, comprising the following steps:

[0044] Step S1, calculating the weighted average failure rate of each equipment supplier based on historical inspection data, and the weighted average failure rate of each supplier constitutes a failure rate density distribution curve.

[0045] Specifically, the weighted average failure rate of each supplier is calculated by collecting the results of nearly ten material inspections. The formula is as follows:

[0046]

[0047] where x i is the weight parameter:

[0048] x i =ζ i +t i

[0049] where ζ i is the chaotic increment parameter, satisfying the insect population model:

[0050] ζ i+1 =μζ i (1-ζ i )

[0051] Where μ is the control parameter, and 1<μ≤4, ζ∈(0,1). As μ changes, the fixed point of the insect population model also changes. In this model, when 1<μ≤3, the sequence ζ i Converges to a fixed point When 1<μ≤3.449, the sequence bifurcates into two fixed points. For example, when μ is 3.2, the sequence alternates between 0.513 and 0.799. When 3.449<μ≤3.545, the fixed points bifurcate again into four. As μ increases further, the fixed points continue to increase exponentially by 2. However, after μ increases to 3.57, the number of fixed points in the sequence increases to infinity. The sequence ζ0, ζ1, ζ2, …, ζ n Like random numbers distributed in the corresponding interval, chaos occurs. As the number of iterations increases, ζ n The value of can almost fill the entire corresponding interval. In particular, when μ = 4, the value of ζ can traverse the entire (0,1) interval.

[0052] t i as follows:

[0053] t i =τ0-τ i

[0054] τ0 represents the eleventh material inspection in the past, τ i Indicates the past i-th material inspection. Specific embodiment Taking four suppliers (ABCD) as an example, the calculation results are shown in Table 1.

[0055] Table 1 Calculation table of weighted average non-conformity rate of some suppliers

[0056]

[0057]

[0058] Calculate the weighted average failure rate of each supplier, where f1 represents the failure rate of the first test in the last ten material tests, and the meanings of other symbols are similar. The formula multiplies the failure rate of each material test by a different factor to determine the proportion of each failure rate in the overall failure rate. This algorithm effectively reflects the latest manufacturing level of each supplier.

[0059] Step S2: Draw the overall supplier failure rate curve based on the statistical failure rate density distribution curve of each supplier, and use the failure rate curve to give the recommended function G(x). Figure 3 shown.

[0060] Specifically, firstly, the number of suppliers with qualified rates from low to high is plotted to generate the sampling objective function curve; then, the recommended function G(x) is given based on the measured overall supplier unqualified rate distribution curve.

[0061] Step S3, sampling is performed based on the proposed function G(x), and specifically the Metropolis Hasting "accept-reject" method is used for sampling. The principle of the Metropolis Hasting "accept-reject" method is: after random sampling, if the sampling point is within the objective function, that is, within the unqualified probability curve, then the sampling point is accepted as a sample; if the sampling sample is outside the range of the objective function, then the sampling point is rejected as a sample.

[0062] like Figure 2 As shown, the process of the Metropolis Hasting acceptance-rejection sampling algorithm of the embodiment of the present invention is as follows: specifically, an initial value is given, sampling is performed based on the initial value, the first sampling point is retained at the next sampling, and the position of the next sampling point is determined by judging the position of the previous sampling point, ensuring that the sampling range converges within the target probability density function, that is, converges within the non-conforming rate curve.

[0063] Among them, when random sampling is performed within the domain of G(x), an initial value X0 is given, and sampling is performed within the function range limited by the initial value to obtain X1.

[0064] Sampling is performed based on the Metropolis-Hastings acceptance and rejection criteria. The specific steps are as follows:

[0065] a) Starting from any given model parameter θ0, set it to the current model parameter θ * =θ0, the model parameter "is the proposed function G(x) mentioned above;

[0066] b) Select a certain step size for random walk, generate a new model parameter θ', and find the prior probability p(θ') of the new model parameter. The generation of this new model does not depend on the current model θ * ;

[0067] c) For the newly generated model parameter θ', apply the existing geological knowledge to calculate the likelihood function p(y|θ′) of the new model;

[0068] d) Calculate the posterior probability under given geological knowledge and model parameters, and perform a ratio operation on the posterior probability of the new model parameters and the posterior probability of the current model parameters:

[0069]

[0070] If the ratio α is greater than 1, the newly generated model is accepted; if α is less than 1, whether to accept it depends on whether the ratio is greater than the random value U of the uniform distribution U(0,1) a, avoiding the Markov chain always forcing to move to a higher probability density, thereby better exploring the posterior probability space with multiple local extreme values;

[0071] e) If accepted, the Markov chain moves to the newly generated model position θ* = θ'; if rejected, the current model θ* is maintained;

[0072] f) Repeat the above steps b to e continuously to obtain the realization of the series model parameters θ.

[0073] Step S4, the specific steps of using the Monte Carlo method to select samples include: calculating the acceptance probability, that is, the ratio of the probability of transferring from the current state to the candidate state to the probability of transferring from the candidate state to the current state. When the ratio is greater than 1, the candidate state can be used as the initial value of the next sampling within the range of G(x) for sampling.

[0074] The embodiment of the present invention uses Bayesian theorem to calculate the acceptance probability, and the principle is as follows:

[0075] The object of Bayesian inference is the prior distribution of a given parameter and the posterior distribution of the parameter under the constraints of the likelihood function. Its general form is as follows:

[0076]

[0077] Where p(θ|y) is the posterior probability distribution, which indicates the probability of θ occurring given the condition y; p(θ) is the prior distribution, which quantifies the initial prior information; p(y|θ) is the likelihood function, which indicates the possibility of obtaining y based on different θ; p(y) is the integral constant, which is usually not considered, so the formula can be simplified to the rightmost form.

[0078] Considering the uncertainty and irregularity of the non-conforming rate curve, the prior parameters of the proposed function G(x) are set to a normal distribution with a mean of 5 and a standard deviation of 10.

[0079] Step S5, iterate the above steps (steps S3 and S4), reach a certain number of iterations, count the proportion of the number of sampling points within each unqualified rate range, determine the sampling ratio for equipment from suppliers with different qualities, and formulate a scientific and reasonable sampling plan.

[0080] The traditional sampling ratio is 5%. Based on this ratio, the sampling weight ratio of each non-conforming rate range is obtained through HC-Bayesian-MCMC sampling to determine the new material sampling ratio. The sampling ratio is re-determined by the following method:

[0081]

[0082] Since the data on the unqualified rate of materials from each supplier have been obtained before, the unqualified rate of suppliers is averaged to obtain the average unqualified rate of the whole materials. When the unqualified rate exceeds the average, the sampling ratio is increased on the original 5% sampling ratio. For example, if the average unqualified rate is 7.3%, the sampling points within the unqualified rate range of 7.5%-7.8% account for 15%, and the average unqualified rate of supplier B is 7.5%, then the sampling ratio of materials from supplier B should be

[0083]

[0084] Similarly, the corresponding material sampling ratio can be obtained based on the material inspection results of other suppliers.

[0085] Before the use of the Markov Chain Monte Carlo method (MCMC), it was necessary to calculate the weighted average failure rate of each equipment supplier based on historical test data. In the process of calculating the weighted average failure rate, it is difficult to simply and directly select the weight value, and the independence between two adjacent sampling results cannot be proved. Therefore, the present invention adopts a heuristic chaos algorithm (HC) to calculate the weighted average failure rate of each supplier. The weighted average failure rate of each supplier constitutes a failure rate density distribution curve; according to the statistical failure rate density curve, a suggestion function G(x) is given, sampling is performed on the basis of the suggestion function G(x), and the Monte Carlo method is used to select samples, specifically using Metropolis Hasting's "accept-reject" method is used for sampling. The acceptance probability is calculated and the acceptance rules are applied to determine the sampling samples. The purpose of using Markov chain is to improve the efficiency of sample sampling and sample selection, reduce the error rate of sample selection, and avoid inaccurate sampling. Specifically, an initial value is given, and sampling is performed based on the initial value. The first sampling point is retained at the next sampling. The position of the next sampling point is determined by judging the position of the previous sampling point, ensuring that the sampling range converges within the target probability density function, that is, converges within the unqualified rate curve. By counting the proportion of sampling points within each unqualified rate range, the sampling ratio for equipment from suppliers with different qualities is determined. By using the Markov chain Monte Carlo method to determine the sampling ratio, strict control of the qualified rate of products from suppliers with poor quality is achieved, reducing the testing cost of products from suppliers with better quality.

[0086] The above is only a specific embodiment of the present invention, but the protection scope of the present invention is not limited thereto. Any changes or substitutions that can be easily thought of by a person skilled in the art within the technical scope disclosed by the present invention should be included in the protection scope of the present invention. Therefore, the protection scope of the present invention should be based on the protection scope of the claims.

Claims

1. A power grid material detection sampling method based on HC-Bayesian-MCMC, characterized in that: The following steps are involved: The weighted average failure rate of each equipment supplier is calculated based on historical test data, and the weighted average failure rate of each supplier constitutes a failure rate density distribution curve; Based on the statistically obtained non-conforming rate density curve, the non-conforming rate curve of the overall supplier is drawn, and the recommended function G(x) is given based on the non-conforming rate curve of the overall supplier; Sampling is performed based on the proposed function G(x); Monte Carlo method was used to select samples; By counting the percentage of sampling points within each unqualified rate range, the sampling ratio for equipment from suppliers with different quality levels can be determined.

2. The HC-Bayesian-MCMC-based power grid material detection sampling method according to claim 1, characterized in that: The weighted average failure rate of each equipment supplier is calculated based on historical test data, and the weighted average failure rate of each supplier constitutes a failure rate density distribution curve, which specifically includes: The weighted average non-conforming rate of each supplier is calculated by collecting the results of nearly ten material inspections. The formula is as follows: where x i is the weight parameter: x i =ζ i +t i where ζ i is the chaotic increment parameter, satisfying the insect population model: g i+1 =mz i (1-g) i ) Where μ is the control parameter, and 1<μ≤4, ζ∈(0,1); Calculate the weighted average failure rate of each supplier, where f1 represents the failure rate of the first test in the last ten material tests. The proportion of each failure rate in the overall failure rate is determined by multiplying the failure rate of each material test by a different factor. The failure rate of the tenth material test represents the latest material test situation.

3. The HC-Bayesian-MCMC-based power grid material detection sampling method according to claim 1, characterized in that: The method of drawing a failure rate curve of the overall supplier according to the statistical failure rate density curve and giving a suggestion function G(x) according to the failure rate curve of the overall supplier, specifically includes: First, plot the number of suppliers with qualified rates from low to high to generate the objective function curve for sampling; Then, the recommended function G(x) is given based on the measured distribution curve of the overall supplier failure rate.

4. The HC-Bayesian-MCMC-based power grid material detection sampling method according to claim 3, characterized in that: The sampling is performed based on the suggestion function G(x), specifically based on the Metropolis-Hastings acceptance and rejection criteria, and the steps include: a) Starting from any given model parameter θ0, set it to the current model parameter θ * =θ0, the model parameter θ0 is the proposed function G(x); b) Select a certain step size for random walk, generate a new model parameter θ', and find the prior probability p(θ') of the new model parameter. The generation of this new model does not depend on the current model θ * ; c) For the newly generated model parameter θ', apply the existing geological knowledge to calculate the likelihood function p(y|θ′) of the new model; d) Calculate the posterior probability under given geological knowledge and model parameters, and perform a ratio operation on the posterior probability of the new model parameters and the posterior probability of the current model parameters: If the ratio α is greater than 1, the newly generated model is accepted; if α is less than 1, whether to accept it depends on whether the ratio is greater than the random value U of the uniform distribution U(0,1) a , avoiding the Markov chain always forcing to move to a higher probability density, thereby better exploring the posterior probability space with multiple local extreme values; e) If accepted, the Markov chain moves to the newly generated model position θ* = θ'; if rejected, the current model θ* is maintained; f) Repeat the above steps b to e continuously to obtain the realization of the series model parameters θ.

5. The HC-Bayesian-MCMC-based power grid material detection sampling method according to claim 1, characterized in that: The sample selection using the Monte Carlo method specifically includes: The acceptance probability is calculated, which is the ratio of the probability of transferring from the current state to the candidate state to the probability of transferring from the candidate state to the current state. When the ratio is greater than 1, the candidate state is used as the initial value of the next sampling within the range of G(x), and the Metropolis-Hastings acceptance-rejection rule is applied to determine the sampling sample.

6. The HC-Bayesian-MCMC-based power grid material detection sampling method according to claim 1, characterized in that: The sampling ratio for equipment from suppliers with different qualities is determined by counting the number of sampling points within each unqualified rate range, specifically including: The unqualified rate sampling ratio is the proportion of the number of sampling points within the unqualified rate range.