CN114067121A - Rusty plate laser cutting method based on computer vision - Google Patents
Rusty plate laser cutting method based on computer vision Download PDFInfo
- Publication number
- CN114067121A CN114067121A CN202111552467.3A CN202111552467A CN114067121A CN 114067121 A CN114067121 A CN 114067121A CN 202111552467 A CN202111552467 A CN 202111552467A CN 114067121 A CN114067121 A CN 114067121A
- Authority
- CN
- China
- Prior art keywords
- laser cutting
- image
- plate
- matrix
- structural part
- 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.)
- Withdrawn
Links
- 238000003698 laser cutting Methods 0.000 title claims abstract description 179
- 238000000034 method Methods 0.000 title claims abstract description 32
- 239000011159 matrix material Substances 0.000 claims abstract description 176
- JEIPFZHSYJVQDO-UHFFFAOYSA-N iron(III) oxide Inorganic materials O=[Fe]O[Fe]=O JEIPFZHSYJVQDO-UHFFFAOYSA-N 0.000 claims abstract description 45
- 238000012545 processing Methods 0.000 claims abstract description 24
- 238000013519 translation Methods 0.000 claims description 17
- 238000003708 edge detection Methods 0.000 claims description 11
- 230000011218 segmentation Effects 0.000 claims description 7
- 238000004364 calculation method Methods 0.000 claims description 3
- 239000002184 metal Substances 0.000 abstract description 4
- 238000013473 artificial intelligence Methods 0.000 abstract description 2
- 238000009826 distribution Methods 0.000 abstract description 2
- 238000003754 machining Methods 0.000 abstract 1
- 239000000463 material Substances 0.000 description 5
- 238000010586 diagram Methods 0.000 description 4
- 238000012797 qualification Methods 0.000 description 4
- 238000004458 analytical method Methods 0.000 description 3
- 241000221535 Pucciniales Species 0.000 description 2
- 238000010521 absorption reaction Methods 0.000 description 1
- 238000010009 beating Methods 0.000 description 1
- 230000009286 beneficial effect Effects 0.000 description 1
- 230000000694 effects Effects 0.000 description 1
- 238000005516 engineering process Methods 0.000 description 1
- 230000020169 heat generation Effects 0.000 description 1
- 230000009191 jumping Effects 0.000 description 1
- 239000007769 metal material Substances 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 239000002699 waste material Substances 0.000 description 1
Images
Classifications
-
- B—PERFORMING OPERATIONS; TRANSPORTING
- B23—MACHINE TOOLS; METAL-WORKING NOT OTHERWISE PROVIDED FOR
- B23K—SOLDERING OR UNSOLDERING; WELDING; CLADDING OR PLATING BY SOLDERING OR WELDING; CUTTING BY APPLYING HEAT LOCALLY, e.g. FLAME CUTTING; WORKING BY LASER BEAM
- B23K26/00—Working by laser beam, e.g. welding, cutting or boring
- B23K26/36—Removing material
- B23K26/38—Removing material by boring or cutting
-
- B—PERFORMING OPERATIONS; TRANSPORTING
- B23—MACHINE TOOLS; METAL-WORKING NOT OTHERWISE PROVIDED FOR
- B23K—SOLDERING OR UNSOLDERING; WELDING; CLADDING OR PLATING BY SOLDERING OR WELDING; CUTTING BY APPLYING HEAT LOCALLY, e.g. FLAME CUTTING; WORKING BY LASER BEAM
- B23K26/00—Working by laser beam, e.g. welding, cutting or boring
- B23K26/70—Auxiliary operations or equipment
- B23K26/702—Auxiliary equipment
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F17/00—Digital computing or data processing equipment or methods, specially adapted for specific functions
- G06F17/10—Complex mathematical operations
- G06F17/16—Matrix or vector computation, e.g. matrix-matrix or matrix-vector multiplication, matrix factorization
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/10—Segmentation; Edge detection
- G06T7/12—Edge-based segmentation
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/10—Segmentation; Edge detection
- G06T7/13—Edge detection
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T2207/00—Indexing scheme for image analysis or image enhancement
- G06T2207/20—Special algorithmic details
- G06T2207/20021—Dividing image into blocks, subimages or windows
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T2207/00—Indexing scheme for image analysis or image enhancement
- G06T2207/30—Subject of image; Context of image processing
- G06T2207/30108—Industrial image inspection
Landscapes
- Engineering & Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Theoretical Computer Science (AREA)
- Mathematical Physics (AREA)
- Mathematical Analysis (AREA)
- Data Mining & Analysis (AREA)
- Mechanical Engineering (AREA)
- Computational Mathematics (AREA)
- Plasma & Fusion (AREA)
- Optics & Photonics (AREA)
- Mathematical Optimization (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Pure & Applied Mathematics (AREA)
- Algebra (AREA)
- Computing Systems (AREA)
- Databases & Information Systems (AREA)
- Software Systems (AREA)
- General Engineering & Computer Science (AREA)
- Laser Beam Processing (AREA)
Abstract
The invention discloses a laser cutting method for rusty plates based on computer vision, which belongs to the field of artificial intelligence design and is mainly used for machining sheet metal structural parts. The method comprises the following steps: acquiring a laser cutting image, and processing to obtain a laser cutting edge image; collecting a plate surface image, and carrying out graying processing to obtain a plate gray image; taking the laser cutting edge image as a sliding window, and sliding on the plate gray scale image to obtain each structural part area; acquiring a laser cutting matrix, a plate gray matrix and each structural member matrix; respectively calculating an edge rust rate matrix of each structural part and an internal rust rate matrix of each structural part; and scoring the region of each structural member through the rusting rate matrix at the edge of each structural member and the rusting rate matrix in each structural member to obtain the region with the highest score for laser cutting. By the technical means provided by the invention, the laser cutting drawing and the distribution condition of the rust spots on the surface of the plate are combined, the rust rate is graded, and the optimal laser cutting area can be accurately and quickly obtained.
Description
Technical Field
The invention relates to the field of artificial intelligence, in particular to a laser cutting method for rusty plates based on computer vision.
Background
In order to avoid the waste of materials, a panel with rusty spots is used in the generation and processing of the sheet metal structural part. From the analysis of the cutting principle of the laser cutting machine, when there is no rust spot or no rust spot on the surface of the material, the situation of laser absorption is different, and the situation of heat generation is also greatly influenced. The cutting head can produce the phenomenon of beating, influences its stability and the qualification rate of cutting the work piece, and when laser cutting had rust panel, the rust spot can influence the stability of cutting head and the qualification rate of cutting the work piece, explodes the hole even when carrying out stamping process, causes the pollution to the lens.
In the prior art, rust removal treatment is usually performed on a rust plate by using a grinding machine, and then laser cutting is performed, but the plate subjected to grinding and rust removal still has certain influence on the laser cutting effect, and further planning is needed to minimize the influence. According to the method, the optimal laser cutting area of the rusted plate is screened out by combining a laser cutting drawing and the distribution condition of rusty spots on the surface of the plate through a computer vision technology.
Disclosure of Invention
The invention provides a laser cutting method of a rusty plate based on computer vision, which aims to solve the existing problems and comprises the following steps: acquiring a laser cutting image, and processing to obtain a laser cutting edge image; collecting a plate surface image, and carrying out graying processing to obtain a plate gray image; taking the laser cutting edge image as a sliding window, and sliding on the plate gray scale image to obtain each structural part area; acquiring a laser cutting matrix, a plate gray matrix and each structural member matrix; calculating an edge rust rate matrix of each structural member according to the laser cutting matrix and the plate gray matrix; calculating a structural member rusting rate matrix through the plate gray matrix and the structural member matrix; and scoring the region of each structural member through the rusting rate matrix at the edge of each structural member and the rusting rate matrix in each structural member to obtain the region with the highest score for laser cutting.
According to the technical means provided by the invention, the laser cutting image and the plate gray image are processed, the obtained structural part area is scored comprehensively through the edge rusting rate of each structural part and the rusting rate of the structural part, the surface of the whole plate can be accurately and quickly analyzed, the laser cutting is carried out according to the structural part area with the highest score, the influence caused by rusting of the plate surface is minimized, and the optimal laser cutting area of the rusted plate is obtained.
The invention adopts the following technical scheme that a rusty plate laser cutting method based on computer vision comprises the following steps:
and obtaining a laser cutting image, carrying out binarization processing to obtain a laser cutting binary image, and carrying out edge detection on the laser cutting binary image to obtain a laser cutting edge image.
Collecting the surface image of the plate, and carrying out gray processing on the surface image of the plate to obtain a gray image of the plate.
And taking the laser cutting edge image as a sliding window, sliding on the plate gray scale image, and obtaining a structural part area image after each sliding.
And calculating the rust rate matrix of the edge of each structural part through the pixel matrix of the laser cutting image and the pixel matrix of the plate gray level image.
And calculating the internal rusting rate matrix of each structural part through the pixel matrix of the plate gray level image and the pixel matrix of the structural part area image.
And scoring the structural part areas through the edge rusting rate matrix of each structural part and the internal rusting rate matrix of each structural part, and obtaining the structural part area with the highest score as a cutting area of the plate for laser cutting.
Further, a there is rust panel laser cutting method based on computer vision, through each structure edge rust rate matrix and each structure inside rust rate matrix is right each structure region is graded, obtains the regional laser cutting that carries out as the cutting region of panel of the structure that grades the highest, includes:
the scoring is carried out on the structural part areas, and the expression is as follows:
wherein p isijRate of rust matrix P for each structural member edgeM×NElement (ii) qijRusting rate matrix Q for structural memberM×NThe element in (1) i and j represent the number of rows and columns of the element in a matrix, M and N represent that the matrix consists of M rows and N columns of elements, and s and t are respectively the influence coefficients of the edge rust rate and the rust rate of the structural member.
Further, a rusty plate laser cutting method based on computer vision is characterized in that a rust rate matrix of the edge of each structural part is calculated through the laser cutting matrix and the plate gray matrix; through panel grey level matrix with structure matrix calculation structure rate of rusting matrix includes:
filling the laser cutting matrix subjected to rotary translation with 0 until the dimension of the laser cutting matrix is consistent with that of the plate gray matrix to obtain a laser cutting matrix AM×NBy laser cutting of matrix AM×NAnd the plate gray level matrix CM×NObtaining an edge rust rate matrix of each structural part at the cutting position by the dot product operation;
in the same way, the structural member matrix BM×NPlate gray matrix CM×NPerforming dot product operation to obtain a structural member rusting rate matrix QM×N(ii) a Where M and N represent a matrix consisting of M rows and N columns of elements in total.
Further, a laser cutting method for rusty plates based on computer vision, which uses the laser cutting edge image as a sliding window to slide on the plate gray scale image, and obtains a structural part area after each sliding, includes:
establishing a rectangular coordinate system by taking the lower left corner of the plate gray level image as an origin, wherein the length and the width of the plate are respectively L and W, putting the laser cutting edge image into the coordinate system, and recording the coordinate of the central point asGiving a cutting range through a minimum external rectangle of the sliding window, and realizing sliding window translation through coordinate change of a central point of the minimum external rectangle;
rotating the translated sliding window, wherein the rotating angle is theta, and the coordinates of the center point of the translated and rotated laser cutting edge image areAnd taking the corresponding area in the gray scale image of the plate at the moment as a structural part area image.
Further, a laser cutting method for rusty plates based on computer vision, which rotates the translated sliding window, further comprises the following steps:
when the rotated coordinates exceed the range of the plate, abandoning the corresponding area of the laser cutting edge image in the plate gray level image;
the range of the rotated coordinates beyond the plate is as follows:
wherein L is the length of the plate gray-scale image, W is the width of the plate gray-scale image, the range of the abscissa x 'of the laser cutting edge image after translation and rotation is [0, L ], and the range of the ordinate y' is [0, W ].
Further, the method for laser cutting of the rusty plate based on computer vision is used for collecting the surface image of the plate and carrying out gray processing on the surface image of the plate to obtain a gray image of the plate, and comprises the following steps:
collecting a surface image of a plate, performing semantic segmentation on the surface image of the plate through a DNN network to obtain a binary mask image of the plate, multiplying the binary mask image and the surface image of the plate to obtain an RGB image of the plate, and performing graying processing on the RGB image to obtain a gray image of the plate.
Further, a laser cutting method for rusty plates based on computer vision, which includes the steps of obtaining a laser cutting image, carrying out binarization processing to obtain a laser cutting binary image, carrying out edge detection on the laser cutting binary image to obtain a laser cutting edge image, and includes:
modeling is carried out according to a laser cutting drawing to obtain a laser cutting drawing, binaryzation is carried out on the laser cutting drawing by utilizing an Otsu threshold value to obtain a laser cutting binary drawing, edge detection is carried out on the laser cutting binary drawing, and a laser cutting edge image is obtained.
The invention has the beneficial effects that: according to the technical means provided by the invention, the laser cutting image and the plate gray image are processed, the obtained structural part area is scored comprehensively through the edge rusting rate of each structural part and the rusting rate of the structural part, the surface of the whole plate can be accurately and quickly analyzed, the laser cutting is carried out according to the structural part area with the highest score, the influence caused by rusting of the plate surface is minimized, and the optimal laser cutting area of the rusted plate is obtained.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to these drawings without creative efforts.
FIG. 1 is a schematic structural diagram of a laser cutting method for rusty plate based on computer vision according to an embodiment of the present invention;
fig. 2 is a schematic structural diagram of another laser cutting method for rusted plates based on computer vision according to an embodiment of the present invention.
Fig. 3 is a schematic diagram of a laser cutting drawing CAD format in an embodiment of the invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
Example 1
As shown in fig. 1, a schematic structural diagram of a laser cutting method for a rusty plate based on computer vision according to an embodiment of the present invention is provided, including:
101. and obtaining a laser cutting image, carrying out binarization processing to obtain a laser cutting binary image, and carrying out edge detection on the laser cutting binary image to obtain a laser cutting edge image.
A laser cutting drawing is designed according to the shape of a required structural part or cutting part, and the laser cutting drawing is exported to a CAD form, namely a form of black and white base lines, by using modeling software, as shown in FIG. 3.
And carrying out binarization processing on the obtained laser cutting image, enabling pixels of the developed image to be uniform to obtain a laser cutting binary image, and carrying out edge detection on the laser cutting binary image to obtain a laser edge cutting image.
102. Collecting the surface image of the plate, and carrying out gray processing on the surface image of the plate to obtain a gray image of the plate.
The rust spots on the plate are places with changed gray scale on the plate, and the rust spots on the plate and the position and degree information of the rust spots are identified by performing gray scale analysis on the surface image of the plate.
In this embodiment, a camera placed above the sheet material is used to capture a surface image of the sheet metal material, and a semantic segmentation method is used to identify an object in the surface image of the sheet material.
In other embodiments, the method for acquiring the image of the surface of the plate can be a camera, a mobile phone or any other device capable of acquiring pictures or pixel data.
In the embodiment, the collected plate image is a sheet metal plate image, and the technical means provided by the invention is suitable for laser segmentation of any metal plate or plate with rusty spots on the surface.
103. And taking the laser cutting edge image as a sliding window, sliding on the plate gray scale image, and obtaining a structural part area after each sliding.
The method comprises the steps of taking a laser edge cutting image as a sliding window to slide on a plate gray-scale image, representing the process of translating and rotating the laser edge cutting image on the plate gray-scale image, giving a translation direction, a translation distance and a rotation angle, reserving a corresponding area on the plate gray-scale image after sliding once, taking the area as a structural part area, and obtaining all structural part areas after sliding for multiple times until certain conditions are met.
For the laser cutting edge image, a cutting range is given through the minimum external rectangle, and the sliding window is translated through the coordinate change of the central point of the minimum external rectangle, so that the sliding window is rotated.
104. And taking the pixel matrix of the laser cutting edge image as a laser cutting matrix.
The laser cutting edge image is a binary image, and the corresponding pixel matrix is marked as a laser cutting matrix AM×NThe matrix is a 0-1 matrix, wherein the value of the pixel point needing laser cutting is 1, and the rest positions are 0.
105. And taking the pixel matrix of the plate gray level image as a plate gray level matrix.
For the gray-scale image of the plate, the pixel value of any pixel point represents whether the pixel point is rusted or not and the rusting degree, and whether the pixel point is in the laser cutting position or not is judged according to the pixel value of the pixel point in the laser cutting.
The pixel matrix corresponding to the plate gray level graph is recorded as a plate gray level matrix CM×NAnd any one pixel value represents whether the pixel point is rusted or not and the rusting degree.
106. And taking the pixel matrix of each structural part area as a structural part matrix.
The pixel matrix of the structural member obtained by laser cutting is recorded as a structural member matrix BM×NThe matrix passes through an identity matrix EM×NAnd laser cutting matrix AM×NSubtracting to obtain a structural member matrix BM×NIs a 0-1 matrix.
107. Calculating an edge rust rate matrix of each structural part according to the pixel matrix of the laser cutting image and the pixel matrix of the plate gray level image; and calculating the internal rusting rate matrix of each structural part through the pixel matrix of the plate gray level image and the pixel matrix of the structural part area image.
Due to laser cutting matrix AM×NIs a 0-1 matrix, and matrix A is cut by laserM×NAnd the plate gray level matrix CM×NThe point multiplication operation of (1) is carried out on two matrixes with consistent dimensionality element by element, for the position needing to be cut, the pixel value is 1, the gray value of the position corresponding to the gray matrix of the plate is multiplied, the rusting degree of the cutting position can be obtained, for the position needing not to be cut, the pixel value is 0, the multiplication result is still 0, and finally the rusting rate matrix P of the edge of each structural part is obtainedM×N。
In the same way, the structural member matrix BM×NAnd the plate gray level matrix CM×NPerforming dot product operation to obtain a structural member rusting rate matrix QM×N。
108. And scoring the structural part areas through the edge rusting rate matrix of each structural part and the internal rusting rate matrix of each structural part, and obtaining the structural part area with the highest score as a cutting area of the plate for laser cutting.
The scoring formula is:
wherein p isijRate of rust matrix P for each structural member edgeM×NElement of (1), rust rate matrix P of each structural member edgeM×N=AM×N·CM×N;qijStructural member rusting rate matrix QM×NThe elements in (1): qM×N=BM×N·CM×NAnd s and t are respectively the influence coefficients of the edge rusting rate of each structural member and the rusting rate of the structural member.
According to the technical means provided by the invention, the laser cutting image and the plate gray image are processed, the obtained structural part area is scored comprehensively through the edge rusting rate of each structural part and the rusting rate of the structural part, the surface of the whole plate can be accurately and quickly analyzed, the laser cutting is carried out according to the structural part area with the highest score, the influence caused by rusting of the plate surface is minimized, and the optimal laser cutting area of the rusted plate is obtained.
Example 2
As shown in fig. 2, another laser cutting method for rusty plates based on computer vision according to an embodiment of the present invention is provided, which includes:
201. and obtaining a laser cutting image, carrying out binarization processing to obtain a laser cutting binary image, and carrying out edge detection on the laser cutting binary image to obtain a laser cutting edge image.
And designing a laser cutting drawing according to the shape of a required structural part or a required cutting part, and exporting the laser cutting drawing into a CAD form, namely a form of black and white base lines by using modeling software.
Acquiring a laser cutting image, carrying out binarization processing to obtain a laser cutting binary image, carrying out edge detection on the laser cutting binary image to obtain a laser cutting edge image, and comprising the following steps:
modeling is carried out according to a laser cutting drawing to obtain a laser cutting drawing, binaryzation is carried out on the laser cutting drawing by utilizing an Otsu threshold value to obtain a laser cutting binary drawing, edge detection is carried out on the binary drawing of the laser cutting drawing by using a canny operator to obtain a laser cutting edge image.
202. Collecting the surface image of the plate, and carrying out gray processing on the surface image of the plate to obtain a gray image of the plate.
The rust spots on the plate are places with changed gray scale on the plate, and the rust spots on the plate and the position and degree information of the rust spots are identified by performing gray scale analysis on the surface image of the plate.
Collecting a plate surface image, and carrying out gray processing on the plate surface image to obtain a plate gray image, wherein the method comprises the following steps:
collecting a surface image of a plate, performing semantic segmentation on the surface image of the plate through a DNN network to obtain a binary mask image of the plate, multiplying the binary mask image and the surface image of the plate to obtain an RGB image of the plate, and performing graying processing on the RGB image to obtain a gray image of the plate.
The specific contents of the DNN network are as follows:
the data set used is a collected sheet surface image data set.
The labels are of two types, a panel area and a background area. The method is pixel-level classification, all pixel points of an image are manually marked, the pixel point value of a plate area is marked as 1, and the pixel point value of a background area is marked as 0.
And after the semantic segmentation result is obtained, the semantic segmentation result is the corresponding binary mask of the plate, multiplication operation is carried out on the binary mask and the original image to realize deduction of the plate image, and after the RGB image of the plate is obtained, corresponding graying processing is carried out to obtain the grayscale image of the plate.
203. And taking the laser cutting edge image as a sliding window, sliding on the plate gray scale image, and obtaining a structural part area after each sliding.
Using the laser cutting edge image as a sliding window, and sliding on the plate gray scale image to obtain corresponding structural part areas, including:
establishing a rectangular coordinate system by taking the lower left corner of the plate gray-scale image as an origin, wherein the length and the width of the plate are respectively L and W, putting the laser cutting edge image into the coordinate system, and recording the coordinates asGiving a cutting range through a minimum external rectangle of the sliding window, and realizing sliding window translation through coordinate change of a central point of the minimum external rectangle;
the abscissa of the pixel point corresponds to x, the range of x is [0, W ], and the ordinate of y is [0, L ].
The range of the translation distance is determined by the movable range of the central point of the minimum circumscribed rectangle in the graph, so that the range of the horizontal translation distance isThe distance range of the vertical translation isl and w are the length and width of the minimum circumscribed rectangle of the laser cut edge image, respectively.
Rotating the translated sliding window, wherein the rotating angle is theta, and the coordinates of the translated and rotated laser cutting edge image areThe angle of rotation theta epsilon 0, 360 deg..
Wherein theta is the rotation angle of the lens,a and b in (1) are translation distances in the horizontal direction and the vertical direction, respectively.
Rotate the sliding window after will translating, still include:
when the rotated coordinates exceed the range of the plate, abandoning the corresponding area of the laser cutting edge image in the plate gray level image;
the range of the rotated coordinates beyond the plate is as follows:
wherein L is the length of the plate gray-scale image, W is the width of the plate gray-scale image, the range of the abscissa x 'of the laser cutting edge image after translation and rotation is [0, L ], and the range of the ordinate y' is [0, W ].
2041. And taking the pixel matrix of the laser cutting edge image as a laser cutting matrix.
The laser cutting edge image is a binary image, and the corresponding pixel matrix is marked as a laser cutting matrix AM×NThe matrix is a 0-1 matrix, wherein the value of the pixel point needing laser cutting is 1, and the rest positions are 0.
2042. And taking the pixel matrix of the plate gray level image as a plate gray level matrix.
For the gray-scale image of the plate, the pixel value of any pixel point represents whether the pixel point is rusted or not and the rusting degree, and whether the pixel point is in the laser cutting position or not is judged according to the pixel value of the pixel point in the laser cutting.
The pixel matrix corresponding to the plate gray level graph is recorded as a plate gray level matrix CM×NAnd any one pixel value represents whether the pixel point is rusted or not and the rusting degree.
2043. And taking the pixel matrix of each structural part area as a structural part matrix.
The pixel matrix of the structural member obtained by laser cutting is recorded as a structural member matrix BM×NThe matrix passes through an identity matrix EM×NAnd laser cutting matrix AM×NSubtracting to obtain a structural member matrix BM×NIs a 0-1 matrix.
205. Calculating an edge rust rate matrix of each structural part according to the pixel matrix of the laser cutting image and the pixel matrix of the plate gray level image; and calculating the internal rusting rate matrix of each structural part through the pixel matrix of the plate gray level image and the pixel matrix of the structural part area image.
When a plate with rusty spots is cut by laser, the cutting head can generate a jumping phenomenon at the rusty spots, so that the stability of the plate and the qualification rate of a cut workpiece are influenced. Therefore, laser cutting is performed to avoid the rusty spot of the plate material as much as possible.
Obtaining the optimal laser cutting area needs to consider the following two aspects:
the rust rate of the edge of each structural part. The less the number of rusts and the lighter the degree of rusting in the area through which the laser cuts, the lower the rate of rusting at the edge of each structural member.
The internal rusting rate of the structural part. The less the number of rusts and the lighter the degree of rusting on the laser-cut structural member, the lower the rate of rusting inside the structural member.
Calculating an edge rust rate matrix of each structural member according to the laser cutting matrix and the plate gray matrix; through panel grey level matrix with structure matrix calculation structure rate of rusting matrix includes:
the matrix dot multiplication operation is required, namely, the two matrixes with the same dimensionality are multiplied element by element, the dimensionality of the two matrixes is required to be consistent, the laser cutting matrix after the rotation translation is filled with 0 until the dimensionality of the laser cutting matrix is consistent with the dimensionality of the plate gray matrix, and the laser cutting matrix A is obtainedM×N(ii) a Filling the structural member matrix with 0 to be consistent with the dimension of the plate gray matrix to obtain a structural member matrix BM×N。
Filling the laser cutting matrix subjected to rotary translation with 0 until the dimension of the laser cutting matrix is consistent with that of the plate gray matrix to obtain a laser cutting matrix AM×NBy laser cutting of matrix AM×NAnd the plate gray level matrix CM×NObtaining an edge rust rate matrix of each structural part at the cutting position by the dot product operation;
in the same way, the structural member matrix BM×NPlate gray matrix CM×NPerforming dot product operation to obtain a structural member rusting rate matrix QM×N。
206. And scoring the structural part areas through the edge rusting rate matrix of each structural part and the internal rusting rate matrix of each structural part, and obtaining the structural part area with the highest score as a cutting area of the plate for laser cutting.
Through each structure edge rust rate matrix and the inside rust rate matrix of each structure are right each structure region is graded, obtains the cutting region of the highest structure region of grading as panel and carries out laser cutting, include:
the scoring is carried out on the structural part areas, and the expression is as follows:
wherein p isijRate of rust matrix P for each structural member edgeM×NElement (ii) qijRusting rate matrix Q for structural memberM×NThe element in (1) i and j represent the number of rows and columns of the element in a matrix, M and N represent that the matrix consists of M rows and N columns of elements, and s and t are respectively the influence coefficients of the edge rust rate and the rust rate of the structural member. In this embodiment, s and t take values of 2 and 1, respectively.
And selecting the area with the highest score according to the scoring result of each structural part to carry out laser cutting, thus obtaining the structural part with the highest qualification rate.
According to the technical means provided by the invention, the laser cutting image and the plate gray image are processed, the obtained structural part area is scored comprehensively through the edge rusting rate of each structural part and the rusting rate of the structural part, the surface of the whole plate can be accurately and quickly analyzed, the laser cutting is carried out according to the structural part area with the highest score, the influence caused by rusting of the plate surface is minimized, and the optimal laser cutting area of the rusted plate is obtained.
The above description is only for the purpose of illustrating the preferred embodiments of the present invention and is not to be construed as limiting the invention, and any modifications, equivalents, improvements and the like that fall within the spirit and principle of the present invention are intended to be included therein.
Claims (7)
1. A rusty plate laser cutting method based on computer vision is characterized by comprising the following steps:
obtaining a laser cutting image, carrying out binarization processing to obtain a laser cutting binary image, and carrying out edge detection on the laser cutting binary image to obtain a laser cutting edge image;
collecting a plate surface image, and carrying out gray processing on the plate surface image to obtain a plate gray image;
taking the laser cutting edge image as a sliding window, sliding on the plate gray scale image, and obtaining a structural part area image after each sliding;
calculating an edge rust rate matrix of each structural part according to the pixel matrix of the laser cutting image and the pixel matrix of the plate gray level image;
calculating an internal rusting rate matrix of each structural part through the pixel matrix of the plate gray level image and the pixel matrix of the structural part area image;
and scoring the structural part areas through the edge rusting rate matrix of each structural part and the internal rusting rate matrix of each structural part, and obtaining the structural part area with the highest score as a cutting area of the plate for laser cutting.
2. The laser cutting method for the rusty plate based on the computer vision is characterized in that each structural part area is scored through the edge rusting rate matrix of each structural part and the internal rusting rate matrix of each structural part, and the structural part area with the highest score is obtained to be used as the cutting area of the plate to be subjected to laser cutting, and comprises the following steps of:
the scoring is carried out on the structural part areas, and the expression is as follows:
wherein p isijRate of rust matrix P for each structural member edgeM×NElement (ii) qijRusting rate matrix Q for structural memberM×NWherein, i and j represent the number of rows and columns of the element in the matrix, N represents the matrix composed of M rows and N columns of elements, and s and t are the influence coefficients of the edge rust rate and the rust rate of the structure respectively.
3. The laser cutting method of the rusty plate based on the computer vision is characterized in that the rust rate matrix of the edge of each structural part is calculated through the laser cutting matrix and the plate gray matrix; through panel grey level matrix with structure matrix calculation structure rate of rusting matrix includes:
filling the laser cutting matrix subjected to rotary translation with 0 until the dimension of the laser cutting matrix is consistent with that of the plate gray matrix to obtain a laser cutting matrix AM×NBy laser cutting of matrix AM×NAnd the plate gray level matrix CM×NThe point multiplication operation of (2) to obtain a rust rate matrix P of the edge of each structural member at the cutting positionM×N;
In the same way, the structural member matrix BM×NPlate gray matrix CM×NPerforming dot product operation to obtain a structural member rusting rate matrix QM×N(ii) a Where M and N represent a matrix consisting of M rows and N columns of elements in total.
4. The laser cutting method of rusty plate based on computer vision as claimed in claim 1, wherein the step of sliding the laser cutting edge image on the gray scale map of the plate as a sliding window, each sliding resulting in a structural part area, comprises:
establishing a rectangular coordinate system by taking the lower left corner of the plate gray level image as an origin, wherein the length and the width of the plate are respectively L and W, putting the laser cutting edge image into the coordinate system, and recording the coordinate of the central point asGiving a cutting range through a minimum external rectangle of the sliding window, and realizing sliding window translation through coordinate change of a central point of the minimum external rectangle;
5. The laser cutting method of rusted plate based on computer vision according to claim 4, wherein the translated sliding window is rotated, further comprising:
when the rotated coordinates exceed the range of the plate, abandoning the corresponding area of the laser cutting edge image in the plate gray level image;
the range of the rotated coordinates beyond the plate is as follows:
wherein L is the length of the plate gray-scale image, W is the width of the plate gray-scale image, the range of the abscissa x 'of the laser cutting edge image after translation and rotation is [0, L ], and the range of the ordinate y' is [0, W ].
6. The laser cutting method of the rusty plate based on the computer vision as claimed in claim 1, wherein the step of acquiring the surface image of the plate, and performing graying processing on the surface image of the plate to obtain a gray-scale image of the plate comprises the following steps:
collecting a surface image of a plate, performing semantic segmentation on the surface image of the plate through a DNN network to obtain a binary mask image of the plate, multiplying the binary mask image and the surface image of the plate to obtain an RGB image of the plate, and performing graying processing on the RGB image to obtain a gray image of the plate.
7. The laser cutting method of the rusty plate based on the computer vision as claimed in claim 1, wherein the step of obtaining a laser cutting map and performing binarization processing to obtain a laser cutting binary map, and performing edge detection on the laser cutting binary map to obtain a laser cutting edge image comprises the steps of:
modeling is carried out according to a laser cutting drawing to obtain a laser cutting drawing, binaryzation is carried out on the laser cutting drawing by utilizing an Otsu threshold value to obtain a laser cutting binary drawing, edge detection is carried out on the laser cutting binary drawing, and a laser cutting edge image is obtained.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202111552467.3A CN114067121A (en) | 2021-12-17 | 2021-12-17 | Rusty plate laser cutting method based on computer vision |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202111552467.3A CN114067121A (en) | 2021-12-17 | 2021-12-17 | Rusty plate laser cutting method based on computer vision |
Publications (1)
Publication Number | Publication Date |
---|---|
CN114067121A true CN114067121A (en) | 2022-02-18 |
Family
ID=80229757
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202111552467.3A Withdrawn CN114067121A (en) | 2021-12-17 | 2021-12-17 | Rusty plate laser cutting method based on computer vision |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN114067121A (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN114406502A (en) * | 2022-03-14 | 2022-04-29 | 扬州市振东电力器材有限公司 | Laser metal cutting method and system |
-
2021
- 2021-12-17 CN CN202111552467.3A patent/CN114067121A/en not_active Withdrawn
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN114406502A (en) * | 2022-03-14 | 2022-04-29 | 扬州市振东电力器材有限公司 | Laser metal cutting method and system |
CN114406502B (en) * | 2022-03-14 | 2022-11-25 | 扬州市振东电力器材有限公司 | Laser metal cutting method and system |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN111080622B (en) | Neural network training method, workpiece surface defect classification and detection method and device | |
CN106934800B (en) | Metal plate strip surface defect detection method and device based on YOLO9000 network | |
CN108355987B (en) | A kind of screen printing of battery quality determining method based on piecemeal template matching | |
CN103439348B (en) | Remote controller key defect detection method based on difference image method | |
US8654398B2 (en) | Method for simulating impact printer output, evaluating print quality, and creating teaching print samples | |
CN103093240A (en) | Calligraphy character identifying method | |
CN104700092B (en) | A kind of small characters digit recognition method being combined based on template and characteristic matching | |
Lee et al. | Automatic extraction of characters in complex scene images | |
CN104156704A (en) | Novel license plate identification method and system | |
CN107832767A (en) | Container number identification method, device and electronic equipment | |
CN111982910B (en) | Weak supervision machine vision detection method and system based on artificial defect simulation | |
CN104636701A (en) | Laser two-dimension code identification method based on image restoration | |
CN110443791B (en) | Workpiece detection method and device based on deep learning network | |
CN113191358B (en) | Metal part surface text detection method and system | |
CN112883926B (en) | Identification method and device for form medical images | |
CN105894487A (en) | Steel material image number extraction and segmentation method | |
CN115294089A (en) | Steel surface defect detection method based on improved YOLOv5 | |
CN109409378A (en) | A kind of digitalized processing method of Nahsi Dongba Confucian classics | |
CN114067121A (en) | Rusty plate laser cutting method based on computer vision | |
CN109741273A (en) | A kind of mobile phone photograph low-quality images automatically process and methods of marking | |
CN110889374A (en) | Seal image processing method and device, computer and storage medium | |
CN111047646A (en) | Multi-target lens positioning method and system based on FPGA | |
CN110766001A (en) | Bank card number positioning and end-to-end identification method based on CNN and RNN | |
CN114565749A (en) | Method and system for identifying key content of visa document of power construction site | |
CN107895152A (en) | A kind of in-orbit clearance quick determination method |
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 | ||
WW01 | Invention patent application withdrawn after publication |
Application publication date: 20220218 |
|
WW01 | Invention patent application withdrawn after publication |