A welding deformation detection method and system based on image data processing
By improving the XFeat model and fixture state analysis, the influence of rigid body motion and elastic rebound in welding deformation detection was resolved, achieving high-precision deformation amount and position detection.
Patent Information
- Application Number
- CN202611254644.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-08-18
- Publication Date
- 2026-11-24
AI Technical Summary
Existing binocular vision-based welding deformation detection methods have difficulty distinguishing between rigid body motion, elastic rebound, and permanent deformation of welded parts after the fixture is released, resulting in insufficient accuracy of the detection results.
By employing an improved XFeat model that combines fixture projection, clamping force difference, and intervention phase, and using a reversible response kernel and a non-response rigid body anchor point, the reversible elastic release displacement and constraint coupling residual displacement of the welded part under different constraint states are separated. The counterfactual free surface is reconstructed and corrected, enabling accurate detection of longitudinal shrinkage, transverse shrinkage, angular deformation, and out-of-plane deformation.
It improves the accuracy and stability of welding deformation detection, and can clearly distinguish between elastic rebound and permanent deformation during the welding process, outputting complete deformation amount and location information.
Smart Images

Figure CN123160458A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of image data processing technology, and in particular to a welding deformation detection method and system based on image data processing. Background Technology
[0002] Under the combined effects of heat input, material shrinkage, and clamping constraints, welded components are prone to longitudinal shrinkage, transverse shrinkage, angular deformation, and out-of-plane deformation, affecting the assembly accuracy and service performance of the components. Traditional welding deformation detection typically uses rulers, dial indicators, coordinate measuring machines, laser scanners, or visual measurement equipment to collect data on the surface contour, feature point positions, or local displacements before and after welding. The deformation is then obtained through coordinate registration, contour comparison, and displacement calculation. Contact measurement is intuitive, but the number of measurement points is limited and the detection efficiency is low. Laser scanning can obtain dense point clouds, but the equipment cost is high, and it is sensitive to reflective surfaces and on-site vibrations. Visual measurement has the advantages of being non-contact, having a large coverage area, and facilitating continuous data acquisition, and has been increasingly used for post-weld deformation detection.
[0003] Existing binocular vision-based welding deformation detection methods typically extract feature points from left and right view images before welding, after welding, or after fixture release. They then use feature matching and binocular measurement to reconstruct the surface's three-dimensional coordinates, perform rigid body registration of the three-dimensional points in different states, and calculate the welding deformation based on the coordinate differences of corresponding points. While these methods can complete surface reconstruction and displacement measurement, fixture release causes translation, rotation, and elastic rebound of the welded part. Ordinary feature matching is prone to mismatches at corresponding points, resulting in measured displacements containing rigid body motion, constraint release displacement, and permanent deformation. This makes it difficult to distinguish the deformation components, leading to insufficient accuracy in the detection results.
[0004] Therefore, how to provide a welding deformation detection method and system based on image data processing is a problem that urgently needs to be solved by those skilled in the art. Summary of the Invention
[0005] One objective of this invention is to propose a welding deformation detection method and system based on image data processing. This invention fully utilizes binocular vision, feature matching, and three-dimensional coordinate analysis technology to fuse fixture projection, clamping force difference, and intervention phase into an improved XFeat model. It details the identification and correction process of the closed concentric points of the welded part in the states before intervention, release, re-clamping, and step-by-step release. Through reversible response kernel, non-response rigid body anchor point, and release increment field, it separates the reversible elastic release displacement from the constraint-coupled residual displacement, reconstructs the counterfactual free surface according to the fixture release sequence, and then uses the actual free surface to complete the correction, realizing the detection of longitudinal shrinkage, lateral shrinkage, angular deformation, out-of-plane deformation, and deformation position. It has the advantages of stable concentric point matching, small rigid body motion interference, clear distinction of deformation components, and high detection accuracy.
[0006] A welding deformation detection method based on image data processing according to an embodiment of the present invention includes:
[0007] Acquire binocular images of the multi-stage constraint state of the welded parts, and perform preprocessing on the binocular images of the multi-stage constraint state of the welded parts to obtain standard fixture intervention image data;
[0008] Standard fixture intervention image data is input into an improved XFeat model, which includes a shared feature backbone, an intervention conditional coding layer, a key point description layer, a non-commutative closure decoder, a joint geometric refinement layer, and a retrace reliability head to obtain closure concordance points.
[0009] Based on the spatial position, release displacement and clamping force difference of the associated closed concentric point of the clamping unit, a reversible response core is formed to determine the non-response rigid body anchoring point.
[0010] Based on the closed conjoint points of the step-by-step release state corrected by the non-responsive rigid body anchor point, the coordinate difference between adjacent states is calculated to obtain the release increment field.
[0011] Based on the reversible response kernel of the release clamp and the response overlapping clamp, the release increment field is inverted to obtain the reversible elastic release field and the constraint coupling residual field, and the necessary response kernels are selected.
[0012] The reversible elastic release field and constraint coupling residual field corresponding to the necessary response core are superimposed on the post-weld clamping surface according to the release order to obtain the antifactual free surface, and then corrected with the actual free surface to generate the corrected antifactual surface;
[0013] Calculate the coordinate difference between the corrected anti-factual surface and the pre-welding clamping surface, and output the longitudinal shrinkage, transverse shrinkage, angular deformation, out-of-plane deformation, and deformation location.
[0014] Optionally, the binocular images of the multi-stage constraint state of the welded parts specifically include binocular images of the fully clamped state before welding, binocular images of the fully clamped state after welding, binocular images of the state before intervention corresponding to each fixture unit, binocular images of the release state and the re-clamping state, binocular images of the release state acquired according to the release order of the fixtures, and binocular images of the actual completely free state after all fixture units are released. Each state binocular image includes a left view image and a right view image acquired synchronously.
[0015] Optionally, the preprocessing of the binocular image of the multi-stage constrained state of the welded part specifically includes state pairing, distortion correction, epipolar correction, effective area cropping, brightness normalization, reflective area marking, and size normalization.
[0016] Optionally, obtaining the closing concordance site includes:
[0017] An improved XFeat model is constructed, which includes a shared feature backbone, an intervention conditional coding layer, a key point description layer, a non-commutative closure decoder, a joint geometric refinement layer, and a homing reliability head.
[0018] Standard clamp intervention image data are input into the shared feature backbone according to the pre-intervention, release and re-clamping states. The basic features of the left and right view images of each state are extracted. The clamp unit position is projected onto the corresponding image, the clamping force difference is calculated and the intervention phase is encoded. After being fused by the intervention condition encoding layer, the intervention condition features are obtained.
[0019] The intervention condition features are input into the key point description layer to extract key point coordinates, 64-dimensional feature descriptions and image matching reliability. The matching relationship from pre-intervention to release, release to re-clamp and pre-intervention to re-clamp is established through a non-commutative closed decoder. The combined return position is obtained by combining the pre-intervention to release and release to re-clamp matching relationships and comparing it with the direct return position of the pre-intervention to re-clamp matching relationship to obtain the candidate closed colocation chain.
[0020] The key points of the candidate closed co-location chain are read in the left and right view images of the three states by the joint geometric refinement layer. Based on the binocular camera calibration parameters, the epipolar residual, reprojection residual, image closure residual and three-dimensional homing residual are jointly corrected to obtain the candidate closed co-location three-dimensional points.
[0021] The release displacement, repositioning, three-dimensional repositioning residual, clamping force recovery ratio, and reprojection error of the candidate closed co-location three-dimensional points are input into the repositioning reliability head to generate mechanical repositioning reliability. After fusion with the image matching reliability, the closed co-location points are selected.
[0022] The improved XFeat model was trained using a weighted sum of feature matching loss, non-commutative closure loss, and geometric homing loss as the optimization objective. The parameters of the shared feature backbone, intervention conditional encoding layer, key point description layer, non-commutative closure decoder, joint geometric refinement layer, and homing reliability head were continuously optimized. When the decrease in the joint loss on the validation set was less than 0.001 for 10 consecutive training epochs, the improved XFeat model was considered to have converged and training was stopped.
[0023] Optionally, determining the non-responsive rigid body anchor point includes:
[0024] Read the spatial position and clamping force of the closed co-position of the clamping unit before intervention, release and re-clamping states, calculate the release displacement, clamping force difference and three-dimensional return residual from before intervention to release state, and remove the closed co-position of the clamping unit whose three-dimensional return residual exceeds the upper limit of binocular measurement error.
[0025] The ratio of the release displacement of each closed co-position point to the difference in clamping force is used as the response intensity. Combined with the distance of the closed co-position point relative to the projected position of the fixture, the direction of the release displacement, and the spatial position, a reversible response core for each fixture unit is formed.
[0026] By superimposing the response quantities generated by all reversible response kernels at each closed concentric point, and screening out the closed concentric points where the synthetic response quantity and the change in the distance between different states do not exceed the upper limit of the binocular measurement error, the non-response rigid body anchor points are obtained.
[0027] Optionally, obtaining the release increment field includes:
[0028] Read the closed contiguous points of the fully clamped state after welding, each step of the release state and the actual fully free state. Using the non-responsive rigid body anchor point common to each state as the reference, calculate the rotation and translation parameters of each state relative to the fully clamped state after welding.
[0029] Based on the rotation and translation parameters, the corresponding closed coherent points are corrected, and the corrected closed coherent points are unified to the coordinate system of the fully clamped state after welding. Adjacent states are associated according to the order of clamp release.
[0030] Select common closure contiguous sites in adjacent states, calculate the three-dimensional coordinate difference of the same closure contiguous site between adjacent states, and write according to the surface position of the closure contiguous site and the corresponding release fixture unit to obtain the release increment field.
[0031] Optionally, the filtering of necessary response kernels includes:
[0032] Read the reversible response kernels of each release increment field and the corresponding release fixture unit according to the release order of the fixtures, and determine the fixtures where the response region intersects with the region where the release increment field is located as response overlapping fixtures, forming a set of candidate response kernels;
[0033] Based on the spatial location, response direction and response intensity of the candidate response kernel record, the response displacement of each closed co-location point is inverted and superimposed to obtain the reversible elastic release field. The reversible elastic release field is then subtracted from the release increment field to obtain the constrained coupling residual field.
[0034] Candidate response kernels are deleted one by one and inverted again. The increment of the release increment field reconstruction error before and after deletion is calculated. Candidate response kernels whose reconstruction error increment exceeds the upper limit of binocular measurement error are retained to obtain the necessary response kernels.
[0035] Optionally, generating the corrected counterfactual surface includes:
[0036] Read the necessary response kernel, reversible elastic release field and constraint coupling residual field corresponding to each release increment field according to the release order of the clamp. Transform the reversible elastic release field and constraint coupling residual field to the post-weld clamping surface coordinate system and associate them with the corresponding closed coherent points to obtain a unified release field sequence.
[0037] Using the post-weld clamped surface as the initial surface, the three-dimensional displacements of each closed contiguous point are superimposed and the coordinates are updated in sequence according to the unified release field sequence to obtain the counterfactual free surface;
[0038] The coordinates of the common closed concentric points of the counterfactual free surface and the actual free surface are compared. The response intensity of the necessary response kernel is adjusted according to the coordinate deviation and then superimposed again until the coordinate deviation does not exceed the upper limit of the binocular measurement error, thus generating the corrected counterfactual surface.
[0039] Optionally, the output of longitudinal shrinkage, lateral shrinkage, angular deformation, out-of-plane deformation, and deformation location includes:
[0040] Read the common closed concentric points of the corrected counterfactual surface and the pre-weld clamping surface, establish a welding coordinate system with the weld extension direction, weld transverse direction and surface normal, and unify the coordinates of the two surfaces based on the non-response rigid body anchor point to obtain the coordinate pairs of the same point.
[0041] Calculate the projection of the coordinate difference at the same point onto the weld extension direction, the weld transverse direction, and the surface normal to obtain the longitudinal shrinkage, transverse shrinkage, and out-of-plane deformation. Calculate the included angle between the surface normals on both sides of the weld to obtain the angular deformation.
[0042] The longitudinal shrinkage, transverse shrinkage, angular deformation, and out-of-plane deformation are associated with the spatial location of the closed coplanar site, and the maximum longitudinal shrinkage, maximum transverse shrinkage, maximum angular deformation, maximum out-of-plane deformation, and corresponding deformation location are extracted, and the welding deformation detection results are output.
[0043] A welding deformation detection system based on image data processing according to an embodiment of the present invention includes the following modules:
[0044] The image acquisition module is used to acquire and preprocess binocular images of the multi-stage constraint state of the welded parts to obtain standard fixture intervention image data;
[0045] The co-location extraction module is used to input standard fixture intervention image data into the improved XFeat model to obtain closed co-locations;
[0046] The response kernel construction module is used to associate the spatial location of the closed concentric point, the release displacement, and the clamping force difference to determine the non-responsive rigid body anchor point.
[0047] The incremental field generation module is used to correct the closed conjoint points of the step-by-step release state based on the non-responding rigid body anchor points to obtain the release incremental field.
[0048] The release field inversion module is used to invert the release increment field based on the reversible response kernel, obtain the reversible elastic release field and the constraint-coupled residual field, and screen the necessary response kernels;
[0049] The counterfact correction module is used to superimpose the reversible elastic release field and constraint coupling residual field corresponding to the necessary response kernel onto the post-weld clamping surface, and correct it with the actual free surface to generate a corrected counterfact surface;
[0050] The deformation output module is used to output the longitudinal shrinkage, lateral shrinkage, angular deformation, out-of-plane deformation, and deformation position.
[0051] The beneficial effects of this invention are:
[0052] This invention acquires binocular images of the welded part under the following conditions: fully clamped before welding, fully clamped after welding, with fixture unit intervention, step-by-step release, and in a completely free state. The fixture projection, clamping force difference, and intervention phase are fused into an improved XFeat model. Non-exchangeable closed matching is performed according to the sequence of pre-intervention, release, and re-clamping. Combined with binocular geometry, mechanical return reliability, and non-response rigid body anchor points, closed co-location point screening and coordinate correction are completed. This can reduce the impact of reflection interference, feature mismatch, and overall translation and rotation of the welded part on the detection results, and improve the continuous correspondence accuracy of the same surface position and the stability of three-dimensional displacement measurement under different constraint states.
[0053] This invention forms a reversible response core based on the release displacement, clamping force difference, response direction, and spatial position of the closed co-location point. It constructs a release increment field through a step-by-step release state and inverts the release increment field into a reversible elastic release field and a constraint coupling residual field. This allows it to distinguish between elastic rebound caused by clamp release, constraint coupling displacement between clamps, and permanent deformation formed by welding. By selecting necessary response cores, reconstructing the counterfactual free surface according to the clamp release sequence, and correcting using the actual free surface, it achieves a unified output of longitudinal shrinkage, lateral shrinkage, angular deformation, out-of-plane deformation, and corresponding deformation positions. This invention has the beneficial effects of complete detection range, clear deformation components, verifiable results, and high detection accuracy. Attached Figure Description
[0054] The accompanying drawings are provided to further illustrate the invention and form part of the specification. They are used in conjunction with embodiments of the invention to explain the invention and do not constitute a limitation thereof. In the drawings:
[0055] Figure 1 This is a flowchart of a welding deformation detection method based on image data processing proposed in this invention;
[0056] Figure 2 This is a schematic diagram of the structure of the improved XFeat model for a welding deformation detection method based on image data processing proposed in this invention;
[0057] Figure 3 This is a schematic diagram of the structure of a welding deformation detection system based on image data processing proposed in this invention. Detailed Implementation
[0058] The present invention will now be described in further detail with reference to the accompanying drawings. These drawings are simplified schematic diagrams, illustrating only the basic structure of the invention, and therefore only show the components relevant to the invention.
[0059] refer to Figure 1 and Figure 2 A welding deformation detection method based on image data processing, comprising:
[0060] Acquire binocular images of the multi-stage constraint state of the welded parts, and perform preprocessing on the binocular images of the multi-stage constraint state of the welded parts to obtain standard fixture intervention image data;
[0061] Standard fixture intervention image data is input into an improved XFeat model, which includes a shared feature backbone, an intervention conditional coding layer, a key point description layer, a non-commutative closure decoder, a joint geometric refinement layer, and a retrace reliability head to obtain closure concordance points.
[0062] Based on the spatial position, release displacement and clamping force difference of the associated closed concentric point of the clamping unit, a reversible response core is formed to determine the non-response rigid body anchoring point.
[0063] Based on the closed conjoint points of the step-by-step release state corrected by the non-responsive rigid body anchor point, the coordinate difference between adjacent states is calculated to obtain the release increment field.
[0064] Based on the reversible response kernel of the release clamp and the response overlapping clamp, the release increment field is inverted to obtain the reversible elastic release field and the constraint coupling residual field, and the necessary response kernels are selected.
[0065] The reversible elastic release field and constraint coupling residual field corresponding to the necessary response core are superimposed on the post-weld clamping surface according to the release order to obtain the antifactual free surface, and then corrected with the actual free surface to generate the corrected antifactual surface;
[0066] Calculate the coordinate difference between the corrected anti-factual surface and the pre-welding clamping surface, and output the longitudinal shrinkage, transverse shrinkage, angular deformation, out-of-plane deformation, and deformation location.
[0067] In this embodiment, the multi-stage constraint state binocular images of the welded parts specifically include binocular images of the fully clamped state before welding, binocular images of the fully clamped state after welding, binocular images of the pre-intervention state corresponding to each fixture unit, binocular images of the release state and the re-clamping state, binocular images of the progressively released state acquired according to the fixture release sequence, and binocular images of the actual completely free state after all fixture units have been released. Each state binocular image includes a synchronously acquired left view image and a right view image, wherein:
[0068] The binocular image of the fully clamped state before welding refers to the left and right view images of the welded part taken when all clamping units maintain the rated clamping force before the start of the welding operation. The binocular image of the fully clamped state after welding refers to the left and right view images of the welded part taken when the welding operation is completed and the temperature of the welded part drops to room temperature, while all clamping units still maintain the rated clamping force.
[0069] A fixture unit refers to a clamping component in a welding fixture that has an independent number and can independently perform clamping, releasing, and re-clamping actions;
[0070] The pre-intervention state binocular image refers to the left and right view images of the weldment collected before the target clamping unit is released and all clamping units maintain the current clamping state. The release state binocular image refers to the left and right view images of the weldment collected when the clamping force of the target clamping unit drops to 0 and the other clamping units maintain the original clamping force. The re-clamping state binocular image refers to the left and right view images of the weldment collected when the target clamping unit is restored to the pre-intervention clamping force and the other clamping units maintain the original clamping force.
[0071] The clamp release sequence refers to the ordered relationship in which the clamping forces decrease to 0 sequentially according to the clamp unit numbering.
[0072] The step-by-step release state binocular image refers to the left and right view images of the welded part acquired after each clamp unit is released in the clamp release sequence. The clamping force of the released clamp units is kept at 0, and the clamp units that have not been released maintain their original clamping force.
[0073] The actual fully free state binocular image after all fixture units are released refers to the left and right view images of the welded part acquired after the clamping force of all fixture units drops to 0 and the surface position of the welded part stabilizes.
[0074] In this embodiment, the preprocessing of the binocular image of the multi-stage constraint state of the welded part specifically includes state pairing, distortion correction, epipolar correction, effective area cropping, brightness normalization, reflective area marking, and size normalization, wherein:
[0075] State pairing refers to reading the weldment identifier, constraint state identifier, fixture unit number, intervention phase, camera number and acquisition timestamp corresponding to each image, forming a state binocular image pair between left and right view images with the same weldment identifier, constraint state identifier, fixture unit number and intervention phase and acquisition timestamp difference of no more than 2 milliseconds, and deleting images with acquisition timestamp difference greater than 2 milliseconds;
[0076] Brightness normalization refers to taking the mean gray value and standard deviation of the gray value of the effective area image in the fully clamped state before welding as the benchmark, subtracting the corresponding mean gray value from the pixel gray value of the other constrained effective area image, dividing by the corresponding standard deviation, multiplying by the benchmark gray value standard deviation and adding the benchmark gray value, setting gray values less than 0 to 0, and setting gray values greater than 255 to 255 to obtain a brightness normalized image.
[0077] The reflective area marking method involves setting pixels with a brightness value of not less than 245 and a saturation value of not more than 25 to 1, and setting the remaining pixels to 0. The method involves checking the 3×3 neighborhood pixel by pixel, setting the center pixel with at least 5 pixels in the neighborhood with a value of 1 to 1, connecting the pixels with a value of 1 according to the 8-neighborhood, deleting connected regions with an area of less than 9 pixels, setting the pixels in the retained region to 1, and setting the remaining pixels to 0, thus obtaining the reflective area mask.
[0078] Size normalization specifically involves maintaining the aspect ratio of the brightness-normalized image, scaling the image to a width of no more than 1280 pixels and a height of no more than 960 pixels, and filling the unfilled areas with a grayscale value of 0.
[0079] In this embodiment, obtaining the closed concordant site includes:
[0080] An improved XFeat model is constructed, comprising a shared feature backbone, an intervention conditional coding layer, a keypoint description layer, a non-commutative closure decoder, a joint geometric refinement layer, and a homing reliability head, wherein:
[0081] The improved XFeat model is constructed as follows:
[0082] The lightweight convolutional backbone of the traditional XFeat model is optimized by inputting the pre-intervention state image, release state image and re-clamp state image into the same set of convolutional parameters to obtain a shared feature backbone, so that the three state images adopt the same feature extraction scale and feature dimension, reducing the feature shift caused by state changes.
[0083] By adding fixture projection, clamping force difference and intervention phase fusion processing between the lightweight convolutional backbone and the key point detection branch of the traditional XFeat model, an intervention conditional coding layer is obtained. The key point detection branch and the feature description branch are combined to obtain the key point description layer. This enables the key point coordinates, 64-dimensional feature description and image matching reliability to be associated with the same fixture intervention state, thereby improving the matching accuracy of the same surface position under different intervention phases.
[0084] Add sequential matching processing from pre-intervention to release, release to re-clamp, and pre-intervention to re-clamp at the output of the key point description layer to obtain a non-switched closed decoder. By comparing the combined return position and the direct return position, the matching relationship that does not conform to the order of pre-intervention, release, and re-clamp is eliminated, thereby improving the reliability of closed matching.
[0085] Binocular geometric and mechanical homing correction processing is added to the output of the non-switched closed decoder to obtain a joint geometric refinement layer. Release displacement, re-clamping homing and clamping force recovery ratio fusion processing is added to the traditional image matching reliability output to obtain a homing reliability head and reduce the coordinate deviation of the closure co-point.
[0086] An improved XFeat model is obtained by combining a shared feature backbone, an intervention condition coding layer, a key point description layer, a non-commutative closed decoder, a joint geometric refinement layer, and a homing reliability head, which improves matching stability, 3D coordinate accuracy, and reversible response recognition reliability.
[0087] Standard clamp intervention image data are input into a shared feature backbone according to the pre-intervention, release, and re-clamping states. Basic features of the left and right view images for each state are extracted. The clamp unit positions are projected onto the corresponding images, the clamping force difference is calculated, and the intervention phase is encoded. These features are then fused through an intervention condition encoding layer to obtain the intervention condition features, where:
[0088] The shared feature backbone includes:
[0089] Status image buffer: Stores left and right view images of the pre-intervention, release, and re-clamping states in the standard clamp intervention image data;
[0090] Convolution parameter register: stores the convolution weights and biases used in the three feature extractions. The left and right views share the same parameters in the three states.
[0091] Intermediate feature buffer: stores the 16-dimensional and 32-dimensional features obtained from the first two feature extractions;
[0092] Basic feature buffer: stores the 64-dimensional basic features corresponding to the left and right view images of each state;
[0093] Extract the basic features of the left and right view images for each state, specifically:
[0094] Read the left and right view images of the pre-intervention state, release state, and re-clamping state from the standard clamp intervention image data. Input each image into the shared feature backbone. The first-level convolution reads a 3×3 neighborhood every 2 pixels. Multiply the neighborhood pixel values with the trained convolution weights one by one and sum them. Then add the corresponding bias. Set the negative result to 0 to form a 16-dimensional feature. The second-level convolution converts the 16-dimensional feature into a 32-dimensional feature in the same process. The third-level convolution converts the 32-dimensional feature into a 64-dimensional feature. All three levels of convolution reduce the feature width and height to 1 / 2 of the input end. Finally, a 64-dimensional basic feature with a width and height of 1 / 8 of the original image is obtained.
[0095] Projecting the position of the fixture unit onto the corresponding image is specifically as follows:
[0096] The three-dimensional coordinates of the fixture unit in the welding coordinate system, as well as the rotation parameters, translation parameters, lateral focal length, longitudinal focal length, and principal point coordinates of the left and right cameras, are read. First, the three-dimensional coordinates of the fixture unit are converted into camera coordinates using the rotation and translation parameters. The camera coordinates are designated as lateral coordinates, longitudinal coordinates, and depth coordinates. The lateral focal length is multiplied by the ratio of the lateral coordinate to the depth coordinate, and then the lateral principal point coordinate is added to obtain the lateral coordinate of the fixture projection position. The longitudinal focal length is multiplied by the ratio of the longitudinal coordinate to the depth coordinate, and then the longitudinal principal point coordinate is added to obtain the ordinate of the fixture projection position. The two coordinates are divided by 8 to obtain the projection position of the fixture unit in the basic features. With the projection position as the center, the value of the center position is set to 1. For each additional feature pixel, the value is reduced by 0.125. The value of the position with a distance of 8 feature pixels is set to 0, thus forming the fixture projection feature.
[0097] The clamping force difference is calculated and the intervention phase is encoded, specifically as follows:
[0098] Read the clamping force of the same clamping unit in the pre-intervention state, release state and re-clamping state. Subtract the clamping force of the corresponding state from the clamping force in the pre-intervention state to obtain the clamping force difference in the corresponding state. Then divide the clamping force difference by the clamping force in the pre-intervention state to obtain the normalized clamping force difference between 0 and 1. Represent the pre-intervention state as 1, 0, 0, the release state as 0, 1, 0, and the re-clamping state as 0, 0, 1 to obtain the 3D intervention phase code.
[0099] The intervention condition coding layer includes:
[0100] Fixture projection register: stores the fixture unit position in the corresponding image and the fixture projection features;
[0101] Clamping force difference register: stores the clamping force difference corresponding to each state;
[0102] Intervention phase register: stores the intervention phase corresponding to the pre-intervention, release, and re-clamping states;
[0103] Conditional feature buffer: stores basic features, fixture projection, clamping force difference, and intervention conditional features formed by intervention phase fusion;
[0104] The characteristics of the intervention conditions were obtained, specifically:
[0105] The 64 basic features are used as the first 64 dimensions of data. The fixture projection features are used as the 65th dimension of data. The normalized clamping force difference is copied to all feature positions and used as the 66th dimension of data. The 3D intervention phase code is copied to all feature positions and used as the 67th to 69th dimensions of data, forming a 69-dimensional fusion feature. For each feature position and each output dimension, the 69 fusion feature values are multiplied by the corresponding weights obtained from training. The 69 products are added together and the corresponding bias is added. Negative results are set to 0. The 64 output dimensions are calculated in sequence to obtain the 64-dimensional intervention condition features.
[0106] The intervention condition features are input into the keypoint description layer to extract keypoint coordinates, 64-dimensional feature descriptors, and image matching reliability. A non-commutative closure decoder is used to establish matching relationships from pre-intervention to release, release to re-clamp, and pre-intervention to re-clamp. Combining the pre-intervention to release and release to re-clamp matching relationships yields the combined return position, which is compared with the direct return position of the pre-intervention to re-clamp matching relationship to obtain candidate closed colocation chains, where:
[0107] The key point description layer includes:
[0108] Keypoint Response Register: Stores the keypoint response values corresponding to each feature location;
[0109] Key point coordinate cache: Stores the key point coordinates of the filtered key points;
[0110] Feature description buffer: stores the 64-dimensional feature descriptions corresponding to each key point;
[0111] Image matching reliability register: stores the image matching reliability corresponding to each key point;
[0112] Extracting keypoint coordinates, 64-dimensional feature descriptors, and image matching reliability, specifically:
[0113] For each feature location in the intervention condition features, the 64 feature values are multiplied by the trained keypoint response weights. The products are summed and a response bias is added to obtain the original keypoint response value. Then, the original keypoint response value is converted to a keypoint response value between 0 and 1 by dividing by 1 and the sum of the negative exponent of the original response value. The location with the largest keypoint response value and not less than 0.6 in the 3×3 neighborhood is retained. Locations covered by reflective area masks are deleted. The top 2048 locations are retained according to the keypoint response value from largest to smallest. For each retained location, two sets of trained keypoint response weights are used. The offset weights are multiplied and summed with the 64-dimensional intervention condition features one by one, and a bias is added to obtain the horizontal offset and the vertical offset. The two offsets are limited to between -0.5 and 0.5. They are added to the horizontal and vertical coordinates of the retained position respectively and multiplied by 8 to obtain the key point coordinates. For each key point, 64 sets of descriptive weights are multiplied and summed with the 64-dimensional intervention condition features at that position one by one, and a bias is added to form 64 descriptive values. Each descriptive value is then divided by the square root of the sum of the squares of the 64 descriptive values to obtain the 64-dimensional feature descriptive quantity. The corresponding key point response value is recorded as the image matching reliability.
[0114] Non-switched closed decoders include:
[0115] Matching Relationship Pool: Stores matching relationships from pre-intervention to release, from release to re-clamping, and from pre-intervention to re-clamping, respectively;
[0116] Combined Return Position Register: Stores the combined return position obtained by combining the first two matching relationships;
[0117] Direct return position register: stores the direct return position obtained from the matching relationship between the two clamps before intervention;
[0118] Candidate closed covariate chain pool: stores candidate closed covariate chains that meet the requirements of comparing the combined return position with the direct return position;
[0119] The matching relationships from pre-intervention to release, release to re-clamp, and pre-intervention to re-clamp are established using a non-commutative closed decoder, specifically as follows:
[0120] The key point coordinates, 64-dimensional feature descriptors, and image matching reliability of three sets of state images under the same camera view are read respectively. The 64-dimensional feature descriptors of two key points are multiplied by the same dimension and summed to obtain the description similarity between the two key points. For each key point in the source state, the target state key point with the largest description similarity is selected. Then, the source state key point with the largest description similarity is selected from the target state in reverse. Key point pairs with consistent forward and reverse selection results, description similarity of not less than 0.8, and image matching reliability of both ends of the key point are retained to obtain the matching relationship from before intervention to release, the matching relationship from release to re-clamping, and the matching relationship from before intervention to re-clamping.
[0121] The combined return position is obtained by matching the relationship between pre-intervention and release and release to the compound clamp, specifically:
[0122] Read the key points of the pre-intervention state and the corresponding key points of the release state in the pre-intervention to release matching relationship. Search for the corresponding key points of the double clamping state in the release to double clamping matching relationship according to the key point number of the release state. Use the coordinates of the found key points of the double clamping state as the combined return position. Search for the key points of the double clamping state in the pre-intervention to double clamping matching relationship according to the same key point number of the pre-intervention state. Use the coordinates of the found key points of the double clamping state as the direct return position. Delete the matching results that do not obtain the combined return position and the direct return position at the same time.
[0123] The candidate closed covariate chain is obtained as follows:
[0124] The x-coordinate difference is obtained by subtracting the x-coordinate of the direct return position from the x-coordinate of the combined return position. The y-coordinate difference is obtained by subtracting the y-coordinate of the direct return position from the y-coordinate of the combined return position. The square of the x-coordinate difference and the square of the y-coordinate difference are added together and the square root is taken to obtain the return position distance. Matching results with a return position distance of no more than 1.5 pixels are retained. The corresponding pre-intervention state key points, release state key points, combined return position and direct return position are associated in the order of pre-intervention, release and re-clamping. The clamp unit number, camera number, key point coordinates, 64-dimensional feature description and image matching reliability are written into the information to obtain the candidate closed colocation chain.
[0125] The joint geometric refinement layer reads key points of candidate closure co-location chains in the left and right view images of three states. Based on the binocular camera calibration parameters, it jointly corrects the epipolar residual, reprojection residual, image closure residual, and 3D homogeneity residual to obtain the candidate closure co-location 3D points, where:
[0126] The joint geometry refinement layer includes:
[0127] Binocular camera calibration parameter register: stores the calibration parameters of the binocular camera;
[0128] State key point cache: stores the key points of the candidate closed covariant chain in the left and right view images of the three states;
[0129] Residual register: stores epipolar residuals, reprojection residuals, image closure residuals, and 3D homing residuals;
[0130] Candidate Closed Coordinate 3D Point Pool: Stores candidate closed coordinate 3D points obtained after joint correction;
[0131] The key points of the candidate closed colocation chain in the left and right view images of the three states refer to the key points of the left and right view images of the pre-intervention state, the key points of the left and right view images of the release state, and the key points of the left and right view images of the re-clamping state corresponding to the same weld surface position in the candidate closed colocation chain. Each key point records the horizontal coordinate, vertical coordinate, 64-dimensional feature description and image matching reliability.
[0132] The candidate closed co-location 3D points are obtained as follows:
[0133] Read the combined return position and direct return position of the double-clamp state, take the average of the x-coordinates of the two positions as the corrected x-coordinate of the double-clamp state, take the average of the y-coordinates of the two positions as the corrected y-coordinate of the double-clamp state, and take the pixel distance between the two positions as the image closure residual. Based on the binocular camera calibration parameters, form the epipolar relationship between the key points of the left view image and the corresponding positions of the right view image. Substitute the coordinates of the key points of the left view image into the epipolar relationship, calculate the theoretical y-coordinate corresponding to the same x-coordinate in the right view image, take the absolute value of the difference between the actual y-coordinate and the theoretical y-coordinate of the key points of the right view image as the epipolar residual, and replace the actual y-coordinate with the theoretical y-coordinate.
[0134] By subtracting the corresponding right-view keypoint's x-coordinate from the left-view keypoint's x-coordinate in the pre-intervention, release, and re-clamping states, the disparity for each state is obtained. The product of the binocular camera's focal length and baseline length, divided by the corresponding disparity, yields the depth coordinate for that state. The lateral coordinate is obtained by subtracting the lateral principal point coordinate from the left-view keypoint's x-coordinate, multiplying by the depth coordinate, and dividing by the lateral focal length. Similarly, the lateral coordinate is obtained by subtracting the longitudinal principal point coordinate from the left-view keypoint's ordinate, multiplying by the depth coordinate, and dividing by the longitudinal focal length. Thus, the 3D coordinates for the pre-intervention, release, and re-clamping states are obtained. These 3D coordinates are then... The binocular camera calibration parameters are converted into the corresponding projection coordinates in the left and right view images. The pixel distance between each projection coordinate and the corresponding key point coordinate is calculated. The average value of all pixel distances is then calculated to obtain the reprojection error. The spatial distance between the three-dimensional coordinates of the pre-intervention state and the three-dimensional coordinates of the re-clamping state is calculated to obtain the three-dimensional return residual. The three-dimensional coordinates of the pre-intervention state, the release state, and the re-clamping state with epipolar residuals not greater than 0.5 pixels, reprojection errors not greater than 1 pixel, and three-dimensional return residuals not greater than 0.2 mm are retained. The image closure residual, reprojection error, and three-dimensional return residual are correlated to obtain candidate closure co-location three-dimensional points.
[0135] The release displacement, repositioning, 3D repositioning residual, clamping force recovery ratio, and reprojection error of the candidate closure concordant 3D points are input into the repositioning reliability header to generate mechanical repositioning reliability. This reliability is then fused with image matching reliability to select the closure concordant points, where:
[0136] The return reliability header includes:
[0137] Return data register: stores release displacement, re-clamp return, three-dimensional return residual, clamping force recovery ratio, and reprojection error;
[0138] Reliability parameter register: stores the weights and biases used to generate the reliability of mechanical return;
[0139] Mechanical return reliability register: stores the generated mechanical return reliability;
[0140] Closed co-location pool: stores closed co-locations obtained by fusing and filtering mechanical return reliability and image matching reliability;
[0141] The reliability of mechanical return is generated as follows:
[0142] Read the three-dimensional coordinates of the candidate closed co-positioning point before intervention, the three-dimensional coordinates of the release state, and the three-dimensional coordinates of the re-clamping state. Calculate the spatial distance from the three-dimensional coordinates of the pre-intervention state to the three-dimensional coordinates of the release state to obtain the release displacement. Calculate the spatial distance from the three-dimensional coordinates of the release state to the three-dimensional coordinates of the re-clamping state to obtain the re-clamping return. Calculate the absolute value of the difference between the release displacement and the re-clamping return and divide it by the release displacement to obtain the displacement recovery deviation. Divide the clamping force in the re-clamping state by the clamping force in the pre-intervention state to obtain the clamping force recovery ratio. Use the displacement recovery deviation of 0.1, the three-dimensional return residual of 0.2 mm, the difference between the clamping force recovery ratio and 1 of 0.05, and the reprojection error of 1 pixel as the limits for the corresponding scores to drop to 0. When the error is 0, the score is 1. The intermediate values decrease from 1 to 0 according to the proportion of the error to the corresponding limit to obtain the displacement recovery score, three-dimensional return score, clamping force recovery score, and reprojection score. Multiply the four scores by 0.25, 0.35, 0.20, and 0.20 respectively and add them together to generate the mechanical return reliability.
[0143] After fusing with image matching reliability, closed concordant sites are obtained through screening, specifically:
[0144] The image matching reliability of the key points of the left and right view images corresponding to the candidate closure co-positioning 3D points before intervention, release, and re-clamping is read. The minimum value is selected as the image matching reliability of the candidate closure co-positioning 3D points. The mechanical return reliability and the image matching reliability are multiplied by 0.5 respectively and then added to obtain the fusion reliability. The candidate closure co-positioning 3D points with a fusion reliability of not less than 0.75 are retained. The retained three-dimensional coordinates of the pre-intervention state, release state, and re-clamping state and the fixture unit number are associated to obtain the closure co-positioning point.
[0145] The improved XFeat model was trained using a weighted sum of feature matching loss, non-commutative closure loss, and geometric homing loss as the optimization objective. The parameters of the shared feature backbone, intervention conditional encoding layer, keypoint description layer, non-commutative closure decoder, joint geometric refinement layer, and homing reliability head were continuously optimized. The improved XFeat model was considered converged and training was stopped when the decrease in the joint loss on the validation set was less than 0.001 for 10 consecutive training epochs.
[0146] The improved XFeat model was trained as follows:
[0147] The left and right view images of the pre-intervention state, release state and re-clamping state with the same surface position of the welded part are divided into training set and validation set in an 8:2 ratio. Each time, 8 sets of training images are read and input into the improved XFeat model, and the output is key point coordinates, 64-dimensional feature description, image matching reliability, combined return position, direct return position and candidate closed co-location 3D points.
[0148] The 64-dimensional feature descriptors of correctly matched keypoint pairs are multiplied dimension by dimension and summed. The sum is then subtracted from 1 and squared. Similarly, the 64-dimensional feature descriptors of incorrectly matched keypoint pairs are multiplied dimension by dimension and summed. If the sum is greater than 0.2, the portion exceeding 0.2 is squared; otherwise, it is set to 0. The average of the results for all correctly matched and incorrectly matched keypoint pairs is calculated and summed to obtain the feature matching loss. The square root of the sum of the squares of the differences between the x-coordinate of the combined returned position and the x-coordinate of the directly returned position, and the y-coordinate of the combined returned position and the directly returned position, is then calculated. Divide by the image diagonal length to calculate the average of all matching results, obtaining the non-commutative closure loss. Divide the epipolar residual by 0.5 pixels, the reprojection error by 1 pixel, and the 3D homing residual by 0.2 mm, and limit each calculation result to between 0 and 1. Subtract the mechanical homing reliability from the homing reliability output by the homing reliability head and take the absolute value. Multiply the four results by 0.20, 0.25, 0.30, and 0.25 respectively, and add them together to obtain the geometric homing loss. Multiply the feature matching loss, non-commutative closure loss, and geometric homing loss by 0.45, 0.25, and 0.30 respectively, and add them together to obtain the joint loss.
[0149] Based on the direction of change of the joint loss relative to the parameters of the improved XFeat model, each parameter of the improved XFeat model is subtracted from the product of the corresponding change value and 0.0001, completing one parameter update. After all images in the training set have been calculated, it is recorded as one training epoch. The joint loss of the validation set is calculated using the updated improved XFeat model. The decrease in the joint loss of the validation set is obtained by subtracting the joint loss of the validation set of the previous training epoch from the joint loss of the validation set of the current training epoch. When the decrease in the joint loss of the validation set is less than 0.001 for 10 consecutive training epochs, the parameter update is stopped and the improved XFeat model that has been trained is obtained.
[0150] In this embodiment, determining the non-responsive rigid body anchor point includes:
[0151] The spatial position and clamping force of the closed concentric points are read according to the clamping unit before intervention, release, and re-clamping states. The release displacement, clamping force difference, and three-dimensional return residual from before intervention to the release state are calculated. Closed concentric points whose three-dimensional return residual exceeds the upper limit of binocular measurement error are eliminated. Among them:
[0152] The spatial position and clamping force of the clamping point at the closing position are read according to the clamping unit before intervention, release, and re-clamping states, specifically as follows:
[0153] Based on the fixture unit number associated with the closing co-location point, the closing co-location points obtained during the intervention process of the same fixture unit are grouped together. The three-dimensional coordinates of each closing co-location point before intervention, the three-dimensional coordinates of the release state, and the three-dimensional coordinates of the re-clamping state are read. At the same time, the clamping force of the fixture unit in the pre-intervention state, the release state, and the re-clamping state is read, so that the three-dimensional coordinates of the three states are associated with the clamping force of the three states one by one according to the state.
[0154] The calculations of the release displacement, clamping force difference, and three-dimensional return residual from before intervention to the release state are as follows:
[0155] Subtract the corresponding coordinates of the three-dimensional coordinates before intervention from the horizontal, vertical, and depth coordinates of the three-dimensional coordinates in the release state to obtain the three coordinate components of the release displacement. Add the squares of the three coordinate components and take the square root to obtain the release displacement. Subtract the clamping force in the release state from the clamping force in the pre-intervention state to obtain the clamping force difference. Subtract the corresponding coordinates of the three-dimensional coordinates before intervention from the three coordinates of the re-clamping state, add the squares of the three coordinate differences and take the square root to obtain the three-dimensional return residual.
[0156] The upper limit of binocular measurement error refers to the maximum spatial distance between the three-dimensional coordinates measured 10 times consecutively by a binocular camera at the same calibration point and the average of the 10 measured three-dimensional coordinates. The upper limit of binocular measurement error is set to 0.2 mm.
[0157] The following steps are taken to remove closed contiguous sites where the 3D repositioning residual exceeds the upper limit of binocular measurement error:
[0158] Compare the three-dimensional return residual of each closed co-location point with 0.2 mm one by one, delete the closed co-location points with a three-dimensional return residual greater than 0.2 mm, retain the closed co-location points with a three-dimensional return residual not greater than 0.2 mm, and retain the three-dimensional coordinates of the three states corresponding to the closed co-location points, the release displacement, the amount of release displacement, the clamping force difference and the fixture unit number.
[0159] The ratio of the release displacement to the clamping force difference at each closed co-position is used as the response intensity. Combined with the distance between the closed co-position and the projected position of the fixture, the direction of the release displacement, and the spatial position, a reversible response core for each fixture unit is formed, wherein:
[0160] The reversible response core of each fixture unit is formed as follows:
[0161] The response intensity is obtained by dividing the release displacement of each closed co-location point by the clamping force difference of the corresponding fixture unit. The release displacement direction is obtained by dividing the three coordinate components of the release displacement by the release displacement amount. When the release displacement amount is 0, the three coordinate components of the release displacement direction are all set to 0. Taking the left view image of the state before intervention as the reference, the horizontal and vertical coordinates of the fixture projection position are subtracted from the horizontal and vertical coordinates of the closed co-location point respectively. The square root of the sum of the squares of the two coordinate differences is used to obtain the distance between the closed co-location point and the fixture projection position. According to the fixture unit number, the three-dimensional coordinates of the state before intervention, the distance between the closed co-location point and the fixture projection position, the response intensity and the release displacement direction of each closed co-location point are associated and arranged in ascending order of the distance between the closed co-location point and the fixture projection position to form the reversible response kernel of each fixture unit.
[0162] By superimposing the responses generated by all reversible response kernels at each closed concentric point, and selecting closed concentric points where the synthetic response and the change in distance between different states do not exceed the upper limit of binocular measurement error, non-response rigid body anchor points are obtained, where:
[0163] The sum of the responses generated by all reversible response kernels at each closed congruent site is as follows:
[0164] For the same closed contiguous site that exists in all reversible response kernels, the response intensity and release displacement direction recorded in each reversible response kernel are read respectively. The response intensity is multiplied by the clamping force difference of the corresponding fixture unit to obtain the response displacement. The response displacement is then multiplied by the three coordinate components of the release displacement direction to obtain the three-dimensional response displacement generated by the corresponding reversible response kernel. The three-dimensional response displacements generated by all reversible response kernels are added in the horizontal, vertical and depth directions respectively to obtain the composite response displacement. The square root of the sum of the squares of the three coordinate components of the composite response displacement is obtained to obtain the composite response amount.
[0165] The non-responsive rigid body anchor point is obtained as follows:
[0166] Retain closed concentric points whose synthetic response is no greater than the upper limit of binocular measurement error. Pair the retained closed concentric points together and calculate the spatial distance of each pair of closed concentric points in the pre-intervention state, release state, and re-clamping state. Take the absolute value of the spatial distance in the release state minus the spatial distance in the pre-intervention state, and take the absolute value of the spatial distance in the re-clamping state minus the spatial distance in the pre-intervention state. Take the maximum of the two absolute values as the mutual distance change. Check the mutual distance change formed during the intervention of each clamp unit one by one. Retain closed concentric points whose synthetic response is no greater than 0.2 mm and whose mutual distance change is no greater than 0.2 mm. Associate the closed concentric point number with the three-dimensional coordinates in the pre-intervention state to obtain the non-response rigid body anchor point.
[0167] In this embodiment, obtaining the release increment field includes:
[0168] Read the contiguous points of the fully clamped state after welding, each progressively released state, and the actual fully free state. Using the common non-responsive rigid body anchor point for each state as a reference, calculate the rotation and translation parameters of each state relative to the fully clamped state after welding, where:
[0169] A non-responsive rigid body anchor point common to all states refers to a non-responsive rigid body anchor point that has the same closed concentric point number in the fully clamped state after welding, each step-by-step release state, and the actual fully free state, and whose synthetic response and mutual distance changes do not exceed the upper limit of binocular measurement error during the intervention of each fixture unit.
[0170] The rotation and translation parameters for each state relative to the fully clamped state after welding are determined as follows:
[0171] Three non-responsive rigid body anchor points not located on the same straight line are selected from the non-responsive rigid body anchor points common to all states. These three non-responsive rigid body anchor points are successively named the first non-responsive rigid body anchor point, the second non-responsive rigid body anchor point, and the third non-responsive rigid body anchor point. In the fully clamped state after welding, the direction from the first non-responsive rigid body anchor point to the second non-responsive rigid body anchor point is taken as the first reference direction. The part of the direction from the first non-responsive rigid body anchor point to the third non-responsive rigid body anchor point that is perpendicular to the first reference direction is taken as the second reference direction. The direction that is perpendicular to both the first and second reference directions is taken as the third reference direction. The three reference directions for the state to be corrected are formed in the same way.
[0172] Calculate the projection values of the three-dimensional coordinates of the state to be corrected in the three reference directions of the state to be corrected. Then multiply the three projection values by the three reference directions corresponding to the fully clamped state after welding and add them together to form the rotation parameters that convert the direction of the state to be corrected into the direction of the fully clamped state after welding. Add the lateral coordinates of all common non-responsive rigid body anchor points in the fully clamped state after welding and divide by the number of non-responsive rigid body anchor points to obtain the lateral coordinates of the anchor center in the fully clamped state after welding. Calculate the longitudinal coordinates and depth coordinates in the same way to obtain the anchor center in the fully clamped state after welding. Calculate the anchor center of the state to be corrected in the same way. Use the rotation parameters to transform the anchor center of the state to be corrected to obtain the rotated anchor center. Subtract the corresponding coordinates of the rotated anchor center from the lateral coordinates, longitudinal coordinates, and depth coordinates of the anchor center in the fully clamped state after welding to obtain the lateral translation, longitudinal translation, and depth translation. Combine the three translations to form the translation parameters.
[0173] Based on the rotation and translation parameters, the corresponding closed coherent points are corrected, and the corrected closed coherent points are unified to the coordinate system of the fully clamped state after welding. Adjacent states are then associated according to the fixture release order, where:
[0174] The closed congruent point of the corresponding state is corrected based on rotation and translation parameters, specifically as follows:
[0175] Read the three-dimensional coordinates of each closed co-point in the state to be corrected, calculate the projection values of the three-dimensional coordinates in the first reference direction, the second reference direction and the third reference direction of the state to be corrected, respectively, multiply the three projection values by the first reference direction, the second reference direction and the third reference direction corresponding to the fully clamped state after welding, and then add the three products to obtain the rotated three-dimensional coordinates. Add the lateral coordinate, longitudinal coordinate and depth coordinate of the rotated three-dimensional coordinates to the lateral translation, longitudinal translation and depth translation respectively to obtain the corrected three-dimensional coordinates, and replace the original three-dimensional coordinates of the closed co-points in the state to be corrected with the corrected three-dimensional coordinates, so that the closed co-points of the corresponding states are unified to the coordinate system of the fully clamped state after welding.
[0176] The adjacent states are associated according to the order of clamp release, specifically:
[0177] Read the status identifiers, collection timestamps, and fixture release order corresponding to the fully clamped state after welding, each step-by-step release state, and the actual fully free state after welding. Arrange the fully clamped state after welding at the first position, arrange each step-by-step release state in the order of fixture release, and arrange the actual fully free state at the last position. Associate the previous state with the next state in the arrangement as adjacent states. Compare the clamping force of each fixture unit in the two adjacent states. Determine the fixture unit whose clamping force changes from a non-zero value to 0 as the corresponding release fixture unit, and associate the corresponding release fixture unit number with the two adjacent states.
[0178] By selecting common contiguous sites in adjacent states, calculating the three-dimensional coordinate difference between adjacent states for the same contiguous site, and writing the data according to the surface position of the contiguous site and the corresponding release fixture unit, the release increment field is obtained, where:
[0179] Calculate the three-dimensional coordinate difference between adjacent states for the same closed congruent point, specifically as follows:
[0180] Based on the closed concentric point number, select the concentric points that coexist in two adjacent states. Subtract the corrected horizontal coordinate of the concentric point in the previous state from the corrected horizontal coordinate of the concentric point in the next state to obtain the horizontal increment. Subtract the corrected vertical coordinate of the concentric point in the previous state from the corrected vertical coordinate of the concentric point in the next state to obtain the vertical increment. Subtract the corrected depth coordinate of the concentric point in the previous state from the corrected depth coordinate of the concentric point in the next state to obtain the depth increment. Combine the horizontal increment, vertical increment, and depth increment to form the three-dimensional coordinate difference of the same concentric point between adjacent states.
[0181] The release increment field is obtained as follows:
[0182] Using the corrected three-dimensional coordinates of the closing co-location point in the previous state as the surface position of the closing co-location point, the closing co-location point number, surface position, lateral increment, longitudinal increment, depth increment, previous state identifier, next state identifier, and corresponding release fixture unit number are associated to form the release increment of the closing co-location point in the corresponding adjacent state. The release increment of each closing co-location point in all adjacent states is associated according to the fixture release order to obtain the release increment field.
[0183] In this embodiment, the screening of necessary response kernels includes:
[0184] Read the reversible response kernels of each release increment field and the corresponding release fixture unit according to the release order of the fixtures. Fixtures whose response regions intersect with the regions where the release increment fields are located are identified as response overlapping fixtures, forming a candidate response kernel set, where:
[0185] The candidate response kernel set is composed as follows:
[0186] According to the release order of the clamps, the closed concentric point number, surface position and corresponding release clamp unit number in each release increment field are read. At the same time, the reversible response kernel of each clamp unit is read. The surface position of the closed concentric point that records the response intensity in the reversible response kernel is determined as the response region of the reversible response kernel. The surface position of the closed concentric point that records the three-dimensional coordinate difference in the release increment field is determined as the region where the release increment field is located. The closed concentric point number recorded by the reversible response kernel and the release increment field is compared. When there is at least one identical closed concentric point number, it is determined that the response region of the reversible response kernel intersects with the region where the release increment field is located. The clamp unit corresponding to the reversible response kernel is determined as the response overlapping clamp. The reversible response kernel of the corresponding release clamp unit is associated with the reversible response kernels of all response overlapping clamps according to the clamp unit number to form the candidate response kernel set of the current release increment field.
[0187] Based on the spatial location, response direction, and response intensity recorded in the candidate response kernel, the response displacements of each closed congruent point are inverted and superimposed to obtain the reversible elastic release field. Subtracting the reversible elastic release field from the release increment field yields the constrained coupling residual field, where:
[0188] Spatial position is the three-dimensional coordinates of the pre-intervention state at the closed co-location point, recorded when the reversible response kernel is formed; response direction is the release displacement obtained by subtracting the pre-intervention three-dimensional coordinates from the release state three-dimensional coordinates, and then dividing the lateral, longitudinal, and depth components of the release displacement by the release displacement amount to form three directional components; response intensity is the displacement corresponding to the unit clamping force change obtained by dividing the release displacement amount at the closed co-location point by the clamping force difference of the corresponding fixture unit.
[0189] The response shifts of each closed congruent point are inverted and superimposed, specifically as follows:
[0190] For each closed co-location point in the release increment field, the corresponding record is searched in the candidate response kernel set according to the closed co-location point number. If no corresponding record is found, the response displacement of the candidate response kernel at the closed co-location point is set to 0. When a corresponding record is found, the response intensity of the candidate response kernel record is multiplied by the clamping force difference of the corresponding clamp unit of the candidate response kernel to obtain the response displacement. Then, the response displacement is multiplied by the transverse component, longitudinal component and depth component of the response direction to obtain the transverse response displacement, longitudinal response displacement and depth response displacement generated by the candidate response kernel at the closed co-location point. The transverse response displacement, longitudinal response displacement and depth response displacement generated by all candidate response kernels are added together to obtain the superimposed response displacement of the closed co-location point. The numbers, surface positions and superimposed response displacements of all closed co-location points are associated to obtain the reversible elastic release field.
[0191] The constrained coupled residual field is obtained as follows:
[0192] According to the closed concentric point number, the lateral response displacement in the reversible elastic release field is subtracted from the lateral increment in the release increment field to obtain the lateral residual displacement. The longitudinal response displacement is subtracted from the longitudinal increment to obtain the longitudinal residual displacement. The depth response displacement is subtracted from the depth increment to obtain the depth residual displacement. The closed concentric point number, surface position, lateral residual displacement, longitudinal residual displacement and depth residual displacement are associated to obtain the constrained coupling residual field.
[0193] Candidate response kernels are deleted one by one and the inversion is performed again. The increment of the release increment field reconstruction error before and after deletion is calculated. Candidate response kernels whose reconstruction error increment exceeds the upper limit of the binocular measurement error are retained to obtain the necessary response kernels, where:
[0194] Candidate response kernels are deleted one by one and the inversion is performed again, specifically as follows:
[0195] The reversible elastic release field obtained by inverting the complete candidate response kernel set is used as the reversible elastic release field before deletion. Each time, one candidate response kernel is selected as the current candidate response kernel, and the current candidate response kernel is temporarily deleted from the candidate response kernel set. The response displacements of each closed congruent point are recalculated using the remaining candidate response kernels and superimposed to obtain the reversible elastic release field after deleting the current candidate response kernel. After the re-inversion of the current candidate response kernel is completed, the current candidate response kernel is restored to the candidate response kernel set, and the next candidate response kernel is selected and the process is repeated, so that each candidate response kernel corresponds to one reversible elastic release field after deletion.
[0196] Calculate the increment of the release increment field reconstruction error before and after deletion, specifically:
[0197] The reversible elastic release field before deletion and the constraint coupling residual field are added together according to the closed contiguous site number to obtain the reconstructed displacement before deletion. For the current candidate response kernel, the reversible elastic release field after deletion of the current candidate response kernel is added together with the same constraint coupling residual field according to the closed contiguous site number to obtain the reconstructed displacement after deletion corresponding to the current candidate response kernel. The corresponding increment in the release increment field is subtracted from the transverse, longitudinal, and depth components of the reconstructed displacement before deletion and the reconstructed displacement after deletion, respectively. The square root of the sum of the squares of the differences in the three directions is used to obtain the reconstructed error before deletion and the reconstructed error after deletion for each closed contiguous site. The average reconstructed error before deletion and the average reconstructed error after deletion for all closed contiguous sites are calculated. The average reconstructed error after deletion is subtracted from the average reconstructed error before deletion to obtain the reconstructed error increment of the release increment field corresponding to the current candidate response kernel.
[0198] The necessary response kernel is obtained, specifically:
[0199] The incremental reconstruction error of the release increment field corresponding to each candidate response core is compared with the upper limit of the binocular measurement error one by one. Candidate response cores whose incremental reconstruction error of the release increment field is not greater than the upper limit of the binocular measurement error are deleted, and candidate response cores whose incremental reconstruction error of the release increment field is greater than the upper limit of the binocular measurement error are retained. The retained candidate response cores are associated with the corresponding release increment field and the corresponding release fixture unit number to obtain the necessary response cores.
[0200] In this embodiment, generating the corrected counterfactual surface includes:
[0201] Read the necessary response kernel, reversible elastic release field, and constraint coupling residual field corresponding to each release increment field according to the clamp release sequence. Transform the reversible elastic release field and constraint coupling residual field to the post-weld clamping surface coordinate system and associate them with the corresponding closing contiguous points to obtain a unified release field sequence, where:
[0202] The clamp release sequence refers to the order in which the clamping force of each clamp unit changes from a non-zero value to 0 during the process of the welded part changing from a fully clamped state after welding to a completely free state. The release sequence of each clamp unit is determined from the earliest to the latest by the timestamps of the collection when the clamping force becomes 0.
[0203] The unified release field sequence is obtained as follows:
[0204] Read the necessary response kernel, reversible elastic release field, and constraint coupling residual field corresponding to each release increment field according to the release order of the fixture, and read the rotation and translation parameters of the corresponding state relative to the fully clamped state after welding. For each closed concentric point, multiply the original lateral coordinate, original longitudinal coordinate, and original depth coordinate of the surface position by the three values used to calculate the lateral coordinate after rotation in the rotation parameters and sum them to obtain the lateral coordinate after rotation. Obtain the longitudinal coordinate and depth coordinate after rotation in the same way. Then add the lateral translation, longitudinal translation, and depth translation to the three coordinates after rotation to obtain the surface position in the post-weld clamped surface coordinate system. Transform the lateral displacement, longitudinal displacement, and depth displacement of the reversible elastic release field and the constraint coupling residual field according to the same rotation method, but without adding translation parameters to obtain the three-dimensional displacement in the post-weld clamped surface coordinate system. Associate the transformed surface position, reversible elastic release field, constraint coupling residual field, necessary response kernel, closed concentric point number, and corresponding release fixture unit number, and arrange them according to the release order of the fixture to obtain a unified release field sequence.
[0205] Using the post-weld clamped surface as the initial surface, the three-dimensional displacements of each closed contiguous point are sequentially superimposed and the coordinates are updated according to a unified release field sequence to obtain the counterfactual free surface, where:
[0206] The counterfactual freedom surface is obtained as follows:
[0207] The three-dimensional coordinates of each closed concentric point in the clamping surface after welding are read and used as the initial coordinates. Starting from the first clamp release sequence according to the unified release field sequence, the corresponding reversible elastic release field and constraint coupling residual field are read sequentially. According to the closed concentric point number, the lateral displacement of the reversible elastic release field and the lateral displacement of the constraint coupling residual field are added to the current lateral coordinate of the closed concentric point. The two longitudinal displacements are added to the current longitudinal coordinate. The two depth displacements are added to the current depth coordinate to obtain the three-dimensional coordinates of the closed concentric point after the current clamp release sequence is completed. The updated three-dimensional coordinates are used as the current coordinates of the next clamp release sequence. The closed concentric points that have not recorded the corresponding three-dimensional displacements keep their current three-dimensional coordinates unchanged. After the coordinate update of all clamp release sequences is completed, the closed concentric point number is associated with the final three-dimensional coordinates to obtain the counterfactual free surface.
[0208] Compare the coordinates of the common closed congruent sites of the counterfactual free surface and the actual free surface. Adjust the response intensity of the necessary response kernels according to the coordinate deviation and re-superimpose them until the coordinate deviation does not exceed the upper limit of the binocular measurement error, thus generating a corrected counterfactual surface, where:
[0209] The response intensity of the necessary response kernel is adjusted and re-superimposed based on the coordinate deviation, specifically as follows:
[0210] Based on the closed contiguous point number, the closed contiguous points common to both the counterfactual free surface and the actual free surface are selected. The lateral coordinate deviation is obtained by subtracting the corresponding lateral coordinate of the counterfactual free surface from the lateral coordinate of the closed contiguous point on the actual free surface. The longitudinal coordinate deviation and depth coordinate deviation are obtained in the same way. For the necessary response kernel that records the corresponding closed contiguous point, the lateral coordinate deviation, longitudinal coordinate deviation, and depth coordinate deviation are multiplied by the corresponding components of the response direction of the necessary response kernel and added together to obtain the coordinate deviation along the response direction. The coordinate deviation along the response direction is divided by the clamping force difference of the corresponding fixture unit and then divided by the number of necessary response kernels that record the corresponding closed contiguous point to obtain the response intensity adjustment amount. The original response intensity of the necessary response kernel is added to the response intensity adjustment amount. If the calculation result is less than 0, it is set to 0 to obtain the adjusted response intensity. Keeping the constraint coupling residual field unchanged, the reversible elastic release field is recalculated using the adjusted response intensity. Then, the three-dimensional displacement of each closed contiguous point is re-superimposed according to the unified release field sequence to obtain the updated counterfactual free surface.
[0211] Generate a corrected counterfactual surface, specifically:
[0212] For each closed concentric point shared by the updated counterfactual free surface and the actual free surface, the corresponding coordinates of the updated counterfactual free surface are subtracted from the lateral, longitudinal, and depth coordinates of the actual free surface. The square root of the sum of the squares of the three coordinate differences is then taken to obtain the coordinate deviation of the closed concentric point. The response intensity of the necessary response kernel is repeatedly adjusted, the reversible elastic release field is recalculated, and the three-dimensional displacement is re-superimposed until the coordinate deviation of all shared closed concentric points does not exceed the upper limit of binocular measurement error. The adjustment is then stopped, and the final closed concentric point number, three-dimensional coordinates, and adjusted necessary response kernel are associated to generate the corrected counterfactual surface.
[0213] In this embodiment, the output of longitudinal shrinkage, lateral shrinkage, angular deformation, out-of-plane deformation, and deformation location includes:
[0214] Read the common contiguous points of the corrected counterfactual surface and the pre-weld clamping surface, establish a welding coordinate system with the weld extension direction, weld transverse direction, and surface normal, and unify the coordinates of the two surfaces based on the non-response rigid body anchor points to obtain the coordinate pairs of the contiguous points, where:
[0215] The common contiguous sites of the corrected counterfactual surface and the pre-weld clamping surface refer to contiguous sites that exist simultaneously in the corrected counterfactual surface and the pre-weld clamping surface, have the same contiguous site number, and correspond to the same weldment surface position. Each common contiguous site includes the three-dimensional coordinates in the corrected counterfactual surface and the three-dimensional coordinates in the pre-weld clamping surface.
[0216] The weld extension direction is a unit direction from the weld start position to the weld end position. The weld transverse direction is a unit direction located within the pre-welding clamping surface, perpendicular to the weld extension direction, and pointing from one side of the weld to the other side. The surface normal is a unit direction that is perpendicular to both the weld extension direction and the weld transverse direction and points to the outside of the weldment.
[0217] A welding coordinate system is established using the weld extension direction, the weld transverse direction, and the surface normal, specifically as follows:
[0218] Read the three-dimensional coordinates of the weld start position and the three-dimensional coordinates of the weld end position. Subtract the corresponding coordinates of the weld start position from the horizontal coordinate, vertical coordinate and depth coordinate of the weld end position to obtain three weld direction components. Divide each of the three weld direction components by the square root of the sum of the squares of the three weld direction components to obtain the weld extension direction.
[0219] One common closing point is selected on each side of the same extension position of the weld. The three-dimensional coordinates of the common closing point on one side of the weld are subtracted from the three-dimensional coordinates of the common closing point on the other side of the weld to obtain the three-dimensional direction across the weld. The projection of the three-dimensional direction across the weld onto the extension direction of the weld is subtracted. Then, the remaining three directional components are divided by the square root of the sum of the squares of the remaining three directional components to obtain the transverse direction of the weld.
[0220] Multiply the longitudinal component of the weld extension direction by the depth component of the weld transverse direction, and then subtract the product of the depth component of the weld extension direction and the longitudinal component of the weld transverse direction to obtain the transverse component of the surface normal. Obtain the longitudinal component and depth component of the surface normal by the same method of cross-multiplication and subtraction. Then divide the three components by the square root of the sum of the squares of the three components and adjust the direction to the outside of the welded part to obtain the surface normal.
[0221] The average three-dimensional coordinates of the non-responsive rigid body anchor points on the pre-welding clamping surface are used as the origin of the welding coordinate system. The weld extension direction is used as the longitudinal coordinate axis, the weld transverse direction is used as the transverse coordinate axis, and the surface normal is used as the normal axis.
[0222] The coordinate pairs of the same location are obtained as follows:
[0223] Screen the non-responsive rigid body anchor points shared by the correction counterfactual surface and the pre-weld clamping surface. Select three non-responsive rigid body anchor points that are not located on the same straight line from the shared non-responsive rigid body anchor points. Read the three-dimensional coordinates of the three non-responsive rigid body anchor points in the correction counterfactual surface and the pre-weld clamping surface according to the same closed concentric point number. In each surface, subtract the three-dimensional coordinates of the first non-responsive rigid body anchor point from the three-dimensional coordinates of the second non-responsive rigid body anchor point. Divide the three coordinate components obtained by the square root of the sum of the squares of the three coordinate components to obtain the first anchoring direction.
[0224] Subtract the three-dimensional coordinates of the first non-responsive rigid body anchor point from the three-dimensional coordinates of the third non-responsive rigid body anchor point, subtract the projection of the obtained direction onto the first anchoring direction, and then unify the length of the remaining direction to obtain the second anchoring direction. Calculate the third anchoring direction, which is perpendicular to both directions, based on the first and second anchoring directions. Add the lateral coordinates of all common non-responsive rigid body anchor points in the corrected counterfactual surface and divide by the number of common non-responsive rigid body anchor points to obtain the lateral coordinates of the anchoring center of the corrected counterfactual surface. Calculate the longitudinal and depth coordinates in the same way to obtain the anchoring center of the corrected counterfactual surface, and obtain the anchoring center of the pre-welding clamping surface in the same way.
[0225] For each common closed concentric point in the corrected counterfactual surface, the anchoring center of the corrected counterfactual surface is subtracted from the three-dimensional coordinates of the common closed concentric point to obtain the centered coordinates. The three components of the centered coordinates are multiplied by the corresponding components of the first anchoring direction of the corrected counterfactual surface and then added to obtain the first direction projection value. The second direction projection value and the third direction projection value are obtained in the same way. The first direction projection value is multiplied by the three components of the first anchoring direction of the pre-welding clamping surface, the second direction projection value is multiplied by the three components of the second anchoring direction of the pre-welding clamping surface, and the third direction projection value is multiplied by the three components of the third anchoring direction of the pre-welding clamping surface. The three sets of results are added in the same coordinate direction, and then the corresponding coordinates of the anchoring center of the pre-welding clamping surface are added to obtain the unified coordinates of the common closed concentric point in the coordinates of the pre-welding clamping surface. According to the concentric point number, the unified coordinates are associated with the three-dimensional coordinates of the corresponding common closed concentric point in the pre-welding clamping surface to obtain the same point coordinate pairs.
[0226] Calculate the projections of the coordinate differences at the same point onto the weld extension direction, the weld transverse direction, and the surface normal direction to obtain the longitudinal shrinkage, transverse shrinkage, and out-of-plane deformation. Calculate the included angle between the surface normals on both sides of the weld to obtain the angular deformation, where:
[0227] The projections of the coordinate differences at the same location points onto the weld extension direction, the weld transverse direction, and the surface normal are calculated as follows:
[0228] For each coordinate pair at the same point, the corresponding coordinates of the pre-weld clamping surface are subtracted from the unified transverse coordinates, unified longitudinal coordinates, and unified depth coordinates of the corrected antifactual surface to obtain the transverse, longitudinal, and depth components of the coordinate difference at the same point. The three coordinate components are multiplied by the corresponding components in the weld extension direction and added together. The absolute value of the sum is taken to obtain the longitudinal shrinkage. The three coordinate components are multiplied by the corresponding components in the transverse direction of the weld and added together. The absolute value of the sum is taken to obtain the transverse shrinkage. The three coordinate components are multiplied by the corresponding components in the surface normal direction and added together. The absolute value of the sum is taken to obtain the out-of-plane deformation.
[0229] The calculation of the included angle between the normals of the two surfaces on both sides of the weld is as follows:
[0230] Based on the spatial location of the common closure contiguous points on the left or right side of the weld, the common closure contiguous points are divided to both sides of the weld. Three common closure contiguous points not located on the same straight line are selected on each side of the same weld extension position. The first surface direction is obtained by subtracting the three-dimensional coordinates of the first common closure contiguous point from the three-dimensional coordinates of the second common closure contiguous point. The second surface direction is obtained by subtracting the three-dimensional coordinates of the first common closure contiguous point from the three-dimensional coordinates of the third common closure contiguous point. The longitudinal component of the first surface direction is multiplied by the depth component of the second surface direction, and then the depth component of the first surface direction is subtracted. The product of the longitudinal components of the second surface direction yields the transverse component of the surface normal. The longitudinal and depth components of the surface normal are obtained by subtracting the cross-multiplications. The three components are then divided by the square root of the sum of the squares of the three components and pointed outwards to obtain the surface normal of the corresponding side. The transverse, longitudinal, and depth components of the surface normals on both sides of the weld are multiplied, and the three products are added together. The inverse cosine of the sum is calculated to obtain the angle between the surface normals on both sides of the weld. The midpoint of the average three-dimensional coordinates of the common closed concentric points on both sides of the weld is taken as the angular deformation position.
[0231] The longitudinal shrinkage, transverse shrinkage, angular deformation, and out-of-plane deformation are associated with the spatial location of the closed coplanar site, and the maximum longitudinal shrinkage, maximum transverse shrinkage, maximum angular deformation, maximum out-of-plane deformation, and their corresponding deformation locations are extracted. The welding deformation detection results are then output, including:
[0232] The output of the welding deformation detection results is as follows:
[0233] The longitudinal shrinkage, transverse shrinkage, and out-of-plane deformation of each common closed concentric point are associated with the spatial position of the corresponding common closed concentric point in the welding coordinate system. The angular deformation of each weld extension position is associated with the corresponding angular deformation position. All longitudinal shrinkage, transverse shrinkage, angular deformation, and out-of-plane deformation are compared. The maximum longitudinal shrinkage, maximum transverse shrinkage, maximum angular deformation, and maximum out-of-plane deformation are extracted, and the spatial position associated with each maximum deformation is read. The maximum longitudinal shrinkage and corresponding deformation position, the maximum transverse shrinkage and corresponding deformation position, the maximum angular deformation and corresponding deformation position, and the maximum out-of-plane deformation and corresponding deformation position are obtained. The longitudinal shrinkage, transverse shrinkage, out-of-plane deformation, and spatial position of each common closed concentric point, the angular deformation of each weld extension position, and the four maximum deformations and their corresponding deformation positions are combined to form the welding deformation detection result and output.
[0234] refer to Figure 3 A welding deformation detection system based on image data processing includes the following modules:
[0235] The image acquisition module is used to acquire and preprocess binocular images of the multi-stage constraint state of the welded parts to obtain standard fixture intervention image data;
[0236] The co-location extraction module is used to input standard fixture intervention image data into the improved XFeat model to obtain closed co-locations;
[0237] The response kernel construction module is used to associate the spatial location of the closed concentric point, the release displacement, and the clamping force difference to determine the non-responsive rigid body anchor point.
[0238] The incremental field generation module is used to correct the closed conjoint points of the step-by-step release state based on the non-responding rigid body anchor points to obtain the release incremental field.
[0239] The release field inversion module is used to invert the release increment field based on the reversible response kernel, obtain the reversible elastic release field and the constraint-coupled residual field, and screen the necessary response kernels;
[0240] The counterfact correction module is used to superimpose the reversible elastic release field and constraint coupling residual field corresponding to the necessary response kernel onto the post-weld clamping surface, and correct it with the actual free surface to generate a corrected counterfact surface;
[0241] The deformation output module is used to output the longitudinal shrinkage, lateral shrinkage, angular deformation, out-of-plane deformation, and deformation position.
[0242] Example 1: To verify the feasibility of the present invention in practice, it was applied to a simulated inspection scenario constructed at a welding inspection station. The inspection object was a low-carbon steel butt welded component with a length of 1200 mm, a width of 600 mm, and a thickness of 8 mm. The weld length was 900 mm. Six clamping units capable of independent release and re-clamping were set on both sides of the weld. The clamping forces before welding were 12.06 kN, 11.94 kN, 12.11 kN, 12.03 kN, 11.87 kN, and 12.08 kN, respectively. The inspection system included a synchronous binocular camera, a clamping force sensor, and an image processing computer. The baseline distance of the binocular camera was 380 mm, and the original image resolution was 2448×2048 pixels. In contrast, the traditional method only performs ordinary feature matching and overall rigid body registration on the binocular images of the fully clamped state and the actual fully free state before welding, and then calculates the welding deformation based on the coordinate difference of the corresponding points. It is difficult to distinguish between the elastic rebound caused by the release of the clamps and the permanent welding deformation.
[0243] The improved XFeat model used 96 identical welded parts as samples, with 72 used for training, 12 for validation, and 12 for testing. For each welded part, images were collected in the following states: fully clamped before welding, fully clamped after welding, before intervention, release and re-clamping of the 6 clamping units, 6 progressive releases, and the actual completely free state. This resulted in 27 state binocular image pairs and 54 images, totaling 5184 images. 43680 closed concordance chains were labeled. The coordinates of the closed concordance site P-317 in the left-view images of the pre-intervention, release, and re-clamping states are as follows: For pixels 782.4 and 426.7, 784.1 and 422.8, and 782.6 and 426.5, the clamping force of the corresponding fixture unit decreased from 12.09 kN to 0.03 kN and then recovered to 12.05 kN. The three-dimensional release displacement was 0.73 mm, and the three-dimensional return residual was 0.08 mm. The reflective area ratio of the reflective sample YP-052 was 11.8%. Ordinary feature matching incorrectly associated the reflective edge of the weld seam with grinding texture points 5.7 mm apart. The improved XFeat model combined fixture projection, clamping force difference, and intervention phase to eliminate incorrect associations.
[0244] In the welded parts under test, the detection system sequentially collects images of the fully clamped state before welding, the fully clamped state after welding, the pre-intervention state of each fixture unit, the release state, and the re-clamping state. Then, it collects images of the release state in the order of C3, C1, C5, C2, C6, and C4. After all fixture units are released, the actual completely free state is collected. After state matching, brightness normalization, reflective area marking, and size normalization, 54 standard fixture intervention images are formed. Eleven effective reflective areas are detected, with the largest reflective area being 2741 pixels. The improved XFeat model extracts 14326 candidate key points from the standard fixture intervention images, forming 1268 candidate closed covariance chains. After non-commutative closed matching, binocular geometric correction, and mechanical return correction, 934 closed covariance points are retained. Among them, 900 matches are confirmed to be correct by manual verification, with a correct matching rate of 96.4%. The traditional method correctly matches 815 of the same 934 reference closed covariance points, with a correct matching rate of 87.3%.
[0245] Taking the closed coaxial point P-317 as an example, the three-dimensional coordinates before C3 intervention were 438.26 mm, 42.71 mm, and 6.38 mm, and the three-dimensional coordinates in the C3 release state were 438.41 mm, 42.52 mm, and 7.08 mm, with release displacements of 0.15 mm, -0.19 mm, and 0.70 mm, and a release displacement amount of 0.74 mm. The C3 clamping force difference was 12.06 kN, the response intensity was 0.0614 mm / kN, and the response directions were 0.203, -0.257, and 0.946. The detection system formed 6 reversible response kernels in the same manner, recording a total of 812 effective closed coaxial points, and screening out 57 non-responsive rigid body anchor points. The average coordinate deviation of the non-responsive rigid body anchor points before each step-by-step release state correction was 0.68 mm, which was reduced to 0.13 mm after correction by rotation and translation parameters. The influence of the overall translation and rotation of the welded part on the three-dimensional coordinates was reduced.
[0246] The corrected adjacent states form six release increment fields, containing 806, 798, 791, 785, 779, and 771 closed contiguous sites, respectively. The three-dimensional coordinate differences of the first release increment field at P-317 are 0.15 mm, -0.19 mm, and 0.70 mm. The response shifts inverted from the C3 reversible response kernel are 0.14 mm, -0.18 mm, and 0.66 mm, and the overlapping response shifts generated by the C2 reversible response kernel are 0.02 mm, -0.01 mm, and 0.05 mm. After superposition, a result of 0.16 mm and -0.05 mm is obtained. The reversible elastic response displacements of 0.19 mm and 0.71 mm were obtained. After subtracting the reversible elastic release field from the release increment field, the constrained coupling residual displacements of -0.01 mm, 0 mm, and -0.01 mm were obtained. After deleting the C3 reversible response core, the average reconstruction error of the first release increment field increased from 0 mm to 0.36 mm, exceeding the upper limit of the binocular measurement error of 0.2 mm. The C3 reversible response core was retained. After deleting the C6 reversible response core, the average reconstruction error increased by 0.08 mm. The C6 reversible response core was deleted. A total of 14 necessary response cores were retained in the entire release increment field.
[0247] The detection system transforms the necessary response kernel, reversible elastic release field, and constraint-coupled residual field into the coordinate system of the post-weld clamping surface, and superimposes them sequentially according to the release order of the fixture. P-317 is updated from 438.26 mm, 42.71 mm, and 6.38 mm on the post-weld clamping surface to 438.41 mm, 42.52 mm, and 7.08 mm after C3 release. After 6 release field superpositions, it is updated to 438.49 mm, 42.44 mm, and 7.49 mm. The coordinates of P-317 on the actual free surface are 438.47 mm, 42.45 mm, and 7.43 mm. The initially formed counterfactual free surface has 763 closed contiguous points with the actual free surface, with an average coordinate deviation of 0.28 mm and a maximum coordinate deviation of 0.58 mm. After 3 response intensity adjustments and re-superpositions, the average coordinate deviation is reduced to 0.14 mm, and the maximum coordinate deviation is reduced to 0.19 mm, generating a corrected counterfactual surface.
[0248] The corrected counterfactual surface and the pre-weld clamping surface form 748 coordinate pairs at the same points. The maximum longitudinal shrinkage is 2.90 mm, the maximum transverse shrinkage is 1.53 mm, the maximum angular deformation is 1.41 degrees, and the maximum out-of-plane deformation is 2.30 mm. The corresponding deformation positions are located at 438 mm, 526 mm, 612 mm, and 574 mm from the weld start position, respectively. The precision three-dimensional scanning reference results are 2.79 mm, 1.43 mm, 1.32 degrees, and 2.17 mm, respectively. The absolute errors of the method of this invention are 0.11 mm, 0.10 mm, 0.09 degrees, and 0.13 mm, respectively. The traditional method yields 3.17 mm, 1.71 mm, 1.59 degrees, and 2.56 mm, with absolute errors of 0.38 mm, 0.28 mm, 0.27 degrees, and 0.39 mm, respectively.
[0249] The same verification was performed on 12 test welded parts, and a total of 10,960 reference closed concentric points were obtained. The method of the present invention correctly matched 10,390 points, with a correct matching rate of 94.8%, while the traditional method correctly matched 9,566 points, with a correct matching rate of 87.3%. The root mean square error of the three-dimensional coordinates of the method of the present invention and the traditional method were 0.24 mm and 0.45 mm, respectively; the average absolute error of longitudinal shrinkage was 0.12 mm and 0.35 mm, respectively; the average absolute error of transverse shrinkage was 0.10 mm and 0.27 mm, respectively; the average absolute error of angular deformation was 0.09 degrees and 0.24 degrees, respectively; and the average absolute error of out-of-plane deformation was 0.14 mm and 0.36 mm, respectively. The verification results show that the present invention can improve the matching stability of closed concentric points under the conditions of reflective surfaces, step-by-step release of the fixture, and overall movement of the welded part, and reduce the situation of misjudging reversible elastic rebound as permanent welding deformation.
[0250] The above description is only a preferred embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any equivalent substitutions or modifications made by those skilled in the art within the scope of the technology disclosed in the present invention, based on the technical solution and inventive concept of the present invention, should be covered within the scope of protection of the present invention.
Claims
1. A welding deformation detection method based on image data processing, characterized in that, include: Acquire binocular images of the multi-stage constraint state of the welded parts, and perform preprocessing on the binocular images of the multi-stage constraint state of the welded parts to obtain standard fixture intervention image data; Standard fixture intervention image data is input into an improved XFeat model, which includes a shared feature backbone, an intervention conditional coding layer, a key point description layer, a non-commutative closure decoder, a joint geometric refinement layer, and a retrace reliability head to obtain closure concordance points. Based on the spatial position, release displacement and clamping force difference of the associated closed concentric point of the clamping unit, a reversible response core is formed to determine the non-response rigid body anchoring point. Based on the closed conjoint points of the step-by-step release state corrected by the non-responsive rigid body anchor point, the coordinate difference between adjacent states is calculated to obtain the release increment field. Based on the reversible response kernel of the release clamp and the response overlapping clamp, the release increment field is inverted to obtain the reversible elastic release field and the constraint coupling residual field, and the necessary response kernels are selected. The reversible elastic release field and constraint coupling residual field corresponding to the necessary response core are superimposed on the post-weld clamping surface according to the release order to obtain the antifactual free surface, and then corrected with the actual free surface to generate the corrected antifactual surface; Calculate the coordinate difference between the corrected anti-factual surface and the pre-welding clamping surface, and output the longitudinal shrinkage, transverse shrinkage, angular deformation, out-of-plane deformation, and deformation location.
2. The welding deformation detection method based on image data processing according to claim 1, characterized in that, The multi-stage constraint state binocular images of the welded parts specifically include binocular images of the fully clamped state before welding, binocular images of the fully clamped state after welding, binocular images of the state before intervention corresponding to each fixture unit, binocular images of the released state and binocular images of the re-clamped state, binocular images of the release state acquired according to the release order of the fixtures, and binocular images of the actual completely free state after all fixture units are released. Each state binocular image includes a left view image and a right view image acquired synchronously.
3. The welding deformation detection method based on image data processing according to claim 1, characterized in that, The preprocessing of the binocular images of the multi-stage constrained state of the welded parts specifically includes state matching, distortion correction, epipolar correction, effective area cropping, brightness normalization, reflective area marking, and size normalization.
4. The welding deformation detection method based on image data processing according to claim 1, characterized in that, The process of obtaining the closed concordant locus includes: An improved XFeat model is constructed, which includes a shared feature backbone, an intervention conditional coding layer, a key point description layer, a non-commutative closure decoder, a joint geometric refinement layer, and a homing reliability head. Standard clamp intervention image data are input into the shared feature backbone according to the pre-intervention, release and re-clamping states. The basic features of the left and right view images of each state are extracted. The clamp unit position is projected onto the corresponding image, the clamping force difference is calculated and the intervention phase is encoded. After being fused by the intervention condition encoding layer, the intervention condition features are obtained. The intervention condition features are input into the key point description layer to extract key point coordinates, 64-dimensional feature descriptions and image matching reliability. The matching relationship from pre-intervention to release, release to re-clamp and pre-intervention to re-clamp is established through a non-commutative closed decoder. The combined return position is obtained by combining the pre-intervention to release and release to re-clamp matching relationships and comparing it with the direct return position of the pre-intervention to re-clamp matching relationship to obtain the candidate closed colocation chain. The key points of the candidate closed co-location chain are read in the left and right view images of the three states by the joint geometric refinement layer. Based on the binocular camera calibration parameters, the epipolar residual, reprojection residual, image closure residual and three-dimensional homing residual are jointly corrected to obtain the candidate closed co-location three-dimensional points. The release displacement, repositioning, three-dimensional repositioning residual, clamping force recovery ratio, and reprojection error of the candidate closed co-location three-dimensional points are input into the repositioning reliability head to generate mechanical repositioning reliability. After fusion with the image matching reliability, the closed co-location points are selected. The improved XFeat model was trained using a weighted sum of feature matching loss, non-commutative closure loss, and geometric homing loss as the optimization objective. The parameters of the shared feature backbone, intervention conditional encoding layer, key point description layer, non-commutative closure decoder, joint geometric refinement layer, and homing reliability head were continuously optimized. When the decrease in the joint loss on the validation set was less than 0.001 for 10 consecutive training epochs, the improved XFeat model was considered to have converged and training was stopped.
5. The welding deformation detection method based on image data processing according to claim 1, characterized in that, The determination of the non-responsive rigid body anchor point includes: Read the spatial position and clamping force of the closed co-position of the clamping unit before intervention, release and re-clamping states, calculate the release displacement, clamping force difference and three-dimensional return residual from before intervention to release state, and remove the closed co-position of the clamping unit whose three-dimensional return residual exceeds the upper limit of binocular measurement error. The ratio of the release displacement of each closed co-position point to the difference in clamping force is used as the response intensity. Combined with the distance of the closed co-position point relative to the projected position of the fixture, the direction of the release displacement, and the spatial position, a reversible response core for each fixture unit is formed. By superimposing the response quantities generated by all reversible response kernels at each closed concentric point, and screening out the closed concentric points where the synthetic response quantity and the change in the distance between different states do not exceed the upper limit of the binocular measurement error, the non-response rigid body anchor points are obtained.
6. The welding deformation detection method based on image data processing according to claim 1, characterized in that, The obtained release increment field includes: Read the closed contiguous points of the fully clamped state after welding, each step of the release state and the actual fully free state. Using the non-responsive rigid body anchor point common to each state as the reference, calculate the rotation and translation parameters of each state relative to the fully clamped state after welding. Based on the rotation and translation parameters, the corresponding closed coherent points are corrected, and the corrected closed coherent points are unified to the coordinate system of the fully clamped state after welding. Adjacent states are associated according to the order of clamp release. Select common closure contiguous sites in adjacent states, calculate the three-dimensional coordinate difference of the same closure contiguous site between adjacent states, and write according to the surface position of the closure contiguous site and the corresponding release fixture unit to obtain the release increment field.
7. The welding deformation detection method based on image data processing according to claim 1, characterized in that, The filtering of necessary response kernels includes: Read the reversible response kernels of each release increment field and the corresponding release fixture unit according to the release order of the fixtures, and determine the fixtures where the response region intersects with the region where the release increment field is located as response overlapping fixtures, forming a set of candidate response kernels; Based on the spatial location, response direction and response intensity of the candidate response kernel record, the response displacement of each closed co-location point is inverted and superimposed to obtain the reversible elastic release field. The reversible elastic release field is then subtracted from the release increment field to obtain the constrained coupling residual field. Candidate response kernels are deleted one by one and inverted again. The increment of the release increment field reconstruction error before and after deletion is calculated. Candidate response kernels whose reconstruction error increment exceeds the upper limit of binocular measurement error are retained to obtain the necessary response kernels.
8. The welding deformation detection method based on image data processing according to claim 1, characterized in that, The generation of the corrected counterfactual surface includes: Read the necessary response kernel, reversible elastic release field and constraint coupling residual field corresponding to each release increment field according to the release order of the clamp. Transform the reversible elastic release field and constraint coupling residual field to the post-weld clamping surface coordinate system and associate them with the corresponding closed coherent points to obtain a unified release field sequence. Using the post-weld clamped surface as the initial surface, the three-dimensional displacements of each closed contiguous point are superimposed and the coordinates are updated in sequence according to the unified release field sequence to obtain the counterfactual free surface; The coordinates of the common closed concentric points of the counterfactual free surface and the actual free surface are compared. The response intensity of the necessary response kernel is adjusted according to the coordinate deviation and then superimposed again until the coordinate deviation does not exceed the upper limit of the binocular measurement error, thus generating the corrected counterfactual surface.
9. The welding deformation detection method based on image data processing according to claim 1, characterized in that, The output longitudinal shrinkage, lateral shrinkage, angular deformation, out-of-plane deformation, and deformation location include: Read the common closed concentric points of the corrected counterfactual surface and the pre-weld clamping surface, establish a welding coordinate system with the weld extension direction, weld transverse direction and surface normal, and unify the coordinates of the two surfaces based on the non-response rigid body anchor point to obtain the coordinate pairs of the same point. Calculate the projection of the coordinate difference at the same point onto the weld extension direction, the weld transverse direction, and the surface normal to obtain the longitudinal shrinkage, transverse shrinkage, and out-of-plane deformation. Calculate the included angle between the surface normals on both sides of the weld to obtain the angular deformation. The longitudinal shrinkage, transverse shrinkage, angular deformation, and out-of-plane deformation are associated with the spatial location of the closed coplanar site, and the maximum longitudinal shrinkage, maximum transverse shrinkage, maximum angular deformation, maximum out-of-plane deformation, and corresponding deformation location are extracted, and the welding deformation detection results are output.
10. A welding deformation detection system based on image data processing, comprising the welding deformation detection method based on image data processing as described in any one of claims 1 to 9, characterized in that, Includes the following modules: The image acquisition module is used to acquire and preprocess binocular images of the multi-stage constraint state of the welded parts to obtain standard fixture intervention image data; The co-location extraction module is used to input standard fixture intervention image data into the improved XFeat model to obtain closed co-locations; The response kernel construction module is used to associate the spatial location of the closed concentric point, the release displacement, and the clamping force difference to determine the non-responsive rigid body anchor point. The incremental field generation module is used to correct the closed conjoint points of the step-by-step release state based on the non-responding rigid body anchor points to obtain the release incremental field. The release field inversion module is used to invert the release increment field based on the reversible response kernel, obtain the reversible elastic release field and the constraint-coupled residual field, and screen the necessary response kernels; The counterfact correction module is used to superimpose the reversible elastic release field and constraint coupling residual field corresponding to the necessary response kernel onto the post-weld clamping surface, and correct it with the actual free surface to generate a corrected counterfact surface; The deformation output module is used to output the longitudinal shrinkage, lateral shrinkage, angular deformation, out-of-plane deformation, and deformation position.
