Self-adaptive parameter-adjusting automatic welding method based on Ros framework
By using BP neural network and visual system during automatic welding, the welding process parameters are adjusted in real time, and the problem of difficult to adjust welding process parameters in real time is solved, and the welding efficiency and quality are improved.
Patent Information
- Application Number
- CN202411597277.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-11
- Publication Date
- 2025-02-18
AI Technical Summary
During the automatic welding process, it is difficult to adjust the welding process parameters in real time during the welding process, resulting in low welding quality and production efficiency.
The correspondence between welding process parameters and weld forming dimensions is obtained through orthogonal process experiments, the BP neural network is trained, the weld image is obtained using the visual system, the weld width is extracted, and the welding process parameters are predicted through the Ros architecture embedded in the BP neural network to achieve the Ros architecture and adaptive adjustment.
The welding process parameters are adjusted in real time according to the weld width, which improves welding efficiency and quality, and simplifies the welding process parameter adjustment process.
Smart Images

Figure SMS_1 
Figure SMS_2 
Figure QLYQS_1
Abstract
Description
Technical Field
[0001] The present invention relates to the field of welding, and in particular to an automatic welding method with adaptive parameter adjustment based on a Ros architecture. Background Art
[0002] In the actual production process, due to the uncertainty of cutting, assembly, etc., the gap of butt welding often fluctuates. When the butt gap error is large, the welding process parameters should be adjusted appropriately to ensure good weld formation and welding quality. In the manual welding process, the welder can use his eyes to observe the changes in the butt gap, and then adjust the height of the welding gun or the wire feeding speed to ensure the welding quality. However, in the automatic welding process, once the welding process parameters are determined, it is often difficult to adjust them in real time during the welding process. Even if the welding gap can be monitored online with the help of visual sensors, it is difficult to correct the process parameters in time according to the gap size to achieve closed-loop control. The adjustment of welding process parameters requires human intervention, resulting in low welding production efficiency. Neural networks learn samples, map and approximate the complex laws hidden in a large pile of data, and are constantly refined during use. They can make up for the shortcomings of regression formulas and finite element predictions, establish a nonlinear mapping relationship between welding process parameters and weld formation dimensions, and realize the prediction of welding process parameters or weld formation dimensions. Summary of the invention
[0003] According to the above technical problems, the present invention provides an automatic welding method with adaptive parameter adjustment based on the Ros framework, and the specific idea is: the weld formation size under different welding process parameters is obtained through orthogonal process experiments, and it is used as sample data to train the BP neural network; the weld image is acquired by the visual system and image algorithm processing and feature point extraction are performed, and the weld width is obtained from the world coordinates of the feature points; the BP neural network embedded in the Ros framework predicts the welding process parameters by starting the BP neural network node, and finally the purpose of automatic welding is achieved by adaptively adjusting the process parameters according to the weld width.
[0004] The steps of the technical solution of the present invention are as follows:
[0005] Step 1: Taking welding speed and wire feeding speed as variables, select the range of welding process parameters, design an orthogonal experiment, deposit a series of 50mm-long cladding layers on a flat plate, measure the width of the cladding layer after cladding is completed, and establish the corresponding relationship between welding process parameters and weld width as the training sample data of the neural network;
[0006] Step 2: Use the training samples to learn and train the BP neural network, take the weld width as the model input, take the welding process parameters as the expected model output, and obtain the nonlinear mapping relationship between the welding process parameters and the weld width;
[0007] Step 3, create a function in Ros to include the trained model file and related code, as well as a launch file to start the BP neural network;
[0008] Step 4: Configure the launch file, including specifying the model file path, device type, input and output topics, etc.
[0009] Step 5: Use a visual sensor to obtain a weld image, obtain the weld feature point position information through an image processing algorithm, and then obtain the weld width;
[0010] Step 6: Run the launch file, start the BP neural network node, take the weld width as input, and predict the process parameters;
[0011] Step 7: The robot performs welding path planning to obtain the walking trajectory and posture of the welding gun;
[0012] Finally, automated welding is carried out under the predicted process parameters.
[0013] The advantages of the present invention are as follows: the present invention simplifies the welding process parameter adjustment process, can obtain the weld width after a certain algorithm processing based on the image obtained by the visual system, and use the weld width as the input layer to predict the welding process parameters using the BP neural network. As an open source robot development platform, the Ros system provides a large number of native and third-party tools and library functions. Based on the Ros architecture, the present invention creates a visual system toolkit, which includes the acquisition of weld images, algorithm processing of images, weld width extraction and image visualization functions. A BP neural network toolkit is also created to predict the welding process parameters based on the weld width. The toolkit is called in the form of a startup node to realize the automated operation of the entire welding process, which significantly improves the welding efficiency and welding quality. BRIEF DESCRIPTION OF THE DRAWINGS
[0014] (1) Figure 1 Schematic diagram of the robot welding system of the present invention
[0015] (2) Figure 2 This is the flow chart of BP neural network training
[0016] (3) Figure 3 It is the welding of variable width welds
[0017] (4) Figure 4 Robot automatic welding flow chart
[0018] (5) Figure 5 This is the flow chart of the weld image algorithm processing
[0019] (6) Figure 6The method is used to realize the automatic welding of variable weld width.
[0020] Specific implementation method
[0021] The present invention is further described below in conjunction with the accompanying drawings and specific implementation methods.
[0022] like Figure 1 As shown, the robot welding system of the present invention is mainly composed of a host computer, a robot system, a welding system and a visual sensor system. The robot system is mainly composed of an ABB welding robot body, a control cabinet and a teaching pendant; the welding system is mainly composed of a Fronius CMT welding power supply, a TPS4000 digital welding machine, a wire feeder, a mixed gas ratio box, a protective gas, etc.; the visual sensor system composed of a CCD camera and a lens collects weld images. The system is installed on the welding gun of the welding robot through a self-made fixture; a computer with a Linux system installed is used as the host computer, and is also used to run related programs and train BP neural networks.
[0023] The practical application steps of this embodiment are as follows:
[0024] Step 1: Taking welding speed and wire feeding speed as variables, select the range of welding process parameters, design an orthogonal experiment, deposit a series of 50mm-long cladding layers on a flat plate, measure the width and height of the cladding layer after cladding is completed, and establish the corresponding relationship between welding process parameters and weld formation dimensions as the training sample data of the neural network;
[0025] Step 2: Combine Figure 2 This embodiment is described. The BP neural network is learned and trained using training samples. The weld formation characteristic quantity is used as the model input, and the welding process parameters are used as the expected model output. The nonlinear mapping relationship between the welding process parameters and the weld width is obtained. The training parameters are shown in the following table.
[0026]
[0027]
[0028] Step 3, create a function in Ros to include the trained model file and related code, as well as a launch file to start the BP neural network;
[0029] Step 4: Configure the launch file, including specifying the model file path, device type, input and output topics, etc.
[0030] Step 5: Use a visual sensor to obtain a weld image, obtain the weld feature point position information through an image processing algorithm, and then obtain the weld width;
[0031] Step 6: Run the launch file, start the BP neural network node, take the weld width as input, and predict the process parameters;
[0032] Step 7: The robot performs welding path planning to obtain the walking trajectory and posture of the welding gun;
[0033] Finally, automated welding is carried out under the predicted process parameters.
[0034] In order to verify the feasibility of the present invention, we conducted a butt welding experiment with variable weld width. Figures 3 to 6 This embodiment is described:
[0035] Step S1, welding material preparation:
[0036] Q235 low alloy steel is used as the welding base material, the base material size is 140mm*50mm*3mm, the welding wire brand is ER70S-G, and the diameter is 1.2mm.
[0037] Step S2: Preparation before welding:
[0038] 1. Grind the surface of the workpiece to remove impurities such as surface oxide film;
[0039] 2. Use alcohol to wipe the surface of the workpiece and blow it dry with cold air from a hair dryer to keep it dry.
[0040] Step S3, start the Ros end, make a Socket connection, and confirm that the robot signal is normal;
[0041] Step S4, the robot teaches to confirm the connection and sets it to automatic mode;
[0042] Step S5, click the welding button to switch to welding state;
[0043] Step S6, combining the topic and service communication mechanism, develop multiple different ROS nodes for data processing and transmission, including camera nodes, image processing nodes, and image visualization nodes, etc., and enable data interaction between nodes by publishing and subscribing to topics. Image processing is performed in OpenCV, and the transmission between Ros and OpenCV can be established through Cvbrigdge. As a publisher, the node converts the acquired image from OpenCV format to ROS Message format through the Cvbridge function package. The image visualization node obtains the weld image in Ros Message format by subscribing to the topic and finally displays it in the interactive interface;
[0044] Step S7, start the BP neural network node, predict the welding process parameters according to the weld width, run the model in Ros and publish the results;
[0045] Step S8: The robot node subscribes to the topic published by the BP neural network node to obtain the predicted welding process parameters.
[0046] Step S9, the robot obtains the welding gun walking trajectory and welding gun posture through welding path planning;
[0047] Step S10, start welding.
Claims
1. An automatic welding method with adaptive parameter adjustment based on Ros architecture, characterized in that: Through orthogonal process experiments, the weld formation dimensions under different welding process parameters are obtained, and they are used as sample data to train the BP neural network; the weld image is acquired by the visual system, and image algorithm processing and feature point extraction are performed, and the weld width is obtained from the world coordinates of the feature points; the BP neural network toolkit is embedded in the Ros framework and the welding process parameters are predicted by starting the BP neural network node, ultimately achieving the purpose of automated welding by adaptively adjusting the process parameters according to the weld width.
2. An automatic welding method with adaptive parameter adjustment based on Ros architecture, the method comprising the following steps: Step 1: Taking welding speed and wire feeding speed as variables, select the range of welding process parameters, design an orthogonal experiment, deposit a series of 50mm-long cladding layers on a flat plate, measure the width of the cladding layer after cladding is completed, and establish the corresponding relationship between welding process parameters and weld width as the training sample data of the neural network; Step 2: Use the training samples to learn and train the BP neural network, take the weld width as the model input, take the welding process parameters as the expected model output, and obtain the nonlinear mapping relationship between the welding process parameters and the weld width; Step 3, create a function in Ros to include the trained model file and related code, as well as a launch file to start the BP neural network; Step 4: Configure the launch file, including specifying the model file path, device type, input and output topics, etc. Step 5: Use a visual sensor to obtain a weld image, obtain the weld feature point position information through an image processing algorithm, and then obtain the weld width; Step 6: Run the launch file, start the BP neural network node, take the weld width as input, and predict the process parameters; Step 7: The robot performs welding path planning to obtain the walking trajectory and posture of the welding gun; Finally, automated welding is carried out under the predicted process parameters.
3. According to the automatic welding method with adaptive parameter adjustment based on Ros architecture as described in claim 2, it is characterized in that: In the step 1, the welding process parameters include: shielding gas flow rate of 15L / min, carbon dioxide and argon ratio of 4:
1. A unified adjustment mode is adopted, that is, the welding current and welding voltage are determined by the wire feeding speed, the welding speed adjustment range is 3-11mm / s, the step length is 1; the wire feeding speed adjustment range is 2-8m / min, the step length is 0.5, and a total of 169 sets of CMT thin plate butt joint process test data are designed as training samples.
4. According to the automatic welding method with adaptive parameter adjustment based on Ros architecture as described in claim 2, it is characterized in that: The BP neural network includes an input layer, a hidden layer, an output layer and transfer functions between the layers. The BP neural network can contain different hidden layers. The number of nodes in the hidden layer can generally be designed according to the empirical formula: Among them, m and n are the number of input and output nodes respectively, and α is a constant, which is generally between 1 and 10.
5. According to claim 4, the input layer is the weld width, the output layer is the welding process parameters (wire feeding speed and welding speed), the number of training times is 1000 times, the hidden layer activation function is ReLU, the output layer activation function is Sigmoid, and the network learning rate is 0.
05.
6. The automatic welding method with adaptive parameter adjustment based on Ros architecture according to claim 2 is characterized in that: Take the camera as a node and obtain the image information collected by the camera by subscribing to the topics published by the node.
7. The image processing algorithm according to claim 6 is encapsulated and packaged under the Ros architecture, and the image acquired by the visual sensor is processed by starting the node.
8. The image processing algorithm according to claim 7 comprises: ROI (Region of Interest) selection, Gaussian filtering, image adaptive threshold segmentation, morphological processing, and edge recognition using the Canny operator to obtain the pixel coordinates of each edge of the plate.
9. The pixel coordinates of the feature points according to claim 8 need to be converted into world coordinates.
10. The automatic welding method with adaptive parameter adjustment based on Ros architecture according to claim 2 is characterized in that: In step 6, the least squares method is used to fit the edge straight lines and find the intersection between the straight lines. The intersection is the corner point on the plate. The center point between the two corner points on the same side is the starting point and the end point of the welding position. Connect the starting point and the end point to form a straight line, which is the center line of the weld. Draw a perpendicular line through any point on the center line of the weld, and find the intersection of the perpendicular line and the two edge straight lines of the weld. The distance between the intersection points is the weld width.