CN117635606B - Method, device, equipment and storage medium for detecting chuck defects of laser pipe cutting machine - Google Patents

Method, device, equipment and storage medium for detecting chuck defects of laser pipe cutting machine Download PDF

Info

Publication number
CN117635606B
CN117635606B CN202410092812.7A CN202410092812A CN117635606B CN 117635606 B CN117635606 B CN 117635606B CN 202410092812 A CN202410092812 A CN 202410092812A CN 117635606 B CN117635606 B CN 117635606B
Authority
CN
China
Prior art keywords
chuck
information
spectrum
frequency band
image sequence
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
CN202410092812.7A
Other languages
Chinese (zh)
Other versions
CN117635606A (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.)
Ruika Changzhou Technology Co ltd
Original Assignee
Ruika Changzhou Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Ruika Changzhou Technology Co ltd filed Critical Ruika Changzhou Technology Co ltd
Priority to CN202410092812.7A priority Critical patent/CN117635606B/en
Publication of CN117635606A publication Critical patent/CN117635606A/en
Application granted granted Critical
Publication of CN117635606B publication Critical patent/CN117635606B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • 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

  • Image Analysis (AREA)

Abstract

The invention relates to the field of defect detection, and discloses a method, a device, equipment and a storage medium for detecting a chuck defect of a laser pipe cutting machine, which are used for solving the problems and improving the detection accuracy and generalization capability through targeted data preprocessing, multi-feature fusion, model optimization and other technical means. The method comprises the steps of data acquisition, image processing, spectrum analysis and model establishment, wherein first, the surface image of a chuck is acquired, and reflection separation and reinforcement treatment are carried out. Then, defect characteristics are extracted through differentiation and morphological operations, and defect boundaries are identified and located. And then, establishing an evaluation model according to the frequency band information, performing time-frequency analysis on the image sequence to be identified of the chuck, extracting the frequency band to be identified, and finally obtaining a defect detection result. The method has the advantages of high accuracy and reliability, real-time performance, good generalization capability, reduced sensitivity to complex background and noise, expandability, flexibility and the like, and provides powerful support for defect detection in the field of industrial manufacturing.

Description

Method, device, equipment and storage medium for detecting chuck defects of laser pipe cutting machine
Technical Field
The present invention relates to the field of defect detection, and in particular, to a method, apparatus, device, and storage medium for detecting a defect of a chuck of a laser pipe cutting machine.
Background
With the rapid development of industrial automation, the laser pipe cutting machine is widely applied in the field of metal processing. The chuck is used as a key component in a laser pipe cutting machine, and the performance of the chuck directly influences the cutting quality and efficiency. However, chucks are susceptible to various factors (e.g., high temperature, friction, corrosion, etc.) during long term use, resulting in surface defects. These defects not only affect the accuracy and stability of the chuck, but may also lead to safety accidents in severe cases. Therefore, the defect detection of the chuck of the laser pipe cutting machine has important practical significance.
In recent years, with rapid development of machine vision and deep learning technologies, more and more automated defect detection methods are applied to defect detection of a chuck of a laser pipe cutting machine. The defects on the surface of the chuck can be rapidly and accurately identified through image processing and pattern identification technologies.
Although the existing automated defect detection methods can achieve better effects in certain situations, some disadvantages still exist: data preprocessing lacks pertinence: existing methods generally employ a general method during the data preprocessing stage, and lack in-depth consideration of chuck surface characteristics. Since reflection characteristics, texture characteristics and the like of the chuck surface are critical to subsequent defect detection, a more targeted data preprocessing method is required to improve the detection accuracy; the feature extraction is insufficient: in the aspect of feature extraction, the existing method only usually considers the gray information of the image, and ignores other important features such as color, texture and the like. These features are critical to distinguishing between different types of defects. Therefore, how to fully extract these features is a key to improve detection accuracy; the model has insufficient generalization capability: since the types of defects on the chuck surface are various and the difference between the different types may be small, a defect detection model is required to have a good generalization ability. However, existing models often behave differently when faced with different types of defects, resulting in limited generalization ability of the model; real-time performance is poor: in a practical production environment, a fast response is required for defect detection of the chuck. However, the existing method is difficult to meet the requirement of real-time performance due to high calculation complexity, long processing time and the like; poor robustness to complex background and noise: in an industrial environment, the background of the chuck surface tends to be complex and noise disturbances may be present. This can lead to some small defects being masked or misjudged, thereby affecting the accuracy of the detection; lack of an effective authentication mechanism: existing methods often focus only on the training and testing process of the model, and lack an effective verification mechanism to ensure performance of the model in an actual production environment. This may result in the model not being found and resolved in time when problems occur in the actual application; in order to overcome the defects, the laser pipe cutting machine chuck defect detection method based on machine vision and deep learning is provided.
In summary, the existing automated defect detection method still has shortcomings in terms of data preprocessing, feature extraction, model generalization capability, instantaneity, robustness to complex background and noise, verification mechanism and the like. The method aims to solve the problems and improve the detection accuracy and generalization capability through targeted data preprocessing, multi-feature fusion, model optimization and other technical means.
Disclosure of Invention
The invention provides a method, a device, equipment and a storage medium for detecting the chuck defects of a laser pipe cutting machine, which are used for solving the problems and improving the detection accuracy and generalization capability through the technical means of targeted data preprocessing, multi-feature fusion, model optimization and the like.
The first aspect of the invention provides a method for detecting the defects of a chuck of a laser pipe cutting machine, which comprises the following steps: carrying out data acquisition on the surface of a chuck to obtain a real chuck image sequence and a chuck to-be-identified image sequence, wherein the real chuck image sequence comprises a training real chuck image sequence and a target real chuck image sequence, and carrying out reflection separation according to the target real chuck image sequence to obtain a plurality of chuck reflection separation images; performing first space transformation according to the multiple chuck reflection separation images to obtain first chuck spectrum center of gravity information and first chuck kurtosis information corresponding to the transformation of the multiple chuck reflection separation images, and performing second space transformation according to the multiple chuck reflection separation images to obtain second chuck spectrum center of gravity information and second chuck kurtosis information corresponding to the transformation of the multiple chuck reflection separation images; spatial convergence is carried out through the first chuck spectrum center of gravity information and the second chuck spectrum center of gravity information to obtain target frequency band information corresponding to the multiple reflection separation images, and spectrogram processing is carried out according to the first chuck kurtosis information, the second chuck kurtosis information and the target frequency band to obtain chuck correction frequency band information; carrying out additional extraction on the chuck correction frequency band information to obtain chuck amplitude information and chuck phase information, carrying out classification processing on the chuck amplitude information and the chuck phase information, decomposing to obtain a plurality of substantial frequency bands, and respectively establishing a plurality of corresponding evaluation models according to the plurality of frequency bands; decomposing according to the chuck image sequence to be identified to obtain a plurality of frequency bands to be identified; and combining the plurality of evaluation models according to the plurality of frequency bands to be identified, outputting to obtain a plurality of analysis data representations, and obtaining a laser pipe cutting machine chuck defect detection result according to the plurality of analysis data representations.
Optionally, in a first implementation manner of the first aspect of the present invention, the acquiring data on a chuck surface to obtain a real chuck image sequence and a chuck image sequence to be identified, where the real chuck image sequence includes a training real chuck image sequence and a target real chuck image sequence, and performing reflection separation according to the target real chuck image sequence to obtain a plurality of chuck reflection separation images includes: performing reinforcement treatment on the target real chuck image sequence to obtain a reinforced real chuck image sequence, and performing background extraction according to the reinforced real chuck image sequence to obtain reflection-free image information; comparing the target real chuck image sequence with the non-reflection image information, calculating the difference between the target real chuck image sequence and the non-reflection image information through differentiation processing, generating a reflection image sequence according to the differentiation processing result, wherein the reflection image sequence can highlight the reflection characteristics of the defects on the surface of the chuck, threshold segmentation is carried out on the reflection image sequence, the reflection areas are separated, morphological operation is carried out, noise and small isolated areas are removed, the main reflection areas are highlighted, then edge detection is used for extracting the edge information of the reflection areas, the boundaries of the defects are identified and positioned, each reflection area is segmented according to the edge detection result, and corresponding multiple chuck reflection separated images are extracted from the original images.
Optionally, in a second implementation manner of the first aspect of the present invention, performing a first spatial transformation according to the multiple-chuck reflection separation images to obtain first chuck spectrum center of gravity information and first chuck kurtosis information corresponding to the multiple-chuck reflection separation images, performing a second spatial transformation according to the multiple-chuck reflection separation images to obtain second chuck spectrum center of gravity information and second chuck kurtosis information corresponding to the multiple-chuck reflection separation images, and includes: obtaining amplitude spectrum information and frequency information according to the reflected and separated images of the chucks, and transforming through the following formula: centroid_x=sum (amplitude_spectrum)/sum (amplitude_spectrum), wherein centroid_x is the spectrum barycentric coordinate, amplitude_spectrum is the amplitude spectrum, frequency is the frequency; kurtosis = sum (magnitude_spectrum)/std) 4/N, where kurtosis is kurtosis information, magnitude_spectrum is an amplitude spectrum, mean is a mean value of the spectrum, std is a standard deviation of the spectrum, N is a length of the spectrum, and (magnitude_spectrum_mean/std) 4 represents dividing each amplitude spectrum value by the standard deviation after subtracting the mean value, and then performing a fourth-order operation on the result.
Optionally, in a third implementation manner of the first aspect of the present invention, the spatially converging the first chuck spectrum center of gravity information and the second chuck spectrum center of gravity information to obtain target frequency band information corresponding to the multiple reflection separation images, and performing spectrogram processing according to the first chuck kurtosis information, the second chuck kurtosis information and the target frequency band to obtain chuck correction frequency band information, where the obtaining includes: determining a region needing space convergence according to the distribution condition of the first chuck spectrum center of gravity information and the second chuck spectrum center of gravity information, setting an intensity threshold value as K, judging whether the region needs space convergence according to the intensity threshold value K, and when the center of gravity intensity of a certain region exceeds the intensity threshold value K, the region needs space convergence; performing spatial fusion operation on the first chuck spectrum center of gravity information and the second chuck spectrum center of gravity information by using image fusion to obtain Fused spectrum information, and extracting target frequency band information from the Fused spectrum information, wherein the Fused spectrum center of gravity is Fused (f) =w1×c1 (f) +w2×c2 (f) if the weights of the image fusion are set to be w1 and w2 respectively; c1 (f 1) is first chuck spectrum centroid information, and C2 (f 2) is first chuck spectrum centroid information: c (f) =Σ (E (f) ×f)/Σe (f), wherein E (f) represents energy at frequency f in the spectrogram; let the target frequency band be [ f_min, f_max ], extract the energy information in this frequency band, then: target_energy=Σ (Fused (f) ×f > =f_min) ×f < =f_max)), wherein (f > =f_min) ×f < =f_max) is a logic function for determining whether the frequency is within the Target frequency band, f_min and f_max are the lower limit and the upper limit of the Target frequency band, target_energy is the Energy information within the extracted Target frequency band, and is used for analyzing or comparing with a preset threshold, fused (f) represents the center of gravity of the spectrum after merging; and combining the target frequency band according to the first chuck kurtosis information and the second chuck kurtosis information to serve as input parameters, performing spectrogram processing, filtering the spectrum data by using a filter, removing information of other frequency bands, only preserving information of the target frequency band, and extracting to obtain chuck correction frequency band information.
Optionally, in a fourth implementation manner of the first aspect of the present invention, the additionally extracting the chuck correction frequency band information to obtain chuck amplitude information and chuck phase information, performing classification processing through the chuck amplitude information and the chuck phase information, decomposing to obtain a plurality of substantial frequency bands, and respectively establishing and obtaining a plurality of corresponding evaluation models according to the plurality of frequency bands, where the method includes: according to each data point of the spectrogram of the chuck correction frequency band information, the selected window function is applied to the spectrogram, the spectrogram is windowed by multiplying the window function and the spectrogram, the amplitude value of each frequency component is calculated to obtain chuck amplitude information, and the window function is set to be (w (n)), then: w (N) = \alpha- \beta\cos\left (\frac {2\pi N } { N-1} \right), wherein (N) is an index of discrete time points, (N) is a length of the window function, (\alpha) and (\beta) are parameters of the window function for adjusting a shape of the window function, (\cos\left (\frac {2\pi N } { N-1} \right)) is a cosine function; setting the spectrogram as X (k), the window function as w (n), and the spectrogram after windowing as X_w (k), then: x_w (k) =x (k) \times w (k); a (k) = |x_w (k) |; wherein a (k) represents the magnitude value of the (k) th frequency component, ||represents the absolute value operation in the modulo operation, \times represents the multiplication operation; calculating phase differences between adjacent frequency points in a spectrogram of the chuck correction frequency band information to obtain chuck phase information, and setting the spectrogram as X (k), wherein: ΔΦ=arg (X (k_i+1)) -arg (X (k_i)); where arg () represents the phase angle, Δφ represents the phase difference between frequencies k_i+1 and k_i; setting a threshold value D according to the chuck amplitude information, removing frequency components with the amplitude lower than the threshold value D, and reserving frequency division rate components; for the frequency-division-by-number frequency components, judging the continuity of the phase by comparing the chuck phase information with a threshold value Q, judging the phase difference as belonging to the same substantial frequency band if the phase difference is smaller than the threshold value Q, and representing the obtained substantial frequency band by saving the starting frequency and the ending frequency of the substantial frequency band and/or saving the center frequency and the bandwidth of the substantial frequency band; the virtual frequency bands comprise data input features and target defect labels, for each virtual frequency band, a gradient lifting tree is used for establishing a corresponding evaluation model, each evaluation model is trained for one virtual frequency band, for each evaluation model, model training is performed by using the data input features and the target defect labels of the corresponding virtual frequency band, and cross verification is adopted for optimizing parameters and generalization capacity of the model, so that a plurality of corresponding evaluation models are obtained; and verifying and training the obtained evaluation model according to the data of the training real chuck image sequence, and updating to obtain the evaluation model.
Optionally, in a fifth implementation manner of the first aspect of the present invention, the decomposing to obtain a plurality of frequency bands to be identified according to the image sequence to be identified of the chuck, combining the plurality of evaluation models according to the plurality of frequency bands to be identified, outputting to obtain a plurality of analysis data representations, and obtaining a detection result of the chuck defect of the laser pipe cutting machine according to the plurality of analysis data representations includes: performing time-frequency analysis on the chuck to-be-identified image sequence, applying short-time Fourier transform on each image of the chuck to-be-identified image sequence, dividing a signal into a plurality of time windows, and transforming on each window to obtain a time-frequency representation, and extracting a to-be-identified frequency band with obvious energy or characteristics from the time-frequency representation by using a threshold value and/or energy distribution; combining the frequency bands to be identified into an evaluation model as data input, wherein the output label of the evaluation model is represented by a plurality of pieces of analysis data; setting an overlapping threshold M for determining when two detection results are considered to be adjacent or overlapped, sequencing the detection results of each category according to the confidence level, starting from the detection result with the highest confidence level, retaining the detection result, removing other detection results which are overlapped with the detection result and exceed the overlapping threshold M, and repeating the process until all the detection results are processed; and (3) carrying out connectivity analysis on the reserved detection results to combine adjacent overlapping results, searching the adjacent detection results by using a graph traversal algorithm, calculating the overlapping areas of the adjacent detection results, and determining whether to combine the adjacent detection results into a larger detection result according to the overlapping area and the overlapping proportion, wherein the results are used as final detection results of the chuck defects of the laser pipe cutting machine.
Optionally, in a sixth implementation manner of the first aspect of the present invention, the performing connectivity analysis on the retained detection results to combine adjacent overlapping results, searching adjacent detection results using a graph traversal algorithm, calculating overlapping areas of adjacent detection results, and determining whether to combine them into a larger detection result according to the overlapping area and the overlapping proportion, where the results are used as final detection results of the chuck defect of the laser pipe cutting machine, where the steps include: defining adjacent detection results under the condition that the overlapping area of the detection results is larger than an overlapping threshold L, defining a graph data structure comprising nodes and edges, wherein each node represents one detection result and comprises a unique identifier and boundary frame coordinate information, traversing all detection results, creating a node for each detection result, and adding the node to a graph; traversing each node in the graph, calculating the overlapping area of each pair of nodes, adding an edge between each pair of nodes if the overlapping area is larger than an overlapping threshold L, traversing the nodes in the graph from any node in the graph, and marking the accessed nodes; in the traversing process, adjacent non-access nodes are found, the overlapping area of the non-access nodes is calculated, if the overlapping area is larger than the overlapping threshold L, the non-access nodes are combined into a larger detection result, the two detection results are combined through expanding a boundary box, and after the traversing is finished, the non-combined detection result is reserved as a final laser pipe cutting machine chuck defect detection result.
The second aspect of the present invention provides a laser pipe cutting machine chuck defect detection device, the laser pipe cutting machine chuck defect detection device includes: the acquisition module is used for acquiring data of the chuck surface and acquiring a real chuck image sequence and a chuck image sequence to be identified; the processing module is used for carrying out space transformation on the reflection separation images of the plurality of chucks to obtain corresponding frequency spectrum gravity center information and kurtosis information, then carrying out space merging operation to obtain target frequency band information, carrying out spectrogram processing according to the target frequency band information and the kurtosis information, and extracting chuck correction frequency band information; the setting module is used for carrying out additional extraction on the chuck correction frequency band information to obtain chuck amplitude information and phase information, then carrying out classification processing according to the amplitude information and the phase information, decomposing to obtain a plurality of substantial frequency bands, establishing a corresponding evaluation model aiming at each substantial frequency band, training by using a gradient lifting tree, and optimizing parameters and generalization capacity of the model by adopting cross verification; the detection module is used for carrying out time-frequency analysis on the image sequence to be identified of the chuck, extracting a frequency band to be identified, then combining the frequency band to be identified with the evaluation model, outputting a plurality of analysis data representations, and finally obtaining a detection result of the chuck defect of the laser pipe cutting machine according to the plurality of analysis data representations.
Optionally, in a first implementation manner of the second aspect of the present invention, the acquiring module is specifically configured to: performing reinforcement treatment on the target real chuck image sequence to obtain a reinforced real chuck image sequence, and performing background extraction according to the reinforced real chuck image sequence to obtain reflection-free image information; comparing the target real chuck image sequence with the non-reflection image information, calculating the difference between the target real chuck image sequence and the non-reflection image information through differentiation processing, generating a reflection image sequence according to the differentiation processing result, wherein the reflection image sequence can highlight the reflection characteristics of the defects on the surface of the chuck, threshold segmentation is carried out on the reflection image sequence, the reflection areas are separated, morphological operation is carried out, noise and small isolated areas are removed, the main reflection areas are highlighted, then edge detection is used for extracting the edge information of the reflection areas, the boundaries of the defects are identified and positioned, each reflection area is segmented according to the edge detection result, and corresponding multiple chuck reflection separated images are extracted from the original images.
Optionally, in a second implementation manner of the second aspect of the present invention, the processing module is specifically configured to: determining a region needing space convergence according to the distribution condition of the first chuck spectrum center of gravity information and the second chuck spectrum center of gravity information, setting an intensity threshold value as K, judging whether the region needs space convergence according to the intensity threshold value K, and when the center of gravity intensity of a certain region exceeds the intensity threshold value K, the region needs space convergence; performing spatial fusion operation on the first chuck spectrum center of gravity information and the second chuck spectrum center of gravity information by using image fusion to obtain fused spectrum information, and extracting target frequency band information from the fused spectrum information; and combining the target frequency band according to the first chuck kurtosis information and the second chuck kurtosis information to serve as input parameters, performing spectrogram processing, filtering the spectrum data by using a filter, removing information of other frequency bands, only preserving information of the target frequency band, and extracting to obtain chuck correction frequency band information.
Optionally, in a third implementation manner of the second aspect of the present invention, the setting module is specifically configured to: according to each data point of a spectrogram of the chuck correction frequency band information, a window function is multiplied with the spectrogram, the spectrogram is windowed, and amplitude values of each frequency component are calculated to obtain chuck amplitude information; setting a threshold value D according to the chuck amplitude information, removing frequency components with the amplitude lower than the threshold value D, and reserving frequency division rate components; for the frequency-division-by-number frequency components, judging the continuity of the phase by comparing the chuck phase information with a threshold value Q, judging the phase difference as belonging to the same substantial frequency band if the phase difference is smaller than the threshold value Q, and representing the obtained substantial frequency band by saving the starting frequency and the ending frequency of the substantial frequency band and/or saving the center frequency and the bandwidth of the substantial frequency band; the virtual frequency bands comprise data input features and target defect labels, for each virtual frequency band, a gradient lifting tree is used for establishing a corresponding evaluation model, each evaluation model is trained for one virtual frequency band, for each evaluation model, model training is performed by using the data input features and the target defect labels of the corresponding virtual frequency band, and cross verification is adopted for optimizing parameters and generalization capacity of the model, so that a plurality of corresponding evaluation models are obtained; and verifying and training the obtained evaluation model according to the data of the training real chuck image sequence, and updating to obtain the evaluation model.
Optionally, in a fourth implementation manner of the second aspect of the present invention, the detection module is specifically configured to: performing time-frequency analysis on the chuck to-be-identified image sequence, applying short-time Fourier transform on each image of the chuck to-be-identified image sequence, dividing a signal into a plurality of time windows, and transforming on each window to obtain a time-frequency representation, and extracting a to-be-identified frequency band with obvious energy or characteristics from the time-frequency representation by using a threshold value and/or energy distribution; combining the frequency bands to be identified into an evaluation model as data input, wherein the output label of the evaluation model is represented by a plurality of pieces of analysis data; setting an overlapping threshold M for determining when two detection results are considered to be adjacent or overlapped, sequencing the detection results of each category according to the confidence level, starting from the detection result with the highest confidence level, retaining the detection result, removing other detection results which are overlapped with the detection result and exceed the overlapping threshold M, and repeating the process until all the detection results are processed; defining adjacent detection results under the condition that the overlapping area of the detection results is larger than an overlapping threshold L, defining a graph data structure comprising nodes and edges, wherein each node represents one detection result and comprises a unique identifier and boundary frame coordinate information, traversing all detection results, creating a node for each detection result, and adding the node to a graph; traversing each node in the graph, calculating the overlapping area of each pair of nodes, adding an edge between each pair of nodes if the overlapping area is larger than an overlapping threshold L, traversing the nodes in the graph from any node in the graph, and marking the accessed nodes; in the traversing process, adjacent non-access nodes are found, the overlapping area of the non-access nodes is calculated, if the overlapping area is larger than the overlapping threshold L, the non-access nodes are combined into a larger detection result, the two detection results are combined through expanding a boundary box, and after the traversing is finished, the non-combined detection result is reserved as a final laser pipe cutting machine chuck defect detection result.
A third aspect of the present invention provides a laser pipe cutting machine chuck defect detection apparatus, including: a memory and at least one processor, the memory having instructions stored therein; the at least one processor invokes the instructions in the memory to cause the laser pipe cutter chuck defect detection apparatus to perform the laser pipe cutter chuck defect detection method described above.
A fourth aspect of the present invention provides a computer readable storage medium having instructions stored therein that, when run on a computer, cause the computer to perform the above-described method of detecting a chuck defect of a laser pipe cutter.
In the technical scheme provided by the invention, the beneficial effects are mainly shown in the following aspects: high accuracy and reliability: through targeted data preprocessing and multi-feature fusion technology, defects can be more accurately identified and positioned, and the possibility of misjudgment and missed detection is reduced; high efficiency and real-time performance: the processing and analysis of a large amount of image data can be completed in a short time by utilizing the space transformation and spectrogram processing technology, so that the requirement of the production line on quick detection is met; good generalization ability: through a method combining training and verification, the model can keep good generalization capability in practical application and is suitable for defect detection under different environments and conditions; reducing sensitivity to complex background and noise: through the spectrum analysis and feature extraction technology, the defect features can be effectively extracted and identified under a complex background, and the influence of the background and noise on the detection result is reduced; scalability and flexibility: the method is not only suitable for defect detection of the chuck of the laser pipe cutting machine, but also can be applied to surface defect detection tasks of other similar equipment, and has good expansibility and flexibility; perfect verification mechanism: through methods such as verification training, cross verification and the like, possible problems of the model in practical application can be found and solved in time, and the accuracy and reliability of a detection result are ensured; in summary, the laser pipe cutting machine chuck defect detection method based on machine vision and deep learning has remarkable advantages in the aspects of accuracy, instantaneity, generalization capability, anti-interference performance and the like, and can provide powerful support for defect detection in the field of industrial manufacturing.
Drawings
FIG. 1 is a schematic diagram of an embodiment of a method for detecting defects of a chuck of a laser pipe cutting machine according to the present invention;
FIG. 2 is a schematic diagram of another embodiment of a method for detecting defects of a chuck of a laser pipe cutting machine according to an embodiment of the present invention;
FIG. 3 is a schematic view of an embodiment of a device for detecting a defect of a chuck of a laser pipe cutting machine according to the present invention;
fig. 4 is a schematic diagram of an embodiment of a device for detecting a defect of a chuck of a laser pipe cutting machine according to an embodiment of the present invention.
Detailed Description
The embodiment of the invention provides a method, a device, equipment and a storage medium for detecting the chuck defects of a laser pipe cutting machine, which are used for solving the problems and improving the detection accuracy and generalization capability through the technical means of targeted data preprocessing, multi-feature fusion, model optimization and the like.
For ease of understanding, a specific flow of an embodiment of the present invention is described below with reference to fig. 1, and an embodiment of a method for detecting a defect in a chuck of a laser pipe cutting machine according to the embodiment of the present invention includes:
101. carrying out data acquisition on the surface of the chuck to obtain a real chuck image sequence and a chuck to-be-identified image sequence, wherein the real chuck image sequence comprises a training real chuck image sequence and a target real chuck image sequence, and carrying out reflection separation according to the target real chuck image sequence to obtain a plurality of chuck reflection separation images;
It is to be understood that the execution body of the present invention may be a laser pipe cutting machine chuck defect detection device, and may also be a terminal or a server, which is not limited herein. The embodiment of the invention is described by taking a server as an execution main body as an example.
It should be noted that, the high-resolution camera or the laser scanner is used to collect data on the chuck surface of the laser pipe cutting machine, so as to ensure that the device maintains a proper distance and angle with the chuck surface, so as to capture clear images, the chuck surface is continuously rotated and a plurality of images are collected by controlling the rotation of the chuck of the laser pipe cutting machine, so that the collected image sequence comprises the complete surface of the chuck, a series of real chuck images are collected, the image sequence to be identified by the chuck is used for waiting detection, and the real chuck image sequence comprises a training real chuck image sequence and a target real chuck image sequence. Training a real chuck image sequence for model updating, and performing reflection separation on the target real chuck image sequence for model training so as to highlight reflection characteristics of chuck surface defects, wherein the method comprises the following steps of: a. extracting a background image: selecting a background image without a chuck as a background reference for reflection separation; b. background image correction: correcting the background image and the target real chuck image sequence, and eliminating illumination difference and noise of the background to obtain a more accurate reflection separation result; c. reflection separation: and performing difference operation on the corrected target real chuck image sequence and the background image to obtain a plurality of chuck reflection separation images, wherein the difference operation is realized by using pixel-level subtraction operation.
102. Performing first space transformation according to the multiple chuck reflection and separation images to obtain first chuck spectrum center of gravity information and first chuck kurtosis information corresponding to the multiple chuck reflection and separation images in a transformation mode, and performing second space transformation according to the multiple chuck reflection and separation images to obtain second chuck spectrum center of gravity information and second chuck kurtosis information corresponding to the multiple chuck reflection and separation images in a transformation mode;
the first space transformation is performed on each chuck reflection separation image, and is realized through the following steps: a. image preprocessing: preprocessing the reflected and separated images of each chuck, such as image enhancement and denoising operation, so as to improve the effect of subsequent transformation; b. first spatial transformation: transforming the preprocessed image by using a proper transformation method, and using Fourier transformation and wavelet transformation; c. extracting spectrum gravity center information and kurtosis information: spectral centroid information and kurtosis information are extracted from the transformed image. The center of gravity of the spectrum is the center position of the spectral distribution, and kurtosis is the statistic describing the shape of the spectrum.
And performing second space transformation on each chuck reflection separation image, wherein the second space transformation is realized through the following steps: a. image preprocessing: preprocessing the reflection separated image of each chuck to ensure the image quality and definition; b. second spatial transformation: performing a second spatial transformation on the preprocessed image using a suitable transformation method, using a one-or two-dimensional transformation method, such as wavelet transformation, discrete cosine transformation, etc.; c. extracting spectrum gravity center information and kurtosis information: and extracting frequency spectrum gravity center information and kurtosis information from the transformed image, and adopting a method similar to the first space transformation.
Examples:
the 10 chuck reflection separation images are acquired as input.
1. First spatial transformation:
a. image preprocessing: graying and Gaussian filtering are carried out on each chuck reflection separation image so as to enhance the contrast of the image and remove noise; b. first spatial transformation: performing Fourier transform on the preprocessed image; c. extracting spectrum gravity center information and kurtosis information: the spectral centroid and kurtosis values of the fourier transformed image are calculated. The center of gravity of the spectrum is obtained by calculating the coordinate position of the center of the spectrum, and kurtosis is obtained by calculating the high-order statistic of the spectrum.
2. Second spatial transformation:
a. image preprocessing: graying and histogram equalization are carried out on each chuck reflection separation image so as to enhance the contrast ratio of the image; b. second spatial transformation: performing wavelet transformation on the preprocessed image; c. extracting spectrum gravity center information and kurtosis information: the spectral centroid and kurtosis values of the wavelet transformed image are calculated.
103. Carrying out space convergence through the first chuck spectrum center of gravity information and the second chuck spectrum center of gravity information to obtain target frequency band information corresponding to a plurality of reflection separation images, and carrying out spectrogram processing according to the first chuck kurtosis information, the second chuck kurtosis information and the target frequency band to obtain chuck correction frequency band information;
The method includes the steps of spatially converging the first chuck spectrum center of gravity information and the second chuck spectrum center of gravity information to obtain target frequency band information corresponding to the plurality of reflection separation images, wherein the specific steps are as follows: a. aligning the first chuck spectrum centroid information and the second chuck spectrum centroid information: since the two spectrum centroid information are obtained in different spaces, they need to be aligned into the same space, and the two spectrum centroid information are aligned using an image registration algorithm, for example, a method based on feature point matching; b. spatial fusion: and performing spatial merging operation on the aligned spectrum center of gravity information, and taking an average value or a weighted average value to obtain target frequency band information corresponding to the multiple reflection separation images.
According to the kurtosis information of the first chuck, the kurtosis information of the second chuck and the target frequency band, performing spectrogram processing operation, wherein the specific steps are as follows: a. extracting a target frequency band: extracting a corresponding target frequency band from the original spectrogram according to the target frequency band information; b. correction of a spectrogram: correcting the target frequency band according to the kurtosis information of the first chuck and the kurtosis information of the second chuck, and adjusting the shape of the frequency spectrum according to the kurtosis information so as to improve the visibility of defects or reduce pseudo defects; c. chuck correction frequency band information: and obtaining chuck correction frequency band information after spectrogram processing, wherein the chuck correction frequency band information comprises a target frequency band corrected by kurtosis information.
Examples:
the first chuck spectrum centroid information, the second chuck spectrum centroid information and the original spectrogram are set as inputs.
Spatial fusion of first chuck spectral centroid information and second chuck spectral centroid information: a. aligning the first chuck spectrum centroid information and the second chuck spectrum centroid information: aligning the two spectrum center of gravity information into the same space by using a characteristic point matching algorithm; spatial fusion: and carrying out average operation on the aligned spectrum center of gravity information to obtain target frequency band information corresponding to the multiple reflection separation images.
Spectral graph processing: a. extracting a target frequency band: extracting a corresponding target frequency band from the original spectrogram according to the target frequency band information; b. correction of a spectrogram: correcting the target frequency band according to the first chuck kurtosis information and the second chuck kurtosis information; if the first chuck kurtosis information indicates that the frequency spectrum needs to enhance the visibility of the defect, the method is realized by increasing the amplitude of a target frequency band; if the second chuck kurtosis information indicates that the frequency spectrum needs to reduce the pseudo-defects, the frequency spectrum is realized by reducing the amplitude of a target frequency band; c. chuck correction frequency band information: and obtaining chuck correction frequency band information after spectrogram processing, wherein the chuck correction frequency band information comprises a target frequency band corrected by kurtosis information.
104. Carrying out additional extraction on chuck correction frequency band information to obtain chuck amplitude information and chuck phase information, carrying out classification processing on the chuck amplitude information and the chuck phase information, decomposing to obtain a plurality of substantial frequency bands, and respectively establishing a plurality of corresponding evaluation models according to the plurality of frequency bands;
the chuck correction frequency band information is further processed, and the chuck amplitude information and the chuck phase information are extracted, wherein the method specifically comprises the following steps of: a. extracting chuck amplitude information: acquiring amplitude values of each frequency band from the chuck correction frequency band information, and extracting the amplitude information of the frequency band by calculating peaks of the frequency band or using other signal processing methods (such as discrete Fourier transform); b. chuck phase information extraction: the phase value for each frequency band is obtained from the chuck corrected frequency band information, and a phase demodulation algorithm (e.g., hilbert transform) is used to extract the phase information for the frequency band.
Classifying by using chuck amplitude information and chuck phase information to decompose to obtain a plurality of substantial frequency bands, wherein the method comprises the following specific steps: a. feature extraction: extracting appropriate features from the chuck amplitude information and the chuck phase information, such as peaks of frequency bands, energy distribution, phase differences, etc.; b. classification algorithm: using machine learning or statistical methods, such as Support Vector Machines (SVMs), random Forest (Random Forest) or neural networks, to build classification models, classifying the essential frequency bands and the non-essential frequency bands with the extracted features as inputs; c. decomposing to obtain a plurality of substantial frequency bands: and extracting the part corresponding to the substantial frequency band in the chuck amplitude information and the chuck phase information according to the classification result to obtain a plurality of substantial frequency bands.
Establishing a plurality of corresponding evaluation models according to the characteristics of the frequency bands and the actual defect data, wherein the models are used for detecting defects and evaluating the states of the chuck;
examples:
additional extraction of chuck correction frequency band information: a, extracting chuck amplitude information: acquiring an amplitude value of each frequency band from chuck correction frequency band information; the phase value of each frequency band is obtained from the chuck correction frequency band information.
Classifying and processing of chuck amplitude information and chuck phase information: a. feature extraction: extracting features from the chuck amplitude information and the chuck phase information, such as peak value and energy distribution of each frequency band; b. classification algorithm: using a Support Vector Machine (SVM) algorithm to establish a classification model, taking the extracted features as input, and classifying a substantial frequency band and an non-substantial frequency band; decomposing to obtain a plurality of substantial frequency bands: and extracting the part corresponding to the substantial frequency band in the chuck amplitude information and the chuck phase information according to the classification result to obtain a plurality of substantial frequency bands.
Establishing an evaluation model based on a plurality of frequency bands: a. data collection and labeling: collecting chuck sample data containing different types of defects and defects, and marking the defects; b. feature extraction: extracting features from each substantial frequency band, such as peaks of the frequency band, energy distribution; c. model training: training a plurality of assessment models using the collected data and the extracted features, for example using a neural network; d. model evaluation and optimization: and evaluating the established evaluation model by using an independent test data set, and optimizing and adjusting the model according to the evaluation result.
105. Decomposing according to the chuck image sequence to be identified to obtain a plurality of frequency bands to be identified;
it should be noted that, the areas of a plurality of frequency bands to be identified are obtained through the chuck to-be-identified image sequence, and the frequency bands to be identified are combined to form a plurality of frequency bands to be evaluated.
106. Combining a plurality of evaluation models according to a plurality of frequency bands to be identified, outputting to obtain a plurality of analysis data representations, and obtaining a laser pipe cutting machine chuck defect detection result according to the plurality of analysis data representations;
it should be noted that, extracting features from each frequency band combination to be evaluated, using shape features, texture features and other features related to the chuck defects, performing classification prediction on each frequency band combination to be evaluated by using a corresponding evaluation model, and expressing a prediction result as corresponding analysis data, which may be defect probability and confidence, for all frequency band combinations to be evaluated, comprehensively judging whether defects exist according to the corresponding analysis data, and obtaining a final detection result of the chuck defects of the laser pipe cutting machine based on threshold setting and comprehensive scoring modes.
Examples:
two evaluation models were set: model a and model B.
A plurality of frequency band combinations to be identified: in the step of spectral decomposition, three frequency bands to be identified are obtained: frequency band 1, frequency band 2, and frequency band 3. We combine them according to rules to obtain two frequency band combinations to be evaluated: combination 1 (frequency band 1 + frequency band 2) and combination 2 (frequency band 2 + frequency band 3);
output of multiple analytical data representations: for the combination 1 and the combination 2, respectively using the model A and the model B to conduct classification prediction to obtain corresponding analysis data;
obtaining a laser pipe cutting machine chuck defect detection result: and (3) comprehensively analyzing the data of the combination 1 and the combination 2, judging whether defects exist or not based on a threshold setting or comprehensive scoring method, and outputting a final laser pipe cutting machine chuck defect detection result.
In the embodiment of the invention, an efficient and accurate chuck surface defect detection scheme is provided for the industrial field by comprehensively utilizing image processing, spectrum analysis and machine learning technologies, and a plurality of chuck reflection separation images are obtained by collecting data on the chuck surface and utilizing a reflection separation technology. Through space transformation and spectrogram processing, chuck frequency spectrum gravity center information and kurtosis information can be extracted, so that accurate target frequency band information and chuck correction frequency band information are obtained. By establishing a plurality of evaluation models and carrying out combined analysis with the frequency band to be identified, an accurate detection result of the chuck defect can be obtained. The method can greatly improve the accuracy of defect detection and reduce the situations of misjudgment and missed judgment; the rapid detection of the chuck can be realized by utilizing advanced technologies such as laser, image processing and the like. The processes of data acquisition and image processing can be completed in a short time, and a plurality of analysis data representations can be rapidly output for analysis of a frequency band to be identified; flexibly and adaptively adjusting parameters and algorithms by adjusting the parameters and algorithms, and adjusting parameters and algorithms of steps such as reflection separation, space transformation, spectrogram processing and the like according to different chuck types and defect characteristics so as to obtain better adaptability and detection effect; in conclusion, the method for detecting the defects of the chuck of the laser pipe cutting machine has the advantages and benefits of high accuracy, rapidness, non-contact performance, multifunction, automation, intellectualization and the like. The method can be widely applied to industrial production lines, improves production efficiency, reduces cost and ensures product quality and safety.
Referring to fig. 2, another embodiment of a method for detecting a defect of a chuck of a laser pipe cutting machine according to an embodiment of the present invention includes:
201. carrying out data acquisition on the surface of the chuck to obtain a real chuck image sequence and a chuck to-be-identified image sequence, wherein the real chuck image sequence comprises a training real chuck image sequence and a target real chuck image sequence, and carrying out reflection separation according to the target real chuck image sequence to obtain a plurality of chuck reflection separation images;
specifically, strengthening treatment is carried out on the target real chuck image sequence to obtain a strengthened real chuck image sequence, and background extraction is carried out according to the strengthened real chuck image sequence to obtain reflection-free image information; comparing the target real chuck image sequence with the non-reflected image information, calculating the difference between the target real chuck image sequence and the non-reflected image information through differentiation processing, generating a reflected image sequence according to the differentiation processing result, performing threshold segmentation on the reflected image sequence, separating a reflected region, performing morphological operation, removing noise and small isolated regions, highlighting a main reflected region, extracting edge information of the reflected region by using edge detection, identifying and positioning the boundary of the defect, dividing each reflected region according to the edge detection result, and extracting a plurality of corresponding chuck reflection separated images from an original image;
In the detection of the defect of the chuck of the laser pipe cutting machine, in order to realize the functions, the following specific implementation scheme is adopted:
performing reinforcement treatment on the target real chuck image sequence, wherein the reinforcement treatment adopts image reinforcement technology, such as histogram equalization, contrast reinforcement and the like, so as to highlight defect characteristics of the chuck surface, background extraction is performed according to the reinforced real chuck image sequence to obtain reflection-free image information, the background extraction uses image segmentation technology, such as threshold segmentation, region growth and the like, so as to separate foreground (defect) and background, contrast is performed according to the target real chuck image sequence and the reflection-free image information, a difference image is obtained by calculating the difference between the foreground and background image sequences, a reflection image sequence is generated according to the difference image, the reflection image sequence can highlight reflection characteristics of the chuck surface defect, threshold segmentation is performed on the reflection image sequence, the reflection region is separated, the threshold segmentation adopts global or local threshold method so as to accurately segment the defect region, morphological operations are performed on the segmented reflection region, including expansion, corrosion, noise and small isolated region are removed, the edge information of the reflection region is further highlighted, and the edge detection algorithm (such as Canny edge detection, sobel edge detection and the like) is used for identifying and positioning the boundary of the defect according to the edge detection result, and the reflection region is separated from the original image;
An example is further described below:
enhancement treatment and background extraction:
python
import cv2
import numpy as np
sequence of # reading target real chuck image
img_sequence = [cv2.imread(img_path) for img_path in image_sequence]
# intensive treatments (e.g. histogram equalization)
enhanced_sequence = [cv2.equalizeHist(img) for img in img_sequence]
# background extraction (e.g., global thresholding)
background = np.zeros_like(enhanced_sequence[0])
for img in enhanced_sequence:
ret, thresh = cv2.threshold(img, 127, 255, cv2.THRESH_BINARY)
background = cv2.bitwise_or(background, thresh)
python
# calculate the difference between the target real chuck image and the background
diff_sequence = [cv2.subtract(img, background) for img in img_sequence]
python
Threshold segmentation (e.g. adaptive threshold segmentation)
thresholded = [cv2.adaptiveThreshold(img_diff, 255, cv2.ADAPTIVE_THRESH_GAUSSIAN_C, cv2.THRESH_BINARY, 11, 2) for img_diff in diff_sequence]
Morphological operations (e.g. erosion and swelling)
dilated = [cv2.dilate(thres, None, iterations=2) for thres in thresholded]
python
# Canny edge detection
edges = [cv2.Canny(img, 50, 150) for img in dilated]。
202. Performing first space transformation according to the multiple chuck reflection and separation images to obtain first chuck spectrum center of gravity information and first chuck kurtosis information corresponding to the multiple chuck reflection and separation images in a transformation mode, and performing second space transformation according to the multiple chuck reflection and separation images to obtain second chuck spectrum center of gravity information and second chuck kurtosis information corresponding to the multiple chuck reflection and separation images in a transformation mode;
specifically, according to the reflection separation images of a plurality of chucks, amplitude spectrum information and frequency information are obtained, and the amplitude spectrum information and the frequency information are transformed through the following formulas:
centroid_x=sum(amplitude_spectrum*frequency)/ sum(amplitude_spectrum)
wherein centroid_x is the spectrum barycentric coordinates, amplitude_spectrum is the amplitude spectrum, and frequency is the frequency;
kurtosis = sum(((amplitude_spectrum - mean) / std) ** 4) / N
where kurtosis is kurtosis information, amplitude_spectrum is amplitude spectrum, mean is spectrum mean, std is spectrum standard deviation, N is spectrum length, ((amplitude_spectrum-mean)/std) 4 means dividing each amplitude spectrum value by standard deviation after subtracting the mean, and then performing fourth-order operation on the result;
It should be noted that, performing a first spatial transformation on the multiple chuck reflection separated images, selecting a transformation method, such as fourier transformation or wavelet transformation, transforming each image, calculating to obtain corresponding spectrum information, extracting amplitude spectrum and frequency from the transformed spectrum information to obtain amplitude spectrum information and frequency information, calculating spectrum gravity center information by using the spectrum information and the amplitude spectrum information obtained by the first spatial transformation, performing weighted summation by using the amplitude spectrum and frequency according to a given formula, dividing by the sum of the amplitude spectrum to obtain spectrum gravity center coordinates, calculating the mean value and standard deviation of the amplitude spectrum according to the given formula, and calculating kurtosis; performing second space transformation on the reflected and separated images of the plurality of chucks, selecting another transformation method, such as wavelet transformation or other transformation methods, transforming each image, calculating to obtain corresponding spectrum information, and extracting amplitude spectrum and frequency from the transformed spectrum information to obtain amplitude spectrum information and frequency information; calculating spectrum gravity center information by utilizing spectrum information and amplitude spectrum information obtained by the second space transformation, carrying out weighted summation by using amplitude spectrum and frequency according to a given formula, dividing the sum of the amplitude spectrum to obtain spectrum gravity center coordinates, carrying out calculation of mean value and standard deviation on the amplitude spectrum according to the given formula, and carrying out calculation of kurtosis;
Spectral barycentric coordinates and kurtosis information were calculated by the following examples:
let us assume that we have 3 chuck reflection separation images, the magnitude spectrum and frequency information for each image is as follows:
image 1: amplitude spectrum: [0.5, 0.8, 0.9, 1.2], frequency: [10, 20, 30, 40];
image 2: amplitude spectrum: [0.7, 1.0, 1.1, 1.3], frequency: [12, 22, 32, 42];
image 3: amplitude spectrum: [0.6, 0.9, 1.0, 1.4], frequency: [11, 21, 31, 41];
first, the spectrum barycentric coordinates (centroid_x) and kurtosis information (kurtosis) of each image are calculated.
```python
import numpy as np
Definition of the amplitude spectrum and frequency information
amplitude_spectrum_1 = np.array([0.5, 0.8, 0.9, 1.2])
frequency_1 = np.array([10, 20, 30, 40])
amplitude_spectrum_2 = np.array([0.7, 1.0, 1.1, 1.3])
frequency_2 = np.array([12, 22, 32, 42])
amplitude_spectrum_3 = np.array([0.6, 0.9, 1.0, 1.4])
frequency_3 = np.array([11, 21, 31, 41])
Calculation of the spectrum barycentric coordinates
centroid_x_1 = np.sum(amplitude_spectrum_1 * frequency_1) / np.sum(amplitude_spectrum_1)
centroid_x_2 = np.sum(amplitude_spectrum_2 * frequency_2) / np.sum(amplitude_spectrum_2)
centroid_x_3 = np.sum(amplitude_spectrum_3 * frequency_3) / np.sum(amplitude_spectrum_3)
Calculation of the mean and standard deviation of the spectrum
mean_1 = np.mean(amplitude_spectrum_1)
mean_2 = np.mean(amplitude_spectrum_2)
mean_3 = np.mean(amplitude_spectrum_3)
std_1 = np.std(amplitude_spectrum_1)
std_2 = np.std(amplitude_spectrum_2)
std_3 = np.std(amplitude_spectrum_3)
Calculation kurtosis information #
kurtosis_1 = np.sum(((amplitude_spectrum_1 - mean_1) / std_1) ** 4) / amplitude_spectrum_1.size
kurtosis_2 = np.sum(((amplitude_spectrum_2 - mean_2) / std_2) ** 4) / amplitude_spectrum_2.size
kurtosis_3 = np.sum(((amplitude_spectrum_3 - mean_3) / std_3) ** 4) / amplitude_spectrum_3.size
Results of # printing
print (' image 1 spectrum barycentric coordinates: ", centroid_x_1)
print (' kurtosis information for image 1: ", kurtosis_1)
print (' image 2 spectrum barycentric coordinates: ", centroid_x_2)
print (' kurtosis information for image 2: ", kurtosis_2)
print (' image 3 spectrum barycentric coordinates: ", centroid_x_3)
print (' kurtosis information for image 3: ", kurtosis_3)
The output result is:
image 1 spectrum barycentric coordinates: 27.083333333333332
Image 1 kurtosis information: 0.2604166666666667
Image 2 spectrum barycentric coordinates: 32.142857142857146
Image 2 kurtosis information: 0.28125
Image 3 spectral barycentric coordinates: 30.0
Image 3 kurtosis information: 0.24305555555555555.
203. Carrying out space convergence through the first chuck spectrum center of gravity information and the second chuck spectrum center of gravity information to obtain target frequency band information corresponding to a plurality of reflection separation images, and carrying out spectrogram processing according to the first chuck kurtosis information, the second chuck kurtosis information and the target frequency band to obtain chuck correction frequency band information;
specifically, according to the distribution condition of the first chuck spectrum center of gravity information and the second chuck spectrum center of gravity information, determining a region needing space convergence, setting an intensity threshold value as K, judging whether the region needs space convergence according to the intensity threshold value K, and when the center of gravity intensity of a certain region exceeds the intensity threshold value K, the region needs space convergence; performing spatial fusion operation on the first chuck spectrum center of gravity information and the second chuck spectrum center of gravity information by using image fusion to obtain fused spectrum information, and extracting target frequency band information from the fused spectrum information;
setting weights of image fusion as w1 and w2 respectively, and setting the center of gravity of the spectrum after fusion as Fused (f) =w1×c1 (f) +w2×c2 (f);
C1 (f 1) is first chuck spectrum centroid information, and C2 (f 2) is first chuck spectrum centroid information:
C(f) = Σ(E(f) * f) / ΣE(f)
wherein E (f) represents energy at a frequency f in the spectrogram;
let the target frequency band be [ f_min, f_max ], extract the energy information in this frequency band, then:
Target_Energy = Σ(Fused(f) * (f >= f_min) * (f <= f_max))
wherein (f > =f_min) × (f < =f_max) is a logic function for determining whether the frequency is within the Target frequency band, f_min and f_max are lower and upper limits of the Target frequency band, target_energy is Energy information in the extracted Target frequency band, the Energy information is used for analysis or comparison with a preset threshold, and Fused (f) represents the center of gravity of the spectrum after fusion;
the following is an example illustrating how spectral centroid merging and energy extraction in laser pipe cutter chuck defect detection may be performed:
the following parameters and data were set: first chuck spectral center of gravity information: c1 (f) = [25, 30, 35, 40, 45]
The method comprises the steps of carrying out a first treatment on the surface of the Second chuck spectral center of gravity information: c2 (f) = [20, 25, 30, 35, 40]; energy information at frequencies in the spectrogram: e (f) = [10, 20, 30, 40, 50]; target frequency band range: [ f_min, f_max ] = [30, 40]; weighting of image fusion: w1=0.6, w2=0.4;
calculate the center of gravity Fused (f) of the spectrum after the fusion:
```python
import numpy as np
# definition Spectrum centroid information and weights
C1 = np.array([25, 30, 35, 40, 45])、C2 = np.array([20, 25, 30, 35, 40])、w1 = 0.6、w2 = 0.4
Calculation of the center of gravity Fused (f) of the spectrum after the fusion
Fused = w1 * C1 + w2 * C2
Spectral center of gravity after # printing convergence
print (' center of gravity of spectrum after confluence: ", fused)
The output result is:
the center of gravity of the converged spectrum: [23.27.31.35.39.]
Next, energy information target_energy within the Target frequency band is calculated according to a formula:
```python
definition of frequency band range
f_min = 30、f_max = 40
# calculating Energy information Target Energy within Target frequency band
Target_Energy = np.sum(Fused * ((f_min <= f) & (f <= f_max)))
Energy information in # printing target frequency band
print ("Energy information in Target frequency band:", target_energy)
The output result is: energy information within the target frequency band: 151.0
And combining the target frequency band according to the first chuck kurtosis information and the second chuck kurtosis information as input parameters, performing spectrogram processing, filtering the spectrum data by using a filter, removing information of other frequency bands, only preserving information of the target frequency band, and extracting to obtain chuck correction frequency band information.
204. Carrying out additional extraction on chuck correction frequency band information to obtain chuck amplitude information and chuck phase information, carrying out classification processing on the chuck amplitude information and the chuck phase information, decomposing to obtain a plurality of substantial frequency bands, and respectively establishing a plurality of corresponding evaluation models according to the plurality of frequency bands;
Specifically, according to each data point of the spectrogram of chuck correction frequency band information to which the selected window function is applied, the spectrogram is windowed by multiplying the window function with the spectrogram, chuck amplitude information is obtained by calculating the amplitude value of each frequency component, and the window function is set to (w (n)), then:
w(n) = \alpha - \beta \cos\left(\frac{2\pi n}{N-1}\right)
where (N) is the index of the discrete time point, (N) is the length of the window function, (\alpha) and (\beta) are parameters of the window function for adjusting the shape of the window function, (\cos\left (\frac {2\pi N } { N-1} \right)) is a cosine function;
setting the spectrogram as X (k), the window function as w (n), and the spectrogram after windowing as X_w (k), then:
X_w(k) = X(k) \times w(k)
A(k) = |X_w(k)|
wherein a (k) represents the magnitude value of the (k) th frequency component, ||represents the absolute value operation in the modulo operation, \times represents the multiplication operation;
calculating phase differences between adjacent frequency points in a spectrogram of the chuck correction frequency band information to obtain chuck phase information, and setting the spectrogram as X (k), wherein:
Δφ = arg(X(k_i+1)) - arg(X(k_i))
where arg () represents the phase angle, Δφ represents the phase difference between frequencies k_i+1 and k_i;
the following is an embodiment of how to use a given formula to implement the frequency spectrum windowing process and the calculation of amplitude and phase information in the detection of the chuck defects of the laser pipe cutting machine;
The following parameters and data were set: frequency spectrum diagram: x (k) = [10, 20, 30, 40, 50]; window function length: n=5; window function parameters: α=0.5, β=0.5;
first, a window function w (n) is calculated:
```python
import numpy as np
# definition Window function parameters and Length
alpha = 0.5、beta = 0.5、N = 5
# calculate window function w (n)
n = np.arange(N)、window = alpha - beta * np.cos(2 * np.pi * n / (N - 1))
# printing window function
print ('Window function:', window)
The output result is:
window function: [1.0.5 0.0.5 1. ]
Next, spectrum windowing processing and amplitude calculation are performed:
```python
definition of spectrogram
X = np.array([10, 20, 30, 40, 50])
# spectral windowing
X_w = X * window
# calculate amplitude value
A = np.abs(X_w)
Print amplitude value #
print (' amplitude value: ", A)
The output result is:
amplitude value: [10.10.0.20.50.]
Finally, phase differences between adjacent frequency points are calculated:
```python
# calculate phase difference
phase_diff = np.angle(X[1:]) - np.angle(X[:-1])
Phase difference of # printing
print (' phase_diff: ", phase:")
The output result is:
phase difference: [0.32175055 0.32175055 0.32175055 0.32175055]
Setting a threshold value D (D is determined according to the minimum value, the maximum value or the average value of the amplitude value) according to the chuck amplitude information, eliminating frequency components with the amplitude lower than the threshold value D, and reserving a frequency division rate component of a number; for the frequency-division-by-number frequency components, judging the continuity of the phase by comparing the magnitude relation of the chuck phase information with a threshold value Q (the phase threshold value Q is set as the range of the phase difference between adjacent frequency points or as a fixed value), if the phase difference is smaller than the threshold value Q, judging them as belonging to the same substantial frequency band, and representing the obtained substantial frequency band by saving the starting frequency and the ending frequency of the substantial frequency band and/or saving the center frequency and the bandwidth of the substantial frequency band; the virtual frequency bands comprise data input features and target defect labels, for each virtual frequency band, a gradient lifting tree is used for establishing a corresponding evaluation model, each evaluation model is trained for one virtual frequency band, for each evaluation model, model training is performed by using the data input features and the target defect labels of the corresponding virtual frequency band, and cross verification is adopted for optimizing parameters and generalization capacity of the model, so that a plurality of corresponding evaluation models are obtained; and verifying and training the obtained evaluation model according to the data of the training real chuck image sequence, and updating to obtain the evaluation model.
205. Decomposing the image sequence to be identified according to the chuck to obtain a plurality of frequency bands to be identified, combining a plurality of evaluation models according to the plurality of frequency bands to be identified, and outputting to obtain a plurality of analysis data representations;
specifically, performing time-frequency analysis on the image sequence to be recognized by the chuck, applying short-time Fourier transform to each image of the image sequence to be recognized by the chuck, dividing a signal into a plurality of time windows, and transforming on each window to obtain a time-frequency representation, and extracting a frequency band to be recognized with significant energy or characteristics from the time-frequency representation by using a threshold value and/or energy distribution; the method comprises the steps that a plurality of frequency bands to be identified are used as data input to be combined into an evaluation model, and an output label of the evaluation model is represented by a plurality of analysis data; setting an overlapping threshold M for determining when two detection results are considered to be adjacent or overlapped, sequencing the detection results of each category according to the confidence level, starting from the detection result with the highest confidence level, retaining the detection result, removing other detection results which are overlapped with the detection result and exceed the overlapping threshold M, and repeating the process until all the detection results are processed;
it should be noted that, collecting the sequence of chuck images to be identified and converting them into a digital image format, applying a preprocessing step, such as image enhancement, noise removal and image smoothing, to each image to increase the accuracy of the subsequent analysis, applying a Short Time Fourier Transform (STFT) to each image, dividing the signal into a plurality of time windows, and transforming on each window, processing the transformed result of each time window to obtain a time-frequency representation, which may be a magnitude spectrum, a phase spectrum or other time-frequency features, extracting the frequency bands to be identified with significant energy or features in the time-frequency representation using a method of a threshold and/or an energy distribution, selecting the frequency bands to be identified with sufficient energy or features by setting a threshold, or extracting the frequency bands with significant energy using the statistical characteristics of the energy distribution, combining the plurality of frequency bands to be identified as data inputs into an evaluation model, the evaluation model being a classifier, a clustering algorithm or other machine learning/deep learning model, for classifying the frequency bands to be identified or analyzing, for the detection results of each category, ranking the confidence levels according to their respective confidence levels, and assigning a high rank to the detection results before the detection results are overlapped with each other, determining when the detection results overlap by a threshold is reached, and the detection results are overlapped by a threshold is repeated until all the detection results are overlapped by a threshold is reached, and the most high, and the detection results are considered to be overlapped.
206. Connectivity analysis is carried out on the detection results in the maintained analysis data representation to combine adjacent overlapping results, a graph traversal algorithm is used for searching for the adjacent detection results, the overlapping areas of the adjacent detection results are calculated, whether the adjacent detection results are combined into a larger detection result is determined according to the overlapping areas and the overlapping proportion, and the results are used as final detection results of the chuck defects of the laser pipe cutting machine;
specifically, the condition of defining adjacent detection results is that the overlapping area of the detection results is larger than an overlapping threshold L (the theoretical value range of the overlapping threshold L is between tens and hundreds of pixels, a balance point is found by adjusting the overlapping threshold L), a graph data structure is defined, each node represents one detection result and comprises a unique identifier and boundary frame coordinate information, all detection results are traversed, a node is created for each detection result, and the node is added into a graph; traversing each node in the graph, calculating the overlapping area of each pair of nodes, adding an edge between each pair of nodes if the overlapping area is larger than an overlapping threshold L, traversing the nodes in the graph from any node in the graph, and marking the accessed nodes; in the traversing process, adjacent non-access nodes are found, the overlapping area of the non-access nodes is calculated, if the overlapping area is larger than an overlapping threshold L, the non-access nodes are combined into a larger detection result, two detection results are combined by expanding a boundary box, and after the traversing is finished, the non-combined detection result is reserved as a final laser pipe cutting machine chuck defect detection result;
It should be noted that, setting an overlap threshold L, defining conditions of adjacent detection results as that their overlap area is greater than the overlap threshold L, defining a graph data structure including nodes and edges, each node representing a detection result, including unique identifier and bounding box coordinate information, traversing all detection results, creating a node for each detection result and adding it to the graph, traversing each node in the graph, for each pair of nodes, calculating their overlap area, if the overlap area is greater than the overlap threshold L, adding an edge between them, starting from any node in the graph, traversing the nodes in the graph, and marking the accessed nodes, finding adjacent non-accessed nodes during the traversal, and calculating their overlap area, if the overlap area is greater than the overlap threshold L, merging them into a larger detection result, by expanding the bounding box to include two detection results, continuing to traverse and merge the adjacent nodes until a new adjacent node cannot be found, retaining the final non-merged detection result as an independent detection result of the laser pipe cutter, and the non-merged detection result representing that the laser pipe cutter has a defect has a small overlap area.
In the embodiment of the invention, the reflection separation images of the chucks are adopted for comparison and spectrum analysis, so that the defects can be more accurately identified and positioned, and the limitation of a single image is avoided. The recognition accuracy is further improved through space transformation and spectrogram processing; automatic detection is realized, and the influence of manual intervention and subjective judgment on detection results is reduced. Through spectrum analysis and classification processing, defect characteristics can be automatically extracted, an evaluation model can be established, and the detection flow is simplified; suitable for different types of chuck defect detection, including but not limited to surface cracking, wear, tarnishing, etc. The method can adapt to different detection requirements and scenes by adjusting the threshold value and the parameters, and has good universality; the time-frequency analysis technology is adopted, so that the image sequence to be identified of the chuck can be rapidly processed, and the detection speed is improved. Meanwhile, training and verification of the evaluation model can be completed in a short time, so that real-time requirements are ensured; the method also provides a data updating mechanism for training the real chuck image sequence, and can continuously optimize the detection effect; the time and cost of manual detection can be reduced, and errors caused by human factors are avoided; in conclusion, the method for detecting the defects of the chuck of the laser pipe cutting machine has the advantages of being high in accuracy, high in automation degree, wide in application range, high in instantaneity, easy to maintain and upgrade, cost-saving, safe, reliable, high in expandability, high in reliability, good in visualization effect and the like.
The method for detecting the defects of the chuck of the laser pipe cutting machine in the embodiment of the invention is described above, and the device for detecting the defects of the chuck of the laser pipe cutting machine in the embodiment of the invention is described below, referring to fig. 3, one embodiment of the device for detecting the defects of the chuck of the laser pipe cutting machine in the embodiment of the invention includes:
the acquisition module 301 is configured to acquire data from a chuck surface, and acquire a real chuck image sequence and a chuck image sequence to be identified;
the processing module 302 is configured to spatially transform the reflected and separated images of the plurality of chucks to obtain corresponding spectrum center-of-gravity information and kurtosis information, then obtain target frequency band information through spatial merging operation, perform spectrogram processing according to the target frequency band information and the kurtosis information, and extract chuck correction frequency band information;
the setting module 303 is configured to additionally extract chuck correction frequency band information to obtain chuck amplitude information and phase information, then perform classification processing according to the amplitude information and the phase information, decompose to obtain a plurality of substantial frequency bands, establish a corresponding evaluation model for each substantial frequency band, train by using a gradient lifting tree, and optimize parameters and generalization capability of the model by adopting cross verification;
The detection module 304 is configured to perform time-frequency analysis on an image sequence to be identified by the chuck, extract a frequency band to be identified, then combine the frequency band to be identified with the evaluation model, output a plurality of analysis data representations, and finally obtain a detection result of the chuck defect of the laser pipe cutting machine according to the plurality of analysis data representations.
In the embodiment of the invention, the acquisition module can acquire the data of the chuck surface with high precision to acquire the real chuck image sequence and the chuck image sequence to be identified. The data acquisition mode can ensure that the acquired image information is accurate and comprehensive, and provides a reliable data basis for subsequent processing; the processing module obtains spectrum gravity center information and kurtosis information by performing space transformation on the reflected and separated images of the plurality of chucks. Such information can provide multi-dimensional features of the chuck surface defects, helping to accurately describe and identify the defects. The frequency band information of the chuck correction can be further extracted through space merging operation and spectrogram processing, so that the sensitivity and reliability of the chuck surface defect are improved; the setting module performs additional extraction on the chuck correction frequency band information to obtain chuck amplitude information and phase information. Then, for each substantial frequency band, a corresponding evaluation model is established and trained using a gradient-lifting tree. The assessment models can classify and identify different types of defects, and have high robustness and generalization capability. The accuracy and the reliability of the model can be further improved through the technical means of cross verification and the like; the accuracy and the credibility of the detection result can be further improved by optimizing the model parameters and the generalization capability; in summary, the device for detecting the defects of the chuck of the laser pipe cutting machine has the advantages and benefits of high data acquisition precision, multidimensional information processing, modeling of a plurality of substantial frequency bands, efficient defect detection, high accuracy, reliability and the like, and provides powerful support for quality control and improvement work.
The above-mentioned fig. 3 describes the device for detecting the defects of the chuck of the laser pipe cutting machine in the embodiment of the present invention in detail from the point of view of modularized functional entities, and the following describes the device for detecting the defects of the chuck of the laser pipe cutting machine in detail from the point of view of hardware processing.
Fig. 4 is a schematic structural diagram of a laser pipe cutter chuck defect detection apparatus according to an embodiment of the present invention, where the laser pipe cutter chuck defect detection apparatus 400 may have a relatively large difference due to different configurations or performances, and may include one or more processors (central processing units, CPU) 410 (e.g., one or more processors) and a memory 420, and one or more storage media 430 (e.g., one or more mass storage devices) storing application programs 433 or data 432. Wherein memory 420 and storage medium 430 may be transitory or persistent storage. The program stored on the storage medium 430 may include one or more modules (not shown), each of which may include a series of instruction operations for the laser pipe cutter chuck defect detection apparatus 400. Still further, the processor 410 may be configured to communicate with the storage medium 430 to execute a series of instruction operations in the storage medium 430 on the laser pipe cutter chuck defect detection apparatus 400.
The laser pipe cutter chuck defect detection apparatus 400 may also include one or more power supplies 440, one or more wired or wireless network interfaces 450, one or more input/output interfaces 460, and/or one or more operating systems 431, such as Windows Serve, mac OS X, unix, linux, freeBSD, and the like. It will be appreciated by those skilled in the art that the laser pipe cutter chuck defect detection apparatus configuration shown in fig. 4 is not limiting of the laser pipe cutter chuck defect detection apparatus and may include more or fewer components than shown, or may be a combination of certain components, or a different arrangement of components.
The invention also provides a device for detecting the defects of the chuck of the laser pipe cutting machine, which comprises a memory and a processor, wherein the memory stores computer readable instructions, and when the computer readable instructions are executed by the processor, the processor executes the steps of the method for detecting the defects of the chuck of the laser pipe cutting machine in the above embodiments.
The present invention also provides a computer readable storage medium, which may be a non-volatile computer readable storage medium, and may also be a volatile computer readable storage medium, where instructions are stored in the computer readable storage medium, where the instructions, when executed on a computer, cause the computer to perform the steps of the method for detecting a chuck defect of a laser pipe cutting machine.
It will be clear to those skilled in the art that, for convenience and brevity of description, specific working procedures of the above-described systems, apparatuses and units may refer to corresponding procedures in the foregoing method embodiments, which are not repeated herein.
The integrated units, if implemented in the form of software functional units and sold or used as stand-alone products, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present invention may be embodied essentially or in part or all of the technical solution or in part in the form of a software product stored in a storage medium, including instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method according to the embodiments of the present invention. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a read-only memory (ROM), a random access memory (random access memory, RAM), a magnetic disk, or an optical disk, or other various media capable of storing program codes.
The above embodiments are only for illustrating the technical solution of the present invention, and not for limiting the same; although the invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical scheme described in the foregoing embodiments can be modified or some technical features thereof can be replaced by equivalents; such modifications and substitutions do not depart from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims (10)

1. The method for detecting the defects of the chuck of the laser pipe cutting machine is characterized by comprising the following steps of:
carrying out data acquisition on the surface of a chuck to obtain a real chuck image sequence and a chuck to-be-identified image sequence, wherein the real chuck image sequence comprises a training real chuck image sequence and a target real chuck image sequence, and carrying out reflection separation according to the target real chuck image sequence to obtain a plurality of chuck reflection separation images;
performing first space transformation according to the multiple chuck reflection separation images to obtain first chuck spectrum center of gravity information and first chuck kurtosis information corresponding to the transformation of the multiple chuck reflection separation images, and performing second space transformation according to the multiple chuck reflection separation images to obtain second chuck spectrum center of gravity information and second chuck kurtosis information corresponding to the transformation of the multiple chuck reflection separation images;
Spatial convergence is carried out through the first chuck spectrum center of gravity information and the second chuck spectrum center of gravity information to obtain target frequency band information corresponding to the multiple reflection separation images, and spectrogram processing is carried out according to the first chuck kurtosis information, the second chuck kurtosis information and the target frequency band to obtain chuck correction frequency band information;
carrying out additional extraction on the chuck correction frequency band information to obtain chuck amplitude information and chuck phase information, carrying out classification processing on the chuck amplitude information and the chuck phase information, decomposing to obtain a plurality of substantial frequency bands, and respectively establishing a plurality of corresponding evaluation models according to the plurality of frequency bands;
decomposing according to the chuck image sequence to be identified to obtain a plurality of frequency bands to be identified;
and combining the plurality of evaluation models according to the plurality of frequency bands to be identified, outputting to obtain a plurality of analysis data representations, and obtaining a laser pipe cutting machine chuck defect detection result according to the plurality of analysis data representations.
2. The method for detecting the chuck defect of the laser pipe cutting machine according to claim 1, wherein the acquiring data of the chuck surface to obtain a real chuck image sequence and a chuck image sequence to be identified, the real chuck image sequence includes a training real chuck image sequence and a target real chuck image sequence, the reflecting separation is performed according to the target real chuck image sequence to obtain a plurality of chuck reflecting separation images, the method comprises the following steps:
Performing reinforcement treatment on the target real chuck image sequence to obtain a reinforced real chuck image sequence, and performing background extraction according to the reinforced real chuck image sequence to obtain reflection-free image information;
comparing the target real chuck image sequence with the non-reflection image information, calculating the difference between the target real chuck image sequence and the non-reflection image information through differentiation processing, generating a reflection image sequence according to the differentiation processing result, wherein the reflection image sequence can highlight the reflection characteristics of the defects on the surface of the chuck, threshold segmentation is carried out on the reflection image sequence, the reflection areas are separated, morphological operation is carried out, noise and small isolated areas are removed, the main reflection areas are highlighted, then edge detection is used for extracting the edge information of the reflection areas, the boundaries of the defects are identified and positioned, each reflection area is segmented according to the edge detection result, and corresponding multiple chuck reflection separated images are extracted from the original images.
3. The method for detecting a defect of a chuck of a laser pipe cutting machine according to claim 1, wherein performing a first spatial transformation according to the plurality of chuck reflection separated images to obtain first chuck spectrum center of gravity information and first chuck kurtosis information corresponding to the plurality of chuck reflection separated images, performing a second spatial transformation according to the plurality of chuck reflection separated images to obtain second chuck spectrum center of gravity information and second chuck kurtosis information corresponding to the plurality of chuck reflection separated images, comprises:
Obtaining amplitude spectrum information and frequency information according to the reflected and separated images of the chucks, and transforming through the following formula:
centroid_x=sum(amplitude_spectrum*frequency)/ sum(amplitude_spectrum)
wherein centroid_x is the spectrum barycentric coordinates, amplitude_spectrum is the amplitude spectrum, and frequency is the frequency;
kurtosis = sum(((amplitude_spectrum - mean) / std) 4 ) / N
where kurtosis is kurtosis information, amplitude_spectrum is amplitude spectrum, mean is the mean of the spectrum, std is the standard deviation of the spectrum, and N is the length of the spectrum (amplitude_spectrum-mean)/std 4 Meaning that each magnitude spectrum value is divided by standard deviation after subtracting the mean value, and then the result is subjected to fourth-order operation.
4. The method for detecting a defect of a chuck of a laser pipe cutting machine according to claim 1, wherein the spatially converging the first chuck spectrum center of gravity information and the second chuck spectrum center of gravity information to obtain target frequency band information corresponding to the plurality of reflection separated images, and performing spectrogram processing according to the first chuck kurtosis information, the second chuck kurtosis information and the target frequency band to obtain chuck correction frequency band information, comprises:
determining a region needing space convergence according to the distribution condition of the first chuck spectrum center of gravity information and the second chuck spectrum center of gravity information, setting an intensity threshold value as K, judging whether the region needs space convergence according to the intensity threshold value K, and when the center of gravity intensity of a certain region exceeds the intensity threshold value K, the region needs space convergence;
Performing spatial fusion operation on the first chuck spectrum center of gravity information and the second chuck spectrum center of gravity information by using image fusion to obtain Fused spectrum information, and extracting target frequency band information from the Fused spectrum information, wherein the Fused spectrum center of gravity is Fused (f) =w1×c1 (f) +w2×c2 (f) if the weights of the image fusion are set to be w1 and w2 respectively;
c1 (f) is first chuck spectrum centroid information, and C2 (f) is first chuck spectrum centroid information:
C(f) = Σ(E(f) * f) / ΣE(f)
wherein E (f) represents energy at a frequency f in the spectrogram;
let the target frequency band be [ f_min, f_max ], extract the energy information in this frequency band, then:
Target_Energy = Σ(Fused(f) * (f >= f_min) * (f <= f_max))
wherein (f > =f_min) × (f < =f_max) is a logic function for determining whether the frequency is within the Target frequency band, f_min and f_max are lower and upper limits of the Target frequency band, target_energy is Energy information in the extracted Target frequency band, the Energy information is used for analysis or comparison with a preset threshold, and Fused (f) represents the center of gravity of the spectrum after fusion;
and combining the target frequency band according to the first chuck kurtosis information and the second chuck kurtosis information to serve as input parameters, performing spectrogram processing, filtering the spectrum data by using a filter, removing information of other frequency bands, only preserving information of the target frequency band, and extracting to obtain chuck correction frequency band information.
5. The method for detecting a defect of a chuck of a laser pipe cutting machine according to claim 1, wherein the additionally extracting the chuck correction frequency band information to obtain chuck amplitude information and chuck phase information, classifying the chuck amplitude information and the chuck phase information to obtain a plurality of substantial frequency bands by decomposition, and respectively establishing a plurality of corresponding evaluation models according to the plurality of frequency bands, wherein the method comprises the steps of:
according to each data point of the spectrogram of the chuck correction frequency band information, the selected window function is applied to the spectrogram, the spectrogram is windowed by multiplying the window function and the spectrogram, the amplitude value of each frequency component is calculated to obtain chuck amplitude information, and the window function is set to be (w (n)), then:
w(n) = \alpha - \beta * cos(2\pi n / (N-1))
where N is the index of the discrete time point, N is the length of the window function, alpha and beta are parameters of the window function for adjusting the shape of the window function, cos left (2 pi N1 right is a cosine function;
setting the spectrogram as X (k), the window function as w (n), and the spectrogram after windowing as X_w (k), then:
X_w(k) = X(k) \times w(k)
A(k) = |X_w(k)|
wherein a (k) represents the magnitude value of the (k) th frequency component, ||represents the absolute value operation in the modulo operation, \times represents the multiplication operation;
Calculating phase differences between adjacent frequency points in a spectrogram of the chuck correction frequency band information to obtain chuck phase information, and setting the spectrogram as X (k), wherein:
Δφ = arg(X(k_i+1)) - arg(X(k_i))
where arg () represents the phase angle, Δφ represents the phase difference between frequencies k_i+1 and k_i;
setting a threshold value D according to the chuck amplitude information, removing frequency components with the amplitude lower than the threshold value D, and reserving frequency division rate components;
for the frequency-division-by-number frequency components, judging the continuity of the phase by comparing the chuck phase information with a threshold value Q, judging the phase difference as belonging to the same substantial frequency band if the phase difference is smaller than the threshold value Q, and representing the obtained substantial frequency band by saving the starting frequency and the ending frequency of the substantial frequency band and/or saving the center frequency and the bandwidth of the substantial frequency band;
the virtual frequency bands comprise data input features and target defect labels, for each virtual frequency band, a gradient lifting tree is used for establishing a corresponding evaluation model, each evaluation model is trained for one virtual frequency band, for each evaluation model, model training is performed by using the data input features and the target defect labels of the corresponding virtual frequency band, and cross verification is adopted for optimizing parameters and generalization capacity of the model, so that a plurality of corresponding evaluation models are obtained;
And verifying and training the obtained evaluation model according to the data of the training real chuck image sequence, and updating to obtain the evaluation model.
6. The method for detecting a chuck defect of a laser pipe cutting machine according to claim 1, wherein the decomposing the image sequence to be recognized according to the chuck to obtain a plurality of frequency bands to be recognized, combining the plurality of evaluation models according to the plurality of frequency bands to be recognized, outputting to obtain a plurality of analysis data representations, and obtaining a detection result of the chuck defect of the laser pipe cutting machine according to the plurality of analysis data representations comprises:
performing time-frequency analysis on the chuck to-be-identified image sequence, applying short-time Fourier transform on each image of the chuck to-be-identified image sequence, dividing a signal into a plurality of time windows, and transforming on each window to obtain a time-frequency representation, and extracting a to-be-identified frequency band with obvious energy or characteristics from the time-frequency representation by using a threshold value and/or energy distribution;
combining the frequency bands to be identified into an evaluation model as data input, wherein the output label of the evaluation model is represented by a plurality of pieces of analysis data;
setting an overlapping threshold M for determining when two detection results are considered to be adjacent or overlapped, sequencing the detection results of each category according to the confidence level, starting from the detection result with the highest confidence level, retaining the detection result, removing other detection results which are overlapped with the detection result and exceed the overlapping threshold M, and repeating the process until all the detection results are processed;
And (3) carrying out connectivity analysis on the reserved detection results to combine adjacent overlapping results, searching the adjacent detection results by using a graph traversal algorithm, calculating the overlapping areas of the adjacent detection results, and determining whether to combine the adjacent detection results into a larger detection result according to the overlapping area and the overlapping proportion, wherein the results are used as final detection results of the chuck defects of the laser pipe cutting machine.
7. The method of claim 6, wherein the performing connectivity analysis on the retained test results to combine adjacent overlapping results, searching adjacent test results using a graph traversal algorithm, calculating overlapping areas of adjacent test results, and determining whether to combine them into a larger test result according to the overlapping area and the overlapping ratio, wherein the results are the final test result of the laser pipe cutting machine chuck defect, and the method comprises:
defining adjacent detection results under the condition that the overlapping area of the detection results is larger than an overlapping threshold L, defining a graph data structure comprising nodes and edges, wherein each node represents one detection result and comprises a unique identifier and boundary frame coordinate information, traversing all detection results, creating a node for each detection result, and adding the node to a graph;
Traversing each node in the graph, calculating the overlapping area of each pair of nodes, adding an edge between each pair of nodes if the overlapping area is larger than an overlapping threshold L, traversing the nodes in the graph from any node in the graph, and marking the accessed nodes;
in the traversing process, adjacent non-access nodes are found, the overlapping area of the non-access nodes is calculated, if the overlapping area is larger than the overlapping threshold L, the non-access nodes are combined into a larger detection result, the two detection results are combined through expanding a boundary box, and after the traversing is finished, the non-combined detection result is reserved as a final laser pipe cutting machine chuck defect detection result.
8. The utility model provides a laser pipe cutting machine chuck defect detection device which characterized in that, laser pipe cutting machine chuck defect detection device includes:
the acquisition module is used for acquiring data of the chuck surface and acquiring a real chuck image sequence and a chuck image sequence to be identified;
the processing module is used for carrying out space transformation on the reflection separation images of the plurality of chucks to obtain corresponding frequency spectrum gravity center information and kurtosis information, then carrying out space merging operation to obtain target frequency band information, carrying out spectrogram processing according to the target frequency band information and the kurtosis information, and extracting chuck correction frequency band information;
The setting module is used for carrying out additional extraction on the chuck correction frequency band information to obtain chuck amplitude information and phase information, then carrying out classification processing according to the amplitude information and the phase information, decomposing to obtain a plurality of substantial frequency bands, establishing a corresponding evaluation model aiming at each substantial frequency band, training by using a gradient lifting tree, and optimizing parameters and generalization capacity of the model by adopting cross verification;
the detection module is used for carrying out time-frequency analysis on the image sequence to be identified of the chuck, extracting a frequency band to be identified, then combining the frequency band to be identified with the evaluation model, outputting a plurality of analysis data representations, and finally obtaining a detection result of the chuck defect of the laser pipe cutting machine according to the plurality of analysis data representations.
9. Laser pipe cutting machine chuck defect detection equipment, its characterized in that, laser pipe cutting machine chuck defect detection equipment includes: a memory and at least one processor, the memory having instructions stored therein;
the at least one processor invoking the instructions in the memory to cause the laser pipe cutter chuck defect detection apparatus to perform the laser pipe cutter chuck defect detection method of any of claims 1-7.
10. A computer readable storage medium having instructions stored thereon, wherein the instructions when executed by a processor implement the method of laser pipe cutter chuck defect detection of any one of claims 1-7.
CN202410092812.7A 2024-01-23 2024-01-23 Method, device, equipment and storage medium for detecting chuck defects of laser pipe cutting machine Active CN117635606B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202410092812.7A CN117635606B (en) 2024-01-23 2024-01-23 Method, device, equipment and storage medium for detecting chuck defects of laser pipe cutting machine

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202410092812.7A CN117635606B (en) 2024-01-23 2024-01-23 Method, device, equipment and storage medium for detecting chuck defects of laser pipe cutting machine

Publications (2)

Publication Number Publication Date
CN117635606A CN117635606A (en) 2024-03-01
CN117635606B true CN117635606B (en) 2024-04-05

Family

ID=90030729

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202410092812.7A Active CN117635606B (en) 2024-01-23 2024-01-23 Method, device, equipment and storage medium for detecting chuck defects of laser pipe cutting machine

Country Status (1)

Country Link
CN (1) CN117635606B (en)

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112184693A (en) * 2020-10-13 2021-01-05 东北大学 Intelligent detection method for weld defects of ray industrial negative
CN112734692A (en) * 2020-12-17 2021-04-30 安徽继远软件有限公司 Transformer equipment defect identification method and device
CN113160192A (en) * 2021-04-28 2021-07-23 北京科技大学 Visual sense-based snow pressing vehicle appearance defect detection method and device under complex background
CN113505865A (en) * 2021-09-10 2021-10-15 浙江双元科技股份有限公司 Sheet surface defect image recognition processing method based on convolutional neural network
CN114219797A (en) * 2021-12-20 2022-03-22 天津光电通信技术有限公司 MEMS acoustic film surface defect detection method based on frequency domain transformation
CN116823817A (en) * 2023-08-28 2023-09-29 江苏州际数码印花有限公司 Textile jacquard defect detection method and system based on deep learning
CN117011250A (en) * 2023-07-20 2023-11-07 广东利元亨智能装备股份有限公司 Defect detection method, device and storage medium
CN117214178A (en) * 2023-09-15 2023-12-12 中国传媒大学 Intelligent identification method for appearance defects of package on packaging production line

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8451504B2 (en) * 2009-09-02 2013-05-28 Xerox Corporation Banding defect detection in digital imaging systems

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112184693A (en) * 2020-10-13 2021-01-05 东北大学 Intelligent detection method for weld defects of ray industrial negative
CN112734692A (en) * 2020-12-17 2021-04-30 安徽继远软件有限公司 Transformer equipment defect identification method and device
CN113160192A (en) * 2021-04-28 2021-07-23 北京科技大学 Visual sense-based snow pressing vehicle appearance defect detection method and device under complex background
CN113505865A (en) * 2021-09-10 2021-10-15 浙江双元科技股份有限公司 Sheet surface defect image recognition processing method based on convolutional neural network
CN114219797A (en) * 2021-12-20 2022-03-22 天津光电通信技术有限公司 MEMS acoustic film surface defect detection method based on frequency domain transformation
CN117011250A (en) * 2023-07-20 2023-11-07 广东利元亨智能装备股份有限公司 Defect detection method, device and storage medium
CN116823817A (en) * 2023-08-28 2023-09-29 江苏州际数码印花有限公司 Textile jacquard defect detection method and system based on deep learning
CN117214178A (en) * 2023-09-15 2023-12-12 中国传媒大学 Intelligent identification method for appearance defects of package on packaging production line

Also Published As

Publication number Publication date
CN117635606A (en) 2024-03-01

Similar Documents

Publication Publication Date Title
CN109740665B (en) Method and system for detecting ship target with occluded image based on expert knowledge constraint
Khan et al. An efficient contour based fine-grained algorithm for multi category object detection
Valliammal et al. Plant leaf segmentation using non linear K means clustering
Phoulady et al. A framework for nucleus and overlapping cytoplasm segmentation in cervical cytology extended depth of field and volume images
CN112614062B (en) Colony counting method, colony counting device and computer storage medium
CN110766689A (en) Method and device for detecting article image defects based on convolutional neural network
CN110348289B (en) Finger vein identification method based on binary image
De Automatic data extraction from 2D and 3D pie chart images
CN113516619B (en) Product surface flaw identification method based on image processing technology
Liang et al. Automatic defect detection of texture surface with an efficient texture removal network
Honi et al. Towards fast edge detection approach for industrial products
CN111814825B (en) Apple detection grading method and system based on genetic algorithm optimization support vector machine
CN109829902B (en) Lung CT image nodule screening method based on generalized S transformation and Teager attribute
Fang et al. Towards real-time crack detection using a deep neural network with a Bayesian fusion algorithm
CN113723314A (en) Sugarcane stem node identification method based on YOLOv3 algorithm
CN112200789B (en) Image recognition method and device, electronic equipment and storage medium
CN117495891A (en) Point cloud edge detection method and device and electronic equipment
CN117635606B (en) Method, device, equipment and storage medium for detecting chuck defects of laser pipe cutting machine
Cheng et al. Power pole detection based on graph cut
CN111488811A (en) Face recognition method and device, terminal equipment and computer readable medium
CN115082449B (en) Electronic component defect detection method
CN116664540A (en) Rubber sealing ring surface defect detection method based on Gaussian line detection
Mohana et al. Stem-calyx recognition of an apple using shape descriptors
CN110197114B (en) Automatic identification method and device for single neuron axon synaptic junction in whole brain range
CN110276260B (en) Commodity detection method based on depth camera

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