Weld seam trajectory generation method and device, computer device and storage medium

By performing planar fitting and projection processing on the point cloud of the welded workpiece, a weld seam image is generated, which solves the interference problem in weld seam trajectory planning and achieves high-accuracy generation of weld seam trajectory.

CN122243922APending Publication Date: 2026-06-19SHIBIT (CHANGSHA) ROBOT TECH CO LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
SHIBIT (CHANGSHA) ROBOT TECH CO LTD
Filing Date
2026-03-17
Publication Date
2026-06-19

AI Technical Summary

Technical Problem

In the welding environment, interference factors such as weld spatter, arc craters, and oxide scale on the weld surface affect the accuracy of weld feature extraction, leading to inaccurate weld trajectory planning.

Method used

By acquiring the point cloud of the target workpiece, performing plane fitting, extracting the weld point cloud and projecting it onto the base plane, a weld image is generated. The weld trajectory is then generated by combining geometric features, reducing environmental interference and improving the accuracy of weld point cloud extraction.

Benefits of technology

It improves the accuracy of weld trajectory planning, reduces interference from the inspection environment, and ensures the precision of weld point cloud extraction.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122243922A_ABST
    Figure CN122243922A_ABST
Patent Text Reader

Abstract

This application relates to a method, apparatus, computer device, and storage medium for generating weld seam trajectories. The method includes: acquiring a workpiece point cloud of a target workpiece; performing planar fitting on the workpiece point cloud to obtain a workpiece base plane; extracting a weld seam point cloud from the workpiece point cloud based on its geometric features; projecting the weld seam point cloud onto the workpiece base plane to generate a weld seam image; and generating a weld seam trajectory based on the weld seam image and the workpiece point cloud. This method helps improve the accuracy of weld seam trajectory planning.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of weld seam trajectory recognition technology, and in particular to a weld seam trajectory generation method, apparatus, computer equipment, and storage medium. Background Technology

[0002] In shipbuilding, automotive industry, and large steel structure production, grinding the weld reinforcement (weld marks) after welding is an essential step. With the development of intelligent manufacturing, using industrial robots to replace manual grinding has become a trend. Currently, automated grinding path planning mainly relies on manual teaching programming and traditional machine vision-guided detection of weld features for path planning.

[0003] However, the welding environment contains many interfering factors, such as high-frequency noise interference from spatter, arc craters, and oxide scale on the weld surface. These interfering factors affect the accuracy of feature extraction, and consequently, the accuracy of weld trajectory planning. Summary of the Invention

[0004] Therefore, it is necessary to provide a weld trajectory generation method, apparatus, computer equipment, computer-readable storage medium, and computer program product that can improve the accuracy of weld trajectory planning, in order to address the above-mentioned technical problems.

[0005] In a first aspect, this application provides a method for generating weld seam trajectories, including:

[0006] Obtain the point cloud of the target workpiece;

[0007] Planar fitting is performed on the workpiece point cloud to obtain the workpiece base plane;

[0008] Based on the geometric features of the workpiece point cloud, the weld seam point cloud is extracted from the workpiece point cloud, and the weld seam point cloud is projected onto the workpiece base plane to generate a weld seam image.

[0009] The weld trajectory is generated based on the weld image and the workpiece point cloud.

[0010] Secondly, this application also provides a weld trajectory generation device, comprising:

[0011] The point cloud acquisition module is used to acquire the point cloud of the target workpiece.

[0012] The plane fitting module is used to perform plane fitting on the workpiece point cloud to obtain the workpiece base plane.

[0013] The point cloud projection module is used to extract the weld seam point cloud from the workpiece point cloud based on the geometric features of the workpiece point cloud, and project the weld seam point cloud onto the workpiece base plane to generate a weld seam image.

[0014] The weld trajectory generation module is used to generate weld trajectories based on weld images and workpiece point clouds.

[0015] Thirdly, this application also provides a computer device, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement the steps in any of the above embodiments of the weld trajectory generation method.

[0016] Fourthly, this application also provides a computer-readable storage medium having a computer program stored thereon, wherein the computer program, when executed by a processor, implements the steps in any of the above embodiments of the weld trajectory generation method.

[0017] Fifthly, this application also provides a computer program product, including a computer program that, when executed by a processor, implements the steps in any of the above-described weld trajectory generation method embodiments.

[0018] The aforementioned weld trajectory generation method, apparatus, computer equipment, computer-readable storage medium, and computer program product first acquire the workpiece point cloud of the target workpiece; second, perform planar fitting on the workpiece point cloud to obtain the workpiece base plane; subsequently, based on the geometric features of the workpiece point cloud, extract the weld point cloud from the workpiece point cloud; project the weld point cloud onto the workpiece base plane to generate a weld image; and finally, generate the weld trajectory based on the weld image and the workpiece point cloud. In this way, the workpiece point cloud in three-dimensional space is projected into two-dimensional space, the weld point cloud is filtered based on the geometric features between the workpiece point clouds, and the weld point cloud in two-dimensional space is then projected back into three-dimensional space. This reduces interference from the detection environment, improves the accuracy of weld point cloud extraction, and thus improves the accuracy of weld trajectory planning. Attached Figure Description

[0019] To more clearly illustrate the technical solutions in the embodiments of this application or related technologies, the drawings used in the description of the embodiments of this application or related technologies will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.

[0020] Figure 1 This is a diagram illustrating the application environment of a weld trajectory generation method in one embodiment.

[0021] Figure 2 This is a flowchart illustrating a weld trajectory generation method in one embodiment;

[0022] Figure 3 This is a schematic diagram of a workpiece point cloud stitching image in one embodiment;

[0023] Figure 4 This is a schematic diagram of a weld image in one embodiment;

[0024] Figure 5 This is a flowchart illustrating the weld trajectory generation method in another embodiment;

[0025] Figure 6 This is a schematic diagram of the weld centerline in one embodiment;

[0026] Figure 7 This is a schematic diagram of the weld center point cloud in one embodiment;

[0027] Figure 8 This is a schematic diagram of the weld trajectory in one embodiment;

[0028] Figure 9 This is a flowchart illustrating the weld trajectory generation method in yet another embodiment;

[0029] Figure 10 This is a schematic diagram of the target weld trajectory in one embodiment;

[0030] Figure 11 This is a structural block diagram of a weld trajectory generation device in one embodiment;

[0031] Figure 12 This is an internal structural diagram of a computer device in one embodiment. Detailed Implementation

[0032] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.

[0033] The weld trajectory generation method provided in this application embodiment can be applied to, for example... Figure 1 In the application environment shown, the point cloud acquisition device 102 is communicatively connected to the control terminal 104. Specifically, the point cloud acquisition device 102 uploads the acquired point cloud of the target workpiece to the control terminal 104. The control terminal 104 acquires the point cloud of the target workpiece, performs planar fitting on the point cloud to obtain the workpiece base plane, extracts the weld seam point cloud from the point cloud based on its geometric features, projects the weld seam point cloud onto the workpiece base plane to generate a weld seam image, and finally generates a weld seam trajectory based on the weld seam image and the workpiece point cloud. The point cloud acquisition device 102 can be, but is not limited to, devices such as laser scanners and structured light scanners.

[0034] In one exemplary embodiment, such as Figure 2 As shown, a method for generating weld seam trajectories is provided, which can be applied to... Figure 1Taking control terminal 104 as an example, the explanation includes the following steps (hereinafter referred to as S): S100 to S400. Wherein:

[0035] S100: Obtain the point cloud of the target workpiece.

[0036] Among them, the flange pose information of the robot represents the flange pose of the controller of the welding robot.

[0037] In practice, the point cloud of the target workpiece in the camera coordinate system and the flange pose information of the robot are acquired. Then, based on the flange pose information and preset transformation parameters, the point cloud of the workpiece is transformed into the robot base coordinate system. The flange pose information of the robot represents the flange pose of the welding robot end effector, and the preset transformation parameters represent the transformation parameters of the camera relative to the robot flange.

[0038] Specifically, the preset transformation parameters can be obtained by pre-calculating the transformation parameters of the camera coordinate system relative to the robot flange coordinate system. Specifically, the robot base coordinate system is first constructed. Flange coordinate system of robot end flange (Line scan) camera coordinate system and the coordinate system of the measurement points Subsequently, the homogeneous transformation matrix of the camera relative to the robot flange was solved through hand-eye calibration. The homogeneous transformation matrix is ​​then used as the transformation parameter.

[0039] Based on the flange pose information and preset transformation parameters, the workpiece point cloud is transformed into the robot base coordinate system to obtain the target workpiece point cloud in the robot base coordinate system, including: the workpiece point cloud of the i-th target workpiece acquired by the camera. The coordinates of the point cloud in the robot's base coordinate system can be calculated using the following chain transformation. :

[0040]

[0041] in, and All The homogeneous transformation matrix is ​​of the following form: Thus, by traversing the workpiece point cloud in the camera coordinate system, the workpiece point cloud in the robot base coordinate system is obtained. The workpiece point cloud mosaic image is as follows Figure 3 As shown.

[0042] S200 performs planar fitting on the workpiece point cloud to obtain the workpiece base plane.

[0043] In practical implementation, for workpiece point cloud The base plane of the workpiece point cloud can be fitted using algorithms such as least squares and RANSAC (random sampling consensus).

[0044] Let the equation of the plane be:

[0045]

[0046] By minimizing the objective function, the fitting parameters of the workpiece base plane are solved. :

[0047]

[0048] S300 extracts the weld seam point cloud from the workpiece point cloud based on the geometric features of the workpiece point cloud, projects the weld seam point cloud onto the workpiece base plane, and generates a weld seam image.

[0049] Among them, geometric features include, but are not limited to, the normal vector of the workpiece point cloud and the distance between the workpiece point cloud and the fitted surface.

[0050] In practice, this can be done by determining the normal vector of each workpiece point cloud, and for each workpiece point cloud, determining whether it is a weld point cloud (the curvature of the weld region changes significantly) based on the change between the normal vector of the workpiece point cloud and the normal vector of its neighboring point clouds within the same neighborhood. Based on the determination result, the weld point cloud can be extracted from the workpiece point cloud. It can also perform planar or surface fitting on the workpiece point cloud to determine the distance from the workpiece point cloud to the fitting surface, and extract the weld point cloud from the workpiece point cloud based on the distance. .

[0051] Subsequently, the workpiece base plane is generated. Local two-dimensional coordinate system The weld seam is dotted with cloud-like patterns. Projected onto the base plane of the workpiece Generate projection matrix The projection matrix contains the weld point cloud on the workpiece base plane. The coordinates of the projection points are determined. The workpiece base plane is rasterized, and a high-resolution binarized image is generated based on the projection matrix. That is, weld images, such as Figure 4 As shown. In this way, the three-dimensional geometric processing is transformed into two-dimensional image processing, which greatly reduces the computational dimensionality.

[0052] S400 generates weld trajectories based on weld images and workpiece point clouds.

[0053] In practice, the planar curve can be fitted to the pixels in the weld area of ​​the weld image to obtain the weld curve. Then, based on the mapping relationship between the pixels in the weld image and the workpiece point cloud, the point cloud corresponding to the weld curve can be determined to generate the weld trajectory.

[0054] In the above-mentioned weld trajectory generation method, firstly, the workpiece point cloud of the target workpiece is acquired; secondly, the workpiece point cloud is fitted with a plane to obtain the workpiece base plane; then, based on the geometric features of the workpiece point cloud, the weld point cloud is extracted from the workpiece point cloud, and the weld point cloud is projected onto the workpiece base plane to generate a weld image; finally, the weld trajectory is generated based on the weld image and the workpiece point cloud. In this way, the workpiece point cloud in three-dimensional space is projected into two-dimensional space, the weld point cloud is filtered according to the geometric features between the workpiece point clouds, and the weld point cloud in two-dimensional space is projected back into three-dimensional space. This reduces the interference of the detection environment, improves the accuracy of weld point cloud extraction, and thus improves the accuracy of weld trajectory planning.

[0055] In one exemplary embodiment, such as Figure 5 As shown, based on the weld image and workpiece point cloud, a weld trajectory is generated, including S401 to S403. Wherein:

[0056] S401, extract the weld centerline from the weld image.

[0057] The weld centerline represents the skeleton of the weld, and its width is a single pixel.

[0058] In practice, morphological algorithms can be used to analyze weld images. The skeleton of the weld area was extracted to obtain the weld centerline. ,like Figure 6 As shown. The weld centerline represents the skeleton of the weld trajectory. For example, a parallel thinning algorithm such as Zhang-Suen is used to extract the weld centerline of the weld region in the weld image. This algorithm iteratively removes boundary pixels that satisfy preset connectivity conditions until only a single-pixel-width centerline remains in the image, thus obtaining the weld centerline. .

[0059] S402, extract the weld center point cloud corresponding to the weld center line from the workpiece point cloud.

[0060] In practice, the correspondence between pixels on the weld centerline and the workpiece point cloud can be determined based on the projection matrix. Then, the point cloud corresponding to the pixels on the weld centerline can be extracted from the workpiece point cloud, thus obtaining the weld centerline point cloud. Figure 7 As shown.

[0061] S403 generates the weld trajectory based on the weld center point cloud and the topological features between the weld center point clouds.

[0062] The topological features may include, but are not limited to, the angle between the normal vectors of the point clouds and the distance between them. For example, determining the weld trajectory based on the weld center point cloud and the topological features between the weld center point clouds includes:

[0063] First, the starting point cloud in the weld center point cloud can be identified. Then, a directed graph is constructed using the weld center point cloud as nodes. The directed edges between nodes can be determined based on the angle between the normal vectors and the distance between the weld center point clouds. Specifically, for each weld center point cloud, the angle between the normal vectors of the weld center point cloud and its neighboring point clouds within a preset neighborhood is determined. Candidate neighboring point clouds with normal vector angles less than a preset threshold are selected from the neighboring point clouds. Then, the target neighboring point cloud with the smallest distance to the weld center point cloud is selected from the candidate neighboring point clouds. A directed edge is added between the weld center point cloud and the target neighboring point cloud. Thus, based on the directed edges, nodes are output from the starting point point cloud to obtain the weld trajectory.

[0064] In this embodiment, the weld centerline is extracted using an image morphology skeleton extraction algorithm, which helps to handle problems such as uneven weld width, edge spatter, and burr interference. Compared with the method of directly finding and calculating the curvature in three-dimensional space to extract the weld centerline, the robustness of weld extraction is improved.

[0065] Based on the topological characteristics between nodes, weld seam trajectories are generated, which improves the accuracy of weld seam trajectory generation.

[0066] In an exemplary embodiment, the topological features include distance, and generating a weld trajectory based on the weld center point cloud and the topological features between the weld center point clouds includes:

[0067] Identify the weld start point cloud from the weld center point cloud, determine the weld start point cloud as the current weld center point cloud, and add the weld start point cloud to the pre-constructed weld trajectory.

[0068] Weld trajectory search steps: Determine the distance between the current weld center point cloud and its neighboring point clouds, update the neighboring point clouds whose distance is less than a preset distance threshold to the current weld center point cloud, and add the current weld center point cloud to the weld trajectory.

[0069] The weld seam trajectory search step is executed iteratively until no neighboring point cloud with a distance less than a preset distance threshold is detected, thus obtaining the weld seam trajectory.

[0070] In this embodiment, for the scattered weld center point cloud, the weld center point cloud is integrated into a point cloud sequence ordered along the weld centerline direction based on the topological features between the weld center point clouds, so as to facilitate weld trajectory planning. In this embodiment, a greedy topological sorting based on KD tree acceleration is used to sort the weld center point cloud to obtain the weld trajectory. Specifically, firstly, the KD tree of the weld center point cloud is constructed. Construction process: (1) Select the split dimension: calculate the variance of the current point set in all dimensions, and select the dimension with the largest variance as the split axis. (2) Determine the split point: sort according to the coordinate of the dimension, and select the median point as the split point. (3) Recursive partitioning: the left subtree contains points whose coordinates in the dimension are less than the median; the right subtree contains points whose coordinates in the dimension are greater than the median.

[0071] Secondly, the starting point cloud of the weld is identified within the weld center point cloud. Specifically, the set of weld center points is traversed, and a KD-tree is used to query the center point cloud of each weld. Within the preset radius The number of neighbor point clouds within the neighborhood Based on the number of neighboring point clouds, identify the weld start point cloud. :

[0072]

[0073] That is, the weld center point cloud corresponding to the minimum number of neighboring point clouds of the weld start point cloud is determined as the weld start point cloud.

[0074] Finally, using a greedy path growth algorithm, starting from the weld origin point cloud, the weld center point cloud is sorted to obtain the welding trajectory. This step corresponds to the weld trajectory search step. Specifically:

[0075] (1) Initialize a list of paths This characterizes the pre-constructed weld trajectory. The weld start point cloud is determined as the current weld center point cloud. The remaining weld center point cloud constitutes the unvisited set. .

[0076] (2) Using a KD-tree in the set Search for the point cloud that has the closest Euclidean distance to the current weld center point cloud. , .

[0077] (3) If the Euclidean distance is less than the preset distance threshold, then the point cloud is added to the pre-constructed weld trajectory. From the set Remove the point from the center and update it to the current weld center point cloud: The preset distance threshold is used to ensure that the point clouds meet the connectivity requirements.

[0078] Thus, steps (2) to (3) above are executed iteratively until no point cloud with a distance less than the preset distance threshold can be found, and the weld trajectory is obtained. .like Figure 8 As shown.

[0079] In this embodiment, a KD-tree spatial index structure is introduced to reduce the event complexity of nearest neighbor search from Optimized to For weld point clouds containing tens of thousands of points, processing time can be reduced from seconds to milliseconds, meeting the cycle time requirements of online production.

[0080] In one exemplary embodiment, after generating the weld seam trajectory, as follows: Figure 9 As shown, the method also includes S500 to S600, wherein:

[0081] S500 performs curve fitting on the weld trajectory to obtain the weld curve.

[0082] The S600 performs point cloud sampling on the weld curve based on preset process parameters to obtain the target weld trajectory.

[0083] To meet the requirement of continuous robot motion, curve fitting is performed on the weld seam trajectory in this embodiment.

[0084] In specific implementation, for S500, non-uniform favorable B-splines (NURBS) are used to trace the weld seam. Perform curve fitting. Specifically:

[0085] The NURBS curve is defined as follows:

[0086]

[0087] in, Control Points;

[0088] Weights;

[0089] for The B-spline basis functions are defined by the Cox-de Boor recursive formula:

[0090]

[0091] It is a node vector.

[0092] Solving for the fitting parameters of the weld curve: The input data points can be determined using the cumulative chord length parameterization method. Corresponding parameter values Then based on the parameter values The node vectors are determined by the average distribution of the data. Finally, the control points are solved using the least squares method. This causes the curve to pass through or approximate the input point. That is, minimizing the objective error function:

[0093]

[0094] For the S600, the spacing can be pre-defined according to the requirements of the grinding process (e.g., ...). Set the sampling interval, and then apply the fitted weld curve according to the sampling interval. Resampling is performed, and the coordinates and tangent vectors of the weld points are calculated to obtain the target weld trajectory. The target weld trajectory can represent a smooth grinding trajectory, such as... Figure 10 As shown.

[0095] In this embodiment, a smooth weld trajectory is obtained by curve fitting and point cloud sampling based on process parameters. This is beneficial for matching the robot's motion characteristics, reducing the amplitude of acceleration changes during robot motion, thereby reducing the possibility of mechanical vibration during grinding, making the surface texture of the weld after grinding uniform and consistent, and improving the welding and grinding quality.

[0096] In an exemplary embodiment, the geometric features include distance. Based on the geometric features of the workpiece point cloud, the weld point cloud is extracted from the workpiece point cloud, including steps S301 to S302, wherein:

[0097] S301, determine the distance between each workpiece point cloud and the workpiece base plane.

[0098] In practice, after fitting the workpiece base plane... Next, determine the workpiece point set. Point cloud of each workpiece With the workpiece base plane Directed distance between :

[0099]

[0100] in, For the workpiece base plane The fitting parameters.

[0101] S302, the workpiece point cloud whose distance is within the preset distance threshold range is determined as the weld point cloud.

[0102] The preset distance threshold range is set based on the welding process specifications. The distance threshold range characterizes the height difference range between the weld point cloud and the workpiece substrate.

[0103] In practical implementation, the distance threshold range is set as follows: Select workpieces from the point cloud set that meet the requirements From multiple workpiece point clouds, the selected workpiece point cloud is identified as the weld seam point cloud. .

[0104] In this embodiment, by fitting the workpiece base plane, the weld seam point cloud is selected based on the distance between the workpiece point cloud and the workpiece base plane, thereby improving the weld seam point cloud extraction efficiency.

[0105] In an exemplary embodiment, before obtaining the workpiece point cloud of the target workpiece, the method further includes S101 to S102, wherein:

[0106] S101, Obtain the dimensional information of the target workpiece.

[0107] The dimensional information may include the length, width, and height of the target workpiece.

[0108] In practice, the length, width, and height of the bounding box of the target workpiece can be obtained through a three-dimensional structural model of the target workpiece. The length, height, and width of the bounding box are then used to determine the dimensions of the target workpiece. Alternatively, an image of the target workpiece can be acquired using a low-resolution global camera, and the length, width, and height of the bounding box of the target workpiece can be determined based on the image. The length, height, and width of the bounding box are then used to determine the dimensions of the target workpiece.

[0109] S102, based on the size information, determine the point cloud acquisition configuration parameters of the target workpiece. The point cloud acquisition configuration parameters represent the operating parameters of the robot and the camera.

[0110] The point cloud acquisition configuration parameters can include the movement distance of the robot's end effector (such as the length of the movement trajectory) and the trigger frequency of the line scan camera. The trigger frequency can be the line frequency, which is the number of lines of images captured by the camera per second, representing the reading frequency of pixel lines on the linear array sensor.

[0111] In practice, the movement distance of the robot's end effector can be determined based on the length in the target workpiece's dimension information, and the trigger frequency of the line scan camera can be determined based on the width in the dimension information. The triggering frequency must meet preset sampling conditions. For example, the preset sampling conditions include a triggering frequency that is greater than or equal to twice the characteristic frequency of the weld.

[0112] Acquire the workpiece point cloud of the target workpiece, including: S103, acquire the workpiece point cloud of the target workpiece according to the point cloud acquisition configuration parameters.

[0113] In practice, the motion trajectory of the robot's end effector is adjusted in advance according to the motion distance in the point cloud acquisition configuration parameters, and the trigger frequency of the line scan camera is adjusted according to the trigger frequency in the point cloud acquisition configuration parameters. Subsequently, the adjusted robot and line scan camera are controlled to acquire the workpiece point cloud of the target workpiece. Here, the implementation method for acquiring the workpiece point cloud of the target workpiece refers to the implementation steps for acquiring the workpiece point cloud of the target workpiece in the above embodiments, and will not be repeated here.

[0114] In this embodiment, the point cloud scanning strategy is adaptively adjusted according to the workpiece size, which improves the adaptability to point cloud acquisition of different specifications and types of sizes and enhances the robustness of point cloud scanning.

[0115] To provide a clearer explanation of the weld trajectory generation method provided in this application, a specific embodiment is described below, which includes the following steps:

[0116] S1. Obtain the size information of the target workpiece. Based on the size information, determine the point cloud acquisition configuration parameters of the target workpiece. The point cloud acquisition configuration parameters represent the operating parameters of the robot and the camera.

[0117] S2, based on the point cloud acquisition configuration parameters, obtain the workpiece point cloud of the target workpiece.

[0118] S3, perform planar fitting on the workpiece point cloud to obtain the workpiece base plane.

[0119] S4, determine the distance between each workpiece point cloud and the workpiece base plane, and determine the workpiece point cloud with the distance within the preset distance threshold range as the weld point cloud.

[0120] S5 projects the weld point cloud onto the workpiece base plane to generate a weld image.

[0121] S6: Extract the weld centerline from the weld image, and extract the weld center point cloud corresponding to the weld centerline from the workpiece point cloud.

[0122] S7. Identify the weld start point cloud from the weld center point cloud, determine the weld start point cloud as the current weld center point cloud, and add the weld start point cloud to the pre-built weld trajectory.

[0123] S8, determine the distance between the current weld center point cloud and the neighbor point clouds of the current weld center point cloud, update the neighbor point clouds whose distance is less than the preset distance threshold to the current weld center point cloud, and add the current weld center point cloud to the weld trajectory.

[0124] S9, iterate through S8 until no neighboring point cloud with a distance less than the preset distance threshold is detected, and the weld trajectory is obtained.

[0125] S10, perform curve fitting on the weld trajectory to obtain the weld curve, and perform point cloud sampling on the weld curve based on the preset process parameters to obtain the target weld trajectory.

[0126] It should be understood that although the steps in the flowcharts of the embodiments described above are shown sequentially according to the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless explicitly stated herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least some steps in the flowcharts of the embodiments described above may include multiple steps or multiple stages. These steps or stages are not necessarily completed at the same time, but can be executed at different times. The execution order of these steps or stages is not necessarily sequential, but can be performed alternately or in turn with other steps or at least some of the steps or stages of other steps.

[0127] In one exemplary embodiment, such as Figure 11 As shown, a weld trajectory generation device 600 is provided, including: a point cloud acquisition module 610, a plane fitting module 620, a point cloud projection module 630, and a weld trajectory generation module 640, wherein:

[0128] The point cloud acquisition module 610 is used to acquire the point cloud of the target workpiece;

[0129] The plane fitting module 620 is used to perform plane fitting on the workpiece point cloud to obtain the workpiece base plane;

[0130] The point cloud projection module 630 is used to extract the weld seam point cloud from the workpiece point cloud based on the geometric features of the workpiece point cloud, project the weld seam point cloud onto the workpiece base plane, and generate a weld seam image.

[0131] The weld trajectory generation module 640 is used to generate weld trajectories based on weld images and workpiece point clouds.

[0132] In an exemplary embodiment, the weld trajectory generation module 640 is further configured to extract the weld centerline from the weld image; extract the weld center point cloud corresponding to the weld centerline from the workpiece point cloud; and generate a weld trajectory based on the weld center point cloud and the topological features between the weld center point clouds.

[0133] In an exemplary embodiment, the weld trajectory generation module 640 is further configured to identify the weld start point cloud from the weld center point cloud, determine the weld start point cloud as the current weld center point cloud, and add the weld start point cloud to the pre-constructed weld trajectory; the weld trajectory search step is configured to: determine the distance between the current weld center point cloud and its neighboring point clouds, update the neighboring point clouds whose distance is less than a preset distance threshold as the current weld center point cloud, and add the current weld center point cloud to the weld trajectory; iteratively execute the weld trajectory search step until no neighboring point clouds whose distance is less than the preset distance threshold are detected, thereby obtaining the weld trajectory.

[0134] In an exemplary embodiment, the weld trajectory generation device 600 further includes a trajectory smoothing module 650, which is used to perform curve fitting on the weld trajectory to obtain a weld curve; and to perform point cloud sampling on the weld curve based on preset process parameters to obtain a target weld trajectory.

[0135] In an exemplary embodiment, the point cloud projection module 630 is further configured to determine the distance between each workpiece point cloud and the workpiece base plane; and to determine the workpiece point clouds whose distance is within a preset distance threshold range as weld point clouds.

[0136] In an exemplary embodiment, the weld trajectory generation device 600 further includes a parameter adjustment module 660, which is used to acquire the size information of the target workpiece; and determine the point cloud acquisition configuration parameters of the target workpiece based on the size information, wherein the point cloud acquisition configuration parameters characterize the operating parameters of the robot and the camera.

[0137] The point cloud acquisition module 610 is also used to acquire the workpiece point cloud of the target workpiece according to the point cloud acquisition configuration parameters.

[0138] Each module in the aforementioned weld trajectory generation device 600 can be implemented entirely or partially through software, hardware, or a combination thereof. These modules can be embedded in or independent of the processor in a computer device, or stored in the memory of a computer device as software, so that the processor can call and execute the operations corresponding to each module.

[0139] In one exemplary embodiment, a computer device is provided, which may be a server, and its internal structure diagram may be as follows: Figure 12As shown, this computer device includes a processor, memory, input / output (I / O) interfaces, and a communication interface. The processor, memory, and I / O interfaces are connected via a system bus, and the communication interface is also connected to the system bus via the I / O interfaces. The processor provides computational and control capabilities. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores the operating system, computer programs, and a database. The internal memory provides the environment for the operation of the operating system and computer programs stored in the non-volatile storage media. The database stores data. The I / O interfaces are used for exchanging information between the processor and external devices. The communication interface is used for communicating with external terminals via a network. When executed by the processor, the computer program implements a weld seam trajectory generation method.

[0140] Those skilled in the art will understand that Figure 12 The structure shown is merely a block diagram of a portion of the structure related to the present application and does not constitute a limitation on the computer device to which the present application is applied. Specific computer devices may include more or fewer components than those shown in the figure, or combine certain components, or have different component arrangements.

[0141] In one exemplary embodiment, a computer device is provided, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement the steps in any of the above embodiments of the weld trajectory generation method.

[0142] In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored, which, when executed by a processor, implements the steps in any of the above embodiments of the weld trajectory generation method.

[0143] In one embodiment, a computer program product is provided, including a computer program that, when executed by a processor, implements the steps in any of the above embodiments of the weld trajectory generation method.

[0144] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, data stored, data displayed, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of the relevant data must comply with relevant regulations.

[0145] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium, and when executed, it can include the processes of the embodiments of the above methods. Any references to memory, databases, or other media used in the embodiments provided in this application can include at least one of non-volatile memory and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetic random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. By way of illustration and not limitation, RAM can take many forms, such as Static Random Access Memory (SRAM) or Dynamic Random Access Memory (DRAM). The databases involved in the embodiments provided in this application may include at least one type of relational database and non-relational database. Non-relational databases may include, but are not limited to, blockchain-based distributed databases. The processors involved in the embodiments provided in this application may be general-purpose processors, central processing units, graphics processing units, digital signal processors, programmable logic devices, quantum computing-based data processing logic devices, artificial intelligence (AI) processors, etc., and are not limited to these.

[0146] The technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this application.

[0147] The embodiments described above are merely illustrative of several implementation methods of this application, and while the descriptions are specific and detailed, they should not be construed as limiting the scope of this patent application. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of this application, and these all fall within the protection scope of this application. Therefore, the protection scope of this application should be determined by the appended claims.

Claims

1. A method for generating weld seam trajectories, characterized in that, The method includes: Obtain the point cloud of the target workpiece; The workpiece base plane is obtained by performing planar fitting on the workpiece point cloud; Based on the geometric features of the workpiece point cloud, the weld seam point cloud is extracted from the workpiece point cloud, and the weld seam point cloud is projected onto the workpiece base plane to generate a weld seam image. A weld trajectory is generated based on the weld image and the workpiece point cloud.

2. The method according to claim 1, characterized in that, The step of generating a weld trajectory based on the weld image and the workpiece point cloud includes: Extract the weld centerline from the weld image; Extract the weld center point cloud corresponding to the weld center line from the workpiece point cloud; The weld trajectory is generated based on the weld center point cloud and the topological features between the weld center point clouds.

3. The method according to claim 2, characterized in that, The topological features include distance; the generation of the weld trajectory based on the weld center point cloud and the topological features between the weld center point clouds includes: The weld start point cloud is identified from the weld center point cloud, the weld start point cloud is determined as the current weld center point cloud, and the weld start point cloud is added to the pre-constructed weld trajectory. Weld trajectory search steps: Determine the distance between the current weld center point cloud and the neighbor point clouds of the current weld center point cloud, update the neighbor point clouds whose distance is less than a preset distance threshold to the current weld center point cloud, and add the current weld center point cloud to the weld trajectory; The weld seam trajectory search step is executed iteratively until no neighboring point cloud with a distance less than a preset distance threshold is detected, thus obtaining the weld seam trajectory.

4. The method according to claim 3, characterized in that, After generating the weld seam trajectory, the method further includes: The weld trajectory is fitted to obtain the weld curve; The weld curve is sampled using point cloud based on preset process parameters to obtain the target weld trajectory.

5. The method according to claim 1, characterized in that, The geometric features include distance; the step of extracting the weld seam point cloud from the workpiece point cloud based on the geometric features of the workpiece point cloud includes: Determine the distance between each of the workpiece point clouds and the workpiece base plane; The point cloud of the workpiece whose distance is within the preset distance threshold range is determined as the weld point cloud.

6. The method according to any one of claims 1 to 5, characterized in that, Before acquiring the workpiece point cloud of the target workpiece, the method further includes: Obtain the dimensional information of the target workpiece; Based on the size information, the point cloud acquisition configuration parameters of the target workpiece are determined, and the point cloud acquisition configuration parameters represent the operating parameters of the robot and the camera; The step of obtaining the point cloud of the target workpiece includes: Based on the point cloud acquisition configuration parameters, obtain the workpiece point cloud of the target workpiece.

7. A weld seam trajectory generation device, characterized in that, The device includes: The point cloud acquisition module is used to acquire the point cloud of the target workpiece. The plane fitting module is used to perform plane fitting on the workpiece point cloud to obtain the workpiece base plane; The point cloud projection module is used to extract the weld seam point cloud from the workpiece point cloud based on the geometric features of the workpiece point cloud, and project the weld seam point cloud onto the workpiece base plane to generate a weld seam image. The weld trajectory generation module is used to generate a weld trajectory based on the weld image and the workpiece point cloud.

8. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that, When the processor executes the computer program, it implements the steps of the method according to any one of claims 1 to 6.

9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 6.

10. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 6.