Three-dimensional scanning path generation method and device, and three-dimensional scanning system

CN122820964APending Publication Date: 2026-09-25SCANTECH (HANGZHOU) CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202610838009.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-06-10
Publication Date
2026-09-25

AI Technical Summary

Technical Problem

[0004]然而,目前的上述方式或者传统方法,在面对不同工件时往往依赖较多的单独配置和重复调整,导致整体处理效率较低,且一致性较差

Benefits of technology

通过构建用于表征待测工件的整体形状或局部形状的几何体模型,且该几何体模型由单个几何体或多个几何体组合得到,能够将原本直接围绕工件本体表面进行的扫描路径组织过程,转化为围绕几何体模型进行的路径生成过程,从而降低路径生成对工件具体表面细节的依赖,提高不同工件尤其是同批次尺寸存在差异的工件在路径生成过程中的统一性和适配性;通过在几何体模型表面生成多个抽象路径点,能够以规则化方式确定待扫描区域对应的候选扫描位置,使路径点在几何体表面形成具有覆盖性的分布,为后续路径规划提供清晰的路径生成基础;通过按照几何体模型、转盘、机械臂及扫描仪之间的坐标转换顺序,将各抽象路径点逐步转换为实际扫描空间中的目标路径点,能够建立抽象路径点与实际扫描系统之间的空间对应关系,使基于几何体模型生成的路径点能够落实到真实扫描设备的工作空间中;通过基于转盘旋转角度和机械臂运动能力,对各目标路径点进行路径规划,能够在转盘与机械臂协同动作的条件下合理组织扫描顺序和扫描范围,使扫描仪覆盖待测工件的各区域。由此,本申请实施例能够在保证扫描覆盖性的同时,简化路径生成过程,降低路径组织复杂度,提高自动化扫描的生成效率、执行稳定性和适用范围。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122820964A_ABST
    Figure CN122820964A_ABST
Patent Text Reader

Abstract

The application discloses a three-dimensional scanning path generation method and device and a three-dimensional scanning system, and belongs to the technical field of three-dimensional scanning. The method comprises the following steps: constructing a geometric model for representing a workpiece to be measured, wherein the geometric model is a single geometric body or a combination of multiple geometric bodies; generating a plurality of abstract path points on the surface of the geometric model; converting each abstract path point into a target path point in an actual scanning space in a coordinate conversion sequence between the geometric model, a rotating disc, a mechanical arm and a scanner; and performing path planning on each target path point based on the rotating angle of the rotating disc and the motion ability of the mechanical arm, so as to obtain a scanning path for enabling the scanner to cover each region of the workpiece to be measured. The application improves the path generation efficiency, scanning coverage and execution stability of automatic scanning.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application belongs to the field of 3D scanning technology, and in particular relates to a 3D scanning path generation method, device and 3D scanning system. Background Technology

[0002] With the development of 3D scanning, robot automation control, and digital inspection technologies, the method of automatically scanning workpieces using robotic arms equipped with scanners is gradually being applied in the field of industrial inspection. This method features non-contact operation, high efficiency, and ease of automation integration, and currently, scanning path planning is typically based on the workpiece's CAD model, mesh model, or point cloud model.

[0003] In traditional techniques, after acquiring the 3D data of the workpiece, engineers typically set the scanning range, scanning position, and equipment movement process based on the workpiece's shape and inspection requirements to create a corresponding scanning plan. In some scenarios, the scanning process needs to be adjusted and verified multiple times based on the workpiece's placement, equipment layout, and inspection requirements of different areas to ensure successful completion.

[0004] However, current methods, or traditional approaches, often rely heavily on individual configurations and repeated adjustments when dealing with different workpieces, resulting in low overall processing efficiency and poor consistency. Especially when workpieces in the same batch exhibit dimensional fluctuations or have complex surface shapes, traditional methods are prone to problems such as insufficient scanning coverage, cumbersome path organization, and unstable execution, thus affecting the efficiency and accuracy of automated scanning. Summary of the Invention

[0005] This application aims to address at least one of the technical problems existing in the prior art. To this end, this application proposes a three-dimensional scanning path generation method, apparatus, and three-dimensional scanning system to improve the efficiency and accuracy of automated scanning.

[0006] In a first aspect, this application provides a method for generating a three-dimensional scanning path, applied to a three-dimensional scanning system, the three-dimensional scanning system including a robotic arm, a scanner, a workpiece to be measured, and a turntable; the method includes: Construct a geometric model to characterize the workpiece to be tested, wherein the geometric model is a single geometric body or a combination of multiple geometric bodies; Multiple abstract path points are generated on the surface of the geometric model; According to the coordinate transformation sequence between the geometric model, turntable, robotic arm and scanner, each abstract path point is gradually converted into a target path point in the actual scanning space; Based on the rotation angle of the turntable and the movement capability of the robotic arm, path planning is performed on each target path point to obtain a scanning path that allows the scanner to cover each area of ​​the workpiece to be tested.

[0007] Secondly, this application provides a three-dimensional scanning path generation device, the device comprising: A construction module is used to construct a geometric model for characterizing the workpiece under test, wherein the geometric model is a single geometric body or a combination of multiple geometric bodies; A generation module is used to generate multiple abstract path points on the surface of the geometric model. The conversion module is used to convert each abstract path point into a target path point in the actual scanning space step by step, according to the coordinate conversion sequence between the geometric model, turntable, robotic arm and scanner. The planning module is used to plan paths for each target path point based on the turntable rotation angle and the robotic arm's motion capability, so as to obtain a scanning path that allows the scanner to cover each area of ​​the workpiece to be tested.

[0008] Thirdly, this application provides a three-dimensional scanning system, characterized in that it includes: robotic arm; The scanner is mounted on the robotic arm; A turntable is used to hold the workpiece to be tested; A processor configured to execute the three-dimensional scan path generation method as described in the first aspect.

[0009] Fourthly, this application provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the three-dimensional scanning path generation method as described in the first aspect above.

[0010] Fifthly, this application provides a non-transitory computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the three-dimensional scanning path generation method as described in the first aspect above.

[0011] In a sixth aspect, this application provides a chip including a processor and a communication interface, the communication interface being coupled to the processor, the processor being used to run programs or instructions to implement the three-dimensional scanning path generation method as described in the first aspect.

[0012] In a seventh aspect, this application provides a computer program product, including a computer program that, when executed by a processor, implements the three-dimensional scanning path generation method as described in the first aspect above.

[0013] The above-described one or more technical solutions in the embodiments of this application have at least one of the following technical effects: By constructing a geometric model to characterize the overall or partial shape of the workpiece under test, and this geometric model is obtained by combining single or multiple geometric bodies, the scanning path organization process, which was originally performed directly around the surface of the workpiece, can be transformed into a path generation process around the geometric model. This reduces the dependence of path generation on the specific surface details of the workpiece and improves the uniformity and adaptability of the path generation process for different workpieces, especially those with different dimensions within the same batch. By generating multiple abstract path points on the surface of the geometric model, candidate scanning positions corresponding to the area to be scanned can be determined in a regularized manner, enabling the path points to form a pattern on the geometric surface. The comprehensive distribution provides a clear foundation for subsequent path generation. By following the coordinate transformation sequence between the geometric model, turntable, robotic arm, and scanner, each abstract path point is gradually converted into a target path point in the actual scanning space. This establishes a spatial correspondence between the abstract path points and the actual scanning system, ensuring that the path points generated based on the geometric model are implemented in the workspace of the real scanning equipment. Furthermore, by planning paths for each target path point based on the turntable's rotation angle and the robotic arm's movement capabilities, the scanning sequence and range can be rationally organized under the condition of coordinated movement of the turntable and robotic arm, enabling the scanner to cover all areas of the workpiece under test. Therefore, this embodiment simplifies the path generation process, reduces path organization complexity, and improves the generation efficiency, execution stability, and applicability of automated scanning while ensuring scanning coverage.

[0014] Additional aspects and advantages of this application will be set forth in part in the description which follows, and in part will be obvious from the description, or may be learned by practice of this application. Attached Figure Description

[0015] The above and / or additional aspects and advantages of this application will become apparent and readily understood from the description of the embodiments taken in conjunction with the following drawings, in which: Figure 1 This is a schematic diagram of the structure of a three-dimensional scanning system provided in some embodiments of this application; Figure 2 This is a schematic diagram of the scanner provided in some embodiments of this application; Figure 3 This is a flowchart illustrating the three-dimensional scanning path generation method provided in some embodiments of this application; Figure 4 This is a schematic diagram of the structure of the three-dimensional scanning path generation device provided in some embodiments of this application; Figure 5 This is a schematic diagram of the structure of an electronic device provided in some embodiments of this application. Detailed Implementation

[0016] The technical solutions of the embodiments of this application will be clearly described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of this application. All other embodiments that can be directly obtained based on the embodiments of this application are within the scope of protection of this application.

[0017] The terms "first," "second," etc., used in the specification and claims of this application are used to distinguish similar objects and not to describe a specific order or sequence. It should be understood that such use of data can be interchanged where appropriate so that embodiments of this application can be implemented in orders other than those illustrated or described herein, and the objects distinguished by "first," "second," etc., are generally of the same class and the number of objects is not limited; for example, a first object can be one or more. Furthermore, in the specification and claims, "and / or" indicates at least one of the connected objects, and the character " / " generally indicates that the preceding and following objects are in an "or" relationship.

[0018] In existing 3D scanning applications, for workpieces with CAD models, mesh models, or point cloud models, engineers typically first import the workpiece data into offline software. Then, based on the arrangement of the robotic arm, scanner, and turntable, they manually set the scanning position, scanning posture, and turntable rotation angle. The software then generates the corresponding scanning trajectory and uses simulation to check for any scanning omissions, equipment interference, or abnormal postures during the scanning process. Once the simulation results meet the requirements, the corresponding trajectory is then sent to the actual equipment for execution.

[0019] For workpieces with relatively regular shapes, engineers can usually set several scanning areas directly based on the surface characteristics of the workpiece, and configure the movement trajectory of the robotic arm and the orientation of the scanner for each scanning area.

[0020] For workpieces with many curved surfaces, large structural undulations, or occlusion relationships, it is usually necessary to set more scanning positions on the workpiece surface and repeatedly adjust the path point sequence, scanning posture, and turntable movement to cover all the areas to be scanned on the workpiece as much as possible.

[0021] However, the above method is essentially still about organizing the path around the actual surface of the workpiece, and the path generation process relies heavily on the engineer's understanding of the workpiece shape and scanning experience. When there are only minor variations in size among workpieces in the same batch, even if the overall shape of the workpiece is basically the same, it is often necessary to re-inspect or readjust the scanning path for different workpieces. Otherwise, it is easy to have insufficient scanning range in some areas or an increased number of local rescans.

[0022] For workpieces with particularly complex surface structures, the numerous details, corners, surface variations, and local occlusions on their surfaces mean that paths generated directly from the workpiece surface are often numerous and poorly organized. This not only increases the workload of path configuration, simulation verification, and on-site debugging but also easily leads to complex collaborative movements between the robotic arm and the turntable, affecting the smoothness and stability of the scanning process. Especially in automated batch scanning scenarios, if the path itself relies too heavily on the specific surface details of the workpiece, it becomes difficult to balance scan coverage, path simplicity, and consistency of repeated execution, thus limiting further improvements in automated scanning efficiency.

[0023] In view of this, embodiments of this application provide a three-dimensional scanning path generation method, apparatus, and three-dimensional scanning system, which aim to reduce the path configuration complexity of different workpieces, especially workpieces with different sizes or complex surface structures in the same batch, during the automated scanning process. By abstracting the workpiece to be measured into a single geometric body or a combination of multiple geometric bodies and generating a scanning path based on the geometric body model, the path generation efficiency, scanning coverage, and execution stability of automated scanning are improved.

[0024] The three-dimensional scanning path generation method, apparatus, and three-dimensional scanning system provided in this application will be described in detail below with reference to the accompanying drawings, through embodiments and application scenarios.

[0025] Figure 1 This is a schematic diagram of the structure of a three-dimensional scanning system provided in some embodiments of this application.

[0026] For example Figure 1 As shown, the 3D scanning system includes a scanner 110, a robotic arm 120, a robotic arm base 130, a workpiece to be measured 140, and a turntable 150.

[0027] A robotic arm 120 is mounted on a robotic arm base 130, which supports and secures the robotic arm 120. A scanner 110 is mounted at the end of the robotic arm 120, which drives the scanner 110 to move in three-dimensional space, enabling the scanner 110 to reach different scanning positions and adjust the scanning orientation.

[0028] The workpiece to be tested 140 refers to the target object that needs to be scanned in three dimensions, including but not limited to automotive body panels, sheet metal parts, mold parts, box parts, shell parts, castings, mechanical parts, composite material parts, or other industrial workpieces that need to be scanned in three dimensions.

[0029] The workpiece 140 to be tested is placed on the turntable 150. The turntable 150 is used to support the workpiece 140 to be tested and changes the spatial orientation of the workpiece 140 to be tested relative to the robotic arm 120 and the scanner 110 by rotating it, so that different areas of the workpiece 140 to be tested are sequentially oriented to the appropriate scanning position, thereby cooperating with the robotic arm 120 to realize multi-angle scanning of the workpiece 140 to be tested.

[0030] The scanner 110 is a scanning component used to acquire three-dimensional data of the surface of the workpiece 140 to be tested. Figure 2 This is a schematic diagram of the scanner structure provided in some embodiments of this application. For example... Figure 2 As shown, the scanner 110 can adopt a spherical or near-spherical multifaceted distribution structure, with multiple scanning units distributed on the outer periphery of the scanner 110, so that the scanner 110 can acquire data from the surface of the workpiece 140 under different orientations. This structure helps to improve the scanning coverage and reduce the problem of difficulty in acquiring data in local areas due to limitations of a single acquisition direction.

[0031] The scanning unit refers to the functional unit in a scanner used to emit scanning signals and / or receive target reflection signals to acquire three-dimensional data of the surface of the workpiece under test. For example, the scanning unit may include one or more of a laser emitter, a structured light projector, an image acquisition unit, an optical receiver, and a depth sensor.

[0032] It should be noted that, Figure 2 The diagram shown is only one schematic structure of the scanner 110. The scanner 110 may also adopt other structural forms suitable for installation at the end of the robotic arm 120 and for performing three-dimensional data acquisition. This application does not limit this.

[0033] In this 3D scanning system, the robotic arm 120, scanner 110, workpiece 140, and turntable 150 together constitute the hardware foundation for performing automated scanning. The robotic arm 120 provides the spatial movement capability of the scanner 110, the turntable 150 provides the rotational adjustment capability of the workpiece 140, the scanner 110 is responsible for performing the actual data acquisition, and the workpiece 140 is fixed on the turntable 150 as the object being scanned.

[0034] Through the coordinated action of the robotic arm 120 and the turntable 150, the scanner 110 can establish appropriate scanning positions and directions around different areas of the workpiece 140 to be measured, thereby providing system support for subsequent generation of scanning paths based on geometric models and execution of automatic scanning.

[0035] In some implementations, the mounting relationship between the robotic arm 120 and the scanner 110 can be pre-calibrated, the positional relationship between the turntable 150 and the robotic arm base 130 can also be pre-calibrated, and the positional relationship of the workpiece 140 to be measured placed on the turntable 150 can also be determined.

[0036] Based on the above relationships, a spatial correspondence can be established between the workpiece 140 to be measured, the turntable 150, the robotic arm 120, and the scanner 110, enabling the subsequently generated scanning path to be mapped to the motion trajectory of the scanner 110 in actual space. Thus, this 3D scanning system not only carries the workpiece 140 to be measured and completes the scanning action, but also provides a hardware and spatial relationship foundation for the conversion of abstract path points into actual executable scanning paths.

[0037] Based on the aforementioned 3D scanning system, this application provides a 3D scanning path generation method. This method is executed by the 3D scanning system, which abstracts the geometry of the workpiece under test and generates a scanning path based on the abstracted geometric model, thereby achieving automatic scanning coverage of various areas of the workpiece by the scanner.

[0038] The three-dimensional scanning path generation method provided in this application embodiment can be executed by a processor, industrial computer, host computer or other control device with data processing capabilities in the above-mentioned three-dimensional scanning system. It can communicate with the robotic arm, scanner and turntable to obtain relevant data of the workpiece to be measured, generate the corresponding scanning path, and control the robotic arm, scanner and turntable to perform the scanning process in a coordinated manner.

[0039] The following describes the three-dimensional scanning path generation method provided in the embodiments of this application, taking the processor as the execution subject as an example.

[0040] Figure 3 This is a flowchart illustrating a three-dimensional scanning path generation method provided in some embodiments of this application. For example... Figure 3 As shown, the method includes steps 310 to 340.

[0041] Step 310: Construct a geometric model to characterize the workpiece to be tested. The geometric model can be a single geometric body or a combination of multiple geometric bodies.

[0042] A geometric body is a regular body used to represent the overall shape or local shape of a workpiece. A geometric body model is an abstract model formed by a single geometric body or a combination of multiple geometric bodies, used for subsequent generation of scanning paths.

[0043] The processor first acquires the workpiece data of the workpiece to be tested. The workpiece data can be at least one of the following: CAD model data, point cloud data, contour data, or dimensional data of the workpiece to be tested.

[0044] When the workpiece to be tested already has model data or point cloud data that can directly reflect its shape, geometric fitting can be performed directly based on the workpiece data; when the workpiece to be tested has not yet formed a complete model, dimensional data and contour data that can characterize the shape features can be obtained first, and then the corresponding geometric model can be constructed accordingly.

[0045] After acquiring the workpiece data, the processor first determines whether the workpiece can be represented by a single geometric body. If the overall shape of the workpiece is relatively regular and its main structure is similar to the shape of a certain type of geometric body, then the workpiece is fitted as a single geometric body. If the overall shape of the workpiece is difficult to fully represent by a single geometric body, the workpiece is divided into multiple local regions, and geometric body fitting is performed for each local region, or a matching target geometric body is selected for each local region to obtain multiple geometric bodies. These multiple geometric bodies are then combined to form a corresponding geometric body model. In other words, in some implementations, the processor can either select a target geometric body that matches the workpiece from a preset geometric body type and obtain the corresponding geometric parameters to generate a geometric body model; or it can acquire the workpiece data and perform geometric body fitting based on the workpiece data to obtain a geometric body model. Through the above methods, the modeling path, whether manually specified or automatically fitted, can be flexibly selected according to the workpiece's shape characteristics, data completeness, and modeling requirements, thereby balancing the efficiency of geometric body model construction and model adaptability.

[0046] Specifically, when generating a geometric model using a manually specified method, the processor can first allow the user to determine the corresponding geometric type based on the shape of the workpiece to be measured, then input the geometric parameters corresponding to that geometric type, and thus generate the geometric model. The geometric types can include cuboids, cylinders, frustums of cones, spheres, prisms, pyramids, ellipsoids, etc.

[0047] For example, when the workpiece to be tested is box-shaped, it can be fitted as a cuboid; when the workpiece to be tested is columnar, it can be fitted as a cylinder; when the workpiece to be tested is frustum-shaped, it can be fitted as a frustum-shaped cone; when the workpiece to be tested is in the form of a polygonal cross-section under tension, it can be characterized as a prism; when the workpiece to be tested is in the form of a pointed, contracting shape, it can be characterized as a pyramid; and when the workpiece to be tested is in the form of an ellipsoid, it can be characterized as an ellipsoid.

[0048] The geometric parameters acquired and used by the processor can vary depending on the type of geometry. For a cuboid, the geometric parameters may include the origin, length, width, height, length direction, width direction, and height direction; for a cylinder, the geometric parameters may include the origin, axis, height, and radius; for a frustum, the geometric parameters may include the origin, axis, height, top circle radius, and bottom circle radius; for a sphere, the geometric parameters may include the center and diameter; for a prism, the geometric parameters may include the origin, axis, height, base profile parameters, and top profile parameters; for a pyramid, the geometric parameters may include the base reference point, axis, height, base profile parameters, and vertex position; and for an ellipsoid, the geometric parameters may include the center, major axis, minor axis, and directions of each axis. Among them, the origin, center of the sphere, base reference point or vertex position are used to determine the position of the geometry in space, the length direction, width direction, height direction or axis are used to determine the orientation of the geometry in space, and length, width, height, radius, top circle radius, bottom circle radius, sphere diameter, bottom profile parameters, top profile parameters, major axis and minor axis are used to determine the size range of the geometry.

[0049] When the target geometry is a cuboid, the processor can determine the cuboid's reference position in space based on the origin, determine its orientation in space based on its length, width, and height, and determine its size range based on its length, width, and height. When the target geometry is a cylinder or frustum, the processor can determine its center position and extension direction based on the origin and axis, and determine its external dimensions based on its height, radius, top circle radius, and bottom circle radius. When the target geometry is a sphere, its spatial position and size range can be directly determined based on its center and diameter. When the target geometry is a prism, the processor can determine the spatial position and extension direction of the prism based on the origin and axis, and determine the external dimensions of the prism based on the base contour parameters, top contour parameters, and height. When the target geometry is a pyramid, the processor can determine the spatial position and contraction direction of the pyramid based on the base reference point, vertex position, and axis, and determine the external dimensions of the pyramid based on the base contour parameters and height. When the target geometry is an ellipsoid, the processor can determine the spatial position of the ellipsoid based on the center of the ellipsoid, and determine the external dimensions and spatial orientation of the ellipsoid based on the major axis, minor axis, and directions of each axis.

[0050] Of course, the above are just examples. The shape and size of the actual workpiece to be measured are not limited to the listed geometric types. They can be regular standard geometric shapes, complex shapes composed of multiple geometric shapes, or arbitrary geometric shapes that fit the shape of the workpiece, so as to flexibly generate geometric models according to different workpiece characteristics and use them for subsequent scanning path planning.

[0051] This approach allows for the provision of corresponding parameter systems for different geometric types, making the construction process of geometric models clearer and facilitating the subsequent generation of abstract path points based on the surface of the geometric model.

[0052] Furthermore, by configuring different parameter sets for different geometric types, the generated geometric model can more accurately reflect the shape characteristics of the workpiece under test.

[0053] When using an automatic fitting method to generate a geometric model, the processor can automatically generate geometric parameters that match the workpiece under test based on the workpiece data.

[0054] It should be noted that the automatic generation method is not limited to a single algorithm. It can be achieved by using bounding box calculation, geometry fitting, calling third-party modeling libraries or geometry processing libraries, or other processing methods that can generate geometric models based on workpiece data. In some implementations, users can also manually input geometric parameters, or further refine the geometric parameters based on the automatically generated results, thereby obtaining the final geometric model.

[0055] For cases where the model is fitted to a cuboid, the processor can calculate the directed bounding box of the workpiece based on the workpiece data to obtain a cuboid model. A directed bounding box is a bounding box that changes with the actual orientation of the workpiece. Compared to axis-aligned bounding boxes with fixed coordinate axes, directed bounding boxes typically fit the shape of the workpiece more closely, making them more suitable as cuboid models. Of course, the generation of cuboid models is not limited to directed bounding box calculations; it can also be achieved through point cloud fitting, boundary extraction followed by construction, automatic generation using third-party libraries, or manual parameter input. For other geometric shapes such as cylinders, frustums, spheres, prisms, pyramids, and ellipsoids, the processor can perform maximum fitting, optimization, or generate the corresponding geometric parameters based on sampling points in the workpiece data, thereby obtaining geometric parameters that match the shape of the workpiece. This method can improve the fitting accuracy by reducing human intervention to minimize subjective bias and increasing the degree of fit between the geometric model and the actual shape of the workpiece.

[0056] The above method is merely an example and is not limited to a specific generation path. This method can improve the fit between the geometric model and the actual shape of the workpiece while reducing human intervention and subjective bias; at the same time, it retains the flexibility of manual adjustment and the parallel use of multiple generation methods.

[0057] If the workpiece to be tested can be represented by a single geometric object, the processor outputs the geometric model corresponding to that single geometric object.

[0058] If the workpiece to be tested needs to be characterized by multiple local areas, the processor outputs a geometric model formed by the combination of multiple geometric bodies.

[0059] Step 320: Generate multiple abstract path points on the surface of the geometric model.

[0060] After obtaining the geometric model, the processor further generates multiple abstract path points on the surface of the geometric model. The surface can be either a plane or a curved surface.

[0061] Abstract path points are points pre-generated on the surface of a geometric model to characterize candidate scanning positions for the scanner. These abstract path points first exist in the geometric space corresponding to the geometric model.

[0062] In some implementations, the processor traverses each surface of the geometric model, samples each surface according to corresponding sampling rules, obtains multiple sampling points, and determines each sampling point as a corresponding abstract path point. By first determining the surface extent, the generation area of ​​subsequent abstract path points can be clearly defined, avoiding the generation of invalid path points in internal regions unrelated to the scan or in non-target regions.

[0063] Sampling rules refer to the rules for determining the distribution positions of path points on a corresponding surface. Since different geometric surfaces have different shapes, sampling rules can also vary accordingly. For planar surfaces, multiple sampling positions can be generated along the two extension directions of the surface at preset intervals; for curved or arc-shaped surfaces of revolution, multiple sampling positions can be generated along the circumferential, axial, or angular directions at preset intervals or preset angular intervals. The preset intervals or preset angular intervals can be set according to the size of the workpiece to be measured, the scanning accuracy requirements, and the subsequent scanning coverage requirements. By setting sampling rules, the generated abstract path points can form a comprehensive distribution on the surface of the geometric model, rather than being randomly scattered.

[0064] For example, the preset sampling rules include: when the surface is a cuboid surface or the bottom surface of a cylinder or frustum, sampling is performed according to length intervals; when the surface is a cylindrical surface, frustum surface, or sphere, sampling is performed according to angle intervals.

[0065] Specifically, when the processor traverses a planar surface, it can generate multiple sampling points along the surface's extension direction at preset length intervals. When the processor traverses a curved surface, it can generate multiple sampling points along the circumferential or spherical angle directions of the curved surface at preset angular intervals. For cuboid surfaces and the bases of cylinders and frustums, due to their relatively flat surface shapes, length-interval sampling can effectively create a regular distribution. For cylindrical, frustum, or spherical surfaces, since their surface orientation changes with position, angular interval sampling is more conducive to ensuring a uniform distribution of sampling points along the curved surface. This method allows for the adoption of appropriate sampling rules based on different surface shapes, enabling abstract path points to form a distribution on the geometric model surface that better meets actual scanning requirements, thus providing a foundation for subsequent path point coordinate transformation and scan path planning.

[0066] Step 330: Following the coordinate transformation sequence between the geometric model, turntable, robotic arm, and scanner, gradually convert each abstract path point into a target path point in the actual scanning space.

[0067] Target path points refer to path points that have been transformed from the abstract space corresponding to the geometric model to the actual scan space and can be used for subsequent path planning processing.

[0068] The actual scanning space refers to the physical space comprised of the turntable, robotic arm, and scanner. In this space, each target path point not only corresponds to a candidate scanning position on the surface of the workpiece to be measured, but also to a spatial reference point for subsequent judgments of the turntable's rotation state, the robotic arm's accessibility, and the scanner's orientation.

[0069] The processor first clarifies the correspondence between the various coordinate systems. The coordinate system corresponding to the geometric model is the reference coordinate system used to describe the shape, size, and surface position of the geometric model; the generated abstract path points are located in this coordinate system. The turntable coordinate system is a coordinate system established with the turntable itself as a reference, used to describe the positional relationship of the workpiece to be measured relative to the turntable. The robotic arm base coordinate system is a coordinate system established with the robotic arm base as a reference, used to describe the spatial reference of the robotic arm as a whole. The robotic arm end effector coordinate system is a coordinate system established with the robotic arm end effector as a reference, used to describe the spatial position and orientation of the robotic arm end effector during movement. The scanner coordinate system is a coordinate system established with the scanner itself as a reference, used to describe the scanner's installation position, installation orientation, and scanning direction.

[0070] Since the workpiece to be tested is placed on the turntable and the scanner is installed at the end of the robotic arm, the abstract path points must be sequentially associated with the actual spatial relationships of the turntable, robotic arm and scanner in order to be used for subsequent path planning.

[0071] Specifically, the processor first transforms the abstract path points in the geometric model's coordinate system to the turntable's coordinate system. This transformation is based on the placement of the geometric model relative to the turntable. Since the geometric model represents the workpiece under test, and the workpiece is actually placed on the turntable, the position and orientation of the geometric model in space need to be determined using the turntable as a supporting foundation. In other words, it's necessary to first know the location of the origin of the geometric model on the turntable and how the orientation of the geometric model corresponds to the orientation of the turntable before the positions of the abstract path points in the geometric model can be converted to their positions on the turntable. After this transformation, the intermediate path points in the turntable coordinate system are obtained. At this point, these intermediate path points can represent the positional distribution of the abstract path points on the surface of the workpiece under test relative to the turntable.

[0072] After transforming the abstract path points to the turntable coordinate system, the processor then transforms each intermediate path point in the turntable coordinate system to the robot arm base coordinate system based on the pose relationship between the turntable and the robot arm base. The pose relationship refers to the installation position and orientation of the turntable in the robot arm's spatial location. Since the planning of all robot arm motion trajectories is usually based on the robot arm base as a spatial reference, only by first transforming the intermediate path points to the robot arm base coordinate system can the spatial distribution of these path points relative to the robot arm be further determined. Through this transformation, another set of intermediate path points located in the robot arm base coordinate system can be obtained. At this point, each path point has been placed in a unified reference datum within the robot arm's actual workspace.

[0073] After obtaining the intermediate path points in the robotic arm base coordinate system, the processor then transforms these intermediate path points into the robotic arm end effector coordinate system based on the pose relationship between the end effector and the base. This transformation establishes a correspondence between the path points and the motion state of the end effector. Since the subsequent scanning action is ultimately achieved by the end effector driving the scanner, changes in the position and orientation of the end effector relative to the base directly affect how the path points are represented relative to the end effector's execution position. After this transformation, the intermediate path points in the end effector coordinate system are obtained. At this point, each path point can be understood as a target point relative to the reference position of the end effector.

[0074] Subsequently, the processor transforms the intermediate path points in the robotic arm's end-effector coordinate system to the scanner's coordinate system based on the scanner's pose relative to the robotic arm's end effector. This pose relationship reflects the scanner's installation offset and orientation after being mounted on the robotic arm's end effector. Since the scanner may not perfectly coincide with the reference origin of the robotic arm's end effector, and the scanner itself has a fixed installation orientation, this transformation is necessary to further express the path points as points in the scanner's own reference system. After this transformation, the target path points in the actual scanning space can be obtained. Thus, the target path points are no longer abstract points existing only on the surface of the geometric model, but rather points corresponding to real scanning systems, which can be used for subsequent path planning by combining the turntable rotation angle and the robotic arm's motion capabilities.

[0075] In some implementations, to reduce redundant calculations caused by step-by-step transformations, a comprehensive transformation relationship describing the overall transformation can be pre-formed based on the pose relationships between the geometric model, turntable, robotic arm, and scanner at various levels. This comprehensive transformation relationship is then used to directly transform each abstract path point from the geometric model coordinate system to the actual scanning space. Regardless of whether step-by-step or comprehensive transformation is used, the essence is to establish a connection between the abstract path points and their spatial positions in the actual scanning system while maintaining the corresponding relationship of the coordinate transformation order.

[0076] Through the above processing, the processor finally obtains the target path points in the actual scanning space. These target path points retain both the coverage and distribution characteristics of the abstract path points on the surface of the geometric model and reflect their spatial position and orientation in the real scanning system, thus providing a basis for subsequent path planning for each target path point based on the turntable rotation angle and the robotic arm's motion capabilities.

[0077] Step 340: Based on the turntable rotation angle and the robotic arm's motion capability, perform path planning for each target path point to obtain a scanning path that allows the scanner to cover all areas of the workpiece to be measured.

[0078] The scanning path refers to the movement path that enables the scanner to sequentially cover each target area of ​​the workpiece under test, in conjunction with the rotation of the turntable and the movement of the robotic arm.

[0079] The motion capability of a robotic arm refers to the range of motion, posture, and reach that a robotic arm can achieve under its structural and control constraints.

[0080] In this step, the processor combines the changes in the workpiece's spatial orientation caused by the rotation angle of the turntable, as well as the robotic arm's ability to reach each target path point in different orientations, to organize and constrain each target path point, thereby generating a scanning path that can be actually executed and covers all areas of the workpiece under test.

[0081] Specifically, the processor first determines the rotation angle range of the turntable and the angle division method. The turntable rotation angle refers to the angle that the turntable rotates around its rotation axis relative to its initial position. Based on the shape range of the workpiece to be measured, the spatial distribution of the target path points, and the expected scan coverage requirements, the processor can pre-determine multiple candidate rotation angles.

[0082] Candidate rotation angles can be a set of angle values ​​obtained by dividing the angles at fixed angular intervals, or a set of angle values ​​that are adaptively determined based on the shape characteristics of the workpiece to be measured and the distribution of target path points.

[0083] After determining these candidate rotation angles, the processor can assume that the workpiece to be measured will exhibit different spatial orientations when the turntable is at different candidate rotation angles, and the spatial relationship between the target path point and the scanner and the robotic arm will also change accordingly.

[0084] After obtaining the candidate rotation angles, the processor determines the matching status between each target path point and the scanning direction under different candidate rotation angles based on the direction information corresponding to each target path point.

[0085] The scanning direction refers to the direction in which the scanner faces the surface of the workpiece being scanned during the scanning process. Since the direction information corresponding to the target path point represents the orientation of the workpiece surface at that point, the orientation of the surface corresponding to the same target path point relative to the scanner will change when the turntable rotates to different angles.

[0086] To this end, the processor can calculate the angle between the orientation information of the target path point and the scanning direction at each candidate rotation angle, or determine whether the two meet the preset orientation matching conditions. If the relationship between a target path point and the scanning direction at a certain candidate rotation angle is more conducive to the scanner's acquisition, then the target path point can be considered more suitable to be scanned at that candidate rotation angle.

[0087] After determining the matching relationship between each target path point and each candidate rotation angle, the processor assigns each target path point to the corresponding candidate rotation angle. That is, for each target path point, the most suitable turntable angle for scanning is determined, and the target path point is assigned to the path point set corresponding to that turntable angle.

[0088] After this processing, the target path points, originally distributed across the entire surface of the workpiece, are divided into multiple subsets. Each subset corresponds to the target path points that are prioritized for scanning when the turntable is at a certain candidate rotation angle. In this way, the degree of freedom of turntable rotation can be introduced into the path planning process, allowing the workpiece to expose different areas at different angles, thereby reducing the burden on the robotic arm to cover the entire area solely by its own posture.

[0089] After assigning target path points to different candidate rotation angles, the processor further combines the robotic arm's motion capabilities to determine the scanning order at each candidate rotation angle. The scanning order includes two levels of order: firstly, the execution order between different candidate rotation angles, and secondly, the execution order between each target path point at each candidate rotation angle.

[0090] The execution order between candidate rotation angles can be determined based on the motion continuity of the robotic arm when switching between adjacent turntable angles, so that the changes in turntable angle and robotic arm posture are as smooth as possible.

[0091] For the execution order of target path points under the same candidate rotation angle, the order is sorted according to the robot arm's ability to reach these target path points.

[0092] Specifically, the processor can determine one by one whether the robotic arm, in its current posture or the posture after completing the previous path point, can successfully reach the next target path point. If it can reach the target path point, then that target path point is used as a subsequent scanning point; if it cannot reach the target path point, or if reaching the target path point requires the robotic arm to undergo an excessively large posture change, then other target path points that are easier to reach consecutively are selected first. In this way, the movement process of the robotic arm when visiting each target path point at the same candidate rotation angle is more continuous.

[0093] In the process of sorting target path points according to the robotic arm's motion capabilities, the processor can further consider the robotic arm's workspace range and attitude constraints. The workspace range refers to the spatial area that the robotic arm's end effector can reach, while attitude constraints refer to the range of directions allowed for the robotic arm's end effector when reaching a certain path point.

[0094] If a target path point is spatially reachable, but the required orientation of the scanner at that point exceeds the range of poses achievable by the robotic arm's end effector, then that target path point can be considered as not meeting the robotic arm's motion capability requirements at the current candidate rotation angle. For such target path points, they can be reassigned to other candidate rotation angles or eliminated during subsequent path correction. Therefore, the path planning process considers not only whether the target path point is located within the robotic arm's reach, but also whether the robotic arm can maintain a suitable acquisition orientation for the scanner when reaching that location.

[0095] After allocating target path points and determining the scanning sequence for each candidate rotation angle, the processor combines the candidate rotation angles and their corresponding path point access sequences to form an initial scanning path. This initial scanning path contains two parts: one is the sequence of rotation angles executed sequentially by the turntable during the scanning process, and the other is the sequence of target path points accessed sequentially by the robotic arm at each turntable angle. In other words, the scanning path is not simply composed of the robotic arm's trajectory, but rather a collaborative path formed by the turntable's rotation and the robotic arm's movement. Through this collaborative path, the scanner can be moved to the corresponding target path point position by the robotic arm while the turntable changes the orientation of the workpiece, thereby gradually covering different areas of the workpiece.

[0096] In some implementations, after obtaining the initial scan path, the processor can further refine it. For example, it can check whether there is an excessively large angle jump between two adjacent candidate rotation angles; if so, the execution order of the candidate rotation angles is adjusted. It can also check whether the robotic arm movement distance between two adjacent target path points under the same candidate rotation angle is too large; if so, the access order of the target path points under that candidate rotation angle is rearranged. Through these refinements, the scan path can ensure that all areas of the workpiece under test are covered while further improving the smoothness and continuity of the coordinated movement of the turntable and the robotic arm.

[0097] Through the above processing, the processor ultimately obtains the scanning path used to enable the scanner to cover all areas of the workpiece under test. This scanning path is no longer merely an abstract set of points generated from the surface of the geometric model, nor simply discrete target path points in the actual scanning space. Instead, it is a path result formed after comprehensively considering the turntable rotation angle and the robotic arm's motion capabilities, and can be actually executed by the 3D scanning system. Subsequently, the turntable and robotic arm movements can be controlled based on this scanning path, allowing the scanner to scan each area of ​​the workpiece under test in the planned sequence.

[0098] According to the three-dimensional scanning path generation method provided in this application, by constructing a geometric model to characterize the overall or local shape of the workpiece to be measured, and the geometric model being obtained by combining a single geometric body or multiple geometric bodies, the scanning path organization process, which was originally performed directly around the surface of the workpiece, can be transformed into a path generation process performed around the geometric model. This reduces the dependence of path generation on the specific surface details of the workpiece and improves the uniformity and adaptability of different workpieces, especially those with different dimensions in the same batch, in the path generation process. By generating multiple abstract path points on the surface of the geometric model, candidate scanning positions corresponding to the area to be scanned can be determined in a regularized manner, making the path... Points are distributed across the surface of the geometric body, providing a clear foundation for subsequent path generation. By following the coordinate transformation sequence between the geometric model, turntable, robotic arm, and scanner, each abstract path point is gradually converted into a target path point in the actual scanning space. This establishes a spatial correspondence between the abstract path points and the actual scanning system, ensuring that the path points generated based on the geometric model are implemented in the workspace of the real scanning equipment. Path planning for each target path point is performed based on the turntable's rotation angle and the robotic arm's movement capabilities. This allows for the rational organization of the scanning sequence and range under the condition of coordinated movement between the turntable and the robotic arm, enabling the scanner to cover all areas of the workpiece under test. Therefore, this embodiment simplifies the path generation process, reduces path organization complexity, and improves the generation efficiency, execution stability, and applicability of automated scanning while ensuring scanning coverage.

[0099] In some implementations, after obtaining the scanning path for the scanner to cover each area of ​​the workpiece to be tested, the processor drives the robotic arm to move the scanner along the scanning path, so that the scanner covers the position of each target path point on the workpiece surface for three-dimensional scanning, thereby obtaining three-dimensional scanning data covering the entire surface of the workpiece to be tested.

[0100] In this process, the robotic arm drives the scanner to move sequentially to the positions corresponding to each target path point according to the scanning path. The turntable rotates in coordination with the corresponding rotation angles along the scanning path, ensuring that different areas of the workpiece under test are positioned and oriented appropriately for scanning. After reaching the position corresponding to each target path point, the scanner performs a 3D scan of the workpiece surface at that position and outputs the corresponding local 3D data. As the robotic arm continues to move along the scanning path and the scanner continues to scan the positions corresponding to each target path point, the processor can sequentially acquire the local 3D data corresponding to each target path point and aggregate the local 3D data to obtain 3D scan data covering the entire surface of the workpiece under test. Thus, the aforementioned scanning path generated based on the geometric model is implemented into the actual scanning process, ensuring that each target area on the surface of the workpiece under test is sequentially covered by the scanner.

[0101] In this way, the aforementioned path generation results can be directly used to drive the robotic arm and scanner to perform actual scanning, thereby converting the target path points generated on the surface of the geometric model into the corresponding real scanning positions, ensuring that each area of ​​the surface of the workpiece to be tested is scanned in the planned order, thereby improving the automation level, scanning coverage integrity and execution consistency of the entire 3D scanning process.

[0102] After generating each sampling position, the processor also needs to determine the corresponding surface orientation information for each sampling position. Surface orientation information refers to the normal direction of the surface where the sampling position is located, used to characterize the orientation of the workpiece surface at that position. For planar surfaces, each sampling position on the same surface can correspond to the same normal direction; for curved surfaces, the normal direction at different sampling positions will change with position, so the processor can calculate the corresponding normal direction according to the local geometric relationship of the curved surface where the sampling position is located. By simultaneously determining the position coordinates and surface orientation information for each sampling position, subsequent processing can not only determine the position that the scanner needs to reach, but also the direction in which the scanner should face the workpiece surface at that position. After obtaining each sampling position and its corresponding surface orientation information, the processor determines each sampling position as multiple abstract path points and establishes a relationship between each abstract path point and its corresponding surface orientation information, thereby obtaining a set of abstract path points containing the correspondence between position and orientation.

[0103] In the subsequent coordinate transformation process, the processor not only transforms the position coordinates of each abstract path point, but also synchronously transforms the surface orientation information corresponding to each abstract path point. Specifically, the abstract path points and their corresponding surface orientation information can be transformed in the same coordinate transformation order: first from the geometric model coordinate system to the turntable coordinate system, then to the robot arm base coordinate system, the robot arm end effector coordinate system, and the scanner coordinate system, thereby obtaining the target path points and their corresponding surface normals in the actual scanning space. That is to say, after step 330, the processor obtains not only a set of target path points located in the actual scanning space, but also the actual orientation information of the workpiece surface at each target path point. In this way, the object processed by subsequent path planning is no longer a discrete point with only geometric position, but a set of target path points that simultaneously includes spatial position and surface orientation.

[0104] Based on this, in some implementations, after obtaining each target path point and its corresponding surface normal in the actual scanning space, the processor then performs path planning for each target path point based on the turntable rotation angle and the robotic arm's motion capability, to obtain a scanning path for the scanner to cover each area of ​​the workpiece to be tested.

[0105] Specifically, the processor first determines the target scanning direction for each target path point based on the surface normal corresponding to that point. The target scanning direction refers to the desired orientation of the scanner when performing a scan at the corresponding target path point, ensuring the scanner faces the workpiece surface in a suitable direction for acquisition. Subsequently, the processor acquires multiple candidate rotation angles of the turntable and determines the matching relationship between each target scanning direction and the scanning direction at each candidate rotation angle. This matching relationship characterizes whether the workpiece surface orientation at the corresponding target path point is more suitable for scanning when the turntable is at a certain candidate rotation angle. Based on this matching relationship, the processor assigns each target path point to a corresponding candidate rotation angle, ensuring that each target path point belongs to a turntable angle more suitable for scanning.

[0106] Subsequently, for each target path point assigned to a candidate rotation angle, the processor determines the corresponding scanning sequence based on the robotic arm's motion capabilities. These capabilities include the robotic arm's reachability, attitude adjustment capabilities, and continuous motion capabilities between adjacent target path points.

[0107] The processor can prioritize arranging target path points that are easier for the robotic arm to reach continuously, have smaller posture changes, or have smoother motion processes in an adjacent order, thereby obtaining the scanning order under each candidate rotation angle, and further generating a scanning path based on each candidate rotation angle and the corresponding scanning order.

[0108] In this way, the target path point positions and surface normals generated and converted in the previous stage are further used to determine the target scanning direction, match candidate rotation angles, and organize the scanning sequence, thus making the scanning path generation process based on both spatial position and surface orientation dimensions. The resulting scanning path not only improves the scanning coverage of each area of ​​the workpiece under test, but also helps reduce robotic arm posture jumps and invalid movements, improving the execution stability and path organization rationality of the 3D scanning process.

[0109] In some implementations, a scanning path is generated based on each candidate rotation angle and the corresponding scanning order, including: performing collision detection, occlusion judgment, and scanner visibility judgment on the target path points under each candidate rotation angle; removing target path points that fail the collision detection, occlusion judgment, or scanner visibility judgment; and generating a scanning path based on the candidate rotation angle and scanning order corresponding to the remaining target path points.

[0110] When generating the scanning path based on each candidate rotation angle and the corresponding scanning sequence, the processor further performs executability screening on the target path points under each candidate rotation angle. Specifically, for each target path point assigned to a candidate rotation angle, the processor combines the workpiece spatial posture corresponding to that candidate rotation angle with the relative positional relationship of the robotic arm, scanner, and turntable in the actual scanning space, and performs collision detection, occlusion judgment, and scanner visibility judgment on each target path point.

[0111] Collision detection is used to determine whether the scanner will spatially interfere with the workpiece, turntable, robotic arm body or other components when performing a scan at the corresponding target path point.

[0112] The occlusion detection is used to determine whether the surface of the workpiece at the target path point is occluded by other areas of the workpiece or system components when the scanner is scanning towards the corresponding target path point.

[0113] Scanner visibility assessment determines whether the scanner is within the observation range of the tracking head at the current candidate rotation angle and corresponding scanning direction, thus enabling effective identification and tracking by the tracking head. For tracking scanners, if the scanner cannot be seen by the tracking head at the current pose, it is not advisable to retain the target path point in the scanning path, even if the corresponding target path point itself meets the scanning direction requirements.

[0114] For target path points that fail collision detection, occlusion judgment, or scanner visibility judgment, the processor removes them from the set of target path points corresponding to the current candidate rotation angle.

[0115] The processor then generates the final scan path based on the candidate rotation angles and scan order corresponding to the remaining target path points. The target path points ultimately retained in the scan path are all valid path points that can be scanned by the actual scanning system at their respective candidate rotation angles.

[0116] This method allows for the further elimination of target path points with collision, occlusion, or invisibility risks during the scanning path generation process. This ensures that the final scanning path not only meets the matching requirements of the turntable rotation angle and scanning direction but also satisfies the execution constraints in the actual scanning process. Consequently, it improves the executability of the scanning path, the stability of the scanning process, and the effectiveness of the scanning results for each area of ​​the workpiece under test.

[0117] Taking automated 3D scanning of car door inner panels in an automotive manufacturing scenario as an example, the workpieces to be measured are door inner panels from the same batch. These workpieces have similar overall contours, but workpieces from different batches or different workstations may have millimeter-level differences in local dimensions. Furthermore, their surfaces have complex structures such as window frames, reinforcing ribs, and mounting hole edges. To balance automated scanning efficiency and scan coverage integrity, a robotic arm carrying the scanner and a turntable supporting the workpiece are used to perform scan path generation and scanning operations.

[0118] First, the positional relationships between the robotic arm, scanner, workpiece under test, and turntable are obtained. The scanner is mounted on the end effector of the robotic arm, and the pose relationship between the scanner and the end effector is pre-observed through hand-eye calibration. The workpiece under test is fixed on the turntable, and its initial positional relationship relative to the robotic arm base is obtained through environmental calibration. The turntable is positioned outside the robotic arm body, and its initial positional relationship relative to the robotic arm base is obtained through external axis calibration. Since the pose relationship between the end effector and the robotic arm base is known, the pose transformation relationships between the scanner, end effector, workpiece under test, turntable, and robotic arm base can all be calculated. Therefore, the abstract path points subsequently generated on the surface of the geometric model can be progressively transformed into the actual scanning space.

[0119] After obtaining the positional relationships, a geometric model corresponding to the workpiece to be tested is further generated. For the inner panel of the car door, since its overall shape is approximately a rectangular thin plate structure, and this embodiment focuses more on overall scanning coverage, it is abstracted as a rectangular prism model. This rectangular prism model can be directly specified by the user based on the shape of the workpiece, or it can be automatically fitted based on the workpiece data. If the automatic fitting method is used, a directed bounding box can be calculated based on the point cloud data of the workpiece or the model data to obtain a rectangular prism model with a higher fit to the shape of the workpiece. This rectangular prism model includes an origin, length, width, height, and length, width, and height directions. The origin is used to determine the position of the model in space, the length, width, and height are used to determine the size of the model, and the length, width, and height directions are used to determine the orientation of the model. For other application scenarios, such as battery boxes, mold cavities, and box-like shell parts, they can also be abstracted as rectangular prisms, cylinders, frustums, spheres, or combinations of multiple geometric shapes. When the surface of a workpiece is particularly complex but the overall shape is still close to a certain standard geometry, the overall shape of the workpiece can be approximated by the standard geometry to reduce the complexity of subsequent path generation.

[0120] After obtaining the cuboid model, the geometric model is sampled. Specifically, each outer surface of the cuboid is traversed, and samples are taken at equal intervals along the length and width directions within each surface, resulting in multiple sampling points. Each sampling point corresponds to a surface normal. For a cuboid, sampling points on the same surface have the same surface normal, so the surface normal can be directly assigned to each sampling point within the surface. This yields a set of abstract path points containing position and normal information. If the geometric model is a cylinder or frustum, its top and bottom surfaces are sampled at length intervals, and its sides are sampled at angular intervals; if the geometric model is a sphere, the spherical surface is sampled at angular intervals. In this way, a comprehensive distribution of candidate scan points can be formed on the surface of the geometric model.

[0121] After generating abstract path points, these path points are categorized. Since relying solely on a robotic arm to scan from a single direction often fails to completely cover the entire workpiece area, a rotating turntable is needed to expose different surface areas of the workpiece at different angles. In this embodiment, one circumference of the turntable is divided into multiple candidate rotation angles, such as the initial angle, 90 degrees, 180 degrees, and 270 degrees. Given an initial optimal scanning direction, the scanning direction changes with the turntable at different angles. For each abstract path point, its normal can be obtained, and the degree of matching between this normal and the corresponding scanning direction for each candidate rotation angle can be calculated, for example, by using a dot product. The larger the dot product result, the more suitable the path point is to be scanned at the corresponding rotation angle. Based on this matching result, the processor assigns each abstract path point to the corresponding turntable rotation angle, thus forming multiple sets of path points divided by turntable angle. In this way, subsequent scanning can gradually cover the entire workpiece surface in the manner of "turntable at a certain angle - scan the area corresponding to that angle - turntable rotates to the next angle - continue scanning".

[0122] After classification, collision detection, occlusion judgment, and tracking head visibility judgment are performed on the path points at each angle. Collision detection determines whether the scanner will interfere with the workpiece, turntable, or robotic arm when it reaches the corresponding position according to the current path point and normal. Occlusion judgment determines whether the workpiece surface corresponding to the path point will be blocked by other structures on the workpiece itself, thus preventing the scanning signal from reaching effectively. Tracking head visibility judgment determines whether the scanner can be observed by the tracking head at the path point. If a path point fails any of the above judgments, it is assigned a corresponding state, such as unexecutable, occlusion risk, or observation limited, and displayed in the simulation scanning interface. Users can modify the position or normal information of the path point based on this state information, or directly remove the path point. For path points that pass the judgment, the scanning sequence at each turntable angle is further determined by combining the reachability of the robotic arm, its attitude adjustment capability, and the continuous movement capability between adjacent path points.

[0123] Finally, a complete scan path is generated based on each candidate rotation angle and its corresponding path point execution order. During scanning, the turntable first remains at its initial angle, and the robotic arm drives the scanner to sequentially access the set of path points at that angle, completing the scan of the corresponding area. Then, the turntable rotates to the next candidate angle, and the robotic arm executes the scan according to the path point sequence at that angle; this cycle continues until the turntable has rotated one full circle. In this way, the scanner can cover all areas of the inner panel of the car door with the coordinated action of the robotic arm and the turntable, ultimately obtaining three-dimensional scan data covering the entire surface of the workpiece under test.

[0124] In the above example, although the workpiece has a locally complex structure, by first abstracting the workpiece into a standard geometric body, then generating path points on the surface of the geometric body and classifying them in combination with the turntable angle, the original scanning path organization process that revolves around the real complex surface can be transformed into a path organization process that revolves around the geometric model. This reduces the difficulty of path planning and improves the consistency and efficiency of automated scanning of workpieces in the same batch.

[0125] Therefore, for workpieces in the same batch with different sizes and workpieces with particularly complex surfaces, the workpiece to be tested is abstracted into a standard geometric body. The geometric body is automatically planned with the goal of completely covering the surface of the geometric body, so as to realize the complete scanning of the workpiece. This greatly reduces the complexity of programming and the professional threshold, breaks through the bottleneck of detection efficiency, and realizes high-speed batch detection.

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

[0127] The three-dimensional scanning path generation method provided in this application can be executed by a three-dimensional scanning path generation device. This application uses the execution of the three-dimensional scanning path generation method by a three-dimensional scanning path generation device as an example to illustrate the three-dimensional scanning path generation device provided in this application.

[0128] Figure 4 This is a schematic diagram of the structure of a three-dimensional scanning path generation device provided in some embodiments of this application. For example... Figure 4 As shown, the 3D scanning path generation device 400 includes: a construction module 401, a generation module 402, a conversion module 403, and a planning module 404.

[0129] Module 401 is used to construct a geometric model to characterize the workpiece to be tested. The geometric model is a single geometric body or a combination of multiple geometric bodies.

[0130] The generation module 402 is used to generate multiple abstract path points on the surface of the geometric model.

[0131] The conversion module 403 is used to convert each abstract path point into a target path point in the actual scanning space step by step, according to the coordinate conversion sequence between the geometric model, turntable, robotic arm and scanner.

[0132] The planning module 404 is used to plan the path for each target path point based on the rotation angle of the turntable and the movement capability of the robotic arm, so as to obtain the scanning path for the scanner to cover each area of ​​the workpiece to be measured.

[0133] According to the three-dimensional scanning path generation apparatus provided in this application, by constructing a geometric model to characterize the overall or partial shape of the workpiece to be measured, and the geometric model being obtained by combining a single geometric body or multiple geometric bodies, the scanning path organization process, which was originally performed directly around the surface of the workpiece, can be transformed into a path generation process performed around the geometric model. This reduces the dependence of path generation on the specific surface details of the workpiece and improves the uniformity and adaptability of different workpieces, especially those with different dimensions in the same batch, in the path generation process. By generating multiple abstract path points on the surface of the geometric model, candidate scanning positions corresponding to the area to be scanned can be determined in a regularized manner, making the path... Points are distributed across the surface of the geometric body, providing a clear foundation for subsequent path generation. By following the coordinate transformation sequence between the geometric model, turntable, robotic arm, and scanner, each abstract path point is gradually converted into a target path point in the actual scanning space. This establishes a spatial correspondence between the abstract path points and the actual scanning system, ensuring that the path points generated based on the geometric model are implemented in the workspace of the real scanning equipment. Path planning for each target path point is performed based on the turntable's rotation angle and the robotic arm's movement capabilities. This allows for the rational organization of the scanning sequence and range under the condition of coordinated movement between the turntable and the robotic arm, enabling the scanner to cover all areas of the workpiece under test. Therefore, this embodiment simplifies the path generation process, reduces path organization complexity, and improves the generation efficiency, execution stability, and applicability of automated scanning while ensuring scanning coverage.

[0134] In some implementations, the planning module is also used to determine the target scanning direction corresponding to each target path point based on the surface normal corresponding to each target path point; determine the matching relationship between each target scanning direction and the scanning direction at each candidate rotation angle based on multiple candidate rotation angles of the turntable, and assign each target path point to the corresponding candidate rotation angle according to the matching relationship; for the target path points assigned to each candidate rotation angle, determine the corresponding scanning sequence in combination with the motion capability of the robotic arm, and generate a scanning path according to each candidate rotation angle and the corresponding scanning sequence.

[0135] In some implementations, the planning module is also used to perform collision detection, occlusion judgment, and scanner visibility judgment on the target path points at each candidate rotation angle; remove target path points that fail the collision detection, occlusion judgment, or scanner visibility judgment; and generate a scanning path based on the candidate rotation angle and scanning order corresponding to the remaining target path points.

[0136] In some implementations, the construction module is also used to select a target geometry that matches the workpiece to be tested from a preset geometry type, and obtain the geometric parameters corresponding to the target geometry to generate a geometry model; or, to obtain the workpiece data of the workpiece to be tested, and to perform geometry fitting on the workpiece to be tested based on the workpiece data to obtain a geometry model.

[0137] In some embodiments, the geometric types include cuboids, cylinders, frustums, and spheres; wherein: when the geometric type is a cuboid, the geometric parameters include the origin, length, width, height, length direction, width direction, and height direction; when the geometric type is a cylinder, the geometric parameters include the origin, axis, height, and radius; when the geometric type is a frustum, the geometric parameters include the origin, axis, height, top circle radius, and bottom circle radius; and when the geometric type is a sphere, the geometric parameters include the center of the sphere and the diameter of the sphere.

[0138] In some implementations, the construction module is also used to calculate the directed bounding box of the workpiece based on the workpiece data to obtain a cuboid model when the workpiece to be tested is fitted to a cuboid; and to perform maximum fitting of the corresponding geometric body based on the workpiece data to obtain the corresponding geometric body model when the workpiece to be tested is fitted to other geometric bodies.

[0139] In some implementations, the generation module is also used to traverse each surface of the geometric model, sample each surface according to the corresponding sampling rules, and obtain multiple sampling points; determine each sampling point as the corresponding abstract path point; wherein the preset sampling rules include: when the surface is a cuboid surface or the bottom surface of a cylinder or frustum, sampling is performed according to the length interval; when the surface is a cylindrical surface, frustum surface or sphere, sampling is performed according to the angle interval.

[0140] In some embodiments, the above-mentioned device further includes a control module for driving the robotic arm to move the scanner along the scanning path, so that the scanner covers the positions of each target path point on the workpiece surface for three-dimensional scanning, thereby obtaining three-dimensional scanning data covering the entire surface of the workpiece to be tested.

[0141] The three-dimensional scanning path generation device in this application embodiment can be an electronic device or a component in an electronic device, such as an integrated circuit or a chip.

[0142] The three-dimensional scanning path generation device provided in this application embodiment can realize all the processes implemented in the above-described three-dimensional scanning path generation method embodiment and can achieve the same technical effect. To avoid repetition, it will not be described again here.

[0143] Figure 5 This is a schematic diagram of the structure of an electronic device provided in some embodiments of this application. For example... Figure 5As shown, this application embodiment also provides an electronic device 500, including a processor 501, a memory 502, and a computer program stored in the memory 502 and executable on the processor 501. When the program is executed by the processor 501, it implements the various processes of the above-described three-dimensional scanning path generation method embodiment and can achieve the same technical effect. To avoid repetition, it will not be described again here.

[0144] This application provides a non-transitory computer-readable storage medium storing a computer program. When the computer program is executed by a processor, it implements the various processes of the above-described three-dimensional scanning path generation method embodiment and achieves the same technical effect. To avoid repetition, it will not be described again here.

[0145] The processor is the processor in the electronic device described in the above embodiments. The readable storage medium includes computer-readable media, such as computer read-only memory (ROM), random-access memory (RAM), magnetic disks, or optical disks.

[0146] The computer-readable storage medium may include: read-only memory (ROM), random-access memory (RAM), magnetic disk or optical disk, etc.

[0147] This application provides a computer program product, including a computer program that, when executed by a processor, implements the above-described three-dimensional scanning path generation method.

[0148] This application provides a chip, which includes a processor and a communication interface. The communication interface is coupled to the processor. The processor is used to run programs or instructions to implement the various processes of the above-described three-dimensional scanning path generation method embodiments and achieve the same technical effect. To avoid repetition, it will not be described again here.

[0149] It should be understood that the chip mentioned in the embodiments of this application may also be referred to as a system-on-a-chip, system chip, chip system, or system-on-a-chip, etc.

[0150] It should be noted that, in this document, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes that element. Furthermore, it should be noted that the scope of the methods and apparatuses in the embodiments of this application is not limited to performing functions in the order shown or discussed, but may also include performing functions substantially simultaneously or in the reverse order, depending on the functions involved. For example, the described methods may be performed in a different order than described, and various steps may be added, omitted, or combined. Additionally, features described with reference to certain examples may be combined in other examples.

[0151] From the above description of the embodiments, it is clear that the methods described in the embodiments can be implemented by means of software plus necessary general-purpose hardware platforms. Of course, they can also be implemented by hardware, but in many cases, the former is a better implementation method. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the related technology, can be embodied in the form of a computer software product. This computer software product is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) and includes several instructions to cause a terminal (which may be a mobile phone, computer, server, or network device, etc.) to execute the methods described in the various embodiments of this application.

[0152] The embodiments of this application have been described above with reference to the accompanying drawings. However, this application is not limited to the above-described embodiments. The above-described embodiments are merely illustrative and not restrictive. Under the guidance of this application, many other forms can be made without departing from the spirit and scope of the claims, and all of them are within the protection scope of this application.

[0153] In the description of this specification, the references to terms such as "one embodiment," "some embodiments," "illustrative embodiment," "example," "specific example," or "some examples," etc., indicate that a specific feature, structure, material, or characteristic described in connection with that embodiment or example is included in at least one embodiment or example of this application. In this specification, the illustrative expressions of the above terms do not necessarily refer to the same embodiment or example. Furthermore, the specific features, structures, materials, or characteristics described may be combined in any suitable manner in one or more embodiments or examples.

[0154] Although embodiments of this application have been shown and described, it is understood that various changes, modifications, substitutions and variations can be made to these embodiments without departing from the principles and spirit of this application, the scope of which is defined by the claims and their equivalents.

Claims

1. A method for generating a three-dimensional scanning path, characterized in that, The method is applied to a 3D scanning system, which includes a robotic arm, a scanner, a workpiece to be measured, and a turntable; the method includes: Construct a geometric model to characterize the workpiece to be tested, wherein the geometric model is a single geometric body or a combination of multiple geometric bodies; Multiple abstract path points are generated on the surface of the geometric model; According to the coordinate transformation sequence between the geometric model, turntable, robotic arm and scanner, each abstract path point is gradually converted into a target path point in the actual scanning space; Based on the rotation angle of the turntable and the movement capability of the robotic arm, path planning is performed on each target path point to obtain a scanning path that allows the scanner to cover each area of ​​the workpiece to be tested.

2. The three-dimensional scanning path generation method according to claim 1, characterized in that, Based on the turntable rotation angle and the robotic arm's motion capability, path planning is performed on each target path point to obtain a scanning path that allows the scanner to cover all areas of the workpiece under test, including: Based on the surface normal corresponding to each target path point, determine the target scanning direction corresponding to each target path point; Based on multiple candidate rotation angles of the turntable, the matching relationship between the scanning direction of each target and the scanning direction at each candidate rotation angle is determined, and each target path point is assigned to the corresponding candidate rotation angle according to the matching relationship. For each target path point assigned to a candidate rotation angle, the corresponding scanning sequence is determined by combining the robotic arm's motion capabilities, and a scanning path is generated based on each candidate rotation angle and its corresponding scanning sequence.

3. The three-dimensional scanning path generation method according to claim 2, characterized in that, The step of generating a scanning path based on each candidate rotation angle and the corresponding scanning order includes: Collision detection, occlusion judgment, and scanner visibility judgment are performed on the target path points under each candidate rotation angle. Remove target path points that fail collision detection, occlusion judgment, or scanner visibility judgment; The scanning path is generated based on the candidate rotation angles and scanning order corresponding to the remaining target path points.

4. The method for generating a three-dimensional scanning path according to any one of claims 1 to 3, characterized in that, The construction of a geometric model to characterize the workpiece under test, wherein the geometric model is a single geometric body or a combination of multiple geometric bodies, results in a geometric model including: Select a target geometry that matches the workpiece to be measured from a preset geometry type, and obtain the geometric parameters corresponding to the target geometry to generate a geometric model; or Obtain the workpiece data of the workpiece to be tested, and perform geometric fitting on the workpiece based on the workpiece data to obtain a geometric model.

5. The three-dimensional scanning path generation method according to claim 4, characterized in that, The geometric types include cuboids, cylinders, frustums of cones, and spheres; wherein: When the geometric type is a cuboid, the geometric parameters include the origin, length, width, height, length direction, width direction, and height direction; When the geometry type is a cylinder, the geometric parameters include the origin, axis, height, and radius; When the geometry type is a frustum, the geometric parameters include the origin, axis, height, top circle radius, and bottom circle radius; When the geometry is a sphere, the geometric parameters include the center and diameter of the sphere.

6. The three-dimensional scanning path generation method according to claim 4, characterized in that, The step of performing geometric fitting on the workpiece to be tested based on the workpiece data to obtain a geometric model includes: When the workpiece to be tested is fitted as a cuboid, the directed bounding box of the workpiece to be tested is calculated based on the workpiece data to obtain the cuboid model. When the workpiece to be tested is fitted to other geometries, the maximum fit of the corresponding geometries is performed based on the workpiece data to obtain the corresponding geometric model.

7. The three-dimensional scanning path generation method according to claim 1, characterized in that, The generation of multiple abstract path points on the surface of the geometric model includes: Traverse each surface of the geometric model and sample each surface according to the corresponding sampling rules to obtain multiple sampling points; Each sampling point is identified as a corresponding abstract path point; The sampling rules include: When the surface is a cuboid surface or the bottom surface of a cylinder or frustum, sampling is performed according to the length interval; When the surface is a cylindrical surface, a frustum, or a sphere, sampling is performed according to angular intervals.

8. The three-dimensional scanning path generation method according to claim 1, characterized in that, The method further includes: The robotic arm is driven to move the scanner along the scanning path, so that the scanner covers the positions of each target path point on the workpiece surface for three-dimensional scanning, thereby obtaining three-dimensional scanning data covering the entire surface of the workpiece to be tested.

9. A three-dimensional scanning path generation device, characterized in that, include: A construction module is used to construct a geometric model for characterizing the workpiece to be tested, wherein the geometric model is a single geometric body or a combination of multiple geometric bodies; A generation module is used to generate multiple abstract path points on the surface of the geometric model. The conversion module is used to convert each abstract path point into a target path point in the actual scanning space step by step, according to the coordinate conversion sequence between the geometric model, turntable, robotic arm and scanner. The planning module is used to plan paths for each target path point based on the turntable rotation angle and the robotic arm's movement capability, so as to obtain a scanning path that allows the scanner to cover each area of ​​the workpiece to be tested.

10. A three-dimensional scanning system, characterized in that, include: robotic arm; The scanner is mounted on the robotic arm; A turntable is used to hold the workpiece to be tested; A processor configured to perform the three-dimensional scan path generation method as described in any one of claims 1-8.