Cable minimum bending radius detection method, system, device and storage medium
By pre-processing and automatic calculation of the images of the bent parts of the cable, the problems of strong subjectivity and low efficiency of the detection of the bending radius of the cable in the prior art are solved, and automatic and accurate detection of the minimum bending radius of the cable is realized, which is suitable for large-scale power distribution project.
Patent Information
- Application Number
- CN202411144840.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-20
- Publication Date
- 2024-11-19
- Estimated Expiration
- 2044-08-20
AI Technical Summary
The existing cable bending radius detection methods have problems such as strong subjectivity and low detection efficiency. Especially in power distribution projects, manual tool measurements are complicated and software-assisted measurements require user manual participation, resulting in a lack of consistency and inefficiency in the detection results.
By pre-processing the collected image of the cable bend part, the target contour point coordinate set is obtained, and it is divided into the first contour point coordinate set and the second contour point coordinate set, and the pixel size of the cable diameter and the minimum bending radius are automatically calculated. , adopt the European distance matrix and polynomial fitting method to unify the calculation process to improve detection efficiency and consistency.
It realizes automatic detection without manual participation from users, ensures the consistency and reliability of the minimum bending radius detection results of the cable, improves detection efficiency, and reduces manual errors. It is suitable for scenarios with a large number of cables in large-scale power distribution projects.
Smart Images

Figure CN118657826B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of cable detection, and in particular to a method, system, device and storage medium for detecting a minimum bending radius of a cable. Background Art
[0002] During the cable laying process of power distribution projects, the standard process requires that the cable's allowable bending radius must be larger than several times the cable diameter (taking single-core armored cable as an example, it must be larger than 15 times). If the cable's minimum bending radius is too small, it can easily cause mechanical damage to the cable's interior, reduce its mechanical strength, and easily cause insulation damage failures.
[0003] At present, the main methods for measuring the bending radius of cables are manual tool measurement and software-assisted measurement. Manual tool measurement mainly uses the tape measure method and the soft ruler method, both of which use tools to measure the outer diameter length of the cable and the outer diameter length after bending, so as to calculate the bending radius of the cable, while software-assisted measurement mainly obtains cable images through image acquisition devices, manually draws the edge contour or edge point of the cable in combination with human-computer interaction, and then automatically calculates the cable diameter and cable bending radius based on these manually input parameters.
[0004] However, both the manual tool measurement and software-assisted measurement require manual participation of the user and are highly subjective, resulting in low detection efficiency. Summary of the invention
[0005] The present application aims to propose a method, system, device and storage medium for detecting the minimum bending radius of a cable, which can improve the detection efficiency of the minimum bending radius of a cable.
[0006] In a first aspect, an embodiment of the present application provides a method for detecting a minimum bending radius of a cable, the method comprising:
[0007] Performing image preprocessing on the collected cable bending part images to obtain a target contour point coordinate set of the cable bending part;
[0008] The target contour point coordinate set is divided into a first contour point coordinate set and a second contour point coordinate set, wherein the first contour point coordinate set is all the target contour point coordinates on the left side of the cable bending part, and the second contour point coordinate set is all the target contour point coordinates on the right side of the cable bending part;
[0009] Calculating the pixel size of the cable diameter and the pixel size of the cable minimum bending radius according to the first contour point coordinate set and the second contour point coordinate set;
[0010] The minimum bending radius of the cable is detected according to the pixel size of the cable diameter and the pixel size of the minimum bending radius of the cable.
[0011] Compared with the prior art, the first aspect of the present application has the following beneficial effects:
[0012] This method obtains the target contour point coordinate set of the cable bending part by performing image preprocessing on the collected cable bending part image, and then directly divides the target contour point coordinate set into a first contour point coordinate set and a second contour point coordinate set, and then automatically calculates the pixel size of the cable diameter and the pixel size of the cable minimum bending radius according to the first contour point coordinate set and the second contour point coordinate set, and finally detects the cable minimum bending radius according to the pixel size of the cable diameter and the pixel size of the cable minimum bending radius. In this way, the target contour point coordinate set of the cable bending part is obtained directly through image preprocessing, without manual participation of the user, which solves the subjective problem existing in the manual measurement process, and then automatically calculates the pixel size of the cable diameter and the pixel size of the cable minimum bending radius according to the first contour point coordinate set and the second contour point coordinate set, unifies the calculation method and process to detect the cable minimum bending radius, ensures the consistency and reliability of the detection results, and can improve the detection efficiency of the cable minimum bending radius.
[0013] In some implementations, dividing the target contour point coordinate set into a first contour point coordinate set and a second contour point coordinate set includes:
[0014] Filtering the target contour point coordinates in the target contour point coordinate set to obtain a filtered target contour point coordinate set;
[0015] Evenly dividing the filtered target contour point coordinate set into a plurality of first target contour point coordinate sets;
[0016] Calculate the mean value in the width direction corresponding to each group of first target contour point coordinate sets;
[0017] According to the mean, the first target contour point coordinates in each group of first target contour point coordinate sets are divided into first contour point coordinates or second contour point coordinates;
[0018] Taking the first contour point coordinates corresponding to the first target contour point coordinates in the first target contour point coordinate sets of all groups as a set, obtaining a first contour point coordinate set;
[0019] The second contour point coordinates corresponding to the first target contour point coordinates in the first target contour point coordinate sets of all groups are taken as a set to obtain a second contour point coordinate set.
[0020] In some implementations, the target contour point coordinates in the target contour point coordinate set are filtered in the following manner to obtain a filtered target contour point coordinate set:
[0021]
[0022]
[0023]
[0024] in, represents the filtered target contour point coordinate set, represents the target contour point coordinate set, represents the target contour point in the target contour point coordinate set, Indicates the coordinates of the target contour points in the target contour point set. coordinate, Indicates the coordinates of the filtered target contour points The minimum value of the coordinate range, Indicates the coordinates of the filtered target contour points The maximum value of the coordinate range, Represents the coordinates of all target contour points in the target contour point set The maximum value of coordinates, Represents the coordinates of all target contour points in the target contour point set Minimum coordinate value.
[0025] In some implementations, the filtered target contour point coordinate set is evenly divided into a plurality of first target contour point coordinate sets in the following manner:
[0026]
[0027]
[0028]
[0029]
[0030] in, Indicates The first target contour point coordinate set, represents the target contour point in the filtered target contour point coordinate set, represents the filtered target contour point coordinate set, Indicates The first target contour point coordinates are concentrated The minimum value of the coordinate range, Indicates the coordinates of the target contour points in the target contour point set. coordinate, Indicates The first target contour point coordinates are concentrated The maximum value of the coordinate range, Indicates the coordinates of the filtered target contour points The minimum value of the coordinate range, Represents the total number of groups of the first target contour point coordinate set, Indicates the coordinates of the filtered target contour points The maximum value of the coordinate range.
[0031] In some implementations, calculating the pixel size of the cable diameter according to the first contour point coordinate set and the second contour point coordinate set includes:
[0032] Calculating the Euclidean distance between each contour point coordinate in the first contour point coordinate set and each contour point coordinate in the second contour point coordinate set to obtain a Euclidean distance matrix;
[0033] According to the Euclidean distance matrix, calculating the minimum value of the Euclidean distance corresponding to each contour point coordinate in the first contour point coordinate set and the Euclidean distance corresponding to each contour point coordinate in the second contour point coordinate set, to obtain a minimum Euclidean distance matrix;
[0034] The average value of all Euclidean distances in the minimum Euclidean distance matrix is calculated to obtain the pixel size of the cable diameter.
[0035] In some implementations, calculating the pixel size of the minimum bending radius of the cable according to the first contour point coordinate set and the second contour point coordinate set includes:
[0036] Performing polynomial fitting on the first contour point coordinate set to obtain a first polynomial fitting function, and performing polynomial fitting on the second contour point coordinate set to obtain a second polynomial fitting function;
[0037] Calculating the curvature radius value of each contour point coordinate in the first contour point coordinate set according to the first polynomial fitting function to obtain a first curvature radius set, and calculating the curvature radius value of each contour point coordinate in the second contour point coordinate set according to the second polynomial fitting function to obtain a second curvature radius set;
[0038] Calculating an average value of all the radius of curvature values in the first radius of curvature set to obtain a first radius of curvature average value, and calculating an average value of all the radius of curvature values in the second radius of curvature set to obtain a second radius of curvature average value;
[0039] Comparing the first average value of the radius of curvature and the second average value of the radius of curvature to obtain a third average value of the radius of curvature, wherein the third average value of the radius of curvature is a larger value between the first average value of the radius of curvature and the second average value of the radius of curvature;
[0040] The smallest curvature radius value in the curvature radius set corresponding to the third curvature radius average value is selected as the pixel size of the minimum bending radius of the cable.
[0041] In some embodiments, detecting the minimum bending radius of the cable according to the pixel size of the cable diameter and the pixel size of the minimum bending radius of the cable includes:
[0042] Calculating a ratio between a pixel size of the cable diameter and a pixel size of a minimum bending radius of the cable;
[0043] According to the ratio, it is detected whether the minimum bending radius of the cable meets the preset standard.
[0044] In a second aspect, an embodiment of the present application further provides a cable minimum bending radius detection system, the system comprising:
[0045] A data acquisition unit, used for performing image preprocessing on the collected cable bending part image to obtain a target contour point coordinate set of the cable bending part;
[0046] A data division unit, used for dividing the target contour point coordinate set into a first contour point coordinate set and a second contour point coordinate set, wherein the first contour point coordinate set is all the target contour point coordinates on the left side of the cable bending part, and the second contour point coordinate set is all the target contour point coordinates on the right side of the cable bending part;
[0047] A data calculation unit, used for calculating the pixel size of the cable diameter and the pixel size of the cable minimum bending radius according to the first contour point coordinate set and the second contour point coordinate set;
[0048] The data detection unit is used to detect the minimum bending radius of the cable according to the pixel size of the cable diameter and the pixel size of the minimum bending radius of the cable.
[0049] In a third aspect, an embodiment of the present application also provides an electronic device, comprising at least one control processor and a memory for communicating with the at least one control processor; the memory stores instructions that can be executed by the at least one control processor, and the instructions are executed by the at least one control processor so that the at least one control processor can execute a method for detecting a minimum bending radius of a cable as described above.
[0050] In a fourth aspect, an embodiment of the present application further provides a computer-readable storage medium, wherein the computer-readable storage medium stores computer-executable instructions, and the computer-executable instructions are used to enable a computer to execute a method for detecting a minimum bending radius of a cable as described above.
[0051] It can be understood that the beneficial effects of the second to fourth aspects compared with the related art are the same as the beneficial effects of the first aspect compared with the related art. Please refer to the relevant description in the first aspect, and no further details will be given here. BRIEF DESCRIPTION OF THE DRAWINGS
[0052] The above and / or additional aspects and advantages of the present application will become apparent and easily understood from the description of the embodiments in conjunction with the following drawings, in which:
[0053] Figure 1 It is a schematic flow chart of an embodiment of a method for detecting a minimum bending radius of a cable provided by the present application;
[0054] Figure 2 It is a schematic diagram of the overall method flow in the best embodiment of the method for detecting the minimum bending radius of a cable provided by the present application;
[0055] Figure 3 It is a schematic diagram of the segmentation of a cable bending part example in an embodiment of the method for detecting the minimum bending radius of a cable provided by the present application;
[0056] Figure 4 It is a schematic diagram of a target contour point coordinate set of a cable bending part in an embodiment of a cable minimum bending radius detection method provided by the present application;
[0057] Figure 5 It is a schematic diagram of grouping contour coordinate points of a cable bending part in an embodiment of a method for detecting a minimum bending radius of a cable provided by the present application;
[0058] Figure 6 It is a structural schematic diagram of an embodiment of a cable minimum bending radius detection system provided by the present application. DETAILED DESCRIPTION
[0059] The embodiments of the present application are described in detail below, and examples of the embodiments are shown in the accompanying drawings, wherein the same or similar reference numerals throughout represent the same or similar elements or elements having the same or similar functions. The embodiments described below with reference to the accompanying drawings are exemplary and are only used to explain the present application, and cannot be understood as limiting the present application.
[0060] In the description of this application, if there is a description of first, second, etc., it is only for the purpose of distinguishing technical features, and cannot be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features or implicitly indicating the order of the indicated technical features.
[0061] In the description of the present application, it should be understood that the descriptions involving orientations, such as the orientations or contour point relationships indicated as up, down, etc., are based on the orientations or contour point relationships shown in the accompanying drawings, and are only for the convenience of describing the present application and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore should not be understood as a limitation on the present application.
[0062] In the description of this application, it should be noted that, unless otherwise clearly defined, terms such as setting, installing, connecting, etc. should be understood in a broad sense, and technicians in the relevant technical field can reasonably determine the specific meaning of the above terms in this application based on the specific content of the technical solution.
[0063] During the cable laying process of power distribution projects, the standard process requires that the cable's allowable bending radius must be larger than several times the cable diameter (taking single-core armored cable as an example, it must be larger than 15 times). If the cable's minimum bending radius is too small, it can easily cause mechanical damage to the cable's interior, reduce its mechanical strength, and easily cause insulation damage failures.
[0064] At present, the main methods for measuring the bending radius of cables are manual tool measurement and software-assisted measurement. Manual tool measurement mainly uses the tape measure method and the soft ruler method, both of which use tools to measure the outer diameter of the cable and the outer diameter after bending, so as to calculate the bending radius of the cable. However, manual tool measurement has the problem of complicated measurement process and long time consumption, especially in large-scale power distribution projects, where a large number of cables need to be measured, which reduces work efficiency. Moreover, manual measurement may be more difficult for some inaccessible cable parts. Software-assisted measurement mainly obtains cable images through image acquisition devices, manually draws the edge contour or edge point of the cable in combination with human-computer interaction, and then automatically calculates the cable diameter and cable bending radius based on these manually input parameters. However, software-assisted measurement also requires manual participation of users, which is highly subjective, lacks consistency in detection results, and also has the problem of low detection efficiency.
[0065] In order to solve the above-mentioned problems of strong subjectivity, lack of consistency in detection results and low detection efficiency, the present application proposes a method, system, device and storage medium for detecting the minimum bending radius of a cable.
[0066] Reference Figure 1 The present application provides a method for detecting the minimum bending radius of a cable, and the method comprises the following steps:
[0067] Step S100, performing image preprocessing on the collected cable bending part image to obtain a target contour point coordinate set of the cable bending part;
[0068] Step S200, dividing the target contour point coordinate set into a first contour point coordinate set and a second contour point coordinate set, the first contour point coordinate set being all target contour point coordinates on the left side of the cable bending part, and the second contour point coordinate set being all target contour point coordinates on the right side of the cable bending part;
[0069] Step S300, calculating the pixel size of the cable diameter and the pixel size of the cable minimum bending radius according to the first contour point coordinate set and the second contour point coordinate set;
[0070] Step S400: Detect the minimum bending radius of the cable according to the pixel size of the cable diameter and the pixel size of the minimum bending radius of the cable.
[0071] In this embodiment, the target contour point coordinate set of the cable bending part is obtained by performing image preprocessing on the collected cable bending part image, and then the target contour point coordinate set is directly divided into a first contour point coordinate set and a second contour point coordinate set, and then the pixel size of the cable diameter and the pixel size of the cable minimum bending radius are automatically calculated according to the first contour point coordinate set and the second contour point coordinate set, and finally the cable minimum bending radius is detected according to the pixel size of the cable diameter and the pixel size of the cable minimum bending radius. In this way, the target contour point coordinate set of the cable bending part is obtained directly through image preprocessing, without manual participation of the user, which solves the subjective problem existing in the manual measurement process, and then the pixel size of the cable diameter and the pixel size of the cable minimum bending radius are automatically calculated according to the first contour point coordinate set and the second contour point coordinate set, unifying the calculation method and process to detect the cable minimum bending radius, ensuring the consistency and reliability of the detection results, and being able to improve the detection efficiency of the cable minimum bending radius.
[0072] The above image preprocessing can adopt filtering algorithm and contour finding and sorting method.
[0073] The above-mentioned filtering algorithm and contour searching and sorting method may be existing technologies, and will not be described in detail in this embodiment.
[0074] The above-mentioned target contour point coordinate set may be a set of coordinates of corresponding points of the contour of the cable bending part.
[0075] The above contour can be viewed as a curve consisting of a series of connected points.
[0076] In some implementations, dividing the target contour point coordinate set into a first contour point coordinate set and a second contour point coordinate set includes:
[0077] Filtering the target contour point coordinates in the target contour point coordinate set to obtain a filtered target contour point coordinate set;
[0078] The filtered target contour point coordinate set is evenly divided into a plurality of first target contour point coordinate sets;
[0079] Calculate the mean value in the width direction corresponding to each group of first target contour point coordinate sets;
[0080] According to the mean, the first target contour point coordinates in each group of first target contour point coordinate sets are divided into first contour point coordinates or second contour point coordinates;
[0081] Taking the first contour point coordinates corresponding to the first target contour point coordinates in the first target contour point coordinate sets of all groups as a set, obtaining a first contour point coordinate set;
[0082] The second contour point coordinates corresponding to the first target contour point coordinates in the first target contour point coordinate sets of all groups are taken as a set to obtain a second contour point coordinate set.
[0083] In this embodiment, by screening the target contour point coordinates in the target contour point coordinate set, a screened target contour point coordinate set that better meets the requirements can be obtained, laying a good data foundation for the subsequent cable minimum bending radius detection.
[0084] In some implementations, the target contour point coordinates in the target contour point coordinate set are filtered in the following manner to obtain a filtered target contour point coordinate set:
[0085]
[0086]
[0087]
[0088] in, represents the filtered target contour point coordinate set, represents the target contour point coordinate set, represents the target contour point in the target contour point coordinate set, Indicates the coordinates of the target contour points in the target contour point set. coordinate, Indicates the coordinates of the filtered target contour points The minimum value of the coordinate range, Indicates the coordinates of the filtered target contour points The maximum value of the coordinate range, Represents the coordinates of all target contour points in the target contour point set The maximum value of coordinates, Represents the coordinates of all target contour points in the target contour point set Minimum coordinate value.
[0089] In this embodiment, the target contour point coordinates in the target contour point coordinate set are filtered by deleting the contour point coordinates at the top and bottom that may be contaminated due to external occlusion, so that a filtered target contour point coordinate set that better meets the requirements can be obtained, laying a good data foundation for the subsequent cable minimum bending radius detection.
[0090] In some implementations, the filtered target contour point coordinate set is evenly divided into a plurality of first target contour point coordinate sets in the following manner:
[0091]
[0092]
[0093]
[0094]
[0095] in, Indicates The first target contour point coordinate set, represents the target contour point in the filtered target contour point coordinate set, represents the filtered target contour point coordinate set, Indicates The first target contour point coordinates are concentrated The minimum value of the coordinate range, Indicates the coordinates of the target contour points in the target contour point set. coordinate, Indicates The first target contour point coordinates are concentrated The maximum value of the coordinate range, Indicates the coordinates of the filtered target contour points The minimum value of the coordinate range, Represents the total number of groups of the first target contour point coordinate set, Indicates the coordinates of the filtered target contour points The maximum value of the coordinate range.
[0096] In this embodiment, the filtered target contour point coordinate set is evenly divided into multiple groups of first target contour point coordinate sets, and then left and right grouping is performed according to each group of first target contour point coordinate sets. The error is smaller than direct grouping, and the accuracy of cable minimum bending radius detection can be improved by reducing the error.
[0097] In some embodiments, calculating the pixel size of the cable diameter according to the first contour point coordinate set and the second contour point coordinate set includes:
[0098] Calculate the Euclidean distance between each contour point coordinate in the first contour point coordinate set and each contour point coordinate in the second contour point coordinate set to obtain a Euclidean distance matrix;
[0099] According to the Euclidean distance matrix, the minimum value of the Euclidean distance corresponding to each contour point coordinate in the first contour point coordinate set and the Euclidean distance corresponding to each contour point coordinate in the second contour point coordinate set is calculated to obtain a minimum Euclidean distance matrix;
[0100] The average of all Euclidean distances in the minimum Euclidean distance matrix is calculated to obtain the pixel size of the cable diameter.
[0101] In this embodiment, the minimum Euclidean distance matrix is obtained by calculating the minimum value of the Euclidean distance corresponding to each contour point coordinate in the first contour point coordinate set and the Euclidean distance corresponding to each contour point coordinate in the second contour point coordinate set according to the Euclidean distance matrix, and then the average value of all Euclidean distances in the minimum Euclidean distance matrix is calculated to obtain the pixel size of the cable diameter. The pixel size of the cable diameter can be calculated by a unified method, thereby ensuring the consistency and reliability of the detection results.
[0102] In some embodiments, calculating the pixel size of the minimum bending radius of the cable according to the first contour point coordinate set and the second contour point coordinate set includes:
[0103] Performing polynomial fitting on the first contour point coordinate set to obtain a first polynomial fitting function, and performing polynomial fitting on the second contour point coordinate set to obtain a second polynomial fitting function;
[0104] Calculating the curvature radius value of each contour point coordinate in the first contour point coordinate set according to the first polynomial fitting function to obtain a first curvature radius set, and calculating the curvature radius value of each contour point coordinate in the second contour point coordinate set according to the second polynomial fitting function to obtain a second curvature radius set;
[0105] Calculating an average value of all the radius of curvature values in the first radius of curvature set to obtain a first radius of curvature average value, and calculating an average value of all the radius of curvature values in the second radius of curvature set to obtain a second radius of curvature average value;
[0106] Compare the first average value of the radius of curvature and the second average value of the radius of curvature to obtain a third average value of the radius of curvature, wherein the third average value of the radius of curvature is a larger value between the first average value of the radius of curvature and the second average value of the radius of curvature;
[0107] The smallest curvature radius value in the curvature radius set corresponding to the third curvature radius average value is selected as the pixel size of the minimum bending radius of the cable.
[0108] In this embodiment, a polynomial fitting is performed on the first contour point coordinate set to obtain a first polynomial fitting function, and a polynomial fitting is performed on the second contour point coordinate set to obtain a second polynomial fitting function. By fitting the contour coordinate points with a polynomial, the situation that the bending trajectory of the actual cable is an irregular curve during the installation process is taken into account, thereby improving the detection accuracy of the minimum bending radius of the cable. In this embodiment, a unified calculation method is used to calculate the pixel size of the minimum bending radius of the cable, thereby ensuring the consistency and reliability of the detection results.
[0109] In some embodiments, detecting the minimum bending radius of the cable according to the pixel size of the cable diameter and the pixel size of the minimum bending radius of the cable includes:
[0110] Calculate the ratio between the pixel size of the cable diameter and the pixel size of the cable's minimum bending radius;
[0111] Based on the ratio, check whether the minimum bending radius of the cable meets the preset standard.
[0112] In this embodiment, by calculating the ratio between the pixel size of the cable diameter and the pixel size of the minimum bending radius of the cable, and then detecting whether the minimum bending radius of the cable meets the preset standard based on the ratio, no manual parameters are required throughout the process, which can improve the detection efficiency. In addition, a unified method is used to detect whether the minimum bending radius of the cable meets the preset standard, thereby ensuring the consistency and reliability of the detection results.
[0113] The above-mentioned detection of whether the minimum bending radius of the cable meets the preset standard based on the ratio may be performed by comparing the ratio with the preset standard. If the ratio reaches the preset standard range, it means that the minimum bending radius of the cable meets the preset standard.
[0114] The above preset standards can be the range set in the "Distribution Network Construction and Maintenance Process Specifications Q / GDW 10742-2016".
[0115] To facilitate understanding by those skilled in the art, a set of best embodiments is provided below:
[0116] In this embodiment, the type of cable is first selected, and the segmented area of the cable bending part is obtained through a deep learning algorithm. Then, the contour target coordinate points of the cable bending part are obtained through an image processing method. The contour coordinate points are grouped through segmentation processing. The pixel sizes of the cable diameter and the minimum bending radius of the cable are calculated based on the grouped contour coordinate points. The proportional relationship between the two is compared with the proportional relationship of the corresponding cable type laying standard (i.e., the preset standard) to determine whether it meets the cable laying standard specifications. The implementation flow chart of this embodiment is as follows: Figure 2 As shown, the specific implementation includes the following steps:
[0117] (1) Manually select the cable type, including whether the cable is armored or not, the number of cable cores (single core, three cores), and obtain the qualified standard for the minimum bending radius of the cable (i.e., the preset standard). For details on the qualified standard for the minimum bending radius of the cable, please refer to the "Technical Specifications for Construction and Maintenance of Distribution Networks Q / GDW 10742-2016".
[0118] (2) Collect image sample data of cable laying through intelligent mobile terminals, construct an instance segmentation model of cable bending parts based on the instance segmentation model framework, and realize instance segmentation of cable bending parts, such as Figure 3 shown.
[0119] It should be noted that the instance segmentation model of this embodiment may be an existing technology used to perform instance segmentation of cable bending parts, which is not described in detail in this embodiment.
[0120] (3) Perform image preprocessing on the segmented area of the cable bending part. First, use a filtering algorithm to solve the jagged problem of the segmented area. Then, for the jagged image area, obtain the target contour point coordinates of the cable bending part by contour search and sorting (that is, obtain the target contour point coordinate set), as shown in the following figure. Figure 4 shown.
[0121] It should be noted that this embodiment can use contour search and sorting methods to obtain the target contour point coordinates of the cable bending part, or can use edge detection, Hough transform, region growing or boundary tracking methods to obtain the target contour point coordinates of the cable bending part, and this embodiment does not make specific restrictions.
[0122] (4) Divide the target contour point coordinates of the cable bending part into two groups according to the position relationship: the first contour point coordinate set and , as the input parameter for calculating the cable diameter and the pixel size of the cable minimum bending radius, the specific method is as follows:
[0123] 1) Delete the top and bottom contour point coordinates that may be contaminated by external occlusion, and retain the points that meet the requirements (i.e. the filtered target contour point coordinate set) , the specific formula is as follows;
[0124] (1)
[0125] (2)
[0126] (3)
[0127] in, represents the filtered target contour point coordinate set, represents the target contour point coordinate set, represents the target contour point in the target contour point coordinate set, Indicates the coordinates of the target contour points in the target contour point set. coordinate, Indicates the coordinates of the filtered target contour points The minimum value of the coordinate range, Indicates the coordinates of the filtered target contour points The maximum value of the coordinate range, Represents the coordinates of all target contour points in the target contour point set The maximum value of coordinates, Represents the coordinates of all target contour points in the target contour point set Minimum coordinate value.
[0128] 2) Set the contour point coordinates Divide the image into equal parts according to its height group, get The first target contour point coordinate set is set, and the mean value of each group of coordinate points in the width direction is calculated , the group calculation formula is as follows:
[0129] (4)
[0130] in, Indicates The first target contour point coordinate set, represents the target contour point in the filtered target contour point coordinate set, represents the filtered target contour point coordinate set, Indicates The first target contour point coordinates are concentrated The minimum value of the coordinate range, Indicates the coordinates of the target contour points in the target contour point set. coordinate, Indicates The first target contour point coordinates are concentrated The maximum value of the coordinate range. and The specific calculation is as follows:
[0131] (5)
[0132] (6)
[0133] (7)
[0134] The mean value of each group of coordinate points in the width direction is calculated as follows:
[0135] (8)
[0136] in, Indicates the coordinates of the filtered target contour points The minimum value of the coordinate range, Represents the total number of groups of the first target contour point coordinate set, Indicates the coordinates of the filtered target contour points The maximum value of the coordinate range, Indicates Group coordinates of all contour points coordinate, Indicates The number of group coordinate contour points.
[0137] 3) Based on the mean value of the width direction of each group of points , divide the contour point coordinates into two groups, left and right. The specific calculation process is as follows: traverse the The coordinate points of each contour in the group, the coordinate points Coordinates less than The left group is the left group, and the right group is the opposite. Each group is calculated according to the above process. The grouping results of the contour coordinate points of the cable bending part are as follows: Figure 5 As shown, Figure 5 The black dots are the left group, and the gray dots are the right group.
[0138] (5) Calculate the pixel size of the cable diameter, that is and The average Euclidean distance between groups is as follows:
[0139] 1) Traverse separately and ,calculate The coordinate points in (i.e. the coordinates of the first contour point) and The Euclidean distance matrix of each coordinate point (i.e. the coordinates of the second contour point) ,in and They are and The number of midpoints;
[0140] 2) Calculation Each point and The minimum value of the Euclidean distance of each coordinate point , that is, calculate the Euclidean distance matrix The minimum value of each row;
[0141] 3) Calculate the minimum Euclidean distance of each coordinate point (i.e. the minimum Euclidean distance matrix) The average value of the cable diameter is the pixel size .
[0142] (6) Calculate the pixel size of the minimum bending radius of the cable.
[0143] 1) For the left and right sets of contour coordinate points and Perform polynomial fitting respectively to obtain the polynomial fitting functions of the two sets of contour points. and ;
[0144] 2) Calculate two polynomial fitting functions using formula (9): and The radius of curvature, that is, the first radius of curvature set and the second radius of curvature set , and the left and right sets of contour coordinate points Substitute the coordinates into them respectively, and the curvature radius is calculated as follows:
[0145] (9)
[0146] (10)
[0147] 3) Take and The mean value of the median curvature radius (i.e. the average value of the first curvature radius and the average value of the second radius of curvature The larger average value (i.e. the third average value of curvature radius) is used as the calculation target of the bending radius. (That is, the curvature radius set corresponding to the average value of the third curvature radius or ), and calculate The minimum value in (i.e. the minimum radius of curvature), As a final result of the pixel size of the cable’s minimum bending radius;
[0148] (11)
[0149] in, , They are , The mean of .
[0150] (7) The ratio of the minimum bending radius pixel size of the cable to the cable diameter pixel size is calculated using the following formula: :
[0151] (12)
[0152] according to , determine whether the minimum bending radius of the cable meets the standard specifications (the standard specifications can be the distribution network construction and maintenance process specifications Q / GDW 10742-2016).
[0153] In this embodiment, the method of this embodiment has the following beneficial effects:
[0154] 1) The ratio of cable diameter to minimum bending radius is automatically detected by deep learning and image processing, without manual contouring and point drawing, which greatly improves the overall detection speed;
[0155] 2) The polynomial is used to fit the contour coordinate points, taking into account the fact that the bending trajectory of the actual cable during installation is an irregular curve, thus improving the detection accuracy of the minimum bending radius of the cable;
[0156] 3) The ratio of cable diameter to minimum bending radius is detected based on a unified algorithm and process, avoiding the influence of subjective factors caused by different personnel and at different times, and ensuring the consistency and reliability of the detection results.
[0157] Reference Figure 6 The embodiment of the present application also provides a cable minimum bending radius detection system, the system includes a data acquisition unit 100, a data division unit 200, a data calculation unit 300 and a data detection unit 400, wherein:
[0158] The data acquisition unit 100 is used to perform image preprocessing on the acquired cable bending part image to obtain a target contour point coordinate set of the cable bending part;
[0159] A data division unit 200 is used to divide the target contour point coordinate set into a first contour point coordinate set and a second contour point coordinate set, wherein the first contour point coordinate set is the coordinates of all target contour points on the left side of the cable bending part, and the second contour point coordinate set is the coordinates of all target contour points on the right side of the cable bending part;
[0160] A data calculation unit 300, used to calculate the pixel size of the cable diameter and the pixel size of the cable minimum bending radius according to the first contour point coordinate set and the second contour point coordinate set;
[0161] The data detection unit 400 is used to detect the minimum bending radius of the cable according to the pixel size of the cable diameter and the pixel size of the minimum bending radius of the cable.
[0162] It should be noted that since the cable minimum bending radius detection system in this embodiment and the above-mentioned cable minimum bending radius detection method are based on the same inventive concept, the corresponding contents in the method embodiment are also applicable to the system embodiment and will not be described in detail here.
[0163] An embodiment of the present invention further provides an electronic device, including: at least one control processor and a memory for communicating with the at least one control processor.
[0164] The memory, as a non-transient computer-readable storage medium, can be used to store non-transient software programs and non-transient computer executable programs. In addition, the memory may include a high-speed random access memory, and may also include a non-transient memory, such as at least one disk storage device, a flash memory device, or other non-transient solid-state storage device. In some embodiments, the memory may optionally include a memory remotely disposed relative to the processor, and these remote memories may be connected to the processor via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.
[0165] The non-transient software program and instructions required to implement the method for detecting the minimum bending radius of a cable in the above embodiment are stored in the memory. When executed by the processor, the method for detecting the minimum bending radius of a cable in the above embodiment is executed, for example, the above described method is executed. Figure 1 The method comprises steps S100 to S400.
[0166] The system embodiments described above are merely illustrative, and the units described as separate components may or may not be physically separated, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0167] The embodiment of the present invention further provides a computer-readable storage medium, which stores computer-executable instructions. The computer-executable instructions are executed by one or more control processors, so that the one or more control processors can execute a method for detecting the minimum bending radius of a cable in the above method embodiment, for example, executing the above described Figure 1 The functions of method steps S100 to S400 in the method.
[0168] It will be appreciated by those skilled in the art that all or some of the steps and systems in the methods disclosed above may be implemented as software, firmware, hardware, and appropriate combinations thereof. Some or all physical components may be implemented as software executed by a processor, such as a central processing unit, a digital signal processor, or a microprocessor, or as hardware, or as an integrated circuit, such as an application-specific integrated circuit. Such software may be distributed on a computer-readable medium, which may include a computer storage medium (or non-transitory medium) and a communication medium (or transient medium). As known to those skilled in the art, the term computer storage medium includes volatile and non-volatile, removable and non-removable media implemented in any method or technology for storing information (such as computer-readable instructions, data structures, program modules, or other data). Computer storage media include, but are not limited to, RAM, ROM, EEPROM, flash memory or other memory technology, CD-ROM, digital versatile disk (DVD) or other optical disk storage, magnetic cassettes, magnetic tapes, disk storage or other magnetic storage devices, or any other medium that can be used to store desired information and can be accessed by a computer. Furthermore, it is well known to those skilled in the art that communication media typically embodies computer readable instructions, data structures, program modules, or other data in a modulated data signal such as a carrier wave or other transport mechanism, and may include any information delivery media.
[0169] The above is a specific description of the preferred implementation of the embodiments of the present application, but the embodiments of the present application are not limited to the above-mentioned implementation methods. Technical personnel familiar with the field can also make various equivalent modifications or substitutions without violating the spirit of the embodiments of the present application. These equivalent modifications or substitutions are all included in the scope defined by the claims of the embodiments of the present application.
Claims
1. A method for detecting the minimum bending radius of a cable, characterized in that: The method comprises: Performing image preprocessing on the collected cable bending part images to obtain a target contour point coordinate set of the cable bending part; The target contour point coordinate set is divided into a first contour point coordinate set and a second contour point coordinate set, wherein the first contour point coordinate set is all the target contour point coordinates on the left side of the cable bending part, and the second contour point coordinate set is all the target contour point coordinates on the right side of the cable bending part; The pixel size of the cable diameter and the pixel size of the cable minimum bending radius are calculated according to the first contour point coordinate set and the second contour point coordinate set; wherein: Performing polynomial fitting on the first contour point coordinate set to obtain a first polynomial fitting function, and performing polynomial fitting on the second contour point coordinate set to obtain a second polynomial fitting function; Calculating the curvature radius value of each contour point coordinate in the first contour point coordinate set according to the first polynomial fitting function to obtain a first curvature radius set, and calculating the curvature radius value of each contour point coordinate in the second contour point coordinate set according to the second polynomial fitting function to obtain a second curvature radius set; Calculating an average value of all the radius of curvature values in the first radius of curvature set to obtain a first radius of curvature average value, and calculating an average value of all the radius of curvature values in the second radius of curvature set to obtain a second radius of curvature average value; Comparing the first average value of the radius of curvature and the second average value of the radius of curvature to obtain a third average value of the radius of curvature, wherein the third average value of the radius of curvature is a larger value between the first average value of the radius of curvature and the second average value of the radius of curvature; The smallest curvature radius value in the curvature radius set corresponding to the third curvature radius average value is selected as the pixel size of the minimum bending radius of the cable; if the third curvature radius average value is the first curvature radius average value, the curvature radius set corresponding to the third curvature radius average value is the first curvature radius set; if the third curvature radius average value is the second curvature radius average value, the curvature radius set corresponding to the third curvature radius average value is the second curvature radius set; Calculating the Euclidean distance between each contour point coordinate in the first contour point coordinate set and each contour point coordinate in the second contour point coordinate set to obtain a Euclidean distance matrix; According to the Euclidean distance matrix, calculating the minimum value of the Euclidean distance corresponding to each contour point coordinate in the first contour point coordinate set and the Euclidean distance corresponding to each contour point coordinate in the second contour point coordinate set, to obtain a minimum Euclidean distance matrix; Calculating the average value of all Euclidean distances in the minimum Euclidean distance matrix to obtain the pixel size of the cable diameter; The minimum bending radius of the cable is detected according to the pixel size of the cable diameter and the pixel size of the minimum bending radius of the cable.
2. The method for detecting the minimum bending radius of a cable according to claim 1, characterized in that: The step of dividing the target contour point coordinate set into a first contour point coordinate set and a second contour point coordinate set comprises: Filtering the target contour point coordinates in the target contour point coordinate set to obtain a filtered target contour point coordinate set; Dividing the filtered target contour point coordinate set into a plurality of first target contour point coordinate sets on average; Calculate the mean value in the width direction corresponding to each group of first target contour point coordinate sets; According to the mean, the first target contour point coordinates in each group of first target contour point coordinate sets are divided into first contour point coordinates or second contour point coordinates; Taking the first contour point coordinates corresponding to the first target contour point coordinates in the first target contour point coordinate sets of all groups as a set, obtaining a first contour point coordinate set; The second contour point coordinates corresponding to the first target contour point coordinates in the first target contour point coordinate sets of all groups are taken as a set to obtain a second contour point coordinate set.
3. The method for detecting the minimum bending radius of a cable according to claim 2, characterized in that: The target contour point coordinates in the target contour point coordinate set are filtered in the following manner to obtain the filtered target contour point coordinate set: ; ; ; in, represents the filtered target contour point coordinate set, represents the target contour point coordinate set, represents the target contour point in the target contour point coordinate set, Indicates the coordinates of the target contour points in the target contour point set. coordinate, Indicates the coordinates of the filtered target contour points The minimum value of the coordinate range, Indicates the coordinates of the filtered target contour points The maximum value of the coordinate range, Represents the coordinates of all target contour points in the target contour point set The maximum value of coordinates, Represents the coordinates of all target contour points in the target contour point set Minimum coordinate value.
4. The method for detecting the minimum bending radius of a cable according to claim 2, characterized in that: The filtered target contour point coordinate set is evenly divided into a plurality of first target contour point coordinate sets in the following manner: ; ; ; ; in, Indicates The first target contour point coordinate set, represents the target contour point in the filtered target contour point coordinate set, represents the filtered target contour point coordinate set, Indicates The first target contour point coordinates are concentrated The minimum value of the coordinate range, Indicates the coordinates of the target contour points in the target contour point set. coordinate, Indicates The first target contour point coordinates are concentrated The maximum value of the coordinate range, Indicates the coordinates of the filtered target contour points The minimum value of the coordinate range, Represents the total number of groups of the first target contour point coordinate set, Indicates the coordinates of the filtered target contour points The maximum value of the coordinate range.
5. The method for detecting the minimum bending radius of a cable according to claim 1, characterized in that: The detecting the minimum bending radius of the cable according to the pixel size of the cable diameter and the pixel size of the minimum bending radius of the cable comprises: Calculating a ratio between a pixel size of the cable diameter and a pixel size of a minimum bending radius of the cable; According to the ratio, it is detected whether the minimum bending radius of the cable meets the preset standard.
6. A cable minimum bending radius detection system, characterized in that: The system comprises: A data acquisition unit, used for performing image preprocessing on the collected cable bending part image to obtain a target contour point coordinate set of the cable bending part; A data division unit, used for dividing the target contour point coordinate set into a first contour point coordinate set and a second contour point coordinate set, wherein the first contour point coordinate set is all the target contour point coordinates on the left side of the cable bending part, and the second contour point coordinate set is all the target contour point coordinates on the right side of the cable bending part; A data calculation unit is used to calculate the pixel size of the cable diameter and the pixel size of the cable minimum bending radius according to the first contour point coordinate set and the second contour point coordinate set; wherein: Performing polynomial fitting on the first contour point coordinate set to obtain a first polynomial fitting function, and performing polynomial fitting on the second contour point coordinate set to obtain a second polynomial fitting function; Calculating the curvature radius value of each contour point coordinate in the first contour point coordinate set according to the first polynomial fitting function to obtain a first curvature radius set, and calculating the curvature radius value of each contour point coordinate in the second contour point coordinate set according to the second polynomial fitting function to obtain a second curvature radius set; Calculating an average value of all the radius of curvature values in the first radius of curvature set to obtain a first radius of curvature average value, and calculating an average value of all the radius of curvature values in the second radius of curvature set to obtain a second radius of curvature average value; Comparing the first average value of the radius of curvature and the second average value of the radius of curvature to obtain a third average value of the radius of curvature, wherein the third average value of the radius of curvature is a larger value between the first average value of the radius of curvature and the second average value of the radius of curvature; Selecting the smallest curvature radius value in the curvature radius set corresponding to the third curvature radius average value as the pixel size of the minimum bending radius of the cable; Calculating the Euclidean distance between each contour point coordinate in the first contour point coordinate set and each contour point coordinate in the second contour point coordinate set to obtain a Euclidean distance matrix; According to the Euclidean distance matrix, calculating the minimum value of the Euclidean distance corresponding to each contour point coordinate in the first contour point coordinate set and the Euclidean distance corresponding to each contour point coordinate in the second contour point coordinate set, to obtain a minimum Euclidean distance matrix; Calculating the average value of all Euclidean distances in the minimum Euclidean distance matrix to obtain the pixel size of the cable diameter; The data detection unit is used to detect the minimum bending radius of the cable according to the pixel size of the cable diameter and the pixel size of the minimum bending radius of the cable.
7. An electronic device, characterized in that: It includes at least one control processor and a memory for communicating with the at least one control processor; the memory stores instructions that can be executed by the at least one control processor, and the instructions are executed by the at least one control processor so that the at least one control processor can execute the method for detecting the minimum bending radius of the cable as described in any one of claims 1 to 5.
8. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer-executable instructions, and the computer-executable instructions are used to enable a computer to execute the method for detecting the minimum bending radius of a cable as claimed in any one of claims 1 to 5.
