CN114998325A - Air conditioner radiating tube welding defect detection method - Google Patents
Air conditioner radiating tube welding defect detection method Download PDFInfo
- Publication number
- CN114998325A CN114998325A CN202210844627.XA CN202210844627A CN114998325A CN 114998325 A CN114998325 A CN 114998325A CN 202210844627 A CN202210844627 A CN 202210844627A CN 114998325 A CN114998325 A CN 114998325A
- Authority
- CN
- China
- Prior art keywords
- reconstructed
- gray
- image
- band
- obtaining
- 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
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/0002—Inspection of images, e.g. flaw detection
- G06T7/0004—Industrial image inspection
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/10—Segmentation; Edge detection
- G06T7/13—Edge detection
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/10—Segmentation; Edge detection
- G06T7/136—Segmentation; Edge detection involving thresholding
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T2207/00—Indexing scheme for image analysis or image enhancement
- G06T2207/10—Image acquisition modality
- G06T2207/10004—Still image; Photographic image
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T2207/00—Indexing scheme for image analysis or image enhancement
- G06T2207/20—Special algorithmic details
- G06T2207/20048—Transform domain processing
- G06T2207/20056—Discrete and fast Fourier transform, [DFT, FFT]
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T2207/00—Indexing scheme for image analysis or image enhancement
- G06T2207/30—Subject of image; Context of image processing
- G06T2207/30108—Industrial image inspection
- G06T2207/30152—Solder
Landscapes
- Engineering & Computer Science (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Theoretical Computer Science (AREA)
- Quality & Reliability (AREA)
- Image Analysis (AREA)
Abstract
The invention relates to the technical field of image processing, in particular to a method for detecting welding defects of a radiating pipe of an air conditioner. The method comprises the following steps: obtaining a frequency spectrum diagram and a phase diagram of a gray scale diagram only containing a welding seam region; constructing a band elimination filter to filter the spectrogram to obtain a filtered spectrogram and simultaneously obtain a reconstructed gray-scale image; constructing a parameter optimization function of the band elimination filter based on texture filtering dilution, edge concentration and potential circle radius of the reconstructed gray level image; when the parameter optimization function obtains the minimum value, obtaining the optimal parameter of the band elimination filter to obtain the optimal band elimination filter; obtaining an optimal reconstruction gray map based on the optimal filtered spectrogram and phase map obtained by the optimal band-stop filter; and detecting the optimal reconstructed gray level image to obtain a welding defect area. The invention greatly improves the detection precision of the welding defect detection of the air-conditioner radiating pipe by weakening the influence of the scale marks on the surface of the welding seam and easily distinguishing the periodic scale marks from bubble defects.
Description
Technical Field
The invention relates to the technical field of image processing, in particular to a method for detecting welding defects of a radiating pipe of an air conditioner.
Background
The environment-friendly air conditioning equipment integrates cooling, ventilation, dust prevention and odor removal, is widely applied to various buildings, such as enterprise workshops, public places, commercial entertainment occasions and the like, not only has the basic ventilation and cooling functions of an air conditioner, but also has the functions of energy conservation and environment protection, and greatly saves the power consumption. The air conditioner radiating pipe is an important component of air conditioner refrigeration, and is an important part in air conditioner research and development production, the performance of the air conditioner radiating pipe directly influences the refrigeration effect and the power consumption, so that the welding quality of the air conditioner radiating pipe needs to be detected in the production process, and the performance of the air conditioner radiating pipe is ensured.
Most of the traditional detection methods for the welding quality of the radiating pipe of the air conditioner are judged based on the experience of workers, but the judgment accuracy is very low, and the welding defects are probably ignored in the detection process. With the development of image processing technology, a method for detecting the welding defects of the air-conditioning radiating pipe by using the image processing technology also appears, but the detection of the defects is influenced by the scale marks appearing on the surface of the welding seam during welding, so that the defect detection result is not good.
Disclosure of Invention
In order to solve the technical problems, the invention aims to provide a method for detecting welding defects of a radiating pipe of an air conditioner, which adopts the following technical scheme:
one embodiment of the invention provides a method for detecting welding defects of a radiating pipe of an air conditioner, which comprises the following steps: obtaining an image of the air-conditioning radiating pipe and preprocessing the image to obtain a gray scale image only containing a welding line area; obtaining a frequency spectrum diagram and a phase diagram of the gray scale diagram; obtaining a significant value of each pixel in the spectrogram by using an FT algorithm; setting a significance threshold value, wherein the maximum value of the distance from a pixel with a significance value larger than the significance threshold value to the center of the frequency spectrum in the frequency spectrum graph is a potential circle radius;
constructing band-stop filters with different parameters to respectively carry out multiple filtering on the spectrogram to obtain a filtered spectrogram, and obtaining a reconstructed gray-scale map based on the filtered spectrogram and the phase map; obtaining an inverse difference and a contrast of the reconstructed gray-scale image based on the gray-scale co-occurrence matrix of the reconstructed gray-scale image; the ratio of the inverse difference to the contrast is the texture filtering dilution of the reconstructed gray level image; obtaining the gradient amplitude of each pixel in the reconstructed gray image, and setting an edge threshold, wherein the pixel with the gradient amplitude larger than the edge threshold is an edge pixel; obtaining the edge concentration of the reconstructed gray-scale image by using the number of edge pixels in the reconstructed gray-scale image and the gradient amplitude of the edge pixels;
constructing a parameter optimization function of the band elimination filter based on the texture filtering dilution, the edge concentration and the potential ring radius of the reconstructed gray scale image; when the parameter optimization function obtains the minimum value, obtaining the optimal parameter of the band elimination filter; obtaining an optimal band-stop filter corresponding to each spectrogram by using the optimal parameters, and obtaining an optimal reconstructed gray scale map based on the optimal filtered spectrogram obtained by the optimal band-stop filter and the phase map; and detecting the welding defects based on the optimal reconstructed gray-scale map.
Preferably, obtaining an image of the radiating pipe of the air conditioner and preprocessing the image to obtain a gray-scale map only containing a welding seam area comprises: graying the RGB-format air-conditioning radiating pipe, removing noise and carrying out histogram equalization treatment to obtain a radiating pipe gray-scale image; and (4) utilizing an OTSU Otsu method to divide the grey-scale map of the radiating pipe to obtain the grey-scale map only containing the welding seam area.
Preferably, the constructing of the band-stop filters with different parameters to respectively perform multiple filtering on the spectrogram to obtain the filtered spectrogram includes: the transfer function of the band elimination filter is as follows:
wherein the content of the first and second substances,representing the transfer function of the band-stop filter;representing pixels on a spectrogramEuclidean distance to the center of the spectrum;andrespectively, the parameters of the band-stop filter,representing the distance from the center of the circular ring of the band-stop filter to the center of the spectrum,representing the width of the circular ring band of the band elimination filter; and filtering one spectrogram for multiple times by using band-stop filters with different parameters to obtain a filtered spectrogram.
Preferably, the obtaining of the inverse difference and the contrast of the reconstructed gray map based on the gray co-occurrence matrix of the reconstructed gray map comprises: and quantizing the gray level of the reconstructed gray level image, solving a gray level co-occurrence matrix of the quantized reconstructed gray level image, and calculating the inverse difference and the contrast of the reconstructed gray level image.
Preferably, obtaining the gradient magnitude of each pixel in the reconstructed gray scale map comprises: and solving the horizontal gradient and the vertical gradient of each pixel on the reconstructed gray scale image by using a sobel operator, calculating the gradient amplitude of each pixel and normalizing.
Preferably, the edge concentrations of the reconstructed gray scale map are:
wherein the content of the first and second substances,representing edge densities of the reconstructed gray scale map;representing the number of edge pixels in the reconstructed gray scale map;andrespectively representing the length and width of the reconstructed gray scale map,representing the number of pixels of the reconstructed gray scale map;representing a gradient magnitude of an ith one of the edge pixels;the value of the regulating parameter is 0.1.
wherein the content of the first and second substances,representing a parametric optimization function;representing the distance of the center of the circular ring of the band-stop filter from the center of the spectrum,representing the width of the circular ring of the band-stop filter;represents the texture filtering dilution of the reconstructed gray scale map,representing edge densities of the reconstructed gray scale map;represents a natural constant; the constraint conditions of the parameter optimization function are as follows:
Preferably, the detecting the welding defect based on the optimal reconstructed gray map comprises: and performing circle detection on the optimal reconstructed gray level image by adopting a Hough gradient circle detection algorithm, wherein if the circle is detected, the welding defect exists, and if the circle is not detected, the welding defect does not exist.
The embodiment of the invention at least has the following beneficial effects: during the process of welding the air-conditioning radiating pipe with other components, the surface of the welding seam presents a series of 'fish scale patterns' which are similar in size and shape and are arranged together at fixed intervals. The shape information of the circular arc-shaped bulges is similar to that of the circular bubble defect with a small target, the circular arc-shaped bulges are circular arcs, the gray scale information is similar, the circular arc-shaped bulges are all of a bulge structure, and the area is bright, namely the gray scale value is large. Similar shape and gray scale information brings great interference to the accurate positioning and contour extraction of bubble defects. Based on the fact that the scale marks have periodicity and have specific frequency characteristics in a frequency spectrum, a band-pass blocking filter is constructed to filter the scale marks, optimal parameters of the band-pass blocking filter are obtained, the effect of weakening the scale marks is achieved, the scale marks in the period are easily distinguished from bubble defects, and the detection precision of the bubble defects is greatly improved.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions and advantages of the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present invention, and other drawings can be obtained by those skilled in the art without creative efforts.
Fig. 1 is a flowchart of a method for detecting welding defects of a radiating pipe of an air conditioner according to the present invention.
Detailed Description
To further illustrate the technical means and effects of the present invention adopted to achieve the predetermined objects, the following detailed description will be given to a method for detecting welding defects of an air-conditioning heat dissipation tube according to the present invention, and the detailed implementation, structure, characteristics and effects thereof with reference to the accompanying drawings and the preferred embodiments. In the following description, the different references to "one embodiment" or "another embodiment" do not necessarily refer to the same embodiment. Furthermore, the particular features, structures, or characteristics may be combined in any suitable manner in one or more embodiments.
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 following describes a specific scheme of the method for detecting the welding defects of the radiating pipe of the air conditioner in detail with reference to the accompanying drawings.
Example (b):
the main application scenarios of the invention are as follows: in the process of welding the air-conditioning radiating pipe with other components, the surface of a welding seam presents a series of 'fish scale marks' which are in the shape of circular arc bulges with similar sizes and shapes and are arranged together at fixed intervals, the detection of welding defects is influenced by the 'fish scale marks', so that the interference of the 'fish scale marks' needs to be removed, and then the welding defect detection is carried out.
Referring to fig. 1, a flowchart of a method for detecting welding defects of a heat radiating pipe of an air conditioner according to an embodiment of the present invention is shown, where the method includes the following steps:
step S1, obtaining an image of the air-conditioner radiating pipe and preprocessing the image to obtain a gray scale image only containing a welding seam area; obtaining a frequency spectrum diagram and a phase diagram of the gray scale diagram; obtaining a significant value of each pixel in the spectrogram by using an FT algorithm; and setting a significance threshold value, wherein the maximum value of the distances from the pixels with significance values larger than the significance threshold value to the center of the spectrum in the spectrogram is the potential circle radius.
Firstly, obtaining an image of the air-conditioning radiating pipe, wherein the image of the air-conditioning radiating pipe is an image in an RGB format, graying the RGB-format air-conditioning radiating pipe, removing noise, and performing histogram equalization processing to obtain a radiating pipe grayscale map, wherein the noise is removed by using a Gaussian filter, and the histogram equalization can enhance the contrast of the radiating pipe grayscale map. Because the gray value difference of the welding line area relative to other areas of the air-conditioning radiating pipe at the outer side is large, and the gray value of the welding line area is large, the optimal gray threshold value is obtained by adopting the OTSU Otsu method to obtain the gray information of the pixels of the gray map of the radiating pipeMake the gray value greater thanAll the pixels are extracted, the minimum external rectangle surrounding the pixels is calculated for the pixels to serve as a welding seam area of the air-conditioning radiating pipe, a gray-scale image only containing the welding seam area is formed, and preferably, the size of the gray-scale image is。
Furthermore, when the air-conditioning radiating pipe is welded, bubbles can appear during welding due to impure welding gas or too low purity of the welding gas, and the bubbles on the surface of the welding seam seriously affect the strength and the tightness of the welding seam and are unqualified performance of the welding seam. Therefore, the detection and accurate positioning of the bubble defects of the welding line are needed, and the subsequent treatment of the welding line by technicians is facilitated. During the welding process, the surface of the welding seam presents a fish scale shape, namely a series of circular arc bulges with similar sizes and shapes are arranged together at fixed intervals, and the shape is called as a fish scale pattern. The shape information of the circular arc-shaped bulges is similar to that of the circular bubble defect with a small target, and the circular arc-shaped bulges are circular arcs, the gray scale information is similar, the circular arc-shaped bulges are of a convex structure, and the gray scale value is large. Similar shape and gray scale information causes great interference to the accurate positioning and contour extraction of bubble defects.
Thereby, the size is as followsGray scale map ofConverted into a two-dimensional complex matrix through two-dimensional fast Fourier transform:
Wherein the content of the first and second substances,is in the value range of,Is in the value range of,Representing imagesGo to the firstGo to the firstThe gray value of the pixel of the column,representing a two-dimensional complex matrixTo middleGo to the firstElements of a column;it can also be expressed in complex form:
wherein the content of the first and second substances,andrespectively represent a pluralityThe real and complex parts of (2).
Thereby obtaining a two-dimensional complex matrixTo middleGo to the firstThe phase of the column element;
thereby constructing a structureOf all elements of the matrixCorresponding phaseForm a phase diagramThus phase diagramCan be expressed as。
same, structureOf all elements of the matrixCorresponding amplitude valueForming a spectrogramSpectrogramsEach pixel in (1) is represented asThe spectrogram shows amplitude information corresponding to different frequencies, and the closer to the center of the spectrogram, the smaller the frequency.
Finally, for the spectrogram of the gray-scale image in the frequency domain, a band-elimination filter is required to be constructed to eliminate the influence of the fish scale on the spectrogram, and in order to achieve a good elimination effect, the optimal parameters of the band-elimination filter need to be obtained, so that the band-elimination filter is based on the spectrogramAmplitude information ofAlgorithm pair frequency spectrogramCarrying out significance solving to obtain a spectrogramThe significance value corresponding to each pixel in the image is set to be the significance value threshold valueThe maximum value of the distances from the pixels with the significant value larger than the significant threshold value to the center of the frequency spectrum is the potential circle radius. The potential circle radius is obtained to facilitate subsequent analysis and use.
Step S2, constructing band-stop filters with different parameters to respectively carry out multiple filtering on the spectrogram to obtain a filtered spectrogram, and obtaining a reconstructed grey-scale map based on the filtered spectrogram and the phase map; obtaining an inverse difference and a contrast of the reconstructed gray level image based on the gray level co-occurrence matrix of the reconstructed gray level image; the ratio of the inverse difference to the contrast is the texture filtering dilution of the reconstructed gray level image; obtaining the gradient amplitude of each pixel in the reconstructed gray image, and setting an edge threshold, wherein the pixel with the gradient amplitude larger than the edge threshold is an edge pixel; and obtaining the edge concentration of the reconstructed gray-scale image by using the number of the edge pixels in the reconstructed gray-scale image and the gradient amplitude of the edge pixels.
First, consider a gray scale mapThe "fish scale pattern" in (1) has periodicity, which has specific frequency characteristics in a frequency spectrum, i.e., appears in a frequency band with a certain width, and appears in a spectrogram as a concentric circle with the center of the spectrogram as a center. Therefore, the band-pass filter is adopted to filter the spectrogram, the spectrogram is positioned at the frequency band position of the periodic fish scale pattern, the amplitude in the frequency band is filtered, the periodic fish scale pattern is restrained, and the effect that the periodic fish scale pattern and the bubble defect area are easily distinguished is achieved.
Constructing band elimination filters with different parameters, wherein the transfer functions of the band elimination filters are as follows:
wherein the content of the first and second substances,representing the transfer function of the band-stop filter;on a frequency spectrum diagramPixelEuclidean distance to the center of the spectrum;andrespectively, the parameters of the band-stop filter,representing the distance of the center of the circular ring of the band-stop filter from the center of the spectrum,the width of a circular ring of a band-stop filter is indicated, wherein the width of the circular ring is also the bandwidth of frequencies that the band-stop filter does not allow to pass.
Since the parameters of the band stop filter are not knownAndthe best effect can be achieved when the fish scale line is eliminated, so that band-stop filters with different parameters are required to be arranged to filter the spectrogram to obtain a filtered spectrogram, and the filtered spectrogram and the phase diagram are obtainedCarrying out inverse operation to obtain a reconstructed gray map; based on the filtered spectrogram and the original phase diagramObtaining a two-dimensional complex matrixNew matrix of the same sizeIn particular, the complex form is obtained based on the magnitude information in the filtered spectrogram and the phase information in the original phase map, so that a new matrix can be obtainedPlural numbers corresponding to each position in the Chinese character, then pairAnd carrying out Fourier inversion to obtain a reconstructed image:
wherein the content of the first and second substances,representing the reconstructed gray scale imageGo to the firstThe gray value of the pixel of the column,representing a new matrixTo middleThe complex number of the element of row v column.
Further, for the reconstructed gray-scale image, if the period "fish scale" on the reconstructed gray-scale image is more suppressed and the bubble defect area is more obvious, the parameters of the band-elimination filter are more optimal. For the reconstructed gray-scale image, the periodic fish scale striations are inhibited and expressed in two aspects of texture change and gray-scale change, the texture grooves of the periodic fish scale striations become shallow, the change of local textures is small, the edge content in the reconstructed gray-scale image is small, the strength is weak, and the inhibition of the periodic fish scale striations is proved. Therefore, the texture and the edge of the reconstructed gray scale map need to be analyzed to obtain corresponding indexes to express the effect of eliminating the fish scale pattern.
Finally, extracting texture features in the reconstructed gray level image by adopting a gray level co-occurrence matrix, quantizing the gray level of the reconstructed gray level image, and obtaining the quantized gray levelObtaining the gray level co-occurrence matrix of the reconstructed gray level image and the contrast of the gray level co-occurrence matrixSum and inverse difference moment:
WhereinThe first to represent gray level co-occurrence matrixGo to the firstThe elements of the column. Wherein the contrast ratioReflecting the degree of depth of the grooves, texture, of the image textureThe deeper the furrows, the greater its contrast, the clearer the visual effect, the poorer the periodic "fish scale furrows" filtering effect in the reconstructed gray-scale image. Moment of adverse differenceReflecting the uniformity and homogeneity of image texture, inverse difference momentSmaller values of (A) indicate that the local texture change of the image is larger, the local texture is more uneven, and the filtering effect of the periodic fish scale texture is poorer. This gave the texture filtration dilution:
i.e. when the contrast is highSmaller, inverse momentThe larger the scale, the better the periodic "fish scale pattern" filtration effect, and the texture filtration dilutionThe larger.
Analyzing the gray information of the reconstructed gray map, and solving the gradient of each pixel in the reconstructed gray map in the horizontal direction by using a sobel operatorAnd gradient in vertical directionObtaining the gradient amplitude of each pixel:
normalizing the gradient amplitude of each pixel, and converting the gradient amplitude into an intervalIn the method, an edge threshold is set, preferably, the value of the edge threshold in this embodiment is 0.8, and in actual implementation, implementation personnel can determine the value of the edge threshold according to actual conditions; if the gradient amplitude of one pixel in the reconstructed gray-scale image is larger than the edge threshold, the pixel is an edge pixel, and the number of the edge pixels in the reconstructed gray-scale image is counted,Reflecting the content of the edge, and simultaneously solving a gradient amplitude average value before the normalization of the edge pixel, wherein the average value reflects the intensity of the edge, thereby obtaining the edge concentration of the reconstructed gray level image:
wherein the content of the first and second substances,representing edge densities of the reconstructed gray scale map;representing the number of edge pixels in the reconstructed gray scale map;andrespectively representing the length and width of the reconstructed gray scale map,number of pixels representing reconstructed gray scale mapAn amount;representing an unnormalized gradient magnitude of an ith one of the edge pixels;the adjustment parameters are expressed and can be determined by implementers according to actual conditions, and preferably, the value in the embodiment is 0.1; therefore, when the edge content in the reconstructed gray-scale image is less, the strength of the edge is less, and the edge concentrationThe smaller the filtration rate, the better the filtering effect on the periodic fish scale pattern.
Step S3, constructing a parameter optimization function of the band elimination filter based on the texture filtering dilution, the edge concentration and the potential ring radius of the reconstructed gray level image; when the parameter optimization function obtains the minimum value, obtaining the optimal parameter of the band elimination filter; obtaining an optimal band-stop filter corresponding to each spectrogram by using the optimal parameters, and obtaining an optimal reconstructed gray scale map based on the optimal filtered spectrogram obtained by the optimal band-stop filter and the phase map; and detecting the welding defects based on the optimal reconstructed gray map.
Firstly, when the parameters of the band elimination filter are solved, the optimal parameters enable the degree that periodic textures are inhibited and a bubble defect area is enhanced to be the maximum after the spectrogram is subjected to Fourier transform reconstruction after filtering, the band elimination filter with the optimal parameters acts on the spectrogram, periodic 'fish scale marks' are filtered, and the optimal reconstructed gray scale image is obtained. A parameter optimization function of the band-stop filter is thus constructed:
wherein the content of the first and second substances,indicates the parameter is excellentA function is transformed;representing the distance from the center of the circular ring of the band-stop filter to the center of the spectrum,representing the width of the circular ring of the band-stop filter;represents the texture filtering dilution of the reconstructed gray scale map,representing edge densities of the reconstructed gray scale map;represents a natural constant; the constraint conditions of the parameter optimization function are as follows:
wherein the content of the first and second substances,indicating the potential circle radius, i.e. containing a strong amplitude within the potential circle radius. The purpose of this is to adjust the parametersThe method is limited to search within the potential circle radius range, greatly reduces the calculated amount, ensures the accuracy of the solution of the global optimization algorithm, and simultaneously ensures the position of the circular ring beltIn thatThe purpose is to avoid the extreme case where the extent of the circular band of the image is too large to filter all the information of the image.
Further, under the condition of meeting the constraint conditions, a Particle Swarm Optimization (PSO) algorithm is adopted to pass through a parameter optimization functionDesigning particles with two attributes of speed and position, firstly, making random initialization of particles, evaluating every particle and judging parameter optimization functionWhether the global optimum is achieved or not is judged, if the global optimum is not achieved, the current speed and the current position of the particles are updated, the function adaptive value of each particle is evaluated at the same time, the global optimum position of the particle swarm is updated, at the moment, each particle is evaluated again, and the parameter optimization function is judgedWhether the optimal parameter of the band elimination filter is achieved or not is judged until the optimal parameter reaches the global optimal value, and when the optimal parameter reaches the global optimal value, namely the minimum value of the parameter optimization function under the condition of meeting the constraint condition, the optimal parameter of the band elimination filter is obtainedAndand obtaining the optimal band-stop filter.
It should be noted that the optimal band-stop filters corresponding to the spectrograms of each gray scale map may be the same or different, which is required to be shown according to the actual situation of the image, so that the spectrograms of each gray scale map correspond to one optimal band-stop filter. Filtering the spectrogram by using the optimal band-stop filter corresponding to each spectrogram to obtain optimal filtered spectrogramThen through the optimal filtered spectrogram and the original phase mapAnd performing Fourier inversion to obtain an optimal reconstructed gray image.
Finally, for the optimal reconstructed gray level image, the scale pattern is greatly weakened, the influence on the bubble defect of the small circular bulge of the target is greatly reduced, and the defect detection precision is greatly improved. Therefore, circle detection is carried out on the optimal reconstruction gray-scale image by adopting a Hough gradient circle detection algorithm, if the circle is detected, the fact that the welding seam area of the air-conditioning radiating pipe contains the bubble defect is indicated, and if the circle is not detected, the fact that the welding seam area of the air-conditioning radiating pipe does not contain the bubble defect is indicated, so that the defect detection of the welding seam area of the air-conditioning radiating pipe is completed.
It should be noted that: the precedence order of the above embodiments of the present invention is only for description, and does not represent the merits of the embodiments. And specific embodiments thereof have been described above. In addition, the processes depicted in the accompanying figures do not necessarily require the particular order shown, or sequential order, to achieve desirable results. In some embodiments, multitasking and parallel processing may also be possible or may be advantageous.
All the embodiments in the present specification are described in a progressive manner, and the same and similar parts among the embodiments are referred to each other, and each embodiment focuses on the differences from other embodiments.
The above description is only for the purpose of illustrating the preferred embodiments of the present invention and should not be taken as limiting the scope of the present invention, which is intended to cover any modifications, equivalents, improvements, etc. within the spirit and scope of the present invention.
Claims (8)
1. A method for detecting welding defects of a radiating pipe of an air conditioner is characterized by comprising the following steps: obtaining an image of the air-conditioning radiating pipe and preprocessing the image to obtain a gray scale image only containing a welding line area; obtaining a frequency spectrum diagram and a phase diagram of the gray scale diagram; obtaining a significant value of each pixel in the spectrogram by using an FT algorithm; setting a significance threshold value, wherein the maximum value of the distance from a pixel with a significance value larger than the significance threshold value to the center of the frequency spectrum in the frequency spectrum graph is a potential circle radius;
constructing band-stop filters with different parameters to respectively carry out multiple filtering on the spectrogram to obtain a filtered spectrogram, and obtaining a reconstructed gray-scale map based on the filtered spectrogram and the phase map; obtaining an inverse difference and a contrast of the reconstructed gray-scale image based on the gray-scale co-occurrence matrix of the reconstructed gray-scale image; the ratio of the inverse difference to the contrast is the texture filtering dilution of the reconstructed gray level image; obtaining the gradient amplitude of each pixel in the reconstructed gray image, and setting an edge threshold, wherein the pixel with the gradient amplitude larger than the edge threshold is an edge pixel; obtaining the edge concentration of the reconstructed gray-scale image by using the number of edge pixels in the reconstructed gray-scale image and the gradient amplitude of the edge pixels;
constructing a parameter optimization function of the band elimination filter based on the texture filtering dilution, the edge concentration and the potential ring radius of the reconstructed gray scale image; when the parameter optimization function obtains the minimum value, obtaining the optimal parameter of the band elimination filter; obtaining an optimal band-stop filter corresponding to each spectrogram by using the optimal parameters, and obtaining an optimal reconstructed gray scale map based on the optimal filtered spectrogram obtained by the optimal band-stop filter and the phase map; and detecting the welding defects based on the optimal reconstructed gray-scale map.
2. The method for detecting the welding defects of the radiating pipe of the air conditioner as claimed in claim 1, wherein the step of obtaining the image of the radiating pipe of the air conditioner and preprocessing the image to obtain the gray-scale map only containing the welding seam area comprises the steps of: graying the radiating pipe of the air conditioner in the RGB format and carrying out noise removal and histogram equalization treatment to obtain a gray level diagram of the radiating pipe; and (4) utilizing an OTSU Otsu method to divide the grey-scale map of the radiating pipe to obtain the grey-scale map only containing the welding seam area.
3. The method for detecting the welding defects of the radiating pipe of the air conditioner as claimed in claim 1, wherein the step of constructing band-stop filters with different parameters to respectively filter the spectrogram for multiple times to obtain a filtered spectrogram comprises the steps of: the transfer function of the band elimination filter is as follows:
wherein the content of the first and second substances,representing the transfer function of the band-stop filter;representing pixels on a spectrogramEuclidean distance to the center of the spectrum;andrespectively, the parameters of the band-stop filter,representing the distance from the center of the circular ring of the band-stop filter to the center of the spectrum,representing the width of the circular ring of the band-stop filter; and filtering one spectrogram for multiple times by using band-stop filters with different parameters to obtain a filtered spectrogram.
4. The air conditioner radiating pipe welding defect detection method of claim 1, wherein the obtaining of the inverse difference and the contrast of the reconstructed gray-scale map based on the gray-scale co-occurrence matrix of the reconstructed gray-scale map comprises: and quantizing the gray level of the reconstructed gray level image, solving a gray level co-occurrence matrix of the quantized reconstructed gray level image, and calculating the inverse difference and the contrast of the reconstructed gray level image.
5. The method for detecting the welding defects of the radiating pipe of the air conditioner as claimed in claim 1, wherein the obtaining the gradient magnitude of each pixel in the reconstructed gray scale map comprises: and solving the horizontal gradient and the vertical gradient of each pixel on the reconstructed gray scale image by using a sobel operator, calculating the gradient amplitude of each pixel and normalizing.
6. The method for detecting the welding defects of the radiating pipe of the air conditioner as claimed in claim 1, wherein the edge concentrations of the reconstructed gray scale map are as follows:
wherein the content of the first and second substances,representing edge densities of the reconstructed gray scale map;representing the number of edge pixels in the reconstructed gray scale map;andrespectively representing the length and width of the reconstructed gray scale map,representing the number of pixels of the reconstructed gray scale map;representing a gradient magnitude of an ith one of the edge pixels;the adjustment parameter is represented, and the value is 0.1.
7. The method for detecting the welding defects of the radiating pipe of the air conditioner as claimed in claim 1, wherein the parameter optimization function is:
wherein the content of the first and second substances,representing a parametric optimization function;representing the distance from the center of the circular ring of the band-stop filter to the center of the spectrum,representing the width of the circular ring of the band-stop filter;texture filtering dilution representing the reconstructed gray scale map,representing edge densities of the reconstructed gray scale map;represents a natural constant; the constraint conditions of the parameter optimization function are as follows:
8. The method for detecting the welding defects of the radiating pipe of the air conditioner as claimed in claim 1, wherein the detecting the welding defects based on the optimal reconstructed gray scale map comprises: and performing circle detection on the optimal reconstructed gray level image by adopting a Hough gradient circle detection algorithm, wherein if the circle is detected, a welding defect exists, and if the circle is not detected, the welding defect does not exist.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202210844627.XA CN114998325B (en) | 2022-07-19 | 2022-07-19 | Air conditioner radiating tube welding defect detection method |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202210844627.XA CN114998325B (en) | 2022-07-19 | 2022-07-19 | Air conditioner radiating tube welding defect detection method |
Publications (2)
Publication Number | Publication Date |
---|---|
CN114998325A true CN114998325A (en) | 2022-09-02 |
CN114998325B CN114998325B (en) | 2022-10-25 |
Family
ID=83022599
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202210844627.XA Active CN114998325B (en) | 2022-07-19 | 2022-07-19 | Air conditioner radiating tube welding defect detection method |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN114998325B (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN115830013A (en) * | 2023-02-08 | 2023-03-21 | 磐石重工(青岛)股份有限公司 | Machine vision-based method for detecting weld defects of pressure vessel |
CN117670842A (en) * | 2023-12-07 | 2024-03-08 | 常州市宏发纵横新材料科技股份有限公司 | Cloth cover horizontal bar detection method, device, equipment and storage medium |
Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107248158A (en) * | 2017-07-20 | 2017-10-13 | 广东工业大学 | A kind of method and system of image procossing |
CN111311510A (en) * | 2020-01-22 | 2020-06-19 | 京东方科技集团股份有限公司 | Method and device for removing stripe noise in image |
CN112862888A (en) * | 2021-01-29 | 2021-05-28 | 广东电网有限责任公司 | Cable positioning method and device, computer equipment and storage medium |
CN112910348A (en) * | 2021-01-26 | 2021-06-04 | 西安交通大学 | Parallel structure frequency spectrum optimization method and system based on model predictive control |
CN113643294A (en) * | 2021-10-14 | 2021-11-12 | 江苏祥顺布业有限公司 | Textile defect self-adaptive detection method based on frequency spectrum analysis |
CN114384520A (en) * | 2022-03-24 | 2022-04-22 | 中国人民解放军火箭军工程大学 | Method for realizing refined radar imaging of sea surface ship by using maneuvering platform |
WO2022083910A1 (en) * | 2020-10-23 | 2022-04-28 | Bayerische Motoren Werke Aktiengesellschaft | Device for evaluating image data in a motor vehicle |
-
2022
- 2022-07-19 CN CN202210844627.XA patent/CN114998325B/en active Active
Patent Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107248158A (en) * | 2017-07-20 | 2017-10-13 | 广东工业大学 | A kind of method and system of image procossing |
CN111311510A (en) * | 2020-01-22 | 2020-06-19 | 京东方科技集团股份有限公司 | Method and device for removing stripe noise in image |
WO2022083910A1 (en) * | 2020-10-23 | 2022-04-28 | Bayerische Motoren Werke Aktiengesellschaft | Device for evaluating image data in a motor vehicle |
CN112910348A (en) * | 2021-01-26 | 2021-06-04 | 西安交通大学 | Parallel structure frequency spectrum optimization method and system based on model predictive control |
CN112862888A (en) * | 2021-01-29 | 2021-05-28 | 广东电网有限责任公司 | Cable positioning method and device, computer equipment and storage medium |
CN113643294A (en) * | 2021-10-14 | 2021-11-12 | 江苏祥顺布业有限公司 | Textile defect self-adaptive detection method based on frequency spectrum analysis |
CN114384520A (en) * | 2022-03-24 | 2022-04-22 | 中国人民解放军火箭军工程大学 | Method for realizing refined radar imaging of sea surface ship by using maneuvering platform |
Non-Patent Citations (4)
Title |
---|
SREEPRASAD AJITHAPRASAD 等: "Defect detection using windowed Fourier spectrum analysis in diffraction phase microscopy", 《JOURNAL OF PHYSICS COMMUNICATIONS》 * |
XIAOLONG BAI 等: "Saliency-Based Defect Detection in Industrial Images by Using Phase Spectrum", 《IEEE TRANSACTIONS ON INDUSTRIAL INFORMATICS》 * |
张雪侠: "相位信息遥感图像边缘检测方法的实例检测分析", 《中国锰业》 * |
苏飞 等: "基于全相位滤波器的3D图像恢复处理算法", 《天津理工大学学报》 * |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN115830013A (en) * | 2023-02-08 | 2023-03-21 | 磐石重工(青岛)股份有限公司 | Machine vision-based method for detecting weld defects of pressure vessel |
CN117670842A (en) * | 2023-12-07 | 2024-03-08 | 常州市宏发纵横新材料科技股份有限公司 | Cloth cover horizontal bar detection method, device, equipment and storage medium |
CN117670842B (en) * | 2023-12-07 | 2024-06-04 | 常州市宏发纵横新材料科技股份有限公司 | Cloth cover horizontal bar detection method, device, equipment and storage medium |
Also Published As
Publication number | Publication date |
---|---|
CN114998325B (en) | 2022-10-25 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN114998325B (en) | Air conditioner radiating tube welding defect detection method | |
CN107808378B (en) | Method for detecting potential defects of complex-structure casting based on vertical longitudinal and transverse line profile features | |
CN113538433B (en) | Mechanical casting defect detection method and system based on artificial intelligence | |
CN107220988B (en) | Part image edge extraction method based on improved canny operator | |
CN116168026B (en) | Water quality detection method and system based on computer vision | |
CN107292310B (en) | Visual positioning and automatic reading method for circular pointer type dial plate | |
CN115619793B (en) | Power adapter appearance quality detection method based on computer vision | |
WO2021109697A1 (en) | Character segmentation method and apparatus, and computer-readable storage medium | |
CN115359044B (en) | Metal part surface scratch detection method based on image enhancement | |
CN115272321B (en) | Textile defect detection method based on machine vision | |
CN115115642A (en) | Strip steel scab defect detection method based on image processing | |
CN103325118A (en) | Method and device for acquiring characteristic parameters of core hole of carbonatite | |
CN115601368B (en) | Sheet metal part defect detection method for building material equipment | |
CN116823822B (en) | Ship sheet metal part welding defect detection method based on visual characteristics | |
CN110473194A (en) | Fruit surface defect detection method based on more image block Threshold Segmentation Algorithms | |
CN107590512A (en) | The adaptive approach and system of parameter in a kind of template matches | |
CN105225244A (en) | Based on the noise detection method that minimum local mean square deviation calculates | |
CN114998311A (en) | Part precision detection method based on homomorphic filtering | |
WO2020114134A1 (en) | Visual processing method for identifying emery particles | |
CN107545549B (en) | Method for estimating scattered focus point spread function based on one-dimensional spectrum curve | |
CN116524205A (en) | Sewage aeration automatic detection and identification method | |
CN103455985A (en) | Road crack enhancement method based on Hessian structural analysis | |
CN111815575B (en) | Bearing steel ball part detection method based on machine vision | |
CN110751687B (en) | Apple size grading method based on computer vision minimum and maximum circle | |
CN102509265A (en) | Digital image denoising method based on gray value difference and local energy |
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 |