Welding three-dimensional deformation detection method based on two-dimensional visual field mapping
By generating and registering a depth visual map based on a two-dimensional visual field mapping method, the problems of high efficiency and accuracy in three-dimensional deformation detection of welding are solved, and it is applicable to the automated detection of various welding processes.
Patent Information
- Application Number
- CN202511567978.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-10-30
- Publication Date
- 2026-02-13
AI Technical Summary
Existing technologies struggle to achieve efficient and accurate three-dimensional deformation detection during welding. Traditional contact-based detection methods suffer from low accuracy and efficiency, while non-contact methods involve complex data processing and high computational demands.
A two-dimensional visual field mapping method is adopted to acquire point cloud data before and after welding using a line laser and an industrial camera, generate a depth visual map and perform registration, and calculate the deformation of the welded part in the Z direction.
It achieves automated and high-precision detection of welding deformation, reduces data complexity, is applicable to various welding processes, and is suitable for integration with automated welding systems.
Smart Images

Figure CN121526992A_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of welding quality detection, and particularly relates to a welding three-dimensional deformation detection method based on two-dimensional visual field mapping. BACKGROUND
[0002] As a main connection process of metal component processing, welding technology plays an irreplaceable role in many industrial fields, and its application range covers mechanical manufacturing, nuclear industry, aerospace, energy transportation, petrochemical industry, shipbuilding, automobile, and building and electronics. In actual welding production or experiment, welding deformation is an inevitable phenomenon, which seriously affects the precision and structural performance of the component. The traditional contact detection method has the problems of low measurement accuracy, low efficiency, and difficulty in adapting to complex environments. Although the existing non-contact method such as structured light scanning can obtain three-dimensional data, the data processing is complex, the storage and calculation amount is large, and the calculation and identification are complex, so it is difficult to realize efficient deformation analysis. Therefore, there is an urgent need for a method capable of quickly and accurately detecting welding deformation to provide support for process optimization and quality control. SUMMARY
[0003] The purpose of the present application is to provide a welding three-dimensional deformation detection method based on two-dimensional visual field mapping, which realizes the automatic and high-precision detection of welding deformation through the steps of three-dimensional reconstruction, depth visual map generation and registration, and deformation calculation.
[0004] The method of the present application comprises the following steps:
[0005] S1, using a line laser to emit a line structured light to scan the welding piece before and after welding, using an industrial camera to collect images, and using a computer processing unit to perform three-dimensional reconstruction on the image information, so as to obtain the point cloud data of the welding piece before and after welding;
[0006] S2, converting the point cloud data into a depth visual map based on coordinate mapping and linear interpolation;
[0007] S3, using thin plate spline (TPS) transformation to register the depth visual maps before and after welding;
[0008] S4, establishing a depth visual map coordinate system and establishing a mapping relationship between the gray value and the depth value;
[0009] S5, calculating the deformation amount of the welding piece after welding in the Z direction based on the registered depth visual map.
[0010] Further, the generation of the depth visual map in the step S2 adopts the following specific steps:
[0011] S1, read the point cloud data and convert the point cloud data into an array, calculate the range of the coordinates X C and Y C of the point cloud data, to obtain a two-dimensional range of the point cloud data;
[0012] S2, determine the resolution of the depth vision map according to the two-dimensional range of the point cloud data using a scaling factor k = 10;
[0013] S3, map the position coordinates (X C , Y C ) of each point in the point cloud to the depth vision image pixel position coordinates (P x , P y ), and normalize the depth coordinates Z C using a scaling factor g = 50, to map Z C to a gray value G, the calculation formula being:
[0014]
[0015] S4, supplement the pixel points by linear interpolation in the y direction, to compensate for the low data density of the point cloud in the y direction, to obtain continuous and sufficient data for the generation of the depth vision map.
[0016] Further, the depth vision map registration in step S3 adopts the following specific steps:
[0017] S1, taking the pre-welding depth vision map of the welding part as the reference map and the post-welding depth vision map as the to-be-registered map;
[0018] S2, detecting registration points based on a connected region detection method;
[0019] S3, implementing registration point matching using KDTree nearest neighbor search;
[0020] S4, completing image registration by TPS transformation model estimation and application.
[0021] Further, the registration point detection adopts an 8-connected component labeling algorithm, and the connected regions with a pixel area less than 50 or greater than 200 are removed, and the center point pixel coordinates of the obtained connected regions are retained as the registration points.
[0022] Further, the registration point matching adopts a bidirectional matching strategy, and only when the registration points in the reference map and the to-be-registered map are the nearest neighbors of each other is the matching considered successful.
[0023] Further, the TPS transformation model includes an affine part and a nonlinear part, and the affine parameters and the weight vector are obtained by solving a linear equation system, to realize global and local deformation registration.
[0024] Further, the establishment of the coordinate system in the step S4 adopts the following specific steps:
[0025] S1, defining the coordinate origin based on the upper left corner registration point in the depth vision graph;
[0026] S2, setting the x-axis consistent with the increasing direction of the image row, and the y-axis consistent with the increasing direction of the column;
[0027] S3, setting the unit length as 10 pixels corresponding to 1 millimeter.
[0028] Further, the mapping relationship between the gray value and the depth value is:
[0029]
[0030] Wherein, Z is the depth value, G is the gray value, and g is the scaling factor.
[0031] Further, the calculation of the z-direction deformation amount in the step S5 is realized by bilinear interpolation on the pre-welding and post-welding depth graphs, and calculating the depth difference value of the corresponding pixel points.
[0032] Compared with the prior art, the present application has the following beneficial effects:
[0033] (1) The method can improve the welding deformation measurement precision, reduce the error caused by subjectivity, and increase the reliability of the welding structure quality detection;
[0034] (2) The method converts the point cloud model into a depth vision graph, which can reduce the data dimension and the calculation complexity;
[0035] (3) The method is suitable for welding deformation detection of various welding processes such as arc welding and laser welding, and can be integrated with an automatic welding system. BRIEF DESCRIPTION OF DRAWINGS
[0036] Figure 1 is a welding deformation feature detection system structure composition schematic diagram based on line structured light and depth vision graph.
[0037] Figure 2 is a three-dimensional point cloud model of the welding part before and after welding;
[0038] Figure 3 is a depth vision graph of the welding part before and after welding;
[0039] Figure 4 is a depth vision graph registration algorithm flowchart based on TPS transformation;
[0040] Figure 5 is a registration point matching result;
[0041] Figure 6is a post-weld depth vision map of the registered welded piece;
[0042] Figure 7 is a schematic diagram of a depth vision map coordinate system;
[0043] Figure 8 is a trend chart of the z-direction deformation of the welded piece with coordinate changes.
[0044] In the figure, 1 is an industrial camera, 2 is a line laser, 3 is an image acquisition unit, 4 is a motor, 5 is a motion control unit, and 6 is a computer processing unit. DETAILED DESCRIPTION
[0045] The application will be described in detail below with reference to the accompanying drawings and specific embodiments.
[0046] In this embodiment, a 2.0 mm thick 6061 aluminum alloy butt plate is used as a test sample, and the welding method is gas shielded arc welding. The detection system is composed of a line laser, an industrial camera, a displacement platform, a motion control unit and a computer processing unit, and the system structure is as shown in Figure 1 The method comprises the following steps:
[0047] S1: three-dimensional point cloud data acquisition
[0048] The sample surface is irradiated with a line laser, and the line structured light stripe images before and after welding are collected by an industrial camera; the collected images are preprocessed and feature extracted to obtain laser stripe center line coordinate data; the two-dimensional image coordinates are converted into three-dimensional camera coordinates through camera calibration; combined with the motion data of the displacement platform, three-dimensional point cloud models before and after welding are generated, as shown in Figure 2
[0049] S2: depth vision map generation
[0050] Read the point cloud data and calculate its two-dimensional range; determine the depth map resolution through the scale factor k=10; map the three-dimensional coordinates in the point cloud to the depth image pixel position and gray value, wherein the scaling factor g=50; use linear interpolation to compensate for the low data density of the point cloud in the y direction; generate the pre-welding and post-welding depth vision maps, as shown in Figure 3
[0051] S3: depth vision map registration
[0052] The pre-welding depth vision map is used as the reference map, and the post-welding depth vision map is used as the to-be-registered map; the connected component labeling algorithm is used to identify the registration points; the nearest neighbor search is used for registration point matching, and a bidirectional matching strategy is implemented; based on the matched point pairs, a thin plate spline transformation model is constructed, and the registration algorithm flow is as shown in Figure 4 Figure 5 The registered depth vision map is shown as Figure 6 as shown.
[0053] S4: Coordinate system establishment and depth mapping
[0054] The origin of the coordinate system is defined based on the registration point; the direction of the coordinate axis and the unit length are set; the mapping relationship between the gray value and the depth value is established, and the established depth vision map coordinate system is shown as Figure 7 as shown.
[0055] S5: z-direction deformation calculation
[0056] The pre-welding and post-welding depth maps are interpolated; the gray value is converted into the depth value under the unified coordinate system; the difference between the post-welding and pre-welding depth values is calculated to obtain the z-direction deformation; the deformation trend at the positions of x=10mm and x=30mm is analyzed, and the z-direction deformation trend with the coordinate change is shown as Figure 8 as shown.
[0057] The welding three-dimensional deformation detection method based on two-dimensional vision field mapping provided by the present application realizes non-contact and high-precision detection of welding deformation; through depth vision map conversion and registration, the data complexity is significantly reduced; the uneven welding deformation can be effectively processed; the method can be integrated with an automatic welding system to realize online quality detection. The method described in the present application is not only suitable for welding deformation detection of welding parts of various welding processes such as arc welding and laser welding, but also can be extended to deformation analysis in other material processing fields, and has a wide industrial application prospect.
[0058] It should be noted that the above examples are only used to illustrate the technical solutions of the present application, but not to limit it. Any modification, equivalent replacement, improvement, etc. made by those skilled in the art within the spirit and principles of the present application shall be included in the protection scope of the present application.
Claims
1. A method for detecting three-dimensional deformation in welding based on two-dimensional visual field mapping, characterized in that, A mechanism consisting of a line laser, an industrial camera, a motor, a motion control unit, and a computer processing unit uses the oblique-ray triangulation principle to automatically detect the geometric features of welding deformation. The method includes the following steps: S1 uses a line laser to emit line structured light to scan the welded parts before and after welding, uses an industrial camera to acquire images, and uses a computer processing unit to reconstruct the image information in three dimensions, thereby obtaining point cloud data of the welded parts before and after welding. S2 converts point cloud data into a depth visual map based on coordinate mapping and linear interpolation; S3, thin plate spline TPS transformation is used to register the depth visual images before and after welding; S4, Establish the depth visual map coordinate system and establish the mapping relationship between grayscale values and depth values; S5, calculate the deformation of the welded part in the Z direction based on the registered depth visual image.
2. The welding three-dimensional deformation detection method based on two-dimensional visual field mapping according to claim 1, characterized in that, The generation of the depth visual map in step S2 adopts the following specific steps: S1: Read the point cloud data and convert it into an array, then calculate the point cloud coordinates X. C and Y C The range is used to obtain the two-dimensional range of the point cloud data; S2, the resolution of the depth visual map is determined by a scaling factor k=10 based on the two-dimensional range of the point cloud data; S3, the position coordinates (X) of each point in the point cloud C , Y C ) is mapped to the pixel position coordinates of the depth visual map (P) x , P y Using a scaling factor g=50 for the depth coordinate Z C Normalization is performed to convert Z... C Mapping to grayscale value G, the calculation formula is: S4 supplements the pixels by linear interpolation in the y-direction, making up for the low data density of the point cloud in the y-direction, and obtaining continuous and sufficient data for the generation of the depth visual map.
3. The welding three-dimensional deformation detection method based on two-dimensional visual field mapping according to claim 1, characterized in that, The depth visual map registration in step S3 adopts the following specific steps: S1, using the pre-weld depth visual image of the welded part as the reference image, and the post-weld depth visual image as the image to be registered; S2, Registration point detection based on connected component detection method; S3 uses KDTree nearest neighbor search to achieve registration point matching; S4 completes image registration through TPS transform model estimation and application.
4. The welding three-dimensional deformation detection method based on two-dimensional visual field mapping according to claim 3, characterized in that, The registration point detection uses an 8-connected component labeling algorithm to remove connected regions with a pixel area less than 50 or greater than 200. The center pixel coordinates of the obtained connected regions are retained as registration points.
5. The welding three-dimensional deformation detection method based on two-dimensional visual field mapping according to claim 3, characterized in that, The registration point matching adopts a bidirectional matching strategy, and the matching is considered successful only when the registration points in the reference map and the map to be registered are each other's nearest neighbors.
6. The welding three-dimensional deformation detection method based on two-dimensional visual field mapping according to claim 3, characterized in that, The TPS transformation model includes an affine part and a nonlinear part. The affine parameters and weight vectors are obtained by solving a system of linear equations to achieve global and local deformation registration.
7. The welding three-dimensional deformation detection method based on two-dimensional visual field mapping according to claim 1, characterized in that, The establishment of the coordinate system in step S4 adopts the following specific steps: S1, with the registration point at the top left corner of the depth visual image as the reference, defines the origin of the coordinate system; S2, set the x-axis to be in the same direction as the row increase of the image, and the y-axis to be in the same direction as the column increase; S3 sets the unit length to 10 pixels, corresponding to 1 millimeter.
8. The welding three-dimensional deformation detection method based on two-dimensional visual field mapping according to claim 1, characterized in that, The mapping relationship between grayscale values and depth values is as follows: Where Z is the depth value, G is the grayscale value, and g is the scaling factor.
9. The welding three-dimensional deformation detection method based on two-dimensional visual field mapping according to claim 1, characterized in that, In step S5, the deformation in the z-direction is calculated by performing bilinear interpolation on the depth maps before and after welding, and calculating the depth difference of the corresponding pixels.