Method and device for automatic workpiece positioning

Through point cloud registration and virtual robot technology, the problems of tedious workpiece positioning steps and low efficiency are solved, fast and accurate workpiece positioning and processing are achieved, and the efficiency and fault tolerance of workpiece processing are improved.

CN115383355BActive Publication Date: 2024-10-18SHEN ZHEN QIAN HAI RUI JI TECHNOLOGY CO LTD +2
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202211063259.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-08-31
Publication Date
2024-10-18
Estimated Expiration
2042-08-31

AI Technical Summary

Technical Problem

In existing workpiece processing technology, the workpiece positioning steps are cumbersome and inefficient, resulting in reduced processing efficiency and increased costs.

Method used

By obtaining the source point cloud of the workpiece digital model, performing point cloud registration, reconstructing the virtual photographing position, obtaining the virtual source point cloud, and realizing the virtual source point cloud positioning in the virtual robot base coordinate system, and then constructing and The consistent workpiece position relationship in real space enables automatic workpiece positioning.

Benefits of technology

It greatly reduces the actual operation time of workpiece positioning, improves processing efficiency, increases processing fault tolerance and accuracy, and reduces the need for manual positioning.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115383355B_ABST
    Figure CN115383355B_ABST
Patent Text Reader

Abstract

The present disclosure provides a method and device for automatic workpiece positioning, including: obtaining the source point cloud of the workpiece digital model according to the surface layer of the workpiece digital model, aligning the target point cloud mapped by the workpiece with the source point cloud, obtaining a rough mapping relationship between the source point cloud and the target point cloud, reconstructing the virtual point cloud camera's virtual shooting position relative to the source point cloud according to the rough mapping relationship, taking a virtual photo of the workpiece digital model at the virtual shooting position of the point cloud camera to obtain a virtual source point cloud, realigning the virtual source point cloud with the target point cloud, obtaining an accurate mapping relationship between the virtual source point cloud and the target point cloud, and performing virtual source point cloud positioning in the virtual robot base coordinate system according to the accurate mapping relationship between the virtual source point cloud and the target point cloud. The present application solves the problem that the traditional method adds a sensor at the end of the welding robot and completes the positioning by touching the workpiece, resulting in cumbersome steps and large positioning errors in the actual welding process.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the field of workpiece processing, and in particular to a method and device for automatic workpiece positioning. Background Art

[0002] With the development of workpiece processing technology, workpiece processing technology has been continuously updated and improved, and has gradually evolved from simple manual processing to workpiece processing technology characterized by automation and intelligence. The scope of processing objects and technical level have been significantly improved.

[0003] In order to continuously improve the degree of automation and intelligence of workpiece processing technology, the main body of workpiece processing has gradually changed from manual to various processing workstations or processing welding robots, realizing full automation and self-efficiency of workpiece processing. However, when performing fully automated and intelligent processing on workpieces, the first thing to do is to position the workpiece. Only when the workpiece is accurately positioned can it be processed more accurately. The current workpiece processing technology cannot solve the positioning problem of the workpiece well. It can only be completed by adding sensors such as short-circuit sensors at the end of the welding robot and moving the welding robot to touch the workpiece. It takes a lot of time to complete the positioning of the entire workpiece, and the process is cumbersome, which greatly reduces the processing efficiency of the workpiece and increases the processing cost. Summary of the invention

[0004] One purpose of the present disclosure is to solve the problem of complicated and inefficient workpiece positioning steps.

[0005] According to one aspect of an embodiment of the present disclosure, a method for automatic workpiece positioning is disclosed, the method comprising:

[0006] Acquire a source point cloud of the workpiece digital model according to the surface layer of the workpiece digital model, wherein the source point cloud is used to express the surface of the workpiece digital model after removing the thickness;

[0007] Registering the target point cloud mapped by the workpiece according to the source point cloud to obtain a rough mapping relationship between the source point cloud and the target point cloud;

[0008] According to the rough mapping relationship between the source point cloud and the target point cloud, reconstructing the virtual point cloud camera's virtual photo taking position relative to the source point cloud for the photo taking position of the point cloud camera;

[0009] Taking a virtual photograph of the workpiece digital model at a virtual photographing position to obtain a virtual source point cloud;

[0010] Re-registering the virtual source point cloud with the target point cloud to obtain an accurate mapping relationship between the virtual source point cloud and the target point cloud formed by the workpiece digital model;

[0011] According to the precise mapping relationship between the virtual source point cloud and the target point cloud, the virtual source point cloud positioning in the virtual robot base coordinate system is performed.

[0012] According to one aspect of an embodiment of the present disclosure, a method for obtaining a source point cloud of a workpiece digital model according to a surface layer of the workpiece digital model is disclosed, including:

[0013] Obtain a shell file according to the workpiece digital model, and extract a surface layer file from the shell file;

[0014] Converting the format of the surface layer file into a point cloud format;

[0015] The thickness of the surface layer point cloud model is removed to obtain the source point cloud of the workpiece digital model.

[0016] According to one aspect of an embodiment of the present disclosure, a target point cloud mapped to the workpiece is registered according to the source point cloud to obtain a rough mapping relationship between the source point cloud and the target point cloud, including:

[0017] Obtain the target point cloud by taking pictures of the workpiece;

[0018] The source point cloud and the target point cloud are registered to obtain a rough mapping relationship between the source point cloud and the target point cloud, and one of the source point cloud or the target point cloud can be rotated and translated according to the rough mapping relationship to coincide with the position of the other.

[0019] According to one aspect of an embodiment of the present disclosure, a method of acquiring a target point cloud by photographing a workpiece is disclosed, including:

[0020] The welding robot is driven to take a picture of the workpiece to obtain a first target point cloud of the workpiece in a point cloud camera coordinate system;

[0021] According to the positional relationship between the welding robot and the point cloud camera, the first target point cloud is calculated to obtain a second target point cloud of the workpiece in the base coordinate system of the welding robot.

[0022] According to one aspect of an embodiment of the present disclosure, a method of acquiring a target point cloud by photographing a workpiece is disclosed, further comprising:

[0023] The second target point cloud is denoised to reduce density to obtain a target point cloud.

[0024] According to one aspect of an embodiment of the present disclosure, a method is disclosed for reconstructing a virtual photographing position of a virtual point cloud camera relative to a source point cloud based on a rough mapping relationship between the source point cloud and the target point cloud, including:

[0025] According to the positional relationship between the point cloud camera and the target point cloud of the workpiece, the positional relationship between the welding robot's photographing position and the workpiece in the welding robot's base coordinate system is obtained;

[0026] The positional relationship between the photographing position of the welding robot and the workpiece is converted according to the rough mapping relationship to obtain the digital model of the workpiece and its corresponding virtual photographing position.

[0027] According to one aspect of an embodiment of the present disclosure, a method for performing virtual source point cloud positioning in a virtual robot base coordinate system according to a precise mapping relationship between the virtual source point cloud and the target point cloud is disclosed, including:

[0028] According to the precise mapping relationship between the virtual source point cloud and the target point cloud and the position of the welding robot, the position of the virtual robot relative to the virtual source point cloud is reconstructed to obtain the positional relationship between the virtual robot and the virtual source point cloud;

[0029] According to the positional relationship between the virtual robot and the virtual source point cloud, the virtual source point cloud is positioned in the virtual robot base coordinate system.

[0030] According to one aspect of an embodiment of the present disclosure, an automatic workpiece positioning device is disclosed, the device comprising:

[0031] Point cloud acquisition module: acquires the source point cloud of the workpiece digital model according to the surface layer of the workpiece digital model, and the source point cloud is used to express the surface of the workpiece digital model after removing the thickness;

[0032] Registration module: registers the target point cloud mapped by the workpiece according to the source point cloud to obtain a rough mapping relationship between the source point cloud and the target point cloud;

[0033] Positioning module: Based on the rough mapping relationship between the source point cloud and the target point cloud, the virtual point cloud camera's virtual shooting position relative to the source point cloud is reconstructed.

[0034] Photo module: take a virtual photo of the workpiece digital model at a virtual photo position to obtain a virtual source point cloud;

[0035] The second registration module is used to re-register the virtual source point cloud and the target point cloud to obtain an accurate mapping relationship between the virtual source point cloud and the target point cloud formed by the workpiece digital model;

[0036] The second positioning module: performs virtual source point cloud positioning in the virtual robot base coordinate system according to the precise mapping relationship between the virtual source point cloud and the target point cloud.

[0037] According to one aspect of an embodiment of the present disclosure, a point cloud acquisition module is disclosed, including:

[0038] Extraction module: obtain the shell file according to the workpiece digital model, and extract the surface layer file from the shell file;

[0039] Conversion module: converting the format of the surface layer file into a point cloud format;

[0040] Thickness removal module: removes the thickness of the surface layer point cloud model to obtain the source point cloud of the workpiece digital model.

[0041] According to one aspect of an embodiment of the present disclosure, an automatic workpiece positioning device is disclosed, comprising: a welding robot, a mechanical arm, a point cloud camera, a memory, and a processor. The welding robot moves the point cloud camera at the end of the mechanical arm through the mechanical arm connected thereto, and the welding robot and the point cloud camera realize automatic positioning of the workpiece. The memory is used to store instructions readable by a mobile terminal.

[0042] The processor, which is electrically connected to the memory, reads the welding robot readable instructions stored in the memory to execute any of the preceding claims.

[0043] In an embodiment of the present application, in order to achieve fast, convenient and accurate positioning and processing of the workpiece, the source point cloud corresponding to the workpiece digital model and the thickness of the digital model is first obtained through the workpiece digital model, and the source point cloud of the workpiece digital model is aligned with the target point cloud mapped to the workpiece to obtain a rough mapping relationship between the source point cloud and the target point cloud. Therefore, the virtual shooting position of the virtual point cloud camera relative to the source point cloud can be reconstructed according to the rough mapping relationship. The workpiece digital model is photographed at the virtual shooting position to obtain the virtual source point cloud, and the virtual source point cloud is realigned with the target point cloud to obtain a precise mapping relationship between the virtual source point cloud and the target point cloud. Finally, according to the precise mapping relationship, the virtual source point cloud positioning in the virtual robot base coordinate system is obtained, so that the position relationship between the welding robot and the workpiece that is consistent with that in the real space can be constructed in the digital model space, and the operation of the virtual robot in the digital model space on the workpiece digital model is mapped to the real space through the precise mapping relationship to complete the processing of the workpiece. There is no need to manually position the workpiece in the real space, which greatly reduces the actual operation time. In addition, by realizing virtual processing mapped by the workpiece using a virtual robot in the digital space, more processing schemes can be simulated, greatly increasing the fault tolerance of workpiece processing in the real space.

[0044] Other features and advantages of the present disclosure will become apparent from the following detailed description, or may be learned in part by the practice of the present disclosure.

[0045] It is to be understood that the foregoing general description and the following detailed description are exemplary only and are not restrictive of the present disclosure. BRIEF DESCRIPTION OF THE DRAWINGS

[0046] The above and other objects, features and advantages of the present disclosure will become more apparent by describing in detail example embodiments thereof with reference to the attached drawings.

[0047] Figure 1 A system architecture diagram of an uplink application according to an embodiment of the present disclosure is shown.

[0048] Figure 2 A flow chart of a method for automatic workpiece positioning according to an embodiment of the present disclosure is shown.

[0049] Figure 3 A flow chart of obtaining a source point cloud of a workpiece digital model based on a surface layer of the workpiece digital model according to another embodiment of the present disclosure is shown.

[0050] Figure 4 A flowchart is shown of mapping a target point cloud of a workpiece according to another embodiment of the present disclosure, registering the target point cloud according to the source point cloud, and obtaining a rough mapping relationship between the source point cloud and the target point cloud.

[0051] Figure 5 A flow chart of acquiring a target point cloud by photographing a workpiece according to another embodiment of the present disclosure is shown.

[0052] Figure 6 A flowchart is shown for reconstructing a virtual photographing position of a virtual point cloud camera relative to a source point cloud based on a rough mapping relationship between a source point cloud and a target point cloud according to another embodiment of the present disclosure.

[0053] Figure 7 A flowchart is shown for performing virtual source point cloud positioning in a virtual robot base coordinate system based on a precise mapping relationship between a virtual source point cloud and a target point cloud according to another embodiment of the present disclosure.

[0054] Figure 8 A hardware structure diagram of a welding robot or a point cloud camera according to an embodiment of the present disclosure is shown. DETAILED DESCRIPTION

[0055] Example embodiments will now be described more fully with reference to the accompanying drawings. However, example embodiments can be implemented in a variety of forms and should not be construed as limited to the examples set forth herein; rather, these example embodiments are provided so that the description of the present disclosure will be more comprehensive and complete and the concepts of the example embodiments will be fully conveyed to those skilled in the art. The accompanying drawings are only schematic illustrations of the present disclosure and are not necessarily drawn to scale. The same reference numerals in the figures represent the same or similar parts, and thus their repeated description will be omitted.

[0056] In addition, the described features, structures or characteristics may be combined in one or more example embodiments in any suitable manner. In the following description, many specific details are provided to provide a full understanding of the example embodiments of the present disclosure. However, those skilled in the art will appreciate that the technical solutions of the present disclosure may be practiced while omitting one or more of the specific details, or other methods, components, steps, etc. may be adopted. In other cases, well-known structures, methods, implementations or operations are not shown or described in detail to avoid obscuring various aspects of the present disclosure.

[0057] Some of the blocks shown in the accompanying drawings are functional entities that do not necessarily correspond to physically or logically independent entities. These functional entities can be implemented in software form, or in one or more hardware modules or integrated circuits, or in different networks and / or processor devices and / or microcontroller devices.

[0058] See also Figure 1 , Figure 1 It is a system architecture used in the embodiments of the present disclosure. The system architecture may include: a welding robot 11 and at least one point cloud camera 12 for taking pictures of a workpiece and generating a target point cloud, and the point cloud camera 12 works under the control of the welding robot 11. In one embodiment, the welding robot 11 controls at least one point cloud camera 12 to extract a point cloud from the workpiece.

[0059] It should be understood that Figure 1 The number of cloud cameras 12 in FIG. 1 is only illustrative. Any number of point cloud cameras 12 may be provided according to implementation requirements.

[0060] Some technical solutions of the embodiments of the present disclosure can be based on Figure 1 The system architecture shown or its variant architecture is used for specific implementation.

[0061] The method of automatic workpiece positioning described in this application aims to achieve the ultimate effect of restoring the positional relationship between the welding robot and the workpiece in the real space in the digital model space. The positional relationship between the virtual robot and the digital model of the workpiece is made the same as the positional relationship between the welding robot and the workpiece in the real space. In the digital model space, the digital model of the workpiece is processed from the perspective of the virtual robot, which deeply restores the processing perspective of the welding robot on the workpiece in the real space. The virtual robot is the mapping of the welding robot in the digital model space, and the processing operations on the digital model of the workpiece are performed from the perspective of the virtual robot, and then these operations are implemented on the workpiece through the mapping relationship. This makes the two perspectives consistent, which is conducive to the grasp of details when processing the workpiece.

[0062] Specifically, this application will achieve the above technical effect through two point cloud registrations.

[0063] The first registration is to register the source point cloud derived from the workpiece digital model and the target point cloud derived from the workpiece to obtain a rough mapping relationship between the digital model space coordinate system and the real space welding robot base coordinate system.

[0064] First of all, it should be noted that before the first registration, the source point cloud has been stripped of thickness to avoid excessive computational complexity in directly obtaining the mapping relationship. The resulting mapping relationship is a rough mapping relationship. In order to eliminate the error caused by the rough mapping relationship, it is necessary to obtain the virtual photographing position corresponding to the workpiece digital model in the digital model space based on the rough mapping relationship.

[0065] The workpiece digital model is photographed virtually at the virtual photographing position to obtain a virtual source point cloud. The virtual source point cloud and the target point cloud are then registered for a second time to obtain an accurate mapping relationship and obtain the position of the virtual robot. The positional relationship between the virtual robot and the workpiece digital model is consistent with the positional relationship between the welding robot and the workpiece in the real space. This completes the positioning of the workpiece digital model in the digital model space.

[0066] Finally, it can be realized that the virtual robot simulates various complex processing on the workpiece digital model in the digital model space. This complex processing only acts on the workpiece digital model first, and does not directly control the welding robot to process the workpiece, so as to realize trial processing for the workpiece and ensure the reliability and effect of the processing process. By directly simulating various processing on the workpiece digital model in the digital model space, and then mapping the processing of the workpiece digital model to the workpiece through the mapping relationship of the above two coordinate systems, the processing of the workpiece in the real space is completed.

[0067] See also Figure 2 , Figure 2 A flow chart of a method for automatic workpiece positioning according to an embodiment of the present disclosure is shown. The present disclosure embodiment provides a method for automatic workpiece positioning, comprising:

[0068] Step S210, obtaining a source point cloud of the workpiece digital model according to the surface layer of the workpiece digital model;

[0069] Step S220, registering the target point cloud mapped by the workpiece according to the source point cloud to obtain a rough mapping relationship between the source point cloud and the target point cloud;

[0070] Step S230, reconstructing the virtual point cloud camera's virtual photo taking position relative to the source point cloud based on the rough mapping relationship between the source point cloud and the target point cloud;

[0071] Step S240, taking a virtual photograph of the workpiece digital model at a virtual photographing position to obtain a virtual source point cloud;

[0072] Step S250, re-registering the virtual source point cloud and the target point cloud to obtain an accurate mapping relationship between the virtual source point cloud and the target point cloud formed by the workpiece digital model;

[0073] Step S260 , performing virtual source point cloud positioning in the virtual robot base coordinate system according to the precise mapping relationship between the virtual source point cloud and the target point cloud.

[0074] These six steps are described in detail below.

[0075] Step S210 is to obtain the source point cloud formed by removing the thickness and even reducing the density. The point cloud refers to the image formed after the coordinate information of each point contained in the point cloud data is materialized. Since the number of "points" is large and dense, it is called "point cloud". The point cloud data is a vector expressed in the form of three-dimensional coordinates. In other words, the point cloud data is a collection of spatial coordinate information of all points. The source point cloud is the image formed after the spatial coordinate information corresponding to each sampling point on the digital model is materialized in the digital model space coordinate system.

[0076] According to these source point clouds used to perform the first registration, they will be acquired in the following way. First, obtain the workpiece digital model that is consistent with the size of the workpiece, obtain the workpiece digital model file of the workpiece digital model, and then extract the shell file of the workpiece digital model from the workpiece digital model file. The workpiece digital model can be established according to the workpiece digital model file. The workpiece digital model file contains data recording the positional relationship between the points of the workpiece digital model. Just select a point in the digital model space as the reference point of the workpiece digital model file, and the entire workpiece digital model can be established according to the positional relationship between the points of the digital model. The shell file of the workpiece digital model is a file containing the surface layer of the workpiece digital model. Secondly, the surface layer file is converted into a point cloud format file through format conversion, and the point cloud format file is read to obtain the point cloud, remove the thickness of the point cloud, and adjust the size corresponding to the remaining point cloud to the size consistent with the size of the workpiece to obtain the source point cloud derived from the workpiece digital model.

[0077] It should be understood that the registration between point clouds described below can only be performed if two point clouds have the same size. Because the target point cloud originates from the workpiece and has the same size as the workpiece, the source point cloud and the target point cloud both have the same size as the workpiece.

[0078] See also Figure 3 , Figure 3 A flowchart showing a method of obtaining a source point cloud of a workpiece digital model according to a surface layer of a workpiece digital model according to an embodiment of the present application is shown. The embodiment of the present application provides a step S210 of obtaining a source point cloud of a workpiece digital model according to a surface layer of the workpiece digital model, including:

[0079] Step S211, obtaining a shell file according to the workpiece digital model, and extracting a surface layer file from the shell file;

[0080] Step S212, converting the format of the surface layer file into a point cloud format;

[0081] Step S213, removing the thickness of the surface layer point cloud model to obtain the source point cloud of the workpiece digital model.

[0082] These three steps are described in detail below.

[0083] In step S211, in order to obtain the source point cloud from the workpiece digital model, first obtain the workpiece digital model created according to the workpiece. Specifically, the workpiece digital model consistent with the size of the workpiece can be drawn or generated according to the workpiece data. The workpiece data is used to describe the size of the workpiece and the positional relationship between each point of the workpiece. It should be noted that the data of the workpiece digital model can come from manual measurement or from various machine measurements. Secondly, the shell file of the workpiece digital model file is obtained according to the workpiece digital model file, and the surface layer file of the workpiece digital model is extracted from the shell file. The surface layer file contains the positional relationship between each point on the surface of the workpiece digital model.

[0084] The execution of step S212 is to convert the surface layer file of the workpiece digital model into a file in point cloud format, and obtain the point cloud mapped by the surface layer of the workpiece digital model according to the file in point cloud format.

[0085] In step S213, the point cloud mapped by the file in the above point cloud format is removed from the point cloud thickness. The removal of the point cloud thickness mentioned here means that only the sampling points on the surface of the workpiece digital model are taken, and all other sampling points inside the workpiece are discarded.

[0086] The embodiment of the present application realizes the thickness removal of the point cloud through the least squares method (LSM). The least squares method is used to simulate the points on the point cloud surface to fit the curve, and then the curve is fitted into a surface to generate a surface fitted by the points on the point cloud surface to form a point cloud surface model. Finally, all points that do not belong to the above point cloud surface model are removed to complete the thickness removal of the point cloud and obtain the source point cloud derived from the workpiece digital model.

[0087] The above-mentioned “simulation” means that the above process removes points that do not belong to the point cloud surface, and does not actually fit the points into curves and surfaces, but is only for identifying points that do not belong to the digital model surface of the workpiece in order to remove them.

[0088] The above-mentioned fitting of curves and surfaces refers to performing segmented fitting curves on discretely distributed points, and then fitting the curves into surfaces. Specifically, the least squares method is used to fit between each adjacent measurement point in the longitudinal or transverse direction to obtain a curve that conforms to the workpiece digital model. The least squares method calculates the curve function parameters with the smallest error between data points based on the coordinates of each measurement point, and uses the curve function parameters to achieve the best effect of curve fitting. Secondly, after the curve is fitted, the least squares method is used again to fit the curve through the corresponding points on the two parallel curves, thereby forming countless fitting curves between the two parallel curves, thereby achieving the effect of fitting into a surface.

[0089] In step S220, the source point cloud obtained above is registered with the target point cloud mapped according to the workpiece to obtain a rough mapping relationship between the source point cloud and the target point cloud.

[0090] The target point cloud refers to the set of sampling points obtained after obtaining the coordinate information of each sampling point on the surface of the workpiece, which is called the target point cloud data. The target point cloud refers to the image formed after the coordinate information of each point contained in the point cloud data is materialized. The coordinate information of the sampling points is collected by the welding robot using a point cloud camera to take pictures of the workpiece. The coordinate information of the target point cloud is in the base coordinate system of the welding robot, and the target point cloud is aligned with the source point cloud, that is, the transformation relationship between the two coordinate systems is found. This application refers to the mapping relationship. According to the mapping relationship, the source point cloud can be rotated and translated to obtain the target point cloud, and the target point cloud can also be rotated and translated according to the mapping relationship to obtain the source point cloud.

[0091] See also Figure 4 , Figure 4 A flowchart is shown of obtaining a rough mapping relationship between the source point cloud and the target point cloud by registering the target point cloud mapped to the workpiece according to an embodiment of the present application. The embodiment of the present application provides a step S220 of obtaining a rough mapping relationship between the source point cloud and the target point cloud by registering the target point cloud mapped to the workpiece according to the source point cloud, including:

[0092] Step S221, obtaining a target point cloud by photographing the workpiece;

[0093] Step S222, registering the source point cloud with the target point cloud to obtain a rough mapping relationship between the source point cloud and the target point cloud, wherein one of the source point cloud or the target point cloud can be rotated or translated according to the rough mapping relationship to coincide with the position of the other.

[0094] The two steps are described in detail below.

[0095] In step S221, the welding robot uses the point cloud camera to take a picture of the workpiece to collect the coordinate information of the workpiece sampling points, and the coordinate information is used to represent the positional relationship between the workpiece sampling points. When the point cloud camera collects the sampling points of the workpiece, the coordinate information contained in the sampling points belongs to the point cloud camera coordinate system. After the sampling points are taken, the welding robot converts the coordinate information belonging to the point cloud camera coordinate system into the coordinate information belonging to the welding robot base coordinate system, and materializes these coordinate data, that is, obtains the target point cloud originating from the workpiece.

[0096] It should be understood that the coordinate information of the sampling points is converted to the base coordinate system of the welding robot in order to facilitate the search for the virtual robot position and the workpiece digital model position with the same positional relationship in the digital model space. The positional relationship between the two is sought because when the workpiece is processed, all processing operations are performed by the welding robot. By clarifying the positional relationship between the two, it is beneficial to improve the processing efficiency of the welding robot.

[0097] See also Figure 5 , Figure 5 A flowchart showing a method of acquiring a target point cloud by photographing a workpiece according to an embodiment of the present application is shown. The embodiment of the present application provides a step S221 of acquiring a target point cloud by photographing a workpiece, including:

[0098] Step S2211, driving the welding robot to take a picture of the workpiece to obtain a first target point cloud of the workpiece in a point cloud camera coordinate system;

[0099] Step S2212: According to the positional relationship between the welding robot and the point cloud camera, the first target point cloud is calculated to obtain a second target point cloud of the workpiece in the base coordinate system of the welding robot.

[0100] The following two steps are described in detail.

[0101] First, it should be noted that the target point cloud in step S221 includes not only the target point cloud itself, but also the first target point cloud and the second target point cloud.

[0102] In step S2211, the welding robot point cloud camera takes a picture of the workpiece, extracts sampling points of the workpiece, obtains coordinate information of the sampling points in the point cloud camera coordinate system, and obtains a first target point cloud.

[0103] In step S2212, based on the positional relationship between the welding robot and the point cloud camera, the coordinate information of each sampling point of the first target point cloud is converted to the welding robot base coordinate system to obtain the second target point cloud. The positional relationship between the welding robot and the point cloud camera is obtained according to the automatic positioning function of the point cloud camera.

[0104] The acquired second target point cloud is denoised, that is, based on the already formed second target point cloud, the coordinate information with a large deviation from the second target point cloud is identified, and the materialized image of the coordinate information is removed. In order to reduce the amount of calculation for the secondary registration, the point cloud density of the denoised second target point cloud is reduced to obtain the target point cloud.

[0105] In step S222, the source point cloud and the target point cloud obtained above are registered. The so-called registration means that the two point clouds have corresponding point pairs that meet the iteration exit condition after rotation and translation, that is, they can overlap with each other through position transformations such as rotation and translation. Point cloud registration is to find out the coordinate position transformation relationship between the two point clouds. In this embodiment, the coordinate position transformation relationship between the source point cloud in the digital-analog space coordinate system and the target point cloud in the welding robot base coordinate system is obtained, that is, a rough mapping relationship between the two is obtained.

[0106] In step S230, when the welding robot uses the point cloud camera to collect sampling point data of the workpiece, the positional relationship between the welding robot's photographing position and the workpiece is obtained. According to the rough mapping relationship, the virtual photographing position of the workpiece digital model in the digital model space can be obtained. The positional relationship between the workpiece digital model and the virtual photographing position in the digital model space is the same as the positional relationship between the welding robot's photographing position and the workpiece.

[0107] See also Figure 6 , Figure 6 A flowchart is shown of reconstructing a virtual point cloud camera's virtual photographing position relative to a source point cloud according to a rough mapping relationship between a source point cloud and a target point cloud according to an embodiment of the present application. The embodiment of the present application provides a step S230 of reconstructing a virtual point cloud camera's virtual photographing position relative to a source point cloud according to a rough mapping relationship between a source point cloud and a target point cloud, including:

[0108] Step S231, according to the positional relationship between the point cloud camera and the target point cloud of the workpiece, obtaining the positional relationship between the welding robot's photographing position and the workpiece in the welding robot's base coordinate system;

[0109] Step S232, the positional relationship between the welding robot's photographing position and the workpiece is converted according to a rough mapping relationship to obtain the workpiece digital model and its corresponding virtual photographing position.

[0110] These two steps are described in detail below.

[0111] In step S231, when the point cloud camera collects the coordinate information of the sampling points of the workpiece, the position relationship of the point cloud camera relative to the workpiece is obtained, and then the position relationship between the workpiece and the point cloud camera in the welding robot coordinate system is obtained based on the position relationship between the point cloud camera and the workpiece, and the obtained coordinate information of the workpiece and the point cloud camera in the welding robot base coordinate system.

[0112] In step S232, a virtual photographing position corresponding to the photographing position of the point cloud camera in the real space is obtained in the digital-analog space according to a rough mapping relationship. The coordinate relationship between the virtual photographing position and the digital-analog position of the workpiece in the digital-analog space coordinate system is the same as the position relationship between the workpiece and the point cloud camera in the base coordinate system of the welding robot.

[0113] In step S240, at the virtual photographing position, the workpiece digital model is virtually photographed to obtain a virtual source point cloud at this position. The virtual source point cloud is different from the source point cloud. The virtual source point cloud has not been subjected to thickness removal, and the shape and posture of the workpiece digital model are restored to the greatest extent. The point cloud derived from the workpiece digital model, i.e., the virtual source point cloud, is reacquired in order to re-register with the target point cloud for the second time, so as to eliminate the error caused by the first registration. Because the positional relationship between the workpiece digital model and the virtual photographing position in the digital model space is the same as the positional relationship between the welding robot photographing position and the workpiece, the posture of the obtained virtual source point cloud is very similar to that of the target point cloud, which greatly reduces the amount of calculation during registration.

[0114] In step S250, the virtual source point cloud is realigned with the target point cloud to obtain an accurate mapping relationship between the digital-analog space coordinate system and the welding robot base coordinate system, so that the position of the virtual robot in the digital-analog space can be found more accurately in the following steps.

[0115] In step S260, the position of the virtual robot in the digital model space is found according to the acquired precise mapping relationship, so that the position relationship between the virtual robot and the workpiece digital model in the digital model space is consistent with the position relationship between the welding robot and the workpiece, thereby realizing the positioning of the workpiece digital model in the digital model space.

[0116] See also Figure 7 , Figure 7 A flowchart is shown of performing virtual source point cloud positioning in a virtual robot base coordinate system according to an accurate mapping relationship between a virtual source point cloud and a target point cloud according to an embodiment of the present application. The embodiment of the present application provides a step S260 of performing virtual source point cloud positioning in a virtual robot base coordinate system according to an accurate mapping relationship between the virtual source point cloud and the target point cloud, including:

[0117] Step S261, based on the precise mapping relationship between the virtual source point cloud and the target point cloud and the position of the welding robot, reconstruct the position of the virtual robot relative to the virtual source point cloud to obtain the positional relationship between the virtual robot and the virtual source point cloud;

[0118] Step S262, according to the positional relationship between the virtual robot and the virtual source point cloud, complete the positioning of the virtual source point cloud in the virtual robot base coordinate system.

[0119] The two steps are described in detail below.

[0120] In step S261, the virtual robot position corresponding to the workpiece digital model is obtained based on the precise mapping relationship between the virtual source point cloud and the target point cloud, and the position relationship between the workpiece and the welding robot. The position relationship between the virtual robot and the workpiece digital model is the same as the position relationship between the workpiece and the welding robot.

[0121] In step S262, based on the positional relationship between the virtual robot and the virtual source point cloud, the coordinates of the virtual robot in the digital-analog space base coordinate system are obtained, thereby completing the positioning of the virtual source point cloud in the digital-analog space.

[0122] In the digital model space, a virtual robot and a virtual source point cloud with the same positional relationship and size as the welding robot and the workpiece in the real space are mapped, and the positioning of the virtual source point cloud in the digital model space is realized.

[0123] The following takes the actual automatic positioning of the workpiece as an example to illustrate the process of achieving automatic positioning of the workpiece.

[0124] The first step is to obtain the source point cloud and target point cloud for the first registration.

[0125] Get a digital model that is consistent with the size of the workpiece, called the workpiece digital model, and get the workpiece digital model file based on the workpiece digital model. Extract the shell file of the workpiece digital model from the workpiece digital model file, and then extract the surface layer file of the workpiece digital model from the shell file. Convert the surface layer file into a point cloud format to obtain the surface layer of the workpiece digital model in the form of a point cloud, obtain the corresponding point cloud, remove the thickness of the point cloud, and obtain the source point cloud corresponding to the workpiece digital model.

[0126] The welding robot drives the infrared camera to take pictures of the workpiece, collects the coordinate information of the sampling points on the workpiece, and obtains the first target point cloud. The coordinate information obtained at this time belongs to the point cloud camera coordinate system. According to the automatic positioning function of the point cloud camera, the coordinate information in the point cloud camera coordinate system is converted to the second target point cloud in the welding robot base coordinate system. The second target point cloud is denoised and the thickness of the second target point cloud is removed to obtain the target point cloud.

[0127] The obtained target point cloud is registered with the source point cloud to obtain a rough mapping relationship between the two.

[0128] According to the rough mapping relationship between the two, as well as the positional relationship between the point cloud camera shooting position and the workpiece, the virtual shooting position corresponding to the source point cloud in the digital model space is obtained, and the workpiece digital model is virtually photographed at the virtual shooting position to obtain the virtual source point cloud of the workpiece digital model.

[0129] The virtual source point cloud is registered with the target point cloud to obtain the precise mapping relationship between the two. Based on the precise mapping relationship and the positional relationship between the welding robot and the workpiece, the virtual robot position corresponding to the workpiece digital model in the digital model space is obtained. The positional relationship between the virtual robot and the workpiece digital model is the same as the positional relationship between the workpiece and the welding robot.

[0130] According to the positional relationship between the virtual robot and the virtual source point cloud, the coordinates of the virtual robot in the digital-analog space base coordinate system are obtained to complete the positioning of the virtual source point cloud in the digital-analog space.

[0131] In the digital model space, a virtual robot and a virtual source point cloud are built, which are consistent with the position relationship and size of the welding robot and the workpiece in the real space, so as to realize the positioning of the virtual source point cloud in the digital model space.

[0132] The automatic workpiece positioning method according to the embodiment of the present disclosure can be Figure 8 The welding robot is used to achieve this. Figure 8 To describe a welding robot or according to an embodiment of the present disclosure. Figure 8 The welding robot shown is merely an example and should not bring any limitation to the functions and scope of use of the embodiments of the present disclosure.

[0133] like Figure 8 As shown, the welding robot may be represented in the form of a general computing device. The components of the welding robot may include, but are not limited to: the at least one processing unit 810, the at least one storage unit 820, and a bus 830 connecting different system components (including the storage unit 820 and the processing unit 810).

[0134] The storage unit stores program codes, which can be executed by the processing unit 810, so that the processing unit 810 performs the steps according to various exemplary embodiments of the present invention described in the description of the exemplary method described above in this specification. For example, the processing unit 810 can perform the following steps: Figure 2 The steps shown in .

[0135] The storage unit 820 may include a readable medium in the form of a volatile storage unit, such as a random access memory unit (RAM) 8201 and / or a cache memory unit 8202 , and may further include a read-only memory unit (ROM) 8203 .

[0136] The storage unit 820 may also include a program / utility 8204 having a set (at least one) of program modules 8205, such program modules 8205 including but not limited to: an operating system, one or more application programs, other program modules, and program data, each of which or some combination may include an implementation of a network environment.

[0137] Bus 830 may represent one or more of several types of bus structures, including a memory unit bus or memory unit controller, a peripheral bus, an accelerated graphics port, a processing unit, or a local bus using any of a variety of bus architectures.

[0138] The welding robot can also communicate with one or more external devices 700 (e.g., keyboards, pointing devices, Bluetooth devices, etc.), and can also communicate with one or more devices that enable a user to interact with the welding robot, and / or communicate with any device that enables the welding robot to communicate with one or more other computing devices (e.g., routers, modems, etc.). Such communication can be performed through an input / output (I / O) interface 850. In addition, the welding robot can also communicate with one or more networks (e.g., a local area network (LAN), a wide area network (WAN), and / or a public network, such as the Internet) through a network adapter 860. As shown, the network adapter 860 communicates with other modules of the point cloud camera 12 through a bus 830. It should be understood that, although not shown in the figure, other hardware and / or software modules can be used in conjunction with the welding robot, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data backup storage systems.

[0139] Through the description of the above implementation, it is easy for those skilled in the art to understand that the example implementation described here can be implemented by software, or by software combined with necessary hardware. Therefore, the technical solution according to the implementation of the present disclosure can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (which can be a CD-ROM, a USB flash drive, a mobile hard disk, etc.) or on a network, including several instructions to enable a computing device (which can be a personal computer, a server, a terminal device, or a network device, etc.) to execute the method according to the implementation of the present disclosure.

[0140] In an exemplary embodiment of the present disclosure, a computer program medium is further provided, on which computer-readable instructions are stored. When the computer-readable instructions are executed by a processor of a computer, the computer is enabled to execute the method described in the above method embodiment.

[0141] According to one embodiment of the present disclosure, a program product for implementing the method in the above method embodiment is also provided, which can adopt a portable compact disk read-only memory (CD-ROM) and include program code, and can be run on a terminal device, such as a personal computer. However, the program product of the present invention is not limited thereto, and in this document, a readable storage medium can be any tangible medium containing or storing a program, which can be used by or in combination with an instruction execution system, an apparatus or a device.

[0142] The program product may use any combination of one or more readable media. The readable medium may be a readable signal medium or a readable storage medium. The readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples (non-exhaustive list) of readable storage media include: an electrical connection with one or more wires, a portable disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above.

[0143] Computer readable signal media may include data signals propagated in baseband or as part of a carrier wave, in which readable program code is carried. Such propagated data signals may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. Readable signal media may also be any readable medium other than a readable storage medium, which may send, propagate, or transmit a program for use by or in conjunction with an instruction execution system, apparatus, or device.

[0144] The program code embodied on the readable medium may be transmitted using any appropriate medium, including but not limited to wireless, wired, optical cable, RF, etc., or any suitable combination of the foregoing.

[0145] Program code for performing the operations of the present invention may be written in any combination of one or more programming languages, including object-oriented programming languages ​​such as Java, C++, etc., and conventional procedural programming languages ​​such as "C" or similar programming languages. The program code may be executed entirely on the user computing device, partially on the user device, as a separate software package, partially on the user computing device and partially on a remote computing device, or entirely on a remote computing device or server. In cases involving a remote computing device, the remote computing device may be connected to the user computing device through any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computing device (e.g., through the Internet using an Internet service provider).

[0146] It should be noted that, although several modules or units of the device for action execution are mentioned in the above detailed description, this division is not mandatory. In fact, according to the embodiments of the present disclosure, the features and functions of two or more modules or units described above can be embodied in one module or unit. On the contrary, the features and functions of one module or unit described above can be further divided into multiple modules or units to be embodied.

[0147] In addition, although the steps of the method in the present disclosure are described in a specific order in the drawings, this does not require or imply that the steps must be performed in this specific order, or that all the steps shown must be performed to achieve the desired results. Additionally or alternatively, some steps may be omitted, multiple steps may be combined into one step, and / or one step may be decomposed into multiple steps, etc.

[0148] Through the description of the above implementation, it is easy for those skilled in the art to understand that the example implementation described here can be implemented by software, or by software combined with necessary hardware. Therefore, the technical solution according to the implementation of the present disclosure can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (which can be a CD-ROM, a USB flash drive, a mobile hard disk, etc.) or on a network, including several instructions to enable a computing device (which can be a personal computer, a server, a mobile terminal, or a network device, etc.) to execute the method according to the implementation of the present disclosure.

[0149] Those skilled in the art will readily appreciate other embodiments of the present disclosure after considering the specification and practicing the invention disclosed herein. This application is intended to cover any modification, use or adaptation of the present disclosure, which follows the general principles of the present disclosure and includes common knowledge or customary techniques in the art that are not disclosed in the present disclosure. The specification and examples are intended to be exemplary only, and the true scope and spirit of the present disclosure are indicated by the appended claims.

Claims

1. A method for automatic workpiece positioning, It is characterized in that The method comprises: Acquire a source point cloud of the workpiece digital model according to the surface layer of the workpiece digital model, wherein the source point cloud is used to express the surface of the workpiece digital model after removing the thickness; Registering the target point cloud mapped by the workpiece according to the source point cloud to obtain a rough mapping relationship between the source point cloud and the target point cloud; Reconstructing the virtual point cloud camera's virtual photo taking position relative to the source point cloud based on the rough mapping relationship between the source point cloud and the target point cloud; Taking a virtual photograph of the workpiece digital model at a virtual photographing position to obtain a virtual source point cloud; Re-registering the virtual source point cloud with the target point cloud to obtain an accurate mapping relationship between the virtual source point cloud and the target point cloud formed by the workpiece digital model; According to the precise mapping relationship between the virtual source point cloud and the target point cloud, the virtual source point cloud positioning in the virtual robot base coordinate system is performed.

2. The method according to claim 1, It is characterized in that The step of obtaining a source point cloud of the workpiece digital model according to the surface layer of the workpiece digital model comprises: Obtain a shell file according to the workpiece digital model, and extract a surface layer file from the shell file; Converting the format of the surface layer file into a point cloud format; The thickness of the surface layer point cloud model is removed to obtain the source point cloud of the workpiece digital model.

3. The method according to claim 1, It is characterized in that The target point cloud mapped to the workpiece is registered according to the source point cloud to obtain a rough mapping relationship between the source point cloud and the target point cloud, including: Obtain the target point cloud by taking pictures of the workpiece; The source point cloud and the target point cloud are registered to obtain a rough mapping relationship between the source point cloud and the target point cloud, and one of the source point cloud or the target point cloud can be rotated and translated according to the rough mapping relationship to coincide with the position of the other.

4. The method according to claim 3, It is characterized in that The step of obtaining a target point cloud by photographing the workpiece includes: The welding robot is driven to take a picture of the workpiece to obtain a first target point cloud of the workpiece in a point cloud camera coordinate system; According to the positional relationship between the welding robot and the point cloud camera, the first target point cloud is calculated to obtain a second target point cloud of the workpiece in the base coordinate system of the welding robot.

5. The method according to claim 4, It is characterized in that The method of obtaining a target point cloud by photographing the workpiece further includes: The second target point cloud is denoised to reduce density to obtain a target point cloud.

6. The method according to claim 1, It is characterized in that The step of reconstructing a virtual photographing position of the virtual point cloud camera relative to the source point cloud according to a rough mapping relationship between the source point cloud and the target point cloud comprises: According to the positional relationship between the point cloud camera and the target point cloud of the workpiece, the positional relationship between the welding robot's photographing position and the workpiece in the welding robot's base coordinate system is obtained; The positional relationship between the photographing position of the welding robot and the workpiece is converted according to the rough mapping relationship to obtain the digital model of the workpiece and its corresponding virtual photographing position.

7. The method according to claim 1, It is characterized in that The performing of positioning of the virtual source point cloud in the virtual robot base coordinate system according to the precise mapping relationship between the virtual source point cloud and the target point cloud comprises: According to the precise mapping relationship between the virtual source point cloud and the target point cloud and the position of the welding robot, the position of the virtual robot relative to the virtual source point cloud is reconstructed to obtain the positional relationship between the virtual robot and the virtual source point cloud; According to the positional relationship between the virtual robot and the virtual source point cloud, the virtual source point cloud is positioned in the virtual robot base coordinate system.

8. An automatic workpiece positioning device, It is characterized in that The device comprises: Point cloud acquisition module: acquires the source point cloud of the workpiece digital model according to the surface layer of the workpiece digital model, and the source point cloud is used to express the surface of the workpiece digital model after removing the thickness; Registration module: registers the target point cloud mapped by the workpiece according to the source point cloud to obtain a rough mapping relationship between the source point cloud and the target point cloud; Positioning module: Based on the rough mapping relationship between the source point cloud and the target point cloud, the virtual point cloud camera's virtual shooting position relative to the source point cloud is reconstructed. Photo module: take a virtual photo of the workpiece digital model at a virtual photo position to obtain a virtual source point cloud; The second registration module is used to re-register the virtual source point cloud and the target point cloud to obtain an accurate mapping relationship between the virtual source point cloud and the target point cloud formed by the workpiece digital model; The second positioning module: performs virtual source point cloud positioning in the virtual robot base coordinate system according to the precise mapping relationship between the virtual source point cloud and the target point cloud.

9. The device according to claim 8, It is characterized in that The point cloud acquisition module includes: Extraction module: obtain the shell file according to the workpiece digital model, and extract the surface layer file from the shell file; Conversion module: converting the format of the surface layer file into a point cloud format; Thickness removal module: removes the thickness of the surface layer point cloud model to obtain the source point cloud of the workpiece digital model.

10. An automatic workpiece positioning device, It is characterized in that include: A welding robot, a robotic arm, a point cloud camera, a memory, and a processor. The welding robot moves the point cloud camera at the end of the robotic arm through the robotic arm connected thereto. The welding robot and the point cloud camera realize automatic positioning of the workpiece. The memory is used to store instructions readable by a mobile terminal. The processor connected to the memory by electrical signals reads the welding robot readable instructions stored in the memory to execute the method described in any one of claims 1-7.

Citation Information

Patent Citations

  • Cloud-based three-dimensional map generation method, device, equipment and application

    CN108230247A

  • Robot welding assembly method and system based on 2D / 3D visual positioning

    CN112743270A