CN111275659B - Weld image processing method and device, terminal equipment and storage medium - Google Patents

Weld image processing method and device, terminal equipment and storage medium Download PDF

Info

Publication number
CN111275659B
CN111275659B CN201811466376.6A CN201811466376A CN111275659B CN 111275659 B CN111275659 B CN 111275659B CN 201811466376 A CN201811466376 A CN 201811466376A CN 111275659 B CN111275659 B CN 111275659B
Authority
CN
China
Prior art keywords
image
weld
area
welding
corrected
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.)
Active
Application number
CN201811466376.6A
Other languages
Chinese (zh)
Other versions
CN111275659A (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.)
Commercial Aircraft Corp of China Ltd
Shanghai Aircraft Manufacturing Co Ltd
Original Assignee
Commercial Aircraft Corp of China Ltd
Shanghai Aircraft Manufacturing 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 Commercial Aircraft Corp of China Ltd, Shanghai Aircraft Manufacturing Co Ltd filed Critical Commercial Aircraft Corp of China Ltd
Priority to CN201811466376.6A priority Critical patent/CN111275659B/en
Publication of CN111275659A publication Critical patent/CN111275659A/en
Application granted granted Critical
Publication of CN111275659B publication Critical patent/CN111275659B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/0002Inspection of images, e.g. flaw detection
    • G06T7/0004Industrial image inspection
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/10Image acquisition modality
    • G06T2207/10116X-ray image
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/30Subject of image; Context of image processing
    • G06T2207/30108Industrial image inspection
    • G06T2207/30152Solder
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02PCLIMATE CHANGE MITIGATION TECHNOLOGIES IN THE PRODUCTION OR PROCESSING OF GOODS
    • Y02P90/00Enabling technologies with a potential contribution to greenhouse gas [GHG] emissions mitigation
    • Y02P90/30Computing systems specially adapted for manufacturing

Landscapes

  • Engineering & Computer Science (AREA)
  • Quality & Reliability (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Analysing Materials By The Use Of Radiation (AREA)
  • Image Processing (AREA)

Abstract

The invention discloses a weld image processing method, a device, terminal equipment and a storage medium. The method comprises the following steps: acquiring an inclination angle of a welding seam region in a welding seam image; correcting the weld image according to the tilt angle; and intercepting the corrected welding line image according to the rectangular area to obtain the corrected welding line area image, wherein parameters of the rectangular area correspond to texture characteristics of the corrected welding line image. By using the method, the accuracy of nondestructive testing of the welding seam image can be improved.

Description

Weld image processing method and device, terminal equipment and storage medium
Technical Field
The embodiment of the invention relates to the technical field of digital image processing, in particular to a weld joint image processing method, a device, terminal equipment and a storage medium.
Background
With the rapid development of modern industrial technology, welding technology, one of the important means of machine manufacturing, has been widely used in various departments of the manufacturing industry. The quality of welding seriously affects the use safety of welded products, so that nondestructive detection of welded structural members is indispensable.
In the technical field of nondestructive detection, the welding quality can be detected by using methods such as ray detection, acoustic emission detection, ultrasonic detection and the like. After the digital image of the object to be inspected is obtained, the main working content is to perform inspection, such as defect inspection, by using manual or digital image processing technology.
When the manual processing is adopted, the problems of low efficiency and high false detection rate exist. With the development of image processing technology, defect detection on digital images has become an important means for quality judgment. However, when the image processing technology is used for judging, some characteristics similar to the defects are regarded as defects to be misjudged, and the accuracy of nondestructive detection is reduced.
Disclosure of Invention
The embodiment of the invention provides a weld image processing method, a device, terminal equipment and a storage medium, which are used for improving the accuracy of nondestructive detection of a weld image.
In a first aspect, an embodiment of the present invention provides a method for processing a weld image, including:
acquiring an inclination angle of a welding seam region in a welding seam image;
correcting the weld image according to the tilt angle;
and intercepting the corrected welding line image according to the rectangular area to obtain the corrected welding line area image, wherein parameters of the rectangular area correspond to texture characteristics of the corrected welding line image.
In a second aspect, an embodiment of the present invention further provides a weld image processing apparatus, including:
the acquisition module is used for acquiring the inclination angle of the welding seam area in the welding seam image;
a correction module for correcting the weld image according to the inclination angle;
the intercepting module is used for intercepting the corrected welding line image according to the rectangular area to obtain the corrected welding line area image, and parameters of the rectangular area correspond to texture features of the corrected welding line image.
In a third aspect, an embodiment of the present invention further provides a terminal device, including:
one or more processors;
a storage means for storing one or more programs;
the one or more programs are executed by the one or more processors, so that the one or more processors implement the weld image processing method provided by the embodiment of the invention.
In a fourth aspect, the embodiment of the present invention further provides a computer readable storage medium, on which a computer program is stored, which when executed by a processor, implements the weld image processing method provided by the embodiment of the present invention.
The embodiment of the invention provides a welding seam image processing method, a device, terminal equipment and a storage medium, by utilizing the technical scheme, the welding seam image can be corrected based on the inclination angle of a welding seam area in the welding seam image; and then, according to the rectangular area corresponding to the texture feature of the corrected welding line image, intercepting the corrected welding line image to obtain a corrected welding line area image, effectively excluding non-welding line areas in the welding line image, and improving the accuracy of subsequently acquiring the defect feature of the welding line area.
Drawings
Fig. 1 is a schematic flow chart of a weld image processing method according to a first embodiment of the present invention;
fig. 2a is a schematic flow chart of a weld image processing method according to a second embodiment of the present invention;
FIG. 2b is a schematic view of a weld image according to a second embodiment of the present invention;
fig. 2c shows a schematic diagram of a small-size image according to a second embodiment of the present invention;
FIG. 2d is a schematic view of an enhanced image according to a second embodiment of the present invention;
FIG. 2e is a schematic diagram of a first binarized image according to a second embodiment of the present invention;
FIG. 2f is a schematic diagram of a centerline image according to a second embodiment of the present invention;
FIG. 2g is a schematic diagram of a rotated image according to a second embodiment of the present invention;
FIG. 2h is a schematic view of a corrected weld image provided by a second embodiment of the present invention;
FIG. 2i is a schematic diagram of a texture image according to a second embodiment of the present invention;
FIG. 2j is a schematic diagram of a second binarized image according to a second embodiment of the present invention;
FIG. 2k is a schematic diagram of a filtered image according to a second embodiment of the present invention;
FIG. 2l is a schematic view of a minimum rectangle provided by a second embodiment of the present invention;
FIG. 2m is a schematic view of a corrected weld area image provided by a second embodiment of the present invention;
Fig. 2n shows a schematic diagram of a black edge removing principle according to a second embodiment of the present invention;
fig. 3 is a schematic structural diagram of a welding seam image processing device according to a third embodiment of the present invention;
fig. 4 is a schematic structural diagram of a terminal device according to a fourth embodiment of the present invention.
Detailed Description
The invention is described in further detail below with reference to the drawings and examples. It is to be understood that the specific embodiments described herein are merely illustrative of the invention and are not limiting thereof. It should be further noted that, for convenience of description, only some, but not all of the structures related to the present invention are shown in the drawings.
Before discussing exemplary embodiments in more detail, it should be mentioned that some exemplary embodiments are described as processes or methods depicted as flowcharts. Although a flowchart depicts operations (or steps) as a sequential process, many of the operations can be performed in parallel, concurrently, or at the same time. Furthermore, the order of the operations may be rearranged. The process may be terminated when its operations are completed, but may have additional steps not included in the figures. The processes may correspond to methods, functions, procedures, subroutines, and the like.
Example 1
Fig. 1 is a schematic flow chart of a method for processing a weld image according to a first embodiment of the present invention, where the method is applicable to a case of processing a weld image, and in particular, the method is applicable to a case of processing an X-ray image of a weld, so as to improve accuracy of nondestructive testing. The method may be performed by a weld image processing apparatus, where the apparatus may be implemented in software and/or hardware and is generally integrated on a terminal device provided in an embodiment of the present invention, where the terminal device includes, but is not limited to: server, notebook computer, desktop computer, etc.
At present, the X-ray technology is used as a common welding nondestructive testing technology, and is very commonly applied to welding defect detection of welding structural parts with high quality requirements. After the X-ray image of the welding seam is acquired, the main working content is to detect the welding seam defect through manual or digital image processing technology. The manual processing has the problems of low efficiency and high false detection rate. With the development of image processing technology, defect detection on digital welding images has become an important means for judging the quality of welding products.
In the weld X-ray image, due to the fact that welding spatter, groove bulge of a part and the like may be caused by a welding piece, some characteristics similar to weld defects exist in a background area outside a weld area in the weld X-ray image. These features may be empirically determined during manual processing. However, for the adaptive weld X-ray digital image algorithm, these features may also be misjudged as weld defects, reducing the accuracy of the non-destructive inspection. Therefore, the embodiment provides a weld image processing method, which can effectively improve the technical problem of low detection accuracy when nondestructive detection is performed on a weld image.
As shown in fig. 1, a welding seam image processing method provided in an embodiment of the present invention includes the following steps:
s101, acquiring an inclination angle of a welding line area in the welding line image.
In this embodiment, the weld image may be understood as an image containing the weld, such as a weld X-ray image, acquired by the image acquisition device. The weld region is understood to be the region of the weld image where the weld is located. The inclination angle is understood to be the angle by which the weld region is inclined.
It should be noted that, in the weld image processing method in this embodiment, two characteristics are required to be satisfied in the weld region: the weld joint area is approximately strip-shaped; the texture characteristics of the weld zone differ from the background by more than a certain threshold, which is not limiting and can be set by a person skilled in the art according to the actual situation.
The specific means for acquiring the inclination angle of the welding seam region of the welding seam image is not limited, and if the step is adopted, the welding seam image can be analyzed to obtain the central line of the welding seam region, then the central line is subjected to linear fitting, and the inclination angle of the straight line after fitting is acquired; in the step, the upper left corner of the weld image is taken as an origin of coordinates, the horizontal direction is taken as an abscissa, and the vertical direction is taken as an ordinate, so that a rectangular coordinate system is established. The measured tilt angle of the weld region diagonal is then determined based on the coordinate system. And determining the actual inclination angle of the welding line area according to the length and the width of the welding line area. And finally, determining the inclination angle of the welding line area according to the actual inclination angle and the actual inclination angle.
It is understood that the inclination angle may be an angle with respect to the horizontal direction or an angle with respect to the vertical direction, and is not limited thereto. The inclination angle can be used for identifying the inclination angle of the welding seam area, and the welding seam image can be adjusted based on the inclination angle so as to obtain the welding seam area in a horizontal state or a vertical state, so that subsequent processing analysis is facilitated. Specifically, the positive and negative of the inclination angle can identify the direction of inclination of the weld region in the weld image, and the value of the inclination angle can identify the degree of inclination of the weld region in the weld image.
Illustratively, taking the upper left corner of the weld image as the origin of coordinates, the horizontal direction to the right as the horizontal axis positive direction, the vertical direction downward as the vertical axis positive direction, a rectangular coordinate system is established, and taking the inclination angle of the weld region relative to the horizontal direction as an example: if the weld area in the weld image is in a horizontal state, the acquired inclination angle may be zero; if the weld region in the weld image is above horizontal, the tilt angle may be negative; the tilt angle may be positive if the weld area is below horizontal in the weld image.
S102, correcting the welding line image according to the inclination angle.
After acquiring the inclination angle of the weld region, the step can correct the weld image based on the inclination angle to obtain the weld region in a horizontal or vertical state, thereby facilitating subsequent processing analysis.
The step is not limited to adjusting the welding seam area in the welding seam image to be in a horizontal state or adjusting the welding seam area in the welding seam image to be in a vertical state, and a person skilled in the art can select a corresponding means to process according to an actual scene.
Specifically, in correcting the weld image, the present step may rotate the weld image according to the acquired inclination angle so that the weld region in the weld image is in a horizontal state or a vertical state. It will be appreciated that, when the weld image is rotated, in order to ensure the integrity of the image, a blank area inevitably appears at the edge portion of the rotated weld image, and this step may further remove the blank area to obtain a corrected weld area. It will be appreciated that this step may only rotate the weld image when correcting the weld region according to the tilt angle; the blank region formed by the rotation may be removed after the rotation of the weld image, and is not limited herein.
S103, intercepting the corrected welding line image according to the rectangular area to obtain the corrected welding line area image, wherein parameters of the rectangular area correspond to texture features of the corrected welding line image.
In this embodiment, the rectangular region may be understood as a minimum circumscribed rectangular region of the weld region determined by performing a minimum rectangular analysis on the texture features of the corrected weld image. The corrected weld region image may be understood to include only the corrected weld image.
After correcting the weld image according to the tilt angle, the step may intercept the corrected weld image according to a rectangular region corresponding to the texture feature of the corrected weld image. Specifically, it is possible to intercept at the corresponding position of the corrected weld bead image according to the parameters of the rectangular region, such as the coordinate values, and take the region corresponding to the rectangular region obtained after the intercept as the corrected weld bead region image. The corrected weld region image may be an image obtained by rotationally correcting the weld region and removing the background. Based on the corrected weld joint region image, nondestructive detection is carried out, and erroneous judgment of weld joint defects can be effectively reduced.
The parameters of the rectangular region can be obtained based on the texture features of the corrected welding seam image, and the obtaining means of the parameters of the rectangular region are not limited, for example, the parameters corresponding to the minimum circumscribed rectangle of the welding seam region can be directly determined based on the texture features of the corrected welding seam image; the texture features of the corrected weld image may also be further analyzed to determine parameters corresponding to the minimum bounding rectangle of the weld region.
The first embodiment of the invention provides a welding seam image processing method, by which a welding seam image can be corrected based on the inclination angle of a welding seam region in the welding seam image; and then intercepting the corrected welding line image according to the rectangular area corresponding to the texture characteristics of the corrected welding line image to obtain the corrected welding line area image, so that the non-welding line area in the welding line image is effectively excluded, and the accuracy of subsequently acquiring the defect characteristics of the welding line area is improved.
Example two
Fig. 2a is a schematic flow chart of a weld image processing method according to a second embodiment of the present invention, where the second embodiment is optimized based on the above embodiments. In this embodiment, the inclination angle of the weld region in the acquired weld image is further specified as: acquiring a welding line image; reducing the resolution of the weld image to obtain a small-size image; selecting a corresponding Gaussian Laplace operator template to carry out image enhancement on the small-size image according to the pixel width of the welding line area in the small-size image, so as to obtain an enhanced image; performing self-adaptive binarization processing on the enhanced image to obtain a first binarized image; acquiring a central line of a welding line area in the first binarization image; and performing straight line fitting on the central line to obtain the inclination angle of the central line.
Further, the present embodiment further corrects the weld image according to the inclination angle, and further optimizes: acquiring a welding line image; rotating the welding line image according to the inclination angle to obtain a rotated image; and removing the blank area of the rotated image to obtain a corrected welding line image.
Based on the optimization, the determination of the parameters of the rectangular area is specifically optimized as follows: processing the corrected weld image by adopting an edge detection algorithm to obtain a texture image; and determining coordinate values of the rectangular area according to the texture image. For details not yet described in detail in this embodiment, refer to embodiment one.
As shown in fig. 2, a welding seam image processing method provided in a second embodiment of the present invention includes the following steps:
s201, acquiring a welding line image.
In acquiring the inclination angle of the weld region in the weld image, the present embodiment may first acquire the weld image. The means for acquiring the image of the weld is not limited herein, and may be input by the user or acquired by the image acquisition device.
S202, reducing the resolution ratio of the welding line image to obtain a small-size image.
In the present embodiment, the small-size image may be understood as an image formed after the resolution of the weld image is reduced, and the small-size image may be considered as an image of a small size with respect to the weld image. The small-size image is reduced in size compared with the weld image, and the size is not limited herein, and can be set according to actual requirements.
After the weld image is acquired, this step may reduce the resolution of the weld image to reduce the size of the weld image. The means for reducing the weld image is not limited herein, for example, the weld image may be sampled, for example, at equal intervals, or an average value of pixel points in a preset area may be taken as a pixel value of the preset area.
According to the method, the resolution of the welding line image is reduced, so that the pixel width of the welding line area is reduced to a reasonable range, and meanwhile, the resolution is reduced, so that a lot of detail interference in the image can be removed, and the subsequent processing is facilitated.
Further, before reducing the resolution of the weld image to obtain a small-size image, the method further includes:
preprocessing the welding line image to obtain a first denoising image; correspondingly, the reducing the resolution of the welding seam image to obtain a small-size image comprises the following steps:
and reducing the resolution of the first denoising image to obtain a small-size image.
The first denoising image can be understood as an image obtained by filtering noise in the welding line image in the step of acquiring the inclination angle of the welding line area.
In this embodiment, the preprocessing means used to obtain the first denoised image includes, but is not limited to: median filtering, smoothing filtering, etc. The purpose of preprocessing the weld image is to eliminate interference information such as various noise and the like existing in the weld image, improve the signal-to-noise ratio of the image and improve the processing efficiency of the weld image.
S203, selecting a corresponding Gaussian Laplacian template to carry out image enhancement on the small-size image according to the pixel width of the welding line area in the small-size image, and obtaining an enhanced image.
After the small-size image is obtained, the step can select a Gaussian Laplacian template matched with the pixel width based on the pixel width of the welding line area in the small-size image to carry out image enhancement processing. The size of the selected laplace submodule is not limited herein, and a person skilled in the art may select the size of the corresponding laplace submodule according to actual requirements, for example, the size may be twice the pixel width of the weld region.
The method comprises the steps of firstly obtaining the pixel width of a welding line area in a small-size image, and then selecting a matched Gaussian Laplacian template according to the obtained pixel width to carry out image enhancement on the small-size image. Specific means for acquiring the pixel width of the weld region in the small-size image are not limited here. Such as may be determined from a pixel width acquisition tool, or may be determined by a corresponding image processing algorithm.
Because the noise point has a certain influence on edge detection, the step can adopt a Gaussian Laplace operator, namely a Log operator, to carry out image enhancement on the small-size image. LOG operator: the operator model integrating Gaussian and Laplace is an operator model integrating smoothness and edges, can improve the contrast between a welding line area and a background, and is convenient for subsequent processing.
S204, performing self-adaptive binarization processing on the enhanced image to obtain a first binarized image.
In this embodiment, the first binarized image may be understood as a binarized image obtained by adaptively binarizing the enhanced image.
After the enhanced image is obtained, this step may perform a binarization process on the enhanced image to segment the main region of the weld from the enhanced image.
Specific means of adaptive binarization processing of the enhanced image in this step include, but are not limited to: cluster binarization algorithm, maximum entropy threshold method, etc. The specific adaptive binarization method is not limited herein, and may be selected by those skilled in the art according to the specific condition of the weld image.
S205, acquiring the central line of the welding line area in the first binarized image.
In this embodiment, the centerline may be understood as a skeletal line that can characterize the weld zone. The present embodiment may use the inclination angle of the center line as the inclination angle of the weld region.
After obtaining the first binarized image, the present step may obtain the center line of the weld area of the first binarized image, i.e., the center line of the weld area having a certain pixel width is thinned to a single pixel width. And analyzing the central line of the welding seam area to determine the inclination angle of the welding seam area.
Specifically, the specific means for obtaining the center line of the weld region is not limited herein, and the corresponding method may be selected in the art according to the specific shape of the weld region to obtain the center line thereof, such as a morphology-based skeleton algorithm, a gravity center method (i.e., median of upper and lower edges), and the like.
S206, performing straight line fitting on the central line to obtain the inclination angle of the central line.
After obtaining the centerline of the weld region, the present step may perform a straight line fitting on the centerline to determine the inclination angle of the centerline by analyzing the fitted straight line.
Specific means of the straight line fitting are not limited herein, and a person skilled in the art may select a corresponding means to perform the straight line fitting according to the shape of the center line, for example, perform the straight line fitting by using a least square method.
After straight line fitting is performed on the center line, the tangent value of the straight line after fitting can be obtained as the inclination angle of the center line in this step. After acquiring the inclination angle of the center line, the present embodiment can correct the bead image based on the inclination angle.
S207, acquiring a welding line image.
In correcting the weld image according to the inclination angle, the present step may first acquire the weld image to correct the weld image. The weld image may be an image of the weld that is acquired when the inclination angle of the weld area is acquired. Means for acquiring the bead image are not limited herein, and for example, a bead image acquired when acquiring the inclination angle of the bead region may be acquired; it is also possible to acquire a weld image re-imported by the user.
S208, rotating the welding line image according to the inclination angle to obtain a rotated image.
After the weld image is acquired, the step may rotate the weld image based on the acquired inclination angle to obtain a rotated image. The rotation direction of the weld image can be determined according to the positive and negative of the inclination angle, and the rotation size of the weld image can be determined according to the absolute value of the inclination angle.
Further, before rotating the weld image according to the inclination angle to obtain a rotated image, the method further includes:
preprocessing the welding line image to obtain a second denoising image; correspondingly, the rotating the welding seam image according to the inclination angle to obtain a rotated image comprises the following steps:
and rotating the second denoising image according to the inclination angle to obtain a rotated image.
The second denoising image can be understood as an image obtained after the noise in the welding line image is filtered out in the welding line image correcting stage.
In this embodiment, the preprocessing means used to obtain the second denoising image includes, but is not limited to: median filtering, smoothing filtering, etc. The purpose of preprocessing the weld image is to eliminate various noise and other interference information in the weld image, improve the signal-to-noise ratio of the image and improve the processing efficiency of the weld image after subsequent interception and correction.
S209, removing the blank area of the rotated image to obtain a corrected welding line image.
It will be appreciated that in spin welding the image, there is inevitably a black edge, i.e. a blank area, at the edge portion of the image after rotation in order to ensure the integrity of the weld image. The blank region may be considered as a non-important region in the weld image and may not be subjected to non-destructive inspection. Therefore, the blank area in the rotated image can be removed in the step, and the corrected welding line image can be obtained.
The means for removing the blank area in the rotated image is not limited here, for example, in this step, the cut-out position may be determined according to four corner points of the weld image in the rotated image, so as to remove the blank area in the rotated image.
S210, processing the corrected weld image by adopting an edge detection algorithm to obtain a texture image.
After the corrected weld image is obtained, the embodiment can determine the minimum circumscribed rectangle of the weld region based on the corrected weld image, and then intercept the corrected weld image based on the determined minimum circumscribed rectangle.
First, in order to obtain the minimum bounding rectangle of the corrected weld image, this step may first obtain a texture image of the corrected weld image. Because the weld has defects and a large surface roughness, a large number of texture features exist in the weld region. The texture of the weld region is completely different from the texture of the background region, and the texture features of the weld region can be highlighted by an edge detection algorithm to obtain a texture image. Edge detection algorithms in this step include, but are not limited to: laplace-of-Gaussian (LoG) and Sobel edge detection operators.
S211, determining coordinate values of the rectangular area according to the texture image.
After the texture image is obtained, the coordinate value of the rectangular area can be determined by carrying out minimum circumscribed rectangle analysis on the texture features in the texture image; the texture image may be further processed, and then the minimum bounding rectangle of the weld region may be determined to obtain coordinate values of the rectangular region. The rectangular area may encompass all of the features of the weld area. The specific means of performing the minimum rectangle analysis is not limited here.
It is understood that, since the weld region is approximately elongated, the coordinate values of the rectangular region obtained in this step may include only the coordinate values of the upper edge and the lower edge of the rectangle.
Further, determining coordinate values of a rectangular region according to the texture image includes:
performing self-adaptive binarization processing on the texture image to obtain a second binarization image;
removing interference information of the second binarized image to obtain a filtered image;
and determining coordinate values of the rectangular area according to the welding seam area in the filtered image.
In order to improve the accuracy of parameter acquisition of the rectangular region, when the coordinate value of the rectangular region is determined according to the texture image, adaptive binarization processing can be performed on the texture image to obtain a second binarized image. The second binarized image may be understood as a binarized image obtained by performing adaptive binarization processing on the texture image. Adaptive binarization includes, but is not limited to: cluster binarization algorithm, maximum entropy threshold method, etc. The purpose of performing adaptive binarization processing on the texture image is to: the main area of the welding line area is more accurately segmented.
After the second binarized image is obtained, interference information in the second binarized image may be removed. The interference information can be understood as interference particles in the second binarized image. The means for removing the interference information in the second binarized image is not limited here. The interference information can be filtered by adopting morphological interference elimination particles and particle filtering.
The morphological interference elimination particles mainly adopt structural elements with proper sizes, and various interference particles in the texture image are removed through a series of morphological algorithms such as open operation, closed operation and the like. The main content of the grain filtering is to adopt a self-adaptive algorithm, take the pixel area of the largest grain in the texture image as a basic value, and adopt a proper coefficient to obtain a grain filtering threshold value. Particles with pixel areas below this threshold are all filtered out. When the interference information is removed, whether the particles are filtered out can be judged according to a series of characteristics such as the size, the shape and/or whether the particles have inner holes or not.
S212, intercepting the corrected welding line image according to the rectangular area to obtain the corrected welding line area image.
The present embodiment is a proposed weld image processing method for the purpose of acquiring a corrected weld region image, that is, a region of interest (region of interest, ROI) image, by a weld image, the corrected weld region image including only a weld region, the method mainly including two steps:
(1) Rotationally correcting the weld X-ray image (i.e., weld image): the method mainly comprises the steps of preprocessing a welding line image, reducing the size of the image, enhancing the image of a Log operator, carrying out self-adaptive binarization, obtaining the central line of a welding line area, obtaining the inclination angle theta of the image by straight line fitting, and correcting the welding line image by rotating the angle theta.
(2) Acquiring an ROI region by texture features of the weld region: the method mainly comprises the steps of preprocessing a welding line image, obtaining texture characteristics of the image after rotation correction, self-adapting binarization, morphological interference particle elimination, particle filtering and ROI region interception.
The purpose of the rotation correction of the welding seam X-ray image is to carry out rotation correction on the inclined welding seam X-ray image, so that the extraction of the subsequent ROI area is facilitated.
The main purpose of the pretreatment of the image is to eliminate interference information such as various noises existing in the welding line X-ray image and improve the signal-to-noise ratio of the image. The preprocessing algorithm mainly comprises median filtering, smooth filtering and the like.
The size of the image is reduced, the main purpose is to reduce the resolution of the image, so that the pixel width of a welding line area is reduced to a reasonable range, and meanwhile, the reduction of the resolution can remove a lot of detail interference information in the image, so that the effective image enhancement processing of a subsequent Log operator is facilitated.
The Log operator adopts a one-dimensional operator template, and the size of the template is matched with the pixel width of a welding line area of the low-size image obtained in the last step. After the algorithm template is processed, the contrast ratio of the welding seam area and the background is obviously improved, and the subsequent binarization and image segmentation are facilitated.
The self-adaptive binarization method comprises a plurality of self-adaptive binarization algorithms such as a common clustering binarization algorithm, a maximum entropy threshold method and the like, and the selection of the algorithm is selected according to the specific condition of the weld image. The main purpose of binarization is to segment the main area of the weld from the image.
The main content of the center line of the weld joint area is: the weld area with a certain pixel width is thinned into a single pixel width bone line. The main selectable methods include a bone algorithm based on morphology, a gravity center method (taking the median value from the upper edge and the lower edge), and the like.
The main purpose of finding the tilt angle θ of the image by straight line fitting is to: the inclination angle θ of the skeleton line of the single pixel width is obtained. The inclination angle theta is the inclination angle of the welding line area of the original image.
The above-described procedures are all performed based on the reduced-size image, and the rotation correction processed image is directed to the original image. After the original image is subjected to rotation correction according to the obtained inclination angle theta, the blank area in the rotated image is deleted.
The acquisition of the ROI area by the texture features of the weld area is performed based on the corrected weld image, and when the ROI area is acquired, the main purpose of the image preprocessing is to eliminate interference information such as various noises and the like existing in the weld X-ray image and improve the signal-to-noise ratio of the image. The preprocessing algorithm mainly comprises median filtering, smooth filtering and the like.
The main reason for obtaining the texture features of the corrected weld image is that the texture of the weld region is completely different from that of the background region, and a large number of texture features exist in the X-ray image of the weld region due to the defects and the large surface roughness of the weld. These textures can be visualized by an edge operator algorithm. The common edge detection algorithm is a LoG operator and a Sobel edge detection operator.
Morphological elimination of interfering particles and particle filtering, there are more interfering particles in the image, and further removal of these particles is required. The morphological interference elimination particles mainly adopt structural elements with proper sizes, and remove various interference particles in a second binarization image corresponding to the texture image through a series of morphological algorithms such as open operation, closed operation and the like. The main content of the particle filtering is to adopt a self-adaptive algorithm, take the pixel area of the largest particle in the image as a basic value, and adopt a proper coefficient to obtain the threshold value of the particle filtering. Particles with pixel areas below this threshold are all filtered out.
Intercepting the ROI area: after some of the above processing, substantially only the weld area remains in the image with a large "grain". By acquiring the upper and lower edges of the smallest rectangle in which the "grain" is located, the region between the upper and lower edges is truncated in the rotation corrected image, and the ROI region is obtained.
By the technical means, the ROI area of the welding line X-ray image is obtained, the technical problems that the welding line image is inclined and has more interference information can be solved, non-welding line areas in the welding line X-ray image are effectively excluded, and the accuracy of obtaining defect characteristics by algorithms such as subsequent image segmentation and characteristic recognition is effectively improved.
The following exemplarily describes a technical solution provided in this embodiment:
taking a welding line X-ray image of an aluminum lithium alloy laser welding piece as an example for explanation, an original image, namely an original welding line X-ray image, is firstly obtained, and the image is the welding line image in the embodiment. Fig. 2b shows a schematic view of a weld image provided by the second embodiment of the present invention, as shown in fig. 2b, the weld image is in an inclined state, and the original image size is 1024×160.
And (3) performing reduction processing on the welding line image, namely reducing the size of the welding line image, and obtaining a low-size image, namely a small-size image in the embodiment. Fig. 2c shows a schematic diagram of a small-size image provided in the second embodiment of the present invention, where the size of the small-size image is 114×18, and the pixel width of the weld area in the small-size image is reduced by about 7 pixels compared to fig. 2b, as shown in fig. 2 c.
Selecting a template of a Log operator with a proper size, performing image enhancement processing on the small-size image in fig. 2c, wherein fig. 2d shows a schematic view of an enhanced image provided by a second embodiment of the present invention, the enhanced image is a Log operator enhanced image, as shown in fig. 2d, the contrast ratio between a white area where a weld joint is located and a background is greatly improved, the background is basically black, and the size of the enhanced image is 114×18.
The enhanced image in fig. 2d is binarized by an adaptive binarization algorithm, and fig. 2e shows a schematic diagram of a first binarized image according to a second embodiment of the present invention, and as shown in fig. 2e, the size of the first binarized image is 114×18.
A morphological skeleton algorithm is selected, and a skeleton center line of a region where a weld is located is obtained by processing fig. 2e, fig. 2f shows a schematic diagram of a center line image provided by a second embodiment of the present invention, where, as shown in fig. 2f, the size of the center line image is 114×18, the center line image can represent characteristic information of the weld region, and an inclination angle of the center line can be used as an inclination angle of the weld region.
The straight line fitting of the least square method is performed on fig. 2f, and a straight line equation is obtained (note: the origin of the image coordinate system is at the upper left corner, the horizontal right direction is the positive direction of the X axis, and the vertical downward direction is the square of the Y axis):
0.0525*X+0.9986Y=10.808
According to the linear equation, the inclination angle is 3 degrees, the original image in fig. 2b is rotated by 3 degrees, a rotated image is obtained, and fig. 2g shows a schematic diagram of the rotated image provided in the second embodiment of the present invention. As shown in fig. 2g, the size of the rotated image is 1031×214. Since the original image is rectangular, after rotation, in order to ensure the integrity of the image, the image inevitably has black edges after rotation.
In order to only preserve the weld region, black edges in the rotated image may be removed after the rotated image is obtained, fig. 2h shows a schematic diagram of a corrected weld image provided in the second embodiment of the present invention, and as shown in fig. 2h, the corrected weld image has a size of 1014×106, and the corrected weld image contains fewer background regions than the weld image in fig. 2b, except for black edges, i.e. blank regions.
To further remove the background area in fig. 2h, an analysis may be performed based on the texture characteristics of the weld area. The corrected weld image in fig. 2h may be processed, for example, using a Sobel operator, to obtain texture features of the corrected weld image. Fig. 2i shows a schematic diagram of a texture image provided in the second embodiment of the present invention, where the texture image is obtained by performing histogram equalization processing on the corrected weld image in fig. 2h by using a Sobel operator. Because the gray value of the image processed by the Sobel operator is low, the gray is unclear, the image processed by the Sobel operator is highlighted for display through histogram equalization, and the size of the texture image is 1014×106.
And performing self-adaptive binarization processing on the texture image to obtain a second binarized image. Fig. 2j shows a schematic diagram of a second binarized image according to a second embodiment of the present invention, and as shown in fig. 2j, the size of the second binarized image is 1014×106.
Morphological degranulation (morphological opening and closing operations) and particle filtering are performed on the texture image to obtain a filtered image, and fig. 2k shows a schematic diagram of the filtered image provided in the second embodiment of the present invention, and as shown in fig. 2k, the size of the filtered image is 1014×106.
And carrying out minimum rectangle analysis on the filtered image to obtain the minimum rectangle of the filtered image. Fig. 2l shows a schematic diagram of a minimum rectangle provided in the second embodiment of the present invention, as shown in fig. 2l, the minimum rectangle is a gray line area in fig. 2, the coordinate value of the upper edge of the minimum rectangle is 32, and the coordinate value of the lower edge is 96. And (3) intercepting an image in the vertical direction between 32 and 96 from the corrected welding line image shown in fig. 2h to obtain a corrected welding line area image. Since the weld region is long, only the upper and lower edges of the minimum rectangle, that is, the coordinate values in the vertical direction may be considered when performing the minimum rectangle analysis.
Fig. 2m shows a schematic diagram of a corrected weld area image provided in the second embodiment of the present invention, where, as shown in fig. 2m, the corrected weld area image has a size of 1014×60, and includes only a weld area, and the weld area is in a horizontal state.
Fig. 2n shows a schematic diagram of the principle of removing black edges according to the second embodiment of the present invention, as shown in fig. 2n, the inclined white area is an original image, that is, a weld image, and the black area is a black edge generated after the original image rotates. The range encircled by the dotted line is the final truncated image, i.e., the corrected weld image. The first dotted line side 1, the second dotted line side 2, the third dotted line side 3 and the fourth dotted line side 4 are four sides of a dotted line frame, and the first corner point 5, the second corner point 6, the third corner point 7 and the fourth corner point 8 are four corner points of a white area in the figure. The principle of removing black edges (i.e. blank areas) is: the first dotted line side 1 and the first corner point 5 of the dotted line frame are in a line, the second dotted line side 2 and the second corner point 6 are in a line, the third dotted line side 3 and the third corner point 7 are in a line, and the fourth dotted line side 4 and the fourth corner point 8 are in a line, so that the specific position of the dotted line frame is obtained.
The second embodiment of the invention provides a weld image processing method, which embodies the operations of acquiring an inclination angle, correcting a weld image and determining parameters of a rectangular area. Firstly, reducing the resolution of a welding line image to obtain a small-size image, and secondly, selecting a corresponding LOG operator module to carry out image enhancement on the small-size image according to the pixel width of a welding line area in the small-size image to obtain an enhanced image; then, carrying out self-adaptive binarization processing on the enhanced image to obtain a first binarized image so as to obtain the central line of a welding line area in the first binarized image; and performing linear fitting on the central line to obtain the inclination angle of the central line. And rotating the welding line image according to the inclination angle of the central line to obtain a rotated image, and removing a blank area of the rotated image to obtain a corrected welding line area. The coordinate values of the rectangular area are determined according to the texture characteristics of the corrected welding seam area, so that the corrected welding seam image is intercepted, the corrected welding seam area image is obtained, the non-welding seam area in the welding seam image is removed more accurately, the obtained welding seam area is the corrected welding seam area, and convenience is provided for subsequent defect analysis of the welding seam area.
Example III
Fig. 3 is a schematic structural diagram of a welding seam image processing device according to a third embodiment of the present invention, where the device may be suitable for processing welding seam images, and in particular, the device may be suitable for processing welding seam X-ray images to improve accuracy of nondestructive detection, where the device may be implemented by software and/or hardware and is generally integrated on a terminal device.
As shown in fig. 3, the weld image processing apparatus includes: an acquisition module 31, a correction module 32 and an interception module 33;
wherein, the acquisition module 31 is used for acquiring the inclination angle of the welding seam area in the welding seam image;
a correction module 32 for correcting the weld image according to the inclination angle;
the intercepting module 33 is configured to intercept the corrected weld image according to a rectangular area, and obtain a corrected weld area image, where parameters of the rectangular area correspond to texture features of the corrected weld image.
In the present embodiment, the weld image processing apparatus first acquires the inclination angle of the weld region in the weld image by the acquisition module 31; secondly correcting the weld image according to the inclination angle by a correction module 32; finally, the corrected weld image is intercepted by the intercepting module 33 according to the rectangular area, so as to obtain a corrected weld area image, and parameters of the rectangular area correspond to texture features of the corrected weld image.
The embodiment provides a welding seam image processing device which can correct a welding seam image based on the inclination angle of a welding seam area in the welding seam image; and then intercepting the corrected welding line image according to the rectangular area corresponding to the texture characteristics of the corrected welding line image to obtain the corrected welding line area image, so that the non-welding line area in the welding line image is effectively excluded, and the accuracy of subsequently acquiring the defect characteristics of the welding line area is improved.
Further, the obtaining module 31 is specifically configured to: acquiring a welding line image; reducing the resolution of the weld image to obtain a small-size image; selecting a corresponding Gaussian Laplace operator template to carry out image enhancement on the small-size image according to the pixel width of the welding line area in the small-size image, so as to obtain an enhanced image; performing self-adaptive binarization processing on the enhanced image to obtain a first binarized image; acquiring a central line of a welding line area in the first binarization image; and performing straight line fitting on the central line to obtain the inclination angle of the central line.
On the basis of the optimization, the welding seam image processing device further comprises: the first denoising module is used for preprocessing the weld joint image before reducing the resolution of the weld joint image to obtain a small-size image to obtain a first denoising image; accordingly, the obtaining module 31 is specifically configured to, when reducing the resolution of the weld image to obtain a small-size image: and reducing the resolution of the first denoising image to obtain a small-size image.
Based on the above technical solution, the correction module 32 is specifically configured to: acquiring a welding line image; rotating the welding line image according to the inclination angle to obtain a rotated image; and removing the blank area of the rotated image to obtain a corrected welding line image.
Further, the weld image processing apparatus further includes: the parameter determining module is used for processing the corrected weld joint image by adopting an edge detection algorithm to obtain a texture image; and determining coordinate values of the rectangular area according to the texture image.
Further, the parameter determining module is specifically configured to: processing the corrected weld image by adopting an edge detection algorithm to obtain a texture image; performing self-adaptive binarization processing on the texture image to obtain a second binarization image; removing interference information of the second binarized image to obtain a filtered image; and determining coordinate values of the rectangular area according to the welding seam area in the filtered image.
Based on the above technical scheme, the welding seam image processing device further comprises: the second denoising module is used for preprocessing the welding line image before rotating the welding line image according to the inclination angle to obtain a rotated image so as to obtain a second denoising image; accordingly, the correction module 32 is specifically configured to, when rotating the weld image according to the inclination angle to obtain a rotated image: and rotating the second denoising image according to the inclination angle to obtain a rotated image.
The weld image processing device can execute the weld image processing method provided by any embodiment of the invention, and has the corresponding functional modules and beneficial effects of the execution method.
Example IV
Fig. 4 is a schematic structural diagram of a terminal device according to a fourth embodiment of the present invention. As shown in fig. 4, a terminal device provided in a fourth embodiment of the present invention includes: one or more processors 41 and a storage device 42; the number of processors 41 in the terminal device may be one or more, one processor 41 being taken as an example in fig. 4; the storage device 42 is used for storing one or more programs; the one or more programs are executed by the one or more processors 41, such that the one or more processors 41 implement the weld image processing method according to any one of the embodiments of the present invention.
The terminal device may further include: an input device 43 and an output device 44.
The processor 41, the storage means 42, the input means 43 and the output means 44 in the terminal device may be connected by a bus or by other means, in fig. 4 by way of example.
The storage device 42 in the terminal device is used as a computer readable storage medium, and may be used to store one or more programs, which may be software programs, computer executable programs, and modules, such as program instructions/modules corresponding to the weld image processing method provided in the first or second embodiment of the present invention (for example, the modules in the weld image processing device shown in fig. 3, including the acquisition module 31, the correction module 32, and the interception module 33). The processor 41 executes various functional applications of the terminal device and data processing by executing software programs, instructions and modules stored in the storage device 42, that is, implements the weld image processing method in the above-described method embodiment.
The storage device 42 may include a storage program area and a storage data area, wherein the storage program area may store an operating system, at least one application program required for a function; the storage data area may store data created according to the use of the terminal device, etc. In addition, the storage 42 may include high-speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other non-volatile solid-state storage device. In some examples, storage 42 may further include memory located remotely from processor 41, which may be connected to the device via a network. Examples of such networks include, but are not limited to, the internet, intranets, local area networks, mobile communication networks, and combinations thereof.
The input means 43 may be used for receiving entered numeric or character information and for generating key signal inputs related to user settings and function control of the terminal device. The output device 44 may include a display device such as a display screen.
And, when one or more programs included in the above-described terminal device are executed by the one or more processors 41, the programs perform the following operations:
Acquiring an inclination angle of a welding seam region in a welding seam image; correcting the weld image according to the tilt angle; and intercepting the corrected welding line image according to the rectangular area to obtain the corrected welding line area image, wherein parameters of the rectangular area correspond to texture characteristics of the corrected welding line image.
Example five
A fifth embodiment of the present invention provides a computer-readable storage medium having stored thereon a computer program for executing a weld image processing method when executed by a processor, the method comprising:
acquiring an inclination angle of a welding seam region in a welding seam image; correcting the weld image according to the tilt angle; and intercepting the corrected welding line image according to the rectangular area to obtain the corrected welding line area image, wherein parameters of the rectangular area correspond to texture characteristics of the corrected welding line image.
Optionally, the program may be further configured to perform the weld image processing method provided in any of the embodiments of the present invention when executed by the processor.
The computer storage media of embodiments of the invention may take the form of any combination of one or more computer-readable media. The computer readable medium may be a computer readable signal medium or a computer readable storage medium. The computer readable storage medium can be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or a combination of any of the foregoing. More specific examples (a non-exhaustive list) of the computer-readable storage medium would include the following: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a random access Memory (Random Access Memory, RAM), a Read-Only Memory (ROM), an erasable programmable Read-Only Memory (Erasable Programmable Read Only Memory, EPROM), a flash Memory, an optical fiber, a portable CD-ROM, an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. A computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device.
The computer readable signal medium may include a propagated data signal with computer readable program code embodied therein, either in baseband or as part of a carrier wave. Such a propagated data signal may take many forms, including, but not limited to: electromagnetic signals, optical signals, or any suitable combination of the preceding. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device.
Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wire, fiber optic cable, radio Frequency (RF), and the like, or any suitable combination of the foregoing.
Computer program code for carrying out operations of the present invention may be written in any combination of one or more programming languages, including an object oriented programming language such as Java, smalltalk, C ++ and conventional procedural programming languages, such as the "C" programming language or similar programming languages. The program code may execute entirely on the user's computer, partly on the user's computer, as a stand-alone software package, partly on the user's computer and partly on a remote computer or entirely on the remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer through any kind of network, including a Local Area Network (LAN) or a Wide Area Network (WAN), or may be connected to an external computer (for example, through the Internet using an Internet service provider).
Note that the above is only a preferred embodiment of the present invention and the technical principle applied. It will be understood by those skilled in the art that the present invention is not limited to the particular embodiments described herein, but is capable of various obvious changes, rearrangements and substitutions as will now become apparent to those skilled in the art without departing from the scope of the invention. Therefore, while the invention has been described in connection with the above embodiments, the invention is not limited to the embodiments, but may be embodied in many other equivalent forms without departing from the spirit or scope of the invention, which is set forth in the following claims.

Claims (6)

1. A weld image processing method, characterized by comprising:
acquiring an inclination angle of a welding seam region in a welding seam image;
correcting the weld image according to the tilt angle;
intercepting a corrected welding line image according to a rectangular area to obtain a corrected welding line area image, wherein parameters of the rectangular area correspond to texture characteristics of the corrected welding line image;
the acquiring the inclination angle of the welding seam area in the welding seam image comprises the following steps:
acquiring a welding line image;
reducing the resolution of the weld image to obtain a small-size image;
Selecting a corresponding Gaussian Laplace operator template to carry out image enhancement on the small-size image according to the pixel width of the welding line area in the small-size image, so as to obtain an enhanced image;
performing self-adaptive binarization processing on the enhanced image to obtain a first binarized image;
acquiring a central line of a welding line area in the first binarization image;
performing straight line fitting on the central line to obtain an inclination angle of the central line;
the correcting the weld image according to the tilt angle includes:
acquiring a welding line image;
rotating the welding line image according to the inclination angle to obtain a rotated image;
removing the blank area of the rotated image to obtain a corrected weld image;
the determination of parameters of the rectangular region includes:
processing the corrected weld image by adopting an edge detection algorithm to obtain a texture image;
determining coordinate values of a rectangular area according to the texture image;
the determining the coordinate value of the rectangular area according to the texture image comprises the following steps:
performing self-adaptive binarization processing on the texture image to obtain a second binarization image;
removing interference information of the second binarized image to obtain a filtered image;
And determining coordinate values of the rectangular area according to the welding seam area in the filtered image.
2. The method of claim 1, further comprising, prior to reducing the resolution of the weld image to obtain a small-size image:
preprocessing the welding line image to obtain a first denoising image; correspondingly, the reducing the resolution of the welding seam image to obtain a small-size image comprises the following steps:
and reducing the resolution of the first denoising image to obtain a small-size image.
3. The method of claim 1, further comprising, prior to rotating the weld image according to the tilt angle, obtaining a rotated image:
preprocessing the welding line image to obtain a second denoising image; correspondingly, the rotating the welding seam image according to the inclination angle to obtain a rotated image comprises the following steps:
and rotating the second denoising image according to the inclination angle to obtain a rotated image.
4. A weld image processing apparatus, characterized by comprising:
the acquisition module is used for acquiring the inclination angle of the welding seam area in the welding seam image;
the method is also used for acquiring a weld image, reducing the resolution of the weld image and obtaining a small-size image; selecting a corresponding Gaussian Laplace operator template to carry out image enhancement on the small-size image according to the pixel width of the welding line area in the small-size image, so as to obtain an enhanced image; performing self-adaptive binarization processing on the enhanced image to obtain a first binarized image; acquiring a central line of a welding line area in the first binarization image; performing straight line fitting on the central line to obtain an inclination angle of the central line;
A correction module for correcting the weld image according to the inclination angle;
the method is also used for acquiring a welding line image, and rotating the welding line image according to the inclination angle to obtain a rotated image; removing the blank area of the rotated image to obtain a corrected weld image;
the intercepting module is used for intercepting the corrected welding line image according to the rectangular area to obtain the corrected welding line area image, and parameters of the rectangular area correspond to texture characteristics of the corrected welding line image;
the parameter determining module is used for processing the corrected weld joint image by adopting an edge detection algorithm to obtain a texture image; determining coordinate values of a rectangular area according to the texture image;
performing self-adaptive binarization processing on the texture image to obtain a second binarization image; removing interference information of the second binarized image to obtain a filtered image; and determining coordinate values of the rectangular area according to the welding seam area in the filtered image.
5. A terminal device, comprising:
one or more processors;
a storage means for storing one or more programs;
the one or more programs, when executed by the one or more processors, cause the one or more processors to implement the weld image processing method of any of claims 1-3.
6. A computer-readable storage medium, on which a computer program is stored, characterized in that the program, when being executed by a processor, implements the weld image processing method as claimed in any one of claims 1 to 3.
CN201811466376.6A 2018-12-03 2018-12-03 Weld image processing method and device, terminal equipment and storage medium Active CN111275659B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811466376.6A CN111275659B (en) 2018-12-03 2018-12-03 Weld image processing method and device, terminal equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811466376.6A CN111275659B (en) 2018-12-03 2018-12-03 Weld image processing method and device, terminal equipment and storage medium

Publications (2)

Publication Number Publication Date
CN111275659A CN111275659A (en) 2020-06-12
CN111275659B true CN111275659B (en) 2023-09-08

Family

ID=70999928

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811466376.6A Active CN111275659B (en) 2018-12-03 2018-12-03 Weld image processing method and device, terminal equipment and storage medium

Country Status (1)

Country Link
CN (1) CN111275659B (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114298964B (en) * 2021-10-08 2022-12-02 厦门微亚智能科技有限公司 Lithium battery module busbar welding line appearance detection algorithm and system
CN115953366A (en) * 2022-12-14 2023-04-11 广州市斯睿特智能科技有限公司 Weld joint detection method, system and device based on reflection image and storage medium
CN116012306A (en) * 2022-12-14 2023-04-25 广州市斯睿特智能科技有限公司 Weld joint detection method, system, device and storage medium based on offset correction
CN117173433A (en) * 2023-07-31 2023-12-05 苏州城市学院 Small-diameter pipe welding seam radiographic image similarity evaluation method

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2000155839A (en) * 1998-11-18 2000-06-06 Nippon Telegr & Teleph Corp <Ntt> Marked area image extraction method, device therefor and recoding medium recorded with marked area image extracting program
CN108280829A (en) * 2018-02-12 2018-07-13 广东省海洋工程装备技术研究所 Welding seam method, computer installation and computer readable storage medium
CN108355981A (en) * 2018-01-08 2018-08-03 西安交通大学 A kind of battery connector quality determining method based on machine vision

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9180552B2 (en) * 2013-05-27 2015-11-10 ThinkSmart IT Solutions Private Limited System and method for identifying defects in welds by processing X-ray images

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2000155839A (en) * 1998-11-18 2000-06-06 Nippon Telegr & Teleph Corp <Ntt> Marked area image extraction method, device therefor and recoding medium recorded with marked area image extracting program
CN108355981A (en) * 2018-01-08 2018-08-03 西安交通大学 A kind of battery connector quality determining method based on machine vision
CN108280829A (en) * 2018-02-12 2018-07-13 广东省海洋工程装备技术研究所 Welding seam method, computer installation and computer readable storage medium

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
杨波,汪同庆,吕永平,叶俊勇,任莉.利用动态结构元素提取直线.计算机辅助设计与图形学学报.2003,(04),全文. *

Also Published As

Publication number Publication date
CN111275659A (en) 2020-06-12

Similar Documents

Publication Publication Date Title
CN111275659B (en) Weld image processing method and device, terminal equipment and storage medium
US9180552B2 (en) System and method for identifying defects in welds by processing X-ray images
CN113436168B (en) Crack defect detection method for industrial welding line X-ray diagram
CN107038704B (en) Retina image exudation area segmentation method and device and computing equipment
CN107146231B (en) Retinal image bleeding area segmentation method and device and computing equipment
CN113077437B (en) Workpiece quality detection method and system
CN115908415B (en) Edge-based defect detection method, device, equipment and storage medium
CN110688871A (en) Edge detection method based on bar code identification
CN115661157B (en) Panel circle defect detection method, device, medium, equipment and program product
CN113155839A (en) Steel plate outer surface defect online detection method based on machine vision
CN112085700A (en) Automatic extraction method, system and medium for weld joint region in X-ray image
Li et al. Detection algorithm of defects on polyethylene gas pipe using image recognition
CN113269770A (en) Image enhancement method, system and equipment for visual defect detection
KR20180115645A (en) Apparatus for weld bead recognition of 2d image-based and soot removal method using the same
CN115294527A (en) Subway tunnel damage detection method based on computer vision
JP2019526865A (en) Particle boundary identification
CN117269179B (en) High-precision detection method and system for edge defects of contact lens based on machine vision
Reddy et al. Canny scale edge detection
CN102184529B (en) Empirical-mode-decomposition-based edge detecting method
Mahmoudi et al. Welding defect detection by segmentation of radiographic images
CN113066051A (en) Groove defect detection method, computing equipment and readable storage medium
CN117635590A (en) Defect detection method, defect detection device and storage medium for notebook computer shell
WO2024016686A1 (en) Corner detection method and apparatus
CN116381053A (en) Ultrasonic detection method and system for welding metal materials
Tao Enhanced Canny Algorithm for Image Edge Detection in Print Quality Assessment

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