Method and device for casual inspection of product life and storage medium

By constructing the objective function and optimizing the sample number and acceptance coefficients using the particle swarm optimization algorithm, the problems of high economic costs and low reliability caused by excessive or too few random inspection products in the prior art are solved, and efficient and reliable product life sampling is achieved.

CN119990914APending Publication Date: 2025-05-13BEIJING HUAYIXIN TECH CO LTD +1
View PDF 8 Cites 0 Cited by

Patent Information

Application Number
CN202510444306.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-04-10
Publication Date
2025-05-13

AI Technical Summary

Technical Problem

In the prior art, if the number of randomly inspected products is too large, it will increase economic costs and reduce inspection efficiency; if the number of randomly inspected products is too small, the reliability of the inspection results is low and cannot represent the service life of the batch of products.

Method used

By receiving preset experimental parameters related to the product logarithmic life, the objective function is constructed, and the sample number and acceptance coefficient are optimized using the particle swarm optimization algorithm to determine the optimal sample number and acceptance coefficient to perform fixed-cutting and loss sampling.

Benefits of technology

While improving the inspection efficiency, ensure the reliability of the inspection results and balance the pass rate of qualified products and the rejection rate of unqualified products in batches.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119990914A_ABST
    Figure CN119990914A_ABST
Patent Text Reader

Abstract

The invention discloses a method and device for carrying out sampling inspection on the service life of a product and a storage medium. The method comprises the steps that preset experiment parameters related to a sampling inspection experiment used for carrying out sampling inspection on the logarithmic service life of the product are received; constructing a target function based on preset experiment parameters; based on the objective function, optimizing the sample number n and the acceptance coefficient k by using a particle swarm optimization algorithm, and determining an optimal solution n0 of the sample number and an optimal solution k0 of the acceptance coefficient; according to the sample number optimal solution n0, determining a sample number n, an acceptance coefficient k and a truncated mantissa m related to a sampling test; and according to the determined sample number n, the acceptance coefficient k and the truncated mantissa m, carrying out sampling inspection on the product. Therefore, the technical effect of ensuring the reliability of the inspection result under the condition of improving the inspection efficiency is achieved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the technical field of quality inspection, and in particular to a method, device and storage medium for performing random inspection on product life. Background Art

[0002] At present, in order to ensure the quality of the products they produce, manufacturers will conduct multi-dimensional inspections on the products throughout the entire production cycle. For example, in order to ensure the normal use of the products, manufacturers will inspect the materials, dimensions, mechanical properties and service life of the products.

[0003] As for the service life of products, if manufacturers inspect all products, it will greatly increase the economic cost of manufacturers and reduce production efficiency. Therefore, at the current stage, manufacturers usually randomly select multiple products from the products they produce and inspect the service life of the selected multiple products. In other words, they conduct random inspections on products.

[0004] However, it is worth noting that the number of products sampled directly affects the reliability of the inspection results and the economic cost of the inspection. For example, if the number of products sampled is too large, it will not only increase the economic cost of the inspection, but also reduce the inspection efficiency of the manufacturer. If the number of products sampled is too small, the reliability of the final inspection results will be low and cannot represent the service life of the batch of products.

[0005] The publication number is CN112949092A, and the name is a discrete parameter regression method for multi-stage periodic sampling product storage life assessment. The steps are as follows: Step 1: Failure probability distribution fitting and mean estimation of factory data; Step 2: Outlier screening and order preservation processing of fused data; Step 3: Weibull parameter estimation based on discrete parameters; Step 4: Life parameter selection and error optimization iteration.

[0006] The publication number is CN119719707A, and the name is a product storage life assessment method based on composite random inspection success and failure data. It includes the following steps: point estimation and confidence limit estimation of failure probability for special test data, randomization of user usage data containing fuzzy samples using uniform distribution or truncated normal distribution; compatibility test of special test data and user usage data; fusion of special test data and user usage data that meet the compatibility test using the Bayesian method to obtain updated special stage failure probability estimates for different storage periods; further screening out degradation failure sample data based on the updated special failure probability estimates, and using the weighted least squares method to assess the storage life of degradation failure data.

[0007] There is no effective solution to the technical problem in the above-mentioned prior art that if too many products are sampled, not only will the economic cost required for inspection increase, but also the inspection efficiency will be reduced; if too few products are sampled, the reliability of the inspection results will be low. Summary of the invention

[0008] The embodiments of the present disclosure provide a method, device and storage medium for random inspection of product life, so as to at least solve the technical problems existing in the prior art that if the number of products randomly inspected is too large, not only the economic cost required for inspection will increase, but also the inspection efficiency will be reduced; if the number of products randomly inspected is too small, the reliability of the inspection result will be low.

[0009] According to one aspect of an embodiment of the present disclosure, a method for sampling a product life is provided, comprising: receiving preset experimental parameters related to a sampling experiment for sampling a logarithmic life of a product, wherein the preset experimental parameters include: a producer risk associated with the product; α , Consumer Risk β , the highest defect rate acceptable to the producer p α and the lowest defect rate that is unacceptable to consumers p β , and the sampling experiment is based on a predetermined deletion rate q Based on the preset experimental parameters, the objective function is constructed, where the variable of the objective function is the number of samples in the random inspection experiment. n and the acceptance coefficient k , where the acceptance coefficient k It is related to the confidence that the logarithmic life of the sample is greater than the predetermined logarithmic life threshold, and the objective function satisfies the condition that the Bayesian producer risk corresponding to the sampling experiment is equal to the producer risk received α Consistent, and the Bayesian consumer risk corresponding to the sampling experiment is consistent with the consumer risk received β Consistent; Based on the objective function, the particle swarm optimization algorithm is used to optimize the number of samples n and the acceptance coefficient k Optimize and determine the optimal solution for the number of samples n 0 and the optimal solution of the acceptance coefficient k 0; optimal solution based on sample size n 0, determine the number of samples related to the sampling experiment n , acceptance coefficient k And the truncated number m ; and according to the determined sample size n , acceptance coefficient k And the truncated number m , conduct random inspections on products.

[0010] According to another aspect of an embodiment of the present disclosure, a storage medium is further provided, the storage medium including a stored program, wherein when the program is running, any one of the above methods is executed by a server.

[0011] According to another aspect of the embodiment of the present disclosure, there is also provided a device for performing random inspection on the life of a product, comprising: an experimental parameter receiving module, for receiving preset experimental parameters related to a random inspection experiment for performing random inspection on the logarithmic life of a product, wherein the preset experimental parameters include: producer risk associated with the product; α , Consumer Risk β , the highest defect rate acceptable to the producer p α and the lowest defect rate that is unacceptable to consumers p β , and the sampling experiment is based on a predetermined deletion rate q The constant truncated sampling experiment; the objective function construction module is used to construct the objective function based on the preset experimental parameters, where the variable of the objective function is the number of samples in the sampling experiment n and the acceptance coefficient k , where the acceptance coefficient k It is related to the confidence that the logarithmic life of the sample is greater than the predetermined logarithmic life threshold, and the objective function satisfies the condition that the Bayesian producer risk corresponding to the sampling experiment is equal to the producer risk received α Consistent, and the Bayesian consumer risk corresponding to the sampling experiment is consistent with the consumer risk received β Consistent; optimization module, used to optimize the number of samples based on the objective function using the particle swarm optimization algorithm n and the acceptance coefficient k Optimize and determine the optimal solution for the number of samples n 0 and the optimal solution of the acceptance coefficient k 0; Sample quantity and acceptance coefficient determination module, used to optimally solve the problem according to the sample quantity n 0, determine the number of samples related to the sampling experiment n , acceptance coefficient k And the truncated number m ; and a product sampling module for sampling the product according to the determined number of samples n , acceptance coefficient k And the truncated number m , conduct random inspections on products.

[0012] According to another aspect of the embodiment of the present disclosure, there is also provided a device for performing random inspection on the life of a product, comprising: a server; and a memory, connected to the server, for providing the server with instructions for processing the following processing steps: receiving preset experimental parameters related to a random inspection experiment for performing random inspection on the logarithmic life of a product, wherein the preset experimental parameters include: producer risk associated with the product; α , Consumer Risk β , the highest defect rate acceptable to the producer p α and the lowest defect rate that is unacceptable to consumers p β , and the sampling experiment is based on a predetermined deletion rate q Based on the preset experimental parameters, the objective function is constructed, where the variable of the objective function is the number of samples in the random inspection experiment. n and the acceptance coefficient k , where the acceptance coefficient k It is related to the confidence that the logarithmic life of the sample is greater than the predetermined logarithmic life threshold, and the objective function satisfies the condition that the Bayesian producer risk corresponding to the sampling experiment is equal to the producer risk received α Consistent, and the Bayesian consumer risk corresponding to the sampling experiment is consistent with the consumer risk received β Consistent; Based on the objective function, the particle swarm optimization algorithm is used to optimize the number of samples n and the acceptance coefficient k Optimize and determine the optimal solution for the number of samples n 0 and the optimal solution of the acceptance coefficient k 0; optimal solution based on sample size n 0, determine the number of samples related to the sampling experiment n , acceptance coefficient k And the truncated number m ; and according to the determined sample size n , acceptance coefficient k And the truncated number m , conduct random inspections on products.

[0013] The present application discloses a method for sampling the life of a product. First, a server receives preset experimental parameters related to an experiment for sampling the logarithmic life of a product. Then, the server constructs an objective function based on the preset experimental parameters. Further, based on the objective function, the server optimizes the sample size and the acceptance coefficient using a particle swarm optimization algorithm to determine the optimal solution for the sample size and the optimal solution for the acceptance coefficient. Afterwards, the server determines the sample size, acceptance coefficient, and truncation number related to the sampling experiment based on the optimal solution for the sample size. Finally, the server performs a sampling inspection on the product based on the determined sample size, acceptance coefficient, and truncation number.

[0014] With reference to the above contents, it can be known that the present application uses the number of samples and the acceptance coefficient of the random inspection experiment as variables, constructs the objective function, and sets the constraint conditions corresponding to the objective function. Thus, the constraint conditions enable the server to further balance the passing rate of qualified products in the batch of products and the rejection rate of unqualified products in the batch of products while determining the reasonable number of samples and the acceptance coefficient based on the objective function.

[0015] In addition, this application determines the optimal solution for sample size and acceptance coefficient based on the objective function and uses the particle swarm optimization algorithm, so that the final determined sample size is the most suitable number for product sampling experiments. Sampling products according to the determined sample size, acceptance coefficient and truncation number can improve the inspection efficiency and ensure the reliability of the inspection results.

[0016] This solves the technical problems existing in the prior art that if too many products are sampled, not only will the economic cost required for inspection increase, but also the inspection efficiency will be reduced; if too few products are sampled, the reliability of the inspection results will be low. BRIEF DESCRIPTION OF THE DRAWINGS

[0017] The drawings described herein are used to provide a further understanding of the present disclosure and constitute a part of the present application. The illustrative embodiments of the present disclosure and their descriptions are used to explain the present disclosure and do not constitute an improper limitation on the present disclosure. In the drawings: Figure 1 is a hardware structure block diagram of a computing device for implementing the method according to Embodiment 1 of the present application; Figure 2 is a schematic diagram of a system for performing random inspection on product life according to Example 1 of the present application; Figure 3 This is a flow chart of the method for spot checking product life according to Example 1 of the present application; Figure 4 is a schematic diagram of a device for performing random inspection on product life according to Example 2 of the present application; and Figure 5 It is a schematic diagram of a device for performing random inspections on product life according to Example 3 of the present application. DETAILED DESCRIPTION

[0018] In order to enable those skilled in the art to better understand the technical solutions of the present disclosure, the technical solutions in the embodiments of the present disclosure will be clearly and completely described below in conjunction with the drawings in the embodiments of the present disclosure. Obviously, the described embodiments are only embodiments of a part of the present disclosure, not all of the embodiments. Based on the embodiments in the present disclosure, all other embodiments obtained by ordinary technicians in this field without making creative work should fall within the scope of protection of the present disclosure.

[0019] It should be noted that the terms "first", "second", etc. in the specification and claims of the present disclosure and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable where appropriate, so that the embodiments of the present disclosure described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions, for example, a process, method, system, product, or device that includes a series of steps or units is not necessarily limited to those steps or units that are clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products, or devices.

[0020] First, some nouns or terms that appear in the process of describing the embodiments of the present disclosure are subject to the following explanations: Logarithmic life: the logarithm of the product's life, which conforms to the normal distribution.

[0021] Example 1 According to this embodiment, a method embodiment of performing random inspections on product life is provided. It should be noted that the steps shown in the flowchart of the accompanying drawings can be executed in a computer system such as a set of computer executable instructions, and although a logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in an order different from that shown here.

[0022] The method embodiment provided in this embodiment can be executed in a mobile terminal, a computer terminal, a server or a similar computing device. Figure 1 FIG. 1 shows a hardware structure block diagram of a computing device for implementing random inspection of product life. Figure 1 As shown, the computing device may include one or more servers (the server may include but is not limited to a processing device such as a microserver MCU or a programmable logic device FPGA), a memory for storing data, a transmission device for communication functions, and an input / output interface. The memory, the transmission device, and the input / output interface are connected to the server via a bus. In addition, it may also include: a display, a keyboard, and a cursor control device connected to the input / output interface. A person skilled in the art can understand that Figure 1 The structure shown is only for illustration and does not limit the structure of the above electronic device. Figure 1 More or fewer components as shown, or with Figure 1 Different configurations are shown.

[0023] It should be noted that the one or more servers and / or other data processing circuits described above may generally be referred to herein as "data processing circuits". The data processing circuits may be embodied in whole or in part as software, hardware, firmware, or any other combination thereof. In addition, the data processing circuit may be a single independent processing module, or may be incorporated in whole or in part into any of the other products in the computing device. As involved in the embodiments of the present disclosure, the data processing circuit acts as a server control (e.g., selection of a variable resistor terminal path connected to an interface).

[0024] The memory can be used to store software programs and modules of application software, such as the program instructions / data storage device corresponding to the method for spot checking the life of products in the embodiment of the present disclosure. The server executes various functional applications and data processing by running the software programs and modules stored in the memory, that is, the method for spot checking the life of products of the above-mentioned application program is realized. The memory may include a high-speed random access memory, and may also include a non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some instances, the memory may further include a memory remotely arranged relative to the server, and these remote memories may be connected to the computing device via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.

[0025] The transmission device is used to receive or send data via a network. The specific example of the above network may include a wireless network provided by a communication provider of the computing device. In one example, the transmission device includes a network adapter (Network Interface Controller, NIC), which can be connected to other network devices through a base station so as to communicate with the Internet. In one example, the transmission device can be a radio frequency (RF) module, which is used to communicate with the Internet wirelessly.

[0026] The display may be, for example, a touch screen liquid crystal display (LCD) that may enable a user to interact with a user interface of the computing device.

[0027] It should be noted that, in some optional embodiments, the above Figure 1The computing device shown may include a hardware product (including a circuit), a software product (including a computer code stored on a computer-readable medium), or a combination of both a hardware product and a software product. Figure 1 This is merely one example of a particular embodiment and is intended to illustrate the types of components that may be present in the computing devices described above.

[0028] Figure 2 Schematic diagram of a system for spot checking product life according to this embodiment. Figure 2 As shown, the system includes: a terminal device 100 and a server 510. The terminal device 100 is connected to the server 510, and the user can send preset experimental parameters for random inspection of the logarithmic life of the product to the server 510 through the terminal device 100. The preset experimental parameters include the producer risk associated with the product. α , Consumer Risk β , the highest defect rate acceptable to the producer p α and the lowest defect rate that is unacceptable to consumers p β .

[0029] The server 510 is used to construct an objective function based on the received preset implementation parameters. The variables of the objective function are the sample size and the acceptance coefficient. The server 510 is also used to determine the optimal solution of the sample size and the optimal solution of the acceptance coefficient based on the objective function and using the particle swarm optimization algorithm, and determine the sample size, acceptance coefficient and truncation number related to the sampling experiment based on the optimal solution of the sample size. And when the server 510 determines the sample size, acceptance coefficient and truncation number, the product is sampled and inspected according to the product number.

[0030] It should be noted that the terminal device 100 and the server 510 in the system can both be applicable to the hardware structure described above.

[0031] Under the above operating environment, according to the first aspect of this embodiment, a method for spot checking product life is provided. The method comprises: Figure 2 The server 510 shown in FIG. Figure 3 A schematic diagram showing the process of the method is shown in FIG. Figure 3 As shown, the method includes: S302: Receive preset experimental parameters related to a random inspection experiment for random inspection of the logarithmic life of a product, wherein the preset experimental parameters include: producer risk associated with the product α , Consumer Risk β , the highest defect rate acceptable to the producer p αand the lowest defect rate that is unacceptable to consumers p β , and the sampling experiment is based on a predetermined deletion rate q The constant censoring sampling experiment; S304: Based on the preset experimental parameters, construct an objective function, where the variable of the objective function is the number of samples in the random inspection experiment n and the acceptance coefficient k , where the acceptance coefficient k It is related to the confidence that the logarithmic life of the sample is greater than the predetermined logarithmic life threshold, and the objective function satisfies the condition that the Bayesian producer risk corresponding to the sampling experiment is equal to the producer risk received α Consistent, and the Bayesian consumer risk corresponding to the sampling experiment is consistent with the consumer risk received β Consistency; S306: Based on the objective function, the particle swarm optimization algorithm is used to optimize the number of samples. n and the acceptance coefficient k Optimize and determine the optimal solution for the number of samples n 0 and the optimal solution of the acceptance coefficient k 0; S308: Optimal solution based on sample size n 0 and the optimal solution of the acceptance coefficient k 0, determine the number of samples related to the sampling experiment n , acceptance coefficient k And the truncated number m ;as well as S310: According to the determined number of samples n , acceptance coefficient k And the truncated number m , conduct random inspections on products.

[0032] Specifically, first, the user sends preset experimental parameters related to the random inspection experiment for random inspection of the logarithmic life of the product to the server 510 through the terminal device 100, so that the server 510 can receive the preset implementation parameters related to the product random inspection experiment (S302). The preset experimental parameters include: producer risk related to the product α , Consumer Risk β , the highest defect rate acceptable to the producer p α and the lowest defect rate that is unacceptable to consumers p β .

[0033] And among them, producer risk α It indicates the probability of failure of the random inspection due to sampling error when the products in the batch are qualified. Consumer Riskβ It indicates the probability of successful sampling test due to sampling error when the batch of products is unqualified. The highest defect rate acceptable to the manufacturer p α It indicates the maximum number of defective products that the producer can accept in this batch of products without the entire batch of products being judged as unqualified. The minimum defect rate that consumers cannot accept p β It indicates the minimum acceptable quality level for consumers in this batch of products. If the threshold is exceeded, the entire batch of products will be judged as unqualified.

[0034] In addition, the random inspection experiment of the logarithmic life of the product in this application is based on a predetermined deletion rate. q In this embodiment, the server 510, for example, predetermines the deletion rate q The data is truncated to 50%. Therefore, the life span data of half of the products in the batch are temporarily not considered, that is, while controlling the risks of consumers and producers, the efficiency of the sampling test can be improved and the economic cost of the sampling test can be reduced in actual production monitoring.

[0035] Then, when the server 510 receives preset experimental parameters related to a sampling experiment for sampling the logarithmic life of a product, an objective function is constructed based on the preset experimental parameters. TG ( n , k ) (S304). In this embodiment, the server 510 will randomly select the number of samples for the test. n and the acceptance coefficient k Determine the variable as the objective function. And accept the coefficient k Related to the confidence that the log lifespan of a sample is greater than a predetermined log lifespan threshold.

[0036] Among them, the objective function TG ( n , k ) in the optimal solution of sample size n 0 and the optimal solution of the acceptance coefficient k 0 satisfies the following two constraints: First, the optimal solution with sample size n 0 and the optimal solution of the acceptance coefficient k The Bayesian producer risk corresponding to 0 is PR ), which is equal to the accepted producer risk. This means that if the product is sampled with the determined optimal solution of sample quantity and the optimal solution of acceptance coefficient, the producer risk in the current state can be guaranteed to be within the acceptable producer risk.

[0037] Second, the optimal solution with sample sizen 0 and the optimal solution of the acceptance coefficient k 0 corresponding to the Bayesian consumer risk ( CR ), which is equal to the accepted consumer risk. This means that if the product is sampled with the optimal solution of sample quantity and acceptance coefficient, it can be guaranteed that the consumer risk in the current state is within the acceptable consumer risk. TG ( n , k ), which will be explained in detail later.

[0038] Further, when the server 510 constructs the objective function, the particle swarm optimization algorithm is used, and the sample quantity and the acceptance coefficient are optimized, so as to determine the optimal solution of the sample quantity and the optimal solution of the acceptance coefficient (S306). Specifically, first, the server 510 randomly generates a plurality of particles, and initializes the initial speed, initial position, initial historical optimal position corresponding to each particle, and the initial global optimal position corresponding to the particle swarm. Then, the server 510 iteratively updates the initial speed and initial position of each particle, determines the current position and current speed of each particle, and calculates the fitness value of each particle at the current position based on the objective function. Further, the server 510 iteratively updates the initial historical optimal position of each particle and the initial global optimal position of the particle swarm based on the fitness value corresponding to each particle. After that, the server 510 determines whether the current number of iterations has reached the preset number of iterations threshold. And when the current number of iterations reaches the number of iterations threshold, the server 510 stops iterating and outputs the global optimal position corresponding to the current number of iterations. The global optimal position is used to indicate the optimal solution of the sample quantity and the optimal solution of the acceptance coefficient. The above content will be described in detail later, so it will not be repeated here.

[0039] Then the server 510 optimizes the solution based on the number of samples. n 0 and the optimal solution of the acceptance coefficient k 0, determine the sample quantity, acceptance coefficient and truncation number related to the sampling experiment (S308). Specifically, since the server 510 uses the particle swarm algorithm to calculate the optimal solution for the sample quantity n 0 may not be an integer, but the actual number of products sampled can only be an integer. Therefore, in this embodiment, the optimal solution is required based on the number of samples. n 0 and the optimal solution of the acceptance coefficient k 0, determine the number of samples related to the sampling experiment n , acceptance coefficient k And the truncated number m The specific process will be described in detail below.

[0040] Finally, the server 510 determines the number of samples n , acceptance coefficient k And the truncated number m , and conduct random inspections on products in the database according to the pre-set product numbers.

[0041] As described in the background technology, the number of products sampled directly affects the reliability of the test results and the economic cost of the test. For example, if the number of products sampled is too large, it will not only increase the economic cost of the test, but also reduce the test efficiency of the manufacturer. If the number of products sampled is too small, the reliability of the test results obtained in the end is low and cannot represent the service life of the batch of products.

[0042] In view of this, the present application provides a method for spot checking product life. Referring to the above content, it can be seen that the present application uses the sample size and acceptance coefficient of the spot check experiment as variables, constructs an objective function, and sets constraints corresponding to the objective function. Thus, the constraints enable the server to further balance the pass rate of qualified products in the batch of products and the rejection rate of unqualified products in the batch of products while determining a reasonable sample size and acceptance coefficient based on the objective function.

[0043] In addition, this application determines the optimal solution for sample size and acceptance coefficient based on the objective function and uses the particle swarm optimization algorithm, so that the final determined sample size is the most suitable number for product sampling experiments. Sampling products according to the determined sample size, acceptance coefficient and truncation number can improve the inspection efficiency and ensure the reliability of the inspection results.

[0044] This solves the technical problems existing in the prior art that if too many products are sampled, not only will the economic cost required for inspection increase, but also the inspection efficiency will be reduced; if too few products are sampled, the reliability of the inspection results will be low.

[0045] In addition, the Bayesian producer risk is used as the producer risk in this application, and the Bayesian consumer risk is used as the consumer risk. Thus, the Bayesian sampling method ( BR ) compared to the traditional average sampling scheme ( AR ), under the same acceptance criteria, the number of samples required is obviously smaller. The following Table 1 shows the α =0.05, β =0.10, p α =0.0319 and p β =0.0942, the optimal sampling plan for the lognormal distribution with a 50% censoring rate AR and BR The designed sample size and simulated sampling risk are for the selected µ p and σ p value: Table 1

[0046] in, APR is the average producer risk based on average sampling, ACR is the average consumer risk based on average sampling, BPR is the Bayesian producer risk based on Bayesian sampling , BCR Bayesian consumer risk based on Bayesian sampling. n is the number of samples.

[0047] Optionally, based on the preset experimental parameters, the operation of constructing the objective function includes constructing the following objective function: TG ( n , k )=( PR - α ) 2 +( CR - β ) 2 (1), in α is the producer risk received, β For the consumer risk received, PR For the Bayesian producer risk: (2), as well as CR For the Bayesian consumer risk: (3), And among them (4), in p is the product defect rate, h 1( p )and h 2( p ) is the prior probability density function, , and is the covariance coefficient of the inverse matrix of the Fisher information matrix under constant truncation, and Φ( ) is the standard normal distribution function.

[0048] Specifically, using the above objective function TG ( n , k ) is as follows: The lognormal distribution is one of the most widely used distributions in survival analysis, reliability analysis, and sampling testing, and life expectancy variables T Logarithm of The mean is μ , standard deviation is σ Normal distribution. Therefore, in this example, the logarithmic life of the product is mainly studied. .

[0049] Among them, the logarithmic life X As a random variable, its cumulative distribution function ( CDF ), probability density function ( PDF ) and the survival function ( SF ) are: ; ;as well as .

[0050] Where Φ(·) represents the standard normal distribution function.

[0051] Given the total sample size n , when m The test ends when the first product fails. At this point, the logarithmic life is recorded. X (1) ≤ X (2) ≤···≤ X (m) , and the remaining nm Products that have not failed are considered to be censored, and the censoring rate is Therefore, only the former m Order Statistics X (1) , . . . , X (m) is observed, and the remaining nm Products in X (m) Still survived afterwards.

[0052] when X i is an independent and identically distributed normal distribution N ( μ , σ 2 ), and only the order statistic is observed X (1) ≤ X (2) ≤···≤ X (m) (In mThe joint density function of these products is: .

[0053] In addition, in this embodiment, in order to make the product meet the quality standards, its life T Must exceed a given lower lifetime limit u , then the logarithm of the product's life X Must exceed the given lower limit of lifespan .if X < l The product is considered defective and is often referred to as a "bad value". p Defined as: Pr ( X < l )= p .

[0054] because X Normal distribution N ( μ , σ 2 ), so: , So we can solve: .

[0055] The maximum likelihood estimate (MLE) of the batch of samples and Under type two censoring, it satisfies: , in k is the acceptance coefficient, which is related to the confidence that the logarithmic life of the sample is greater than the predetermined logarithmic life threshold. The following inequality is obtained: .

[0056] Define the pivot amount Y 1 and Y 2: ; .

[0057] Thus, the above inequality simplifies to: .

[0058] Optionally, h 1( p )and h 2( p) is the probability density function of the Beta distribution. Therefore, the operating characteristic function, that is, the OC function, can be defined as: .

[0059] Among them, 0< p <1.

[0060] In addition, the OC function of the lognormal distribution under type two censoring is The asymptotic normal approximation of is reasonable: .

[0061] in, is a 2×2 covariance matrix whose elements γ ij ( i , j =1,2) comes from the inverse matrix of the Fisher information matrix under type-two censoring.

[0062] Let the information matrix be: , but: .

[0063] definition Z = Y 1- k ( Y 2-1), its asymptotic distribution is: .

[0064] Therefore, the decision rule can be rewritten as: Z >Φ -1 ( p )+ k . According to asymptotic normality, we have: .

[0065] Therefore, the approximate expression of the OC function under type II censoring is: (4).

[0066] In addition, in reliability testing and quality control, producers and consumers need to p Jointly develop quality standards to ensure that the production process controls the outflow of substandard products while not setting overly stringent standards for qualified products.

[0067] Acceptable quality level (AQL) and reject quality level (RQL) are two key indicators that represent the maximum defect rate acceptable to the producer. p αand the lowest defect rate that is unacceptable to consumers p β ,in: p β > p α .

[0068] Based on this, the quality inspection process involves two main risks: producer risk ( PR ) refers to the batch qualified ( p ≤ p α ), the probability of test failure due to sampling error is usually expressed as α ; Consumer risk ( CR ) refers to the batch failure ( p ≥ p β ), the probability of a test passing due to sampling error is usually expressed as β .

[0069] The goal of sampling plan design is to find the optimal solution (n, m, k) to ensure: PR ≤α, and CR ≤ β.

[0070] This ensures that risks for both producers and consumers are controlled, balancing the pass rate of qualified products and the rejection rate of unqualified products while maintaining a reasonable sample size and testing cost. A review mechanism is introduced to reduce testing time or cost, and a prior distribution is further introduced to optimize the decision-making process. Here, h 1(·) and h 2(·) respectively represent the producer and consumer p The prior probability density function of has a corresponding cumulative distribution function (CDF) H 1(·) and H 2(·). The Bayesian method can further optimize the sampling strategy and make the decision more rational. Therefore, in this embodiment, Bayesian producer risk and Bayesian consumer risk are used as producer risk. PR and consumer risks PR : (2) in, PR represents the Bayesian producer risk, p is the product defect rate, h 1( p ) is the prior probability density function.

[0071] (3) in, CR represents the Bayesian consumer risk, p is the product defect rate, h 2( p ) is the prior probability density function.

[0072] In order to ensure that both producer risk and consumer risk can be well controlled, it is necessary to balance the passing rate of qualified products in the batch and the rejection rate of unqualified products in the batch while determining the reasonable sample size and the cost required for the sampling test. That is, when the server 510 constructs the objective function, the objective function needs to meet the following constraints: the Bayesian producer risk corresponding to the sampling test and the received producer risk α Consistent, and the Bayesian consumer risk corresponding to the sampling experiment is consistent with the consumer risk received β The specific formula is as follows: (5) (6).

[0073] in, PR ( n 0, k 0) represents the optimal solution with the number of samples n 0 and the optimal solution of the acceptance coefficient k The Bayesian producer risk corresponding to 0 is, CR ( n 0, k 0) represents the optimal solution with the number of samples n 0 and the optimal solution of the acceptance coefficient k 0 corresponds to the Bayesian consumer risk.

[0074] Based on the above conditions, the formula for constructing the objective function in this embodiment is as follows: (1) in, TG ( n , k ) represents the number of samples n and the acceptance coefficient k The corresponding objective function is PR represents the Bayesian producer risk, CR represents the Bayesian consumer risk, α is the producer risk received, β is the consumer risk received. PR and CR It is expressed by formula (2) and formula (3).

[0075] Optionally, h 1(p )and h 2( p ) is the probability density function of the Beta distribution. Therefore, the probability density function of the Beta distribution is used as the prior probability density function h 1( p )and h 2( p ), can save more samples, thus reducing the time and cost of random inspection.

[0076] Optionally, based on the objective function, the particle swarm optimization algorithm is used to optimize the sample size and acceptance coefficient to determine the optimal solution for the sample size. n 0 and the optimal solution of the acceptance coefficient k 0, including: randomly generating multiple particles, and initializing the initial speed, initial position, initial historical optimal position corresponding to each particle, and the initial global optimal position corresponding to the particle group; iteratively updating the initial speed and initial position of each particle, determining the current position and current speed of each particle, and calculating the fitness value of each particle at the current position based on the objective function; iteratively updating the initial historical optimal position of each particle and the initial global optimal position of the particle group based on the fitness value corresponding to each particle; judging whether the current number of iterations has reached a preset iteration number threshold; when the current number of iterations reaches the iteration number threshold, stopping the iteration, and outputting the global optimal position corresponding to the current number of iterations, wherein the global optimal position is used to indicate the optimal solution for the number of samples n 0 And the optimal solution of acceptance coefficient k 0.

[0077] Specifically, referring to the above content, it can be known that when constructing the objective function, the server 510 uses the particle swarm optimization algorithm to optimize the sample quantity and the acceptance coefficient, and determines the optimal solution for the sample quantity. n 0 and the optimal solution of the acceptance coefficient k The operation of 0 is as follows: First, the server 510 randomly generates a plurality of particles and initializes the parameters corresponding to each particle. The parameters include: particle group size 1~m, inertia weight , learning factor , And random numbers , At the same time, the initial velocity corresponding to each particle 1~m is initialized , ,..., , initial position , ,..., , initial historical optimal position , ,..., , the fitness value corresponding to the initial historical optimal position , ,..., , the initial global optimal position corresponding to the particle swarm , ,..., And the fitness value corresponding to the initial global optimal position , ,..., .

[0078] in, ; ; ... .

[0079] in, represents the initial sample size of the jth particle, represents the initial acceptance coefficient of the jth particle. And, j=1~m.

[0080] Then, the server 510 iteratively updates the initial speed and initial position of each particle to determine the current position and current speed of each particle. The specific calculation formula of the speed iteration formula is as follows:

[0081] The specific calculation of the position iteration formula is as follows:

[0082] in, t Indicates the number of iterations; j represents the particle number, j =1~ m ; v j t , x j t Particles j Speed ​​and position before update; v j t+1 , x j t+1 Particles j Updated speed and position; p j t , gt Particles j The individual position of and the global optimal position of the group; ω 0 represents the inertia weight; c 1. c 2 represents the learning factor; r 1. r 2 represents a random number between 0 and 1.

[0083] When the server 510 determines the current position and current speed of each particle based on the above speed iteration formula and position iteration formula, the fitness value of each particle at the current position is calculated based on the target optimization function. For example, the server 510 determines the current speed of each particle based on the above speed iteration formula and position iteration formula. , ,..., and current location , ,..., Then, the server 510 determines the current position of each particle , ,..., In the case of , the number of samples of each particle at the current number of iterations can be further determined and acceptance coefficient . Then the server 510 will be the number of samples corresponding to the current number of iterations and the acceptance coefficient Input to the objective function and output the fitness value corresponding to the objective function. This includes the fitness value corresponding to the historical optimal position. , ,..., And the fitness value corresponding to the global optimal position , ,..., .

[0084] Furthermore, the server 510 iteratively updates the historical optimal position and the global optimal position of each particle based on the fitness value corresponding to each particle. For example, when the fitness value at the current iteration number is greater than the fitness value corresponding to the historical optimal position, the historical optimal position is updated to the current position, and when the historical optimal position of any particle in the particle swarm is better than the current global optimal position, the global optimal position is updated to the historical optimal position corresponding to the particle.

[0085] The server 510 then determines whether the current number of iterations has reached a preset iteration threshold. If the current number of iterations has reached the iteration threshold, the server 510 stops iterating and outputs the global optimal position corresponding to the current number of iterations. The global optimal position is used to indicate the optimal solution for the number of samples. n 0 And the optimal solution of acceptance coefficient k 0.

[0086] Therefore, in this embodiment, the particle swarm optimization algorithm is used to process the optimal sampling scheme (including the number of samples and the acceptance coefficient), which can make the final error reach , and ensure that the error range is minimized to the greatest extent. Then, when the product is sampled based on the determined optimal sampling plan, the accuracy of the sampling results can be guaranteed.

[0087] Optionally, the optimal solution based on the number of samples n 0, determine the number of samples related to the sampling experiment n , acceptance coefficient k And the truncated number m Operations include: optimal solution for sample size n 0 is rounded up to determine the number of samples related to the sampling experiment n ; Optimal solution based on sample size n 0. Accept the optimal solution of coefficient k 0 and censoring rate q , determine the truncation number m ; and according to the determined sample size n , determine the acceptance coefficient k .

[0088] Specifically, as described above, since the server 510 uses the particle swarm algorithm to calculate the optimal solution for the number of samples n 0 may not be an integer, and the actual number of products sampled can only be an integer. Therefore, in this embodiment, the server 510 calculates the optimal solution for the number of samples. n 0 is rounded up to determine the number of samples related to the sampling experiment n , denoted as .

[0089] Then, the server 510 optimizes the number of samples. n 0. Accept the optimal solution of coefficient k 0 and censoring rate q , determine the truncation number m ; and according to the determined sample size n , determine the acceptance coefficient k The specific process will be described in detail below.

[0090] Optionally, the optimal solution based on the number of samples n 0. Accept the optimal solution of coefficient k 0 and censoring rate q , determine the truncation number m The operation includes: according to the determined sample quantity n and acceptance coefficient optimal solution k 0Determining producer risk PR and consumer risks CR Whether the constraints are met PR ≤ α as well as CR ≤ β Then determine the truncation number based on the judgment result m .

[0091] Specifically, the server 510 determines the number of samples related to the sampling experiment. n In the case of , the truncated number is calculated as follows m : if q=0 ,but m=n ; if q≠0 ,but: The calculated sample size n and the optimal solution of the acceptance coefficient are k Substitute 0 into the above formulas (2) to (4) and verify the calculated producer risk PR and consumer risks CR Are the following constraints met? PR ≤ α ,as well as CR ≤ β .

[0092] When the above constraints are met, ; If the above constraints are not met, .

[0093] Optionally, based on the determined sample size n , determine the acceptance coefficient k The operation includes: n Substituting into the equation established according to the above formula (2), the acceptance coefficient is calculated k The corresponding first estimate k α ; The determined sample size n Substituting into the equation established according to the above formula (3), the acceptance coefficient is calculated k The corresponding second estimate kβ ; and the first estimate k α and the second estimate k β Find the average value and get the acceptance coefficient k .

[0094] Specifically, and in determining the number of samples related to the sampling experiment n In the case of k Located in the range In which k α and k β , are acceptance coefficients k Thus, the server 510 establishes the following equation according to the above formula (2): (7); And based on the above formula (3), the following equation is suggested: (8).

[0095] Thus, the server 510 calculates the acceptance coefficient k Estimated value of k α and k β .

[0096] Then the server 510 calculates the estimated value k α and k β . Determine the final acceptance coefficient k For estimated value k α and k β The average value of: .

[0097] In this way, the application calculates the number of samples to be inspected. n After that, the above operation makes the calculated acceptance coefficient k , which can be compared with the calculated sample size n Together, the number of samples n and acceptance coefficient k Calculate the Bayesian producer risk PR ( n , k ) and Bayesian consumer risk CR ( n , k ) satisfies the following constraints: PR ≤ α ,as well as CR ≤ β . This makes the sampling results more accurate.

[0098] Therefore, according to the first aspect of this embodiment, the technical effect of ensuring the reliability of the inspection results while improving the inspection efficiency can be achieved.

[0099] In addition, reference Figure 1 As shown, according to the second aspect of this embodiment, a storage medium is provided, wherein the storage medium includes a stored program, wherein when the program is running, a server executes any one of the above methods.

[0100] Therefore, according to this embodiment, the technical effect of ensuring the reliability of the inspection results while improving the inspection efficiency can be achieved.

[0101] It should be noted that, for the above-mentioned method embodiments, for the sake of simplicity, they are all described as a series of action combinations, but those skilled in the art should know that the present invention is not limited by the described action sequence, because according to the present invention, certain steps can be performed in other sequences or simultaneously. Secondly, those skilled in the art should also know that the embodiments described in the specification are all preferred embodiments, and the actions and modules involved are not necessarily required by the present invention.

[0102] Through the description of the above implementation methods, those skilled in the art can clearly understand that the method according to the above embodiment can be implemented by means of software plus a necessary general hardware platform, and of course can also be implemented by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present invention, or the part that contributes to the prior art, can be embodied in the form of a software product, which is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk), and includes a number of instructions for enabling a terminal device (which can be a mobile phone, computer, server, or network device, etc.) to execute the methods described in each embodiment of the present invention.

[0103] Example 2

[0104] Figure 4 The device for performing random inspection on the life of a product according to this embodiment is shown, and the device corresponds to the method according to embodiment 1. As shown in reference 4, the device includes: an experimental parameter receiving module 410, which is used to receive preset experimental parameters related to the random inspection experiment for performing random inspection on the logarithmic life of the product, wherein the preset experimental parameters include: producer risk related to the product α , Consumer Risk β , the highest defect rate acceptable to the producerp α and the lowest defect rate that is unacceptable to consumers p β , and the sampling experiment is based on a predetermined deletion rate q The constant truncated sampling experiment; the objective function construction module 420 is used to construct the objective function based on the preset experimental parameters, wherein the variable of the objective function is the number of samples in the sampling experiment n and the acceptance coefficient k , where the acceptance coefficient k It is related to the confidence that the logarithmic life of the sample is greater than the predetermined logarithmic life threshold, and the objective function satisfies the condition that the Bayesian producer risk corresponding to the sampling experiment is equal to the producer risk received α The Bayesian consumer risk corresponding to the sampling experiment is consistent with the received consumer risk. β ; Optimization module 430, used to optimize the number of samples based on the objective function using the particle swarm optimization algorithm n and the acceptance coefficient k Optimize and determine the optimal solution for the number of samples n 0 and the optimal solution of the acceptance coefficient k 0; Sample quantity and acceptance coefficient determination module 440, used to optimally solve the problem according to the sample quantity n 0, determine the number of samples related to the sampling experiment n , acceptance coefficient k And the truncated number m ; and product sampling module 450, for determining the number of samples according to the determined n , acceptance coefficient k And the truncated number m , conduct random inspections on products.

[0105] Optionally, the target function construction module 420 includes: a target function construction submodule, wherein the target function construction submodule is used to construct the following function: TG ( n , k )=( PR - α ) 2 +( CR - β ) 2 (1), where α is the producer risk received, β For the consumer risk received, PR For the Bayesian producer risk: (2), and CR For the Bayesian consumer risk: (3), and among them (4), wherep is the product defect rate, h 1( p )and h 2( p ) is the prior probability density function, , and is the covariance coefficient of the inverse matrix of the Fisher information matrix under constant censoring, Φ ( ) is the standard normal distribution function.

[0106] Optionally, h 1( p )and h 2( p ) is the probability density function of the Beta distribution.

[0107] Optionally, the optimization module 430 includes: a particle generation module, which is used to randomly generate multiple particles, and initialize the generation of an initial speed, an initial position, an initial historical optimal position corresponding to each particle, and an initial global optimal position corresponding to the particle group; a first iterative update module, which is used to iteratively update the initial speed and initial position of each particle, determine the current position and current speed of each particle, and calculate the fitness value of each particle at the current position based on the objective function; a second iterative update module, which is used to iteratively update the historical optimal position of each particle and the global optimal position of the particle group based on the fitness value corresponding to each particle; a judgment module, which is used to judge whether the current number of iterations has reached a preset number of iterations threshold; a result output module, which is used to stop the iteration when the current number of iterations reaches the number of iterations threshold, and output the global optimal position corresponding to the current number of iterations, wherein the global optimal position is used to indicate the optimal solution for the number of samples. n 0 And the optimal solution of acceptance coefficient k 0.

[0108] Optionally, the sample quantity and acceptance coefficient determination module 440 includes: an upper rounding module for determining the optimal solution for the sample quantity. n 0 is rounded up to determine the number of samples related to the sampling experiment n ; Truncation number determination module, used to optimally solve the problem according to the number of samples n 0 and censoring rate q , determine the truncation number m ; and an acceptance coefficient determination module for determining the number of samples determined n , determine the acceptance coefficient k .

[0109] Optionally, the acceptance coefficient determination module includes: a first estimation value calculation module, which is used to calculate the determined sample quantity nSubstituting into the above formula (2), we can calculate the acceptance coefficient k The corresponding first estimate k α ; A second estimation value calculation module is used to determine the number of samples n Substituting into the above formula (3), we can calculate the acceptance coefficient k The corresponding second estimate k β ; and an acceptance coefficient determination submodule for converting the first estimated value k α and the second estimate k β Find the average value and get the acceptance coefficient k .

[0110] Therefore, according to this embodiment, the technical effect of ensuring the reliability of the inspection results while improving the inspection efficiency can be achieved.

[0111] Example 3 Figure 5 FIG. 4 shows a device for performing random inspection on product life according to this embodiment, which corresponds to the method according to embodiment 1. Figure 5 As shown, the device includes: a server 510; and a memory 520, connected to the server 510, for providing the server 510 with instructions for processing the following processing steps: receiving preset experimental parameters related to a sampling test for sampling the logarithmic life of a product, wherein the preset experimental parameters include: producer risk associated with the product α , Consumer Risk β , the highest defect rate acceptable to the producer p α and the lowest defect rate that is unacceptable to consumers p β , and the sampling experiment is based on a predetermined deletion rate q Based on the preset experimental parameters, the objective function is constructed, where the variable of the objective function is the number of samples in the random inspection experiment. n and the acceptance coefficient k , where the acceptance coefficient k It is related to the confidence that the logarithmic life of the sample is greater than the predetermined logarithmic life threshold, and the objective function satisfies the condition that the Bayesian producer risk corresponding to the sampling experiment is equal to the producer risk received α The Bayesian consumer risk corresponding to the sampling experiment is consistent with the received consumer risk. β ; Based on the objective function, the particle swarm optimization algorithm is used to optimize the number of samples n and the acceptance coefficient k Optimize and determine the optimal solution for the number of samplesn 0 and the optimal solution of the acceptance coefficient k 0; optimal solution based on sample size n 0, determine the number of samples related to the sampling experiment n , acceptance coefficient k And the truncated number m ; and according to the determined sample size n , acceptance coefficient k And the truncated number m , conduct random inspections on products.

[0112] Optionally, based on the preset experimental parameters, the operation of constructing the objective function includes constructing the following objective function: TG ( n , k )=( PR - α ) 2 +( CR - β ) 2 (1), where α is the producer risk received, β For the consumer risk received, PR For the Bayesian producer risk: (2), and CR For the Bayesian consumer risk: (3), and among them (4), where p is the product defect rate, h 1( p )and h 2( p ) is the prior probability density function, , and is the covariance coefficient of the inverse matrix of the Fisher information matrix under constant censoring, Φ ( ) is the standard normal distribution function.

[0113] Optionally, h 1( p )and h 2( p ) is the probability density function of the Beta distribution.

[0114] Optionally, based on the objective function, the particle swarm optimization algorithm is used to optimize the sample size and acceptance coefficient to determine the optimal solution for the sample size. n 0 and the optimal solution of the acceptance coefficient k0, including: randomly generating multiple particles, and initializing the initial speed, initial position, initial historical optimal position corresponding to each particle, and the initial global optimal position corresponding to the particle group; iteratively updating the initial speed and initial position of each particle, determining the current position and current speed of each particle, and calculating the fitness value of each particle at the current position based on the objective function; iteratively updating the initial historical optimal position of each particle and the initial global optimal position of the particle group based on the fitness value corresponding to each particle; judging whether the current number of iterations has reached a preset iteration number threshold; when the current number of iterations reaches the iteration number threshold, stopping the iteration, and outputting the global optimal position corresponding to the current number of iterations, wherein the global optimal position is used to indicate the optimal solution for the number of samples n 0 And the optimal solution of acceptance coefficient k 0.

[0115] Optionally, the optimal solution based on the number of samples n 0, determine the number of samples related to the sampling experiment n , acceptance coefficient k And the truncated number m Operations include: optimal solution for sample size n 0 is rounded up to determine the number of samples related to the sampling experiment n ; Optimal solution based on sample size n 0 and censoring rate q , determine the truncation number m ; and according to the determined sample size n , determine the acceptance coefficient k .

[0116] Optionally, based on the determined sample size n , determine the acceptance coefficient k The operation includes: n Substituting into the above formula (2), we can calculate the acceptance coefficient k The corresponding first estimate k α ; The determined sample size n Substituting into the above formula (3), we can calculate the acceptance coefficient k The corresponding second estimate k β ; and the first estimate k α and the second estimate k β Find the average value and get the acceptance coefficient k .

[0117] Therefore, according to this embodiment, the technical effect of ensuring the reliability of the inspection results while improving the inspection efficiency can be achieved.

[0118] The serial numbers of the above embodiments of the present invention are only for description and do not represent the advantages or disadvantages of the embodiments.

[0119] In the above embodiments of the present invention, the description of each embodiment has its own emphasis. For parts that are not described in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.

[0120] In the several embodiments provided in this application, it should be understood that the disclosed technical content can be implemented in other ways. Among them, the device embodiments described above are only schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of units or modules, which can be electrical or other forms.

[0121] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0122] In addition, each functional unit in each embodiment of the present invention may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.

[0123] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, or all or part of the technical solution can be embodied in the form of a software product. The computer software product is stored in a storage medium, including several instructions for a computer device (which can be a personal computer, server or network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present invention. The aforementioned storage medium includes: U disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), mobile hard disk, disk or optical disk, etc. Various media that can store program codes.

[0124] The above is only a preferred embodiment of the present invention. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principle of the present invention. These improvements and modifications should also be regarded as the scope of protection of the present invention.

Claims

1. A method for spot checking product life, characterized in that: include: Receiving preset experimental parameters related to a random inspection experiment for random inspection of the logarithmic life of a product, wherein the preset experimental parameters include: a producer risk associated with the product α , Consumer Risk β , the highest defect rate acceptable to the producer p α and the lowest defect rate that is unacceptable to consumers p β , and the sampling experiment is based on a predetermined deletion rate q The constant censoring sampling experiment; Based on the preset experimental parameters, an objective function is constructed, wherein the variable of the objective function is the number of samples in the sampling experiment. n and the acceptance coefficient k , where the acceptance coefficient k The confidence level that the logarithmic life of the sample is greater than a predetermined logarithmic life threshold is related to the confidence level that the logarithmic life threshold of the sample is greater than a predetermined logarithmic life threshold, and the objective function satisfies the condition that the Bayesian producer risk corresponding to the sampling experiment is equal to the producer risk received. α The Bayesian consumer risk corresponding to the sampling experiment is consistent with the consumer risk received β Consistency; Based on the objective function, the number of samples is optimized using a particle swarm optimization algorithm. n And the acceptance coefficient k Optimize and determine the optimal solution for the number of samples n 0 and the optimal solution of the acceptance coefficient k 0; The optimal solution based on the number of samples n 0 and the optimal solution of the acceptance coefficient k 0, determine the number of samples related to the sampling experiment n , acceptance coefficient k And the truncated number m ;as well as According to the determined sample size n , acceptance coefficient k And the truncated number m , conduct random inspections on the products.

2. The method according to claim 1, characterized in that Based on the preset experimental parameters, the operation of constructing the objective function includes constructing the following objective function: TG ( n , k )=( PR - α ) 2 +( CR - β ) 2 (1), where α is the producer risk received, β For the consumer risk received, PR The Bayesian producer risk is: (2), and CR For the Bayesian consumer risk: (3), and among them (4), where p is the defect rate of the product, h 1( p )and h 2( p ) is the prior probability density function, , and is the covariance coefficient of the inverse matrix of the Fisher information matrix under constant censoring, Φ ( ) is the standard normal distribution function.

3. The method according to claim 2, characterized in that h 1( p )and h 2( p ) is the probability density function of the Beta distribution.

4. The method according to claim 2, characterized in that: Based on the objective function, the particle swarm optimization algorithm is used to optimize the sample size and the acceptance coefficient to determine the optimal solution for the sample size. n 0 and the optimal solution of the acceptance coefficient k 0 operations, including: Randomly generate multiple particles, and initialize the initial speed, initial position, initial historical optimal position corresponding to each particle and the initial global optimal position corresponding to the particle group; Iteratively updating the initial velocity and initial position of each particle, determining the current position and current velocity of each particle, and calculating the fitness value of each particle at the current position based on the objective function; Iteratively updating the historical optimal position of each particle and the global optimal position of the particle swarm based on the fitness value corresponding to each particle; Determine whether the current number of iterations has reached a preset number of iterations threshold; When the current number of iterations reaches the iteration number threshold, the iteration is stopped, and the global optimal position corresponding to the current number of iterations is output, wherein the global optimal position is used to indicate the optimal solution for the number of samples. n 0 And the optimal solution of the acceptance coefficient k 0.

5. The method according to claim 4, characterized in that The optimal solution based on the number of samples n 0 and the optimal solution of the acceptance coefficient k 0, determine the number of samples related to the sampling experiment n , acceptance coefficient k And the truncated number m Operations include: The optimal solution for the sample size n 0 is rounded up to determine the number of samples related to the sampling experiment n ; The optimal solution based on the number of samples n 0. The optimal solution of the acceptance coefficient k 0 and the censoring rate q , determine the truncation number m ;as well as According to the determined sample size n , determine the acceptance coefficient k .

6. The method according to claim 5, characterized in that According to the determined sample size n , determine the acceptance coefficient k Operations include: The determined sample size n Substituting into the equation established according to the above formula (2), the acceptance coefficient is calculated to be k The corresponding first estimate k α ; The determined sample size n Substituting into the equation established according to the above formula (3), the acceptance coefficient is calculated to be k The corresponding second estimate k β ;as well as The first estimate k α and the second estimate k β Find the average value and get the acceptance coefficient k .

7. A storage medium, characterized in that: The storage medium includes a stored program, wherein when the program is run, the server executes the method according to any one of claims 1 to 6.

8. A device for spot checking product life, characterized in that: include: The experimental parameter receiving module is used to receive preset experimental parameters related to the random inspection experiment for random inspection of the logarithmic life of the product, wherein the preset experimental parameters include: the producer risk related to the product α , Consumer Risk β , the highest defect rate acceptable to the producer p α and the lowest defect rate that is unacceptable to consumers p β , and the sampling experiment is based on a predetermined deletion rate q The constant censoring sampling experiment; An objective function construction module is used to construct an objective function based on the preset experimental parameters, wherein the variable of the objective function is the number of samples in the sampling experiment. n and the acceptance coefficient k , where the acceptance coefficient k The confidence level that the logarithmic life of the sample is greater than a predetermined logarithmic life threshold is related to the confidence level that the logarithmic life threshold of the sample is greater than a predetermined logarithmic life threshold, and the objective function satisfies the condition that the Bayesian producer risk corresponding to the sampling experiment is equal to the producer risk received. α The Bayesian consumer risk corresponding to the sampling experiment is consistent with the consumer risk received β Consistency; An optimization module is used to optimize the number of samples based on the objective function using a particle swarm optimization algorithm. n And the acceptance coefficient k Optimize and determine the optimal solution for the number of samples n 0 and the optimal solution of the acceptance coefficient k 0; The sample quantity and acceptance coefficient determination module is used to optimally solve the problem according to the sample quantity. n 0, determine the number of samples related to the sampling experiment n , acceptance coefficient k And the truncated number m ;as well as Product sampling module, used to determine the number of samples n , acceptance coefficient k And the truncated number m , conduct random inspections on the products.

9. The device according to claim 8, characterized in that The objective function construction module includes: an objective function construction submodule, wherein the objective function construction submodule is used to construct the following function: TG ( n , k )=( PR - α ) 2 +( CR - β ) 2 (1), where α is the producer risk received, β For the consumer risk received, PR The Bayesian producer risk is: (2), and CR For the Bayesian consumer risk: (3), and among them (4), where p is the defect rate of the product, h 1( p )and h 2( p ) is the prior probability density function, , and is the covariance coefficient of the inverse matrix of the Fisher information matrix under constant censoring, Φ ( ) is the standard normal distribution function.

10. A device for spot checking product life, characterized in that: include: server; as well as A memory, connected to the server, is used to provide the server with instructions for processing the following processing steps: Receiving preset experimental parameters related to a random inspection experiment for random inspection of the logarithmic life of a product, wherein the preset experimental parameters include: a producer risk associated with the product α , Consumer Risk β , the highest defect rate acceptable to the producer p α and the lowest defect rate that is unacceptable to consumers p β , and the sampling experiment is based on a predetermined deletion rate q The constant censoring sampling experiment; Based on the preset experimental parameters, an objective function is constructed, wherein the variable of the objective function is the number of samples in the sampling experiment. n and the acceptance coefficient k , where the acceptance coefficient k The confidence level that the logarithmic life of the sample is greater than a predetermined logarithmic life threshold is related to the confidence level that the logarithmic life threshold of the sample is greater than a predetermined logarithmic life threshold, and the objective function satisfies the condition that the Bayesian producer risk corresponding to the sampling experiment is equal to the producer risk received. α The Bayesian consumer risk corresponding to the sampling experiment is consistent with the consumer risk received β Consistency; Based on the objective function, the number of samples is optimized using a particle swarm optimization algorithm. n And the acceptance coefficient k Optimize and determine the optimal solution for the number of samples n 0 and the optimal solution of the acceptance coefficient k 0; The optimal solution based on the number of samples n 0, determine the number of samples related to the sampling experiment n , acceptance coefficient k And the truncated number m ;as well as According to the determined sample size n , acceptance coefficient k And the truncated number m , conduct random inspections on the products.

Citation Information

Patent Citations

  • A honey detection method by support vector machine classifier parameter selection based on particle swarm optimization

    CN104749219A

  • Product reliability evaluation method

    CN107767019A

  • Discrete parameter regression method for multi-stage regular sampling inspection type product storage life evaluation

    CN112949092A

  • Electric power system material sampling inspection management method and device

    CN116452054A

  • Target tracking method and system based on improved quantum particle swarm optimization particle filter, and medium

    CN118115537A