CN113920122A - Cable defect detection method and system based on artificial intelligence - Google Patents

Cable defect detection method and system based on artificial intelligence Download PDF

Info

Publication number
CN113920122A
CN113920122A CN202111527503.0A CN202111527503A CN113920122A CN 113920122 A CN113920122 A CN 113920122A CN 202111527503 A CN202111527503 A CN 202111527503A CN 113920122 A CN113920122 A CN 113920122A
Authority
CN
China
Prior art keywords
connected domain
cable
target
obtaining
domain
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202111527503.0A
Other languages
Chinese (zh)
Other versions
CN113920122B (en
Inventor
束建磊
刘建强
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shandong Yinglian Photoelectric Technology Co Ltd
Original Assignee
Shandong Yinglian Photoelectric Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shandong Yinglian Photoelectric Technology Co Ltd filed Critical Shandong Yinglian Photoelectric Technology Co Ltd
Priority to CN202111527503.0A priority Critical patent/CN113920122B/en
Publication of CN113920122A publication Critical patent/CN113920122A/en
Application granted granted Critical
Publication of CN113920122B publication Critical patent/CN113920122B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/0002Inspection of images, e.g. flaw detection
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q10/00Administration; Management
    • G06Q10/20Administration of product repair or maintenance
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q50/00Systems or methods specially adapted for specific business sectors, e.g. utilities or tourism
    • G06Q50/06Electricity, gas or water supply
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/10Segmentation; Edge detection
    • G06T7/187Segmentation; Edge detection involving region growing; involving region merging; involving connected component labelling

Abstract

The invention relates to a cable defect detection method and system based on artificial intelligence, and belongs to the technical field of cable defect detection. The method comprises the following steps: screening each first communication domain according to the main component direction corresponding to each first communication domain to obtain a second communication domain corresponding to the cable target image; carrying out Hough transform on each second connected domain to obtain the number of target highlight points corresponding to each second connected domain; screening the second connected domains according to the first bending degree corresponding to the second connected domains and the number of the target highlight points corresponding to the second connected domains to obtain the target connected domains corresponding to the cable target images; obtaining the parallelism between the target connected domains according to the corresponding principal component directions of the target connected domains; and judging whether the cable has strand scattering defects or not according to the parallelism among the target connected domains and the first bending degree corresponding to the target connected domains. The method and the device can improve the accuracy of the detection of the scattered strand defect of the cable.

Description

Cable defect detection method and system based on artificial intelligence
Technical Field
The invention relates to the technical field of cable defect detection, in particular to a cable defect detection method and system based on artificial intelligence.
Background
In the modern industry, a cable stranded wire is formed by stranding a plurality of single wires with the same diameter or different diameters together according to a certain direction and a certain rule to form an integral stranded wire core; slight slippage between the outer layer and the inner layer may occur in the twisting process, or a certain section of torsion is too small in the twisting process, so that the outermost layer of the cable has a defect of local strand scattering, and the quality of the stranded wire may be seriously affected by the defect of strand scattering, so that an immeasurable result is caused.
The existing threshold segmentation method is generally based on a more conventional threshold segmentation method to detect whether the cable strand has the strand scattering defect, and the detection method is influenced by phenomena such as light reflection of the material of the cable strand and the like, so that the detection accuracy of the existing threshold segmentation method is low.
Disclosure of Invention
The invention provides a cable defect detection method and system based on artificial intelligence, which are used for solving the problem that the existing cable strand scattering defect cannot be accurately detected, and adopt the following technical scheme:
in a first aspect, an embodiment of the present invention provides a cable defect detection method and system based on artificial intelligence, including the following steps:
obtaining a cable target image;
analyzing the connected domains of the cable target image to obtain a plurality of first connected domains corresponding to the cable target image;
obtaining a principal component direction corresponding to each first communication domain corresponding to the cable target image according to the coordinates of each pixel point in each first communication domain; screening each first communication domain according to the main component direction corresponding to each first communication domain to obtain a plurality of second communication domains corresponding to the cable target image;
obtaining a first bending degree corresponding to each second connected domain according to the minimum abscissa in each second connected domain and the maximum abscissa in each second connected domain; carrying out Hough transform on each second connected domain to obtain the number of target highlight points corresponding to each second connected domain;
screening each second connected domain according to the first bending degree corresponding to each second connected domain and the number of the target highlight points corresponding to each second connected domain to obtain each target connected domain corresponding to the cable target image;
obtaining the parallelism between the target connected domains according to the corresponding principal component directions of the target connected domains; and judging whether the cable has strand scattering defects or not according to the parallelism among the target connected domains and the first bending degree corresponding to the target connected domains.
The invention also provides a cable defect detection system based on artificial intelligence, which comprises a memory and a processor, wherein the processor executes a computer program stored in the memory so as to realize the cable defect detection method based on artificial intelligence.
Has the advantages that: according to the method, the principal component direction corresponding to each first connected domain is used as a basis for screening each first connected domain to obtain a second connected domain corresponding to a cable target image; the bending degree corresponding to each second connected domain and the number of the target highlight points corresponding to each second connected domain are used as the basis for screening each second connected domain to obtain each target connected domain corresponding to the cable target image, and the parallelism among the target connected domains and the first bending degree corresponding to each target connected domain are used as the basis for judging whether the cable has strand scattering defects.
Preferably, the method for obtaining the cable target image comprises the following steps:
acquiring a cable side image and a corresponding standard cable side image;
performing semantic segmentation processing on the cable side image to obtain an image only containing the cable side;
carrying out binarization processing on the image only containing the cable side surface to obtain a binarization image corresponding to the image only containing the cable side surface; the pixel value of the pixel point of the outermost wire on the binary image is 1, and the pixel value of the pixel point of the gap area between the outermost wire and the wire is 0; carrying out reverse graying processing on the binary image;
and multiplying the image only containing the cable surface by using the gap area between the conducting wires at the outermost layer in the binarized image after the reverse graying processing as a mask to obtain a cable target image corresponding to the cable side image.
Preferably, the principal component direction corresponding to each first communication domain corresponding to the cable target image is obtained according to the coordinates of each pixel point in each first communication domain; according to the principal component direction corresponding to each first connected domain, the method for screening each first connected domain to obtain a plurality of second connected domains corresponding to the cable target image comprises the following steps:
obtaining a first principal component direction corresponding to each first communication domain by using a principal component analysis method according to the coordinates of each pixel point in each first communication domain;
constructing a coordinate system by taking the pixel point corresponding to the minimum abscissa and the minimum ordinate in the cable target image as an origin, and recording the constructed coordinate system as a target coordinate system;
obtaining an included angle between each first principal component direction and an abscissa axis in the target coordinate system, and recording the included angle between each first principal component direction and the abscissa axis in the target coordinate system as a direction angle corresponding to each first communication domain;
sorting the direction angles, classifying the sorted direction angles by using a multi-threshold segmentation method, and obtaining the number of the direction angles in each category;
obtaining the number of the wires in the standard cable side image according to the standard cable side image; obtaining the number of standard first communication areas corresponding to the standard cable side image according to the number of the conducting wires in the standard cable side image;
judging whether the absolute value of the difference value between the number of the direction angles in each category and the number of the standard first communication domains is larger than a preset difference threshold value or not, and if so, rejecting the corresponding first communication domains;
and marking the remaining first communication domain after the elimination as a second communication domain corresponding to the cable target image.
Preferably, the method for obtaining the first bending degree corresponding to each second connected domain according to the minimum abscissa and the maximum abscissa in each second connected domain includes:
obtaining a first short side and a second short side corresponding to each second connected domain according to the pixel point coordinate corresponding to the minimum abscissa, the pixel point number corresponding to the minimum abscissa, the pixel point coordinate corresponding to the maximum abscissa and the pixel point number corresponding to the maximum abscissa in each second connected domain;
obtaining a first long side and a second long side corresponding to each second connected domain according to the first short side and the second short side corresponding to each second connected domain;
obtaining the slope corresponding to the first principal component direction corresponding to each second connected domain according to the direction angle corresponding to each second connected domain;
obtaining an expression of a first principal component direction straight line corresponding to each second connected domain according to the center point coordinates in each second connected domain and the slope corresponding to the first principal component direction corresponding to each second connected domain; recording the expression of the first principal component direction straight line as a first principal component direction line corresponding to a second connected domain;
drawing a perpendicular line perpendicular to the corresponding first principal component direction line through each pixel point on the first principal component direction line, and marking the perpendicular line as a perpendicular line corresponding to each pixel point on the first principal component direction line;
obtaining an intersection point of a vertical line corresponding to each pixel point on the first principal component direction line and a first long side corresponding to a corresponding second connected domain; recording the intersection point on the first long side as a first intersection point corresponding to each pixel point on a first principal component direction line;
calculating the distance between each pixel point on the first principal component direction line and the corresponding first intersection point; recording the distance between each pixel point on the first principal component direction line and the corresponding first intersection point as a first distance corresponding to each second connected domain; according to the first distance, constructing and obtaining a first distance sequence corresponding to each second connected domain;
selecting the maximum first distance and the minimum first distance in the first distance sequence, and obtaining a first bending rate corresponding to each second connected domain according to the maximum first distance and the minimum first distance;
obtaining an intersection point of a vertical line corresponding to each pixel point on the first principal component direction line and a second long side corresponding to a corresponding second connected domain; recording the intersection point on the second long side as a second intersection point corresponding to each pixel point on the first principal component direction line;
calculating the distance between each pixel point on the first principal component direction line and the corresponding second intersection point, and recording the distance between each pixel point on the first principal component direction line and the corresponding second intersection point as the second distance corresponding to each second connected domain; according to the second distance, constructing and obtaining a second distance sequence corresponding to each second connected domain;
selecting a maximum second distance and a minimum second distance in the second distance sequence, and obtaining a second bending rate corresponding to each second connected domain according to the maximum second distance and the minimum second distance;
and obtaining a first bending degree corresponding to each second connected domain according to the first bending rate and the second bending rate.
Preferably, the method for performing hough transform on each second connected domain to obtain the number of target highlights corresponding to each second connected domain includes:
carrying out binarization processing on each second connected domain corresponding to the cable target image, and carrying out Hough line detection on each second connected domain after binarization processing to obtain the number of highlight points of each second connected domain in Hough space;
counting the number of highlight points corresponding to each abscissa of each second connected domain in the Hough space; summing the number of highlight points corresponding to the same horizontal coordinate in the Hough space among different second connected domains to obtain the horizontal coordinate corresponding to the most highlight points; recording the abscissa corresponding to the maximum highlight point as a target abscissa corresponding to a cable target image, and recording the highlight point corresponding to the target abscissa as a target highlight point;
counting the number of the target highlight points in the Hough space of each second connected domain; and recording the number of the target highlight points of each second connected domain in the Hough space as the number of the target highlight points corresponding to each second connected domain.
Preferably, the method for obtaining each target connected domain corresponding to the cable target image by screening each second connected domain according to the first bending degree corresponding to each second connected domain and the number of the target highlight points corresponding to each second connected domain includes:
obtaining the range corresponding to each second connected domain according to the minimum ordinate and the maximum ordinate in each second connected domain;
judging whether the first bending degree corresponding to each second connected domain, the range corresponding to each second connected domain and the number of the target highlight points corresponding to each second connected domain are in positive correlation or not, if so, retaining the corresponding second connected domain, and otherwise, rejecting the corresponding second connected domain;
marking the remaining second connected domains after the elimination as third connected domains corresponding to the cable target images;
obtaining a second direction corresponding to the cable target image according to the target abscissa;
according to the intersection points of each pixel point on the first principal component direction line corresponding to each third connected domain passing through the second direction, obtaining a second bending rate corresponding to each pixel point on the first principal component direction line of each third connected domain;
and screening the third connected domains according to the range corresponding to each third connected domain and the second bending rate corresponding to each pixel point on the first principal component direction line of each third connected domain to obtain the target connected domain corresponding to the cable target image.
Preferably, the method for obtaining the target connected domain corresponding to the cable target image by screening each third connected domain according to the range corresponding to each third connected domain and the second bending rate corresponding to each pixel point on the first principal component direction line of each third connected domain includes:
obtaining a characteristic value corresponding to each third connected domain according to the range corresponding to each third connected domain and a second bending rate corresponding to each pixel point on the first principal component direction line of each third connected domain;
according to the sequence from large to small of the characteristic values corresponding to the third connected domains, constructing and obtaining a characteristic value sequence corresponding to the cable target image;
constructing and obtaining a target highlight point sequence corresponding to the cable target image according to the sequence of the number of the target highlight points corresponding to each third connected domain from large to small;
and screening the third connected domains according to the sequence of the third connected domains in the characterization value sequence and the sequence of the third connected domains in the target highlight number sequence to obtain the target connected domains corresponding to the cable target image.
Preferably, the parallelism between the target connected domains is obtained according to the main component direction corresponding to the target connected domains; the method for judging whether the cable has the strand scattering defect or not according to the parallelism among the target connected domains and the first bending degree corresponding to the target connected domains comprises the following steps:
according to the direction angle corresponding to each target connected domain, constructing and obtaining a direction angle sequence corresponding to the target connected domain corresponding to the cable target image;
calculating a direction angle variance corresponding to the direction angle sequence corresponding to the target connected domain, and obtaining the parallelism between the target connected domains corresponding to the cable target image according to the direction angle variance;
obtaining a first bending degree mean value corresponding to the cable target image according to the first bending degree corresponding to each target connected domain;
obtaining the strand divergence degree corresponding to the cable target image according to the parallelism among the target connected domains and the first bending degree mean value corresponding to the cable target image;
and judging whether the cable has strand scattering defects or not according to the strand scattering degree.
Drawings
To more clearly illustrate the embodiments of the present invention or the technical solutions and advantages of the prior art, the following description will be made
While the drawings necessary for the embodiment or prior art description are briefly described, it should be apparent that the drawings in the following description are merely examples of the invention and that other drawings may be derived from those drawings by those of ordinary skill in the art without inventive step.
FIG. 1 is a flow chart of an artificial intelligence based cable defect detection method of the present invention;
FIG. 2 is a schematic diagram of a long side corresponding to a second connected domain according to the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be described clearly and completely with reference to the accompanying drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, rather than all embodiments, and all other embodiments obtained by those skilled in the art based on the embodiments of the present invention belong to the protection scope of the embodiments of the present invention.
Unless defined otherwise, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this invention belongs.
The embodiment provides a cable defect detection method based on artificial intelligence, which is described in detail as follows:
as shown in fig. 1, the cable defect detection method based on artificial intelligence comprises the following steps:
step S001, obtaining a cable target image.
In this embodiment, can influence the quality of cable when the strand defect appears scattering in the cable, directly make the cable can not come into use even, so whether detect the cable and scatter the strand defect, and the cable can't detect basically after the cladding whether the strand defect appears scattering in inside cable, consequently need before the cable cladding, after the transposition, detect the strand defect that scatters to the cable. In this embodiment, in the twisting process, the twisting directions of the two adjacent layers of wires are different.
In the embodiment, a camera is arranged to collect side images of the cable after being twisted before being coated, wherein the collected side images of the cable after being twisted before being coated are RGB images; and recording the acquired side image of the cable after twisting before coating as a cable side image, and acquiring a standard cable side image corresponding to the cable side image. In this embodiment, the process of obtaining the standard cable side image corresponding to the cable side image is the prior art, and therefore, is not described in detail.
In the embodiment, the obtained cable side image is subjected to semantic segmentation network to obtain an image only containing the cable side; the semantic segmentation network is of an Encoder-Decoder structure, the semantic segmentation network performs convolution operation through an Encoder to extract features, the output result of the Encoder is a feature map, and the feature map is operated through a Decoder to obtain an image only containing the side face of the cable; the specific training process of the semantic perception network comprises the following steps: acquiring a training sample set, wherein the training sample set comprises a plurality of cable side sample images; marking the pixel point of the cable area in each cable side sample image as 1, marking other areas as 0, inputting each cable side sample image and marking data into a semantic segmentation network without training, performing iterative training by adopting a cross entropy loss function, and continuously updating network parameters; in this embodiment, the specific network structure and training process of the semantic segmentation network are the prior art, and therefore this embodiment is not described in detail.
In the embodiment, the image only containing the cable side surface is subjected to binarization processing to obtain a binarization image corresponding to the image only containing the cable side surface; the pixel value of the pixel point of the outermost wire on the binary image is 1, and the pixel value of the pixel point of the gap area between the outermost wire and the wire is 0; carrying out reverse graying processing on the binary image; multiplying a gap region between the outermost layer of conducting wires in the binarized image after the reverse graying processing and the conducting wires by an image only containing the cable surface as a mask, converting the multiplied image into a histogram, and performing histogram equalization processing on the converted histogram to weaken the influence of illumination on the image; and recording the image after the histogram equalization processing as a cable target image corresponding to the cable side image.
In this embodiment, the binarization processing, the inverse graying processing, the histogram equalization processing, and the process of converting an image into a histogram are all prior art, and therefore this embodiment is not described in detail.
And S002, analyzing the connected domains of the cable target image to obtain a plurality of first connected domains corresponding to the cable target image.
In this embodiment, based on the characteristics of the cable region with the strand scattering defect, each region on the cable target image is screened, the region where the cable conductor is affected by reflection or interfered by other factors is eliminated, and the remaining region after elimination is analyzed to obtain the detection result of the strand scattering defect of the cable.
In this embodiment, performing eight-connected domain analysis on the obtained cable target image, and marking each connected domain on the cable target image obtained after the eight-connected domain analysis as a first connected domain corresponding to the cable target image; each of the obtained first communication domains includes not only the gap regions between the wires at the outermost layer of the cable, but also possibly other communication domains other than the gap regions between the wires at the outermost layer.
Step S003, obtaining the principal component direction corresponding to each first communication domain corresponding to the cable target image according to the coordinates of each pixel point in each first communication domain; and screening the first communication domains according to the main component directions corresponding to the first communication domains to obtain a plurality of second communication domains corresponding to the cable target image.
In this embodiment, each first connection domain may include other connection domains that are not the outermost layer of the wire and the gap region between the wires, and therefore, each first connection domain needs to be primarily screened to obtain a second connection domain corresponding to a cable target image; and taking the obtained second connected domain as the basis for subsequently obtaining a target connected domain corresponding to the cable target image.
In this embodiment, a coordinate system is constructed by using a pixel point corresponding to the minimum abscissa and the minimum ordinate in a cable target image as an origin, the constructed coordinate system is recorded as a target coordinate system, and coordinates of pixels appearing subsequently are coordinates corresponding to the target coordinate system. In this embodiment, other ways of establishing the target coordinate system may also be set according to different requirements, for example, a coordinate system may also be established by using a pixel point corresponding to the maximum abscissa and the maximum ordinate in the cable target image as an origin.
In this embodiment, for the coordinates of each pixel point in each first communication domain, a PCA algorithm is used to obtain principal component directions of the coordinates of each pixel point corresponding to each first communication domain, and since the coordinates are 2-dimensional data, 2 principal component directions can be obtained, each principal component direction is a 2-dimensional unit vector, and each principal component direction corresponds to a feature value; the principal component direction with the largest eigenvalue obtained is taken as the first principal component direction, that is, the first principal component direction corresponding to each first connected domain is obtained.
In this embodiment, an included angle between a first principal component direction corresponding to each first communication domain and an abscissa axis in a target coordinate system is obtained, and an included angle between the first principal component direction corresponding to each first communication domain and the abscissa axis in the target coordinate system is recorded as a direction angle corresponding to each first communication domain; sorting the direction angles corresponding to the first communication domains in descending order, recording the sorted result as a direction angle sequence corresponding to the cable target image, classifying the sorted direction angle sequence by using a multi-threshold segmentation method, and obtaining the number of the direction angles in each class, wherein the number of the direction angles in each class is also the number of the first principal component directions in each class, namely the number of the first communication domains.
As another embodiment, the direction angle corresponding to each first communication field may be obtained by another method according to the requirement, for example, an angle between the first principal component direction corresponding to each first communication field and the ordinate axis in the target coordinate system may be obtained, and an angle between the first principal component direction corresponding to each first communication field and the ordinate axis in the target coordinate system may be defined as the direction angle corresponding to each first communication field.
In this embodiment, because the number of wires appearing in the standard cable side image is determined, and the number of wires appearing in the standard cable side image is recorded as m, the number of standard first communication domains corresponding to the standard cable side image is obtained as m-1 according to the number of wires in the standard cable side image; calculating the absolute value of the difference between the number of the direction angles in each category corresponding to the direction angle sequence after multi-threshold segmentation and the number of the standard first communication domains, judging whether the absolute value of the difference between the number of the direction angles in each category corresponding to the direction angle sequence after multi-threshold segmentation and the number of the standard first communication domains is greater than a preset difference threshold, and if so, rejecting the first communication domains corresponding to the direction angles greater than the preset difference threshold; and marking the remaining first communication domain after the elimination as a second communication domain corresponding to the cable target image. For example, the sorted direction angle sequences [ 10124559606061616296123 ] are classified by a multi-threshold segmentation method to obtain direction angle subsequences [ (10,15), (45), (596060616162), (96), (123) ] corresponding to the direction angle sequences, wherein the direction angles in one () form one direction angle subsequence, that is, the direction angles in the same small bracket are one category obtained after multi-threshold segmentation, if the standard first connected domain number is 5 and the size of a preset difference threshold is 1, the first connected domains corresponding to the categories (10,15), (45), (96) and (123) are removed, and each first connected domain in the remaining categories (596060616162) after removal is regarded as a second connected domain. In this embodiment, the size of the preset difference threshold needs to be set according to actual conditions.
Step S004, obtaining a first bending degree corresponding to each second connected domain according to the minimum abscissa in each second connected domain and the maximum abscissa in each second connected domain; and carrying out Hough transform on each second connected domain to obtain the number of the target highlight points corresponding to each second connected domain.
In this embodiment, the above process is only the primary screening of each area in the cable target image, and the primary screening can only eliminate interference of a few factors, so that each second connected domain is further analyzed to obtain the first bending degree corresponding to each second connected domain and the number of target high-brightness points corresponding to each second connected domain; and taking the first bending degree corresponding to each second connected domain and the number of the target highlight points corresponding to each second connected domain as the basis for screening the second connected domains subsequently.
(a) The specific process of obtaining the first bending degree corresponding to each second connected domain according to the minimum abscissa in each second connected domain and the maximum abscissa in each second connected domain is as follows:
in this embodiment, when the local region of cable appears the straggling defect, the regional outermost wire of cable outside that appears the straggling defect can be more crooked than normal time, consequently with the first crooked degree that each second connected domain corresponds as the basis that follow-up second connected domain carries out the screening.
In this embodiment, the positions of the two short sides corresponding to each second connected domain are determined according to the pixel point coordinate corresponding to the minimum abscissa and the pixel point coordinate corresponding to the maximum abscissa in each second connected domain, and the lengths of the two short sides corresponding to each second connected domain are determined according to the number of the pixel points corresponding to the minimum abscissa and the number of the pixel points corresponding to the maximum abscissa in each second connected domain; obtaining two short sides corresponding to each second connected domain according to the positions of the two short sides corresponding to each second connected domain and the lengths of the two short sides corresponding to each second connected domain; recording two short sides corresponding to each second connected domain as a first short side and a second short side corresponding to each second connected domain, wherein the number of pixel points corresponding to the minimum abscissa and the number of pixel points corresponding to the maximum abscissa are the length of the first short side corresponding to each second connected domain and the length of the corresponding second short side respectively; obtaining two long sides corresponding to each second connected domain according to the first short side and the second short side corresponding to each second connected domain, and marking the two long sides corresponding to each second connected domain as the first long side and the second long side corresponding to each second connected domain, as shown in fig. 2, 1, 2, 3, and 4 are pixel points corresponding to the minimum abscissa in a certain second connected domain, 5, 6, and 7 are pixel points corresponding to the maximum abscissa in the second connected domain, the pixel points, the line segment formed by the pixel points 1, 2, 3, and 4 is the first short side, the line segment formed by the pixel points 5, 6, and 7 is the second short side, the line segment formed by the pixel points 1 and 5 is the first long side, and the line segment formed by the pixel points 4 and 7 is the second long side.
In this embodiment, the slope corresponding to the first principal component direction corresponding to each second connected domain is calculated according to the direction angle corresponding to each second connected domain; calculating the slope corresponding to the first principal component direction corresponding to each second connected domain according to the following formula:
Figure 726322DEST_PATH_IMAGE002
wherein the content of the first and second substances,
Figure DEST_PATH_IMAGE003
the slope corresponding to the first principal component direction corresponding to the second connected domain,
Figure 135438DEST_PATH_IMAGE004
is as follows
Figure DEST_PATH_IMAGE005
And the direction angle corresponding to the second connected domain.
In this embodiment, a mean value of abscissa of each pixel point corresponding to each second connected domain and a mean value of ordinate of each pixel point corresponding to each second connected domain are calculated, and coordinates corresponding to the mean value of abscissa of each pixel point corresponding to each second connected domain and the mean value of ordinate of each pixel point corresponding to each second connected domain are recorded as coordinates of a center point corresponding to each second connected domain; determining an expression of a first principal component direction straight line corresponding to each second connected domain according to the slope corresponding to the first principal component direction corresponding to each second connected domain and the center point coordinate corresponding to each second connected domain; and recording the expression of the first principal component direction straight line corresponding to each second connected domain as the first principal component direction line corresponding to the second connected domain.
In this embodiment, a perpendicular line perpendicular to the corresponding first principal component direction line is drawn through each pixel point on the first principal component direction line corresponding to each second connected domain, and the obtained perpendicular line is recorded as a perpendicular line corresponding to each pixel point on the first principal component direction line corresponding to each second connected domain; acquiring an intersection point of a vertical line corresponding to each pixel point on the first principal component direction line corresponding to each second connected domain and the first long side corresponding to the corresponding second connected domain; recording the obtained intersection point on the first long side as a first intersection point corresponding to each pixel point on the first principal component direction line; calculating the distance between each pixel point on the first principal component direction line corresponding to each second connected domain and the corresponding first intersection point, and recording the distance between each pixel point on the first principal component direction line corresponding to each second connected domain and the corresponding first intersection point as the first distance corresponding to each second connected domain; according to the first distance corresponding to each second connected domain, constructing and obtaining a first distance sequence corresponding to each second connected domain; and selecting the maximum first distance and the minimum first distance in the first distance sequence corresponding to each second connected domain, calculating the ratio of the maximum first distance and the minimum first distance corresponding to each second connected domain, and recording the obtained ratio of the maximum first distance and the minimum first distance corresponding to each second connected domain as the first bending rate corresponding to each second connected domain.
In this embodiment, an intersection point of a perpendicular line corresponding to each pixel point on the first principal component direction line corresponding to each second connected domain and a second long side corresponding to the corresponding second connected domain is obtained; recording the obtained intersection point on the second long side as a second intersection point corresponding to each pixel point on the first principal component direction line; calculating the distance between each pixel point on the first principal component direction line corresponding to each second connected domain and the corresponding second intersection point, and recording the distance between each pixel point on the first principal component direction line corresponding to each second connected domain and the corresponding second intersection point as the second distance corresponding to each second connected domain; according to the second distance corresponding to each second connected domain, constructing and obtaining a second distance sequence corresponding to each second connected domain; and selecting the maximum second distance and the minimum second distance in the second distance sequence corresponding to each second connected domain, calculating the ratio of the maximum second distance and the minimum second distance corresponding to each second connected domain, and recording the obtained ratio of the maximum second distance and the minimum second distance corresponding to each second connected domain as the second bending rate corresponding to each second connected domain.
In this embodiment, the first bending degree corresponding to each second connected domain is constructed and obtained according to the obtained first bending rate corresponding to each second connected domain and the obtained second bending rate corresponding to each second connected domain (a: (a)
Figure DEST_PATH_IMAGE007
,
Figure DEST_PATH_IMAGE009
) Wherein, in the step (A),
Figure 767145DEST_PATH_IMAGE007
is as follows
Figure 728148DEST_PATH_IMAGE005
A first curvature corresponding to the second connected component,
Figure DEST_PATH_IMAGE011
is as follows
Figure 641877DEST_PATH_IMAGE005
And a second curvature corresponding to the second connected domain.
(b) Performing hough transform on each second connected domain to obtain the number of target highlight points corresponding to each second connected domain:
in this embodiment, when a local area of the cable has a strand spreading defect, a distance between the outermost wires of the cable and the wires becomes larger, so that an area of the wire adjacent to the outermost layer is also seen to become larger, the wire adjacent to the outermost layer is referred to as a second layer, the same wire in the second layer is divided into a plurality of parts by the outermost wire, that is, a gap between two adjacent wires in the second layer is also divided into a plurality of parts by the gap between two adjacent wires in the outermost layer, but directions between different parts are the same, that is, slopes are the same, a direction in which the wires in the second layer are twisted is different from a direction in which the outermost wires are twisted, and then the number of target highlight points corresponding to each second connected domain is obtained by analyzing the gap area between the wires in the second layer.
In this embodiment, each second connected domain corresponding to the cable target image is subjected to binarization processing to obtain a binarized image corresponding to each second connected domain, where a pixel value of a pixel point in a lighter-colored region in each second connected domain on the binarized image corresponding to each second connected domain is 0, that is, the pixel value is also 0The pixel value of the pixel point of the second layer of wire is 0, the pixel value of the pixel point of the darker area in each second connected domain is 1, namely the pixel value of the pixel point of the gap area between the second layer of wire and the wire is 1; in the embodiment, hough line detection is performed on the binary images corresponding to the second connected domains, and the number of highlight points corresponding to each abscissa in the hough space in each second connected domain is counted; summing the number of highlight points corresponding to the same horizontal coordinate in the Hough space among different second connected domains to obtain the horizontal coordinate corresponding to the most highlight points; marking the abscissa corresponding to the maximum highlight point as a target abscissa corresponding to the cable target image, and marking the highlight point corresponding to the target abscissa as a target highlight point; for example, the number of second connected components is 2, wherein the abscissa of one second connected component
Figure 323525DEST_PATH_IMAGE012
The number of corresponding highlight points is 4, abscissa
Figure DEST_PATH_IMAGE013
The number of corresponding highlight points is 2, and the abscissa in the other second connected domain
Figure 763734DEST_PATH_IMAGE012
The number of corresponding highlight points is 2, abscissa
Figure 9820DEST_PATH_IMAGE013
The number of corresponding highlight points is 2, the abscissa
Figure 4320DEST_PATH_IMAGE012
And the target abscissa corresponds to the cable target image.
In this embodiment, a target abscissa corresponding to the cable target image is an abscissa in the hough space, the abscissa in the hough space is an angle, a target highlight corresponding to the target abscissa is a gap between the wires in the second layer, the angle corresponding to the target abscissa is recorded as a direction value of the gap between the wires in the second layer, and is also a direction value corresponding to the target highlight in the second layer, and the direction value of the gap between the wires in the second layer is recorded as a second direction corresponding to the cable target image.
And S005, screening the second connected domains according to the first bending degree corresponding to the second connected domains and the number of the target highlight points corresponding to the second connected domains to obtain the target connected domains corresponding to the cable target image.
In this embodiment, each second connected domain is further screened according to the first bending degree corresponding to each second connected domain and the number of the target highlight points corresponding to each second connected domain, the remaining second connected domains after screening are analyzed to obtain each target connected domain corresponding to the cable target image, and each target connected domain corresponding to the cable target image is used as a basis for subsequently analyzing the divergence degree corresponding to the cable target image.
In the embodiment, the number of the target highlight points of each second connected domain in the Hough space is counted; recording the number of the target highlight points of each second connected domain in the Hough space as the number of the target highlight points corresponding to each second connected domain; in this embodiment, a difference between the maximum ordinate and the minimum ordinate in each second connected domain is calculated, and the difference between the maximum ordinate and the minimum ordinate in each second connected domain is recorded as a pole difference corresponding to each second connected domain; in this embodiment, when the larger the first bending degree and the corresponding range corresponding to the second connected component are, the larger the splitting degree of the second connected component is, the more the wires in the second layer are detected, that is, the more the number of the target highlight points corresponding to the second connected component is; therefore, whether the first bending degree corresponding to each second connected domain, the range corresponding to each second connected domain and the number of the target highlight points corresponding to each second connected domain are in a positive correlation or not is judged, if yes, the corresponding second connected domain is reserved, and otherwise, the corresponding second connected domain is removed.
In this embodiment, the remaining second connected domains after the elimination are marked as third connected domains, and a characterization value corresponding to each third connected domain is obtained according to the range corresponding to each third connected domain and the second direction corresponding to the cable target image; and taking the characterization value corresponding to each third connected domain and the number of the target highlight points in each third connected domain as the basis for further screening the third connected domains.
In this embodiment, the second direction corresponding to the cable target image passes through each pixel point on the first principal component direction line corresponding to each third connected domain, and the second direction of each pixel point on the first principal component direction line corresponding to each third connected domain is recorded as the second direction corresponding to each pixel point on the first principal component direction line corresponding to each third connected domain; obtaining two intersection points of the second direction corresponding to each pixel point on the first principal component direction line corresponding to each third connected domain and the corresponding third connected domain boundary, and recording the two intersection points of the second direction corresponding to each pixel point on the first principal component direction line corresponding to each third connected domain and the corresponding third connected domain boundary as the third intersection point and the fourth intersection point corresponding to each pixel point on the first principal component direction line corresponding to each third connected domain; calculating the distance between a third intersection point corresponding to each pixel point on the first principal component direction line corresponding to each third connected domain and the corresponding pixel point, and recording the distance between the third intersection point corresponding to each pixel point on the first principal component direction line corresponding to each third connected domain and the corresponding pixel point as the third distance corresponding to each pixel point on the first principal component direction line corresponding to each third connected domain; calculating the distance between a corresponding fourth intersection point and a corresponding pixel point corresponding to each pixel point on the first principal component direction line corresponding to each third connected domain, and recording the distance between the corresponding fourth intersection point and the corresponding pixel point corresponding to each pixel point on the first principal component direction line corresponding to each third connected domain as the fourth distance corresponding to each pixel point on the first principal component direction line corresponding to each third connected domain; summing the third distances corresponding to the pixel points on the first principal component direction lines corresponding to the third connected domains and the corresponding fourth distances, and recording the result after summing as a second bending rate corresponding to the pixel points on the first principal component direction lines of the third connected domains; and summing the second bending rates corresponding to the pixel points on the first principal component direction line of each third connected domain, then calculating an average value, and recording the average value as the second bending degree corresponding to each third connected domain.
In this embodiment, a characteristic value corresponding to each third connected domain is obtained according to the second bending degree corresponding to each third connected domain and the range corresponding to each third connected domain; the second bending degree corresponding to each third connected domain and the range corresponding to each third connected domain form a positive correlation with the characterization value corresponding to each third connected domain; and calculating the corresponding characteristic value of each third connected domain according to the following formula:
Figure DEST_PATH_IMAGE015
wherein the content of the first and second substances,
Figure 755239DEST_PATH_IMAGE016
is as follows
Figure DEST_PATH_IMAGE017
The token value corresponding to the third connected component,
Figure 925320DEST_PATH_IMAGE018
is as follows
Figure 228125DEST_PATH_IMAGE017
The third connected domain corresponds to a very poor,
Figure DEST_PATH_IMAGE019
is as follows
Figure 850868DEST_PATH_IMAGE017
A second degree of curvature corresponding to the third connected components; the larger the representation value corresponding to each third connected domain is, the larger the gap area between the wires of the outermost layer of the cable is, the more the wires of the second layer of the cable are detected, that is, the larger the number of the corresponding target highlight points corresponding to the third connected domain is.
In this embodiment, according to the descending order of the token values corresponding to the third connected domains, a token value sequence corresponding to the cable target image is constructed and obtained, the order of each third connected domain in the token value sequence is obtained, and the order of each third connected domain in the token value sequence is recorded as a first order corresponding to each third connected domain; according to the sequence of the target highlight number corresponding to each third connected domain from large to small, constructing and obtaining a target highlight number sequence corresponding to the cable target image, obtaining the sequence of each third connected domain in the target highlight number sequence, and recording the sequence of each third connected domain in the target highlight number sequence as a second sequence corresponding to each third connected domain; judging whether the absolute value of the difference value between the first order corresponding to each third connected domain and the corresponding second order is greater than a preset order difference value threshold value or not, and if so, rejecting the corresponding third connected domain; in this embodiment, the preset sequence difference threshold needs to be set according to an actual situation; for example, if the order 5 of a third connected component in the token value sequence and the order 1 of the target highlight sequence have a predetermined order difference threshold of 2, and the absolute value of the order difference between the third connected component in the token value sequence and the target highlight sequence is greater than the predetermined order difference threshold, the third connected component is rejected. In this embodiment, the third connected domain remaining after the elimination is recorded as a target connected domain corresponding to the cable target image.
As another embodiment, different methods for constructing the token value sequence and the target highlight point sequence may be set according to different requirements, for example, a token value sequence corresponding to the cable target image may be constructed and obtained according to a descending order of token values corresponding to the third connected domains, and a target highlight point sequence corresponding to the cable target image may be constructed and obtained according to a descending order of the number of target highlight points corresponding to the third connected domains.
Step S006, obtaining the parallelism between the target connected domains according to the main component directions corresponding to the target connected domains; and judging whether the cable has strand scattering defects or not according to the parallelism among the target connected domains and the first bending degree corresponding to the target connected domains.
In this embodiment, the divergence degree corresponding to the cable target image is obtained by analyzing the parallelism between the target connected domains and the first bending degree corresponding to each target connected domain, and the divergence degree corresponding to the cable target image is used as a basis for judging whether the cable has a divergence defect.
In this embodiment, a direction angle sequence corresponding to a target connected domain corresponding to a cable target image is constructed and obtained according to a direction angle corresponding to each target connected domain; calculating the direction angle variance corresponding to the direction angle sequence corresponding to the target connected domain, and obtaining the parallelism between the target connected domains corresponding to the cable target image according to the direction angle variance corresponding to the direction angle sequence corresponding to the target connected domain; the direction angle variance corresponding to the direction angle sequence corresponding to the target connected domain and the parallelism between the target connected domains corresponding to the cable target images form a negative correlation; calculating the parallelism between the target connected domains corresponding to the cable target images according to the following formula:
Figure DEST_PATH_IMAGE021
wherein the content of the first and second substances,
Figure 904012DEST_PATH_IMAGE022
for parallelism between the target connected domains corresponding to the cable target images,
Figure DEST_PATH_IMAGE023
the direction angle variance corresponding to the direction angle sequence corresponding to the target connected domain; the larger the direction angle variance corresponding to the direction angle sequence corresponding to the target connected domain is, the less parallel the target connected domains corresponding to the cable target image are, and the smaller the parallelism between the target connected domains corresponding to the cable target image is, the more serious the strand scattering defect occurs in the cable region corresponding to the cable target image is.
In the embodiment, the first bending degrees corresponding to the target connected domains are summed and then averaged to obtain a first bending degree average value corresponding to the cable target image; obtaining the strand divergence degree corresponding to the cable target image according to the first bending degree mean value corresponding to the cable target image and the parallelism between the target connected domains corresponding to the cable target image; the mean value of the first bending degree corresponding to the cable target image and the divergence degree corresponding to the cable target image form a positive correlation relationship, and the parallelism between the target connected domains corresponding to the cable target image and the divergence degree corresponding to the cable target image form a negative correlation relationship; calculating the corresponding divergence degree of the cable target image according to the following formula:
Figure DEST_PATH_IMAGE025
wherein the content of the first and second substances,
Figure 725338DEST_PATH_IMAGE026
for the degree of divergence corresponding to the cable target image,
Figure 933465DEST_PATH_IMAGE022
for parallelism between the target connected domains corresponding to the cable target images,
Figure DEST_PATH_IMAGE027
the first bending degree mean value corresponding to the cable target image;
Figure 43504DEST_PATH_IMAGE026
the larger the size, the more serious the strand scattering defect appears in the cable area corresponding to the cable target image.
In this embodiment, whether the divergence degree corresponding to the cable target image is greater than a preset divergence degree threshold value or not is judged, and if yes, the outer-layer wires corresponding to the target connected domain corresponding to the cable target image are repaired. In this embodiment, the preset divergence threshold value needs to be set according to actual conditions.
Has the advantages that: in this embodiment, the principal component direction corresponding to each first connected domain is used as a basis for screening each first connected domain to obtain a second connected domain corresponding to the cable target image; the bending degree corresponding to each second connected domain and the number of the target highlight points corresponding to each second connected domain are used as the basis for screening each second connected domain to obtain each target connected domain corresponding to the cable target image, the parallelism among the target connected domains and the first bending degree corresponding to each target connected domain are used as the basis for judging whether the cable has strand scattering defects or not, in the embodiment, each area on the cable target image is screened through the characteristics of the strand scattering defect area, the interference of the reflection of the cable strand material or other factors on the strand scattering defect area detection is filtered, and the accuracy of the cable strand scattering defect detection is improved.
The artificial intelligence-based cable defect detection system of the embodiment comprises a memory and a processor, wherein the processor executes a computer program stored in the memory to realize the artificial intelligence-based cable defect detection method.
It should be noted that the order of the above-mentioned embodiments of the present invention is merely for description and does not represent the merits of the embodiments, and in some cases, actions or steps recited in the claims may be executed in an order different from the order of the embodiments and still achieve desirable results.

Claims (9)

1. A cable defect detection method based on artificial intelligence is characterized by comprising the following steps:
obtaining a cable target image;
analyzing the connected domains of the cable target image to obtain a plurality of first connected domains corresponding to the cable target image;
obtaining a principal component direction corresponding to each first communication domain corresponding to the cable target image according to the coordinates of each pixel point in each first communication domain; screening each first communication domain according to the main component direction corresponding to each first communication domain to obtain a plurality of second communication domains corresponding to the cable target image;
obtaining a first bending degree corresponding to each second connected domain according to the minimum abscissa in each second connected domain and the maximum abscissa in each second connected domain; carrying out Hough transform on each second connected domain to obtain the number of target highlight points corresponding to each second connected domain;
screening each second connected domain according to the first bending degree corresponding to each second connected domain and the number of the target highlight points corresponding to each second connected domain to obtain each target connected domain corresponding to the cable target image;
obtaining the parallelism between the target connected domains according to the corresponding principal component directions of the target connected domains; and judging whether the cable has strand scattering defects or not according to the parallelism among the target connected domains and the first bending degree corresponding to the target connected domains.
2. The artificial intelligence based cable defect detection method of claim 1, wherein the method for obtaining the cable target image comprises:
acquiring a cable side image and a corresponding standard cable side image;
performing semantic segmentation processing on the cable side image to obtain an image only containing the cable side;
carrying out binarization processing on the image only containing the cable side surface to obtain a binarization image corresponding to the image only containing the cable side surface; the pixel value of the pixel point of the outermost wire on the binary image is 1, and the pixel value of the pixel point of the gap area between the outermost wire and the wire is 0; carrying out reverse graying processing on the binary image;
and multiplying the image only containing the cable surface by using the gap area between the conducting wires at the outermost layer in the binarized image after the reverse graying processing as a mask to obtain a cable target image corresponding to the cable side image.
3. The method according to claim 2, wherein the principal component direction corresponding to each first communication domain corresponding to the cable target image is obtained according to the coordinates of each pixel point in each first communication domain; according to the principal component direction corresponding to each first connected domain, the method for screening each first connected domain to obtain a plurality of second connected domains corresponding to the cable target image comprises the following steps:
obtaining a first principal component direction corresponding to each first communication domain by using a principal component analysis method according to the coordinates of each pixel point in each first communication domain;
constructing a coordinate system by taking the pixel point corresponding to the minimum abscissa and the minimum ordinate in the cable target image as an origin, and recording the constructed coordinate system as a target coordinate system;
obtaining an included angle between each first principal component direction and an abscissa axis in the target coordinate system, and recording the included angle between each first principal component direction and the abscissa axis in the target coordinate system as a direction angle corresponding to each first communication domain;
sorting the direction angles, classifying the sorted direction angles by using a multi-threshold segmentation method, and obtaining the number of the direction angles in each category;
obtaining the number of the wires in the standard cable side image according to the standard cable side image; obtaining the number of standard first communication areas corresponding to the standard cable side image according to the number of the conducting wires in the standard cable side image;
judging whether the absolute value of the difference value between the number of the direction angles in each category and the number of the standard first communication domains is larger than a preset difference threshold value or not, and if so, rejecting the corresponding first communication domains;
and marking the remaining first communication domain after the elimination as a second communication domain corresponding to the cable target image.
4. The method for detecting cable defects based on artificial intelligence as claimed in claim 3, wherein the method for obtaining the first bending degree corresponding to each second connected domain according to the minimum abscissa in each second connected domain and the maximum abscissa in each second connected domain comprises:
obtaining a first short side and a second short side corresponding to each second connected domain according to the pixel point coordinate corresponding to the minimum abscissa, the pixel point number corresponding to the minimum abscissa, the pixel point coordinate corresponding to the maximum abscissa and the pixel point number corresponding to the maximum abscissa in each second connected domain;
obtaining a first long side and a second long side corresponding to each second connected domain according to the first short side and the second short side corresponding to each second connected domain;
obtaining the slope corresponding to the first principal component direction corresponding to each second connected domain according to the direction angle corresponding to each second connected domain;
obtaining an expression of a first principal component direction straight line corresponding to each second connected domain according to the center point coordinates in each second connected domain and the slope corresponding to the first principal component direction corresponding to each second connected domain; recording the expression of the first principal component direction straight line as a first principal component direction line corresponding to a second connected domain;
drawing a perpendicular line perpendicular to the corresponding first principal component direction line through each pixel point on the first principal component direction line, and marking the perpendicular line as a perpendicular line corresponding to each pixel point on the first principal component direction line;
obtaining an intersection point of a vertical line corresponding to each pixel point on the first principal component direction line and a first long side corresponding to a corresponding second connected domain; recording the intersection point on the first long side as a first intersection point corresponding to each pixel point on a first principal component direction line;
calculating the distance between each pixel point on the first principal component direction line and the corresponding first intersection point; recording the distance between each pixel point on the first principal component direction line and the corresponding first intersection point as a first distance corresponding to each second connected domain; according to the first distance, constructing and obtaining a first distance sequence corresponding to each second connected domain;
selecting the maximum first distance and the minimum first distance in the first distance sequence, and obtaining a first bending rate corresponding to each second connected domain according to the maximum first distance and the minimum first distance;
obtaining an intersection point of a vertical line corresponding to each pixel point on the first principal component direction line and a second long side corresponding to a corresponding second connected domain; recording the intersection point on the second long side as a second intersection point corresponding to each pixel point on the first principal component direction line;
calculating the distance between each pixel point on the first principal component direction line and the corresponding second intersection point, and recording the distance between each pixel point on the first principal component direction line and the corresponding second intersection point as the second distance corresponding to each second connected domain; according to the second distance, constructing and obtaining a second distance sequence corresponding to each second connected domain;
selecting a maximum second distance and a minimum second distance in the second distance sequence, and obtaining a second bending rate corresponding to each second connected domain according to the maximum second distance and the minimum second distance;
and obtaining a first bending degree corresponding to each second connected domain according to the first bending rate and the second bending rate.
5. The method for detecting the cable defect based on the artificial intelligence as claimed in claim 2, wherein the method for obtaining the number of target highlights corresponding to each second connected domain by performing hough transform on each second connected domain comprises:
carrying out binarization processing on each second connected domain corresponding to the cable target image, and carrying out Hough line detection on each second connected domain after binarization processing to obtain the number of highlight points of each second connected domain in Hough space;
counting the number of highlight points corresponding to each abscissa of each second connected domain in the Hough space; summing the number of highlight points corresponding to the same horizontal coordinate in the Hough space among different second connected domains to obtain the horizontal coordinate corresponding to the most highlight points; recording the abscissa corresponding to the maximum highlight point as a target abscissa corresponding to a cable target image, and recording the highlight point corresponding to the target abscissa as a target highlight point;
counting the number of the target highlight points in the Hough space of each second connected domain; and recording the number of the target highlight points of each second connected domain in the Hough space as the number of the target highlight points corresponding to each second connected domain.
6. The method for detecting cable defects based on artificial intelligence as claimed in claim 5, wherein the method for screening each second connected domain according to the first bending degree corresponding to each second connected domain and the number of the target highlight points corresponding to each second connected domain to obtain each target connected domain corresponding to the cable target image comprises:
obtaining the range corresponding to each second connected domain according to the minimum ordinate and the maximum ordinate in each second connected domain;
judging whether the first bending degree corresponding to each second connected domain, the range corresponding to each second connected domain and the number of the target highlight points corresponding to each second connected domain are in positive correlation or not, if so, retaining the corresponding second connected domain, and otherwise, rejecting the corresponding second connected domain;
marking the remaining second connected domains after the elimination as third connected domains corresponding to the cable target images;
obtaining a second direction corresponding to the cable target image according to the target abscissa;
according to the intersection points of each pixel point on the first principal component direction line corresponding to each third connected domain passing through the second direction, obtaining a second bending rate corresponding to each pixel point on the first principal component direction line of each third connected domain;
and screening the third connected domains according to the range corresponding to each third connected domain and the second bending rate corresponding to each pixel point on the first principal component direction line of each third connected domain to obtain the target connected domain corresponding to the cable target image.
7. The method for detecting cable defects based on artificial intelligence as claimed in claim 6, wherein the method for obtaining the target connected domain corresponding to the cable target image by screening the third connected domains according to the range corresponding to the third connected domains and the second curvature corresponding to each pixel point on the first principal component direction line of the third connected domains comprises:
obtaining a characteristic value corresponding to each third connected domain according to the range corresponding to each third connected domain and a second bending rate corresponding to each pixel point on the first principal component direction line of each third connected domain;
according to the sequence from large to small of the characteristic values corresponding to the third connected domains, constructing and obtaining a characteristic value sequence corresponding to the cable target image;
constructing and obtaining a target highlight point sequence corresponding to the cable target image according to the sequence of the number of the target highlight points corresponding to each third connected domain from large to small;
and screening the third connected domains according to the sequence of the third connected domains in the characterization value sequence and the sequence of the third connected domains in the target highlight number sequence to obtain the target connected domains corresponding to the cable target image.
8. The method according to claim 3, wherein the parallelism between the target connected domains is obtained according to the principal component direction corresponding to each target connected domain; the method for judging whether the cable has the strand scattering defect or not according to the parallelism among the target connected domains and the first bending degree corresponding to the target connected domains comprises the following steps:
according to the direction angle corresponding to each target connected domain, constructing and obtaining a direction angle sequence corresponding to the target connected domain corresponding to the cable target image;
calculating a direction angle variance corresponding to the direction angle sequence corresponding to the target connected domain, and obtaining the parallelism between the target connected domains corresponding to the cable target image according to the direction angle variance;
obtaining a first bending degree mean value corresponding to the cable target image according to the first bending degree corresponding to each target connected domain;
obtaining the strand divergence degree corresponding to the cable target image according to the parallelism among the target connected domains and the first bending degree mean value corresponding to the cable target image;
and judging whether the cable has strand scattering defects or not according to the strand scattering degree.
9. An artificial intelligence based cable defect detection system comprising a memory and a processor, wherein the processor executes a computer program stored in the memory to implement an artificial intelligence based cable defect detection method according to any one of claims 1 to 8.
CN202111527503.0A 2021-12-15 2021-12-15 Cable defect detection method and system based on artificial intelligence Active CN113920122B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111527503.0A CN113920122B (en) 2021-12-15 2021-12-15 Cable defect detection method and system based on artificial intelligence

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111527503.0A CN113920122B (en) 2021-12-15 2021-12-15 Cable defect detection method and system based on artificial intelligence

Publications (2)

Publication Number Publication Date
CN113920122A true CN113920122A (en) 2022-01-11
CN113920122B CN113920122B (en) 2022-03-04

Family

ID=79249026

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111527503.0A Active CN113920122B (en) 2021-12-15 2021-12-15 Cable defect detection method and system based on artificial intelligence

Country Status (1)

Country Link
CN (1) CN113920122B (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114299406A (en) * 2022-03-07 2022-04-08 山东鹰联光电科技股份有限公司 Optical fiber cable line inspection method based on unmanned aerial vehicle aerial photography
CN114937039A (en) * 2022-07-21 2022-08-23 阿法龙(山东)科技有限公司 Intelligent detection method for steel pipe defects
CN115100202A (en) * 2022-08-25 2022-09-23 聊城市宏伟电器有限公司 Cable quality detection method based on image processing
CN115588139A (en) * 2022-11-22 2023-01-10 东北电力大学 Power grid safety intelligent cruise detection method
CN117173166A (en) * 2023-11-02 2023-12-05 江苏裕荣光电科技有限公司 Optical cable surface defect detection method

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103886610A (en) * 2014-04-05 2014-06-25 东北电力大学 Image type defect detecting method for insulator
US20150154467A1 (en) * 2013-12-04 2015-06-04 Mitsubishi Electric Research Laboratories, Inc. Method for Extracting Planes from 3D Point Cloud Sensor Data
CN106373123A (en) * 2016-09-21 2017-02-01 哈尔滨工业大学 K_tSL central clustering algorithm-based industrial component surface defect detection method
CN107506768A (en) * 2017-10-11 2017-12-22 电子科技大学 A kind of stranded recognition methods of transmission line wire based on full convolutional neural networks
CN107808378A (en) * 2017-11-20 2018-03-16 浙江大学 Complicated structure casting latent defect detection method based on vertical co-ordination contour feature
CN107886493A (en) * 2016-09-29 2018-04-06 成都思晗科技股份有限公司 A kind of wire share split defect inspection method of transmission line of electricity
CN108734689A (en) * 2018-02-07 2018-11-02 西安工程大学 A kind of conducting wire broken lot detection method based on region growing
WO2021228194A1 (en) * 2020-05-15 2021-11-18 上海非夕机器人科技有限公司 Cable detection method, robot and storage device
CN113744270A (en) * 2021-11-05 2021-12-03 南京市特种设备安全监督检验研究院 Unmanned aerial vehicle visual detection and identification method for crane complex steel structure surface defects

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20150154467A1 (en) * 2013-12-04 2015-06-04 Mitsubishi Electric Research Laboratories, Inc. Method for Extracting Planes from 3D Point Cloud Sensor Data
CN103886610A (en) * 2014-04-05 2014-06-25 东北电力大学 Image type defect detecting method for insulator
CN106373123A (en) * 2016-09-21 2017-02-01 哈尔滨工业大学 K_tSL central clustering algorithm-based industrial component surface defect detection method
CN107886493A (en) * 2016-09-29 2018-04-06 成都思晗科技股份有限公司 A kind of wire share split defect inspection method of transmission line of electricity
CN107506768A (en) * 2017-10-11 2017-12-22 电子科技大学 A kind of stranded recognition methods of transmission line wire based on full convolutional neural networks
CN107808378A (en) * 2017-11-20 2018-03-16 浙江大学 Complicated structure casting latent defect detection method based on vertical co-ordination contour feature
CN108734689A (en) * 2018-02-07 2018-11-02 西安工程大学 A kind of conducting wire broken lot detection method based on region growing
WO2021228194A1 (en) * 2020-05-15 2021-11-18 上海非夕机器人科技有限公司 Cable detection method, robot and storage device
CN113744270A (en) * 2021-11-05 2021-12-03 南京市特种设备安全监督检验研究院 Unmanned aerial vehicle visual detection and identification method for crane complex steel structure surface defects

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
JIAN LI 等: "From edges to linear features: A PCA and graph based approach", 《2010 IEEE INTERNATIONAL CONFERENCE ON ACOUSTICS, SPEECH AND SIGNAL PROCESSING》 *
叶震 等: "一种获取焊缝偏差的图像处理方法", 《上海交通大学学报 》 *
贺慧: "基于机器视觉的表贴元件缺陷检测与分类研究", 《中国优秀硕士学位论文全文数据库信息科技辑》 *

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114299406A (en) * 2022-03-07 2022-04-08 山东鹰联光电科技股份有限公司 Optical fiber cable line inspection method based on unmanned aerial vehicle aerial photography
CN114299406B (en) * 2022-03-07 2022-06-07 山东鹰联光电科技股份有限公司 Optical fiber cable line inspection method based on unmanned aerial vehicle aerial photography
CN114937039A (en) * 2022-07-21 2022-08-23 阿法龙(山东)科技有限公司 Intelligent detection method for steel pipe defects
CN115100202A (en) * 2022-08-25 2022-09-23 聊城市宏伟电器有限公司 Cable quality detection method based on image processing
CN115588139A (en) * 2022-11-22 2023-01-10 东北电力大学 Power grid safety intelligent cruise detection method
CN117173166A (en) * 2023-11-02 2023-12-05 江苏裕荣光电科技有限公司 Optical cable surface defect detection method
CN117173166B (en) * 2023-11-02 2023-12-26 江苏裕荣光电科技有限公司 Optical cable surface defect detection method

Also Published As

Publication number Publication date
CN113920122B (en) 2022-03-04

Similar Documents

Publication Publication Date Title
CN113920122B (en) Cable defect detection method and system based on artificial intelligence
CN114842017B (en) HDMI cable surface quality detection method and system
CN115170576B (en) Aluminum pipe surface defect detection method based on machine vision
CN113989279B (en) Plastic film quality detection method based on artificial intelligence and image processing
CN114757900B (en) Artificial intelligence-based textile defect type identification method
Fardo et al. A formal evaluation of PSNR as quality measurement parameter for image segmentation algorithms
CN113808138B (en) Artificial intelligence-based wire and cable surface defect detection method
CN114049489B (en) Early warning method for breakage of optical fiber cable sheath
CN114419025A (en) Fiberboard quality evaluation method based on image processing
CN114494256B (en) Electric wire production defect detection method based on image processing
CN114235825B (en) Steel wire rope quality detection method based on computer vision
CN115063430B (en) Electric pipeline crack detection method based on image processing
CN115294140A (en) Hardware part defect detection method and system
CN115439494B (en) Spray image processing method for quality inspection of sprayer
CN115775250A (en) Golden finger circuit board defect rapid detection system based on digital image analysis
CN108734704B (en) Transmission conductor strand breakage detection method based on gray variance normalization
CN115330790B (en) Image-based cable strand quality detection method and system
CN112381800B (en) Wire diameter abnormity identification method and device, electronic equipment and computer readable storage medium
CN113935666A (en) Building decoration wall tile abnormity evaluation method based on image processing
CN115272335A (en) Metallurgical metal surface defect detection method based on significance detection
CN115035110B (en) Yarn hairiness quantitative detection method based on pit cutting and chain code tracking
CN114140669A (en) Welding defect recognition model training method and device and computer terminal
CN115689948A (en) Image enhancement method for detecting cracks of building water supply pipeline
CN115330796A (en) Copper wire tinning defect identification method
CN114742832B (en) Welding defect detection method for MiniLED thin plate

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant