Irregular cable insulation thickness detection method based on adaptive local alternation genetic algorithm, storage medium and electronic device

The adaptive local alternation genetic algorithm for detecting cable insulation thickness solves the problems of low efficiency and poor accuracy in detecting irregular cables, achieving fast and accurate thickness measurement, and is suitable for industrial inspection of irregular cables.

CN117218373BActive Publication Date: 2026-04-14GUANGDONG UNIV OF TECH
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
GUANGDONG UNIV OF TECH
Filing Date
2023-10-07
Publication Date
2026-04-14

AI Technical Summary

Technical Problem

Existing methods suffer from low efficiency and poor accuracy when detecting the insulation thickness of irregular cables, especially in large solution spaces where it is difficult to quickly and accurately obtain multiple thickness values, which cannot meet the industrial needs of large-volume tasks.

Method used

An adaptive local alternation genetic algorithm is adopted. By acquiring cross-sectional images of cables, extracting inner and outer edge information, calculating curvature features, randomly selecting pixels, generating an initial population, and searching for the location of minimum insulation thickness using the adaptive local alternation genetic algorithm, combined with Gray code encoding and adaptive crossover mutation to accelerate convergence.

Benefits of technology

It expands the scope of application, significantly improves the detection speed and accuracy, and can quickly and accurately obtain the thinnest thickness of cables to meet industrial testing needs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117218373B_ABST
    Figure CN117218373B_ABST
Patent Text Reader

Abstract

The present application relates to a kind of irregular cable insulation thickness detection method based on adaptive local alternative genetic algorithm, electronic equipment, computer readable storage medium. Among them, the method is first according to the curvature characteristics of test piece section, enough sample points are randomly selected in inner and outer edges, the minimum insulation thickness position is searched by using improved genetic algorithm alternately in inner and outer edges, then the inner and outer edge sample points near the current minimum insulation thickness position are removed in a certain proportion in combination with section characteristics, in turn, the remaining sample points are taken as research object, so repeated iteration is carried out, and the insulation thickness value of the same way is obtained.The large number of comparative experiments fully confirm that ALA-GA can greatly shorten the detection time in irregular cable insulation thickness detection and has the highest data accuracy, therefore, the present application has higher application value and economic benefits in the field of cable insulation thickness detection.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention addresses the problems of low efficiency and poor accuracy in traditional methods for measuring cable insulation thickness. It proposes a method, electronic device, and computer-readable storage medium for detecting the insulation thickness of irregular cables based on an Adaptive Locally-Alternate Genetic Algorithm (ALA-GA). Background Technology

[0002] Cables, including electrical cables and optical fibers, are fundamental materials essential for the normal operation of society and the economy, making their quality paramount. Cable products consist of two main components: conductor and insulation. my country's current cable product standard, GB / T5023.3-2008, imposes extremely strict regulations on the average and minimum insulation thickness. However, insulation thickness often falls short of national standards. Currently, the national standard's testing technology remains at the traditional level, combining optical magnifying projectors or reading microscopes with manual measurement. This method is cumbersome, difficult to read, and suffers from poor repeatability and reproducibility, resulting in inaccurate quality control. Insulation thickness testing is a crucial test item, directly related to the cable's withstand voltage test, insulation resistance, and various mechanical properties (tensile strength, elongation at break, etc.). Uneven insulation thickness or a minimum thickness less than the standard value can shorten the cable's lifespan, leading to breakdown during use, leakage, short circuits, damage to electrical equipment, and even fires.

[0003] In recent years, with the rapid development of machine vision technology, some scholars have proposed to use machine vision technology to automatically measure the insulation thickness of cables. For example, Xie Lijie et al. proposed an algorithm in "Design and Implementation of Cable Insulation Sheath Thickness Measurement System Based on Matlab [J]. Quality and Technical Supervision Research, 2015, 39(3): 182-184", which extracts the edge brute force traversal after processing the cable cross-section image to obtain the minimum insulation value, and then takes a minimum value every 60±5° as the thickness measurement value. Wang Aijun et al. proposed an automatic measurement method for the cross-sectional geometric dimensions of cable based on the tangent method to locate the center of the circle in "Design and Implementation of Automatic Measurement Method for Cable Cross-section Geometric Dimensions Based on Tangent Method to Locate the Center of the Circle [J]. Journal of Zhengzhou University (Science Edition), 2018, 50(2): 111-115", which uses the parallel tangent method to determine the geometric center of the cable and measures the insulation thickness by ray through the geometric center. Wang et al., in "Measurement of cable thickness based on sub-pixel image processing [C] / / IEEE 2011 10th International Conference on Electronic Measurement & Instruments.IEEE,2011,3:38-41", proposed using principal axis analysis, multi-scale gradient algorithm, and universal sub-pixel relocation to more accurately annotate the object surface to locate the object edge, thereby calculating the insulation thickness. Huang et al., in "A cable sheath material thickness measurement method based on image measurement technology [C] / / Applied Mechanics and Materials. Trans Tech Publications Ltd,2012,182:477-481", improved the interpolation method, significantly increasing the speed of edge information extraction while maintaining computational accuracy. They applied this method to a cable material thickness image measurement system, achieving accurate and rapid measurement.

[0004] While existing methods have yielded relevant results in the field of cable insulation thickness testing, they are only applicable to specimens with approximately circular cross-sections. However, cable products are diverse, and for specimens with irregular cross-sections, the extension line of the thickness measurement location typically does not pass through the centroid (center of the circle). Therefore, besides brute-force calculations that can accurately obtain the minimum insulation value, the accuracy of the other five insulation thickness values ​​cannot be guaranteed. Furthermore, for cable cross-section images captured by typical industrial cameras, the solution space for extracted edge information is quite large. For example, a typical 6-megapixel industrial camera can capture over 20,000 pixels on the outer edge and over 15,000 pixels on the inner edge of a 2.5mm diameter cable cross-section, resulting in a solution space of up to 3 × 10⁻⁶ pixels. 9 Therefore, existing methods suffer from excessive time complexity and poor accuracy, failing to meet the industrial requirements for rapid and accurate detection in scenarios involving large-scale tasks.

[0005] The problem of finding the insulation thickness of irregular cables is essentially an optimization problem with a large solution space. Methods for solving optimization problems can generally be summarized into three types: enumeration, heuristic algorithms, and search algorithms. Enumeration methods are inefficient when the solution space is large; heuristic algorithms have poor versatility and require specific heuristic rules for different cables; while search algorithms, combined with some heuristic knowledge, can achieve a good balance between solution quality and efficiency. Genetic Algorithm (GA) is a global optimization probabilistic search algorithm that uses the principle of "survival of the fittest" to simulate the evolutionary rules of natural selection to find the optimal solution. The main operations of a genetic algorithm include encoding, selection, crossover, and mutation. Its main characteristic is the ability to use information from multiple search points for probabilistic searching. Although this probabilistic characteristic may result in some individuals with low fitness, as the evolutionary process progresses, it always tends to produce more superior individuals. Both practice and theory have proven that under certain conditions, genetic algorithms always converge to the optimal solution with probability 1, and their results are superior to other optimization methods.

[0006] Therefore, to address the above problems, this paper proposes a cable insulation thickness detection method based on a genetic algorithm, and improves the traditional genetic algorithm by combining the characteristics of cable insulation thickness to improve detection efficiency. Summary of the Invention

[0007] To address or partially address the shortcomings of existing technologies, this invention provides a method for detecting the insulation thickness of irregular cables based on an adaptive local alternation genetic algorithm, an electronic device, and a computer-readable storage medium.

[0008] To address this, a method for detecting the insulation thickness of irregular cables based on an adaptive local alternation genetic algorithm is provided, comprising the following steps performed sequentially:

[0009] Step S1: Acquire cross-sectional images of the specimen and extract its inner and outer edge information;

[0010] Step S2: Calculate the curvature features of the cross section, and randomly select pixels at the inner and outer edges based on the curvature features;

[0011] Step S3: Iterate through and calculate the distance between the inner and outer edge pixels, take the minimum value as the individual detection position, and generate the initial detection position population;

[0012] Step S4: Determine whether the current population has reached the termination iteration condition. If the termination iteration condition is reached, output the optimal detection position and proceed to step S7; otherwise, proceed to step S5. The termination iteration condition is configured as the number of iterations reaching a given allowable value or converging to the global optimal solution.

[0013] Step S5: Perform an adaptive local alternation genetic algorithm on the inner and outer edges of the detection position population to search for the position with the minimum insulation thickness and generate a new detection position population;

[0014] Step S6: Select the new and old detection location populations and update the detection location populations, then proceed to step S4;

[0015] Step S7: If the number of detected positions reaches the set number, the algorithm ends; otherwise, proceed to step S8.

[0016] Step S8: Remove a set percentage of pixels from the current inner and outer edges, then proceed to step S2.

[0017] This invention proposes a method based on a genetic algorithm to alternately search the inner and outer edges of a cable cross-section to detect the thinnest thickness of the cable. This method overcomes the limitations of previous machine vision measurement methods, which could only handle simple cable cross-section structures. It expands the scope of application, greatly speeds up the detection process, and achieves high data accuracy.

[0018] A storage medium is also provided, wherein the storage medium stores one or more programs that, when executed by a processor, implement the method described above.

[0019] An electronic device is also provided, wherein the electronic device includes:

[0020] Processor; and,

[0021] A memory is configured to store computer-executable instructions, which, when executed, cause the processor to perform the method described above.

[0022] The description provided is merely an overview of the technical solution of this invention. In order to better understand the technical means of this invention and to implement it in accordance with the contents of the specification, and to make the described and other objects, features and advantages of this invention more apparent and understandable, specific embodiments of this invention are described below. Attached Figure Description

[0023] Various other advantages and benefits will become apparent to those skilled in the art upon reading the following detailed description of preferred embodiments. The accompanying drawings are for illustrative purposes only and are not intended to limit the invention. Furthermore, the same reference numerals denote the same components throughout the drawings.

[0024] In the attached diagram:

[0025] Figure 1 An example diagram of insulation thickness measurement in the national standard (irregular cross-section specimen) is shown;

[0026] Figure 2 The detection process of the present invention is shown;

[0027] Figure 3 An image of the calibrated standard glass plate is shown;

[0028] Figure 4 The original image of the cross-section of the cable insulation sheet is shown;

[0029] Figure 5 The image after edge extraction is shown;

[0030] Figure 6 An image showing the initial population generation is displayed;

[0031] Figure 7 The image shows the result after removing pixels near the current thinnest position according to the removal ratio;

[0032] Figure 8 The insulation thickness test results are shown;

[0033] Figure 9 The graph showing the thinnest insulation thickness using the traditional genetic algorithm is shown.

[0034] Figure 10 The graph shows the thinnest insulation thickness under the improved genetic algorithm;

[0035] Figure 11 A schematic diagram of the electronic device of the present invention is shown;

[0036] Figure 12 A schematic diagram of the structure of the computer-readable storage medium of the present invention is shown. Detailed Implementation

[0037] Exemplary embodiments of the present disclosure will now be described in more detail with reference to the accompanying drawings. While exemplary embodiments of the present disclosure are shown in the drawings, it should be understood that the present disclosure may be implemented in various forms and should not be limited to the embodiments set forth herein. Rather, these embodiments are provided so that this disclosure will be thorough and complete, and will fully convey the scope of the disclosure to those skilled in the art.

[0038] This embodiment is implemented based on an electronic device, such as a computer device. The electronic device includes a memory, a processor, and a computer program stored in the memory and capable of running on the processor. When the processor executes the program, it implements a method for detecting the insulation thickness of irregular cables based on an adaptive local alternation genetic algorithm.

[0039] (I) Mathematical Model of Insulation Thickness

[0040] According to the current national standard GB / T 2951.11-2008 for cable insulation thickness testing, three test specimens are required, with a total of six measurement points per specimen (the set number of test points). In all cases, the first measurement should be taken at the thinnest point of the insulation. For specimens with irregular cross-sections (such as sector conductors or stranded conductors), the six thickness points should be taken as small as possible and distributed as evenly as possible across the entire edge space. Figure 1 As shown.

[0041] 1.1 Constraints

[0042] Cross-sectional images of the specimen were acquired using an industrial camera. Image edge detection technology was used to extract the inner and outer edge information, which consisted of multiple pixels. The inner edge pixel array (hereinafter referred to as the inner edge) is denoted as C. in The outer edge pixel array (hereinafter referred to as the outer edge) is denoted as C. out An insulation thickness measurement location x j,k Composed of one inner edge pixel and one outer edge pixel, it can be represented as:

[0043]

[0044] Among them: I, O k represents the coordinates of the inner and outer edge pixels; n and m are the lengths of the inner and outer edge arrays.

[0045] 1.2 Insulation Thickness Representation

[0046] The insulation thickness at a measurement location is the straight-line distance between the inner and outer edge pixels at that location, which can be expressed as:

[0047]

[0048] Where: ||·|| represents the second norm.

[0049] 1.3 Objective Function

[0050] From equation (1), all insulation thickness measurement locations can be represented as:

[0051] X={x 0,0 x 0,1 , ..., x (n-1),(m-1)} (3)

[0052] All insulation thickness values ​​from equation (3) can be expressed as:

[0053] dst(x)={dst(x 0,0 ), dst(x 0,1 ), ..., dst(x) (n-1),(m-1) (4)

[0054] According to the current national standard GB / T 2951.11-2008, measurements should always begin at the thinnest insulation thickness. The location for measuring the thinnest insulation thickness... It can be represented as:

[0055]

[0056] Therefore, the shortest distance between the inner and outer edges, min(dst(X)), is taken as the objective function.

[0057] (II) Insulation Thickness Detection Method for Irregular Cables Based on Adaptive Local Alternation Genetic Algorithm

[0058] For the task of detecting the insulation thickness of irregular cables, in order for the genetic algorithm to quickly find the global optimum, its genetic method, initial population generation, and genetic operator design must be more consistent with the actual situation of the specimen. Based on the mathematical model in (I), the specific design of the irregular cable insulation thickness detection method based on the adaptive local alternation genetic algorithm in this embodiment is as follows:

[0059] 2.1 Testing Process Design

[0060] Since detecting cable insulation thickness requires traversing both the inner and outer edges of the specimen simultaneously, and the detection position is composed of pixels from both the inner and outer edges, using a genetic algorithm for probabilistic search on both the inner and outer edges simultaneously results in poor local search capabilities, easily missing the global optimum and making it difficult to guarantee the algorithm's convergence speed. Therefore, this invention proposes an adaptive locally alternating genetic algorithm and applies it to cable insulation thickness detection. The overall process is as follows: Figure 2 As shown.

[0061] The specific process is as follows:

[0062] (1) The cross-sectional image of the specimen was acquired by image processing technology, and its inner and outer edge information was extracted;

[0063] (2) Calculate the cross-sectional curvature features using image processing techniques, and randomly select pixels at the inner and outer edges based on the curvature features;

[0064] (3) Traverse and calculate the distance between inner and outer edge pixels, take the minimum value as the individual detection position, and generate the initial detection position population;

[0065] (4) Determine whether the current population has reached the termination iteration condition. If the termination iteration condition is reached (the number of iterations reaches the given allowable value or converges to the global optimal solution), output the optimal detection position and proceed to step (7); otherwise, proceed to step (5).

[0066] (5) Perform a local alternation genetic algorithm on the inner and outer edges of the detection position population to search for the position with the minimum insulation thickness and generate a new detection position population;

[0067] (6) Select the population at the new and old detection locations and update the population at the detection locations, then proceed to step (4);

[0068] (7) If the number of detected positions is 6, the algorithm ends; otherwise, proceed to step (8).

[0069] (8) Remove a certain proportion of pixels from the current inner and outer edges and proceed to step (2).

[0070] 2.2 Improved Local Alternation Genetic Algorithm

[0071] 2.2.1 Encoding Method

[0072] Since the pixels on the inner and outer edges of the cable cross-section correspond one-to-one with array indices and are arranged in the order of their corresponding array indices, the array indices of the pixels can be encoded. Furthermore, because the pixels are continuous, binary encoding would struggle to approximate the optimal solution in local areas; therefore, Gray code encoding is used to encode the array indices of the inner and outer edge pixels. With Gray code encoding, the codes corresponding to two consecutive integers differ by only one bit, effectively enhancing the local search capability of the genetic algorithm, and facilitating the implementation of genetic operations such as crossover and mutation.

[0073] Since the length of the outer edge array is always greater than that of the inner edge, the Gray code encoding bit length is determined based on the outer edge array length, and the pixel indices of the inner and outer edges are encoded separately. For example, if the outer edge length is 935, the encoding bit length is 10 bits, as shown in Table 1.

[0074] Table 1. Encoding of outer edge pixels

[0075]

[0076] If an insulation thickness measurement location is determined by C in The 243rd pixel I 243 and C out The 5th pixel O 457 Composition, of which I 243 =(332,297), O 457 = (347, 380), then the phenotype of the individual at this position can be represented as:

[0077] x 243,457 =(I 243 O 457 )=((332,297),(347,380))

[0078] The encoded genotype is

[0079] 2.2.2 Fitness Function

[0080] Genetic algorithms use the fitness value of each individual in the population for searching. The choice of fitness function directly affects the convergence speed and whether the optimal solution can be found. This paper addresses a minimization problem, and the fitness function can be derived from the objective function:

[0081] f(x j,k )=1 / dst(x j,k (6)

[0082] From equation (6), we can see that the smaller the insulation thickness at a certain detection location, the greater the fitness value of the individual at that location.

[0083] 2.2.3 Generation of the initial population

[0084] Since irregular cable specimens are more likely to achieve thinner insulation thicknesses at locations with greater curvature, to ensure the richness of the initial population's genes, image processing techniques were used to calculate the curvature characteristics of the specimen cross-section. The number of locations with greater curvature on the inner and outer edges was counted, denoted as a and b, respectively. The inner and outer edges were divided into n segments, where:

[0085] n = k × max{a, b} (7)

[0086] Where k is the initial population selection rate, 10≤k≤100.

[0087] Each segment randomly selects an index address, resulting in n C's. in Sample points and C out Sample points, traverse and calculate C in Each sample point and C outThe distance between sample points is taken as the minimum value corresponding to C. out Each sample point forms an individual insulation thickness detection location, and n insulation thickness detection locations can be obtained in this way, which serve as the initial population.

[0088] 2.2.4 Crossover

[0089] In traditional genetic algorithms, crossover is a probabilistic event, resulting in slow search speed. This paper, by applying the selection operation later to the detection population, skips the selection process for the current edge pixel population and directly randomly selects two different individuals for crossover, with a crossover probability of 1.

[0090] Furthermore, due to the use of Gray code encoding, the probability search speed remains relatively slow under low fitness conditions. Therefore, an adaptive crossover method is proposed, where the crossover pattern is determined by Table 2.

[0091] Table 2 Crossover Methods

[0092] fitness conditions Cross method <![CDATA[f≥f avg ]]> Single point intersection <![CDATA[f<f avg ]]> Double intersection

[0093] Among them, f avg denoted as the average fitness of the population, and f is the larger fitness of the two individuals to be crossed.

[0094] 2.2.5 Mutation

[0095] Since the selection operation is applied later to the detection location population, for the current edge pixel population, in order to accelerate the convergence speed, the mutation probability is 1, and an adaptive mutation method is adopted. The mutation method is determined by Table 3:

[0096] Table 3 Variation Modes

[0097] fitness conditions Mutation mode <![CDATA[f′≥f avg ]]> Single point mutation <![CDATA[f′<f avg ]]> Two-point mutation

[0098] Where f′ represents individual fitness.

[0099] 2.2.6 Selection

[0100] After crossover and mutation, n sample points at the current edge are used to generate n new sample points. The distance between the newly generated sample points and the sample points at the other edge is calculated to obtain a new detection location population. The old detection location population and the new location population are sorted in descending order of fitness. Duplicate individuals are removed, and the top n individuals are taken as the detection location population for the next round. This ensures that the attributes of the better individuals are inherited by the next generation population.

[0101] (III) Algorithm Simulation and Result Analysis

[0102] To verify the effectiveness of the proposed improved genetic algorithm in cable insulation thickness detection, this paper implements the proposed improved genetic algorithm using Python 3.9.7 and OpenCV 4.5.5.62, and develops a testing software system using PyQt 55.15.6 to conduct extensive comparative simulations, which fully verify the effectiveness and superiority of the algorithm in cable insulation thickness detection.

[0103] Since the genetic algorithm measures cable insulation thickness in pixels, while the national standard uses millimeters, the machine vision measurement system must be calibrated first. The standard glass plate image for calibration is shown below. Figure 3 As shown, the coordinates of the intersection points of the glass plate lines are obtained by corner point positioning, and the physical distance between adjacent intersection points is 1mm.

[0104] The original image of the cross-section of the cable insulation sheet used in this verification is as follows: Figure 4 As shown.

[0105] First, the original image is converted to grayscale. Then, denoising and thresholding are performed. Finally, edge detection is performed to obtain the image after edge extraction, as shown below. Figure 5 As shown.

[0106] The main parameter settings of the improved local alternation genetic algorithm are shown in Table 4. The number of locations with large curvature on the inner edge of the specimen cross-section is 6, and the number of locations with large curvature on the outer edge is 0, as determined by Equation 7. The initial population size is 30. Based on the cross-sectional curvature characteristics, the inner and outer edges are divided into 30 segments on average, and a pixel is randomly selected from each segment, as shown below. Figure 6 As shown.

[0107] Table 4. Main parameters of the local alternation genetic algorithm

[0108] parameter symbol Value Selection coefficient k 5 Number of iterations iter 50 Crossover probability <![CDATA[P c ]]> 1 Mutation probability <![CDATA[P m ]]> 1 Elimination coefficient α 0.8

[0109] Taking the inner edge as the research object, we traverse and calculate the distance between each point on the inner edge and each point on the outer edge, and take the minimum distance and the corresponding outer edge pixel as an individual in the initial population.

[0110] Pixel index addresses are encoded using Gray code, and the fitness function is the reciprocal of the distance between two points. An improved genetic algorithm is used iteratively to find the thinnest thickness of the current domain, and pixels near the current thinnest thickness position are removed according to a set elimination ratio. Figure 7 As shown, the next thickness position is calculated, and this process continues until the domain is insufficient for further pixel removal. Finally, the insulation thickness data for 6 points is obtained, as shown below. Figure 8 As shown.

[0111] Depend on Figure 9 , Figure 10It is known that traditional genetic algorithms are prone to getting stuck in local optima when searching for the thinnest insulation thickness, while the improved genetic algorithm can converge to the global optimum faster and has good stability.

[0112] The measurement results and performance analysis of the same specimen using different methods are shown in Tables 5 and 6.

[0113] Table 5. Results of 100 measurements of the same specimen using different methods.

[0114]

[0115]

[0116] Table 6 Average Time Cost of Different Methods

[0117]

[0118] As can be seen from Tables 5 and 6, traditional manual methods rely on sensory observation and subjective judgment, resulting in poor repeatability and low efficiency. Machine vision technology combined with brute-force algorithms improves repeatability and accuracy, but also incurs a significant time cost. Machine vision technology for geometric Hough circle detection has a lower time cost, but its accuracy is poor. Overall, the comparison shows that using machine vision technology combined with the improved genetic algorithm presented in this paper demonstrates superior performance in terms of data accuracy and time cost.

[0119] (IV) Conclusion

[0120] This invention proposes a method based on a genetic algorithm to alternately search the inner and outer edges of a cable cross-section to detect the thinnest thickness of the cable. This method overcomes the limitations of previous machine vision measurement methods, which could only handle simple cable cross-section structures. It expands the scope of application, greatly speeds up the detection process, and achieves high data accuracy.

[0121] In addition, this invention makes several improvements to the traditional genetic algorithm based on the actual characteristics of the cable test specimens:

[0122] 1) Generate an initial population based on the curvature characteristics of the specimen cross section to ensure gene richness;

[0123] 2) Adaptive crossover and mutation are used to accelerate the search speed for the optimal solution;

[0124] 3) Use a local alternation genetic algorithm to search for and approximate the optimal solution alternately on the inner and outer edges.

[0125] Extensive comparative experiments have shown that the proposed method has significantly improved in terms of applicability, accuracy, repeatability, and efficiency, and has promising application prospects in the field of practical cable testing.

[0126] In this embodiment, a computer-readable storage medium is also provided, wherein the computer-readable storage medium stores one or more programs, which, when executed by a processor, implement the method described.

[0127] In this embodiment, an electronic device is also provided, wherein the electronic device includes:

[0128] Processor; and,

[0129] A memory is configured to store computer-executable instructions that, when executed, cause the processor to perform the method described.

[0130] It should be noted that:

[0131] The method used in this embodiment can be converted into program steps and apparatus that can be stored in a computer storage medium and implemented by being called and executed by a controller. The apparatus should be understood as a functional module implemented by a computer program.

[0132] The algorithms and displays provided herein are not inherently related to any particular computer, virtual device, or other equipment. Various general-purpose devices can also be used in conjunction with the teachings herein. The required structure for constructing such devices is apparent from the above description. Furthermore, this invention is not directed to any particular programming language. It should be understood that the contents of the invention described herein can be implemented using various programming languages, and the above description of specific languages ​​is for the purpose of disclosing the best mode of implementation of the invention.

[0133] Numerous specific details are set forth in the specification provided herein. However, it will be understood that embodiments of the invention may be practiced without these specific details. In some instances, well-known methods, structures, and techniques have not been shown in detail so as not to obscure the understanding of this specification.

[0134] Similarly, it should be understood that, in order to simplify this disclosure and aid in understanding one or more of the various aspects of the invention, in the above description of exemplary embodiments of the invention, various features of the invention are sometimes grouped together in a single embodiment, figure, or description thereof. However, this method of disclosure should not be construed as reflecting an intention that the claimed invention requires more features than are expressly recited in each claim. Rather, as reflected in the following claims, inventive aspects lie in fewer than all features of a single foregoing disclosed embodiment. Therefore, the claims following the detailed description are hereby expressly incorporated into this detailed description, wherein each claim itself is a separate embodiment of the invention.

[0135] Those skilled in the art will understand that modules in the device of the embodiments can be adaptively changed and placed in one or more devices different from that embodiment. Modules, units, or components in the embodiments can be combined into a single module, unit, or component, and further, they can be divided into multiple sub-modules, sub-units, or sub-components. Except where at least some of such features and / or processes or units are mutually exclusive, any combination can be used to combine all features disclosed in this specification (including the accompanying claims, abstract, and drawings) and all processes or units of any method or device so disclosed. Unless expressly stated otherwise, each feature disclosed in this specification (including the accompanying claims, abstract, and drawings) may be replaced by an alternative feature that serves the same, equivalent, or similar purpose.

[0136] Furthermore, those skilled in the art will understand that although some embodiments described herein include certain features but not others included in other embodiments, combinations of features from different embodiments are intended to be within the scope of the invention and form different embodiments. For example, in the following claims, any of the claimed embodiments can be used in any combination.

[0137] The various component embodiments of the present invention can be implemented in hardware, or as software modules running on one or more processors, or a combination thereof. The present invention can also be implemented as a device or apparatus program (e.g., a computer program and computer program product) for performing some or all of the methods described herein. Such programs implementing the present invention can be stored on a computer-readable medium, or can take the form of one or more signals. Such signals can be downloaded from an Internet website, provided on a carrier signal, or provided in any other form.

[0138] For example, Figure 11A schematic diagram of an electronic device according to an embodiment of the present invention is shown. The electronic device conventionally includes a processor 31 and a memory 32 arranged to store computer-executable instructions (program code). The memory 32 may be an electronic memory such as flash memory, EEPROM (Electrically Erasable Programmable Read-Only Memory), EPROM, hard disk, or ROM. The memory 32 has storage space 33 for storing program code 34 for performing any method steps in the embodiments. For example, the storage space 33 for program code may include various program codes 34 respectively for implementing the various steps in the above methods. These program codes can be read from or written to one or more computer program products. These computer program products include program code carriers such as hard disks, CDs, memory cards, or floppy disks. Such computer program products are typically, for example... Figure 12 The aforementioned computer-readable storage medium. This computer-readable storage medium may have the same characteristics as... Figure 11 The memory 32 in the electronic device is similarly arranged as a storage segment, storage space, etc. The program code can be compressed, for example, in a suitable form. Typically, the storage unit stores program code 41 for performing the method steps according to the invention, i.e., program code that can be read by a processor such as 31, which, when run by the electronic device, causes the electronic device to perform the various steps of the method described above.

[0139] It should be noted that the embodiments described are illustrative of the invention and not restrictive, and that alternative embodiments can be devised by those skilled in the art without departing from the scope of the appended claims. In the claims, any reference signs placed between parentheses should not be construed as limiting the claims. The word "comprising" does not exclude the presence of elements or steps not listed in the claims. The word "a" or "an" preceding an element does not exclude the presence of a plurality of such elements. The invention can be implemented by means of hardware comprising several different elements and by means of a suitably programmed computer. In the unit claims enumerating several means, several of these means may be embodied by the same item of hardware. The use of the words first, second, and third, etc., does not indicate any order. These words can be interpreted as names.

Claims

1. A method for detecting the insulation thickness of irregular cables based on an adaptive local alternation genetic algorithm, characterized in that, This includes the following steps performed sequentially: Step S1: Acquire cross-sectional images of the specimen and extract its inner and outer edge information; Step S2: Calculate the curvature features of the cross section, and randomly select pixels at the inner and outer edges based on the curvature features; Step S3: Iterate through and calculate the distance between the inner and outer edge pixels, take the minimum value as the individual detection position, and generate the initial detection position population; Step S4: Determine whether the current population has reached the termination iteration condition. If the termination iteration condition is reached, output the optimal detection position and proceed to step S7; otherwise, proceed to step S5. The termination iteration condition is configured as the number of iterations reaching a given allowable value or converging to the global optimal solution. Step S5: Perform an adaptive local alternation genetic algorithm on the inner and outer edges of the detection position population to search for the position with the minimum insulation thickness and generate a new detection position population; Step S6: Select the new and old detection location populations and update the detection location populations, then proceed to step S4; Step S7: If the number of detected positions reaches the set number, the algorithm ends; otherwise, proceed to step S8. Step S8: Remove a set percentage of pixels from the current inner and outer edges, then proceed to step S2.

2. The method for detecting the insulation thickness of irregular cables as described in claim 1, characterized in that: Configure the inner and outer edge pixels of the cable cross section to correspond one-to-one with the array index, and arrange them in the order of the corresponding array index. Then, use Gray code encoding to encode the array index of the inner and outer edge pixels.

3. The method for detecting the insulation thickness of irregular cables as described in claim 1, characterized in that, Step S5 further includes: In the adaptive local alternation genetic algorithm, the reciprocal of the insulation thickness is taken as the fitness function, and the crossover and mutation methods in the genetic algorithm are adjusted according to the fitness value.

4. The method for detecting the insulation thickness of irregular cables as described in claim 3, characterized in that, The crossing method is determined based on the following rules: If f≥f avg In this case, a single-point intersection is used; If f <f avg Then a two-point intersection is used; Among them, f avg denoted as the average fitness of the population, and f is the larger fitness of the two individuals to be crossed.

5. The method for detecting the insulation thickness of irregular cables as described in claim 3, characterized in that, The mutation method is determined based on the following rules: If f'≥f avg If so, then single-point mutation is used; If f' <f avg If so, then two-point mutation is used; Among them, f avg f' represents the average fitness of the population, and f' represents the fitness of an individual.

6. The method for detecting the insulation thickness of irregular cables as described in claim 3, 4, or 5, characterized in that, Step S6 further includes: The new population and the old population obtained after crossover and mutation are sorted by fitness, and individuals with high fitness are selected as the next generation population.

7. The method for detecting the insulation thickness of irregular cables as described in claim 1, characterized in that, Step S3 further includes: The curvature characteristics of the specimen cross-section were calculated using image processing techniques. The number of locations with larger curvature at the inner and outer edges was counted and denoted as a and b, respectively. The inner and outer edges were then divided into n segments, where: n = k × max{a, b} Where k is the initial population selection rate, 10≤k≤100; Each segment randomly selects an index address, resulting in n C's. in Sample points and C out Sample points, traverse and calculate C in Each sample point and C out The distance between sample points is taken as the minimum value corresponding to C. out Each sample point forms an individual insulation thickness detection location, resulting in n insulation thickness detection locations, which serve as the initial population, where C in C is an array of pixels representing the inner edges. out This is the outer edge pixel array.

8. A storage medium, wherein, The storage medium stores one or more programs, which, when executed by a processor, implement the method for detecting the insulation thickness of irregular cables according to any one of claims 1 to 7.

9. An electronic device, wherein, The electronic device includes: Processor; and, A memory configured to store computer-executable instructions, which, when executed, cause the processor to perform the method for detecting the insulation thickness of irregular cables according to any one of claims 1 to 7.

Citation Information

Patent Citations

  • Image-processing-based cable sheath thickness measuring method

    CN102032875A

  • High voltage insulator numerical optimization method based on small population real-coded genetic algorithm

    CN108875187A