Laser rapid marking positioning method and system

By obtaining the scale feature information of the target image and edge point coordinates, distortion correction and positioning matching are performed, the problems of low positioning accuracy and great distortion impact in the prior art are solved, and a higher laser marking accuracy is achieved.

CN119549892AActive Publication Date: 2025-03-04JIESEN POWER TECH (GUANGDONG) CO LTD
View PDF 6 Cites 0 Cited by

Patent Information

Application Number
CN202411680964.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-11-22
Publication Date
2025-03-04
Estimated Expiration
2044-11-22

AI Technical Summary

Technical Problem

In the existing laser marking technology, the positioning accuracy is low and the distortion is greatly affected, making it difficult to accurately determine the spatial coordinates of edge points, affecting the accuracy of marking.

Method used

By obtaining the image scale feature information of the target image, extracting multiple groups of effective edge point coordinates, constructing preliminary contour information, and calculating the rotation angle and translation distance through distortion value correction, constructing the corrected contour information, and obtaining the simulated mapping trajectory for positioning and matching.

Benefits of technology

The positioning accuracy of the laser marking system is significantly improved, ensuring that the laser beam can be accurately focused on the target area, and avoiding errors caused by inaccurate positioning.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119549892A_ABST
    Figure CN119549892A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of laser positioning, and particularly discloses a laser rapid marking positioning method and system, and the method comprises the steps: obtaining the image scale feature information of a target image; obtaining a plurality of groups of effective edge point coordinates according to the image scale feature information; acquiring first contour information of the target image according to the multiple groups of effective edge point coordinates; obtaining a distortion value of the target image according to the first contour information; calculating a rotation angle value and a translation distance value of the target image according to the distortion value; correcting the first contour information according to the rotation angle value and the translation distance value, and obtaining second contour information after correction of the target image; through accurate distortion correction and coordinate transformation, the positioning accuracy of the laser marking system can be remarkably improved, the distortion coefficient is used for correcting coordinates, the rotation angle and the translation distance are calculated, and the positioning and marking accuracy can be remarkably improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of laser positioning technology, and in particular to a laser rapid marking positioning method and system. Background Art

[0002] Laser processing is a non-contact processing method that can achieve a variety of processing goals. In laser processing, the traditional manual positioning method has problems such as inaccurate workpiece placement and low work efficiency. Therefore, it is necessary to improve the positioning accuracy of the workpiece during processing. Based on this, many scholars have studied laser processing positioning methods, such as the power line suspension point positioning method based on laser point cloud.

[0003] In the prior art, when positioning is performed through machine vision image recognition, only surface information can be obtained, and it is difficult to accurately determine the spatial coordinates of edge points. In addition, when existing laser marking equipment (such as scanning galvanometers) obtains image information, there is often varying degrees of distortion in the information of the target image obtained by the scanning galvanometer, which will affect the accuracy of laser marking and further affect the accuracy of marking. Summary of the invention

[0004] The purpose of the present invention is to provide a laser rapid marking positioning method to solve the technical problems raised in the above background technology.

[0005] To achieve the above object, the present invention provides the following technical solutions:

[0006] A laser rapid marking positioning method, comprising:

[0007] Obtaining image scale feature information of the target image;

[0008] Acquire multiple groups of valid edge point coordinates according to image scale feature information;

[0009] Acquire first contour information of the target image according to multiple groups of valid edge point coordinates;

[0010] Acquire a distortion value of the target image according to the first contour information;

[0011] Calculate the rotation angle value and translation distance value of the target image according to the distortion value;

[0012] Correcting the first contour information according to the rotation angle value and the translation distance value, and obtaining the corrected second contour information of the target image;

[0013] Acquire the coordinates of the contour edge points according to the second contour information, and acquire the simulation mapping trajectory according to the coordinates of the contour edge points;

[0014] Perform edge point positioning and matching on the target image based on the simulated mapping trajectory;

[0015] If they match, the target image is positioned by laser marking;

[0016] If there is no match, the second contour information is returned as the first contour information to the step of obtaining the distortion value of the target image according to the first contour information.

[0017] Preferably, the step of acquiring multiple groups of valid edge point coordinates according to the image scale feature information includes:

[0018] Acquire the real-time image width and real-time image height according to the image scale feature information;

[0019] Obtain aspect ratio value according to real-time image width and real-time image height;

[0020] Acquire edge point feature information of the target image based on the optical flow method, wherein the edge point feature information includes edge point coordinate information and edge point direction information;

[0021] Obtaining the angle value between the edge point and the preset horizontal axis according to the edge point coordinate information and the edge point direction information;

[0022] Divide the target image according to the angle value, the real-time image width, the real-time image height and the aspect ratio value to obtain a plurality of image division areas;

[0023] Get the brightness value of the edge points in each image segmentation area;

[0024] Determine whether the brightness value of the edge point is less than the preset value;

[0025] If it is less than, the corresponding edge point will be removed;

[0026] If it is greater than, the corresponding edge point is determined to be a valid edge point;

[0027] Get the valid edge point coordinates corresponding to the valid edge points in all image partition areas.

[0028] Preferably, the step of acquiring first contour information of the target image according to multiple groups of valid edge point coordinates includes:

[0029] Obtain multiple horizontal coordinates and multiple vertical coordinates according to each group of edge point coordinates;

[0030] Obtain the direction angle of the edge point according to the horizontal coordinate and the vertical coordinate;

[0031] The contour of each edge point coordinate is traced according to the edge point direction angle to obtain the first contour information.

[0032] Preferably, the step of acquiring the distortion value of the target image according to the first contour information includes:

[0033] Acquire a maximum contour width value and a maximum contour height value according to the first contour information;

[0034] Obtain preset characteristic coefficients;

[0035] Get the preset outline width and preset outline height;

[0036] The contour edge variation coefficient is calculated based on the contour width, contour height and preset characteristic coefficient. The calculation formula is:

[0037]

[0038] Among them, Q is the contour edge variation coefficient, ρ is the preset characteristic coefficient, k x is the contour width, k y is the profile height, i is the preset profile width, and j is the preset profile height;

[0039] Acquire a scale value of the first contour information according to a maximum contour width value and a maximum contour height value;

[0040] The distortion value is calculated according to the contour edge variation coefficient and scale value. The calculation formula is:

[0041] f (x,y) =Q*L (x,y) ;

[0042] Among them, f (x , y) is the distortion value, Q is the contour edge variation coefficient, L (x , y) is the scale value.

[0043] Preferably, the step of obtaining the rotation angle value and the translation distance value of the target image according to the distortion value includes:

[0044] Acquire a contour horizontal coordinate according to the first contour information;

[0045] Obtaining a first distortion coefficient of the contour horizontal coordinate according to the distortion coefficient;

[0046] Acquire the contour ordinate according to the first contour information;

[0047] Obtaining a second distortion coefficient of the contour ordinate according to the distortion coefficient;

[0048] The corrected abscissa is calculated according to the profile abscissa, the first distortion coefficient, the profile ordinate and the second distortion coefficient. The calculation formula is:

[0049] x (u) =X+(2p1Y+p2(r 2 +2X 2 ));

[0050] Among them, x (u) is the correction horizontal coordinate, X is the profile horizontal coordinate, Y is the profile vertical coordinate, p1 is the first distortion coefficient, and p2 is the second distortion coefficient;

[0051] The corrected ordinate is calculated according to the profile abscissa, the first distortion coefficient, the profile ordinate and the second distortion coefficient. The calculation formula is:

[0052] y (u) =Y+(p1(r 2 +2Y 2 )+2p2X);

[0053] Among them, y (u) is the correction ordinate, X is the profile abscissa, Y is the profile ordinate, p1 is the first distortion coefficient, and p2 is the second distortion coefficient;

[0054] Obtain the rotation angle value according to the correction horizontal coordinate, the correction vertical coordinate, the contour horizontal coordinate, and the contour vertical coordinate;

[0055] The translation distance value is obtained according to the corrected horizontal coordinate and the corrected vertical coordinate and the contour horizontal coordinate and the contour vertical coordinate based on the Euclidean distance calculation method.

[0056] Preferably, the step of correcting the first contour information according to the rotation angle value and the translation distance value, and acquiring the corrected second contour information of the target image comprises:

[0057] Acquire contour abscissas and contour ordinates of a plurality of contour points according to the first contour information;

[0058] Based on the rotation angle value and the translation distance value, the contour abscissa and the contour ordinate of each contour point are transformed to obtain the corresponding contour correction point;

[0059] All contour correction points are connected to obtain second contour information.

[0060] Preferably, the step of obtaining the coordinates of the contour edge points according to the second contour information, and obtaining the simulated mapping trajectory according to the coordinates of the contour edge points includes:

[0061] Acquire a plurality of contour correction point information according to the second contour information, wherein the contour correction point information includes a contour correction horizontal coordinate and a contour correction vertical coordinate;

[0062] Get the distance value from the scanning galvanometer to the target image;

[0063] Based on the distance value, all the contour edge point coordinates are mapped into the three-dimensional space to obtain multiple three-dimensional coordinates;

[0064] Establishing a contour simulation image according to a plurality of three-dimensional coordinates;

[0065] Acquire multiple three-dimensional contour edge point coordinates according to the contour simulation image;

[0066] Acquire a connection sequence of tracking edge points based on multiple three-dimensional contour edge point coordinates;

[0067] Marking the coordinates of all contour edge points based on the connection sequence of the tracked edge points;

[0068] The simulated mapping trajectory is obtained based on the labeling process.

[0069] The present invention also discloses a laser rapid marking positioning system, comprising:

[0070] A first acquisition module is used to acquire image scale feature information of a target image;

[0071] A second acquisition module is used to acquire multiple groups of valid edge point coordinates according to image scale feature information;

[0072] A third acquisition module, used for acquiring first contour information of the target image according to multiple groups of valid edge point coordinates;

[0073] A fourth acquisition module, used for acquiring a distortion value of a target image according to the first contour information;

[0074] A fifth acquisition module, used for calculating a rotation angle value and a translation distance value of a target image according to the distortion value;

[0075] A sixth acquisition module, used to correct the first contour information according to the rotation angle value and the translation distance value, and obtain the corrected second contour information of the target image;

[0076] A seventh acquisition module, used to acquire the coordinates of the contour edge points according to the second contour information, and to acquire the simulation mapping trajectory according to the coordinates of the contour edge points;

[0077] A judgment module, used for locating and matching edge points of a target image based on a simulated mapping trajectory;

[0078] If they match, the target image is positioned by laser marking;

[0079] If there is no match, the second contour information is returned as the first contour information to the step of obtaining the distortion value of the target image according to the first contour information.

[0080] Preferably, the fourth acquisition module includes:

[0081] A first acquisition unit, used for acquiring a maximum contour width value and a maximum contour height value according to the first contour information;

[0082] A second acquisition unit, used to acquire a preset characteristic coefficient;

[0083] A third acquisition unit, used to acquire a preset contour width and a preset contour height;

[0084] The first calculation unit is used to calculate the contour edge variation coefficient according to the contour width, the contour height and the preset characteristic coefficient, and the calculation formula is:

[0085]

[0086] Among them, Q is the contour edge variation coefficient, ρ is the preset characteristic coefficient, k x is the contour width, k y is the profile height, i is the preset profile width, and j is the preset profile height;

[0087] A fourth acquisition unit, configured to acquire a scale value of the first contour information according to a maximum contour width value and a maximum contour height value;

[0088] The second calculation unit is used to calculate the distortion value according to the contour edge variation coefficient and the scale value. The calculation formula is:

[0089] f (x,y) =Q*L (x,y) ;

[0090] Among them, f (x,y) is the distortion value, Q is the contour edge variation coefficient, L (x,y) is the scale value.

[0091] Preferably, the fifth acquisition module includes:

[0092] A fifth acquisition unit, configured to acquire a contour horizontal coordinate according to the first contour information;

[0093] A sixth acquisition unit, used for acquiring a first distortion coefficient of a horizontal coordinate of a contour according to the distortion coefficient;

[0094] A seventh acquisition unit, configured to acquire a contour ordinate according to the first contour information;

[0095] An eighth acquisition unit, configured to acquire a second distortion coefficient of the contour ordinate according to the distortion coefficient;

[0096] The third calculation unit is used to calculate the corrected horizontal coordinate according to the contour horizontal coordinate, the first distortion coefficient, the contour vertical coordinate and the second distortion coefficient, and the calculation formula is:

[0097] x (u) =X+(2p1Y+p2(r 2 +2X 2 ));

[0098] Among them, x (u)is the correction horizontal coordinate, X is the profile horizontal coordinate, Y is the profile vertical coordinate, p1 is the first distortion coefficient, and p2 is the second distortion coefficient;

[0099] The fourth calculation unit is used to calculate the corrected ordinate according to the profile abscissa, the first distortion coefficient, the profile ordinate and the second distortion coefficient, and the calculation formula is:

[0100] y (u) =Y+(p1(r 2 +2Y 2 )+2p2X);

[0101] Among them, y (u) is the correction ordinate, X is the profile abscissa, Y is the profile ordinate, p1 is the first distortion coefficient, and p2 is the second distortion coefficient;

[0102] A ninth acquisition unit, configured to acquire a rotation angle value according to the corrected horizontal coordinate and the corrected vertical coordinate and the contour horizontal coordinate and the contour vertical coordinate;

[0103] The tenth acquisition unit is used to acquire the translation distance value according to the corrected horizontal coordinate and the corrected vertical coordinate and the contour horizontal coordinate and the contour vertical coordinate based on the Euclidean distance calculation method.

[0104] The beneficial effects of the present application are as follows: the present invention can significantly improve the positioning accuracy of the laser marking system through precise distortion correction and coordinate transformation, and can significantly improve the accuracy of positioning and marking by using distortion coefficients to correct coordinates, calculate rotation angles and translation distances, etc. This ensures that during the marking process, the laser beam can be accurately focused on the target area, avoiding errors caused by inaccurate positioning, and constructing preliminary contour information by acquiring the scale feature information of the target image, extracting the coordinates of the effective edge points. Due to the distortion and noise that may exist during image acquisition and transmission, errors exist in the preliminary contour information. Therefore, by calculating the distortion value, the contour information is corrected, and the rotation angle and translation distance are obtained, thereby constructing the corrected contour information. Based on the corrected contour information, a virtual simulation mapping trajectory is constructed, which is the path that the laser marking device needs to follow. If the simulated mapping trajectory matches the actual path, the positioning is successful; otherwise, the correction and positioning operations are repeated until they match. BRIEF DESCRIPTION OF THE DRAWINGS

[0105] Figure 1 Schematic diagram of the method flow of this application.

[0106] Figure 2 This is a schematic diagram of the system structure of this application.

[0107] The realization of the purpose, functional features and advantages of this application will be further explained in conjunction with embodiments and with reference to the accompanying drawings. DETAILED DESCRIPTION

[0108] It should be understood that the specific embodiments described herein are only used to explain the present invention, and are not used to limit the present invention.

[0109] like Figure 1 As shown, the present application provides a laser rapid marking positioning method, comprising:

[0110] S1, obtaining image scale feature information of the target image;

[0111] S2, obtaining multiple sets of valid edge point coordinates according to image scale feature information;

[0112] S3, acquiring first contour information of the target image according to multiple groups of valid edge point coordinates;

[0113] S4, obtaining a distortion value of the target image according to the first contour information;

[0114] S5. Obtaining a rotation angle value and a translation distance value of the target image according to the distortion value;

[0115] S6, correcting the first contour information according to the rotation angle value and the translation distance value, and obtaining the corrected second contour information of the target image;

[0116] S7, obtaining the coordinates of the contour edge points according to the second contour information, and obtaining the simulation mapping trajectory according to the coordinates of the contour edge points;

[0117] S8, performing edge point positioning and matching on the target image based on the simulated mapping trajectory;

[0118] If they match, the target image is positioned by laser marking;

[0119] If there is no match, the second contour information is returned as the first contour information to the step of obtaining the distortion value of the target image according to the first contour information.

[0120] As described in the above steps S1-S8, existing laser rapid marking positioning methods, such as steps based on image scale feature information acquisition, determination of multiple sets of effective edge point coordinates, extraction and correction of contour information, have improved the positioning accuracy and efficiency of laser marking to a certain extent. However, these methods still have some defects and limitations in practical applications. First, although the image recognition technology based on machine vision can obtain the surface information and edge detection range of the target image, the reflection of the laser on the surface of the object and the energy loss often lead to inaccurate marking. In addition, image distortion and distortion will also affect the accuracy of edge detection, and then affect the positioning accuracy of marking. Secondly, when dealing with workpieces with complex shapes and textures, the existing laser rapid marking positioning methods often find it difficult to obtain accurate edge point coordinates and contour information, making edge detection and contour extraction difficult. This is because complex shapes and textures can cause the edge features of the image to become blurred and difficult to identify, thus affecting the positioning accuracy;

[0121] The present invention obtains the image scale feature information of the target image, including the basic size of the target image and the edge point feature information of the target image, and then analyzes the size and position relationship of different parts in the image through the image scale feature information, providing basic data for subsequent positioning operations, and then, according to the image scale feature information, multiple groups of valid edge point coordinates can be extracted. These edge point coordinates are key points of the boundary or contour in the image, and their positions and quantities directly affect the accuracy and completeness of the subsequent contour information. After obtaining multiple groups of valid edge point coordinates, the first contour information of the target image is constructed according to these coordinate information. The first contour information is a preliminary description of the image boundary or contour, which includes basic information such as the shape and size of the contour. However, since the image may be affected by various factors during the acquisition and transmission process, such as camera lens distortion, image noise, etc., when the laser marking equipment (such as the scanning galvanometer) obtains the target image information, the lens used by the scanning galvanometer may have certain distortions, such as radial distortion (the edge of the image bends or expands toward the center) and tangential distortion (the edge of the image is distorted). These distortions will cause the image shape to be distorted. At the same time, if the optical axis of the scanning galvanometer is not accurately aligned or offset during use, the image will also be deformed during the scanning process, often resulting in different degrees of distortion. These distortions will directly affect the accuracy of laser marking, and then affect the quality of the final product, resulting in certain errors in the first contour information. In order to eliminate these errors, the distortion value of the target image is calculated based on the first contour information. The distortion value reflects the degree of difference between the image and the actual object. The first contour information can be corrected by calculating the distortion value. After obtaining the distortion value, the rotation angle value and translation distance value of the target image can be calculated based on the distortion value. Finally, according to the corrected second contour information, the coordinates of the contour edge points can be obtained, and a simulated mapping trajectory can be constructed based on these coordinate information. This simulated mapping trajectory is the path that the laser marking device needs to follow in actual operation. If the simulated mapping trajectory matches the actual laser marking path, it means that the positioning is successful; otherwise, the second contour information needs to be used as the first contour information to re-perform distortion correction and positioning operations until a matching simulated mapping trajectory is found.

[0122] In one embodiment, the step of acquiring multiple sets of valid edge point coordinates according to the image scale feature information includes:

[0123] S201, acquiring real-time image width and real-time image height according to image scale feature information;

[0124] S202, obtaining an aspect ratio according to the real-time image width and the real-time image height;

[0125] S203, acquiring edge point feature information of the target image based on an optical flow method, wherein the edge point feature information includes edge point coordinate information and edge point direction information;

[0126] S204, obtaining the angle value between the edge point and the preset horizontal coordinate axis according to the edge point coordinate information and the edge point direction information;

[0127] S205, dividing the target image according to the angle value, the real-time image width, the real-time image height and the aspect ratio to obtain a plurality of image division areas;

[0128] S206, obtaining the brightness value of the edge points in each image division area;

[0129] S207, determining whether the brightness value of the edge point is less than a preset value;

[0130] If it is less than, the corresponding edge point will be removed;

[0131] If it is greater than, the corresponding edge point is determined to be a valid edge point;

[0132] S208: Obtain the valid edge point coordinates corresponding to the valid edge points in all image division areas.

[0133] As described in the above steps S201-S208, the present invention obtains the size information of the image in real time through image acquisition, which can ensure that subsequent processing is based on the accurate image size. Then, the aspect ratio is obtained according to the real-time image width and the real-time image height, which avoids inaccurate positioning caused by changes in the image shape. The image of the object to be marked can be captured in real time or on demand. Then, the edge point feature information of the target image is obtained based on the optical flow method, and the key features in the image (such as edges, corner points, etc.) are extracted. The angle value between the edge point and the preset horizontal coordinate axis is obtained according to the edge point coordinate information and the edge point direction information. First, the edge points of the image to be processed are obtained by image processing technology (such as edge detection algorithm). These edge points usually contain position information (i.e., edge point coordinate information) and edge point direction information. The edge point direction information can be obtained by the gradient direction, which indicates the trend of image brightness change at the edge point. For example: a pair of adjacent edge points A(x A ,y A ) and B(x B ,y B ), calculate the vector between them, the vector calculation formula is: v = (x2-x1, y2-y1), the vector (v) of edge point A is calculated by the above formula A ) and the vector of edge point B (v B ), then according to The calculated θ is the angle value between adjacent edge points. The angle value of the edge point reflects the local direction and trend of the edge in the image. Then, according to the real-time image width and real-time image height, the actual size of the image is obtained. The direction information of the edge point is used as a guide to divide the area along the main edge direction. The angle value is used to determine whether the edge points are in the same range, and the same range is divided into the same area. Ensure that the divided area is consistent with the main feature direction of the image, which can more accurately describe the spatial distribution and shape characteristics of the edge points. Then, the brightness values ​​of all edge points in each divided area are obtained, and all edge points therein are obtained. The brightness values ​​in the image are assumed to be 100. For each edge point, if its brightness value is less than 100, it is considered that this edge point may be caused by noise or shadow and needs to be removed.

[0134] In one embodiment, the step of acquiring first contour information of the target image according to multiple sets of valid edge point coordinates includes:

[0135] S301, obtaining a plurality of horizontal coordinates and a plurality of vertical coordinates according to each group of edge point coordinates;

[0136] S302, obtaining the direction angle of the edge point according to the horizontal coordinate and the vertical coordinate;

[0137] S303: Tracing the contour of each edge point coordinate according to the edge point direction angle to obtain first contour information.

[0138] As described in the above steps S301-S303, the present invention obtains multiple horizontal coordinates and multiple vertical coordinates according to each group of edge point coordinates, locates the edge points in the image through edge detection algorithms (such as Canny, Sobel, etc.), these edge points have specific horizontal coordinates (x) and vertical coordinates (y), and then regards two adjacent edge points as the starting point and end point of the vector, and the vector can be calculated through the coordinates of these two points. For example, if the coordinates of the first edge point are (x1, y1) and the coordinates of the second edge point are (x2, y2), then the vector between these two points can be expressed as (x2-x1, y2-y1). By calculating the angle between two adjacent vectors (the angle between adjacent vectors can be calculated using the vector angle calculation formula (such as the dot product formula, cosine theorem, etc.), the change in the direction of the edge point can be determined. This angle can reflect the degree of curvature or direction change of the edge line. By directly obtaining the horizontal and vertical coordinates through the edge point coordinates, the position of the edge point in the two-dimensional space can be clearly indicated. According to the calculated edge point direction angle, each edge point is tracked to construct the image contour. By calculating the direction angle, the relative direction between the edge points can be understood and tracked. The process usually starts from a selected starting edge point, and then moves to the next edge point along the direction of the edge line (i.e., the indicated direction of the edge point direction angle). When moving to the next edge point, the coordinates and direction angle information of the current edge point, as well as the expected position of the next edge point (obtained by prediction or search) are used to determine the tracking path. The above process is repeated until all edge points are tracked, or the tracking path meets certain termination conditions (such as returning to the starting point, reaching the maximum tracking length, etc.), so as to understand the trend of the edge. The change in the direction angle of adjacent edge points can reflect the continuity and smoothness of the edge. By tracking the edge point coordinates, the contour information of the image can be fully obtained. Tracking based on the direction angle can more accurately depict the shape of the contour.

[0139] In one embodiment, the step of acquiring the distortion value of the target image according to the first contour information includes:

[0140] S401, acquiring a maximum contour width value and a maximum contour height value according to first contour information;

[0141] S402, obtaining a preset characteristic coefficient;

[0142] S403, obtaining a preset outline width and a preset outline height;

[0143] S404, calculating the contour edge variation coefficient according to the contour width, contour height and preset characteristic coefficient, the calculation formula is:

[0144]

[0145] Among them, Q is the contour edge variation coefficient, ρ is the preset characteristic coefficient, k x is the contour width, k y is the profile height, i is the preset profile width, and j is the preset profile height;

[0146] S405, obtaining a scale value of the first contour information according to the maximum contour width value and the maximum contour height value;

[0147] S406, calculating the distortion value according to the contour edge variation coefficient and the scale value, the calculation formula is:

[0148] f (x,y) =Q*L(x,y);

[0149] Among them, f (x,y) is the distortion value, Q is the contour edge variation coefficient, and L(x, y) is the scale value.

[0150] As described in the above steps S401-S406, the present invention can accurately obtain the maximum width value of the contour (the maximum width value of the contour refers to the distance between the two farthest points in the horizontal direction on the projection (or simplified representation) of the contour, and each point of the contour is projected onto the horizontal axis (x-axis) to obtain a series of horizontal coordinate values, and the minimum value and the maximum value are found in these horizontal coordinate values, which correspond to the leftmost and rightmost points of the contour in the horizontal direction, respectively, and the difference between the maximum value and the minimum value is the maximum width value of the contour) and the maximum height value (the maximum height value of the contour refers to the distance between the two farthest points in the vertical direction on the projection (or simplified representation) of the contour, and each point of the contour is projected onto the vertical axis (y-axis) to obtain a series of vertical coordinate values, and the minimum value and the maximum value are found in these vertical coordinate values, which correspond to the topmost and bottommost points of the contour in the vertical direction, respectively, and the difference between the maximum value and the minimum value is the maximum height value of the contour) by directly analyzing the boundary of the contour, and then obtain the preset feature coefficient, which can be adjusted according to different application scenarios. The preset feature coefficient can be adjusted according to the design specification and the allowable error range of the product. The contour points are projected onto the horizontal axis (x-axis) and the vertical axis (y-axis). The minimum and maximum values ​​of the horizontal and vertical coordinates are found respectively. The difference between the maximum and minimum values ​​is the maximum width or maximum height of the contour in that direction. Then the minimum rectangle (bounding box) containing the contour is calculated. Its width and height are the maximum width and maximum height of the contour. Then the scale value is calculated by combining the area, perimeter, and the ratio of the maximum width to the maximum height of the contour. If a small change in the contour of the product has little effect on the performance, the feature coefficient can be set to a lower value to reduce the sensitivity to the contour distortion. On the contrary, if the accuracy of the product contour is critical to the performance (such as precision instruments or medical devices), the feature coefficient needs to be set to a higher value to more accurately detect any possible distortion. In shape recognition applications, the preset feature coefficient can be used to adjust the algorithm's emphasis on different shape features. For example, when recognizing handwritten digits, some stroke features (such as curvature, length, etc.) may be more important than other features. By adjusting the feature coefficients, the algorithm can be ensured to pay more attention to these key features, thereby improving the accuracy of recognition. Assuming that the contour width k obtained from the first contour information is x is 100 units, the contour height k y is 50 units, ρ is 0.01, i is 150 units, j is 75 units, L(x, y) is 75 (preset constant), according to The calculated Q is 0.05, according to Q*L (x,y) Calculate f (x,y) is 3.75.

[0151] In one embodiment, the step of obtaining a rotation angle value and a translation distance value of a target image according to the distortion value comprises:

[0152] S501, obtaining a contour horizontal coordinate according to first contour information;

[0153] S502, obtaining a first distortion coefficient of the contour horizontal coordinate according to the distortion coefficient;

[0154] S503, obtaining a contour ordinate according to the first contour information;

[0155] S504, obtaining a second distortion coefficient of the contour ordinate according to the distortion coefficient;

[0156] S505, calculating the corrected abscissa according to the contour abscissa, the first distortion coefficient, the contour ordinate and the second distortion coefficient, the calculation formula is:

[0157] x (u) =X+(2p1Y+p2(r 2 +2X 2 ));

[0158] Among them, x (u) is the correction horizontal coordinate, X is the profile horizontal coordinate, Y is the profile vertical coordinate, p1 is the first distortion coefficient, and p2 is the second distortion coefficient;

[0159] S506, calculating the corrected ordinate according to the contour abscissa, the first distortion coefficient, the contour ordinate and the second distortion coefficient, the calculation formula is:

[0160] y (u) =Y+(p1(r 2 +2Y 2 )+2p2X);

[0161] Among them, y (u) is the correction ordinate, X is the profile abscissa, Y is the profile ordinate, p1 is the first distortion coefficient, and p2 is the second distortion coefficient;

[0162] S507, obtaining a rotation angle value according to the corrected horizontal coordinate, the corrected vertical coordinate, the contour horizontal coordinate, and the contour vertical coordinate;

[0163] S508 , obtaining a translation distance value according to the corrected horizontal coordinate and the corrected vertical coordinate and the contour horizontal coordinate and the contour vertical coordinate based on the Euclidean distance calculation method.

[0164] As described in the above steps S501-S508, the present invention obtains the contour horizontal coordinate according to the first contour information. In image processing, the image is firstly subjected to edge detection or contour extraction to obtain the contour information of the target object. Then, we can traverse these contour points to obtain the horizontal coordinate (X) and vertical coordinate (Y) of each point, and then obtain the first distortion coefficient of the contour horizontal coordinate according to the distortion coefficient. The distortion coefficient is usually obtained by camera calibration. For radial distortion, we usually have two coefficients: k1 (the first radial distortion coefficient, the corresponding first distortion coefficient is found by a table lookup method according to the contour horizontal coordinate (i.e., the X coordinate of the point)) and k2 (the second radial distortion coefficient, the corresponding second distortion coefficient is found by a table lookup method according to the contour horizontal coordinate (i.e., the Y coordinate of the point), through X+(2p1Y+p2(r 2 +2X 2 )) and Y+(p1(r 2 +2Y 2 )+2p2X) to calculate the corrected coordinates, and then for each contour point, calculate the offset between its corrected coordinates and the original coordinates, which includes the offset of the horizontal coordinate (corrected horizontal coordinate-contour horizontal coordinate) and the offset of the vertical coordinate (corrected vertical coordinate-contour vertical coordinate), and get the translation distance. If the offset of the entire contour has a consistent tendency in the horizontal coordinate direction (for example, all offset to the right), it may mean that the image needs to be rotated to the left by a certain angle for correction, and vice versa. Then, through the least squares method, principal component analysis (PCA) or other optimization algorithms, the coordinate changes of all points on the contour can be considered, and the best fitting rotation angle can be calculated. After the rotation angle is calculated, it can be applied to the transformation of the contour coordinates to eliminate the positioning error caused by image rotation distortion, and the rotation angle and translation distance can be obtained. For example, we have the values ​​of p1 and p2, and a point (X1, Y1) on the contour. We use the correction formula y(u)=Y1+(p1*(r2+2Y1^2)+2p2*X1) to calculate the corrected ordinate y(u), where r is the distance from the point to the center of the image. Comparing the contours before and after correction, we find that the contour has a small rotation on the image plane. By calculating the change in the direction of the principal axis, we get the rotation angle θ. The coordinates of all points in the horizontal and vertical coordinates of the original contour are (X1,Y1), (X2,Y2),...,(Xn,Yn). For each point (Xi,Yi), apply the transformation of rotation θ and translation d to obtain the new coordinates (Xi',Yi'). Connect (X1',Y1'),(X2',Y2'),...,(Xn',Yn') to form the corrected contour.

[0165] In one embodiment, the step of correcting the first contour information according to the rotation angle value and the translation distance value and acquiring the corrected second contour information of the target image includes:

[0166] S601, acquiring contour abscissas and contour ordinates of a plurality of contour points according to first contour information;

[0167] S602, transforming the contour abscissa and contour ordinate of each contour point based on the rotation angle value and the translation distance value to obtain a corresponding contour correction point;

[0168] S603: Connect all contour correction points to obtain second contour information.

[0169] As described in the above steps S601-S603, the present invention obtains the scale feature information of the image, so that the system can more accurately identify the key elements in the image, and then obtains multiple groups of valid edge point coordinates according to the image scale feature information. By extracting these coordinates, the contour of the target image can be constructed for subsequent distortion correction and positioning, and then the first contour information of the target image is obtained according to the multiple groups of valid edge point coordinates. By obtaining the first contour information, the basic shape and position of the target image can be understood, and then the distortion value of the target image is obtained according to the first contour information. By obtaining the distortion value, the distortion of the image can be understood for subsequent distortion correction, and the corrected image position can be calculated by obtaining the rotation angle value and the translation distance value. The corrected contour information is more accurate and can better reflect the actual position of the target image.

[0170] In one embodiment, the step of obtaining the coordinates of the contour edge points according to the second contour information, and obtaining the simulated mapping trajectory according to the coordinates of the contour edge points includes:

[0171] S701, acquiring a plurality of contour correction point information according to the second contour information, wherein the contour correction point information includes a contour correction horizontal coordinate and a contour correction vertical coordinate;

[0172] S702, obtaining the distance value from the scanning galvanometer to the target image;

[0173] S703, mapping all the contour edge point coordinates to a three-dimensional space based on the distance value to obtain a plurality of three-dimensional coordinates;

[0174] S704, establishing a contour simulation image according to a plurality of three-dimensional coordinates;

[0175] S705, obtaining coordinates of a plurality of three-dimensional contour edge points according to the contour simulation image;

[0176] S706, acquiring a connection sequence of tracking edge points based on the coordinates of multiple 3D contour edge points;

[0177] S707, marking the coordinates of all contour edge points based on the connection sequence of the tracked edge points;

[0178] S708 , obtaining a simulated mapping trajectory based on the marking process.

[0179] As described in the above steps S701-S708, the present invention obtains the coordinates of the contour edge points according to the second contour information, and obtains the simulated mapping trajectory according to the coordinates of the contour edge points. The simulated mapping trajectory is the actual path of laser marking. By obtaining this trajectory, it can be ensured that the laser is marked along the correct path, and the accuracy and efficiency of marking are improved. According to the second contour information, multiple contour edge point coordinates are obtained, and the edge point coordinates are extracted from the corrected second contour information. These coordinates represent the precise boundary of the marking area, avoiding the direct use of the original contour information, which may cause inaccurate positioning, because the original information may contain distortion, and then obtain the distance value from the scanning galvanometer to the target image. The distance value is a key parameter in the laser marking system, which determines the position where the laser beam is focused on the object. Obtaining this value can ensure that the laser beam is correctly focused on the target area, map it to three-dimensional space, and establish a three-dimensional coordinate system. The origin of this three-dimensional coordinate system can be set at the position of the scanning galvanometer, and the z axis is perpendicular to the image plane and points to the object to be marked. For each contour edge point (x, y) on the two-dimensional image plane, the x and y coordinates in its three-dimensional coordinates remain unchanged, and the z coordinate is set to the distance value from the galvanometer to the target image. Therefore, each two-dimensional coordinate (x, y) is mapped to a three-dimensional coordinate (x, y, z), where z is a fixed distance value. Then, inputting the two-dimensional coordinate into the three-dimensional space can provide more complete spatial information, which helps to control the motion path of the laser beam more accurately. The two-dimensional coordinate only provides plane information and cannot reflect the actual position of the object in the three-dimensional space, while the three-dimensional coordinate can more accurately reflect the actual situation. The simulated image can help the operator to more intuitively understand the shape and position of the marking area in the three-dimensional space, which helps to perform more accurate marking operations. Extracting the contour edge point coordinates from the simulated image again can ensure that these coordinates are based on the latest and corrected simulated image. Tracking the time series of edge points can help the system understand the movement of edge points in the marking process in real time, thereby ensuring that the laser beam always moves with the target edge. The marking process can help the system distinguish the edge point coordinates at different time points, thereby more accurately controlling the motion path of the laser beam. The simulated mapping trajectory is the final path of laser marking. It is based on the data and calculations of all the previous steps and has a high degree of accuracy and reliability. Assume that after distortion correction, we get the second contour information, which describes the shape of the metal part. From this contour information, multiple contour edge point coordinates are extracted, such as (x1, y1), (x2, y2), ..., (xn, yn). In the laser marking equipment, the scanning galvanometer is responsible for controlling the direction of the laser beam. A sensor or measuring tool is used to obtain the distance value from the scanning galvanometer to the surface of the metal part, such as 50 mm, and then the two-dimensional contour edge point coordinates are mapped into three-dimensional space.Assuming that our marking system is a simple vertical marking system, the three-dimensional coordinates will simply add the value of the z-axis, such as (x1, y1, 50), (x2, y2, 50), ..., (xn, yn, 50). Through these three-dimensional coordinates, a three-dimensional contour simulation image can be constructed on the computer. This image will show the shape and position of the metal part in three-dimensional space. Then, during the marking process, it may be necessary to track the position changes of the edge points to ensure that the laser beam always moves along the edge of the part. Assuming that our marking process is a continuous process, we can record the edge point coordinates at each time point to form a time series, such as t1: (x1_t1, y1_t1, 50), t2: (x2_t2, y2_t2, 50), ..., and finally simulate the motion trajectory of the laser beam on the computer based on these marked coordinate points. This simulated mapping trajectory will serve as a reference path for actual marking to ensure that the laser beam can mark according to the predetermined path.

[0180] like Figure 2 As shown, the present invention also discloses a laser rapid marking positioning system, which is characterized by comprising:

[0181] The first acquisition module 1 is used to acquire image scale feature information of the target image;

[0182] The second acquisition module 2 is used to acquire multiple groups of valid edge point coordinates according to the image scale feature information;

[0183] A third acquisition module 3, used to acquire first contour information of the target image according to multiple groups of valid edge point coordinates;

[0184] A fourth acquisition module 4, used to acquire a distortion value of the target image according to the first contour information;

[0185] A fifth acquisition module 5, used to calculate a rotation angle value and a translation distance value of a target image according to the distortion value;

[0186] A sixth acquisition module 6, used to correct the first contour information according to the rotation angle value and the translation distance value, and obtain the corrected second contour information of the target image;

[0187] A seventh acquisition module 7, used to acquire the coordinates of the contour edge points according to the second contour information, and to acquire the simulation mapping trajectory according to the coordinates of the contour edge points;

[0188] A judgment module 8 is used to locate and match edge points of the target image based on the simulated mapping trajectory;

[0189] If they match, the target image is positioned by laser marking;

[0190] If there is no match, the second contour information is returned as the first contour information to the step of obtaining the distortion value of the target image according to the first contour information.

[0191] In one embodiment, the fourth acquisition module 4 includes:

[0192] A first acquisition unit, used for acquiring a maximum contour width value and a maximum contour height value according to the first contour information;

[0193] A second acquisition unit, used to acquire a preset characteristic coefficient;

[0194] A third acquisition unit, used to acquire a preset contour width and a preset contour height;

[0195] The first calculation unit is used to calculate the contour edge variation coefficient according to the contour width, the contour height and the preset characteristic coefficient, and the calculation formula is:

[0196]

[0197] Among them, Q is the contour edge variation coefficient, ρ is the preset characteristic coefficient, k x is the contour width, k y is the profile height, i is the preset profile width, and j is the preset profile height;

[0198] A fourth acquisition unit, configured to acquire a scale value of the first contour information according to a maximum contour width value and a maximum contour height value;

[0199] The second calculation unit is used to calculate the distortion value according to the contour edge variation coefficient and the scale value. The calculation formula is:

[0200] f (x,y) =Q*L (x,y) ;

[0201] Among them, f (x,y) is the distortion value, Q is the contour edge variation coefficient, L (x,y) is the scale value.

[0202] In one embodiment, the fifth acquisition module 5 includes:

[0203] A fifth acquisition unit, configured to acquire a contour horizontal coordinate according to the first contour information;

[0204] A sixth acquisition unit, used for acquiring a first distortion coefficient of a horizontal coordinate of a contour according to the distortion coefficient;

[0205] A seventh acquisition unit, configured to acquire a contour ordinate according to the first contour information;

[0206] An eighth acquisition unit, configured to acquire a second distortion coefficient of the contour ordinate according to the distortion coefficient;

[0207] The third calculation unit is used to calculate the corrected horizontal coordinate according to the contour horizontal coordinate, the first distortion coefficient, the contour vertical coordinate and the second distortion coefficient, and the calculation formula is:

[0208] x (u) =X+(2p1Y+p2(r 2 +2X 2 ));

[0209] Among them, x (u) is the correction horizontal coordinate, X is the profile horizontal coordinate, Y is the profile vertical coordinate, p1 is the first distortion coefficient, and p2 is the second distortion coefficient;

[0210] The fourth calculation unit is used to calculate the corrected ordinate according to the profile abscissa, the first distortion coefficient, the profile ordinate and the second distortion coefficient, and the calculation formula is:

[0211] y (u) =Y+(p1(r 2 +2Y 2 )+2p2X);

[0212] Among them, y (u) is the correction ordinate, X is the profile abscissa, Y is the profile ordinate, p1 is the first distortion coefficient, and p2 is the second distortion coefficient;

[0213] A ninth acquisition unit, configured to acquire a rotation angle value according to the corrected horizontal coordinate and the corrected vertical coordinate and the contour horizontal coordinate and the contour vertical coordinate;

[0214] The tenth acquisition unit is used to acquire the translation distance value according to the corrected horizontal coordinate and the corrected vertical coordinate and the contour horizontal coordinate and the contour vertical coordinate based on the Euclidean distance calculation method.

[0215] Those of ordinary skill in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media provided in this application and used in the embodiments may include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory may include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in a variety of forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (SSRSDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM), etc.

[0216] It should be noted that, in this article, the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, device, article or method including a series of elements includes not only those elements, but also includes other elements not explicitly listed, or also includes elements inherent to such process, device, article or method. In the absence of further restrictions, an element defined by the sentence "includes a ..." does not exclude the presence of other identical elements in the process, device, article or method including the element.

[0217] The above description is only a preferred embodiment of the present invention, and does not limit the patent scope of the present invention. Any equivalent structure or equivalent process transformation made by using the contents of the present invention specification and drawings, or directly or indirectly applied in other related technical fields, are also included in the patent protection scope of the present invention.

Claims

1. A laser rapid marking positioning method, characterized in that: include: Obtaining image scale feature information of the target image; Acquire multiple groups of valid edge point coordinates according to image scale feature information; Acquire first contour information of the target image according to multiple groups of valid edge point coordinates; Acquire a distortion value of the target image according to the first contour information; Calculate the rotation angle value and translation distance value of the target image according to the distortion value; Correcting the first contour information according to the rotation angle value and the translation distance value, and obtaining the corrected second contour information of the target image; Acquire the coordinates of the contour edge points according to the second contour information, and acquire the simulation mapping trajectory according to the coordinates of the contour edge points; Perform edge point positioning and matching on the target image based on the simulated mapping trajectory; If they match, the target image is laser marked and positioned; If there is no match, the second contour information is returned as the first contour information to the step of obtaining the distortion value of the target image according to the first contour information.

2. The laser rapid marking positioning method according to claim 1, characterized in that: The step of obtaining multiple groups of valid edge point coordinates according to the image scale feature information includes: Acquire the real-time image width and real-time image height according to the image scale feature information; Obtain aspect ratio value according to real-time image width and real-time image height; Acquire edge point feature information of the target image based on the optical flow method, wherein the edge point feature information includes edge point coordinate information and edge point direction information; Obtaining the angle value between the edge point and the preset horizontal axis according to the edge point coordinate information and the edge point direction information; Divide the target image according to the angle value, the real-time image width, the real-time image height and the aspect ratio value to obtain a plurality of image division areas; Get the brightness value of the edge points in each image segmentation area; Determine whether the brightness value of the edge point is less than the preset value; If it is less than, the corresponding edge point will be removed; If it is greater than, the corresponding edge point is determined to be a valid edge point; Get the valid edge point coordinates corresponding to the valid edge points in all image partition areas.

3. The laser rapid marking positioning method according to claim 1, characterized in that: The step of acquiring first contour information of the target image according to multiple groups of valid edge point coordinates comprises: Obtain multiple horizontal coordinates and multiple vertical coordinates according to each group of edge point coordinates; Obtain the direction angle of the edge point according to the horizontal coordinate and the vertical coordinate; The contour of each edge point coordinate is traced according to the edge point direction angle to obtain the first contour information.

4. The laser rapid marking positioning method according to claim 1, characterized in that: The step of acquiring the distortion value of the target image according to the first contour information comprises: Acquire a maximum contour width value and a maximum contour height value according to the first contour information; Obtaining preset characteristic coefficients; Get the preset outline width and preset outline height; The contour edge variation coefficient is calculated based on the contour width, contour height and preset characteristic coefficient. The calculation formula is: Among them, Q is the contour edge variation coefficient, ρ is the preset characteristic coefficient, k x is the contour width, k y is the profile height, i is the preset profile width, and j is the preset profile height; Acquire a scale value of the first contour information according to a maximum contour width value and a maximum contour height value; The distortion value is calculated according to the contour edge variation coefficient and scale value. The calculation formula is: f (x,y) =Q*L (x,y) ; Among them, f (x,y) is the distortion value, Q is the contour edge variation coefficient, L (x,y) is the scale value.

5. The laser rapid marking positioning method according to claim 3, characterized in that: The step of obtaining the rotation angle value and the translation distance value of the target image according to the distortion value comprises: Acquire a contour horizontal coordinate according to the first contour information; Obtaining a first distortion coefficient of the contour horizontal coordinate according to the distortion coefficient; Acquire the contour ordinate according to the first contour information; Obtaining a second distortion coefficient of the contour ordinate according to the distortion coefficient; The corrected abscissa is calculated according to the profile abscissa, the first distortion coefficient, the profile ordinate and the second distortion coefficient. The calculation formula is: x (u) =X+(2p1Y+p2(r 2 +2X 2 )); Among them, x (u) is the correction horizontal coordinate, X is the profile horizontal coordinate, Y is the profile vertical coordinate, p1 is the first distortion coefficient, and p2 is the second distortion coefficient; The corrected ordinate is calculated according to the profile abscissa, the first distortion coefficient, the profile ordinate and the second distortion coefficient. The calculation formula is: <h2 style=";text-align:left;direction:ltr">y<h2 style=";text-align:left;direction:ltr"> (u) <h2 style=";text-align:left;direction:ltr"> =Y+(p1(r<h2 style=";text-align:left;direction:ltr"> 2 <h2 style=";text-align:left;direction:ltr"> +2Y<h2 style=";text-align:left;direction:ltr"> 2 <h2 style=";text-align:left;direction:ltr"> )+2p2X); Among them, y (u) is the correction ordinate, X is the profile abscissa, Y is the profile ordinate, p1 is the first distortion coefficient, and p2 is the second distortion coefficient; Obtain the rotation angle value according to the correction horizontal coordinate, the correction vertical coordinate, the contour horizontal coordinate, and the contour vertical coordinate; The translation distance value is obtained according to the corrected horizontal coordinate and the corrected vertical coordinate and the contour horizontal coordinate and the contour vertical coordinate based on the Euclidean distance calculation method.

6. The laser rapid marking positioning method according to claim 1, characterized in that: The step of correcting the first contour information according to the rotation angle value and the translation distance value, and obtaining the corrected second contour information of the target image comprises: Acquire contour abscissas and contour ordinates of a plurality of contour points according to the first contour information; Based on the rotation angle value and the translation distance value, the contour abscissa and the contour ordinate of each contour point are transformed to obtain the corresponding contour correction point; All contour correction points are connected to obtain second contour information.

7. The laser rapid marking positioning method according to claim 1, characterized in that: The step of obtaining the coordinates of the contour edge points according to the second contour information, and obtaining the simulated mapping trajectory according to the coordinates of the contour edge points includes: Acquire a plurality of contour correction point information according to the second contour information, wherein the contour correction point information includes a contour correction horizontal coordinate and a contour correction vertical coordinate; Get the distance value from the scanning galvanometer to the target image; Based on the distance value, all the contour edge point coordinates are mapped into the three-dimensional space to obtain multiple three-dimensional coordinates; Establishing a contour simulation image according to a plurality of three-dimensional coordinates; Acquire multiple three-dimensional contour edge point coordinates according to the contour simulation image; Acquire a connection sequence of tracking edge points based on multiple three-dimensional contour edge point coordinates; Marking the coordinates of all contour edge points based on the connection sequence of the tracked edge points; The simulated mapping trajectory is obtained based on the labeling process.

8. A laser rapid marking positioning system, characterized in that: include: A first acquisition module is used to acquire image scale feature information of a target image; A second acquisition module is used to acquire multiple groups of valid edge point coordinates according to image scale feature information; A third acquisition module, used for acquiring first contour information of the target image according to multiple groups of valid edge point coordinates; A fourth acquisition module, used for acquiring a distortion value of a target image according to the first contour information; A fifth acquisition module, used for calculating a rotation angle value and a translation distance value of a target image according to the distortion value; A sixth acquisition module, used to correct the first contour information according to the rotation angle value and the translation distance value, and obtain the corrected second contour information of the target image; A seventh acquisition module, used to acquire the coordinates of the contour edge points according to the second contour information, and to acquire the simulation mapping trajectory according to the coordinates of the contour edge points; A judgment module, used for locating and matching edge points of a target image based on a simulated mapping trajectory; If they match, the target image is laser marked and positioned; If there is no match, the second contour information is returned as the first contour information to the step of obtaining the distortion value of the target image according to the first contour information.

9. A laser rapid marking positioning system according to claim 8, characterized in that: The fourth acquisition module includes: A first acquisition unit, used for acquiring a maximum contour width value and a maximum contour height value according to the first contour information; A second acquisition unit, used to acquire a preset characteristic coefficient; A third acquisition unit, used to acquire a preset contour width and a preset contour height; The first calculation unit is used to calculate the contour edge variation coefficient according to the contour width, the contour height and the preset characteristic coefficient, and the calculation formula is: Among them, Q is the contour edge variation coefficient, ρ is the preset characteristic coefficient, k x is the contour width, k y is the profile height, i is the preset profile width, and j is the preset profile height; A fourth acquisition unit, configured to acquire a scale value of the first contour information according to a maximum contour width value and a maximum contour height value; The second calculation unit is used to calculate the distortion value according to the contour edge variation coefficient and the scale value. The calculation formula is: f (x,y) =Q*L (x,y) ; Among them, f (x , y) is the distortion value, Q is the contour edge variation coefficient, L (x , y) is the scale value.

10. The laser rapid marking positioning system according to claim 8, characterized in that: The fifth acquisition module comprises: A fifth acquisition unit, configured to acquire a contour horizontal coordinate according to the first contour information; A sixth acquisition unit, used for acquiring a first distortion coefficient of a horizontal coordinate of a contour according to the distortion coefficient; A seventh acquisition unit, configured to acquire a contour ordinate according to the first contour information; An eighth acquisition unit, configured to acquire a second distortion coefficient of the contour ordinate according to the distortion coefficient; The third calculation unit is used to calculate the corrected horizontal coordinate according to the contour horizontal coordinate, the first distortion coefficient, the contour vertical coordinate and the second distortion coefficient, and the calculation formula is: x (u) =X+(2p1Y+p2(r 2 +2X 2 )); Among them, x (u) is the correction abscissa, X is the profile abscissa, Y is the profile ordinate, b1 is the first distortion coefficient, and p2 is the second distortion coefficient; The fourth calculation unit is used to calculate the corrected ordinate according to the profile abscissa, the first distortion coefficient, the profile ordinate and the second distortion coefficient, and the calculation formula is: <h2 style=";text-align:left;direction:ltr">y<h2 style=";text-align:left;direction:ltr"> (u) <h2 style=";text-align:left;direction:ltr"> =Y+(p1(r<h2 style=";text-align:left;direction:ltr"> 2 <h2 style=";text-align:left;direction:ltr"> +2Y<h2 style=";text-align:left;direction:ltr"> 2 <h2 style=";text-align:left;direction:ltr"> )+2p2X); Among them, y (u) is the correction ordinate, X is the profile abscissa, Y is the profile ordinate, p1 is the first distortion coefficient, and p2 is the second distortion coefficient; A ninth acquisition unit, configured to acquire a rotation angle value according to the corrected horizontal coordinate and the corrected vertical coordinate and the contour horizontal coordinate and the contour vertical coordinate; The tenth acquisition unit is used to acquire the translation distance value according to the corrected horizontal coordinate and the corrected vertical coordinate and the contour horizontal coordinate and the contour vertical coordinate based on the Euclidean distance calculation method.

Citation Information

Patent Citations

  • Calibration method and device used for laser processing system

    CN104439698A

  • Circular workpiece plane coordinate high-precision positioning method based on machine vision

    CN113592955A

  • High-precision calibration method and device for laser processing system

    CN113989369A

  • Floor calibration method based on distortion image correction and related device

    CN115496814A

  • Image processing method for image distortion automatic correction

    CN1937698A