Parameter optimization methods, systems, electronic devices, and computer-readable storage media
The detection parameters of the optical detection algorithm are optimized by using the particle swarm optimization algorithm. The global optimal position parameters are selected by using the iteration and scoring mechanism of the particle swarm optimization algorithm, which solves the problem of long optimization time of detection parameters and achieves faster optimization of detection parameters.
Patent Information
- Application Number
- CN202211514677.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-11-29
- Publication Date
- 2025-12-02
- Estimated Expiration
- 2042-11-29
AI Technical Summary
In existing technologies, the optimization time for detection parameters in optical detection algorithms is too long, and this time increases significantly with the number of detection parameters.
The detection parameters are optimized using the particle swarm optimization algorithm. By annotating the regions to be detected in the template image, the optimization range of the detection parameters is determined. The target number of particles in the particle swarm is distributed within this range. The global optimal position parameters are selected by the iteration and scoring mechanism of the particle swarm optimization algorithm, forming a cyclical optimization between the detection algorithm and the particle swarm optimization algorithm.
It improves the quality and speed of detection parameter optimization, quickly finds the optimal parameters of the detection algorithm, and solves the problem of long optimization time for detection parameters.
Smart Images

Figure CN115797286B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of optical inspection technology, and in particular to a parameter optimization method, a material dispensing device, a material dispensing equipment, and a computer-readable storage medium. Background Technology
[0002] Currently, optical inspection technology has been widely used in the field of industrial defect detection, such as chip inspection. Before detecting defects, it is necessary to manually adjust the detection parameters of the detection algorithm to optimize the target detection parameters, and then use the target detection parameters to detect defects.
[0003] As the accuracy requirements for defect detection increase, detection algorithms become more complex, and the number of detection parameters also increases. The optimization time for detection parameters increases significantly with the increase in the number of detection parameters, resulting in the technical problem of long optimization time for detection parameters. Summary of the Invention
[0004] The purpose of this invention is to provide a parameter optimization method, system, electronic device, and computer-readable storage medium to solve the technical problem of long optimization time for detection parameters in the prior art.
[0005] In a first aspect, the present invention provides a parameter optimization method, comprising:
[0006] The regions to be detected in the template image are labeled to obtain the labeled regions;
[0007] Determine the optimization range of the detection parameters of the detection algorithm for the pre-constructed detection region, and distribute the target number of particles in the particle swarm within the optimization range of the detection parameters;
[0008] The verification region extraction step involves calculating the verification region of the region to be detected using the calibration position parameters of each particle in the current particle swarm.
[0009] The parameter scoring step involves scoring the calibration position parameters of each particle using the verification region and the labeled region of each particle in the current particle swarm, respectively, to obtain the position parameter score of each particle.
[0010] The local optimal parameter screening step uses the current position parameter score and the position parameter scores of previous generations for each particle to screen out the local optimal position parameters for each particle in the current generation.
[0011] The global optimal parameter selection step uses the position parameter scores of all particles in the particle swarm to select the optimal local optimal position parameter as the global optimal position parameter of the current particle swarm.
[0012] The iteration count determination step determines whether the iteration count has reached the preset iteration count threshold. If so, the globally optimal position parameter is determined as the optimal parameter of the detection algorithm. If not, the process proceeds to the iteration position parameter acquisition step.
[0013] The iterative position parameter acquisition step uses the particle swarm optimization algorithm, the global optimal position parameters of the current particle swarm, and the local optimal position parameters of each particle in the current swarm to iterate and obtain the iterative position parameters of each particle in the next generation particle swarm.
[0014] The location parameter iteration step involves iterating the calibration location parameters in the verification region extraction step using iterative location parameters, and then sequentially executing the verification region extraction step, the parameter scoring step, the local optimal parameter filtering step, the global optimal parameter filtering step, and the iteration count determination step.
[0015] As an embodiment of the present invention, before the local optimal parameter screening step, the parameter optimization method further includes:
[0016] The algebraic judgment step determines whether the particle swarm is in the first generation. If so, the calibration position parameters of each particle in the current generation of the particle swarm are determined as the local optimal position parameters of each particle, and the process proceeds to the global optimal parameter acquisition step. If not, the local optimal parameter filtering step is executed.
[0017] As an embodiment of the present invention, the step of annotating the region to be detected in the template image to obtain the annotated region includes:
[0018] The region to be detected in the template image is outlined to obtain the first labeled region;
[0019] The region to be detected in the template image is expanded and labeled to obtain a second labeled region, and the second labeled region covers the first labeled region.
[0020] As an embodiment of the present invention, the parameter scoring step includes:
[0021] The overlapping area between the verification area and the first annotation area is set as the first result area;
[0022] Subtract the first labeled area from the second labeled area to obtain the second result area;
[0023] The overlapping area between the verification area and the second result area is set as the third result area;
[0024] Calculate the ratio of the first result area to the first labeled area to obtain the first ratio;
[0025] Calculate the ratio of the third result region to the second result region to obtain the second ratio;
[0026] Calculate the ratio of the first ratio to the second ratio to obtain a third ratio, and set the third ratio as the parameter score.
[0027] As an embodiment of the present invention, the iterative position parameter acquisition step includes:
[0028] The inertia coefficient iterative formula for the particle swarm optimization algorithm is as follows:
[0029] ω=ω max -(ω max -ω min )t / t max ;
[0030] Construct the iterative formula for the parameter changes in the particle swarm optimization algorithm;
[0031] V ij (t+1) =ωV ij (t) +c1r1(P ij (t) -X ij (t) )+c2r2(P tj (t) -X ij (t) );
[0032] Constructing the position parameter iteration formula for the particle swarm algorithm:
[0033] X ij (t+1) =X ij (t) +V ij (t+1) ;
[0034] The parameter change value is obtained by calculating the iterative formula using the local optimal position parameters of each particle in the current generation and the global optimal position parameters of the current particle swarm.
[0035] The iterative formula for calculating the position parameters using the parameter change values yields the iterative position parameters.
[0036] Where, ω max ω is the maximum inertia coefficient of the particle. min t is the minimum inertia coefficient of the particle. max Where c1 is the individual learning factor of the particle and c2 is the collective learning factor of the particle; t is the current iteration number; r1 and r2 are independent random numbers in the interval [0, 1]; ω is the particle's inertia coefficient; Vij (t) V represents the change in the position parameter of particle i in the t-th iteration; ij (t+1) P represents the change in the position parameter of particle i at position j during the (t+1)th iteration; ij (t) Let J be the local optimal position parameter of particle i in the t-th iteration; P tj (t) Let X be the globally optimal position parameter of the particle swarm in the t-th iteration; ij (t) Let X be the calibration position parameter of particle i in the t-th iteration; ij (t+1) Let j be the calibration position parameter of particle i in the t-th iteration.
[0037] As an embodiment of the present invention, before calculating the position using the parameter change value using the parameter iteration formula to obtain the iterative position parameter, the iterative position parameter acquisition step further includes:
[0038] Determine whether the parameter change value of the particle is less than the preset lower limit value. If so, update the parameter change value of the particle to the lower limit value. If not, determine whether the parameter change value is greater than the preset upper limit value. If so, update the parameter change value of the particle to the upper limit value.
[0039] After obtaining the iterative position parameters by calculating the position using the parameter change values using the iterative formula, the step of obtaining the iterative position parameters further includes:
[0040] If the iterative position parameter is less than a preset lower limit, the particle's iterative position parameter is updated to the lower limit. If not, the particle's iterative position parameter is updated to the upper limit.
[0041] As an embodiment of the present invention, the verification region extraction step includes:
[0042] The first extraction region is obtained by dynamically thresholding the region to be detected in the template image using the calibration position parameters of each particle.
[0043] Static thresholding is performed on the region to be detected in the template image using the calibration position parameters of each particle to obtain the second extraction region;
[0044] The first extracted region and the second extracted region are merged to obtain the merged region;
[0045] The intersection of the merged region and the second labeled region is performed to obtain the merged region after intersection.
[0046] The merged region after the intersection is subjected to a closing operation to obtain the verification region;
[0047] The intersection of the verification region and the second annotation region is performed to obtain the intersection verification region.
[0048] Secondly, the present invention provides a detection parameter optimization system, comprising:
[0049] The annotation module is used to annotate the regions to be detected in the template image to obtain the annotated regions;
[0050] The particle distribution module determines the optimization range of the detection parameters of the detection algorithm for the pre-constructed detection area to be detected, and distributes the target number of particles in the particle swarm within the optimization range of the detection parameters.
[0051] The verification region extraction module is used to calculate the verification region of the region to be detected by the detection algorithm using the calibration position parameters of each particle in the current particle swarm.
[0052] The parameter scoring module is used to score the calibration position parameters of each particle using the verification region and the annotation region of each particle in the current particle swarm, respectively, to obtain the position parameter score of each particle.
[0053] The first filtering module is used to filter out the local optimal position parameters of each particle in the current generation by using the position parameter score of each particle in the current generation and the position parameter scores of the previous several generations.
[0054] The second filtering module is used to filter out an optimal local optimal position parameter as the global optimal position parameter of the current particle swarm using the position parameter scores of all particles in the particle swarm.
[0055] The first judgment module is used to determine whether the number of iterations has reached a preset iteration threshold. If so, the globally optimal position parameter is determined as the optimal parameter of the detection algorithm; otherwise, the process is transferred to the first iteration module.
[0056] The first iteration module is used to iterate the iterative position parameters of each particle in the next generation of particle swarm using the particle swarm algorithm, the global optimal position parameters of the current particle swarm, and the local optimal position parameters of each particle in the current generation.
[0057] The second iteration module is used to iterate the calibration position parameters in the verification region extraction step using the iteration position parameters.
[0058] Thirdly, the present invention provides an electronic device comprising: a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, when the processor executes the computer program, it implements the method as described in the first aspect.
[0059] Fourthly, the present invention provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the method described in the first aspect.
[0060] Implementing the embodiments of the present invention will have the following beneficial effects:
[0061] This invention optimizes the detection parameters of the detection algorithm using a particle swarm optimization (PSO) algorithm. Specifically, for the region to be detected in the template image, not only is the labeled region obtained, but the optimization range of the detection parameters of the detection algorithm for the pre-constructed region to be detected is also determined. The target number of particles in the particle swarm is distributed within the range of the detection parameters, meaning that each particle has a calibration position parameter, which is the detection parameter of the detection algorithm. Therefore, by using the calibration position parameter of each particle to calculate the detection algorithm, a verification region for the region to be detected can be obtained. This invention uses the verification region and labeled region of each particle in the current particle swarm to score the calibration position parameter of each particle. The higher the score, the better the calibration position parameter of the particle. Then, the current position parameter score and the position parameter scores of previous generations of each particle are used to filter out the local optimal position parameters of each particle in the current generation. Finally, the position parameter scores of all particles in the particle swarm are used to filter out a... The optimal local optimal position parameters are used as the global optimal position parameters of the current particle swarm. After obtaining the global optimal position parameters, the number of iterations is judged. If the number of iterations has not reached the preset iteration threshold, the calibration position parameters of the particles need to be iterated. Specifically, the particle swarm optimization algorithm, the global optimal position parameters of the current particle swarm, and the local optimal position parameters of each particle in the current swarm are used to iterate the iterative position parameters of each particle in the next generation particle swarm. Then, the iterative position parameters are used to iterate the calibration position parameters in the verification region extraction step. The verification region extraction step, parameter scoring step, local optimal parameter filtering step, global optimal parameter filtering step, and iteration count judgment step are executed again until the number of iterations reaches the preset iteration threshold. Only then is it considered that the optimization of the calibration position parameters of all particles has been completed, and the global optimal position parameters of the current particle swarm are determined as the optimal parameters of the detection algorithm, which means that the optimization of the detection parameters is completed. This invention incorporates the verification region obtained from the detection algorithm using calibration position parameters into the parameter scoring step of the particle swarm optimization. It updates the calibration position parameters using the iterative position parameters obtained from the particle swarm optimization step, and then substitutes these parameters into the detection algorithm, thus forming a loop between the detection algorithm and the particle swarm optimization algorithm. Furthermore, it uses the labeled region and the verification region to score the calibration position parameters of the particles, improving the accuracy of selecting local and global optimal parameters, more accurately calculating the iterative position parameters, and improving the optimization quality of the detection parameters. This technical solution utilizes the rapid update of the calibration position parameters of the particles in the particle swarm optimization, enabling quick identification of the global optimal position parameters of the particle swarm and optimization of the optimal parameters for the detection algorithm, thus solving the technical problem of long optimization time for detection parameters in existing technologies. Attached Figure Description
[0062] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0063] Figure 1 This is a flowchart illustrating the parameter optimization method shown in an embodiment of the present invention;
[0064] Figure 2 This is a structural block diagram of the parameter optimization system shown in an embodiment of the present invention;
[0065] Figure 3 This is a structural block diagram of the electronic device shown in an embodiment of the present invention. Detailed Implementation
[0066] To make the objectives, features, and advantages of this invention more apparent and understandable, the technical solutions of the embodiments of this invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of this invention, and not all of them. All other embodiments obtained by those skilled in the art based on the embodiments of this invention without creative effort are within the scope of protection of this invention.
[0067] When inspecting chips, different detection algorithms are constructed for chip solder joint inspection, wire bonding inspection, surface contamination inspection, and finger contamination inspection. Based on this, the present invention provides a parameter optimization method for optimizing the detection parameters of the detection algorithm.
[0068] See Figure 1 The optimization methods for this parameter include:
[0069] S1. Mark the areas to be detected in the template image to obtain the marked areas; specifically, obtaining the template image means finding a defect-free product, taking a picture of the product, and obtaining the template image.
[0070] S2. Construct a detection algorithm for the region to be detected, determine the optimization range of the detection parameters of the detection algorithm, and distribute the target number of particles in the particle swarm within the optimization range of the detection parameters.
[0071] S3, Verification region extraction step: The verification region of the area to be detected is obtained by calculating the calibration position parameters of each particle in the current particle swarm using the detection algorithm.
[0072] S4. Parameter scoring step: The calibration position parameters of each particle are scored using the verification region and the labeled region of each particle in the current particle swarm, respectively, to obtain the position parameter score of each particle.
[0073] S5. Local optimal parameter screening step: Use the current position parameter score of each particle and the position parameter scores of the previous several generations to screen out the local optimal position parameters of each particle in the current generation.
[0074] S6. Global optimal parameter selection step: Use the position parameter scores of all particles in the particle swarm to select the optimal local optimal position parameter as the global optimal position parameter of the current particle swarm.
[0075] S7. Iteration count judgment step: Determine whether the iteration count has reached the preset iteration count threshold. If yes, determine the global optimal position parameter as the optimal parameter of the detection algorithm. If no, proceed to the iteration position parameter acquisition step.
[0076] S8. Iterative position parameter acquisition step: Using the particle swarm optimization algorithm, the global optimal position parameter of the current particle swarm, and the local optimal position parameter of each particle in the current particle swarm, the iterative position parameter of each particle in the next generation particle swarm is obtained iteratively.
[0077] S9. Position parameter iteration step: Use the iterative position parameters to iterate the calibration position parameters in the verification region extraction step, and sequentially execute the verification region extraction step, the parameter scoring step, the local optimal parameter filtering step, the global optimal parameter filtering step, and the iteration count judgment step.
[0078] This invention optimizes the detection parameters of the detection algorithm using a particle swarm optimization (PSO) algorithm. Specifically, for the region to be detected in the template image, not only is the labeled region obtained, but the optimization range of the detection parameters of the detection algorithm for the pre-constructed region to be detected is also determined. The target number of particles in the particle swarm is distributed within the range of the detection parameters, meaning that each particle has a calibration position parameter, which is the detection parameter of the detection algorithm. Therefore, by using the calibration position parameter of each particle to calculate the detection algorithm, a verification region for the region to be detected can be obtained. This invention uses the verification region and labeled region of each particle in the current particle swarm to score the calibration position parameter of each particle. The higher the score, the better the calibration position parameter of the particle. Then, the current position parameter score and the position parameter scores of previous generations of each particle are used to filter out the local optimal position parameters of each particle in the current generation. Finally, the position parameter scores of all particles in the particle swarm are used to filter out a... The optimal local optimal position parameters are used as the global optimal position parameters of the current particle swarm. After obtaining the global optimal position parameters, the number of iterations is judged. If the number of iterations has not reached the preset iteration threshold, the calibration position parameters of the particles need to be iterated. Specifically, the particle swarm optimization algorithm, the global optimal position parameters of the current particle swarm, and the local optimal position parameters of each particle in the current swarm are used to iterate the iterative position parameters of each particle in the next generation particle swarm. Then, the iterative position parameters are used to iterate the calibration position parameters in the verification region extraction step. The verification region extraction step, parameter scoring step, local optimal parameter filtering step, global optimal parameter filtering step, and iteration count judgment step are executed again until the number of iterations reaches the preset iteration threshold. Only then is it considered that the optimization of the calibration position parameters of all particles has been completed, and the global optimal position parameters of the current particle swarm are determined as the optimal parameters of the detection algorithm, which means that the optimization of the detection parameters is completed. This invention incorporates the verification region obtained from the detection algorithm using calibration position parameters into the parameter scoring step of the particle swarm optimization. It updates the calibration position parameters using the iterative position parameters obtained from the particle swarm optimization step, and then substitutes these parameters into the detection algorithm, thus forming a loop between the detection algorithm and the particle swarm optimization algorithm. Furthermore, it uses the labeled region and the verification region to score the calibration position parameters of the particles, improving the accuracy of selecting local and global optimal parameters, more accurately calculating the iterative position parameters, and improving the optimization quality of the detection parameters. This technical solution utilizes the rapid update of the calibration position parameters of the particles in the particle swarm optimization, enabling quick identification of the global optimal position parameters of the particle swarm and optimization of the optimal parameters for the detection algorithm, thus solving the technical problem of long optimization time for detection parameters in existing technologies.
[0079] In some specific embodiments, when the staff narrows down the optimization range of the detection parameters based on practical experience and iterating the particle swarm is not required, the preset iteration number threshold is zero. After screening the globally optimal position parameters of the first-generation particle swarm, the globally optimal parameters can be determined as the optimal parameters of the detection algorithm. If iterating the particle swarm is required, the preset iteration number threshold is N (N is a positive integer). After screening the globally optimal position parameters of the first-generation particle swarm, the particle swarm has not yet been iterated, and the iteration number has not reached the preset iteration number threshold. Therefore, it is necessary to proceed to the iteration position parameter acquisition step and the position parameter iteration step to obtain the iteration position parameters. The calibration position parameters in the extraction region step are then used to iterate and verify the iteration position parameters. The verification region extraction step, the parameter scoring step, the local optimal parameter screening step, the globally optimal parameter screening step, and the iteration number judgment step are then executed sequentially until it is determined that the iteration number has reached N. Only then are the globally optimal position parameters determined as the optimal parameters of the detection algorithm.
[0080] The following explains the concept of the current generation particle swarm: After distributing the target number of particles within the optimized range of the detection parameters, the particle swarm at this point is the first generation particle swarm, which is also the current generation particle swarm. After the first iteration (iterating the first generation particle swarm), the particle swarm is the second generation particle swarm, which is the current generation particle swarm, and the first generation particle swarm is the previous generation particle swarm. If a second iteration is to be performed to form a third generation particle swarm (iterating the second generation particle swarm), then the third generation particle swarm that has not yet emerged is the next generation of the current generation particle swarm…
[0081] In some specific embodiments, when the area to be detected is a bonding wire, the detection parameters of the detection algorithm include mean filtering, minimum contrast, minimum gray level, maximum gray level, etc.; that is, after distributing the target number of particles within the parameter range, the calibration position parameters of each particle include mean filtering, minimum contrast, minimum gray level, and maximum gray level.
[0082] In some specific embodiments, when the area to be detected is a bonding wire, the mean filtering range can be set to [1, 99], the minimum contrast range can be set to [5, 128], and the minimum and maximum grayscale ranges can be set to [0, 255]. That is, after distributing the target number of particles within the parameter range, the mean filtering in the calibration position parameters of each particle is within the range of [1, 99], the minimum contrast in the calibration position parameters of each particle is within the range of [5, 128], and the minimum and maximum grayscale in the calibration position parameters of each particle are within the range of [0, 255]. Among these, the maximum grayscale value is greater than or equal to the minimum grayscale value.
[0083] In one embodiment, before the local optimal parameter screening step, the parameter optimization method further includes: an algebraic judgment step, which determines whether the algebra of the particle swarm is the first generation. If so, the calibration position parameter of each particle in the current generation of the particle swarm is determined as the local optimal position parameter of each particle, and the process proceeds to the global optimal parameter acquisition step; otherwise, the local optimal parameter screening step is executed.
[0084] When the particle swarm is distributed within the optimized range of the detection parameters, the particles are assigned initial position parameters. At this point, each initial position parameter of the particle swarm is a calibration position parameter. Since this particle swarm is a first-generation swarm and has not yet undergone iteration, the calibration position parameters of the particles are being scored for the first time, and each particle has only one position parameter score. Therefore, the local optimal parameter selection step is not applicable to the first-generation particle swarm. Thus, this embodiment also includes an algebraic judgment step. When it is determined that the particle swarm is of the first generation, the calibration position parameters of each particle in the current generation are directly determined as the local optimal parameters of each particle. That is, the initial position parameters of each particle are directly determined as the local optimal parameters of each particle, without needing to use position parameter scoring to select the local optimal position parameters. Therefore, after the algebraic judgment step, the local optimal parameter selection step is not required, and the process proceeds directly to the global optimal parameter selection step. When it is determined that the particle's algebra is not the first generation, it indicates that the particle swarm has undergone iteration, and the calibration position parameters of the particles are not being scored for the first time, meaning the particles have at least two position parameter scores. In this case, the local optimal parameter selection step must be performed first, followed by the global optimal parameter selection step.
[0085] In some specific embodiments, the local optimal position parameters for each particle in the current generation are selected using the position parameter score of each particle in the current generation and the position parameter scores of the previous several generations, specifically as follows:
[0086] Determine whether the position parameter score of the current generation of the particle is greater than that of the previous generation. If so, determine the calibration position parameter of the current generation of the particle as the local optimal position parameter of the current generation of the particle. If not, determine the calibration position parameter of the previous generation of the particle as the local optimal position parameter of the current generation of the particle.
[0087] That is, each time a particle is scored, it will have a new position parameter score. Before and after the iteration, the position parameter with the larger position parameter score is recorded as the local optimal position parameter. In this way, each iteration only needs to compare with the position parameter score of the previous generation, that is, only one comparison is needed.
[0088] In one embodiment, the step of annotating the region to be detected in the template image to obtain the annotated region includes:
[0089] The region to be detected in the template image is outlined to obtain the first labeled region;
[0090] The region to be detected in the template image is expanded and labeled to obtain a second labeled region, and the second labeled region covers the first labeled region.
[0091] In the particle swarm optimization process, the verification region obtained by calculating the detection parameters using the particle's calibration position parameters will exceed the actual area of the area to be detected. Based on this, this embodiment further limits the annotation region, setting the annotation region as a first annotation region and a second annotation region. The first annotation region is obtained by contour annotation of the area to be detected in the template image, that is, the first annotation region is the actual area of the area to be detected. The second annotation region is obtained by expanding the annotation of the area to be detected in the template image. Therefore, when using the annotation region and the verification region to score the particle's calibration position parameters, the first annotation region, the second annotation region, and the verification region are used to score the particle's calibration position parameters, which can improve the accuracy of the position parameter scoring.
[0092] In some specific embodiments, the width of the second annotation area is three times that of the first annotation area.
[0093] The following example illustrates how to expand the markings of the area to be inspected when the area to be inspected is a solder joint:
[0094] Draw frames around the two solder joints located at both ends of the solder wire to obtain the first frame area and the second frame area.
[0095] The centers of the first bounding region and the second bounding region are extracted to obtain the first center point and the second center point;
[0096] Connecting the first center point and the second center point yields the wire bonding skeleton;
[0097] Set the inflection point at the center of each bend in the welding wire;
[0098] The wire bonding skeleton is bent at the inflection point to obtain the bent wire bonding skeleton.
[0099] The centers of the two solder joints located at both ends of the solder wire are extracted to obtain the center of the first solder joint and the center of the second solder joint.
[0100] Calculate the offset of the first center point relative to the center of the first solder joint and the offset of the second center point relative to the center of the second solder joint, respectively, to obtain the first offset and the second offset;
[0101] The two ends of the wire bonding skeleton after the bend are offset by a first offset and a second offset to obtain the offset wire bonding skeleton.
[0102] Fill the vertical sides of the offset wire skeleton with a preset width value to obtain the second annotation area.
[0103] In some specific embodiments, the preset width value can be set according to the allowable wire bonding error; it can also be set according to the width ratio of the second marking area to the first marking area.
[0104] In one embodiment, the parameter scoring step includes:
[0105] The overlapping area between the verification area and the first annotation area is set as the first result area;
[0106] Subtract the first labeled area from the second labeled area to obtain the second result area;
[0107] The overlapping area between the verification area and the second result area is set as the third result area;
[0108] Calculate the ratio of the first result area to the first labeled area to obtain the first ratio;
[0109] Calculate the ratio of the third result region to the second result region to obtain the second ratio;
[0110] Calculate the ratio of the first ratio to the second ratio to obtain a third ratio, and set the third ratio as the parameter score.
[0111] Specifically, if we set the first annotation area as R1, the first result area as R2, the second result area as R3, the third result area as R4, and the parameter score as GoodScore, then the formula for calculating the parameter score is:
[0112]
[0113] By substituting R1, R2, R3, and R4 into the parameter scoring formula, the position parameter score of the corresponding particle can be calculated.
[0114] In one embodiment, the iterative position parameter acquisition step includes:
[0115] Construct the iterative formula for the parameter changes in the particle swarm optimization algorithm;
[0116] V ij (t+1) =ωV ij (t) +c1r1(P ij (t) -X ij (t) )+c2r2(P tj(t) -X ij (t) );
[0117] Constructing the position parameter iteration formula for the particle swarm algorithm:
[0118] X ij (t+1) =X ij (t) +V ij (t+1) ;
[0119] The parameter change value is obtained by calculating the iterative formula using the local optimal position parameters of each particle in the current generation and the global optimal position parameters of the current particle swarm.
[0120] The iterative formula for calculating the position using the parameter change values yields the iterative position parameters;
[0121] Where c1 is the individual learning factor of the particle, c2 is the group learning factor of the particles; t is the current iteration number; r1 and r2 are independent random numbers in the interval [0, 1]; ω is the particle's inertia coefficient; V ij (t) V represents the change in the position parameter of particle i in the t-th iteration; ij (t+1) P represents the change in the position parameter of particle i at position j during the (t+1)th iteration; ij (t) Let J be the local optimal position parameter of particle i in the t-th iteration; P tj (t) Let X be the globally optimal position parameter of the particle swarm in the t-th iteration; ij (t) Let X be the calibration position parameter of particle i in the t-th iteration; ij (t+1) Let j be the calibration position parameter of particle i in the t-th iteration.
[0122] The parameter change value refers to the change between the calibration position parameters of particles in the current particle swarm and the standard position parameters of particles in the next generation particle swarm. That is, the parameter change value is first calculated by using the local optimal position parameters and the global optimal position parameters to obtain the parameter change value of the particles. Then, the parameter change value is used to calculate the position parameter iterative formula to obtain the iterative position parameters of the particles, which are the calibration position parameters of the next generation of particles.
[0123] In some specific embodiments, c1 takes the value of 1 and c2 takes the value of 1, which can be understood as the particle's self-cognition and social cognition being equal.
[0124] In one embodiment, before constructing the iterative formula for the parameter change values of the particle swarm optimization algorithm, the step of obtaining the iterative position parameters further includes:
[0125] The inertia coefficient iterative formula for the particle swarm optimization algorithm is as follows:
[0126] ω=ω max -(ω max -ω min )t / t max ;
[0127] Where, ω max ω is the maximum inertia coefficient of the particle. min t is the minimum inertia coefficient of the particle. max This is the threshold for the number of iterations.
[0128] During the iteration process of a particle, its inertia changes. Therefore, before using the iterative formula to calculate the parameter changes using local and global optimal position parameters, it is necessary to update the particle's inertia coefficient, specifically the maximum inertia coefficient ω. max Minimum inertia coefficient ω min Iteration number threshold t max Since it is pre-set, the inertia coefficient of the particle can be obtained by using the iterative formula for calculating the inertia coefficient using the current iteration number t of the particle.
[0129] In some specific embodiments, ω max The value of ω is 0.5; min The value is 0.3.
[0130] In some specific embodiments, t max The value of is 50, meaning that when the number of iterations reaches 50, the globally optimal position parameter selected in the current iteration is determined as the optimal parameter of the detection algorithm.
[0131] In one embodiment, before calculating the iterative position parameter using the parameter change value to obtain the iterative position parameter, the iterative position parameter acquisition step further includes:
[0132] Determine whether the parameter change value of the particle is less than the preset lower limit value. If so, update the parameter change value of the particle to the lower limit value. If not, determine whether the parameter change value is greater than the preset upper limit value. If so, update the parameter change value of the particle to the upper limit value.
[0133] This embodiment sets lower and upper limits for parameter changes, which essentially sets upper and lower limits for particle movement. When a particle moves too fast, it indicates that the particle's previous calibration position parameter may be greater than the optimal parameter to be solved (the number of iterations reaches a preset threshold, and the global optimal position parameter of the particle swarm is the optimal parameter), while the current calibration position parameter is less than the optimal parameter. When a particle moves too slowly, it indicates that the particle's iteration search is too slow. Therefore, by setting lower and upper limits for parameter changes, when the parameter change is less than the lower limit, the particle's parameter change is updated to the lower limit; when the parameter change is greater than the upper limit, the particle's parameter change is updated to the upper limit. If the parameter change is neither less than the lower limit nor greater than the upper limit, it means that the parameter change meets the range limit, and the parameter change can be directly used to calculate the parameter iteration formula. This controls the magnitude of the parameter change, which helps improve the accuracy of optimization.
[0134] In some specific embodiments, the lower limit of change is set to Vmin, and the upper limit of change is set to Vmax. When Vmin is -2 and Vmax is 2, the magnitude of the parameter change value is limited to the range of [-2, 2]. When the parameter change value of the particle is less than -2, the parameter change value of the particle is updated to -2; when the parameter change value of the particle is greater than 2, the parameter change value of the particle is updated to 2.
[0135] In one embodiment, before calculating the iterative position parameter using the parameter change value to obtain the iterative position parameter, the iterative position parameter acquisition step further includes:
[0136] Determine whether the parameter change value of the particle is less than the preset lower limit value. If so, update the parameter change value of the particle to the lower limit value. If not, determine whether the parameter change value is greater than the preset upper limit value. If so, update the parameter change value of the particle to the upper limit value.
[0137] As mentioned above, the range of detection parameters for the detection algorithm is determined before particle distribution, including the upper and lower limits of the detection parameters. Since the particles are distributed within the range of the detection parameters, the lower limit of the detection parameters is the lower limit of the particle position parameters, and the upper limit of the detection parameters is the upper limit of the particle position parameters. In this embodiment, after calculating the iterative position parameters of the particles, the lower and upper limits are used to determine the magnitude of the iterative position parameters, which in turn determines the distribution range of the particles after the next iteration. When the iterative position parameters are less than the lower limit or greater than the upper limit, it indicates that the iterative distribution of the particles has exceeded the range. Increasing the distribution range of the particles will require increasing the number of iterations or the number of particles; otherwise, the obtained optimal value may not be the true optimal value. However, increasing the number of iterations or the number of particles will increase the computational load, directly increasing the time for finding the optimal value. Therefore, this embodiment controls the magnitude of the iterative position parameters to improve the optimization speed.
[0138] In one embodiment, the verification region extraction step includes:
[0139] The template image is dynamically thresholded using the calibration position parameters of each particle to obtain the first extraction region;
[0140] Static thresholding is performed on the template image using the calibration position parameters of each particle to obtain the second extraction region;
[0141] The first extracted region and the second extracted region are merged to obtain the merged region;
[0142] The merged region is subjected to a closing operation to obtain the verification region.
[0143] In this embodiment, when the number of regions to be detected exceeds a preset number, the entire template image is processed directly, avoiding slow image processing speed caused by cyclically processing a single region to be detected. Specifically, dynamic threshold extraction and static threshold extraction are performed on the template image using calibration position parameters to obtain a first extraction region and a second extraction region. The first extraction region obtained by dynamic threshold extraction is closer to the edge of the region to be detected, while the second extraction region obtained by static threshold extraction is closer to the center of the region to be detected. Therefore, the first extraction region and the second extraction region need to be merged to obtain a merged region. Then, a closing operation is performed on the merged region to fill in the regions belonging to the region to be detected that were not extracted, thus obtaining the verification region.
[0144] If the area to be detected is a weld line, the detection parameters of the weld line detection algorithm include mean filtering, minimum contrast, minimum gray level, maximum gray level, etc. Therefore, mean filtering and minimum contrast are used to achieve dynamic threshold extraction of the template image, and minimum gray level and maximum gray level are used to achieve static threshold extraction of the template image.
[0145] In some specific embodiments, the calibration position parameters of each particle are used to perform dynamic threshold extraction on the region to be detected in the template image to obtain the first extraction region;
[0146] Static threshold extraction is performed on the region to be detected in the template image using the calibration position parameters of each particle to obtain the second extraction region;
[0147] The first extracted region and the second extracted region are merged to obtain the merged region;
[0148] The merged region is subjected to a closing operation to obtain the verification region.
[0149] In this embodiment, when the number of regions to be detected is less than a preset number, the verification region can be extracted directly from the regions to be detected in the template image instead of processing the entire image, thereby improving the extraction speed of the verification region. That is, dynamic threshold extraction and static threshold extraction are performed directly on a single region to be detected, and then merging and closing operations are performed to obtain the verification region of the region to be detected; then the next region to be detected is processed in a loop.
[0150] In some specific embodiments, the closing operation on the intersection region is performed as follows: first, the intersection region is expanded using a circular structuring element with a radius of 3, thereby connecting the regions adjacent to the intersection region with the intersection region, thus changing the edge of the intersection region; then, the expanded intersection region is eroded using a circular structuring element with a radius of 3 to obtain the verification region.
[0151] In some specific embodiments, before performing a closing operation on the merged region to obtain the verification region, the verification region extraction step further includes:
[0152] The intersection of the merged region and the second labeled region is performed to obtain the merged region after intersection.
[0153] As mentioned above, the second labeled region covers the first labeled region. Therefore, the intersection of the merged region and the second labeled region is taken to obtain an intersection region. This intersection region is recorded as the merged region after the intersection, thereby removing the regions extracted from the merged region that do not belong to the region to be detected.
[0154] In some specific embodiments, after performing a closing operation on the merged region to obtain the verification region, the verification region extraction step further includes:
[0155] The intersection of the verification region and the second annotation region is performed to obtain the intersection verification region.
[0156] Similarly, the intersection of the verification region and the second annotation region is taken to obtain an intersection region, which is recorded as the verification region after the intersection, thereby removing the regions that do not belong to the region to be detected due to the closing operation.
[0157] Please see Figure 2 The present invention also provides a detection parameter optimization system 100, comprising: a labeling module 10, a particle distribution module 20, a verification region extraction module 30, a parameter scoring module 40, a first screening module 50, a second screening module 60, a first judgment module 70, a first iteration module 80, and a second iteration module 90.
[0158] The annotation module 10 is used to annotate the region to be detected in the template image to obtain the annotated region; the particle distribution module 20 is used to construct the detection algorithm for the region to be detected, determine the optimization range of the detection parameters of the detection algorithm, and distribute the target number of particles in the particle swarm within the optimization range of the detection parameters; the verification region extraction module 30 is used to calculate the verification region of the region to be detected by the detection algorithm using the calibration position parameters of each particle in the current particle swarm; the parameter scoring module 40 is used to score the calibration position parameters of each particle using the verification region of each particle in the current particle swarm and the annotated region to obtain the position parameter score of each particle; the first filtering module 50 is used to use the position parameter score of each particle in the current generation and the position parameter scores of the previous several generations. The first filtering module 60 selects the local optimal position parameters for each particle in the current generation; the second filtering module 60 uses the position parameter scores of all particles in the particle swarm to select an optimal local optimal position parameter as the global optimal position parameter of the current generation particle swarm; the first judgment module 70 determines whether the number of iterations has reached a preset iteration threshold. If so, the global optimal position parameter is determined as the optimal parameter of the detection algorithm; otherwise, it proceeds to the first iteration module; the first iteration module 80 uses the particle swarm algorithm, the global optimal position parameter of the current generation particle swarm, and the local optimal position parameters of each particle in the current generation to iterate the iterative position parameters of each particle in the next generation particle swarm; the second iteration module 90 uses the iterative position parameters to iterate the calibration position parameters in the verification region extraction step.
[0159] In one embodiment, the system further includes a second judgment module, which is used to determine whether the generation of the particle swarm is the first generation. If so, the calibration position parameters of each particle in the current generation of the particle swarm are determined as the local optimal position parameters of each particle, and the process proceeds to the global optimal parameter acquisition step. If not, the local optimal parameter filtering step is executed.
[0160] In some specific embodiments, the annotation module includes a first annotation unit and a second annotation unit. The first annotation unit is used to perform contour annotation on the region to be detected in the template image to obtain a first annotation region. The second annotation unit is used to expand the annotation on the region to be detected in the template image to obtain a second annotation region, and the second annotation region covers the first annotation region.
[0161] In some specific embodiments, the parameter scoring module includes a first region acquisition unit, a second region acquisition unit, a third region acquisition unit, a first ratio unit, a second ratio unit, and a third ratio unit. The first region acquisition unit is used to set the overlapping area of the verification region and the first annotation region as a first result region; the second region acquisition unit is used to subtract the first annotation region from the second annotation region to obtain a second result region; the third region acquisition unit is used to set the overlapping area of the verification region and the second result region as a third result region; the first ratio unit is used to calculate the ratio of the first result region to the first annotation region to obtain a first ratio; the second ratio unit is used to calculate the ratio of the second result region to the second annotation region to obtain a second ratio; and the third ratio unit is used to calculate the ratio of the first ratio to the second ratio to obtain a third ratio, and set the third ratio as the parameter score.
[0162] Please see Figure 3 The present invention also provides an electronic device, which further includes: a memory 601, a processor 602, and a computer program stored in the memory 601 and executable on the processor 602. When the processor 602 executes the computer program, it implements the parameter optimization method described in the foregoing embodiments.
[0163] Furthermore, the electronic device also includes at least one input device 603 and at least one output device 604.
[0164] The aforementioned memory 601, processor 602, input device 603, and output device 604 are connected via bus 605.
[0165] The input device 603 can specifically be a camera, touch panel, physical buttons, or mouse, etc. The output device 604 can specifically be a display screen.
[0166] The memory 601 can be a high-speed random access memory (RAM) or a non-volatile memory, such as a disk storage device. The memory 601 is used to store a set of executable program code, and the processor 602 is coupled to the memory 601.
[0167] Furthermore, this application embodiment also provides a computer-readable storage medium, which may be disposed in the electronic device of the above embodiments, and the computer-readable storage medium may be the aforementioned memory 601. The computer-readable storage medium stores a computer program, which, when executed by the processor 602, implements the parameter optimization method described in the foregoing embodiments.
[0168] Furthermore, the storage medium of the computer can also be a USB flash drive, a portable hard drive, a read-only memory (ROM), RAM, a magnetic disk, or an optical disk, or any other medium that can store program code.
[0169] In the several embodiments provided in this application, it should be understood that the disclosed apparatus and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of modules is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple modules or components may be combined or integrated into another electronic device, or some features may be ignored or not executed. Furthermore, the mutual coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between devices or modules may be electrical, mechanical, or other forms.
[0170] The modules described as separate components may or may not be physically separate. The components shown as modules may or may not be physical modules; that is, they may be located in one place or distributed across multiple network modules. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs.
[0171] Furthermore, the functional modules in the various embodiments of the present invention can be integrated into one processing module, or each module can exist physically separately, or two or more modules can be integrated into one module. The integrated modules described above can be implemented in hardware or as software functional modules.
[0172] If the integrated module is implemented as a software functional module 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.
[0173] It should be noted that, for the sake of simplicity, the foregoing method embodiments are all described as a series of actions. However, those skilled in the art should understand that the present invention is not limited to the described order of actions, because according to the present invention, some steps can be performed in other orders or simultaneously. Furthermore, those skilled in the art should also understand that the embodiments described in the specification are preferred embodiments, and the actions and modules involved are not necessarily essential to the present invention.
[0174] In the above embodiments, the descriptions of each embodiment have different focuses. For parts not described in detail in a certain embodiment, please refer to the relevant descriptions of other embodiments.
[0175] The above is a description of a parameter optimization method, a material distribution device, a material distribution equipment, and a computer-readable storage medium provided by the present invention. For those skilled in the art, based on the ideas of the embodiments of the present invention, there will be changes in the specific implementation methods and application scope. Therefore, the content of this specification should not be construed as a limitation of the present invention.
Claims
1. A parameter optimization method, characterized in that, include: The regions to be detected in the template image are labeled to obtain the labeled regions; The process of annotating the regions to be detected in the template image to obtain the annotated regions includes: The region to be detected in the template image is outlined to obtain the first labeled region; The region to be detected in the template image is enlarged and labeled to obtain a second labeled region, and the second labeled region covers the first labeled region; Determine the optimization range of the detection parameters of the detection algorithm for the pre-constructed detection region, and distribute the target number of particles in the particle swarm within the optimization range of the detection parameters; The verification region extraction step involves calculating the verification region of the area to be detected using the calibration position parameters of each particle in the current particle swarm. The parameter scoring step involves scoring the calibration position parameters of each particle using the verification region and the labeled region of each particle in the current particle swarm, respectively, to obtain the position parameter score of each particle. The parameter scoring steps include: The overlapping area between the verification area and the first annotation area is set as the first result area; Subtract the first labeled area from the second labeled area to obtain the second result area; The overlapping area between the verification area and the second result area is set as the third result area; Calculate the ratio of the first result area to the first labeled area to obtain the first ratio; Calculate the ratio of the third result region to the second result region to obtain the second ratio; Calculate the ratio of the first ratio to the second ratio to obtain a third ratio, and set the third ratio as the parameter score; The local optimal parameter screening step uses the current position parameter score and the position parameter scores of previous generations for each particle to screen out the local optimal position parameters for each particle in the current generation. The global optimal parameter selection step uses the position parameter scores of all particles in the particle swarm to select the optimal local optimal position parameter as the global optimal position parameter of the current particle swarm. The iteration count determination step determines whether the iteration count has reached the preset iteration count threshold. If so, the globally optimal position parameter is determined as the optimal parameter of the detection algorithm. If not, the process proceeds to the iteration position parameter acquisition step. The iterative position parameter acquisition step uses the particle swarm optimization algorithm, the global optimal position parameters of the current particle swarm, and the local optimal position parameters of each particle in the current swarm to iterate and obtain the iterative position parameters of each particle in the next generation particle swarm. The location parameter iteration step involves iterating the calibration location parameters in the verification region extraction step using iterative location parameters, and then sequentially executing the verification region extraction step, the parameter scoring step, the local optimal parameter filtering step, the global optimal parameter filtering step, and the iteration count determination step.
2. The parameter optimization method according to claim 1, characterized in that, Prior to the local optimum parameter selection step, the parameter optimization method further includes: The algebraic judgment step determines whether the particle swarm is in the first generation. If so, the calibration position parameters of each particle in the current generation of the particle swarm are determined as the local optimal position parameters of each particle, and the process proceeds to the global optimal parameter acquisition step. If not, the local optimal parameter filtering step is executed.
3. The parameter optimization method according to claim 1, characterized in that, The iterative position parameter acquisition step includes: The inertia coefficient iterative formula for the particle swarm optimization algorithm is as follows: ω=ω max -(oh max -oh min )t / t max ; Construct the iterative formula for the parameter changes in the particle swarm optimization algorithm; V ij (t+1) =ωV ij (t) +c1 r1(P ij (t) -X ij (t) )+c2 r2(P tj (t) -X ij (t) ); Constructing the position parameter iteration formula for the particle swarm algorithm: X ij (t+1) =X ij (t) +V ij (t+1) ; The parameter change value is obtained by calculating the iterative formula using the local optimal position parameters of each particle in the current generation and the global optimal position parameters of the current particle swarm. The iterative formula for the position parameters is calculated using the parameter change values to obtain the iterative position parameters; Where, ω max ω is the maximum inertia coefficient of the particle. min t is the minimum inertia coefficient of the particle. max Where c1 is the individual learning factor of the particle and c2 is the collective learning factor of the particle; t is the current iteration number; r1 and r2 are independent random numbers in the interval [0, 1]; ω is the particle's inertia coefficient; V ij (t) V represents the change in the position parameter of particle i in the t-th iteration; ij (t+1) P represents the change in the position parameter of particle i at position j during the (t+1)th iteration; ij (t) Let J be the local optimal position parameter of particle i in the t-th iteration; P tj (t) Let X be the globally optimal position parameter of the particle swarm in the t-th iteration; ij (t) Let X be the calibration position parameter of particle i in the t-th iteration; ij (t+1) Let j be the calibration position parameter of particle i in the t-th iteration.
4. The parameter optimization method according to claim 3, characterized in that, Before obtaining the iterative position parameters by calculating the position using the parameter change values using the iterative formula, the step of obtaining the iterative position parameters further includes: Determine whether the parameter change value of the particle is less than the preset lower limit value. If so, update the parameter change value of the particle to the lower limit value. If not, determine whether the parameter change value is greater than the preset upper limit value. If so, update the parameter change value of the particle to the upper limit value. After obtaining the iterative position parameters by calculating the position using the parameter change values using the iterative formula, the step of obtaining the iterative position parameters further includes: If the iterative position parameter is less than a preset lower limit, the particle's iterative position parameter is updated to the lower limit. If not, the particle's iterative position parameter is updated to the upper limit.
5. The parameter optimization method according to claim 1, characterized in that, The verification region extraction step includes: The first extraction region is obtained by dynamically thresholding the region to be detected in the template image using the calibration position parameters of each particle. Static thresholding is performed on the region to be detected in the template image using the calibration position parameters of each particle to obtain the second extraction region; The first extracted region and the second extracted region are merged to obtain the merged region; The intersection of the merged region and the second labeled region is performed to obtain the merged region after intersection. The merged region after the intersection is subjected to a closing operation to obtain the verification region; The intersection of the verification region and the second annotation region is performed to obtain the intersection verification region.
6. A detection parameter optimization system, characterized in that, include: The annotation module is used to annotate the regions to be detected in the template image to obtain the annotated regions; The process of annotating the regions to be detected in the template image to obtain the annotated regions includes: The region to be detected in the template image is outlined to obtain the first labeled region; The region to be detected in the template image is enlarged and labeled to obtain a second labeled region, and the second labeled region covers the first labeled region; The particle distribution module determines the optimization range of the detection parameters of the detection algorithm for the pre-built detection area to be detected, and distributes the target number of particles in the particle swarm within the optimization range of the detection parameters. The verification region extraction module is used to calculate the verification region of the region to be detected by the detection algorithm using the calibration position parameters of each particle in the current particle swarm. The parameter scoring module is used to score the calibration position parameters of each particle using the verification region and the annotation region of each particle in the current particle swarm, respectively, to obtain the position parameter score of each particle. The parameter scoring module includes: The overlapping area between the verification area and the first annotation area is set as the first result area; Subtract the first labeled area from the second labeled area to obtain the second result area; The overlapping area between the verification area and the second result area is set as the third result area; Calculate the ratio of the first result area to the first labeled area to obtain the first ratio; Calculate the ratio of the third result region to the second result region to obtain the second ratio; Calculate the ratio of the first ratio to the second ratio to obtain a third ratio, and set the third ratio as the parameter score; The first filtering module is used to filter out the local optimal position parameters of each particle in the current generation by using the position parameter score of each particle in the current generation and the position parameter scores of the previous several generations. The second filtering module is used to filter out an optimal local optimal position parameter as the global optimal position parameter of the current particle swarm using the position parameter scores of all particles in the particle swarm. The first judgment module is used to determine whether the number of iterations has reached a preset iteration threshold. If so, the globally optimal position parameter is determined as the optimal parameter of the detection algorithm; otherwise, the process is transferred to the first iteration module. The first iteration module is used to iterate the iterative position parameters of each particle in the next generation of particle swarm using the particle swarm algorithm, the global optimal position parameters of the current particle swarm, and the local optimal position parameters of each particle in the current generation. The second iteration module is used to iterate the calibration position parameters in the verification region extraction step using the iteration position parameters.
7. An electronic device comprising: A memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, when the processor executes the computer program, it implements the parameter optimization method according to any one of claims 1-5.
8. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, it implements the parameter optimization method according to any one of claims 1-5.
Citation Information
Patent Citations
Multi-objective particle swarm parameter optimization method based on graph segmentation process
CN104021552A
Self-adaptive gray-scale image enhancement system
CN107274356A