Data processing method and apparatus, terminal, and medium
By generating basic rays in the point cloud format model and filtering them as feature points, the point cloud format model is optimized, solving the two-layer structure problem in the point cloud registration process and improving the accuracy of intelligent automated operations.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- 深圳前海瑞集科技有限公司
- Filing Date
- 2022-08-31
- Publication Date
- 2026-05-29
AI Technical Summary
In existing technologies, the point cloud format model generated by converting STL files presents a two-layer structure, which greatly hinders the point cloud registration process and affects the accuracy of intelligent automated operations.
By connecting a preset base point with multiple base points to generate a basic ray, calculating the included angle and classifying it as a target ray, setting a filtering model on the extended trajectory of the target ray, filtering the base points into feature points, and finally generating target point cloud data, the point cloud format model is optimized.
It effectively reduces the technical difficulty of the registration process in intelligent automated operations, making the point cloud format model close to the point cloud obtained from real photographs, and improving the accuracy of the registration process.
Smart Images

Figure CN115409732B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of industrial production technology, and in particular to a data processing method, apparatus, terminal, and medium. Background Technology
[0002] Currently, intelligent automation is an essential means to address the shortage of skilled workers in industrial production and to achieve overall upgrading in the field of intelligent manufacturing. Based on this, a commonly used intelligent approach is based on digital twin technology. This involves registering a digital workpiece model generated in a virtual environment with a real workpiece, then digitally simulating the work process in the virtual environment based on the digital workpiece model, and finally controlling the workpiece to perform operations in the real environment based on the results of the digital simulation.
[0003] In the implementation of the aforementioned intelligent automated operations, the industry typically uses point cloud registration to register the digital workpiece model with the actual workpiece, that is, registering the STL format workpiece in the digital model environment with the actual acquired workpiece point cloud format. However, due to the limitations of the STL file format, the point cloud format model generated by converting the STL file will have a two-layer structure, that is, point clouds will be generated on both sides of the point cloud format model. This greatly hinders the registration process and thus seriously affects the accuracy of intelligent automated operations in industrial production.
[0004] Therefore, how to optimize the point cloud format model with a two-layer structure to reduce the technical difficulty of the registration process in intelligent automated operations is a problem that urgently needs to be solved in the field of industrial production. Summary of the Invention
[0005] The main objective of this invention is to provide a data processing method, system, terminal, and medium, which aims to optimize a point cloud format model with a two-layer structure through data processing, making it closer to the point cloud obtained by real photography, thereby reducing the technical difficulty of the registration process in intelligent automated operations.
[0006] According to one aspect of the embodiments of this application, a data processing method is disclosed, including:
[0007] Multiple basic rays are generated by connecting a preset base point with multiple base points, and the base points are included in the base point cloud data used to reflect the preset model.
[0008] Calculate the angle between each pair of the multiple basic rays. If the angle is less than or equal to a preset angle threshold, then classify the two basic rays corresponding to the angle into one target ray.
[0009] Multiple filter models are set on the extended trajectory of the target ray to filter the base points contained within the multiple filter models;
[0010] The basic points contained in the multiple filtering models are recorded as multiple feature points, wherein one filtering model corresponds to one feature point;
[0011] The multiple feature points are combined to generate target point cloud data, which is point cloud data obtained after filtering the basic point cloud data.
[0012] In some embodiments of this application, based on the above technical solutions, before classifying the two basic rays corresponding to the included angle into one target ray if the included angle is less than or equal to a preset angle threshold, the data processing method further includes:
[0013] Detect the number of the base points and the spatial volume of the base point distribution;
[0014] The first point cloud density level of the basic point cloud data is calculated based on the number of basic points and the spatial volume.
[0015] The preset angle threshold is determined based on the first point cloud density level, and the first point cloud density level is negatively correlated with the preset angle threshold.
[0016] In some embodiments of this application, based on the above technical solutions, before classifying the two basic rays corresponding to the included angle into one target ray if the included angle is less than or equal to a preset angle threshold, the data processing method further includes:
[0017] The space of the coordinate system containing the basic point cloud data is divided into multiple preset regions;
[0018] The second point cloud density level of the preset area is obtained based on the number of basic rays within the preset area;
[0019] The preset angle threshold is determined based on the second point cloud density level, and the second point cloud density level is negatively correlated with the preset angle threshold.
[0020] In some embodiments of this application, based on the above technical solutions, multiple filtering models are set on the extended trajectory of the target ray, including:
[0021] The model step size is set according to user instructions, and the model step size is used to determine the size of the filtering model;
[0022] The multiple filtering models are set on the extended trajectory of the target ray according to the model step size.
[0023] In some embodiments of this application, based on the above technical solutions, multiple filtering models are set on the extended trajectory of the target ray, including:
[0024] Obtain the distance between the base point position and the preset base point included in the extended trajectory of the target ray;
[0025] The model step size is determined based on the distance, and the distance and the model step size are negatively correlated.
[0026] The multiple filtering models are set on the extended trajectory of the target ray according to the model step size.
[0027] In some embodiments of this application, based on the above technical solutions, multiple filtering models are set on the extended trajectory of the target ray, including:
[0028] Obtain the distance between the base point position and the preset base point included in the extended trajectory of the target ray;
[0029] The model step size is determined based on the distance, and the distance and the model step size are negatively correlated.
[0030] The multiple filtering models are set on the extended trajectory of the target ray according to the model step size.
[0031] In some embodiments of this application, based on the above technical solutions, before recording the basic points contained in the plurality of filtering models as plurality of feature points, the data processing method further includes:
[0032] Detect whether the filtering model contains at least one basic point;
[0033] If the filtering model contains at least one base point, then the center point of the filtering model is recorded as a single feature point.
[0034] In some embodiments of this application, based on the above technical solutions, after combining the plurality of feature points to generate target point cloud data, the data processing method further includes:
[0035] The target point cloud data and the workpiece point cloud data are registered using a point cloud registration algorithm to obtain the registration result;
[0036] The correspondence between the simulated coordinate system and the operational coordinate system is determined based on the registration results. The simulated coordinate system is the coordinate system corresponding to the target point cloud data in the digital twin environment, and the operational coordinate system is the coordinate system corresponding to the mechanical equipment in actual operation.
[0037] The simulated job process is generated within the digital twin environment;
[0038] The mechanical equipment is controlled to perform operations based on the simulated operation process and the corresponding relationship.
[0039] According to one aspect of the embodiments of this application, a data processing apparatus is disclosed, the data processing apparatus comprising:
[0040] The connection module is configured to connect a preset base point with multiple base points to generate multiple basic rays, wherein the base points are included in the basic point cloud data used to reflect the preset model;
[0041] The classification module is configured to calculate the angle between each pair of the multiple basic rays. If the angle is less than or equal to a preset angle threshold, the two basic rays corresponding to the angle are classified as a target ray.
[0042] The setting module is configured to set multiple filter models on the extended trajectory of the target ray to filter the base points contained within the multiple filter models.
[0043] The recording module is configured to record the basic points contained in the multiple filtering models as multiple feature points, wherein one filtering model corresponds to one feature point;
[0044] The generation module is configured to combine the multiple feature points to generate target point cloud data, wherein the target point cloud data is point cloud data obtained by filtering the basic point cloud data.
[0045] According to one aspect of the embodiments of this application, a computer program product or computer program is provided, which includes computer instructions stored in a computer-readable storage medium. A processor of a computer device reads the computer instructions from the computer-readable storage medium and executes the computer instructions, causing the computer device to perform the data processing method as described in the above technical solutions.
[0046] The data processing method provided in this application first selects a base point in the coordinate system corresponding to the basic point cloud data converted from the STL file. This base point is used to simulate the shooting point when acquiring point cloud data by taking pictures. The base point is connected with multiple base points contained in the workpiece model to generate multiple basic rays. That is, all base points are traversed through the above basic rays. Then, the basic rays are classified to obtain target rays. By classification, redundant basic rays can be filtered out. Next, multiple filtering models are set on the extension trajectory of the target rays, and multiple base points contained in each filtering model are recorded and replaced with a single feature point. Thus, multiple base points are filtered according to each filtering model. Finally, all feature points recorded by the filtering models are combined to generate target point cloud data. That is, the target point cloud data is the optimized result obtained after filtering the basic point cloud data. At this time, the target point cloud data has filtered out some duplicate point clouds compared with the original basic point cloud data. Therefore, it no longer presents a two-layer structure, which can effectively reduce the technical difficulty of the registration process in subsequent intelligent automated operations.
[0047] Thus, the data processing method provided in this application can optimize the point cloud format model with a two-layer structure with relatively low operational difficulty, making it close to the point cloud obtained by real photography, thereby reducing the technical difficulty of the registration process in intelligent automated operations.
[0048] It should be understood that the above general description and the following detailed description are merely exemplary and do not limit this application. Attached Figure Description
[0049] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this application and, together with the description, serve to explain the principles of this application. It is obvious that the drawings described below are merely some embodiments of this application, and those skilled in the art can obtain other drawings based on these drawings without any inventive effort.
[0050] Figure 1 A flowchart illustrating the steps of a data processing method according to one embodiment of this application is shown.
[0051] Figure 2 This illustration shows the effect of basic point cloud data in one embodiment of this application.
[0052] Figure 3 This illustration shows a schematic diagram of the effect of target point cloud data in one embodiment of this application.
[0053] Figure 4 A flowchart illustrating the steps of recording the center point of the filtering model as a feature point in one embodiment of this application is shown.
[0054] Figure 5 A schematic block diagram of the data processing apparatus provided in an embodiment of this application is shown.
[0055] Figure 6 A schematic diagram of a computer system architecture suitable for implementing the embodiments of this application is shown. Detailed Implementation
[0056] Exemplary embodiments will now be described more fully with reference to the accompanying drawings. However, these exemplary embodiments can be implemented in many forms and should not be construed as limited to the examples set forth herein; rather, these embodiments are provided to make this application more comprehensive and complete, and to fully convey the concept of the exemplary embodiments to those skilled in the art.
[0057] Furthermore, the described features, structures, or characteristics can be combined in any suitable manner in one or more embodiments. Numerous specific details are provided in the following description to give a thorough understanding of embodiments of this application. However, those skilled in the art will recognize that the technical solutions of this application can be practiced without one or more of the specific details, or other methods, components, apparatuses, steps, etc., can be employed. In other instances, well-known methods, apparatuses, implementations, or operations are not shown or described in detail to avoid obscuring various aspects of this application.
[0058] The block diagrams shown in the accompanying drawings are merely functional entities and do not necessarily correspond to physically independent entities. That is, these functional entities can be implemented in software, in one or more hardware modules or integrated circuits, or in different network and / or processor devices and / or microcontroller devices.
[0059] The flowcharts shown in the accompanying drawings are merely illustrative and do not necessarily include all content and operations / steps, nor do they necessarily need to be performed in the described order. For example, some operations / steps can be broken down, while others can be combined or partially combined; therefore, the actual execution order may change depending on the specific circumstances.
[0060] The following detailed description of the data processing methods, apparatus, terminals, and media provided in this application, in conjunction with specific embodiments, provides a detailed explanation.
[0061] Figure 1 A flowchart illustrating the steps of a data processing method in one embodiment of this application is shown, as follows: Figure 1 As shown, the data processing method mainly includes the following steps S100 to S500.
[0062] Step S100: Connect the preset base point with multiple base points to generate multiple basic rays. The base points are included in the base point cloud data used to reflect the preset model.
[0063] Step S200: Calculate the angle between each pair of the multiple basic rays. If the angle is less than or equal to a preset angle threshold, then classify the two basic rays corresponding to the angle into one target ray.
[0064] Step S300: Set multiple filter models on the extended trajectory of the target ray to filter the base points contained in the multiple filter models.
[0065] Step S400: Record the basic points contained in the multiple filtering models as multiple feature points, wherein one filtering model corresponds to one feature point.
[0066] Step S500: Combine the multiple feature points to generate target point cloud data, wherein the target point cloud data is point cloud data obtained after filtering the basic point cloud data.
[0067] The data processing method provided in this application first selects a base point in the coordinate system corresponding to the basic point cloud data converted from the STL file. This base point is used to simulate the shooting point when acquiring point cloud data by taking pictures. The base point is connected with multiple base points contained in the workpiece model to generate multiple basic rays. That is, all base points are traversed through the above basic rays. Then, the basic rays are classified to obtain target rays. By classification, redundant basic rays can be filtered out. Next, multiple filtering models are set on the extension trajectory of the target rays, and multiple base points contained in each filtering model are recorded and replaced with a single feature point. Thus, multiple base points are filtered according to each filtering model. Finally, all feature points recorded by the filtering models are combined to generate target point cloud data. That is, the target point cloud data is the optimized result obtained after filtering the basic point cloud data. At this time, the target point cloud data has filtered out some duplicate point clouds compared with the original basic point cloud data. Therefore, it no longer presents a two-layer structure, which can effectively reduce the technical difficulty of the registration process in subsequent intelligent automated operations.
[0068] Thus, the data processing method provided in this application can optimize the point cloud format model with a two-layer structure with relatively low operational difficulty, making it close to the point cloud obtained by real photography, thereby reducing the technical difficulty of the registration process in intelligent automated operations.
[0069] The following sections will provide a detailed explanation of each step in the data processing method.
[0070] Step S100: Connect the preset base point with multiple base points to generate multiple basic rays. The base points are included in the base point cloud data used to reflect the preset model.
[0071] Specifically, first, the file information stored in the software's STL format is converted into a readable file. Then, the coordinate information of the triangular grid points corresponding to the triangular mesh in the STL format file is found, i.e., the coordinate information in the 3D coordinate xyz format. This coordinate information is then output to obtain a standard point cloud PCD format file. This output standard point cloud PCD format file contains the basic point cloud data that needs to be optimized, such as... Figure 2 The base point cloud model shown is unfiltered and unoptimized point cloud data, which is used to reflect a preset model, such as the shape of a workpiece. Then, a base point is set in the coordinate system of the standard point cloud PCD format file. This base point is used to simulate the image point in the photographed point cloud. Finally, this base point is connected to all the base points contained in the base point cloud data to generate multiple basic rays, that is, the basic rays traverse all the base points in the base point cloud data.
[0072] Step S200: Calculate the angle between each pair of the multiple basic rays. If the angle is less than or equal to a preset angle threshold, then classify the two basic rays corresponding to the angle into one target ray.
[0073] Specifically, after obtaining multiple basic rays by connecting the base point and the foundation point, the angle between each pair of basic rays is calculated, all basic rays are traversed, and two basic rays with an angle less than or equal to a preset angle threshold are classified as a target ray, thereby greatly reducing the number of redundant basic rays.
[0074] For example, assuming the angle threshold is 0.01 radians, basic rays are selected sequentially in the coordinate system. Any other basic rays whose angle with the selected basic ray is less than 0.01 radians are classified as the same target ray. The base points involved in the above-mentioned classified basic rays are also regarded as one type of point. The basic rays after classification are no longer included in the selection range. Then, basic rays are selected from the unclassified basic rays for classification.
[0075] Step S300: Set multiple filter models on the extension trajectory of the basic ray to filter the basic points contained in the multiple filter models.
[0076] Specifically, after classifying the basic rays to obtain the target rays, multiple filtering models are set on the extension trajectory of each target ray. The filtering models can adopt geometric shapes such as cubes, rectangles, and rhombuses. Since each target ray has multiple filtering models, the filtering models can include all basic points covering the basic point cloud data.
[0077] Step S400: Record the basic points contained in the multiple filtering models as multiple feature points, wherein one filtering model corresponds to one feature point.
[0078] Specifically, after setting multiple filtering models for the extended trajectory of the target ray, each filtering model contains multiple non-repeating base points. The multiple base points contained in a single filtering model are replaced by a single feature point, which can significantly reduce the number of redundant feature points and optimize the filtering of point cloud data.
[0079] Step S500: Combine the multiple feature points to generate target point cloud data, wherein the target point cloud data is point cloud data obtained after filtering the basic point cloud data.
[0080] Specifically, the feature points obtained through the filtering model are combined to generate target point cloud data, and the original basic point data records are eliminated. The resulting target point cloud data is the result of filtering and optimizing the basic point cloud data, as shown below. Figure 3 The target point cloud data shown is for Figure 2 The result after filtering and optimizing the basic point cloud data.
[0081] Furthermore, in a feasible embodiment, before classifying the two basic rays corresponding to the included angle into one target ray if the included angle is less than or equal to a preset angle threshold in step S200 above, the data processing method further includes the following steps S201 to S203.
[0082] Step S201: Detect the number of the base points and the spatial volume of the base point distribution.
[0083] Specifically, the software detects the number of base points contained in the coordinate system of the aforementioned standard point cloud PCD format file, as well as the spatial volume corresponding to the distribution of these base points.
[0084] Step S202: Calculate the first point cloud density level of the basic point cloud data based on the number of basic points and the spatial volume.
[0085] Specifically, after detecting the number of base points and the spatial volume of the base point distribution, the first point cloud density can be calculated by dividing the number by the spatial volume. Then, the first point cloud density is classified according to the preset database to determine the first point cloud density level.
[0086] Step S203: Determine the preset angle threshold based on the first point cloud density level, wherein the first point cloud density level and the preset angle threshold are negatively correlated.
[0087] Specifically, the higher the density level of the first point cloud, that is, the denser the base points contained in the coordinate system of the aforementioned standard point cloud PCD format file, the smaller the preset angle threshold used to classify basic rays. In other words, the fewer basic rays are classified as the same target ray, so as to avoid erroneously deleting important features of the preset model during the classification process. Conversely, the lower the density level of the first point cloud, that is, the sparser the base points contained in the coordinate system of the aforementioned standard point cloud PCD format file, the larger the preset angle threshold used to classify basic rays, thereby reducing computational costs in the process of reducing redundant basic rays through classification.
[0088] Thus, in this embodiment, the first point cloud density level is determined based on the number of base points and the spatial volume of the data point distribution. Then, the angle threshold for classifying basic rays is determined based on the first point cloud density level, thereby balancing the accuracy of the classification process and the computational cost, and improving the practicality of the data processing method of this application.
[0089] Furthermore, in a feasible embodiment, before classifying the two basic rays corresponding to the included angle into one target ray if the included angle is less than or equal to a preset angle threshold in step S200 above, the data processing method further includes the following steps S204 to S206.
[0090] Step S204: Divide the space of the coordinate system where the basic point cloud data is located into multiple preset regions.
[0091] Specifically, the preset area can be a geometrically shaped area such as a fan-shaped area or a rectangular area, dividing the space of the coordinate system into multiple preset areas.
[0092] As an optional implementation method, a preset base point can be used as the origin of the spatial division.
[0093] Step S205: Obtain the second point cloud density level of the preset area based on the number of basic rays within the preset area.
[0094] Specifically, after dividing the space into multiple preset regions, the number of basic rays in each preset region is detected. Since the basic rays are generated by connecting the base point and the preset base point, the number of basic rays can directly reflect the second point cloud density in the preset region. Then, the second point cloud density is classified according to the preset database to determine the second point cloud density level.
[0095] Step S206: Determine the preset angle threshold based on the second point cloud density level, wherein the second point cloud density level is negatively correlated with the preset angle threshold.
[0096] When the cloud density level of the second point is higher, the base points within the preset area are more concentrated, indicating that the preset area may be used to reflect important features of the preset model. Therefore, the preset angle threshold for classifying basic rays corresponding to the preset area is smaller, that is, the number of basic rays classified as the same target ray is smaller, so as to avoid erroneously deleting important features of the preset model during the classification process. When the cloud density level of the first point is lower, that is, the base points within the preset area are more sparse, the preset angle threshold for classifying basic rays is larger, thereby reducing the computational cost in the process of reducing redundant basic rays through classification.
[0097] Thus, in this embodiment, the coordinate system space is divided into multiple preset regions, and the second point cloud density level is determined based on the number of basic rays within the preset regions. Then, the angle threshold for classifying basic rays is determined based on the second point cloud density level, thereby balancing the accuracy of the classification process and the computational cost, and improving the practicality of the data processing method of this application.
[0098] Furthermore, in a feasible embodiment, multiple filtering models are set on the extension trajectory of the target ray in step S300 above, including steps S301 and S302 as follows.
[0099] Step S301: Set the model step size according to the user instruction. The model step size is used to determine the size of the filtering model.
[0100] Step S302: Set the multiple filtering models on the extension trajectory of the target ray according to the model step size.
[0101] Specifically, the technical solution of this application replaces multiple base points with a single feature point through a filtering model. The volume of the filtering model affects the number of base points contained in a single filtering model and the total number of filtering models, thus ultimately affecting the number of feature points used to combine and generate the target point cloud data. Based on this, an appropriate model step size can be set to determine the volume of the filtering model, thereby balancing the accuracy and computational cost of the base point filtering optimization process. In this embodiment, a general model step size is set according to a user-triggered instruction, and multiple filtering models are set along the extension trajectory of the target ray according to this model step size.
[0102] Furthermore, in a feasible embodiment, multiple filtering models are set on the extension trajectory of the target ray in step S300 above, including steps S303 to S305 below.
[0103] Step S303: Obtain the distance between the base point position and the preset base point included in the extension trajectory of the target ray.
[0104] Step S304: Determine the model step size based on the distance, wherein the distance and the model step size are negatively correlated.
[0105] Step S305: Set the plurality of filter models on the extension trajectory of the target ray according to the model step size.
[0106] This embodiment provides another method for determining the model step size: determining the position of the filtering model based on the location of the base points, and then further determining the model step size based on the distance between the filtering model and the preset base points. Specifically, the positions of the base points on the extension trajectory of the target ray are obtained, and the distances between these base points and the preset base points are determined. Multiple filtering models are sequentially set along the extension trajectory of the target ray, from the direction closest to the preset base points to the direction furthest from them. The model step size used to set the filtering model is smaller the farther it is from the preset base points, meaning the volume of the filtering model farther from the preset base points is smaller, thus reducing the number of base points included in the filtering model and avoiding the erroneous deletion of important features of the preset model during the base point filtering optimization process. Conversely, the model step size used to set the filtering model is larger the closer it is to the preset base points, meaning the volume of the filtering model closer to the preset base points is larger, thus reducing the computational cost of the base point filtering optimization process.
[0107] Furthermore, such as Figure 4 As shown, based on the above embodiments, before recording the basic points contained in the multiple filtering models as multiple feature points in step S400, the data processing method further includes the following steps S401 and S402.
[0108] Step S401: Detect whether the filtering model contains at least one basic point.
[0109] Step S402: If the filtering model contains at least one base point, then the center point of the filtering model is recorded as a single feature point.
[0110] Specifically, after setting multiple filter models on the extended trajectory of the target ray, the filter models are detected in sequence. When a filter model contains at least one base point, the center point of the filter model is recorded as a single feature point, and the data record of the base point contained in the filter model is cleared, thereby avoiding the recording of redundant feature points and ensuring the geometric position of the feature points to accurately reflect the features of the preset model.
[0111] Furthermore, based on the above embodiments, after combining the multiple feature points to generate target point cloud data in step S500, the data processing method further includes the following steps S501 to S504.
[0112] Step S501: The target point cloud data and the workpiece point cloud data are registered using a point cloud registration algorithm to obtain a registration result.
[0113] Step S502: Determine the correspondence between the simulation coordinate system and the operation coordinate system based on the registration result. The simulation coordinate system is the coordinate system corresponding to the target point cloud data in the digital twin environment, and the operation coordinate system is the coordinate system corresponding to the mechanical equipment in actual operation.
[0114] Step S503: Generate a simulated job process in the digital twin environment.
[0115] Step S504: Control the mechanical equipment to perform operations according to the simulated operation process and the corresponding relationship.
[0116] Specifically, the target point cloud data generated based on feature points is registered with the actual collected workpiece point cloud data using a point cloud registration algorithm such as the ICP algorithm to obtain the coordinate system correspondence between the digital twin environment and the actual working environment. Then, a simulation process for controlling mechanical equipment to perform operations is set up in the digital twin environment, such as a simulation process for controlling a robot to weld a workpiece. Based on the above coordinate system correspondence, this simulation process can be mapped to the coordinate system of the actual working environment, thereby controlling the mechanical equipment to perform operations according to the operation process in the actual working environment.
[0117] The following describes an apparatus embodiment of this application, which can be used to execute the data processing method described in the above embodiments of this application. Figure 5 A schematic block diagram of the data processing apparatus provided in an embodiment of this application is shown. Figure 5 As shown, the data processing device includes:
[0118] The connection module is configured to connect a preset base point with multiple base points to generate multiple basic rays, wherein the base points are included in the basic point cloud data used to reflect the preset model;
[0119] The classification module is configured to calculate the angle between each pair of the multiple basic rays. If the angle is less than or equal to a preset angle threshold, the two basic rays corresponding to the angle are classified as a target ray.
[0120] The setting module is configured to set multiple filter models on the extended trajectory of the target ray to filter the base points contained within the multiple filter models.
[0121] The recording module is configured to record the basic points contained in the multiple filtering models as multiple feature points, wherein one filtering model corresponds to one feature point;
[0122] The generation module is configured to combine the multiple feature points to generate target point cloud data, wherein the target point cloud data is point cloud data obtained by filtering the basic point cloud data.
[0123] In one embodiment of this application, based on the above embodiments, the data processing apparatus further includes:
[0124] The first angle threshold determination module is configured to detect the number of the base points and the spatial volume of the base point distribution; and to calculate a first point cloud density level of the base point cloud data based on the number of base points and the spatial volume; and to determine the preset angle threshold based on the first point cloud density level, wherein the first point cloud density level is negatively correlated with the preset angle threshold.
[0125] In one embodiment of this application, based on the above embodiments, the data processing apparatus further includes:
[0126] The second angle threshold determination module is configured to divide the space of the coordinate system where the basic point cloud data is located into multiple preset regions; and to obtain the second point cloud density level of the preset region based on the number of basic rays in the preset region; and to determine the preset angle threshold based on the second point cloud density level, wherein the second point cloud density level is negatively correlated with the preset angle threshold.
[0127] In one embodiment of this application, based on the above embodiments, the data processing apparatus further includes:
[0128] The first model step size determination module is configured to set a model step size according to a user instruction, the model step size being used to determine the size of the filter model; and to set the plurality of filter models on the extension trajectory of the target ray according to the model step size.
[0129] In one embodiment of this application, based on the above embodiments, the data processing apparatus further includes:
[0130] The second model step size determination module is configured to obtain the distance between the base point position contained in the extension trajectory of the target ray and the preset base point; and to determine the model step size based on the distance, wherein the distance and the model step size are negatively correlated; and to set the plurality of filtering models on the extension trajectory of the target ray based on the model step size.
[0131] In one embodiment of this application, based on the above embodiments, the recording module includes:
[0132] The center point recording unit is configured to detect whether the filtering model contains at least one base point; and if the filtering model contains at least one base point, to record the center point of the filtering model as a single feature point.
[0133] In one embodiment of this application, based on the above embodiments, the data processing apparatus further includes:
[0134] The registration module is configured to register the target point cloud data and the workpiece point cloud data using a point cloud registration algorithm to obtain a registration result; and to determine the correspondence between a simulated coordinate system and a working coordinate system based on the registration result, wherein the simulated coordinate system is the coordinate system corresponding to the target point cloud data in the digital twin environment, and the working coordinate system is the coordinate system corresponding to the mechanical equipment in actual operation; and to generate a simulated operation process in the digital twin environment; and to control the mechanical equipment to perform operations based on the simulated operation process and the correspondence.
[0135] Figure 6 A schematic block diagram of a computer system architecture for implementing an electronic device according to embodiments of the present application is shown.
[0136] It should be noted that, Figure 6 The computer system 600 of the electronic device shown is merely an example and should not impose any limitation on the functionality and scope of use of the embodiments of this application.
[0137] like Figure 6 As shown, the computer system 600 includes a central processing unit (CPU) 601, which can perform various appropriate actions and processes based on programs stored in read-only memory (ROM) 602 or programs loaded from storage section 608 into random access memory (RAM). The RAM 603 also stores various programs and data required for system operation. The CPU 601, ROM 602, and RAM 603 are interconnected via a bus 604. An input / output interface 605 (I / O interface) is also connected to the bus 604.
[0138] The following components are connected to the input / output interface 605: an input section 606 including a keyboard, mouse, etc.; an output section 607 including a cathode ray tube (CRT), liquid crystal display (LCD), etc., and speakers, etc.; a storage section 608 including a hard disk, etc.; and a communication section 609 including a network interface card such as a local area network card, modem, etc. The communication section 609 performs communication processing via a network such as the Internet. A drive 610 is also connected to the input / output interface 605 as needed. A removable medium 611, such as a disk, optical disk, magneto-optical disk, semiconductor memory, etc., is installed on the drive 610 as needed so that computer programs read from it can be installed into the storage section 608 as needed.
[0139] Specifically, according to embodiments of this application, the processes described in the various method flowcharts can be implemented as computer software programs. For example, embodiments of this application include a computer program product comprising a computer program carried on a computer-readable medium, the computer program containing program code for performing the methods shown in the flowcharts. In such embodiments, the computer program can be downloaded and installed from a network via communication section 609, and / or installed from removable medium 611. When the computer program is executed by central processing unit 601, it performs various functions defined in the system of this application.
[0140] It should be noted that the computer-readable medium shown in the embodiments of this application can be a computer-readable signal medium, a computer-readable storage medium, or any combination of the two. A computer-readable storage medium can be, for example,—but not limited to—an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination thereof. More specific examples of a computer-readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer disk, a hard disk, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM), flash memory, optical fiber, portable compact disc read-only memory (CD-ROM), optical storage device, magnetic storage device, or any suitable combination thereof. In this application, a computer-readable storage medium can be any tangible medium containing or storing a program that can be used by or in conjunction with an instruction execution system, apparatus, or device. In this application, a computer-readable signal medium can include a data signal propagated in baseband or as part of a carrier wave, carrying computer-readable program code. Such transmitted data signals can take various forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination thereof. The computer-readable signal medium can also be any computer-readable medium other than a computer-readable storage medium, which can send, propagate, or transmit a program for use by or in connection with an instruction execution system, apparatus, or device. The program code contained on the computer-readable medium can be transmitted using any suitable medium, including but not limited to wireless, wired, etc., or any suitable combination thereof.
[0141] The flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of systems, methods, and computer program products according to various embodiments of this application. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of code containing one or more executable instructions for implementing a specified logical function. It should also be noted that in some alternative implementations, the functions indicated in the blocks may occur in a different order than those indicated in the drawings. For example, two consecutively indicated blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in a block diagram or flowchart, and combinations of blocks in a block diagram or flowchart, may be implemented using a dedicated hardware-based system that performs the specified function or operation, or using a combination of dedicated hardware and computer instructions.
[0142] It should be noted that although several modules or units for the device used to perform actions have been mentioned in the detailed description above, this division is not mandatory. In fact, according to the embodiments of this application, the features and functions of two or more modules or units described above can be embodied in one module or unit. Conversely, the features and functions of one module or unit described above can be further divided and embodied by multiple modules or units.
[0143] Through the above description of the embodiments, those skilled in the art will readily understand that the exemplary embodiments described herein can be implemented by software or by combining software with necessary hardware. Therefore, the technical solutions according to the embodiments of this application can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (such as a CD-ROM, USB flash drive, external hard drive, etc.) or on a network, including several instructions to cause a computing device (such as a personal computer, server, touch terminal, or network device, etc.) to execute the method according to the embodiments of this application.
[0144] Other embodiments of this application will readily occur to those skilled in the art upon consideration of the specification and practice of the invention disclosed herein. This application is intended to cover any variations, uses, or adaptations of this application that follow the general principles of this application and include common knowledge or customary techniques in the art not disclosed herein.
[0145] It should be understood that this application is not limited to the precise structure described above and shown in the accompanying drawings, and various modifications and changes can be made without departing from its scope. The scope of this application is limited only by the appended claims.
Claims
1. A data processing method, characterized in that, The data processing method includes: Multiple basic rays are generated by connecting a preset base point with multiple base points. The base points are contained in the base point cloud data used to reflect the preset model. The preset base points are used to simulate the photographed points in the photographed point cloud. The base point cloud data has a two-layer structure. Calculate the angle between each pair of the multiple basic rays. If the angle is less than or equal to a preset angle threshold, then classify the two basic rays corresponding to the angle into one target ray. Multiple filter models are set on the extended trajectory of the target ray to filter the base points contained within the multiple filter models; The basic points contained in the multiple filtering models are recorded as multiple feature points, wherein one filtering model corresponds to one feature point; The multiple feature points are combined to generate target point cloud data, which is point cloud data obtained after filtering the basic point cloud data. The target point cloud data is not a two-layer structure.
2. The data processing method as described in claim 1, characterized in that, Before classifying the two basic rays corresponding to the included angle into one target ray if the included angle is less than or equal to a preset angle threshold, the data processing method further includes: Detect the number of the base points and the spatial volume of the base point distribution; The first point cloud density level of the basic point cloud data is calculated based on the number of basic points and the spatial volume. The preset angle threshold is determined based on the first point cloud density level, and the first point cloud density level is negatively correlated with the preset angle threshold.
3. The data processing method as described in claim 1, characterized in that, Before classifying the two basic rays corresponding to the included angle into one target ray if the included angle is less than or equal to a preset angle threshold, the data processing method further includes: The space of the coordinate system containing the basic point cloud data is divided into multiple preset regions; The second point cloud density level of the preset area is obtained based on the number of basic rays within the preset area; The preset angle threshold is determined based on the second point cloud density level, and the second point cloud density level is negatively correlated with the preset angle threshold.
4. The data processing method as described in claim 1, characterized in that, Multiple filtering models are set along the extended trajectory of the target ray, including: The model step size is set according to user instructions, and the model step size is used to determine the size of the filtering model; The multiple filtering models are set on the extended trajectory of the target ray according to the model step size.
5. The data processing method as described in claim 1, characterized in that, Multiple filtering models are set along the extended trajectory of the target ray, including: Obtain the distance between the base point position and the preset base point included in the extended trajectory of the target ray; The model step size is determined based on the distance, and the distance and the model step size are negatively correlated. The multiple filtering models are set on the extended trajectory of the target ray according to the model step size.
6. The data processing method as described in claim 1, characterized in that, Before recording the base points contained in the multiple filtering models as multiple feature points, the data processing method further includes: Detect whether the filtering model contains at least one basic point; If the filtering model contains at least one base point, then the center point of the filtering model is recorded as a single feature point.
7. The data processing method as described in claim 1, characterized in that, After combining the multiple feature points to generate target point cloud data, the data processing method further includes: The target point cloud data and the workpiece point cloud data are registered using a point cloud registration algorithm to obtain the registration result; The correspondence between the simulated coordinate system and the operational coordinate system is determined based on the registration results. The simulated coordinate system is the coordinate system corresponding to the target point cloud data in the digital twin environment, and the operational coordinate system is the coordinate system corresponding to the mechanical equipment in actual operation. The simulated job process is generated within the digital twin environment; The mechanical equipment is controlled to perform operations based on the simulated operation process and the corresponding relationship.
8. A data processing apparatus, characterized in that, The data processing device includes: The connection module is configured to connect a preset base point with multiple base points to generate multiple basic rays. The base points are contained in the basic point cloud data used to reflect the preset model. The preset base points are used to simulate the photographed points in the photographed point cloud. The basic point cloud data has a two-layer structure. The classification module is configured to calculate the angle between each pair of the multiple basic rays. If the angle is less than or equal to a preset angle threshold, the two basic rays corresponding to the angle are classified as a target ray. The setting module is configured to set multiple filter models on the extended trajectory of the target ray to filter the base points contained within the multiple filter models. The recording module is configured to record the basic points contained in the multiple filtering models as multiple feature points, wherein one filtering model corresponds to one feature point; The generation module is configured to combine the multiple feature points to generate target point cloud data, wherein the target point cloud data is point cloud data obtained after filtering the basic point cloud data, and the target point cloud data is not a two-layer structure.
9. A terminal device, characterized in that, The terminal device includes: a memory, a processor, and a data processing program stored in the memory and executable on the processor, wherein the data processing program, when executed by the processor, implements the data processing method as described in any one of claims 1 to 7.
10. A storage medium, characterized in that, The storage medium stores a computer program, which, when executed by a processor, implements the data processing method as described in any one of claims 1 to 7.